@tom2012/cc-web 1.5.54 → 1.5.56

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (23) hide show
  1. package/README.md +1 -1
  2. package/backend/dist/index.d.ts.map +1 -1
  3. package/backend/dist/index.js +3 -0
  4. package/backend/dist/index.js.map +1 -1
  5. package/frontend/dist/assets/{ChatView-SSfb4jQh.js → ChatView-DH14n4YW.js} +1 -1
  6. package/frontend/dist/assets/{GraphPreview-Bu10mEVC.js → GraphPreview-B0dC7c_q.js} +1 -1
  7. package/frontend/dist/assets/{OfficePreview-B76DK236.js → OfficePreview-CHGUXowA.js} +3 -3
  8. package/frontend/dist/assets/{ProjectPage-Cs_pFCyS.js → ProjectPage-BbEOvh4D.js} +4 -4
  9. package/frontend/dist/assets/{SettingsPage-Cb6j2aJ3.js → SettingsPage-W-rH5UiK.js} +1 -1
  10. package/frontend/dist/assets/{ShareViewPage-DXmGmoZM.js → ShareViewPage-BmPLFG-T.js} +1 -1
  11. package/frontend/dist/assets/{SkillHubPage-BjkmFW9M.js → SkillHubPage-COgCGxfO.js} +1 -1
  12. package/frontend/dist/assets/{bot-Dvon5AP9.js → bot-ByqY_wjy.js} +1 -1
  13. package/frontend/dist/assets/{chevron-down-oywyj_mF.js → chevron-down-Dr94IS1X.js} +1 -1
  14. package/frontend/dist/assets/{download-s_UyPGX4.js → download-DYEz-nxl.js} +1 -1
  15. package/frontend/dist/assets/index-CjekP9LT.js +275 -0
  16. package/frontend/dist/assets/{index-D_ReGjmg.js → index-DHv2QLtK.js} +1 -1
  17. package/frontend/dist/assets/{index-DhOfrbbP.css → index-Dtp6YTZg.css} +1 -1
  18. package/frontend/dist/assets/{jszip.min-DDXUx9vE.js → jszip.min-DziwEKhw.js} +1 -1
  19. package/frontend/dist/assets/{save-DXU_4k3M.js → save-CeOqUQlr.js} +1 -1
  20. package/frontend/dist/assets/{user-DrmNnlq0.js → user-CV9nu6Vl.js} +1 -1
  21. package/frontend/dist/index.html +2 -2
  22. package/package.json +1 -1
  23. package/frontend/dist/assets/index-D4FtflMi.js +0 -275
@@ -0,0 +1,275 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/ProjectPage-BbEOvh4D.js","assets/save-CeOqUQlr.js","assets/download-DYEz-nxl.js","assets/chevron-down-Dr94IS1X.js","assets/bot-ByqY_wjy.js","assets/user-CV9nu6Vl.js","assets/ProjectPage-9CEnUXvW.css","assets/SettingsPage-W-rH5UiK.js","assets/SkillHubPage-COgCGxfO.js","assets/ShareViewPage-BmPLFG-T.js"])))=>i.map(i=>d[i]);
2
+ var pw=Object.defineProperty;var mw=(e,t,n)=>t in e?pw(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var tl=(e,t,n)=>mw(e,typeof t!="symbol"?t+"":t,n);function gw(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const s in r)if(s!=="default"&&!(s in e)){const o=Object.getOwnPropertyDescriptor(r,s);o&&Object.defineProperty(e,s,o.get?o:{enumerable:!0,get:()=>r[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const o of s)if(o.type==="childList")for(const i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&r(i)}).observe(document,{childList:!0,subtree:!0});function n(s){const o={};return s.integrity&&(o.integrity=s.integrity),s.referrerPolicy&&(o.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?o.credentials="include":s.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(s){if(s.ep)return;s.ep=!0;const o=n(s);fetch(s.href,o)}})();var _M=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Nm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function IM(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var s=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,s.get?s:{enumerable:!0,get:function(){return e[r]}})}),n}var jm={exports:{}},ya={},Rm={exports:{}},G={};/**
3
+ * @license React
4
+ * react.production.min.js
5
+ *
6
+ * Copyright (c) Facebook, Inc. and its affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */var xo=Symbol.for("react.element"),yw=Symbol.for("react.portal"),vw=Symbol.for("react.fragment"),xw=Symbol.for("react.strict_mode"),ww=Symbol.for("react.profiler"),Sw=Symbol.for("react.provider"),Ew=Symbol.for("react.context"),kw=Symbol.for("react.forward_ref"),bw=Symbol.for("react.suspense"),Cw=Symbol.for("react.memo"),Tw=Symbol.for("react.lazy"),xf=Symbol.iterator;function Pw(e){return e===null||typeof e!="object"?null:(e=xf&&e[xf]||e["@@iterator"],typeof e=="function"?e:null)}var Mm={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Am=Object.assign,Dm={};function ls(e,t,n){this.props=e,this.context=t,this.refs=Dm,this.updater=n||Mm}ls.prototype.isReactComponent={};ls.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): 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")};ls.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Lm(){}Lm.prototype=ls.prototype;function Pc(e,t,n){this.props=e,this.context=t,this.refs=Dm,this.updater=n||Mm}var Nc=Pc.prototype=new Lm;Nc.constructor=Pc;Am(Nc,ls.prototype);Nc.isPureReactComponent=!0;var wf=Array.isArray,Om=Object.prototype.hasOwnProperty,jc={current:null},_m={key:!0,ref:!0,__self:!0,__source:!0};function Im(e,t,n){var r,s={},o=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(o=""+t.key),t)Om.call(t,r)&&!_m.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1<a){for(var l=Array(a),c=0;c<a;c++)l[c]=arguments[c+2];s.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)s[r]===void 0&&(s[r]=a[r]);return{$$typeof:xo,type:e,key:o,ref:i,props:s,_owner:jc.current}}function Nw(e,t){return{$$typeof:xo,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Rc(e){return typeof e=="object"&&e!==null&&e.$$typeof===xo}function jw(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Sf=/\/+/g;function nl(e,t){return typeof e=="object"&&e!==null&&e.key!=null?jw(""+e.key):t.toString(36)}function di(e,t,n,r,s){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var i=!1;if(e===null)i=!0;else switch(o){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case xo:case yw:i=!0}}if(i)return i=e,s=s(i),e=r===""?"."+nl(i,0):r,wf(s)?(n="",e!=null&&(n=e.replace(Sf,"$&/")+"/"),di(s,t,n,"",function(c){return c})):s!=null&&(Rc(s)&&(s=Nw(s,n+(!s.key||i&&i.key===s.key?"":(""+s.key).replace(Sf,"$&/")+"/")+e)),t.push(s)),1;if(i=0,r=r===""?".":r+":",wf(e))for(var a=0;a<e.length;a++){o=e[a];var l=r+nl(o,a);i+=di(o,t,n,l,s)}else if(l=Pw(e),typeof l=="function")for(e=l.call(e),a=0;!(o=e.next()).done;)o=o.value,l=r+nl(o,a++),i+=di(o,t,n,l,s);else if(o==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return i}function Oo(e,t,n){if(e==null)return e;var r=[],s=0;return di(e,r,"","",function(o){return t.call(n,o,s++)}),r}function Rw(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Ze={current:null},fi={transition:null},Mw={ReactCurrentDispatcher:Ze,ReactCurrentBatchConfig:fi,ReactCurrentOwner:jc};function Vm(){throw Error("act(...) is not supported in production builds of React.")}G.Children={map:Oo,forEach:function(e,t,n){Oo(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Oo(e,function(){t++}),t},toArray:function(e){return Oo(e,function(t){return t})||[]},only:function(e){if(!Rc(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};G.Component=ls;G.Fragment=vw;G.Profiler=ww;G.PureComponent=Pc;G.StrictMode=xw;G.Suspense=bw;G.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Mw;G.act=Vm;G.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Am({},e.props),s=e.key,o=e.ref,i=e._owner;if(t!=null){if(t.ref!==void 0&&(o=t.ref,i=jc.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(l in t)Om.call(t,l)&&!_m.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&a!==void 0?a[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){a=Array(l);for(var c=0;c<l;c++)a[c]=arguments[c+2];r.children=a}return{$$typeof:xo,type:e.type,key:s,ref:o,props:r,_owner:i}};G.createContext=function(e){return e={$$typeof:Ew,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Sw,_context:e},e.Consumer=e};G.createElement=Im;G.createFactory=function(e){var t=Im.bind(null,e);return t.type=e,t};G.createRef=function(){return{current:null}};G.forwardRef=function(e){return{$$typeof:kw,render:e}};G.isValidElement=Rc;G.lazy=function(e){return{$$typeof:Tw,_payload:{_status:-1,_result:e},_init:Rw}};G.memo=function(e,t){return{$$typeof:Cw,type:e,compare:t===void 0?null:t}};G.startTransition=function(e){var t=fi.transition;fi.transition={};try{e()}finally{fi.transition=t}};G.unstable_act=Vm;G.useCallback=function(e,t){return Ze.current.useCallback(e,t)};G.useContext=function(e){return Ze.current.useContext(e)};G.useDebugValue=function(){};G.useDeferredValue=function(e){return Ze.current.useDeferredValue(e)};G.useEffect=function(e,t){return Ze.current.useEffect(e,t)};G.useId=function(){return Ze.current.useId()};G.useImperativeHandle=function(e,t,n){return Ze.current.useImperativeHandle(e,t,n)};G.useInsertionEffect=function(e,t){return Ze.current.useInsertionEffect(e,t)};G.useLayoutEffect=function(e,t){return Ze.current.useLayoutEffect(e,t)};G.useMemo=function(e,t){return Ze.current.useMemo(e,t)};G.useReducer=function(e,t,n){return Ze.current.useReducer(e,t,n)};G.useRef=function(e){return Ze.current.useRef(e)};G.useState=function(e){return Ze.current.useState(e)};G.useSyncExternalStore=function(e,t,n){return Ze.current.useSyncExternalStore(e,t,n)};G.useTransition=function(){return Ze.current.useTransition()};G.version="18.3.1";Rm.exports=G;var p=Rm.exports;const R=Nm(p),va=gw({__proto__:null,default:R},[p]);/**
11
+ * @license React
12
+ * react-jsx-runtime.production.min.js
13
+ *
14
+ * Copyright (c) Facebook, Inc. and its affiliates.
15
+ *
16
+ * This source code is licensed under the MIT license found in the
17
+ * LICENSE file in the root directory of this source tree.
18
+ */var Aw=p,Dw=Symbol.for("react.element"),Lw=Symbol.for("react.fragment"),Ow=Object.prototype.hasOwnProperty,_w=Aw.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Iw={key:!0,ref:!0,__self:!0,__source:!0};function Fm(e,t,n){var r,s={},o=null,i=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(i=t.ref);for(r in t)Ow.call(t,r)&&!Iw.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)s[r]===void 0&&(s[r]=t[r]);return{$$typeof:Dw,type:e,key:o,ref:i,props:s,_owner:_w.current}}ya.Fragment=Lw;ya.jsx=Fm;ya.jsxs=Fm;jm.exports=ya;var h=jm.exports,nu={},zm={exports:{}},ft={},Bm={exports:{}},$m={};/**
19
+ * @license React
20
+ * scheduler.production.min.js
21
+ *
22
+ * Copyright (c) Facebook, Inc. and its affiliates.
23
+ *
24
+ * This source code is licensed under the MIT license found in the
25
+ * LICENSE file in the root directory of this source tree.
26
+ */(function(e){function t(j,O){var V=j.length;j.push(O);e:for(;0<V;){var $=V-1>>>1,se=j[$];if(0<s(se,O))j[$]=O,j[V]=se,V=$;else break e}}function n(j){return j.length===0?null:j[0]}function r(j){if(j.length===0)return null;var O=j[0],V=j.pop();if(V!==O){j[0]=V;e:for(var $=0,se=j.length,H=se>>>1;$<H;){var Z=2*($+1)-1,K=j[Z],pe=Z+1,Je=j[pe];if(0>s(K,V))pe<se&&0>s(Je,K)?(j[$]=Je,j[pe]=V,$=pe):(j[$]=K,j[Z]=V,$=Z);else if(pe<se&&0>s(Je,V))j[$]=Je,j[pe]=V,$=pe;else break e}}return O}function s(j,O){var V=j.sortIndex-O.sortIndex;return V!==0?V:j.id-O.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var i=Date,a=i.now();e.unstable_now=function(){return i.now()-a}}var l=[],c=[],d=1,u=null,f=3,y=!1,w=!1,x=!1,S=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(j){for(var O=n(c);O!==null;){if(O.callback===null)r(c);else if(O.startTime<=j)r(c),O.sortIndex=O.expirationTime,t(l,O);else break;O=n(c)}}function E(j){if(x=!1,v(j),!w)if(n(l)!==null)w=!0,z(C);else{var O=n(c);O!==null&&re(E,O.startTime-j)}}function C(j,O){w=!1,x&&(x=!1,m(b),b=-1),y=!0;var V=f;try{for(v(O),u=n(l);u!==null&&(!(u.expirationTime>O)||j&&!D());){var $=u.callback;if(typeof $=="function"){u.callback=null,f=u.priorityLevel;var se=$(u.expirationTime<=O);O=e.unstable_now(),typeof se=="function"?u.callback=se:u===n(l)&&r(l),v(O)}else r(l);u=n(l)}if(u!==null)var H=!0;else{var Z=n(c);Z!==null&&re(E,Z.startTime-O),H=!1}return H}finally{u=null,f=V,y=!1}}var T=!1,k=null,b=-1,A=5,P=-1;function D(){return!(e.unstable_now()-P<A)}function L(){if(k!==null){var j=e.unstable_now();P=j;var O=!0;try{O=k(!0,j)}finally{O?Q():(T=!1,k=null)}}else T=!1}var Q;if(typeof g=="function")Q=function(){g(L)};else if(typeof MessageChannel<"u"){var le=new MessageChannel,ge=le.port2;le.port1.onmessage=L,Q=function(){ge.postMessage(null)}}else Q=function(){S(L,0)};function z(j){k=j,T||(T=!0,Q())}function re(j,O){b=S(function(){j(e.unstable_now())},O)}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(j){j.callback=null},e.unstable_continueExecution=function(){w||y||(w=!0,z(C))},e.unstable_forceFrameRate=function(j){0>j||125<j?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):A=0<j?Math.floor(1e3/j):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(j){switch(f){case 1:case 2:case 3:var O=3;break;default:O=f}var V=f;f=O;try{return j()}finally{f=V}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(j,O){switch(j){case 1:case 2:case 3:case 4:case 5:break;default:j=3}var V=f;f=j;try{return O()}finally{f=V}},e.unstable_scheduleCallback=function(j,O,V){var $=e.unstable_now();switch(typeof V=="object"&&V!==null?(V=V.delay,V=typeof V=="number"&&0<V?$+V:$):V=$,j){case 1:var se=-1;break;case 2:se=250;break;case 5:se=1073741823;break;case 4:se=1e4;break;default:se=5e3}return se=V+se,j={id:d++,callback:O,priorityLevel:j,startTime:V,expirationTime:se,sortIndex:-1},V>$?(j.sortIndex=V,t(c,j),n(l)===null&&j===n(c)&&(x?(m(b),b=-1):x=!0,re(E,V-$))):(j.sortIndex=se,t(l,j),w||y||(w=!0,z(C))),j},e.unstable_shouldYield=D,e.unstable_wrapCallback=function(j){var O=f;return function(){var V=f;f=O;try{return j.apply(this,arguments)}finally{f=V}}}})($m);Bm.exports=$m;var Vw=Bm.exports;/**
27
+ * @license React
28
+ * react-dom.production.min.js
29
+ *
30
+ * Copyright (c) Facebook, Inc. and its affiliates.
31
+ *
32
+ * This source code is licensed under the MIT license found in the
33
+ * LICENSE file in the root directory of this source tree.
34
+ */var Fw=p,dt=Vw;function M(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;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."}var Um=new Set,Gs={};function Sr(e,t){Jr(e,t),Jr(e+"Capture",t)}function Jr(e,t){for(Gs[e]=t,e=0;e<t.length;e++)Um.add(t[e])}var rn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ru=Object.prototype.hasOwnProperty,zw=/^[: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]*$/,Ef={},kf={};function Bw(e){return ru.call(kf,e)?!0:ru.call(Ef,e)?!1:zw.test(e)?kf[e]=!0:(Ef[e]=!0,!1)}function $w(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Uw(e,t,n,r){if(t===null||typeof t>"u"||$w(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function qe(e,t,n,r,s,o,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=i}var Fe={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Fe[e]=new qe(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Fe[t]=new qe(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Fe[e]=new qe(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Fe[e]=new qe(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Fe[e]=new qe(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Fe[e]=new qe(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Fe[e]=new qe(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Fe[e]=new qe(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Fe[e]=new qe(e,5,!1,e.toLowerCase(),null,!1,!1)});var Mc=/[\-:]([a-z])/g;function Ac(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Mc,Ac);Fe[t]=new qe(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Mc,Ac);Fe[t]=new qe(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Mc,Ac);Fe[t]=new qe(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Fe[e]=new qe(e,1,!1,e.toLowerCase(),null,!1,!1)});Fe.xlinkHref=new qe("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Fe[e]=new qe(e,1,!1,e.toLowerCase(),null,!0,!0)});function Dc(e,t,n,r){var s=Fe.hasOwnProperty(t)?Fe[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Uw(t,n,s,r)&&(n=null),r||s===null?Bw(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):s.mustUseProperty?e[s.propertyName]=n===null?s.type===3?!1:"":n:(t=s.attributeName,r=s.attributeNamespace,n===null?e.removeAttribute(t):(s=s.type,n=s===3||s===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var ln=Fw.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,_o=Symbol.for("react.element"),jr=Symbol.for("react.portal"),Rr=Symbol.for("react.fragment"),Lc=Symbol.for("react.strict_mode"),su=Symbol.for("react.profiler"),Wm=Symbol.for("react.provider"),Hm=Symbol.for("react.context"),Oc=Symbol.for("react.forward_ref"),ou=Symbol.for("react.suspense"),iu=Symbol.for("react.suspense_list"),_c=Symbol.for("react.memo"),Sn=Symbol.for("react.lazy"),Gm=Symbol.for("react.offscreen"),bf=Symbol.iterator;function ys(e){return e===null||typeof e!="object"?null:(e=bf&&e[bf]||e["@@iterator"],typeof e=="function"?e:null)}var we=Object.assign,rl;function Ns(e){if(rl===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);rl=t&&t[1]||""}return`
35
+ `+rl+e}var sl=!1;function ol(e,t){if(!e||sl)return"";sl=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var s=c.stack.split(`
36
+ `),o=r.stack.split(`
37
+ `),i=s.length-1,a=o.length-1;1<=i&&0<=a&&s[i]!==o[a];)a--;for(;1<=i&&0<=a;i--,a--)if(s[i]!==o[a]){if(i!==1||a!==1)do if(i--,a--,0>a||s[i]!==o[a]){var l=`
38
+ `+s[i].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=i&&0<=a);break}}}finally{sl=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Ns(e):""}function Ww(e){switch(e.tag){case 5:return Ns(e.type);case 16:return Ns("Lazy");case 13:return Ns("Suspense");case 19:return Ns("SuspenseList");case 0:case 2:case 15:return e=ol(e.type,!1),e;case 11:return e=ol(e.type.render,!1),e;case 1:return e=ol(e.type,!0),e;default:return""}}function au(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Rr:return"Fragment";case jr:return"Portal";case su:return"Profiler";case Lc:return"StrictMode";case ou:return"Suspense";case iu:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Hm:return(e.displayName||"Context")+".Consumer";case Wm:return(e._context.displayName||"Context")+".Provider";case Oc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case _c:return t=e.displayName||null,t!==null?t:au(e.type)||"Memo";case Sn:t=e._payload,e=e._init;try{return au(e(t))}catch{}}return null}function Hw(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return au(t);case 8:return t===Lc?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function zn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Km(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Gw(e){var t=Km(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var s=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(i){r=""+i,o.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Io(e){e._valueTracker||(e._valueTracker=Gw(e))}function Ym(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Km(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Li(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function lu(e,t){var n=t.checked;return we({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Cf(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=zn(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Xm(e,t){t=t.checked,t!=null&&Dc(e,"checked",t,!1)}function uu(e,t){Xm(e,t);var n=zn(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?cu(e,t.type,n):t.hasOwnProperty("defaultValue")&&cu(e,t.type,zn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Tf(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function cu(e,t,n){(t!=="number"||Li(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var js=Array.isArray;function Wr(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s<n.length;s++)t["$"+n[s]]=!0;for(n=0;n<e.length;n++)s=t.hasOwnProperty("$"+e[n].value),e[n].selected!==s&&(e[n].selected=s),s&&r&&(e[n].defaultSelected=!0)}else{for(n=""+zn(n),t=null,s=0;s<e.length;s++){if(e[s].value===n){e[s].selected=!0,r&&(e[s].defaultSelected=!0);return}t!==null||e[s].disabled||(t=e[s])}t!==null&&(t.selected=!0)}}function du(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(M(91));return we({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Pf(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(M(92));if(js(n)){if(1<n.length)throw Error(M(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:zn(n)}}function Qm(e,t){var n=zn(t.value),r=zn(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function Nf(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Zm(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function fu(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Zm(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Vo,qm=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,s){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,s)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Vo=Vo||document.createElement("div"),Vo.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Vo.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Ks(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ds={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Kw=["Webkit","ms","Moz","O"];Object.keys(Ds).forEach(function(e){Kw.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ds[t]=Ds[e]})});function Jm(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ds.hasOwnProperty(e)&&Ds[e]?(""+t).trim():t+"px"}function eg(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=Jm(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var Yw=we({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function hu(e,t){if(t){if(Yw[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(M(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(M(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(M(61))}if(t.style!=null&&typeof t.style!="object")throw Error(M(62))}}function pu(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 mu=null;function Ic(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var gu=null,Hr=null,Gr=null;function jf(e){if(e=Eo(e)){if(typeof gu!="function")throw Error(M(280));var t=e.stateNode;t&&(t=ka(t),gu(e.stateNode,e.type,t))}}function tg(e){Hr?Gr?Gr.push(e):Gr=[e]:Hr=e}function ng(){if(Hr){var e=Hr,t=Gr;if(Gr=Hr=null,jf(e),t)for(e=0;e<t.length;e++)jf(t[e])}}function rg(e,t){return e(t)}function sg(){}var il=!1;function og(e,t,n){if(il)return e(t,n);il=!0;try{return rg(e,t,n)}finally{il=!1,(Hr!==null||Gr!==null)&&(sg(),ng())}}function Ys(e,t){var n=e.stateNode;if(n===null)return null;var r=ka(n);if(r===null)return null;n=r[t];e: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 e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(M(231,t,typeof n));return n}var yu=!1;if(rn)try{var vs={};Object.defineProperty(vs,"passive",{get:function(){yu=!0}}),window.addEventListener("test",vs,vs),window.removeEventListener("test",vs,vs)}catch{yu=!1}function Xw(e,t,n,r,s,o,i,a,l){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(d){this.onError(d)}}var Ls=!1,Oi=null,_i=!1,vu=null,Qw={onError:function(e){Ls=!0,Oi=e}};function Zw(e,t,n,r,s,o,i,a,l){Ls=!1,Oi=null,Xw.apply(Qw,arguments)}function qw(e,t,n,r,s,o,i,a,l){if(Zw.apply(this,arguments),Ls){if(Ls){var c=Oi;Ls=!1,Oi=null}else throw Error(M(198));_i||(_i=!0,vu=c)}}function Er(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 ig(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 Rf(e){if(Er(e)!==e)throw Error(M(188))}function Jw(e){var t=e.alternate;if(!t){if(t=Er(e),t===null)throw Error(M(188));return t!==e?null:e}for(var n=e,r=t;;){var s=n.return;if(s===null)break;var o=s.alternate;if(o===null){if(r=s.return,r!==null){n=r;continue}break}if(s.child===o.child){for(o=s.child;o;){if(o===n)return Rf(s),e;if(o===r)return Rf(s),t;o=o.sibling}throw Error(M(188))}if(n.return!==r.return)n=s,r=o;else{for(var i=!1,a=s.child;a;){if(a===n){i=!0,n=s,r=o;break}if(a===r){i=!0,r=s,n=o;break}a=a.sibling}if(!i){for(a=o.child;a;){if(a===n){i=!0,n=o,r=s;break}if(a===r){i=!0,r=o,n=s;break}a=a.sibling}if(!i)throw Error(M(189))}}if(n.alternate!==r)throw Error(M(190))}if(n.tag!==3)throw Error(M(188));return n.stateNode.current===n?e:t}function ag(e){return e=Jw(e),e!==null?lg(e):null}function lg(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=lg(e);if(t!==null)return t;e=e.sibling}return null}var ug=dt.unstable_scheduleCallback,Mf=dt.unstable_cancelCallback,e1=dt.unstable_shouldYield,t1=dt.unstable_requestPaint,ke=dt.unstable_now,n1=dt.unstable_getCurrentPriorityLevel,Vc=dt.unstable_ImmediatePriority,cg=dt.unstable_UserBlockingPriority,Ii=dt.unstable_NormalPriority,r1=dt.unstable_LowPriority,dg=dt.unstable_IdlePriority,xa=null,Ht=null;function s1(e){if(Ht&&typeof Ht.onCommitFiberRoot=="function")try{Ht.onCommitFiberRoot(xa,e,void 0,(e.current.flags&128)===128)}catch{}}var At=Math.clz32?Math.clz32:a1,o1=Math.log,i1=Math.LN2;function a1(e){return e>>>=0,e===0?32:31-(o1(e)/i1|0)|0}var Fo=64,zo=4194304;function Rs(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Vi(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,o=e.pingedLanes,i=n&268435455;if(i!==0){var a=i&~s;a!==0?r=Rs(a):(o&=i,o!==0&&(r=Rs(o)))}else i=n&~s,i!==0?r=Rs(i):o!==0&&(r=Rs(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,o=t&-t,s>=o||s===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-At(t),s=1<<n,r|=e[n],t&=~s;return r}function l1(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64: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:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function u1(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,o=e.pendingLanes;0<o;){var i=31-At(o),a=1<<i,l=s[i];l===-1?(!(a&n)||a&r)&&(s[i]=l1(a,t)):l<=t&&(e.expiredLanes|=a),o&=~a}}function xu(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function fg(){var e=Fo;return Fo<<=1,!(Fo&4194240)&&(Fo=64),e}function al(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function wo(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-At(t),e[t]=n}function c1(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var s=31-At(n),o=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~o}}function Fc(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-At(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var te=0;function hg(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var pg,zc,mg,gg,yg,wu=!1,Bo=[],Rn=null,Mn=null,An=null,Xs=new Map,Qs=new Map,kn=[],d1="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 submit".split(" ");function Af(e,t){switch(e){case"focusin":case"focusout":Rn=null;break;case"dragenter":case"dragleave":Mn=null;break;case"mouseover":case"mouseout":An=null;break;case"pointerover":case"pointerout":Xs.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Qs.delete(t.pointerId)}}function xs(e,t,n,r,s,o){return e===null||e.nativeEvent!==o?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:o,targetContainers:[s]},t!==null&&(t=Eo(t),t!==null&&zc(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function f1(e,t,n,r,s){switch(t){case"focusin":return Rn=xs(Rn,e,t,n,r,s),!0;case"dragenter":return Mn=xs(Mn,e,t,n,r,s),!0;case"mouseover":return An=xs(An,e,t,n,r,s),!0;case"pointerover":var o=s.pointerId;return Xs.set(o,xs(Xs.get(o)||null,e,t,n,r,s)),!0;case"gotpointercapture":return o=s.pointerId,Qs.set(o,xs(Qs.get(o)||null,e,t,n,r,s)),!0}return!1}function vg(e){var t=sr(e.target);if(t!==null){var n=Er(t);if(n!==null){if(t=n.tag,t===13){if(t=ig(n),t!==null){e.blockedOn=t,yg(e.priority,function(){mg(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 hi(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Su(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);mu=r,n.target.dispatchEvent(r),mu=null}else return t=Eo(n),t!==null&&zc(t),e.blockedOn=n,!1;t.shift()}return!0}function Df(e,t,n){hi(e)&&n.delete(t)}function h1(){wu=!1,Rn!==null&&hi(Rn)&&(Rn=null),Mn!==null&&hi(Mn)&&(Mn=null),An!==null&&hi(An)&&(An=null),Xs.forEach(Df),Qs.forEach(Df)}function ws(e,t){e.blockedOn===t&&(e.blockedOn=null,wu||(wu=!0,dt.unstable_scheduleCallback(dt.unstable_NormalPriority,h1)))}function Zs(e){function t(s){return ws(s,e)}if(0<Bo.length){ws(Bo[0],e);for(var n=1;n<Bo.length;n++){var r=Bo[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Rn!==null&&ws(Rn,e),Mn!==null&&ws(Mn,e),An!==null&&ws(An,e),Xs.forEach(t),Qs.forEach(t),n=0;n<kn.length;n++)r=kn[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<kn.length&&(n=kn[0],n.blockedOn===null);)vg(n),n.blockedOn===null&&kn.shift()}var Kr=ln.ReactCurrentBatchConfig,Fi=!0;function p1(e,t,n,r){var s=te,o=Kr.transition;Kr.transition=null;try{te=1,Bc(e,t,n,r)}finally{te=s,Kr.transition=o}}function m1(e,t,n,r){var s=te,o=Kr.transition;Kr.transition=null;try{te=4,Bc(e,t,n,r)}finally{te=s,Kr.transition=o}}function Bc(e,t,n,r){if(Fi){var s=Su(e,t,n,r);if(s===null)yl(e,t,r,zi,n),Af(e,r);else if(f1(s,e,t,n,r))r.stopPropagation();else if(Af(e,r),t&4&&-1<d1.indexOf(e)){for(;s!==null;){var o=Eo(s);if(o!==null&&pg(o),o=Su(e,t,n,r),o===null&&yl(e,t,r,zi,n),o===s)break;s=o}s!==null&&r.stopPropagation()}else yl(e,t,r,null,n)}}var zi=null;function Su(e,t,n,r){if(zi=null,e=Ic(r),e=sr(e),e!==null)if(t=Er(e),t===null)e=null;else if(n=t.tag,n===13){if(e=ig(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 zi=e,null}function xg(e){switch(e){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"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 1;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"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(n1()){case Vc:return 1;case cg:return 4;case Ii:case r1:return 16;case dg:return 536870912;default:return 16}default:return 16}}var Cn=null,$c=null,pi=null;function wg(){if(pi)return pi;var e,t=$c,n=t.length,r,s="value"in Cn?Cn.value:Cn.textContent,o=s.length;for(e=0;e<n&&t[e]===s[e];e++);var i=n-e;for(r=1;r<=i&&t[n-r]===s[o-r];r++);return pi=s.slice(e,1<r?1-r:void 0)}function mi(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 $o(){return!0}function Lf(){return!1}function ht(e){function t(n,r,s,o,i){this._reactName=n,this._targetInst=s,this.type=r,this.nativeEvent=o,this.target=i,this.currentTarget=null;for(var a in e)e.hasOwnProperty(a)&&(n=e[a],this[a]=n?n(o):o[a]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?$o:Lf,this.isPropagationStopped=Lf,this}return we(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=$o)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=$o)},persist:function(){},isPersistent:$o}),t}var us={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Uc=ht(us),So=we({},us,{view:0,detail:0}),g1=ht(So),ll,ul,Ss,wa=we({},So,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Wc,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!==Ss&&(Ss&&e.type==="mousemove"?(ll=e.screenX-Ss.screenX,ul=e.screenY-Ss.screenY):ul=ll=0,Ss=e),ll)},movementY:function(e){return"movementY"in e?e.movementY:ul}}),Of=ht(wa),y1=we({},wa,{dataTransfer:0}),v1=ht(y1),x1=we({},So,{relatedTarget:0}),cl=ht(x1),w1=we({},us,{animationName:0,elapsedTime:0,pseudoElement:0}),S1=ht(w1),E1=we({},us,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),k1=ht(E1),b1=we({},us,{data:0}),_f=ht(b1),C1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},T1={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"},P1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function N1(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=P1[e])?!!t[e]:!1}function Wc(){return N1}var j1=we({},So,{key:function(e){if(e.key){var t=C1[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=mi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?T1[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Wc,charCode:function(e){return e.type==="keypress"?mi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?mi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),R1=ht(j1),M1=we({},wa,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),If=ht(M1),A1=we({},So,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Wc}),D1=ht(A1),L1=we({},us,{propertyName:0,elapsedTime:0,pseudoElement:0}),O1=ht(L1),_1=we({},wa,{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}),I1=ht(_1),V1=[9,13,27,32],Hc=rn&&"CompositionEvent"in window,Os=null;rn&&"documentMode"in document&&(Os=document.documentMode);var F1=rn&&"TextEvent"in window&&!Os,Sg=rn&&(!Hc||Os&&8<Os&&11>=Os),Vf=" ",Ff=!1;function Eg(e,t){switch(e){case"keyup":return V1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function kg(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Mr=!1;function z1(e,t){switch(e){case"compositionend":return kg(t);case"keypress":return t.which!==32?null:(Ff=!0,Vf);case"textInput":return e=t.data,e===Vf&&Ff?null:e;default:return null}}function B1(e,t){if(Mr)return e==="compositionend"||!Hc&&Eg(e,t)?(e=wg(),pi=$c=Cn=null,Mr=!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 Sg&&t.locale!=="ko"?null:t.data;default:return null}}var $1={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 zf(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!$1[e.type]:t==="textarea"}function bg(e,t,n,r){tg(r),t=Bi(t,"onChange"),0<t.length&&(n=new Uc("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var _s=null,qs=null;function U1(e){Og(e,0)}function Sa(e){var t=Lr(e);if(Ym(t))return e}function W1(e,t){if(e==="change")return t}var Cg=!1;if(rn){var dl;if(rn){var fl="oninput"in document;if(!fl){var Bf=document.createElement("div");Bf.setAttribute("oninput","return;"),fl=typeof Bf.oninput=="function"}dl=fl}else dl=!1;Cg=dl&&(!document.documentMode||9<document.documentMode)}function $f(){_s&&(_s.detachEvent("onpropertychange",Tg),qs=_s=null)}function Tg(e){if(e.propertyName==="value"&&Sa(qs)){var t=[];bg(t,qs,e,Ic(e)),og(U1,t)}}function H1(e,t,n){e==="focusin"?($f(),_s=t,qs=n,_s.attachEvent("onpropertychange",Tg)):e==="focusout"&&$f()}function G1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Sa(qs)}function K1(e,t){if(e==="click")return Sa(t)}function Y1(e,t){if(e==="input"||e==="change")return Sa(t)}function X1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Ot=typeof Object.is=="function"?Object.is:X1;function Js(e,t){if(Ot(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)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 s=n[r];if(!ru.call(t,s)||!Ot(e[s],t[s]))return!1}return!0}function Uf(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Wf(e,t){var n=Uf(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}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Uf(n)}}function Pg(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Pg(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ng(){for(var e=window,t=Li();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Li(e.document)}return t}function Gc(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")}function Q1(e){var t=Ng(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Pg(n.ownerDocument.documentElement,n)){if(r!==null&&Gc(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var s=n.textContent.length,o=Math.min(r.start,s);r=r.end===void 0?o:Math.min(r.end,s),!e.extend&&o>r&&(s=r,r=o,o=s),s=Wf(n,o);var i=Wf(n,r);s&&i&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Z1=rn&&"documentMode"in document&&11>=document.documentMode,Ar=null,Eu=null,Is=null,ku=!1;function Hf(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;ku||Ar==null||Ar!==Li(r)||(r=Ar,"selectionStart"in r&&Gc(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}),Is&&Js(Is,r)||(Is=r,r=Bi(Eu,"onSelect"),0<r.length&&(t=new Uc("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Ar)))}function Uo(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Dr={animationend:Uo("Animation","AnimationEnd"),animationiteration:Uo("Animation","AnimationIteration"),animationstart:Uo("Animation","AnimationStart"),transitionend:Uo("Transition","TransitionEnd")},hl={},jg={};rn&&(jg=document.createElement("div").style,"AnimationEvent"in window||(delete Dr.animationend.animation,delete Dr.animationiteration.animation,delete Dr.animationstart.animation),"TransitionEvent"in window||delete Dr.transitionend.transition);function Ea(e){if(hl[e])return hl[e];if(!Dr[e])return e;var t=Dr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in jg)return hl[e]=t[n];return e}var Rg=Ea("animationend"),Mg=Ea("animationiteration"),Ag=Ea("animationstart"),Dg=Ea("transitionend"),Lg=new Map,Gf="abort auxClick 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(" ");function Wn(e,t){Lg.set(e,t),Sr(t,[e])}for(var pl=0;pl<Gf.length;pl++){var ml=Gf[pl],q1=ml.toLowerCase(),J1=ml[0].toUpperCase()+ml.slice(1);Wn(q1,"on"+J1)}Wn(Rg,"onAnimationEnd");Wn(Mg,"onAnimationIteration");Wn(Ag,"onAnimationStart");Wn("dblclick","onDoubleClick");Wn("focusin","onFocus");Wn("focusout","onBlur");Wn(Dg,"onTransitionEnd");Jr("onMouseEnter",["mouseout","mouseover"]);Jr("onMouseLeave",["mouseout","mouseover"]);Jr("onPointerEnter",["pointerout","pointerover"]);Jr("onPointerLeave",["pointerout","pointerover"]);Sr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Sr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Sr("onBeforeInput",["compositionend","keypress","textInput","paste"]);Sr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Sr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Sr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ms="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(" "),eS=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ms));function Kf(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,qw(r,t,void 0,e),e.currentTarget=null}function Og(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],s=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var i=r.length-1;0<=i;i--){var a=r[i],l=a.instance,c=a.currentTarget;if(a=a.listener,l!==o&&s.isPropagationStopped())break e;Kf(s,a,c),o=l}else for(i=0;i<r.length;i++){if(a=r[i],l=a.instance,c=a.currentTarget,a=a.listener,l!==o&&s.isPropagationStopped())break e;Kf(s,a,c),o=l}}}if(_i)throw e=vu,_i=!1,vu=null,e}function de(e,t){var n=t[Nu];n===void 0&&(n=t[Nu]=new Set);var r=e+"__bubble";n.has(r)||(_g(t,e,2,!1),n.add(r))}function gl(e,t,n){var r=0;t&&(r|=4),_g(n,e,r,t)}var Wo="_reactListening"+Math.random().toString(36).slice(2);function eo(e){if(!e[Wo]){e[Wo]=!0,Um.forEach(function(n){n!=="selectionchange"&&(eS.has(n)||gl(n,!1,e),gl(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Wo]||(t[Wo]=!0,gl("selectionchange",!1,t))}}function _g(e,t,n,r){switch(xg(t)){case 1:var s=p1;break;case 4:s=m1;break;default:s=Bc}n=s.bind(null,t,n,e),s=void 0,!yu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}function yl(e,t,n,r,s){var o=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var i=r.tag;if(i===3||i===4){var a=r.stateNode.containerInfo;if(a===s||a.nodeType===8&&a.parentNode===s)break;if(i===4)for(i=r.return;i!==null;){var l=i.tag;if((l===3||l===4)&&(l=i.stateNode.containerInfo,l===s||l.nodeType===8&&l.parentNode===s))return;i=i.return}for(;a!==null;){if(i=sr(a),i===null)return;if(l=i.tag,l===5||l===6){r=o=i;continue e}a=a.parentNode}}r=r.return}og(function(){var c=o,d=Ic(n),u=[];e:{var f=Lg.get(e);if(f!==void 0){var y=Uc,w=e;switch(e){case"keypress":if(mi(n)===0)break e;case"keydown":case"keyup":y=R1;break;case"focusin":w="focus",y=cl;break;case"focusout":w="blur",y=cl;break;case"beforeblur":case"afterblur":y=cl;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":y=Of;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":y=v1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":y=D1;break;case Rg:case Mg:case Ag:y=S1;break;case Dg:y=O1;break;case"scroll":y=g1;break;case"wheel":y=I1;break;case"copy":case"cut":case"paste":y=k1;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":y=If}var x=(t&4)!==0,S=!x&&e==="scroll",m=x?f!==null?f+"Capture":null:f;x=[];for(var g=c,v;g!==null;){v=g;var E=v.stateNode;if(v.tag===5&&E!==null&&(v=E,m!==null&&(E=Ys(g,m),E!=null&&x.push(to(g,E,v)))),S)break;g=g.return}0<x.length&&(f=new y(f,w,null,n,d),u.push({event:f,listeners:x}))}}if(!(t&7)){e:{if(f=e==="mouseover"||e==="pointerover",y=e==="mouseout"||e==="pointerout",f&&n!==mu&&(w=n.relatedTarget||n.fromElement)&&(sr(w)||w[sn]))break e;if((y||f)&&(f=d.window===d?d:(f=d.ownerDocument)?f.defaultView||f.parentWindow:window,y?(w=n.relatedTarget||n.toElement,y=c,w=w?sr(w):null,w!==null&&(S=Er(w),w!==S||w.tag!==5&&w.tag!==6)&&(w=null)):(y=null,w=c),y!==w)){if(x=Of,E="onMouseLeave",m="onMouseEnter",g="mouse",(e==="pointerout"||e==="pointerover")&&(x=If,E="onPointerLeave",m="onPointerEnter",g="pointer"),S=y==null?f:Lr(y),v=w==null?f:Lr(w),f=new x(E,g+"leave",y,n,d),f.target=S,f.relatedTarget=v,E=null,sr(d)===c&&(x=new x(m,g+"enter",w,n,d),x.target=v,x.relatedTarget=S,E=x),S=E,y&&w)t:{for(x=y,m=w,g=0,v=x;v;v=br(v))g++;for(v=0,E=m;E;E=br(E))v++;for(;0<g-v;)x=br(x),g--;for(;0<v-g;)m=br(m),v--;for(;g--;){if(x===m||m!==null&&x===m.alternate)break t;x=br(x),m=br(m)}x=null}else x=null;y!==null&&Yf(u,f,y,x,!1),w!==null&&S!==null&&Yf(u,S,w,x,!0)}}e:{if(f=c?Lr(c):window,y=f.nodeName&&f.nodeName.toLowerCase(),y==="select"||y==="input"&&f.type==="file")var C=W1;else if(zf(f))if(Cg)C=Y1;else{C=G1;var T=H1}else(y=f.nodeName)&&y.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(C=K1);if(C&&(C=C(e,c))){bg(u,C,n,d);break e}T&&T(e,f,c),e==="focusout"&&(T=f._wrapperState)&&T.controlled&&f.type==="number"&&cu(f,"number",f.value)}switch(T=c?Lr(c):window,e){case"focusin":(zf(T)||T.contentEditable==="true")&&(Ar=T,Eu=c,Is=null);break;case"focusout":Is=Eu=Ar=null;break;case"mousedown":ku=!0;break;case"contextmenu":case"mouseup":case"dragend":ku=!1,Hf(u,n,d);break;case"selectionchange":if(Z1)break;case"keydown":case"keyup":Hf(u,n,d)}var k;if(Hc)e:{switch(e){case"compositionstart":var b="onCompositionStart";break e;case"compositionend":b="onCompositionEnd";break e;case"compositionupdate":b="onCompositionUpdate";break e}b=void 0}else Mr?Eg(e,n)&&(b="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(b="onCompositionStart");b&&(Sg&&n.locale!=="ko"&&(Mr||b!=="onCompositionStart"?b==="onCompositionEnd"&&Mr&&(k=wg()):(Cn=d,$c="value"in Cn?Cn.value:Cn.textContent,Mr=!0)),T=Bi(c,b),0<T.length&&(b=new _f(b,e,null,n,d),u.push({event:b,listeners:T}),k?b.data=k:(k=kg(n),k!==null&&(b.data=k)))),(k=F1?z1(e,n):B1(e,n))&&(c=Bi(c,"onBeforeInput"),0<c.length&&(d=new _f("onBeforeInput","beforeinput",null,n,d),u.push({event:d,listeners:c}),d.data=k))}Og(u,t)})}function to(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Bi(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,o=s.stateNode;s.tag===5&&o!==null&&(s=o,o=Ys(e,n),o!=null&&r.unshift(to(e,o,s)),o=Ys(e,t),o!=null&&r.push(to(e,o,s))),e=e.return}return r}function br(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Yf(e,t,n,r,s){for(var o=t._reactName,i=[];n!==null&&n!==r;){var a=n,l=a.alternate,c=a.stateNode;if(l!==null&&l===r)break;a.tag===5&&c!==null&&(a=c,s?(l=Ys(n,o),l!=null&&i.unshift(to(n,l,a))):s||(l=Ys(n,o),l!=null&&i.push(to(n,l,a)))),n=n.return}i.length!==0&&e.push({event:t,listeners:i})}var tS=/\r\n?/g,nS=/\u0000|\uFFFD/g;function Xf(e){return(typeof e=="string"?e:""+e).replace(tS,`
39
+ `).replace(nS,"")}function Ho(e,t,n){if(t=Xf(t),Xf(e)!==t&&n)throw Error(M(425))}function $i(){}var bu=null,Cu=null;function Tu(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Pu=typeof setTimeout=="function"?setTimeout:void 0,rS=typeof clearTimeout=="function"?clearTimeout:void 0,Qf=typeof Promise=="function"?Promise:void 0,sS=typeof queueMicrotask=="function"?queueMicrotask:typeof Qf<"u"?function(e){return Qf.resolve(null).then(e).catch(oS)}:Pu;function oS(e){setTimeout(function(){throw e})}function vl(e,t){var n=t,r=0;do{var s=n.nextSibling;if(e.removeChild(n),s&&s.nodeType===8)if(n=s.data,n==="/$"){if(r===0){e.removeChild(s),Zs(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);Zs(t)}function Dn(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==="$?")break;if(t==="/$")return null}}return e}function Zf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var cs=Math.random().toString(36).slice(2),Ut="__reactFiber$"+cs,no="__reactProps$"+cs,sn="__reactContainer$"+cs,Nu="__reactEvents$"+cs,iS="__reactListeners$"+cs,aS="__reactHandles$"+cs;function sr(e){var t=e[Ut];if(t)return t;for(var n=e.parentNode;n;){if(t=n[sn]||n[Ut]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Zf(e);e!==null;){if(n=e[Ut])return n;e=Zf(e)}return t}e=n,n=e.parentNode}return null}function Eo(e){return e=e[Ut]||e[sn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Lr(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(M(33))}function ka(e){return e[no]||null}var ju=[],Or=-1;function Hn(e){return{current:e}}function he(e){0>Or||(e.current=ju[Or],ju[Or]=null,Or--)}function ae(e,t){Or++,ju[Or]=e.current,e.current=t}var Bn={},He=Hn(Bn),rt=Hn(!1),pr=Bn;function es(e,t){var n=e.type.contextTypes;if(!n)return Bn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},o;for(o in n)s[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function st(e){return e=e.childContextTypes,e!=null}function Ui(){he(rt),he(He)}function qf(e,t,n){if(He.current!==Bn)throw Error(M(168));ae(He,t),ae(rt,n)}function Ig(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(M(108,Hw(e)||"Unknown",s));return we({},n,r)}function Wi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Bn,pr=He.current,ae(He,e),ae(rt,rt.current),!0}function Jf(e,t,n){var r=e.stateNode;if(!r)throw Error(M(169));n?(e=Ig(e,t,pr),r.__reactInternalMemoizedMergedChildContext=e,he(rt),he(He),ae(He,e)):he(rt),ae(rt,n)}var Jt=null,ba=!1,xl=!1;function Vg(e){Jt===null?Jt=[e]:Jt.push(e)}function lS(e){ba=!0,Vg(e)}function Gn(){if(!xl&&Jt!==null){xl=!0;var e=0,t=te;try{var n=Jt;for(te=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}Jt=null,ba=!1}catch(s){throw Jt!==null&&(Jt=Jt.slice(e+1)),ug(Vc,Gn),s}finally{te=t,xl=!1}}return null}var _r=[],Ir=0,Hi=null,Gi=0,mt=[],gt=0,mr=null,en=1,tn="";function er(e,t){_r[Ir++]=Gi,_r[Ir++]=Hi,Hi=e,Gi=t}function Fg(e,t,n){mt[gt++]=en,mt[gt++]=tn,mt[gt++]=mr,mr=e;var r=en;e=tn;var s=32-At(r)-1;r&=~(1<<s),n+=1;var o=32-At(t)+s;if(30<o){var i=s-s%5;o=(r&(1<<i)-1).toString(32),r>>=i,s-=i,en=1<<32-At(t)+s|n<<s|r,tn=o+e}else en=1<<o|n<<s|r,tn=e}function Kc(e){e.return!==null&&(er(e,1),Fg(e,1,0))}function Yc(e){for(;e===Hi;)Hi=_r[--Ir],_r[Ir]=null,Gi=_r[--Ir],_r[Ir]=null;for(;e===mr;)mr=mt[--gt],mt[gt]=null,tn=mt[--gt],mt[gt]=null,en=mt[--gt],mt[gt]=null}var ut=null,lt=null,me=!1,Mt=null;function zg(e,t){var n=yt(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function eh(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,ut=e,lt=Dn(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,ut=e,lt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=mr!==null?{id:en,overflow:tn}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=yt(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,ut=e,lt=null,!0):!1;default:return!1}}function Ru(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Mu(e){if(me){var t=lt;if(t){var n=t;if(!eh(e,t)){if(Ru(e))throw Error(M(418));t=Dn(n.nextSibling);var r=ut;t&&eh(e,t)?zg(r,n):(e.flags=e.flags&-4097|2,me=!1,ut=e)}}else{if(Ru(e))throw Error(M(418));e.flags=e.flags&-4097|2,me=!1,ut=e}}}function th(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;ut=e}function Go(e){if(e!==ut)return!1;if(!me)return th(e),me=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Tu(e.type,e.memoizedProps)),t&&(t=lt)){if(Ru(e))throw Bg(),Error(M(418));for(;t;)zg(e,t),t=Dn(t.nextSibling)}if(th(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(M(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){lt=Dn(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}lt=null}}else lt=ut?Dn(e.stateNode.nextSibling):null;return!0}function Bg(){for(var e=lt;e;)e=Dn(e.nextSibling)}function ts(){lt=ut=null,me=!1}function Xc(e){Mt===null?Mt=[e]:Mt.push(e)}var uS=ln.ReactCurrentBatchConfig;function Es(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(M(309));var r=n.stateNode}if(!r)throw Error(M(147,e));var s=r,o=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===o?t.ref:(t=function(i){var a=s.refs;i===null?delete a[o]:a[o]=i},t._stringRef=o,t)}if(typeof e!="string")throw Error(M(284));if(!n._owner)throw Error(M(290,e))}return e}function Ko(e,t){throw e=Object.prototype.toString.call(t),Error(M(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function nh(e){var t=e._init;return t(e._payload)}function $g(e){function t(m,g){if(e){var v=m.deletions;v===null?(m.deletions=[g],m.flags|=16):v.push(g)}}function n(m,g){if(!e)return null;for(;g!==null;)t(m,g),g=g.sibling;return null}function r(m,g){for(m=new Map;g!==null;)g.key!==null?m.set(g.key,g):m.set(g.index,g),g=g.sibling;return m}function s(m,g){return m=In(m,g),m.index=0,m.sibling=null,m}function o(m,g,v){return m.index=v,e?(v=m.alternate,v!==null?(v=v.index,v<g?(m.flags|=2,g):v):(m.flags|=2,g)):(m.flags|=1048576,g)}function i(m){return e&&m.alternate===null&&(m.flags|=2),m}function a(m,g,v,E){return g===null||g.tag!==6?(g=Tl(v,m.mode,E),g.return=m,g):(g=s(g,v),g.return=m,g)}function l(m,g,v,E){var C=v.type;return C===Rr?d(m,g,v.props.children,E,v.key):g!==null&&(g.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Sn&&nh(C)===g.type)?(E=s(g,v.props),E.ref=Es(m,g,v),E.return=m,E):(E=Ei(v.type,v.key,v.props,null,m.mode,E),E.ref=Es(m,g,v),E.return=m,E)}function c(m,g,v,E){return g===null||g.tag!==4||g.stateNode.containerInfo!==v.containerInfo||g.stateNode.implementation!==v.implementation?(g=Pl(v,m.mode,E),g.return=m,g):(g=s(g,v.children||[]),g.return=m,g)}function d(m,g,v,E,C){return g===null||g.tag!==7?(g=cr(v,m.mode,E,C),g.return=m,g):(g=s(g,v),g.return=m,g)}function u(m,g,v){if(typeof g=="string"&&g!==""||typeof g=="number")return g=Tl(""+g,m.mode,v),g.return=m,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case _o:return v=Ei(g.type,g.key,g.props,null,m.mode,v),v.ref=Es(m,null,g),v.return=m,v;case jr:return g=Pl(g,m.mode,v),g.return=m,g;case Sn:var E=g._init;return u(m,E(g._payload),v)}if(js(g)||ys(g))return g=cr(g,m.mode,v,null),g.return=m,g;Ko(m,g)}return null}function f(m,g,v,E){var C=g!==null?g.key:null;if(typeof v=="string"&&v!==""||typeof v=="number")return C!==null?null:a(m,g,""+v,E);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case _o:return v.key===C?l(m,g,v,E):null;case jr:return v.key===C?c(m,g,v,E):null;case Sn:return C=v._init,f(m,g,C(v._payload),E)}if(js(v)||ys(v))return C!==null?null:d(m,g,v,E,null);Ko(m,v)}return null}function y(m,g,v,E,C){if(typeof E=="string"&&E!==""||typeof E=="number")return m=m.get(v)||null,a(g,m,""+E,C);if(typeof E=="object"&&E!==null){switch(E.$$typeof){case _o:return m=m.get(E.key===null?v:E.key)||null,l(g,m,E,C);case jr:return m=m.get(E.key===null?v:E.key)||null,c(g,m,E,C);case Sn:var T=E._init;return y(m,g,v,T(E._payload),C)}if(js(E)||ys(E))return m=m.get(v)||null,d(g,m,E,C,null);Ko(g,E)}return null}function w(m,g,v,E){for(var C=null,T=null,k=g,b=g=0,A=null;k!==null&&b<v.length;b++){k.index>b?(A=k,k=null):A=k.sibling;var P=f(m,k,v[b],E);if(P===null){k===null&&(k=A);break}e&&k&&P.alternate===null&&t(m,k),g=o(P,g,b),T===null?C=P:T.sibling=P,T=P,k=A}if(b===v.length)return n(m,k),me&&er(m,b),C;if(k===null){for(;b<v.length;b++)k=u(m,v[b],E),k!==null&&(g=o(k,g,b),T===null?C=k:T.sibling=k,T=k);return me&&er(m,b),C}for(k=r(m,k);b<v.length;b++)A=y(k,m,b,v[b],E),A!==null&&(e&&A.alternate!==null&&k.delete(A.key===null?b:A.key),g=o(A,g,b),T===null?C=A:T.sibling=A,T=A);return e&&k.forEach(function(D){return t(m,D)}),me&&er(m,b),C}function x(m,g,v,E){var C=ys(v);if(typeof C!="function")throw Error(M(150));if(v=C.call(v),v==null)throw Error(M(151));for(var T=C=null,k=g,b=g=0,A=null,P=v.next();k!==null&&!P.done;b++,P=v.next()){k.index>b?(A=k,k=null):A=k.sibling;var D=f(m,k,P.value,E);if(D===null){k===null&&(k=A);break}e&&k&&D.alternate===null&&t(m,k),g=o(D,g,b),T===null?C=D:T.sibling=D,T=D,k=A}if(P.done)return n(m,k),me&&er(m,b),C;if(k===null){for(;!P.done;b++,P=v.next())P=u(m,P.value,E),P!==null&&(g=o(P,g,b),T===null?C=P:T.sibling=P,T=P);return me&&er(m,b),C}for(k=r(m,k);!P.done;b++,P=v.next())P=y(k,m,b,P.value,E),P!==null&&(e&&P.alternate!==null&&k.delete(P.key===null?b:P.key),g=o(P,g,b),T===null?C=P:T.sibling=P,T=P);return e&&k.forEach(function(L){return t(m,L)}),me&&er(m,b),C}function S(m,g,v,E){if(typeof v=="object"&&v!==null&&v.type===Rr&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case _o:e:{for(var C=v.key,T=g;T!==null;){if(T.key===C){if(C=v.type,C===Rr){if(T.tag===7){n(m,T.sibling),g=s(T,v.props.children),g.return=m,m=g;break e}}else if(T.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Sn&&nh(C)===T.type){n(m,T.sibling),g=s(T,v.props),g.ref=Es(m,T,v),g.return=m,m=g;break e}n(m,T);break}else t(m,T);T=T.sibling}v.type===Rr?(g=cr(v.props.children,m.mode,E,v.key),g.return=m,m=g):(E=Ei(v.type,v.key,v.props,null,m.mode,E),E.ref=Es(m,g,v),E.return=m,m=E)}return i(m);case jr:e:{for(T=v.key;g!==null;){if(g.key===T)if(g.tag===4&&g.stateNode.containerInfo===v.containerInfo&&g.stateNode.implementation===v.implementation){n(m,g.sibling),g=s(g,v.children||[]),g.return=m,m=g;break e}else{n(m,g);break}else t(m,g);g=g.sibling}g=Pl(v,m.mode,E),g.return=m,m=g}return i(m);case Sn:return T=v._init,S(m,g,T(v._payload),E)}if(js(v))return w(m,g,v,E);if(ys(v))return x(m,g,v,E);Ko(m,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,g!==null&&g.tag===6?(n(m,g.sibling),g=s(g,v),g.return=m,m=g):(n(m,g),g=Tl(v,m.mode,E),g.return=m,m=g),i(m)):n(m,g)}return S}var ns=$g(!0),Ug=$g(!1),Ki=Hn(null),Yi=null,Vr=null,Qc=null;function Zc(){Qc=Vr=Yi=null}function qc(e){var t=Ki.current;he(Ki),e._currentValue=t}function Au(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Yr(e,t){Yi=e,Qc=Vr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(nt=!0),e.firstContext=null)}function St(e){var t=e._currentValue;if(Qc!==e)if(e={context:e,memoizedValue:t,next:null},Vr===null){if(Yi===null)throw Error(M(308));Vr=e,Yi.dependencies={lanes:0,firstContext:e}}else Vr=Vr.next=e;return t}var or=null;function Jc(e){or===null?or=[e]:or.push(e)}function Wg(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Jc(t)):(n.next=s.next,s.next=n),t.interleaved=n,on(e,r)}function on(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var En=!1;function ed(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Hg(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function nn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Ln(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,X&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,on(e,n)}return s=r.interleaved,s===null?(t.next=t,Jc(r)):(t.next=s.next,s.next=t),r.interleaved=t,on(e,n)}function gi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Fc(e,n)}}function rh(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?s=o=i:o=o.next=i,n=n.next}while(n!==null);o===null?s=o=t:o=o.next=t}else s=o=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:o,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Xi(e,t,n,r){var s=e.updateQueue;En=!1;var o=s.firstBaseUpdate,i=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var l=a,c=l.next;l.next=null,i===null?o=c:i.next=c,i=l;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==i&&(a===null?d.firstBaseUpdate=c:a.next=c,d.lastBaseUpdate=l))}if(o!==null){var u=s.baseState;i=0,d=c=l=null,a=o;do{var f=a.lane,y=a.eventTime;if((r&f)===f){d!==null&&(d=d.next={eventTime:y,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var w=e,x=a;switch(f=t,y=n,x.tag){case 1:if(w=x.payload,typeof w=="function"){u=w.call(y,u,f);break e}u=w;break e;case 3:w.flags=w.flags&-65537|128;case 0:if(w=x.payload,f=typeof w=="function"?w.call(y,u,f):w,f==null)break e;u=we({},u,f);break e;case 2:En=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,f=s.effects,f===null?s.effects=[a]:f.push(a))}else y={eventTime:y,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(c=d=y,l=u):d=d.next=y,i|=f;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;f=a,a=f.next,f.next=null,s.lastBaseUpdate=f,s.shared.pending=null}}while(!0);if(d===null&&(l=u),s.baseState=l,s.firstBaseUpdate=c,s.lastBaseUpdate=d,t=s.shared.interleaved,t!==null){s=t;do i|=s.lane,s=s.next;while(s!==t)}else o===null&&(s.shared.lanes=0);yr|=i,e.lanes=i,e.memoizedState=u}}function sh(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],s=r.callback;if(s!==null){if(r.callback=null,r=n,typeof s!="function")throw Error(M(191,s));s.call(r)}}}var ko={},Gt=Hn(ko),ro=Hn(ko),so=Hn(ko);function ir(e){if(e===ko)throw Error(M(174));return e}function td(e,t){switch(ae(so,t),ae(ro,e),ae(Gt,ko),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:fu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=fu(t,e)}he(Gt),ae(Gt,t)}function rs(){he(Gt),he(ro),he(so)}function Gg(e){ir(so.current);var t=ir(Gt.current),n=fu(t,e.type);t!==n&&(ae(ro,e),ae(Gt,n))}function nd(e){ro.current===e&&(he(Gt),he(ro))}var ve=Hn(0);function Qi(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){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 wl=[];function rd(){for(var e=0;e<wl.length;e++)wl[e]._workInProgressVersionPrimary=null;wl.length=0}var yi=ln.ReactCurrentDispatcher,Sl=ln.ReactCurrentBatchConfig,gr=0,xe=null,je=null,Ae=null,Zi=!1,Vs=!1,oo=0,cS=0;function $e(){throw Error(M(321))}function sd(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Ot(e[n],t[n]))return!1;return!0}function od(e,t,n,r,s,o){if(gr=o,xe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,yi.current=e===null||e.memoizedState===null?pS:mS,e=n(r,s),Vs){o=0;do{if(Vs=!1,oo=0,25<=o)throw Error(M(301));o+=1,Ae=je=null,t.updateQueue=null,yi.current=gS,e=n(r,s)}while(Vs)}if(yi.current=qi,t=je!==null&&je.next!==null,gr=0,Ae=je=xe=null,Zi=!1,t)throw Error(M(300));return e}function id(){var e=oo!==0;return oo=0,e}function zt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ae===null?xe.memoizedState=Ae=e:Ae=Ae.next=e,Ae}function Et(){if(je===null){var e=xe.alternate;e=e!==null?e.memoizedState:null}else e=je.next;var t=Ae===null?xe.memoizedState:Ae.next;if(t!==null)Ae=t,je=e;else{if(e===null)throw Error(M(310));je=e,e={memoizedState:je.memoizedState,baseState:je.baseState,baseQueue:je.baseQueue,queue:je.queue,next:null},Ae===null?xe.memoizedState=Ae=e:Ae=Ae.next=e}return Ae}function io(e,t){return typeof t=="function"?t(e):t}function El(e){var t=Et(),n=t.queue;if(n===null)throw Error(M(311));n.lastRenderedReducer=e;var r=je,s=r.baseQueue,o=n.pending;if(o!==null){if(s!==null){var i=s.next;s.next=o.next,o.next=i}r.baseQueue=s=o,n.pending=null}if(s!==null){o=s.next,r=r.baseState;var a=i=null,l=null,c=o;do{var d=c.lane;if((gr&d)===d)l!==null&&(l=l.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var u={lane:d,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};l===null?(a=l=u,i=r):l=l.next=u,xe.lanes|=d,yr|=d}c=c.next}while(c!==null&&c!==o);l===null?i=r:l.next=a,Ot(r,t.memoizedState)||(nt=!0),t.memoizedState=r,t.baseState=i,t.baseQueue=l,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do o=s.lane,xe.lanes|=o,yr|=o,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function kl(e){var t=Et(),n=t.queue;if(n===null)throw Error(M(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,o=t.memoizedState;if(s!==null){n.pending=null;var i=s=s.next;do o=e(o,i.action),i=i.next;while(i!==s);Ot(o,t.memoizedState)||(nt=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Kg(){}function Yg(e,t){var n=xe,r=Et(),s=t(),o=!Ot(r.memoizedState,s);if(o&&(r.memoizedState=s,nt=!0),r=r.queue,ad(Zg.bind(null,n,r,e),[e]),r.getSnapshot!==t||o||Ae!==null&&Ae.memoizedState.tag&1){if(n.flags|=2048,ao(9,Qg.bind(null,n,r,s,t),void 0,null),De===null)throw Error(M(349));gr&30||Xg(n,t,s)}return s}function Xg(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=xe.updateQueue,t===null?(t={lastEffect:null,stores:null},xe.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Qg(e,t,n,r){t.value=n,t.getSnapshot=r,qg(t)&&Jg(e)}function Zg(e,t,n){return n(function(){qg(t)&&Jg(e)})}function qg(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Ot(e,n)}catch{return!0}}function Jg(e){var t=on(e,1);t!==null&&Dt(t,e,1,-1)}function oh(e){var t=zt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:io,lastRenderedState:e},t.queue=e,e=e.dispatch=hS.bind(null,xe,e),[t.memoizedState,e]}function ao(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=xe.updateQueue,t===null?(t={lastEffect:null,stores:null},xe.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function ey(){return Et().memoizedState}function vi(e,t,n,r){var s=zt();xe.flags|=e,s.memoizedState=ao(1|t,n,void 0,r===void 0?null:r)}function Ca(e,t,n,r){var s=Et();r=r===void 0?null:r;var o=void 0;if(je!==null){var i=je.memoizedState;if(o=i.destroy,r!==null&&sd(r,i.deps)){s.memoizedState=ao(t,n,o,r);return}}xe.flags|=e,s.memoizedState=ao(1|t,n,o,r)}function ih(e,t){return vi(8390656,8,e,t)}function ad(e,t){return Ca(2048,8,e,t)}function ty(e,t){return Ca(4,2,e,t)}function ny(e,t){return Ca(4,4,e,t)}function ry(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function sy(e,t,n){return n=n!=null?n.concat([e]):null,Ca(4,4,ry.bind(null,t,e),n)}function ld(){}function oy(e,t){var n=Et();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sd(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function iy(e,t){var n=Et();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sd(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function ay(e,t,n){return gr&21?(Ot(n,t)||(n=fg(),xe.lanes|=n,yr|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,nt=!0),e.memoizedState=n)}function dS(e,t){var n=te;te=n!==0&&4>n?n:4,e(!0);var r=Sl.transition;Sl.transition={};try{e(!1),t()}finally{te=n,Sl.transition=r}}function ly(){return Et().memoizedState}function fS(e,t,n){var r=_n(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},uy(e))cy(t,n);else if(n=Wg(e,t,n,r),n!==null){var s=Qe();Dt(n,e,r,s),dy(n,t,r)}}function hS(e,t,n){var r=_n(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(uy(e))cy(t,s);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var i=t.lastRenderedState,a=o(i,n);if(s.hasEagerState=!0,s.eagerState=a,Ot(a,i)){var l=t.interleaved;l===null?(s.next=s,Jc(t)):(s.next=l.next,l.next=s),t.interleaved=s;return}}catch{}finally{}n=Wg(e,t,s,r),n!==null&&(s=Qe(),Dt(n,e,r,s),dy(n,t,r))}}function uy(e){var t=e.alternate;return e===xe||t!==null&&t===xe}function cy(e,t){Vs=Zi=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function dy(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Fc(e,n)}}var qi={readContext:St,useCallback:$e,useContext:$e,useEffect:$e,useImperativeHandle:$e,useInsertionEffect:$e,useLayoutEffect:$e,useMemo:$e,useReducer:$e,useRef:$e,useState:$e,useDebugValue:$e,useDeferredValue:$e,useTransition:$e,useMutableSource:$e,useSyncExternalStore:$e,useId:$e,unstable_isNewReconciler:!1},pS={readContext:St,useCallback:function(e,t){return zt().memoizedState=[e,t===void 0?null:t],e},useContext:St,useEffect:ih,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,vi(4194308,4,ry.bind(null,t,e),n)},useLayoutEffect:function(e,t){return vi(4194308,4,e,t)},useInsertionEffect:function(e,t){return vi(4,2,e,t)},useMemo:function(e,t){var n=zt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=zt();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=fS.bind(null,xe,e),[r.memoizedState,e]},useRef:function(e){var t=zt();return e={current:e},t.memoizedState=e},useState:oh,useDebugValue:ld,useDeferredValue:function(e){return zt().memoizedState=e},useTransition:function(){var e=oh(!1),t=e[0];return e=dS.bind(null,e[1]),zt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=xe,s=zt();if(me){if(n===void 0)throw Error(M(407));n=n()}else{if(n=t(),De===null)throw Error(M(349));gr&30||Xg(r,t,n)}s.memoizedState=n;var o={value:n,getSnapshot:t};return s.queue=o,ih(Zg.bind(null,r,o,e),[e]),r.flags|=2048,ao(9,Qg.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=zt(),t=De.identifierPrefix;if(me){var n=tn,r=en;n=(r&~(1<<32-At(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=oo++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=cS++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},mS={readContext:St,useCallback:oy,useContext:St,useEffect:ad,useImperativeHandle:sy,useInsertionEffect:ty,useLayoutEffect:ny,useMemo:iy,useReducer:El,useRef:ey,useState:function(){return El(io)},useDebugValue:ld,useDeferredValue:function(e){var t=Et();return ay(t,je.memoizedState,e)},useTransition:function(){var e=El(io)[0],t=Et().memoizedState;return[e,t]},useMutableSource:Kg,useSyncExternalStore:Yg,useId:ly,unstable_isNewReconciler:!1},gS={readContext:St,useCallback:oy,useContext:St,useEffect:ad,useImperativeHandle:sy,useInsertionEffect:ty,useLayoutEffect:ny,useMemo:iy,useReducer:kl,useRef:ey,useState:function(){return kl(io)},useDebugValue:ld,useDeferredValue:function(e){var t=Et();return je===null?t.memoizedState=e:ay(t,je.memoizedState,e)},useTransition:function(){var e=kl(io)[0],t=Et().memoizedState;return[e,t]},useMutableSource:Kg,useSyncExternalStore:Yg,useId:ly,unstable_isNewReconciler:!1};function jt(e,t){if(e&&e.defaultProps){t=we({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Du(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:we({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ta={isMounted:function(e){return(e=e._reactInternals)?Er(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Qe(),s=_n(e),o=nn(r,s);o.payload=t,n!=null&&(o.callback=n),t=Ln(e,o,s),t!==null&&(Dt(t,e,s,r),gi(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Qe(),s=_n(e),o=nn(r,s);o.tag=1,o.payload=t,n!=null&&(o.callback=n),t=Ln(e,o,s),t!==null&&(Dt(t,e,s,r),gi(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Qe(),r=_n(e),s=nn(n,r);s.tag=2,t!=null&&(s.callback=t),t=Ln(e,s,r),t!==null&&(Dt(t,e,r,n),gi(t,e,r))}};function ah(e,t,n,r,s,o,i){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,o,i):t.prototype&&t.prototype.isPureReactComponent?!Js(n,r)||!Js(s,o):!0}function fy(e,t,n){var r=!1,s=Bn,o=t.contextType;return typeof o=="object"&&o!==null?o=St(o):(s=st(t)?pr:He.current,r=t.contextTypes,o=(r=r!=null)?es(e,s):Bn),t=new t(n,o),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Ta,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=o),t}function lh(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&&Ta.enqueueReplaceState(t,t.state,null)}function Lu(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},ed(e);var o=t.contextType;typeof o=="object"&&o!==null?s.context=St(o):(o=st(t)?pr:He.current,s.context=es(e,o)),s.state=e.memoizedState,o=t.getDerivedStateFromProps,typeof o=="function"&&(Du(e,t,o,n),s.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof s.getSnapshotBeforeUpdate=="function"||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(t=s.state,typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount(),t!==s.state&&Ta.enqueueReplaceState(s,s.state,null),Xi(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function ss(e,t){try{var n="",r=t;do n+=Ww(r),r=r.return;while(r);var s=n}catch(o){s=`
40
+ Error generating stack: `+o.message+`
41
+ `+o.stack}return{value:e,source:t,stack:s,digest:null}}function bl(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Ou(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var yS=typeof WeakMap=="function"?WeakMap:Map;function hy(e,t,n){n=nn(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){ea||(ea=!0,Hu=r),Ou(e,t)},n}function py(e,t,n){n=nn(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var s=t.value;n.payload=function(){return r(s)},n.callback=function(){Ou(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){Ou(e,t),typeof r!="function"&&(On===null?On=new Set([this]):On.add(this));var i=t.stack;this.componentDidCatch(t.value,{componentStack:i!==null?i:""})}),n}function uh(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new yS;var s=new Set;r.set(t,s)}else s=r.get(t),s===void 0&&(s=new Set,r.set(t,s));s.has(n)||(s.add(n),e=MS.bind(null,e,t,n),t.then(e,e))}function ch(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function dh(e,t,n,r,s){return e.mode&1?(e.flags|=65536,e.lanes=s,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=nn(-1,1),t.tag=2,Ln(n,t,1))),n.lanes|=1),e)}var vS=ln.ReactCurrentOwner,nt=!1;function Ke(e,t,n,r){t.child=e===null?Ug(t,null,n,r):ns(t,e.child,n,r)}function fh(e,t,n,r,s){n=n.render;var o=t.ref;return Yr(t,s),r=od(e,t,n,r,o,s),n=id(),e!==null&&!nt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,an(e,t,s)):(me&&n&&Kc(t),t.flags|=1,Ke(e,t,r,s),t.child)}function hh(e,t,n,r,s){if(e===null){var o=n.type;return typeof o=="function"&&!gd(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,my(e,t,o,r,s)):(e=Ei(n.type,null,r,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!(e.lanes&s)){var i=o.memoizedProps;if(n=n.compare,n=n!==null?n:Js,n(i,r)&&e.ref===t.ref)return an(e,t,s)}return t.flags|=1,e=In(o,r),e.ref=t.ref,e.return=t,t.child=e}function my(e,t,n,r,s){if(e!==null){var o=e.memoizedProps;if(Js(o,r)&&e.ref===t.ref)if(nt=!1,t.pendingProps=r=o,(e.lanes&s)!==0)e.flags&131072&&(nt=!0);else return t.lanes=e.lanes,an(e,t,s)}return _u(e,t,n,r,s)}function gy(e,t,n){var r=t.pendingProps,s=r.children,o=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},ae(zr,at),at|=n;else{if(!(n&1073741824))return e=o!==null?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,ae(zr,at),at|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,ae(zr,at),at|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,ae(zr,at),at|=r;return Ke(e,t,s,n),t.child}function yy(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function _u(e,t,n,r,s){var o=st(n)?pr:He.current;return o=es(t,o),Yr(t,s),n=od(e,t,n,r,o,s),r=id(),e!==null&&!nt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,an(e,t,s)):(me&&r&&Kc(t),t.flags|=1,Ke(e,t,n,s),t.child)}function ph(e,t,n,r,s){if(st(n)){var o=!0;Wi(t)}else o=!1;if(Yr(t,s),t.stateNode===null)xi(e,t),fy(t,n,r),Lu(t,n,r,s),r=!0;else if(e===null){var i=t.stateNode,a=t.memoizedProps;i.props=a;var l=i.context,c=n.contextType;typeof c=="object"&&c!==null?c=St(c):(c=st(n)?pr:He.current,c=es(t,c));var d=n.getDerivedStateFromProps,u=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function";u||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==r||l!==c)&&lh(t,i,r,c),En=!1;var f=t.memoizedState;i.state=f,Xi(t,r,i,s),l=t.memoizedState,a!==r||f!==l||rt.current||En?(typeof d=="function"&&(Du(t,n,d,r),l=t.memoizedState),(a=En||ah(t,n,a,r,f,l,c))?(u||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),i.props=r,i.state=l,i.context=c,r=a):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,Hg(e,t),a=t.memoizedProps,c=t.type===t.elementType?a:jt(t.type,a),i.props=c,u=t.pendingProps,f=i.context,l=n.contextType,typeof l=="object"&&l!==null?l=St(l):(l=st(n)?pr:He.current,l=es(t,l));var y=n.getDerivedStateFromProps;(d=typeof y=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==u||f!==l)&&lh(t,i,r,l),En=!1,f=t.memoizedState,i.state=f,Xi(t,r,i,s);var w=t.memoizedState;a!==u||f!==w||rt.current||En?(typeof y=="function"&&(Du(t,n,y,r),w=t.memoizedState),(c=En||ah(t,n,c,r,f,w,l)||!1)?(d||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(r,w,l),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(r,w,l)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=w),i.props=r,i.state=w,i.context=l,r=c):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return Iu(e,t,n,r,o,s)}function Iu(e,t,n,r,s,o){yy(e,t);var i=(t.flags&128)!==0;if(!r&&!i)return s&&Jf(t,n,!1),an(e,t,o);r=t.stateNode,vS.current=t;var a=i&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&i?(t.child=ns(t,e.child,null,o),t.child=ns(t,null,a,o)):Ke(e,t,a,o),t.memoizedState=r.state,s&&Jf(t,n,!0),t.child}function vy(e){var t=e.stateNode;t.pendingContext?qf(e,t.pendingContext,t.pendingContext!==t.context):t.context&&qf(e,t.context,!1),td(e,t.containerInfo)}function mh(e,t,n,r,s){return ts(),Xc(s),t.flags|=256,Ke(e,t,n,r),t.child}var Vu={dehydrated:null,treeContext:null,retryLane:0};function Fu(e){return{baseLanes:e,cachePool:null,transitions:null}}function xy(e,t,n){var r=t.pendingProps,s=ve.current,o=!1,i=(t.flags&128)!==0,a;if((a=i)||(a=e!==null&&e.memoizedState===null?!1:(s&2)!==0),a?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),ae(ve,s&1),e===null)return Mu(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(i=r.children,e=r.fallback,o?(r=t.mode,o=t.child,i={mode:"hidden",children:i},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=i):o=ja(i,r,0,null),e=cr(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=Fu(n),t.memoizedState=Vu,e):ud(t,i));if(s=e.memoizedState,s!==null&&(a=s.dehydrated,a!==null))return xS(e,t,i,r,a,s,n);if(o){o=r.fallback,i=t.mode,s=e.child,a=s.sibling;var l={mode:"hidden",children:r.children};return!(i&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=In(s,l),r.subtreeFlags=s.subtreeFlags&14680064),a!==null?o=In(a,o):(o=cr(o,i,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,i=e.child.memoizedState,i=i===null?Fu(n):{baseLanes:i.baseLanes|n,cachePool:null,transitions:i.transitions},o.memoizedState=i,o.childLanes=e.childLanes&~n,t.memoizedState=Vu,r}return o=e.child,e=o.sibling,r=In(o,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function ud(e,t){return t=ja({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Yo(e,t,n,r){return r!==null&&Xc(r),ns(t,e.child,null,n),e=ud(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function xS(e,t,n,r,s,o,i){if(n)return t.flags&256?(t.flags&=-257,r=bl(Error(M(422))),Yo(e,t,i,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,s=t.mode,r=ja({mode:"visible",children:r.children},s,0,null),o=cr(o,s,i,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&ns(t,e.child,null,i),t.child.memoizedState=Fu(i),t.memoizedState=Vu,o);if(!(t.mode&1))return Yo(e,t,i,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var a=r.dgst;return r=a,o=Error(M(419)),r=bl(o,r,void 0),Yo(e,t,i,r)}if(a=(i&e.childLanes)!==0,nt||a){if(r=De,r!==null){switch(i&-i){case 4:s=2;break;case 16:s=8;break;case 64: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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:s=32;break;case 536870912:s=268435456;break;default:s=0}s=s&(r.suspendedLanes|i)?0:s,s!==0&&s!==o.retryLane&&(o.retryLane=s,on(e,s),Dt(r,e,s,-1))}return md(),r=bl(Error(M(421))),Yo(e,t,i,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=AS.bind(null,e),s._reactRetry=t,null):(e=o.treeContext,lt=Dn(s.nextSibling),ut=t,me=!0,Mt=null,e!==null&&(mt[gt++]=en,mt[gt++]=tn,mt[gt++]=mr,en=e.id,tn=e.overflow,mr=t),t=ud(t,r.children),t.flags|=4096,t)}function gh(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Au(e.return,t,n)}function Cl(e,t,n,r,s){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:s}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=s)}function wy(e,t,n){var r=t.pendingProps,s=r.revealOrder,o=r.tail;if(Ke(e,t,r.children,n),r=ve.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&gh(e,n,t);else if(e.tag===19)gh(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(ae(ve,r),!(t.mode&1))t.memoizedState=null;else switch(s){case"forwards":for(n=t.child,s=null;n!==null;)e=n.alternate,e!==null&&Qi(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Cl(t,!1,s,n,o);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&Qi(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Cl(t,!0,n,null,o);break;case"together":Cl(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function xi(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function an(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),yr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(M(153));if(t.child!==null){for(e=t.child,n=In(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=In(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function wS(e,t,n){switch(t.tag){case 3:vy(t),ts();break;case 5:Gg(t);break;case 1:st(t.type)&&Wi(t);break;case 4:td(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;ae(Ki,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(ae(ve,ve.current&1),t.flags|=128,null):n&t.child.childLanes?xy(e,t,n):(ae(ve,ve.current&1),e=an(e,t,n),e!==null?e.sibling:null);ae(ve,ve.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return wy(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),ae(ve,ve.current),r)break;return null;case 22:case 23:return t.lanes=0,gy(e,t,n)}return an(e,t,n)}var Sy,zu,Ey,ky;Sy=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};zu=function(){};Ey=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,ir(Gt.current);var o=null;switch(n){case"input":s=lu(e,s),r=lu(e,r),o=[];break;case"select":s=we({},s,{value:void 0}),r=we({},r,{value:void 0}),o=[];break;case"textarea":s=du(e,s),r=du(e,r),o=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=$i)}hu(n,r);var i;n=null;for(c in s)if(!r.hasOwnProperty(c)&&s.hasOwnProperty(c)&&s[c]!=null)if(c==="style"){var a=s[c];for(i in a)a.hasOwnProperty(i)&&(n||(n={}),n[i]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(Gs.hasOwnProperty(c)?o||(o=[]):(o=o||[]).push(c,null));for(c in r){var l=r[c];if(a=s!=null?s[c]:void 0,r.hasOwnProperty(c)&&l!==a&&(l!=null||a!=null))if(c==="style")if(a){for(i in a)!a.hasOwnProperty(i)||l&&l.hasOwnProperty(i)||(n||(n={}),n[i]="");for(i in l)l.hasOwnProperty(i)&&a[i]!==l[i]&&(n||(n={}),n[i]=l[i])}else n||(o||(o=[]),o.push(c,n)),n=l;else c==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(o=o||[]).push(c,l)):c==="children"?typeof l!="string"&&typeof l!="number"||(o=o||[]).push(c,""+l):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(Gs.hasOwnProperty(c)?(l!=null&&c==="onScroll"&&de("scroll",e),o||a===l||(o=[])):(o=o||[]).push(c,l))}n&&(o=o||[]).push("style",n);var c=o;(t.updateQueue=c)&&(t.flags|=4)}};ky=function(e,t,n,r){n!==r&&(t.flags|=4)};function ks(e,t){if(!me)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 Ue(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags&14680064,r|=s.flags&14680064,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags,r|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function SS(e,t,n){var r=t.pendingProps;switch(Yc(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ue(t),null;case 1:return st(t.type)&&Ui(),Ue(t),null;case 3:return r=t.stateNode,rs(),he(rt),he(He),rd(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Go(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Mt!==null&&(Yu(Mt),Mt=null))),zu(e,t),Ue(t),null;case 5:nd(t);var s=ir(so.current);if(n=t.type,e!==null&&t.stateNode!=null)Ey(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(M(166));return Ue(t),null}if(e=ir(Gt.current),Go(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[Ut]=t,r[no]=o,e=(t.mode&1)!==0,n){case"dialog":de("cancel",r),de("close",r);break;case"iframe":case"object":case"embed":de("load",r);break;case"video":case"audio":for(s=0;s<Ms.length;s++)de(Ms[s],r);break;case"source":de("error",r);break;case"img":case"image":case"link":de("error",r),de("load",r);break;case"details":de("toggle",r);break;case"input":Cf(r,o),de("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},de("invalid",r);break;case"textarea":Pf(r,o),de("invalid",r)}hu(n,o),s=null;for(var i in o)if(o.hasOwnProperty(i)){var a=o[i];i==="children"?typeof a=="string"?r.textContent!==a&&(o.suppressHydrationWarning!==!0&&Ho(r.textContent,a,e),s=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(o.suppressHydrationWarning!==!0&&Ho(r.textContent,a,e),s=["children",""+a]):Gs.hasOwnProperty(i)&&a!=null&&i==="onScroll"&&de("scroll",r)}switch(n){case"input":Io(r),Tf(r,o,!0);break;case"textarea":Io(r),Nf(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=$i)}r=s,t.updateQueue=r,r!==null&&(t.flags|=4)}else{i=s.nodeType===9?s:s.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Zm(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[Ut]=t,e[no]=r,Sy(e,t,!1,!1),t.stateNode=e;e:{switch(i=pu(n,r),n){case"dialog":de("cancel",e),de("close",e),s=r;break;case"iframe":case"object":case"embed":de("load",e),s=r;break;case"video":case"audio":for(s=0;s<Ms.length;s++)de(Ms[s],e);s=r;break;case"source":de("error",e),s=r;break;case"img":case"image":case"link":de("error",e),de("load",e),s=r;break;case"details":de("toggle",e),s=r;break;case"input":Cf(e,r),s=lu(e,r),de("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=we({},r,{value:void 0}),de("invalid",e);break;case"textarea":Pf(e,r),s=du(e,r),de("invalid",e);break;default:s=r}hu(n,s),a=s;for(o in a)if(a.hasOwnProperty(o)){var l=a[o];o==="style"?eg(e,l):o==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&qm(e,l)):o==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&Ks(e,l):typeof l=="number"&&Ks(e,""+l):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(Gs.hasOwnProperty(o)?l!=null&&o==="onScroll"&&de("scroll",e):l!=null&&Dc(e,o,l,i))}switch(n){case"input":Io(e),Tf(e,r,!1);break;case"textarea":Io(e),Nf(e);break;case"option":r.value!=null&&e.setAttribute("value",""+zn(r.value));break;case"select":e.multiple=!!r.multiple,o=r.value,o!=null?Wr(e,!!r.multiple,o,!1):r.defaultValue!=null&&Wr(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=$i)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Ue(t),null;case 6:if(e&&t.stateNode!=null)ky(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(M(166));if(n=ir(so.current),ir(Gt.current),Go(t)){if(r=t.stateNode,n=t.memoizedProps,r[Ut]=t,(o=r.nodeValue!==n)&&(e=ut,e!==null))switch(e.tag){case 3:Ho(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Ho(r.nodeValue,n,(e.mode&1)!==0)}o&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Ut]=t,t.stateNode=r}return Ue(t),null;case 13:if(he(ve),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(me&&lt!==null&&t.mode&1&&!(t.flags&128))Bg(),ts(),t.flags|=98560,o=!1;else if(o=Go(t),r!==null&&r.dehydrated!==null){if(e===null){if(!o)throw Error(M(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(M(317));o[Ut]=t}else ts(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Ue(t),o=!1}else Mt!==null&&(Yu(Mt),Mt=null),o=!0;if(!o)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||ve.current&1?Re===0&&(Re=3):md())),t.updateQueue!==null&&(t.flags|=4),Ue(t),null);case 4:return rs(),zu(e,t),e===null&&eo(t.stateNode.containerInfo),Ue(t),null;case 10:return qc(t.type._context),Ue(t),null;case 17:return st(t.type)&&Ui(),Ue(t),null;case 19:if(he(ve),o=t.memoizedState,o===null)return Ue(t),null;if(r=(t.flags&128)!==0,i=o.rendering,i===null)if(r)ks(o,!1);else{if(Re!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(i=Qi(e),i!==null){for(t.flags|=128,ks(o,!1),r=i.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)o=n,e=r,o.flags&=14680066,i=o.alternate,i===null?(o.childLanes=0,o.lanes=e,o.child=null,o.subtreeFlags=0,o.memoizedProps=null,o.memoizedState=null,o.updateQueue=null,o.dependencies=null,o.stateNode=null):(o.childLanes=i.childLanes,o.lanes=i.lanes,o.child=i.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=i.memoizedProps,o.memoizedState=i.memoizedState,o.updateQueue=i.updateQueue,o.type=i.type,e=i.dependencies,o.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return ae(ve,ve.current&1|2),t.child}e=e.sibling}o.tail!==null&&ke()>os&&(t.flags|=128,r=!0,ks(o,!1),t.lanes=4194304)}else{if(!r)if(e=Qi(i),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ks(o,!0),o.tail===null&&o.tailMode==="hidden"&&!i.alternate&&!me)return Ue(t),null}else 2*ke()-o.renderingStartTime>os&&n!==1073741824&&(t.flags|=128,r=!0,ks(o,!1),t.lanes=4194304);o.isBackwards?(i.sibling=t.child,t.child=i):(n=o.last,n!==null?n.sibling=i:t.child=i,o.last=i)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=ke(),t.sibling=null,n=ve.current,ae(ve,r?n&1|2:n&1),t):(Ue(t),null);case 22:case 23:return pd(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?at&1073741824&&(Ue(t),t.subtreeFlags&6&&(t.flags|=8192)):Ue(t),null;case 24:return null;case 25:return null}throw Error(M(156,t.tag))}function ES(e,t){switch(Yc(t),t.tag){case 1:return st(t.type)&&Ui(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return rs(),he(rt),he(He),rd(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return nd(t),null;case 13:if(he(ve),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(M(340));ts()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return he(ve),null;case 4:return rs(),null;case 10:return qc(t.type._context),null;case 22:case 23:return pd(),null;case 24:return null;default:return null}}var Xo=!1,We=!1,kS=typeof WeakSet=="function"?WeakSet:Set,_=null;function Fr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ee(e,t,r)}else n.current=null}function Bu(e,t,n){try{n()}catch(r){Ee(e,t,r)}}var yh=!1;function bS(e,t){if(bu=Fi,e=Ng(),Gc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var s=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var i=0,a=-1,l=-1,c=0,d=0,u=e,f=null;t:for(;;){for(var y;u!==n||s!==0&&u.nodeType!==3||(a=i+s),u!==o||r!==0&&u.nodeType!==3||(l=i+r),u.nodeType===3&&(i+=u.nodeValue.length),(y=u.firstChild)!==null;)f=u,u=y;for(;;){if(u===e)break t;if(f===n&&++c===s&&(a=i),f===o&&++d===r&&(l=i),(y=u.nextSibling)!==null)break;u=f,f=u.parentNode}u=y}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Cu={focusedElem:e,selectionRange:n},Fi=!1,_=t;_!==null;)if(t=_,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,_=e;else for(;_!==null;){t=_;try{var w=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(w!==null){var x=w.memoizedProps,S=w.memoizedState,m=t.stateNode,g=m.getSnapshotBeforeUpdate(t.elementType===t.type?x:jt(t.type,x),S);m.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(M(163))}}catch(E){Ee(t,t.return,E)}if(e=t.sibling,e!==null){e.return=t.return,_=e;break}_=t.return}return w=yh,yh=!1,w}function Fs(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var o=s.destroy;s.destroy=void 0,o!==void 0&&Bu(t,n,o)}s=s.next}while(s!==r)}}function Pa(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function $u(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function by(e){var t=e.alternate;t!==null&&(e.alternate=null,by(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ut],delete t[no],delete t[Nu],delete t[iS],delete t[aS])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Cy(e){return e.tag===5||e.tag===3||e.tag===4}function vh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Cy(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.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Uu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=$i));else if(r!==4&&(e=e.child,e!==null))for(Uu(e,t,n),e=e.sibling;e!==null;)Uu(e,t,n),e=e.sibling}function Wu(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&&(e=e.child,e!==null))for(Wu(e,t,n),e=e.sibling;e!==null;)Wu(e,t,n),e=e.sibling}var Oe=null,Rt=!1;function pn(e,t,n){for(n=n.child;n!==null;)Ty(e,t,n),n=n.sibling}function Ty(e,t,n){if(Ht&&typeof Ht.onCommitFiberUnmount=="function")try{Ht.onCommitFiberUnmount(xa,n)}catch{}switch(n.tag){case 5:We||Fr(n,t);case 6:var r=Oe,s=Rt;Oe=null,pn(e,t,n),Oe=r,Rt=s,Oe!==null&&(Rt?(e=Oe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Oe.removeChild(n.stateNode));break;case 18:Oe!==null&&(Rt?(e=Oe,n=n.stateNode,e.nodeType===8?vl(e.parentNode,n):e.nodeType===1&&vl(e,n),Zs(e)):vl(Oe,n.stateNode));break;case 4:r=Oe,s=Rt,Oe=n.stateNode.containerInfo,Rt=!0,pn(e,t,n),Oe=r,Rt=s;break;case 0:case 11:case 14:case 15:if(!We&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var o=s,i=o.destroy;o=o.tag,i!==void 0&&(o&2||o&4)&&Bu(n,t,i),s=s.next}while(s!==r)}pn(e,t,n);break;case 1:if(!We&&(Fr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ee(n,t,a)}pn(e,t,n);break;case 21:pn(e,t,n);break;case 22:n.mode&1?(We=(r=We)||n.memoizedState!==null,pn(e,t,n),We=r):pn(e,t,n);break;default:pn(e,t,n)}}function xh(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new kS),t.forEach(function(r){var s=DS.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function Tt(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var s=n[r];try{var o=e,i=t,a=i;e:for(;a!==null;){switch(a.tag){case 5:Oe=a.stateNode,Rt=!1;break e;case 3:Oe=a.stateNode.containerInfo,Rt=!0;break e;case 4:Oe=a.stateNode.containerInfo,Rt=!0;break e}a=a.return}if(Oe===null)throw Error(M(160));Ty(o,i,s),Oe=null,Rt=!1;var l=s.alternate;l!==null&&(l.return=null),s.return=null}catch(c){Ee(s,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Py(t,e),t=t.sibling}function Py(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Tt(t,e),Vt(e),r&4){try{Fs(3,e,e.return),Pa(3,e)}catch(x){Ee(e,e.return,x)}try{Fs(5,e,e.return)}catch(x){Ee(e,e.return,x)}}break;case 1:Tt(t,e),Vt(e),r&512&&n!==null&&Fr(n,n.return);break;case 5:if(Tt(t,e),Vt(e),r&512&&n!==null&&Fr(n,n.return),e.flags&32){var s=e.stateNode;try{Ks(s,"")}catch(x){Ee(e,e.return,x)}}if(r&4&&(s=e.stateNode,s!=null)){var o=e.memoizedProps,i=n!==null?n.memoizedProps:o,a=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{a==="input"&&o.type==="radio"&&o.name!=null&&Xm(s,o),pu(a,i);var c=pu(a,o);for(i=0;i<l.length;i+=2){var d=l[i],u=l[i+1];d==="style"?eg(s,u):d==="dangerouslySetInnerHTML"?qm(s,u):d==="children"?Ks(s,u):Dc(s,d,u,c)}switch(a){case"input":uu(s,o);break;case"textarea":Qm(s,o);break;case"select":var f=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!o.multiple;var y=o.value;y!=null?Wr(s,!!o.multiple,y,!1):f!==!!o.multiple&&(o.defaultValue!=null?Wr(s,!!o.multiple,o.defaultValue,!0):Wr(s,!!o.multiple,o.multiple?[]:"",!1))}s[no]=o}catch(x){Ee(e,e.return,x)}}break;case 6:if(Tt(t,e),Vt(e),r&4){if(e.stateNode===null)throw Error(M(162));s=e.stateNode,o=e.memoizedProps;try{s.nodeValue=o}catch(x){Ee(e,e.return,x)}}break;case 3:if(Tt(t,e),Vt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Zs(t.containerInfo)}catch(x){Ee(e,e.return,x)}break;case 4:Tt(t,e),Vt(e);break;case 13:Tt(t,e),Vt(e),s=e.child,s.flags&8192&&(o=s.memoizedState!==null,s.stateNode.isHidden=o,!o||s.alternate!==null&&s.alternate.memoizedState!==null||(fd=ke())),r&4&&xh(e);break;case 22:if(d=n!==null&&n.memoizedState!==null,e.mode&1?(We=(c=We)||d,Tt(t,e),We=c):Tt(t,e),Vt(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!d&&e.mode&1)for(_=e,d=e.child;d!==null;){for(u=_=d;_!==null;){switch(f=_,y=f.child,f.tag){case 0:case 11:case 14:case 15:Fs(4,f,f.return);break;case 1:Fr(f,f.return);var w=f.stateNode;if(typeof w.componentWillUnmount=="function"){r=f,n=f.return;try{t=r,w.props=t.memoizedProps,w.state=t.memoizedState,w.componentWillUnmount()}catch(x){Ee(r,n,x)}}break;case 5:Fr(f,f.return);break;case 22:if(f.memoizedState!==null){Sh(u);continue}}y!==null?(y.return=f,_=y):Sh(u)}d=d.sibling}e:for(d=null,u=e;;){if(u.tag===5){if(d===null){d=u;try{s=u.stateNode,c?(o=s.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(a=u.stateNode,l=u.memoizedProps.style,i=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=Jm("display",i))}catch(x){Ee(e,e.return,x)}}}else if(u.tag===6){if(d===null)try{u.stateNode.nodeValue=c?"":u.memoizedProps}catch(x){Ee(e,e.return,x)}}else if((u.tag!==22&&u.tag!==23||u.memoizedState===null||u===e)&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break e;for(;u.sibling===null;){if(u.return===null||u.return===e)break e;d===u&&(d=null),u=u.return}d===u&&(d=null),u.sibling.return=u.return,u=u.sibling}}break;case 19:Tt(t,e),Vt(e),r&4&&xh(e);break;case 21:break;default:Tt(t,e),Vt(e)}}function Vt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Cy(n)){var r=n;break e}n=n.return}throw Error(M(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(Ks(s,""),r.flags&=-33);var o=vh(e);Wu(e,o,s);break;case 3:case 4:var i=r.stateNode.containerInfo,a=vh(e);Uu(e,a,i);break;default:throw Error(M(161))}}catch(l){Ee(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function CS(e,t,n){_=e,Ny(e)}function Ny(e,t,n){for(var r=(e.mode&1)!==0;_!==null;){var s=_,o=s.child;if(s.tag===22&&r){var i=s.memoizedState!==null||Xo;if(!i){var a=s.alternate,l=a!==null&&a.memoizedState!==null||We;a=Xo;var c=We;if(Xo=i,(We=l)&&!c)for(_=s;_!==null;)i=_,l=i.child,i.tag===22&&i.memoizedState!==null?Eh(s):l!==null?(l.return=i,_=l):Eh(s);for(;o!==null;)_=o,Ny(o),o=o.sibling;_=s,Xo=a,We=c}wh(e)}else s.subtreeFlags&8772&&o!==null?(o.return=s,_=o):wh(e)}}function wh(e){for(;_!==null;){var t=_;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:We||Pa(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!We)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:jt(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=t.updateQueue;o!==null&&sh(t,o,r);break;case 3:var i=t.updateQueue;if(i!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}sh(t,i,n)}break;case 5:var a=t.stateNode;if(n===null&&t.flags&4){n=a;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var c=t.alternate;if(c!==null){var d=c.memoizedState;if(d!==null){var u=d.dehydrated;u!==null&&Zs(u)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(M(163))}We||t.flags&512&&$u(t)}catch(f){Ee(t,t.return,f)}}if(t===e){_=null;break}if(n=t.sibling,n!==null){n.return=t.return,_=n;break}_=t.return}}function Sh(e){for(;_!==null;){var t=_;if(t===e){_=null;break}var n=t.sibling;if(n!==null){n.return=t.return,_=n;break}_=t.return}}function Eh(e){for(;_!==null;){var t=_;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Pa(4,t)}catch(l){Ee(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(l){Ee(t,s,l)}}var o=t.return;try{$u(t)}catch(l){Ee(t,o,l)}break;case 5:var i=t.return;try{$u(t)}catch(l){Ee(t,i,l)}}}catch(l){Ee(t,t.return,l)}if(t===e){_=null;break}var a=t.sibling;if(a!==null){a.return=t.return,_=a;break}_=t.return}}var TS=Math.ceil,Ji=ln.ReactCurrentDispatcher,cd=ln.ReactCurrentOwner,xt=ln.ReactCurrentBatchConfig,X=0,De=null,Ce=null,Ve=0,at=0,zr=Hn(0),Re=0,lo=null,yr=0,Na=0,dd=0,zs=null,tt=null,fd=0,os=1/0,qt=null,ea=!1,Hu=null,On=null,Qo=!1,Tn=null,ta=0,Bs=0,Gu=null,wi=-1,Si=0;function Qe(){return X&6?ke():wi!==-1?wi:wi=ke()}function _n(e){return e.mode&1?X&2&&Ve!==0?Ve&-Ve:uS.transition!==null?(Si===0&&(Si=fg()),Si):(e=te,e!==0||(e=window.event,e=e===void 0?16:xg(e.type)),e):1}function Dt(e,t,n,r){if(50<Bs)throw Bs=0,Gu=null,Error(M(185));wo(e,n,r),(!(X&2)||e!==De)&&(e===De&&(!(X&2)&&(Na|=n),Re===4&&bn(e,Ve)),ot(e,r),n===1&&X===0&&!(t.mode&1)&&(os=ke()+500,ba&&Gn()))}function ot(e,t){var n=e.callbackNode;u1(e,t);var r=Vi(e,e===De?Ve:0);if(r===0)n!==null&&Mf(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Mf(n),t===1)e.tag===0?lS(kh.bind(null,e)):Vg(kh.bind(null,e)),sS(function(){!(X&6)&&Gn()}),n=null;else{switch(hg(r)){case 1:n=Vc;break;case 4:n=cg;break;case 16:n=Ii;break;case 536870912:n=dg;break;default:n=Ii}n=_y(n,jy.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function jy(e,t){if(wi=-1,Si=0,X&6)throw Error(M(327));var n=e.callbackNode;if(Xr()&&e.callbackNode!==n)return null;var r=Vi(e,e===De?Ve:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=na(e,r);else{t=r;var s=X;X|=2;var o=My();(De!==e||Ve!==t)&&(qt=null,os=ke()+500,ur(e,t));do try{jS();break}catch(a){Ry(e,a)}while(!0);Zc(),Ji.current=o,X=s,Ce!==null?t=0:(De=null,Ve=0,t=Re)}if(t!==0){if(t===2&&(s=xu(e),s!==0&&(r=s,t=Ku(e,s))),t===1)throw n=lo,ur(e,0),bn(e,r),ot(e,ke()),n;if(t===6)bn(e,r);else{if(s=e.current.alternate,!(r&30)&&!PS(s)&&(t=na(e,r),t===2&&(o=xu(e),o!==0&&(r=o,t=Ku(e,o))),t===1))throw n=lo,ur(e,0),bn(e,r),ot(e,ke()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(M(345));case 2:tr(e,tt,qt);break;case 3:if(bn(e,r),(r&130023424)===r&&(t=fd+500-ke(),10<t)){if(Vi(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){Qe(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=Pu(tr.bind(null,e,tt,qt),t);break}tr(e,tt,qt);break;case 4:if(bn(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var i=31-At(r);o=1<<i,i=t[i],i>s&&(s=i),r&=~o}if(r=s,r=ke()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*TS(r/1960))-r,10<r){e.timeoutHandle=Pu(tr.bind(null,e,tt,qt),r);break}tr(e,tt,qt);break;case 5:tr(e,tt,qt);break;default:throw Error(M(329))}}}return ot(e,ke()),e.callbackNode===n?jy.bind(null,e):null}function Ku(e,t){var n=zs;return e.current.memoizedState.isDehydrated&&(ur(e,t).flags|=256),e=na(e,t),e!==2&&(t=tt,tt=n,t!==null&&Yu(t)),e}function Yu(e){tt===null?tt=e:tt.push.apply(tt,e)}function PS(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var s=n[r],o=s.getSnapshot;s=s.value;try{if(!Ot(o(),s))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 bn(e,t){for(t&=~dd,t&=~Na,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-At(t),r=1<<n;e[n]=-1,t&=~r}}function kh(e){if(X&6)throw Error(M(327));Xr();var t=Vi(e,0);if(!(t&1))return ot(e,ke()),null;var n=na(e,t);if(e.tag!==0&&n===2){var r=xu(e);r!==0&&(t=r,n=Ku(e,r))}if(n===1)throw n=lo,ur(e,0),bn(e,t),ot(e,ke()),n;if(n===6)throw Error(M(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,tr(e,tt,qt),ot(e,ke()),null}function hd(e,t){var n=X;X|=1;try{return e(t)}finally{X=n,X===0&&(os=ke()+500,ba&&Gn())}}function vr(e){Tn!==null&&Tn.tag===0&&!(X&6)&&Xr();var t=X;X|=1;var n=xt.transition,r=te;try{if(xt.transition=null,te=1,e)return e()}finally{te=r,xt.transition=n,X=t,!(X&6)&&Gn()}}function pd(){at=zr.current,he(zr)}function ur(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,rS(n)),Ce!==null)for(n=Ce.return;n!==null;){var r=n;switch(Yc(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ui();break;case 3:rs(),he(rt),he(He),rd();break;case 5:nd(r);break;case 4:rs();break;case 13:he(ve);break;case 19:he(ve);break;case 10:qc(r.type._context);break;case 22:case 23:pd()}n=n.return}if(De=e,Ce=e=In(e.current,null),Ve=at=t,Re=0,lo=null,dd=Na=yr=0,tt=zs=null,or!==null){for(t=0;t<or.length;t++)if(n=or[t],r=n.interleaved,r!==null){n.interleaved=null;var s=r.next,o=n.pending;if(o!==null){var i=o.next;o.next=s,r.next=i}n.pending=r}or=null}return e}function Ry(e,t){do{var n=Ce;try{if(Zc(),yi.current=qi,Zi){for(var r=xe.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}Zi=!1}if(gr=0,Ae=je=xe=null,Vs=!1,oo=0,cd.current=null,n===null||n.return===null){Re=1,lo=t,Ce=null;break}e:{var o=e,i=n.return,a=n,l=t;if(t=Ve,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var c=l,d=a,u=d.tag;if(!(d.mode&1)&&(u===0||u===11||u===15)){var f=d.alternate;f?(d.updateQueue=f.updateQueue,d.memoizedState=f.memoizedState,d.lanes=f.lanes):(d.updateQueue=null,d.memoizedState=null)}var y=ch(i);if(y!==null){y.flags&=-257,dh(y,i,a,o,t),y.mode&1&&uh(o,c,t),t=y,l=c;var w=t.updateQueue;if(w===null){var x=new Set;x.add(l),t.updateQueue=x}else w.add(l);break e}else{if(!(t&1)){uh(o,c,t),md();break e}l=Error(M(426))}}else if(me&&a.mode&1){var S=ch(i);if(S!==null){!(S.flags&65536)&&(S.flags|=256),dh(S,i,a,o,t),Xc(ss(l,a));break e}}o=l=ss(l,a),Re!==4&&(Re=2),zs===null?zs=[o]:zs.push(o),o=i;do{switch(o.tag){case 3:o.flags|=65536,t&=-t,o.lanes|=t;var m=hy(o,l,t);rh(o,m);break e;case 1:a=l;var g=o.type,v=o.stateNode;if(!(o.flags&128)&&(typeof g.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(On===null||!On.has(v)))){o.flags|=65536,t&=-t,o.lanes|=t;var E=py(o,a,t);rh(o,E);break e}}o=o.return}while(o!==null)}Dy(n)}catch(C){t=C,Ce===n&&n!==null&&(Ce=n=n.return);continue}break}while(!0)}function My(){var e=Ji.current;return Ji.current=qi,e===null?qi:e}function md(){(Re===0||Re===3||Re===2)&&(Re=4),De===null||!(yr&268435455)&&!(Na&268435455)||bn(De,Ve)}function na(e,t){var n=X;X|=2;var r=My();(De!==e||Ve!==t)&&(qt=null,ur(e,t));do try{NS();break}catch(s){Ry(e,s)}while(!0);if(Zc(),X=n,Ji.current=r,Ce!==null)throw Error(M(261));return De=null,Ve=0,Re}function NS(){for(;Ce!==null;)Ay(Ce)}function jS(){for(;Ce!==null&&!e1();)Ay(Ce)}function Ay(e){var t=Oy(e.alternate,e,at);e.memoizedProps=e.pendingProps,t===null?Dy(e):Ce=t,cd.current=null}function Dy(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=ES(n,t),n!==null){n.flags&=32767,Ce=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Re=6,Ce=null;return}}else if(n=SS(n,t,at),n!==null){Ce=n;return}if(t=t.sibling,t!==null){Ce=t;return}Ce=t=e}while(t!==null);Re===0&&(Re=5)}function tr(e,t,n){var r=te,s=xt.transition;try{xt.transition=null,te=1,RS(e,t,n,r)}finally{xt.transition=s,te=r}return null}function RS(e,t,n,r){do Xr();while(Tn!==null);if(X&6)throw Error(M(327));n=e.finishedWork;var s=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(M(177));e.callbackNode=null,e.callbackPriority=0;var o=n.lanes|n.childLanes;if(c1(e,o),e===De&&(Ce=De=null,Ve=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Qo||(Qo=!0,_y(Ii,function(){return Xr(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=xt.transition,xt.transition=null;var i=te;te=1;var a=X;X|=4,cd.current=null,bS(e,n),Py(n,e),Q1(Cu),Fi=!!bu,Cu=bu=null,e.current=n,CS(n),t1(),X=a,te=i,xt.transition=o}else e.current=n;if(Qo&&(Qo=!1,Tn=e,ta=s),o=e.pendingLanes,o===0&&(On=null),s1(n.stateNode),ot(e,ke()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)s=t[n],r(s.value,{componentStack:s.stack,digest:s.digest});if(ea)throw ea=!1,e=Hu,Hu=null,e;return ta&1&&e.tag!==0&&Xr(),o=e.pendingLanes,o&1?e===Gu?Bs++:(Bs=0,Gu=e):Bs=0,Gn(),null}function Xr(){if(Tn!==null){var e=hg(ta),t=xt.transition,n=te;try{if(xt.transition=null,te=16>e?16:e,Tn===null)var r=!1;else{if(e=Tn,Tn=null,ta=0,X&6)throw Error(M(331));var s=X;for(X|=4,_=e.current;_!==null;){var o=_,i=o.child;if(_.flags&16){var a=o.deletions;if(a!==null){for(var l=0;l<a.length;l++){var c=a[l];for(_=c;_!==null;){var d=_;switch(d.tag){case 0:case 11:case 15:Fs(8,d,o)}var u=d.child;if(u!==null)u.return=d,_=u;else for(;_!==null;){d=_;var f=d.sibling,y=d.return;if(by(d),d===c){_=null;break}if(f!==null){f.return=y,_=f;break}_=y}}}var w=o.alternate;if(w!==null){var x=w.child;if(x!==null){w.child=null;do{var S=x.sibling;x.sibling=null,x=S}while(x!==null)}}_=o}}if(o.subtreeFlags&2064&&i!==null)i.return=o,_=i;else e:for(;_!==null;){if(o=_,o.flags&2048)switch(o.tag){case 0:case 11:case 15:Fs(9,o,o.return)}var m=o.sibling;if(m!==null){m.return=o.return,_=m;break e}_=o.return}}var g=e.current;for(_=g;_!==null;){i=_;var v=i.child;if(i.subtreeFlags&2064&&v!==null)v.return=i,_=v;else e:for(i=g;_!==null;){if(a=_,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:Pa(9,a)}}catch(C){Ee(a,a.return,C)}if(a===i){_=null;break e}var E=a.sibling;if(E!==null){E.return=a.return,_=E;break e}_=a.return}}if(X=s,Gn(),Ht&&typeof Ht.onPostCommitFiberRoot=="function")try{Ht.onPostCommitFiberRoot(xa,e)}catch{}r=!0}return r}finally{te=n,xt.transition=t}}return!1}function bh(e,t,n){t=ss(n,t),t=hy(e,t,1),e=Ln(e,t,1),t=Qe(),e!==null&&(wo(e,1,t),ot(e,t))}function Ee(e,t,n){if(e.tag===3)bh(e,e,n);else for(;t!==null;){if(t.tag===3){bh(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(On===null||!On.has(r))){e=ss(n,e),e=py(t,e,1),t=Ln(t,e,1),e=Qe(),t!==null&&(wo(t,1,e),ot(t,e));break}}t=t.return}}function MS(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=Qe(),e.pingedLanes|=e.suspendedLanes&n,De===e&&(Ve&n)===n&&(Re===4||Re===3&&(Ve&130023424)===Ve&&500>ke()-fd?ur(e,0):dd|=n),ot(e,t)}function Ly(e,t){t===0&&(e.mode&1?(t=zo,zo<<=1,!(zo&130023424)&&(zo=4194304)):t=1);var n=Qe();e=on(e,t),e!==null&&(wo(e,t,n),ot(e,n))}function AS(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ly(e,n)}function DS(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(M(314))}r!==null&&r.delete(t),Ly(e,n)}var Oy;Oy=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||rt.current)nt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return nt=!1,wS(e,t,n);nt=!!(e.flags&131072)}else nt=!1,me&&t.flags&1048576&&Fg(t,Gi,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;xi(e,t),e=t.pendingProps;var s=es(t,He.current);Yr(t,n),s=od(null,t,r,e,s,n);var o=id();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,st(r)?(o=!0,Wi(t)):o=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,ed(t),s.updater=Ta,t.stateNode=s,s._reactInternals=t,Lu(t,r,e,n),t=Iu(null,t,r,!0,o,n)):(t.tag=0,me&&o&&Kc(t),Ke(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(xi(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=OS(r),e=jt(r,e),s){case 0:t=_u(null,t,r,e,n);break e;case 1:t=ph(null,t,r,e,n);break e;case 11:t=fh(null,t,r,e,n);break e;case 14:t=hh(null,t,r,jt(r.type,e),n);break e}throw Error(M(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:jt(r,s),_u(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:jt(r,s),ph(e,t,r,s,n);case 3:e:{if(vy(t),e===null)throw Error(M(387));r=t.pendingProps,o=t.memoizedState,s=o.element,Hg(e,t),Xi(t,r,null,n);var i=t.memoizedState;if(r=i.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){s=ss(Error(M(423)),t),t=mh(e,t,r,n,s);break e}else if(r!==s){s=ss(Error(M(424)),t),t=mh(e,t,r,n,s);break e}else for(lt=Dn(t.stateNode.containerInfo.firstChild),ut=t,me=!0,Mt=null,n=Ug(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ts(),r===s){t=an(e,t,n);break e}Ke(e,t,r,n)}t=t.child}return t;case 5:return Gg(t),e===null&&Mu(t),r=t.type,s=t.pendingProps,o=e!==null?e.memoizedProps:null,i=s.children,Tu(r,s)?i=null:o!==null&&Tu(r,o)&&(t.flags|=32),yy(e,t),Ke(e,t,i,n),t.child;case 6:return e===null&&Mu(t),null;case 13:return xy(e,t,n);case 4:return td(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ns(t,null,r,n):Ke(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:jt(r,s),fh(e,t,r,s,n);case 7:return Ke(e,t,t.pendingProps,n),t.child;case 8:return Ke(e,t,t.pendingProps.children,n),t.child;case 12:return Ke(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,o=t.memoizedProps,i=s.value,ae(Ki,r._currentValue),r._currentValue=i,o!==null)if(Ot(o.value,i)){if(o.children===s.children&&!rt.current){t=an(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var a=o.dependencies;if(a!==null){i=o.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=nn(-1,n&-n),l.tag=2;var c=o.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?l.next=l:(l.next=d.next,d.next=l),c.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Au(o.return,n,t),a.lanes|=n;break}l=l.next}}else if(o.tag===10)i=o.type===t.type?null:o.child;else if(o.tag===18){if(i=o.return,i===null)throw Error(M(341));i.lanes|=n,a=i.alternate,a!==null&&(a.lanes|=n),Au(i,n,t),i=o.sibling}else i=o.child;if(i!==null)i.return=o;else for(i=o;i!==null;){if(i===t){i=null;break}if(o=i.sibling,o!==null){o.return=i.return,i=o;break}i=i.return}o=i}Ke(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,Yr(t,n),s=St(s),r=r(s),t.flags|=1,Ke(e,t,r,n),t.child;case 14:return r=t.type,s=jt(r,t.pendingProps),s=jt(r.type,s),hh(e,t,r,s,n);case 15:return my(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:jt(r,s),xi(e,t),t.tag=1,st(r)?(e=!0,Wi(t)):e=!1,Yr(t,n),fy(t,r,s),Lu(t,r,s,n),Iu(null,t,r,!0,e,n);case 19:return wy(e,t,n);case 22:return gy(e,t,n)}throw Error(M(156,t.tag))};function _y(e,t){return ug(e,t)}function LS(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.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 yt(e,t,n,r){return new LS(e,t,n,r)}function gd(e){return e=e.prototype,!(!e||!e.isReactComponent)}function OS(e){if(typeof e=="function")return gd(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Oc)return 11;if(e===_c)return 14}return 2}function In(e,t){var n=e.alternate;return n===null?(n=yt(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&14680064,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}function Ei(e,t,n,r,s,o){var i=2;if(r=e,typeof e=="function")gd(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case Rr:return cr(n.children,s,o,t);case Lc:i=8,s|=8;break;case su:return e=yt(12,n,t,s|2),e.elementType=su,e.lanes=o,e;case ou:return e=yt(13,n,t,s),e.elementType=ou,e.lanes=o,e;case iu:return e=yt(19,n,t,s),e.elementType=iu,e.lanes=o,e;case Gm:return ja(n,s,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Wm:i=10;break e;case Hm:i=9;break e;case Oc:i=11;break e;case _c:i=14;break e;case Sn:i=16,r=null;break e}throw Error(M(130,e==null?e:typeof e,""))}return t=yt(i,n,t,s),t.elementType=e,t.type=r,t.lanes=o,t}function cr(e,t,n,r){return e=yt(7,e,r,t),e.lanes=n,e}function ja(e,t,n,r){return e=yt(22,e,r,t),e.elementType=Gm,e.lanes=n,e.stateNode={isHidden:!1},e}function Tl(e,t,n){return e=yt(6,e,null,t),e.lanes=n,e}function Pl(e,t,n){return t=yt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function _S(e,t,n,r,s){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=al(0),this.expirationTimes=al(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=al(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function yd(e,t,n,r,s,o,i,a,l){return e=new _S(e,t,n,a,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=yt(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},ed(o),e}function IS(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:jr,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Iy(e){if(!e)return Bn;e=e._reactInternals;e:{if(Er(e)!==e||e.tag!==1)throw Error(M(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(st(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(M(171))}if(e.tag===1){var n=e.type;if(st(n))return Ig(e,n,t)}return t}function Vy(e,t,n,r,s,o,i,a,l){return e=yd(n,r,!0,e,s,o,i,a,l),e.context=Iy(null),n=e.current,r=Qe(),s=_n(n),o=nn(r,s),o.callback=t??null,Ln(n,o,s),e.current.lanes=s,wo(e,s,r),ot(e,r),e}function Ra(e,t,n,r){var s=t.current,o=Qe(),i=_n(s);return n=Iy(n),t.context===null?t.context=n:t.pendingContext=n,t=nn(o,i),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=Ln(s,t,i),e!==null&&(Dt(e,s,i,o),gi(e,s,i)),i}function ra(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function Ch(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function vd(e,t){Ch(e,t),(e=e.alternate)&&Ch(e,t)}function VS(){return null}var Fy=typeof reportError=="function"?reportError:function(e){console.error(e)};function xd(e){this._internalRoot=e}Ma.prototype.render=xd.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(M(409));Ra(e,t,null,null)};Ma.prototype.unmount=xd.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;vr(function(){Ra(null,e,null,null)}),t[sn]=null}};function Ma(e){this._internalRoot=e}Ma.prototype.unstable_scheduleHydration=function(e){if(e){var t=gg();e={blockedOn:null,target:e,priority:t};for(var n=0;n<kn.length&&t!==0&&t<kn[n].priority;n++);kn.splice(n,0,e),n===0&&vg(e)}};function wd(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Aa(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Th(){}function FS(e,t,n,r,s){if(s){if(typeof r=="function"){var o=r;r=function(){var c=ra(i);o.call(c)}}var i=Vy(t,r,e,0,null,!1,!1,"",Th);return e._reactRootContainer=i,e[sn]=i.current,eo(e.nodeType===8?e.parentNode:e),vr(),i}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var a=r;r=function(){var c=ra(l);a.call(c)}}var l=yd(e,0,!1,null,null,!1,!1,"",Th);return e._reactRootContainer=l,e[sn]=l.current,eo(e.nodeType===8?e.parentNode:e),vr(function(){Ra(t,l,n,r)}),l}function Da(e,t,n,r,s){var o=n._reactRootContainer;if(o){var i=o;if(typeof s=="function"){var a=s;s=function(){var l=ra(i);a.call(l)}}Ra(t,i,e,s)}else i=FS(n,t,e,s,r);return ra(i)}pg=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Rs(t.pendingLanes);n!==0&&(Fc(t,n|1),ot(t,ke()),!(X&6)&&(os=ke()+500,Gn()))}break;case 13:vr(function(){var r=on(e,1);if(r!==null){var s=Qe();Dt(r,e,1,s)}}),vd(e,1)}};zc=function(e){if(e.tag===13){var t=on(e,134217728);if(t!==null){var n=Qe();Dt(t,e,134217728,n)}vd(e,134217728)}};mg=function(e){if(e.tag===13){var t=_n(e),n=on(e,t);if(n!==null){var r=Qe();Dt(n,e,t,r)}vd(e,t)}};gg=function(){return te};yg=function(e,t){var n=te;try{return te=e,t()}finally{te=n}};gu=function(e,t,n){switch(t){case"input":if(uu(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var s=ka(r);if(!s)throw Error(M(90));Ym(r),uu(r,s)}}}break;case"textarea":Qm(e,n);break;case"select":t=n.value,t!=null&&Wr(e,!!n.multiple,t,!1)}};rg=hd;sg=vr;var zS={usingClientEntryPoint:!1,Events:[Eo,Lr,ka,tg,ng,hd]},bs={findFiberByHostInstance:sr,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},BS={bundleType:bs.bundleType,version:bs.version,rendererPackageName:bs.rendererPackageName,rendererConfig:bs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ln.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=ag(e),e===null?null:e.stateNode},findFiberByHostInstance:bs.findFiberByHostInstance||VS,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Zo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Zo.isDisabled&&Zo.supportsFiber)try{xa=Zo.inject(BS),Ht=Zo}catch{}}ft.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=zS;ft.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!wd(t))throw Error(M(200));return IS(e,t,null,n)};ft.createRoot=function(e,t){if(!wd(e))throw Error(M(299));var n=!1,r="",s=Fy;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=yd(e,1,!1,null,null,n,!1,r,s),e[sn]=t.current,eo(e.nodeType===8?e.parentNode:e),new xd(t)};ft.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(M(188)):(e=Object.keys(e).join(","),Error(M(268,e)));return e=ag(t),e=e===null?null:e.stateNode,e};ft.flushSync=function(e){return vr(e)};ft.hydrate=function(e,t,n){if(!Aa(t))throw Error(M(200));return Da(null,e,t,!0,n)};ft.hydrateRoot=function(e,t,n){if(!wd(e))throw Error(M(405));var r=n!=null&&n.hydratedSources||null,s=!1,o="",i=Fy;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(i=n.onRecoverableError)),t=Vy(t,null,e,1,n??null,s,!1,o,i),e[sn]=t.current,eo(e),r)for(e=0;e<r.length;e++)n=r[e],s=n._getVersion,s=s(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,s]:t.mutableSourceEagerHydrationData.push(n,s);return new Ma(t)};ft.render=function(e,t,n){if(!Aa(t))throw Error(M(200));return Da(null,e,t,!1,n)};ft.unmountComponentAtNode=function(e){if(!Aa(e))throw Error(M(40));return e._reactRootContainer?(vr(function(){Da(null,null,e,!1,function(){e._reactRootContainer=null,e[sn]=null})}),!0):!1};ft.unstable_batchedUpdates=hd;ft.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Aa(n))throw Error(M(200));if(e==null||e._reactInternals===void 0)throw Error(M(38));return Da(e,t,n,!1,r)};ft.version="18.3.1-next-f1338f8080-20240426";function zy(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(zy)}catch(e){console.error(e)}}zy(),zm.exports=ft;var Sd=zm.exports;const By=Nm(Sd);var Ph=Sd;nu.createRoot=Ph.createRoot,nu.hydrateRoot=Ph.hydrateRoot;const $S="modulepreload",US=function(e){return"/"+e},Nh={},bo=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const i=document.querySelector("meta[property=csp-nonce]"),a=(i==null?void 0:i.nonce)||(i==null?void 0:i.getAttribute("nonce"));s=Promise.allSettled(n.map(l=>{if(l=US(l),l in Nh)return;Nh[l]=!0;const c=l.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${d}`))return;const u=document.createElement("link");if(u.rel=c?"stylesheet":$S,c||(u.as="script"),u.crossOrigin="",u.href=l,a&&u.setAttribute("nonce",a),document.head.appendChild(u),c)return new Promise((f,y)=>{u.addEventListener("load",f),u.addEventListener("error",()=>y(new Error(`Unable to preload CSS for ${l}`)))})}))}function o(i){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=i,window.dispatchEvent(a),!a.defaultPrevented)throw i}return s.then(i=>{for(const a of i||[])a.status==="rejected"&&o(a.reason);return t().catch(o)})};/**
42
+ * @remix-run/router v1.23.2
43
+ *
44
+ * Copyright (c) Remix Software Inc.
45
+ *
46
+ * This source code is licensed under the MIT license found in the
47
+ * LICENSE.md file in the root directory of this source tree.
48
+ *
49
+ * @license MIT
50
+ */function uo(){return uo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},uo.apply(this,arguments)}var Pn;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Pn||(Pn={}));const jh="popstate";function WS(e){e===void 0&&(e={});function t(r,s){let{pathname:o,search:i,hash:a}=r.location;return Xu("",{pathname:o,search:i,hash:a},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:$y(s)}return GS(t,n,null,e)}function Te(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Ed(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function HS(){return Math.random().toString(36).substr(2,8)}function Rh(e,t){return{usr:e.state,key:e.key,idx:t}}function Xu(e,t,n,r){return n===void 0&&(n=null),uo({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?ds(t):t,{state:n,key:t&&t.key||r||HS()})}function $y(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function ds(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function GS(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:o=!1}=r,i=s.history,a=Pn.Pop,l=null,c=d();c==null&&(c=0,i.replaceState(uo({},i.state,{idx:c}),""));function d(){return(i.state||{idx:null}).idx}function u(){a=Pn.Pop;let S=d(),m=S==null?null:S-c;c=S,l&&l({action:a,location:x.location,delta:m})}function f(S,m){a=Pn.Push;let g=Xu(x.location,S,m);c=d()+1;let v=Rh(g,c),E=x.createHref(g);try{i.pushState(v,"",E)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;s.location.assign(E)}o&&l&&l({action:a,location:x.location,delta:1})}function y(S,m){a=Pn.Replace;let g=Xu(x.location,S,m);c=d();let v=Rh(g,c),E=x.createHref(g);i.replaceState(v,"",E),o&&l&&l({action:a,location:x.location,delta:0})}function w(S){let m=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof S=="string"?S:$y(S);return g=g.replace(/ $/,"%20"),Te(m,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,m)}let x={get action(){return a},get location(){return e(s,i)},listen(S){if(l)throw new Error("A history only accepts one active listener");return s.addEventListener(jh,u),l=S,()=>{s.removeEventListener(jh,u),l=null}},createHref(S){return t(s,S)},createURL:w,encodeLocation(S){let m=w(S);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:f,replace:y,go(S){return i.go(S)}};return x}var Mh;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Mh||(Mh={}));function KS(e,t,n){return n===void 0&&(n="/"),YS(e,t,n)}function YS(e,t,n,r){let s=typeof t=="string"?ds(t):t,o=Hy(s.pathname||"/",n);if(o==null)return null;let i=Uy(e);XS(i);let a=null;for(let l=0;a==null&&l<i.length;++l){let c=aE(o);a=sE(i[l],c)}return a}function Uy(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let s=(o,i,a)=>{let l={relativePath:a===void 0?o.path||"":a,caseSensitive:o.caseSensitive===!0,childrenIndex:i,route:o};l.relativePath.startsWith("/")&&(Te(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let c=dr([r,l.relativePath]),d=n.concat(l);o.children&&o.children.length>0&&(Te(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),Uy(o.children,t,d,c)),!(o.path==null&&!o.index)&&t.push({path:c,score:nE(c,o.index),routesMeta:d})};return e.forEach((o,i)=>{var a;if(o.path===""||!((a=o.path)!=null&&a.includes("?")))s(o,i);else for(let l of Wy(o.path))s(o,i,l)}),t}function Wy(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return s?[o,""]:[o];let i=Wy(r.join("/")),a=[];return a.push(...i.map(l=>l===""?o:[o,l].join("/"))),s&&a.push(...i),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function XS(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:rE(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const QS=/^:[\w-]+$/,ZS=3,qS=2,JS=1,eE=10,tE=-2,Ah=e=>e==="*";function nE(e,t){let n=e.split("/"),r=n.length;return n.some(Ah)&&(r+=tE),t&&(r+=qS),n.filter(s=>!Ah(s)).reduce((s,o)=>s+(QS.test(o)?ZS:o===""?JS:eE),r)}function rE(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function sE(e,t,n){let{routesMeta:r}=e,s={},o="/",i=[];for(let a=0;a<r.length;++a){let l=r[a],c=a===r.length-1,d=o==="/"?t:t.slice(o.length)||"/",u=oE({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},d),f=l.route;if(!u)return null;Object.assign(s,u.params),i.push({params:s,pathname:dr([o,u.pathname]),pathnameBase:fE(dr([o,u.pathnameBase])),route:f}),u.pathnameBase!=="/"&&(o=dr([o,u.pathnameBase]))}return i}function oE(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=iE(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let o=s[0],i=o.replace(/(.)\/+$/,"$1"),a=s.slice(1);return{params:r.reduce((c,d,u)=>{let{paramName:f,isOptional:y}=d;if(f==="*"){let x=a[u]||"";i=o.slice(0,o.length-x.length).replace(/(.)\/+$/,"$1")}const w=a[u];return y&&!w?c[f]=void 0:c[f]=(w||"").replace(/%2F/g,"/"),c},{}),pathname:o,pathnameBase:i,pattern:e}}function iE(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Ed(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function aE(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Ed(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Hy(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}const lE=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,uE=e=>lE.test(e);function cE(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?ds(e):e,o;if(n)if(uE(n))o=n;else{if(n.includes("//")){let i=n;n=n.replace(/\/\/+/g,"/"),Ed(!1,"Pathnames cannot have embedded double slashes - normalizing "+(i+" -> "+n))}n.startsWith("/")?o=Dh(n.substring(1),"/"):o=Dh(n,t)}else o=t;return{pathname:o,search:hE(r),hash:pE(s)}}function Dh(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Nl(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function dE(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Gy(e,t){let n=dE(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Ky(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=ds(e):(s=uo({},e),Te(!s.pathname||!s.pathname.includes("?"),Nl("?","pathname","search",s)),Te(!s.pathname||!s.pathname.includes("#"),Nl("#","pathname","hash",s)),Te(!s.search||!s.search.includes("#"),Nl("#","search","hash",s)));let o=e===""||s.pathname==="",i=o?"/":s.pathname,a;if(i==null)a=n;else{let u=t.length-1;if(!r&&i.startsWith("..")){let f=i.split("/");for(;f[0]==="..";)f.shift(),u-=1;s.pathname=f.join("/")}a=u>=0?t[u]:"/"}let l=cE(s,a),c=i&&i!=="/"&&i.endsWith("/"),d=(o||i===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(c||d)&&(l.pathname+="/"),l}const dr=e=>e.join("/").replace(/\/\/+/g,"/"),fE=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),hE=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,pE=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function mE(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Yy=["post","put","patch","delete"];new Set(Yy);const gE=["get",...Yy];new Set(gE);/**
51
+ * React Router v6.30.3
52
+ *
53
+ * Copyright (c) Remix Software Inc.
54
+ *
55
+ * This source code is licensed under the MIT license found in the
56
+ * LICENSE.md file in the root directory of this source tree.
57
+ *
58
+ * @license MIT
59
+ */function co(){return co=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},co.apply(this,arguments)}const kd=p.createContext(null),yE=p.createContext(null),Co=p.createContext(null),La=p.createContext(null),Kn=p.createContext({outlet:null,matches:[],isDataRoute:!1}),Xy=p.createContext(null);function To(){return p.useContext(La)!=null}function bd(){return To()||Te(!1),p.useContext(La).location}function Qy(e){p.useContext(Co).static||p.useLayoutEffect(e)}function Oa(){let{isDataRoute:e}=p.useContext(Kn);return e?RE():vE()}function vE(){To()||Te(!1);let e=p.useContext(kd),{basename:t,future:n,navigator:r}=p.useContext(Co),{matches:s}=p.useContext(Kn),{pathname:o}=bd(),i=JSON.stringify(Gy(s,n.v7_relativeSplatPath)),a=p.useRef(!1);return Qy(()=>{a.current=!0}),p.useCallback(function(c,d){if(d===void 0&&(d={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let u=Ky(c,JSON.parse(i),o,d.relative==="path");e==null&&t!=="/"&&(u.pathname=u.pathname==="/"?t:dr([t,u.pathname])),(d.replace?r.replace:r.push)(u,d.state,d)},[t,r,i,o,e])}function VM(){let{matches:e}=p.useContext(Kn),t=e[e.length-1];return t?t.params:{}}function xE(e,t){return wE(e,t)}function wE(e,t,n,r){To()||Te(!1);let{navigator:s}=p.useContext(Co),{matches:o}=p.useContext(Kn),i=o[o.length-1],a=i?i.params:{};i&&i.pathname;let l=i?i.pathnameBase:"/";i&&i.route;let c=bd(),d;if(t){var u;let S=typeof t=="string"?ds(t):t;l==="/"||(u=S.pathname)!=null&&u.startsWith(l)||Te(!1),d=S}else d=c;let f=d.pathname||"/",y=f;if(l!=="/"){let S=l.replace(/^\//,"").split("/");y="/"+f.replace(/^\//,"").split("/").slice(S.length).join("/")}let w=KS(e,{pathname:y}),x=CE(w&&w.map(S=>Object.assign({},S,{params:Object.assign({},a,S.params),pathname:dr([l,s.encodeLocation?s.encodeLocation(S.pathname).pathname:S.pathname]),pathnameBase:S.pathnameBase==="/"?l:dr([l,s.encodeLocation?s.encodeLocation(S.pathnameBase).pathname:S.pathnameBase])})),o,n,r);return t&&x?p.createElement(La.Provider,{value:{location:co({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:Pn.Pop}},x):x}function SE(){let e=jE(),t=mE(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return p.createElement(p.Fragment,null,p.createElement("h2",null,"Unexpected Application Error!"),p.createElement("h3",{style:{fontStyle:"italic"}},t),n?p.createElement("pre",{style:s},n):null,null)}const EE=p.createElement(SE,null);class kE extends p.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?p.createElement(Kn.Provider,{value:this.props.routeContext},p.createElement(Xy.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function bE(e){let{routeContext:t,match:n,children:r}=e,s=p.useContext(kd);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),p.createElement(Kn.Provider,{value:t},r)}function CE(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var o;if(!n)return null;if(n.errors)e=n.matches;else if((o=r)!=null&&o.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let i=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let d=i.findIndex(u=>u.route.id&&(a==null?void 0:a[u.route.id])!==void 0);d>=0||Te(!1),i=i.slice(0,Math.min(i.length,d+1))}let l=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d<i.length;d++){let u=i[d];if((u.route.HydrateFallback||u.route.hydrateFallbackElement)&&(c=d),u.route.id){let{loaderData:f,errors:y}=n,w=u.route.loader&&f[u.route.id]===void 0&&(!y||y[u.route.id]===void 0);if(u.route.lazy||w){l=!0,c>=0?i=i.slice(0,c+1):i=[i[0]];break}}}return i.reduceRight((d,u,f)=>{let y,w=!1,x=null,S=null;n&&(y=a&&u.route.id?a[u.route.id]:void 0,x=u.route.errorElement||EE,l&&(c<0&&f===0?(ME("route-fallback"),w=!0,S=null):c===f&&(w=!0,S=u.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,f+1)),g=()=>{let v;return y?v=x:w?v=S:u.route.Component?v=p.createElement(u.route.Component,null):u.route.element?v=u.route.element:v=d,p.createElement(bE,{match:u,routeContext:{outlet:d,matches:m,isDataRoute:n!=null},children:v})};return n&&(u.route.ErrorBoundary||u.route.errorElement||f===0)?p.createElement(kE,{location:n.location,revalidation:n.revalidation,component:x,error:y,children:g(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):g()},null)}var Zy=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Zy||{}),qy=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(qy||{});function TE(e){let t=p.useContext(kd);return t||Te(!1),t}function PE(e){let t=p.useContext(yE);return t||Te(!1),t}function NE(e){let t=p.useContext(Kn);return t||Te(!1),t}function Jy(e){let t=NE(),n=t.matches[t.matches.length-1];return n.route.id||Te(!1),n.route.id}function jE(){var e;let t=p.useContext(Xy),n=PE(),r=Jy();return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function RE(){let{router:e}=TE(Zy.UseNavigateStable),t=Jy(qy.UseNavigateStable),n=p.useRef(!1);return Qy(()=>{n.current=!0}),p.useCallback(function(s,o){o===void 0&&(o={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,co({fromRouteId:t},o)))},[e,t])}const Lh={};function ME(e,t,n){Lh[e]||(Lh[e]=!0)}function AE(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function ev(e){let{to:t,replace:n,state:r,relative:s}=e;To()||Te(!1);let{future:o,static:i}=p.useContext(Co),{matches:a}=p.useContext(Kn),{pathname:l}=bd(),c=Oa(),d=Ky(t,Gy(a,o.v7_relativeSplatPath),l,s==="path"),u=JSON.stringify(d);return p.useEffect(()=>c(JSON.parse(u),{replace:n,state:r,relative:s}),[c,u,s,n,r]),null}function yn(e){Te(!1)}function DE(e){let{basename:t="/",children:n=null,location:r,navigationType:s=Pn.Pop,navigator:o,static:i=!1,future:a}=e;To()&&Te(!1);let l=t.replace(/^\/*/,"/"),c=p.useMemo(()=>({basename:l,navigator:o,static:i,future:co({v7_relativeSplatPath:!1},a)}),[l,a,o,i]);typeof r=="string"&&(r=ds(r));let{pathname:d="/",search:u="",hash:f="",state:y=null,key:w="default"}=r,x=p.useMemo(()=>{let S=Hy(d,l);return S==null?null:{location:{pathname:S,search:u,hash:f,state:y,key:w},navigationType:s}},[l,d,u,f,y,w,s]);return x==null?null:p.createElement(Co.Provider,{value:c},p.createElement(La.Provider,{children:n,value:x}))}function LE(e){let{children:t,location:n}=e;return xE(Qu(t),n)}new Promise(()=>{});function Qu(e,t){t===void 0&&(t=[]);let n=[];return p.Children.forEach(e,(r,s)=>{if(!p.isValidElement(r))return;let o=[...t,s];if(r.type===p.Fragment){n.push.apply(n,Qu(r.props.children,o));return}r.type!==yn&&Te(!1),!r.props.index||!r.props.children||Te(!1);let i={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(i.children=Qu(r.props.children,o)),n.push(i)}),n}/**
60
+ * React Router DOM v6.30.3
61
+ *
62
+ * Copyright (c) Remix Software Inc.
63
+ *
64
+ * This source code is licensed under the MIT license found in the
65
+ * LICENSE.md file in the root directory of this source tree.
66
+ *
67
+ * @license MIT
68
+ */const OE="6";try{window.__reactRouterVersion=OE}catch{}const _E="startTransition",Oh=va[_E];function IE(e){let{basename:t,children:n,future:r,window:s}=e,o=p.useRef();o.current==null&&(o.current=WS({window:s,v5Compat:!0}));let i=o.current,[a,l]=p.useState({action:i.action,location:i.location}),{v7_startTransition:c}=r||{},d=p.useCallback(u=>{c&&Oh?Oh(()=>l(u)):l(u)},[l,c]);return p.useLayoutEffect(()=>i.listen(d),[i,d]),p.useEffect(()=>AE(r),[r]),p.createElement(DE,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:i,future:r})}var _h;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(_h||(_h={}));var Ih;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Ih||(Ih={}));const Cd=p.createContext({});function Td(e){const t=p.useRef(null);return t.current===null&&(t.current=e()),t.current}const VE=typeof window<"u",tv=VE?p.useLayoutEffect:p.useEffect,_a=p.createContext(null);function Pd(e,t){e.indexOf(t)===-1&&e.push(t)}function sa(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Yt=(e,t,n)=>n>t?t:n<e?e:n;let Nd=()=>{};const $n={},nv=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function rv(e){return typeof e=="object"&&e!==null}const sv=e=>/^0[^.\s]+$/u.test(e);function ov(e){let t;return()=>(t===void 0&&(t=e()),t)}const wt=e=>e,FE=(e,t)=>n=>t(e(n)),Po=(...e)=>e.reduce(FE),fo=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class jd{constructor(){this.subscriptions=[]}add(t){return Pd(this.subscriptions,t),()=>sa(this.subscriptions,t)}notify(t,n,r){const s=this.subscriptions.length;if(s)if(s===1)this.subscriptions[0](t,n,r);else for(let o=0;o<s;o++){const i=this.subscriptions[o];i&&i(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const ct=e=>e*1e3,vt=e=>e/1e3;function iv(e,t){return t?e*(1e3/t):0}const av=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,zE=1e-7,BE=12;function $E(e,t,n,r,s){let o,i,a=0;do i=t+(n-t)/2,o=av(i,r,s)-e,o>0?n=i:t=i;while(Math.abs(o)>zE&&++a<BE);return i}function No(e,t,n,r){if(e===t&&n===r)return wt;const s=o=>$E(o,0,1,e,n);return o=>o===0||o===1?o:av(s(o),t,r)}const lv=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,uv=e=>t=>1-e(1-t),cv=No(.33,1.53,.69,.99),Rd=uv(cv),dv=lv(Rd),fv=e=>e>=1?1:(e*=2)<1?.5*Rd(e):.5*(2-Math.pow(2,-10*(e-1))),Md=e=>1-Math.sin(Math.acos(e)),hv=uv(Md),pv=lv(Md),UE=No(.42,0,1,1),WE=No(0,0,.58,1),mv=No(.42,0,.58,1),HE=e=>Array.isArray(e)&&typeof e[0]!="number",gv=e=>Array.isArray(e)&&typeof e[0]=="number",GE={linear:wt,easeIn:UE,easeInOut:mv,easeOut:WE,circIn:Md,circInOut:pv,circOut:hv,backIn:Rd,backInOut:dv,backOut:cv,anticipate:fv},KE=e=>typeof e=="string",Vh=e=>{if(gv(e)){Nd(e.length===4);const[t,n,r,s]=e;return No(t,n,r,s)}else if(KE(e))return GE[e];return e},qo=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function YE(e,t){let n=new Set,r=new Set,s=!1,o=!1;const i=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(d){i.has(d)&&(c.schedule(d),e()),d(a)}const c={schedule:(d,u=!1,f=!1)=>{const w=f&&s?n:r;return u&&i.add(d),w.add(d),d},cancel:d=>{r.delete(d),i.delete(d)},process:d=>{if(a=d,s){o=!0;return}s=!0;const u=n;n=r,r=u,n.forEach(l),n.clear(),s=!1,o&&(o=!1,c.process(d))}};return c}const XE=40;function yv(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,i=qo.reduce((v,E)=>(v[E]=YE(o),v),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:d,update:u,preRender:f,render:y,postRender:w}=i,x=()=>{const v=$n.useManualTiming,E=v?s.timestamp:performance.now();n=!1,v||(s.delta=r?1e3/60:Math.max(Math.min(E-s.timestamp,XE),1)),s.timestamp=E,s.isProcessing=!0,a.process(s),l.process(s),c.process(s),d.process(s),u.process(s),f.process(s),y.process(s),w.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(x))},S=()=>{n=!0,r=!0,s.isProcessing||e(x)};return{schedule:qo.reduce((v,E)=>{const C=i[E];return v[E]=(T,k=!1,b=!1)=>(n||S(),C.schedule(T,k,b)),v},{}),cancel:v=>{for(let E=0;E<qo.length;E++)i[qo[E]].cancel(v)},state:s,steps:i}}const{schedule:oe,cancel:Un,state:_e,steps:jl}=yv(typeof requestAnimationFrame<"u"?requestAnimationFrame:wt,!0);let ki;function QE(){ki=void 0}const Ye={now:()=>(ki===void 0&&Ye.set(_e.isProcessing||$n.useManualTiming?_e.timestamp:performance.now()),ki),set:e=>{ki=e,queueMicrotask(QE)}},vv=e=>t=>typeof t=="string"&&t.startsWith(e),xv=vv("--"),ZE=vv("var(--"),Ad=e=>ZE(e)?qE.test(e.split("/*")[0].trim()):!1,qE=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Fh(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const fs={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ho={...fs,transform:e=>Yt(0,1,e)},Jo={...fs,default:1},$s=e=>Math.round(e*1e5)/1e5,Dd=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function JE(e){return e==null}const ek=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Ld=(e,t)=>n=>!!(typeof n=="string"&&ek.test(n)&&n.startsWith(e)||t&&!JE(n)&&Object.prototype.hasOwnProperty.call(n,t)),wv=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,o,i,a]=r.match(Dd);return{[e]:parseFloat(s),[t]:parseFloat(o),[n]:parseFloat(i),alpha:a!==void 0?parseFloat(a):1}},tk=e=>Yt(0,255,e),Rl={...fs,transform:e=>Math.round(tk(e))},ar={test:Ld("rgb","red"),parse:wv("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Rl.transform(e)+", "+Rl.transform(t)+", "+Rl.transform(n)+", "+$s(ho.transform(r))+")"};function nk(e){let t="",n="",r="",s="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),s=e.substring(4,5),t+=t,n+=n,r+=r,s+=s),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:s?parseInt(s,16)/255:1}}const Zu={test:Ld("#"),parse:nk,transform:ar.transform},jo=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),vn=jo("deg"),Kt=jo("%"),I=jo("px"),rk=jo("vh"),sk=jo("vw"),zh={...Kt,parse:e=>Kt.parse(e)/100,transform:e=>Kt.transform(e*100)},Br={test:Ld("hsl","hue"),parse:wv("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Kt.transform($s(t))+", "+Kt.transform($s(n))+", "+$s(ho.transform(r))+")"},be={test:e=>ar.test(e)||Zu.test(e)||Br.test(e),parse:e=>ar.test(e)?ar.parse(e):Br.test(e)?Br.parse(e):Zu.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?ar.transform(e):Br.transform(e),getAnimatableNone:e=>{const t=be.parse(e);return t.alpha=0,be.transform(t)}},ok=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ik(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Dd))==null?void 0:t.length)||0)+(((n=e.match(ok))==null?void 0:n.length)||0)>0}const Sv="number",Ev="color",ak="var",lk="var(",Bh="${}",uk=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function is(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let o=0;const a=t.replace(uk,l=>(be.test(l)?(r.color.push(o),s.push(Ev),n.push(be.parse(l))):l.startsWith(lk)?(r.var.push(o),s.push(ak),n.push(l)):(r.number.push(o),s.push(Sv),n.push(parseFloat(l))),++o,Bh)).split(Bh);return{values:n,split:a,indexes:r,types:s}}function ck(e){return is(e).values}function kv({split:e,types:t}){const n=e.length;return r=>{let s="";for(let o=0;o<n;o++)if(s+=e[o],r[o]!==void 0){const i=t[o];i===Sv?s+=$s(r[o]):i===Ev?s+=be.transform(r[o]):s+=r[o]}return s}}function dk(e){return kv(is(e))}const fk=e=>typeof e=="number"?0:be.test(e)?be.getAnimatableNone(e):e,hk=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:fk(e);function pk(e){const t=is(e);return kv(t)(t.values.map((r,s)=>hk(r,t.split[s])))}const Lt={test:ik,parse:ck,createTransformer:dk,getAnimatableNone:pk};function Ml(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function mk({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let s=0,o=0,i=0;if(!t)s=o=i=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;s=Ml(l,a,e+1/3),o=Ml(l,a,e),i=Ml(l,a,e-1/3)}return{red:Math.round(s*255),green:Math.round(o*255),blue:Math.round(i*255),alpha:r}}function oa(e,t){return n=>n>0?t:e}const fe=(e,t,n)=>e+(t-e)*n,Al=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},gk=[Zu,ar,Br],yk=e=>gk.find(t=>t.test(e));function $h(e){const t=yk(e);if(!t)return!1;let n=t.parse(e);return t===Br&&(n=mk(n)),n}const Uh=(e,t)=>{const n=$h(e),r=$h(t);if(!n||!r)return oa(e,t);const s={...n};return o=>(s.red=Al(n.red,r.red,o),s.green=Al(n.green,r.green,o),s.blue=Al(n.blue,r.blue,o),s.alpha=fe(n.alpha,r.alpha,o),ar.transform(s))},qu=new Set(["none","hidden"]);function vk(e,t){return qu.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function xk(e,t){return n=>fe(e,t,n)}function Od(e){return typeof e=="number"?xk:typeof e=="string"?Ad(e)?oa:be.test(e)?Uh:Ek:Array.isArray(e)?bv:typeof e=="object"?be.test(e)?Uh:wk:oa}function bv(e,t){const n=[...e],r=n.length,s=e.map((o,i)=>Od(o)(o,t[i]));return o=>{for(let i=0;i<r;i++)n[i]=s[i](o);return n}}function wk(e,t){const n={...e,...t},r={};for(const s in n)e[s]!==void 0&&t[s]!==void 0&&(r[s]=Od(e[s])(e[s],t[s]));return s=>{for(const o in r)n[o]=r[o](s);return n}}function Sk(e,t){const n=[],r={color:0,var:0,number:0};for(let s=0;s<t.values.length;s++){const o=t.types[s],i=e.indexes[o][r[o]],a=e.values[i]??0;n[s]=a,r[o]++}return n}const Ek=(e,t)=>{const n=Lt.createTransformer(t),r=is(e),s=is(t);return r.indexes.var.length===s.indexes.var.length&&r.indexes.color.length===s.indexes.color.length&&r.indexes.number.length>=s.indexes.number.length?qu.has(e)&&!s.values.length||qu.has(t)&&!r.values.length?vk(e,t):Po(bv(Sk(r,s),s.values),n):oa(e,t)};function Cv(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?fe(e,t,n):Od(e)(e,t)}const kk=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>oe.update(t,n),stop:()=>Un(t),now:()=>_e.isProcessing?_e.timestamp:Ye.now()}},Tv=(e,t,n=10)=>{let r="";const s=Math.max(Math.round(t/n),2);for(let o=0;o<s;o++)r+=Math.round(e(o/(s-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},ia=2e4;function _d(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<ia;)t+=n,r=e.next(t);return t>=ia?1/0:t}function bk(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(_d(r),ia);return{type:"keyframes",ease:o=>r.next(s*o).value/t,duration:vt(s)}}const Se={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function Ju(e,t){return e*Math.sqrt(1-t*t)}const Ck=12;function Tk(e,t,n){let r=n;for(let s=1;s<Ck;s++)r=r-e(r)/t(r);return r}const Dl=.001;function Pk({duration:e=Se.duration,bounce:t=Se.bounce,velocity:n=Se.velocity,mass:r=Se.mass}){let s,o,i=1-t;i=Yt(Se.minDamping,Se.maxDamping,i),e=Yt(Se.minDuration,Se.maxDuration,vt(e)),i<1?(s=c=>{const d=c*i,u=d*e,f=d-n,y=Ju(c,i),w=Math.exp(-u);return Dl-f/y*w},o=c=>{const u=c*i*e,f=u*n+n,y=Math.pow(i,2)*Math.pow(c,2)*e,w=Math.exp(-u),x=Ju(Math.pow(c,2),i);return(-s(c)+Dl>0?-1:1)*((f-y)*w)/x}):(s=c=>{const d=Math.exp(-c*e),u=(c-n)*e+1;return-Dl+d*u},o=c=>{const d=Math.exp(-c*e),u=(n-c)*(e*e);return d*u});const a=5/e,l=Tk(s,o,a);if(e=ct(e),isNaN(l))return{stiffness:Se.stiffness,damping:Se.damping,duration:e};{const c=Math.pow(l,2)*r;return{stiffness:c,damping:i*2*Math.sqrt(r*c),duration:e}}}const Nk=["duration","bounce"],jk=["stiffness","damping","mass"];function Wh(e,t){return t.some(n=>e[n]!==void 0)}function Rk(e){let t={velocity:Se.velocity,stiffness:Se.stiffness,damping:Se.damping,mass:Se.mass,isResolvedFromDuration:!1,...e};if(!Wh(e,jk)&&Wh(e,Nk))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),s=r*r,o=2*Yt(.05,1,1-(e.bounce||0))*Math.sqrt(s);t={...t,mass:Se.mass,stiffness:s,damping:o}}else{const n=Pk({...e,velocity:0});t={...t,...n,mass:Se.mass},t.isResolvedFromDuration=!0}return t}function aa(e=Se.visualDuration,t=Se.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:s}=n;const o=n.keyframes[0],i=n.keyframes[n.keyframes.length-1],a={done:!1,value:o},{stiffness:l,damping:c,mass:d,duration:u,velocity:f,isResolvedFromDuration:y}=Rk({...n,velocity:-vt(n.velocity||0)}),w=f||0,x=c/(2*Math.sqrt(l*d)),S=i-o,m=vt(Math.sqrt(l/d)),g=Math.abs(S)<5;r||(r=g?Se.restSpeed.granular:Se.restSpeed.default),s||(s=g?Se.restDelta.granular:Se.restDelta.default);let v,E,C,T,k,b;if(x<1)C=Ju(m,x),T=(w+x*m*S)/C,v=P=>{const D=Math.exp(-x*m*P);return i-D*(T*Math.sin(C*P)+S*Math.cos(C*P))},k=x*m*T+S*C,b=x*m*S-T*C,E=P=>Math.exp(-x*m*P)*(k*Math.sin(C*P)+b*Math.cos(C*P));else if(x===1){v=D=>i-Math.exp(-m*D)*(S+(w+m*S)*D);const P=w+m*S;E=D=>Math.exp(-m*D)*(m*P*D-w)}else{const P=m*Math.sqrt(x*x-1);v=le=>{const ge=Math.exp(-x*m*le),z=Math.min(P*le,300);return i-ge*((w+x*m*S)*Math.sinh(z)+P*S*Math.cosh(z))/P};const D=(w+x*m*S)/P,L=x*m*D-S*P,Q=x*m*S-D*P;E=le=>{const ge=Math.exp(-x*m*le),z=Math.min(P*le,300);return ge*(L*Math.sinh(z)+Q*Math.cosh(z))}}const A={calculatedDuration:y&&u||null,velocity:P=>ct(E(P)),next:P=>{if(!y&&x<1){const L=Math.exp(-x*m*P),Q=Math.sin(C*P),le=Math.cos(C*P),ge=i-L*(T*Q+S*le),z=ct(L*(k*Q+b*le));return a.done=Math.abs(z)<=r&&Math.abs(i-ge)<=s,a.value=a.done?i:ge,a}const D=v(P);if(y)a.done=P>=u;else{const L=ct(E(P));a.done=Math.abs(L)<=r&&Math.abs(i-D)<=s}return a.value=a.done?i:D,a},toString:()=>{const P=Math.min(_d(A),ia),D=Tv(L=>A.next(P*L).value,P,30);return P+"ms "+D},toTransition:()=>{}};return A}aa.applyToOptions=e=>{const t=bk(e,100,aa);return e.ease=t.ease,e.duration=ct(t.duration),e.type="keyframes",e};const Mk=5;function Pv(e,t,n){const r=Math.max(t-Mk,0);return iv(n-e(r),t-r)}function ec({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:s=10,bounceStiffness:o=500,modifyTarget:i,min:a,max:l,restDelta:c=.5,restSpeed:d}){const u=e[0],f={done:!1,value:u},y=b=>a!==void 0&&b<a||l!==void 0&&b>l,w=b=>a===void 0?l:l===void 0||Math.abs(a-b)<Math.abs(l-b)?a:l;let x=n*t;const S=u+x,m=i===void 0?S:i(S);m!==S&&(x=m-u);const g=b=>-x*Math.exp(-b/r),v=b=>m+g(b),E=b=>{const A=g(b),P=v(b);f.done=Math.abs(A)<=c,f.value=f.done?m:P};let C,T;const k=b=>{y(f.value)&&(C=b,T=aa({keyframes:[f.value,w(f.value)],velocity:Pv(v,b,f.value),damping:s,stiffness:o,restDelta:c,restSpeed:d}))};return k(0),{calculatedDuration:null,next:b=>{let A=!1;return!T&&C===void 0&&(A=!0,E(b),k(b)),C!==void 0&&b>=C?T.next(b-C):(!A&&E(b),f)}}}function Ak(e,t,n){const r=[],s=n||$n.mix||Cv,o=e.length-1;for(let i=0;i<o;i++){let a=s(e[i],e[i+1]);if(t){const l=Array.isArray(t)?t[i]||wt:t;a=Po(l,a)}r.push(a)}return r}function Dk(e,t,{clamp:n=!0,ease:r,mixer:s}={}){const o=e.length;if(Nd(o===t.length),o===1)return()=>t[0];if(o===2&&t[0]===t[1])return()=>t[1];const i=e[0]===e[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=Ak(t,r,s),l=a.length,c=d=>{if(i&&d<e[0])return t[0];let u=0;if(l>1)for(;u<e.length-2&&!(d<e[u+1]);u++);const f=fo(e[u],e[u+1],d);return a[u](f)};return n?d=>c(Yt(e[0],e[o-1],d)):c}function Lk(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=fo(0,t,r);e.push(fe(n,1,s))}}function Ok(e){const t=[0];return Lk(t,e.length-1),t}function _k(e,t){return e.map(n=>n*t)}function Ik(e,t){return e.map(()=>t||mv).splice(0,e.length-1)}function Us({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=HE(r)?r.map(Vh):Vh(r),o={done:!1,value:t[0]},i=_k(n&&n.length===t.length?n:Ok(t),e),a=Dk(i,t,{ease:Array.isArray(s)?s:Ik(t,s)});return{calculatedDuration:e,next:l=>(o.value=a(l),o.done=l>=e,o)}}const Vk=e=>e!==null;function Ia(e,{repeat:t,repeatType:n="loop"},r,s=1){const o=e.filter(Vk),a=s<0||t&&n!=="loop"&&t%2===1?0:o.length-1;return!a||r===void 0?o[a]:r}const Fk={decay:ec,inertia:ec,tween:Us,keyframes:Us,spring:aa};function Nv(e){typeof e.type=="string"&&(e.type=Fk[e.type])}class Id{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const zk=e=>e/100;class la extends Id{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==Ye.now()&&this.tick(Ye.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(s=(r=this.options).onStop)==null||s.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Nv(t);const{type:n=Us,repeat:r=0,repeatDelay:s=0,repeatType:o,velocity:i=0}=t;let{keyframes:a}=t;const l=n||Us;l!==Us&&typeof a[0]!="number"&&(this.mixKeyframes=Po(zk,Cv(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});o==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-i})),c.calculatedDuration===null&&(c.calculatedDuration=_d(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+s,this.totalDuration=this.resolvedDuration*(r+1)-s,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:s,mixKeyframes:o,mirroredGenerator:i,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:c=0,keyframes:d,repeat:u,repeatType:f,repeatDelay:y,type:w,onUpdate:x,finalKeyframe:S}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-s/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-c*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?m<0:m>s;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,E=r;if(u){const b=Math.min(this.currentTime,s)/a;let A=Math.floor(b),P=b%1;!P&&b>=1&&(P=1),P===1&&A--,A=Math.min(A,u+1),!!(A%2)&&(f==="reverse"?(P=1-P,y&&(P-=y/a)):f==="mirror"&&(E=i)),v=Yt(0,1,P)*a}let C;g?(this.delayState.value=d[0],C=this.delayState):C=E.next(v),o&&!g&&(C.value=o(C.value));let{done:T}=C;!g&&l!==null&&(T=this.playbackSpeed>=0?this.currentTime>=s:this.currentTime<=0);const k=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&T);return k&&w!==ec&&(C.value=Ia(d,this.options,S,this.speed)),x&&x(C.value),k&&this.finish(),C}then(t,n){return this.finished.then(t,n)}get duration(){return vt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+vt(t)}get time(){return vt(this.currentTime)}set time(t){t=ct(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return Pv(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(Ye.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=vt(this.currentTime))}play(){var s,o;if(this.isStopped)return;const{driver:t=kk,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),(o=(s=this.options).onPlay)==null||o.call(s);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Ye.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function Bk(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const lr=e=>e*180/Math.PI,tc=e=>{const t=lr(Math.atan2(e[1],e[0]));return nc(t)},$k={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:tc,rotateZ:tc,skewX:e=>lr(Math.atan(e[1])),skewY:e=>lr(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},nc=e=>(e=e%360,e<0&&(e+=360),e),Hh=tc,Gh=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Kh=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Uk={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Gh,scaleY:Kh,scale:e=>(Gh(e)+Kh(e))/2,rotateX:e=>nc(lr(Math.atan2(e[6],e[5]))),rotateY:e=>nc(lr(Math.atan2(-e[2],e[0]))),rotateZ:Hh,rotate:Hh,skewX:e=>lr(Math.atan(e[4])),skewY:e=>lr(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function rc(e){return e.includes("scale")?1:0}function sc(e,t){if(!e||e==="none")return rc(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=Uk,s=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=$k,s=a}if(!s)return rc(t);const o=r[t],i=s[1].split(",").map(Hk);return typeof o=="function"?o(i):i[o]}const Wk=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return sc(n,t)};function Hk(e){return parseFloat(e.trim())}const hs=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ps=new Set(hs),Yh=e=>e===fs||e===I,Gk=new Set(["x","y","z"]),Kk=hs.filter(e=>!Gk.has(e));function Yk(e){const t=[];return Kk.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Nn={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>sc(t,"x"),y:(e,{transform:t})=>sc(t,"y")};Nn.translateX=Nn.x;Nn.translateY=Nn.y;const fr=new Set;let oc=!1,ic=!1,ac=!1;function jv(){if(ic){const e=Array.from(fr).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=Yk(r);s.length&&(n.set(r,s),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const s=n.get(r);s&&s.forEach(([o,i])=>{var a;(a=r.getValue(o))==null||a.set(i)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}ic=!1,oc=!1,fr.forEach(e=>e.complete(ac)),fr.clear()}function Rv(){fr.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(ic=!0)})}function Xk(){ac=!0,Rv(),jv(),ac=!1}class Vd{constructor(t,n,r,s,o,i=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=s,this.element=o,this.isAsync=i}scheduleResolve(){this.state="scheduled",this.isAsync?(fr.add(this),oc||(oc=!0,oe.read(Rv),oe.resolveKeyframes(jv))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:s}=this;if(t[0]===null){const o=s==null?void 0:s.get(),i=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const a=r.readValue(n,i);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=i),s&&o===void 0&&s.set(t[0])}Bk(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),fr.delete(this)}cancel(){this.state==="scheduled"&&(fr.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Qk=e=>e.startsWith("--");function Mv(e,t,n){Qk(t)?e.style.setProperty(t,n):e.style[t]=n}const Zk={};function Av(e,t){const n=ov(e);return()=>Zk[t]??n()}const qk=Av(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),Dv=Av(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),As=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Xh={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:As([0,.65,.55,1]),circOut:As([.55,0,1,.45]),backIn:As([.31,.01,.66,-.59]),backOut:As([.33,1.53,.69,.99])};function Lv(e,t){if(e)return typeof e=="function"?Dv()?Tv(e,t):"ease-out":gv(e)?As(e):Array.isArray(e)?e.map(n=>Lv(n,t)||Xh.easeOut):Xh[e]}function Jk(e,t,n,{delay:r=0,duration:s=300,repeat:o=0,repeatType:i="loop",ease:a="easeOut",times:l}={},c=void 0){const d={[t]:n};l&&(d.offset=l);const u=Lv(a,s);Array.isArray(u)&&(d.easing=u);const f={delay:r,duration:s,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:o+1,direction:i==="reverse"?"alternate":"normal"};return c&&(f.pseudoElement=c),e.animate(d,f)}function Ov(e){return typeof e=="function"&&"applyToOptions"in e}function eb({type:e,...t}){return Ov(e)&&Dv()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class _v extends Id{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:s,pseudoElement:o,allowFlatten:i=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!o,this.allowFlatten=i,this.options=t,Nd(typeof t.type!="string");const c=eb(t);this.animation=Jk(n,r,s,c,o),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const d=Ia(s,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(d),Mv(n,r,d),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,s;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((s=(r=this.animation).commitStyles)==null||s.call(r))}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return vt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+vt(t)}get time(){return vt(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=ct(t),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:s}){var o;return this.allowFlatten&&((o=this.animation.effect)==null||o.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&qk()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),wt):s(this)}}const Iv={anticipate:fv,backInOut:dv,circInOut:pv};function tb(e){return e in Iv}function nb(e){typeof e.ease=="string"&&tb(e.ease)&&(e.ease=Iv[e.ease])}const Ll=10;class rb extends _v{constructor(t){nb(t),Nv(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:s,element:o,...i}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new la({...i,autoplay:!1}),l=Math.max(Ll,Ye.now()-this.startTime),c=Yt(0,Ll,l-Ll),d=a.sample(l).value,{name:u}=this.options;o&&u&&Mv(o,u,d),n.setWithVelocity(a.sample(Math.max(0,l-c)).value,d,c),a.stop()}}const Qh=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Lt.test(e)||e==="0")&&!e.startsWith("url("));function sb(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function ob(e,t,n,r){const s=e[0];if(s===null)return!1;if(t==="display"||t==="visibility")return!0;const o=e[e.length-1],i=Qh(s,t),a=Qh(o,t);return!i||!a?!1:sb(e)||(n==="spring"||Ov(n))&&r}function lc(e){e.duration=0,e.type="keyframes"}const Vv=new Set(["opacity","clipPath","filter","transform"]),ib=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function ab(e){for(let t=0;t<e.length;t++)if(typeof e[t]=="string"&&ib.test(e[t]))return!0;return!1}const lb=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),ub=ov(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function cb(e){var u;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:o,type:i,keyframes:a}=e;if(!(((u=t==null?void 0:t.owner)==null?void 0:u.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:d}=t.owner.getProps();return ub()&&n&&(Vv.has(n)||lb.has(n)&&ab(a))&&(n!=="transform"||!d)&&!c&&!r&&s!=="mirror"&&o!==0&&i!=="inertia"}const db=40;class fb extends Id{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:o=0,repeatType:i="loop",keyframes:a,name:l,motionValue:c,element:d,...u}){var w;super(),this.stop=()=>{var x,S;this._animation&&(this._animation.stop(),(x=this.stopTimeline)==null||x.call(this)),(S=this.keyframeResolver)==null||S.cancel()},this.createdAt=Ye.now();const f={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:o,repeatType:i,name:l,motionValue:c,element:d,...u},y=(d==null?void 0:d.KeyframeResolver)||Vd;this.keyframeResolver=new y(a,(x,S,m)=>this.onKeyframesResolved(x,S,f,!m),l,c,d),(w=this.keyframeResolver)==null||w.scheduleResolve()}onKeyframesResolved(t,n,r,s){var m,g;this.keyframeResolver=void 0;const{name:o,type:i,velocity:a,delay:l,isHandoff:c,onUpdate:d}=r;this.resolvedAt=Ye.now();let u=!0;ob(t,o,i,a)||(u=!1,($n.instantAnimations||!l)&&(d==null||d(Ia(t,r,n))),t[0]=t[t.length-1],lc(r),r.repeat=0);const y={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>db?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},w=u&&!c&&cb(y),x=(g=(m=y.motionValue)==null?void 0:m.owner)==null?void 0:g.current;let S;if(w)try{S=new rb({...y,element:x})}catch{S=new la(y)}else S=new la(y);S.finished.then(()=>{this.notifyFinished()}).catch(wt),this.pendingTimeline&&(this.stopTimeline=S.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=S}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),Xk()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}function Fv(e,t,n,r=0,s=1){const o=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),i=e.size,a=(i-1)*r;return typeof n=="function"?n(o,i):s===1?o*r:a-o*r}const hb=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function pb(e){const t=hb.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}function zv(e,t,n=1){const[r,s]=pb(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const i=o.trim();return nv(i)?parseFloat(i):i}return Ad(s)?zv(s,t,n+1):s}const mb={type:"spring",stiffness:500,damping:25,restSpeed:10},gb=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),yb={type:"keyframes",duration:.8},vb={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},xb=(e,{keyframes:t})=>t.length>2?yb:ps.has(e)?e.startsWith("scale")?gb(t[1]):mb:vb;function Bv(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function Fd(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?Bv(n,e):n}const wb=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function Sb(e){for(const t in e)if(!wb.has(t))return!0;return!1}const zd=(e,t,n,r={},s,o)=>i=>{const a=Fd(r,e)||{},l=a.delay||r.delay||0;let{elapsed:c=0}=r;c=c-ct(l);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{i(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:o?void 0:s};Sb(a)||Object.assign(d,xb(e,d)),d.duration&&(d.duration=ct(d.duration)),d.repeatDelay&&(d.repeatDelay=ct(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let u=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(lc(d),d.delay===0&&(u=!0)),($n.instantAnimations||$n.skipAnimations||s!=null&&s.shouldSkipAnimations)&&(u=!0,lc(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,u&&!o&&t.get()!==void 0){const f=Ia(d.keyframes,a);if(f!==void 0){oe.update(()=>{d.onUpdate(f),d.onComplete()});return}}return a.isSync?new la(d):new fb(d)};function Zh(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Bd(e,t,n,r){if(typeof t=="function"){const[s,o]=Zh(r);t=t(n!==void 0?n:e.custom,s,o)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[s,o]=Zh(r);t=t(n!==void 0?n:e.custom,s,o)}return t}function hr(e,t,n){const r=e.getProps();return Bd(r,t,n!==void 0?n:r.custom,e)}const $v=new Set(["width","height","top","left","right","bottom",...hs]),qh=30,Eb=e=>!isNaN(parseFloat(e));class kb{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var o;const s=Ye.now();if(this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ye.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=Eb(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new jd);const r=this.events[t].add(n);return t==="change"?()=>{r(),oe.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Ye.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>qh)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,qh);return iv(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function as(e,t){return new kb(e,t)}const uc=e=>Array.isArray(e);function bb(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,as(n))}function Cb(e){return uc(e)?e[e.length-1]||0:e}function Tb(e,t){const n=hr(e,t);let{transitionEnd:r={},transition:s={},...o}=n||{};o={...o,...r};for(const i in o){const a=Cb(o[i]);bb(e,i,a)}}const Ie=e=>!!(e&&e.getVelocity);function Pb(e){return!!(Ie(e)&&e.add)}function cc(e,t){const n=e.getValue("willChange");if(Pb(n))return n.add(t);if(!n&&$n.WillChange){const r=new $n.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function $d(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const Nb="framerAppearId",Uv="data-"+$d(Nb);function Wv(e){return e.props[Uv]}function jb({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function Hv(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:o,transitionEnd:i,...a}=t;const l=e.getDefaultTransition();o=o?Bv(o,l):l;const c=o==null?void 0:o.reduceMotion;r&&(o=r);const d=[],u=s&&e.animationState&&e.animationState.getState()[s];for(const f in a){const y=e.getValue(f,e.latestValues[f]??null),w=a[f];if(w===void 0||u&&jb(u,f))continue;const x={delay:n,...Fd(o||{},f)},S=y.get();if(S!==void 0&&!y.isAnimating()&&!Array.isArray(w)&&w===S&&!x.velocity){oe.update(()=>y.set(w));continue}let m=!1;if(window.MotionHandoffAnimation){const E=Wv(e);if(E){const C=window.MotionHandoffAnimation(E,f,oe);C!==null&&(x.startTime=C,m=!0)}}cc(e,f);const g=c??e.shouldReduceMotion;y.start(zd(f,y,w,g&&$v.has(f)?{type:!1}:x,e,m));const v=y.animation;v&&d.push(v)}if(i){const f=()=>oe.update(()=>{i&&Tb(e,i)});d.length?Promise.all(d).then(f):f()}return d}function dc(e,t,n={}){var l;const r=hr(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const o=r?()=>Promise.all(Hv(e,r,n)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:d=0,staggerChildren:u,staggerDirection:f}=s;return Rb(e,t,c,d,u,f,n)}:()=>Promise.resolve(),{when:a}=s;if(a){const[c,d]=a==="beforeChildren"?[o,i]:[i,o];return c().then(()=>d())}else return Promise.all([o(),i(n.delay)])}function Rb(e,t,n=0,r=0,s=0,o=1,i){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(dc(l,t,{...i,delay:n+(typeof r=="function"?0:r)+Fv(e.variantChildren,l,r,s,o)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function Mb(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(o=>dc(e,o,n));r=Promise.all(s)}else if(typeof t=="string")r=dc(e,t,n);else{const s=typeof t=="function"?hr(e,t,n.custom):t;r=Promise.all(Hv(e,s,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const Ab={test:e=>e==="auto",parse:e=>e},Gv=e=>t=>t.test(e),Kv=[fs,I,Kt,vn,sk,rk,Ab],Jh=e=>Kv.find(Gv(e));function Db(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||sv(e):!0}const Lb=new Set(["brightness","contrast","saturate","opacity"]);function Ob(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Dd)||[];if(!r)return e;const s=n.replace(r,"");let o=Lb.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+s+")"}const _b=/\b([a-z-]*)\(.*?\)/gu,fc={...Lt,getAnimatableNone:e=>{const t=e.match(_b);return t?t.map(Ob).join(" "):e}},hc={...Lt,getAnimatableNone:e=>{const t=Lt.parse(e);return Lt.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},ep={...fs,transform:Math.round},Ib={rotate:vn,rotateX:vn,rotateY:vn,rotateZ:vn,scale:Jo,scaleX:Jo,scaleY:Jo,scaleZ:Jo,skew:vn,skewX:vn,skewY:vn,distance:I,translateX:I,translateY:I,translateZ:I,x:I,y:I,z:I,perspective:I,transformPerspective:I,opacity:ho,originX:zh,originY:zh,originZ:I},Ud={borderWidth:I,borderTopWidth:I,borderRightWidth:I,borderBottomWidth:I,borderLeftWidth:I,borderRadius:I,borderTopLeftRadius:I,borderTopRightRadius:I,borderBottomRightRadius:I,borderBottomLeftRadius:I,width:I,maxWidth:I,height:I,maxHeight:I,top:I,right:I,bottom:I,left:I,inset:I,insetBlock:I,insetBlockStart:I,insetBlockEnd:I,insetInline:I,insetInlineStart:I,insetInlineEnd:I,padding:I,paddingTop:I,paddingRight:I,paddingBottom:I,paddingLeft:I,paddingBlock:I,paddingBlockStart:I,paddingBlockEnd:I,paddingInline:I,paddingInlineStart:I,paddingInlineEnd:I,margin:I,marginTop:I,marginRight:I,marginBottom:I,marginLeft:I,marginBlock:I,marginBlockStart:I,marginBlockEnd:I,marginInline:I,marginInlineStart:I,marginInlineEnd:I,fontSize:I,backgroundPositionX:I,backgroundPositionY:I,...Ib,zIndex:ep,fillOpacity:ho,strokeOpacity:ho,numOctaves:ep},Vb={...Ud,color:be,backgroundColor:be,outlineColor:be,fill:be,stroke:be,borderColor:be,borderTopColor:be,borderRightColor:be,borderBottomColor:be,borderLeftColor:be,filter:fc,WebkitFilter:fc,mask:hc,WebkitMask:hc},Yv=e=>Vb[e],Fb=new Set([fc,hc]);function Xv(e,t){let n=Yv(e);return Fb.has(n)||(n=Lt),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const zb=new Set(["auto","none","0"]);function Bb(e,t,n){let r=0,s;for(;r<e.length&&!s;){const o=e[r];typeof o=="string"&&!zb.has(o)&&is(o).values.length&&(s=e[r]),r++}if(s&&n)for(const o of t)e[o]=Xv(n,s)}class $b extends Vd{constructor(t,n,r,s,o){super(t,n,r,s,o,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let u=t[d];if(typeof u=="string"&&(u=u.trim(),Ad(u))){const f=zv(u,n.current);f!==void 0&&(t[d]=f),d===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!$v.has(r)||t.length!==2)return;const[s,o]=t,i=Jh(s),a=Jh(o),l=Fh(s),c=Fh(o);if(l!==c&&Nn[r]){this.needsMeasurement=!0;return}if(i!==a)if(Yh(i)&&Yh(a))for(let d=0;d<t.length;d++){const u=t[d];typeof u=="string"&&(t[d]=parseFloat(u))}else Nn[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let s=0;s<t.length;s++)(t[s]===null||Db(t[s]))&&r.push(s);r.length&&Bb(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Nn[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const s=n[n.length-1];s!==void 0&&t.getValue(r,s).jump(s,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const s=t.getValue(n);s&&s.jump(this.measuredOrigin,!1);const o=r.length-1,i=r[o];r[o]=Nn[n](t.measureViewportBox(),window.getComputedStyle(t.current)),i!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=i),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([l,c])=>{t.getValue(l).set(c)}),this.resolveNoneKeyframes()}}function Qv(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const s=(n==null?void 0:n[e])??r.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e).filter(r=>r!=null)}const Zv=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function bi(e){return rv(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:Wd}=yv(queueMicrotask,!1),Nt={x:!1,y:!1};function qv(){return Nt.x||Nt.y}function Ub(e){return e==="x"||e==="y"?Nt[e]?null:(Nt[e]=!0,()=>{Nt[e]=!1}):Nt.x||Nt.y?null:(Nt.x=Nt.y=!0,()=>{Nt.x=Nt.y=!1})}function Jv(e,t){const n=Qv(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function Wb(e){return!(e.pointerType==="touch"||qv())}function Hb(e,t,n={}){const[r,s,o]=Jv(e,n);return r.forEach(i=>{let a=!1,l=!1,c;const d=()=>{i.removeEventListener("pointerleave",w)},u=S=>{c&&(c(S),c=void 0),d()},f=S=>{a=!1,window.removeEventListener("pointerup",f),window.removeEventListener("pointercancel",f),l&&(l=!1,u(S))},y=()=>{a=!0,window.addEventListener("pointerup",f,s),window.addEventListener("pointercancel",f,s)},w=S=>{if(S.pointerType!=="touch"){if(a){l=!0;return}u(S)}},x=S=>{if(!Wb(S))return;l=!1;const m=t(i,S);typeof m=="function"&&(c=m,i.addEventListener("pointerleave",w,s))};i.addEventListener("pointerenter",x,s),i.addEventListener("pointerdown",y,s)}),o}const e0=(e,t)=>t?e===t?!0:e0(e,t.parentElement):!1,Hd=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Gb=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Kb(e){return Gb.has(e.tagName)||e.isContentEditable===!0}const Yb=new Set(["INPUT","SELECT","TEXTAREA"]);function Xb(e){return Yb.has(e.tagName)||e.isContentEditable===!0}const Ci=new WeakSet;function tp(e){return t=>{t.key==="Enter"&&e(t)}}function Ol(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Qb=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=tp(()=>{if(Ci.has(n))return;Ol(n,"down");const s=tp(()=>{Ol(n,"up")}),o=()=>Ol(n,"cancel");n.addEventListener("keyup",s,t),n.addEventListener("blur",o,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function np(e){return Hd(e)&&!qv()}const rp=new WeakSet;function Zb(e,t,n={}){const[r,s,o]=Jv(e,n),i=a=>{const l=a.currentTarget;if(!np(a)||rp.has(a))return;Ci.add(l),n.stopPropagation&&rp.add(a);const c=t(l,a),d=(y,w)=>{window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",f),Ci.has(l)&&Ci.delete(l),np(y)&&typeof c=="function"&&c(y,{success:w})},u=y=>{d(y,l===window||l===document||n.useGlobalTarget||e0(l,y.target))},f=y=>{d(y,!1)};window.addEventListener("pointerup",u,s),window.addEventListener("pointercancel",f,s)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",i,s),bi(a)&&(a.addEventListener("focus",c=>Qb(c,s)),!Kb(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),o}function Gd(e){return rv(e)&&"ownerSVGElement"in e}const Ti=new WeakMap;let xn;const t0=(e,t,n)=>(r,s)=>s&&s[0]?s[0][e+"Size"]:Gd(r)&&"getBBox"in r?r.getBBox()[t]:r[n],qb=t0("inline","width","offsetWidth"),Jb=t0("block","height","offsetHeight");function eC({target:e,borderBoxSize:t}){var n;(n=Ti.get(e))==null||n.forEach(r=>{r(e,{get width(){return qb(e,t)},get height(){return Jb(e,t)}})})}function tC(e){e.forEach(eC)}function nC(){typeof ResizeObserver>"u"||(xn=new ResizeObserver(tC))}function rC(e,t){xn||nC();const n=Qv(e);return n.forEach(r=>{let s=Ti.get(r);s||(s=new Set,Ti.set(r,s)),s.add(t),xn==null||xn.observe(r)}),()=>{n.forEach(r=>{const s=Ti.get(r);s==null||s.delete(t),s!=null&&s.size||xn==null||xn.unobserve(r)})}}const Pi=new Set;let $r;function sC(){$r=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};Pi.forEach(t=>t(e))},window.addEventListener("resize",$r)}function oC(e){return Pi.add(e),$r||sC(),()=>{Pi.delete(e),!Pi.size&&typeof $r=="function"&&(window.removeEventListener("resize",$r),$r=void 0)}}function sp(e,t){return typeof e=="function"?oC(e):rC(e,t)}function iC(e){return Gd(e)&&e.tagName==="svg"}const aC=[...Kv,be,Lt],lC=e=>aC.find(Gv(e)),op=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ur=()=>({x:op(),y:op()}),ip=()=>({min:0,max:0}),Ne=()=>({x:ip(),y:ip()}),uC=new WeakMap;function Va(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function po(e){return typeof e=="string"||Array.isArray(e)}const Kd=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Yd=["initial",...Kd];function Fa(e){return Va(e.animate)||Yd.some(t=>po(e[t]))}function n0(e){return!!(Fa(e)||e.variants)}function cC(e,t,n){for(const r in t){const s=t[r],o=n[r];if(Ie(s))e.addValue(r,s);else if(Ie(o))e.addValue(r,as(s,{owner:e}));else if(o!==s)if(e.hasValue(r)){const i=e.getValue(r);i.liveStyle===!0?i.jump(s):i.hasAnimated||i.set(s)}else{const i=e.getStaticValue(r);e.addValue(r,as(i!==void 0?i:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const pc={current:null},r0={current:!1},dC=typeof window<"u";function fC(){if(r0.current=!0,!!dC)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>pc.current=e.matches;e.addEventListener("change",t),t()}else pc.current=!1}const ap=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let ua={};function s0(e){ua=e}function hC(){return ua}class pC{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,skipAnimations:o,blockInitialAnimation:i,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=Vd,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const y=Ye.now();this.renderScheduledAt<y&&(this.renderScheduledAt=y,oe.render(this.render,!1,!0))};const{latestValues:c,renderState:d}=a;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=d,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.skipAnimationsConfig=o,this.options=l,this.blockInitialAnimation=!!i,this.isControllingVariants=Fa(n),this.isVariantNode=n0(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:u,...f}=this.scrapeMotionValuesFromProps(n,{},this);for(const y in f){const w=f[y];c[y]!==void 0&&Ie(w)&&w.set(c[y])}}mount(t){var n,r;if(this.hasBeenMounted)for(const s in this.initialValues)(n=this.values.get(s))==null||n.jump(this.initialValues[s]),this.latestValues[s]=this.initialValues[s];this.current=t,uC.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((s,o)=>this.bindToMotionValue(o,s)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(r0.current||fC(),this.shouldReduceMotion=pc.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),Un(this.notifyUpdate),Un(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&Vv.has(t)&&this.current instanceof HTMLElement){const{factory:i,keyframes:a,times:l,ease:c,duration:d}=n.accelerate,u=new _v({element:this.current,name:t,keyframes:a,times:l,ease:c,duration:ct(d)}),f=i(u);this.valueSubscriptions.set(t,()=>{f(),u.cancel()});return}const r=ps.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&oe.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;typeof window<"u"&&window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{s(),o&&o(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in ua){const n=ua[t];if(!n)continue;const{isEnabled:r,Feature:s}=n;if(!this.features[t]&&s&&r(this.props)&&(this.features[t]=new s(this)),this.features[t]){const o=this.features[t];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ne()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<ap.length;r++){const s=ap[r];this.propEventSubscriptions[s]&&(this.propEventSubscriptions[s](),delete this.propEventSubscriptions[s]);const o="on"+s,i=t[o];i&&(this.propEventSubscriptions[s]=this.on(s,i))}this.prevMotionValues=cC(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=as(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(nv(r)||sv(r))?r=parseFloat(r):!lC(r)&&Lt.test(n)&&(r=Xv(t,n)),this.setBaseTarget(t,Ie(r)?r.get():r)),Ie(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var o;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const i=Bd(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);i&&(r=i[t])}if(n&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!Ie(s)?s:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new jd),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Wd.render(this.render)}}class o0 extends pC{constructor(){super(...arguments),this.KeyframeResolver=$b}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Yn{constructor(t){this.isMounted=!1,this.node=t}update(){}}function i0({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function mC({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function gC(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function _l(e){return e===void 0||e===1}function mc({scale:e,scaleX:t,scaleY:n}){return!_l(e)||!_l(t)||!_l(n)}function nr(e){return mc(e)||a0(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function a0(e){return lp(e.x)||lp(e.y)}function lp(e){return e&&e!=="0%"}function ca(e,t,n){const r=e-n,s=t*r;return n+s}function up(e,t,n,r,s){return s!==void 0&&(e=ca(e,s,r)),ca(e,n,r)+t}function gc(e,t=0,n=1,r,s){e.min=up(e.min,t,n,r,s),e.max=up(e.max,t,n,r,s)}function l0(e,{x:t,y:n}){gc(e.x,t.translate,t.scale,t.originPoint),gc(e.y,n.translate,n.scale,n.originPoint)}const cp=.999999999999,dp=1.0000000000001;function yC(e,t,n,r=!1){var a;const s=n.length;if(!s)return;t.x=t.y=1;let o,i;for(let l=0;l<s;l++){o=n[l],i=o.projectionDelta;const{visualElement:c}=o.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&($t(e.x,-o.scroll.offset.x),$t(e.y,-o.scroll.offset.y)),i&&(t.x*=i.x.scale,t.y*=i.y.scale,l0(e,i)),r&&nr(o.latestValues)&&Ni(e,o.latestValues,(a=o.layout)==null?void 0:a.layoutBox))}t.x<dp&&t.x>cp&&(t.x=1),t.y<dp&&t.y>cp&&(t.y=1)}function $t(e,t){e.min+=t,e.max+=t}function fp(e,t,n,r,s=.5){const o=fe(e.min,e.max,s);gc(e,t,n,o,r)}function hp(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function Ni(e,t,n){const r=n??e;fp(e.x,hp(t.x,r.x),t.scaleX,t.scale,t.originX),fp(e.y,hp(t.y,r.y),t.scaleY,t.scale,t.originY)}function u0(e,t){return i0(gC(e.getBoundingClientRect(),t))}function vC(e,t,n){const r=u0(e,n),{scroll:s}=t;return s&&($t(r.x,s.offset.x),$t(r.y,s.offset.y)),r}const xC={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},wC=hs.length;function SC(e,t,n){let r="",s=!0;for(let o=0;o<wC;o++){const i=hs[o],a=e[i];if(a===void 0)continue;let l=!0;if(typeof a=="number")l=a===(i.startsWith("scale")?1:0);else{const c=parseFloat(a);l=i.startsWith("scale")?c===1:c===0}if(!l||n){const c=Zv(a,Ud[i]);if(!l){s=!1;const d=xC[i]||i;r+=`${d}(${c}) `}n&&(t[i]=c)}}return r=r.trim(),n?r=n(t,s?"":r):s&&(r="none"),r}function Xd(e,t,n){const{style:r,vars:s,transformOrigin:o}=e;let i=!1,a=!1;for(const l in t){const c=t[l];if(ps.has(l)){i=!0;continue}else if(xv(l)){s[l]=c;continue}else{const d=Zv(c,Ud[l]);l.startsWith("origin")?(a=!0,o[l]=d):r[l]=d}}if(t.transform||(i||n?r.transform=SC(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:d=0}=o;r.transformOrigin=`${l} ${c} ${d}`}}function c0(e,{style:t,vars:n},r,s){const o=e.style;let i;for(i in t)o[i]=t[i];s==null||s.applyProjectionStyles(o,r);for(i in n)o.setProperty(i,n[i])}function pp(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Cs={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(I.test(e))e=parseFloat(e);else return e;const n=pp(e,t.target.x),r=pp(e,t.target.y);return`${n}% ${r}%`}},EC={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=Lt.parse(e);if(s.length>5)return r;const o=Lt.createTransformer(e),i=typeof s[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;s[0+i]/=a,s[1+i]/=l;const c=fe(a,l,.5);return typeof s[2+i]=="number"&&(s[2+i]/=c),typeof s[3+i]=="number"&&(s[3+i]/=c),o(s)}},yc={borderRadius:{...Cs,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Cs,borderTopRightRadius:Cs,borderBottomLeftRadius:Cs,borderBottomRightRadius:Cs,boxShadow:EC};function d0(e,{layout:t,layoutId:n}){return ps.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!yc[e]||e==="opacity")}function Qd(e,t,n){var i;const r=e.style,s=t==null?void 0:t.style,o={};if(!r)return o;for(const a in r)(Ie(r[a])||s&&Ie(s[a])||d0(a,e)||((i=n==null?void 0:n.getValue(a))==null?void 0:i.liveStyle)!==void 0)&&(o[a]=r[a]);return o}function kC(e){return window.getComputedStyle(e)}class bC extends o0{constructor(){super(...arguments),this.type="html",this.renderInstance=c0}readValueFromInstance(t,n){var r;if(ps.has(n))return(r=this.projection)!=null&&r.isProjecting?rc(n):Wk(t,n);{const s=kC(t),o=(xv(n)?s.getPropertyValue(n):s[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return u0(t,n)}build(t,n,r){Xd(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Qd(t,n,r)}}const CC={offset:"stroke-dashoffset",array:"stroke-dasharray"},TC={offset:"strokeDashoffset",array:"strokeDasharray"};function PC(e,t,n=1,r=0,s=!0){e.pathLength=1;const o=s?CC:TC;e[o.offset]=`${-r}`,e[o.array]=`${t} ${n}`}const NC=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function f0(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:o=1,pathOffset:i=0,...a},l,c,d){if(Xd(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:u,style:f}=e;u.transform&&(f.transform=u.transform,delete u.transform),(f.transform||u.transformOrigin)&&(f.transformOrigin=u.transformOrigin??"50% 50%",delete u.transformOrigin),f.transform&&(f.transformBox=(d==null?void 0:d.transformBox)??"fill-box",delete u.transformBox);for(const y of NC)u[y]!==void 0&&(f[y]=u[y],delete u[y]);t!==void 0&&(u.x=t),n!==void 0&&(u.y=n),r!==void 0&&(u.scale=r),s!==void 0&&PC(u,s,o,i,!1)}const h0=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),p0=e=>typeof e=="string"&&e.toLowerCase()==="svg";function jC(e,t,n,r){c0(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(h0.has(s)?s:$d(s),t.attrs[s])}function m0(e,t,n){const r=Qd(e,t,n);for(const s in e)if(Ie(e[s])||Ie(t[s])){const o=hs.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[o]=e[s]}return r}class RC extends o0{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ne}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(ps.has(n)){const r=Yv(n);return r&&r.default||0}return n=h0.has(n)?n:$d(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return m0(t,n,r)}build(t,n,r){f0(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){jC(t,n,r,s)}mount(t){this.isSVGTag=p0(t.tagName),super.mount(t)}}const MC=Yd.length;function g0(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?g0(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<MC;n++){const r=Yd[n],s=e.props[r];(po(s)||s===!1)&&(t[r]=s)}return t}function y0(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const AC=[...Kd].reverse(),DC=Kd.length;function LC(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Mb(e,n,r)))}function OC(e){let t=LC(e),n=mp(),r=!0,s=!1;const o=c=>(d,u)=>{var y;const f=hr(e,u,c==="exit"?(y=e.presenceContext)==null?void 0:y.custom:void 0);if(f){const{transition:w,transitionEnd:x,...S}=f;d={...d,...S,...x}}return d};function i(c){t=c(e)}function a(c){const{props:d}=e,u=g0(e.parent)||{},f=[],y=new Set;let w={},x=1/0;for(let m=0;m<DC;m++){const g=AC[m],v=n[g],E=d[g]!==void 0?d[g]:u[g],C=po(E),T=g===c?v.isActive:null;T===!1&&(x=m);let k=E===u[g]&&E!==d[g]&&C;if(k&&(r||s)&&e.manuallyAnimateOnMount&&(k=!1),v.protectedKeys={...w},!v.isActive&&T===null||!E&&!v.prevProp||Va(E)||typeof E=="boolean")continue;if(g==="exit"&&v.isActive&&T!==!0){v.prevResolvedValues&&(w={...w,...v.prevResolvedValues});continue}const b=_C(v.prevProp,E);let A=b||g===c&&v.isActive&&!k&&C||m>x&&C,P=!1;const D=Array.isArray(E)?E:[E];let L=D.reduce(o(g),{});T===!1&&(L={});const{prevResolvedValues:Q={}}=v,le={...Q,...L},ge=j=>{A=!0,y.has(j)&&(P=!0,y.delete(j)),v.needsAnimating[j]=!0;const O=e.getValue(j);O&&(O.liveStyle=!1)};for(const j in le){const O=L[j],V=Q[j];if(w.hasOwnProperty(j))continue;let $=!1;uc(O)&&uc(V)?$=!y0(O,V):$=O!==V,$?O!=null?ge(j):y.add(j):O!==void 0&&y.has(j)?ge(j):v.protectedKeys[j]=!0}v.prevProp=E,v.prevResolvedValues=L,v.isActive&&(w={...w,...L}),(r||s)&&e.blockInitialAnimation&&(A=!1);const z=k&&b;A&&(!z||P)&&f.push(...D.map(j=>{const O={type:g};if(typeof j=="string"&&(r||s)&&!z&&e.manuallyAnimateOnMount&&e.parent){const{parent:V}=e,$=hr(V,j);if(V.enteringChildren&&$){const{delayChildren:se}=$.transition||{};O.delay=Fv(V.enteringChildren,e,se)}}return{animation:j,options:O}}))}if(y.size){const m={};if(typeof d.initial!="boolean"){const g=hr(e,Array.isArray(d.initial)?d.initial[0]:d.initial);g&&g.transition&&(m.transition=g.transition)}y.forEach(g=>{const v=e.getBaseTarget(g),E=e.getValue(g);E&&(E.liveStyle=!0),m[g]=v??null}),f.push({animation:m})}let S=!!f.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(S=!1),r=!1,s=!1,S?t(f):Promise.resolve()}function l(c,d){var f;if(n[c].isActive===d)return Promise.resolve();(f=e.variantChildren)==null||f.forEach(y=>{var w;return(w=y.animationState)==null?void 0:w.setActive(c,d)}),n[c].isActive=d;const u=a(c);for(const y in n)n[y].protectedKeys={};return u}return{animateChanges:a,setActive:l,setAnimateFunction:i,getState:()=>n,reset:()=>{n=mp(),s=!0}}}function _C(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!y0(t,e):!1}function Jn(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function mp(){return{animate:Jn(!0),whileInView:Jn(),whileHover:Jn(),whileTap:Jn(),whileDrag:Jn(),whileFocus:Jn(),exit:Jn()}}function vc(e,t){e.min=t.min,e.max=t.max}function Pt(e,t){vc(e.x,t.x),vc(e.y,t.y)}function gp(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const v0=1e-4,IC=1-v0,VC=1+v0,x0=.01,FC=0-x0,zC=0+x0;function Xe(e){return e.max-e.min}function BC(e,t,n){return Math.abs(e-t)<=n}function yp(e,t,n,r=.5){e.origin=r,e.originPoint=fe(t.min,t.max,e.origin),e.scale=Xe(n)/Xe(t),e.translate=fe(n.min,n.max,e.origin)-e.originPoint,(e.scale>=IC&&e.scale<=VC||isNaN(e.scale))&&(e.scale=1),(e.translate>=FC&&e.translate<=zC||isNaN(e.translate))&&(e.translate=0)}function Ws(e,t,n,r){yp(e.x,t.x,n.x,r?r.originX:void 0),yp(e.y,t.y,n.y,r?r.originY:void 0)}function vp(e,t,n,r=0){const s=r?fe(n.min,n.max,r):n.min;e.min=s+t.min,e.max=e.min+Xe(t)}function $C(e,t,n,r){vp(e.x,t.x,n.x,r==null?void 0:r.x),vp(e.y,t.y,n.y,r==null?void 0:r.y)}function xp(e,t,n,r=0){const s=r?fe(n.min,n.max,r):n.min;e.min=t.min-s,e.max=e.min+Xe(t)}function da(e,t,n,r){xp(e.x,t.x,n.x,r==null?void 0:r.x),xp(e.y,t.y,n.y,r==null?void 0:r.y)}function wp(e,t,n,r,s){return e-=t,e=ca(e,1/n,r),s!==void 0&&(e=ca(e,1/s,r)),e}function UC(e,t=0,n=1,r=.5,s,o=e,i=e){if(Kt.test(t)&&(t=parseFloat(t),t=fe(i.min,i.max,t/100)-i.min),typeof t!="number")return;let a=fe(o.min,o.max,r);e===o&&(a-=t),e.min=wp(e.min,t,n,a,s),e.max=wp(e.max,t,n,a,s)}function Sp(e,t,[n,r,s],o,i){UC(e,t[n],t[r],t[s],t.scale,o,i)}const WC=["x","scaleX","originX"],HC=["y","scaleY","originY"];function Ep(e,t,n,r){Sp(e.x,t,WC,n?n.x:void 0,r?r.x:void 0),Sp(e.y,t,HC,n?n.y:void 0,r?r.y:void 0)}function kp(e){return e.translate===0&&e.scale===1}function w0(e){return kp(e.x)&&kp(e.y)}function bp(e,t){return e.min===t.min&&e.max===t.max}function GC(e,t){return bp(e.x,t.x)&&bp(e.y,t.y)}function Cp(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function S0(e,t){return Cp(e.x,t.x)&&Cp(e.y,t.y)}function Tp(e){return Xe(e.x)/Xe(e.y)}function Pp(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Bt(e){return[e("x"),e("y")]}function KC(e,t,n){let r="";const s=e.x.translate/t.x,o=e.y.translate/t.y,i=(n==null?void 0:n.z)||0;if((s||o||i)&&(r=`translate3d(${s}px, ${o}px, ${i}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,rotateX:u,rotateY:f,skewX:y,skewY:w}=n;c&&(r=`perspective(${c}px) ${r}`),d&&(r+=`rotate(${d}deg) `),u&&(r+=`rotateX(${u}deg) `),f&&(r+=`rotateY(${f}deg) `),y&&(r+=`skewX(${y}deg) `),w&&(r+=`skewY(${w}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const E0=["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"],YC=E0.length,Np=e=>typeof e=="string"?parseFloat(e):e,jp=e=>typeof e=="number"||I.test(e);function XC(e,t,n,r,s,o){s?(e.opacity=fe(0,n.opacity??1,QC(r)),e.opacityExit=fe(t.opacity??1,0,ZC(r))):o&&(e.opacity=fe(t.opacity??1,n.opacity??1,r));for(let i=0;i<YC;i++){const a=E0[i];let l=Rp(t,a),c=Rp(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||jp(l)===jp(c)?(e[a]=Math.max(fe(Np(l),Np(c),r),0),(Kt.test(c)||Kt.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=fe(t.rotate||0,n.rotate||0,r))}function Rp(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const QC=k0(0,.5,hv),ZC=k0(.5,.95,wt);function k0(e,t,n){return r=>r<e?0:r>t?1:n(fo(e,t,r))}function qC(e,t,n){const r=Ie(e)?e:as(e);return r.start(zd("",r,t,n)),r.animation}function mo(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const JC=(e,t)=>e.depth-t.depth;class e2{constructor(){this.children=[],this.isDirty=!1}add(t){Pd(this.children,t),this.isDirty=!0}remove(t){sa(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(JC),this.isDirty=!1,this.children.forEach(t)}}function t2(e,t){const n=Ye.now(),r=({timestamp:s})=>{const o=s-n;o>=t&&(Un(r),e(o-t))};return oe.setup(r,!0),()=>Un(r)}function ji(e){return Ie(e)?e.get():e}class n2{constructor(){this.members=[]}add(t){Pd(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const s=r.instance;(!s||s.isConnected===!1)&&!r.snapshot&&(sa(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(sa(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1&&((n=s.instance)==null?void 0:n.isConnected)!==!1)return this.promote(s),!0}return!1}promote(t,n){var s;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:o}=r.options,{layoutDependency:i}=t.options;(o===void 0||o!==i)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(s=t.root)!=null&&s.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,s,o,i;(r=(n=t.options).onExitComplete)==null||r.call(n),(i=(s=t.resumingFrom)==null?void 0:(o=s.options).onExitComplete)==null||i.call(o)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const Ri={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Il=["","X","Y","Z"],r2=1e3;let s2=0;function Vl(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function b0(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Wv(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",oe,!(s||o))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&b0(r)}function C0({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(i={},a=t==null?void 0:t()){this.id=s2++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(a2),this.nodes.forEach(h2),this.nodes.forEach(p2),this.nodes.forEach(l2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=i,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new e2)}addEventListener(i,a){return this.eventHandlers.has(i)||this.eventHandlers.set(i,new jd),this.eventHandlers.get(i).add(a)}notifyListeners(i,...a){const l=this.eventHandlers.get(i);l&&l.notify(...a)}hasListeners(i){return this.eventHandlers.has(i)}mount(i){if(this.instance)return;this.isSVG=Gd(i)&&!iC(i),this.instance=i;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(i),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let d,u=0;const f=()=>this.root.updateBlockedByResize=!1;oe.read(()=>{u=window.innerWidth}),e(i,()=>{const y=window.innerWidth;y!==u&&(u=y,this.root.updateBlockedByResize=!0,d&&d(),d=t2(f,250),Ri.hasAnimatedSinceResize&&(Ri.hasAnimatedSinceResize=!1,this.nodes.forEach(Dp)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:u,hasRelativeLayoutChanged:f,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||c.getDefaultTransition()||x2,{onLayoutAnimationStart:x,onLayoutAnimationComplete:S}=c.getProps(),m=!this.targetLayout||!S0(this.targetLayout,y),g=!u&&f;if(this.options.layoutRoot||this.resumeFrom||g||u&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={...Fd(w,"layout"),onPlay:x,onComplete:S};(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(d,g)}else u||Dp(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const i=this.getStack();i&&i.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Un(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(m2),this.animationId++)}getTransformTemplate(){const{visualElement:i}=this.options;return i&&i.getProps().transformTemplate}willUpdate(i=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&b0(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const u=this.path[d];u.shouldResetTransform=!0,(typeof u.latestValues.x=="string"||typeof u.latestValues.y=="string")&&(u.isLayoutDirty=!0),u.updateScroll("snapshot"),u.options.layoutRoot&&u.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),i&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){const l=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),l&&this.nodes.forEach(c2),this.nodes.forEach(Mp);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Ap);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(d2),this.nodes.forEach(f2),this.nodes.forEach(o2),this.nodes.forEach(i2)):this.nodes.forEach(Ap),this.clearAllSnapshots();const a=Ye.now();_e.delta=Yt(0,1e3/60,a-_e.timestamp),_e.timestamp=a,_e.isProcessing=!0,jl.update.process(_e),jl.preRender.process(_e),jl.render.process(_e),_e.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Wd.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(u2),this.sharedNodes.forEach(g2)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,oe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){oe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Xe(this.snapshot.measuredBox.x)&&!Xe(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const i=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||(this.layoutCorrected=Ne()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,i?i.layoutBox:void 0)}updateScroll(i="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===i&&(a=!1),a&&this.instance){const l=r(this.instance);this.scroll={animationId:this.root.animationId,phase:i,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!s)return;const i=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!w0(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,d=c!==this.prevTransformTemplateValue;i&&this.instance&&(a||nr(this.latestValues)||d)&&(s(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(i=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return i&&(l=this.removeTransform(l)),w2(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var c;const{visualElement:i}=this.options;if(!i)return Ne();const a=i.measureViewportBox();if(!(((c=this.scroll)==null?void 0:c.wasRoot)||this.path.some(S2))){const{scroll:d}=this.root;d&&($t(a.x,d.offset.x),$t(a.y,d.offset.y))}return a}removeElementScroll(i){var l;const a=Ne();if(Pt(a,i),(l=this.scroll)!=null&&l.wasRoot)return a;for(let c=0;c<this.path.length;c++){const d=this.path[c],{scroll:u,options:f}=d;d!==this.root&&u&&f.layoutScroll&&(u.wasRoot&&Pt(a,i),$t(a.x,u.offset.x),$t(a.y,u.offset.y))}return a}applyTransform(i,a=!1,l){var d,u;const c=l||Ne();Pt(c,i);for(let f=0;f<this.path.length;f++){const y=this.path[f];!a&&y.options.layoutScroll&&y.scroll&&y!==y.root&&($t(c.x,-y.scroll.offset.x),$t(c.y,-y.scroll.offset.y)),nr(y.latestValues)&&Ni(c,y.latestValues,(d=y.layout)==null?void 0:d.layoutBox)}return nr(this.latestValues)&&Ni(c,this.latestValues,(u=this.layout)==null?void 0:u.layoutBox),c}removeTransform(i){var l;const a=Ne();Pt(a,i);for(let c=0;c<this.path.length;c++){const d=this.path[c];if(!nr(d.latestValues))continue;let u;d.instance&&(mc(d.latestValues)&&d.updateSnapshot(),u=Ne(),Pt(u,d.measurePageBox())),Ep(a,d.latestValues,(l=d.snapshot)==null?void 0:l.layoutBox,u)}return nr(this.latestValues)&&Ep(a,this.latestValues),a}setTargetDelta(i){this.targetDelta=i,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(i){this.options={...this.options,...i,crossfade:i.crossfade!==void 0?i.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==_e.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(i=!1){var y;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(i||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(y=this.parent)!=null&&y.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:u}=this.options;if(!this.layout||!(d||u))return;this.resolvedRelativeTargetAt=_e.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Ne(),this.targetWithTransforms=Ne()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),$C(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):Pt(this.target,this.layout.layoutBox),l0(this.target,this.targetDelta)):Pt(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||mc(this.parent.latestValues)||a0(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(i,a,l){this.relativeParent=i,this.linkedParentVersion=i.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ne(),this.relativeTargetOrigin=Ne(),da(this.relativeTargetOrigin,a,l,this.options.layoutAnchor||void 0),Pt(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var w;const i=this.getLead(),a=!!this.resumingFrom||this!==i;let l=!0;if((this.isProjectionDirty||(w=this.parent)!=null&&w.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===_e.timestamp&&(l=!1),l)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;Pt(this.layoutCorrected,this.layout.layoutBox);const u=this.treeScale.x,f=this.treeScale.y;yC(this.layoutCorrected,this.treeScale,this.path,a),i.layout&&!i.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(i.target=i.layout.layoutBox,i.targetWithTransforms=Ne());const{target:y}=i;if(!y){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(gp(this.prevProjectionDelta.x,this.projectionDelta.x),gp(this.prevProjectionDelta.y,this.projectionDelta.y)),Ws(this.projectionDelta,this.layoutCorrected,y,this.latestValues),(this.treeScale.x!==u||this.treeScale.y!==f||!Pp(this.projectionDelta.x,this.prevProjectionDelta.x)||!Pp(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",y))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(i=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),i){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ur(),this.projectionDelta=Ur(),this.projectionDeltaWithTransform=Ur()}setAnimationOrigin(i,a=!1){const l=this.snapshot,c=l?l.latestValues:{},d={...this.latestValues},u=Ur();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const f=Ne(),y=l?l.source:void 0,w=this.layout?this.layout.source:void 0,x=y!==w,S=this.getStack(),m=!S||S.members.length<=1,g=!!(x&&!m&&this.options.crossfade===!0&&!this.path.some(v2));this.animationProgress=0;let v;this.mixTargetDelta=E=>{const C=E/1e3;Lp(u.x,i.x,C),Lp(u.y,i.y,C),this.setTargetDelta(u),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(da(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),y2(this.relativeTarget,this.relativeTargetOrigin,f,C),v&&GC(this.relativeTarget,v)&&(this.isProjectionDirty=!1),v||(v=Ne()),Pt(v,this.relativeTarget)),x&&(this.animationValues=d,XC(d,c,this.latestValues,C,g,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=C},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(i){var a,l,c;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(c=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||c.stop(),this.pendingAnimation&&(Un(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=oe.update(()=>{Ri.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=as(0)),this.motionValue.jump(0,!1),this.currentAnimation=qC(this.motionValue,[0,1e3],{...i,velocity:0,isSync:!0,onUpdate:d=>{this.mixTargetDelta(d),i.onUpdate&&i.onUpdate(d)},onStop:()=>{},onComplete:()=>{i.onComplete&&i.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const i=this.getStack();i&&i.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(r2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const i=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:d}=i;if(!(!a||!l||!c)){if(this!==i&&this.layout&&c&&T0(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||Ne();const u=Xe(this.layout.layoutBox.x);l.x.min=i.target.x.min,l.x.max=l.x.min+u;const f=Xe(this.layout.layoutBox.y);l.y.min=i.target.y.min,l.y.max=l.y.min+f}Pt(a,l),Ni(a,d),Ws(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(i,a){this.sharedNodes.has(i)||this.sharedNodes.set(i,new n2),this.sharedNodes.get(i).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const i=this.getStack();return i?i.lead===this:!0}getLead(){var a;const{layoutId:i}=this.options;return i?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:i}=this.options;return i?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:i}=this.options;if(i)return this.root.sharedNodes.get(i)}promote({needsReset:i,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),i&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const i=this.getStack();return i?i.relegate(this):!1}resetSkewAndRotation(){const{visualElement:i}=this.options;if(!i)return;let a=!1;const{latestValues:l}=i;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&Vl("z",i,c,this.animationValues);for(let d=0;d<Il.length;d++)Vl(`rotate${Il[d]}`,i,c,this.animationValues),Vl(`skew${Il[d]}`,i,c,this.animationValues);i.render();for(const d in c)i.setStaticValue(d,c[d]),this.animationValues&&(this.animationValues[d]=c[d]);i.scheduleRender()}applyProjectionStyles(i,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){i.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,i.visibility="",i.opacity="",i.pointerEvents=ji(a==null?void 0:a.pointerEvents)||"",i.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(i.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,i.pointerEvents=ji(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!nr(this.latestValues)&&(i.transform=l?l({},""):"none",this.hasProjected=!1);return}i.visibility="";const d=c.animationValues||c.latestValues;this.applyTransformsToTarget();let u=KC(this.projectionDeltaWithTransform,this.treeScale,d);l&&(u=l(d,u)),i.transform=u;const{x:f,y}=this.projectionDelta;i.transformOrigin=`${f.origin*100}% ${y.origin*100}% 0`,c.animationValues?i.opacity=c===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:i.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const w in yc){if(d[w]===void 0)continue;const{correct:x,applyTo:S,isCSSVariable:m}=yc[w],g=u==="none"?d[w]:x(d[w],c);if(S){const v=S.length;for(let E=0;E<v;E++)i[S[E]]=g}else m?this.options.visualElement.renderState.vars[w]=g:i[w]=g}this.options.layoutId&&(i.pointerEvents=c===this?ji(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(i=>{var a;return(a=i.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Mp),this.root.sharedNodes.clear()}}}function o2(e){e.updateLayout()}function i2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:s}=e.layout,{animationType:o}=e.options,i=t.source!==e.layout.source;if(o==="size")Bt(u=>{const f=i?t.measuredBox[u]:t.layoutBox[u],y=Xe(f);f.min=r[u].min,f.max=f.min+y});else if(o==="x"||o==="y"){const u=o==="x"?"y":"x";vc(i?t.measuredBox[u]:t.layoutBox[u],r[u])}else T0(o,t.layoutBox,r)&&Bt(u=>{const f=i?t.measuredBox[u]:t.layoutBox[u],y=Xe(r[u]);f.max=f.min+y,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[u].max=e.relativeTarget[u].min+y)});const a=Ur();Ws(a,r,t.layoutBox);const l=Ur();i?Ws(l,e.applyTransform(s,!0),t.measuredBox):Ws(l,r,t.layoutBox);const c=!w0(a);let d=!1;if(!e.resumeFrom){const u=e.getClosestProjectingParent();if(u&&!u.resumeFrom){const{snapshot:f,layout:y}=u;if(f&&y){const w=e.options.layoutAnchor||void 0,x=Ne();da(x,t.layoutBox,f.layoutBox,w);const S=Ne();da(S,r,y.layoutBox,w),S0(x,S)||(d=!0),u.options.layoutRoot&&(e.relativeTarget=S,e.relativeTargetOrigin=x,e.relativeParent=u)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function a2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function l2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function u2(e){e.clearSnapshot()}function Mp(e){e.clearMeasurements()}function c2(e){e.isLayoutDirty=!0,e.updateLayout()}function Ap(e){e.isLayoutDirty=!1}function d2(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function f2(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Dp(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function h2(e){e.resolveTargetDelta()}function p2(e){e.calcProjection()}function m2(e){e.resetSkewAndRotation()}function g2(e){e.removeLeadSnapshot()}function Lp(e,t,n){e.translate=fe(t.translate,0,n),e.scale=fe(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Op(e,t,n,r){e.min=fe(t.min,n.min,r),e.max=fe(t.max,n.max,r)}function y2(e,t,n,r){Op(e.x,t.x,n.x,r),Op(e.y,t.y,n.y,r)}function v2(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const x2={duration:.45,ease:[.4,0,.1,1]},_p=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Ip=_p("applewebkit/")&&!_p("chrome/")?Math.round:wt;function Vp(e){e.min=Ip(e.min),e.max=Ip(e.max)}function w2(e){Vp(e.x),Vp(e.y)}function T0(e,t,n){return e==="position"||e==="preserve-aspect"&&!BC(Tp(t),Tp(n),.2)}function S2(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const E2=C0({attachResizeListener:(e,t)=>mo(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Fl={current:void 0},P0=C0({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Fl.current){const e=new E2({});e.mount(window),e.setOptions({layoutScroll:!0}),Fl.current=e}return Fl.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Zd=p.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Fp(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function k2(...e){return t=>{let n=!1;const r=e.map(s=>{const o=Fp(s,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let s=0;s<r.length;s++){const o=r[s];typeof o=="function"?o():Fp(e[s],null)}}}}function b2(...e){return p.useCallback(k2(...e),e)}class C2 extends p.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(bi(n)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,s=bi(r)&&r.offsetWidth||0,o=bi(r)&&r.offsetHeight||0,i=getComputedStyle(n),a=this.props.sizeRef.current;a.height=parseFloat(i.height),a.width=parseFloat(i.width),a.top=n.offsetTop,a.left=n.offsetLeft,a.right=s-a.width-a.left,a.bottom=o-a.height-a.top}return null}componentDidUpdate(){}render(){return this.props.children}}function T2({children:e,isPresent:t,anchorX:n,anchorY:r,root:s,pop:o}){var f;const i=p.useId(),a=p.useRef(null),l=p.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:c}=p.useContext(Zd),d=((f=e.props)==null?void 0:f.ref)??(e==null?void 0:e.ref),u=b2(a,d);return p.useInsertionEffect(()=>{const{width:y,height:w,top:x,left:S,right:m,bottom:g}=l.current;if(t||o===!1||!a.current||!y||!w)return;const v=n==="left"?`left: ${S}`:`right: ${m}`,E=r==="bottom"?`bottom: ${g}`:`top: ${x}`;a.current.dataset.motionPopId=i;const C=document.createElement("style");c&&(C.nonce=c);const T=s??document.head;return T.appendChild(C),C.sheet&&C.sheet.insertRule(`
69
+ [data-motion-pop-id="${i}"] {
70
+ position: absolute !important;
71
+ width: ${y}px !important;
72
+ height: ${w}px !important;
73
+ ${v}px !important;
74
+ ${E}px !important;
75
+ }
76
+ `),()=>{var k;(k=a.current)==null||k.removeAttribute("data-motion-pop-id"),T.contains(C)&&T.removeChild(C)}},[t]),h.jsx(C2,{isPresent:t,childRef:a,sizeRef:l,pop:o,children:o===!1?e:p.cloneElement(e,{ref:u})})}const P2=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:s,presenceAffectsLayout:o,mode:i,anchorX:a,anchorY:l,root:c})=>{const d=Td(N2),u=p.useId();let f=!0,y=p.useMemo(()=>(f=!1,{id:u,initial:t,isPresent:n,custom:s,onExitComplete:w=>{d.set(w,!0);for(const x of d.values())if(!x)return;r&&r()},register:w=>(d.set(w,!1),()=>d.delete(w))}),[n,d,r]);return o&&f&&(y={...y}),p.useMemo(()=>{d.forEach((w,x)=>d.set(x,!1))},[n]),p.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),e=h.jsx(T2,{pop:i==="popLayout",isPresent:n,anchorX:a,anchorY:l,root:c,children:e}),h.jsx(_a.Provider,{value:y,children:e})};function N2(){return new Map}function N0(e=!0){const t=p.useContext(_a);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,o=p.useId();p.useEffect(()=>{if(e)return s(o)},[e]);const i=p.useCallback(()=>e&&r&&r(o),[o,r,e]);return!n&&r?[!1,i]:[!0]}const ei=e=>e.key||"";function zp(e){const t=[];return p.Children.forEach(e,n=>{p.isValidElement(n)&&t.push(n)}),t}const qd=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:s=!0,mode:o="sync",propagate:i=!1,anchorX:a="left",anchorY:l="top",root:c})=>{const[d,u]=N0(i),f=p.useMemo(()=>zp(e),[e]),y=i&&!d?[]:f.map(ei),w=p.useRef(!0),x=p.useRef(f),S=Td(()=>new Map),m=p.useRef(new Set),[g,v]=p.useState(f),[E,C]=p.useState(f);tv(()=>{w.current=!1,x.current=f;for(let b=0;b<E.length;b++){const A=ei(E[b]);y.includes(A)?(S.delete(A),m.current.delete(A)):S.get(A)!==!0&&S.set(A,!1)}},[E,y.length,y.join("-")]);const T=[];if(f!==g){let b=[...f];for(let A=0;A<E.length;A++){const P=E[A],D=ei(P);y.includes(D)||(b.splice(A,0,P),T.push(P))}return o==="wait"&&T.length&&(b=T),C(zp(b)),v(f),null}const{forceRender:k}=p.useContext(Cd);return h.jsx(h.Fragment,{children:E.map(b=>{const A=ei(b),P=i&&!d?!1:f===E||y.includes(A),D=()=>{if(m.current.has(A))return;if(S.has(A))m.current.add(A),S.set(A,!0);else return;let L=!0;S.forEach(Q=>{Q||(L=!1)}),L&&(k==null||k(),C(x.current),i&&(u==null||u()),r&&r())};return h.jsx(P2,{isPresent:P,initial:!w.current||n?void 0:!1,custom:t,presenceAffectsLayout:s,mode:o,root:c,onExitComplete:P?void 0:D,anchorX:a,anchorY:l,children:b},A)})})},j0=p.createContext({strict:!1}),Bp={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let $p=!1;function j2(){if($p)return;const e={};for(const t in Bp)e[t]={isEnabled:n=>Bp[t].some(r=>!!n[r])};s0(e),$p=!0}function R0(){return j2(),hC()}function R2(e){const t=R0();for(const n in e)t[n]={...t[n],...e[n]};s0(t)}const M2=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function fa(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||M2.has(e)}let M0=e=>!fa(e);function A2(e){typeof e=="function"&&(M0=t=>t.startsWith("on")?!fa(t):e(t))}try{A2(require("@emotion/is-prop-valid").default)}catch{}function D2(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||Ie(e[s])||(M0(s)||n===!0&&fa(s)||!t&&!fa(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}const za=p.createContext({});function L2(e,t){if(Fa(e)){const{initial:n,animate:r}=e;return{initial:n===!1||po(n)?n:void 0,animate:po(r)?r:void 0}}return e.inherit!==!1?t:{}}function O2(e){const{initial:t,animate:n}=L2(e,p.useContext(za));return p.useMemo(()=>({initial:t,animate:n}),[Up(t),Up(n)])}function Up(e){return Array.isArray(e)?e.join(" "):e}const Jd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function A0(e,t,n){for(const r in t)!Ie(t[r])&&!d0(r,n)&&(e[r]=t[r])}function _2({transformTemplate:e},t){return p.useMemo(()=>{const n=Jd();return Xd(n,t,e),Object.assign({},n.vars,n.style)},[t])}function I2(e,t){const n=e.style||{},r={};return A0(r,n,e),Object.assign(r,_2(e,t)),r}function V2(e,t){const n={},r=I2(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const D0=()=>({...Jd(),attrs:{}});function F2(e,t,n,r){const s=p.useMemo(()=>{const o=D0();return f0(o,t,p0(r),e.transformTemplate,e.style),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};A0(o,e.style,e),s.style={...o,...s.style}}return s}const z2=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function ef(e){return typeof e!="string"||e.includes("-")?!1:!!(z2.indexOf(e)>-1||/[A-Z]/u.test(e))}function B2(e,t,n,{latestValues:r},s,o=!1,i){const l=(i??ef(e)?F2:V2)(t,r,s,e),c=D2(t,typeof e=="string",o),d=e!==p.Fragment?{...c,...l,ref:n}:{},{children:u}=t,f=p.useMemo(()=>Ie(u)?u.get():u,[u]);return p.createElement(e,{...d,children:f})}function $2({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:U2(n,r,s,e),renderState:t()}}function U2(e,t,n,r){const s={},o=r(e,{});for(const f in o)s[f]=ji(o[f]);let{initial:i,animate:a}=e;const l=Fa(e),c=n0(e);t&&c&&!l&&e.inherit!==!1&&(i===void 0&&(i=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||i===!1;const u=d?a:i;if(u&&typeof u!="boolean"&&!Va(u)){const f=Array.isArray(u)?u:[u];for(let y=0;y<f.length;y++){const w=Bd(e,f[y]);if(w){const{transitionEnd:x,transition:S,...m}=w;for(const g in m){let v=m[g];if(Array.isArray(v)){const E=d?v.length-1:0;v=v[E]}v!==null&&(s[g]=v)}for(const g in x)s[g]=x[g]}}}return s}const L0=e=>(t,n)=>{const r=p.useContext(za),s=p.useContext(_a),o=()=>$2(e,t,r,s);return n?o():Td(o)},W2=L0({scrapeMotionValuesFromProps:Qd,createRenderState:Jd}),H2=L0({scrapeMotionValuesFromProps:m0,createRenderState:D0}),G2=Symbol.for("motionComponentSymbol");function K2(e,t,n){const r=p.useRef(n);p.useInsertionEffect(()=>{r.current=n});const s=p.useRef(null);return p.useCallback(o=>{var a;o&&((a=e.onMount)==null||a.call(e,o));const i=r.current;if(typeof i=="function")if(o){const l=i(o);typeof l=="function"&&(s.current=l)}else s.current?(s.current(),s.current=null):i(o);else i&&(i.current=o);t&&(o?t.mount(o):t.unmount())},[t])}const O0=p.createContext({});function Nr(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Y2(e,t,n,r,s,o){var v,E;const{visualElement:i}=p.useContext(za),a=p.useContext(j0),l=p.useContext(_a),c=p.useContext(Zd),d=c.reducedMotion,u=c.skipAnimations,f=p.useRef(null),y=p.useRef(!1);r=r||a.renderer,!f.current&&r&&(f.current=r(e,{visualState:t,parent:i,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:d,skipAnimations:u,isSVG:o}),y.current&&f.current&&(f.current.manuallyAnimateOnMount=!0));const w=f.current,x=p.useContext(O0);w&&!w.projection&&s&&(w.type==="html"||w.type==="svg")&&X2(f.current,n,s,x);const S=p.useRef(!1);p.useInsertionEffect(()=>{w&&S.current&&w.update(n,l)});const m=n[Uv],g=p.useRef(!!m&&typeof window<"u"&&!((v=window.MotionHandoffIsComplete)!=null&&v.call(window,m))&&((E=window.MotionHasOptimisedAnimation)==null?void 0:E.call(window,m)));return tv(()=>{y.current=!0,w&&(S.current=!0,window.MotionIsMounted=!0,w.updateFeatures(),w.scheduleRenderMicrotask(),g.current&&w.animationState&&w.animationState.animateChanges())}),p.useEffect(()=>{w&&(!g.current&&w.animationState&&w.animationState.animateChanges(),g.current&&(queueMicrotask(()=>{var C;(C=window.MotionHandoffMarkAsComplete)==null||C.call(window,m)}),g.current=!1),w.enteringChildren=void 0)}),w}function X2(e,t,n,r){const{layoutId:s,layout:o,drag:i,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutAnchor:d,layoutCrossfade:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:_0(e.parent)),e.projection.setOptions({layoutId:s,layout:o,alwaysMeasureLayout:!!i||a&&Nr(a),visualElement:e,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,crossfade:u,layoutScroll:l,layoutRoot:c,layoutAnchor:d})}function _0(e){if(e)return e.options.allowProjection!==!1?e.projection:_0(e.parent)}function zl(e,{forwardMotionProps:t=!1,type:n}={},r,s){r&&R2(r);const o=n?n==="svg":ef(e),i=o?H2:W2;function a(c,d){let u;const f={...p.useContext(Zd),...c,layoutId:Q2(c)},{isStatic:y}=f,w=O2(c),x=i(c,y);if(!y&&typeof window<"u"){Z2();const S=q2(f);u=S.MeasureLayout,w.visualElement=Y2(e,x,f,s,S.ProjectionNode,o)}return h.jsxs(za.Provider,{value:w,children:[u&&w.visualElement?h.jsx(u,{visualElement:w.visualElement,...f}):null,B2(e,c,K2(x,w.visualElement,d),x,y,t,o)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=p.forwardRef(a);return l[G2]=e,l}function Q2({layoutId:e}){const t=p.useContext(Cd).id;return t&&e!==void 0?t+"-"+e:e}function Z2(e,t){p.useContext(j0).strict}function q2(e){const t=R0(),{drag:n,layout:r}=t;if(!n&&!r)return{};const s={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?s.MeasureLayout:void 0,ProjectionNode:s.ProjectionNode}}function J2(e,t){if(typeof Proxy>"u")return zl;const n=new Map,r=(o,i)=>zl(o,i,e,t),s=(o,i)=>r(o,i);return new Proxy(s,{get:(o,i)=>i==="create"?r:(n.has(i)||n.set(i,zl(i,void 0,e,t)),n.get(i))})}const eT=(e,t)=>t.isSVG??ef(e)?new RC(t):new bC(t,{allowProjection:e!==p.Fragment});class tT extends Yn{constructor(t){super(t),t.animationState||(t.animationState=OC(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Va(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let nT=0;class rT extends Yn{constructor(){super(...arguments),this.id=nT++,this.isExitComplete=!1}update(){var o;if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;if(t&&r===!1){if(this.isExitComplete){const{initial:i,custom:a}=this.node.getProps();if(typeof i=="string"){const l=hr(this.node,i,a);if(l){const{transition:c,transitionEnd:d,...u}=l;for(const f in u)(o=this.node.getValue(f))==null||o.jump(u[f])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const sT={animation:{Feature:tT},exit:{Feature:rT}};function Ro(e){return{point:{x:e.pageX,y:e.pageY}}}const oT=e=>t=>Hd(t)&&e(t,Ro(t));function Hs(e,t,n,r){return mo(e,t,oT(n),r)}const I0=({current:e})=>e?e.ownerDocument.defaultView:null,Wp=(e,t)=>Math.abs(e-t);function iT(e,t){const n=Wp(e.x,t.x),r=Wp(e.y,t.y);return Math.sqrt(n**2+r**2)}const Hp=new Set(["auto","scroll"]);class V0{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:o=!1,distanceThreshold:i=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=y=>{this.handleScroll(y.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=ti(this.lastRawMoveEventInfo,this.transformPagePoint));const y=Bl(this.lastMoveEventInfo,this.history),w=this.startEvent!==null,x=iT(y.offset,{x:0,y:0})>=this.distanceThreshold;if(!w&&!x)return;const{point:S}=y,{timestamp:m}=_e;this.history.push({...S,timestamp:m});const{onStart:g,onMove:v}=this.handlers;w||(g&&g(this.lastMoveEvent,y),this.startEvent=this.lastMoveEvent),v&&v(this.lastMoveEvent,y)},this.handlePointerMove=(y,w)=>{this.lastMoveEvent=y,this.lastRawMoveEventInfo=w,this.lastMoveEventInfo=ti(w,this.transformPagePoint),oe.update(this.updatePoint,!0)},this.handlePointerUp=(y,w)=>{this.end();const{onEnd:x,onSessionEnd:S,resumeAnimation:m}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&m&&m(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const g=Bl(y.type==="pointercancel"?this.lastMoveEventInfo:ti(w,this.transformPagePoint),this.history);this.startEvent&&x&&x(y,g),S&&S(y,g)},!Hd(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=i,this.contextWindow=s||window;const l=Ro(t),c=ti(l,this.transformPagePoint),{point:d}=c,{timestamp:u}=_e;this.history=[{...d,timestamp:u}];const{onSessionStart:f}=n;f&&f(t,Bl(c,this.history)),this.removeListeners=Po(Hs(this.contextWindow,"pointermove",this.handlePointerMove),Hs(this.contextWindow,"pointerup",this.handlePointerUp),Hs(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(Hp.has(r.overflowX)||Hp.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,s=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},o={x:s.x-n.x,y:s.y-n.y};o.x===0&&o.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=o.x,this.lastMoveEventInfo.point.y+=o.y):this.history.length>0&&(this.history[0].x-=o.x,this.history[0].y-=o.y),this.scrollPositions.set(t,s),oe.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Un(this.updatePoint)}}function ti(e,t){return t?{point:t(e.point)}:e}function Gp(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Bl({point:e},t){return{point:e,delta:Gp(e,F0(t)),offset:Gp(e,aT(t)),velocity:lT(t,.1)}}function aT(e){return e[0]}function F0(e){return e[e.length-1]}function lT(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=F0(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>ct(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&s.timestamp-r.timestamp>ct(t)*2&&(r=e[1]);const o=vt(s.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const i={x:(s.x-r.x)/o,y:(s.y-r.y)/o};return i.x===1/0&&(i.x=0),i.y===1/0&&(i.y=0),i}function uT(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?fe(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?fe(n,e,r.max):Math.min(e,n)),e}function Kp(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function cT(e,{top:t,left:n,bottom:r,right:s}){return{x:Kp(e.x,n,s),y:Kp(e.y,t,r)}}function Yp(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function dT(e,t){return{x:Yp(e.x,t.x),y:Yp(e.y,t.y)}}function fT(e,t){let n=.5;const r=Xe(e),s=Xe(t);return s>r?n=fo(t.min,t.max-r,e.min):r>s&&(n=fo(e.min,e.max-s,t.min)),Yt(0,1,n)}function hT(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const xc=.35;function pT(e=xc){return e===!1?e=0:e===!0&&(e=xc),{x:Xp(e,"left","right"),y:Xp(e,"top","bottom")}}function Xp(e,t,n){return{min:Qp(e,t),max:Qp(e,n)}}function Qp(e,t){return typeof e=="number"?e:e[t]||0}const mT=new WeakMap;class gT{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Ne(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:s}=this.visualElement;if(s&&s.isPresent===!1)return;const o=u=>{n&&this.snapToCursor(Ro(u).point),this.stopAnimation()},i=(u,f)=>{const{drag:y,dragPropagation:w,onDragStart:x}=this.getProps();if(y&&!w&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Ub(y),!this.openDragLock))return;this.latestPointerEvent=u,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Bt(m=>{let g=this.getAxisMotionValue(m).get()||0;if(Kt.test(g)){const{projection:v}=this.visualElement;if(v&&v.layout){const E=v.layout.layoutBox[m];E&&(g=Xe(E)*(parseFloat(g)/100))}}this.originPoint[m]=g}),x&&oe.update(()=>x(u,f),!1,!0),cc(this.visualElement,"transform");const{animationState:S}=this.visualElement;S&&S.setActive("whileDrag",!0)},a=(u,f)=>{this.latestPointerEvent=u,this.latestPanInfo=f;const{dragPropagation:y,dragDirectionLock:w,onDirectionLock:x,onDrag:S}=this.getProps();if(!y&&!this.openDragLock)return;const{offset:m}=f;if(w&&this.currentDirection===null){this.currentDirection=vT(m),this.currentDirection!==null&&x&&x(this.currentDirection);return}this.updateAxis("x",f.point,m),this.updateAxis("y",f.point,m),this.visualElement.render(),S&&oe.update(()=>S(u,f),!1,!0)},l=(u,f)=>{this.latestPointerEvent=u,this.latestPanInfo=f,this.stop(u,f),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{const{dragSnapToOrigin:u}=this.getProps();(u||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:d}=this.getProps();this.panSession=new V0(t,{onSessionStart:o,onStart:i,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:r,contextWindow:I0(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,s=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!s||!r)return;const{velocity:i}=s;this.startAnimation(i);const{onDragEnd:a}=this.getProps();a&&oe.postRender(()=>a(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!ni(t,s,this.currentDirection))return;const o=this.getAxisMotionValue(t);let i=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(i=uT(i,this.constraints[t],this.elastic[t])),o.set(i)}resolveConstraints(){var o;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,s=this.constraints;t&&Nr(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=cT(r.layoutBox,t):this.constraints=!1,this.elastic=pT(n),s!==this.constraints&&!Nr(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Bt(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=hT(r.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Nr(t))return!1;const r=t.current,{projection:s}=this.visualElement;if(!s||!s.layout)return!1;const o=vC(r,s.root,this.visualElement.getTransformPagePoint());let i=dT(s.layout.layoutBox,o);if(n){const a=n(mC(i));this.hasMutatedConstraints=!!a,a&&(i=i0(a))}return i}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:o,dragSnapToOrigin:i,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=Bt(d=>{if(!ni(d,n,this.currentDirection))return;let u=l&&l[d]||{};(i===!0||i===d)&&(u={min:0,max:0});const f=s?200:1e6,y=s?40:1e7,w={type:"inertia",velocity:r?t[d]:0,bounceStiffness:f,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10,...o,...u};return this.startAxisValueAnimation(d,w)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return cc(this.visualElement,t),r.start(zd(t,r,0,n,this.visualElement,!1))}stopAnimation(){Bt(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),s=r[n];return s||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Bt(n=>{const{drag:r}=this.getProps();if(!ni(n,r,this.currentDirection))return;const{projection:s}=this.visualElement,o=this.getAxisMotionValue(n);if(s&&s.layout){const{min:i,max:a}=s.layout.layoutBox[n],l=o.get()||0;o.set(t[n]-fe(i,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Nr(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Bt(i=>{const a=this.getAxisMotionValue(i);if(a&&this.constraints!==!1){const l=a.get();s[i]=fT({min:l,max:l},this.constraints[i])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),Bt(i=>{if(!ni(i,t,null))return;const a=this.getAxisMotionValue(i),{min:l,max:c}=this.constraints[i];a.set(fe(l,c,s[i]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;mT.set(this.visualElement,this);const t=this.visualElement.current,n=Hs(t,"pointerdown",c=>{const{drag:d,dragListener:u=!0}=this.getProps(),f=c.target,y=f!==t&&Xb(f);d&&u&&!y&&this.start(c)});let r;const s=()=>{const{dragConstraints:c}=this.getProps();Nr(c)&&c.current&&(this.constraints=this.resolveRefConstraints(),r||(r=yT(t,c.current,()=>this.scalePositionWithinConstraints())))},{projection:o}=this.visualElement,i=o.addEventListener("measure",s);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),oe.read(s);const a=mo(window,"resize",()=>this.scalePositionWithinConstraints()),l=o.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d})=>{this.isDragging&&d&&(Bt(u=>{const f=this.getAxisMotionValue(u);f&&(this.originPoint[u]+=c[u].translate,f.set(f.get()+c[u].translate))}),this.visualElement.render())});return()=>{a(),n(),i(),l&&l(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:o=!1,dragElastic:i=xc,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:o,dragElastic:i,dragMomentum:a}}}function Zp(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function yT(e,t,n){const r=sp(e,Zp(n)),s=sp(t,Zp(n));return()=>{r(),s()}}function ni(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function vT(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class xT extends Yn{constructor(t){super(t),this.removeGroupControls=wt,this.removeListeners=wt,this.controls=new gT(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||wt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const $l=e=>(t,n)=>{e&&oe.update(()=>e(t,n),!1,!0)};class wT extends Yn{constructor(){super(...arguments),this.removePointerDownListener=wt}onPointerDown(t){this.session=new V0(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:I0(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:$l(t),onStart:$l(n),onMove:$l(r),onEnd:(o,i)=>{delete this.session,s&&oe.postRender(()=>s(o,i))}}}mount(){this.removePointerDownListener=Hs(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Ul=!1;class ST extends p.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:s}=this.props,{projection:o}=t;o&&(n.group&&n.group.add(o),r&&r.register&&s&&r.register(o),Ul&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Ri.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:o}=this.props,{projection:i}=r;return i&&(i.isPresent=o,t.layoutDependency!==n&&i.setOptions({...i.options,layoutDependency:n}),Ul=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==o?i.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?i.promote():i.relegate()||oe.postRender(()=>{const a=i.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),Wd.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;Ul=!0,s&&(s.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(s),r&&r.deregister&&r.deregister(s))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function z0(e){const[t,n]=N0(),r=p.useContext(Cd);return h.jsx(ST,{...e,layoutGroup:r,switchLayoutGroup:p.useContext(O0),isPresent:t,safeToRemove:n})}const ET={pan:{Feature:wT},drag:{Feature:xT,ProjectionNode:P0,MeasureLayout:z0}};function qp(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const s="onHover"+n,o=r[s];o&&oe.postRender(()=>o(t,Ro(t)))}class kT extends Yn{mount(){const{current:t}=this.node;t&&(this.unmount=Hb(t,(n,r)=>(qp(this.node,r,"Start"),s=>qp(this.node,s,"End"))))}unmount(){}}class bT extends Yn{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Po(mo(this.node.current,"focus",()=>this.onFocus()),mo(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Jp(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const s="onTap"+(n==="End"?"":n),o=r[s];o&&oe.postRender(()=>o(t,Ro(t)))}class CT extends Yn{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=Zb(t,(s,o)=>(Jp(this.node,o,"Start"),(i,{success:a})=>Jp(this.node,i,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const wc=new WeakMap,Wl=new WeakMap,TT=e=>{const t=wc.get(e.target);t&&t(e)},PT=e=>{e.forEach(TT)};function NT({root:e,...t}){const n=e||document;Wl.has(n)||Wl.set(n,{});const r=Wl.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(PT,{root:e,...t})),r[s]}function jT(e,t,n){const r=NT(t);return wc.set(e,n),r.observe(e),()=>{wc.delete(e),r.unobserve(e)}}const RT={some:0,all:1};class MT extends Yn{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var l;(l=this.stopObserver)==null||l.call(this);const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:s="some",once:o}=t,i={root:n?n.current:void 0,rootMargin:r,threshold:typeof s=="number"?s:RT[s]},a=c=>{const{isIntersecting:d}=c;if(this.isInView===d||(this.isInView=d,o&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:u,onViewportLeave:f}=this.node.getProps(),y=d?u:f;y&&y(c)};this.stopObserver=jT(this.node.current,i,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(AT(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function AT({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const DT={inView:{Feature:MT},tap:{Feature:CT},focus:{Feature:bT},hover:{Feature:kT}},LT={layout:{ProjectionNode:P0,MeasureLayout:z0}},OT={...sT,...DT,...ET,...LT},Vn=J2(OT,eT);function B0(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=B0(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function $0(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=B0(e))&&(r&&(r+=" "),r+=t);return r}const tf="-",_T=e=>{const t=VT(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{const a=i.split(tf);return a[0]===""&&a.length!==1&&a.shift(),U0(a,t)||IT(i)},getConflictingClassGroupIds:(i,a)=>{const l=n[i]||[];return a&&r[i]?[...l,...r[i]]:l}}},U0=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),s=r?U0(e.slice(1),r):void 0;if(s)return s;if(t.validators.length===0)return;const o=e.join(tf);return(i=t.validators.find(({validator:a})=>a(o)))==null?void 0:i.classGroupId},em=/^\[(.+)\]$/,IT=e=>{if(em.test(e)){const t=em.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},VT=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return zT(Object.entries(e.classGroups),n).forEach(([o,i])=>{Sc(i,r,o,t)}),r},Sc=(e,t,n,r)=>{e.forEach(s=>{if(typeof s=="string"){const o=s===""?t:tm(t,s);o.classGroupId=n;return}if(typeof s=="function"){if(FT(s)){Sc(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(([o,i])=>{Sc(i,tm(t,o),n,r)})})},tm=(e,t)=>{let n=e;return t.split(tf).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},FT=e=>e.isThemeGetter,zT=(e,t)=>t?e.map(([n,r])=>{const s=r.map(o=>typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([i,a])=>[t+i,a])):o);return[n,s]}):e,BT=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const s=(o,i)=>{n.set(o,i),t++,t>e&&(t=0,r=n,n=new Map)};return{get(o){let i=n.get(o);if(i!==void 0)return i;if((i=r.get(o))!==void 0)return s(o,i),i},set(o,i){n.has(o)?n.set(o,i):s(o,i)}}},W0="!",$T=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,s=t[0],o=t.length,i=a=>{const l=[];let c=0,d=0,u;for(let S=0;S<a.length;S++){let m=a[S];if(c===0){if(m===s&&(r||a.slice(S,S+o)===t)){l.push(a.slice(d,S)),d=S+o;continue}if(m==="/"){u=S;continue}}m==="["?c++:m==="]"&&c--}const f=l.length===0?a:a.substring(d),y=f.startsWith(W0),w=y?f.substring(1):f,x=u&&u>d?u-d:void 0;return{modifiers:l,hasImportantModifier:y,baseClassName:w,maybePostfixModifierPosition:x}};return n?a=>n({className:a,parseClassName:i}):i},UT=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},WT=e=>({cache:BT(e.cacheSize),parseClassName:$T(e),..._T(e)}),HT=/\s+/,GT=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:s}=t,o=[],i=e.trim().split(HT);let a="";for(let l=i.length-1;l>=0;l-=1){const c=i[l],{modifiers:d,hasImportantModifier:u,baseClassName:f,maybePostfixModifierPosition:y}=n(c);let w=!!y,x=r(w?f.substring(0,y):f);if(!x){if(!w){a=c+(a.length>0?" "+a:a);continue}if(x=r(f),!x){a=c+(a.length>0?" "+a:a);continue}w=!1}const S=UT(d).join(":"),m=u?S+W0:S,g=m+x;if(o.includes(g))continue;o.push(g);const v=s(x,w);for(let E=0;E<v.length;++E){const C=v[E];o.push(m+C)}a=c+(a.length>0?" "+a:a)}return a};function KT(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=H0(t))&&(r&&(r+=" "),r+=n);return r}const H0=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=H0(e[r]))&&(n&&(n+=" "),n+=t);return n};function YT(e,...t){let n,r,s,o=i;function i(l){const c=t.reduce((d,u)=>u(d),e());return n=WT(c),r=n.cache.get,s=n.cache.set,o=a,a(l)}function a(l){const c=r(l);if(c)return c;const d=GT(l,n);return s(l,d),d}return function(){return o(KT.apply(null,arguments))}}const ce=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},G0=/^\[(?:([a-z-]+):)?(.+)\]$/i,XT=/^\d+\/\d+$/,QT=new Set(["px","full","screen"]),ZT=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,qT=/\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$/,JT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,eP=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,tP=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Zt=e=>Qr(e)||QT.has(e)||XT.test(e),mn=e=>ms(e,"length",uP),Qr=e=>!!e&&!Number.isNaN(Number(e)),Hl=e=>ms(e,"number",Qr),Ts=e=>!!e&&Number.isInteger(Number(e)),nP=e=>e.endsWith("%")&&Qr(e.slice(0,-1)),W=e=>G0.test(e),gn=e=>ZT.test(e),rP=new Set(["length","size","percentage"]),sP=e=>ms(e,rP,K0),oP=e=>ms(e,"position",K0),iP=new Set(["image","url"]),aP=e=>ms(e,iP,dP),lP=e=>ms(e,"",cP),Ps=()=>!0,ms=(e,t,n)=>{const r=G0.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},uP=e=>qT.test(e)&&!JT.test(e),K0=()=>!1,cP=e=>eP.test(e),dP=e=>tP.test(e),fP=()=>{const e=ce("colors"),t=ce("spacing"),n=ce("blur"),r=ce("brightness"),s=ce("borderColor"),o=ce("borderRadius"),i=ce("borderSpacing"),a=ce("borderWidth"),l=ce("contrast"),c=ce("grayscale"),d=ce("hueRotate"),u=ce("invert"),f=ce("gap"),y=ce("gradientColorStops"),w=ce("gradientColorStopPositions"),x=ce("inset"),S=ce("margin"),m=ce("opacity"),g=ce("padding"),v=ce("saturate"),E=ce("scale"),C=ce("sepia"),T=ce("skew"),k=ce("space"),b=ce("translate"),A=()=>["auto","contain","none"],P=()=>["auto","hidden","clip","visible","scroll"],D=()=>["auto",W,t],L=()=>[W,t],Q=()=>["",Zt,mn],le=()=>["auto",Qr,W],ge=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],z=()=>["solid","dashed","dotted","double","none"],re=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],j=()=>["start","end","center","between","around","evenly","stretch"],O=()=>["","0",W],V=()=>["auto","avoid","all","avoid-page","page","left","right","column"],$=()=>[Qr,W];return{cacheSize:500,separator:":",theme:{colors:[Ps],spacing:[Zt,mn],blur:["none","",gn,W],brightness:$(),borderColor:[e],borderRadius:["none","","full",gn,W],borderSpacing:L(),borderWidth:Q(),contrast:$(),grayscale:O(),hueRotate:$(),invert:O(),gap:L(),gradientColorStops:[e],gradientColorStopPositions:[nP,mn],inset:D(),margin:D(),opacity:$(),padding:L(),saturate:$(),scale:$(),sepia:O(),skew:$(),space:L(),translate:L()},classGroups:{aspect:[{aspect:["auto","square","video",W]}],container:["container"],columns:[{columns:[gn]}],"break-after":[{"break-after":V()}],"break-before":[{"break-before":V()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ge(),W]}],overflow:[{overflow:P()}],"overflow-x":[{"overflow-x":P()}],"overflow-y":[{"overflow-y":P()}],overscroll:[{overscroll:A()}],"overscroll-x":[{"overscroll-x":A()}],"overscroll-y":[{"overscroll-y":A()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[x]}],"inset-x":[{"inset-x":[x]}],"inset-y":[{"inset-y":[x]}],start:[{start:[x]}],end:[{end:[x]}],top:[{top:[x]}],right:[{right:[x]}],bottom:[{bottom:[x]}],left:[{left:[x]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ts,W]}],basis:[{basis:D()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",W]}],grow:[{grow:O()}],shrink:[{shrink:O()}],order:[{order:["first","last","none",Ts,W]}],"grid-cols":[{"grid-cols":[Ps]}],"col-start-end":[{col:["auto",{span:["full",Ts,W]},W]}],"col-start":[{"col-start":le()}],"col-end":[{"col-end":le()}],"grid-rows":[{"grid-rows":[Ps]}],"row-start-end":[{row:["auto",{span:[Ts,W]},W]}],"row-start":[{"row-start":le()}],"row-end":[{"row-end":le()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",W]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",W]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...j()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...j(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...j(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[g]}],px:[{px:[g]}],py:[{py:[g]}],ps:[{ps:[g]}],pe:[{pe:[g]}],pt:[{pt:[g]}],pr:[{pr:[g]}],pb:[{pb:[g]}],pl:[{pl:[g]}],m:[{m:[S]}],mx:[{mx:[S]}],my:[{my:[S]}],ms:[{ms:[S]}],me:[{me:[S]}],mt:[{mt:[S]}],mr:[{mr:[S]}],mb:[{mb:[S]}],ml:[{ml:[S]}],"space-x":[{"space-x":[k]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[k]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",W,t]}],"min-w":[{"min-w":[W,t,"min","max","fit"]}],"max-w":[{"max-w":[W,t,"none","full","min","max","fit","prose",{screen:[gn]},gn]}],h:[{h:[W,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[W,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[W,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[W,t,"auto","min","max","fit"]}],"font-size":[{text:["base",gn,mn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Hl]}],"font-family":[{font:[Ps]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",W]}],"line-clamp":[{"line-clamp":["none",Qr,Hl]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Zt,W]}],"list-image":[{"list-image":["none",W]}],"list-style-type":[{list:["none","disc","decimal",W]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...z(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Zt,mn]}],"underline-offset":[{"underline-offset":["auto",Zt,W]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:L()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",W]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",W]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ge(),oP]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",sP]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},aP]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[y]}],"gradient-via":[{via:[y]}],"gradient-to":[{to:[y]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[m]}],"border-style":[{border:[...z(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[m]}],"divide-style":[{divide:z()}],"border-color":[{border:[s]}],"border-color-x":[{"border-x":[s]}],"border-color-y":[{"border-y":[s]}],"border-color-s":[{"border-s":[s]}],"border-color-e":[{"border-e":[s]}],"border-color-t":[{"border-t":[s]}],"border-color-r":[{"border-r":[s]}],"border-color-b":[{"border-b":[s]}],"border-color-l":[{"border-l":[s]}],"divide-color":[{divide:[s]}],"outline-style":[{outline:["",...z()]}],"outline-offset":[{"outline-offset":[Zt,W]}],"outline-w":[{outline:[Zt,mn]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:Q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[Zt,mn]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",gn,lP]}],"shadow-color":[{shadow:[Ps]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":[...re(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":re()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",gn,W]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[u]}],saturate:[{saturate:[v]}],sepia:[{sepia:[C]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[u]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[C]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",W]}],duration:[{duration:$()}],ease:[{ease:["linear","in","out","in-out",W]}],delay:[{delay:$()}],animate:[{animate:["none","spin","ping","pulse","bounce",W]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[E]}],"scale-x":[{"scale-x":[E]}],"scale-y":[{"scale-y":[E]}],rotate:[{rotate:[Ts,W]}],"translate-x":[{"translate-x":[b]}],"translate-y":[{"translate-y":[b]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",W]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",W]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":L()}],"scroll-mx":[{"scroll-mx":L()}],"scroll-my":[{"scroll-my":L()}],"scroll-ms":[{"scroll-ms":L()}],"scroll-me":[{"scroll-me":L()}],"scroll-mt":[{"scroll-mt":L()}],"scroll-mr":[{"scroll-mr":L()}],"scroll-mb":[{"scroll-mb":L()}],"scroll-ml":[{"scroll-ml":L()}],"scroll-p":[{"scroll-p":L()}],"scroll-px":[{"scroll-px":L()}],"scroll-py":[{"scroll-py":L()}],"scroll-ps":[{"scroll-ps":L()}],"scroll-pe":[{"scroll-pe":L()}],"scroll-pt":[{"scroll-pt":L()}],"scroll-pr":[{"scroll-pr":L()}],"scroll-pb":[{"scroll-pb":L()}],"scroll-pl":[{"scroll-pl":L()}],"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",W]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Zt,mn,Hl]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},hP=YT(fP);function q(...e){return hP($0(e))}const nf=p.forwardRef(({className:e,...t},n)=>h.jsx("div",{ref:n,className:q("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));nf.displayName="Card";const rf=p.forwardRef(({className:e,...t},n)=>h.jsx("div",{ref:n,className:q("flex flex-col space-y-1.5 p-6",e),...t}));rf.displayName="CardHeader";const sf=p.forwardRef(({className:e,...t},n)=>h.jsx("h3",{ref:n,className:q("text-2xl font-semibold leading-none tracking-tight",e),...t}));sf.displayName="CardTitle";const Y0=p.forwardRef(({className:e,...t},n)=>h.jsx("p",{ref:n,className:q("text-sm text-muted-foreground",e),...t}));Y0.displayName="CardDescription";const of=p.forwardRef(({className:e,...t},n)=>h.jsx("div",{ref:n,className:q("p-6 pt-0",e),...t}));of.displayName="CardContent";const X0=p.forwardRef(({className:e,...t},n)=>h.jsx("div",{ref:n,className:q("flex items-center p-6 pt-0",e),...t}));X0.displayName="CardFooter";function nm(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Ba(...e){return t=>{let n=!1;const r=e.map(s=>{const o=nm(s,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let s=0;s<r.length;s++){const o=r[s];typeof o=="function"?o():nm(e[s],null)}}}}function kr(...e){return p.useCallback(Ba(...e),e)}var pP=Symbol.for("react.lazy"),ha=va[" use ".trim().toString()];function mP(e){return typeof e=="object"&&e!==null&&"then"in e}function Q0(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===pP&&"_payload"in e&&mP(e._payload)}function Z0(e){const t=yP(e),n=p.forwardRef((r,s)=>{let{children:o,...i}=r;Q0(o)&&typeof ha=="function"&&(o=ha(o._payload));const a=p.Children.toArray(o),l=a.find(xP);if(l){const c=l.props.children,d=a.map(u=>u===l?p.Children.count(c)>1?p.Children.only(null):p.isValidElement(c)?c.props.children:null:u);return h.jsx(t,{...i,ref:s,children:p.isValidElement(c)?p.cloneElement(c,void 0,d):null})}return h.jsx(t,{...i,ref:s,children:o})});return n.displayName=`${e}.Slot`,n}var gP=Z0("Slot");function yP(e){const t=p.forwardRef((n,r)=>{let{children:s,...o}=n;if(Q0(s)&&typeof ha=="function"&&(s=ha(s._payload)),p.isValidElement(s)){const i=SP(s),a=wP(o,s.props);return s.type!==p.Fragment&&(a.ref=r?Ba(r,i):i),p.cloneElement(s,a)}return p.Children.count(s)>1?p.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var vP=Symbol("radix.slottable");function xP(e){return p.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===vP}function wP(e,t){const n={...t};for(const r in t){const s=e[r],o=t[r];/^on[A-Z]/.test(r)?s&&o?n[r]=(...a)=>{const l=o(...a);return s(...a),l}:s&&(n[r]=s):r==="style"?n[r]={...s,...o}:r==="className"&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}function SP(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const rm=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,sm=$0,af=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return sm(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:s,defaultVariants:o}=t,i=Object.keys(s).map(c=>{const d=n==null?void 0:n[c],u=o==null?void 0:o[c];if(d===null)return null;const f=rm(d)||rm(u);return s[c][f]}),a=n&&Object.entries(n).reduce((c,d)=>{let[u,f]=d;return f===void 0||(c[u]=f),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:u,className:f,...y}=d;return Object.entries(y).every(w=>{let[x,S]=w;return Array.isArray(S)?S.includes({...o,...a}[x]):{...o,...a}[x]===S})?[...c,u,f]:c},[]);return sm(e,i,l,n==null?void 0:n.class,n==null?void 0:n.className)},EP=af("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ie=p.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...s},o)=>{const i=r?gP:"button";return h.jsx(i,{className:q(EP({variant:t,size:n,className:e})),ref:o,...s})});ie.displayName="Button";const go=p.forwardRef(({className:e,type:t,...n},r)=>h.jsx("input",{type:t,className:q("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...n}));go.displayName="Input";var kP=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],bP=kP.reduce((e,t)=>{const n=Z0(`Primitive.${t}`),r=p.forwardRef((s,o)=>{const{asChild:i,...a}=s,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),h.jsx(l,{...a,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),CP="Label",q0=p.forwardRef((e,t)=>h.jsx(bP.label,{...e,ref:t,onMouseDown:n=>{var s;n.target.closest("button, input, select, textarea")||((s=e.onMouseDown)==null||s.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));q0.displayName=CP;var J0=q0;const TP=af("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),jn=p.forwardRef(({className:e,...t},n)=>h.jsx(J0,{ref:n,className:q(TP(),e),...t}));jn.displayName=J0.displayName;const om=e=>{let t;const n=new Set,r=(c,d)=>{const u=typeof c=="function"?c(t):c;if(!Object.is(u,t)){const f=t;t=d??(typeof u!="object"||u===null)?u:Object.assign({},t,u),n.forEach(y=>y(t,f))}},s=()=>t,a={setState:r,getState:s,getInitialState:()=>l,subscribe:c=>(n.add(c),()=>n.delete(c))},l=t=e(r,s,a);return a},PP=e=>e?om(e):om,NP=e=>e;function jP(e,t=NP){const n=R.useSyncExternalStore(e.subscribe,R.useCallback(()=>t(e.getState()),[e,t]),R.useCallback(()=>t(e.getInitialState()),[e,t]));return R.useDebugValue(n),n}const im=e=>{const t=PP(e),n=r=>jP(t,r);return Object.assign(n,t),n},ex=e=>e?im(e):im,Zr={token:"cc_web_token",theme:"cc_web_theme",viewMode:e=>`cc_viewmode_${e}`,panelFileTree:"cc_panel_filetree",panelShortcuts:"cc_panel_shortcuts",fileZoom:"cc_file_zoom",skillhubAuthor:"ccweb_skillhub_author",projectOrder:"cc_project_order"};function RP(e,t,n){try{const r=localStorage.getItem(e);return r===null?t:n?JSON.parse(r):r}catch{return t}}function tx(e,t,n){try{localStorage.setItem(e,n?JSON.stringify(t):String(t))}catch{}}function MP(e){try{localStorage.removeItem(e)}catch{}}function AP(e,t,n){const r=(n==null?void 0:n.parse)??!1,[s,o]=p.useState(()=>{try{const a=localStorage.getItem(e);return a===null?t:r?JSON.parse(a):a}catch{return t}}),i=p.useCallback(a=>{o(l=>{const c=typeof a=="function"?a(l):a;try{localStorage.setItem(e,r?JSON.stringify(c):String(c))}catch{}return c})},[e,r]);return[s,i]}const xr=ex(e=>({token:localStorage.getItem(Zr.token),setToken:t=>{tx(Zr.token,t),e({token:t})},clearToken:()=>{MP(Zr.token),e({token:null})}})),DP=()=>xr.getState().token,LP=e=>xr.getState().setToken(e),OP=()=>xr.getState().clearToken();let Gl=null;async function _P(){return Gl||(Gl=(await bo(()=>Promise.resolve().then(()=>CN),void 0)).getProjects),Gl()}const am=ex((e,t)=>({projects:[],loading:!1,error:null,hasFetched:!1,fetchProjects:async()=>{if(!t().loading){e({loading:!0,error:null});try{const n=await _P();e({projects:n,hasFetched:!0})}catch(n){e({error:n instanceof Error?n.message:"Failed to load projects"})}finally{e({loading:!1})}}},addProject:n=>e(r=>({projects:[...r.projects,n]})),updateProject:n=>e(r=>({projects:r.projects.map(s=>s.id===n.id?n:s)})),removeProject:n=>e(r=>({projects:r.projects.filter(s=>s.id!==n)})),setProjects:n=>e({projects:n})})),$a="";function Mo(){return DP()}function IP(e){LP(e)}function nx(){OP()}async function F(e,t,n,r=!0,s){const o={"Content-Type":"application/json"};if(r){const a=Mo();a&&(o.Authorization=`Bearer ${a}`)}const i=await fetch(`${$a}${t}`,{method:e,headers:o,body:n!==void 0?JSON.stringify(n):void 0,signal:s});if(i.status===401)throw nx(),window.location.pathname!=="/login"&&(window.location.href="/login"),new Error("Unauthorized");if(!i.ok){let a=`HTTP ${i.status}`;try{const l=await i.json();l.error&&(a=l.error)}catch{}throw new Error(a)}return i.json()}async function rx(e,t){return(await F("POST","/api/auth/login",{username:e,password:t},!1)).token}function pa(){const e=window.location.hostname;return e==="localhost"||e==="127.0.0.1"||e==="::1"}async function lf(){return(await F("GET","/api/auth/local-token",void 0,!1)).token}async function VP(){return(await F("GET","/api/projects/workspace")).workspace}async function FP(){return F("GET","/api/projects")}async function sx(){return F("GET","/api/projects/users")}async function ox(e,t){return F("PUT",`/api/projects/${e}/shares`,{shares:t})}async function ix(e){return F("POST","/api/projects",e)}async function ax(e){return F("POST","/api/projects/open",{folderPath:e})}async function lx(e){await F("DELETE",`/api/projects/${e}`)}async function zP(e){return F("PATCH",`/api/projects/${e}/stop`)}async function BP(e){return F("PATCH",`/api/projects/${e}/start`)}async function ux(e){return F("PATCH",`/api/projects/${e}/archive`)}async function cx(e){return F("PATCH",`/api/projects/${e}/unarchive`)}async function $P(e,t){return F("GET",`/api/projects/${e}/sessions`,void 0,!0,t)}async function UP(e,t,n){return F("GET",`/api/projects/${e}/sessions/${t}`,void 0,!0,n)}async function WP(e){return F("GET","/api/projects/activity",void 0,!0,e)}async function dx(){return F("GET","/api/shortcuts")}async function fx(e){return F("POST","/api/shortcuts",e)}async function hx(e,t){return F("PUT",`/api/shortcuts/${e}`,t)}async function px(e){await F("DELETE",`/api/shortcuts/${e}`)}async function HP(e){return F("GET",`/api/shortcuts/project/${e}`)}async function GP(e,t){return F("POST",`/api/shortcuts/project/${e}`,t)}async function KP(e,t,n){return F("PUT",`/api/shortcuts/project/${e}/${t}`,n)}async function YP(e,t){await F("DELETE",`/api/shortcuts/project/${e}/${t}`)}async function XP(){return F("GET","/api/skillhub/skills")}async function QP(e){await F("POST","/api/skillhub/submit",e)}async function ZP(e){return F("POST",`/api/skillhub/download/${e}`)}async function mx(){return F("GET","/api/projects/usage")}async function gx(){return F("GET","/api/projects/usage?refresh=true")}async function yx(e){const t=e?`?path=${encodeURIComponent(e)}`:"";return F("GET",`/api/filesystem${t}`)}function qP(e){return`${$a}/api/filesystem/raw?path=${encodeURIComponent(e)}`}async function JP(e,t){const n=new FormData;n.append("path",e);for(const i of t)n.append("files",i);const r={},s=Mo();s&&(r.Authorization=`Bearer ${s}`);const o=await fetch(`${$a}/api/filesystem/upload`,{method:"POST",headers:r,body:n});if(!o.ok){const i=await o.json().catch(()=>({}));throw new Error(i.error||`Upload failed: ${o.status}`)}return o.json()}async function vx(e,t){return F("POST","/api/filesystem/mkdir",{path:e,name:t})}async function eN(e){return F("GET",`/api/filesystem/file?path=${encodeURIComponent(e)}`)}async function tN(e,t){return F("PUT","/api/filesystem/file",{path:e,content:t})}async function nN(){return F("GET","/api/update/check-running")}async function rN(){return F("POST","/api/update/prepare")}async function sN(){return F("GET","/api/backup/built-in-oauth")}async function oN(){return F("GET","/api/backup/providers")}async function iN(e){return F("POST","/api/backup/providers",e)}async function aN(e){await F("DELETE",`/api/backup/providers/${e}`)}async function lN(e){return F("GET",`/api/backup/auth/${e}/url`)}async function uN(e){return F("POST",`/api/backup/run/${e}`)}async function cN(){return F("GET","/api/backup/schedule")}async function dN(e){return F("PUT","/api/backup/schedule",e)}async function fN(){return F("GET","/api/backup/excludes")}async function hN(e){return F("PUT","/api/backup/excludes",{patterns:e})}async function pN(){return F("GET","/api/backup/history")}async function mN(){return F("GET","/api/notify/config")}async function gN(e){return F("PUT","/api/notify/config",e)}async function yN(e){return F("GET",`/api/projects/${e}/git/status`)}async function vN(e,t){const n=t?`?file=${encodeURIComponent(t)}`:"";return F("GET",`/api/projects/${e}/git/diff${n}`)}async function xN(e,t){await F("POST",`/api/projects/${e}/git/add`,{files:t})}async function wN(e,t){await F("POST",`/api/projects/${e}/git/commit`,{message:t})}async function xx(e){return F("GET",`/api/projects/sessions/search?q=${encodeURIComponent(e)}`)}async function SN(e,t){return F("PATCH",`/api/projects/${e}/tags`,{tags:t})}async function EN(e){return F("GET",`/api/projects/${e}/todos`)}async function kN(e,t){return F("POST",`/api/sessions/${e}/share`,{expiryDays:t})}async function bN(e){const t=await fetch(`${$a}/api/share/${e}`);if(!t.ok){let n=`HTTP ${t.status}`;try{const r=await t.json();r.error&&(n=r.error)}catch{}throw new Error(n)}return t.json()}const CN=Object.freeze(Object.defineProperty({__proto__:null,addBackupProvider:iN,archiveProject:ux,browseFilesystem:yx,checkRunningProjects:nN,clearToken:nx,createFolder:vx,createGlobalShortcut:fx,createProject:ix,createProjectShortcut:GP,deleteBackupProvider:aN,deleteGlobalShortcut:px,deleteProject:lx,deleteProjectShortcut:YP,downloadSkillFromHub:ZP,getAllUsers:sx,getBackupAuthUrl:lN,getBackupExcludes:fN,getBackupHistory:pN,getBackupProviders:oN,getBackupSchedule:cN,getBuiltInOAuthTypes:sN,getGitDiff:vN,getGitStatus:yN,getGlobalShortcuts:dx,getLocalToken:lf,getNotifyConfig:mN,getProjectShortcuts:HP,getProjectTodos:EN,getProjects:FP,getProjectsActivity:WP,getRawFileUrl:qP,getSession:UP,getSessions:$P,getSharedSession:bN,getSkillHubSkills:XP,getToken:Mo,getUsage:mx,getWorkspace:VP,gitAdd:xN,gitCommit:wN,isLocalAccess:pa,login:rx,openProject:ax,prepareForUpdate:rN,readFile:eN,refreshUsage:gx,searchSessions:xx,setToken:IP,shareSession:kN,startProject:BP,stopProject:zP,submitSkillToHub:QP,triggerBackup:uN,unarchiveProject:cx,updateBackupExcludes:hN,updateBackupSchedule:dN,updateGlobalShortcut:hx,updateNotifyConfig:gN,updateProjectShares:ox,updateProjectShortcut:KP,updateProjectTags:SN,uploadFiles:JP,writeFile:tN},Symbol.toStringTag,{value:"Module"}));function TN(){const e=Oa(),t=xr(u=>u.setToken),[n,r]=p.useState(""),[s,o]=p.useState(""),[i,a]=p.useState(null),[l,c]=p.useState(!1);p.useEffect(()=>{if(!pa())return;let u=!1;return(async()=>{try{const f=await lf();u||(t(f),e("/",{replace:!0}))}catch{}})(),()=>{u=!0}},[e,t]);const d=async u=>{u.preventDefault(),a(null),c(!0);try{const f=await rx(n,s);t(f),e("/")}catch(f){a(f instanceof Error?f.message:"Login failed")}finally{c(!1)}};return h.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background p-4",children:h.jsx(Vn.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.4,ease:"easeOut"},className:"w-full max-w-sm",children:h.jsxs(nf,{children:[h.jsxs(rf,{className:"text-center",children:[h.jsx(sf,{className:"text-2xl",children:"CC Web"}),h.jsx(Y0,{children:pa()?"Connecting locally...":"Sign in to manage your Claude projects"})]}),h.jsxs("form",{onSubmit:u=>void d(u),children:[h.jsxs(of,{className:"space-y-4",children:[h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{htmlFor:"username",children:"Username"}),h.jsx(go,{id:"username",type:"text",autoComplete:"username",value:n,onChange:u=>r(u.target.value),required:!0,autoFocus:!0})]}),h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{htmlFor:"password",children:"Password"}),h.jsx(go,{id:"password",type:"password",autoComplete:"current-password",value:s,onChange:u=>o(u.target.value),required:!0})]}),h.jsx(qd,{children:i&&h.jsx(Vn.p,{initial:{opacity:0,x:-8},animate:{opacity:1,x:0},exit:{opacity:0,x:-8},transition:{duration:.2},className:"text-sm text-destructive",children:i})})]}),h.jsx(X0,{children:h.jsx(Vn.div,{className:"w-full",whileTap:{scale:.98},children:h.jsx(ie,{type:"submit",className:"w-full",disabled:l,children:l?"Signing in...":"Sign In"})})})]})]})})})}/**
77
+ * @license lucide-react v0.309.0 - ISC
78
+ *
79
+ * This source code is licensed under the ISC license.
80
+ * See the LICENSE file in the root directory of this source tree.
81
+ */var PN={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"};/**
82
+ * @license lucide-react v0.309.0 - ISC
83
+ *
84
+ * This source code is licensed under the ISC license.
85
+ * See the LICENSE file in the root directory of this source tree.
86
+ */const NN=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase().trim(),ne=(e,t)=>{const n=p.forwardRef(({color:r="currentColor",size:s=24,strokeWidth:o=2,absoluteStrokeWidth:i,className:a="",children:l,...c},d)=>p.createElement("svg",{ref:d,...PN,width:s,height:s,stroke:r,strokeWidth:i?Number(o)*24/Number(s):o,className:["lucide",`lucide-${NN(e)}`,a].join(" "),...c},[...t.map(([u,f])=>p.createElement(u,f)),...Array.isArray(l)?l:[l]]));return n.displayName=`${e}`,n};/**
87
+ * @license lucide-react v0.309.0 - ISC
88
+ *
89
+ * This source code is licensed under the ISC license.
90
+ * See the LICENSE file in the root directory of this source tree.
91
+ */const jN=ne("ArchiveRestore",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h2",key:"tvwodi"}],["path",{d:"M20 8v11a2 2 0 0 1-2 2h-2",key:"1gkqxj"}],["path",{d:"m9 15 3-3 3 3",key:"1pd0qc"}],["path",{d:"M12 12v9",key:"192myk"}]]);/**
92
+ * @license lucide-react v0.309.0 - ISC
93
+ *
94
+ * This source code is licensed under the ISC license.
95
+ * See the LICENSE file in the root directory of this source tree.
96
+ */const RN=ne("Archive",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]);/**
97
+ * @license lucide-react v0.309.0 - ISC
98
+ *
99
+ * This source code is licensed under the ISC license.
100
+ * See the LICENSE file in the root directory of this source tree.
101
+ */const MN=ne("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
102
+ * @license lucide-react v0.309.0 - ISC
103
+ *
104
+ * This source code is licensed under the ISC license.
105
+ * See the LICENSE file in the root directory of this source tree.
106
+ */const AN=ne("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
107
+ * @license lucide-react v0.309.0 - ISC
108
+ *
109
+ * This source code is licensed under the ISC license.
110
+ * See the LICENSE file in the root directory of this source tree.
111
+ */const wx=ne("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
112
+ * @license lucide-react v0.309.0 - ISC
113
+ *
114
+ * This source code is licensed under the ISC license.
115
+ * See the LICENSE file in the root directory of this source tree.
116
+ */const DN=ne("Eye",[["path",{d:"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z",key:"rwhkz3"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
117
+ * @license lucide-react v0.309.0 - ISC
118
+ *
119
+ * This source code is licensed under the ISC license.
120
+ * See the LICENSE file in the root directory of this source tree.
121
+ */const LN=ne("File",[["path",{d:"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z",key:"1nnpy2"}],["polyline",{points:"14 2 14 8 20 8",key:"1ew0cm"}]]);/**
122
+ * @license lucide-react v0.309.0 - ISC
123
+ *
124
+ * This source code is licensed under the ISC license.
125
+ * See the LICENSE file in the root directory of this source tree.
126
+ */const Ec=ne("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
127
+ * @license lucide-react v0.309.0 - ISC
128
+ *
129
+ * This source code is licensed under the ISC license.
130
+ * See the LICENSE file in the root directory of this source tree.
131
+ */const ON=ne("FolderPlus",[["path",{d:"M12 10v6",key:"1bos4e"}],["path",{d:"M9 13h6",key:"1uhe8q"}],["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);/**
132
+ * @license lucide-react v0.309.0 - ISC
133
+ *
134
+ * This source code is licensed under the ISC license.
135
+ * See the LICENSE file in the root directory of this source tree.
136
+ */const lm=ne("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);/**
137
+ * @license lucide-react v0.309.0 - ISC
138
+ *
139
+ * This source code is licensed under the ISC license.
140
+ * See the LICENSE file in the root directory of this source tree.
141
+ */const Kl=ne("GitMerge",[["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}],["circle",{cx:"6",cy:"6",r:"3",key:"1lh9wr"}],["path",{d:"M6 21V9a9 9 0 0 0 9 9",key:"7kw0sc"}]]);/**
142
+ * @license lucide-react v0.309.0 - ISC
143
+ *
144
+ * This source code is licensed under the ISC license.
145
+ * See the LICENSE file in the root directory of this source tree.
146
+ */const _N=ne("Home",[["path",{d:"m3 9 9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"y5dka4"}],["polyline",{points:"9 22 9 12 15 12 15 22",key:"e2us08"}]]);/**
147
+ * @license lucide-react v0.309.0 - ISC
148
+ *
149
+ * This source code is licensed under the ISC license.
150
+ * See the LICENSE file in the root directory of this source tree.
151
+ */const IN=ne("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
152
+ * @license lucide-react v0.309.0 - ISC
153
+ *
154
+ * This source code is licensed under the ISC license.
155
+ * See the LICENSE file in the root directory of this source tree.
156
+ */const VN=ne("Maximize",[["path",{d:"M8 3H5a2 2 0 0 0-2 2v3",key:"1dcmit"}],["path",{d:"M21 8V5a2 2 0 0 0-2-2h-3",key:"1e4gt3"}],["path",{d:"M3 16v3a2 2 0 0 0 2 2h3",key:"wsl5sc"}],["path",{d:"M16 21h3a2 2 0 0 0 2-2v-3",key:"18trek"}]]);/**
157
+ * @license lucide-react v0.309.0 - ISC
158
+ *
159
+ * This source code is licensed under the ISC license.
160
+ * See the LICENSE file in the root directory of this source tree.
161
+ */const FN=ne("Minimize",[["path",{d:"M8 3v3a2 2 0 0 1-2 2H3",key:"hohbtr"}],["path",{d:"M21 8h-3a2 2 0 0 1-2-2V3",key:"5jw1f3"}],["path",{d:"M3 16h3a2 2 0 0 1 2 2v3",key:"198tvr"}],["path",{d:"M16 21v-3a2 2 0 0 1 2-2h3",key:"ph8mxp"}]]);/**
162
+ * @license lucide-react v0.309.0 - ISC
163
+ *
164
+ * This source code is licensed under the ISC license.
165
+ * See the LICENSE file in the root directory of this source tree.
166
+ */const zN=ne("Monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);/**
167
+ * @license lucide-react v0.309.0 - ISC
168
+ *
169
+ * This source code is licensed under the ISC license.
170
+ * See the LICENSE file in the root directory of this source tree.
171
+ */const BN=ne("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
172
+ * @license lucide-react v0.309.0 - ISC
173
+ *
174
+ * This source code is licensed under the ISC license.
175
+ * See the LICENSE file in the root directory of this source tree.
176
+ */const Sx=ne("Pencil",[["path",{d:"M17 3a2.85 2.83 0 1 1 4 4L7.5 20.5 2 22l1.5-5.5Z",key:"5qss01"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);/**
177
+ * @license lucide-react v0.309.0 - ISC
178
+ *
179
+ * This source code is licensed under the ISC license.
180
+ * See the LICENSE file in the root directory of this source tree.
181
+ */const ma=ne("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
182
+ * @license lucide-react v0.309.0 - ISC
183
+ *
184
+ * This source code is licensed under the ISC license.
185
+ * See the LICENSE file in the root directory of this source tree.
186
+ */const $N=ne("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
187
+ * @license lucide-react v0.309.0 - ISC
188
+ *
189
+ * This source code is licensed under the ISC license.
190
+ * See the LICENSE file in the root directory of this source tree.
191
+ */const UN=ne("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
192
+ * @license lucide-react v0.309.0 - ISC
193
+ *
194
+ * This source code is licensed under the ISC license.
195
+ * See the LICENSE file in the root directory of this source tree.
196
+ */const WN=ne("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
197
+ * @license lucide-react v0.309.0 - ISC
198
+ *
199
+ * This source code is licensed under the ISC license.
200
+ * See the LICENSE file in the root directory of this source tree.
201
+ */const HN=ne("Sparkles",[["path",{d:"m12 3-1.912 5.813a2 2 0 0 1-1.275 1.275L3 12l5.813 1.912a2 2 0 0 1 1.275 1.275L12 21l1.912-5.813a2 2 0 0 1 1.275-1.275L21 12l-5.813-1.912a2 2 0 0 1-1.275-1.275L12 3Z",key:"17u4zn"}],["path",{d:"M5 3v4",key:"bklmnn"}],["path",{d:"M19 17v4",key:"iiml17"}],["path",{d:"M3 5h4",key:"nem4j1"}],["path",{d:"M17 19h4",key:"lbex7p"}]]);/**
202
+ * @license lucide-react v0.309.0 - ISC
203
+ *
204
+ * This source code is licensed under the ISC license.
205
+ * See the LICENSE file in the root directory of this source tree.
206
+ */const GN=ne("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"}]]);/**
207
+ * @license lucide-react v0.309.0 - ISC
208
+ *
209
+ * This source code is licensed under the ISC license.
210
+ * See the LICENSE file in the root directory of this source tree.
211
+ */const um=ne("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]);/**
212
+ * @license lucide-react v0.309.0 - ISC
213
+ *
214
+ * This source code is licensed under the ISC license.
215
+ * See the LICENSE file in the root directory of this source tree.
216
+ */const Ex=ne("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
217
+ * @license lucide-react v0.309.0 - ISC
218
+ *
219
+ * This source code is licensed under the ISC license.
220
+ * See the LICENSE file in the root directory of this source tree.
221
+ */const kc=ne("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
222
+ * @license lucide-react v0.309.0 - ISC
223
+ *
224
+ * This source code is licensed under the ISC license.
225
+ * See the LICENSE file in the root directory of this source tree.
226
+ */const uf=ne("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
227
+ * @license lucide-react v0.309.0 - ISC
228
+ *
229
+ * This source code is licensed under the ISC license.
230
+ * See the LICENSE file in the root directory of this source tree.
231
+ */const cm=ne("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]),KN=af("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function rr({className:e,variant:t,...n}){return h.jsx("div",{className:q(KN({variant:t}),e),...n})}function Fn(e,t,{checkForDefaultPrevented:n=!0}={}){return function(s){if(e==null||e(s),n===!1||!s.defaultPrevented)return t==null?void 0:t(s)}}function YN(e,t){const n=p.createContext(t),r=o=>{const{children:i,...a}=o,l=p.useMemo(()=>a,Object.values(a));return h.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function s(o){const i=p.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,s]}function XN(e,t=[]){let n=[];function r(o,i){const a=p.createContext(i),l=n.length;n=[...n,i];const c=u=>{var m;const{scope:f,children:y,...w}=u,x=((m=f==null?void 0:f[e])==null?void 0:m[l])||a,S=p.useMemo(()=>w,Object.values(w));return h.jsx(x.Provider,{value:S,children:y})};c.displayName=o+"Provider";function d(u,f){var x;const y=((x=f==null?void 0:f[e])==null?void 0:x[l])||a,w=p.useContext(y);if(w)return w;if(i!==void 0)return i;throw new Error(`\`${u}\` must be used within \`${o}\``)}return[c,d]}const s=()=>{const o=n.map(i=>p.createContext(i));return function(a){const l=(a==null?void 0:a[e])||o;return p.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return s.scopeName=e,[r,QN(s,...t)]}function QN(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(o){const i=r.reduce((a,{useScope:l,scopeName:c})=>{const u=l(o)[`__scope${c}`];return{...a,...u}},{});return p.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}var yo=globalThis!=null&&globalThis.document?p.useLayoutEffect:()=>{},ZN=va[" useId ".trim().toString()]||(()=>{}),qN=0;function Yl(e){const[t,n]=p.useState(ZN());return yo(()=>{n(r=>r??String(qN++))},[e]),e||(t?`radix-${t}`:"")}var JN=va[" useInsertionEffect ".trim().toString()]||yo;function ej({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[s,o,i]=tj({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:s;{const d=p.useRef(e!==void 0);p.useEffect(()=>{const u=d.current;u!==a&&console.warn(`${r} is changing from ${u?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=a},[a,r])}const c=p.useCallback(d=>{var u;if(a){const f=nj(d)?d(e):d;f!==e&&((u=i.current)==null||u.call(i,f))}else o(d)},[a,e,o,i]);return[l,c]}function tj({defaultProp:e,onChange:t}){const[n,r]=p.useState(e),s=p.useRef(n),o=p.useRef(t);return JN(()=>{o.current=t},[t]),p.useEffect(()=>{var i;s.current!==n&&((i=o.current)==null||i.call(o,n),s.current=n)},[n,s]),[n,r,o]}function nj(e){return typeof e=="function"}function rj(e){const t=sj(e),n=p.forwardRef((r,s)=>{const{children:o,...i}=r,a=p.Children.toArray(o),l=a.find(ij);if(l){const c=l.props.children,d=a.map(u=>u===l?p.Children.count(c)>1?p.Children.only(null):p.isValidElement(c)?c.props.children:null:u);return h.jsx(t,{...i,ref:s,children:p.isValidElement(c)?p.cloneElement(c,void 0,d):null})}return h.jsx(t,{...i,ref:s,children:o})});return n.displayName=`${e}.Slot`,n}function sj(e){const t=p.forwardRef((n,r)=>{const{children:s,...o}=n;if(p.isValidElement(s)){const i=lj(s),a=aj(o,s.props);return s.type!==p.Fragment&&(a.ref=r?Ba(r,i):i),p.cloneElement(s,a)}return p.Children.count(s)>1?p.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var oj=Symbol("radix.slottable");function ij(e){return p.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===oj}function aj(e,t){const n={...t};for(const r in t){const s=e[r],o=t[r];/^on[A-Z]/.test(r)?s&&o?n[r]=(...a)=>{const l=o(...a);return s(...a),l}:s&&(n[r]=s):r==="style"?n[r]={...s,...o}:r==="className"&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}function lj(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var uj=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],un=uj.reduce((e,t)=>{const n=rj(`Primitive.${t}`),r=p.forwardRef((s,o)=>{const{asChild:i,...a}=s,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),h.jsx(l,{...a,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function cj(e,t){e&&Sd.flushSync(()=>e.dispatchEvent(t))}function vo(e){const t=p.useRef(e);return p.useEffect(()=>{t.current=e}),p.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function dj(e,t=globalThis==null?void 0:globalThis.document){const n=vo(e);p.useEffect(()=>{const r=s=>{s.key==="Escape"&&n(s)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var fj="DismissableLayer",bc="dismissableLayer.update",hj="dismissableLayer.pointerDownOutside",pj="dismissableLayer.focusOutside",dm,kx=p.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),bx=p.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:o,onInteractOutside:i,onDismiss:a,...l}=e,c=p.useContext(kx),[d,u]=p.useState(null),f=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,y]=p.useState({}),w=kr(t,k=>u(k)),x=Array.from(c.layers),[S]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),m=x.indexOf(S),g=d?x.indexOf(d):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,E=g>=m,C=yj(k=>{const b=k.target,A=[...c.branches].some(P=>P.contains(b));!E||A||(s==null||s(k),i==null||i(k),k.defaultPrevented||a==null||a())},f),T=vj(k=>{const b=k.target;[...c.branches].some(P=>P.contains(b))||(o==null||o(k),i==null||i(k),k.defaultPrevented||a==null||a())},f);return dj(k=>{g===c.layers.size-1&&(r==null||r(k),!k.defaultPrevented&&a&&(k.preventDefault(),a()))},f),p.useEffect(()=>{if(d)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(dm=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(d)),c.layers.add(d),fm(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=dm)}},[d,f,n,c]),p.useEffect(()=>()=>{d&&(c.layers.delete(d),c.layersWithOutsidePointerEventsDisabled.delete(d),fm())},[d,c]),p.useEffect(()=>{const k=()=>y({});return document.addEventListener(bc,k),()=>document.removeEventListener(bc,k)},[]),h.jsx(un.div,{...l,ref:w,style:{pointerEvents:v?E?"auto":"none":void 0,...e.style},onFocusCapture:Fn(e.onFocusCapture,T.onFocusCapture),onBlurCapture:Fn(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:Fn(e.onPointerDownCapture,C.onPointerDownCapture)})});bx.displayName=fj;var mj="DismissableLayerBranch",gj=p.forwardRef((e,t)=>{const n=p.useContext(kx),r=p.useRef(null),s=kr(t,r);return p.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),h.jsx(un.div,{...e,ref:s})});gj.displayName=mj;function yj(e,t=globalThis==null?void 0:globalThis.document){const n=vo(e),r=p.useRef(!1),s=p.useRef(()=>{});return p.useEffect(()=>{const o=a=>{if(a.target&&!r.current){let l=function(){Cx(hj,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",s.current),s.current=l,t.addEventListener("click",s.current,{once:!0})):l()}else t.removeEventListener("click",s.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",o),t.removeEventListener("click",s.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function vj(e,t=globalThis==null?void 0:globalThis.document){const n=vo(e),r=p.useRef(!1);return p.useEffect(()=>{const s=o=>{o.target&&!r.current&&Cx(pj,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",s),()=>t.removeEventListener("focusin",s)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function fm(){const e=new CustomEvent(bc);document.dispatchEvent(e)}function Cx(e,t,n,{discrete:r}){const s=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&s.addEventListener(e,t,{once:!0}),r?cj(s,o):s.dispatchEvent(o)}var Xl="focusScope.autoFocusOnMount",Ql="focusScope.autoFocusOnUnmount",hm={bubbles:!1,cancelable:!0},xj="FocusScope",Tx=p.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:s,onUnmountAutoFocus:o,...i}=e,[a,l]=p.useState(null),c=vo(s),d=vo(o),u=p.useRef(null),f=kr(t,x=>l(x)),y=p.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;p.useEffect(()=>{if(r){let x=function(v){if(y.paused||!a)return;const E=v.target;a.contains(E)?u.current=E:wn(u.current,{select:!0})},S=function(v){if(y.paused||!a)return;const E=v.relatedTarget;E!==null&&(a.contains(E)||wn(u.current,{select:!0}))},m=function(v){if(document.activeElement===document.body)for(const C of v)C.removedNodes.length>0&&wn(a)};document.addEventListener("focusin",x),document.addEventListener("focusout",S);const g=new MutationObserver(m);return a&&g.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",x),document.removeEventListener("focusout",S),g.disconnect()}}},[r,a,y.paused]),p.useEffect(()=>{if(a){mm.add(y);const x=document.activeElement;if(!a.contains(x)){const m=new CustomEvent(Xl,hm);a.addEventListener(Xl,c),a.dispatchEvent(m),m.defaultPrevented||(wj(Cj(Px(a)),{select:!0}),document.activeElement===x&&wn(a))}return()=>{a.removeEventListener(Xl,c),setTimeout(()=>{const m=new CustomEvent(Ql,hm);a.addEventListener(Ql,d),a.dispatchEvent(m),m.defaultPrevented||wn(x??document.body,{select:!0}),a.removeEventListener(Ql,d),mm.remove(y)},0)}}},[a,c,d,y]);const w=p.useCallback(x=>{if(!n&&!r||y.paused)return;const S=x.key==="Tab"&&!x.altKey&&!x.ctrlKey&&!x.metaKey,m=document.activeElement;if(S&&m){const g=x.currentTarget,[v,E]=Sj(g);v&&E?!x.shiftKey&&m===E?(x.preventDefault(),n&&wn(v,{select:!0})):x.shiftKey&&m===v&&(x.preventDefault(),n&&wn(E,{select:!0})):m===g&&x.preventDefault()}},[n,r,y.paused]);return h.jsx(un.div,{tabIndex:-1,...i,ref:f,onKeyDown:w})});Tx.displayName=xj;function wj(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(wn(r,{select:t}),document.activeElement!==n)return}function Sj(e){const t=Px(e),n=pm(t,e),r=pm(t.reverse(),e);return[n,r]}function Px(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const s=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||s?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function pm(e,t){for(const n of e)if(!Ej(n,{upTo:t}))return n}function Ej(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function kj(e){return e instanceof HTMLInputElement&&"select"in e}function wn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&kj(e)&&t&&e.select()}}var mm=bj();function bj(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=gm(e,t),e.unshift(t)},remove(t){var n;e=gm(e,t),(n=e[0])==null||n.resume()}}}function gm(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Cj(e){return e.filter(t=>t.tagName!=="A")}var Tj="Portal",Nx=p.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[s,o]=p.useState(!1);yo(()=>o(!0),[]);const i=n||s&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?By.createPortal(h.jsx(un.div,{...r,ref:t}),i):null});Nx.displayName=Tj;function Pj(e,t){return p.useReducer((n,r)=>t[n][r]??n,e)}var Ua=e=>{const{present:t,children:n}=e,r=Nj(t),s=typeof n=="function"?n({present:r.isPresent}):p.Children.only(n),o=kr(r.ref,jj(s));return typeof n=="function"||r.isPresent?p.cloneElement(s,{ref:o}):null};Ua.displayName="Presence";function Nj(e){const[t,n]=p.useState(),r=p.useRef(null),s=p.useRef(e),o=p.useRef("none"),i=e?"mounted":"unmounted",[a,l]=Pj(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return p.useEffect(()=>{const c=ri(r.current);o.current=a==="mounted"?c:"none"},[a]),yo(()=>{const c=r.current,d=s.current;if(d!==e){const f=o.current,y=ri(c);e?l("MOUNT"):y==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(d&&f!==y?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),yo(()=>{if(t){let c;const d=t.ownerDocument.defaultView??window,u=y=>{const x=ri(r.current).includes(CSS.escape(y.animationName));if(y.target===t&&x&&(l("ANIMATION_END"),!s.current)){const S=t.style.animationFillMode;t.style.animationFillMode="forwards",c=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=S)})}},f=y=>{y.target===t&&(o.current=ri(r.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{d.clearTimeout(c),t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:p.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function ri(e){return(e==null?void 0:e.animationName)||"none"}function jj(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Zl=0;function Rj(){p.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ym()),document.body.insertAdjacentElement("beforeend",e[1]??ym()),Zl++,()=>{Zl===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Zl--}},[])}function ym(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Wt=function(){return Wt=Object.assign||function(t){for(var n,r=1,s=arguments.length;r<s;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},Wt.apply(this,arguments)};function jx(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 s=0,r=Object.getOwnPropertySymbols(e);s<r.length;s++)t.indexOf(r[s])<0&&Object.prototype.propertyIsEnumerable.call(e,r[s])&&(n[r[s]]=e[r[s]]);return n}function Mj(e,t,n){if(n||arguments.length===2)for(var r=0,s=t.length,o;r<s;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Mi="right-scroll-bar-position",Ai="width-before-scroll-bar",Aj="with-scroll-bars-hidden",Dj="--removed-body-scroll-bar-size";function ql(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Lj(e,t){var n=p.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var s=n.value;s!==r&&(n.value=r,n.callback(r,s))}}}})[0];return n.callback=t,n.facade}var Oj=typeof window<"u"?p.useLayoutEffect:p.useEffect,vm=new WeakMap;function _j(e,t){var n=Lj(null,function(r){return e.forEach(function(s){return ql(s,r)})});return Oj(function(){var r=vm.get(n);if(r){var s=new Set(r),o=new Set(e),i=n.current;s.forEach(function(a){o.has(a)||ql(a,null)}),o.forEach(function(a){s.has(a)||ql(a,i)})}vm.set(n,e)},[e]),n}function Ij(e){return e}function Vj(e,t){t===void 0&&(t=Ij);var n=[],r=!1,s={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(o){var i=t(o,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(o){for(r=!0;n.length;){var i=n;n=[],i.forEach(o)}n={push:function(a){return o(a)},filter:function(){return n}}},assignMedium:function(o){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(o),i=n}var l=function(){var d=i;i=[],d.forEach(o)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(d){i.push(d),c()},filter:function(d){return i=i.filter(d),n}}}};return s}function Fj(e){e===void 0&&(e={});var t=Vj(null);return t.options=Wt({async:!0,ssr:!1},e),t}var Rx=function(e){var t=e.sideCar,n=jx(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return p.createElement(r,Wt({},n))};Rx.isSideCarExport=!0;function zj(e,t){return e.useMedium(t),Rx}var Mx=Fj(),Jl=function(){},Wa=p.forwardRef(function(e,t){var n=p.useRef(null),r=p.useState({onScrollCapture:Jl,onWheelCapture:Jl,onTouchMoveCapture:Jl}),s=r[0],o=r[1],i=e.forwardProps,a=e.children,l=e.className,c=e.removeScrollBar,d=e.enabled,u=e.shards,f=e.sideCar,y=e.noRelative,w=e.noIsolation,x=e.inert,S=e.allowPinchZoom,m=e.as,g=m===void 0?"div":m,v=e.gapMode,E=jx(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),C=f,T=_j([n,t]),k=Wt(Wt({},E),s);return p.createElement(p.Fragment,null,d&&p.createElement(C,{sideCar:Mx,removeScrollBar:c,shards:u,noRelative:y,noIsolation:w,inert:x,setCallbacks:o,allowPinchZoom:!!S,lockRef:n,gapMode:v}),i?p.cloneElement(p.Children.only(a),Wt(Wt({},k),{ref:T})):p.createElement(g,Wt({},k,{className:l,ref:T}),a))});Wa.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Wa.classNames={fullWidth:Ai,zeroRight:Mi};var Bj=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function $j(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Bj();return t&&e.setAttribute("nonce",t),e}function Uj(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Wj(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Hj=function(){var e=0,t=null;return{add:function(n){e==0&&(t=$j())&&(Uj(t,n),Wj(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Gj=function(){var e=Hj();return function(t,n){p.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ax=function(){var e=Gj(),t=function(n){var r=n.styles,s=n.dynamic;return e(r,s),null};return t},Kj={left:0,top:0,right:0,gap:0},eu=function(e){return parseInt(e||"",10)||0},Yj=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],s=t[e==="padding"?"paddingRight":"marginRight"];return[eu(n),eu(r),eu(s)]},Xj=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Kj;var t=Yj(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])}},Qj=Ax(),qr="data-scroll-locked",Zj=function(e,t,n,r){var s=e.left,o=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
232
+ .`.concat(Aj,` {
233
+ overflow: hidden `).concat(r,`;
234
+ padding-right: `).concat(a,"px ").concat(r,`;
235
+ }
236
+ body[`).concat(qr,`] {
237
+ overflow: hidden `).concat(r,`;
238
+ overscroll-behavior: contain;
239
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
240
+ padding-left: `.concat(s,`px;
241
+ padding-top: `).concat(o,`px;
242
+ padding-right: `).concat(i,`px;
243
+ margin-left:0;
244
+ margin-top:0;
245
+ margin-right: `).concat(a,"px ").concat(r,`;
246
+ `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),`
247
+ }
248
+
249
+ .`).concat(Mi,` {
250
+ right: `).concat(a,"px ").concat(r,`;
251
+ }
252
+
253
+ .`).concat(Ai,` {
254
+ margin-right: `).concat(a,"px ").concat(r,`;
255
+ }
256
+
257
+ .`).concat(Mi," .").concat(Mi,` {
258
+ right: 0 `).concat(r,`;
259
+ }
260
+
261
+ .`).concat(Ai," .").concat(Ai,` {
262
+ margin-right: 0 `).concat(r,`;
263
+ }
264
+
265
+ body[`).concat(qr,`] {
266
+ `).concat(Dj,": ").concat(a,`px;
267
+ }
268
+ `)},xm=function(){var e=parseInt(document.body.getAttribute(qr)||"0",10);return isFinite(e)?e:0},qj=function(){p.useEffect(function(){return document.body.setAttribute(qr,(xm()+1).toString()),function(){var e=xm()-1;e<=0?document.body.removeAttribute(qr):document.body.setAttribute(qr,e.toString())}},[])},Jj=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,s=r===void 0?"margin":r;qj();var o=p.useMemo(function(){return Xj(s)},[s]);return p.createElement(Qj,{styles:Zj(o,!t,s,n?"":"!important")})},Cc=!1;if(typeof window<"u")try{var si=Object.defineProperty({},"passive",{get:function(){return Cc=!0,!0}});window.addEventListener("test",si,si),window.removeEventListener("test",si,si)}catch{Cc=!1}var Cr=Cc?{passive:!1}:!1,eR=function(e){return e.tagName==="TEXTAREA"},Dx=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!eR(e)&&n[t]==="visible")},tR=function(e){return Dx(e,"overflowY")},nR=function(e){return Dx(e,"overflowX")},wm=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=Lx(e,r);if(s){var o=Ox(e,r),i=o[1],a=o[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},rR=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},sR=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Lx=function(e,t){return e==="v"?tR(t):nR(t)},Ox=function(e,t){return e==="v"?rR(t):sR(t)},oR=function(e,t){return e==="h"&&t==="rtl"?-1:1},iR=function(e,t,n,r,s){var o=oR(e,window.getComputedStyle(t).direction),i=o*r,a=n.target,l=t.contains(a),c=!1,d=i>0,u=0,f=0;do{if(!a)break;var y=Ox(e,a),w=y[0],x=y[1],S=y[2],m=x-S-o*w;(w||m)&&Lx(e,a)&&(u+=m,f+=w);var g=a.parentNode;a=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(d&&Math.abs(u)<1||!d&&Math.abs(f)<1)&&(c=!0),c},oi=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Sm=function(e){return[e.deltaX,e.deltaY]},Em=function(e){return e&&"current"in e?e.current:e},aR=function(e,t){return e[0]===t[0]&&e[1]===t[1]},lR=function(e){return`
269
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
270
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
271
+ `)},uR=0,Tr=[];function cR(e){var t=p.useRef([]),n=p.useRef([0,0]),r=p.useRef(),s=p.useState(uR++)[0],o=p.useState(Ax)[0],i=p.useRef(e);p.useEffect(function(){i.current=e},[e]),p.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var x=Mj([e.lockRef.current],(e.shards||[]).map(Em),!0).filter(Boolean);return x.forEach(function(S){return S.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),x.forEach(function(S){return S.classList.remove("allow-interactivity-".concat(s))})}}},[e.inert,e.lockRef.current,e.shards]);var a=p.useCallback(function(x,S){if("touches"in x&&x.touches.length===2||x.type==="wheel"&&x.ctrlKey)return!i.current.allowPinchZoom;var m=oi(x),g=n.current,v="deltaX"in x?x.deltaX:g[0]-m[0],E="deltaY"in x?x.deltaY:g[1]-m[1],C,T=x.target,k=Math.abs(v)>Math.abs(E)?"h":"v";if("touches"in x&&k==="h"&&T.type==="range")return!1;var b=window.getSelection(),A=b&&b.anchorNode,P=A?A===T||A.contains(T):!1;if(P)return!1;var D=wm(k,T);if(!D)return!0;if(D?C=k:(C=k==="v"?"h":"v",D=wm(k,T)),!D)return!1;if(!r.current&&"changedTouches"in x&&(v||E)&&(r.current=C),!C)return!0;var L=r.current||C;return iR(L,S,x,L==="h"?v:E)},[]),l=p.useCallback(function(x){var S=x;if(!(!Tr.length||Tr[Tr.length-1]!==o)){var m="deltaY"in S?Sm(S):oi(S),g=t.current.filter(function(C){return C.name===S.type&&(C.target===S.target||S.target===C.shadowParent)&&aR(C.delta,m)})[0];if(g&&g.should){S.cancelable&&S.preventDefault();return}if(!g){var v=(i.current.shards||[]).map(Em).filter(Boolean).filter(function(C){return C.contains(S.target)}),E=v.length>0?a(S,v[0]):!i.current.noIsolation;E&&S.cancelable&&S.preventDefault()}}},[]),c=p.useCallback(function(x,S,m,g){var v={name:x,delta:S,target:m,should:g,shadowParent:dR(m)};t.current.push(v),setTimeout(function(){t.current=t.current.filter(function(E){return E!==v})},1)},[]),d=p.useCallback(function(x){n.current=oi(x),r.current=void 0},[]),u=p.useCallback(function(x){c(x.type,Sm(x),x.target,a(x,e.lockRef.current))},[]),f=p.useCallback(function(x){c(x.type,oi(x),x.target,a(x,e.lockRef.current))},[]);p.useEffect(function(){return Tr.push(o),e.setCallbacks({onScrollCapture:u,onWheelCapture:u,onTouchMoveCapture:f}),document.addEventListener("wheel",l,Cr),document.addEventListener("touchmove",l,Cr),document.addEventListener("touchstart",d,Cr),function(){Tr=Tr.filter(function(x){return x!==o}),document.removeEventListener("wheel",l,Cr),document.removeEventListener("touchmove",l,Cr),document.removeEventListener("touchstart",d,Cr)}},[]);var y=e.removeScrollBar,w=e.inert;return p.createElement(p.Fragment,null,w?p.createElement(o,{styles:lR(s)}):null,y?p.createElement(Jj,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function dR(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const fR=zj(Mx,cR);var _x=p.forwardRef(function(e,t){return p.createElement(Wa,Wt({},e,{ref:t,sideCar:fR}))});_x.classNames=Wa.classNames;var hR=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Pr=new WeakMap,ii=new WeakMap,ai={},tu=0,Ix=function(e){return e&&(e.host||Ix(e.parentNode))},pR=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Ix(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},mR=function(e,t,n,r){var s=pR(t,Array.isArray(e)?e:[e]);ai[n]||(ai[n]=new WeakMap);var o=ai[n],i=[],a=new Set,l=new Set(s),c=function(u){!u||a.has(u)||(a.add(u),c(u.parentNode))};s.forEach(c);var d=function(u){!u||l.has(u)||Array.prototype.forEach.call(u.children,function(f){if(a.has(f))d(f);else try{var y=f.getAttribute(r),w=y!==null&&y!=="false",x=(Pr.get(f)||0)+1,S=(o.get(f)||0)+1;Pr.set(f,x),o.set(f,S),i.push(f),x===1&&w&&ii.set(f,!0),S===1&&f.setAttribute(n,"true"),w||f.setAttribute(r,"true")}catch(m){console.error("aria-hidden: cannot operate on ",f,m)}})};return d(t),a.clear(),tu++,function(){i.forEach(function(u){var f=Pr.get(u)-1,y=o.get(u)-1;Pr.set(u,f),o.set(u,y),f||(ii.has(u)||u.removeAttribute(r),ii.delete(u)),y||u.removeAttribute(n)}),tu--,tu||(Pr=new WeakMap,Pr=new WeakMap,ii=new WeakMap,ai={})}},gR=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),s=hR(e);return s?(r.push.apply(r,Array.from(s.querySelectorAll("[aria-live], script"))),mR(r,s,n,"aria-hidden")):function(){return null}};function yR(e){const t=vR(e),n=p.forwardRef((r,s)=>{const{children:o,...i}=r,a=p.Children.toArray(o),l=a.find(wR);if(l){const c=l.props.children,d=a.map(u=>u===l?p.Children.count(c)>1?p.Children.only(null):p.isValidElement(c)?c.props.children:null:u);return h.jsx(t,{...i,ref:s,children:p.isValidElement(c)?p.cloneElement(c,void 0,d):null})}return h.jsx(t,{...i,ref:s,children:o})});return n.displayName=`${e}.Slot`,n}function vR(e){const t=p.forwardRef((n,r)=>{const{children:s,...o}=n;if(p.isValidElement(s)){const i=ER(s),a=SR(o,s.props);return s.type!==p.Fragment&&(a.ref=r?Ba(r,i):i),p.cloneElement(s,a)}return p.Children.count(s)>1?p.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var xR=Symbol("radix.slottable");function wR(e){return p.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===xR}function SR(e,t){const n={...t};for(const r in t){const s=e[r],o=t[r];/^on[A-Z]/.test(r)?s&&o?n[r]=(...a)=>{const l=o(...a);return s(...a),l}:s&&(n[r]=s):r==="style"?n[r]={...s,...o}:r==="className"&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}function ER(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Ha="Dialog",[Vx]=XN(Ha),[kR,_t]=Vx(Ha),Fx=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:s,onOpenChange:o,modal:i=!0}=e,a=p.useRef(null),l=p.useRef(null),[c,d]=ej({prop:r,defaultProp:s??!1,onChange:o,caller:Ha});return h.jsx(kR,{scope:t,triggerRef:a,contentRef:l,contentId:Yl(),titleId:Yl(),descriptionId:Yl(),open:c,onOpenChange:d,onOpenToggle:p.useCallback(()=>d(u=>!u),[d]),modal:i,children:n})};Fx.displayName=Ha;var zx="DialogTrigger",bR=p.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=_t(zx,n),o=kr(t,s.triggerRef);return h.jsx(un.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":ff(s.open),...r,ref:o,onClick:Fn(e.onClick,s.onOpenToggle)})});bR.displayName=zx;var cf="DialogPortal",[CR,Bx]=Vx(cf,{forceMount:void 0}),$x=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:s}=e,o=_t(cf,t);return h.jsx(CR,{scope:t,forceMount:n,children:p.Children.map(r,i=>h.jsx(Ua,{present:n||o.open,children:h.jsx(Nx,{asChild:!0,container:s,children:i})}))})};$x.displayName=cf;var ga="DialogOverlay",Ux=p.forwardRef((e,t)=>{const n=Bx(ga,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=_t(ga,e.__scopeDialog);return o.modal?h.jsx(Ua,{present:r||o.open,children:h.jsx(PR,{...s,ref:t})}):null});Ux.displayName=ga;var TR=yR("DialogOverlay.RemoveScroll"),PR=p.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=_t(ga,n);return h.jsx(_x,{as:TR,allowPinchZoom:!0,shards:[s.contentRef],children:h.jsx(un.div,{"data-state":ff(s.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),wr="DialogContent",Wx=p.forwardRef((e,t)=>{const n=Bx(wr,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=_t(wr,e.__scopeDialog);return h.jsx(Ua,{present:r||o.open,children:o.modal?h.jsx(NR,{...s,ref:t}):h.jsx(jR,{...s,ref:t})})});Wx.displayName=wr;var NR=p.forwardRef((e,t)=>{const n=_t(wr,e.__scopeDialog),r=p.useRef(null),s=kr(t,n.contentRef,r);return p.useEffect(()=>{const o=r.current;if(o)return gR(o)},[]),h.jsx(Hx,{...e,ref:s,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Fn(e.onCloseAutoFocus,o=>{var i;o.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:Fn(e.onPointerDownOutside,o=>{const i=o.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&o.preventDefault()}),onFocusOutside:Fn(e.onFocusOutside,o=>o.preventDefault())})}),jR=p.forwardRef((e,t)=>{const n=_t(wr,e.__scopeDialog),r=p.useRef(!1),s=p.useRef(!1);return h.jsx(Hx,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,o),o.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),o.preventDefault()),r.current=!1,s.current=!1},onInteractOutside:o=>{var l,c;(l=e.onInteractOutside)==null||l.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const i=o.target;((c=n.triggerRef.current)==null?void 0:c.contains(i))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&s.current&&o.preventDefault()}})}),Hx=p.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:o,...i}=e,a=_t(wr,n),l=p.useRef(null),c=kr(t,l);return Rj(),h.jsxs(h.Fragment,{children:[h.jsx(Tx,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:s,onUnmountAutoFocus:o,children:h.jsx(bx,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":ff(a.open),...i,ref:c,onDismiss:()=>a.onOpenChange(!1)})}),h.jsxs(h.Fragment,{children:[h.jsx(RR,{titleId:a.titleId}),h.jsx(AR,{contentRef:l,descriptionId:a.descriptionId})]})]})}),df="DialogTitle",Gx=p.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=_t(df,n);return h.jsx(un.h2,{id:s.titleId,...r,ref:t})});Gx.displayName=df;var Kx="DialogDescription",Yx=p.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=_t(Kx,n);return h.jsx(un.p,{id:s.descriptionId,...r,ref:t})});Yx.displayName=Kx;var Xx="DialogClose",Qx=p.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=_t(Xx,n);return h.jsx(un.button,{type:"button",...r,ref:t,onClick:Fn(e.onClick,()=>s.onOpenChange(!1))})});Qx.displayName=Xx;function ff(e){return e?"open":"closed"}var Zx="DialogTitleWarning",[zM,qx]=YN(Zx,{contentName:wr,titleName:df,docsSlug:"dialog"}),RR=({titleId:e})=>{const t=qx(Zx),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
272
+
273
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
274
+
275
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return p.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},MR="DialogDescriptionWarning",AR=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${qx(MR).contentName}}.`;return p.useEffect(()=>{var o;const s=(o=e.current)==null?void 0:o.getAttribute("aria-describedby");t&&s&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},DR=Fx,LR=$x,Jx=Ux,ew=Wx,tw=Gx,nw=Yx,OR=Qx;const hf=DR,_R=LR,rw=p.forwardRef(({className:e,...t},n)=>h.jsx(Jx,{ref:n,className:q("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));rw.displayName=Jx.displayName;const Ga=p.forwardRef(({className:e,children:t,...n},r)=>h.jsxs(_R,{children:[h.jsx(rw,{}),h.jsxs(ew,{ref:r,className:q("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,h.jsxs(OR,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[h.jsx(uf,{className:"h-4 w-4"}),h.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Ga.displayName=ew.displayName;const Ka=({className:e,...t})=>h.jsx("div",{className:q("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Ka.displayName="DialogHeader";const Ya=({className:e,...t})=>h.jsx("div",{className:q("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Ya.displayName="DialogFooter";const Xa=p.forwardRef(({className:e,...t},n)=>h.jsx(tw,{ref:n,className:q("text-lg font-semibold leading-none tracking-tight",e),...t}));Xa.displayName=tw.displayName;const Qa=p.forwardRef(({className:e,...t},n)=>h.jsx(nw,{ref:n,className:q("text-sm text-muted-foreground",e),...t}));Qa.displayName=nw.displayName;function IR({project:e,open:t,onOpenChange:n,onUpdated:r}){const[s,o]=p.useState([]),[i,a]=p.useState([]),[l,c]=p.useState(!1),[d,u]=p.useState(null);p.useEffect(()=>{if(!t)return;o(e.shares?[...e.shares]:[]),u(null);let g=!1;return sx().then(v=>{g||a(v)}).catch(()=>{}),()=>{g=!0}},[t,e.id]);const f=new Set(s.map(g=>g.username)),y=i.filter(g=>g!==e.owner&&!f.has(g)),w=g=>{o(v=>[...v,{username:g,permission:"view"}])},x=g=>{o(v=>v.filter(E=>E.username!==g))},S=g=>{o(v=>v.map(E=>E.username===g?{...E,permission:E.permission==="view"?"edit":"view"}:E))},m=async()=>{c(!0),u(null);try{const g=await ox(e.id,s);r(g),n(!1)}catch(g){u(g instanceof Error?g.message:"Failed to update shares")}finally{c(!1)}};return h.jsx(hf,{open:t,onOpenChange:n,children:h.jsxs(Ga,{className:"sm:max-w-md",children:[h.jsxs(Ka,{children:[h.jsxs(Xa,{className:"flex items-center gap-2",children:[h.jsx(kc,{className:"h-4 w-4"}),"共享设置"]}),h.jsx(Qa,{children:"选择用户并设置权限:可见(只读)或可编辑(读写+终端)"})]}),h.jsxs("div",{className:"space-y-3 max-h-64 overflow-y-auto",children:[s.length===0&&h.jsx("p",{className:"text-sm text-muted-foreground text-center py-4",children:"尚未共享给任何用户"}),s.map(g=>h.jsxs("div",{className:"flex items-center justify-between gap-2 px-1",children:[h.jsx("span",{className:"text-sm font-medium",children:g.username}),h.jsxs("div",{className:"flex items-center gap-1.5",children:[h.jsx("button",{onClick:()=>S(g.username),className:"focus:outline-none",children:h.jsx(rr,{variant:g.permission==="edit"?"default":"secondary",className:"cursor-pointer text-xs",children:g.permission==="edit"?"可编辑":"可见"})}),h.jsx(ie,{variant:"ghost",size:"icon",className:"h-7 w-7 text-destructive hover:text-destructive",onClick:()=>x(g.username),children:h.jsx(Ex,{className:"h-3.5 w-3.5"})})]})]},g.username))]}),y.length>0&&h.jsxs("div",{className:"border-t pt-3",children:[h.jsx("p",{className:"text-xs text-muted-foreground mb-2",children:"添加用户"}),h.jsx("div",{className:"flex flex-wrap gap-1.5",children:y.map(g=>h.jsxs(ie,{variant:"outline",size:"sm",className:"h-7 text-xs gap-1",onClick:()=>w(g),children:[h.jsx(ma,{className:"h-3 w-3"}),g]},g))})]}),d&&h.jsx("p",{className:"text-sm text-destructive",children:d}),h.jsxs(Ya,{children:[h.jsx(ie,{variant:"outline",onClick:()=>n(!1),disabled:l,children:"取消"}),h.jsx(ie,{onClick:()=>void m(),disabled:l,children:l?"保存中...":"保存"})]})]})})}function VR(e,t){switch(e){case"thinking":return"Thinking…";case"tool_use":return t?`${t}`:"Tool…";case"tool_result":return"Reading…";case"text":return"Writing…"}}function FR({status:e}){return h.jsx("span",{className:q("inline-block w-2 h-2 rounded-full",{"bg-green-500":e==="running","bg-zinc-400":e==="stopped","bg-yellow-400 animate-pulse":e==="restarting"})})}const km=R.memo(function({project:t,active:n=!1,statusStack:r=[],onDelete:s,onArchive:o,onUnarchive:i,onUpdated:a}){var g,v;const l=Oa(),[c,d]=p.useState(!1),u=!!t._sharedPermission,f=t._sharedPermission==="view",y=E=>{E.stopPropagation(),confirm(`Delete project "${t.name}"? This cannot be undone.`)&&s(t.id)},w=E=>{E.stopPropagation(),o(t.id)},x=E=>{E.stopPropagation(),i(t.id)},S=h.jsx(Vn.div,{whileHover:!t.archived&&!n?{y:-2}:{},transition:{duration:.2},children:h.jsxs(nf,{className:q("group cursor-pointer transition-colors relative",t.archived?"opacity-60 hover:opacity-80 hover:border-zinc-400":n?"border-transparent hover:border-transparent bg-transparent shadow-none":"hover:border-zinc-400 hover:shadow-md"),onClick:()=>!t.archived&&l(`/projects/${t.id}`),children:[h.jsxs(rf,{className:"pb-2",children:[h.jsxs("div",{className:"flex items-start justify-between gap-2",children:[h.jsx(sf,{className:q("text-base leading-tight",t.archived&&"text-muted-foreground"),children:t.name}),h.jsx("div",{className:"flex items-center gap-0.5 opacity-0 group-hover:opacity-100 transition-opacity flex-shrink-0",children:!u&&h.jsxs(h.Fragment,{children:[t.archived?h.jsx(ie,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-foreground",onClick:x,title:"Restore project",children:h.jsx(jN,{className:"h-3.5 w-3.5"})}):h.jsxs(h.Fragment,{children:[h.jsx(ie,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-foreground",onClick:E=>{E.stopPropagation(),d(!0)},title:"共享设置",children:h.jsx(kc,{className:"h-3.5 w-3.5"})}),h.jsx(ie,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-foreground",onClick:w,title:"Archive project",children:h.jsx(RN,{className:"h-3.5 w-3.5"})})]}),h.jsx(ie,{variant:"ghost",size:"icon",className:"h-7 w-7 text-destructive hover:text-destructive hover:bg-destructive/10",onClick:y,title:"Delete project",children:h.jsx(Ex,{className:"h-3.5 w-3.5"})})]})})]}),h.jsx("div",{className:"flex items-center gap-1.5",children:t.archived?h.jsx(rr,{variant:"secondary",className:"text-xs",children:"Archived"}):h.jsxs(h.Fragment,{children:[h.jsx(FR,{status:t.status}),h.jsx("span",{className:"text-xs text-muted-foreground capitalize",children:t.status}),n&&r.length>0&&h.jsx("div",{className:"ml-auto",children:h.jsx(qd,{mode:"wait",children:r.slice(-1).map(E=>h.jsx(Vn.div,{initial:{opacity:0,y:6},animate:{opacity:1,y:0},exit:{opacity:0,y:-6},transition:{duration:.25,ease:"easeOut"},children:h.jsx(rr,{variant:"outline",className:"text-xs font-normal whitespace-nowrap",children:VR(E.phase,E.detail)})},E.id))})})]})})]}),h.jsxs(of,{className:"space-y-2",children:[h.jsxs("div",{className:"flex items-center gap-1.5 text-xs text-muted-foreground",children:[h.jsx(Ec,{className:"h-3.5 w-3.5 flex-shrink-0"}),h.jsx("span",{className:"truncate font-mono",children:t.folderPath})]}),h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(rr,{variant:"outline",className:"text-xs font-mono",children:t.cliTool??"claude"}),h.jsx(rr,{variant:t.permissionMode==="unlimited"?"destructive":"secondary",className:"text-xs",children:t.permissionMode==="unlimited"?"Unlimited":"Limited"}),u&&h.jsxs(rr,{variant:"outline",className:"text-xs gap-0.5",children:[f?h.jsx(DN,{className:"h-3 w-3"}):h.jsx(Sx,{className:"h-3 w-3"}),f?"可见":"可编辑"]}),!u&&t.shares&&t.shares.length>0&&h.jsxs(rr,{variant:"outline",className:"text-xs gap-0.5",children:[h.jsx(kc,{className:"h-3 w-3"}),t.shares.length]}),h.jsx("span",{className:"text-xs text-muted-foreground",children:new Date(t.createdAt).toLocaleDateString()})]}),(t.tags??[]).length>0&&h.jsxs("div",{className:"flex flex-wrap gap-1 mt-1",children:[(t.tags??[]).slice(0,3).map(E=>h.jsxs("span",{className:"px-1.5 py-0 rounded-full text-[10px] bg-muted text-muted-foreground border border-border",children:["#",E]},E)),(((g=t.tags)==null?void 0:g.length)??0)>3&&h.jsxs("span",{className:"text-[10px] text-muted-foreground",children:["+",(((v=t.tags)==null?void 0:v.length)??0)-3]})]})]})]})}),m=n&&!t.archived?h.jsx("div",{className:"card-active-glow rounded-lg",children:S}):S;return h.jsxs(h.Fragment,{children:[m,!u&&a&&h.jsx(IR,{project:t,open:c,onOpenChange:d,onUpdated:a})]})});function sw({onSelect:e}){const[t,n]=p.useState(""),[r,s]=p.useState(null),[o,i]=p.useState([]),[a,l]=p.useState(!0),[c,d]=p.useState(null),[u,f]=p.useState(!1),[y,w]=p.useState(""),[x,S]=p.useState(null),[m,g]=p.useState(!1),v=p.useRef(null),E=async D=>{l(!0),d(null);try{const L=await yx(D);n(L.path),s(L.parent),i(L.entries)}catch(L){d(L instanceof Error?L.message:"Failed to load directory")}finally{l(!1)}};p.useEffect(()=>{E()},[]),p.useEffect(()=>{u&&setTimeout(()=>{var D;return(D=v.current)==null?void 0:D.focus()},0)},[u]);const C=()=>{w(""),S(null),f(!0)},T=()=>{f(!1),w(""),S(null)},k=async()=>{const D=y.trim();if(D){g(!0),S(null);try{const{path:L}=await vx(t,D);f(!1),w(""),await E(t),E(L)}catch(L){S(L instanceof Error?L.message:"Failed to create folder")}finally{g(!1)}}},b=D=>{D.key==="Enter"?(D.preventDefault(),k()):D.key==="Escape"&&T()},A=t.split("/").filter(Boolean),P=D=>{const L="/"+A.slice(0,D+1).join("/");E(L)};return h.jsxs("div",{className:"flex flex-col h-64 border rounded-md overflow-hidden",children:[h.jsxs("div",{className:"flex items-center gap-1 px-2 py-2 bg-muted border-b flex-shrink-0",children:[h.jsx(ie,{variant:"ghost",size:"sm",className:"h-6 px-1 flex-shrink-0",onClick:()=>void E(),title:"Home",children:h.jsx(_N,{className:"h-3 w-3"})}),h.jsx("div",{className:"flex items-center gap-1 flex-1 overflow-x-auto min-w-0",children:A.map((D,L)=>h.jsxs(R.Fragment,{children:[h.jsx(wx,{className:"h-3 w-3 text-muted-foreground flex-shrink-0"}),h.jsx("button",{className:"text-xs hover:text-foreground text-muted-foreground whitespace-nowrap",onClick:()=>P(L),children:D})]},L))}),h.jsxs(ie,{variant:"ghost",size:"sm",className:"h-6 px-1.5 flex-shrink-0 gap-1 text-xs",onClick:C,disabled:u||a||!!c,title:"New folder",children:[h.jsx(ON,{className:"h-3.5 w-3.5"}),h.jsx("span",{className:"hidden sm:inline",children:"New folder"})]})]}),h.jsxs("div",{className:"flex-1 overflow-y-auto",children:[a&&h.jsx("div",{className:"flex items-center justify-center h-full text-sm text-muted-foreground",children:"Loading..."}),c&&h.jsx("div",{className:"flex items-center justify-center h-full text-sm text-destructive px-4 text-center",children:c}),!a&&!c&&h.jsxs("div",{className:"p-1",children:[r&&h.jsxs("button",{className:"flex items-center gap-2 w-full px-2 py-1.5 text-sm rounded hover:bg-accent hover:text-accent-foreground",onClick:()=>void E(r),children:[h.jsx(MN,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("span",{children:".."})]}),u&&h.jsxs("div",{className:"flex items-center gap-1 px-2 py-1.5",children:[h.jsx(lm,{className:"h-4 w-4 text-blue-500 flex-shrink-0"}),h.jsx("input",{ref:v,className:q("flex-1 text-sm bg-background border rounded px-1.5 py-0.5 outline-none","focus:ring-1 focus:ring-ring",x&&"border-destructive"),placeholder:"Folder name",value:y,onChange:D=>{w(D.target.value),S(null)},onKeyDown:b,disabled:m}),h.jsx("button",{className:"p-1 rounded hover:bg-accent disabled:opacity-50",onClick:()=>void k(),disabled:!y.trim()||m,title:"Create",children:h.jsx(AN,{className:"h-3.5 w-3.5 text-green-600"})}),h.jsx("button",{className:"p-1 rounded hover:bg-accent",onClick:T,disabled:m,title:"Cancel",children:h.jsx(uf,{className:"h-3.5 w-3.5 text-muted-foreground"})})]}),x&&h.jsx("p",{className:"px-3 pb-1 text-xs text-destructive",children:x}),o.length===0&&!u&&h.jsx("div",{className:"text-sm text-muted-foreground px-2 py-4 text-center",children:"Empty directory"}),o.map(D=>h.jsxs("button",{className:q("flex items-center gap-2 w-full px-2 py-1.5 text-sm rounded text-left",D.type==="dir"?"hover:bg-accent hover:text-accent-foreground cursor-pointer":"opacity-40 cursor-not-allowed"),onClick:()=>{D.type==="dir"&&E(D.path)},disabled:D.type==="file",children:[D.type==="dir"?h.jsx(lm,{className:"h-4 w-4 text-blue-500 flex-shrink-0"}):h.jsx(LN,{className:"h-4 w-4 text-muted-foreground flex-shrink-0"}),h.jsx("span",{className:"truncate",children:D.name})]},D.path))]})]}),h.jsxs("div",{className:"border-t px-3 py-2 flex items-center justify-between gap-2 flex-shrink-0 bg-background",children:[h.jsx("span",{className:"text-xs text-muted-foreground truncate flex-1",children:t}),h.jsx(ie,{size:"sm",onClick:()=>e(t),disabled:!t,children:"Select this folder"})]})]})}const zR=[{value:"claude",label:"Claude",desc:"Anthropic Claude Code CLI"},{value:"opencode",label:"OpenCode",desc:"OpenCode CLI (sst/opencode)"},{value:"codex",label:"Codex",desc:"OpenAI Codex CLI"},{value:"qwen",label:"Qwen",desc:"Qwen Code CLI (QwenLM)"}],bm={claude:{limited:"claude",unlimited:"claude --dangerously-skip-permissions"},opencode:{limited:"opencode",unlimited:"opencode --dangerously-skip-permissions"},codex:{limited:"codex",unlimited:"codex --ask-for-approval never --sandbox danger-full-access"},qwen:{limited:"qwen-code",unlimited:"qwen-code --yolo"}};function BR({open:e,onOpenChange:t,onCreated:n}){const[r,s]=p.useState("name"),[o,i]=p.useState(""),[a,l]=p.useState(""),[c,d]=p.useState("claude"),[u,f]=p.useState("limited"),[y,w]=p.useState(!1),[x,S]=p.useState(null),m=()=>{s("name"),i(""),l(""),d("claude"),f("limited"),S(null),w(!1)},g=b=>{b||m(),t(b)},v=()=>{if(!o.trim()){S("Please enter a project name");return}S(null),s("folder")},E=b=>{l(b),s("settings")},C=async()=>{w(!0),S(null);try{const b=await ix({name:o.trim(),folderPath:a,permissionMode:u,cliTool:c});n(b),g(!1)}catch(b){S(b instanceof Error?b.message:"Failed to create project")}finally{w(!1)}},T={name:"New Project — Name",folder:"New Project — Select Folder",settings:"New Project — Settings"},k=["name","folder","settings"];return h.jsx(hf,{open:e,onOpenChange:g,children:h.jsxs(Ga,{className:"sm:max-w-lg",children:[h.jsxs(Ka,{children:[h.jsx(Xa,{children:T[r]}),h.jsxs(Qa,{children:[r==="name"&&"Give your project a name.",r==="folder"&&"Choose the working directory for this project.",r==="settings"&&"Choose the AI coding tool and run mode."]})]}),h.jsx("div",{className:"flex gap-2 mb-2",children:k.map((b,A)=>h.jsx("div",{className:`h-1.5 flex-1 rounded-full ${r===b?"bg-primary":k.indexOf(r)>A?"bg-primary/40":"bg-muted"}`},b))}),r==="name"&&h.jsxs("div",{className:"space-y-4",children:[h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{htmlFor:"project-name",children:"Project Name"}),h.jsx(go,{id:"project-name",placeholder:"My Project",value:o,onChange:b=>i(b.target.value),onKeyDown:b=>{b.key==="Enter"&&v()},autoFocus:!0})]}),x&&h.jsx("p",{className:"text-sm text-destructive",children:x})]}),r==="folder"&&h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{children:"Working Directory"}),h.jsx(sw,{onSelect:E})]}),r==="settings"&&h.jsxs("div",{className:"space-y-5",children:[h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{children:"AI Coding Tool"}),h.jsx("div",{className:"grid grid-cols-2 gap-2",children:zR.map(b=>h.jsxs("label",{className:`flex items-center gap-2.5 cursor-pointer p-3 rounded-md border transition-colors ${c===b.value?"border-primary bg-primary/5":"hover:bg-accent"}`,children:[h.jsx("input",{type:"radio",name:"cliTool",value:b.value,checked:c===b.value,onChange:()=>d(b.value),className:"accent-primary"}),h.jsxs("div",{children:[h.jsx("div",{className:"font-medium text-sm",children:b.label}),h.jsx("div",{className:"text-xs text-muted-foreground",children:b.desc})]})]},b.value))})]}),h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{children:"Permission Mode"}),h.jsxs("div",{className:"space-y-2",children:[h.jsxs("label",{className:"flex items-start gap-3 cursor-pointer p-3 rounded-md border hover:bg-accent transition-colors",children:[h.jsx("input",{type:"radio",name:"permissionMode",value:"limited",checked:u==="limited",onChange:()=>f("limited"),className:"mt-0.5"}),h.jsxs("div",{children:[h.jsx("div",{className:"font-medium text-sm",children:"Limited"}),h.jsxs("div",{className:"text-xs text-muted-foreground",children:["Runs ",h.jsx("code",{className:"bg-muted px-1 rounded",children:bm[c].limited})," — asks for permission before file changes."]})]})]}),h.jsxs("label",{className:"flex items-start gap-3 cursor-pointer p-3 rounded-md border hover:bg-accent transition-colors",children:[h.jsx("input",{type:"radio",name:"permissionMode",value:"unlimited",checked:u==="unlimited",onChange:()=>f("unlimited"),className:"mt-0.5"}),h.jsxs("div",{children:[h.jsx("div",{className:"font-medium text-sm",children:"Unlimited"}),h.jsxs("div",{className:"text-xs text-muted-foreground",children:["Runs ",h.jsx("code",{className:"bg-muted px-1 rounded",children:bm[c].unlimited})," — acts autonomously."]})]})]})]})]}),h.jsxs("div",{className:"text-xs text-muted-foreground",children:[h.jsx("span",{className:"font-medium",children:"Folder:"})," ",h.jsx("span",{className:"font-mono",children:a})]}),x&&h.jsx("p",{className:"text-sm text-destructive",children:x})]}),h.jsxs(Ya,{children:[r!=="name"&&h.jsx(ie,{variant:"outline",onClick:()=>s(r==="settings"?"folder":"name"),disabled:y,children:"Back"}),r==="name"&&h.jsx(ie,{onClick:v,children:"Next"}),r==="folder"&&h.jsx(ie,{variant:"outline",onClick:()=>t(!1),children:"Cancel"}),r==="settings"&&h.jsx(ie,{onClick:()=>void C(),disabled:y,children:y?"Creating...":"Create Project"})]})]})})}function $R({open:e,onOpenChange:t,onOpened:n}){const[r,s]=p.useState(""),[o,i]=p.useState(!1),[a,l]=p.useState(null),c=()=>{s(""),l(null),i(!1)},d=f=>{f||c(),t(f)},u=async f=>{s(f),i(!0),l(null);try{const y=await ax(f);n(y),d(!1)}catch(y){l(y instanceof Error?y.message:"Failed to open project"),i(!1)}};return h.jsx(hf,{open:e,onOpenChange:d,children:h.jsxs(Ga,{className:"sm:max-w-lg",children:[h.jsxs(Ka,{children:[h.jsx(Xa,{children:"Open Existing Project"}),h.jsxs(Qa,{children:["Select a folder that contains a ",h.jsx("code",{className:"bg-muted px-1 rounded text-xs",children:".ccweb/"})," configuration. The project's history and settings will be restored."]})]}),h.jsxs("div",{className:"space-y-2",children:[h.jsx(jn,{children:"Project Folder"}),h.jsx(sw,{onSelect:f=>void u(f)})]}),a&&h.jsx("p",{className:"text-sm text-destructive",children:a}),r&&!a&&o&&h.jsxs("p",{className:"text-sm text-muted-foreground",children:["Opening project from ",r,"..."]}),h.jsx(Ya,{children:h.jsx(ie,{variant:"outline",onClick:()=>d(!1),disabled:o,children:"Cancel"})})]})})}function UR(e){if(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))}const WR=e=>{switch(e){case"success":return KR;case"info":return XR;case"warning":return YR;case"error":return QR;default:return null}},HR=Array(12).fill(0),GR=({visible:e,className:t})=>R.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},R.createElement("div",{className:"sonner-spinner"},HR.map((n,r)=>R.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),KR=R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},R.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),YR=R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},R.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),XR=R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},R.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),QR=R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},R.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),ZR=R.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},R.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),R.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),qR=()=>{const[e,t]=R.useState(document.hidden);return R.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Tc=1;class JR{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...s}=t,o=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Tc++,i=this.toasts.find(l=>l.id===o),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),i?this.toasts=this.toasts.map(l=>l.id===o?(this.publish({...l,...t,id:o,title:r}),{...l,...t,id:o,dismissible:a,title:r}):l):this.addToast({title:r,...s,dismissible:a,id:o}),o},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const s=Promise.resolve(t instanceof Function?t():t);let o=r!==void 0,i;const a=s.then(async c=>{if(i=["resolve",c],R.isValidElement(c))o=!1,this.create({id:r,type:"default",message:c});else if(tM(c)&&!c.ok){o=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,f=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,w=typeof u=="object"&&!R.isValidElement(u)?u:{message:u};this.create({id:r,type:"error",description:f,...w})}else if(c instanceof Error){o=!1;const u=typeof n.error=="function"?await n.error(c):n.error,f=typeof n.description=="function"?await n.description(c):n.description,w=typeof u=="object"&&!R.isValidElement(u)?u:{message:u};this.create({id:r,type:"error",description:f,...w})}else if(n.success!==void 0){o=!1;const u=typeof n.success=="function"?await n.success(c):n.success,f=typeof n.description=="function"?await n.description(c):n.description,w=typeof u=="object"&&!R.isValidElement(u)?u:{message:u};this.create({id:r,type:"success",description:f,...w})}}).catch(async c=>{if(i=["reject",c],n.error!==void 0){o=!1;const d=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,y=typeof d=="object"&&!R.isValidElement(d)?d:{message:d};this.create({id:r,type:"error",description:u,...y})}}).finally(()=>{o&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((c,d)=>a.then(()=>i[0]==="reject"?d(i[1]):c(i[1])).catch(d));return typeof r!="string"&&typeof r!="number"?{unwrap:l}:Object.assign(r,{unwrap:l})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||Tc++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const et=new JR,eM=(e,t)=>{const n=(t==null?void 0:t.id)||Tc++;return et.addToast({title:e,...t,id:n}),n},tM=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",nM=eM,rM=()=>et.toasts,sM=()=>et.getActiveToasts(),Di=Object.assign(nM,{success:et.success,info:et.info,warning:et.warning,error:et.error,custom:et.custom,message:et.message,promise:et.promise,dismiss:et.dismiss,loading:et.loading},{getHistory:rM,getToasts:sM});UR("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function li(e){return e.label!==void 0}const oM=3,iM="24px",aM="16px",Cm=4e3,lM=356,uM=14,cM=45,dM=200;function Ft(...e){return e.filter(Boolean).join(" ")}function fM(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const hM=e=>{var t,n,r,s,o,i,a,l,c;const{invert:d,toast:u,unstyled:f,interacting:y,setHeights:w,visibleToasts:x,heights:S,index:m,toasts:g,expanded:v,removeToast:E,defaultRichColors:C,closeButton:T,style:k,cancelButtonStyle:b,actionButtonStyle:A,className:P="",descriptionClassName:D="",duration:L,position:Q,gap:le,expandByDefault:ge,classNames:z,icons:re,closeButtonAriaLabel:j="Close toast"}=e,[O,V]=R.useState(null),[$,se]=R.useState(null),[H,Z]=R.useState(!1),[K,pe]=R.useState(!1),[Je,J]=R.useState(!1),[Xt,cn]=R.useState(!1),[Qt,It]=R.useState(!1),[gs,Xn]=R.useState(0),[Za,Qn]=R.useState(0),dn=R.useRef(u.duration||L||Cm),Ao=R.useRef(null),kt=R.useRef(null),qa=m===0,Ja=m+1<=x,ze=u.type,N=u.dismissible!==!1,B=u.className||"",Y=u.descriptionClassName||"",ee=R.useMemo(()=>S.findIndex(U=>U.toastId===u.id)||0,[S,u.id]),ue=R.useMemo(()=>{var U;return(U=u.closeButton)!=null?U:T},[u.closeButton,T]),Pe=R.useMemo(()=>u.duration||L||Cm,[u.duration,L]),Ge=R.useRef(0),ye=R.useRef(0),Zn=R.useRef(0),fn=R.useRef(null),[uw,cw]=Q.split("-"),pf=R.useMemo(()=>S.reduce((U,Me,Be)=>Be>=ee?U:U+Me.height,0),[S,ee]),mf=qR(),dw=u.invert||d,el=ze==="loading";ye.current=R.useMemo(()=>ee*le+pf,[ee,pf]),R.useEffect(()=>{dn.current=Pe},[Pe]),R.useEffect(()=>{Z(!0)},[]),R.useEffect(()=>{const U=kt.current;if(U){const Me=U.getBoundingClientRect().height;return Qn(Me),w(Be=>[{toastId:u.id,height:Me,position:u.position},...Be]),()=>w(Be=>Be.filter(it=>it.toastId!==u.id))}},[w,u.id]),R.useLayoutEffect(()=>{if(!H)return;const U=kt.current,Me=U.style.height;U.style.height="auto";const Be=U.getBoundingClientRect().height;U.style.height=Me,Qn(Be),w(it=>it.find(Le=>Le.toastId===u.id)?it.map(Le=>Le.toastId===u.id?{...Le,height:Be}:Le):[{toastId:u.id,height:Be,position:u.position},...it])},[H,u.title,u.description,w,u.id,u.jsx,u.action,u.cancel]);const hn=R.useCallback(()=>{pe(!0),Xn(ye.current),w(U=>U.filter(Me=>Me.toastId!==u.id)),setTimeout(()=>{E(u)},dM)},[u,E,w,ye]);R.useEffect(()=>{if(u.promise&&ze==="loading"||u.duration===1/0||u.type==="loading")return;let U;return v||y||mf?(()=>{if(Zn.current<Ge.current){const it=new Date().getTime()-Ge.current;dn.current=dn.current-it}Zn.current=new Date().getTime()})():(()=>{dn.current!==1/0&&(Ge.current=new Date().getTime(),U=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),hn()},dn.current))})(),()=>clearTimeout(U)},[v,y,u,ze,mf,hn]),R.useEffect(()=>{u.delete&&(hn(),u.onDismiss==null||u.onDismiss.call(u,u))},[hn,u.delete]);function fw(){var U;if(re!=null&&re.loading){var Me;return R.createElement("div",{className:Ft(z==null?void 0:z.loader,u==null||(Me=u.classNames)==null?void 0:Me.loader,"sonner-loader"),"data-visible":ze==="loading"},re.loading)}return R.createElement(GR,{className:Ft(z==null?void 0:z.loader,u==null||(U=u.classNames)==null?void 0:U.loader),visible:ze==="loading"})}const hw=u.icon||(re==null?void 0:re[ze])||WR(ze);var gf,yf;return R.createElement("li",{tabIndex:0,ref:kt,className:Ft(P,B,z==null?void 0:z.toast,u==null||(t=u.classNames)==null?void 0:t.toast,z==null?void 0:z.default,z==null?void 0:z[ze],u==null||(n=u.classNames)==null?void 0:n[ze]),"data-sonner-toast":"","data-rich-colors":(gf=u.richColors)!=null?gf:C,"data-styled":!(u.jsx||u.unstyled||f),"data-mounted":H,"data-promise":!!u.promise,"data-swiped":Qt,"data-removed":K,"data-visible":Ja,"data-y-position":uw,"data-x-position":cw,"data-index":m,"data-front":qa,"data-swiping":Je,"data-dismissible":N,"data-type":ze,"data-invert":dw,"data-swipe-out":Xt,"data-swipe-direction":$,"data-expanded":!!(v||ge&&H),"data-testid":u.testId,style:{"--index":m,"--toasts-before":m,"--z-index":g.length-m,"--offset":`${K?gs:ye.current}px`,"--initial-height":ge?"auto":`${Za}px`,...k,...u.style},onDragEnd:()=>{J(!1),V(null),fn.current=null},onPointerDown:U=>{U.button!==2&&(el||!N||(Ao.current=new Date,Xn(ye.current),U.target.setPointerCapture(U.pointerId),U.target.tagName!=="BUTTON"&&(J(!0),fn.current={x:U.clientX,y:U.clientY})))},onPointerUp:()=>{var U,Me,Be;if(Xt||!N)return;fn.current=null;const it=Number(((U=kt.current)==null?void 0:U.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Do=Number(((Me=kt.current)==null?void 0:Me.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Le=new Date().getTime()-((Be=Ao.current)==null?void 0:Be.getTime()),pt=O==="x"?it:Do,Lo=Math.abs(pt)/Le;if(Math.abs(pt)>=cM||Lo>.11){Xn(ye.current),u.onDismiss==null||u.onDismiss.call(u,u),se(O==="x"?it>0?"right":"left":Do>0?"down":"up"),hn(),cn(!0);return}else{var bt,Ct;(bt=kt.current)==null||bt.style.setProperty("--swipe-amount-x","0px"),(Ct=kt.current)==null||Ct.style.setProperty("--swipe-amount-y","0px")}It(!1),J(!1),V(null)},onPointerMove:U=>{var Me,Be,it;if(!fn.current||!N||((Me=window.getSelection())==null?void 0:Me.toString().length)>0)return;const Le=U.clientY-fn.current.y,pt=U.clientX-fn.current.x;var Lo;const bt=(Lo=e.swipeDirections)!=null?Lo:fM(Q);!O&&(Math.abs(pt)>1||Math.abs(Le)>1)&&V(Math.abs(pt)>Math.abs(Le)?"x":"y");let Ct={x:0,y:0};const vf=qn=>1/(1.5+Math.abs(qn)/20);if(O==="y"){if(bt.includes("top")||bt.includes("bottom"))if(bt.includes("top")&&Le<0||bt.includes("bottom")&&Le>0)Ct.y=Le;else{const qn=Le*vf(Le);Ct.y=Math.abs(qn)<Math.abs(Le)?qn:Le}}else if(O==="x"&&(bt.includes("left")||bt.includes("right")))if(bt.includes("left")&&pt<0||bt.includes("right")&&pt>0)Ct.x=pt;else{const qn=pt*vf(pt);Ct.x=Math.abs(qn)<Math.abs(pt)?qn:pt}(Math.abs(Ct.x)>0||Math.abs(Ct.y)>0)&&It(!0),(Be=kt.current)==null||Be.style.setProperty("--swipe-amount-x",`${Ct.x}px`),(it=kt.current)==null||it.style.setProperty("--swipe-amount-y",`${Ct.y}px`)}},ue&&!u.jsx&&ze!=="loading"?R.createElement("button",{"aria-label":j,"data-disabled":el,"data-close-button":!0,onClick:el||!N?()=>{}:()=>{hn(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Ft(z==null?void 0:z.closeButton,u==null||(r=u.classNames)==null?void 0:r.closeButton)},(yf=re==null?void 0:re.close)!=null?yf:ZR):null,(ze||u.icon||u.promise)&&u.icon!==null&&((re==null?void 0:re[ze])!==null||u.icon)?R.createElement("div",{"data-icon":"",className:Ft(z==null?void 0:z.icon,u==null||(s=u.classNames)==null?void 0:s.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||fw():null,u.type!=="loading"?hw:null):null,R.createElement("div",{"data-content":"",className:Ft(z==null?void 0:z.content,u==null||(o=u.classNames)==null?void 0:o.content)},R.createElement("div",{"data-title":"",className:Ft(z==null?void 0:z.title,u==null||(i=u.classNames)==null?void 0:i.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?R.createElement("div",{"data-description":"",className:Ft(D,Y,z==null?void 0:z.description,u==null||(a=u.classNames)==null?void 0:a.description)},typeof u.description=="function"?u.description():u.description):null),R.isValidElement(u.cancel)?u.cancel:u.cancel&&li(u.cancel)?R.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||b,onClick:U=>{li(u.cancel)&&N&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,U),hn())},className:Ft(z==null?void 0:z.cancelButton,u==null||(l=u.classNames)==null?void 0:l.cancelButton)},u.cancel.label):null,R.isValidElement(u.action)?u.action:u.action&&li(u.action)?R.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||A,onClick:U=>{li(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,U),!U.defaultPrevented&&hn())},className:Ft(z==null?void 0:z.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Tm(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function pM(e,t){const n={};return[e,t].forEach((r,s)=>{const o=s===1,i=o?"--mobile-offset":"--offset",a=o?aM:iM;function l(c){["top","right","bottom","left"].forEach(d=>{n[`${i}-${d}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?l(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${i}-${c}`]=a:n[`${i}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):l(a)}),n}const mM=R.forwardRef(function(t,n){const{id:r,invert:s,position:o="bottom-right",hotkey:i=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:u,theme:f="light",richColors:y,duration:w,style:x,visibleToasts:S=oM,toastOptions:m,dir:g=Tm(),gap:v=uM,icons:E,containerAriaLabel:C="Notifications"}=t,[T,k]=R.useState([]),b=R.useMemo(()=>r?T.filter(H=>H.toasterId===r):T.filter(H=>!H.toasterId),[T,r]),A=R.useMemo(()=>Array.from(new Set([o].concat(b.filter(H=>H.position).map(H=>H.position)))),[b,o]),[P,D]=R.useState([]),[L,Q]=R.useState(!1),[le,ge]=R.useState(!1),[z,re]=R.useState(f!=="system"?f:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),j=R.useRef(null),O=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),V=R.useRef(null),$=R.useRef(!1),se=R.useCallback(H=>{k(Z=>{var K;return(K=Z.find(pe=>pe.id===H.id))!=null&&K.delete||et.dismiss(H.id),Z.filter(({id:pe})=>pe!==H.id)})},[]);return R.useEffect(()=>et.subscribe(H=>{if(H.dismiss){requestAnimationFrame(()=>{k(Z=>Z.map(K=>K.id===H.id?{...K,delete:!0}:K))});return}setTimeout(()=>{By.flushSync(()=>{k(Z=>{const K=Z.findIndex(pe=>pe.id===H.id);return K!==-1?[...Z.slice(0,K),{...Z[K],...H},...Z.slice(K+1)]:[H,...Z]})})})}),[T]),R.useEffect(()=>{if(f!=="system"){re(f);return}if(f==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?re("dark"):re("light")),typeof window>"u")return;const H=window.matchMedia("(prefers-color-scheme: dark)");try{H.addEventListener("change",({matches:Z})=>{re(Z?"dark":"light")})}catch{H.addListener(({matches:K})=>{try{re(K?"dark":"light")}catch(pe){console.error(pe)}})}},[f]),R.useEffect(()=>{T.length<=1&&Q(!1)},[T]),R.useEffect(()=>{const H=Z=>{var K;if(i.every(J=>Z[J]||Z.code===J)){var Je;Q(!0),(Je=j.current)==null||Je.focus()}Z.code==="Escape"&&(document.activeElement===j.current||(K=j.current)!=null&&K.contains(document.activeElement))&&Q(!1)};return document.addEventListener("keydown",H),()=>document.removeEventListener("keydown",H)},[i]),R.useEffect(()=>{if(j.current)return()=>{V.current&&(V.current.focus({preventScroll:!0}),V.current=null,$.current=!1)}},[j.current]),R.createElement("section",{ref:n,"aria-label":`${C} ${O}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},A.map((H,Z)=>{var K;const[pe,Je]=H.split("-");return b.length?R.createElement("ol",{key:H,dir:g==="auto"?Tm():g,tabIndex:-1,ref:j,className:c,"data-sonner-toaster":!0,"data-sonner-theme":z,"data-y-position":pe,"data-x-position":Je,style:{"--front-toast-height":`${((K=P[0])==null?void 0:K.height)||0}px`,"--width":`${lM}px`,"--gap":`${v}px`,...x,...pM(d,u)},onBlur:J=>{$.current&&!J.currentTarget.contains(J.relatedTarget)&&($.current=!1,V.current&&(V.current.focus({preventScroll:!0}),V.current=null))},onFocus:J=>{J.target instanceof HTMLElement&&J.target.dataset.dismissible==="false"||$.current||($.current=!0,V.current=J.relatedTarget)},onMouseEnter:()=>Q(!0),onMouseMove:()=>Q(!0),onMouseLeave:()=>{le||Q(!1)},onDragEnd:()=>Q(!1),onPointerDown:J=>{J.target instanceof HTMLElement&&J.target.dataset.dismissible==="false"||ge(!0)},onPointerUp:()=>ge(!1)},b.filter(J=>!J.position&&Z===0||J.position===H).map((J,Xt)=>{var cn,Qt;return R.createElement(hM,{key:J.id,icons:E,index:Xt,toast:J,defaultRichColors:y,duration:(cn=m==null?void 0:m.duration)!=null?cn:w,className:m==null?void 0:m.className,descriptionClassName:m==null?void 0:m.descriptionClassName,invert:s,visibleToasts:S,closeButton:(Qt=m==null?void 0:m.closeButton)!=null?Qt:l,interacting:le,position:H,style:m==null?void 0:m.style,unstyled:m==null?void 0:m.unstyled,classNames:m==null?void 0:m.classNames,cancelButtonStyle:m==null?void 0:m.cancelButtonStyle,actionButtonStyle:m==null?void 0:m.actionButtonStyle,closeButtonAriaLabel:m==null?void 0:m.closeButtonAriaLabel,removeToast:se,toasts:b.filter(It=>It.position==J.position),heights:P.filter(It=>It.position==J.position),setHeights:D,expandByDefault:a,gap:v,expanded:L,swipeDirections:t.swipeDirections})})):null}))}),ow=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}`,iw=5,aw=3e3;function BM(e,t){const n=p.useRef(null),r=p.useRef(0),s=p.useRef(!0),o=p.useRef(!1),i=p.useRef(t);i.current=t;const a=p.useRef(!1),l=p.useCallback(w=>{var x;((x=n.current)==null?void 0:x.readyState)===WebSocket.OPEN&&n.current.send(JSON.stringify(w))},[]),c=p.useCallback((w,x)=>{var S;((S=n.current)==null?void 0:S.readyState)===WebSocket.OPEN?(n.current.send(JSON.stringify({type:"terminal_subscribe",cols:w,rows:x})),a.current=!1):a.current=!0},[]),d=p.useCallback(w=>{l({type:"terminal_input",data:w})},[l]),u=p.useCallback((w,x)=>{l({type:"terminal_resize",cols:w,rows:x})},[l]),f=p.useCallback(()=>{l({type:"chat_subscribe"})},[l]),y=p.useCallback(()=>{if(!s.current||o.current)return;const w=Mo();if(!w){window.location.href="/login";return}o.current=!0;const x=new WebSocket(`${ow}/ws/projects/${e}`);n.current=x,x.onopen=()=>{o.current=!1,r.current=0,x.send(JSON.stringify({type:"auth",token:w}))},x.onmessage=S=>{var g,v,E,C,T,k,b,A;let m;try{m=JSON.parse(S.data)}catch{return}switch(m.type){case"connected":a.current=!1,(v=(g=i.current).onConnected)==null||v.call(g);break;case"terminal_data":(C=(E=i.current).onTerminalData)==null||C.call(E,m.data);break;case"status":(k=(T=i.current).onStatus)==null||k.call(T,m.status);break;case"chat_message":{const P=m;(A=(b=i.current).onChatMessage)==null||A.call(b,P);break}case"error":console.error("[WS] Server error:",m.message);break}},x.onclose=()=>{o.current=!1,n.current=null,s.current&&r.current<iw&&(r.current++,setTimeout(y,aw))},x.onerror=S=>{o.current=!1,console.error("[WS] WebSocket error:",S)}},[e]);return p.useEffect(()=>(s.current=!0,y(),()=>{var w;s.current=!1,(w=n.current)==null||w.close(),n.current=null}),[y]),{subscribeTerminal:c,sendTerminalInput:d,sendTerminalResize:u,subscribeChatMessages:f}}function gM(e){const t=p.useRef(null),n=p.useRef(0),r=p.useRef(!0),s=p.useRef(!1),o=p.useRef(e);o.current=e;const i=p.useCallback(()=>{if(!r.current||s.current)return;const a=Mo();if(!a)return;s.current=!0;const l=new WebSocket(`${ow}/ws/dashboard`);t.current=l,l.onopen=()=>{s.current=!1,n.current=0,l.send(JSON.stringify({type:"auth",token:a}))},l.onmessage=c=>{var d,u;try{const f=JSON.parse(c.data);f.type==="activity_update"?o.current.onActivityUpdate(f):f.type==="project_stopped"&&((u=(d=o.current).onProjectStopped)==null||u.call(d,f.projectId,f.projectName))}catch{}},l.onclose=()=>{s.current=!1,t.current=null,r.current&&n.current<iw&&(n.current++,setTimeout(i,aw))},l.onerror=c=>{s.current=!1,console.error("[DashboardWS] Error:",c)}},[]);p.useEffect(()=>(r.current=!0,i(),()=>{var a;r.current=!1,(a=t.current)==null||a.close(),t.current=null}),[i])}function yM(e){if(!e)return"";const t=new Date(e).getTime()-Date.now();if(t<=0)return"即将重置";const n=Math.floor(t/36e5),r=Math.floor(t%36e5/6e4);return n>0?`${n}h${r}m`:`${r}m`}const Pm=5*36e5;function vM(e){if(!e||e.utilization===void 0||e.utilization<=0||!e.resetAt)return null;const t=new Date(e.resetAt).getTime()-Date.now();if(t<=0)return null;const n=Pm-t;return n<=0?null:Math.round(e.utilization/(n/Pm))}function ui({label:e,bucket:t}){if(!t||t.utilization===void 0)return null;const n=t.utilization,r=n<50?"text-green-400":n<80?"text-yellow-400":"text-red-400",s=yM(t.resetAt);return h.jsxs("span",{className:"text-muted-foreground whitespace-nowrap",children:[e," ",h.jsxs("span",{className:q("font-medium",r),children:[n,"%"]}),s&&h.jsxs("span",{className:"text-muted-foreground/70 ml-0.5",children:["(",s,")"]})]})}function xM({className:e}){const[t,n]=p.useState("loading"),[r,s]=p.useState(!1);p.useEffect(()=>{const f=async()=>{try{n(await mx())}catch{n(null)}};f();const y=setInterval(()=>void f(),5*60*1e3);return()=>clearInterval(y)},[]);const o=async()=>{s(!0);try{n(await gx())}catch{n(null)}finally{s(!1)}};if(t==="loading"||!t)return null;const i=!!t.fiveHour,a=!!t.sevenDay,l=!!t.sevenDaySonnet,c=!!t.sevenDayOpus,d=i||a||l||c,u=vM(t.fiveHour);return h.jsxs("div",{className:q("flex items-center gap-1.5 text-xs",e),children:[u!==null&&h.jsxs("span",{className:q("font-medium",u<=100?"text-green-400":"text-orange-400"),title:`5h 使用进度:按当前速率,窗口结束时预计使用 ${u}%`,children:[u,"%"]}),t.planName&&h.jsx("span",{className:"font-medium text-foreground bg-muted border border-border px-2 py-0.5 rounded-full",children:t.planName}),d&&h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"text-muted-foreground/50",children:"|"}),h.jsx(ui,{label:"5h",bucket:t.fiveHour}),a&&h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"text-muted-foreground/50",children:"·"}),h.jsx(ui,{label:"7d",bucket:t.sevenDay})]}),l&&h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"text-muted-foreground/50",children:"·"}),h.jsx(ui,{label:"7d Sonnet",bucket:t.sevenDaySonnet})]}),c&&h.jsxs(h.Fragment,{children:[h.jsx("span",{className:"text-muted-foreground/50",children:"·"}),h.jsx(ui,{label:"7d Opus",bucket:t.sevenDayOpus})]})]}),h.jsx("button",{onClick:()=>void o(),className:"text-muted-foreground hover:text-foreground transition-colors",title:"刷新用量信息",children:h.jsx($N,{className:q("h-3 w-3",r&&"animate-spin")})})]})}function wM(){const[e,t]=p.useState([]),[n,r]=p.useState(!1),[s,o]=p.useState(""),[i,a]=p.useState(""),[l,c]=p.useState(""),[d,u]=p.useState(null),[f,y]=p.useState(""),[w,x]=p.useState(""),[S,m]=p.useState(""),g=p.useRef(null),v=p.useRef(null);p.useEffect(()=>{dx().then(t).catch(()=>t([]))},[]),p.useEffect(()=>{n&&setTimeout(()=>{var k;return(k=g.current)==null?void 0:k.focus()},0)},[n]),p.useEffect(()=>{d&&setTimeout(()=>{var k;return(k=v.current)==null?void 0:k.focus()},0)},[d]);const E=async()=>{const k=i.trim();if(k)try{const b=await fx({label:s.trim()||k,command:k,...l?{parentId:l}:{}});t(A=>[...A,b]),o(""),a(""),c(""),r(!1)}catch(b){console.error("[GlobalShortcuts] Failed to add:",b)}},C=async k=>{try{await px(k),t(b=>b.filter(A=>A.id!==k)),d===k&&u(null)}catch(b){console.error("[GlobalShortcuts] Failed to delete:",b)}},T=async()=>{const k=w.trim();if(!(!k||!d))try{const b=await hx(d,{label:f.trim()||k,command:k,parentId:S||null});t(A=>A.map(P=>P.id===d?b:P)),u(null)}catch(b){console.error("[GlobalShortcuts] Failed to save:",b)}};return h.jsxs("section",{className:"mt-10",children:[h.jsxs("div",{className:"flex items-center justify-between mb-4",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(cm,{className:"h-4 w-4 text-muted-foreground"}),h.jsx("h2",{className:"text-lg font-semibold",children:"全局快捷命令"}),h.jsx("span",{className:"text-xs text-muted-foreground",children:"在所有项目的终端中可用"})]}),h.jsxs("button",{onClick:()=>{r(k=>!k),u(null)},className:q("flex items-center gap-1.5 text-sm px-3 py-1.5 rounded-md border transition-colors",n?"border-border text-foreground bg-muted":"border-border text-muted-foreground hover:text-foreground hover:bg-muted"),children:[h.jsx(ma,{className:"h-3.5 w-3.5"}),"新建"]})]}),n&&h.jsxs("div",{className:"mb-4 p-4 rounded-lg border border-border bg-background space-y-3",children:[h.jsx("input",{ref:g,placeholder:"名称(可选)",value:s,onChange:k=>o(k.target.value),className:"w-full text-sm bg-muted border border-border rounded px-3 py-1.5 text-foreground placeholder:text-muted-foreground outline-none focus:border-border transition-colors"}),h.jsx("textarea",{placeholder:"命令内容…",value:i,onChange:k=>a(k.target.value),rows:3,className:"w-full text-sm bg-muted border border-border rounded px-3 py-1.5 text-foreground placeholder:text-muted-foreground font-mono outline-none focus:border-border transition-colors resize-none",onKeyDown:k=>{k.key==="Enter"&&(k.metaKey||k.ctrlKey)&&(k.preventDefault(),E()),k.key==="Escape"&&(r(!1),o(""),a(""),c(""))}}),h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(Kl,{className:"h-3.5 w-3.5 text-muted-foreground shrink-0"}),h.jsxs("select",{value:l,onChange:k=>c(k.target.value),className:"flex-1 text-sm bg-muted border border-border rounded px-3 py-1.5 text-foreground outline-none focus:border-border transition-colors",children:[h.jsx("option",{value:"",children:"无继承"}),e.map(k=>h.jsx("option",{value:k.id,children:k.label},k.id))]})]}),h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("span",{className:"text-xs text-muted-foreground",children:"⌘↩ 保存 · Esc 取消"}),h.jsxs("div",{className:"flex gap-2",children:[h.jsx("button",{onClick:()=>{r(!1),o(""),a("")},className:"text-sm px-3 py-1 rounded bg-secondary hover:bg-accent text-foreground transition-colors",children:"取消"}),h.jsx("button",{onClick:()=>void E(),disabled:!i.trim(),className:q("text-sm px-3 py-1 rounded transition-colors text-white",i.trim()?"bg-blue-600 hover:bg-blue-500":"bg-secondary opacity-40 cursor-not-allowed"),children:"保存"})]})]})]}),e.length===0&&!n?h.jsxs("div",{className:"flex flex-col items-center gap-2 py-10 text-muted-foreground/50 border border-dashed border-border rounded-lg",children:[h.jsx(cm,{className:"h-6 w-6"}),h.jsx("p",{className:"text-sm",children:"还没有全局快捷命令"})]}):h.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3",children:e.map(k=>d===k.id?h.jsxs("div",{className:"rounded-lg border border-border bg-background p-3 space-y-2",children:[h.jsx("input",{ref:v,value:f,onChange:b=>y(b.target.value),placeholder:"名称(可选)",className:"w-full text-sm bg-muted border border-border rounded px-2.5 py-1 text-foreground placeholder:text-muted-foreground outline-none focus:border-border transition-colors"}),h.jsx("textarea",{value:w,onChange:b=>x(b.target.value),rows:3,className:"w-full text-sm bg-muted border border-border rounded px-2.5 py-1 text-foreground font-mono outline-none focus:border-border transition-colors resize-none",onKeyDown:b=>{b.key==="Enter"&&(b.metaKey||b.ctrlKey)&&(b.preventDefault(),T()),b.key==="Escape"&&u(null)}}),h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(Kl,{className:"h-3.5 w-3.5 text-muted-foreground shrink-0"}),h.jsxs("select",{value:S,onChange:b=>m(b.target.value),className:"flex-1 text-sm bg-muted border border-border rounded px-2.5 py-1 text-foreground outline-none focus:border-border transition-colors",children:[h.jsx("option",{value:"",children:"无继承"}),e.filter(b=>b.id!==k.id).map(b=>h.jsx("option",{value:b.id,children:b.label},b.id))]})]}),h.jsxs("div",{className:"flex gap-2 justify-end",children:[h.jsx("button",{onClick:()=>u(null),className:"text-xs px-2.5 py-1 rounded bg-secondary hover:bg-accent text-foreground transition-colors",children:"取消"}),h.jsx("button",{onClick:()=>void T(),disabled:!w.trim(),className:q("text-xs px-2.5 py-1 rounded transition-colors text-white",w.trim()?"bg-blue-600 hover:bg-blue-500":"bg-secondary opacity-40 cursor-not-allowed"),children:"保存"})]})]},k.id):h.jsxs("div",{className:"group relative rounded-lg border border-border bg-background hover:border-muted-foreground/30 transition-colors p-3",children:[h.jsx("div",{className:"text-sm font-medium text-foreground truncate pr-14",children:k.label}),k.parentId&&(()=>{const b=e.find(A=>A.id===k.parentId);return b?h.jsxs("div",{className:"flex items-center gap-1 mt-1",children:[h.jsx(Kl,{className:"h-3 w-3 text-muted-foreground"}),h.jsxs("span",{className:"text-xs text-muted-foreground truncate",children:["继承: ",b.label]})]}):null})(),!k.parentId&&k.label!==k.command&&h.jsx("div",{className:"text-xs text-muted-foreground font-mono truncate mt-1 pr-14",children:k.command}),h.jsxs("div",{className:"absolute top-2.5 right-2.5 flex gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:[h.jsx("button",{onClick:()=>{u(k.id),y(k.label),x(k.command),m(k.parentId||""),r(!1)},className:"p-1 rounded text-muted-foreground hover:text-blue-400 transition-colors",title:"编辑",children:h.jsx(Sx,{className:"h-3.5 w-3.5"})}),h.jsx("button",{onClick:()=>void C(k.id),className:"p-1 rounded text-muted-foreground hover:text-red-400 transition-colors",title:"删除",children:h.jsx(uf,{className:"h-3.5 w-3.5"})})]})]},k.id))})]})}const lw=p.createContext({theme:"system",resolved:"dark",setTheme:()=>{}});function SM(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}function EM(){return p.useSyncExternalStore(e=>{const t=window.matchMedia("(prefers-color-scheme: dark)");return t.addEventListener("change",e),()=>t.removeEventListener("change",e)},()=>SM())}function kM({children:e}){const[t,n]=p.useState(()=>RP(Zr.theme,"system")),r=EM(),s=t==="system"?r:t;p.useEffect(()=>{const i=document.documentElement;i.classList.remove("light","dark"),i.classList.add(s)},[s]);const o=i=>{n(i),tx(Zr.theme,i)};return h.jsx(lw.Provider,{value:{theme:t,resolved:s,setTheme:o},children:e})}function bM(){return p.useContext(lw)}function CM(){const{theme:e,setTheme:t}=bM(),n=[{value:"light",icon:GN,label:"浅色"},{value:"dark",icon:BN,label:"深色"},{value:"system",icon:zN,label:"系统"}];return h.jsx("div",{className:"flex items-center rounded-md border border-border bg-muted/50 p-0.5",children:n.map(({value:r,icon:s,label:o})=>h.jsx("button",{onClick:()=>t(r),className:q("p-1 rounded-sm transition-colors",e===r?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),title:o,children:h.jsx(s,{className:"h-3.5 w-3.5"})},r))})}function TM(){const e=Oa(),{projects:t,loading:n,error:r,fetchProjects:s,addProject:o,updateProject:i,removeProject:a}=am(),l=xr(N=>N.clearToken),[c,d]=p.useState(!1),[u,f]=p.useState(!1),[y,w]=p.useState(new Set),x=p.useRef(new Map),[S,m]=p.useState(new Map),g=p.useRef(0),[v,E]=p.useState(!!document.fullscreenElement),[C,T]=p.useState(!1),[k,b]=p.useState(""),[A,P]=p.useState([]),[D,L]=p.useState(!1);p.useEffect(()=>{if(!k.trim()||k.trim().length<2){P([]);return}const N=setTimeout(()=>{L(!0),xx(k).then(B=>P(B)).catch(()=>P([])).finally(()=>L(!1))},400);return()=>clearTimeout(N)},[k]);const Q=()=>{document.fullscreenElement?document.exitFullscreen():document.documentElement.requestFullscreen()};p.useEffect(()=>{const N=()=>E(!!document.fullscreenElement);return document.addEventListener("fullscreenchange",N),()=>document.removeEventListener("fullscreenchange",N)},[]),p.useEffect(()=>{s()},[s]),p.useEffect(()=>{"Notification"in window&&Notification.permission==="default"&&Notification.requestPermission()},[]);const le=2e3,ge=3,z=8e3,re=p.useCallback(N=>{if(N.status){const ee=am.getState().projects.find(ue=>ue.id===N.projectId);ee&&ee.status!==N.status&&i({...ee,status:N.status})}const B=Date.now(),Y=x.current;if(B-N.lastActivityAt<le){w(ye=>ye.has(N.projectId)?ye:new Set(ye).add(N.projectId));const ee=Y.get(N.projectId)??[];let ue=!1;if(N.semantic){const ye=ee[ee.length-1],Zn=`${N.semantic.phase}:${N.semantic.detail??""}`,fn=ye?`${ye.phase}:${ye.detail??""}`:"";Zn!==fn?(ee.push({id:g.current++,phase:N.semantic.phase,detail:N.semantic.detail,ts:B}),ue=!0):ye&&(ye.ts=B)}const Pe=ee.filter(ye=>B-ye.ts<z),Ge=Pe.length>ge?Pe.slice(-ge):Pe;Ge.length!==ee.length&&(ue=!0),Y.set(N.projectId,Ge),ue&&m(new Map(Y))}else w(ee=>{if(!ee.has(N.projectId))return ee;const ue=new Set(ee);return ue.delete(N.projectId),ue}),Y.has(N.projectId)&&Y.get(N.projectId).length>0&&(Y.set(N.projectId,[]),m(new Map(Y)))},[]),j=p.useCallback((N,B)=>{"Notification"in window&&Notification.permission==="granted"&&new Notification("Claude 已完成",{body:`项目「${B}」的任务已完成`,icon:"/terminal.svg"})},[]);gM({onActivityUpdate:re,onProjectStopped:j}),p.useEffect(()=>{const N=setInterval(()=>{const B=Date.now(),Y=x.current;let ee=!1;for(const[ue,Pe]of Y){const Ge=Pe.filter(ye=>B-ye.ts<z);Ge.length!==Pe.length&&(Y.set(ue,Ge),ee=!0)}ee&&m(new Map(Y)),w(ue=>{let Pe=!1;const Ge=new Set(ue);for(const ye of ue){const Zn=Y.get(ye);(!Zn||Zn.length===0)&&(Ge.delete(ye),Pe=!0)}return Pe?Ge:ue})},3e3);return()=>clearInterval(N)},[]);const O=()=>{l(),e("/login")},V=N=>{o(N)},$=N=>{o(N)},se=async N=>{try{await lx(N),a(N)}catch(B){Di.error(B instanceof Error?B.message:"Failed to delete project")}},H=async N=>{try{const B=await ux(N);i(B)}catch(B){Di.error(B instanceof Error?B.message:"Failed to archive project")}},Z=async N=>{try{const B=await cx(N);i(B)}catch(B){Di.error(B instanceof Error?B.message:"Failed to restore project")}},K=p.useMemo(()=>t.filter(N=>!N.archived),[t]),pe=p.useMemo(()=>t.filter(N=>N.archived),[t]),Je=p.useMemo(()=>Array.from(new Set(t.flatMap(N=>N.tags??[]))),[t]),[J,Xt]=p.useState([]),cn=p.useMemo(()=>J.length===0?K:K.filter(N=>J.some(B=>{var Y;return(Y=N.tags)==null?void 0:Y.includes(B)})),[K,J]),[Qt,It]=AP(Zr.projectOrder,[],{parse:!0}),[gs,Xn]=p.useState(null),[Za,Qn]=p.useState(null);p.useEffect(()=>{if(K.length===0)return;const N=K.map(B=>B.id);It(B=>{const Y=B.filter(Pe=>N.includes(Pe)),ee=N.filter(Pe=>!B.includes(Pe)),ue=[...Y,...ee];return ue.join(",")===B.join(",")?B:ue})},[K]);const dn=p.useMemo(()=>Qt.length===0?cn:[...cn].sort((N,B)=>{const Y=Qt.indexOf(N.id),ee=Qt.indexOf(B.id);return Y===-1?1:ee===-1?-1:Y-ee}),[cn,Qt]),Ao=p.useCallback(N=>Xn(N),[]),kt=p.useCallback(()=>{Xn(null),Qn(null)},[]),qa=p.useCallback((N,B)=>{N.preventDefault(),Qn(B)},[]),Ja=p.useCallback((N,B,Y)=>{if(N.preventDefault(),!Y||Y===B){Qn(null);return}It(ee=>{const ue=[...ee],Pe=ue.indexOf(Y),Ge=ue.indexOf(B);return Pe===-1||Ge===-1?ee:(ue.splice(Pe,1),ue.splice(Ge,0,Y),ue)}),Xn(null),Qn(null)},[It]),ze={onDelete:N=>void se(N),onArchive:N=>void H(N),onUnarchive:N=>void Z(N),onUpdated:i};return h.jsxs("div",{className:"min-h-screen bg-background",children:[h.jsx("header",{className:"border-b sticky top-0 bg-background z-10",children:h.jsxs("div",{className:"max-w-6xl mx-auto px-4 h-14 flex items-center justify-between",children:[h.jsxs("div",{className:"flex items-center gap-2",children:[h.jsx(um,{className:"h-5 w-5"}),h.jsx("span",{className:"font-semibold text-lg",children:"CC Web"})]}),h.jsx(xM,{}),h.jsxs("div",{className:"relative",children:[h.jsx(UN,{className:"absolute left-2.5 top-1/2 -translate-y-1/2 h-3.5 w-3.5 text-muted-foreground pointer-events-none"}),h.jsx(go,{placeholder:"搜索历史对话…",value:k,onChange:N=>b(N.target.value),className:"pl-8 h-8 text-xs w-48"}),k.trim().length>=2&&h.jsxs("div",{className:"absolute top-full mt-1 right-0 w-96 max-h-80 overflow-y-auto bg-popover border border-border rounded-lg shadow-xl z-50",children:[D&&h.jsx("div",{className:"px-4 py-3 text-xs text-muted-foreground",children:"搜索中…"}),!D&&A.length===0&&h.jsx("div",{className:"px-4 py-3 text-xs text-muted-foreground",children:"无结果"}),A.map((N,B)=>h.jsxs("button",{className:"w-full text-left px-4 py-2.5 hover:bg-muted transition-colors border-b border-border last:border-0",onClick:()=>{e(`/project/${N.projectId}`),b("")},children:[h.jsxs("div",{className:"flex items-center gap-2 mb-0.5",children:[h.jsx("span",{className:"text-xs font-medium text-foreground truncate",children:N.projectName}),h.jsx("span",{className:"text-[10px] text-muted-foreground flex-shrink-0",children:new Date(N.startedAt).toLocaleDateString("zh-CN")})]}),h.jsx("p",{className:"text-[11px] text-muted-foreground leading-relaxed line-clamp-2",children:N.snippet})]},B))]})]}),h.jsx(ie,{variant:"ghost",size:"sm",onClick:()=>e("/skillhub"),title:"SkillHub",children:h.jsx(HN,{className:"h-4 w-4"})}),h.jsx(ie,{variant:"ghost",size:"sm",onClick:()=>e("/settings"),title:"设置",children:h.jsx(WN,{className:"h-4 w-4"})}),h.jsx(ie,{variant:"ghost",size:"sm",onClick:Q,title:v?"Exit fullscreen":"Fullscreen",children:v?h.jsx(FN,{className:"h-4 w-4"}):h.jsx(VN,{className:"h-4 w-4"})}),h.jsx(CM,{}),h.jsxs(ie,{variant:"ghost",size:"sm",onClick:O,children:[h.jsx(IN,{className:"h-4 w-4 mr-2"}),"Logout"]})]})}),h.jsxs("main",{className:"max-w-6xl mx-auto px-4 py-8",children:[h.jsxs("div",{className:"flex items-center justify-between mb-6",children:[h.jsxs("div",{children:[h.jsx("h1",{className:"text-2xl font-bold",children:"Projects"}),h.jsx("p",{className:"text-muted-foreground text-sm mt-1",children:"Each project runs Claude CLI in a dedicated terminal session."})]}),h.jsxs("div",{className:"flex gap-2",children:[h.jsxs(ie,{variant:"outline",onClick:()=>f(!0),children:[h.jsx(Ec,{className:"h-4 w-4 mr-2"}),"Open Project"]}),h.jsxs(ie,{onClick:()=>d(!0),children:[h.jsx(ma,{className:"h-4 w-4 mr-2"}),"New Project"]})]})]}),n&&h.jsx("div",{className:"text-center text-muted-foreground py-12",children:"Loading projects..."}),r&&h.jsx("div",{className:"text-center text-destructive py-12",children:r}),!n&&!r&&t.length===0&&h.jsxs("div",{className:"text-center py-20",children:[h.jsx(um,{className:"h-12 w-12 text-muted-foreground mx-auto mb-4"}),h.jsx("h2",{className:"text-lg font-semibold mb-2",children:"No projects yet"}),h.jsx("p",{className:"text-muted-foreground text-sm mb-6",children:"Create a new project or open an existing one."}),h.jsxs("div",{className:"flex gap-2 justify-center",children:[h.jsxs(ie,{variant:"outline",onClick:()=>f(!0),children:[h.jsx(Ec,{className:"h-4 w-4 mr-2"}),"Open Project"]}),h.jsxs(ie,{onClick:()=>d(!0),children:[h.jsx(ma,{className:"h-4 w-4 mr-2"}),"New Project"]})]})]}),!n&&!r&&Je.length>0&&h.jsxs("div",{className:"flex flex-wrap gap-1.5 mb-4",children:[Je.map(N=>h.jsxs("button",{onClick:()=>Xt(B=>B.includes(N)?B.filter(Y=>Y!==N):[...B,N]),className:q("px-2 py-0.5 rounded-full text-xs border transition-colors",J.includes(N)?"bg-blue-500/20 text-blue-400 border-blue-500/40":"bg-muted text-muted-foreground border-border hover:border-muted-foreground/40"),children:["#",N]},N)),J.length>0&&h.jsx("button",{onClick:()=>Xt([]),className:"px-2 py-0.5 rounded-full text-xs text-muted-foreground hover:text-foreground transition-colors",children:"清除"})]}),!n&&!r&&dn.length>0&&h.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",children:dn.map((N,B)=>h.jsx(Vn.div,{initial:{opacity:0,y:16},animate:{opacity:1,y:0},transition:{duration:.3,delay:B*.05,ease:"easeOut"},draggable:!0,onDragStart:()=>Ao(N.id),onDragOver:Y=>qa(Y,N.id),onDrop:Y=>Ja(Y,N.id,gs),onDragEnd:kt,style:{opacity:gs===N.id?.4:1,cursor:"grab"},className:q(Za===N.id&&gs!==N.id&&"ring-2 ring-blue-500/50 rounded-xl"),children:h.jsx(km,{project:N,active:y.has(N.id),statusStack:S.get(N.id)??[],...ze})},N.id))}),!n&&!r&&pe.length>0&&h.jsxs("div",{className:"mt-10",children:[h.jsxs("button",{className:"flex items-center gap-2 text-sm text-muted-foreground hover:text-foreground transition-colors mb-4 group",onClick:()=>T(N=>!N),children:[h.jsx(Vn.span,{animate:{rotate:C?90:0},transition:{duration:.2},children:h.jsx(wx,{className:"h-4 w-4"})}),h.jsx("span",{className:"font-medium",children:"Archived"}),h.jsx("span",{className:"text-xs bg-muted rounded-full px-2 py-0.5",children:pe.length})]}),h.jsx(qd,{children:C&&h.jsx(Vn.div,{initial:{opacity:0,height:0},animate:{opacity:1,height:"auto"},exit:{opacity:0,height:0},transition:{duration:.25,ease:"easeInOut"},className:"overflow-hidden",children:h.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",children:pe.map(N=>h.jsx(km,{project:N,active:!1,...ze},N.id))})})})]}),h.jsx(wM,{})]}),h.jsx(BR,{open:c,onOpenChange:d,onCreated:V}),h.jsx($R,{open:u,onOpenChange:f,onOpened:$})]})}class PM extends R.Component{constructor(){super(...arguments);tl(this,"state",{hasError:!1,error:null});tl(this,"handleReset",()=>{var n,r;this.setState({hasError:!1,error:null}),(r=(n=this.props).onReset)==null||r.call(n)})}static getDerivedStateFromError(n){return{hasError:!0,error:n}}componentDidCatch(n,r){console.error("[ErrorBoundary]",n,r.componentStack),Di.error(n.message||"Something went wrong")}render(){return this.state.hasError?this.props.fallback?this.props.fallback:h.jsxs("div",{className:"flex flex-col items-center justify-center h-full gap-3 p-4 text-sm text-muted-foreground",children:[h.jsx("p",{children:"出错了"}),h.jsx("button",{onClick:this.handleReset,className:"px-3 py-1.5 text-xs rounded-md border border-border hover:bg-muted transition-colors",children:"重新加载"})]}):this.props.children}}const NM=R.lazy(()=>bo(()=>import("./ProjectPage-BbEOvh4D.js").then(e=>e.P),__vite__mapDeps([0,1,2,3,4,5,6])).then(e=>({default:e.ProjectPage}))),jM=R.lazy(()=>bo(()=>import("./SettingsPage-W-rH5UiK.js"),__vite__mapDeps([7,3,1])).then(e=>({default:e.SettingsPage}))),RM=R.lazy(()=>bo(()=>import("./SkillHubPage-COgCGxfO.js"),__vite__mapDeps([8,5,2,3])).then(e=>({default:e.SkillHubPage}))),MM=R.lazy(()=>bo(()=>import("./ShareViewPage-BmPLFG-T.js"),__vite__mapDeps([9,5,4])).then(e=>({default:e.ShareViewPage})));function AM(){return h.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:h.jsx("span",{className:"text-muted-foreground text-sm",children:"Loading…"})})}function ci({children:e}){const[t,n]=p.useState(!1),r=xr(o=>o.token),s=xr(o=>o.setToken);return p.useEffect(()=>{if(r){n(!0);return}pa()?lf().then(o=>s(o)).catch(()=>{}).finally(()=>n(!0)):n(!0)},[]),!t&&!r?null:r?h.jsx(h.Fragment,{children:e}):h.jsx(ev,{to:"/login",replace:!0})}function DM(){return h.jsxs(kM,{children:[h.jsx(mM,{richColors:!0,position:"bottom-right"}),h.jsx(PM,{children:h.jsx(IE,{children:h.jsx(p.Suspense,{fallback:h.jsx(AM,{}),children:h.jsxs(LE,{children:[h.jsx(yn,{path:"/login",element:h.jsx(TN,{})}),h.jsx(yn,{path:"/",element:h.jsx(ci,{children:h.jsx(TM,{})})}),h.jsx(yn,{path:"/projects/:id",element:h.jsx(ci,{children:h.jsx(NM,{})})}),h.jsx(yn,{path:"/settings",element:h.jsx(ci,{children:h.jsx(jM,{})})}),h.jsx(yn,{path:"/skillhub",element:h.jsx(ci,{children:h.jsx(RM,{})})}),h.jsx(yn,{path:"/share/:token",element:h.jsx(MM,{})}),h.jsx(yn,{path:"*",element:h.jsx(ev,{to:"/",replace:!0})})]})})})})]})}nu.createRoot(document.getElementById("root")).render(h.jsx(R.StrictMode,{children:h.jsx(DM,{})}));export{EN as $,qd as A,ie as B,wx as C,HP as D,DN as E,Ec as F,dx as G,Kl as H,go as I,YP as J,hf as K,Ga as L,FN as M,Ka as N,Xa as O,Sx as P,Qa as Q,R,Zr as S,jn as T,Ya as U,KP as V,GP as W,uf as X,QP as Y,cm as Z,bo as _,_M as a,$P as a0,kN as a1,UP as a2,Oa as a3,MN as a4,rr as a5,xM as a6,CM as a7,uN as a8,zP as a9,lN as aA,nf as aB,rf as aC,sf as aD,of as aE,Ex as aF,mN as aG,oN as aH,cN as aI,fN as aJ,pN as aK,aN as aL,hN as aM,dN as aN,gN as aO,XP as aP,ZP as aQ,bN as aR,IM as aS,BP as aa,UN as ab,AP as ac,BM as ad,um as ae,VM as af,am as ag,yo as ah,kr as ai,ej as aj,un as ak,Fn as al,XN as am,Ba as an,Yl as ao,vo as ap,Ua as aq,Sd as ar,Nx as as,gR as at,Rj as au,_x as av,Tx as aw,bx as ax,sN as ay,iN as az,Mo as b,ne as c,eN as d,q as e,VN as f,Nm as g,qP as h,RP as i,h as j,yx as k,$N as l,JP as m,lm as n,Vn as o,yN as p,AN as q,p as r,tx as s,Di as t,bM as u,ma as v,tN as w,vN as x,xN as y,wN as z};