@musistudio/claude-code-router 1.0.35 → 1.0.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -0
- package/README_zh.md +2 -0
- package/dist/cli.js +4689 -4729
- package/dist/index.html +9 -9
- package/package.json +2 -2
- package/dist/lib/worker.js +0 -2
package/dist/index.html
CHANGED
|
@@ -44,15 +44,15 @@
|
|
|
44
44
|
*
|
|
45
45
|
* This source code is licensed under the MIT license found in the
|
|
46
46
|
* LICENSE file in the root directory of this source tree.
|
|
47
|
-
*/var Rv;function Xw(){if(Rv)return Wi;Rv=1;var n=Gw(),a=Ud(),l=$y();function i(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function s(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function u(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function f(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 h(e){if(u(e)!==e)throw Error(i(188))}function p(e){var t=e.alternate;if(!t){if(t=u(e),t===null)throw Error(i(188));return t!==e?null:e}for(var r=e,o=t;;){var c=r.return;if(c===null)break;var d=c.alternate;if(d===null){if(o=c.return,o!==null){r=o;continue}break}if(c.child===d.child){for(d=c.child;d;){if(d===r)return h(c),e;if(d===o)return h(c),t;d=d.sibling}throw Error(i(188))}if(r.return!==o.return)r=c,o=d;else{for(var b=!1,E=c.child;E;){if(E===r){b=!0,r=c,o=d;break}if(E===o){b=!0,o=c,r=d;break}E=E.sibling}if(!b){for(E=d.child;E;){if(E===r){b=!0,r=d,o=c;break}if(E===o){b=!0,o=d,r=c;break}E=E.sibling}if(!b)throw Error(i(189))}}if(r.alternate!==o)throw Error(i(190))}if(r.tag!==3)throw Error(i(188));return r.stateNode.current===r?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}var g=Object.assign,x=Symbol.for("react.element"),S=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),C=Symbol.for("react.fragment"),R=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),O=Symbol.for("react.provider"),z=Symbol.for("react.consumer"),k=Symbol.for("react.context"),H=Symbol.for("react.forward_ref"),P=Symbol.for("react.suspense"),A=Symbol.for("react.suspense_list"),G=Symbol.for("react.memo"),J=Symbol.for("react.lazy"),re=Symbol.for("react.activity"),ie=Symbol.for("react.memo_cache_sentinel"),Oe=Symbol.iterator;function Ee(e){return e===null||typeof e!="object"?null:(e=Oe&&e[Oe]||e["@@iterator"],typeof e=="function"?e:null)}var me=Symbol.for("react.client.reference");function he(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===me?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case C:return"Fragment";case T:return"Profiler";case R:return"StrictMode";case P:return"Suspense";case A:return"SuspenseList";case re:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case w:return"Portal";case k:return(e.displayName||"Context")+".Provider";case z:return(e._context.displayName||"Context")+".Consumer";case H:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case G:return t=e.displayName||null,t!==null?t:he(e.type)||"Memo";case J:t=e._payload,e=e._init;try{return he(e(t))}catch{}}return null}var fe=Array.isArray,_=a.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=l.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,$={pending:!1,data:null,method:null,action:null},pe=[],N=-1;function Y(e){return{current:e}}function L(e){0>N||(e.current=pe[N],pe[N]=null,N--)}function K(e,t){N++,pe[N]=e.current,e.current=t}var W=Y(null),oe=Y(null),de=Y(null),ge=Y(null);function ze(e,t){switch(K(de,t),K(oe,e),K(W,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Rg(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Rg(t),e=Cg(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}L(W),K(W,e)}function Ze(){L(W),L(oe),L(de)}function je(e){e.memoizedState!==null&&K(ge,e);var t=W.current,r=Cg(t,e.type);t!==r&&(K(oe,e),K(W,r))}function ae(e){oe.current===e&&(L(W),L(oe)),ge.current===e&&(L(ge),Gi._currentValue=$)}var te=Object.prototype.hasOwnProperty,se=n.unstable_scheduleCallback,ue=n.unstable_cancelCallback,Ne=n.unstable_shouldYield,Ue=n.unstable_requestPaint,Me=n.unstable_now,ot=n.unstable_getCurrentPriorityLevel,Cn=n.unstable_ImmediatePriority,qr=n.unstable_UserBlockingPriority,Yr=n.unstable_NormalPriority,Jn=n.unstable_LowPriority,Ra=n.unstable_IdlePriority,Co=n.log,ni=n.unstable_setDisableYieldValue,Yt=null,mt=null;function On(e){if(typeof Co=="function"&&ni(e),mt&&typeof mt.setStrictMode=="function")try{mt.setStrictMode(Yt,e)}catch{}}var Lt=Math.clz32?Math.clz32:Oo,ku=Math.log,Ln=Math.LN2;function Oo(e){return e>>>=0,e===0?32:31-(ku(e)/Ln|0)|0}var sr=256,ur=4194304;function In(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function cr(e,t,r){var o=e.pendingLanes;if(o===0)return 0;var c=0,d=e.suspendedLanes,b=e.pingedLanes;e=e.warmLanes;var E=o&134217727;return E!==0?(o=E&~d,o!==0?c=In(o):(b&=E,b!==0?c=In(b):r||(r=E&~e,r!==0&&(c=In(r))))):(E=o&~d,E!==0?c=In(E):b!==0?c=In(b):r||(r=o&~e,r!==0&&(c=In(r)))),c===0?0:t!==0&&t!==c&&(t&d)===0&&(d=c&-c,r=t&-t,d>=r||d===32&&(r&4194048)!==0)?t:c}function zn(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ao(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Kr(){var e=sr;return sr<<=1,(sr&4194048)===0&&(sr=256),e}function No(){var e=ur;return ur<<=1,(ur&62914560)===0&&(ur=4194304),e}function Gr(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function fr(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function To(e,t,r,o,c,d){var b=e.pendingLanes;e.pendingLanes=r,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=r,e.entangledLanes&=r,e.errorRecoveryDisabledLanes&=r,e.shellSuspendCounter=0;var E=e.entanglements,j=e.expirationTimes,q=e.hiddenUpdates;for(r=b&~r;0<r;){var I=31-Lt(r),ne=1<<I;E[I]=0,j[I]=-1;var F=q[I];if(F!==null)for(q[I]=null,I=0;I<F.length;I++){var X=F[I];X!==null&&(X.lane&=-536870913)}r&=~ne}o!==0&&dr(e,o,0),d!==0&&c===0&&e.tag!==0&&(e.suspendedLanes|=d&~(b&~t))}function dr(e,t,r){e.pendingLanes|=t,e.suspendedLanes&=~t;var o=31-Lt(t);e.entangledLanes|=t,e.entanglements[o]=e.entanglements[o]|1073741824|r&4194090}function hr(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var o=31-Lt(r),c=1<<o;c&t|e[o]&t&&(e[o]|=t),r&=~c}}function ai(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function ri(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function M(){var e=Z.p;return e!==0?e:(e=window.event,e===void 0?32:Yg(e.type))}function B(e,t){var r=Z.p;try{return Z.p=e,t()}finally{Z.p=r}}var Q=Math.random().toString(36).slice(2),le="__reactFiber$"+Q,ce="__reactProps$"+Q,xe="__reactContainer$"+Q,Re="__reactEvents$"+Q,Se="__reactListeners$"+Q,Te="__reactHandles$"+Q,_e="__reactResources$"+Q,we="__reactMarker$"+Q;function Ce(e){delete e[le],delete e[ce],delete e[Re],delete e[Se],delete e[Te]}function Ve(e){var t=e[le];if(t)return t;for(var r=e.parentNode;r;){if(t=r[xe]||r[le]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=Tg(e);e!==null;){if(r=e[le])return r;e=Tg(e)}return t}e=r,r=e.parentNode}return null}function et(e){if(e=e[le]||e[xe]){var t=e.tag;if(t===5||t===6||t===13||t===26||t===27||t===3)return e}return null}function vt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function yt(e){var t=e[_e];return t||(t=e[_e]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Be(e){e[we]=!0}var at=new Set,kn={};function It(e,t){Vt(e,t),Vt(e+"Capture",t)}function Vt(e,t){for(kn[e]=t,e=0;e<t.length;e++)at.add(t[e])}var dn=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Fr={},Ca={};function Wn(e){return te.call(Ca,e)?!0:te.call(Fr,e)?!1:dn.test(e)?Ca[e]=!0:(Fr[e]=!0,!1)}function ea(e,t,r){if(Wn(t))if(r===null)e.removeAttribute(t);else{switch(typeof r){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var o=t.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+r)}}function ta(e,t,r){if(r===null)e.removeAttribute(t);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+r)}}function Ke(e,t,r,o){if(o===null)e.removeAttribute(r);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(r);return}e.setAttributeNS(t,r,""+o)}}var Ct,mr;function hn(e){if(Ct===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);Ct=t&&t[1]||"",mr=-1<r.stack.indexOf(`
|
|
47
|
+
*/var Rv;function Xw(){if(Rv)return Wi;Rv=1;var n=Gw(),a=Ud(),l=$y();function i(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function s(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function u(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function f(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 h(e){if(u(e)!==e)throw Error(i(188))}function p(e){var t=e.alternate;if(!t){if(t=u(e),t===null)throw Error(i(188));return t!==e?null:e}for(var r=e,o=t;;){var c=r.return;if(c===null)break;var d=c.alternate;if(d===null){if(o=c.return,o!==null){r=o;continue}break}if(c.child===d.child){for(d=c.child;d;){if(d===r)return h(c),e;if(d===o)return h(c),t;d=d.sibling}throw Error(i(188))}if(r.return!==o.return)r=c,o=d;else{for(var b=!1,E=c.child;E;){if(E===r){b=!0,r=c,o=d;break}if(E===o){b=!0,o=c,r=d;break}E=E.sibling}if(!b){for(E=d.child;E;){if(E===r){b=!0,r=d,o=c;break}if(E===o){b=!0,o=d,r=c;break}E=E.sibling}if(!b)throw Error(i(189))}}if(r.alternate!==o)throw Error(i(190))}if(r.tag!==3)throw Error(i(188));return r.stateNode.current===r?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}var g=Object.assign,x=Symbol.for("react.element"),S=Symbol.for("react.transitional.element"),w=Symbol.for("react.portal"),C=Symbol.for("react.fragment"),R=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),O=Symbol.for("react.provider"),z=Symbol.for("react.consumer"),k=Symbol.for("react.context"),H=Symbol.for("react.forward_ref"),P=Symbol.for("react.suspense"),A=Symbol.for("react.suspense_list"),G=Symbol.for("react.memo"),J=Symbol.for("react.lazy"),re=Symbol.for("react.activity"),ie=Symbol.for("react.memo_cache_sentinel"),Oe=Symbol.iterator;function Ee(e){return e===null||typeof e!="object"?null:(e=Oe&&e[Oe]||e["@@iterator"],typeof e=="function"?e:null)}var me=Symbol.for("react.client.reference");function he(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===me?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case C:return"Fragment";case T:return"Profiler";case R:return"StrictMode";case P:return"Suspense";case A:return"SuspenseList";case re:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case w:return"Portal";case k:return(e.displayName||"Context")+".Provider";case z:return(e._context.displayName||"Context")+".Consumer";case H:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case G:return t=e.displayName||null,t!==null?t:he(e.type)||"Memo";case J:t=e._payload,e=e._init;try{return he(e(t))}catch{}}return null}var fe=Array.isArray,_=a.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=l.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,$={pending:!1,data:null,method:null,action:null},pe=[],N=-1;function Y(e){return{current:e}}function L(e){0>N||(e.current=pe[N],pe[N]=null,N--)}function K(e,t){N++,pe[N]=e.current,e.current=t}var W=Y(null),oe=Y(null),de=Y(null),ge=Y(null);function ze(e,t){switch(K(de,t),K(oe,e),K(W,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Rg(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Rg(t),e=Cg(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}L(W),K(W,e)}function Ze(){L(W),L(oe),L(de)}function je(e){e.memoizedState!==null&&K(ge,e);var t=W.current,r=Cg(t,e.type);t!==r&&(K(oe,e),K(W,r))}function ae(e){oe.current===e&&(L(W),L(oe)),ge.current===e&&(L(ge),Gi._currentValue=$)}var te=Object.prototype.hasOwnProperty,se=n.unstable_scheduleCallback,ue=n.unstable_cancelCallback,Ne=n.unstable_shouldYield,Ue=n.unstable_requestPaint,Me=n.unstable_now,ot=n.unstable_getCurrentPriorityLevel,Cn=n.unstable_ImmediatePriority,qr=n.unstable_UserBlockingPriority,Yr=n.unstable_NormalPriority,Jn=n.unstable_LowPriority,Ra=n.unstable_IdlePriority,Co=n.log,ni=n.unstable_setDisableYieldValue,Yt=null,mt=null;function On(e){if(typeof Co=="function"&&ni(e),mt&&typeof mt.setStrictMode=="function")try{mt.setStrictMode(Yt,e)}catch{}}var Lt=Math.clz32?Math.clz32:Oo,ku=Math.log,Ln=Math.LN2;function Oo(e){return e>>>=0,e===0?32:31-(ku(e)/Ln|0)|0}var sr=256,ur=4194304;function In(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194048;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function cr(e,t,r){var o=e.pendingLanes;if(o===0)return 0;var c=0,d=e.suspendedLanes,b=e.pingedLanes;e=e.warmLanes;var E=o&134217727;return E!==0?(o=E&~d,o!==0?c=In(o):(b&=E,b!==0?c=In(b):r||(r=E&~e,r!==0&&(c=In(r))))):(E=o&~d,E!==0?c=In(E):b!==0?c=In(b):r||(r=o&~e,r!==0&&(c=In(r)))),c===0?0:t!==0&&t!==c&&(t&d)===0&&(d=c&-c,r=t&-t,d>=r||d===32&&(r&4194048)!==0)?t:c}function zn(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ao(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Kr(){var e=sr;return sr<<=1,(sr&4194048)===0&&(sr=256),e}function No(){var e=ur;return ur<<=1,(ur&62914560)===0&&(ur=4194304),e}function Gr(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function fr(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function To(e,t,r,o,c,d){var b=e.pendingLanes;e.pendingLanes=r,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=r,e.entangledLanes&=r,e.errorRecoveryDisabledLanes&=r,e.shellSuspendCounter=0;var E=e.entanglements,j=e.expirationTimes,q=e.hiddenUpdates;for(r=b&~r;0<r;){var I=31-Lt(r),ne=1<<I;E[I]=0,j[I]=-1;var F=q[I];if(F!==null)for(q[I]=null,I=0;I<F.length;I++){var X=F[I];X!==null&&(X.lane&=-536870913)}r&=~ne}o!==0&&dr(e,o,0),d!==0&&c===0&&e.tag!==0&&(e.suspendedLanes|=d&~(b&~t))}function dr(e,t,r){e.pendingLanes|=t,e.suspendedLanes&=~t;var o=31-Lt(t);e.entangledLanes|=t,e.entanglements[o]=e.entanglements[o]|1073741824|r&4194090}function hr(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var o=31-Lt(r),c=1<<o;c&t|e[o]&t&&(e[o]|=t),r&=~c}}function ai(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function ri(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function M(){var e=Z.p;return e!==0?e:(e=window.event,e===void 0?32:Yg(e.type))}function B(e,t){var r=Z.p;try{return Z.p=e,t()}finally{Z.p=r}}var Q=Math.random().toString(36).slice(2),le="__reactFiber$"+Q,ce="__reactProps$"+Q,xe="__reactContainer$"+Q,Re="__reactEvents$"+Q,Se="__reactListeners$"+Q,Te="__reactHandles$"+Q,_e="__reactResources$"+Q,we="__reactMarker$"+Q;function Ce(e){delete e[le],delete e[ce],delete e[Re],delete e[Se],delete e[Te]}function Ve(e){var t=e[le];if(t)return t;for(var r=e.parentNode;r;){if(t=r[xe]||r[le]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=Tg(e);e!==null;){if(r=e[le])return r;e=Tg(e)}return t}e=r,r=e.parentNode}return null}function et(e){if(e=e[le]||e[xe]){var t=e.tag;if(t===5||t===6||t===13||t===26||t===27||t===3)return e}return null}function vt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function yt(e){var t=e[_e];return t||(t=e[_e]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Be(e){e[we]=!0}var at=new Set,kn={};function Jt(e,t){Vt(e,t),Vt(e+"Capture",t)}function Vt(e,t){for(kn[e]=t,e=0;e<t.length;e++)at.add(t[e])}var dn=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Fr={},Ca={};function Wn(e){return te.call(Ca,e)?!0:te.call(Fr,e)?!1:dn.test(e)?Ca[e]=!0:(Fr[e]=!0,!1)}function ea(e,t,r){if(Wn(t))if(r===null)e.removeAttribute(t);else{switch(typeof r){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var o=t.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+r)}}function ta(e,t,r){if(r===null)e.removeAttribute(t);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+r)}}function Ke(e,t,r,o){if(o===null)e.removeAttribute(r);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(r);return}e.setAttributeNS(t,r,""+o)}}var Ct,mr;function hn(e){if(Ct===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);Ct=t&&t[1]||"",mr=-1<r.stack.indexOf(`
|
|
48
48
|
at`)?" (<anonymous>)":-1<r.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
49
49
|
`+Ct+e+mr}var pt=!1;function Oa(e,t){if(!e||pt)return"";pt=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var o={DetermineComponentFrameRoot:function(){try{if(t){var ne=function(){throw Error()};if(Object.defineProperty(ne.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ne,[])}catch(X){var F=X}Reflect.construct(e,[],ne)}else{try{ne.call()}catch(X){F=X}e.call(ne.prototype)}}else{try{throw Error()}catch(X){F=X}(ne=e())&&typeof ne.catch=="function"&&ne.catch(function(){})}}catch(X){if(X&&F&&typeof X.stack=="string")return[X.stack,F.stack]}return[null,null]}};o.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var c=Object.getOwnPropertyDescriptor(o.DetermineComponentFrameRoot,"name");c&&c.configurable&&Object.defineProperty(o.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var d=o.DetermineComponentFrameRoot(),b=d[0],E=d[1];if(b&&E){var j=b.split(`
|
|
50
50
|
`),q=E.split(`
|
|
51
51
|
`);for(c=o=0;o<j.length&&!j[o].includes("DetermineComponentFrameRoot");)o++;for(;c<q.length&&!q[c].includes("DetermineComponentFrameRoot");)c++;if(o===j.length||c===q.length)for(o=j.length-1,c=q.length-1;1<=o&&0<=c&&j[o]!==q[c];)c--;for(;1<=o&&0<=c;o--,c--)if(j[o]!==q[c]){if(o!==1||c!==1)do if(o--,c--,0>c||j[o]!==q[c]){var I=`
|
|
52
52
|
`+j[o].replace(" at new "," at ");return e.displayName&&I.includes("<anonymous>")&&(I=I.replace("<anonymous>",e.displayName)),I}while(1<=o&&0<=c);break}}}finally{pt=!1,Error.prepareStackTrace=r}return(r=e?e.displayName||e.name:"")?hn(r):""}function jo(e){switch(e.tag){case 26:case 27:case 5:return hn(e.type);case 16:return hn("Lazy");case 13:return hn("Suspense");case 19:return hn("SuspenseList");case 0:case 15:return Oa(e.type,!1);case 11:return Oa(e.type.render,!1);case 1:return Oa(e.type,!0);case 31:return hn("Activity");default:return""}}function Mo(e){try{var t="";do t+=jo(e),e=e.return;while(e);return t}catch(r){return`
|
|
53
53
|
Error generating stack: `+r.message+`
|
|
54
|
-
`+r.stack}}function mn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function bh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Ex(e){var t=bh(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),o=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var c=r.get,d=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return c.call(this)},set:function(b){o=""+b,d.call(this,b)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return o},setValue:function(b){o=""+b},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function _o(e){e._valueTracker||(e._valueTracker=Ex(e))}function xh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),o="";return e&&(o=bh(e)?e.checked?"true":"false":e.value),e=o,e!==r?(t.setValue(e),!0):!1}function Do(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}}var Rx=/[\n"\\]/g;function pn(e){return e.replace(Rx,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Uu(e,t,r,o,c,d,b,E){e.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.type=b:e.removeAttribute("type"),t!=null?b==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+mn(t)):e.value!==""+mn(t)&&(e.value=""+mn(t)):b!=="submit"&&b!=="reset"||e.removeAttribute("value"),t!=null?Pu(e,b,mn(t)):r!=null?Pu(e,b,mn(r)):o!=null&&e.removeAttribute("value"),c==null&&d!=null&&(e.defaultChecked=!!d),c!=null&&(e.checked=c&&typeof c!="function"&&typeof c!="symbol"),E!=null&&typeof E!="function"&&typeof E!="symbol"&&typeof E!="boolean"?e.name=""+mn(E):e.removeAttribute("name")}function Sh(e,t,r,o,c,d,b,E){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),t!=null||r!=null){if(!(d!=="submit"&&d!=="reset"||t!=null))return;r=r!=null?""+mn(r):"",t=t!=null?""+mn(t):r,E||t===e.value||(e.value=t),e.defaultValue=t}o=o??c,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=E?e.checked:!!o,e.defaultChecked=!!o,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(e.name=b)}function Pu(e,t,r){t==="number"&&Do(e.ownerDocument)===e||e.defaultValue===""+r||(e.defaultValue=""+r)}function Xr(e,t,r,o){if(e=e.options,t){t={};for(var c=0;c<r.length;c++)t["$"+r[c]]=!0;for(r=0;r<e.length;r++)c=t.hasOwnProperty("$"+e[r].value),e[r].selected!==c&&(e[r].selected=c),c&&o&&(e[r].defaultSelected=!0)}else{for(r=""+mn(r),t=null,c=0;c<e.length;c++){if(e[c].value===r){e[c].selected=!0,o&&(e[c].defaultSelected=!0);return}t!==null||e[c].disabled||(t=e[c])}t!==null&&(t.selected=!0)}}function wh(e,t,r){if(t!=null&&(t=""+mn(t),t!==e.value&&(e.value=t),r==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=r!=null?""+mn(r):""}function Eh(e,t,r,o){if(t==null){if(o!=null){if(r!=null)throw Error(i(92));if(fe(o)){if(1<o.length)throw Error(i(93));o=o[0]}r=o}r==null&&(r=""),t=r}r=mn(t),e.defaultValue=r,o=e.textContent,o===r&&o!==""&&o!==null&&(e.value=o)}function Qr(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Cx=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Rh(e,t,r){var o=t.indexOf("--")===0;r==null||typeof r=="boolean"||r===""?o?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":o?e.setProperty(t,r):typeof r!="number"||r===0||Cx.has(t)?t==="float"?e.cssFloat=r:e[t]=(""+r).trim():e[t]=r+"px"}function Ch(e,t,r){if(t!=null&&typeof t!="object")throw Error(i(62));if(e=e.style,r!=null){for(var o in r)!r.hasOwnProperty(o)||t!=null&&t.hasOwnProperty(o)||(o.indexOf("--")===0?e.setProperty(o,""):o==="float"?e.cssFloat="":e[o]="");for(var c in t)o=t[c],t.hasOwnProperty(c)&&r[c]!==o&&Rh(e,c,o)}else for(var d in t)t.hasOwnProperty(d)&&Rh(e,d,t[d])}function Hu(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Ox=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Ax=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Lo(e){return Ax.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Bu=null;function $u(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Zr=null,Jr=null;function Oh(e){var t=et(e);if(t&&(e=t.stateNode)){var r=e[ce]||null;e:switch(e=t.stateNode,t.type){case"input":if(Uu(e,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll('input[name="'+pn(""+t)+'"][type="radio"]'),t=0;t<r.length;t++){var o=r[t];if(o!==e&&o.form===e.form){var c=o[ce]||null;if(!c)throw Error(i(90));Uu(o,c.value,c.defaultValue,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name)}}for(t=0;t<r.length;t++)o=r[t],o.form===e.form&&xh(o)}break e;case"textarea":wh(e,r.value,r.defaultValue);break e;case"select":t=r.value,t!=null&&Xr(e,!!r.multiple,t,!1)}}}var Vu=!1;function Ah(e,t,r){if(Vu)return e(t,r);Vu=!0;try{var o=e(t);return o}finally{if(Vu=!1,(Zr!==null||Jr!==null)&&(bs(),Zr&&(t=Zr,e=Jr,Jr=Zr=null,Oh(t),e)))for(t=0;t<e.length;t++)Oh(e[t])}}function li(e,t){var r=e.stateNode;if(r===null)return null;var o=r[ce]||null;if(o===null)return null;r=o[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":(o=!o.disabled)||(e=e.type,o=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!o;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error(i(231,t,typeof r));return r}var na=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qu=!1;if(na)try{var ii={};Object.defineProperty(ii,"passive",{get:function(){qu=!0}}),window.addEventListener("test",ii,ii),window.removeEventListener("test",ii,ii)}catch{qu=!1}var Aa=null,Yu=null,zo=null;function Nh(){if(zo)return zo;var e,t=Yu,r=t.length,o,c="value"in Aa?Aa.value:Aa.textContent,d=c.length;for(e=0;e<r&&t[e]===c[e];e++);var b=r-e;for(o=1;o<=b&&t[r-o]===c[d-o];o++);return zo=c.slice(e,1<o?1-o:void 0)}function ko(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 Uo(){return!0}function Th(){return!1}function Kt(e){function t(r,o,c,d,b){this._reactName=r,this._targetInst=c,this.type=o,this.nativeEvent=d,this.target=b,this.currentTarget=null;for(var E in e)e.hasOwnProperty(E)&&(r=e[E],this[E]=r?r(d):d[E]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?Uo:Th,this.isPropagationStopped=Th,this}return g(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=Uo)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=Uo)},persist:function(){},isPersistent:Uo}),t}var pr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Po=Kt(pr),oi=g({},pr,{view:0,detail:0}),Nx=Kt(oi),Ku,Gu,si,Ho=g({},oi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Xu,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!==si&&(si&&e.type==="mousemove"?(Ku=e.screenX-si.screenX,Gu=e.screenY-si.screenY):Gu=Ku=0,si=e),Ku)},movementY:function(e){return"movementY"in e?e.movementY:Gu}}),jh=Kt(Ho),Tx=g({},Ho,{dataTransfer:0}),jx=Kt(Tx),Mx=g({},oi,{relatedTarget:0}),Fu=Kt(Mx),_x=g({},pr,{animationName:0,elapsedTime:0,pseudoElement:0}),Dx=Kt(_x),Lx=g({},pr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),zx=Kt(Lx),kx=g({},pr,{data:0}),Mh=Kt(kx),Ux={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Px={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"},Hx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Bx(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Hx[e])?!!t[e]:!1}function Xu(){return Bx}var $x=g({},oi,{key:function(e){if(e.key){var t=Ux[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ko(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Px[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Xu,charCode:function(e){return e.type==="keypress"?ko(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ko(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Vx=Kt($x),qx=g({},Ho,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),_h=Kt(qx),Yx=g({},oi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Xu}),Kx=Kt(Yx),Gx=g({},pr,{propertyName:0,elapsedTime:0,pseudoElement:0}),Fx=Kt(Gx),Xx=g({},Ho,{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}),Qx=Kt(Xx),Zx=g({},pr,{newState:0,oldState:0}),Jx=Kt(Zx),Ix=[9,13,27,32],Qu=na&&"CompositionEvent"in window,ui=null;na&&"documentMode"in document&&(ui=document.documentMode);var Wx=na&&"TextEvent"in window&&!ui,Dh=na&&(!Qu||ui&&8<ui&&11>=ui),Lh=" ",zh=!1;function kh(e,t){switch(e){case"keyup":return Ix.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Uh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ir=!1;function e1(e,t){switch(e){case"compositionend":return Uh(t);case"keypress":return t.which!==32?null:(zh=!0,Lh);case"textInput":return e=t.data,e===Lh&&zh?null:e;default:return null}}function t1(e,t){if(Ir)return e==="compositionend"||!Qu&&kh(e,t)?(e=Nh(),zo=Yu=Aa=null,Ir=!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 Dh&&t.locale!=="ko"?null:t.data;default:return null}}var n1={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 Ph(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!n1[e.type]:t==="textarea"}function Hh(e,t,r,o){Zr?Jr?Jr.push(o):Jr=[o]:Zr=o,t=Cs(t,"onChange"),0<t.length&&(r=new Po("onChange","change",null,r,o),e.push({event:r,listeners:t}))}var ci=null,fi=null;function a1(e){bg(e,0)}function Bo(e){var t=vt(e);if(xh(t))return e}function Bh(e,t){if(e==="change")return t}var $h=!1;if(na){var Zu;if(na){var Ju="oninput"in document;if(!Ju){var Vh=document.createElement("div");Vh.setAttribute("oninput","return;"),Ju=typeof Vh.oninput=="function"}Zu=Ju}else Zu=!1;$h=Zu&&(!document.documentMode||9<document.documentMode)}function qh(){ci&&(ci.detachEvent("onpropertychange",Yh),fi=ci=null)}function Yh(e){if(e.propertyName==="value"&&Bo(fi)){var t=[];Hh(t,fi,e,$u(e)),Ah(a1,t)}}function r1(e,t,r){e==="focusin"?(qh(),ci=t,fi=r,ci.attachEvent("onpropertychange",Yh)):e==="focusout"&&qh()}function l1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Bo(fi)}function i1(e,t){if(e==="click")return Bo(t)}function o1(e,t){if(e==="input"||e==="change")return Bo(t)}function s1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Wt=typeof Object.is=="function"?Object.is:s1;function di(e,t){if(Wt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),o=Object.keys(t);if(r.length!==o.length)return!1;for(o=0;o<r.length;o++){var c=r[o];if(!te.call(t,c)||!Wt(e[c],t[c]))return!1}return!0}function Kh(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Gh(e,t){var r=Kh(e);e=0;for(var o;r;){if(r.nodeType===3){if(o=e+r.textContent.length,e<=t&&o>=t)return{node:r,offset:t-e};e=o}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Kh(r)}}function Fh(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Fh(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Xh(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Do(e.document);t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Do(e.document)}return t}function Iu(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var u1=na&&"documentMode"in document&&11>=document.documentMode,Wr=null,Wu=null,hi=null,ec=!1;function Qh(e,t,r){var o=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;ec||Wr==null||Wr!==Do(o)||(o=Wr,"selectionStart"in o&&Iu(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),hi&&di(hi,o)||(hi=o,o=Cs(Wu,"onSelect"),0<o.length&&(t=new Po("onSelect","select",null,t,r),e.push({event:t,listeners:o}),t.target=Wr)))}function gr(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var el={animationend:gr("Animation","AnimationEnd"),animationiteration:gr("Animation","AnimationIteration"),animationstart:gr("Animation","AnimationStart"),transitionrun:gr("Transition","TransitionRun"),transitionstart:gr("Transition","TransitionStart"),transitioncancel:gr("Transition","TransitionCancel"),transitionend:gr("Transition","TransitionEnd")},tc={},Zh={};na&&(Zh=document.createElement("div").style,"AnimationEvent"in window||(delete el.animationend.animation,delete el.animationiteration.animation,delete el.animationstart.animation),"TransitionEvent"in window||delete el.transitionend.transition);function vr(e){if(tc[e])return tc[e];if(!el[e])return e;var t=el[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in Zh)return tc[e]=t[r];return e}var Jh=vr("animationend"),Ih=vr("animationiteration"),Wh=vr("animationstart"),c1=vr("transitionrun"),f1=vr("transitionstart"),d1=vr("transitioncancel"),em=vr("transitionend"),tm=new Map,nc="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");nc.push("scrollEnd");function An(e,t){tm.set(e,t),It(t,[e])}var nm=new WeakMap;function gn(e,t){if(typeof e=="object"&&e!==null){var r=nm.get(e);return r!==void 0?r:(t={value:e,source:t,stack:Mo(t)},nm.set(e,t),t)}return{value:e,source:t,stack:Mo(t)}}var vn=[],tl=0,ac=0;function $o(){for(var e=tl,t=ac=tl=0;t<e;){var r=vn[t];vn[t++]=null;var o=vn[t];vn[t++]=null;var c=vn[t];vn[t++]=null;var d=vn[t];if(vn[t++]=null,o!==null&&c!==null){var b=o.pending;b===null?c.next=c:(c.next=b.next,b.next=c),o.pending=c}d!==0&&am(r,c,d)}}function Vo(e,t,r,o){vn[tl++]=e,vn[tl++]=t,vn[tl++]=r,vn[tl++]=o,ac|=o,e.lanes|=o,e=e.alternate,e!==null&&(e.lanes|=o)}function rc(e,t,r,o){return Vo(e,t,r,o),qo(e)}function nl(e,t){return Vo(e,null,null,t),qo(e)}function am(e,t,r){e.lanes|=r;var o=e.alternate;o!==null&&(o.lanes|=r);for(var c=!1,d=e.return;d!==null;)d.childLanes|=r,o=d.alternate,o!==null&&(o.childLanes|=r),d.tag===22&&(e=d.stateNode,e===null||e._visibility&1||(c=!0)),e=d,d=d.return;return e.tag===3?(d=e.stateNode,c&&t!==null&&(c=31-Lt(r),e=d.hiddenUpdates,o=e[c],o===null?e[c]=[t]:o.push(t),t.lane=r|536870912),d):null}function qo(e){if(50<Pi)throw Pi=0,ff=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var al={};function h1(e,t,r,o){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function en(e,t,r,o){return new h1(e,t,r,o)}function lc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function aa(e,t){var r=e.alternate;return r===null?(r=en(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&65011712,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r.refCleanup=e.refCleanup,r}function rm(e,t){e.flags&=65011714;var r=e.alternate;return r===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=r.childLanes,e.lanes=r.lanes,e.child=r.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=r.memoizedProps,e.memoizedState=r.memoizedState,e.updateQueue=r.updateQueue,e.type=r.type,t=r.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Yo(e,t,r,o,c,d){var b=0;if(o=e,typeof e=="function")lc(e)&&(b=1);else if(typeof e=="string")b=pS(e,r,W.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case re:return e=en(31,r,t,c),e.elementType=re,e.lanes=d,e;case C:return yr(r.children,c,d,t);case R:b=8,c|=24;break;case T:return e=en(12,r,t,c|2),e.elementType=T,e.lanes=d,e;case P:return e=en(13,r,t,c),e.elementType=P,e.lanes=d,e;case A:return e=en(19,r,t,c),e.elementType=A,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case O:case k:b=10;break e;case z:b=9;break e;case H:b=11;break e;case G:b=14;break e;case J:b=16,o=null;break e}b=29,r=Error(i(130,e===null?"null":typeof e,"")),o=null}return t=en(b,r,t,c),t.elementType=e,t.type=o,t.lanes=d,t}function yr(e,t,r,o){return e=en(7,e,o,t),e.lanes=r,e}function ic(e,t,r){return e=en(6,e,null,t),e.lanes=r,e}function oc(e,t,r){return t=en(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var rl=[],ll=0,Ko=null,Go=0,yn=[],bn=0,br=null,ra=1,la="";function xr(e,t){rl[ll++]=Go,rl[ll++]=Ko,Ko=e,Go=t}function lm(e,t,r){yn[bn++]=ra,yn[bn++]=la,yn[bn++]=br,br=e;var o=ra;e=la;var c=32-Lt(o)-1;o&=~(1<<c),r+=1;var d=32-Lt(t)+c;if(30<d){var b=c-c%5;d=(o&(1<<b)-1).toString(32),o>>=b,c-=b,ra=1<<32-Lt(t)+c|r<<c|o,la=d+e}else ra=1<<d|r<<c|o,la=e}function sc(e){e.return!==null&&(xr(e,1),lm(e,1,0))}function uc(e){for(;e===Ko;)Ko=rl[--ll],rl[ll]=null,Go=rl[--ll],rl[ll]=null;for(;e===br;)br=yn[--bn],yn[bn]=null,la=yn[--bn],yn[bn]=null,ra=yn[--bn],yn[bn]=null}var qt=null,bt=null,We=!1,Sr=null,Un=!1,cc=Error(i(519));function wr(e){var t=Error(i(418,""));throw gi(gn(t,e)),cc}function im(e){var t=e.stateNode,r=e.type,o=e.memoizedProps;switch(t[le]=e,t[ce]=o,r){case"dialog":Qe("cancel",t),Qe("close",t);break;case"iframe":case"object":case"embed":Qe("load",t);break;case"video":case"audio":for(r=0;r<Bi.length;r++)Qe(Bi[r],t);break;case"source":Qe("error",t);break;case"img":case"image":case"link":Qe("error",t),Qe("load",t);break;case"details":Qe("toggle",t);break;case"input":Qe("invalid",t),Sh(t,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0),_o(t);break;case"select":Qe("invalid",t);break;case"textarea":Qe("invalid",t),Eh(t,o.value,o.defaultValue,o.children),_o(t)}r=o.children,typeof r!="string"&&typeof r!="number"&&typeof r!="bigint"||t.textContent===""+r||o.suppressHydrationWarning===!0||Eg(t.textContent,r)?(o.popover!=null&&(Qe("beforetoggle",t),Qe("toggle",t)),o.onScroll!=null&&Qe("scroll",t),o.onScrollEnd!=null&&Qe("scrollend",t),o.onClick!=null&&(t.onclick=Os),t=!0):t=!1,t||wr(e)}function om(e){for(qt=e.return;qt;)switch(qt.tag){case 5:case 13:Un=!1;return;case 27:case 3:Un=!0;return;default:qt=qt.return}}function mi(e){if(e!==qt)return!1;if(!We)return om(e),We=!0,!1;var t=e.tag,r;if((r=t!==3&&t!==27)&&((r=t===5)&&(r=e.type,r=!(r!=="form"&&r!=="button")||Af(e.type,e.memoizedProps)),r=!r),r&&bt&&wr(e),om(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8)if(r=e.data,r==="/$"){if(t===0){bt=Tn(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++;e=e.nextSibling}bt=null}}else t===27?(t=bt,qa(e.type)?(e=Mf,Mf=null,bt=e):bt=t):bt=qt?Tn(e.stateNode.nextSibling):null;return!0}function pi(){bt=qt=null,We=!1}function sm(){var e=Sr;return e!==null&&(Xt===null?Xt=e:Xt.push.apply(Xt,e),Sr=null),e}function gi(e){Sr===null?Sr=[e]:Sr.push(e)}var fc=Y(null),Er=null,ia=null;function Na(e,t,r){K(fc,t._currentValue),t._currentValue=r}function oa(e){e._currentValue=fc.current,L(fc)}function dc(e,t,r){for(;e!==null;){var o=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,o!==null&&(o.childLanes|=t)):o!==null&&(o.childLanes&t)!==t&&(o.childLanes|=t),e===r)break;e=e.return}}function hc(e,t,r,o){var c=e.child;for(c!==null&&(c.return=e);c!==null;){var d=c.dependencies;if(d!==null){var b=c.child;d=d.firstContext;e:for(;d!==null;){var E=d;d=c;for(var j=0;j<t.length;j++)if(E.context===t[j]){d.lanes|=r,E=d.alternate,E!==null&&(E.lanes|=r),dc(d.return,r,e),o||(b=null);break e}d=E.next}}else if(c.tag===18){if(b=c.return,b===null)throw Error(i(341));b.lanes|=r,d=b.alternate,d!==null&&(d.lanes|=r),dc(b,r,e),b=null}else b=c.child;if(b!==null)b.return=c;else for(b=c;b!==null;){if(b===e){b=null;break}if(c=b.sibling,c!==null){c.return=b.return,b=c;break}b=b.return}c=b}}function vi(e,t,r,o){e=null;for(var c=t,d=!1;c!==null;){if(!d){if((c.flags&524288)!==0)d=!0;else if((c.flags&262144)!==0)break}if(c.tag===10){var b=c.alternate;if(b===null)throw Error(i(387));if(b=b.memoizedProps,b!==null){var E=c.type;Wt(c.pendingProps.value,b.value)||(e!==null?e.push(E):e=[E])}}else if(c===ge.current){if(b=c.alternate,b===null)throw Error(i(387));b.memoizedState.memoizedState!==c.memoizedState.memoizedState&&(e!==null?e.push(Gi):e=[Gi])}c=c.return}e!==null&&hc(t,e,r,o),t.flags|=262144}function Fo(e){for(e=e.firstContext;e!==null;){if(!Wt(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Rr(e){Er=e,ia=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ht(e){return um(Er,e)}function Xo(e,t){return Er===null&&Rr(e),um(e,t)}function um(e,t){var r=t._currentValue;if(t={context:t,memoizedValue:r,next:null},ia===null){if(e===null)throw Error(i(308));ia=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else ia=ia.next=t;return r}var m1=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(r,o){e.push(o)}};this.abort=function(){t.aborted=!0,e.forEach(function(r){return r()})}},p1=n.unstable_scheduleCallback,g1=n.unstable_NormalPriority,Nt={$$typeof:k,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function mc(){return{controller:new m1,data:new Map,refCount:0}}function yi(e){e.refCount--,e.refCount===0&&p1(g1,function(){e.controller.abort()})}var bi=null,pc=0,il=0,ol=null;function v1(e,t){if(bi===null){var r=bi=[];pc=0,il=yf(),ol={status:"pending",value:void 0,then:function(o){r.push(o)}}}return pc++,t.then(cm,cm),t}function cm(){if(--pc===0&&bi!==null){ol!==null&&(ol.status="fulfilled");var e=bi;bi=null,il=0,ol=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function y1(e,t){var r=[],o={status:"pending",value:null,reason:null,then:function(c){r.push(c)}};return e.then(function(){o.status="fulfilled",o.value=t;for(var c=0;c<r.length;c++)(0,r[c])(t)},function(c){for(o.status="rejected",o.reason=c,c=0;c<r.length;c++)(0,r[c])(void 0)}),o}var fm=_.S;_.S=function(e,t){typeof t=="object"&&t!==null&&typeof t.then=="function"&&v1(e,t),fm!==null&&fm(e,t)};var Cr=Y(null);function gc(){var e=Cr.current;return e!==null?e:ut.pooledCache}function Qo(e,t){t===null?K(Cr,Cr.current):K(Cr,t.pool)}function dm(){var e=gc();return e===null?null:{parent:Nt._currentValue,pool:e}}var xi=Error(i(460)),hm=Error(i(474)),Zo=Error(i(542)),vc={then:function(){}};function mm(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Jo(){}function pm(e,t,r){switch(r=e[r],r===void 0?e.push(t):r!==t&&(t.then(Jo,Jo),t=r),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,vm(e),e;default:if(typeof t.status=="string")t.then(Jo,Jo);else{if(e=ut,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status="pending",e.then(function(o){if(t.status==="pending"){var c=t;c.status="fulfilled",c.value=o}},function(o){if(t.status==="pending"){var c=t;c.status="rejected",c.reason=o}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,vm(e),e}throw Si=t,xi}}var Si=null;function gm(){if(Si===null)throw Error(i(459));var e=Si;return Si=null,e}function vm(e){if(e===xi||e===Zo)throw Error(i(483))}var Ta=!1;function yc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function ja(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ma(e,t,r){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(tt&2)!==0){var c=o.pending;return c===null?t.next=t:(t.next=c.next,c.next=t),o.pending=t,t=qo(e),am(e,null,r),t}return Vo(e,o,t,r),qo(e)}function wi(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194048)!==0)){var o=t.lanes;o&=e.pendingLanes,r|=o,t.lanes=r,hr(e,r)}}function xc(e,t){var r=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,r===o)){var c=null,d=null;if(r=r.firstBaseUpdate,r!==null){do{var b={lane:r.lane,tag:r.tag,payload:r.payload,callback:null,next:null};d===null?c=d=b:d=d.next=b,r=r.next}while(r!==null);d===null?c=d=t:d=d.next=t}else c=d=t;r={baseState:o.baseState,firstBaseUpdate:c,lastBaseUpdate:d,shared:o.shared,callbacks:o.callbacks},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}var Sc=!1;function Ei(){if(Sc){var e=ol;if(e!==null)throw e}}function Ri(e,t,r,o){Sc=!1;var c=e.updateQueue;Ta=!1;var d=c.firstBaseUpdate,b=c.lastBaseUpdate,E=c.shared.pending;if(E!==null){c.shared.pending=null;var j=E,q=j.next;j.next=null,b===null?d=q:b.next=q,b=j;var I=e.alternate;I!==null&&(I=I.updateQueue,E=I.lastBaseUpdate,E!==b&&(E===null?I.firstBaseUpdate=q:E.next=q,I.lastBaseUpdate=j))}if(d!==null){var ne=c.baseState;b=0,I=q=j=null,E=d;do{var F=E.lane&-536870913,X=F!==E.lane;if(X?(Je&F)===F:(o&F)===F){F!==0&&F===il&&(Sc=!0),I!==null&&(I=I.next={lane:0,tag:E.tag,payload:E.payload,callback:null,next:null});e:{var ke=e,De=E;F=t;var it=r;switch(De.tag){case 1:if(ke=De.payload,typeof ke=="function"){ne=ke.call(it,ne,F);break e}ne=ke;break e;case 3:ke.flags=ke.flags&-65537|128;case 0:if(ke=De.payload,F=typeof ke=="function"?ke.call(it,ne,F):ke,F==null)break e;ne=g({},ne,F);break e;case 2:Ta=!0}}F=E.callback,F!==null&&(e.flags|=64,X&&(e.flags|=8192),X=c.callbacks,X===null?c.callbacks=[F]:X.push(F))}else X={lane:F,tag:E.tag,payload:E.payload,callback:E.callback,next:null},I===null?(q=I=X,j=ne):I=I.next=X,b|=F;if(E=E.next,E===null){if(E=c.shared.pending,E===null)break;X=E,E=X.next,X.next=null,c.lastBaseUpdate=X,c.shared.pending=null}}while(!0);I===null&&(j=ne),c.baseState=j,c.firstBaseUpdate=q,c.lastBaseUpdate=I,d===null&&(c.shared.lanes=0),Ha|=b,e.lanes=b,e.memoizedState=ne}}function ym(e,t){if(typeof e!="function")throw Error(i(191,e));e.call(t)}function bm(e,t){var r=e.callbacks;if(r!==null)for(e.callbacks=null,e=0;e<r.length;e++)ym(r[e],t)}var sl=Y(null),Io=Y(0);function xm(e,t){e=ma,K(Io,e),K(sl,t),ma=e|t.baseLanes}function wc(){K(Io,ma),K(sl,sl.current)}function Ec(){ma=Io.current,L(sl),L(Io)}var _a=0,qe=null,rt=null,Ot=null,Wo=!1,ul=!1,Or=!1,es=0,Ci=0,cl=null,b1=0;function wt(){throw Error(i(321))}function Rc(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!Wt(e[r],t[r]))return!1;return!0}function Cc(e,t,r,o,c,d){return _a=d,qe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,_.H=e===null||e.memoizedState===null?ap:rp,Or=!1,d=r(o,c),Or=!1,ul&&(d=wm(t,r,o,c)),Sm(e),d}function Sm(e){_.H=is;var t=rt!==null&&rt.next!==null;if(_a=0,Ot=rt=qe=null,Wo=!1,Ci=0,cl=null,t)throw Error(i(300));e===null||Mt||(e=e.dependencies,e!==null&&Fo(e)&&(Mt=!0))}function wm(e,t,r,o){qe=e;var c=0;do{if(ul&&(cl=null),Ci=0,ul=!1,25<=c)throw Error(i(301));if(c+=1,Ot=rt=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}_.H=O1,d=t(r,o)}while(ul);return d}function x1(){var e=_.H,t=e.useState()[0];return t=typeof t.then=="function"?Oi(t):t,e=e.useState()[0],(rt!==null?rt.memoizedState:null)!==e&&(qe.flags|=1024),t}function Oc(){var e=es!==0;return es=0,e}function Ac(e,t,r){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~r}function Nc(e){if(Wo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Wo=!1}_a=0,Ot=rt=qe=null,ul=!1,Ci=es=0,cl=null}function Gt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ot===null?qe.memoizedState=Ot=e:Ot=Ot.next=e,Ot}function At(){if(rt===null){var e=qe.alternate;e=e!==null?e.memoizedState:null}else e=rt.next;var t=Ot===null?qe.memoizedState:Ot.next;if(t!==null)Ot=t,rt=e;else{if(e===null)throw qe.alternate===null?Error(i(467)):Error(i(310));rt=e,e={memoizedState:rt.memoizedState,baseState:rt.baseState,baseQueue:rt.baseQueue,queue:rt.queue,next:null},Ot===null?qe.memoizedState=Ot=e:Ot=Ot.next=e}return Ot}function Tc(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Oi(e){var t=Ci;return Ci+=1,cl===null&&(cl=[]),e=pm(cl,e,t),t=qe,(Ot===null?t.memoizedState:Ot.next)===null&&(t=t.alternate,_.H=t===null||t.memoizedState===null?ap:rp),e}function ts(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Oi(e);if(e.$$typeof===k)return Ht(e)}throw Error(i(438,String(e)))}function jc(e){var t=null,r=qe.updateQueue;if(r!==null&&(t=r.memoCache),t==null){var o=qe.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(t={data:o.data.map(function(c){return c.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),r===null&&(r=Tc(),qe.updateQueue=r),r.memoCache=t,r=t.data[t.index],r===void 0)for(r=t.data[t.index]=Array(e),o=0;o<e;o++)r[o]=ie;return t.index++,r}function sa(e,t){return typeof t=="function"?t(e):t}function ns(e){var t=At();return Mc(t,rt,e)}function Mc(e,t,r){var o=e.queue;if(o===null)throw Error(i(311));o.lastRenderedReducer=r;var c=e.baseQueue,d=o.pending;if(d!==null){if(c!==null){var b=c.next;c.next=d.next,d.next=b}t.baseQueue=c=d,o.pending=null}if(d=e.baseState,c===null)e.memoizedState=d;else{t=c.next;var E=b=null,j=null,q=t,I=!1;do{var ne=q.lane&-536870913;if(ne!==q.lane?(Je&ne)===ne:(_a&ne)===ne){var F=q.revertLane;if(F===0)j!==null&&(j=j.next={lane:0,revertLane:0,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null}),ne===il&&(I=!0);else if((_a&F)===F){q=q.next,F===il&&(I=!0);continue}else ne={lane:0,revertLane:q.revertLane,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null},j===null?(E=j=ne,b=d):j=j.next=ne,qe.lanes|=F,Ha|=F;ne=q.action,Or&&r(d,ne),d=q.hasEagerState?q.eagerState:r(d,ne)}else F={lane:ne,revertLane:q.revertLane,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null},j===null?(E=j=F,b=d):j=j.next=F,qe.lanes|=ne,Ha|=ne;q=q.next}while(q!==null&&q!==t);if(j===null?b=d:j.next=E,!Wt(d,e.memoizedState)&&(Mt=!0,I&&(r=ol,r!==null)))throw r;e.memoizedState=d,e.baseState=b,e.baseQueue=j,o.lastRenderedState=d}return c===null&&(o.lanes=0),[e.memoizedState,o.dispatch]}function _c(e){var t=At(),r=t.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=e;var o=r.dispatch,c=r.pending,d=t.memoizedState;if(c!==null){r.pending=null;var b=c=c.next;do d=e(d,b.action),b=b.next;while(b!==c);Wt(d,t.memoizedState)||(Mt=!0),t.memoizedState=d,t.baseQueue===null&&(t.baseState=d),r.lastRenderedState=d}return[d,o]}function Em(e,t,r){var o=qe,c=At(),d=We;if(d){if(r===void 0)throw Error(i(407));r=r()}else r=t();var b=!Wt((rt||c).memoizedState,r);b&&(c.memoizedState=r,Mt=!0),c=c.queue;var E=Om.bind(null,o,c,e);if(Ai(2048,8,E,[e]),c.getSnapshot!==t||b||Ot!==null&&Ot.memoizedState.tag&1){if(o.flags|=2048,fl(9,as(),Cm.bind(null,o,c,r,t),null),ut===null)throw Error(i(349));d||(_a&124)!==0||Rm(o,t,r)}return r}function Rm(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=qe.updateQueue,t===null?(t=Tc(),qe.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function Cm(e,t,r,o){t.value=r,t.getSnapshot=o,Am(t)&&Nm(e)}function Om(e,t,r){return r(function(){Am(t)&&Nm(e)})}function Am(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!Wt(e,r)}catch{return!0}}function Nm(e){var t=nl(e,2);t!==null&&ln(t,e,2)}function Dc(e){var t=Gt();if(typeof e=="function"){var r=e;if(e=r(),Or){On(!0);try{r()}finally{On(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:e},t}function Tm(e,t,r,o){return e.baseState=r,Mc(e,rt,typeof o=="function"?o:sa)}function S1(e,t,r,o,c){if(ls(e))throw Error(i(485));if(e=t.action,e!==null){var d={payload:c,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){d.listeners.push(b)}};_.T!==null?r(!0):d.isTransition=!1,o(d),r=t.pending,r===null?(d.next=t.pending=d,jm(t,d)):(d.next=r.next,t.pending=r.next=d)}}function jm(e,t){var r=t.action,o=t.payload,c=e.state;if(t.isTransition){var d=_.T,b={};_.T=b;try{var E=r(c,o),j=_.S;j!==null&&j(b,E),Mm(e,t,E)}catch(q){Lc(e,t,q)}finally{_.T=d}}else try{d=r(c,o),Mm(e,t,d)}catch(q){Lc(e,t,q)}}function Mm(e,t,r){r!==null&&typeof r=="object"&&typeof r.then=="function"?r.then(function(o){_m(e,t,o)},function(o){return Lc(e,t,o)}):_m(e,t,r)}function _m(e,t,r){t.status="fulfilled",t.value=r,Dm(t),e.state=r,t=e.pending,t!==null&&(r=t.next,r===t?e.pending=null:(r=r.next,t.next=r,jm(e,r)))}function Lc(e,t,r){var o=e.pending;if(e.pending=null,o!==null){o=o.next;do t.status="rejected",t.reason=r,Dm(t),t=t.next;while(t!==o)}e.action=null}function Dm(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Lm(e,t){return t}function zm(e,t){if(We){var r=ut.formState;if(r!==null){e:{var o=qe;if(We){if(bt){t:{for(var c=bt,d=Un;c.nodeType!==8;){if(!d){c=null;break t}if(c=Tn(c.nextSibling),c===null){c=null;break t}}d=c.data,c=d==="F!"||d==="F"?c:null}if(c){bt=Tn(c.nextSibling),o=c.data==="F!";break e}}wr(o)}o=!1}o&&(t=r[0])}}return r=Gt(),r.memoizedState=r.baseState=t,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Lm,lastRenderedState:t},r.queue=o,r=ep.bind(null,qe,o),o.dispatch=r,o=Dc(!1),d=Hc.bind(null,qe,!1,o.queue),o=Gt(),c={state:t,dispatch:null,action:e,pending:null},o.queue=c,r=S1.bind(null,qe,c,d,r),c.dispatch=r,o.memoizedState=e,[t,r,!1]}function km(e){var t=At();return Um(t,rt,e)}function Um(e,t,r){if(t=Mc(e,t,Lm)[0],e=ns(sa)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var o=Oi(t)}catch(b){throw b===xi?Zo:b}else o=t;t=At();var c=t.queue,d=c.dispatch;return r!==t.memoizedState&&(qe.flags|=2048,fl(9,as(),w1.bind(null,c,r),null)),[o,d,e]}function w1(e,t){e.action=t}function Pm(e){var t=At(),r=rt;if(r!==null)return Um(t,r,e);At(),t=t.memoizedState,r=At();var o=r.queue.dispatch;return r.memoizedState=e,[t,o,!1]}function fl(e,t,r,o){return e={tag:e,create:r,deps:o,inst:t,next:null},t=qe.updateQueue,t===null&&(t=Tc(),qe.updateQueue=t),r=t.lastEffect,r===null?t.lastEffect=e.next=e:(o=r.next,r.next=e,e.next=o,t.lastEffect=e),e}function as(){return{destroy:void 0,resource:void 0}}function Hm(){return At().memoizedState}function rs(e,t,r,o){var c=Gt();o=o===void 0?null:o,qe.flags|=e,c.memoizedState=fl(1|t,as(),r,o)}function Ai(e,t,r,o){var c=At();o=o===void 0?null:o;var d=c.memoizedState.inst;rt!==null&&o!==null&&Rc(o,rt.memoizedState.deps)?c.memoizedState=fl(t,d,r,o):(qe.flags|=e,c.memoizedState=fl(1|t,d,r,o))}function Bm(e,t){rs(8390656,8,e,t)}function $m(e,t){Ai(2048,8,e,t)}function Vm(e,t){return Ai(4,2,e,t)}function qm(e,t){return Ai(4,4,e,t)}function Ym(e,t){if(typeof t=="function"){e=e();var r=t(e);return function(){typeof r=="function"?r():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Km(e,t,r){r=r!=null?r.concat([e]):null,Ai(4,4,Ym.bind(null,t,e),r)}function zc(){}function Gm(e,t){var r=At();t=t===void 0?null:t;var o=r.memoizedState;return t!==null&&Rc(t,o[1])?o[0]:(r.memoizedState=[e,t],e)}function Fm(e,t){var r=At();t=t===void 0?null:t;var o=r.memoizedState;if(t!==null&&Rc(t,o[1]))return o[0];if(o=e(),Or){On(!0);try{e()}finally{On(!1)}}return r.memoizedState=[o,t],o}function kc(e,t,r){return r===void 0||(_a&1073741824)!==0?e.memoizedState=t:(e.memoizedState=r,e=Zp(),qe.lanes|=e,Ha|=e,r)}function Xm(e,t,r,o){return Wt(r,t)?r:sl.current!==null?(e=kc(e,r,o),Wt(e,t)||(Mt=!0),e):(_a&42)===0?(Mt=!0,e.memoizedState=r):(e=Zp(),qe.lanes|=e,Ha|=e,t)}function Qm(e,t,r,o,c){var d=Z.p;Z.p=d!==0&&8>d?d:8;var b=_.T,E={};_.T=E,Hc(e,!1,t,r);try{var j=c(),q=_.S;if(q!==null&&q(E,j),j!==null&&typeof j=="object"&&typeof j.then=="function"){var I=y1(j,o);Ni(e,t,I,rn(e))}else Ni(e,t,o,rn(e))}catch(ne){Ni(e,t,{then:function(){},status:"rejected",reason:ne},rn())}finally{Z.p=d,_.T=b}}function E1(){}function Uc(e,t,r,o){if(e.tag!==5)throw Error(i(476));var c=Zm(e).queue;Qm(e,c,t,$,r===null?E1:function(){return Jm(e),r(o)})}function Zm(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:$,baseState:$,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:$},next:null};var r={};return t.next={memoizedState:r,baseState:r,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:r},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Jm(e){var t=Zm(e).next.queue;Ni(e,t,{},rn())}function Pc(){return Ht(Gi)}function Im(){return At().memoizedState}function Wm(){return At().memoizedState}function R1(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var r=rn();e=ja(r);var o=Ma(t,e,r);o!==null&&(ln(o,t,r),wi(o,t,r)),t={cache:mc()},e.payload=t;return}t=t.return}}function C1(e,t,r){var o=rn();r={lane:o,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null},ls(e)?tp(t,r):(r=rc(e,t,r,o),r!==null&&(ln(r,e,o),np(r,t,o)))}function ep(e,t,r){var o=rn();Ni(e,t,r,o)}function Ni(e,t,r,o){var c={lane:o,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null};if(ls(e))tp(t,c);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=t.lastRenderedReducer,d!==null))try{var b=t.lastRenderedState,E=d(b,r);if(c.hasEagerState=!0,c.eagerState=E,Wt(E,b))return Vo(e,t,c,0),ut===null&&$o(),!1}catch{}finally{}if(r=rc(e,t,c,o),r!==null)return ln(r,e,o),np(r,t,o),!0}return!1}function Hc(e,t,r,o){if(o={lane:2,revertLane:yf(),action:o,hasEagerState:!1,eagerState:null,next:null},ls(e)){if(t)throw Error(i(479))}else t=rc(e,r,o,2),t!==null&&ln(t,e,2)}function ls(e){var t=e.alternate;return e===qe||t!==null&&t===qe}function tp(e,t){ul=Wo=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function np(e,t,r){if((r&4194048)!==0){var o=t.lanes;o&=e.pendingLanes,r|=o,t.lanes=r,hr(e,r)}}var is={readContext:Ht,use:ts,useCallback:wt,useContext:wt,useEffect:wt,useImperativeHandle:wt,useLayoutEffect:wt,useInsertionEffect:wt,useMemo:wt,useReducer:wt,useRef:wt,useState:wt,useDebugValue:wt,useDeferredValue:wt,useTransition:wt,useSyncExternalStore:wt,useId:wt,useHostTransitionStatus:wt,useFormState:wt,useActionState:wt,useOptimistic:wt,useMemoCache:wt,useCacheRefresh:wt},ap={readContext:Ht,use:ts,useCallback:function(e,t){return Gt().memoizedState=[e,t===void 0?null:t],e},useContext:Ht,useEffect:Bm,useImperativeHandle:function(e,t,r){r=r!=null?r.concat([e]):null,rs(4194308,4,Ym.bind(null,t,e),r)},useLayoutEffect:function(e,t){return rs(4194308,4,e,t)},useInsertionEffect:function(e,t){rs(4,2,e,t)},useMemo:function(e,t){var r=Gt();t=t===void 0?null:t;var o=e();if(Or){On(!0);try{e()}finally{On(!1)}}return r.memoizedState=[o,t],o},useReducer:function(e,t,r){var o=Gt();if(r!==void 0){var c=r(t);if(Or){On(!0);try{r(t)}finally{On(!1)}}}else c=t;return o.memoizedState=o.baseState=c,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:c},o.queue=e,e=e.dispatch=C1.bind(null,qe,e),[o.memoizedState,e]},useRef:function(e){var t=Gt();return e={current:e},t.memoizedState=e},useState:function(e){e=Dc(e);var t=e.queue,r=ep.bind(null,qe,t);return t.dispatch=r,[e.memoizedState,r]},useDebugValue:zc,useDeferredValue:function(e,t){var r=Gt();return kc(r,e,t)},useTransition:function(){var e=Dc(!1);return e=Qm.bind(null,qe,e.queue,!0,!1),Gt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,r){var o=qe,c=Gt();if(We){if(r===void 0)throw Error(i(407));r=r()}else{if(r=t(),ut===null)throw Error(i(349));(Je&124)!==0||Rm(o,t,r)}c.memoizedState=r;var d={value:r,getSnapshot:t};return c.queue=d,Bm(Om.bind(null,o,d,e),[e]),o.flags|=2048,fl(9,as(),Cm.bind(null,o,d,r,t),null),r},useId:function(){var e=Gt(),t=ut.identifierPrefix;if(We){var r=la,o=ra;r=(o&~(1<<32-Lt(o)-1)).toString(32)+r,t="«"+t+"R"+r,r=es++,0<r&&(t+="H"+r.toString(32)),t+="»"}else r=b1++,t="«"+t+"r"+r.toString(32)+"»";return e.memoizedState=t},useHostTransitionStatus:Pc,useFormState:zm,useActionState:zm,useOptimistic:function(e){var t=Gt();t.memoizedState=t.baseState=e;var r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=r,t=Hc.bind(null,qe,!0,r),r.dispatch=t,[e,t]},useMemoCache:jc,useCacheRefresh:function(){return Gt().memoizedState=R1.bind(null,qe)}},rp={readContext:Ht,use:ts,useCallback:Gm,useContext:Ht,useEffect:$m,useImperativeHandle:Km,useInsertionEffect:Vm,useLayoutEffect:qm,useMemo:Fm,useReducer:ns,useRef:Hm,useState:function(){return ns(sa)},useDebugValue:zc,useDeferredValue:function(e,t){var r=At();return Xm(r,rt.memoizedState,e,t)},useTransition:function(){var e=ns(sa)[0],t=At().memoizedState;return[typeof e=="boolean"?e:Oi(e),t]},useSyncExternalStore:Em,useId:Im,useHostTransitionStatus:Pc,useFormState:km,useActionState:km,useOptimistic:function(e,t){var r=At();return Tm(r,rt,e,t)},useMemoCache:jc,useCacheRefresh:Wm},O1={readContext:Ht,use:ts,useCallback:Gm,useContext:Ht,useEffect:$m,useImperativeHandle:Km,useInsertionEffect:Vm,useLayoutEffect:qm,useMemo:Fm,useReducer:_c,useRef:Hm,useState:function(){return _c(sa)},useDebugValue:zc,useDeferredValue:function(e,t){var r=At();return rt===null?kc(r,e,t):Xm(r,rt.memoizedState,e,t)},useTransition:function(){var e=_c(sa)[0],t=At().memoizedState;return[typeof e=="boolean"?e:Oi(e),t]},useSyncExternalStore:Em,useId:Im,useHostTransitionStatus:Pc,useFormState:Pm,useActionState:Pm,useOptimistic:function(e,t){var r=At();return rt!==null?Tm(r,rt,e,t):(r.baseState=e,[e,r.queue.dispatch])},useMemoCache:jc,useCacheRefresh:Wm},dl=null,Ti=0;function os(e){var t=Ti;return Ti+=1,dl===null&&(dl=[]),pm(dl,e,t)}function ji(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function ss(e,t){throw t.$$typeof===x?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function lp(e){var t=e._init;return t(e._payload)}function ip(e){function t(U,D){if(e){var V=U.deletions;V===null?(U.deletions=[D],U.flags|=16):V.push(D)}}function r(U,D){if(!e)return null;for(;D!==null;)t(U,D),D=D.sibling;return null}function o(U){for(var D=new Map;U!==null;)U.key!==null?D.set(U.key,U):D.set(U.index,U),U=U.sibling;return D}function c(U,D){return U=aa(U,D),U.index=0,U.sibling=null,U}function d(U,D,V){return U.index=V,e?(V=U.alternate,V!==null?(V=V.index,V<D?(U.flags|=67108866,D):V):(U.flags|=67108866,D)):(U.flags|=1048576,D)}function b(U){return e&&U.alternate===null&&(U.flags|=67108866),U}function E(U,D,V,ee){return D===null||D.tag!==6?(D=ic(V,U.mode,ee),D.return=U,D):(D=c(D,V),D.return=U,D)}function j(U,D,V,ee){var ve=V.type;return ve===C?I(U,D,V.props.children,ee,V.key):D!==null&&(D.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===J&&lp(ve)===D.type)?(D=c(D,V.props),ji(D,V),D.return=U,D):(D=Yo(V.type,V.key,V.props,null,U.mode,ee),ji(D,V),D.return=U,D)}function q(U,D,V,ee){return D===null||D.tag!==4||D.stateNode.containerInfo!==V.containerInfo||D.stateNode.implementation!==V.implementation?(D=oc(V,U.mode,ee),D.return=U,D):(D=c(D,V.children||[]),D.return=U,D)}function I(U,D,V,ee,ve){return D===null||D.tag!==7?(D=yr(V,U.mode,ee,ve),D.return=U,D):(D=c(D,V),D.return=U,D)}function ne(U,D,V){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return D=ic(""+D,U.mode,V),D.return=U,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case S:return V=Yo(D.type,D.key,D.props,null,U.mode,V),ji(V,D),V.return=U,V;case w:return D=oc(D,U.mode,V),D.return=U,D;case J:var ee=D._init;return D=ee(D._payload),ne(U,D,V)}if(fe(D)||Ee(D))return D=yr(D,U.mode,V,null),D.return=U,D;if(typeof D.then=="function")return ne(U,os(D),V);if(D.$$typeof===k)return ne(U,Xo(U,D),V);ss(U,D)}return null}function F(U,D,V,ee){var ve=D!==null?D.key:null;if(typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint")return ve!==null?null:E(U,D,""+V,ee);if(typeof V=="object"&&V!==null){switch(V.$$typeof){case S:return V.key===ve?j(U,D,V,ee):null;case w:return V.key===ve?q(U,D,V,ee):null;case J:return ve=V._init,V=ve(V._payload),F(U,D,V,ee)}if(fe(V)||Ee(V))return ve!==null?null:I(U,D,V,ee,null);if(typeof V.then=="function")return F(U,D,os(V),ee);if(V.$$typeof===k)return F(U,D,Xo(U,V),ee);ss(U,V)}return null}function X(U,D,V,ee,ve){if(typeof ee=="string"&&ee!==""||typeof ee=="number"||typeof ee=="bigint")return U=U.get(V)||null,E(D,U,""+ee,ve);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case S:return U=U.get(ee.key===null?V:ee.key)||null,j(D,U,ee,ve);case w:return U=U.get(ee.key===null?V:ee.key)||null,q(D,U,ee,ve);case J:var Ge=ee._init;return ee=Ge(ee._payload),X(U,D,V,ee,ve)}if(fe(ee)||Ee(ee))return U=U.get(V)||null,I(D,U,ee,ve,null);if(typeof ee.then=="function")return X(U,D,V,os(ee),ve);if(ee.$$typeof===k)return X(U,D,V,Xo(D,ee),ve);ss(D,ee)}return null}function ke(U,D,V,ee){for(var ve=null,Ge=null,Ae=D,Le=D=0,Dt=null;Ae!==null&&Le<V.length;Le++){Ae.index>Le?(Dt=Ae,Ae=null):Dt=Ae.sibling;var Ie=F(U,Ae,V[Le],ee);if(Ie===null){Ae===null&&(Ae=Dt);break}e&&Ae&&Ie.alternate===null&&t(U,Ae),D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie,Ae=Dt}if(Le===V.length)return r(U,Ae),We&&xr(U,Le),ve;if(Ae===null){for(;Le<V.length;Le++)Ae=ne(U,V[Le],ee),Ae!==null&&(D=d(Ae,D,Le),Ge===null?ve=Ae:Ge.sibling=Ae,Ge=Ae);return We&&xr(U,Le),ve}for(Ae=o(Ae);Le<V.length;Le++)Dt=X(Ae,U,Le,V[Le],ee),Dt!==null&&(e&&Dt.alternate!==null&&Ae.delete(Dt.key===null?Le:Dt.key),D=d(Dt,D,Le),Ge===null?ve=Dt:Ge.sibling=Dt,Ge=Dt);return e&&Ae.forEach(function(Xa){return t(U,Xa)}),We&&xr(U,Le),ve}function De(U,D,V,ee){if(V==null)throw Error(i(151));for(var ve=null,Ge=null,Ae=D,Le=D=0,Dt=null,Ie=V.next();Ae!==null&&!Ie.done;Le++,Ie=V.next()){Ae.index>Le?(Dt=Ae,Ae=null):Dt=Ae.sibling;var Xa=F(U,Ae,Ie.value,ee);if(Xa===null){Ae===null&&(Ae=Dt);break}e&&Ae&&Xa.alternate===null&&t(U,Ae),D=d(Xa,D,Le),Ge===null?ve=Xa:Ge.sibling=Xa,Ge=Xa,Ae=Dt}if(Ie.done)return r(U,Ae),We&&xr(U,Le),ve;if(Ae===null){for(;!Ie.done;Le++,Ie=V.next())Ie=ne(U,Ie.value,ee),Ie!==null&&(D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie);return We&&xr(U,Le),ve}for(Ae=o(Ae);!Ie.done;Le++,Ie=V.next())Ie=X(Ae,U,Le,Ie.value,ee),Ie!==null&&(e&&Ie.alternate!==null&&Ae.delete(Ie.key===null?Le:Ie.key),D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie);return e&&Ae.forEach(function(AS){return t(U,AS)}),We&&xr(U,Le),ve}function it(U,D,V,ee){if(typeof V=="object"&&V!==null&&V.type===C&&V.key===null&&(V=V.props.children),typeof V=="object"&&V!==null){switch(V.$$typeof){case S:e:{for(var ve=V.key;D!==null;){if(D.key===ve){if(ve=V.type,ve===C){if(D.tag===7){r(U,D.sibling),ee=c(D,V.props.children),ee.return=U,U=ee;break e}}else if(D.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===J&&lp(ve)===D.type){r(U,D.sibling),ee=c(D,V.props),ji(ee,V),ee.return=U,U=ee;break e}r(U,D);break}else t(U,D);D=D.sibling}V.type===C?(ee=yr(V.props.children,U.mode,ee,V.key),ee.return=U,U=ee):(ee=Yo(V.type,V.key,V.props,null,U.mode,ee),ji(ee,V),ee.return=U,U=ee)}return b(U);case w:e:{for(ve=V.key;D!==null;){if(D.key===ve)if(D.tag===4&&D.stateNode.containerInfo===V.containerInfo&&D.stateNode.implementation===V.implementation){r(U,D.sibling),ee=c(D,V.children||[]),ee.return=U,U=ee;break e}else{r(U,D);break}else t(U,D);D=D.sibling}ee=oc(V,U.mode,ee),ee.return=U,U=ee}return b(U);case J:return ve=V._init,V=ve(V._payload),it(U,D,V,ee)}if(fe(V))return ke(U,D,V,ee);if(Ee(V)){if(ve=Ee(V),typeof ve!="function")throw Error(i(150));return V=ve.call(V),De(U,D,V,ee)}if(typeof V.then=="function")return it(U,D,os(V),ee);if(V.$$typeof===k)return it(U,D,Xo(U,V),ee);ss(U,V)}return typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint"?(V=""+V,D!==null&&D.tag===6?(r(U,D.sibling),ee=c(D,V),ee.return=U,U=ee):(r(U,D),ee=ic(V,U.mode,ee),ee.return=U,U=ee),b(U)):r(U,D)}return function(U,D,V,ee){try{Ti=0;var ve=it(U,D,V,ee);return dl=null,ve}catch(Ae){if(Ae===xi||Ae===Zo)throw Ae;var Ge=en(29,Ae,null,U.mode);return Ge.lanes=ee,Ge.return=U,Ge}finally{}}}var hl=ip(!0),op=ip(!1),xn=Y(null),Pn=null;function Da(e){var t=e.alternate;K(Tt,Tt.current&1),K(xn,e),Pn===null&&(t===null||sl.current!==null||t.memoizedState!==null)&&(Pn=e)}function sp(e){if(e.tag===22){if(K(Tt,Tt.current),K(xn,e),Pn===null){var t=e.alternate;t!==null&&t.memoizedState!==null&&(Pn=e)}}else La()}function La(){K(Tt,Tt.current),K(xn,xn.current)}function ua(e){L(xn),Pn===e&&(Pn=null),L(Tt)}var Tt=Y(0);function us(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||jf(r)))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&128)!==0)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}function Bc(e,t,r,o){t=e.memoizedState,r=r(o,t),r=r==null?t:g({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var $c={enqueueSetState:function(e,t,r){e=e._reactInternals;var o=rn(),c=ja(o);c.payload=t,r!=null&&(c.callback=r),t=Ma(e,c,o),t!==null&&(ln(t,e,o),wi(t,e,o))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var o=rn(),c=ja(o);c.tag=1,c.payload=t,r!=null&&(c.callback=r),t=Ma(e,c,o),t!==null&&(ln(t,e,o),wi(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=rn(),o=ja(r);o.tag=2,t!=null&&(o.callback=t),t=Ma(e,o,r),t!==null&&(ln(t,e,r),wi(t,e,r))}};function up(e,t,r,o,c,d,b){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(o,d,b):t.prototype&&t.prototype.isPureReactComponent?!di(r,o)||!di(c,d):!0}function cp(e,t,r,o){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,o),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,o),t.state!==e&&$c.enqueueReplaceState(t,t.state,null)}function Ar(e,t){var r=t;if("ref"in t){r={};for(var o in t)o!=="ref"&&(r[o]=t[o])}if(e=e.defaultProps){r===t&&(r=g({},r));for(var c in e)r[c]===void 0&&(r[c]=e[c])}return r}var cs=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function fp(e){cs(e)}function dp(e){console.error(e)}function hp(e){cs(e)}function fs(e,t){try{var r=e.onUncaughtError;r(t.value,{componentStack:t.stack})}catch(o){setTimeout(function(){throw o})}}function mp(e,t,r){try{var o=e.onCaughtError;o(r.value,{componentStack:r.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(c){setTimeout(function(){throw c})}}function Vc(e,t,r){return r=ja(r),r.tag=3,r.payload={element:null},r.callback=function(){fs(e,t)},r}function pp(e){return e=ja(e),e.tag=3,e}function gp(e,t,r,o){var c=r.type.getDerivedStateFromError;if(typeof c=="function"){var d=o.value;e.payload=function(){return c(d)},e.callback=function(){mp(t,r,o)}}var b=r.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(e.callback=function(){mp(t,r,o),typeof c!="function"&&(Ba===null?Ba=new Set([this]):Ba.add(this));var E=o.stack;this.componentDidCatch(o.value,{componentStack:E!==null?E:""})})}function A1(e,t,r,o,c){if(r.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(t=r.alternate,t!==null&&vi(t,r,c,!0),r=xn.current,r!==null){switch(r.tag){case 13:return Pn===null?hf():r.alternate===null&&xt===0&&(xt=3),r.flags&=-257,r.flags|=65536,r.lanes=c,o===vc?r.flags|=16384:(t=r.updateQueue,t===null?r.updateQueue=new Set([o]):t.add(o),pf(e,o,c)),!1;case 22:return r.flags|=65536,o===vc?r.flags|=16384:(t=r.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([o])},r.updateQueue=t):(r=t.retryQueue,r===null?t.retryQueue=new Set([o]):r.add(o)),pf(e,o,c)),!1}throw Error(i(435,r.tag))}return pf(e,o,c),hf(),!1}if(We)return t=xn.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=c,o!==cc&&(e=Error(i(422),{cause:o}),gi(gn(e,r)))):(o!==cc&&(t=Error(i(423),{cause:o}),gi(gn(t,r))),e=e.current.alternate,e.flags|=65536,c&=-c,e.lanes|=c,o=gn(o,r),c=Vc(e.stateNode,o,c),xc(e,c),xt!==4&&(xt=2)),!1;var d=Error(i(520),{cause:o});if(d=gn(d,r),Ui===null?Ui=[d]:Ui.push(d),xt!==4&&(xt=2),t===null)return!0;o=gn(o,r),r=t;do{switch(r.tag){case 3:return r.flags|=65536,e=c&-c,r.lanes|=e,e=Vc(r.stateNode,o,e),xc(r,e),!1;case 1:if(t=r.type,d=r.stateNode,(r.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(Ba===null||!Ba.has(d))))return r.flags|=65536,c&=-c,r.lanes|=c,c=pp(c),gp(c,e,r,o),xc(r,c),!1}r=r.return}while(r!==null);return!1}var vp=Error(i(461)),Mt=!1;function zt(e,t,r,o){t.child=e===null?op(t,null,r,o):hl(t,e.child,r,o)}function yp(e,t,r,o,c){r=r.render;var d=t.ref;if("ref"in o){var b={};for(var E in o)E!=="ref"&&(b[E]=o[E])}else b=o;return Rr(t),o=Cc(e,t,r,b,d,c),E=Oc(),e!==null&&!Mt?(Ac(e,t,c),ca(e,t,c)):(We&&E&&sc(t),t.flags|=1,zt(e,t,o,c),t.child)}function bp(e,t,r,o,c){if(e===null){var d=r.type;return typeof d=="function"&&!lc(d)&&d.defaultProps===void 0&&r.compare===null?(t.tag=15,t.type=d,xp(e,t,d,o,c)):(e=Yo(r.type,null,o,t,t.mode,c),e.ref=t.ref,e.return=t,t.child=e)}if(d=e.child,!Zc(e,c)){var b=d.memoizedProps;if(r=r.compare,r=r!==null?r:di,r(b,o)&&e.ref===t.ref)return ca(e,t,c)}return t.flags|=1,e=aa(d,o),e.ref=t.ref,e.return=t,t.child=e}function xp(e,t,r,o,c){if(e!==null){var d=e.memoizedProps;if(di(d,o)&&e.ref===t.ref)if(Mt=!1,t.pendingProps=o=d,Zc(e,c))(e.flags&131072)!==0&&(Mt=!0);else return t.lanes=e.lanes,ca(e,t,c)}return qc(e,t,r,o,c)}function Sp(e,t,r){var o=t.pendingProps,c=o.children,d=e!==null?e.memoizedState:null;if(o.mode==="hidden"){if((t.flags&128)!==0){if(o=d!==null?d.baseLanes|r:r,e!==null){for(c=t.child=e.child,d=0;c!==null;)d=d|c.lanes|c.childLanes,c=c.sibling;t.childLanes=d&~o}else t.childLanes=0,t.child=null;return wp(e,t,o,r)}if((r&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Qo(t,d!==null?d.cachePool:null),d!==null?xm(t,d):wc(),sp(t);else return t.lanes=t.childLanes=536870912,wp(e,t,d!==null?d.baseLanes|r:r,r)}else d!==null?(Qo(t,d.cachePool),xm(t,d),La(),t.memoizedState=null):(e!==null&&Qo(t,null),wc(),La());return zt(e,t,c,r),t.child}function wp(e,t,r,o){var c=gc();return c=c===null?null:{parent:Nt._currentValue,pool:c},t.memoizedState={baseLanes:r,cachePool:c},e!==null&&Qo(t,null),wc(),sp(t),e!==null&&vi(e,t,o,!0),null}function ds(e,t){var r=t.ref;if(r===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof r!="function"&&typeof r!="object")throw Error(i(284));(e===null||e.ref!==r)&&(t.flags|=4194816)}}function qc(e,t,r,o,c){return Rr(t),r=Cc(e,t,r,o,void 0,c),o=Oc(),e!==null&&!Mt?(Ac(e,t,c),ca(e,t,c)):(We&&o&&sc(t),t.flags|=1,zt(e,t,r,c),t.child)}function Ep(e,t,r,o,c,d){return Rr(t),t.updateQueue=null,r=wm(t,o,r,c),Sm(e),o=Oc(),e!==null&&!Mt?(Ac(e,t,d),ca(e,t,d)):(We&&o&&sc(t),t.flags|=1,zt(e,t,r,d),t.child)}function Rp(e,t,r,o,c){if(Rr(t),t.stateNode===null){var d=al,b=r.contextType;typeof b=="object"&&b!==null&&(d=Ht(b)),d=new r(o,d),t.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=$c,t.stateNode=d,d._reactInternals=t,d=t.stateNode,d.props=o,d.state=t.memoizedState,d.refs={},yc(t),b=r.contextType,d.context=typeof b=="object"&&b!==null?Ht(b):al,d.state=t.memoizedState,b=r.getDerivedStateFromProps,typeof b=="function"&&(Bc(t,r,b,o),d.state=t.memoizedState),typeof r.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(b=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),b!==d.state&&$c.enqueueReplaceState(d,d.state,null),Ri(t,o,d,c),Ei(),d.state=t.memoizedState),typeof d.componentDidMount=="function"&&(t.flags|=4194308),o=!0}else if(e===null){d=t.stateNode;var E=t.memoizedProps,j=Ar(r,E);d.props=j;var q=d.context,I=r.contextType;b=al,typeof I=="object"&&I!==null&&(b=Ht(I));var ne=r.getDerivedStateFromProps;I=typeof ne=="function"||typeof d.getSnapshotBeforeUpdate=="function",E=t.pendingProps!==E,I||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(E||q!==b)&&cp(t,d,o,b),Ta=!1;var F=t.memoizedState;d.state=F,Ri(t,o,d,c),Ei(),q=t.memoizedState,E||F!==q||Ta?(typeof ne=="function"&&(Bc(t,r,ne,o),q=t.memoizedState),(j=Ta||up(t,r,j,o,F,q,b))?(I||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount()),typeof d.componentDidMount=="function"&&(t.flags|=4194308)):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=o,t.memoizedState=q),d.props=o,d.state=q,d.context=b,o=j):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),o=!1)}else{d=t.stateNode,bc(e,t),b=t.memoizedProps,I=Ar(r,b),d.props=I,ne=t.pendingProps,F=d.context,q=r.contextType,j=al,typeof q=="object"&&q!==null&&(j=Ht(q)),E=r.getDerivedStateFromProps,(q=typeof E=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(b!==ne||F!==j)&&cp(t,d,o,j),Ta=!1,F=t.memoizedState,d.state=F,Ri(t,o,d,c),Ei();var X=t.memoizedState;b!==ne||F!==X||Ta||e!==null&&e.dependencies!==null&&Fo(e.dependencies)?(typeof E=="function"&&(Bc(t,r,E,o),X=t.memoizedState),(I=Ta||up(t,r,I,o,F,X,j)||e!==null&&e.dependencies!==null&&Fo(e.dependencies))?(q||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(o,X,j),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(o,X,j)),typeof d.componentDidUpdate=="function"&&(t.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=1024),t.memoizedProps=o,t.memoizedState=X),d.props=o,d.state=X,d.context=j,o=I):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=1024),o=!1)}return d=o,ds(e,t),o=(t.flags&128)!==0,d||o?(d=t.stateNode,r=o&&typeof r.getDerivedStateFromError!="function"?null:d.render(),t.flags|=1,e!==null&&o?(t.child=hl(t,e.child,null,c),t.child=hl(t,null,r,c)):zt(e,t,r,c),t.memoizedState=d.state,e=t.child):e=ca(e,t,c),e}function Cp(e,t,r,o){return pi(),t.flags|=256,zt(e,t,r,o),t.child}var Yc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Kc(e){return{baseLanes:e,cachePool:dm()}}function Gc(e,t,r){return e=e!==null?e.childLanes&~r:0,t&&(e|=Sn),e}function Op(e,t,r){var o=t.pendingProps,c=!1,d=(t.flags&128)!==0,b;if((b=d)||(b=e!==null&&e.memoizedState===null?!1:(Tt.current&2)!==0),b&&(c=!0,t.flags&=-129),b=(t.flags&32)!==0,t.flags&=-33,e===null){if(We){if(c?Da(t):La(),We){var E=bt,j;if(j=E){e:{for(j=E,E=Un;j.nodeType!==8;){if(!E){E=null;break e}if(j=Tn(j.nextSibling),j===null){E=null;break e}}E=j}E!==null?(t.memoizedState={dehydrated:E,treeContext:br!==null?{id:ra,overflow:la}:null,retryLane:536870912,hydrationErrors:null},j=en(18,null,null,0),j.stateNode=E,j.return=t,t.child=j,qt=t,bt=null,j=!0):j=!1}j||wr(t)}if(E=t.memoizedState,E!==null&&(E=E.dehydrated,E!==null))return jf(E)?t.lanes=32:t.lanes=536870912,null;ua(t)}return E=o.children,o=o.fallback,c?(La(),c=t.mode,E=hs({mode:"hidden",children:E},c),o=yr(o,c,r,null),E.return=t,o.return=t,E.sibling=o,t.child=E,c=t.child,c.memoizedState=Kc(r),c.childLanes=Gc(e,b,r),t.memoizedState=Yc,o):(Da(t),Fc(t,E))}if(j=e.memoizedState,j!==null&&(E=j.dehydrated,E!==null)){if(d)t.flags&256?(Da(t),t.flags&=-257,t=Xc(e,t,r)):t.memoizedState!==null?(La(),t.child=e.child,t.flags|=128,t=null):(La(),c=o.fallback,E=t.mode,o=hs({mode:"visible",children:o.children},E),c=yr(c,E,r,null),c.flags|=2,o.return=t,c.return=t,o.sibling=c,t.child=o,hl(t,e.child,null,r),o=t.child,o.memoizedState=Kc(r),o.childLanes=Gc(e,b,r),t.memoizedState=Yc,t=c);else if(Da(t),jf(E)){if(b=E.nextSibling&&E.nextSibling.dataset,b)var q=b.dgst;b=q,o=Error(i(419)),o.stack="",o.digest=b,gi({value:o,source:null,stack:null}),t=Xc(e,t,r)}else if(Mt||vi(e,t,r,!1),b=(r&e.childLanes)!==0,Mt||b){if(b=ut,b!==null&&(o=r&-r,o=(o&42)!==0?1:ai(o),o=(o&(b.suspendedLanes|r))!==0?0:o,o!==0&&o!==j.retryLane))throw j.retryLane=o,nl(e,o),ln(b,e,o),vp;E.data==="$?"||hf(),t=Xc(e,t,r)}else E.data==="$?"?(t.flags|=192,t.child=e.child,t=null):(e=j.treeContext,bt=Tn(E.nextSibling),qt=t,We=!0,Sr=null,Un=!1,e!==null&&(yn[bn++]=ra,yn[bn++]=la,yn[bn++]=br,ra=e.id,la=e.overflow,br=t),t=Fc(t,o.children),t.flags|=4096);return t}return c?(La(),c=o.fallback,E=t.mode,j=e.child,q=j.sibling,o=aa(j,{mode:"hidden",children:o.children}),o.subtreeFlags=j.subtreeFlags&65011712,q!==null?c=aa(q,c):(c=yr(c,E,r,null),c.flags|=2),c.return=t,o.return=t,o.sibling=c,t.child=o,o=c,c=t.child,E=e.child.memoizedState,E===null?E=Kc(r):(j=E.cachePool,j!==null?(q=Nt._currentValue,j=j.parent!==q?{parent:q,pool:q}:j):j=dm(),E={baseLanes:E.baseLanes|r,cachePool:j}),c.memoizedState=E,c.childLanes=Gc(e,b,r),t.memoizedState=Yc,o):(Da(t),r=e.child,e=r.sibling,r=aa(r,{mode:"visible",children:o.children}),r.return=t,r.sibling=null,e!==null&&(b=t.deletions,b===null?(t.deletions=[e],t.flags|=16):b.push(e)),t.child=r,t.memoizedState=null,r)}function Fc(e,t){return t=hs({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function hs(e,t){return e=en(22,e,null,t),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Xc(e,t,r){return hl(t,e.child,null,r),e=Fc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Ap(e,t,r){e.lanes|=t;var o=e.alternate;o!==null&&(o.lanes|=t),dc(e.return,t,r)}function Qc(e,t,r,o,c){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:o,tail:r,tailMode:c}:(d.isBackwards=t,d.rendering=null,d.renderingStartTime=0,d.last=o,d.tail=r,d.tailMode=c)}function Np(e,t,r){var o=t.pendingProps,c=o.revealOrder,d=o.tail;if(zt(e,t,o.children,r),o=Tt.current,(o&2)!==0)o=o&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ap(e,r,t);else if(e.tag===19)Ap(e,r,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}o&=1}switch(K(Tt,o),c){case"forwards":for(r=t.child,c=null;r!==null;)e=r.alternate,e!==null&&us(e)===null&&(c=r),r=r.sibling;r=c,r===null?(c=t.child,t.child=null):(c=r.sibling,r.sibling=null),Qc(t,!1,c,r,d);break;case"backwards":for(r=null,c=t.child,t.child=null;c!==null;){if(e=c.alternate,e!==null&&us(e)===null){t.child=c;break}e=c.sibling,c.sibling=r,r=c,c=e}Qc(t,!0,r,null,d);break;case"together":Qc(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ca(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),Ha|=t.lanes,(r&t.childLanes)===0)if(e!==null){if(vi(e,t,r,!1),(r&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,r=aa(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=aa(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function Zc(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Fo(e)))}function N1(e,t,r){switch(t.tag){case 3:ze(t,t.stateNode.containerInfo),Na(t,Nt,e.memoizedState.cache),pi();break;case 27:case 5:je(t);break;case 4:ze(t,t.stateNode.containerInfo);break;case 10:Na(t,t.type,t.memoizedProps.value);break;case 13:var o=t.memoizedState;if(o!==null)return o.dehydrated!==null?(Da(t),t.flags|=128,null):(r&t.child.childLanes)!==0?Op(e,t,r):(Da(t),e=ca(e,t,r),e!==null?e.sibling:null);Da(t);break;case 19:var c=(e.flags&128)!==0;if(o=(r&t.childLanes)!==0,o||(vi(e,t,r,!1),o=(r&t.childLanes)!==0),c){if(o)return Np(e,t,r);t.flags|=128}if(c=t.memoizedState,c!==null&&(c.rendering=null,c.tail=null,c.lastEffect=null),K(Tt,Tt.current),o)break;return null;case 22:case 23:return t.lanes=0,Sp(e,t,r);case 24:Na(t,Nt,e.memoizedState.cache)}return ca(e,t,r)}function Tp(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps)Mt=!0;else{if(!Zc(e,r)&&(t.flags&128)===0)return Mt=!1,N1(e,t,r);Mt=(e.flags&131072)!==0}else Mt=!1,We&&(t.flags&1048576)!==0&&lm(t,Go,t.index);switch(t.lanes=0,t.tag){case 16:e:{e=t.pendingProps;var o=t.elementType,c=o._init;if(o=c(o._payload),t.type=o,typeof o=="function")lc(o)?(e=Ar(o,e),t.tag=1,t=Rp(null,t,o,e,r)):(t.tag=0,t=qc(null,t,o,e,r));else{if(o!=null){if(c=o.$$typeof,c===H){t.tag=11,t=yp(null,t,o,e,r);break e}else if(c===G){t.tag=14,t=bp(null,t,o,e,r);break e}}throw t=he(o)||o,Error(i(306,t,""))}}return t;case 0:return qc(e,t,t.type,t.pendingProps,r);case 1:return o=t.type,c=Ar(o,t.pendingProps),Rp(e,t,o,c,r);case 3:e:{if(ze(t,t.stateNode.containerInfo),e===null)throw Error(i(387));o=t.pendingProps;var d=t.memoizedState;c=d.element,bc(e,t),Ri(t,o,null,r);var b=t.memoizedState;if(o=b.cache,Na(t,Nt,o),o!==d.cache&&hc(t,[Nt],r,!0),Ei(),o=b.element,d.isDehydrated)if(d={element:o,isDehydrated:!1,cache:b.cache},t.updateQueue.baseState=d,t.memoizedState=d,t.flags&256){t=Cp(e,t,o,r);break e}else if(o!==c){c=gn(Error(i(424)),t),gi(c),t=Cp(e,t,o,r);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(bt=Tn(e.firstChild),qt=t,We=!0,Sr=null,Un=!0,r=op(t,null,o,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling}else{if(pi(),o===c){t=ca(e,t,r);break e}zt(e,t,o,r)}t=t.child}return t;case 26:return ds(e,t),e===null?(r=Dg(t.type,null,t.pendingProps,null))?t.memoizedState=r:We||(r=t.type,e=t.pendingProps,o=As(de.current).createElement(r),o[le]=t,o[ce]=e,Ut(o,r,e),Be(o),t.stateNode=o):t.memoizedState=Dg(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return je(t),e===null&&We&&(o=t.stateNode=jg(t.type,t.pendingProps,de.current),qt=t,Un=!0,c=bt,qa(t.type)?(Mf=c,bt=Tn(o.firstChild)):bt=c),zt(e,t,t.pendingProps.children,r),ds(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&We&&((c=o=bt)&&(o=nS(o,t.type,t.pendingProps,Un),o!==null?(t.stateNode=o,qt=t,bt=Tn(o.firstChild),Un=!1,c=!0):c=!1),c||wr(t)),je(t),c=t.type,d=t.pendingProps,b=e!==null?e.memoizedProps:null,o=d.children,Af(c,d)?o=null:b!==null&&Af(c,b)&&(t.flags|=32),t.memoizedState!==null&&(c=Cc(e,t,x1,null,null,r),Gi._currentValue=c),ds(e,t),zt(e,t,o,r),t.child;case 6:return e===null&&We&&((e=r=bt)&&(r=aS(r,t.pendingProps,Un),r!==null?(t.stateNode=r,qt=t,bt=null,e=!0):e=!1),e||wr(t)),null;case 13:return Op(e,t,r);case 4:return ze(t,t.stateNode.containerInfo),o=t.pendingProps,e===null?t.child=hl(t,null,o,r):zt(e,t,o,r),t.child;case 11:return yp(e,t,t.type,t.pendingProps,r);case 7:return zt(e,t,t.pendingProps,r),t.child;case 8:return zt(e,t,t.pendingProps.children,r),t.child;case 12:return zt(e,t,t.pendingProps.children,r),t.child;case 10:return o=t.pendingProps,Na(t,t.type,o.value),zt(e,t,o.children,r),t.child;case 9:return c=t.type._context,o=t.pendingProps.children,Rr(t),c=Ht(c),o=o(c),t.flags|=1,zt(e,t,o,r),t.child;case 14:return bp(e,t,t.type,t.pendingProps,r);case 15:return xp(e,t,t.type,t.pendingProps,r);case 19:return Np(e,t,r);case 31:return o=t.pendingProps,r=t.mode,o={mode:o.mode,children:o.children},e===null?(r=hs(o,r),r.ref=t.ref,t.child=r,r.return=t,t=r):(r=aa(e.child,o),r.ref=t.ref,t.child=r,r.return=t,t=r),t;case 22:return Sp(e,t,r);case 24:return Rr(t),o=Ht(Nt),e===null?(c=gc(),c===null&&(c=ut,d=mc(),c.pooledCache=d,d.refCount++,d!==null&&(c.pooledCacheLanes|=r),c=d),t.memoizedState={parent:o,cache:c},yc(t),Na(t,Nt,c)):((e.lanes&r)!==0&&(bc(e,t),Ri(t,null,null,r),Ei()),c=e.memoizedState,d=t.memoizedState,c.parent!==o?(c={parent:o,cache:o},t.memoizedState=c,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=c),Na(t,Nt,o)):(o=d.cache,Na(t,Nt,o),o!==c.cache&&hc(t,[Nt],r,!0))),zt(e,t,t.pendingProps.children,r),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function fa(e){e.flags|=4}function jp(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Pg(t)){if(t=xn.current,t!==null&&((Je&4194048)===Je?Pn!==null:(Je&62914560)!==Je&&(Je&536870912)===0||t!==Pn))throw Si=vc,hm;e.flags|=8192}}function ms(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?No():536870912,e.lanes|=t,vl|=t)}function Mi(e,t){if(!We)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var o=null;r!==null;)r.alternate!==null&&(o=r),r=r.sibling;o===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:o.sibling=null}}function gt(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,o=0;if(t)for(var c=e.child;c!==null;)r|=c.lanes|c.childLanes,o|=c.subtreeFlags&65011712,o|=c.flags&65011712,c.return=e,c=c.sibling;else for(c=e.child;c!==null;)r|=c.lanes|c.childLanes,o|=c.subtreeFlags,o|=c.flags,c.return=e,c=c.sibling;return e.subtreeFlags|=o,e.childLanes=r,t}function T1(e,t,r){var o=t.pendingProps;switch(uc(t),t.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return gt(t),null;case 1:return gt(t),null;case 3:return r=t.stateNode,o=null,e!==null&&(o=e.memoizedState.cache),t.memoizedState.cache!==o&&(t.flags|=2048),oa(Nt),Ze(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(mi(t)?fa(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,sm())),gt(t),null;case 26:return r=t.memoizedState,e===null?(fa(t),r!==null?(gt(t),jp(t,r)):(gt(t),t.flags&=-16777217)):r?r!==e.memoizedState?(fa(t),gt(t),jp(t,r)):(gt(t),t.flags&=-16777217):(e.memoizedProps!==o&&fa(t),gt(t),t.flags&=-16777217),null;case 27:ae(t),r=de.current;var c=t.type;if(e!==null&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(!o){if(t.stateNode===null)throw Error(i(166));return gt(t),null}e=W.current,mi(t)?im(t):(e=jg(c,o,r),t.stateNode=e,fa(t))}return gt(t),null;case 5:if(ae(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(!o){if(t.stateNode===null)throw Error(i(166));return gt(t),null}if(e=W.current,mi(t))im(t);else{switch(c=As(de.current),e){case 1:e=c.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:e=c.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":e=c.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":e=c.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":e=c.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof o.is=="string"?c.createElement("select",{is:o.is}):c.createElement("select"),o.multiple?e.multiple=!0:o.size&&(e.size=o.size);break;default:e=typeof o.is=="string"?c.createElement(r,{is:o.is}):c.createElement(r)}}e[le]=t,e[ce]=o;e:for(c=t.child;c!==null;){if(c.tag===5||c.tag===6)e.appendChild(c.stateNode);else if(c.tag!==4&&c.tag!==27&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===t)break e;for(;c.sibling===null;){if(c.return===null||c.return===t)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}t.stateNode=e;e:switch(Ut(e,r,o),r){case"button":case"input":case"select":case"textarea":e=!!o.autoFocus;break e;case"img":e=!0;break e;default:e=!1}e&&fa(t)}}return gt(t),t.flags&=-16777217,null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(typeof o!="string"&&t.stateNode===null)throw Error(i(166));if(e=de.current,mi(t)){if(e=t.stateNode,r=t.memoizedProps,o=null,c=qt,c!==null)switch(c.tag){case 27:case 5:o=c.memoizedProps}e[le]=t,e=!!(e.nodeValue===r||o!==null&&o.suppressHydrationWarning===!0||Eg(e.nodeValue,r)),e||wr(t)}else e=As(e).createTextNode(o),e[le]=t,t.stateNode=e}return gt(t),null;case 13:if(o=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(c=mi(t),o!==null&&o.dehydrated!==null){if(e===null){if(!c)throw Error(i(318));if(c=t.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(i(317));c[le]=t}else pi(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;gt(t),c=!1}else c=sm(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=c),c=!0;if(!c)return t.flags&256?(ua(t),t):(ua(t),null)}if(ua(t),(t.flags&128)!==0)return t.lanes=r,t;if(r=o!==null,e=e!==null&&e.memoizedState!==null,r){o=t.child,c=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(c=o.alternate.memoizedState.cachePool.pool);var d=null;o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(d=o.memoizedState.cachePool.pool),d!==c&&(o.flags|=2048)}return r!==e&&r&&(t.child.flags|=8192),ms(t,t.updateQueue),gt(t),null;case 4:return Ze(),e===null&&wf(t.stateNode.containerInfo),gt(t),null;case 10:return oa(t.type),gt(t),null;case 19:if(L(Tt),c=t.memoizedState,c===null)return gt(t),null;if(o=(t.flags&128)!==0,d=c.rendering,d===null)if(o)Mi(c,!1);else{if(xt!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(d=us(e),d!==null){for(t.flags|=128,Mi(c,!1),e=d.updateQueue,t.updateQueue=e,ms(t,e),t.subtreeFlags=0,e=r,r=t.child;r!==null;)rm(r,e),r=r.sibling;return K(Tt,Tt.current&1|2),t.child}e=e.sibling}c.tail!==null&&Me()>vs&&(t.flags|=128,o=!0,Mi(c,!1),t.lanes=4194304)}else{if(!o)if(e=us(d),e!==null){if(t.flags|=128,o=!0,e=e.updateQueue,t.updateQueue=e,ms(t,e),Mi(c,!0),c.tail===null&&c.tailMode==="hidden"&&!d.alternate&&!We)return gt(t),null}else 2*Me()-c.renderingStartTime>vs&&r!==536870912&&(t.flags|=128,o=!0,Mi(c,!1),t.lanes=4194304);c.isBackwards?(d.sibling=t.child,t.child=d):(e=c.last,e!==null?e.sibling=d:t.child=d,c.last=d)}return c.tail!==null?(t=c.tail,c.rendering=t,c.tail=t.sibling,c.renderingStartTime=Me(),t.sibling=null,e=Tt.current,K(Tt,o?e&1|2:e&1),t):(gt(t),null);case 22:case 23:return ua(t),Ec(),o=t.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(t.flags|=8192):o&&(t.flags|=8192),o?(r&536870912)!==0&&(t.flags&128)===0&&(gt(t),t.subtreeFlags&6&&(t.flags|=8192)):gt(t),r=t.updateQueue,r!==null&&ms(t,r.retryQueue),r=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),o=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(o=t.memoizedState.cachePool.pool),o!==r&&(t.flags|=2048),e!==null&&L(Cr),null;case 24:return r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),oa(Nt),gt(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function j1(e,t){switch(uc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return oa(Nt),Ze(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ae(t),null;case 13:if(ua(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));pi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return L(Tt),null;case 4:return Ze(),null;case 10:return oa(t.type),null;case 22:case 23:return ua(t),Ec(),e!==null&&L(Cr),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return oa(Nt),null;case 25:return null;default:return null}}function Mp(e,t){switch(uc(t),t.tag){case 3:oa(Nt),Ze();break;case 26:case 27:case 5:ae(t);break;case 4:Ze();break;case 13:ua(t);break;case 19:L(Tt);break;case 10:oa(t.type);break;case 22:case 23:ua(t),Ec(),e!==null&&L(Cr);break;case 24:oa(Nt)}}function _i(e,t){try{var r=t.updateQueue,o=r!==null?r.lastEffect:null;if(o!==null){var c=o.next;r=c;do{if((r.tag&e)===e){o=void 0;var d=r.create,b=r.inst;o=d(),b.destroy=o}r=r.next}while(r!==c)}}catch(E){st(t,t.return,E)}}function za(e,t,r){try{var o=t.updateQueue,c=o!==null?o.lastEffect:null;if(c!==null){var d=c.next;o=d;do{if((o.tag&e)===e){var b=o.inst,E=b.destroy;if(E!==void 0){b.destroy=void 0,c=t;var j=r,q=E;try{q()}catch(I){st(c,j,I)}}}o=o.next}while(o!==d)}}catch(I){st(t,t.return,I)}}function _p(e){var t=e.updateQueue;if(t!==null){var r=e.stateNode;try{bm(t,r)}catch(o){st(e,e.return,o)}}}function Dp(e,t,r){r.props=Ar(e.type,e.memoizedProps),r.state=e.memoizedState;try{r.componentWillUnmount()}catch(o){st(e,t,o)}}function Di(e,t){try{var r=e.ref;if(r!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:o=e.stateNode;break;default:o=e.stateNode}typeof r=="function"?e.refCleanup=r(o):r.current=o}}catch(c){st(e,t,c)}}function Hn(e,t){var r=e.ref,o=e.refCleanup;if(r!==null)if(typeof o=="function")try{o()}catch(c){st(e,t,c)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof r=="function")try{r(null)}catch(c){st(e,t,c)}else r.current=null}function Lp(e){var t=e.type,r=e.memoizedProps,o=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":r.autoFocus&&o.focus();break e;case"img":r.src?o.src=r.src:r.srcSet&&(o.srcset=r.srcSet)}}catch(c){st(e,e.return,c)}}function Jc(e,t,r){try{var o=e.stateNode;J1(o,e.type,r,t),o[ce]=t}catch(c){st(e,e.return,c)}}function zp(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&qa(e.type)||e.tag===4}function Ic(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||zp(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&qa(e.type)||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 Wc(e,t,r){var o=e.tag;if(o===5||o===6)e=e.stateNode,t?(r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r).insertBefore(e,t):(t=r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r,t.appendChild(e),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=Os));else if(o!==4&&(o===27&&qa(e.type)&&(r=e.stateNode,t=null),e=e.child,e!==null))for(Wc(e,t,r),e=e.sibling;e!==null;)Wc(e,t,r),e=e.sibling}function ps(e,t,r){var o=e.tag;if(o===5||o===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(o!==4&&(o===27&&qa(e.type)&&(r=e.stateNode),e=e.child,e!==null))for(ps(e,t,r),e=e.sibling;e!==null;)ps(e,t,r),e=e.sibling}function kp(e){var t=e.stateNode,r=e.memoizedProps;try{for(var o=e.type,c=t.attributes;c.length;)t.removeAttributeNode(c[0]);Ut(t,o,r),t[le]=e,t[ce]=r}catch(d){st(e,e.return,d)}}var da=!1,Et=!1,ef=!1,Up=typeof WeakSet=="function"?WeakSet:Set,_t=null;function M1(e,t){if(e=e.containerInfo,Cf=Ds,e=Xh(e),Iu(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var o=r.getSelection&&r.getSelection();if(o&&o.rangeCount!==0){r=o.anchorNode;var c=o.anchorOffset,d=o.focusNode;o=o.focusOffset;try{r.nodeType,d.nodeType}catch{r=null;break e}var b=0,E=-1,j=-1,q=0,I=0,ne=e,F=null;t:for(;;){for(var X;ne!==r||c!==0&&ne.nodeType!==3||(E=b+c),ne!==d||o!==0&&ne.nodeType!==3||(j=b+o),ne.nodeType===3&&(b+=ne.nodeValue.length),(X=ne.firstChild)!==null;)F=ne,ne=X;for(;;){if(ne===e)break t;if(F===r&&++q===c&&(E=b),F===d&&++I===o&&(j=b),(X=ne.nextSibling)!==null)break;ne=F,F=ne.parentNode}ne=X}r=E===-1||j===-1?null:{start:E,end:j}}else r=null}r=r||{start:0,end:0}}else r=null;for(Of={focusedElem:e,selectionRange:r},Ds=!1,_t=t;_t!==null;)if(t=_t,e=t.child,(t.subtreeFlags&1024)!==0&&e!==null)e.return=t,_t=e;else for(;_t!==null;){switch(t=_t,d=t.alternate,e=t.flags,t.tag){case 0:break;case 11:case 15:break;case 1:if((e&1024)!==0&&d!==null){e=void 0,r=t,c=d.memoizedProps,d=d.memoizedState,o=r.stateNode;try{var ke=Ar(r.type,c,r.elementType===r.type);e=o.getSnapshotBeforeUpdate(ke,d),o.__reactInternalSnapshotBeforeUpdate=e}catch(De){st(r,r.return,De)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,r=e.nodeType,r===9)Tf(e);else if(r===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Tf(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,_t=e;break}_t=t.return}}function Pp(e,t,r){var o=r.flags;switch(r.tag){case 0:case 11:case 15:ka(e,r),o&4&&_i(5,r);break;case 1:if(ka(e,r),o&4)if(e=r.stateNode,t===null)try{e.componentDidMount()}catch(b){st(r,r.return,b)}else{var c=Ar(r.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(c,t,e.__reactInternalSnapshotBeforeUpdate)}catch(b){st(r,r.return,b)}}o&64&&_p(r),o&512&&Di(r,r.return);break;case 3:if(ka(e,r),o&64&&(e=r.updateQueue,e!==null)){if(t=null,r.child!==null)switch(r.child.tag){case 27:case 5:t=r.child.stateNode;break;case 1:t=r.child.stateNode}try{bm(e,t)}catch(b){st(r,r.return,b)}}break;case 27:t===null&&o&4&&kp(r);case 26:case 5:ka(e,r),t===null&&o&4&&Lp(r),o&512&&Di(r,r.return);break;case 12:ka(e,r);break;case 13:ka(e,r),o&4&&$p(e,r),o&64&&(e=r.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(r=B1.bind(null,r),rS(e,r))));break;case 22:if(o=r.memoizedState!==null||da,!o){t=t!==null&&t.memoizedState!==null||Et,c=da;var d=Et;da=o,(Et=t)&&!d?Ua(e,r,(r.subtreeFlags&8772)!==0):ka(e,r),da=c,Et=d}break;case 30:break;default:ka(e,r)}}function Hp(e){var t=e.alternate;t!==null&&(e.alternate=null,Hp(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Ce(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ht=null,Ft=!1;function ha(e,t,r){for(r=r.child;r!==null;)Bp(e,t,r),r=r.sibling}function Bp(e,t,r){if(mt&&typeof mt.onCommitFiberUnmount=="function")try{mt.onCommitFiberUnmount(Yt,r)}catch{}switch(r.tag){case 26:Et||Hn(r,t),ha(e,t,r),r.memoizedState?r.memoizedState.count--:r.stateNode&&(r=r.stateNode,r.parentNode.removeChild(r));break;case 27:Et||Hn(r,t);var o=ht,c=Ft;qa(r.type)&&(ht=r.stateNode,Ft=!1),ha(e,t,r),Vi(r.stateNode),ht=o,Ft=c;break;case 5:Et||Hn(r,t);case 6:if(o=ht,c=Ft,ht=null,ha(e,t,r),ht=o,Ft=c,ht!==null)if(Ft)try{(ht.nodeType===9?ht.body:ht.nodeName==="HTML"?ht.ownerDocument.body:ht).removeChild(r.stateNode)}catch(d){st(r,t,d)}else try{ht.removeChild(r.stateNode)}catch(d){st(r,t,d)}break;case 18:ht!==null&&(Ft?(e=ht,Ng(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,r.stateNode),Zi(e)):Ng(ht,r.stateNode));break;case 4:o=ht,c=Ft,ht=r.stateNode.containerInfo,Ft=!0,ha(e,t,r),ht=o,Ft=c;break;case 0:case 11:case 14:case 15:Et||za(2,r,t),Et||za(4,r,t),ha(e,t,r);break;case 1:Et||(Hn(r,t),o=r.stateNode,typeof o.componentWillUnmount=="function"&&Dp(r,t,o)),ha(e,t,r);break;case 21:ha(e,t,r);break;case 22:Et=(o=Et)||r.memoizedState!==null,ha(e,t,r),Et=o;break;default:ha(e,t,r)}}function $p(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Zi(e)}catch(r){st(t,t.return,r)}}function _1(e){switch(e.tag){case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Up),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Up),t;default:throw Error(i(435,e.tag))}}function tf(e,t){var r=_1(e);t.forEach(function(o){var c=$1.bind(null,e,o);r.has(o)||(r.add(o),o.then(c,c))})}function tn(e,t){var r=t.deletions;if(r!==null)for(var o=0;o<r.length;o++){var c=r[o],d=e,b=t,E=b;e:for(;E!==null;){switch(E.tag){case 27:if(qa(E.type)){ht=E.stateNode,Ft=!1;break e}break;case 5:ht=E.stateNode,Ft=!1;break e;case 3:case 4:ht=E.stateNode.containerInfo,Ft=!0;break e}E=E.return}if(ht===null)throw Error(i(160));Bp(d,b,c),ht=null,Ft=!1,d=c.alternate,d!==null&&(d.return=null),c.return=null}if(t.subtreeFlags&13878)for(t=t.child;t!==null;)Vp(t,e),t=t.sibling}var Nn=null;function Vp(e,t){var r=e.alternate,o=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:tn(t,e),nn(e),o&4&&(za(3,e,e.return),_i(3,e),za(5,e,e.return));break;case 1:tn(t,e),nn(e),o&512&&(Et||r===null||Hn(r,r.return)),o&64&&da&&(e=e.updateQueue,e!==null&&(o=e.callbacks,o!==null&&(r=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=r===null?o:r.concat(o))));break;case 26:var c=Nn;if(tn(t,e),nn(e),o&512&&(Et||r===null||Hn(r,r.return)),o&4){var d=r!==null?r.memoizedState:null;if(o=e.memoizedState,r===null)if(o===null)if(e.stateNode===null){e:{o=e.type,r=e.memoizedProps,c=c.ownerDocument||c;t:switch(o){case"title":d=c.getElementsByTagName("title")[0],(!d||d[we]||d[le]||d.namespaceURI==="http://www.w3.org/2000/svg"||d.hasAttribute("itemprop"))&&(d=c.createElement(o),c.head.insertBefore(d,c.querySelector("head > title"))),Ut(d,o,r),d[le]=e,Be(d),o=d;break e;case"link":var b=kg("link","href",c).get(o+(r.href||""));if(b){for(var E=0;E<b.length;E++)if(d=b[E],d.getAttribute("href")===(r.href==null||r.href===""?null:r.href)&&d.getAttribute("rel")===(r.rel==null?null:r.rel)&&d.getAttribute("title")===(r.title==null?null:r.title)&&d.getAttribute("crossorigin")===(r.crossOrigin==null?null:r.crossOrigin)){b.splice(E,1);break t}}d=c.createElement(o),Ut(d,o,r),c.head.appendChild(d);break;case"meta":if(b=kg("meta","content",c).get(o+(r.content||""))){for(E=0;E<b.length;E++)if(d=b[E],d.getAttribute("content")===(r.content==null?null:""+r.content)&&d.getAttribute("name")===(r.name==null?null:r.name)&&d.getAttribute("property")===(r.property==null?null:r.property)&&d.getAttribute("http-equiv")===(r.httpEquiv==null?null:r.httpEquiv)&&d.getAttribute("charset")===(r.charSet==null?null:r.charSet)){b.splice(E,1);break t}}d=c.createElement(o),Ut(d,o,r),c.head.appendChild(d);break;default:throw Error(i(468,o))}d[le]=e,Be(d),o=d}e.stateNode=o}else Ug(c,e.type,e.stateNode);else e.stateNode=zg(c,o,e.memoizedProps);else d!==o?(d===null?r.stateNode!==null&&(r=r.stateNode,r.parentNode.removeChild(r)):d.count--,o===null?Ug(c,e.type,e.stateNode):zg(c,o,e.memoizedProps)):o===null&&e.stateNode!==null&&Jc(e,e.memoizedProps,r.memoizedProps)}break;case 27:tn(t,e),nn(e),o&512&&(Et||r===null||Hn(r,r.return)),r!==null&&o&4&&Jc(e,e.memoizedProps,r.memoizedProps);break;case 5:if(tn(t,e),nn(e),o&512&&(Et||r===null||Hn(r,r.return)),e.flags&32){c=e.stateNode;try{Qr(c,"")}catch(X){st(e,e.return,X)}}o&4&&e.stateNode!=null&&(c=e.memoizedProps,Jc(e,c,r!==null?r.memoizedProps:c)),o&1024&&(ef=!0);break;case 6:if(tn(t,e),nn(e),o&4){if(e.stateNode===null)throw Error(i(162));o=e.memoizedProps,r=e.stateNode;try{r.nodeValue=o}catch(X){st(e,e.return,X)}}break;case 3:if(js=null,c=Nn,Nn=Ns(t.containerInfo),tn(t,e),Nn=c,nn(e),o&4&&r!==null&&r.memoizedState.isDehydrated)try{Zi(t.containerInfo)}catch(X){st(e,e.return,X)}ef&&(ef=!1,qp(e));break;case 4:o=Nn,Nn=Ns(e.stateNode.containerInfo),tn(t,e),nn(e),Nn=o;break;case 12:tn(t,e),nn(e);break;case 13:tn(t,e),nn(e),e.child.flags&8192&&e.memoizedState!==null!=(r!==null&&r.memoizedState!==null)&&(sf=Me()),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,tf(e,o)));break;case 22:c=e.memoizedState!==null;var j=r!==null&&r.memoizedState!==null,q=da,I=Et;if(da=q||c,Et=I||j,tn(t,e),Et=I,da=q,nn(e),o&8192)e:for(t=e.stateNode,t._visibility=c?t._visibility&-2:t._visibility|1,c&&(r===null||j||da||Et||Nr(e)),r=null,t=e;;){if(t.tag===5||t.tag===26){if(r===null){j=r=t;try{if(d=j.stateNode,c)b=d.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none";else{E=j.stateNode;var ne=j.memoizedProps.style,F=ne!=null&&ne.hasOwnProperty("display")?ne.display:null;E.style.display=F==null||typeof F=="boolean"?"":(""+F).trim()}}catch(X){st(j,j.return,X)}}}else if(t.tag===6){if(r===null){j=t;try{j.stateNode.nodeValue=c?"":j.memoizedProps}catch(X){st(j,j.return,X)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;r===t&&(r=null),t=t.return}r===t&&(r=null),t.sibling.return=t.return,t=t.sibling}o&4&&(o=e.updateQueue,o!==null&&(r=o.retryQueue,r!==null&&(o.retryQueue=null,tf(e,r))));break;case 19:tn(t,e),nn(e),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,tf(e,o)));break;case 30:break;case 21:break;default:tn(t,e),nn(e)}}function nn(e){var t=e.flags;if(t&2){try{for(var r,o=e.return;o!==null;){if(zp(o)){r=o;break}o=o.return}if(r==null)throw Error(i(160));switch(r.tag){case 27:var c=r.stateNode,d=Ic(e);ps(e,d,c);break;case 5:var b=r.stateNode;r.flags&32&&(Qr(b,""),r.flags&=-33);var E=Ic(e);ps(e,E,b);break;case 3:case 4:var j=r.stateNode.containerInfo,q=Ic(e);Wc(e,q,j);break;default:throw Error(i(161))}}catch(I){st(e,e.return,I)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function qp(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;qp(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ka(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Pp(e,t.alternate,t),t=t.sibling}function Nr(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:za(4,t,t.return),Nr(t);break;case 1:Hn(t,t.return);var r=t.stateNode;typeof r.componentWillUnmount=="function"&&Dp(t,t.return,r),Nr(t);break;case 27:Vi(t.stateNode);case 26:case 5:Hn(t,t.return),Nr(t);break;case 22:t.memoizedState===null&&Nr(t);break;case 30:Nr(t);break;default:Nr(t)}e=e.sibling}}function Ua(e,t,r){for(r=r&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var o=t.alternate,c=e,d=t,b=d.flags;switch(d.tag){case 0:case 11:case 15:Ua(c,d,r),_i(4,d);break;case 1:if(Ua(c,d,r),o=d,c=o.stateNode,typeof c.componentDidMount=="function")try{c.componentDidMount()}catch(q){st(o,o.return,q)}if(o=d,c=o.updateQueue,c!==null){var E=o.stateNode;try{var j=c.shared.hiddenCallbacks;if(j!==null)for(c.shared.hiddenCallbacks=null,c=0;c<j.length;c++)ym(j[c],E)}catch(q){st(o,o.return,q)}}r&&b&64&&_p(d),Di(d,d.return);break;case 27:kp(d);case 26:case 5:Ua(c,d,r),r&&o===null&&b&4&&Lp(d),Di(d,d.return);break;case 12:Ua(c,d,r);break;case 13:Ua(c,d,r),r&&b&4&&$p(c,d);break;case 22:d.memoizedState===null&&Ua(c,d,r),Di(d,d.return);break;case 30:break;default:Ua(c,d,r)}t=t.sibling}}function nf(e,t){var r=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==r&&(e!=null&&e.refCount++,r!=null&&yi(r))}function af(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yi(e))}function Bn(e,t,r,o){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Yp(e,t,r,o),t=t.sibling}function Yp(e,t,r,o){var c=t.flags;switch(t.tag){case 0:case 11:case 15:Bn(e,t,r,o),c&2048&&_i(9,t);break;case 1:Bn(e,t,r,o);break;case 3:Bn(e,t,r,o),c&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yi(e)));break;case 12:if(c&2048){Bn(e,t,r,o),e=t.stateNode;try{var d=t.memoizedProps,b=d.id,E=d.onPostCommit;typeof E=="function"&&E(b,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(j){st(t,t.return,j)}}else Bn(e,t,r,o);break;case 13:Bn(e,t,r,o);break;case 23:break;case 22:d=t.stateNode,b=t.alternate,t.memoizedState!==null?d._visibility&2?Bn(e,t,r,o):Li(e,t):d._visibility&2?Bn(e,t,r,o):(d._visibility|=2,ml(e,t,r,o,(t.subtreeFlags&10256)!==0)),c&2048&&nf(b,t);break;case 24:Bn(e,t,r,o),c&2048&&af(t.alternate,t);break;default:Bn(e,t,r,o)}}function ml(e,t,r,o,c){for(c=c&&(t.subtreeFlags&10256)!==0,t=t.child;t!==null;){var d=e,b=t,E=r,j=o,q=b.flags;switch(b.tag){case 0:case 11:case 15:ml(d,b,E,j,c),_i(8,b);break;case 23:break;case 22:var I=b.stateNode;b.memoizedState!==null?I._visibility&2?ml(d,b,E,j,c):Li(d,b):(I._visibility|=2,ml(d,b,E,j,c)),c&&q&2048&&nf(b.alternate,b);break;case 24:ml(d,b,E,j,c),c&&q&2048&&af(b.alternate,b);break;default:ml(d,b,E,j,c)}t=t.sibling}}function Li(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var r=e,o=t,c=o.flags;switch(o.tag){case 22:Li(r,o),c&2048&&nf(o.alternate,o);break;case 24:Li(r,o),c&2048&&af(o.alternate,o);break;default:Li(r,o)}t=t.sibling}}var zi=8192;function pl(e){if(e.subtreeFlags&zi)for(e=e.child;e!==null;)Kp(e),e=e.sibling}function Kp(e){switch(e.tag){case 26:pl(e),e.flags&zi&&e.memoizedState!==null&&vS(Nn,e.memoizedState,e.memoizedProps);break;case 5:pl(e);break;case 3:case 4:var t=Nn;Nn=Ns(e.stateNode.containerInfo),pl(e),Nn=t;break;case 22:e.memoizedState===null&&(t=e.alternate,t!==null&&t.memoizedState!==null?(t=zi,zi=16777216,pl(e),zi=t):pl(e));break;default:pl(e)}}function Gp(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function ki(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var r=0;r<t.length;r++){var o=t[r];_t=o,Xp(o,e)}Gp(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Fp(e),e=e.sibling}function Fp(e){switch(e.tag){case 0:case 11:case 15:ki(e),e.flags&2048&&za(9,e,e.return);break;case 3:ki(e);break;case 12:ki(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,gs(e)):ki(e);break;default:ki(e)}}function gs(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var r=0;r<t.length;r++){var o=t[r];_t=o,Xp(o,e)}Gp(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:za(8,t,t.return),gs(t);break;case 22:r=t.stateNode,r._visibility&2&&(r._visibility&=-3,gs(t));break;default:gs(t)}e=e.sibling}}function Xp(e,t){for(;_t!==null;){var r=_t;switch(r.tag){case 0:case 11:case 15:za(8,r,t);break;case 23:case 22:if(r.memoizedState!==null&&r.memoizedState.cachePool!==null){var o=r.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:yi(r.memoizedState.cache)}if(o=r.child,o!==null)o.return=r,_t=o;else e:for(r=e;_t!==null;){o=_t;var c=o.sibling,d=o.return;if(Hp(o),o===r){_t=null;break e}if(c!==null){c.return=d,_t=c;break e}_t=d}}}var D1={getCacheForType:function(e){var t=Ht(Nt),r=t.data.get(e);return r===void 0&&(r=e(),t.data.set(e,r)),r}},L1=typeof WeakMap=="function"?WeakMap:Map,tt=0,ut=null,Xe=null,Je=0,nt=0,an=null,Pa=!1,gl=!1,rf=!1,ma=0,xt=0,Ha=0,Tr=0,lf=0,Sn=0,vl=0,Ui=null,Xt=null,of=!1,sf=0,vs=1/0,ys=null,Ba=null,kt=0,$a=null,yl=null,bl=0,uf=0,cf=null,Qp=null,Pi=0,ff=null;function rn(){if((tt&2)!==0&&Je!==0)return Je&-Je;if(_.T!==null){var e=il;return e!==0?e:yf()}return M()}function Zp(){Sn===0&&(Sn=(Je&536870912)===0||We?Kr():536870912);var e=xn.current;return e!==null&&(e.flags|=32),Sn}function ln(e,t,r){(e===ut&&(nt===2||nt===9)||e.cancelPendingCommit!==null)&&(xl(e,0),Va(e,Je,Sn,!1)),fr(e,r),((tt&2)===0||e!==ut)&&(e===ut&&((tt&2)===0&&(Tr|=r),xt===4&&Va(e,Je,Sn,!1)),$n(e))}function Jp(e,t,r){if((tt&6)!==0)throw Error(i(327));var o=!r&&(t&124)===0&&(t&e.expiredLanes)===0||zn(e,t),c=o?U1(e,t):mf(e,t,!0),d=o;do{if(c===0){gl&&!o&&Va(e,t,0,!1);break}else{if(r=e.current.alternate,d&&!z1(r)){c=mf(e,t,!1),d=!1;continue}if(c===2){if(d=t,e.errorRecoveryDisabledLanes&d)var b=0;else b=e.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){t=b;e:{var E=e;c=Ui;var j=E.current.memoizedState.isDehydrated;if(j&&(xl(E,b).flags|=256),b=mf(E,b,!1),b!==2){if(rf&&!j){E.errorRecoveryDisabledLanes|=d,Tr|=d,c=4;break e}d=Xt,Xt=c,d!==null&&(Xt===null?Xt=d:Xt.push.apply(Xt,d))}c=b}if(d=!1,c!==2)continue}}if(c===1){xl(e,0),Va(e,t,0,!0);break}e:{switch(o=e,d=c,d){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:Va(o,t,Sn,!Pa);break e;case 2:Xt=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(c=sf+300-Me(),10<c)){if(Va(o,t,Sn,!Pa),cr(o,0,!0)!==0)break e;o.timeoutHandle=Og(Ip.bind(null,o,r,Xt,ys,of,t,Sn,Tr,vl,Pa,d,2,-0,0),c);break e}Ip(o,r,Xt,ys,of,t,Sn,Tr,vl,Pa,d,0,-0,0)}}break}while(!0);$n(e)}function Ip(e,t,r,o,c,d,b,E,j,q,I,ne,F,X){if(e.timeoutHandle=-1,ne=t.subtreeFlags,(ne&8192||(ne&16785408)===16785408)&&(Ki={stylesheets:null,count:0,unsuspend:gS},Kp(t),ne=yS(),ne!==null)){e.cancelPendingCommit=ne(lg.bind(null,e,t,d,r,o,c,b,E,j,I,1,F,X)),Va(e,d,b,!q);return}lg(e,t,d,r,o,c,b,E,j)}function z1(e){for(var t=e;;){var r=t.tag;if((r===0||r===11||r===15)&&t.flags&16384&&(r=t.updateQueue,r!==null&&(r=r.stores,r!==null)))for(var o=0;o<r.length;o++){var c=r[o],d=c.getSnapshot;c=c.value;try{if(!Wt(d(),c))return!1}catch{return!1}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;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 Va(e,t,r,o){t&=~lf,t&=~Tr,e.suspendedLanes|=t,e.pingedLanes&=~t,o&&(e.warmLanes|=t),o=e.expirationTimes;for(var c=t;0<c;){var d=31-Lt(c),b=1<<d;o[d]=-1,c&=~b}r!==0&&dr(e,r,t)}function bs(){return(tt&6)===0?(Hi(0),!1):!0}function df(){if(Xe!==null){if(nt===0)var e=Xe.return;else e=Xe,ia=Er=null,Nc(e),dl=null,Ti=0,e=Xe;for(;e!==null;)Mp(e.alternate,e),e=e.return;Xe=null}}function xl(e,t){var r=e.timeoutHandle;r!==-1&&(e.timeoutHandle=-1,W1(r)),r=e.cancelPendingCommit,r!==null&&(e.cancelPendingCommit=null,r()),df(),ut=e,Xe=r=aa(e.current,null),Je=t,nt=0,an=null,Pa=!1,gl=zn(e,t),rf=!1,vl=Sn=lf=Tr=Ha=xt=0,Xt=Ui=null,of=!1,(t&8)!==0&&(t|=t&32);var o=e.entangledLanes;if(o!==0)for(e=e.entanglements,o&=t;0<o;){var c=31-Lt(o),d=1<<c;t|=e[c],o&=~d}return ma=t,$o(),r}function Wp(e,t){qe=null,_.H=is,t===xi||t===Zo?(t=gm(),nt=3):t===hm?(t=gm(),nt=4):nt=t===vp?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,an=t,Xe===null&&(xt=1,fs(e,gn(t,e.current)))}function eg(){var e=_.H;return _.H=is,e===null?is:e}function tg(){var e=_.A;return _.A=D1,e}function hf(){xt=4,Pa||(Je&4194048)!==Je&&xn.current!==null||(gl=!0),(Ha&134217727)===0&&(Tr&134217727)===0||ut===null||Va(ut,Je,Sn,!1)}function mf(e,t,r){var o=tt;tt|=2;var c=eg(),d=tg();(ut!==e||Je!==t)&&(ys=null,xl(e,t)),t=!1;var b=xt;e:do try{if(nt!==0&&Xe!==null){var E=Xe,j=an;switch(nt){case 8:df(),b=6;break e;case 3:case 2:case 9:case 6:xn.current===null&&(t=!0);var q=nt;if(nt=0,an=null,Sl(e,E,j,q),r&&gl){b=0;break e}break;default:q=nt,nt=0,an=null,Sl(e,E,j,q)}}k1(),b=xt;break}catch(I){Wp(e,I)}while(!0);return t&&e.shellSuspendCounter++,ia=Er=null,tt=o,_.H=c,_.A=d,Xe===null&&(ut=null,Je=0,$o()),b}function k1(){for(;Xe!==null;)ng(Xe)}function U1(e,t){var r=tt;tt|=2;var o=eg(),c=tg();ut!==e||Je!==t?(ys=null,vs=Me()+500,xl(e,t)):gl=zn(e,t);e:do try{if(nt!==0&&Xe!==null){t=Xe;var d=an;t:switch(nt){case 1:nt=0,an=null,Sl(e,t,d,1);break;case 2:case 9:if(mm(d)){nt=0,an=null,ag(t);break}t=function(){nt!==2&&nt!==9||ut!==e||(nt=7),$n(e)},d.then(t,t);break e;case 3:nt=7;break e;case 4:nt=5;break e;case 7:mm(d)?(nt=0,an=null,ag(t)):(nt=0,an=null,Sl(e,t,d,7));break;case 5:var b=null;switch(Xe.tag){case 26:b=Xe.memoizedState;case 5:case 27:var E=Xe;if(!b||Pg(b)){nt=0,an=null;var j=E.sibling;if(j!==null)Xe=j;else{var q=E.return;q!==null?(Xe=q,xs(q)):Xe=null}break t}}nt=0,an=null,Sl(e,t,d,5);break;case 6:nt=0,an=null,Sl(e,t,d,6);break;case 8:df(),xt=6;break e;default:throw Error(i(462))}}P1();break}catch(I){Wp(e,I)}while(!0);return ia=Er=null,_.H=o,_.A=c,tt=r,Xe!==null?0:(ut=null,Je=0,$o(),xt)}function P1(){for(;Xe!==null&&!Ne();)ng(Xe)}function ng(e){var t=Tp(e.alternate,e,ma);e.memoizedProps=e.pendingProps,t===null?xs(e):Xe=t}function ag(e){var t=e,r=t.alternate;switch(t.tag){case 15:case 0:t=Ep(r,t,t.pendingProps,t.type,void 0,Je);break;case 11:t=Ep(r,t,t.pendingProps,t.type.render,t.ref,Je);break;case 5:Nc(t);default:Mp(r,t),t=Xe=rm(t,ma),t=Tp(r,t,ma)}e.memoizedProps=e.pendingProps,t===null?xs(e):Xe=t}function Sl(e,t,r,o){ia=Er=null,Nc(t),dl=null,Ti=0;var c=t.return;try{if(A1(e,c,t,r,Je)){xt=1,fs(e,gn(r,e.current)),Xe=null;return}}catch(d){if(c!==null)throw Xe=c,d;xt=1,fs(e,gn(r,e.current)),Xe=null;return}t.flags&32768?(We||o===1?e=!0:gl||(Je&536870912)!==0?e=!1:(Pa=e=!0,(o===2||o===9||o===3||o===6)&&(o=xn.current,o!==null&&o.tag===13&&(o.flags|=16384))),rg(t,e)):xs(t)}function xs(e){var t=e;do{if((t.flags&32768)!==0){rg(t,Pa);return}e=t.return;var r=T1(t.alternate,t,ma);if(r!==null){Xe=r;return}if(t=t.sibling,t!==null){Xe=t;return}Xe=t=e}while(t!==null);xt===0&&(xt=5)}function rg(e,t){do{var r=j1(e.alternate,e);if(r!==null){r.flags&=32767,Xe=r;return}if(r=e.return,r!==null&&(r.flags|=32768,r.subtreeFlags=0,r.deletions=null),!t&&(e=e.sibling,e!==null)){Xe=e;return}Xe=e=r}while(e!==null);xt=6,Xe=null}function lg(e,t,r,o,c,d,b,E,j){e.cancelPendingCommit=null;do Ss();while(kt!==0);if((tt&6)!==0)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(d=t.lanes|t.childLanes,d|=ac,To(e,r,d,b,E,j),e===ut&&(Xe=ut=null,Je=0),yl=t,$a=e,bl=r,uf=d,cf=c,Qp=o,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,V1(Yr,function(){return cg(),null})):(e.callbackNode=null,e.callbackPriority=0),o=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||o){o=_.T,_.T=null,c=Z.p,Z.p=2,b=tt,tt|=4;try{M1(e,t,r)}finally{tt=b,Z.p=c,_.T=o}}kt=1,ig(),og(),sg()}}function ig(){if(kt===1){kt=0;var e=$a,t=yl,r=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||r){r=_.T,_.T=null;var o=Z.p;Z.p=2;var c=tt;tt|=4;try{Vp(t,e);var d=Of,b=Xh(e.containerInfo),E=d.focusedElem,j=d.selectionRange;if(b!==E&&E&&E.ownerDocument&&Fh(E.ownerDocument.documentElement,E)){if(j!==null&&Iu(E)){var q=j.start,I=j.end;if(I===void 0&&(I=q),"selectionStart"in E)E.selectionStart=q,E.selectionEnd=Math.min(I,E.value.length);else{var ne=E.ownerDocument||document,F=ne&&ne.defaultView||window;if(F.getSelection){var X=F.getSelection(),ke=E.textContent.length,De=Math.min(j.start,ke),it=j.end===void 0?De:Math.min(j.end,ke);!X.extend&&De>it&&(b=it,it=De,De=b);var U=Gh(E,De),D=Gh(E,it);if(U&&D&&(X.rangeCount!==1||X.anchorNode!==U.node||X.anchorOffset!==U.offset||X.focusNode!==D.node||X.focusOffset!==D.offset)){var V=ne.createRange();V.setStart(U.node,U.offset),X.removeAllRanges(),De>it?(X.addRange(V),X.extend(D.node,D.offset)):(V.setEnd(D.node,D.offset),X.addRange(V))}}}}for(ne=[],X=E;X=X.parentNode;)X.nodeType===1&&ne.push({element:X,left:X.scrollLeft,top:X.scrollTop});for(typeof E.focus=="function"&&E.focus(),E=0;E<ne.length;E++){var ee=ne[E];ee.element.scrollLeft=ee.left,ee.element.scrollTop=ee.top}}Ds=!!Cf,Of=Cf=null}finally{tt=c,Z.p=o,_.T=r}}e.current=t,kt=2}}function og(){if(kt===2){kt=0;var e=$a,t=yl,r=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||r){r=_.T,_.T=null;var o=Z.p;Z.p=2;var c=tt;tt|=4;try{Pp(e,t.alternate,t)}finally{tt=c,Z.p=o,_.T=r}}kt=3}}function sg(){if(kt===4||kt===3){kt=0,Ue();var e=$a,t=yl,r=bl,o=Qp;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?kt=5:(kt=0,yl=$a=null,ug(e,e.pendingLanes));var c=e.pendingLanes;if(c===0&&(Ba=null),ri(r),t=t.stateNode,mt&&typeof mt.onCommitFiberRoot=="function")try{mt.onCommitFiberRoot(Yt,t,void 0,(t.current.flags&128)===128)}catch{}if(o!==null){t=_.T,c=Z.p,Z.p=2,_.T=null;try{for(var d=e.onRecoverableError,b=0;b<o.length;b++){var E=o[b];d(E.value,{componentStack:E.stack})}}finally{_.T=t,Z.p=c}}(bl&3)!==0&&Ss(),$n(e),c=e.pendingLanes,(r&4194090)!==0&&(c&42)!==0?e===ff?Pi++:(Pi=0,ff=e):Pi=0,Hi(0)}}function ug(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,yi(t)))}function Ss(e){return ig(),og(),sg(),cg()}function cg(){if(kt!==5)return!1;var e=$a,t=uf;uf=0;var r=ri(bl),o=_.T,c=Z.p;try{Z.p=32>r?32:r,_.T=null,r=cf,cf=null;var d=$a,b=bl;if(kt=0,yl=$a=null,bl=0,(tt&6)!==0)throw Error(i(331));var E=tt;if(tt|=4,Fp(d.current),Yp(d,d.current,b,r),tt=E,Hi(0,!1),mt&&typeof mt.onPostCommitFiberRoot=="function")try{mt.onPostCommitFiberRoot(Yt,d)}catch{}return!0}finally{Z.p=c,_.T=o,ug(e,t)}}function fg(e,t,r){t=gn(r,t),t=Vc(e.stateNode,t,2),e=Ma(e,t,2),e!==null&&(fr(e,2),$n(e))}function st(e,t,r){if(e.tag===3)fg(e,e,r);else for(;t!==null;){if(t.tag===3){fg(t,e,r);break}else if(t.tag===1){var o=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(Ba===null||!Ba.has(o))){e=gn(r,e),r=pp(2),o=Ma(t,r,2),o!==null&&(gp(r,o,t,e),fr(o,2),$n(o));break}}t=t.return}}function pf(e,t,r){var o=e.pingCache;if(o===null){o=e.pingCache=new L1;var c=new Set;o.set(t,c)}else c=o.get(t),c===void 0&&(c=new Set,o.set(t,c));c.has(r)||(rf=!0,c.add(r),e=H1.bind(null,e,t,r),t.then(e,e))}function H1(e,t,r){var o=e.pingCache;o!==null&&o.delete(t),e.pingedLanes|=e.suspendedLanes&r,e.warmLanes&=~r,ut===e&&(Je&r)===r&&(xt===4||xt===3&&(Je&62914560)===Je&&300>Me()-sf?(tt&2)===0&&xl(e,0):lf|=r,vl===Je&&(vl=0)),$n(e)}function dg(e,t){t===0&&(t=No()),e=nl(e,t),e!==null&&(fr(e,t),$n(e))}function B1(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),dg(e,r)}function $1(e,t){var r=0;switch(e.tag){case 13:var o=e.stateNode,c=e.memoizedState;c!==null&&(r=c.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(i(314))}o!==null&&o.delete(t),dg(e,r)}function V1(e,t){return se(e,t)}var ws=null,wl=null,gf=!1,Es=!1,vf=!1,jr=0;function $n(e){e!==wl&&e.next===null&&(wl===null?ws=wl=e:wl=wl.next=e),Es=!0,gf||(gf=!0,Y1())}function Hi(e,t){if(!vf&&Es){vf=!0;do for(var r=!1,o=ws;o!==null;){if(e!==0){var c=o.pendingLanes;if(c===0)var d=0;else{var b=o.suspendedLanes,E=o.pingedLanes;d=(1<<31-Lt(42|e)+1)-1,d&=c&~(b&~E),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(r=!0,gg(o,d))}else d=Je,d=cr(o,o===ut?d:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(d&3)===0||zn(o,d)||(r=!0,gg(o,d));o=o.next}while(r);vf=!1}}function q1(){hg()}function hg(){Es=gf=!1;var e=0;jr!==0&&(I1()&&(e=jr),jr=0);for(var t=Me(),r=null,o=ws;o!==null;){var c=o.next,d=mg(o,t);d===0?(o.next=null,r===null?ws=c:r.next=c,c===null&&(wl=r)):(r=o,(e!==0||(d&3)!==0)&&(Es=!0)),o=c}Hi(e)}function mg(e,t){for(var r=e.suspendedLanes,o=e.pingedLanes,c=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var b=31-Lt(d),E=1<<b,j=c[b];j===-1?((E&r)===0||(E&o)!==0)&&(c[b]=Ao(E,t)):j<=t&&(e.expiredLanes|=E),d&=~E}if(t=ut,r=Je,r=cr(e,e===t?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o=e.callbackNode,r===0||e===t&&(nt===2||nt===9)||e.cancelPendingCommit!==null)return o!==null&&o!==null&&ue(o),e.callbackNode=null,e.callbackPriority=0;if((r&3)===0||zn(e,r)){if(t=r&-r,t===e.callbackPriority)return t;switch(o!==null&&ue(o),ri(r)){case 2:case 8:r=qr;break;case 32:r=Yr;break;case 268435456:r=Ra;break;default:r=Yr}return o=pg.bind(null,e),r=se(r,o),e.callbackPriority=t,e.callbackNode=r,t}return o!==null&&o!==null&&ue(o),e.callbackPriority=2,e.callbackNode=null,2}function pg(e,t){if(kt!==0&&kt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var r=e.callbackNode;if(Ss()&&e.callbackNode!==r)return null;var o=Je;return o=cr(e,e===ut?o:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o===0?null:(Jp(e,o,t),mg(e,Me()),e.callbackNode!=null&&e.callbackNode===r?pg.bind(null,e):null)}function gg(e,t){if(Ss())return null;Jp(e,t,!0)}function Y1(){eS(function(){(tt&6)!==0?se(Cn,q1):hg()})}function yf(){return jr===0&&(jr=Kr()),jr}function vg(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Lo(""+e)}function yg(e,t){var r=t.ownerDocument.createElement("input");return r.name=t.name,r.value=t.value,e.id&&r.setAttribute("form",e.id),t.parentNode.insertBefore(r,t),e=new FormData(e),r.parentNode.removeChild(r),e}function K1(e,t,r,o,c){if(t==="submit"&&r&&r.stateNode===c){var d=vg((c[ce]||null).action),b=o.submitter;b&&(t=(t=b[ce]||null)?vg(t.formAction):b.getAttribute("formAction"),t!==null&&(d=t,b=null));var E=new Po("action","action",null,o,c);e.push({event:E,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(jr!==0){var j=b?yg(c,b):new FormData(c);Uc(r,{pending:!0,data:j,method:c.method,action:d},null,j)}}else typeof d=="function"&&(E.preventDefault(),j=b?yg(c,b):new FormData(c),Uc(r,{pending:!0,data:j,method:c.method,action:d},d,j))},currentTarget:c}]})}}for(var bf=0;bf<nc.length;bf++){var xf=nc[bf],G1=xf.toLowerCase(),F1=xf[0].toUpperCase()+xf.slice(1);An(G1,"on"+F1)}An(Jh,"onAnimationEnd"),An(Ih,"onAnimationIteration"),An(Wh,"onAnimationStart"),An("dblclick","onDoubleClick"),An("focusin","onFocus"),An("focusout","onBlur"),An(c1,"onTransitionRun"),An(f1,"onTransitionStart"),An(d1,"onTransitionCancel"),An(em,"onTransitionEnd"),Vt("onMouseEnter",["mouseout","mouseover"]),Vt("onMouseLeave",["mouseout","mouseover"]),Vt("onPointerEnter",["pointerout","pointerover"]),Vt("onPointerLeave",["pointerout","pointerover"]),It("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),It("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),It("onBeforeInput",["compositionend","keypress","textInput","paste"]),It("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),It("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),It("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Bi="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(" "),X1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Bi));function bg(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var o=e[r],c=o.event;o=o.listeners;e:{var d=void 0;if(t)for(var b=o.length-1;0<=b;b--){var E=o[b],j=E.instance,q=E.currentTarget;if(E=E.listener,j!==d&&c.isPropagationStopped())break e;d=E,c.currentTarget=q;try{d(c)}catch(I){cs(I)}c.currentTarget=null,d=j}else for(b=0;b<o.length;b++){if(E=o[b],j=E.instance,q=E.currentTarget,E=E.listener,j!==d&&c.isPropagationStopped())break e;d=E,c.currentTarget=q;try{d(c)}catch(I){cs(I)}c.currentTarget=null,d=j}}}}function Qe(e,t){var r=t[Re];r===void 0&&(r=t[Re]=new Set);var o=e+"__bubble";r.has(o)||(xg(t,e,2,!1),r.add(o))}function Sf(e,t,r){var o=0;t&&(o|=4),xg(r,e,o,t)}var Rs="_reactListening"+Math.random().toString(36).slice(2);function wf(e){if(!e[Rs]){e[Rs]=!0,at.forEach(function(r){r!=="selectionchange"&&(X1.has(r)||Sf(r,!1,e),Sf(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Rs]||(t[Rs]=!0,Sf("selectionchange",!1,t))}}function xg(e,t,r,o){switch(Yg(t)){case 2:var c=SS;break;case 8:c=wS;break;default:c=kf}r=c.bind(null,t,r,e),c=void 0,!qu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(c=!0),o?c!==void 0?e.addEventListener(t,r,{capture:!0,passive:c}):e.addEventListener(t,r,!0):c!==void 0?e.addEventListener(t,r,{passive:c}):e.addEventListener(t,r,!1)}function Ef(e,t,r,o,c){var d=o;if((t&1)===0&&(t&2)===0&&o!==null)e:for(;;){if(o===null)return;var b=o.tag;if(b===3||b===4){var E=o.stateNode.containerInfo;if(E===c)break;if(b===4)for(b=o.return;b!==null;){var j=b.tag;if((j===3||j===4)&&b.stateNode.containerInfo===c)return;b=b.return}for(;E!==null;){if(b=Ve(E),b===null)return;if(j=b.tag,j===5||j===6||j===26||j===27){o=d=b;continue e}E=E.parentNode}}o=o.return}Ah(function(){var q=d,I=$u(r),ne=[];e:{var F=tm.get(e);if(F!==void 0){var X=Po,ke=e;switch(e){case"keypress":if(ko(r)===0)break e;case"keydown":case"keyup":X=Vx;break;case"focusin":ke="focus",X=Fu;break;case"focusout":ke="blur",X=Fu;break;case"beforeblur":case"afterblur":X=Fu;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":X=jh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":X=jx;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":X=Kx;break;case Jh:case Ih:case Wh:X=Dx;break;case em:X=Fx;break;case"scroll":case"scrollend":X=Nx;break;case"wheel":X=Qx;break;case"copy":case"cut":case"paste":X=zx;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":X=_h;break;case"toggle":case"beforetoggle":X=Jx}var De=(t&4)!==0,it=!De&&(e==="scroll"||e==="scrollend"),U=De?F!==null?F+"Capture":null:F;De=[];for(var D=q,V;D!==null;){var ee=D;if(V=ee.stateNode,ee=ee.tag,ee!==5&&ee!==26&&ee!==27||V===null||U===null||(ee=li(D,U),ee!=null&&De.push($i(D,ee,V))),it)break;D=D.return}0<De.length&&(F=new X(F,ke,null,r,I),ne.push({event:F,listeners:De}))}}if((t&7)===0){e:{if(F=e==="mouseover"||e==="pointerover",X=e==="mouseout"||e==="pointerout",F&&r!==Bu&&(ke=r.relatedTarget||r.fromElement)&&(Ve(ke)||ke[xe]))break e;if((X||F)&&(F=I.window===I?I:(F=I.ownerDocument)?F.defaultView||F.parentWindow:window,X?(ke=r.relatedTarget||r.toElement,X=q,ke=ke?Ve(ke):null,ke!==null&&(it=u(ke),De=ke.tag,ke!==it||De!==5&&De!==27&&De!==6)&&(ke=null)):(X=null,ke=q),X!==ke)){if(De=jh,ee="onMouseLeave",U="onMouseEnter",D="mouse",(e==="pointerout"||e==="pointerover")&&(De=_h,ee="onPointerLeave",U="onPointerEnter",D="pointer"),it=X==null?F:vt(X),V=ke==null?F:vt(ke),F=new De(ee,D+"leave",X,r,I),F.target=it,F.relatedTarget=V,ee=null,Ve(I)===q&&(De=new De(U,D+"enter",ke,r,I),De.target=V,De.relatedTarget=it,ee=De),it=ee,X&&ke)t:{for(De=X,U=ke,D=0,V=De;V;V=El(V))D++;for(V=0,ee=U;ee;ee=El(ee))V++;for(;0<D-V;)De=El(De),D--;for(;0<V-D;)U=El(U),V--;for(;D--;){if(De===U||U!==null&&De===U.alternate)break t;De=El(De),U=El(U)}De=null}else De=null;X!==null&&Sg(ne,F,X,De,!1),ke!==null&&it!==null&&Sg(ne,it,ke,De,!0)}}e:{if(F=q?vt(q):window,X=F.nodeName&&F.nodeName.toLowerCase(),X==="select"||X==="input"&&F.type==="file")var ve=Bh;else if(Ph(F))if($h)ve=o1;else{ve=l1;var Ge=r1}else X=F.nodeName,!X||X.toLowerCase()!=="input"||F.type!=="checkbox"&&F.type!=="radio"?q&&Hu(q.elementType)&&(ve=Bh):ve=i1;if(ve&&(ve=ve(e,q))){Hh(ne,ve,r,I);break e}Ge&&Ge(e,F,q),e==="focusout"&&q&&F.type==="number"&&q.memoizedProps.value!=null&&Pu(F,"number",F.value)}switch(Ge=q?vt(q):window,e){case"focusin":(Ph(Ge)||Ge.contentEditable==="true")&&(Wr=Ge,Wu=q,hi=null);break;case"focusout":hi=Wu=Wr=null;break;case"mousedown":ec=!0;break;case"contextmenu":case"mouseup":case"dragend":ec=!1,Qh(ne,r,I);break;case"selectionchange":if(u1)break;case"keydown":case"keyup":Qh(ne,r,I)}var Ae;if(Qu)e:{switch(e){case"compositionstart":var Le="onCompositionStart";break e;case"compositionend":Le="onCompositionEnd";break e;case"compositionupdate":Le="onCompositionUpdate";break e}Le=void 0}else Ir?kh(e,r)&&(Le="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(Le="onCompositionStart");Le&&(Dh&&r.locale!=="ko"&&(Ir||Le!=="onCompositionStart"?Le==="onCompositionEnd"&&Ir&&(Ae=Nh()):(Aa=I,Yu="value"in Aa?Aa.value:Aa.textContent,Ir=!0)),Ge=Cs(q,Le),0<Ge.length&&(Le=new Mh(Le,e,null,r,I),ne.push({event:Le,listeners:Ge}),Ae?Le.data=Ae:(Ae=Uh(r),Ae!==null&&(Le.data=Ae)))),(Ae=Wx?e1(e,r):t1(e,r))&&(Le=Cs(q,"onBeforeInput"),0<Le.length&&(Ge=new Mh("onBeforeInput","beforeinput",null,r,I),ne.push({event:Ge,listeners:Le}),Ge.data=Ae)),K1(ne,e,q,r,I)}bg(ne,t)})}function $i(e,t,r){return{instance:e,listener:t,currentTarget:r}}function Cs(e,t){for(var r=t+"Capture",o=[];e!==null;){var c=e,d=c.stateNode;if(c=c.tag,c!==5&&c!==26&&c!==27||d===null||(c=li(e,r),c!=null&&o.unshift($i(e,c,d)),c=li(e,t),c!=null&&o.push($i(e,c,d))),e.tag===3)return o;e=e.return}return[]}function El(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Sg(e,t,r,o,c){for(var d=t._reactName,b=[];r!==null&&r!==o;){var E=r,j=E.alternate,q=E.stateNode;if(E=E.tag,j!==null&&j===o)break;E!==5&&E!==26&&E!==27||q===null||(j=q,c?(q=li(r,d),q!=null&&b.unshift($i(r,q,j))):c||(q=li(r,d),q!=null&&b.push($i(r,q,j)))),r=r.return}b.length!==0&&e.push({event:t,listeners:b})}var Q1=/\r\n?/g,Z1=/\u0000|\uFFFD/g;function wg(e){return(typeof e=="string"?e:""+e).replace(Q1,`
|
|
55
|
-
`).replace(Z1,"")}function Eg(e,t){return t=wg(t),wg(e)===t}function Os(){}function lt(e,t,r,o,c,d){switch(r){case"children":typeof o=="string"?t==="body"||t==="textarea"&&o===""||Qr(e,o):(typeof o=="number"||typeof o=="bigint")&&t!=="body"&&Qr(e,""+o);break;case"className":ta(e,"class",o);break;case"tabIndex":ta(e,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":ta(e,r,o);break;case"style":Ch(e,o,d);break;case"data":if(t!=="object"){ta(e,"data",o);break}case"src":case"href":if(o===""&&(t!=="a"||r!=="href")){e.removeAttribute(r);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(r);break}o=Lo(""+o),e.setAttribute(r,o);break;case"action":case"formAction":if(typeof o=="function"){e.setAttribute(r,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof d=="function"&&(r==="formAction"?(t!=="input"&<(e,t,"name",c.name,c,null),lt(e,t,"formEncType",c.formEncType,c,null),lt(e,t,"formMethod",c.formMethod,c,null),lt(e,t,"formTarget",c.formTarget,c,null)):(lt(e,t,"encType",c.encType,c,null),lt(e,t,"method",c.method,c,null),lt(e,t,"target",c.target,c,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(r);break}o=Lo(""+o),e.setAttribute(r,o);break;case"onClick":o!=null&&(e.onclick=Os);break;case"onScroll":o!=null&&Qe("scroll",e);break;case"onScrollEnd":o!=null&&Qe("scrollend",e);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(r=o.__html,r!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=r}}break;case"multiple":e.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":e.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){e.removeAttribute("xlink:href");break}r=Lo(""+o),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",r);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,""+o):e.removeAttribute(r);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":o&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,""):e.removeAttribute(r);break;case"capture":case"download":o===!0?e.setAttribute(r,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,o):e.removeAttribute(r);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?e.setAttribute(r,o):e.removeAttribute(r);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?e.removeAttribute(r):e.setAttribute(r,o);break;case"popover":Qe("beforetoggle",e),Qe("toggle",e),ea(e,"popover",o);break;case"xlinkActuate":Ke(e,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":Ke(e,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":Ke(e,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":Ke(e,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":Ke(e,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":Ke(e,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":ea(e,"is",o);break;case"innerText":case"textContent":break;default:(!(2<r.length)||r[0]!=="o"&&r[0]!=="O"||r[1]!=="n"&&r[1]!=="N")&&(r=Ox.get(r)||r,ea(e,r,o))}}function Rf(e,t,r,o,c,d){switch(r){case"style":Ch(e,o,d);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(r=o.__html,r!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=r}}break;case"children":typeof o=="string"?Qr(e,o):(typeof o=="number"||typeof o=="bigint")&&Qr(e,""+o);break;case"onScroll":o!=null&&Qe("scroll",e);break;case"onScrollEnd":o!=null&&Qe("scrollend",e);break;case"onClick":o!=null&&(e.onclick=Os);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!kn.hasOwnProperty(r))e:{if(r[0]==="o"&&r[1]==="n"&&(c=r.endsWith("Capture"),t=r.slice(2,c?r.length-7:void 0),d=e[ce]||null,d=d!=null?d[r]:null,typeof d=="function"&&e.removeEventListener(t,d,c),typeof o=="function")){typeof d!="function"&&d!==null&&(r in e?e[r]=null:e.hasAttribute(r)&&e.removeAttribute(r)),e.addEventListener(t,o,c);break e}r in e?e[r]=o:o===!0?e.setAttribute(r,""):ea(e,r,o)}}}function Ut(e,t,r){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Qe("error",e),Qe("load",e);var o=!1,c=!1,d;for(d in r)if(r.hasOwnProperty(d)){var b=r[d];if(b!=null)switch(d){case"src":o=!0;break;case"srcSet":c=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(i(137,t));default:lt(e,t,d,b,r,null)}}c&<(e,t,"srcSet",r.srcSet,r,null),o&<(e,t,"src",r.src,r,null);return;case"input":Qe("invalid",e);var E=d=b=c=null,j=null,q=null;for(o in r)if(r.hasOwnProperty(o)){var I=r[o];if(I!=null)switch(o){case"name":c=I;break;case"type":b=I;break;case"checked":j=I;break;case"defaultChecked":q=I;break;case"value":d=I;break;case"defaultValue":E=I;break;case"children":case"dangerouslySetInnerHTML":if(I!=null)throw Error(i(137,t));break;default:lt(e,t,o,I,r,null)}}Sh(e,d,E,j,q,b,c,!1),_o(e);return;case"select":Qe("invalid",e),o=b=d=null;for(c in r)if(r.hasOwnProperty(c)&&(E=r[c],E!=null))switch(c){case"value":d=E;break;case"defaultValue":b=E;break;case"multiple":o=E;default:lt(e,t,c,E,r,null)}t=d,r=b,e.multiple=!!o,t!=null?Xr(e,!!o,t,!1):r!=null&&Xr(e,!!o,r,!0);return;case"textarea":Qe("invalid",e),d=c=o=null;for(b in r)if(r.hasOwnProperty(b)&&(E=r[b],E!=null))switch(b){case"value":o=E;break;case"defaultValue":c=E;break;case"children":d=E;break;case"dangerouslySetInnerHTML":if(E!=null)throw Error(i(91));break;default:lt(e,t,b,E,r,null)}Eh(e,o,c,d),_o(e);return;case"option":for(j in r)if(r.hasOwnProperty(j)&&(o=r[j],o!=null))switch(j){case"selected":e.selected=o&&typeof o!="function"&&typeof o!="symbol";break;default:lt(e,t,j,o,r,null)}return;case"dialog":Qe("beforetoggle",e),Qe("toggle",e),Qe("cancel",e),Qe("close",e);break;case"iframe":case"object":Qe("load",e);break;case"video":case"audio":for(o=0;o<Bi.length;o++)Qe(Bi[o],e);break;case"image":Qe("error",e),Qe("load",e);break;case"details":Qe("toggle",e);break;case"embed":case"source":case"link":Qe("error",e),Qe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(q in r)if(r.hasOwnProperty(q)&&(o=r[q],o!=null))switch(q){case"children":case"dangerouslySetInnerHTML":throw Error(i(137,t));default:lt(e,t,q,o,r,null)}return;default:if(Hu(t)){for(I in r)r.hasOwnProperty(I)&&(o=r[I],o!==void 0&&Rf(e,t,I,o,r,void 0));return}}for(E in r)r.hasOwnProperty(E)&&(o=r[E],o!=null&<(e,t,E,o,r,null))}function J1(e,t,r,o){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var c=null,d=null,b=null,E=null,j=null,q=null,I=null;for(X in r){var ne=r[X];if(r.hasOwnProperty(X)&&ne!=null)switch(X){case"checked":break;case"value":break;case"defaultValue":j=ne;default:o.hasOwnProperty(X)||lt(e,t,X,null,o,ne)}}for(var F in o){var X=o[F];if(ne=r[F],o.hasOwnProperty(F)&&(X!=null||ne!=null))switch(F){case"type":d=X;break;case"name":c=X;break;case"checked":q=X;break;case"defaultChecked":I=X;break;case"value":b=X;break;case"defaultValue":E=X;break;case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(i(137,t));break;default:X!==ne&<(e,t,F,X,o,ne)}}Uu(e,b,E,j,q,I,d,c);return;case"select":X=b=E=F=null;for(d in r)if(j=r[d],r.hasOwnProperty(d)&&j!=null)switch(d){case"value":break;case"multiple":X=j;default:o.hasOwnProperty(d)||lt(e,t,d,null,o,j)}for(c in o)if(d=o[c],j=r[c],o.hasOwnProperty(c)&&(d!=null||j!=null))switch(c){case"value":F=d;break;case"defaultValue":E=d;break;case"multiple":b=d;default:d!==j&<(e,t,c,d,o,j)}t=E,r=b,o=X,F!=null?Xr(e,!!r,F,!1):!!o!=!!r&&(t!=null?Xr(e,!!r,t,!0):Xr(e,!!r,r?[]:"",!1));return;case"textarea":X=F=null;for(E in r)if(c=r[E],r.hasOwnProperty(E)&&c!=null&&!o.hasOwnProperty(E))switch(E){case"value":break;case"children":break;default:lt(e,t,E,null,o,c)}for(b in o)if(c=o[b],d=r[b],o.hasOwnProperty(b)&&(c!=null||d!=null))switch(b){case"value":F=c;break;case"defaultValue":X=c;break;case"children":break;case"dangerouslySetInnerHTML":if(c!=null)throw Error(i(91));break;default:c!==d&<(e,t,b,c,o,d)}wh(e,F,X);return;case"option":for(var ke in r)if(F=r[ke],r.hasOwnProperty(ke)&&F!=null&&!o.hasOwnProperty(ke))switch(ke){case"selected":e.selected=!1;break;default:lt(e,t,ke,null,o,F)}for(j in o)if(F=o[j],X=r[j],o.hasOwnProperty(j)&&F!==X&&(F!=null||X!=null))switch(j){case"selected":e.selected=F&&typeof F!="function"&&typeof F!="symbol";break;default:lt(e,t,j,F,o,X)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var De in r)F=r[De],r.hasOwnProperty(De)&&F!=null&&!o.hasOwnProperty(De)&<(e,t,De,null,o,F);for(q in o)if(F=o[q],X=r[q],o.hasOwnProperty(q)&&F!==X&&(F!=null||X!=null))switch(q){case"children":case"dangerouslySetInnerHTML":if(F!=null)throw Error(i(137,t));break;default:lt(e,t,q,F,o,X)}return;default:if(Hu(t)){for(var it in r)F=r[it],r.hasOwnProperty(it)&&F!==void 0&&!o.hasOwnProperty(it)&&Rf(e,t,it,void 0,o,F);for(I in o)F=o[I],X=r[I],!o.hasOwnProperty(I)||F===X||F===void 0&&X===void 0||Rf(e,t,I,F,o,X);return}}for(var U in r)F=r[U],r.hasOwnProperty(U)&&F!=null&&!o.hasOwnProperty(U)&<(e,t,U,null,o,F);for(ne in o)F=o[ne],X=r[ne],!o.hasOwnProperty(ne)||F===X||F==null&&X==null||lt(e,t,ne,F,o,X)}var Cf=null,Of=null;function As(e){return e.nodeType===9?e:e.ownerDocument}function Rg(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Cg(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Af(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Nf=null;function I1(){var e=window.event;return e&&e.type==="popstate"?e===Nf?!1:(Nf=e,!0):(Nf=null,!1)}var Og=typeof setTimeout=="function"?setTimeout:void 0,W1=typeof clearTimeout=="function"?clearTimeout:void 0,Ag=typeof Promise=="function"?Promise:void 0,eS=typeof queueMicrotask=="function"?queueMicrotask:typeof Ag<"u"?function(e){return Ag.resolve(null).then(e).catch(tS)}:Og;function tS(e){setTimeout(function(){throw e})}function qa(e){return e==="head"}function Ng(e,t){var r=t,o=0,c=0;do{var d=r.nextSibling;if(e.removeChild(r),d&&d.nodeType===8)if(r=d.data,r==="/$"){if(0<o&&8>o){r=o;var b=e.ownerDocument;if(r&1&&Vi(b.documentElement),r&2&&Vi(b.body),r&4)for(r=b.head,Vi(r),b=r.firstChild;b;){var E=b.nextSibling,j=b.nodeName;b[we]||j==="SCRIPT"||j==="STYLE"||j==="LINK"&&b.rel.toLowerCase()==="stylesheet"||r.removeChild(b),b=E}}if(c===0){e.removeChild(d),Zi(t);return}c--}else r==="$"||r==="$?"||r==="$!"?c++:o=r.charCodeAt(0)-48;else o=0;r=d}while(r);Zi(t)}function Tf(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var r=t;switch(t=t.nextSibling,r.nodeName){case"HTML":case"HEAD":case"BODY":Tf(r),Ce(r);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(r.rel.toLowerCase()==="stylesheet")continue}e.removeChild(r)}}function nS(e,t,r,o){for(;e.nodeType===1;){var c=r;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!o&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(o){if(!e[we])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(d=e.getAttribute("rel"),d==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(d!==c.rel||e.getAttribute("href")!==(c.href==null||c.href===""?null:c.href)||e.getAttribute("crossorigin")!==(c.crossOrigin==null?null:c.crossOrigin)||e.getAttribute("title")!==(c.title==null?null:c.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(d=e.getAttribute("src"),(d!==(c.src==null?null:c.src)||e.getAttribute("type")!==(c.type==null?null:c.type)||e.getAttribute("crossorigin")!==(c.crossOrigin==null?null:c.crossOrigin))&&d&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var d=c.name==null?null:""+c.name;if(c.type==="hidden"&&e.getAttribute("name")===d)return e}else return e;if(e=Tn(e.nextSibling),e===null)break}return null}function aS(e,t,r){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!r||(e=Tn(e.nextSibling),e===null))return null;return e}function jf(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function rS(e,t){var r=e.ownerDocument;if(e.data!=="$?"||r.readyState==="complete")t();else{var o=function(){t(),r.removeEventListener("DOMContentLoaded",o)};r.addEventListener("DOMContentLoaded",o),e._reactRetry=o}}function Tn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="F!"||t==="F")break;if(t==="/$")return null}}return e}var Mf=null;function Tg(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}function jg(e,t,r){switch(t=As(r),e){case"html":if(e=t.documentElement,!e)throw Error(i(452));return e;case"head":if(e=t.head,!e)throw Error(i(453));return e;case"body":if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function Vi(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Ce(e)}var wn=new Map,Mg=new Set;function Ns(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var pa=Z.d;Z.d={f:lS,r:iS,D:oS,C:sS,L:uS,m:cS,X:dS,S:fS,M:hS};function lS(){var e=pa.f(),t=bs();return e||t}function iS(e){var t=et(e);t!==null&&t.tag===5&&t.type==="form"?Jm(t):pa.r(e)}var Rl=typeof document>"u"?null:document;function _g(e,t,r){var o=Rl;if(o&&typeof t=="string"&&t){var c=pn(t);c='link[rel="'+e+'"][href="'+c+'"]',typeof r=="string"&&(c+='[crossorigin="'+r+'"]'),Mg.has(c)||(Mg.add(c),e={rel:e,crossOrigin:r,href:t},o.querySelector(c)===null&&(t=o.createElement("link"),Ut(t,"link",e),Be(t),o.head.appendChild(t)))}}function oS(e){pa.D(e),_g("dns-prefetch",e,null)}function sS(e,t){pa.C(e,t),_g("preconnect",e,t)}function uS(e,t,r){pa.L(e,t,r);var o=Rl;if(o&&e&&t){var c='link[rel="preload"][as="'+pn(t)+'"]';t==="image"&&r&&r.imageSrcSet?(c+='[imagesrcset="'+pn(r.imageSrcSet)+'"]',typeof r.imageSizes=="string"&&(c+='[imagesizes="'+pn(r.imageSizes)+'"]')):c+='[href="'+pn(e)+'"]';var d=c;switch(t){case"style":d=Cl(e);break;case"script":d=Ol(e)}wn.has(d)||(e=g({rel:"preload",href:t==="image"&&r&&r.imageSrcSet?void 0:e,as:t},r),wn.set(d,e),o.querySelector(c)!==null||t==="style"&&o.querySelector(qi(d))||t==="script"&&o.querySelector(Yi(d))||(t=o.createElement("link"),Ut(t,"link",e),Be(t),o.head.appendChild(t)))}}function cS(e,t){pa.m(e,t);var r=Rl;if(r&&e){var o=t&&typeof t.as=="string"?t.as:"script",c='link[rel="modulepreload"][as="'+pn(o)+'"][href="'+pn(e)+'"]',d=c;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Ol(e)}if(!wn.has(d)&&(e=g({rel:"modulepreload",href:e},t),wn.set(d,e),r.querySelector(c)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(r.querySelector(Yi(d)))return}o=r.createElement("link"),Ut(o,"link",e),Be(o),r.head.appendChild(o)}}}function fS(e,t,r){pa.S(e,t,r);var o=Rl;if(o&&e){var c=yt(o).hoistableStyles,d=Cl(e);t=t||"default";var b=c.get(d);if(!b){var E={loading:0,preload:null};if(b=o.querySelector(qi(d)))E.loading=5;else{e=g({rel:"stylesheet",href:e,"data-precedence":t},r),(r=wn.get(d))&&_f(e,r);var j=b=o.createElement("link");Be(j),Ut(j,"link",e),j._p=new Promise(function(q,I){j.onload=q,j.onerror=I}),j.addEventListener("load",function(){E.loading|=1}),j.addEventListener("error",function(){E.loading|=2}),E.loading|=4,Ts(b,t,o)}b={type:"stylesheet",instance:b,count:1,state:E},c.set(d,b)}}}function dS(e,t){pa.X(e,t);var r=Rl;if(r&&e){var o=yt(r).hoistableScripts,c=Ol(e),d=o.get(c);d||(d=r.querySelector(Yi(c)),d||(e=g({src:e,async:!0},t),(t=wn.get(c))&&Df(e,t),d=r.createElement("script"),Be(d),Ut(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(c,d))}}function hS(e,t){pa.M(e,t);var r=Rl;if(r&&e){var o=yt(r).hoistableScripts,c=Ol(e),d=o.get(c);d||(d=r.querySelector(Yi(c)),d||(e=g({src:e,async:!0,type:"module"},t),(t=wn.get(c))&&Df(e,t),d=r.createElement("script"),Be(d),Ut(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(c,d))}}function Dg(e,t,r,o){var c=(c=de.current)?Ns(c):null;if(!c)throw Error(i(446));switch(e){case"meta":case"title":return null;case"style":return typeof r.precedence=="string"&&typeof r.href=="string"?(t=Cl(r.href),r=yt(c).hoistableStyles,o=r.get(t),o||(o={type:"style",instance:null,count:0,state:null},r.set(t,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(r.rel==="stylesheet"&&typeof r.href=="string"&&typeof r.precedence=="string"){e=Cl(r.href);var d=yt(c).hoistableStyles,b=d.get(e);if(b||(c=c.ownerDocument||c,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,b),(d=c.querySelector(qi(e)))&&!d._p&&(b.instance=d,b.state.loading=5),wn.has(e)||(r={rel:"preload",as:"style",href:r.href,crossOrigin:r.crossOrigin,integrity:r.integrity,media:r.media,hrefLang:r.hrefLang,referrerPolicy:r.referrerPolicy},wn.set(e,r),d||mS(c,e,r,b.state))),t&&o===null)throw Error(i(528,""));return b}if(t&&o!==null)throw Error(i(529,""));return null;case"script":return t=r.async,r=r.src,typeof r=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Ol(r),r=yt(c).hoistableScripts,o=r.get(t),o||(o={type:"script",instance:null,count:0,state:null},r.set(t,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Cl(e){return'href="'+pn(e)+'"'}function qi(e){return'link[rel="stylesheet"]['+e+"]"}function Lg(e){return g({},e,{"data-precedence":e.precedence,precedence:null})}function mS(e,t,r,o){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?o.loading=1:(t=e.createElement("link"),o.preload=t,t.addEventListener("load",function(){return o.loading|=1}),t.addEventListener("error",function(){return o.loading|=2}),Ut(t,"link",r),Be(t),e.head.appendChild(t))}function Ol(e){return'[src="'+pn(e)+'"]'}function Yi(e){return"script[async]"+e}function zg(e,t,r){if(t.count++,t.instance===null)switch(t.type){case"style":var o=e.querySelector('style[data-href~="'+pn(r.href)+'"]');if(o)return t.instance=o,Be(o),o;var c=g({},r,{"data-href":r.href,"data-precedence":r.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),Be(o),Ut(o,"style",c),Ts(o,r.precedence,e),t.instance=o;case"stylesheet":c=Cl(r.href);var d=e.querySelector(qi(c));if(d)return t.state.loading|=4,t.instance=d,Be(d),d;o=Lg(r),(c=wn.get(c))&&_f(o,c),d=(e.ownerDocument||e).createElement("link"),Be(d);var b=d;return b._p=new Promise(function(E,j){b.onload=E,b.onerror=j}),Ut(d,"link",o),t.state.loading|=4,Ts(d,r.precedence,e),t.instance=d;case"script":return d=Ol(r.src),(c=e.querySelector(Yi(d)))?(t.instance=c,Be(c),c):(o=r,(c=wn.get(d))&&(o=g({},r),Df(o,c)),e=e.ownerDocument||e,c=e.createElement("script"),Be(c),Ut(c,"link",o),e.head.appendChild(c),t.instance=c);case"void":return null;default:throw Error(i(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(o=t.instance,t.state.loading|=4,Ts(o,r.precedence,e));return t.instance}function Ts(e,t,r){for(var o=r.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),c=o.length?o[o.length-1]:null,d=c,b=0;b<o.length;b++){var E=o[b];if(E.dataset.precedence===t)d=E;else if(d!==c)break}d?d.parentNode.insertBefore(e,d.nextSibling):(t=r.nodeType===9?r.head:r,t.insertBefore(e,t.firstChild))}function _f(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Df(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var js=null;function kg(e,t,r){if(js===null){var o=new Map,c=js=new Map;c.set(r,o)}else c=js,o=c.get(r),o||(o=new Map,c.set(r,o));if(o.has(e))return o;for(o.set(e,null),r=r.getElementsByTagName(e),c=0;c<r.length;c++){var d=r[c];if(!(d[we]||d[le]||e==="link"&&d.getAttribute("rel")==="stylesheet")&&d.namespaceURI!=="http://www.w3.org/2000/svg"){var b=d.getAttribute(t)||"";b=e+b;var E=o.get(b);E?E.push(d):o.set(b,[d])}}return o}function Ug(e,t,r){e=e.ownerDocument||e,e.head.insertBefore(r,t==="title"?e.querySelector("head > title"):null)}function pS(e,t,r){if(r===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Pg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var Ki=null;function gS(){}function vS(e,t,r){if(Ki===null)throw Error(i(475));var o=Ki;if(t.type==="stylesheet"&&(typeof r.media!="string"||matchMedia(r.media).matches!==!1)&&(t.state.loading&4)===0){if(t.instance===null){var c=Cl(r.href),d=e.querySelector(qi(c));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(o.count++,o=Ms.bind(o),e.then(o,o)),t.state.loading|=4,t.instance=d,Be(d);return}d=e.ownerDocument||e,r=Lg(r),(c=wn.get(c))&&_f(r,c),d=d.createElement("link"),Be(d);var b=d;b._p=new Promise(function(E,j){b.onload=E,b.onerror=j}),Ut(d,"link",r),t.instance=d}o.stylesheets===null&&(o.stylesheets=new Map),o.stylesheets.set(t,e),(e=t.state.preload)&&(t.state.loading&3)===0&&(o.count++,t=Ms.bind(o),e.addEventListener("load",t),e.addEventListener("error",t))}}function yS(){if(Ki===null)throw Error(i(475));var e=Ki;return e.stylesheets&&e.count===0&&Lf(e,e.stylesheets),0<e.count?function(t){var r=setTimeout(function(){if(e.stylesheets&&Lf(e,e.stylesheets),e.unsuspend){var o=e.unsuspend;e.unsuspend=null,o()}},6e4);return e.unsuspend=t,function(){e.unsuspend=null,clearTimeout(r)}}:null}function Ms(){if(this.count--,this.count===0){if(this.stylesheets)Lf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var _s=null;function Lf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,_s=new Map,t.forEach(bS,e),_s=null,Ms.call(e))}function bS(e,t){if(!(t.state.loading&4)){var r=_s.get(e);if(r)var o=r.get(null);else{r=new Map,_s.set(e,r);for(var c=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d<c.length;d++){var b=c[d];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(r.set(b.dataset.precedence,b),o=b)}o&&r.set(null,o)}c=t.instance,b=c.getAttribute("data-precedence"),d=r.get(b)||o,d===o&&r.set(null,c),r.set(b,c),this.count++,o=Ms.bind(this),c.addEventListener("load",o),c.addEventListener("error",o),d?d.parentNode.insertBefore(c,d.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(c,e.firstChild)),t.state.loading|=4}}var Gi={$$typeof:k,Provider:null,Consumer:null,_currentValue:$,_currentValue2:$,_threadCount:0};function xS(e,t,r,o,c,d,b,E){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Gr(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Gr(0),this.hiddenUpdates=Gr(null),this.identifierPrefix=o,this.onUncaughtError=c,this.onCaughtError=d,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=E,this.incompleteTransitions=new Map}function Hg(e,t,r,o,c,d,b,E,j,q,I,ne){return e=new xS(e,t,r,b,E,j,q,ne),t=1,d===!0&&(t|=24),d=en(3,null,null,t),e.current=d,d.stateNode=e,t=mc(),t.refCount++,e.pooledCache=t,t.refCount++,d.memoizedState={element:o,isDehydrated:r,cache:t},yc(d),e}function Bg(e){return e?(e=al,e):al}function $g(e,t,r,o,c,d){c=Bg(c),o.context===null?o.context=c:o.pendingContext=c,o=ja(t),o.payload={element:r},d=d===void 0?null:d,d!==null&&(o.callback=d),r=Ma(e,o,t),r!==null&&(ln(r,e,t),wi(r,e,t))}function Vg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function zf(e,t){Vg(e,t),(e=e.alternate)&&Vg(e,t)}function qg(e){if(e.tag===13){var t=nl(e,67108864);t!==null&&ln(t,e,67108864),zf(e,67108864)}}var Ds=!0;function SS(e,t,r,o){var c=_.T;_.T=null;var d=Z.p;try{Z.p=2,kf(e,t,r,o)}finally{Z.p=d,_.T=c}}function wS(e,t,r,o){var c=_.T;_.T=null;var d=Z.p;try{Z.p=8,kf(e,t,r,o)}finally{Z.p=d,_.T=c}}function kf(e,t,r,o){if(Ds){var c=Uf(o);if(c===null)Ef(e,t,o,Ls,r),Kg(e,o);else if(RS(c,e,t,r,o))o.stopPropagation();else if(Kg(e,o),t&4&&-1<ES.indexOf(e)){for(;c!==null;){var d=et(c);if(d!==null)switch(d.tag){case 3:if(d=d.stateNode,d.current.memoizedState.isDehydrated){var b=In(d.pendingLanes);if(b!==0){var E=d;for(E.pendingLanes|=2,E.entangledLanes|=2;b;){var j=1<<31-Lt(b);E.entanglements[1]|=j,b&=~j}$n(d),(tt&6)===0&&(vs=Me()+500,Hi(0))}}break;case 13:E=nl(d,2),E!==null&&ln(E,d,2),bs(),zf(d,2)}if(d=Uf(o),d===null&&Ef(e,t,o,Ls,r),d===c)break;c=d}c!==null&&o.stopPropagation()}else Ef(e,t,o,null,r)}}function Uf(e){return e=$u(e),Pf(e)}var Ls=null;function Pf(e){if(Ls=null,e=Ve(e),e!==null){var t=u(e);if(t===null)e=null;else{var r=t.tag;if(r===13){if(e=f(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ls=e,null}function Yg(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(ot()){case Cn:return 2;case qr:return 8;case Yr:case Jn:return 32;case Ra:return 268435456;default:return 32}default:return 32}}var Hf=!1,Ya=null,Ka=null,Ga=null,Fi=new Map,Xi=new Map,Fa=[],ES="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Kg(e,t){switch(e){case"focusin":case"focusout":Ya=null;break;case"dragenter":case"dragleave":Ka=null;break;case"mouseover":case"mouseout":Ga=null;break;case"pointerover":case"pointerout":Fi.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xi.delete(t.pointerId)}}function Qi(e,t,r,o,c,d){return e===null||e.nativeEvent!==d?(e={blockedOn:t,domEventName:r,eventSystemFlags:o,nativeEvent:d,targetContainers:[c]},t!==null&&(t=et(t),t!==null&&qg(t)),e):(e.eventSystemFlags|=o,t=e.targetContainers,c!==null&&t.indexOf(c)===-1&&t.push(c),e)}function RS(e,t,r,o,c){switch(t){case"focusin":return Ya=Qi(Ya,e,t,r,o,c),!0;case"dragenter":return Ka=Qi(Ka,e,t,r,o,c),!0;case"mouseover":return Ga=Qi(Ga,e,t,r,o,c),!0;case"pointerover":var d=c.pointerId;return Fi.set(d,Qi(Fi.get(d)||null,e,t,r,o,c)),!0;case"gotpointercapture":return d=c.pointerId,Xi.set(d,Qi(Xi.get(d)||null,e,t,r,o,c)),!0}return!1}function Gg(e){var t=Ve(e.target);if(t!==null){var r=u(t);if(r!==null){if(t=r.tag,t===13){if(t=f(r),t!==null){e.blockedOn=t,B(e.priority,function(){if(r.tag===13){var o=rn();o=ai(o);var c=nl(r,o);c!==null&&ln(c,r,o),zf(r,o)}});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function zs(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=Uf(e.nativeEvent);if(r===null){r=e.nativeEvent;var o=new r.constructor(r.type,r);Bu=o,r.target.dispatchEvent(o),Bu=null}else return t=et(r),t!==null&&qg(t),e.blockedOn=r,!1;t.shift()}return!0}function Fg(e,t,r){zs(e)&&r.delete(t)}function CS(){Hf=!1,Ya!==null&&zs(Ya)&&(Ya=null),Ka!==null&&zs(Ka)&&(Ka=null),Ga!==null&&zs(Ga)&&(Ga=null),Fi.forEach(Fg),Xi.forEach(Fg)}function ks(e,t){e.blockedOn===t&&(e.blockedOn=null,Hf||(Hf=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,CS)))}var Us=null;function Xg(e){Us!==e&&(Us=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Us===e&&(Us=null);for(var t=0;t<e.length;t+=3){var r=e[t],o=e[t+1],c=e[t+2];if(typeof o!="function"){if(Pf(o||r)===null)continue;break}var d=et(r);d!==null&&(e.splice(t,3),t-=3,Uc(d,{pending:!0,data:c,method:r.method,action:o},o,c))}}))}function Zi(e){function t(j){return ks(j,e)}Ya!==null&&ks(Ya,e),Ka!==null&&ks(Ka,e),Ga!==null&&ks(Ga,e),Fi.forEach(t),Xi.forEach(t);for(var r=0;r<Fa.length;r++){var o=Fa[r];o.blockedOn===e&&(o.blockedOn=null)}for(;0<Fa.length&&(r=Fa[0],r.blockedOn===null);)Gg(r),r.blockedOn===null&&Fa.shift();if(r=(e.ownerDocument||e).$$reactFormReplay,r!=null)for(o=0;o<r.length;o+=3){var c=r[o],d=r[o+1],b=c[ce]||null;if(typeof d=="function")b||Xg(r);else if(b){var E=null;if(d&&d.hasAttribute("formAction")){if(c=d,b=d[ce]||null)E=b.formAction;else if(Pf(c)!==null)continue}else E=b.action;typeof E=="function"?r[o+1]=E:(r.splice(o,3),o-=3),Xg(r)}}}function Bf(e){this._internalRoot=e}Ps.prototype.render=Bf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var r=t.current,o=rn();$g(r,o,e,t,null,null)},Ps.prototype.unmount=Bf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;$g(e.current,2,null,e,null,null),bs(),t[xe]=null}};function Ps(e){this._internalRoot=e}Ps.prototype.unstable_scheduleHydration=function(e){if(e){var t=M();e={blockedOn:null,target:e,priority:t};for(var r=0;r<Fa.length&&t!==0&&t<Fa[r].priority;r++);Fa.splice(r,0,e),r===0&&Gg(e)}};var Qg=a.version;if(Qg!=="19.1.0")throw Error(i(527,Qg,"19.1.0"));Z.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(i(188)):(e=Object.keys(e).join(","),Error(i(268,e)));return e=p(t),e=e!==null?m(e):null,e=e===null?null:e.stateNode,e};var OS={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:_,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Hs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Hs.isDisabled&&Hs.supportsFiber)try{Yt=Hs.inject(OS),mt=Hs}catch{}}return Wi.createRoot=function(e,t){if(!s(e))throw Error(i(299));var r=!1,o="",c=fp,d=dp,b=hp,E=null;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(o=t.identifierPrefix),t.onUncaughtError!==void 0&&(c=t.onUncaughtError),t.onCaughtError!==void 0&&(d=t.onCaughtError),t.onRecoverableError!==void 0&&(b=t.onRecoverableError),t.unstable_transitionCallbacks!==void 0&&(E=t.unstable_transitionCallbacks)),t=Hg(e,1,!1,null,null,r,o,c,d,b,E,null),e[xe]=t.current,wf(e),new Bf(t)},Wi.hydrateRoot=function(e,t,r){if(!s(e))throw Error(i(299));var o=!1,c="",d=fp,b=dp,E=hp,j=null,q=null;return r!=null&&(r.unstable_strictMode===!0&&(o=!0),r.identifierPrefix!==void 0&&(c=r.identifierPrefix),r.onUncaughtError!==void 0&&(d=r.onUncaughtError),r.onCaughtError!==void 0&&(b=r.onCaughtError),r.onRecoverableError!==void 0&&(E=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(j=r.unstable_transitionCallbacks),r.formState!==void 0&&(q=r.formState)),t=Hg(e,1,!0,t,r??null,o,c,d,b,E,j,q),t.context=Bg(null),r=t.current,o=rn(),o=ai(o),c=ja(o),c.callback=null,Ma(r,c,o),r=o,t.current.lanes=r,fr(t,r),$n(t),e[xe]=t.current,wf(e),new Ps(t)},Wi.version="19.1.0",Wi}var Cv;function Qw(){if(Cv)return Yf.exports;Cv=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(a){console.error(a)}}return n(),Yf.exports=Xw(),Yf.exports}var Zw=Qw();/**
|
|
54
|
+
`+r.stack}}function mn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function bh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Ex(e){var t=bh(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),o=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var c=r.get,d=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return c.call(this)},set:function(b){o=""+b,d.call(this,b)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return o},setValue:function(b){o=""+b},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function _o(e){e._valueTracker||(e._valueTracker=Ex(e))}function xh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),o="";return e&&(o=bh(e)?e.checked?"true":"false":e.value),e=o,e!==r?(t.setValue(e),!0):!1}function Do(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}}var Rx=/[\n"\\]/g;function pn(e){return e.replace(Rx,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Uu(e,t,r,o,c,d,b,E){e.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.type=b:e.removeAttribute("type"),t!=null?b==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+mn(t)):e.value!==""+mn(t)&&(e.value=""+mn(t)):b!=="submit"&&b!=="reset"||e.removeAttribute("value"),t!=null?Pu(e,b,mn(t)):r!=null?Pu(e,b,mn(r)):o!=null&&e.removeAttribute("value"),c==null&&d!=null&&(e.defaultChecked=!!d),c!=null&&(e.checked=c&&typeof c!="function"&&typeof c!="symbol"),E!=null&&typeof E!="function"&&typeof E!="symbol"&&typeof E!="boolean"?e.name=""+mn(E):e.removeAttribute("name")}function Sh(e,t,r,o,c,d,b,E){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),t!=null||r!=null){if(!(d!=="submit"&&d!=="reset"||t!=null))return;r=r!=null?""+mn(r):"",t=t!=null?""+mn(t):r,E||t===e.value||(e.value=t),e.defaultValue=t}o=o??c,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=E?e.checked:!!o,e.defaultChecked=!!o,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(e.name=b)}function Pu(e,t,r){t==="number"&&Do(e.ownerDocument)===e||e.defaultValue===""+r||(e.defaultValue=""+r)}function Xr(e,t,r,o){if(e=e.options,t){t={};for(var c=0;c<r.length;c++)t["$"+r[c]]=!0;for(r=0;r<e.length;r++)c=t.hasOwnProperty("$"+e[r].value),e[r].selected!==c&&(e[r].selected=c),c&&o&&(e[r].defaultSelected=!0)}else{for(r=""+mn(r),t=null,c=0;c<e.length;c++){if(e[c].value===r){e[c].selected=!0,o&&(e[c].defaultSelected=!0);return}t!==null||e[c].disabled||(t=e[c])}t!==null&&(t.selected=!0)}}function wh(e,t,r){if(t!=null&&(t=""+mn(t),t!==e.value&&(e.value=t),r==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=r!=null?""+mn(r):""}function Eh(e,t,r,o){if(t==null){if(o!=null){if(r!=null)throw Error(i(92));if(fe(o)){if(1<o.length)throw Error(i(93));o=o[0]}r=o}r==null&&(r=""),t=r}r=mn(t),e.defaultValue=r,o=e.textContent,o===r&&o!==""&&o!==null&&(e.value=o)}function Qr(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Cx=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Rh(e,t,r){var o=t.indexOf("--")===0;r==null||typeof r=="boolean"||r===""?o?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":o?e.setProperty(t,r):typeof r!="number"||r===0||Cx.has(t)?t==="float"?e.cssFloat=r:e[t]=(""+r).trim():e[t]=r+"px"}function Ch(e,t,r){if(t!=null&&typeof t!="object")throw Error(i(62));if(e=e.style,r!=null){for(var o in r)!r.hasOwnProperty(o)||t!=null&&t.hasOwnProperty(o)||(o.indexOf("--")===0?e.setProperty(o,""):o==="float"?e.cssFloat="":e[o]="");for(var c in t)o=t[c],t.hasOwnProperty(c)&&r[c]!==o&&Rh(e,c,o)}else for(var d in t)t.hasOwnProperty(d)&&Rh(e,d,t[d])}function Hu(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Ox=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Ax=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Lo(e){return Ax.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Bu=null;function $u(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Zr=null,Jr=null;function Oh(e){var t=et(e);if(t&&(e=t.stateNode)){var r=e[ce]||null;e:switch(e=t.stateNode,t.type){case"input":if(Uu(e,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll('input[name="'+pn(""+t)+'"][type="radio"]'),t=0;t<r.length;t++){var o=r[t];if(o!==e&&o.form===e.form){var c=o[ce]||null;if(!c)throw Error(i(90));Uu(o,c.value,c.defaultValue,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name)}}for(t=0;t<r.length;t++)o=r[t],o.form===e.form&&xh(o)}break e;case"textarea":wh(e,r.value,r.defaultValue);break e;case"select":t=r.value,t!=null&&Xr(e,!!r.multiple,t,!1)}}}var Vu=!1;function Ah(e,t,r){if(Vu)return e(t,r);Vu=!0;try{var o=e(t);return o}finally{if(Vu=!1,(Zr!==null||Jr!==null)&&(bs(),Zr&&(t=Zr,e=Jr,Jr=Zr=null,Oh(t),e)))for(t=0;t<e.length;t++)Oh(e[t])}}function li(e,t){var r=e.stateNode;if(r===null)return null;var o=r[ce]||null;if(o===null)return null;r=o[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":(o=!o.disabled)||(e=e.type,o=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!o;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error(i(231,t,typeof r));return r}var na=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qu=!1;if(na)try{var ii={};Object.defineProperty(ii,"passive",{get:function(){qu=!0}}),window.addEventListener("test",ii,ii),window.removeEventListener("test",ii,ii)}catch{qu=!1}var Aa=null,Yu=null,zo=null;function Nh(){if(zo)return zo;var e,t=Yu,r=t.length,o,c="value"in Aa?Aa.value:Aa.textContent,d=c.length;for(e=0;e<r&&t[e]===c[e];e++);var b=r-e;for(o=1;o<=b&&t[r-o]===c[d-o];o++);return zo=c.slice(e,1<o?1-o:void 0)}function ko(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 Uo(){return!0}function Th(){return!1}function Kt(e){function t(r,o,c,d,b){this._reactName=r,this._targetInst=c,this.type=o,this.nativeEvent=d,this.target=b,this.currentTarget=null;for(var E in e)e.hasOwnProperty(E)&&(r=e[E],this[E]=r?r(d):d[E]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?Uo:Th,this.isPropagationStopped=Th,this}return g(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=Uo)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=Uo)},persist:function(){},isPersistent:Uo}),t}var pr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Po=Kt(pr),oi=g({},pr,{view:0,detail:0}),Nx=Kt(oi),Ku,Gu,si,Ho=g({},oi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Xu,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!==si&&(si&&e.type==="mousemove"?(Ku=e.screenX-si.screenX,Gu=e.screenY-si.screenY):Gu=Ku=0,si=e),Ku)},movementY:function(e){return"movementY"in e?e.movementY:Gu}}),jh=Kt(Ho),Tx=g({},Ho,{dataTransfer:0}),jx=Kt(Tx),Mx=g({},oi,{relatedTarget:0}),Fu=Kt(Mx),_x=g({},pr,{animationName:0,elapsedTime:0,pseudoElement:0}),Dx=Kt(_x),Lx=g({},pr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),zx=Kt(Lx),kx=g({},pr,{data:0}),Mh=Kt(kx),Ux={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Px={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"},Hx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Bx(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Hx[e])?!!t[e]:!1}function Xu(){return Bx}var $x=g({},oi,{key:function(e){if(e.key){var t=Ux[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ko(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Px[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Xu,charCode:function(e){return e.type==="keypress"?ko(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ko(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Vx=Kt($x),qx=g({},Ho,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),_h=Kt(qx),Yx=g({},oi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Xu}),Kx=Kt(Yx),Gx=g({},pr,{propertyName:0,elapsedTime:0,pseudoElement:0}),Fx=Kt(Gx),Xx=g({},Ho,{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}),Qx=Kt(Xx),Zx=g({},pr,{newState:0,oldState:0}),Jx=Kt(Zx),Ix=[9,13,27,32],Qu=na&&"CompositionEvent"in window,ui=null;na&&"documentMode"in document&&(ui=document.documentMode);var Wx=na&&"TextEvent"in window&&!ui,Dh=na&&(!Qu||ui&&8<ui&&11>=ui),Lh=" ",zh=!1;function kh(e,t){switch(e){case"keyup":return Ix.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Uh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ir=!1;function e1(e,t){switch(e){case"compositionend":return Uh(t);case"keypress":return t.which!==32?null:(zh=!0,Lh);case"textInput":return e=t.data,e===Lh&&zh?null:e;default:return null}}function t1(e,t){if(Ir)return e==="compositionend"||!Qu&&kh(e,t)?(e=Nh(),zo=Yu=Aa=null,Ir=!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 Dh&&t.locale!=="ko"?null:t.data;default:return null}}var n1={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 Ph(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!n1[e.type]:t==="textarea"}function Hh(e,t,r,o){Zr?Jr?Jr.push(o):Jr=[o]:Zr=o,t=Cs(t,"onChange"),0<t.length&&(r=new Po("onChange","change",null,r,o),e.push({event:r,listeners:t}))}var ci=null,fi=null;function a1(e){bg(e,0)}function Bo(e){var t=vt(e);if(xh(t))return e}function Bh(e,t){if(e==="change")return t}var $h=!1;if(na){var Zu;if(na){var Ju="oninput"in document;if(!Ju){var Vh=document.createElement("div");Vh.setAttribute("oninput","return;"),Ju=typeof Vh.oninput=="function"}Zu=Ju}else Zu=!1;$h=Zu&&(!document.documentMode||9<document.documentMode)}function qh(){ci&&(ci.detachEvent("onpropertychange",Yh),fi=ci=null)}function Yh(e){if(e.propertyName==="value"&&Bo(fi)){var t=[];Hh(t,fi,e,$u(e)),Ah(a1,t)}}function r1(e,t,r){e==="focusin"?(qh(),ci=t,fi=r,ci.attachEvent("onpropertychange",Yh)):e==="focusout"&&qh()}function l1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Bo(fi)}function i1(e,t){if(e==="click")return Bo(t)}function o1(e,t){if(e==="input"||e==="change")return Bo(t)}function s1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var It=typeof Object.is=="function"?Object.is:s1;function di(e,t){if(It(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),o=Object.keys(t);if(r.length!==o.length)return!1;for(o=0;o<r.length;o++){var c=r[o];if(!te.call(t,c)||!It(e[c],t[c]))return!1}return!0}function Kh(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Gh(e,t){var r=Kh(e);e=0;for(var o;r;){if(r.nodeType===3){if(o=e+r.textContent.length,e<=t&&o>=t)return{node:r,offset:t-e};e=o}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Kh(r)}}function Fh(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Fh(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Xh(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Do(e.document);t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Do(e.document)}return t}function Iu(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var u1=na&&"documentMode"in document&&11>=document.documentMode,Wr=null,Wu=null,hi=null,ec=!1;function Qh(e,t,r){var o=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;ec||Wr==null||Wr!==Do(o)||(o=Wr,"selectionStart"in o&&Iu(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),hi&&di(hi,o)||(hi=o,o=Cs(Wu,"onSelect"),0<o.length&&(t=new Po("onSelect","select",null,t,r),e.push({event:t,listeners:o}),t.target=Wr)))}function gr(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var el={animationend:gr("Animation","AnimationEnd"),animationiteration:gr("Animation","AnimationIteration"),animationstart:gr("Animation","AnimationStart"),transitionrun:gr("Transition","TransitionRun"),transitionstart:gr("Transition","TransitionStart"),transitioncancel:gr("Transition","TransitionCancel"),transitionend:gr("Transition","TransitionEnd")},tc={},Zh={};na&&(Zh=document.createElement("div").style,"AnimationEvent"in window||(delete el.animationend.animation,delete el.animationiteration.animation,delete el.animationstart.animation),"TransitionEvent"in window||delete el.transitionend.transition);function vr(e){if(tc[e])return tc[e];if(!el[e])return e;var t=el[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in Zh)return tc[e]=t[r];return e}var Jh=vr("animationend"),Ih=vr("animationiteration"),Wh=vr("animationstart"),c1=vr("transitionrun"),f1=vr("transitionstart"),d1=vr("transitioncancel"),em=vr("transitionend"),tm=new Map,nc="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");nc.push("scrollEnd");function An(e,t){tm.set(e,t),Jt(t,[e])}var nm=new WeakMap;function gn(e,t){if(typeof e=="object"&&e!==null){var r=nm.get(e);return r!==void 0?r:(t={value:e,source:t,stack:Mo(t)},nm.set(e,t),t)}return{value:e,source:t,stack:Mo(t)}}var vn=[],tl=0,ac=0;function $o(){for(var e=tl,t=ac=tl=0;t<e;){var r=vn[t];vn[t++]=null;var o=vn[t];vn[t++]=null;var c=vn[t];vn[t++]=null;var d=vn[t];if(vn[t++]=null,o!==null&&c!==null){var b=o.pending;b===null?c.next=c:(c.next=b.next,b.next=c),o.pending=c}d!==0&&am(r,c,d)}}function Vo(e,t,r,o){vn[tl++]=e,vn[tl++]=t,vn[tl++]=r,vn[tl++]=o,ac|=o,e.lanes|=o,e=e.alternate,e!==null&&(e.lanes|=o)}function rc(e,t,r,o){return Vo(e,t,r,o),qo(e)}function nl(e,t){return Vo(e,null,null,t),qo(e)}function am(e,t,r){e.lanes|=r;var o=e.alternate;o!==null&&(o.lanes|=r);for(var c=!1,d=e.return;d!==null;)d.childLanes|=r,o=d.alternate,o!==null&&(o.childLanes|=r),d.tag===22&&(e=d.stateNode,e===null||e._visibility&1||(c=!0)),e=d,d=d.return;return e.tag===3?(d=e.stateNode,c&&t!==null&&(c=31-Lt(r),e=d.hiddenUpdates,o=e[c],o===null?e[c]=[t]:o.push(t),t.lane=r|536870912),d):null}function qo(e){if(50<Pi)throw Pi=0,ff=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var al={};function h1(e,t,r,o){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Wt(e,t,r,o){return new h1(e,t,r,o)}function lc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function aa(e,t){var r=e.alternate;return r===null?(r=Wt(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&65011712,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r.refCleanup=e.refCleanup,r}function rm(e,t){e.flags&=65011714;var r=e.alternate;return r===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=r.childLanes,e.lanes=r.lanes,e.child=r.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=r.memoizedProps,e.memoizedState=r.memoizedState,e.updateQueue=r.updateQueue,e.type=r.type,t=r.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Yo(e,t,r,o,c,d){var b=0;if(o=e,typeof e=="function")lc(e)&&(b=1);else if(typeof e=="string")b=pS(e,r,W.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case re:return e=Wt(31,r,t,c),e.elementType=re,e.lanes=d,e;case C:return yr(r.children,c,d,t);case R:b=8,c|=24;break;case T:return e=Wt(12,r,t,c|2),e.elementType=T,e.lanes=d,e;case P:return e=Wt(13,r,t,c),e.elementType=P,e.lanes=d,e;case A:return e=Wt(19,r,t,c),e.elementType=A,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case O:case k:b=10;break e;case z:b=9;break e;case H:b=11;break e;case G:b=14;break e;case J:b=16,o=null;break e}b=29,r=Error(i(130,e===null?"null":typeof e,"")),o=null}return t=Wt(b,r,t,c),t.elementType=e,t.type=o,t.lanes=d,t}function yr(e,t,r,o){return e=Wt(7,e,o,t),e.lanes=r,e}function ic(e,t,r){return e=Wt(6,e,null,t),e.lanes=r,e}function oc(e,t,r){return t=Wt(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var rl=[],ll=0,Ko=null,Go=0,yn=[],bn=0,br=null,ra=1,la="";function xr(e,t){rl[ll++]=Go,rl[ll++]=Ko,Ko=e,Go=t}function lm(e,t,r){yn[bn++]=ra,yn[bn++]=la,yn[bn++]=br,br=e;var o=ra;e=la;var c=32-Lt(o)-1;o&=~(1<<c),r+=1;var d=32-Lt(t)+c;if(30<d){var b=c-c%5;d=(o&(1<<b)-1).toString(32),o>>=b,c-=b,ra=1<<32-Lt(t)+c|r<<c|o,la=d+e}else ra=1<<d|r<<c|o,la=e}function sc(e){e.return!==null&&(xr(e,1),lm(e,1,0))}function uc(e){for(;e===Ko;)Ko=rl[--ll],rl[ll]=null,Go=rl[--ll],rl[ll]=null;for(;e===br;)br=yn[--bn],yn[bn]=null,la=yn[--bn],yn[bn]=null,ra=yn[--bn],yn[bn]=null}var qt=null,bt=null,We=!1,Sr=null,Un=!1,cc=Error(i(519));function wr(e){var t=Error(i(418,""));throw gi(gn(t,e)),cc}function im(e){var t=e.stateNode,r=e.type,o=e.memoizedProps;switch(t[le]=e,t[ce]=o,r){case"dialog":Qe("cancel",t),Qe("close",t);break;case"iframe":case"object":case"embed":Qe("load",t);break;case"video":case"audio":for(r=0;r<Bi.length;r++)Qe(Bi[r],t);break;case"source":Qe("error",t);break;case"img":case"image":case"link":Qe("error",t),Qe("load",t);break;case"details":Qe("toggle",t);break;case"input":Qe("invalid",t),Sh(t,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0),_o(t);break;case"select":Qe("invalid",t);break;case"textarea":Qe("invalid",t),Eh(t,o.value,o.defaultValue,o.children),_o(t)}r=o.children,typeof r!="string"&&typeof r!="number"&&typeof r!="bigint"||t.textContent===""+r||o.suppressHydrationWarning===!0||Eg(t.textContent,r)?(o.popover!=null&&(Qe("beforetoggle",t),Qe("toggle",t)),o.onScroll!=null&&Qe("scroll",t),o.onScrollEnd!=null&&Qe("scrollend",t),o.onClick!=null&&(t.onclick=Os),t=!0):t=!1,t||wr(e)}function om(e){for(qt=e.return;qt;)switch(qt.tag){case 5:case 13:Un=!1;return;case 27:case 3:Un=!0;return;default:qt=qt.return}}function mi(e){if(e!==qt)return!1;if(!We)return om(e),We=!0,!1;var t=e.tag,r;if((r=t!==3&&t!==27)&&((r=t===5)&&(r=e.type,r=!(r!=="form"&&r!=="button")||Af(e.type,e.memoizedProps)),r=!r),r&&bt&&wr(e),om(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8)if(r=e.data,r==="/$"){if(t===0){bt=Tn(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++;e=e.nextSibling}bt=null}}else t===27?(t=bt,qa(e.type)?(e=Mf,Mf=null,bt=e):bt=t):bt=qt?Tn(e.stateNode.nextSibling):null;return!0}function pi(){bt=qt=null,We=!1}function sm(){var e=Sr;return e!==null&&(Xt===null?Xt=e:Xt.push.apply(Xt,e),Sr=null),e}function gi(e){Sr===null?Sr=[e]:Sr.push(e)}var fc=Y(null),Er=null,ia=null;function Na(e,t,r){K(fc,t._currentValue),t._currentValue=r}function oa(e){e._currentValue=fc.current,L(fc)}function dc(e,t,r){for(;e!==null;){var o=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,o!==null&&(o.childLanes|=t)):o!==null&&(o.childLanes&t)!==t&&(o.childLanes|=t),e===r)break;e=e.return}}function hc(e,t,r,o){var c=e.child;for(c!==null&&(c.return=e);c!==null;){var d=c.dependencies;if(d!==null){var b=c.child;d=d.firstContext;e:for(;d!==null;){var E=d;d=c;for(var j=0;j<t.length;j++)if(E.context===t[j]){d.lanes|=r,E=d.alternate,E!==null&&(E.lanes|=r),dc(d.return,r,e),o||(b=null);break e}d=E.next}}else if(c.tag===18){if(b=c.return,b===null)throw Error(i(341));b.lanes|=r,d=b.alternate,d!==null&&(d.lanes|=r),dc(b,r,e),b=null}else b=c.child;if(b!==null)b.return=c;else for(b=c;b!==null;){if(b===e){b=null;break}if(c=b.sibling,c!==null){c.return=b.return,b=c;break}b=b.return}c=b}}function vi(e,t,r,o){e=null;for(var c=t,d=!1;c!==null;){if(!d){if((c.flags&524288)!==0)d=!0;else if((c.flags&262144)!==0)break}if(c.tag===10){var b=c.alternate;if(b===null)throw Error(i(387));if(b=b.memoizedProps,b!==null){var E=c.type;It(c.pendingProps.value,b.value)||(e!==null?e.push(E):e=[E])}}else if(c===ge.current){if(b=c.alternate,b===null)throw Error(i(387));b.memoizedState.memoizedState!==c.memoizedState.memoizedState&&(e!==null?e.push(Gi):e=[Gi])}c=c.return}e!==null&&hc(t,e,r,o),t.flags|=262144}function Fo(e){for(e=e.firstContext;e!==null;){if(!It(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Rr(e){Er=e,ia=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ht(e){return um(Er,e)}function Xo(e,t){return Er===null&&Rr(e),um(e,t)}function um(e,t){var r=t._currentValue;if(t={context:t,memoizedValue:r,next:null},ia===null){if(e===null)throw Error(i(308));ia=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else ia=ia.next=t;return r}var m1=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(r,o){e.push(o)}};this.abort=function(){t.aborted=!0,e.forEach(function(r){return r()})}},p1=n.unstable_scheduleCallback,g1=n.unstable_NormalPriority,Nt={$$typeof:k,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function mc(){return{controller:new m1,data:new Map,refCount:0}}function yi(e){e.refCount--,e.refCount===0&&p1(g1,function(){e.controller.abort()})}var bi=null,pc=0,il=0,ol=null;function v1(e,t){if(bi===null){var r=bi=[];pc=0,il=yf(),ol={status:"pending",value:void 0,then:function(o){r.push(o)}}}return pc++,t.then(cm,cm),t}function cm(){if(--pc===0&&bi!==null){ol!==null&&(ol.status="fulfilled");var e=bi;bi=null,il=0,ol=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function y1(e,t){var r=[],o={status:"pending",value:null,reason:null,then:function(c){r.push(c)}};return e.then(function(){o.status="fulfilled",o.value=t;for(var c=0;c<r.length;c++)(0,r[c])(t)},function(c){for(o.status="rejected",o.reason=c,c=0;c<r.length;c++)(0,r[c])(void 0)}),o}var fm=_.S;_.S=function(e,t){typeof t=="object"&&t!==null&&typeof t.then=="function"&&v1(e,t),fm!==null&&fm(e,t)};var Cr=Y(null);function gc(){var e=Cr.current;return e!==null?e:ut.pooledCache}function Qo(e,t){t===null?K(Cr,Cr.current):K(Cr,t.pool)}function dm(){var e=gc();return e===null?null:{parent:Nt._currentValue,pool:e}}var xi=Error(i(460)),hm=Error(i(474)),Zo=Error(i(542)),vc={then:function(){}};function mm(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Jo(){}function pm(e,t,r){switch(r=e[r],r===void 0?e.push(t):r!==t&&(t.then(Jo,Jo),t=r),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,vm(e),e;default:if(typeof t.status=="string")t.then(Jo,Jo);else{if(e=ut,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status="pending",e.then(function(o){if(t.status==="pending"){var c=t;c.status="fulfilled",c.value=o}},function(o){if(t.status==="pending"){var c=t;c.status="rejected",c.reason=o}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,vm(e),e}throw Si=t,xi}}var Si=null;function gm(){if(Si===null)throw Error(i(459));var e=Si;return Si=null,e}function vm(e){if(e===xi||e===Zo)throw Error(i(483))}var Ta=!1;function yc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function ja(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ma(e,t,r){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(tt&2)!==0){var c=o.pending;return c===null?t.next=t:(t.next=c.next,c.next=t),o.pending=t,t=qo(e),am(e,null,r),t}return Vo(e,o,t,r),qo(e)}function wi(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194048)!==0)){var o=t.lanes;o&=e.pendingLanes,r|=o,t.lanes=r,hr(e,r)}}function xc(e,t){var r=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,r===o)){var c=null,d=null;if(r=r.firstBaseUpdate,r!==null){do{var b={lane:r.lane,tag:r.tag,payload:r.payload,callback:null,next:null};d===null?c=d=b:d=d.next=b,r=r.next}while(r!==null);d===null?c=d=t:d=d.next=t}else c=d=t;r={baseState:o.baseState,firstBaseUpdate:c,lastBaseUpdate:d,shared:o.shared,callbacks:o.callbacks},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}var Sc=!1;function Ei(){if(Sc){var e=ol;if(e!==null)throw e}}function Ri(e,t,r,o){Sc=!1;var c=e.updateQueue;Ta=!1;var d=c.firstBaseUpdate,b=c.lastBaseUpdate,E=c.shared.pending;if(E!==null){c.shared.pending=null;var j=E,q=j.next;j.next=null,b===null?d=q:b.next=q,b=j;var I=e.alternate;I!==null&&(I=I.updateQueue,E=I.lastBaseUpdate,E!==b&&(E===null?I.firstBaseUpdate=q:E.next=q,I.lastBaseUpdate=j))}if(d!==null){var ne=c.baseState;b=0,I=q=j=null,E=d;do{var F=E.lane&-536870913,X=F!==E.lane;if(X?(Je&F)===F:(o&F)===F){F!==0&&F===il&&(Sc=!0),I!==null&&(I=I.next={lane:0,tag:E.tag,payload:E.payload,callback:null,next:null});e:{var ke=e,De=E;F=t;var it=r;switch(De.tag){case 1:if(ke=De.payload,typeof ke=="function"){ne=ke.call(it,ne,F);break e}ne=ke;break e;case 3:ke.flags=ke.flags&-65537|128;case 0:if(ke=De.payload,F=typeof ke=="function"?ke.call(it,ne,F):ke,F==null)break e;ne=g({},ne,F);break e;case 2:Ta=!0}}F=E.callback,F!==null&&(e.flags|=64,X&&(e.flags|=8192),X=c.callbacks,X===null?c.callbacks=[F]:X.push(F))}else X={lane:F,tag:E.tag,payload:E.payload,callback:E.callback,next:null},I===null?(q=I=X,j=ne):I=I.next=X,b|=F;if(E=E.next,E===null){if(E=c.shared.pending,E===null)break;X=E,E=X.next,X.next=null,c.lastBaseUpdate=X,c.shared.pending=null}}while(!0);I===null&&(j=ne),c.baseState=j,c.firstBaseUpdate=q,c.lastBaseUpdate=I,d===null&&(c.shared.lanes=0),Ha|=b,e.lanes=b,e.memoizedState=ne}}function ym(e,t){if(typeof e!="function")throw Error(i(191,e));e.call(t)}function bm(e,t){var r=e.callbacks;if(r!==null)for(e.callbacks=null,e=0;e<r.length;e++)ym(r[e],t)}var sl=Y(null),Io=Y(0);function xm(e,t){e=ma,K(Io,e),K(sl,t),ma=e|t.baseLanes}function wc(){K(Io,ma),K(sl,sl.current)}function Ec(){ma=Io.current,L(sl),L(Io)}var _a=0,qe=null,rt=null,Ot=null,Wo=!1,ul=!1,Or=!1,es=0,Ci=0,cl=null,b1=0;function wt(){throw Error(i(321))}function Rc(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!It(e[r],t[r]))return!1;return!0}function Cc(e,t,r,o,c,d){return _a=d,qe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,_.H=e===null||e.memoizedState===null?ap:rp,Or=!1,d=r(o,c),Or=!1,ul&&(d=wm(t,r,o,c)),Sm(e),d}function Sm(e){_.H=is;var t=rt!==null&&rt.next!==null;if(_a=0,Ot=rt=qe=null,Wo=!1,Ci=0,cl=null,t)throw Error(i(300));e===null||Mt||(e=e.dependencies,e!==null&&Fo(e)&&(Mt=!0))}function wm(e,t,r,o){qe=e;var c=0;do{if(ul&&(cl=null),Ci=0,ul=!1,25<=c)throw Error(i(301));if(c+=1,Ot=rt=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}_.H=O1,d=t(r,o)}while(ul);return d}function x1(){var e=_.H,t=e.useState()[0];return t=typeof t.then=="function"?Oi(t):t,e=e.useState()[0],(rt!==null?rt.memoizedState:null)!==e&&(qe.flags|=1024),t}function Oc(){var e=es!==0;return es=0,e}function Ac(e,t,r){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~r}function Nc(e){if(Wo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Wo=!1}_a=0,Ot=rt=qe=null,ul=!1,Ci=es=0,cl=null}function Gt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ot===null?qe.memoizedState=Ot=e:Ot=Ot.next=e,Ot}function At(){if(rt===null){var e=qe.alternate;e=e!==null?e.memoizedState:null}else e=rt.next;var t=Ot===null?qe.memoizedState:Ot.next;if(t!==null)Ot=t,rt=e;else{if(e===null)throw qe.alternate===null?Error(i(467)):Error(i(310));rt=e,e={memoizedState:rt.memoizedState,baseState:rt.baseState,baseQueue:rt.baseQueue,queue:rt.queue,next:null},Ot===null?qe.memoizedState=Ot=e:Ot=Ot.next=e}return Ot}function Tc(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Oi(e){var t=Ci;return Ci+=1,cl===null&&(cl=[]),e=pm(cl,e,t),t=qe,(Ot===null?t.memoizedState:Ot.next)===null&&(t=t.alternate,_.H=t===null||t.memoizedState===null?ap:rp),e}function ts(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Oi(e);if(e.$$typeof===k)return Ht(e)}throw Error(i(438,String(e)))}function jc(e){var t=null,r=qe.updateQueue;if(r!==null&&(t=r.memoCache),t==null){var o=qe.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(t={data:o.data.map(function(c){return c.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),r===null&&(r=Tc(),qe.updateQueue=r),r.memoCache=t,r=t.data[t.index],r===void 0)for(r=t.data[t.index]=Array(e),o=0;o<e;o++)r[o]=ie;return t.index++,r}function sa(e,t){return typeof t=="function"?t(e):t}function ns(e){var t=At();return Mc(t,rt,e)}function Mc(e,t,r){var o=e.queue;if(o===null)throw Error(i(311));o.lastRenderedReducer=r;var c=e.baseQueue,d=o.pending;if(d!==null){if(c!==null){var b=c.next;c.next=d.next,d.next=b}t.baseQueue=c=d,o.pending=null}if(d=e.baseState,c===null)e.memoizedState=d;else{t=c.next;var E=b=null,j=null,q=t,I=!1;do{var ne=q.lane&-536870913;if(ne!==q.lane?(Je&ne)===ne:(_a&ne)===ne){var F=q.revertLane;if(F===0)j!==null&&(j=j.next={lane:0,revertLane:0,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null}),ne===il&&(I=!0);else if((_a&F)===F){q=q.next,F===il&&(I=!0);continue}else ne={lane:0,revertLane:q.revertLane,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null},j===null?(E=j=ne,b=d):j=j.next=ne,qe.lanes|=F,Ha|=F;ne=q.action,Or&&r(d,ne),d=q.hasEagerState?q.eagerState:r(d,ne)}else F={lane:ne,revertLane:q.revertLane,action:q.action,hasEagerState:q.hasEagerState,eagerState:q.eagerState,next:null},j===null?(E=j=F,b=d):j=j.next=F,qe.lanes|=ne,Ha|=ne;q=q.next}while(q!==null&&q!==t);if(j===null?b=d:j.next=E,!It(d,e.memoizedState)&&(Mt=!0,I&&(r=ol,r!==null)))throw r;e.memoizedState=d,e.baseState=b,e.baseQueue=j,o.lastRenderedState=d}return c===null&&(o.lanes=0),[e.memoizedState,o.dispatch]}function _c(e){var t=At(),r=t.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=e;var o=r.dispatch,c=r.pending,d=t.memoizedState;if(c!==null){r.pending=null;var b=c=c.next;do d=e(d,b.action),b=b.next;while(b!==c);It(d,t.memoizedState)||(Mt=!0),t.memoizedState=d,t.baseQueue===null&&(t.baseState=d),r.lastRenderedState=d}return[d,o]}function Em(e,t,r){var o=qe,c=At(),d=We;if(d){if(r===void 0)throw Error(i(407));r=r()}else r=t();var b=!It((rt||c).memoizedState,r);b&&(c.memoizedState=r,Mt=!0),c=c.queue;var E=Om.bind(null,o,c,e);if(Ai(2048,8,E,[e]),c.getSnapshot!==t||b||Ot!==null&&Ot.memoizedState.tag&1){if(o.flags|=2048,fl(9,as(),Cm.bind(null,o,c,r,t),null),ut===null)throw Error(i(349));d||(_a&124)!==0||Rm(o,t,r)}return r}function Rm(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=qe.updateQueue,t===null?(t=Tc(),qe.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function Cm(e,t,r,o){t.value=r,t.getSnapshot=o,Am(t)&&Nm(e)}function Om(e,t,r){return r(function(){Am(t)&&Nm(e)})}function Am(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!It(e,r)}catch{return!0}}function Nm(e){var t=nl(e,2);t!==null&&rn(t,e,2)}function Dc(e){var t=Gt();if(typeof e=="function"){var r=e;if(e=r(),Or){On(!0);try{r()}finally{On(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:e},t}function Tm(e,t,r,o){return e.baseState=r,Mc(e,rt,typeof o=="function"?o:sa)}function S1(e,t,r,o,c){if(ls(e))throw Error(i(485));if(e=t.action,e!==null){var d={payload:c,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){d.listeners.push(b)}};_.T!==null?r(!0):d.isTransition=!1,o(d),r=t.pending,r===null?(d.next=t.pending=d,jm(t,d)):(d.next=r.next,t.pending=r.next=d)}}function jm(e,t){var r=t.action,o=t.payload,c=e.state;if(t.isTransition){var d=_.T,b={};_.T=b;try{var E=r(c,o),j=_.S;j!==null&&j(b,E),Mm(e,t,E)}catch(q){Lc(e,t,q)}finally{_.T=d}}else try{d=r(c,o),Mm(e,t,d)}catch(q){Lc(e,t,q)}}function Mm(e,t,r){r!==null&&typeof r=="object"&&typeof r.then=="function"?r.then(function(o){_m(e,t,o)},function(o){return Lc(e,t,o)}):_m(e,t,r)}function _m(e,t,r){t.status="fulfilled",t.value=r,Dm(t),e.state=r,t=e.pending,t!==null&&(r=t.next,r===t?e.pending=null:(r=r.next,t.next=r,jm(e,r)))}function Lc(e,t,r){var o=e.pending;if(e.pending=null,o!==null){o=o.next;do t.status="rejected",t.reason=r,Dm(t),t=t.next;while(t!==o)}e.action=null}function Dm(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Lm(e,t){return t}function zm(e,t){if(We){var r=ut.formState;if(r!==null){e:{var o=qe;if(We){if(bt){t:{for(var c=bt,d=Un;c.nodeType!==8;){if(!d){c=null;break t}if(c=Tn(c.nextSibling),c===null){c=null;break t}}d=c.data,c=d==="F!"||d==="F"?c:null}if(c){bt=Tn(c.nextSibling),o=c.data==="F!";break e}}wr(o)}o=!1}o&&(t=r[0])}}return r=Gt(),r.memoizedState=r.baseState=t,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Lm,lastRenderedState:t},r.queue=o,r=ep.bind(null,qe,o),o.dispatch=r,o=Dc(!1),d=Hc.bind(null,qe,!1,o.queue),o=Gt(),c={state:t,dispatch:null,action:e,pending:null},o.queue=c,r=S1.bind(null,qe,c,d,r),c.dispatch=r,o.memoizedState=e,[t,r,!1]}function km(e){var t=At();return Um(t,rt,e)}function Um(e,t,r){if(t=Mc(e,t,Lm)[0],e=ns(sa)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var o=Oi(t)}catch(b){throw b===xi?Zo:b}else o=t;t=At();var c=t.queue,d=c.dispatch;return r!==t.memoizedState&&(qe.flags|=2048,fl(9,as(),w1.bind(null,c,r),null)),[o,d,e]}function w1(e,t){e.action=t}function Pm(e){var t=At(),r=rt;if(r!==null)return Um(t,r,e);At(),t=t.memoizedState,r=At();var o=r.queue.dispatch;return r.memoizedState=e,[t,o,!1]}function fl(e,t,r,o){return e={tag:e,create:r,deps:o,inst:t,next:null},t=qe.updateQueue,t===null&&(t=Tc(),qe.updateQueue=t),r=t.lastEffect,r===null?t.lastEffect=e.next=e:(o=r.next,r.next=e,e.next=o,t.lastEffect=e),e}function as(){return{destroy:void 0,resource:void 0}}function Hm(){return At().memoizedState}function rs(e,t,r,o){var c=Gt();o=o===void 0?null:o,qe.flags|=e,c.memoizedState=fl(1|t,as(),r,o)}function Ai(e,t,r,o){var c=At();o=o===void 0?null:o;var d=c.memoizedState.inst;rt!==null&&o!==null&&Rc(o,rt.memoizedState.deps)?c.memoizedState=fl(t,d,r,o):(qe.flags|=e,c.memoizedState=fl(1|t,d,r,o))}function Bm(e,t){rs(8390656,8,e,t)}function $m(e,t){Ai(2048,8,e,t)}function Vm(e,t){return Ai(4,2,e,t)}function qm(e,t){return Ai(4,4,e,t)}function Ym(e,t){if(typeof t=="function"){e=e();var r=t(e);return function(){typeof r=="function"?r():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Km(e,t,r){r=r!=null?r.concat([e]):null,Ai(4,4,Ym.bind(null,t,e),r)}function zc(){}function Gm(e,t){var r=At();t=t===void 0?null:t;var o=r.memoizedState;return t!==null&&Rc(t,o[1])?o[0]:(r.memoizedState=[e,t],e)}function Fm(e,t){var r=At();t=t===void 0?null:t;var o=r.memoizedState;if(t!==null&&Rc(t,o[1]))return o[0];if(o=e(),Or){On(!0);try{e()}finally{On(!1)}}return r.memoizedState=[o,t],o}function kc(e,t,r){return r===void 0||(_a&1073741824)!==0?e.memoizedState=t:(e.memoizedState=r,e=Zp(),qe.lanes|=e,Ha|=e,r)}function Xm(e,t,r,o){return It(r,t)?r:sl.current!==null?(e=kc(e,r,o),It(e,t)||(Mt=!0),e):(_a&42)===0?(Mt=!0,e.memoizedState=r):(e=Zp(),qe.lanes|=e,Ha|=e,t)}function Qm(e,t,r,o,c){var d=Z.p;Z.p=d!==0&&8>d?d:8;var b=_.T,E={};_.T=E,Hc(e,!1,t,r);try{var j=c(),q=_.S;if(q!==null&&q(E,j),j!==null&&typeof j=="object"&&typeof j.then=="function"){var I=y1(j,o);Ni(e,t,I,an(e))}else Ni(e,t,o,an(e))}catch(ne){Ni(e,t,{then:function(){},status:"rejected",reason:ne},an())}finally{Z.p=d,_.T=b}}function E1(){}function Uc(e,t,r,o){if(e.tag!==5)throw Error(i(476));var c=Zm(e).queue;Qm(e,c,t,$,r===null?E1:function(){return Jm(e),r(o)})}function Zm(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:$,baseState:$,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:$},next:null};var r={};return t.next={memoizedState:r,baseState:r,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:r},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Jm(e){var t=Zm(e).next.queue;Ni(e,t,{},an())}function Pc(){return Ht(Gi)}function Im(){return At().memoizedState}function Wm(){return At().memoizedState}function R1(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var r=an();e=ja(r);var o=Ma(t,e,r);o!==null&&(rn(o,t,r),wi(o,t,r)),t={cache:mc()},e.payload=t;return}t=t.return}}function C1(e,t,r){var o=an();r={lane:o,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null},ls(e)?tp(t,r):(r=rc(e,t,r,o),r!==null&&(rn(r,e,o),np(r,t,o)))}function ep(e,t,r){var o=an();Ni(e,t,r,o)}function Ni(e,t,r,o){var c={lane:o,revertLane:0,action:r,hasEagerState:!1,eagerState:null,next:null};if(ls(e))tp(t,c);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=t.lastRenderedReducer,d!==null))try{var b=t.lastRenderedState,E=d(b,r);if(c.hasEagerState=!0,c.eagerState=E,It(E,b))return Vo(e,t,c,0),ut===null&&$o(),!1}catch{}finally{}if(r=rc(e,t,c,o),r!==null)return rn(r,e,o),np(r,t,o),!0}return!1}function Hc(e,t,r,o){if(o={lane:2,revertLane:yf(),action:o,hasEagerState:!1,eagerState:null,next:null},ls(e)){if(t)throw Error(i(479))}else t=rc(e,r,o,2),t!==null&&rn(t,e,2)}function ls(e){var t=e.alternate;return e===qe||t!==null&&t===qe}function tp(e,t){ul=Wo=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function np(e,t,r){if((r&4194048)!==0){var o=t.lanes;o&=e.pendingLanes,r|=o,t.lanes=r,hr(e,r)}}var is={readContext:Ht,use:ts,useCallback:wt,useContext:wt,useEffect:wt,useImperativeHandle:wt,useLayoutEffect:wt,useInsertionEffect:wt,useMemo:wt,useReducer:wt,useRef:wt,useState:wt,useDebugValue:wt,useDeferredValue:wt,useTransition:wt,useSyncExternalStore:wt,useId:wt,useHostTransitionStatus:wt,useFormState:wt,useActionState:wt,useOptimistic:wt,useMemoCache:wt,useCacheRefresh:wt},ap={readContext:Ht,use:ts,useCallback:function(e,t){return Gt().memoizedState=[e,t===void 0?null:t],e},useContext:Ht,useEffect:Bm,useImperativeHandle:function(e,t,r){r=r!=null?r.concat([e]):null,rs(4194308,4,Ym.bind(null,t,e),r)},useLayoutEffect:function(e,t){return rs(4194308,4,e,t)},useInsertionEffect:function(e,t){rs(4,2,e,t)},useMemo:function(e,t){var r=Gt();t=t===void 0?null:t;var o=e();if(Or){On(!0);try{e()}finally{On(!1)}}return r.memoizedState=[o,t],o},useReducer:function(e,t,r){var o=Gt();if(r!==void 0){var c=r(t);if(Or){On(!0);try{r(t)}finally{On(!1)}}}else c=t;return o.memoizedState=o.baseState=c,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:c},o.queue=e,e=e.dispatch=C1.bind(null,qe,e),[o.memoizedState,e]},useRef:function(e){var t=Gt();return e={current:e},t.memoizedState=e},useState:function(e){e=Dc(e);var t=e.queue,r=ep.bind(null,qe,t);return t.dispatch=r,[e.memoizedState,r]},useDebugValue:zc,useDeferredValue:function(e,t){var r=Gt();return kc(r,e,t)},useTransition:function(){var e=Dc(!1);return e=Qm.bind(null,qe,e.queue,!0,!1),Gt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,r){var o=qe,c=Gt();if(We){if(r===void 0)throw Error(i(407));r=r()}else{if(r=t(),ut===null)throw Error(i(349));(Je&124)!==0||Rm(o,t,r)}c.memoizedState=r;var d={value:r,getSnapshot:t};return c.queue=d,Bm(Om.bind(null,o,d,e),[e]),o.flags|=2048,fl(9,as(),Cm.bind(null,o,d,r,t),null),r},useId:function(){var e=Gt(),t=ut.identifierPrefix;if(We){var r=la,o=ra;r=(o&~(1<<32-Lt(o)-1)).toString(32)+r,t="«"+t+"R"+r,r=es++,0<r&&(t+="H"+r.toString(32)),t+="»"}else r=b1++,t="«"+t+"r"+r.toString(32)+"»";return e.memoizedState=t},useHostTransitionStatus:Pc,useFormState:zm,useActionState:zm,useOptimistic:function(e){var t=Gt();t.memoizedState=t.baseState=e;var r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=r,t=Hc.bind(null,qe,!0,r),r.dispatch=t,[e,t]},useMemoCache:jc,useCacheRefresh:function(){return Gt().memoizedState=R1.bind(null,qe)}},rp={readContext:Ht,use:ts,useCallback:Gm,useContext:Ht,useEffect:$m,useImperativeHandle:Km,useInsertionEffect:Vm,useLayoutEffect:qm,useMemo:Fm,useReducer:ns,useRef:Hm,useState:function(){return ns(sa)},useDebugValue:zc,useDeferredValue:function(e,t){var r=At();return Xm(r,rt.memoizedState,e,t)},useTransition:function(){var e=ns(sa)[0],t=At().memoizedState;return[typeof e=="boolean"?e:Oi(e),t]},useSyncExternalStore:Em,useId:Im,useHostTransitionStatus:Pc,useFormState:km,useActionState:km,useOptimistic:function(e,t){var r=At();return Tm(r,rt,e,t)},useMemoCache:jc,useCacheRefresh:Wm},O1={readContext:Ht,use:ts,useCallback:Gm,useContext:Ht,useEffect:$m,useImperativeHandle:Km,useInsertionEffect:Vm,useLayoutEffect:qm,useMemo:Fm,useReducer:_c,useRef:Hm,useState:function(){return _c(sa)},useDebugValue:zc,useDeferredValue:function(e,t){var r=At();return rt===null?kc(r,e,t):Xm(r,rt.memoizedState,e,t)},useTransition:function(){var e=_c(sa)[0],t=At().memoizedState;return[typeof e=="boolean"?e:Oi(e),t]},useSyncExternalStore:Em,useId:Im,useHostTransitionStatus:Pc,useFormState:Pm,useActionState:Pm,useOptimistic:function(e,t){var r=At();return rt!==null?Tm(r,rt,e,t):(r.baseState=e,[e,r.queue.dispatch])},useMemoCache:jc,useCacheRefresh:Wm},dl=null,Ti=0;function os(e){var t=Ti;return Ti+=1,dl===null&&(dl=[]),pm(dl,e,t)}function ji(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function ss(e,t){throw t.$$typeof===x?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function lp(e){var t=e._init;return t(e._payload)}function ip(e){function t(U,D){if(e){var V=U.deletions;V===null?(U.deletions=[D],U.flags|=16):V.push(D)}}function r(U,D){if(!e)return null;for(;D!==null;)t(U,D),D=D.sibling;return null}function o(U){for(var D=new Map;U!==null;)U.key!==null?D.set(U.key,U):D.set(U.index,U),U=U.sibling;return D}function c(U,D){return U=aa(U,D),U.index=0,U.sibling=null,U}function d(U,D,V){return U.index=V,e?(V=U.alternate,V!==null?(V=V.index,V<D?(U.flags|=67108866,D):V):(U.flags|=67108866,D)):(U.flags|=1048576,D)}function b(U){return e&&U.alternate===null&&(U.flags|=67108866),U}function E(U,D,V,ee){return D===null||D.tag!==6?(D=ic(V,U.mode,ee),D.return=U,D):(D=c(D,V),D.return=U,D)}function j(U,D,V,ee){var ve=V.type;return ve===C?I(U,D,V.props.children,ee,V.key):D!==null&&(D.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===J&&lp(ve)===D.type)?(D=c(D,V.props),ji(D,V),D.return=U,D):(D=Yo(V.type,V.key,V.props,null,U.mode,ee),ji(D,V),D.return=U,D)}function q(U,D,V,ee){return D===null||D.tag!==4||D.stateNode.containerInfo!==V.containerInfo||D.stateNode.implementation!==V.implementation?(D=oc(V,U.mode,ee),D.return=U,D):(D=c(D,V.children||[]),D.return=U,D)}function I(U,D,V,ee,ve){return D===null||D.tag!==7?(D=yr(V,U.mode,ee,ve),D.return=U,D):(D=c(D,V),D.return=U,D)}function ne(U,D,V){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return D=ic(""+D,U.mode,V),D.return=U,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case S:return V=Yo(D.type,D.key,D.props,null,U.mode,V),ji(V,D),V.return=U,V;case w:return D=oc(D,U.mode,V),D.return=U,D;case J:var ee=D._init;return D=ee(D._payload),ne(U,D,V)}if(fe(D)||Ee(D))return D=yr(D,U.mode,V,null),D.return=U,D;if(typeof D.then=="function")return ne(U,os(D),V);if(D.$$typeof===k)return ne(U,Xo(U,D),V);ss(U,D)}return null}function F(U,D,V,ee){var ve=D!==null?D.key:null;if(typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint")return ve!==null?null:E(U,D,""+V,ee);if(typeof V=="object"&&V!==null){switch(V.$$typeof){case S:return V.key===ve?j(U,D,V,ee):null;case w:return V.key===ve?q(U,D,V,ee):null;case J:return ve=V._init,V=ve(V._payload),F(U,D,V,ee)}if(fe(V)||Ee(V))return ve!==null?null:I(U,D,V,ee,null);if(typeof V.then=="function")return F(U,D,os(V),ee);if(V.$$typeof===k)return F(U,D,Xo(U,V),ee);ss(U,V)}return null}function X(U,D,V,ee,ve){if(typeof ee=="string"&&ee!==""||typeof ee=="number"||typeof ee=="bigint")return U=U.get(V)||null,E(D,U,""+ee,ve);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case S:return U=U.get(ee.key===null?V:ee.key)||null,j(D,U,ee,ve);case w:return U=U.get(ee.key===null?V:ee.key)||null,q(D,U,ee,ve);case J:var Ge=ee._init;return ee=Ge(ee._payload),X(U,D,V,ee,ve)}if(fe(ee)||Ee(ee))return U=U.get(V)||null,I(D,U,ee,ve,null);if(typeof ee.then=="function")return X(U,D,V,os(ee),ve);if(ee.$$typeof===k)return X(U,D,V,Xo(D,ee),ve);ss(D,ee)}return null}function ke(U,D,V,ee){for(var ve=null,Ge=null,Ae=D,Le=D=0,Dt=null;Ae!==null&&Le<V.length;Le++){Ae.index>Le?(Dt=Ae,Ae=null):Dt=Ae.sibling;var Ie=F(U,Ae,V[Le],ee);if(Ie===null){Ae===null&&(Ae=Dt);break}e&&Ae&&Ie.alternate===null&&t(U,Ae),D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie,Ae=Dt}if(Le===V.length)return r(U,Ae),We&&xr(U,Le),ve;if(Ae===null){for(;Le<V.length;Le++)Ae=ne(U,V[Le],ee),Ae!==null&&(D=d(Ae,D,Le),Ge===null?ve=Ae:Ge.sibling=Ae,Ge=Ae);return We&&xr(U,Le),ve}for(Ae=o(Ae);Le<V.length;Le++)Dt=X(Ae,U,Le,V[Le],ee),Dt!==null&&(e&&Dt.alternate!==null&&Ae.delete(Dt.key===null?Le:Dt.key),D=d(Dt,D,Le),Ge===null?ve=Dt:Ge.sibling=Dt,Ge=Dt);return e&&Ae.forEach(function(Xa){return t(U,Xa)}),We&&xr(U,Le),ve}function De(U,D,V,ee){if(V==null)throw Error(i(151));for(var ve=null,Ge=null,Ae=D,Le=D=0,Dt=null,Ie=V.next();Ae!==null&&!Ie.done;Le++,Ie=V.next()){Ae.index>Le?(Dt=Ae,Ae=null):Dt=Ae.sibling;var Xa=F(U,Ae,Ie.value,ee);if(Xa===null){Ae===null&&(Ae=Dt);break}e&&Ae&&Xa.alternate===null&&t(U,Ae),D=d(Xa,D,Le),Ge===null?ve=Xa:Ge.sibling=Xa,Ge=Xa,Ae=Dt}if(Ie.done)return r(U,Ae),We&&xr(U,Le),ve;if(Ae===null){for(;!Ie.done;Le++,Ie=V.next())Ie=ne(U,Ie.value,ee),Ie!==null&&(D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie);return We&&xr(U,Le),ve}for(Ae=o(Ae);!Ie.done;Le++,Ie=V.next())Ie=X(Ae,U,Le,Ie.value,ee),Ie!==null&&(e&&Ie.alternate!==null&&Ae.delete(Ie.key===null?Le:Ie.key),D=d(Ie,D,Le),Ge===null?ve=Ie:Ge.sibling=Ie,Ge=Ie);return e&&Ae.forEach(function(AS){return t(U,AS)}),We&&xr(U,Le),ve}function it(U,D,V,ee){if(typeof V=="object"&&V!==null&&V.type===C&&V.key===null&&(V=V.props.children),typeof V=="object"&&V!==null){switch(V.$$typeof){case S:e:{for(var ve=V.key;D!==null;){if(D.key===ve){if(ve=V.type,ve===C){if(D.tag===7){r(U,D.sibling),ee=c(D,V.props.children),ee.return=U,U=ee;break e}}else if(D.elementType===ve||typeof ve=="object"&&ve!==null&&ve.$$typeof===J&&lp(ve)===D.type){r(U,D.sibling),ee=c(D,V.props),ji(ee,V),ee.return=U,U=ee;break e}r(U,D);break}else t(U,D);D=D.sibling}V.type===C?(ee=yr(V.props.children,U.mode,ee,V.key),ee.return=U,U=ee):(ee=Yo(V.type,V.key,V.props,null,U.mode,ee),ji(ee,V),ee.return=U,U=ee)}return b(U);case w:e:{for(ve=V.key;D!==null;){if(D.key===ve)if(D.tag===4&&D.stateNode.containerInfo===V.containerInfo&&D.stateNode.implementation===V.implementation){r(U,D.sibling),ee=c(D,V.children||[]),ee.return=U,U=ee;break e}else{r(U,D);break}else t(U,D);D=D.sibling}ee=oc(V,U.mode,ee),ee.return=U,U=ee}return b(U);case J:return ve=V._init,V=ve(V._payload),it(U,D,V,ee)}if(fe(V))return ke(U,D,V,ee);if(Ee(V)){if(ve=Ee(V),typeof ve!="function")throw Error(i(150));return V=ve.call(V),De(U,D,V,ee)}if(typeof V.then=="function")return it(U,D,os(V),ee);if(V.$$typeof===k)return it(U,D,Xo(U,V),ee);ss(U,V)}return typeof V=="string"&&V!==""||typeof V=="number"||typeof V=="bigint"?(V=""+V,D!==null&&D.tag===6?(r(U,D.sibling),ee=c(D,V),ee.return=U,U=ee):(r(U,D),ee=ic(V,U.mode,ee),ee.return=U,U=ee),b(U)):r(U,D)}return function(U,D,V,ee){try{Ti=0;var ve=it(U,D,V,ee);return dl=null,ve}catch(Ae){if(Ae===xi||Ae===Zo)throw Ae;var Ge=Wt(29,Ae,null,U.mode);return Ge.lanes=ee,Ge.return=U,Ge}finally{}}}var hl=ip(!0),op=ip(!1),xn=Y(null),Pn=null;function Da(e){var t=e.alternate;K(Tt,Tt.current&1),K(xn,e),Pn===null&&(t===null||sl.current!==null||t.memoizedState!==null)&&(Pn=e)}function sp(e){if(e.tag===22){if(K(Tt,Tt.current),K(xn,e),Pn===null){var t=e.alternate;t!==null&&t.memoizedState!==null&&(Pn=e)}}else La()}function La(){K(Tt,Tt.current),K(xn,xn.current)}function ua(e){L(xn),Pn===e&&(Pn=null),L(Tt)}var Tt=Y(0);function us(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||jf(r)))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&128)!==0)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}function Bc(e,t,r,o){t=e.memoizedState,r=r(o,t),r=r==null?t:g({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var $c={enqueueSetState:function(e,t,r){e=e._reactInternals;var o=an(),c=ja(o);c.payload=t,r!=null&&(c.callback=r),t=Ma(e,c,o),t!==null&&(rn(t,e,o),wi(t,e,o))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var o=an(),c=ja(o);c.tag=1,c.payload=t,r!=null&&(c.callback=r),t=Ma(e,c,o),t!==null&&(rn(t,e,o),wi(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=an(),o=ja(r);o.tag=2,t!=null&&(o.callback=t),t=Ma(e,o,r),t!==null&&(rn(t,e,r),wi(t,e,r))}};function up(e,t,r,o,c,d,b){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(o,d,b):t.prototype&&t.prototype.isPureReactComponent?!di(r,o)||!di(c,d):!0}function cp(e,t,r,o){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,o),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,o),t.state!==e&&$c.enqueueReplaceState(t,t.state,null)}function Ar(e,t){var r=t;if("ref"in t){r={};for(var o in t)o!=="ref"&&(r[o]=t[o])}if(e=e.defaultProps){r===t&&(r=g({},r));for(var c in e)r[c]===void 0&&(r[c]=e[c])}return r}var cs=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function fp(e){cs(e)}function dp(e){console.error(e)}function hp(e){cs(e)}function fs(e,t){try{var r=e.onUncaughtError;r(t.value,{componentStack:t.stack})}catch(o){setTimeout(function(){throw o})}}function mp(e,t,r){try{var o=e.onCaughtError;o(r.value,{componentStack:r.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(c){setTimeout(function(){throw c})}}function Vc(e,t,r){return r=ja(r),r.tag=3,r.payload={element:null},r.callback=function(){fs(e,t)},r}function pp(e){return e=ja(e),e.tag=3,e}function gp(e,t,r,o){var c=r.type.getDerivedStateFromError;if(typeof c=="function"){var d=o.value;e.payload=function(){return c(d)},e.callback=function(){mp(t,r,o)}}var b=r.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(e.callback=function(){mp(t,r,o),typeof c!="function"&&(Ba===null?Ba=new Set([this]):Ba.add(this));var E=o.stack;this.componentDidCatch(o.value,{componentStack:E!==null?E:""})})}function A1(e,t,r,o,c){if(r.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(t=r.alternate,t!==null&&vi(t,r,c,!0),r=xn.current,r!==null){switch(r.tag){case 13:return Pn===null?hf():r.alternate===null&&xt===0&&(xt=3),r.flags&=-257,r.flags|=65536,r.lanes=c,o===vc?r.flags|=16384:(t=r.updateQueue,t===null?r.updateQueue=new Set([o]):t.add(o),pf(e,o,c)),!1;case 22:return r.flags|=65536,o===vc?r.flags|=16384:(t=r.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([o])},r.updateQueue=t):(r=t.retryQueue,r===null?t.retryQueue=new Set([o]):r.add(o)),pf(e,o,c)),!1}throw Error(i(435,r.tag))}return pf(e,o,c),hf(),!1}if(We)return t=xn.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=c,o!==cc&&(e=Error(i(422),{cause:o}),gi(gn(e,r)))):(o!==cc&&(t=Error(i(423),{cause:o}),gi(gn(t,r))),e=e.current.alternate,e.flags|=65536,c&=-c,e.lanes|=c,o=gn(o,r),c=Vc(e.stateNode,o,c),xc(e,c),xt!==4&&(xt=2)),!1;var d=Error(i(520),{cause:o});if(d=gn(d,r),Ui===null?Ui=[d]:Ui.push(d),xt!==4&&(xt=2),t===null)return!0;o=gn(o,r),r=t;do{switch(r.tag){case 3:return r.flags|=65536,e=c&-c,r.lanes|=e,e=Vc(r.stateNode,o,e),xc(r,e),!1;case 1:if(t=r.type,d=r.stateNode,(r.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(Ba===null||!Ba.has(d))))return r.flags|=65536,c&=-c,r.lanes|=c,c=pp(c),gp(c,e,r,o),xc(r,c),!1}r=r.return}while(r!==null);return!1}var vp=Error(i(461)),Mt=!1;function zt(e,t,r,o){t.child=e===null?op(t,null,r,o):hl(t,e.child,r,o)}function yp(e,t,r,o,c){r=r.render;var d=t.ref;if("ref"in o){var b={};for(var E in o)E!=="ref"&&(b[E]=o[E])}else b=o;return Rr(t),o=Cc(e,t,r,b,d,c),E=Oc(),e!==null&&!Mt?(Ac(e,t,c),ca(e,t,c)):(We&&E&&sc(t),t.flags|=1,zt(e,t,o,c),t.child)}function bp(e,t,r,o,c){if(e===null){var d=r.type;return typeof d=="function"&&!lc(d)&&d.defaultProps===void 0&&r.compare===null?(t.tag=15,t.type=d,xp(e,t,d,o,c)):(e=Yo(r.type,null,o,t,t.mode,c),e.ref=t.ref,e.return=t,t.child=e)}if(d=e.child,!Zc(e,c)){var b=d.memoizedProps;if(r=r.compare,r=r!==null?r:di,r(b,o)&&e.ref===t.ref)return ca(e,t,c)}return t.flags|=1,e=aa(d,o),e.ref=t.ref,e.return=t,t.child=e}function xp(e,t,r,o,c){if(e!==null){var d=e.memoizedProps;if(di(d,o)&&e.ref===t.ref)if(Mt=!1,t.pendingProps=o=d,Zc(e,c))(e.flags&131072)!==0&&(Mt=!0);else return t.lanes=e.lanes,ca(e,t,c)}return qc(e,t,r,o,c)}function Sp(e,t,r){var o=t.pendingProps,c=o.children,d=e!==null?e.memoizedState:null;if(o.mode==="hidden"){if((t.flags&128)!==0){if(o=d!==null?d.baseLanes|r:r,e!==null){for(c=t.child=e.child,d=0;c!==null;)d=d|c.lanes|c.childLanes,c=c.sibling;t.childLanes=d&~o}else t.childLanes=0,t.child=null;return wp(e,t,o,r)}if((r&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Qo(t,d!==null?d.cachePool:null),d!==null?xm(t,d):wc(),sp(t);else return t.lanes=t.childLanes=536870912,wp(e,t,d!==null?d.baseLanes|r:r,r)}else d!==null?(Qo(t,d.cachePool),xm(t,d),La(),t.memoizedState=null):(e!==null&&Qo(t,null),wc(),La());return zt(e,t,c,r),t.child}function wp(e,t,r,o){var c=gc();return c=c===null?null:{parent:Nt._currentValue,pool:c},t.memoizedState={baseLanes:r,cachePool:c},e!==null&&Qo(t,null),wc(),sp(t),e!==null&&vi(e,t,o,!0),null}function ds(e,t){var r=t.ref;if(r===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof r!="function"&&typeof r!="object")throw Error(i(284));(e===null||e.ref!==r)&&(t.flags|=4194816)}}function qc(e,t,r,o,c){return Rr(t),r=Cc(e,t,r,o,void 0,c),o=Oc(),e!==null&&!Mt?(Ac(e,t,c),ca(e,t,c)):(We&&o&&sc(t),t.flags|=1,zt(e,t,r,c),t.child)}function Ep(e,t,r,o,c,d){return Rr(t),t.updateQueue=null,r=wm(t,o,r,c),Sm(e),o=Oc(),e!==null&&!Mt?(Ac(e,t,d),ca(e,t,d)):(We&&o&&sc(t),t.flags|=1,zt(e,t,r,d),t.child)}function Rp(e,t,r,o,c){if(Rr(t),t.stateNode===null){var d=al,b=r.contextType;typeof b=="object"&&b!==null&&(d=Ht(b)),d=new r(o,d),t.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=$c,t.stateNode=d,d._reactInternals=t,d=t.stateNode,d.props=o,d.state=t.memoizedState,d.refs={},yc(t),b=r.contextType,d.context=typeof b=="object"&&b!==null?Ht(b):al,d.state=t.memoizedState,b=r.getDerivedStateFromProps,typeof b=="function"&&(Bc(t,r,b,o),d.state=t.memoizedState),typeof r.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(b=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),b!==d.state&&$c.enqueueReplaceState(d,d.state,null),Ri(t,o,d,c),Ei(),d.state=t.memoizedState),typeof d.componentDidMount=="function"&&(t.flags|=4194308),o=!0}else if(e===null){d=t.stateNode;var E=t.memoizedProps,j=Ar(r,E);d.props=j;var q=d.context,I=r.contextType;b=al,typeof I=="object"&&I!==null&&(b=Ht(I));var ne=r.getDerivedStateFromProps;I=typeof ne=="function"||typeof d.getSnapshotBeforeUpdate=="function",E=t.pendingProps!==E,I||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(E||q!==b)&&cp(t,d,o,b),Ta=!1;var F=t.memoizedState;d.state=F,Ri(t,o,d,c),Ei(),q=t.memoizedState,E||F!==q||Ta?(typeof ne=="function"&&(Bc(t,r,ne,o),q=t.memoizedState),(j=Ta||up(t,r,j,o,F,q,b))?(I||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount()),typeof d.componentDidMount=="function"&&(t.flags|=4194308)):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=o,t.memoizedState=q),d.props=o,d.state=q,d.context=b,o=j):(typeof d.componentDidMount=="function"&&(t.flags|=4194308),o=!1)}else{d=t.stateNode,bc(e,t),b=t.memoizedProps,I=Ar(r,b),d.props=I,ne=t.pendingProps,F=d.context,q=r.contextType,j=al,typeof q=="object"&&q!==null&&(j=Ht(q)),E=r.getDerivedStateFromProps,(q=typeof E=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(b!==ne||F!==j)&&cp(t,d,o,j),Ta=!1,F=t.memoizedState,d.state=F,Ri(t,o,d,c),Ei();var X=t.memoizedState;b!==ne||F!==X||Ta||e!==null&&e.dependencies!==null&&Fo(e.dependencies)?(typeof E=="function"&&(Bc(t,r,E,o),X=t.memoizedState),(I=Ta||up(t,r,I,o,F,X,j)||e!==null&&e.dependencies!==null&&Fo(e.dependencies))?(q||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(o,X,j),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(o,X,j)),typeof d.componentDidUpdate=="function"&&(t.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=1024),t.memoizedProps=o,t.memoizedState=X),d.props=o,d.state=X,d.context=j,o=I):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&F===e.memoizedState||(t.flags|=1024),o=!1)}return d=o,ds(e,t),o=(t.flags&128)!==0,d||o?(d=t.stateNode,r=o&&typeof r.getDerivedStateFromError!="function"?null:d.render(),t.flags|=1,e!==null&&o?(t.child=hl(t,e.child,null,c),t.child=hl(t,null,r,c)):zt(e,t,r,c),t.memoizedState=d.state,e=t.child):e=ca(e,t,c),e}function Cp(e,t,r,o){return pi(),t.flags|=256,zt(e,t,r,o),t.child}var Yc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Kc(e){return{baseLanes:e,cachePool:dm()}}function Gc(e,t,r){return e=e!==null?e.childLanes&~r:0,t&&(e|=Sn),e}function Op(e,t,r){var o=t.pendingProps,c=!1,d=(t.flags&128)!==0,b;if((b=d)||(b=e!==null&&e.memoizedState===null?!1:(Tt.current&2)!==0),b&&(c=!0,t.flags&=-129),b=(t.flags&32)!==0,t.flags&=-33,e===null){if(We){if(c?Da(t):La(),We){var E=bt,j;if(j=E){e:{for(j=E,E=Un;j.nodeType!==8;){if(!E){E=null;break e}if(j=Tn(j.nextSibling),j===null){E=null;break e}}E=j}E!==null?(t.memoizedState={dehydrated:E,treeContext:br!==null?{id:ra,overflow:la}:null,retryLane:536870912,hydrationErrors:null},j=Wt(18,null,null,0),j.stateNode=E,j.return=t,t.child=j,qt=t,bt=null,j=!0):j=!1}j||wr(t)}if(E=t.memoizedState,E!==null&&(E=E.dehydrated,E!==null))return jf(E)?t.lanes=32:t.lanes=536870912,null;ua(t)}return E=o.children,o=o.fallback,c?(La(),c=t.mode,E=hs({mode:"hidden",children:E},c),o=yr(o,c,r,null),E.return=t,o.return=t,E.sibling=o,t.child=E,c=t.child,c.memoizedState=Kc(r),c.childLanes=Gc(e,b,r),t.memoizedState=Yc,o):(Da(t),Fc(t,E))}if(j=e.memoizedState,j!==null&&(E=j.dehydrated,E!==null)){if(d)t.flags&256?(Da(t),t.flags&=-257,t=Xc(e,t,r)):t.memoizedState!==null?(La(),t.child=e.child,t.flags|=128,t=null):(La(),c=o.fallback,E=t.mode,o=hs({mode:"visible",children:o.children},E),c=yr(c,E,r,null),c.flags|=2,o.return=t,c.return=t,o.sibling=c,t.child=o,hl(t,e.child,null,r),o=t.child,o.memoizedState=Kc(r),o.childLanes=Gc(e,b,r),t.memoizedState=Yc,t=c);else if(Da(t),jf(E)){if(b=E.nextSibling&&E.nextSibling.dataset,b)var q=b.dgst;b=q,o=Error(i(419)),o.stack="",o.digest=b,gi({value:o,source:null,stack:null}),t=Xc(e,t,r)}else if(Mt||vi(e,t,r,!1),b=(r&e.childLanes)!==0,Mt||b){if(b=ut,b!==null&&(o=r&-r,o=(o&42)!==0?1:ai(o),o=(o&(b.suspendedLanes|r))!==0?0:o,o!==0&&o!==j.retryLane))throw j.retryLane=o,nl(e,o),rn(b,e,o),vp;E.data==="$?"||hf(),t=Xc(e,t,r)}else E.data==="$?"?(t.flags|=192,t.child=e.child,t=null):(e=j.treeContext,bt=Tn(E.nextSibling),qt=t,We=!0,Sr=null,Un=!1,e!==null&&(yn[bn++]=ra,yn[bn++]=la,yn[bn++]=br,ra=e.id,la=e.overflow,br=t),t=Fc(t,o.children),t.flags|=4096);return t}return c?(La(),c=o.fallback,E=t.mode,j=e.child,q=j.sibling,o=aa(j,{mode:"hidden",children:o.children}),o.subtreeFlags=j.subtreeFlags&65011712,q!==null?c=aa(q,c):(c=yr(c,E,r,null),c.flags|=2),c.return=t,o.return=t,o.sibling=c,t.child=o,o=c,c=t.child,E=e.child.memoizedState,E===null?E=Kc(r):(j=E.cachePool,j!==null?(q=Nt._currentValue,j=j.parent!==q?{parent:q,pool:q}:j):j=dm(),E={baseLanes:E.baseLanes|r,cachePool:j}),c.memoizedState=E,c.childLanes=Gc(e,b,r),t.memoizedState=Yc,o):(Da(t),r=e.child,e=r.sibling,r=aa(r,{mode:"visible",children:o.children}),r.return=t,r.sibling=null,e!==null&&(b=t.deletions,b===null?(t.deletions=[e],t.flags|=16):b.push(e)),t.child=r,t.memoizedState=null,r)}function Fc(e,t){return t=hs({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function hs(e,t){return e=Wt(22,e,null,t),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Xc(e,t,r){return hl(t,e.child,null,r),e=Fc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Ap(e,t,r){e.lanes|=t;var o=e.alternate;o!==null&&(o.lanes|=t),dc(e.return,t,r)}function Qc(e,t,r,o,c){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:o,tail:r,tailMode:c}:(d.isBackwards=t,d.rendering=null,d.renderingStartTime=0,d.last=o,d.tail=r,d.tailMode=c)}function Np(e,t,r){var o=t.pendingProps,c=o.revealOrder,d=o.tail;if(zt(e,t,o.children,r),o=Tt.current,(o&2)!==0)o=o&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ap(e,r,t);else if(e.tag===19)Ap(e,r,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}o&=1}switch(K(Tt,o),c){case"forwards":for(r=t.child,c=null;r!==null;)e=r.alternate,e!==null&&us(e)===null&&(c=r),r=r.sibling;r=c,r===null?(c=t.child,t.child=null):(c=r.sibling,r.sibling=null),Qc(t,!1,c,r,d);break;case"backwards":for(r=null,c=t.child,t.child=null;c!==null;){if(e=c.alternate,e!==null&&us(e)===null){t.child=c;break}e=c.sibling,c.sibling=r,r=c,c=e}Qc(t,!0,r,null,d);break;case"together":Qc(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ca(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),Ha|=t.lanes,(r&t.childLanes)===0)if(e!==null){if(vi(e,t,r,!1),(r&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,r=aa(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=aa(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function Zc(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Fo(e)))}function N1(e,t,r){switch(t.tag){case 3:ze(t,t.stateNode.containerInfo),Na(t,Nt,e.memoizedState.cache),pi();break;case 27:case 5:je(t);break;case 4:ze(t,t.stateNode.containerInfo);break;case 10:Na(t,t.type,t.memoizedProps.value);break;case 13:var o=t.memoizedState;if(o!==null)return o.dehydrated!==null?(Da(t),t.flags|=128,null):(r&t.child.childLanes)!==0?Op(e,t,r):(Da(t),e=ca(e,t,r),e!==null?e.sibling:null);Da(t);break;case 19:var c=(e.flags&128)!==0;if(o=(r&t.childLanes)!==0,o||(vi(e,t,r,!1),o=(r&t.childLanes)!==0),c){if(o)return Np(e,t,r);t.flags|=128}if(c=t.memoizedState,c!==null&&(c.rendering=null,c.tail=null,c.lastEffect=null),K(Tt,Tt.current),o)break;return null;case 22:case 23:return t.lanes=0,Sp(e,t,r);case 24:Na(t,Nt,e.memoizedState.cache)}return ca(e,t,r)}function Tp(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps)Mt=!0;else{if(!Zc(e,r)&&(t.flags&128)===0)return Mt=!1,N1(e,t,r);Mt=(e.flags&131072)!==0}else Mt=!1,We&&(t.flags&1048576)!==0&&lm(t,Go,t.index);switch(t.lanes=0,t.tag){case 16:e:{e=t.pendingProps;var o=t.elementType,c=o._init;if(o=c(o._payload),t.type=o,typeof o=="function")lc(o)?(e=Ar(o,e),t.tag=1,t=Rp(null,t,o,e,r)):(t.tag=0,t=qc(null,t,o,e,r));else{if(o!=null){if(c=o.$$typeof,c===H){t.tag=11,t=yp(null,t,o,e,r);break e}else if(c===G){t.tag=14,t=bp(null,t,o,e,r);break e}}throw t=he(o)||o,Error(i(306,t,""))}}return t;case 0:return qc(e,t,t.type,t.pendingProps,r);case 1:return o=t.type,c=Ar(o,t.pendingProps),Rp(e,t,o,c,r);case 3:e:{if(ze(t,t.stateNode.containerInfo),e===null)throw Error(i(387));o=t.pendingProps;var d=t.memoizedState;c=d.element,bc(e,t),Ri(t,o,null,r);var b=t.memoizedState;if(o=b.cache,Na(t,Nt,o),o!==d.cache&&hc(t,[Nt],r,!0),Ei(),o=b.element,d.isDehydrated)if(d={element:o,isDehydrated:!1,cache:b.cache},t.updateQueue.baseState=d,t.memoizedState=d,t.flags&256){t=Cp(e,t,o,r);break e}else if(o!==c){c=gn(Error(i(424)),t),gi(c),t=Cp(e,t,o,r);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(bt=Tn(e.firstChild),qt=t,We=!0,Sr=null,Un=!0,r=op(t,null,o,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling}else{if(pi(),o===c){t=ca(e,t,r);break e}zt(e,t,o,r)}t=t.child}return t;case 26:return ds(e,t),e===null?(r=Dg(t.type,null,t.pendingProps,null))?t.memoizedState=r:We||(r=t.type,e=t.pendingProps,o=As(de.current).createElement(r),o[le]=t,o[ce]=e,Ut(o,r,e),Be(o),t.stateNode=o):t.memoizedState=Dg(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return je(t),e===null&&We&&(o=t.stateNode=jg(t.type,t.pendingProps,de.current),qt=t,Un=!0,c=bt,qa(t.type)?(Mf=c,bt=Tn(o.firstChild)):bt=c),zt(e,t,t.pendingProps.children,r),ds(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&We&&((c=o=bt)&&(o=nS(o,t.type,t.pendingProps,Un),o!==null?(t.stateNode=o,qt=t,bt=Tn(o.firstChild),Un=!1,c=!0):c=!1),c||wr(t)),je(t),c=t.type,d=t.pendingProps,b=e!==null?e.memoizedProps:null,o=d.children,Af(c,d)?o=null:b!==null&&Af(c,b)&&(t.flags|=32),t.memoizedState!==null&&(c=Cc(e,t,x1,null,null,r),Gi._currentValue=c),ds(e,t),zt(e,t,o,r),t.child;case 6:return e===null&&We&&((e=r=bt)&&(r=aS(r,t.pendingProps,Un),r!==null?(t.stateNode=r,qt=t,bt=null,e=!0):e=!1),e||wr(t)),null;case 13:return Op(e,t,r);case 4:return ze(t,t.stateNode.containerInfo),o=t.pendingProps,e===null?t.child=hl(t,null,o,r):zt(e,t,o,r),t.child;case 11:return yp(e,t,t.type,t.pendingProps,r);case 7:return zt(e,t,t.pendingProps,r),t.child;case 8:return zt(e,t,t.pendingProps.children,r),t.child;case 12:return zt(e,t,t.pendingProps.children,r),t.child;case 10:return o=t.pendingProps,Na(t,t.type,o.value),zt(e,t,o.children,r),t.child;case 9:return c=t.type._context,o=t.pendingProps.children,Rr(t),c=Ht(c),o=o(c),t.flags|=1,zt(e,t,o,r),t.child;case 14:return bp(e,t,t.type,t.pendingProps,r);case 15:return xp(e,t,t.type,t.pendingProps,r);case 19:return Np(e,t,r);case 31:return o=t.pendingProps,r=t.mode,o={mode:o.mode,children:o.children},e===null?(r=hs(o,r),r.ref=t.ref,t.child=r,r.return=t,t=r):(r=aa(e.child,o),r.ref=t.ref,t.child=r,r.return=t,t=r),t;case 22:return Sp(e,t,r);case 24:return Rr(t),o=Ht(Nt),e===null?(c=gc(),c===null&&(c=ut,d=mc(),c.pooledCache=d,d.refCount++,d!==null&&(c.pooledCacheLanes|=r),c=d),t.memoizedState={parent:o,cache:c},yc(t),Na(t,Nt,c)):((e.lanes&r)!==0&&(bc(e,t),Ri(t,null,null,r),Ei()),c=e.memoizedState,d=t.memoizedState,c.parent!==o?(c={parent:o,cache:o},t.memoizedState=c,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=c),Na(t,Nt,o)):(o=d.cache,Na(t,Nt,o),o!==c.cache&&hc(t,[Nt],r,!0))),zt(e,t,t.pendingProps.children,r),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function fa(e){e.flags|=4}function jp(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Pg(t)){if(t=xn.current,t!==null&&((Je&4194048)===Je?Pn!==null:(Je&62914560)!==Je&&(Je&536870912)===0||t!==Pn))throw Si=vc,hm;e.flags|=8192}}function ms(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?No():536870912,e.lanes|=t,vl|=t)}function Mi(e,t){if(!We)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var o=null;r!==null;)r.alternate!==null&&(o=r),r=r.sibling;o===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:o.sibling=null}}function gt(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,o=0;if(t)for(var c=e.child;c!==null;)r|=c.lanes|c.childLanes,o|=c.subtreeFlags&65011712,o|=c.flags&65011712,c.return=e,c=c.sibling;else for(c=e.child;c!==null;)r|=c.lanes|c.childLanes,o|=c.subtreeFlags,o|=c.flags,c.return=e,c=c.sibling;return e.subtreeFlags|=o,e.childLanes=r,t}function T1(e,t,r){var o=t.pendingProps;switch(uc(t),t.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return gt(t),null;case 1:return gt(t),null;case 3:return r=t.stateNode,o=null,e!==null&&(o=e.memoizedState.cache),t.memoizedState.cache!==o&&(t.flags|=2048),oa(Nt),Ze(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(mi(t)?fa(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,sm())),gt(t),null;case 26:return r=t.memoizedState,e===null?(fa(t),r!==null?(gt(t),jp(t,r)):(gt(t),t.flags&=-16777217)):r?r!==e.memoizedState?(fa(t),gt(t),jp(t,r)):(gt(t),t.flags&=-16777217):(e.memoizedProps!==o&&fa(t),gt(t),t.flags&=-16777217),null;case 27:ae(t),r=de.current;var c=t.type;if(e!==null&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(!o){if(t.stateNode===null)throw Error(i(166));return gt(t),null}e=W.current,mi(t)?im(t):(e=jg(c,o,r),t.stateNode=e,fa(t))}return gt(t),null;case 5:if(ae(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(!o){if(t.stateNode===null)throw Error(i(166));return gt(t),null}if(e=W.current,mi(t))im(t);else{switch(c=As(de.current),e){case 1:e=c.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:e=c.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":e=c.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":e=c.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":e=c.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof o.is=="string"?c.createElement("select",{is:o.is}):c.createElement("select"),o.multiple?e.multiple=!0:o.size&&(e.size=o.size);break;default:e=typeof o.is=="string"?c.createElement(r,{is:o.is}):c.createElement(r)}}e[le]=t,e[ce]=o;e:for(c=t.child;c!==null;){if(c.tag===5||c.tag===6)e.appendChild(c.stateNode);else if(c.tag!==4&&c.tag!==27&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===t)break e;for(;c.sibling===null;){if(c.return===null||c.return===t)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}t.stateNode=e;e:switch(Ut(e,r,o),r){case"button":case"input":case"select":case"textarea":e=!!o.autoFocus;break e;case"img":e=!0;break e;default:e=!1}e&&fa(t)}}return gt(t),t.flags&=-16777217,null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==o&&fa(t);else{if(typeof o!="string"&&t.stateNode===null)throw Error(i(166));if(e=de.current,mi(t)){if(e=t.stateNode,r=t.memoizedProps,o=null,c=qt,c!==null)switch(c.tag){case 27:case 5:o=c.memoizedProps}e[le]=t,e=!!(e.nodeValue===r||o!==null&&o.suppressHydrationWarning===!0||Eg(e.nodeValue,r)),e||wr(t)}else e=As(e).createTextNode(o),e[le]=t,t.stateNode=e}return gt(t),null;case 13:if(o=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(c=mi(t),o!==null&&o.dehydrated!==null){if(e===null){if(!c)throw Error(i(318));if(c=t.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(i(317));c[le]=t}else pi(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;gt(t),c=!1}else c=sm(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=c),c=!0;if(!c)return t.flags&256?(ua(t),t):(ua(t),null)}if(ua(t),(t.flags&128)!==0)return t.lanes=r,t;if(r=o!==null,e=e!==null&&e.memoizedState!==null,r){o=t.child,c=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(c=o.alternate.memoizedState.cachePool.pool);var d=null;o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(d=o.memoizedState.cachePool.pool),d!==c&&(o.flags|=2048)}return r!==e&&r&&(t.child.flags|=8192),ms(t,t.updateQueue),gt(t),null;case 4:return Ze(),e===null&&wf(t.stateNode.containerInfo),gt(t),null;case 10:return oa(t.type),gt(t),null;case 19:if(L(Tt),c=t.memoizedState,c===null)return gt(t),null;if(o=(t.flags&128)!==0,d=c.rendering,d===null)if(o)Mi(c,!1);else{if(xt!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(d=us(e),d!==null){for(t.flags|=128,Mi(c,!1),e=d.updateQueue,t.updateQueue=e,ms(t,e),t.subtreeFlags=0,e=r,r=t.child;r!==null;)rm(r,e),r=r.sibling;return K(Tt,Tt.current&1|2),t.child}e=e.sibling}c.tail!==null&&Me()>vs&&(t.flags|=128,o=!0,Mi(c,!1),t.lanes=4194304)}else{if(!o)if(e=us(d),e!==null){if(t.flags|=128,o=!0,e=e.updateQueue,t.updateQueue=e,ms(t,e),Mi(c,!0),c.tail===null&&c.tailMode==="hidden"&&!d.alternate&&!We)return gt(t),null}else 2*Me()-c.renderingStartTime>vs&&r!==536870912&&(t.flags|=128,o=!0,Mi(c,!1),t.lanes=4194304);c.isBackwards?(d.sibling=t.child,t.child=d):(e=c.last,e!==null?e.sibling=d:t.child=d,c.last=d)}return c.tail!==null?(t=c.tail,c.rendering=t,c.tail=t.sibling,c.renderingStartTime=Me(),t.sibling=null,e=Tt.current,K(Tt,o?e&1|2:e&1),t):(gt(t),null);case 22:case 23:return ua(t),Ec(),o=t.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(t.flags|=8192):o&&(t.flags|=8192),o?(r&536870912)!==0&&(t.flags&128)===0&&(gt(t),t.subtreeFlags&6&&(t.flags|=8192)):gt(t),r=t.updateQueue,r!==null&&ms(t,r.retryQueue),r=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),o=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(o=t.memoizedState.cachePool.pool),o!==r&&(t.flags|=2048),e!==null&&L(Cr),null;case 24:return r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),oa(Nt),gt(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function j1(e,t){switch(uc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return oa(Nt),Ze(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ae(t),null;case 13:if(ua(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));pi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return L(Tt),null;case 4:return Ze(),null;case 10:return oa(t.type),null;case 22:case 23:return ua(t),Ec(),e!==null&&L(Cr),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return oa(Nt),null;case 25:return null;default:return null}}function Mp(e,t){switch(uc(t),t.tag){case 3:oa(Nt),Ze();break;case 26:case 27:case 5:ae(t);break;case 4:Ze();break;case 13:ua(t);break;case 19:L(Tt);break;case 10:oa(t.type);break;case 22:case 23:ua(t),Ec(),e!==null&&L(Cr);break;case 24:oa(Nt)}}function _i(e,t){try{var r=t.updateQueue,o=r!==null?r.lastEffect:null;if(o!==null){var c=o.next;r=c;do{if((r.tag&e)===e){o=void 0;var d=r.create,b=r.inst;o=d(),b.destroy=o}r=r.next}while(r!==c)}}catch(E){st(t,t.return,E)}}function za(e,t,r){try{var o=t.updateQueue,c=o!==null?o.lastEffect:null;if(c!==null){var d=c.next;o=d;do{if((o.tag&e)===e){var b=o.inst,E=b.destroy;if(E!==void 0){b.destroy=void 0,c=t;var j=r,q=E;try{q()}catch(I){st(c,j,I)}}}o=o.next}while(o!==d)}}catch(I){st(t,t.return,I)}}function _p(e){var t=e.updateQueue;if(t!==null){var r=e.stateNode;try{bm(t,r)}catch(o){st(e,e.return,o)}}}function Dp(e,t,r){r.props=Ar(e.type,e.memoizedProps),r.state=e.memoizedState;try{r.componentWillUnmount()}catch(o){st(e,t,o)}}function Di(e,t){try{var r=e.ref;if(r!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:o=e.stateNode;break;default:o=e.stateNode}typeof r=="function"?e.refCleanup=r(o):r.current=o}}catch(c){st(e,t,c)}}function Hn(e,t){var r=e.ref,o=e.refCleanup;if(r!==null)if(typeof o=="function")try{o()}catch(c){st(e,t,c)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof r=="function")try{r(null)}catch(c){st(e,t,c)}else r.current=null}function Lp(e){var t=e.type,r=e.memoizedProps,o=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":r.autoFocus&&o.focus();break e;case"img":r.src?o.src=r.src:r.srcSet&&(o.srcset=r.srcSet)}}catch(c){st(e,e.return,c)}}function Jc(e,t,r){try{var o=e.stateNode;J1(o,e.type,r,t),o[ce]=t}catch(c){st(e,e.return,c)}}function zp(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&qa(e.type)||e.tag===4}function Ic(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||zp(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&qa(e.type)||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 Wc(e,t,r){var o=e.tag;if(o===5||o===6)e=e.stateNode,t?(r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r).insertBefore(e,t):(t=r.nodeType===9?r.body:r.nodeName==="HTML"?r.ownerDocument.body:r,t.appendChild(e),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=Os));else if(o!==4&&(o===27&&qa(e.type)&&(r=e.stateNode,t=null),e=e.child,e!==null))for(Wc(e,t,r),e=e.sibling;e!==null;)Wc(e,t,r),e=e.sibling}function ps(e,t,r){var o=e.tag;if(o===5||o===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(o!==4&&(o===27&&qa(e.type)&&(r=e.stateNode),e=e.child,e!==null))for(ps(e,t,r),e=e.sibling;e!==null;)ps(e,t,r),e=e.sibling}function kp(e){var t=e.stateNode,r=e.memoizedProps;try{for(var o=e.type,c=t.attributes;c.length;)t.removeAttributeNode(c[0]);Ut(t,o,r),t[le]=e,t[ce]=r}catch(d){st(e,e.return,d)}}var da=!1,Et=!1,ef=!1,Up=typeof WeakSet=="function"?WeakSet:Set,_t=null;function M1(e,t){if(e=e.containerInfo,Cf=Ds,e=Xh(e),Iu(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var o=r.getSelection&&r.getSelection();if(o&&o.rangeCount!==0){r=o.anchorNode;var c=o.anchorOffset,d=o.focusNode;o=o.focusOffset;try{r.nodeType,d.nodeType}catch{r=null;break e}var b=0,E=-1,j=-1,q=0,I=0,ne=e,F=null;t:for(;;){for(var X;ne!==r||c!==0&&ne.nodeType!==3||(E=b+c),ne!==d||o!==0&&ne.nodeType!==3||(j=b+o),ne.nodeType===3&&(b+=ne.nodeValue.length),(X=ne.firstChild)!==null;)F=ne,ne=X;for(;;){if(ne===e)break t;if(F===r&&++q===c&&(E=b),F===d&&++I===o&&(j=b),(X=ne.nextSibling)!==null)break;ne=F,F=ne.parentNode}ne=X}r=E===-1||j===-1?null:{start:E,end:j}}else r=null}r=r||{start:0,end:0}}else r=null;for(Of={focusedElem:e,selectionRange:r},Ds=!1,_t=t;_t!==null;)if(t=_t,e=t.child,(t.subtreeFlags&1024)!==0&&e!==null)e.return=t,_t=e;else for(;_t!==null;){switch(t=_t,d=t.alternate,e=t.flags,t.tag){case 0:break;case 11:case 15:break;case 1:if((e&1024)!==0&&d!==null){e=void 0,r=t,c=d.memoizedProps,d=d.memoizedState,o=r.stateNode;try{var ke=Ar(r.type,c,r.elementType===r.type);e=o.getSnapshotBeforeUpdate(ke,d),o.__reactInternalSnapshotBeforeUpdate=e}catch(De){st(r,r.return,De)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,r=e.nodeType,r===9)Tf(e);else if(r===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Tf(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,_t=e;break}_t=t.return}}function Pp(e,t,r){var o=r.flags;switch(r.tag){case 0:case 11:case 15:ka(e,r),o&4&&_i(5,r);break;case 1:if(ka(e,r),o&4)if(e=r.stateNode,t===null)try{e.componentDidMount()}catch(b){st(r,r.return,b)}else{var c=Ar(r.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(c,t,e.__reactInternalSnapshotBeforeUpdate)}catch(b){st(r,r.return,b)}}o&64&&_p(r),o&512&&Di(r,r.return);break;case 3:if(ka(e,r),o&64&&(e=r.updateQueue,e!==null)){if(t=null,r.child!==null)switch(r.child.tag){case 27:case 5:t=r.child.stateNode;break;case 1:t=r.child.stateNode}try{bm(e,t)}catch(b){st(r,r.return,b)}}break;case 27:t===null&&o&4&&kp(r);case 26:case 5:ka(e,r),t===null&&o&4&&Lp(r),o&512&&Di(r,r.return);break;case 12:ka(e,r);break;case 13:ka(e,r),o&4&&$p(e,r),o&64&&(e=r.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(r=B1.bind(null,r),rS(e,r))));break;case 22:if(o=r.memoizedState!==null||da,!o){t=t!==null&&t.memoizedState!==null||Et,c=da;var d=Et;da=o,(Et=t)&&!d?Ua(e,r,(r.subtreeFlags&8772)!==0):ka(e,r),da=c,Et=d}break;case 30:break;default:ka(e,r)}}function Hp(e){var t=e.alternate;t!==null&&(e.alternate=null,Hp(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Ce(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ht=null,Ft=!1;function ha(e,t,r){for(r=r.child;r!==null;)Bp(e,t,r),r=r.sibling}function Bp(e,t,r){if(mt&&typeof mt.onCommitFiberUnmount=="function")try{mt.onCommitFiberUnmount(Yt,r)}catch{}switch(r.tag){case 26:Et||Hn(r,t),ha(e,t,r),r.memoizedState?r.memoizedState.count--:r.stateNode&&(r=r.stateNode,r.parentNode.removeChild(r));break;case 27:Et||Hn(r,t);var o=ht,c=Ft;qa(r.type)&&(ht=r.stateNode,Ft=!1),ha(e,t,r),Vi(r.stateNode),ht=o,Ft=c;break;case 5:Et||Hn(r,t);case 6:if(o=ht,c=Ft,ht=null,ha(e,t,r),ht=o,Ft=c,ht!==null)if(Ft)try{(ht.nodeType===9?ht.body:ht.nodeName==="HTML"?ht.ownerDocument.body:ht).removeChild(r.stateNode)}catch(d){st(r,t,d)}else try{ht.removeChild(r.stateNode)}catch(d){st(r,t,d)}break;case 18:ht!==null&&(Ft?(e=ht,Ng(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,r.stateNode),Zi(e)):Ng(ht,r.stateNode));break;case 4:o=ht,c=Ft,ht=r.stateNode.containerInfo,Ft=!0,ha(e,t,r),ht=o,Ft=c;break;case 0:case 11:case 14:case 15:Et||za(2,r,t),Et||za(4,r,t),ha(e,t,r);break;case 1:Et||(Hn(r,t),o=r.stateNode,typeof o.componentWillUnmount=="function"&&Dp(r,t,o)),ha(e,t,r);break;case 21:ha(e,t,r);break;case 22:Et=(o=Et)||r.memoizedState!==null,ha(e,t,r),Et=o;break;default:ha(e,t,r)}}function $p(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Zi(e)}catch(r){st(t,t.return,r)}}function _1(e){switch(e.tag){case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Up),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Up),t;default:throw Error(i(435,e.tag))}}function tf(e,t){var r=_1(e);t.forEach(function(o){var c=$1.bind(null,e,o);r.has(o)||(r.add(o),o.then(c,c))})}function en(e,t){var r=t.deletions;if(r!==null)for(var o=0;o<r.length;o++){var c=r[o],d=e,b=t,E=b;e:for(;E!==null;){switch(E.tag){case 27:if(qa(E.type)){ht=E.stateNode,Ft=!1;break e}break;case 5:ht=E.stateNode,Ft=!1;break e;case 3:case 4:ht=E.stateNode.containerInfo,Ft=!0;break e}E=E.return}if(ht===null)throw Error(i(160));Bp(d,b,c),ht=null,Ft=!1,d=c.alternate,d!==null&&(d.return=null),c.return=null}if(t.subtreeFlags&13878)for(t=t.child;t!==null;)Vp(t,e),t=t.sibling}var Nn=null;function Vp(e,t){var r=e.alternate,o=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:en(t,e),tn(e),o&4&&(za(3,e,e.return),_i(3,e),za(5,e,e.return));break;case 1:en(t,e),tn(e),o&512&&(Et||r===null||Hn(r,r.return)),o&64&&da&&(e=e.updateQueue,e!==null&&(o=e.callbacks,o!==null&&(r=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=r===null?o:r.concat(o))));break;case 26:var c=Nn;if(en(t,e),tn(e),o&512&&(Et||r===null||Hn(r,r.return)),o&4){var d=r!==null?r.memoizedState:null;if(o=e.memoizedState,r===null)if(o===null)if(e.stateNode===null){e:{o=e.type,r=e.memoizedProps,c=c.ownerDocument||c;t:switch(o){case"title":d=c.getElementsByTagName("title")[0],(!d||d[we]||d[le]||d.namespaceURI==="http://www.w3.org/2000/svg"||d.hasAttribute("itemprop"))&&(d=c.createElement(o),c.head.insertBefore(d,c.querySelector("head > title"))),Ut(d,o,r),d[le]=e,Be(d),o=d;break e;case"link":var b=kg("link","href",c).get(o+(r.href||""));if(b){for(var E=0;E<b.length;E++)if(d=b[E],d.getAttribute("href")===(r.href==null||r.href===""?null:r.href)&&d.getAttribute("rel")===(r.rel==null?null:r.rel)&&d.getAttribute("title")===(r.title==null?null:r.title)&&d.getAttribute("crossorigin")===(r.crossOrigin==null?null:r.crossOrigin)){b.splice(E,1);break t}}d=c.createElement(o),Ut(d,o,r),c.head.appendChild(d);break;case"meta":if(b=kg("meta","content",c).get(o+(r.content||""))){for(E=0;E<b.length;E++)if(d=b[E],d.getAttribute("content")===(r.content==null?null:""+r.content)&&d.getAttribute("name")===(r.name==null?null:r.name)&&d.getAttribute("property")===(r.property==null?null:r.property)&&d.getAttribute("http-equiv")===(r.httpEquiv==null?null:r.httpEquiv)&&d.getAttribute("charset")===(r.charSet==null?null:r.charSet)){b.splice(E,1);break t}}d=c.createElement(o),Ut(d,o,r),c.head.appendChild(d);break;default:throw Error(i(468,o))}d[le]=e,Be(d),o=d}e.stateNode=o}else Ug(c,e.type,e.stateNode);else e.stateNode=zg(c,o,e.memoizedProps);else d!==o?(d===null?r.stateNode!==null&&(r=r.stateNode,r.parentNode.removeChild(r)):d.count--,o===null?Ug(c,e.type,e.stateNode):zg(c,o,e.memoizedProps)):o===null&&e.stateNode!==null&&Jc(e,e.memoizedProps,r.memoizedProps)}break;case 27:en(t,e),tn(e),o&512&&(Et||r===null||Hn(r,r.return)),r!==null&&o&4&&Jc(e,e.memoizedProps,r.memoizedProps);break;case 5:if(en(t,e),tn(e),o&512&&(Et||r===null||Hn(r,r.return)),e.flags&32){c=e.stateNode;try{Qr(c,"")}catch(X){st(e,e.return,X)}}o&4&&e.stateNode!=null&&(c=e.memoizedProps,Jc(e,c,r!==null?r.memoizedProps:c)),o&1024&&(ef=!0);break;case 6:if(en(t,e),tn(e),o&4){if(e.stateNode===null)throw Error(i(162));o=e.memoizedProps,r=e.stateNode;try{r.nodeValue=o}catch(X){st(e,e.return,X)}}break;case 3:if(js=null,c=Nn,Nn=Ns(t.containerInfo),en(t,e),Nn=c,tn(e),o&4&&r!==null&&r.memoizedState.isDehydrated)try{Zi(t.containerInfo)}catch(X){st(e,e.return,X)}ef&&(ef=!1,qp(e));break;case 4:o=Nn,Nn=Ns(e.stateNode.containerInfo),en(t,e),tn(e),Nn=o;break;case 12:en(t,e),tn(e);break;case 13:en(t,e),tn(e),e.child.flags&8192&&e.memoizedState!==null!=(r!==null&&r.memoizedState!==null)&&(sf=Me()),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,tf(e,o)));break;case 22:c=e.memoizedState!==null;var j=r!==null&&r.memoizedState!==null,q=da,I=Et;if(da=q||c,Et=I||j,en(t,e),Et=I,da=q,tn(e),o&8192)e:for(t=e.stateNode,t._visibility=c?t._visibility&-2:t._visibility|1,c&&(r===null||j||da||Et||Nr(e)),r=null,t=e;;){if(t.tag===5||t.tag===26){if(r===null){j=r=t;try{if(d=j.stateNode,c)b=d.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none";else{E=j.stateNode;var ne=j.memoizedProps.style,F=ne!=null&&ne.hasOwnProperty("display")?ne.display:null;E.style.display=F==null||typeof F=="boolean"?"":(""+F).trim()}}catch(X){st(j,j.return,X)}}}else if(t.tag===6){if(r===null){j=t;try{j.stateNode.nodeValue=c?"":j.memoizedProps}catch(X){st(j,j.return,X)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;r===t&&(r=null),t=t.return}r===t&&(r=null),t.sibling.return=t.return,t=t.sibling}o&4&&(o=e.updateQueue,o!==null&&(r=o.retryQueue,r!==null&&(o.retryQueue=null,tf(e,r))));break;case 19:en(t,e),tn(e),o&4&&(o=e.updateQueue,o!==null&&(e.updateQueue=null,tf(e,o)));break;case 30:break;case 21:break;default:en(t,e),tn(e)}}function tn(e){var t=e.flags;if(t&2){try{for(var r,o=e.return;o!==null;){if(zp(o)){r=o;break}o=o.return}if(r==null)throw Error(i(160));switch(r.tag){case 27:var c=r.stateNode,d=Ic(e);ps(e,d,c);break;case 5:var b=r.stateNode;r.flags&32&&(Qr(b,""),r.flags&=-33);var E=Ic(e);ps(e,E,b);break;case 3:case 4:var j=r.stateNode.containerInfo,q=Ic(e);Wc(e,q,j);break;default:throw Error(i(161))}}catch(I){st(e,e.return,I)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function qp(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;qp(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ka(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Pp(e,t.alternate,t),t=t.sibling}function Nr(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:za(4,t,t.return),Nr(t);break;case 1:Hn(t,t.return);var r=t.stateNode;typeof r.componentWillUnmount=="function"&&Dp(t,t.return,r),Nr(t);break;case 27:Vi(t.stateNode);case 26:case 5:Hn(t,t.return),Nr(t);break;case 22:t.memoizedState===null&&Nr(t);break;case 30:Nr(t);break;default:Nr(t)}e=e.sibling}}function Ua(e,t,r){for(r=r&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var o=t.alternate,c=e,d=t,b=d.flags;switch(d.tag){case 0:case 11:case 15:Ua(c,d,r),_i(4,d);break;case 1:if(Ua(c,d,r),o=d,c=o.stateNode,typeof c.componentDidMount=="function")try{c.componentDidMount()}catch(q){st(o,o.return,q)}if(o=d,c=o.updateQueue,c!==null){var E=o.stateNode;try{var j=c.shared.hiddenCallbacks;if(j!==null)for(c.shared.hiddenCallbacks=null,c=0;c<j.length;c++)ym(j[c],E)}catch(q){st(o,o.return,q)}}r&&b&64&&_p(d),Di(d,d.return);break;case 27:kp(d);case 26:case 5:Ua(c,d,r),r&&o===null&&b&4&&Lp(d),Di(d,d.return);break;case 12:Ua(c,d,r);break;case 13:Ua(c,d,r),r&&b&4&&$p(c,d);break;case 22:d.memoizedState===null&&Ua(c,d,r),Di(d,d.return);break;case 30:break;default:Ua(c,d,r)}t=t.sibling}}function nf(e,t){var r=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(r=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==r&&(e!=null&&e.refCount++,r!=null&&yi(r))}function af(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yi(e))}function Bn(e,t,r,o){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Yp(e,t,r,o),t=t.sibling}function Yp(e,t,r,o){var c=t.flags;switch(t.tag){case 0:case 11:case 15:Bn(e,t,r,o),c&2048&&_i(9,t);break;case 1:Bn(e,t,r,o);break;case 3:Bn(e,t,r,o),c&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yi(e)));break;case 12:if(c&2048){Bn(e,t,r,o),e=t.stateNode;try{var d=t.memoizedProps,b=d.id,E=d.onPostCommit;typeof E=="function"&&E(b,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(j){st(t,t.return,j)}}else Bn(e,t,r,o);break;case 13:Bn(e,t,r,o);break;case 23:break;case 22:d=t.stateNode,b=t.alternate,t.memoizedState!==null?d._visibility&2?Bn(e,t,r,o):Li(e,t):d._visibility&2?Bn(e,t,r,o):(d._visibility|=2,ml(e,t,r,o,(t.subtreeFlags&10256)!==0)),c&2048&&nf(b,t);break;case 24:Bn(e,t,r,o),c&2048&&af(t.alternate,t);break;default:Bn(e,t,r,o)}}function ml(e,t,r,o,c){for(c=c&&(t.subtreeFlags&10256)!==0,t=t.child;t!==null;){var d=e,b=t,E=r,j=o,q=b.flags;switch(b.tag){case 0:case 11:case 15:ml(d,b,E,j,c),_i(8,b);break;case 23:break;case 22:var I=b.stateNode;b.memoizedState!==null?I._visibility&2?ml(d,b,E,j,c):Li(d,b):(I._visibility|=2,ml(d,b,E,j,c)),c&&q&2048&&nf(b.alternate,b);break;case 24:ml(d,b,E,j,c),c&&q&2048&&af(b.alternate,b);break;default:ml(d,b,E,j,c)}t=t.sibling}}function Li(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var r=e,o=t,c=o.flags;switch(o.tag){case 22:Li(r,o),c&2048&&nf(o.alternate,o);break;case 24:Li(r,o),c&2048&&af(o.alternate,o);break;default:Li(r,o)}t=t.sibling}}var zi=8192;function pl(e){if(e.subtreeFlags&zi)for(e=e.child;e!==null;)Kp(e),e=e.sibling}function Kp(e){switch(e.tag){case 26:pl(e),e.flags&zi&&e.memoizedState!==null&&vS(Nn,e.memoizedState,e.memoizedProps);break;case 5:pl(e);break;case 3:case 4:var t=Nn;Nn=Ns(e.stateNode.containerInfo),pl(e),Nn=t;break;case 22:e.memoizedState===null&&(t=e.alternate,t!==null&&t.memoizedState!==null?(t=zi,zi=16777216,pl(e),zi=t):pl(e));break;default:pl(e)}}function Gp(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function ki(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var r=0;r<t.length;r++){var o=t[r];_t=o,Xp(o,e)}Gp(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Fp(e),e=e.sibling}function Fp(e){switch(e.tag){case 0:case 11:case 15:ki(e),e.flags&2048&&za(9,e,e.return);break;case 3:ki(e);break;case 12:ki(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,gs(e)):ki(e);break;default:ki(e)}}function gs(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var r=0;r<t.length;r++){var o=t[r];_t=o,Xp(o,e)}Gp(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:za(8,t,t.return),gs(t);break;case 22:r=t.stateNode,r._visibility&2&&(r._visibility&=-3,gs(t));break;default:gs(t)}e=e.sibling}}function Xp(e,t){for(;_t!==null;){var r=_t;switch(r.tag){case 0:case 11:case 15:za(8,r,t);break;case 23:case 22:if(r.memoizedState!==null&&r.memoizedState.cachePool!==null){var o=r.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:yi(r.memoizedState.cache)}if(o=r.child,o!==null)o.return=r,_t=o;else e:for(r=e;_t!==null;){o=_t;var c=o.sibling,d=o.return;if(Hp(o),o===r){_t=null;break e}if(c!==null){c.return=d,_t=c;break e}_t=d}}}var D1={getCacheForType:function(e){var t=Ht(Nt),r=t.data.get(e);return r===void 0&&(r=e(),t.data.set(e,r)),r}},L1=typeof WeakMap=="function"?WeakMap:Map,tt=0,ut=null,Xe=null,Je=0,nt=0,nn=null,Pa=!1,gl=!1,rf=!1,ma=0,xt=0,Ha=0,Tr=0,lf=0,Sn=0,vl=0,Ui=null,Xt=null,of=!1,sf=0,vs=1/0,ys=null,Ba=null,kt=0,$a=null,yl=null,bl=0,uf=0,cf=null,Qp=null,Pi=0,ff=null;function an(){if((tt&2)!==0&&Je!==0)return Je&-Je;if(_.T!==null){var e=il;return e!==0?e:yf()}return M()}function Zp(){Sn===0&&(Sn=(Je&536870912)===0||We?Kr():536870912);var e=xn.current;return e!==null&&(e.flags|=32),Sn}function rn(e,t,r){(e===ut&&(nt===2||nt===9)||e.cancelPendingCommit!==null)&&(xl(e,0),Va(e,Je,Sn,!1)),fr(e,r),((tt&2)===0||e!==ut)&&(e===ut&&((tt&2)===0&&(Tr|=r),xt===4&&Va(e,Je,Sn,!1)),$n(e))}function Jp(e,t,r){if((tt&6)!==0)throw Error(i(327));var o=!r&&(t&124)===0&&(t&e.expiredLanes)===0||zn(e,t),c=o?U1(e,t):mf(e,t,!0),d=o;do{if(c===0){gl&&!o&&Va(e,t,0,!1);break}else{if(r=e.current.alternate,d&&!z1(r)){c=mf(e,t,!1),d=!1;continue}if(c===2){if(d=t,e.errorRecoveryDisabledLanes&d)var b=0;else b=e.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){t=b;e:{var E=e;c=Ui;var j=E.current.memoizedState.isDehydrated;if(j&&(xl(E,b).flags|=256),b=mf(E,b,!1),b!==2){if(rf&&!j){E.errorRecoveryDisabledLanes|=d,Tr|=d,c=4;break e}d=Xt,Xt=c,d!==null&&(Xt===null?Xt=d:Xt.push.apply(Xt,d))}c=b}if(d=!1,c!==2)continue}}if(c===1){xl(e,0),Va(e,t,0,!0);break}e:{switch(o=e,d=c,d){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:Va(o,t,Sn,!Pa);break e;case 2:Xt=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(c=sf+300-Me(),10<c)){if(Va(o,t,Sn,!Pa),cr(o,0,!0)!==0)break e;o.timeoutHandle=Og(Ip.bind(null,o,r,Xt,ys,of,t,Sn,Tr,vl,Pa,d,2,-0,0),c);break e}Ip(o,r,Xt,ys,of,t,Sn,Tr,vl,Pa,d,0,-0,0)}}break}while(!0);$n(e)}function Ip(e,t,r,o,c,d,b,E,j,q,I,ne,F,X){if(e.timeoutHandle=-1,ne=t.subtreeFlags,(ne&8192||(ne&16785408)===16785408)&&(Ki={stylesheets:null,count:0,unsuspend:gS},Kp(t),ne=yS(),ne!==null)){e.cancelPendingCommit=ne(lg.bind(null,e,t,d,r,o,c,b,E,j,I,1,F,X)),Va(e,d,b,!q);return}lg(e,t,d,r,o,c,b,E,j)}function z1(e){for(var t=e;;){var r=t.tag;if((r===0||r===11||r===15)&&t.flags&16384&&(r=t.updateQueue,r!==null&&(r=r.stores,r!==null)))for(var o=0;o<r.length;o++){var c=r[o],d=c.getSnapshot;c=c.value;try{if(!It(d(),c))return!1}catch{return!1}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;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 Va(e,t,r,o){t&=~lf,t&=~Tr,e.suspendedLanes|=t,e.pingedLanes&=~t,o&&(e.warmLanes|=t),o=e.expirationTimes;for(var c=t;0<c;){var d=31-Lt(c),b=1<<d;o[d]=-1,c&=~b}r!==0&&dr(e,r,t)}function bs(){return(tt&6)===0?(Hi(0),!1):!0}function df(){if(Xe!==null){if(nt===0)var e=Xe.return;else e=Xe,ia=Er=null,Nc(e),dl=null,Ti=0,e=Xe;for(;e!==null;)Mp(e.alternate,e),e=e.return;Xe=null}}function xl(e,t){var r=e.timeoutHandle;r!==-1&&(e.timeoutHandle=-1,W1(r)),r=e.cancelPendingCommit,r!==null&&(e.cancelPendingCommit=null,r()),df(),ut=e,Xe=r=aa(e.current,null),Je=t,nt=0,nn=null,Pa=!1,gl=zn(e,t),rf=!1,vl=Sn=lf=Tr=Ha=xt=0,Xt=Ui=null,of=!1,(t&8)!==0&&(t|=t&32);var o=e.entangledLanes;if(o!==0)for(e=e.entanglements,o&=t;0<o;){var c=31-Lt(o),d=1<<c;t|=e[c],o&=~d}return ma=t,$o(),r}function Wp(e,t){qe=null,_.H=is,t===xi||t===Zo?(t=gm(),nt=3):t===hm?(t=gm(),nt=4):nt=t===vp?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,nn=t,Xe===null&&(xt=1,fs(e,gn(t,e.current)))}function eg(){var e=_.H;return _.H=is,e===null?is:e}function tg(){var e=_.A;return _.A=D1,e}function hf(){xt=4,Pa||(Je&4194048)!==Je&&xn.current!==null||(gl=!0),(Ha&134217727)===0&&(Tr&134217727)===0||ut===null||Va(ut,Je,Sn,!1)}function mf(e,t,r){var o=tt;tt|=2;var c=eg(),d=tg();(ut!==e||Je!==t)&&(ys=null,xl(e,t)),t=!1;var b=xt;e:do try{if(nt!==0&&Xe!==null){var E=Xe,j=nn;switch(nt){case 8:df(),b=6;break e;case 3:case 2:case 9:case 6:xn.current===null&&(t=!0);var q=nt;if(nt=0,nn=null,Sl(e,E,j,q),r&&gl){b=0;break e}break;default:q=nt,nt=0,nn=null,Sl(e,E,j,q)}}k1(),b=xt;break}catch(I){Wp(e,I)}while(!0);return t&&e.shellSuspendCounter++,ia=Er=null,tt=o,_.H=c,_.A=d,Xe===null&&(ut=null,Je=0,$o()),b}function k1(){for(;Xe!==null;)ng(Xe)}function U1(e,t){var r=tt;tt|=2;var o=eg(),c=tg();ut!==e||Je!==t?(ys=null,vs=Me()+500,xl(e,t)):gl=zn(e,t);e:do try{if(nt!==0&&Xe!==null){t=Xe;var d=nn;t:switch(nt){case 1:nt=0,nn=null,Sl(e,t,d,1);break;case 2:case 9:if(mm(d)){nt=0,nn=null,ag(t);break}t=function(){nt!==2&&nt!==9||ut!==e||(nt=7),$n(e)},d.then(t,t);break e;case 3:nt=7;break e;case 4:nt=5;break e;case 7:mm(d)?(nt=0,nn=null,ag(t)):(nt=0,nn=null,Sl(e,t,d,7));break;case 5:var b=null;switch(Xe.tag){case 26:b=Xe.memoizedState;case 5:case 27:var E=Xe;if(!b||Pg(b)){nt=0,nn=null;var j=E.sibling;if(j!==null)Xe=j;else{var q=E.return;q!==null?(Xe=q,xs(q)):Xe=null}break t}}nt=0,nn=null,Sl(e,t,d,5);break;case 6:nt=0,nn=null,Sl(e,t,d,6);break;case 8:df(),xt=6;break e;default:throw Error(i(462))}}P1();break}catch(I){Wp(e,I)}while(!0);return ia=Er=null,_.H=o,_.A=c,tt=r,Xe!==null?0:(ut=null,Je=0,$o(),xt)}function P1(){for(;Xe!==null&&!Ne();)ng(Xe)}function ng(e){var t=Tp(e.alternate,e,ma);e.memoizedProps=e.pendingProps,t===null?xs(e):Xe=t}function ag(e){var t=e,r=t.alternate;switch(t.tag){case 15:case 0:t=Ep(r,t,t.pendingProps,t.type,void 0,Je);break;case 11:t=Ep(r,t,t.pendingProps,t.type.render,t.ref,Je);break;case 5:Nc(t);default:Mp(r,t),t=Xe=rm(t,ma),t=Tp(r,t,ma)}e.memoizedProps=e.pendingProps,t===null?xs(e):Xe=t}function Sl(e,t,r,o){ia=Er=null,Nc(t),dl=null,Ti=0;var c=t.return;try{if(A1(e,c,t,r,Je)){xt=1,fs(e,gn(r,e.current)),Xe=null;return}}catch(d){if(c!==null)throw Xe=c,d;xt=1,fs(e,gn(r,e.current)),Xe=null;return}t.flags&32768?(We||o===1?e=!0:gl||(Je&536870912)!==0?e=!1:(Pa=e=!0,(o===2||o===9||o===3||o===6)&&(o=xn.current,o!==null&&o.tag===13&&(o.flags|=16384))),rg(t,e)):xs(t)}function xs(e){var t=e;do{if((t.flags&32768)!==0){rg(t,Pa);return}e=t.return;var r=T1(t.alternate,t,ma);if(r!==null){Xe=r;return}if(t=t.sibling,t!==null){Xe=t;return}Xe=t=e}while(t!==null);xt===0&&(xt=5)}function rg(e,t){do{var r=j1(e.alternate,e);if(r!==null){r.flags&=32767,Xe=r;return}if(r=e.return,r!==null&&(r.flags|=32768,r.subtreeFlags=0,r.deletions=null),!t&&(e=e.sibling,e!==null)){Xe=e;return}Xe=e=r}while(e!==null);xt=6,Xe=null}function lg(e,t,r,o,c,d,b,E,j){e.cancelPendingCommit=null;do Ss();while(kt!==0);if((tt&6)!==0)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(d=t.lanes|t.childLanes,d|=ac,To(e,r,d,b,E,j),e===ut&&(Xe=ut=null,Je=0),yl=t,$a=e,bl=r,uf=d,cf=c,Qp=o,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,V1(Yr,function(){return cg(),null})):(e.callbackNode=null,e.callbackPriority=0),o=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||o){o=_.T,_.T=null,c=Z.p,Z.p=2,b=tt,tt|=4;try{M1(e,t,r)}finally{tt=b,Z.p=c,_.T=o}}kt=1,ig(),og(),sg()}}function ig(){if(kt===1){kt=0;var e=$a,t=yl,r=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||r){r=_.T,_.T=null;var o=Z.p;Z.p=2;var c=tt;tt|=4;try{Vp(t,e);var d=Of,b=Xh(e.containerInfo),E=d.focusedElem,j=d.selectionRange;if(b!==E&&E&&E.ownerDocument&&Fh(E.ownerDocument.documentElement,E)){if(j!==null&&Iu(E)){var q=j.start,I=j.end;if(I===void 0&&(I=q),"selectionStart"in E)E.selectionStart=q,E.selectionEnd=Math.min(I,E.value.length);else{var ne=E.ownerDocument||document,F=ne&&ne.defaultView||window;if(F.getSelection){var X=F.getSelection(),ke=E.textContent.length,De=Math.min(j.start,ke),it=j.end===void 0?De:Math.min(j.end,ke);!X.extend&&De>it&&(b=it,it=De,De=b);var U=Gh(E,De),D=Gh(E,it);if(U&&D&&(X.rangeCount!==1||X.anchorNode!==U.node||X.anchorOffset!==U.offset||X.focusNode!==D.node||X.focusOffset!==D.offset)){var V=ne.createRange();V.setStart(U.node,U.offset),X.removeAllRanges(),De>it?(X.addRange(V),X.extend(D.node,D.offset)):(V.setEnd(D.node,D.offset),X.addRange(V))}}}}for(ne=[],X=E;X=X.parentNode;)X.nodeType===1&&ne.push({element:X,left:X.scrollLeft,top:X.scrollTop});for(typeof E.focus=="function"&&E.focus(),E=0;E<ne.length;E++){var ee=ne[E];ee.element.scrollLeft=ee.left,ee.element.scrollTop=ee.top}}Ds=!!Cf,Of=Cf=null}finally{tt=c,Z.p=o,_.T=r}}e.current=t,kt=2}}function og(){if(kt===2){kt=0;var e=$a,t=yl,r=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||r){r=_.T,_.T=null;var o=Z.p;Z.p=2;var c=tt;tt|=4;try{Pp(e,t.alternate,t)}finally{tt=c,Z.p=o,_.T=r}}kt=3}}function sg(){if(kt===4||kt===3){kt=0,Ue();var e=$a,t=yl,r=bl,o=Qp;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?kt=5:(kt=0,yl=$a=null,ug(e,e.pendingLanes));var c=e.pendingLanes;if(c===0&&(Ba=null),ri(r),t=t.stateNode,mt&&typeof mt.onCommitFiberRoot=="function")try{mt.onCommitFiberRoot(Yt,t,void 0,(t.current.flags&128)===128)}catch{}if(o!==null){t=_.T,c=Z.p,Z.p=2,_.T=null;try{for(var d=e.onRecoverableError,b=0;b<o.length;b++){var E=o[b];d(E.value,{componentStack:E.stack})}}finally{_.T=t,Z.p=c}}(bl&3)!==0&&Ss(),$n(e),c=e.pendingLanes,(r&4194090)!==0&&(c&42)!==0?e===ff?Pi++:(Pi=0,ff=e):Pi=0,Hi(0)}}function ug(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,yi(t)))}function Ss(e){return ig(),og(),sg(),cg()}function cg(){if(kt!==5)return!1;var e=$a,t=uf;uf=0;var r=ri(bl),o=_.T,c=Z.p;try{Z.p=32>r?32:r,_.T=null,r=cf,cf=null;var d=$a,b=bl;if(kt=0,yl=$a=null,bl=0,(tt&6)!==0)throw Error(i(331));var E=tt;if(tt|=4,Fp(d.current),Yp(d,d.current,b,r),tt=E,Hi(0,!1),mt&&typeof mt.onPostCommitFiberRoot=="function")try{mt.onPostCommitFiberRoot(Yt,d)}catch{}return!0}finally{Z.p=c,_.T=o,ug(e,t)}}function fg(e,t,r){t=gn(r,t),t=Vc(e.stateNode,t,2),e=Ma(e,t,2),e!==null&&(fr(e,2),$n(e))}function st(e,t,r){if(e.tag===3)fg(e,e,r);else for(;t!==null;){if(t.tag===3){fg(t,e,r);break}else if(t.tag===1){var o=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(Ba===null||!Ba.has(o))){e=gn(r,e),r=pp(2),o=Ma(t,r,2),o!==null&&(gp(r,o,t,e),fr(o,2),$n(o));break}}t=t.return}}function pf(e,t,r){var o=e.pingCache;if(o===null){o=e.pingCache=new L1;var c=new Set;o.set(t,c)}else c=o.get(t),c===void 0&&(c=new Set,o.set(t,c));c.has(r)||(rf=!0,c.add(r),e=H1.bind(null,e,t,r),t.then(e,e))}function H1(e,t,r){var o=e.pingCache;o!==null&&o.delete(t),e.pingedLanes|=e.suspendedLanes&r,e.warmLanes&=~r,ut===e&&(Je&r)===r&&(xt===4||xt===3&&(Je&62914560)===Je&&300>Me()-sf?(tt&2)===0&&xl(e,0):lf|=r,vl===Je&&(vl=0)),$n(e)}function dg(e,t){t===0&&(t=No()),e=nl(e,t),e!==null&&(fr(e,t),$n(e))}function B1(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),dg(e,r)}function $1(e,t){var r=0;switch(e.tag){case 13:var o=e.stateNode,c=e.memoizedState;c!==null&&(r=c.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(i(314))}o!==null&&o.delete(t),dg(e,r)}function V1(e,t){return se(e,t)}var ws=null,wl=null,gf=!1,Es=!1,vf=!1,jr=0;function $n(e){e!==wl&&e.next===null&&(wl===null?ws=wl=e:wl=wl.next=e),Es=!0,gf||(gf=!0,Y1())}function Hi(e,t){if(!vf&&Es){vf=!0;do for(var r=!1,o=ws;o!==null;){if(e!==0){var c=o.pendingLanes;if(c===0)var d=0;else{var b=o.suspendedLanes,E=o.pingedLanes;d=(1<<31-Lt(42|e)+1)-1,d&=c&~(b&~E),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(r=!0,gg(o,d))}else d=Je,d=cr(o,o===ut?d:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(d&3)===0||zn(o,d)||(r=!0,gg(o,d));o=o.next}while(r);vf=!1}}function q1(){hg()}function hg(){Es=gf=!1;var e=0;jr!==0&&(I1()&&(e=jr),jr=0);for(var t=Me(),r=null,o=ws;o!==null;){var c=o.next,d=mg(o,t);d===0?(o.next=null,r===null?ws=c:r.next=c,c===null&&(wl=r)):(r=o,(e!==0||(d&3)!==0)&&(Es=!0)),o=c}Hi(e)}function mg(e,t){for(var r=e.suspendedLanes,o=e.pingedLanes,c=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var b=31-Lt(d),E=1<<b,j=c[b];j===-1?((E&r)===0||(E&o)!==0)&&(c[b]=Ao(E,t)):j<=t&&(e.expiredLanes|=E),d&=~E}if(t=ut,r=Je,r=cr(e,e===t?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o=e.callbackNode,r===0||e===t&&(nt===2||nt===9)||e.cancelPendingCommit!==null)return o!==null&&o!==null&&ue(o),e.callbackNode=null,e.callbackPriority=0;if((r&3)===0||zn(e,r)){if(t=r&-r,t===e.callbackPriority)return t;switch(o!==null&&ue(o),ri(r)){case 2:case 8:r=qr;break;case 32:r=Yr;break;case 268435456:r=Ra;break;default:r=Yr}return o=pg.bind(null,e),r=se(r,o),e.callbackPriority=t,e.callbackNode=r,t}return o!==null&&o!==null&&ue(o),e.callbackPriority=2,e.callbackNode=null,2}function pg(e,t){if(kt!==0&&kt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var r=e.callbackNode;if(Ss()&&e.callbackNode!==r)return null;var o=Je;return o=cr(e,e===ut?o:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o===0?null:(Jp(e,o,t),mg(e,Me()),e.callbackNode!=null&&e.callbackNode===r?pg.bind(null,e):null)}function gg(e,t){if(Ss())return null;Jp(e,t,!0)}function Y1(){eS(function(){(tt&6)!==0?se(Cn,q1):hg()})}function yf(){return jr===0&&(jr=Kr()),jr}function vg(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Lo(""+e)}function yg(e,t){var r=t.ownerDocument.createElement("input");return r.name=t.name,r.value=t.value,e.id&&r.setAttribute("form",e.id),t.parentNode.insertBefore(r,t),e=new FormData(e),r.parentNode.removeChild(r),e}function K1(e,t,r,o,c){if(t==="submit"&&r&&r.stateNode===c){var d=vg((c[ce]||null).action),b=o.submitter;b&&(t=(t=b[ce]||null)?vg(t.formAction):b.getAttribute("formAction"),t!==null&&(d=t,b=null));var E=new Po("action","action",null,o,c);e.push({event:E,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(jr!==0){var j=b?yg(c,b):new FormData(c);Uc(r,{pending:!0,data:j,method:c.method,action:d},null,j)}}else typeof d=="function"&&(E.preventDefault(),j=b?yg(c,b):new FormData(c),Uc(r,{pending:!0,data:j,method:c.method,action:d},d,j))},currentTarget:c}]})}}for(var bf=0;bf<nc.length;bf++){var xf=nc[bf],G1=xf.toLowerCase(),F1=xf[0].toUpperCase()+xf.slice(1);An(G1,"on"+F1)}An(Jh,"onAnimationEnd"),An(Ih,"onAnimationIteration"),An(Wh,"onAnimationStart"),An("dblclick","onDoubleClick"),An("focusin","onFocus"),An("focusout","onBlur"),An(c1,"onTransitionRun"),An(f1,"onTransitionStart"),An(d1,"onTransitionCancel"),An(em,"onTransitionEnd"),Vt("onMouseEnter",["mouseout","mouseover"]),Vt("onMouseLeave",["mouseout","mouseover"]),Vt("onPointerEnter",["pointerout","pointerover"]),Vt("onPointerLeave",["pointerout","pointerover"]),Jt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Jt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Jt("onBeforeInput",["compositionend","keypress","textInput","paste"]),Jt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Jt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Jt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Bi="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(" "),X1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Bi));function bg(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var o=e[r],c=o.event;o=o.listeners;e:{var d=void 0;if(t)for(var b=o.length-1;0<=b;b--){var E=o[b],j=E.instance,q=E.currentTarget;if(E=E.listener,j!==d&&c.isPropagationStopped())break e;d=E,c.currentTarget=q;try{d(c)}catch(I){cs(I)}c.currentTarget=null,d=j}else for(b=0;b<o.length;b++){if(E=o[b],j=E.instance,q=E.currentTarget,E=E.listener,j!==d&&c.isPropagationStopped())break e;d=E,c.currentTarget=q;try{d(c)}catch(I){cs(I)}c.currentTarget=null,d=j}}}}function Qe(e,t){var r=t[Re];r===void 0&&(r=t[Re]=new Set);var o=e+"__bubble";r.has(o)||(xg(t,e,2,!1),r.add(o))}function Sf(e,t,r){var o=0;t&&(o|=4),xg(r,e,o,t)}var Rs="_reactListening"+Math.random().toString(36).slice(2);function wf(e){if(!e[Rs]){e[Rs]=!0,at.forEach(function(r){r!=="selectionchange"&&(X1.has(r)||Sf(r,!1,e),Sf(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Rs]||(t[Rs]=!0,Sf("selectionchange",!1,t))}}function xg(e,t,r,o){switch(Yg(t)){case 2:var c=SS;break;case 8:c=wS;break;default:c=kf}r=c.bind(null,t,r,e),c=void 0,!qu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(c=!0),o?c!==void 0?e.addEventListener(t,r,{capture:!0,passive:c}):e.addEventListener(t,r,!0):c!==void 0?e.addEventListener(t,r,{passive:c}):e.addEventListener(t,r,!1)}function Ef(e,t,r,o,c){var d=o;if((t&1)===0&&(t&2)===0&&o!==null)e:for(;;){if(o===null)return;var b=o.tag;if(b===3||b===4){var E=o.stateNode.containerInfo;if(E===c)break;if(b===4)for(b=o.return;b!==null;){var j=b.tag;if((j===3||j===4)&&b.stateNode.containerInfo===c)return;b=b.return}for(;E!==null;){if(b=Ve(E),b===null)return;if(j=b.tag,j===5||j===6||j===26||j===27){o=d=b;continue e}E=E.parentNode}}o=o.return}Ah(function(){var q=d,I=$u(r),ne=[];e:{var F=tm.get(e);if(F!==void 0){var X=Po,ke=e;switch(e){case"keypress":if(ko(r)===0)break e;case"keydown":case"keyup":X=Vx;break;case"focusin":ke="focus",X=Fu;break;case"focusout":ke="blur",X=Fu;break;case"beforeblur":case"afterblur":X=Fu;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":X=jh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":X=jx;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":X=Kx;break;case Jh:case Ih:case Wh:X=Dx;break;case em:X=Fx;break;case"scroll":case"scrollend":X=Nx;break;case"wheel":X=Qx;break;case"copy":case"cut":case"paste":X=zx;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":X=_h;break;case"toggle":case"beforetoggle":X=Jx}var De=(t&4)!==0,it=!De&&(e==="scroll"||e==="scrollend"),U=De?F!==null?F+"Capture":null:F;De=[];for(var D=q,V;D!==null;){var ee=D;if(V=ee.stateNode,ee=ee.tag,ee!==5&&ee!==26&&ee!==27||V===null||U===null||(ee=li(D,U),ee!=null&&De.push($i(D,ee,V))),it)break;D=D.return}0<De.length&&(F=new X(F,ke,null,r,I),ne.push({event:F,listeners:De}))}}if((t&7)===0){e:{if(F=e==="mouseover"||e==="pointerover",X=e==="mouseout"||e==="pointerout",F&&r!==Bu&&(ke=r.relatedTarget||r.fromElement)&&(Ve(ke)||ke[xe]))break e;if((X||F)&&(F=I.window===I?I:(F=I.ownerDocument)?F.defaultView||F.parentWindow:window,X?(ke=r.relatedTarget||r.toElement,X=q,ke=ke?Ve(ke):null,ke!==null&&(it=u(ke),De=ke.tag,ke!==it||De!==5&&De!==27&&De!==6)&&(ke=null)):(X=null,ke=q),X!==ke)){if(De=jh,ee="onMouseLeave",U="onMouseEnter",D="mouse",(e==="pointerout"||e==="pointerover")&&(De=_h,ee="onPointerLeave",U="onPointerEnter",D="pointer"),it=X==null?F:vt(X),V=ke==null?F:vt(ke),F=new De(ee,D+"leave",X,r,I),F.target=it,F.relatedTarget=V,ee=null,Ve(I)===q&&(De=new De(U,D+"enter",ke,r,I),De.target=V,De.relatedTarget=it,ee=De),it=ee,X&&ke)t:{for(De=X,U=ke,D=0,V=De;V;V=El(V))D++;for(V=0,ee=U;ee;ee=El(ee))V++;for(;0<D-V;)De=El(De),D--;for(;0<V-D;)U=El(U),V--;for(;D--;){if(De===U||U!==null&&De===U.alternate)break t;De=El(De),U=El(U)}De=null}else De=null;X!==null&&Sg(ne,F,X,De,!1),ke!==null&&it!==null&&Sg(ne,it,ke,De,!0)}}e:{if(F=q?vt(q):window,X=F.nodeName&&F.nodeName.toLowerCase(),X==="select"||X==="input"&&F.type==="file")var ve=Bh;else if(Ph(F))if($h)ve=o1;else{ve=l1;var Ge=r1}else X=F.nodeName,!X||X.toLowerCase()!=="input"||F.type!=="checkbox"&&F.type!=="radio"?q&&Hu(q.elementType)&&(ve=Bh):ve=i1;if(ve&&(ve=ve(e,q))){Hh(ne,ve,r,I);break e}Ge&&Ge(e,F,q),e==="focusout"&&q&&F.type==="number"&&q.memoizedProps.value!=null&&Pu(F,"number",F.value)}switch(Ge=q?vt(q):window,e){case"focusin":(Ph(Ge)||Ge.contentEditable==="true")&&(Wr=Ge,Wu=q,hi=null);break;case"focusout":hi=Wu=Wr=null;break;case"mousedown":ec=!0;break;case"contextmenu":case"mouseup":case"dragend":ec=!1,Qh(ne,r,I);break;case"selectionchange":if(u1)break;case"keydown":case"keyup":Qh(ne,r,I)}var Ae;if(Qu)e:{switch(e){case"compositionstart":var Le="onCompositionStart";break e;case"compositionend":Le="onCompositionEnd";break e;case"compositionupdate":Le="onCompositionUpdate";break e}Le=void 0}else Ir?kh(e,r)&&(Le="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(Le="onCompositionStart");Le&&(Dh&&r.locale!=="ko"&&(Ir||Le!=="onCompositionStart"?Le==="onCompositionEnd"&&Ir&&(Ae=Nh()):(Aa=I,Yu="value"in Aa?Aa.value:Aa.textContent,Ir=!0)),Ge=Cs(q,Le),0<Ge.length&&(Le=new Mh(Le,e,null,r,I),ne.push({event:Le,listeners:Ge}),Ae?Le.data=Ae:(Ae=Uh(r),Ae!==null&&(Le.data=Ae)))),(Ae=Wx?e1(e,r):t1(e,r))&&(Le=Cs(q,"onBeforeInput"),0<Le.length&&(Ge=new Mh("onBeforeInput","beforeinput",null,r,I),ne.push({event:Ge,listeners:Le}),Ge.data=Ae)),K1(ne,e,q,r,I)}bg(ne,t)})}function $i(e,t,r){return{instance:e,listener:t,currentTarget:r}}function Cs(e,t){for(var r=t+"Capture",o=[];e!==null;){var c=e,d=c.stateNode;if(c=c.tag,c!==5&&c!==26&&c!==27||d===null||(c=li(e,r),c!=null&&o.unshift($i(e,c,d)),c=li(e,t),c!=null&&o.push($i(e,c,d))),e.tag===3)return o;e=e.return}return[]}function El(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Sg(e,t,r,o,c){for(var d=t._reactName,b=[];r!==null&&r!==o;){var E=r,j=E.alternate,q=E.stateNode;if(E=E.tag,j!==null&&j===o)break;E!==5&&E!==26&&E!==27||q===null||(j=q,c?(q=li(r,d),q!=null&&b.unshift($i(r,q,j))):c||(q=li(r,d),q!=null&&b.push($i(r,q,j)))),r=r.return}b.length!==0&&e.push({event:t,listeners:b})}var Q1=/\r\n?/g,Z1=/\u0000|\uFFFD/g;function wg(e){return(typeof e=="string"?e:""+e).replace(Q1,`
|
|
55
|
+
`).replace(Z1,"")}function Eg(e,t){return t=wg(t),wg(e)===t}function Os(){}function lt(e,t,r,o,c,d){switch(r){case"children":typeof o=="string"?t==="body"||t==="textarea"&&o===""||Qr(e,o):(typeof o=="number"||typeof o=="bigint")&&t!=="body"&&Qr(e,""+o);break;case"className":ta(e,"class",o);break;case"tabIndex":ta(e,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":ta(e,r,o);break;case"style":Ch(e,o,d);break;case"data":if(t!=="object"){ta(e,"data",o);break}case"src":case"href":if(o===""&&(t!=="a"||r!=="href")){e.removeAttribute(r);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(r);break}o=Lo(""+o),e.setAttribute(r,o);break;case"action":case"formAction":if(typeof o=="function"){e.setAttribute(r,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof d=="function"&&(r==="formAction"?(t!=="input"&<(e,t,"name",c.name,c,null),lt(e,t,"formEncType",c.formEncType,c,null),lt(e,t,"formMethod",c.formMethod,c,null),lt(e,t,"formTarget",c.formTarget,c,null)):(lt(e,t,"encType",c.encType,c,null),lt(e,t,"method",c.method,c,null),lt(e,t,"target",c.target,c,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(r);break}o=Lo(""+o),e.setAttribute(r,o);break;case"onClick":o!=null&&(e.onclick=Os);break;case"onScroll":o!=null&&Qe("scroll",e);break;case"onScrollEnd":o!=null&&Qe("scrollend",e);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(r=o.__html,r!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=r}}break;case"multiple":e.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":e.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){e.removeAttribute("xlink:href");break}r=Lo(""+o),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",r);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,""+o):e.removeAttribute(r);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":o&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,""):e.removeAttribute(r);break;case"capture":case"download":o===!0?e.setAttribute(r,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(r,o):e.removeAttribute(r);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?e.setAttribute(r,o):e.removeAttribute(r);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?e.removeAttribute(r):e.setAttribute(r,o);break;case"popover":Qe("beforetoggle",e),Qe("toggle",e),ea(e,"popover",o);break;case"xlinkActuate":Ke(e,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":Ke(e,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":Ke(e,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":Ke(e,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":Ke(e,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":Ke(e,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":Ke(e,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":ea(e,"is",o);break;case"innerText":case"textContent":break;default:(!(2<r.length)||r[0]!=="o"&&r[0]!=="O"||r[1]!=="n"&&r[1]!=="N")&&(r=Ox.get(r)||r,ea(e,r,o))}}function Rf(e,t,r,o,c,d){switch(r){case"style":Ch(e,o,d);break;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(i(61));if(r=o.__html,r!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=r}}break;case"children":typeof o=="string"?Qr(e,o):(typeof o=="number"||typeof o=="bigint")&&Qr(e,""+o);break;case"onScroll":o!=null&&Qe("scroll",e);break;case"onScrollEnd":o!=null&&Qe("scrollend",e);break;case"onClick":o!=null&&(e.onclick=Os);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!kn.hasOwnProperty(r))e:{if(r[0]==="o"&&r[1]==="n"&&(c=r.endsWith("Capture"),t=r.slice(2,c?r.length-7:void 0),d=e[ce]||null,d=d!=null?d[r]:null,typeof d=="function"&&e.removeEventListener(t,d,c),typeof o=="function")){typeof d!="function"&&d!==null&&(r in e?e[r]=null:e.hasAttribute(r)&&e.removeAttribute(r)),e.addEventListener(t,o,c);break e}r in e?e[r]=o:o===!0?e.setAttribute(r,""):ea(e,r,o)}}}function Ut(e,t,r){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Qe("error",e),Qe("load",e);var o=!1,c=!1,d;for(d in r)if(r.hasOwnProperty(d)){var b=r[d];if(b!=null)switch(d){case"src":o=!0;break;case"srcSet":c=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(i(137,t));default:lt(e,t,d,b,r,null)}}c&<(e,t,"srcSet",r.srcSet,r,null),o&<(e,t,"src",r.src,r,null);return;case"input":Qe("invalid",e);var E=d=b=c=null,j=null,q=null;for(o in r)if(r.hasOwnProperty(o)){var I=r[o];if(I!=null)switch(o){case"name":c=I;break;case"type":b=I;break;case"checked":j=I;break;case"defaultChecked":q=I;break;case"value":d=I;break;case"defaultValue":E=I;break;case"children":case"dangerouslySetInnerHTML":if(I!=null)throw Error(i(137,t));break;default:lt(e,t,o,I,r,null)}}Sh(e,d,E,j,q,b,c,!1),_o(e);return;case"select":Qe("invalid",e),o=b=d=null;for(c in r)if(r.hasOwnProperty(c)&&(E=r[c],E!=null))switch(c){case"value":d=E;break;case"defaultValue":b=E;break;case"multiple":o=E;default:lt(e,t,c,E,r,null)}t=d,r=b,e.multiple=!!o,t!=null?Xr(e,!!o,t,!1):r!=null&&Xr(e,!!o,r,!0);return;case"textarea":Qe("invalid",e),d=c=o=null;for(b in r)if(r.hasOwnProperty(b)&&(E=r[b],E!=null))switch(b){case"value":o=E;break;case"defaultValue":c=E;break;case"children":d=E;break;case"dangerouslySetInnerHTML":if(E!=null)throw Error(i(91));break;default:lt(e,t,b,E,r,null)}Eh(e,o,c,d),_o(e);return;case"option":for(j in r)if(r.hasOwnProperty(j)&&(o=r[j],o!=null))switch(j){case"selected":e.selected=o&&typeof o!="function"&&typeof o!="symbol";break;default:lt(e,t,j,o,r,null)}return;case"dialog":Qe("beforetoggle",e),Qe("toggle",e),Qe("cancel",e),Qe("close",e);break;case"iframe":case"object":Qe("load",e);break;case"video":case"audio":for(o=0;o<Bi.length;o++)Qe(Bi[o],e);break;case"image":Qe("error",e),Qe("load",e);break;case"details":Qe("toggle",e);break;case"embed":case"source":case"link":Qe("error",e),Qe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(q in r)if(r.hasOwnProperty(q)&&(o=r[q],o!=null))switch(q){case"children":case"dangerouslySetInnerHTML":throw Error(i(137,t));default:lt(e,t,q,o,r,null)}return;default:if(Hu(t)){for(I in r)r.hasOwnProperty(I)&&(o=r[I],o!==void 0&&Rf(e,t,I,o,r,void 0));return}}for(E in r)r.hasOwnProperty(E)&&(o=r[E],o!=null&<(e,t,E,o,r,null))}function J1(e,t,r,o){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var c=null,d=null,b=null,E=null,j=null,q=null,I=null;for(X in r){var ne=r[X];if(r.hasOwnProperty(X)&&ne!=null)switch(X){case"checked":break;case"value":break;case"defaultValue":j=ne;default:o.hasOwnProperty(X)||lt(e,t,X,null,o,ne)}}for(var F in o){var X=o[F];if(ne=r[F],o.hasOwnProperty(F)&&(X!=null||ne!=null))switch(F){case"type":d=X;break;case"name":c=X;break;case"checked":q=X;break;case"defaultChecked":I=X;break;case"value":b=X;break;case"defaultValue":E=X;break;case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(i(137,t));break;default:X!==ne&<(e,t,F,X,o,ne)}}Uu(e,b,E,j,q,I,d,c);return;case"select":X=b=E=F=null;for(d in r)if(j=r[d],r.hasOwnProperty(d)&&j!=null)switch(d){case"value":break;case"multiple":X=j;default:o.hasOwnProperty(d)||lt(e,t,d,null,o,j)}for(c in o)if(d=o[c],j=r[c],o.hasOwnProperty(c)&&(d!=null||j!=null))switch(c){case"value":F=d;break;case"defaultValue":E=d;break;case"multiple":b=d;default:d!==j&<(e,t,c,d,o,j)}t=E,r=b,o=X,F!=null?Xr(e,!!r,F,!1):!!o!=!!r&&(t!=null?Xr(e,!!r,t,!0):Xr(e,!!r,r?[]:"",!1));return;case"textarea":X=F=null;for(E in r)if(c=r[E],r.hasOwnProperty(E)&&c!=null&&!o.hasOwnProperty(E))switch(E){case"value":break;case"children":break;default:lt(e,t,E,null,o,c)}for(b in o)if(c=o[b],d=r[b],o.hasOwnProperty(b)&&(c!=null||d!=null))switch(b){case"value":F=c;break;case"defaultValue":X=c;break;case"children":break;case"dangerouslySetInnerHTML":if(c!=null)throw Error(i(91));break;default:c!==d&<(e,t,b,c,o,d)}wh(e,F,X);return;case"option":for(var ke in r)if(F=r[ke],r.hasOwnProperty(ke)&&F!=null&&!o.hasOwnProperty(ke))switch(ke){case"selected":e.selected=!1;break;default:lt(e,t,ke,null,o,F)}for(j in o)if(F=o[j],X=r[j],o.hasOwnProperty(j)&&F!==X&&(F!=null||X!=null))switch(j){case"selected":e.selected=F&&typeof F!="function"&&typeof F!="symbol";break;default:lt(e,t,j,F,o,X)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var De in r)F=r[De],r.hasOwnProperty(De)&&F!=null&&!o.hasOwnProperty(De)&<(e,t,De,null,o,F);for(q in o)if(F=o[q],X=r[q],o.hasOwnProperty(q)&&F!==X&&(F!=null||X!=null))switch(q){case"children":case"dangerouslySetInnerHTML":if(F!=null)throw Error(i(137,t));break;default:lt(e,t,q,F,o,X)}return;default:if(Hu(t)){for(var it in r)F=r[it],r.hasOwnProperty(it)&&F!==void 0&&!o.hasOwnProperty(it)&&Rf(e,t,it,void 0,o,F);for(I in o)F=o[I],X=r[I],!o.hasOwnProperty(I)||F===X||F===void 0&&X===void 0||Rf(e,t,I,F,o,X);return}}for(var U in r)F=r[U],r.hasOwnProperty(U)&&F!=null&&!o.hasOwnProperty(U)&<(e,t,U,null,o,F);for(ne in o)F=o[ne],X=r[ne],!o.hasOwnProperty(ne)||F===X||F==null&&X==null||lt(e,t,ne,F,o,X)}var Cf=null,Of=null;function As(e){return e.nodeType===9?e:e.ownerDocument}function Rg(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Cg(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Af(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Nf=null;function I1(){var e=window.event;return e&&e.type==="popstate"?e===Nf?!1:(Nf=e,!0):(Nf=null,!1)}var Og=typeof setTimeout=="function"?setTimeout:void 0,W1=typeof clearTimeout=="function"?clearTimeout:void 0,Ag=typeof Promise=="function"?Promise:void 0,eS=typeof queueMicrotask=="function"?queueMicrotask:typeof Ag<"u"?function(e){return Ag.resolve(null).then(e).catch(tS)}:Og;function tS(e){setTimeout(function(){throw e})}function qa(e){return e==="head"}function Ng(e,t){var r=t,o=0,c=0;do{var d=r.nextSibling;if(e.removeChild(r),d&&d.nodeType===8)if(r=d.data,r==="/$"){if(0<o&&8>o){r=o;var b=e.ownerDocument;if(r&1&&Vi(b.documentElement),r&2&&Vi(b.body),r&4)for(r=b.head,Vi(r),b=r.firstChild;b;){var E=b.nextSibling,j=b.nodeName;b[we]||j==="SCRIPT"||j==="STYLE"||j==="LINK"&&b.rel.toLowerCase()==="stylesheet"||r.removeChild(b),b=E}}if(c===0){e.removeChild(d),Zi(t);return}c--}else r==="$"||r==="$?"||r==="$!"?c++:o=r.charCodeAt(0)-48;else o=0;r=d}while(r);Zi(t)}function Tf(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var r=t;switch(t=t.nextSibling,r.nodeName){case"HTML":case"HEAD":case"BODY":Tf(r),Ce(r);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(r.rel.toLowerCase()==="stylesheet")continue}e.removeChild(r)}}function nS(e,t,r,o){for(;e.nodeType===1;){var c=r;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!o&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(o){if(!e[we])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(d=e.getAttribute("rel"),d==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(d!==c.rel||e.getAttribute("href")!==(c.href==null||c.href===""?null:c.href)||e.getAttribute("crossorigin")!==(c.crossOrigin==null?null:c.crossOrigin)||e.getAttribute("title")!==(c.title==null?null:c.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(d=e.getAttribute("src"),(d!==(c.src==null?null:c.src)||e.getAttribute("type")!==(c.type==null?null:c.type)||e.getAttribute("crossorigin")!==(c.crossOrigin==null?null:c.crossOrigin))&&d&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var d=c.name==null?null:""+c.name;if(c.type==="hidden"&&e.getAttribute("name")===d)return e}else return e;if(e=Tn(e.nextSibling),e===null)break}return null}function aS(e,t,r){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!r||(e=Tn(e.nextSibling),e===null))return null;return e}function jf(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function rS(e,t){var r=e.ownerDocument;if(e.data!=="$?"||r.readyState==="complete")t();else{var o=function(){t(),r.removeEventListener("DOMContentLoaded",o)};r.addEventListener("DOMContentLoaded",o),e._reactRetry=o}}function Tn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="F!"||t==="F")break;if(t==="/$")return null}}return e}var Mf=null;function Tg(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}function jg(e,t,r){switch(t=As(r),e){case"html":if(e=t.documentElement,!e)throw Error(i(452));return e;case"head":if(e=t.head,!e)throw Error(i(453));return e;case"body":if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function Vi(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Ce(e)}var wn=new Map,Mg=new Set;function Ns(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var pa=Z.d;Z.d={f:lS,r:iS,D:oS,C:sS,L:uS,m:cS,X:dS,S:fS,M:hS};function lS(){var e=pa.f(),t=bs();return e||t}function iS(e){var t=et(e);t!==null&&t.tag===5&&t.type==="form"?Jm(t):pa.r(e)}var Rl=typeof document>"u"?null:document;function _g(e,t,r){var o=Rl;if(o&&typeof t=="string"&&t){var c=pn(t);c='link[rel="'+e+'"][href="'+c+'"]',typeof r=="string"&&(c+='[crossorigin="'+r+'"]'),Mg.has(c)||(Mg.add(c),e={rel:e,crossOrigin:r,href:t},o.querySelector(c)===null&&(t=o.createElement("link"),Ut(t,"link",e),Be(t),o.head.appendChild(t)))}}function oS(e){pa.D(e),_g("dns-prefetch",e,null)}function sS(e,t){pa.C(e,t),_g("preconnect",e,t)}function uS(e,t,r){pa.L(e,t,r);var o=Rl;if(o&&e&&t){var c='link[rel="preload"][as="'+pn(t)+'"]';t==="image"&&r&&r.imageSrcSet?(c+='[imagesrcset="'+pn(r.imageSrcSet)+'"]',typeof r.imageSizes=="string"&&(c+='[imagesizes="'+pn(r.imageSizes)+'"]')):c+='[href="'+pn(e)+'"]';var d=c;switch(t){case"style":d=Cl(e);break;case"script":d=Ol(e)}wn.has(d)||(e=g({rel:"preload",href:t==="image"&&r&&r.imageSrcSet?void 0:e,as:t},r),wn.set(d,e),o.querySelector(c)!==null||t==="style"&&o.querySelector(qi(d))||t==="script"&&o.querySelector(Yi(d))||(t=o.createElement("link"),Ut(t,"link",e),Be(t),o.head.appendChild(t)))}}function cS(e,t){pa.m(e,t);var r=Rl;if(r&&e){var o=t&&typeof t.as=="string"?t.as:"script",c='link[rel="modulepreload"][as="'+pn(o)+'"][href="'+pn(e)+'"]',d=c;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Ol(e)}if(!wn.has(d)&&(e=g({rel:"modulepreload",href:e},t),wn.set(d,e),r.querySelector(c)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(r.querySelector(Yi(d)))return}o=r.createElement("link"),Ut(o,"link",e),Be(o),r.head.appendChild(o)}}}function fS(e,t,r){pa.S(e,t,r);var o=Rl;if(o&&e){var c=yt(o).hoistableStyles,d=Cl(e);t=t||"default";var b=c.get(d);if(!b){var E={loading:0,preload:null};if(b=o.querySelector(qi(d)))E.loading=5;else{e=g({rel:"stylesheet",href:e,"data-precedence":t},r),(r=wn.get(d))&&_f(e,r);var j=b=o.createElement("link");Be(j),Ut(j,"link",e),j._p=new Promise(function(q,I){j.onload=q,j.onerror=I}),j.addEventListener("load",function(){E.loading|=1}),j.addEventListener("error",function(){E.loading|=2}),E.loading|=4,Ts(b,t,o)}b={type:"stylesheet",instance:b,count:1,state:E},c.set(d,b)}}}function dS(e,t){pa.X(e,t);var r=Rl;if(r&&e){var o=yt(r).hoistableScripts,c=Ol(e),d=o.get(c);d||(d=r.querySelector(Yi(c)),d||(e=g({src:e,async:!0},t),(t=wn.get(c))&&Df(e,t),d=r.createElement("script"),Be(d),Ut(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(c,d))}}function hS(e,t){pa.M(e,t);var r=Rl;if(r&&e){var o=yt(r).hoistableScripts,c=Ol(e),d=o.get(c);d||(d=r.querySelector(Yi(c)),d||(e=g({src:e,async:!0,type:"module"},t),(t=wn.get(c))&&Df(e,t),d=r.createElement("script"),Be(d),Ut(d,"link",e),r.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},o.set(c,d))}}function Dg(e,t,r,o){var c=(c=de.current)?Ns(c):null;if(!c)throw Error(i(446));switch(e){case"meta":case"title":return null;case"style":return typeof r.precedence=="string"&&typeof r.href=="string"?(t=Cl(r.href),r=yt(c).hoistableStyles,o=r.get(t),o||(o={type:"style",instance:null,count:0,state:null},r.set(t,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(r.rel==="stylesheet"&&typeof r.href=="string"&&typeof r.precedence=="string"){e=Cl(r.href);var d=yt(c).hoistableStyles,b=d.get(e);if(b||(c=c.ownerDocument||c,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,b),(d=c.querySelector(qi(e)))&&!d._p&&(b.instance=d,b.state.loading=5),wn.has(e)||(r={rel:"preload",as:"style",href:r.href,crossOrigin:r.crossOrigin,integrity:r.integrity,media:r.media,hrefLang:r.hrefLang,referrerPolicy:r.referrerPolicy},wn.set(e,r),d||mS(c,e,r,b.state))),t&&o===null)throw Error(i(528,""));return b}if(t&&o!==null)throw Error(i(529,""));return null;case"script":return t=r.async,r=r.src,typeof r=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Ol(r),r=yt(c).hoistableScripts,o=r.get(t),o||(o={type:"script",instance:null,count:0,state:null},r.set(t,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Cl(e){return'href="'+pn(e)+'"'}function qi(e){return'link[rel="stylesheet"]['+e+"]"}function Lg(e){return g({},e,{"data-precedence":e.precedence,precedence:null})}function mS(e,t,r,o){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?o.loading=1:(t=e.createElement("link"),o.preload=t,t.addEventListener("load",function(){return o.loading|=1}),t.addEventListener("error",function(){return o.loading|=2}),Ut(t,"link",r),Be(t),e.head.appendChild(t))}function Ol(e){return'[src="'+pn(e)+'"]'}function Yi(e){return"script[async]"+e}function zg(e,t,r){if(t.count++,t.instance===null)switch(t.type){case"style":var o=e.querySelector('style[data-href~="'+pn(r.href)+'"]');if(o)return t.instance=o,Be(o),o;var c=g({},r,{"data-href":r.href,"data-precedence":r.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),Be(o),Ut(o,"style",c),Ts(o,r.precedence,e),t.instance=o;case"stylesheet":c=Cl(r.href);var d=e.querySelector(qi(c));if(d)return t.state.loading|=4,t.instance=d,Be(d),d;o=Lg(r),(c=wn.get(c))&&_f(o,c),d=(e.ownerDocument||e).createElement("link"),Be(d);var b=d;return b._p=new Promise(function(E,j){b.onload=E,b.onerror=j}),Ut(d,"link",o),t.state.loading|=4,Ts(d,r.precedence,e),t.instance=d;case"script":return d=Ol(r.src),(c=e.querySelector(Yi(d)))?(t.instance=c,Be(c),c):(o=r,(c=wn.get(d))&&(o=g({},r),Df(o,c)),e=e.ownerDocument||e,c=e.createElement("script"),Be(c),Ut(c,"link",o),e.head.appendChild(c),t.instance=c);case"void":return null;default:throw Error(i(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(o=t.instance,t.state.loading|=4,Ts(o,r.precedence,e));return t.instance}function Ts(e,t,r){for(var o=r.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),c=o.length?o[o.length-1]:null,d=c,b=0;b<o.length;b++){var E=o[b];if(E.dataset.precedence===t)d=E;else if(d!==c)break}d?d.parentNode.insertBefore(e,d.nextSibling):(t=r.nodeType===9?r.head:r,t.insertBefore(e,t.firstChild))}function _f(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Df(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var js=null;function kg(e,t,r){if(js===null){var o=new Map,c=js=new Map;c.set(r,o)}else c=js,o=c.get(r),o||(o=new Map,c.set(r,o));if(o.has(e))return o;for(o.set(e,null),r=r.getElementsByTagName(e),c=0;c<r.length;c++){var d=r[c];if(!(d[we]||d[le]||e==="link"&&d.getAttribute("rel")==="stylesheet")&&d.namespaceURI!=="http://www.w3.org/2000/svg"){var b=d.getAttribute(t)||"";b=e+b;var E=o.get(b);E?E.push(d):o.set(b,[d])}}return o}function Ug(e,t,r){e=e.ownerDocument||e,e.head.insertBefore(r,t==="title"?e.querySelector("head > title"):null)}function pS(e,t,r){if(r===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function Pg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var Ki=null;function gS(){}function vS(e,t,r){if(Ki===null)throw Error(i(475));var o=Ki;if(t.type==="stylesheet"&&(typeof r.media!="string"||matchMedia(r.media).matches!==!1)&&(t.state.loading&4)===0){if(t.instance===null){var c=Cl(r.href),d=e.querySelector(qi(c));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(o.count++,o=Ms.bind(o),e.then(o,o)),t.state.loading|=4,t.instance=d,Be(d);return}d=e.ownerDocument||e,r=Lg(r),(c=wn.get(c))&&_f(r,c),d=d.createElement("link"),Be(d);var b=d;b._p=new Promise(function(E,j){b.onload=E,b.onerror=j}),Ut(d,"link",r),t.instance=d}o.stylesheets===null&&(o.stylesheets=new Map),o.stylesheets.set(t,e),(e=t.state.preload)&&(t.state.loading&3)===0&&(o.count++,t=Ms.bind(o),e.addEventListener("load",t),e.addEventListener("error",t))}}function yS(){if(Ki===null)throw Error(i(475));var e=Ki;return e.stylesheets&&e.count===0&&Lf(e,e.stylesheets),0<e.count?function(t){var r=setTimeout(function(){if(e.stylesheets&&Lf(e,e.stylesheets),e.unsuspend){var o=e.unsuspend;e.unsuspend=null,o()}},6e4);return e.unsuspend=t,function(){e.unsuspend=null,clearTimeout(r)}}:null}function Ms(){if(this.count--,this.count===0){if(this.stylesheets)Lf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var _s=null;function Lf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,_s=new Map,t.forEach(bS,e),_s=null,Ms.call(e))}function bS(e,t){if(!(t.state.loading&4)){var r=_s.get(e);if(r)var o=r.get(null);else{r=new Map,_s.set(e,r);for(var c=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d<c.length;d++){var b=c[d];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(r.set(b.dataset.precedence,b),o=b)}o&&r.set(null,o)}c=t.instance,b=c.getAttribute("data-precedence"),d=r.get(b)||o,d===o&&r.set(null,c),r.set(b,c),this.count++,o=Ms.bind(this),c.addEventListener("load",o),c.addEventListener("error",o),d?d.parentNode.insertBefore(c,d.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(c,e.firstChild)),t.state.loading|=4}}var Gi={$$typeof:k,Provider:null,Consumer:null,_currentValue:$,_currentValue2:$,_threadCount:0};function xS(e,t,r,o,c,d,b,E){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Gr(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Gr(0),this.hiddenUpdates=Gr(null),this.identifierPrefix=o,this.onUncaughtError=c,this.onCaughtError=d,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=E,this.incompleteTransitions=new Map}function Hg(e,t,r,o,c,d,b,E,j,q,I,ne){return e=new xS(e,t,r,b,E,j,q,ne),t=1,d===!0&&(t|=24),d=Wt(3,null,null,t),e.current=d,d.stateNode=e,t=mc(),t.refCount++,e.pooledCache=t,t.refCount++,d.memoizedState={element:o,isDehydrated:r,cache:t},yc(d),e}function Bg(e){return e?(e=al,e):al}function $g(e,t,r,o,c,d){c=Bg(c),o.context===null?o.context=c:o.pendingContext=c,o=ja(t),o.payload={element:r},d=d===void 0?null:d,d!==null&&(o.callback=d),r=Ma(e,o,t),r!==null&&(rn(r,e,t),wi(r,e,t))}function Vg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function zf(e,t){Vg(e,t),(e=e.alternate)&&Vg(e,t)}function qg(e){if(e.tag===13){var t=nl(e,67108864);t!==null&&rn(t,e,67108864),zf(e,67108864)}}var Ds=!0;function SS(e,t,r,o){var c=_.T;_.T=null;var d=Z.p;try{Z.p=2,kf(e,t,r,o)}finally{Z.p=d,_.T=c}}function wS(e,t,r,o){var c=_.T;_.T=null;var d=Z.p;try{Z.p=8,kf(e,t,r,o)}finally{Z.p=d,_.T=c}}function kf(e,t,r,o){if(Ds){var c=Uf(o);if(c===null)Ef(e,t,o,Ls,r),Kg(e,o);else if(RS(c,e,t,r,o))o.stopPropagation();else if(Kg(e,o),t&4&&-1<ES.indexOf(e)){for(;c!==null;){var d=et(c);if(d!==null)switch(d.tag){case 3:if(d=d.stateNode,d.current.memoizedState.isDehydrated){var b=In(d.pendingLanes);if(b!==0){var E=d;for(E.pendingLanes|=2,E.entangledLanes|=2;b;){var j=1<<31-Lt(b);E.entanglements[1]|=j,b&=~j}$n(d),(tt&6)===0&&(vs=Me()+500,Hi(0))}}break;case 13:E=nl(d,2),E!==null&&rn(E,d,2),bs(),zf(d,2)}if(d=Uf(o),d===null&&Ef(e,t,o,Ls,r),d===c)break;c=d}c!==null&&o.stopPropagation()}else Ef(e,t,o,null,r)}}function Uf(e){return e=$u(e),Pf(e)}var Ls=null;function Pf(e){if(Ls=null,e=Ve(e),e!==null){var t=u(e);if(t===null)e=null;else{var r=t.tag;if(r===13){if(e=f(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ls=e,null}function Yg(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(ot()){case Cn:return 2;case qr:return 8;case Yr:case Jn:return 32;case Ra:return 268435456;default:return 32}default:return 32}}var Hf=!1,Ya=null,Ka=null,Ga=null,Fi=new Map,Xi=new Map,Fa=[],ES="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Kg(e,t){switch(e){case"focusin":case"focusout":Ya=null;break;case"dragenter":case"dragleave":Ka=null;break;case"mouseover":case"mouseout":Ga=null;break;case"pointerover":case"pointerout":Fi.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xi.delete(t.pointerId)}}function Qi(e,t,r,o,c,d){return e===null||e.nativeEvent!==d?(e={blockedOn:t,domEventName:r,eventSystemFlags:o,nativeEvent:d,targetContainers:[c]},t!==null&&(t=et(t),t!==null&&qg(t)),e):(e.eventSystemFlags|=o,t=e.targetContainers,c!==null&&t.indexOf(c)===-1&&t.push(c),e)}function RS(e,t,r,o,c){switch(t){case"focusin":return Ya=Qi(Ya,e,t,r,o,c),!0;case"dragenter":return Ka=Qi(Ka,e,t,r,o,c),!0;case"mouseover":return Ga=Qi(Ga,e,t,r,o,c),!0;case"pointerover":var d=c.pointerId;return Fi.set(d,Qi(Fi.get(d)||null,e,t,r,o,c)),!0;case"gotpointercapture":return d=c.pointerId,Xi.set(d,Qi(Xi.get(d)||null,e,t,r,o,c)),!0}return!1}function Gg(e){var t=Ve(e.target);if(t!==null){var r=u(t);if(r!==null){if(t=r.tag,t===13){if(t=f(r),t!==null){e.blockedOn=t,B(e.priority,function(){if(r.tag===13){var o=an();o=ai(o);var c=nl(r,o);c!==null&&rn(c,r,o),zf(r,o)}});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function zs(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=Uf(e.nativeEvent);if(r===null){r=e.nativeEvent;var o=new r.constructor(r.type,r);Bu=o,r.target.dispatchEvent(o),Bu=null}else return t=et(r),t!==null&&qg(t),e.blockedOn=r,!1;t.shift()}return!0}function Fg(e,t,r){zs(e)&&r.delete(t)}function CS(){Hf=!1,Ya!==null&&zs(Ya)&&(Ya=null),Ka!==null&&zs(Ka)&&(Ka=null),Ga!==null&&zs(Ga)&&(Ga=null),Fi.forEach(Fg),Xi.forEach(Fg)}function ks(e,t){e.blockedOn===t&&(e.blockedOn=null,Hf||(Hf=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,CS)))}var Us=null;function Xg(e){Us!==e&&(Us=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Us===e&&(Us=null);for(var t=0;t<e.length;t+=3){var r=e[t],o=e[t+1],c=e[t+2];if(typeof o!="function"){if(Pf(o||r)===null)continue;break}var d=et(r);d!==null&&(e.splice(t,3),t-=3,Uc(d,{pending:!0,data:c,method:r.method,action:o},o,c))}}))}function Zi(e){function t(j){return ks(j,e)}Ya!==null&&ks(Ya,e),Ka!==null&&ks(Ka,e),Ga!==null&&ks(Ga,e),Fi.forEach(t),Xi.forEach(t);for(var r=0;r<Fa.length;r++){var o=Fa[r];o.blockedOn===e&&(o.blockedOn=null)}for(;0<Fa.length&&(r=Fa[0],r.blockedOn===null);)Gg(r),r.blockedOn===null&&Fa.shift();if(r=(e.ownerDocument||e).$$reactFormReplay,r!=null)for(o=0;o<r.length;o+=3){var c=r[o],d=r[o+1],b=c[ce]||null;if(typeof d=="function")b||Xg(r);else if(b){var E=null;if(d&&d.hasAttribute("formAction")){if(c=d,b=d[ce]||null)E=b.formAction;else if(Pf(c)!==null)continue}else E=b.action;typeof E=="function"?r[o+1]=E:(r.splice(o,3),o-=3),Xg(r)}}}function Bf(e){this._internalRoot=e}Ps.prototype.render=Bf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var r=t.current,o=an();$g(r,o,e,t,null,null)},Ps.prototype.unmount=Bf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;$g(e.current,2,null,e,null,null),bs(),t[xe]=null}};function Ps(e){this._internalRoot=e}Ps.prototype.unstable_scheduleHydration=function(e){if(e){var t=M();e={blockedOn:null,target:e,priority:t};for(var r=0;r<Fa.length&&t!==0&&t<Fa[r].priority;r++);Fa.splice(r,0,e),r===0&&Gg(e)}};var Qg=a.version;if(Qg!=="19.1.0")throw Error(i(527,Qg,"19.1.0"));Z.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(i(188)):(e=Object.keys(e).join(","),Error(i(268,e)));return e=p(t),e=e!==null?m(e):null,e=e===null?null:e.stateNode,e};var OS={bundleType:0,version:"19.1.0",rendererPackageName:"react-dom",currentDispatcherRef:_,reconcilerVersion:"19.1.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Hs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Hs.isDisabled&&Hs.supportsFiber)try{Yt=Hs.inject(OS),mt=Hs}catch{}}return Wi.createRoot=function(e,t){if(!s(e))throw Error(i(299));var r=!1,o="",c=fp,d=dp,b=hp,E=null;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(o=t.identifierPrefix),t.onUncaughtError!==void 0&&(c=t.onUncaughtError),t.onCaughtError!==void 0&&(d=t.onCaughtError),t.onRecoverableError!==void 0&&(b=t.onRecoverableError),t.unstable_transitionCallbacks!==void 0&&(E=t.unstable_transitionCallbacks)),t=Hg(e,1,!1,null,null,r,o,c,d,b,E,null),e[xe]=t.current,wf(e),new Bf(t)},Wi.hydrateRoot=function(e,t,r){if(!s(e))throw Error(i(299));var o=!1,c="",d=fp,b=dp,E=hp,j=null,q=null;return r!=null&&(r.unstable_strictMode===!0&&(o=!0),r.identifierPrefix!==void 0&&(c=r.identifierPrefix),r.onUncaughtError!==void 0&&(d=r.onUncaughtError),r.onCaughtError!==void 0&&(b=r.onCaughtError),r.onRecoverableError!==void 0&&(E=r.onRecoverableError),r.unstable_transitionCallbacks!==void 0&&(j=r.unstable_transitionCallbacks),r.formState!==void 0&&(q=r.formState)),t=Hg(e,1,!0,t,r??null,o,c,d,b,E,j,q),t.context=Bg(null),r=t.current,o=an(),o=ai(o),c=ja(o),c.callback=null,Ma(r,c,o),r=o,t.current.lanes=r,fr(t,r),$n(t),e[xe]=t.current,wf(e),new Ps(t)},Wi.version="19.1.0",Wi}var Cv;function Qw(){if(Cv)return Yf.exports;Cv=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(a){console.error(a)}}return n(),Yf.exports=Xw(),Yf.exports}var Zw=Qw();/**
|
|
56
56
|
* react-router v7.7.0
|
|
57
57
|
*
|
|
58
58
|
* Copyright (c) Remix Software Inc.
|
|
@@ -61,10 +61,10 @@ Error generating stack: `+r.message+`
|
|
|
61
61
|
* LICENSE.md file in the root directory of this source tree.
|
|
62
62
|
*
|
|
63
63
|
* @license MIT
|
|
64
|
-
*/var Vy=n=>{throw TypeError(n)},Jw=(n,a,l)=>a.has(n)||Vy("Cannot "+l),Xf=(n,a,l)=>(Jw(n,a,"read from private field"),l?l.call(n):a.get(n)),Iw=(n,a,l)=>a.has(n)?Vy("Cannot add the same private member more than once"):a instanceof WeakSet?a.add(n):a.set(n,l);function Ww(n={}){let{initialEntries:a=["/"],initialIndex:l,v5Compat:i=!1}=n,s;s=a.map((w,C)=>g(w,typeof w=="string"?null:w.state,C===0?"default":void 0));let u=p(l??s.length-1),f="POP",h=null;function p(w){return Math.min(Math.max(w,0),s.length-1)}function m(){return s[u]}function g(w,C=null,R){let T=xd(s?m().pathname:"/",w,C,R);return St(T.pathname.charAt(0)==="/",`relative pathnames are not supported in memory history: ${JSON.stringify(w)}`),T}function x(w){return typeof w=="string"?w:tr(w)}return{get index(){return u},get action(){return f},get location(){return m()},createHref:x,createURL(w){return new URL(x(w),"http://localhost")},encodeLocation(w){let C=typeof w=="string"?Ea(w):w;return{pathname:C.pathname||"",search:C.search||"",hash:C.hash||""}},push(w,C){f="PUSH";let R=g(w,C);u+=1,s.splice(u,s.length,R),i&&h&&h({action:f,location:R,delta:1})},replace(w,C){f="REPLACE";let R=g(w,C);s[u]=R,i&&h&&h({action:f,location:R,delta:0})},go(w){f="POP";let C=p(u+w),R=s[C];u=C,h&&h({action:f,location:R,delta:w})},listen(w){return h=w,()=>{h=null}}}}function Fe(n,a){if(n===!1||n===null||typeof n>"u")throw new Error(a)}function St(n,a){if(!n){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function eE(){return Math.random().toString(36).substring(2,10)}function xd(n,a,l=null,i){return{pathname:typeof n=="string"?n:n.pathname,search:"",hash:"",...typeof a=="string"?Ea(a):a,state:l,key:a&&a.key||i||eE()}}function tr({pathname:n="/",search:a="",hash:l=""}){return a&&a!=="?"&&(n+=a.charAt(0)==="?"?a:"?"+a),l&&l!=="#"&&(n+=l.charAt(0)==="#"?l:"#"+l),n}function Ea(n){let a={};if(n){let l=n.indexOf("#");l>=0&&(a.hash=n.substring(l),n=n.substring(0,l));let i=n.indexOf("?");i>=0&&(a.search=n.substring(i),n=n.substring(0,i)),n&&(a.pathname=n)}return a}function tE(n,a=!1){let l="http://localhost";typeof window<"u"&&(l=window.location.origin!=="null"?window.location.origin:window.location.href),Fe(l,"No window.location.(origin|href) available to create URL");let i=typeof n=="string"?n:tr(n);return i=i.replace(/ $/,"%20"),!a&&i.startsWith("//")&&(i=l+i),new URL(i,l)}var lo,Ov=class{constructor(n){if(Iw(this,lo,new Map),n)for(let[a,l]of n)this.set(a,l)}get(n){if(Xf(this,lo).has(n))return Xf(this,lo).get(n);if(n.defaultValue!==void 0)return n.defaultValue;throw new Error("No value found for context")}set(n,a){Xf(this,lo).set(n,a)}};lo=new WeakMap;var nE=new Set(["lazy","caseSensitive","path","id","index","children"]);function aE(n){return nE.has(n)}var rE=new Set(["lazy","caseSensitive","path","id","index","unstable_middleware","children"]);function lE(n){return rE.has(n)}function iE(n){return n.index===!0}function fo(n,a,l=[],i={},s=!1){return n.map((u,f)=>{let h=[...l,String(f)],p=typeof u.id=="string"?u.id:h.join("-");if(Fe(u.index!==!0||!u.children,"Cannot specify children on an index route"),Fe(s||!i[p],`Found a route id collision on id "${p}". Route id's must be globally unique within Data Router usages`),iE(u)){let m={...u,...a(u),id:p};return i[p]=m,m}else{let m={...u,...a(u),id:p,children:void 0};return i[p]=m,u.children&&(m.children=fo(u.children,a,h,i,s)),m}})}function Ia(n,a,l="/"){return Ws(n,a,l,!1)}function Ws(n,a,l,i){let s=typeof a=="string"?Ea(a):a,u=Rn(s.pathname||"/",l);if(u==null)return null;let f=qy(n);sE(f);let h=null;for(let p=0;h==null&&p<f.length;++p){let m=bE(u);h=vE(f[p],m,i)}return h}function oE(n,a){let{route:l,pathname:i,params:s}=n;return{id:l.id,pathname:i,params:s,data:a[l.id],handle:l.handle}}function qy(n,a=[],l=[],i=""){let s=(u,f,h)=>{let p={relativePath:h===void 0?u.path||"":h,caseSensitive:u.caseSensitive===!0,childrenIndex:f,route:u};p.relativePath.startsWith("/")&&(Fe(p.relativePath.startsWith(i),`Absolute route path "${p.relativePath}" nested under path "${i}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),p.relativePath=p.relativePath.slice(i.length));let m=Kn([i,p.relativePath]),g=l.concat(p);u.children&&u.children.length>0&&(Fe(u.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${m}".`),qy(u.children,a,g,m)),!(u.path==null&&!u.index)&&a.push({path:m,score:pE(m,u.index),routesMeta:g})};return n.forEach((u,f)=>{if(u.path===""||!u.path?.includes("?"))s(u,f);else for(let h of Yy(u.path))s(u,f,h)}),a}function Yy(n){let a=n.split("/");if(a.length===0)return[];let[l,...i]=a,s=l.endsWith("?"),u=l.replace(/\?$/,"");if(i.length===0)return s?[u,""]:[u];let f=Yy(i.join("/")),h=[];return h.push(...f.map(p=>p===""?u:[u,p].join("/"))),s&&h.push(...f),h.map(p=>n.startsWith("/")&&p===""?"/":p)}function sE(n){n.sort((a,l)=>a.score!==l.score?l.score-a.score:gE(a.routesMeta.map(i=>i.childrenIndex),l.routesMeta.map(i=>i.childrenIndex)))}var uE=/^:[\w-]+$/,cE=3,fE=2,dE=1,hE=10,mE=-2,Av=n=>n==="*";function pE(n,a){let l=n.split("/"),i=l.length;return l.some(Av)&&(i+=mE),a&&(i+=fE),l.filter(s=>!Av(s)).reduce((s,u)=>s+(uE.test(u)?cE:u===""?dE:hE),i)}function gE(n,a){return n.length===a.length&&n.slice(0,-1).every((i,s)=>i===a[s])?n[n.length-1]-a[a.length-1]:0}function vE(n,a,l=!1){let{routesMeta:i}=n,s={},u="/",f=[];for(let h=0;h<i.length;++h){let p=i[h],m=h===i.length-1,g=u==="/"?a:a.slice(u.length)||"/",x=uu({path:p.relativePath,caseSensitive:p.caseSensitive,end:m},g),S=p.route;if(!x&&m&&l&&!i[i.length-1].route.index&&(x=uu({path:p.relativePath,caseSensitive:p.caseSensitive,end:!1},g)),!x)return null;Object.assign(s,x.params),f.push({params:s,pathname:Kn([u,x.pathname]),pathnameBase:EE(Kn([u,x.pathnameBase])),route:S}),x.pathnameBase!=="/"&&(u=Kn([u,x.pathnameBase]))}return f}function uu(n,a){typeof n=="string"&&(n={path:n,caseSensitive:!1,end:!0});let[l,i]=yE(n.path,n.caseSensitive,n.end),s=a.match(l);if(!s)return null;let u=s[0],f=u.replace(/(.)\/+$/,"$1"),h=s.slice(1);return{params:i.reduce((m,{paramName:g,isOptional:x},S)=>{if(g==="*"){let C=h[S]||"";f=u.slice(0,u.length-C.length).replace(/(.)\/+$/,"$1")}const w=h[S];return x&&!w?m[g]=void 0:m[g]=(w||"").replace(/%2F/g,"/"),m},{}),pathname:u,pathnameBase:f,pattern:n}}function yE(n,a=!1,l=!0){St(n==="*"||!n.endsWith("*")||n.endsWith("/*"),`Route path "${n}" will be treated as if it were "${n.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${n.replace(/\*$/,"/*")}".`);let i=[],s="^"+n.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(f,h,p)=>(i.push({paramName:h,isOptional:p!=null}),p?"/?([^\\/]+)?":"/([^\\/]+)"));return n.endsWith("*")?(i.push({paramName:"*"}),s+=n==="*"||n==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):l?s+="\\/*$":n!==""&&n!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,a?void 0:"i"),i]}function bE(n){try{return n.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return St(!1,`The URL path "${n}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${a}).`),n}}function Rn(n,a){if(a==="/")return n;if(!n.toLowerCase().startsWith(a.toLowerCase()))return null;let l=a.endsWith("/")?a.length-1:a.length,i=n.charAt(l);return i&&i!=="/"?null:n.slice(l)||"/"}function xE({basename:n,pathname:a}){return a==="/"?n:Kn([n,a])}function SE(n,a="/"){let{pathname:l,search:i="",hash:s=""}=typeof n=="string"?Ea(n):n;return{pathname:l?l.startsWith("/")?l:wE(l,a):a,search:RE(i),hash:CE(s)}}function wE(n,a){let l=a.replace(/\/+$/,"").split("/");return n.split("/").forEach(s=>{s===".."?l.length>1&&l.pop():s!=="."&&l.push(s)}),l.length>1?l.join("/"):"/"}function Qf(n,a,l,i){return`Cannot include a '${n}' character in a manually specified \`to.${a}\` field [${JSON.stringify(i)}]. Please separate it out to the \`to.${l}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Ky(n){return n.filter((a,l)=>l===0||a.route.path&&a.route.path.length>0)}function bu(n){let a=Ky(n);return a.map((l,i)=>i===a.length-1?l.pathname:l.pathnameBase)}function xu(n,a,l,i=!1){let s;typeof n=="string"?s=Ea(n):(s={...n},Fe(!s.pathname||!s.pathname.includes("?"),Qf("?","pathname","search",s)),Fe(!s.pathname||!s.pathname.includes("#"),Qf("#","pathname","hash",s)),Fe(!s.search||!s.search.includes("#"),Qf("#","search","hash",s)));let u=n===""||s.pathname==="",f=u?"/":s.pathname,h;if(f==null)h=l;else{let x=a.length-1;if(!i&&f.startsWith("..")){let S=f.split("/");for(;S[0]==="..";)S.shift(),x-=1;s.pathname=S.join("/")}h=x>=0?a[x]:"/"}let p=SE(s,h),m=f&&f!=="/"&&f.endsWith("/"),g=(u||f===".")&&l.endsWith("/");return!p.pathname.endsWith("/")&&(m||g)&&(p.pathname+="/"),p}var Kn=n=>n.join("/").replace(/\/\/+/g,"/"),EE=n=>n.replace(/\/+$/,"").replace(/^\/*/,"/"),RE=n=>!n||n==="?"?"":n.startsWith("?")?n:"?"+n,CE=n=>!n||n==="#"?"":n.startsWith("#")?n:"#"+n,Sd=class{constructor(n,a,l,i=!1){this.status=n,this.statusText=a||"",this.internal=i,l instanceof Error?(this.data=l.toString(),this.error=l):this.data=l}};function ho(n){return n!=null&&typeof n.status=="number"&&typeof n.statusText=="string"&&typeof n.internal=="boolean"&&"data"in n}var Gy=["POST","PUT","PATCH","DELETE"],OE=new Set(Gy),AE=["GET",...Gy],NE=new Set(AE),TE=new Set([301,302,303,307,308]),jE=new Set([307,308]),Zf={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},ME={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},eo={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},_E=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Pd=n=>_E.test(n),DE=n=>({hasErrorBoundary:!!n.hasErrorBoundary}),Fy="remix-router-transitions",Xy=Symbol("ResetLoaderData");function LE(n){const a=n.window?n.window:typeof window<"u"?window:void 0,l=typeof a<"u"&&typeof a.document<"u"&&typeof a.document.createElement<"u";Fe(n.routes.length>0,"You must provide a non-empty routes array to createRouter");let i=n.hydrationRouteProperties||[],s=n.mapRouteProperties||DE,u={},f=fo(n.routes,s,void 0,u),h,p=n.basename||"/",m=n.dataStrategy||HE,g={unstable_middleware:!1,...n.future},x=null,S=new Set,w=null,C=null,R=null,T=n.hydrationData!=null,O=Ia(f,n.history.location,p),z=!1,k=null,H;if(O==null&&!n.patchRoutesOnNavigation){let M=En(404,{pathname:n.history.location.pathname}),{matches:B,route:Q}=Hv(f);H=!0,O=B,k={[Q.id]:M}}else if(O&&!n.hydrationData&&dr(O,f,n.history.location.pathname).active&&(O=null),O)if(O.some(M=>M.route.lazy))H=!1;else if(!O.some(M=>M.route.loader))H=!0;else{let M=n.hydrationData?n.hydrationData.loaderData:null,B=n.hydrationData?n.hydrationData.errors:null;if(B){let Q=O.findIndex(le=>B[le.route.id]!==void 0);H=O.slice(0,Q+1).every(le=>!Ed(le.route,M,B))}else H=O.every(Q=>!Ed(Q.route,M,B))}else{H=!1,O=[];let M=dr(null,f,n.history.location.pathname);M.active&&M.matches&&(z=!0,O=M.matches)}let P,A={historyAction:n.history.action,location:n.history.location,matches:O,initialized:H,navigation:Zf,restoreScrollPosition:n.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:n.hydrationData&&n.hydrationData.loaderData||{},actionData:n.hydrationData&&n.hydrationData.actionData||null,errors:n.hydrationData&&n.hydrationData.errors||k,fetchers:new Map,blockers:new Map},G="POP",J=!1,re,ie=!1,Oe=new Map,Ee=null,me=!1,he=!1,fe=new Set,_=new Map,Z=0,$=-1,pe=new Map,N=new Set,Y=new Map,L=new Map,K=new Set,W=new Map,oe,de=null;function ge(){if(x=n.history.listen(({action:M,location:B,delta:Q})=>{if(oe){oe(),oe=void 0;return}St(W.size===0||Q!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let le=Ao({currentLocation:A.location,nextLocation:B,historyAction:M});if(le&&Q!=null){let ce=new Promise(xe=>{oe=xe});n.history.go(Q*-1),zn(le,{state:"blocked",location:B,proceed(){zn(le,{state:"proceeding",proceed:void 0,reset:void 0,location:B}),ce.then(()=>n.history.go(Q))},reset(){let xe=new Map(A.blockers);xe.set(le,eo),je({blockers:xe})}});return}return ue(M,B)}),l){ZE(a,Oe);let M=()=>JE(a,Oe);a.addEventListener("pagehide",M),Ee=()=>a.removeEventListener("pagehide",M)}return A.initialized||ue("POP",A.location,{initialHydration:!0}),P}function ze(){x&&x(),Ee&&Ee(),S.clear(),re&&re.abort(),A.fetchers.forEach((M,B)=>Lt(B)),A.blockers.forEach((M,B)=>cr(B))}function Ze(M){return S.add(M),()=>S.delete(M)}function je(M,B={}){M.matches&&(M.matches=M.matches.map(ce=>{let xe=u[ce.route.id],Re=ce.route;return Re.element!==xe.element||Re.errorElement!==xe.errorElement||Re.hydrateFallbackElement!==xe.hydrateFallbackElement?{...ce,route:xe}:ce})),A={...A,...M};let Q=[],le=[];A.fetchers.forEach((ce,xe)=>{ce.state==="idle"&&(K.has(xe)?Q.push(xe):le.push(xe))}),K.forEach(ce=>{!A.fetchers.has(ce)&&!_.has(ce)&&Q.push(ce)}),[...S].forEach(ce=>ce(A,{deletedFetchers:Q,viewTransitionOpts:B.viewTransitionOpts,flushSync:B.flushSync===!0})),Q.forEach(ce=>Lt(ce)),le.forEach(ce=>A.fetchers.delete(ce))}function ae(M,B,{flushSync:Q}={}){let le=A.actionData!=null&&A.navigation.formMethod!=null&&Qt(A.navigation.formMethod)&&A.navigation.state==="loading"&&M.state?._isRedirect!==!0,ce;B.actionData?Object.keys(B.actionData).length>0?ce=B.actionData:ce=null:le?ce=A.actionData:ce=null;let xe=B.loaderData?Uv(A.loaderData,B.loaderData,B.matches||[],B.errors):A.loaderData,Re=A.blockers;Re.size>0&&(Re=new Map(Re),Re.forEach((we,Ce)=>Re.set(Ce,eo)));let Se=me?!1:To(M,B.matches||A.matches),Te=J===!0||A.navigation.formMethod!=null&&Qt(A.navigation.formMethod)&&M.state?._isRedirect!==!0;h&&(f=h,h=void 0),me||G==="POP"||(G==="PUSH"?n.history.push(M,M.state):G==="REPLACE"&&n.history.replace(M,M.state));let _e;if(G==="POP"){let we=Oe.get(A.location.pathname);we&&we.has(M.pathname)?_e={currentLocation:A.location,nextLocation:M}:Oe.has(M.pathname)&&(_e={currentLocation:M,nextLocation:A.location})}else if(ie){let we=Oe.get(A.location.pathname);we?we.add(M.pathname):(we=new Set([M.pathname]),Oe.set(A.location.pathname,we)),_e={currentLocation:A.location,nextLocation:M}}je({...B,actionData:ce,loaderData:xe,historyAction:G,location:M,initialized:!0,navigation:Zf,revalidation:"idle",restoreScrollPosition:Se,preventScrollReset:Te,blockers:Re},{viewTransitionOpts:_e,flushSync:Q===!0}),G="POP",J=!1,ie=!1,me=!1,he=!1,de?.resolve(),de=null}async function te(M,B){if(typeof M=="number"){n.history.go(M);return}let Q=wd(A.location,A.matches,p,M,B?.fromRouteId,B?.relative),{path:le,submission:ce,error:xe}=Nv(!1,Q,B),Re=A.location,Se=xd(A.location,le,B&&B.state);Se={...Se,...n.history.encodeLocation(Se)};let Te=B&&B.replace!=null?B.replace:void 0,_e="PUSH";Te===!0?_e="REPLACE":Te===!1||ce!=null&&Qt(ce.formMethod)&&ce.formAction===A.location.pathname+A.location.search&&(_e="REPLACE");let we=B&&"preventScrollReset"in B?B.preventScrollReset===!0:void 0,Ce=(B&&B.flushSync)===!0,Ve=Ao({currentLocation:Re,nextLocation:Se,historyAction:_e});if(Ve){zn(Ve,{state:"blocked",location:Se,proceed(){zn(Ve,{state:"proceeding",proceed:void 0,reset:void 0,location:Se}),te(M,B)},reset(){let et=new Map(A.blockers);et.set(Ve,eo),je({blockers:et})}});return}await ue(_e,Se,{submission:ce,pendingError:xe,preventScrollReset:we,replace:B&&B.replace,enableViewTransition:B&&B.viewTransition,flushSync:Ce})}function se(){de||(de=IE()),ni(),je({revalidation:"loading"});let M=de.promise;return A.navigation.state==="submitting"?M:A.navigation.state==="idle"?(ue(A.historyAction,A.location,{startUninterruptedRevalidation:!0}),M):(ue(G||A.historyAction,A.navigation.location,{overrideNavigation:A.navigation,enableViewTransition:ie===!0}),M)}async function ue(M,B,Q){re&&re.abort(),re=null,G=M,me=(Q&&Q.startUninterruptedRevalidation)===!0,fr(A.location,A.matches),J=(Q&&Q.preventScrollReset)===!0,ie=(Q&&Q.enableViewTransition)===!0;let le=h||f,ce=Q&&Q.overrideNavigation,xe=Q?.initialHydration&&A.matches&&A.matches.length>0&&!z?A.matches:Ia(le,B,p),Re=(Q&&Q.flushSync)===!0;if(xe&&A.initialized&&!he&&KE(A.location,B)&&!(Q&&Q.submission&&Qt(Q.submission.formMethod))){ae(B,{matches:xe},{flushSync:Re});return}let Se=dr(xe,le,B.pathname);if(Se.active&&Se.matches&&(xe=Se.matches),!xe){let{error:yt,notFoundMatches:Be,route:at}=Kr(B.pathname);ae(B,{matches:Be,loaderData:{},errors:{[at.id]:yt}},{flushSync:Re});return}re=new AbortController;let Te=Ll(n.history,B,re.signal,Q&&Q.submission),_e=new Ov(n.unstable_getContext?await n.unstable_getContext():void 0),we;if(Q&&Q.pendingError)we=[_r(xe).route.id,{type:"error",error:Q.pendingError}];else if(Q&&Q.submission&&Qt(Q.submission.formMethod)){let yt=await Ne(Te,B,Q.submission,xe,_e,Se.active,Q&&Q.initialHydration===!0,{replace:Q.replace,flushSync:Re});if(yt.shortCircuited)return;if(yt.pendingActionResult){let[Be,at]=yt.pendingActionResult;if(on(at)&&ho(at.error)&&at.error.status===404){re=null,ae(B,{matches:yt.matches,loaderData:{},errors:{[Be]:at.error}});return}}xe=yt.matches||xe,we=yt.pendingActionResult,ce=Jf(B,Q.submission),Re=!1,Se.active=!1,Te=Ll(n.history,Te.url,Te.signal)}let{shortCircuited:Ce,matches:Ve,loaderData:et,errors:vt}=await Ue(Te,B,xe,_e,Se.active,ce,Q&&Q.submission,Q&&Q.fetcherSubmission,Q&&Q.replace,Q&&Q.initialHydration===!0,Re,we);Ce||(re=null,ae(B,{matches:Ve||xe,...Pv(we),loaderData:et,errors:vt}))}async function Ne(M,B,Q,le,ce,xe,Re,Se={}){ni();let Te=XE(B,Q);if(je({navigation:Te},{flushSync:Se.flushSync===!0}),xe){let Ce=await hr(le,B.pathname,M.signal);if(Ce.type==="aborted")return{shortCircuited:!0};if(Ce.type==="error"){let Ve=_r(Ce.partialMatches).route.id;return{matches:Ce.partialMatches,pendingActionResult:[Ve,{type:"error",error:Ce.error}]}}else if(Ce.matches)le=Ce.matches;else{let{notFoundMatches:Ve,error:et,route:vt}=Kr(B.pathname);return{matches:Ve,pendingActionResult:[vt.id,{type:"error",error:et}]}}}let _e,we=eu(le,B);if(!we.route.action&&!we.route.lazy)_e={type:"error",error:En(405,{method:M.method,pathname:B.pathname,routeId:we.route.id})};else{let Ce=Pl(s,u,M,le,we,Re?[]:i,ce),Ve=await Ra(M,Ce,ce,null);if(_e=Ve[we.route.id],!_e){for(let et of le)if(Ve[et.route.id]){_e=Ve[et.route.id];break}}if(M.signal.aborted)return{shortCircuited:!0}}if(Dr(_e)){let Ce;return Se&&Se.replace!=null?Ce=Se.replace:Ce=Lv(_e.response.headers.get("Location"),new URL(M.url),p)===A.location.pathname+A.location.search,await Jn(M,_e,!0,{submission:Q,replace:Ce}),{shortCircuited:!0}}if(on(_e)){let Ce=_r(le,we.route.id);return(Se&&Se.replace)!==!0&&(G="PUSH"),{matches:le,pendingActionResult:[Ce.route.id,_e,we.route.id]}}return{matches:le,pendingActionResult:[we.route.id,_e]}}async function Ue(M,B,Q,le,ce,xe,Re,Se,Te,_e,we,Ce){let Ve=xe||Jf(B,Re),et=Re||Se||$v(Ve),vt=!me&&!_e;if(ce){if(vt){let Ct=Me(Ce);je({navigation:Ve,...Ct!==void 0?{actionData:Ct}:{}},{flushSync:we})}let Ke=await hr(Q,B.pathname,M.signal);if(Ke.type==="aborted")return{shortCircuited:!0};if(Ke.type==="error"){let Ct=_r(Ke.partialMatches).route.id;return{matches:Ke.partialMatches,loaderData:{},errors:{[Ct]:Ke.error}}}else if(Ke.matches)Q=Ke.matches;else{let{error:Ct,notFoundMatches:mr,route:hn}=Kr(B.pathname);return{matches:mr,loaderData:{},errors:{[hn.id]:Ct}}}}let yt=h||f,{dsMatches:Be,revalidatingFetchers:at}=Tv(M,le,s,u,n.history,A,Q,et,B,_e?[]:i,_e===!0,he,fe,K,Y,N,yt,p,n.patchRoutesOnNavigation!=null,Ce);if($=++Z,!n.dataStrategy&&!Be.some(Ke=>Ke.shouldLoad)&&at.length===0){let Ke=sr();return ae(B,{matches:Q,loaderData:{},errors:Ce&&on(Ce[1])?{[Ce[0]]:Ce[1].error}:null,...Pv(Ce),...Ke?{fetchers:new Map(A.fetchers)}:{}},{flushSync:we}),{shortCircuited:!0}}if(vt){let Ke={};if(!ce){Ke.navigation=Ve;let Ct=Me(Ce);Ct!==void 0&&(Ke.actionData=Ct)}at.length>0&&(Ke.fetchers=ot(at)),je(Ke,{flushSync:we})}at.forEach(Ke=>{Ln(Ke.key),Ke.controller&&_.set(Ke.key,Ke.controller)});let kn=()=>at.forEach(Ke=>Ln(Ke.key));re&&re.signal.addEventListener("abort",kn);let{loaderResults:It,fetcherResults:Vt}=await Co(Be,at,M,le);if(M.signal.aborted)return{shortCircuited:!0};re&&re.signal.removeEventListener("abort",kn),at.forEach(Ke=>_.delete(Ke.key));let dn=$s(It);if(dn)return await Jn(M,dn.result,!0,{replace:Te}),{shortCircuited:!0};if(dn=$s(Vt),dn)return N.add(dn.key),await Jn(M,dn.result,!0,{replace:Te}),{shortCircuited:!0};let{loaderData:Fr,errors:Ca}=kv(A,Q,It,Ce,at,Vt);_e&&A.errors&&(Ca={...A.errors,...Ca});let Wn=sr(),ea=ur($),ta=Wn||ea||at.length>0;return{matches:Q,loaderData:Fr,errors:Ca,...ta?{fetchers:new Map(A.fetchers)}:{}}}function Me(M){if(M&&!on(M[1]))return{[M[0]]:M[1].data};if(A.actionData)return Object.keys(A.actionData).length===0?null:A.actionData}function ot(M){return M.forEach(B=>{let Q=A.fetchers.get(B.key),le=to(void 0,Q?Q.data:void 0);A.fetchers.set(B.key,le)}),new Map(A.fetchers)}async function Cn(M,B,Q,le){Ln(M);let ce=(le&&le.flushSync)===!0,xe=h||f,Re=wd(A.location,A.matches,p,Q,B,le?.relative),Se=Ia(xe,Re,p),Te=dr(Se,xe,Re);if(Te.active&&Te.matches&&(Se=Te.matches),!Se){mt(M,B,En(404,{pathname:Re}),{flushSync:ce});return}let{path:_e,submission:we,error:Ce}=Nv(!0,Re,le);if(Ce){mt(M,B,Ce,{flushSync:ce});return}let Ve=new Ov(n.unstable_getContext?await n.unstable_getContext():void 0),et=(le&&le.preventScrollReset)===!0;if(we&&Qt(we.formMethod)){await qr(M,B,_e,Se,Ve,Te.active,ce,et,we);return}Y.set(M,{routeId:B,path:_e}),await Yr(M,B,_e,Se,Ve,Te.active,ce,et,we)}async function qr(M,B,Q,le,ce,xe,Re,Se,Te){ni(),Y.delete(M);let _e=A.fetchers.get(M);Yt(M,QE(Te,_e),{flushSync:Re});let we=new AbortController,Ce=Ll(n.history,Q,we.signal,Te);if(xe){let pt=await hr(le,new URL(Ce.url).pathname,Ce.signal,M);if(pt.type==="aborted")return;if(pt.type==="error"){mt(M,B,pt.error,{flushSync:Re});return}else if(pt.matches)le=pt.matches;else{mt(M,B,En(404,{pathname:Q}),{flushSync:Re});return}}let Ve=eu(le,Q);if(!Ve.route.action&&!Ve.route.lazy){let pt=En(405,{method:Te.formMethod,pathname:Q,routeId:B});mt(M,B,pt,{flushSync:Re});return}_.set(M,we);let et=Z,vt=Pl(s,u,Ce,le,Ve,i,ce),Be=(await Ra(Ce,vt,ce,M))[Ve.route.id];if(Ce.signal.aborted){_.get(M)===we&&_.delete(M);return}if(K.has(M)){if(Dr(Be)||on(Be)){Yt(M,Za(void 0));return}}else{if(Dr(Be))if(_.delete(M),$>et){Yt(M,Za(void 0));return}else return N.add(M),Yt(M,to(Te)),Jn(Ce,Be,!1,{fetcherSubmission:Te,preventScrollReset:Se});if(on(Be)){mt(M,B,Be.error);return}}let at=A.navigation.location||A.location,kn=Ll(n.history,at,we.signal),It=h||f,Vt=A.navigation.state!=="idle"?Ia(It,A.navigation.location,p):A.matches;Fe(Vt,"Didn't find any matches after fetcher action");let dn=++Z;pe.set(M,dn);let Fr=to(Te,Be.data);A.fetchers.set(M,Fr);let{dsMatches:Ca,revalidatingFetchers:Wn}=Tv(kn,ce,s,u,n.history,A,Vt,Te,at,i,!1,he,fe,K,Y,N,It,p,n.patchRoutesOnNavigation!=null,[Ve.route.id,Be]);Wn.filter(pt=>pt.key!==M).forEach(pt=>{let Oa=pt.key,jo=A.fetchers.get(Oa),Mo=to(void 0,jo?jo.data:void 0);A.fetchers.set(Oa,Mo),Ln(Oa),pt.controller&&_.set(Oa,pt.controller)}),je({fetchers:new Map(A.fetchers)});let ea=()=>Wn.forEach(pt=>Ln(pt.key));we.signal.addEventListener("abort",ea);let{loaderResults:ta,fetcherResults:Ke}=await Co(Ca,Wn,kn,ce);if(we.signal.aborted)return;if(we.signal.removeEventListener("abort",ea),pe.delete(M),_.delete(M),Wn.forEach(pt=>_.delete(pt.key)),A.fetchers.has(M)){let pt=Za(Be.data);A.fetchers.set(M,pt)}let Ct=$s(ta);if(Ct)return Jn(kn,Ct.result,!1,{preventScrollReset:Se});if(Ct=$s(Ke),Ct)return N.add(Ct.key),Jn(kn,Ct.result,!1,{preventScrollReset:Se});let{loaderData:mr,errors:hn}=kv(A,Vt,ta,void 0,Wn,Ke);ur(dn),A.navigation.state==="loading"&&dn>$?(Fe(G,"Expected pending action"),re&&re.abort(),ae(A.navigation.location,{matches:Vt,loaderData:mr,errors:hn,fetchers:new Map(A.fetchers)})):(je({errors:hn,loaderData:Uv(A.loaderData,mr,Vt,hn),fetchers:new Map(A.fetchers)}),he=!1)}async function Yr(M,B,Q,le,ce,xe,Re,Se,Te){let _e=A.fetchers.get(M);Yt(M,to(Te,_e?_e.data:void 0),{flushSync:Re});let we=new AbortController,Ce=Ll(n.history,Q,we.signal);if(xe){let at=await hr(le,new URL(Ce.url).pathname,Ce.signal,M);if(at.type==="aborted")return;if(at.type==="error"){mt(M,B,at.error,{flushSync:Re});return}else if(at.matches)le=at.matches;else{mt(M,B,En(404,{pathname:Q}),{flushSync:Re});return}}let Ve=eu(le,Q);_.set(M,we);let et=Z,vt=Pl(s,u,Ce,le,Ve,i,ce),Be=(await Ra(Ce,vt,ce,M))[Ve.route.id];if(_.get(M)===we&&_.delete(M),!Ce.signal.aborted){if(K.has(M)){Yt(M,Za(void 0));return}if(Dr(Be))if($>et){Yt(M,Za(void 0));return}else{N.add(M),await Jn(Ce,Be,!1,{preventScrollReset:Se});return}if(on(Be)){mt(M,B,Be.error);return}Yt(M,Za(Be.data))}}async function Jn(M,B,Q,{submission:le,fetcherSubmission:ce,preventScrollReset:xe,replace:Re}={}){B.response.headers.has("X-Remix-Revalidate")&&(he=!0);let Se=B.response.headers.get("Location");Fe(Se,"Expected a Location header on the redirect Response"),Se=Lv(Se,new URL(M.url),p);let Te=xd(A.location,Se,{_isRedirect:!0});if(l){let vt=!1;if(B.response.headers.has("X-Remix-Reload-Document"))vt=!0;else if(Pd(Se)){const yt=tE(Se,!0);vt=yt.origin!==a.location.origin||Rn(yt.pathname,p)==null}if(vt){Re?a.location.replace(Se):a.location.assign(Se);return}}re=null;let _e=Re===!0||B.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:we,formAction:Ce,formEncType:Ve}=A.navigation;!le&&!ce&&we&&Ce&&Ve&&(le=$v(A.navigation));let et=le||ce;if(jE.has(B.response.status)&&et&&Qt(et.formMethod))await ue(_e,Te,{submission:{...et,formAction:Se},preventScrollReset:xe||J,enableViewTransition:Q?ie:void 0});else{let vt=Jf(Te,le);await ue(_e,Te,{overrideNavigation:vt,fetcherSubmission:ce,preventScrollReset:xe||J,enableViewTransition:Q?ie:void 0})}}async function Ra(M,B,Q,le){let ce,xe={};try{ce=await BE(m,M,B,le,Q,!1)}catch(Re){return B.filter(Se=>Se.shouldLoad).forEach(Se=>{xe[Se.route.id]={type:"error",error:Re}}),xe}if(M.signal.aborted)return xe;for(let[Re,Se]of Object.entries(ce))if(GE(Se)){let Te=Se.result;xe[Re]={type:"redirect",response:qE(Te,M,Re,B,p)}}else xe[Re]=await VE(Se);return xe}async function Co(M,B,Q,le){let ce=Ra(Q,M,le,null),xe=Promise.all(B.map(async Te=>{if(Te.matches&&Te.match&&Te.request&&Te.controller){let we=(await Ra(Te.request,Te.matches,le,Te.key))[Te.match.route.id];return{[Te.key]:we}}else return Promise.resolve({[Te.key]:{type:"error",error:En(404,{pathname:Te.path})}})})),Re=await ce,Se=(await xe).reduce((Te,_e)=>Object.assign(Te,_e),{});return{loaderResults:Re,fetcherResults:Se}}function ni(){he=!0,Y.forEach((M,B)=>{_.has(B)&&fe.add(B),Ln(B)})}function Yt(M,B,Q={}){A.fetchers.set(M,B),je({fetchers:new Map(A.fetchers)},{flushSync:(Q&&Q.flushSync)===!0})}function mt(M,B,Q,le={}){let ce=_r(A.matches,B);Lt(M),je({errors:{[ce.route.id]:Q},fetchers:new Map(A.fetchers)},{flushSync:(le&&le.flushSync)===!0})}function On(M){return L.set(M,(L.get(M)||0)+1),K.has(M)&&K.delete(M),A.fetchers.get(M)||ME}function Lt(M){let B=A.fetchers.get(M);_.has(M)&&!(B&&B.state==="loading"&&pe.has(M))&&Ln(M),Y.delete(M),pe.delete(M),N.delete(M),K.delete(M),fe.delete(M),A.fetchers.delete(M)}function ku(M){let B=(L.get(M)||0)-1;B<=0?(L.delete(M),K.add(M)):L.set(M,B),je({fetchers:new Map(A.fetchers)})}function Ln(M){let B=_.get(M);B&&(B.abort(),_.delete(M))}function Oo(M){for(let B of M){let Q=On(B),le=Za(Q.data);A.fetchers.set(B,le)}}function sr(){let M=[],B=!1;for(let Q of N){let le=A.fetchers.get(Q);Fe(le,`Expected fetcher: ${Q}`),le.state==="loading"&&(N.delete(Q),M.push(Q),B=!0)}return Oo(M),B}function ur(M){let B=[];for(let[Q,le]of pe)if(le<M){let ce=A.fetchers.get(Q);Fe(ce,`Expected fetcher: ${Q}`),ce.state==="loading"&&(Ln(Q),pe.delete(Q),B.push(Q))}return Oo(B),B.length>0}function In(M,B){let Q=A.blockers.get(M)||eo;return W.get(M)!==B&&W.set(M,B),Q}function cr(M){A.blockers.delete(M),W.delete(M)}function zn(M,B){let Q=A.blockers.get(M)||eo;Fe(Q.state==="unblocked"&&B.state==="blocked"||Q.state==="blocked"&&B.state==="blocked"||Q.state==="blocked"&&B.state==="proceeding"||Q.state==="blocked"&&B.state==="unblocked"||Q.state==="proceeding"&&B.state==="unblocked",`Invalid blocker state transition: ${Q.state} -> ${B.state}`);let le=new Map(A.blockers);le.set(M,B),je({blockers:le})}function Ao({currentLocation:M,nextLocation:B,historyAction:Q}){if(W.size===0)return;W.size>1&&St(!1,"A router only supports one blocker at a time");let le=Array.from(W.entries()),[ce,xe]=le[le.length-1],Re=A.blockers.get(ce);if(!(Re&&Re.state==="proceeding")&&xe({currentLocation:M,nextLocation:B,historyAction:Q}))return ce}function Kr(M){let B=En(404,{pathname:M}),Q=h||f,{matches:le,route:ce}=Hv(Q);return{notFoundMatches:le,route:ce,error:B}}function No(M,B,Q){if(w=M,R=B,C=Q||null,!T&&A.navigation===Zf){T=!0;let le=To(A.location,A.matches);le!=null&&je({restoreScrollPosition:le})}return()=>{w=null,R=null,C=null}}function Gr(M,B){return C&&C(M,B.map(le=>oE(le,A.loaderData)))||M.key}function fr(M,B){if(w&&R){let Q=Gr(M,B);w[Q]=R()}}function To(M,B){if(w){let Q=Gr(M,B),le=w[Q];if(typeof le=="number")return le}return null}function dr(M,B,Q){if(n.patchRoutesOnNavigation)if(M){if(Object.keys(M[0].params).length>0)return{active:!0,matches:Ws(B,Q,p,!0)}}else return{active:!0,matches:Ws(B,Q,p,!0)||[]};return{active:!1,matches:null}}async function hr(M,B,Q,le){if(!n.patchRoutesOnNavigation)return{type:"success",matches:M};let ce=M;for(;;){let xe=h==null,Re=h||f,Se=u;try{await n.patchRoutesOnNavigation({signal:Q,path:B,matches:ce,fetcherKey:le,patch:(we,Ce)=>{Q.aborted||jv(we,Ce,Re,Se,s,!1)}})}catch(we){return{type:"error",error:we,partialMatches:ce}}finally{xe&&!Q.aborted&&(f=[...f])}if(Q.aborted)return{type:"aborted"};let Te=Ia(Re,B,p);if(Te)return{type:"success",matches:Te};let _e=Ws(Re,B,p,!0);if(!_e||ce.length===_e.length&&ce.every((we,Ce)=>we.route.id===_e[Ce].route.id))return{type:"success",matches:null};ce=_e}}function ai(M){u={},h=fo(M,s,void 0,u)}function ri(M,B,Q=!1){let le=h==null;jv(M,B,h||f,u,s,Q),le&&(f=[...f],je({}))}return P={get basename(){return p},get future(){return g},get state(){return A},get routes(){return f},get window(){return a},initialize:ge,subscribe:Ze,enableScrollRestoration:No,navigate:te,fetch:Cn,revalidate:se,createHref:M=>n.history.createHref(M),encodeLocation:M=>n.history.encodeLocation(M),getFetcher:On,deleteFetcher:ku,dispose:ze,getBlocker:In,deleteBlocker:cr,patchRoutes:ri,_internalFetchControllers:_,_internalSetRoutes:ai,_internalSetStateDoNotUseOrYouWillBreakYourApp(M){je(M)}},P}function zE(n){return n!=null&&("formData"in n&&n.formData!=null||"body"in n&&n.body!==void 0)}function wd(n,a,l,i,s,u){let f,h;if(s){f=[];for(let m of a)if(f.push(m),m.route.id===s){h=m;break}}else f=a,h=a[a.length-1];let p=xu(i||".",bu(f),Rn(n.pathname,l)||n.pathname,u==="path");if(i==null&&(p.search=n.search,p.hash=n.hash),(i==null||i===""||i===".")&&h){let m=Hd(p.search);if(h.route.index&&!m)p.search=p.search?p.search.replace(/^\?/,"?index&"):"?index";else if(!h.route.index&&m){let g=new URLSearchParams(p.search),x=g.getAll("index");g.delete("index"),x.filter(w=>w).forEach(w=>g.append("index",w));let S=g.toString();p.search=S?`?${S}`:""}}return l!=="/"&&(p.pathname=xE({basename:l,pathname:p.pathname})),tr(p)}function Nv(n,a,l){if(!l||!zE(l))return{path:a};if(l.formMethod&&!FE(l.formMethod))return{path:a,error:En(405,{method:l.formMethod})};let i=()=>({path:a,error:En(400,{type:"invalid-body"})}),u=(l.formMethod||"get").toUpperCase(),f=e0(a);if(l.body!==void 0){if(l.formEncType==="text/plain"){if(!Qt(u))return i();let x=typeof l.body=="string"?l.body:l.body instanceof FormData||l.body instanceof URLSearchParams?Array.from(l.body.entries()).reduce((S,[w,C])=>`${S}${w}=${C}
|
|
65
|
-
`,""):String(l.body);return{path:a,submission:{formMethod:u,formAction:f,formEncType:l.formEncType,formData:void 0,json:void 0,text:x}}}else if(l.formEncType==="application/json"){if(!Qt(u))return i();try{let x=typeof l.body=="string"?JSON.parse(l.body):l.body;return{path:a,submission:{formMethod:u,formAction:f,formEncType:l.formEncType,formData:void 0,json:x,text:void 0}}}catch{return i()}}}Fe(typeof FormData=="function","FormData is not available in this environment");let h,p;if(l.formData)h=Cd(l.formData),p=l.formData;else if(l.body instanceof FormData)h=Cd(l.body),p=l.body;else if(l.body instanceof URLSearchParams)h=l.body,p=zv(h);else if(l.body==null)h=new URLSearchParams,p=new FormData;else try{h=new URLSearchParams(l.body),p=zv(h)}catch{return i()}let m={formMethod:u,formAction:f,formEncType:l&&l.formEncType||"application/x-www-form-urlencoded",formData:p,json:void 0,text:void 0};if(Qt(m.formMethod))return{path:a,submission:m};let g=Ea(a);return n&&g.search&&Hd(g.search)&&h.append("index",""),g.search=`?${h}`,{path:tr(g),submission:m}}function Tv(n,a,l,i,s,u,f,h,p,m,g,x,S,w,C,R,T,O,z,k){let H=k?on(k[1])?k[1].error:k[1].data:void 0,P=s.createURL(u.location),A=s.createURL(p),G;if(g&&u.errors){let me=Object.keys(u.errors)[0];G=f.findIndex(he=>he.route.id===me)}else if(k&&on(k[1])){let me=k[0];G=f.findIndex(he=>he.route.id===me)-1}let J=k?k[1].statusCode:void 0,re=J&&J>=400,ie={currentUrl:P,currentParams:u.matches[0]?.params||{},nextUrl:A,nextParams:f[0].params,...h,actionResult:H,actionStatus:J},Oe=f.map((me,he)=>{let{route:fe}=me,_=null;if(G!=null&&he>G?_=!1:fe.lazy?_=!0:fe.loader==null?_=!1:g?_=Ed(fe,u.loaderData,u.errors):kE(u.loaderData,u.matches[he],me)&&(_=!0),_!==null)return Rd(l,i,n,me,m,a,_);let Z=re?!1:x||P.pathname+P.search===A.pathname+A.search||P.search!==A.search||UE(u.matches[he],me),$={...ie,defaultShouldRevalidate:Z},pe=cu(me,$);return Rd(l,i,n,me,m,a,pe,$)}),Ee=[];return C.forEach((me,he)=>{if(g||!f.some(L=>L.route.id===me.routeId)||w.has(he))return;let fe=u.fetchers.get(he),_=fe&&fe.state!=="idle"&&fe.data===void 0,Z=Ia(T,me.path,O);if(!Z){if(z&&_)return;Ee.push({key:he,routeId:me.routeId,path:me.path,matches:null,match:null,request:null,controller:null});return}if(R.has(he))return;let $=eu(Z,me.path),pe=new AbortController,N=Ll(s,me.path,pe.signal),Y=null;if(S.has(he))S.delete(he),Y=Pl(l,i,N,Z,$,m,a);else if(_)x&&(Y=Pl(l,i,N,Z,$,m,a));else{let L={...ie,defaultShouldRevalidate:re?!1:x};cu($,L)&&(Y=Pl(l,i,N,Z,$,m,a,L))}Y&&Ee.push({key:he,routeId:me.routeId,path:me.path,matches:Y,match:$,request:N,controller:pe})}),{dsMatches:Oe,revalidatingFetchers:Ee}}function Ed(n,a,l){if(n.lazy)return!0;if(!n.loader)return!1;let i=a!=null&&n.id in a,s=l!=null&&l[n.id]!==void 0;return!i&&s?!1:typeof n.loader=="function"&&n.loader.hydrate===!0?!0:!i&&!s}function kE(n,a,l){let i=!a||l.route.id!==a.route.id,s=!n.hasOwnProperty(l.route.id);return i||s}function UE(n,a){let l=n.route.path;return n.pathname!==a.pathname||l!=null&&l.endsWith("*")&&n.params["*"]!==a.params["*"]}function cu(n,a){if(n.route.shouldRevalidate){let l=n.route.shouldRevalidate(a);if(typeof l=="boolean")return l}return a.defaultShouldRevalidate}function jv(n,a,l,i,s,u){let f;if(n){let m=i[n];Fe(m,`No route found to patch children into: routeId = ${n}`),m.children||(m.children=[]),f=m.children}else f=l;let h=[],p=[];if(a.forEach(m=>{let g=f.find(x=>Qy(m,x));g?p.push({existingRoute:g,newRoute:m}):h.push(m)}),h.length>0){let m=fo(h,s,[n||"_","patch",String(f?.length||"0")],i);f.push(...m)}if(u&&p.length>0)for(let m=0;m<p.length;m++){let{existingRoute:g,newRoute:x}=p[m],S=g,[w]=fo([x],s,[],{},!0);Object.assign(S,{element:w.element?w.element:S.element,errorElement:w.errorElement?w.errorElement:S.errorElement,hydrateFallbackElement:w.hydrateFallbackElement?w.hydrateFallbackElement:S.hydrateFallbackElement})}}function Qy(n,a){return"id"in n&&"id"in a&&n.id===a.id?!0:n.index===a.index&&n.path===a.path&&n.caseSensitive===a.caseSensitive?(!n.children||n.children.length===0)&&(!a.children||a.children.length===0)?!0:n.children.every((l,i)=>a.children?.some(s=>Qy(l,s))):!1}var Mv=new WeakMap,Zy=({key:n,route:a,manifest:l,mapRouteProperties:i})=>{let s=l[a.id];if(Fe(s,"No route found in manifest"),!s.lazy||typeof s.lazy!="object")return;let u=s.lazy[n];if(!u)return;let f=Mv.get(s);f||(f={},Mv.set(s,f));let h=f[n];if(h)return h;let p=(async()=>{let m=aE(n),x=s[n]!==void 0&&n!=="hasErrorBoundary";if(m)St(!m,"Route property "+n+" is not a supported lazy route property. This property will be ignored."),f[n]=Promise.resolve();else if(x)St(!1,`Route "${s.id}" has a static property "${n}" defined. The lazy property will be ignored.`);else{let S=await u();S!=null&&(Object.assign(s,{[n]:S}),Object.assign(s,i(s)))}typeof s.lazy=="object"&&(s.lazy[n]=void 0,Object.values(s.lazy).every(S=>S===void 0)&&(s.lazy=void 0))})();return f[n]=p,p},_v=new WeakMap;function PE(n,a,l,i,s){let u=l[n.id];if(Fe(u,"No route found in manifest"),!n.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof n.lazy=="function"){let g=_v.get(u);if(g)return{lazyRoutePromise:g,lazyHandlerPromise:g};let x=(async()=>{Fe(typeof n.lazy=="function","No lazy route function found");let S=await n.lazy(),w={};for(let C in S){let R=S[C];if(R===void 0)continue;let T=lE(C),z=u[C]!==void 0&&C!=="hasErrorBoundary";T?St(!T,"Route property "+C+" is not a supported property to be returned from a lazy route function. This property will be ignored."):z?St(!z,`Route "${u.id}" has a static property "${C}" defined but its lazy function is also returning a value for this property. The lazy route property "${C}" will be ignored.`):w[C]=R}Object.assign(u,w),Object.assign(u,{...i(u),lazy:void 0})})();return _v.set(u,x),x.catch(()=>{}),{lazyRoutePromise:x,lazyHandlerPromise:x}}let f=Object.keys(n.lazy),h=[],p;for(let g of f){if(s&&s.includes(g))continue;let x=Zy({key:g,route:n,manifest:l,mapRouteProperties:i});x&&(h.push(x),g===a&&(p=x))}let m=h.length>0?Promise.all(h).then(()=>{}):void 0;return m?.catch(()=>{}),p?.catch(()=>{}),{lazyRoutePromise:m,lazyHandlerPromise:p}}async function Dv(n){let a=n.matches.filter(s=>s.shouldLoad),l={};return(await Promise.all(a.map(s=>s.resolve()))).forEach((s,u)=>{l[a[u].route.id]=s}),l}async function HE(n){return n.matches.some(a=>a.route.unstable_middleware)?Jy(n,!1,()=>Dv(n),(a,l)=>({[l]:{type:"error",result:a}})):Dv(n)}async function Jy(n,a,l,i){let{matches:s,request:u,params:f,context:h}=n,p={handlerResult:void 0};try{let m=s.flatMap(x=>x.route.unstable_middleware?x.route.unstable_middleware.map(S=>[x.route.id,S]):[]),g=await Iy({request:u,params:f,context:h},m,a,p,l);return a?g:p.handlerResult}catch(m){if(!p.middlewareError)throw m;let g=await i(p.middlewareError.error,p.middlewareError.routeId);return p.handlerResult?Object.assign(p.handlerResult,g):g}}async function Iy(n,a,l,i,s,u=0){let{request:f}=n;if(f.signal.aborted)throw f.signal.reason?f.signal.reason:new Error(`Request aborted without an \`AbortSignal.reason\`: ${f.method} ${f.url}`);let h=a[u];if(!h)return i.handlerResult=await s(),i.handlerResult;let[p,m]=h,g=!1,x,S=async()=>{if(g)throw new Error("You may only call `next()` once per middleware");g=!0,await Iy(n,a,l,i,s,u+1)};try{let w=await m({request:n.request,params:n.params,context:n.context},S);return g?w===void 0?x:w:S()}catch(w){throw i.middlewareError?i.middlewareError.error!==w&&(i.middlewareError={routeId:p,error:w}):i.middlewareError={routeId:p,error:w},w}}function Wy(n,a,l,i,s){let u=Zy({key:"unstable_middleware",route:i.route,manifest:a,mapRouteProperties:n}),f=PE(i.route,Qt(l.method)?"action":"loader",a,n,s);return{middleware:u,route:f.lazyRoutePromise,handler:f.lazyHandlerPromise}}function Rd(n,a,l,i,s,u,f,h=null){let p=!1,m=Wy(n,a,l,i,s);return{...i,_lazyPromises:m,shouldLoad:f,unstable_shouldRevalidateArgs:h,unstable_shouldCallHandler(g){return p=!0,h?typeof g=="boolean"?cu(i,{...h,defaultShouldRevalidate:g}):cu(i,h):f},resolve(g){return p||f||g&&!Qt(l.method)&&(i.route.lazy||i.route.loader)?$E({request:l,match:i,lazyHandlerPromise:m?.handler,lazyRoutePromise:m?.route,handlerOverride:g,scopedContext:u}):Promise.resolve({type:"data",result:void 0})}}}function Pl(n,a,l,i,s,u,f,h=null){return i.map(p=>p.route.id!==s.route.id?{...p,shouldLoad:!1,unstable_shouldRevalidateArgs:h,unstable_shouldCallHandler:()=>!1,_lazyPromises:Wy(n,a,l,p,u),resolve:()=>Promise.resolve({type:"data",result:void 0})}:Rd(n,a,l,p,u,f,!0,h))}async function BE(n,a,l,i,s,u){l.some(m=>m._lazyPromises?.middleware)&&await Promise.all(l.map(m=>m._lazyPromises?.middleware));let f={request:a,params:l[0].params,context:s,matches:l},p=await n({...f,fetcherKey:i,unstable_runClientMiddleware:m=>{let g=f;return Jy(g,!1,()=>m({...g,fetcherKey:i,unstable_runClientMiddleware:()=>{throw new Error("Cannot call `unstable_runClientMiddleware()` from within an `unstable_runClientMiddleware` handler")}}),(x,S)=>({[S]:{type:"error",result:x}}))}});try{await Promise.all(l.flatMap(m=>[m._lazyPromises?.handler,m._lazyPromises?.route]))}catch{}return p}async function $E({request:n,match:a,lazyHandlerPromise:l,lazyRoutePromise:i,handlerOverride:s,scopedContext:u}){let f,h,p=Qt(n.method),m=p?"action":"loader",g=x=>{let S,w=new Promise((T,O)=>S=O);h=()=>S(),n.signal.addEventListener("abort",h);let C=T=>typeof x!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${m}" [routeId: ${a.route.id}]`)):x({request:n,params:a.params,context:u},...T!==void 0?[T]:[]),R=(async()=>{try{return{type:"data",result:await(s?s(O=>C(O)):C())}}catch(T){return{type:"error",result:T}}})();return Promise.race([R,w])};try{let x=p?a.route.action:a.route.loader;if(l||i)if(x){let S,[w]=await Promise.all([g(x).catch(C=>{S=C}),l,i]);if(S!==void 0)throw S;f=w}else{await l;let S=p?a.route.action:a.route.loader;if(S)[f]=await Promise.all([g(S),i]);else if(m==="action"){let w=new URL(n.url),C=w.pathname+w.search;throw En(405,{method:n.method,pathname:C,routeId:a.route.id})}else return{type:"data",result:void 0}}else if(x)f=await g(x);else{let S=new URL(n.url),w=S.pathname+S.search;throw En(404,{pathname:w})}}catch(x){return{type:"error",result:x}}finally{h&&n.signal.removeEventListener("abort",h)}return f}async function VE(n){let{result:a,type:l}=n;if(t0(a)){let i;try{let s=a.headers.get("Content-Type");s&&/\bapplication\/json\b/.test(s)?a.body==null?i=null:i=await a.json():i=await a.text()}catch(s){return{type:"error",error:s}}return l==="error"?{type:"error",error:new Sd(a.status,a.statusText,i),statusCode:a.status,headers:a.headers}:{type:"data",data:i,statusCode:a.status,headers:a.headers}}return l==="error"?Bv(a)?a.data instanceof Error?{type:"error",error:a.data,statusCode:a.init?.status,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"error",error:new Sd(a.init?.status||500,void 0,a.data),statusCode:ho(a)?a.status:void 0,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"error",error:a,statusCode:ho(a)?a.status:void 0}:Bv(a)?{type:"data",data:a.data,statusCode:a.init?.status,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"data",data:a}}function qE(n,a,l,i,s){let u=n.headers.get("Location");if(Fe(u,"Redirects returned/thrown from loaders/actions must have a Location header"),!Pd(u)){let f=i.slice(0,i.findIndex(h=>h.route.id===l)+1);u=wd(new URL(a.url),f,s,u),n.headers.set("Location",u)}return n}function Lv(n,a,l){if(Pd(n)){let i=n,s=i.startsWith("//")?new URL(a.protocol+i):new URL(i),u=Rn(s.pathname,l)!=null;if(s.origin===a.origin&&u)return s.pathname+s.search+s.hash}return n}function Ll(n,a,l,i){let s=n.createURL(e0(a)).toString(),u={signal:l};if(i&&Qt(i.formMethod)){let{formMethod:f,formEncType:h}=i;u.method=f.toUpperCase(),h==="application/json"?(u.headers=new Headers({"Content-Type":h}),u.body=JSON.stringify(i.json)):h==="text/plain"?u.body=i.text:h==="application/x-www-form-urlencoded"&&i.formData?u.body=Cd(i.formData):u.body=i.formData}return new Request(s,u)}function Cd(n){let a=new URLSearchParams;for(let[l,i]of n.entries())a.append(l,typeof i=="string"?i:i.name);return a}function zv(n){let a=new FormData;for(let[l,i]of n.entries())a.append(l,i);return a}function YE(n,a,l,i=!1,s=!1){let u={},f=null,h,p=!1,m={},g=l&&on(l[1])?l[1].error:void 0;return n.forEach(x=>{if(!(x.route.id in a))return;let S=x.route.id,w=a[S];if(Fe(!Dr(w),"Cannot handle redirect results in processLoaderData"),on(w)){let C=w.error;if(g!==void 0&&(C=g,g=void 0),f=f||{},s)f[S]=C;else{let R=_r(n,S);f[R.route.id]==null&&(f[R.route.id]=C)}i||(u[S]=Xy),p||(p=!0,h=ho(w.error)?w.error.status:500),w.headers&&(m[S]=w.headers)}else u[S]=w.data,w.statusCode&&w.statusCode!==200&&!p&&(h=w.statusCode),w.headers&&(m[S]=w.headers)}),g!==void 0&&l&&(f={[l[0]]:g},l[2]&&(u[l[2]]=void 0)),{loaderData:u,errors:f,statusCode:h||200,loaderHeaders:m}}function kv(n,a,l,i,s,u){let{loaderData:f,errors:h}=YE(a,l,i);return s.filter(p=>!p.matches||p.matches.some(m=>m.shouldLoad)).forEach(p=>{let{key:m,match:g,controller:x}=p,S=u[m];if(Fe(S,"Did not find corresponding fetcher result"),!(x&&x.signal.aborted))if(on(S)){let w=_r(n.matches,g?.route.id);h&&h[w.route.id]||(h={...h,[w.route.id]:S.error}),n.fetchers.delete(m)}else if(Dr(S))Fe(!1,"Unhandled fetcher revalidation redirect");else{let w=Za(S.data);n.fetchers.set(m,w)}}),{loaderData:f,errors:h}}function Uv(n,a,l,i){let s=Object.entries(a).filter(([,u])=>u!==Xy).reduce((u,[f,h])=>(u[f]=h,u),{});for(let u of l){let f=u.route.id;if(!a.hasOwnProperty(f)&&n.hasOwnProperty(f)&&u.route.loader&&(s[f]=n[f]),i&&i.hasOwnProperty(f))break}return s}function Pv(n){return n?on(n[1])?{actionData:{}}:{actionData:{[n[0]]:n[1].data}}:{}}function _r(n,a){return(a?n.slice(0,n.findIndex(i=>i.route.id===a)+1):[...n]).reverse().find(i=>i.route.hasErrorBoundary===!0)||n[0]}function Hv(n){let a=n.length===1?n[0]:n.find(l=>l.index||!l.path||l.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:a}],route:a}}function En(n,{pathname:a,routeId:l,method:i,type:s,message:u}={}){let f="Unknown Server Error",h="Unknown @remix-run/router error";return n===400?(f="Bad Request",i&&a&&l?h=`You made a ${i} request to "${a}" but did not provide a \`loader\` for route "${l}", so there is no way to handle the request.`:s==="invalid-body"&&(h="Unable to encode submission body")):n===403?(f="Forbidden",h=`Route "${l}" does not match URL "${a}"`):n===404?(f="Not Found",h=`No route matches URL "${a}"`):n===405&&(f="Method Not Allowed",i&&a&&l?h=`You made a ${i.toUpperCase()} request to "${a}" but did not provide an \`action\` for route "${l}", so there is no way to handle the request.`:i&&(h=`Invalid request method "${i.toUpperCase()}"`)),new Sd(n||500,f,new Error(h),!0)}function $s(n){let a=Object.entries(n);for(let l=a.length-1;l>=0;l--){let[i,s]=a[l];if(Dr(s))return{key:i,result:s}}}function e0(n){let a=typeof n=="string"?Ea(n):n;return tr({...a,hash:""})}function KE(n,a){return n.pathname!==a.pathname||n.search!==a.search?!1:n.hash===""?a.hash!=="":n.hash===a.hash?!0:a.hash!==""}function GE(n){return t0(n.result)&&TE.has(n.result.status)}function on(n){return n.type==="error"}function Dr(n){return(n&&n.type)==="redirect"}function Bv(n){return typeof n=="object"&&n!=null&&"type"in n&&"data"in n&&"init"in n&&n.type==="DataWithResponseInit"}function t0(n){return n!=null&&typeof n.status=="number"&&typeof n.statusText=="string"&&typeof n.headers=="object"&&typeof n.body<"u"}function FE(n){return NE.has(n.toUpperCase())}function Qt(n){return OE.has(n.toUpperCase())}function Hd(n){return new URLSearchParams(n).getAll("index").some(a=>a==="")}function eu(n,a){let l=typeof a=="string"?Ea(a).search:a.search;if(n[n.length-1].route.index&&Hd(l||""))return n[n.length-1];let i=Ky(n);return i[i.length-1]}function $v(n){let{formMethod:a,formAction:l,formEncType:i,text:s,formData:u,json:f}=n;if(!(!a||!l||!i)){if(s!=null)return{formMethod:a,formAction:l,formEncType:i,formData:void 0,json:void 0,text:s};if(u!=null)return{formMethod:a,formAction:l,formEncType:i,formData:u,json:void 0,text:void 0};if(f!==void 0)return{formMethod:a,formAction:l,formEncType:i,formData:void 0,json:f,text:void 0}}}function Jf(n,a){return a?{state:"loading",location:n,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}:{state:"loading",location:n,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function XE(n,a){return{state:"submitting",location:n,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}}function to(n,a){return n?{state:"loading",formMethod:n.formMethod,formAction:n.formAction,formEncType:n.formEncType,formData:n.formData,json:n.json,text:n.text,data:a}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:a}}function QE(n,a){return{state:"submitting",formMethod:n.formMethod,formAction:n.formAction,formEncType:n.formEncType,formData:n.formData,json:n.json,text:n.text,data:a?a.data:void 0}}function Za(n){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:n}}function ZE(n,a){try{let l=n.sessionStorage.getItem(Fy);if(l){let i=JSON.parse(l);for(let[s,u]of Object.entries(i||{}))u&&Array.isArray(u)&&a.set(s,new Set(u||[]))}}catch{}}function JE(n,a){if(a.size>0){let l={};for(let[i,s]of a)l[i]=[...s];try{n.sessionStorage.setItem(Fy,JSON.stringify(l))}catch(i){St(!1,`Failed to save applied view transitions in sessionStorage (${i}).`)}}}function IE(){let n,a,l=new Promise((i,s)=>{n=async u=>{i(u);try{await l}catch{}},a=async u=>{s(u);try{await l}catch{}}});return{promise:l,resolve:n,reject:a}}var Vr=v.createContext(null);Vr.displayName="DataRouter";var bo=v.createContext(null);bo.displayName="DataRouterState";v.createContext(!1);var Bd=v.createContext({isTransitioning:!1});Bd.displayName="ViewTransition";var n0=v.createContext(new Map);n0.displayName="Fetchers";var WE=v.createContext(null);WE.displayName="Await";var _n=v.createContext(null);_n.displayName="Navigation";var Su=v.createContext(null);Su.displayName="Location";var Qn=v.createContext({outlet:null,matches:[],isDataRoute:!1});Qn.displayName="Route";var $d=v.createContext(null);$d.displayName="RouteError";function eR(n,{relative:a}={}){Fe(Xl(),"useHref() may be used only in the context of a <Router> component.");let{basename:l,navigator:i}=v.useContext(_n),{hash:s,pathname:u,search:f}=xo(n,{relative:a}),h=u;return l!=="/"&&(h=u==="/"?l:Kn([l,u])),i.createHref({pathname:h,search:f,hash:s})}function Xl(){return v.useContext(Su)!=null}function ir(){return Fe(Xl(),"useLocation() may be used only in the context of a <Router> component."),v.useContext(Su).location}var a0="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function r0(n){v.useContext(_n).static||v.useLayoutEffect(n)}function wu(){let{isDataRoute:n}=v.useContext(Qn);return n?hR():tR()}function tR(){Fe(Xl(),"useNavigate() may be used only in the context of a <Router> component.");let n=v.useContext(Vr),{basename:a,navigator:l}=v.useContext(_n),{matches:i}=v.useContext(Qn),{pathname:s}=ir(),u=JSON.stringify(bu(i)),f=v.useRef(!1);return r0(()=>{f.current=!0}),v.useCallback((p,m={})=>{if(St(f.current,a0),!f.current)return;if(typeof p=="number"){l.go(p);return}let g=xu(p,JSON.parse(u),s,m.relative==="path");n==null&&a!=="/"&&(g.pathname=g.pathname==="/"?a:Kn([a,g.pathname])),(m.replace?l.replace:l.push)(g,m.state,m)},[a,l,u,s,n])}v.createContext(null);function xo(n,{relative:a}={}){let{matches:l}=v.useContext(Qn),{pathname:i}=ir(),s=JSON.stringify(bu(l));return v.useMemo(()=>xu(n,JSON.parse(s),i,a==="path"),[n,s,i,a])}function nR(n,a,l,i){Fe(Xl(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:s}=v.useContext(_n),{matches:u}=v.useContext(Qn),f=u[u.length-1],h=f?f.params:{},p=f?f.pathname:"/",m=f?f.pathnameBase:"/",g=f&&f.route;{let O=g&&g.path||"";l0(p,!g||O.endsWith("*")||O.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${p}" (under <Route path="${O}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
64
|
+
*/var Vy=n=>{throw TypeError(n)},Jw=(n,a,l)=>a.has(n)||Vy("Cannot "+l),Xf=(n,a,l)=>(Jw(n,a,"read from private field"),l?l.call(n):a.get(n)),Iw=(n,a,l)=>a.has(n)?Vy("Cannot add the same private member more than once"):a instanceof WeakSet?a.add(n):a.set(n,l);function Ww(n={}){let{initialEntries:a=["/"],initialIndex:l,v5Compat:i=!1}=n,s;s=a.map((w,C)=>g(w,typeof w=="string"?null:w.state,C===0?"default":void 0));let u=p(l??s.length-1),f="POP",h=null;function p(w){return Math.min(Math.max(w,0),s.length-1)}function m(){return s[u]}function g(w,C=null,R){let T=xd(s?m().pathname:"/",w,C,R);return St(T.pathname.charAt(0)==="/",`relative pathnames are not supported in memory history: ${JSON.stringify(w)}`),T}function x(w){return typeof w=="string"?w:tr(w)}return{get index(){return u},get action(){return f},get location(){return m()},createHref:x,createURL(w){return new URL(x(w),"http://localhost")},encodeLocation(w){let C=typeof w=="string"?Ea(w):w;return{pathname:C.pathname||"",search:C.search||"",hash:C.hash||""}},push(w,C){f="PUSH";let R=g(w,C);u+=1,s.splice(u,s.length,R),i&&h&&h({action:f,location:R,delta:1})},replace(w,C){f="REPLACE";let R=g(w,C);s[u]=R,i&&h&&h({action:f,location:R,delta:0})},go(w){f="POP";let C=p(u+w),R=s[C];u=C,h&&h({action:f,location:R,delta:w})},listen(w){return h=w,()=>{h=null}}}}function Fe(n,a){if(n===!1||n===null||typeof n>"u")throw new Error(a)}function St(n,a){if(!n){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function eE(){return Math.random().toString(36).substring(2,10)}function xd(n,a,l=null,i){return{pathname:typeof n=="string"?n:n.pathname,search:"",hash:"",...typeof a=="string"?Ea(a):a,state:l,key:a&&a.key||i||eE()}}function tr({pathname:n="/",search:a="",hash:l=""}){return a&&a!=="?"&&(n+=a.charAt(0)==="?"?a:"?"+a),l&&l!=="#"&&(n+=l.charAt(0)==="#"?l:"#"+l),n}function Ea(n){let a={};if(n){let l=n.indexOf("#");l>=0&&(a.hash=n.substring(l),n=n.substring(0,l));let i=n.indexOf("?");i>=0&&(a.search=n.substring(i),n=n.substring(0,i)),n&&(a.pathname=n)}return a}function tE(n,a=!1){let l="http://localhost";typeof window<"u"&&(l=window.location.origin!=="null"?window.location.origin:window.location.href),Fe(l,"No window.location.(origin|href) available to create URL");let i=typeof n=="string"?n:tr(n);return i=i.replace(/ $/,"%20"),!a&&i.startsWith("//")&&(i=l+i),new URL(i,l)}var lo,Ov=class{constructor(n){if(Iw(this,lo,new Map),n)for(let[a,l]of n)this.set(a,l)}get(n){if(Xf(this,lo).has(n))return Xf(this,lo).get(n);if(n.defaultValue!==void 0)return n.defaultValue;throw new Error("No value found for context")}set(n,a){Xf(this,lo).set(n,a)}};lo=new WeakMap;var nE=new Set(["lazy","caseSensitive","path","id","index","children"]);function aE(n){return nE.has(n)}var rE=new Set(["lazy","caseSensitive","path","id","index","unstable_middleware","children"]);function lE(n){return rE.has(n)}function iE(n){return n.index===!0}function fo(n,a,l=[],i={},s=!1){return n.map((u,f)=>{let h=[...l,String(f)],p=typeof u.id=="string"?u.id:h.join("-");if(Fe(u.index!==!0||!u.children,"Cannot specify children on an index route"),Fe(s||!i[p],`Found a route id collision on id "${p}". Route id's must be globally unique within Data Router usages`),iE(u)){let m={...u,...a(u),id:p};return i[p]=m,m}else{let m={...u,...a(u),id:p,children:void 0};return i[p]=m,u.children&&(m.children=fo(u.children,a,h,i,s)),m}})}function Ia(n,a,l="/"){return Ws(n,a,l,!1)}function Ws(n,a,l,i){let s=typeof a=="string"?Ea(a):a,u=Rn(s.pathname||"/",l);if(u==null)return null;let f=qy(n);sE(f);let h=null;for(let p=0;h==null&&p<f.length;++p){let m=bE(u);h=vE(f[p],m,i)}return h}function oE(n,a){let{route:l,pathname:i,params:s}=n;return{id:l.id,pathname:i,params:s,data:a[l.id],handle:l.handle}}function qy(n,a=[],l=[],i=""){let s=(u,f,h)=>{let p={relativePath:h===void 0?u.path||"":h,caseSensitive:u.caseSensitive===!0,childrenIndex:f,route:u};p.relativePath.startsWith("/")&&(Fe(p.relativePath.startsWith(i),`Absolute route path "${p.relativePath}" nested under path "${i}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),p.relativePath=p.relativePath.slice(i.length));let m=Kn([i,p.relativePath]),g=l.concat(p);u.children&&u.children.length>0&&(Fe(u.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${m}".`),qy(u.children,a,g,m)),!(u.path==null&&!u.index)&&a.push({path:m,score:pE(m,u.index),routesMeta:g})};return n.forEach((u,f)=>{if(u.path===""||!u.path?.includes("?"))s(u,f);else for(let h of Yy(u.path))s(u,f,h)}),a}function Yy(n){let a=n.split("/");if(a.length===0)return[];let[l,...i]=a,s=l.endsWith("?"),u=l.replace(/\?$/,"");if(i.length===0)return s?[u,""]:[u];let f=Yy(i.join("/")),h=[];return h.push(...f.map(p=>p===""?u:[u,p].join("/"))),s&&h.push(...f),h.map(p=>n.startsWith("/")&&p===""?"/":p)}function sE(n){n.sort((a,l)=>a.score!==l.score?l.score-a.score:gE(a.routesMeta.map(i=>i.childrenIndex),l.routesMeta.map(i=>i.childrenIndex)))}var uE=/^:[\w-]+$/,cE=3,fE=2,dE=1,hE=10,mE=-2,Av=n=>n==="*";function pE(n,a){let l=n.split("/"),i=l.length;return l.some(Av)&&(i+=mE),a&&(i+=fE),l.filter(s=>!Av(s)).reduce((s,u)=>s+(uE.test(u)?cE:u===""?dE:hE),i)}function gE(n,a){return n.length===a.length&&n.slice(0,-1).every((i,s)=>i===a[s])?n[n.length-1]-a[a.length-1]:0}function vE(n,a,l=!1){let{routesMeta:i}=n,s={},u="/",f=[];for(let h=0;h<i.length;++h){let p=i[h],m=h===i.length-1,g=u==="/"?a:a.slice(u.length)||"/",x=uu({path:p.relativePath,caseSensitive:p.caseSensitive,end:m},g),S=p.route;if(!x&&m&&l&&!i[i.length-1].route.index&&(x=uu({path:p.relativePath,caseSensitive:p.caseSensitive,end:!1},g)),!x)return null;Object.assign(s,x.params),f.push({params:s,pathname:Kn([u,x.pathname]),pathnameBase:EE(Kn([u,x.pathnameBase])),route:S}),x.pathnameBase!=="/"&&(u=Kn([u,x.pathnameBase]))}return f}function uu(n,a){typeof n=="string"&&(n={path:n,caseSensitive:!1,end:!0});let[l,i]=yE(n.path,n.caseSensitive,n.end),s=a.match(l);if(!s)return null;let u=s[0],f=u.replace(/(.)\/+$/,"$1"),h=s.slice(1);return{params:i.reduce((m,{paramName:g,isOptional:x},S)=>{if(g==="*"){let C=h[S]||"";f=u.slice(0,u.length-C.length).replace(/(.)\/+$/,"$1")}const w=h[S];return x&&!w?m[g]=void 0:m[g]=(w||"").replace(/%2F/g,"/"),m},{}),pathname:u,pathnameBase:f,pattern:n}}function yE(n,a=!1,l=!0){St(n==="*"||!n.endsWith("*")||n.endsWith("/*"),`Route path "${n}" will be treated as if it were "${n.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${n.replace(/\*$/,"/*")}".`);let i=[],s="^"+n.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(f,h,p)=>(i.push({paramName:h,isOptional:p!=null}),p?"/?([^\\/]+)?":"/([^\\/]+)"));return n.endsWith("*")?(i.push({paramName:"*"}),s+=n==="*"||n==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):l?s+="\\/*$":n!==""&&n!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,a?void 0:"i"),i]}function bE(n){try{return n.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return St(!1,`The URL path "${n}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${a}).`),n}}function Rn(n,a){if(a==="/")return n;if(!n.toLowerCase().startsWith(a.toLowerCase()))return null;let l=a.endsWith("/")?a.length-1:a.length,i=n.charAt(l);return i&&i!=="/"?null:n.slice(l)||"/"}function xE({basename:n,pathname:a}){return a==="/"?n:Kn([n,a])}function SE(n,a="/"){let{pathname:l,search:i="",hash:s=""}=typeof n=="string"?Ea(n):n;return{pathname:l?l.startsWith("/")?l:wE(l,a):a,search:RE(i),hash:CE(s)}}function wE(n,a){let l=a.replace(/\/+$/,"").split("/");return n.split("/").forEach(s=>{s===".."?l.length>1&&l.pop():s!=="."&&l.push(s)}),l.length>1?l.join("/"):"/"}function Qf(n,a,l,i){return`Cannot include a '${n}' character in a manually specified \`to.${a}\` field [${JSON.stringify(i)}]. Please separate it out to the \`to.${l}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Ky(n){return n.filter((a,l)=>l===0||a.route.path&&a.route.path.length>0)}function bu(n){let a=Ky(n);return a.map((l,i)=>i===a.length-1?l.pathname:l.pathnameBase)}function xu(n,a,l,i=!1){let s;typeof n=="string"?s=Ea(n):(s={...n},Fe(!s.pathname||!s.pathname.includes("?"),Qf("?","pathname","search",s)),Fe(!s.pathname||!s.pathname.includes("#"),Qf("#","pathname","hash",s)),Fe(!s.search||!s.search.includes("#"),Qf("#","search","hash",s)));let u=n===""||s.pathname==="",f=u?"/":s.pathname,h;if(f==null)h=l;else{let x=a.length-1;if(!i&&f.startsWith("..")){let S=f.split("/");for(;S[0]==="..";)S.shift(),x-=1;s.pathname=S.join("/")}h=x>=0?a[x]:"/"}let p=SE(s,h),m=f&&f!=="/"&&f.endsWith("/"),g=(u||f===".")&&l.endsWith("/");return!p.pathname.endsWith("/")&&(m||g)&&(p.pathname+="/"),p}var Kn=n=>n.join("/").replace(/\/\/+/g,"/"),EE=n=>n.replace(/\/+$/,"").replace(/^\/*/,"/"),RE=n=>!n||n==="?"?"":n.startsWith("?")?n:"?"+n,CE=n=>!n||n==="#"?"":n.startsWith("#")?n:"#"+n,Sd=class{constructor(n,a,l,i=!1){this.status=n,this.statusText=a||"",this.internal=i,l instanceof Error?(this.data=l.toString(),this.error=l):this.data=l}};function ho(n){return n!=null&&typeof n.status=="number"&&typeof n.statusText=="string"&&typeof n.internal=="boolean"&&"data"in n}var Gy=["POST","PUT","PATCH","DELETE"],OE=new Set(Gy),AE=["GET",...Gy],NE=new Set(AE),TE=new Set([301,302,303,307,308]),jE=new Set([307,308]),Zf={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},ME={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},eo={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},_E=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Pd=n=>_E.test(n),DE=n=>({hasErrorBoundary:!!n.hasErrorBoundary}),Fy="remix-router-transitions",Xy=Symbol("ResetLoaderData");function LE(n){const a=n.window?n.window:typeof window<"u"?window:void 0,l=typeof a<"u"&&typeof a.document<"u"&&typeof a.document.createElement<"u";Fe(n.routes.length>0,"You must provide a non-empty routes array to createRouter");let i=n.hydrationRouteProperties||[],s=n.mapRouteProperties||DE,u={},f=fo(n.routes,s,void 0,u),h,p=n.basename||"/",m=n.dataStrategy||HE,g={unstable_middleware:!1,...n.future},x=null,S=new Set,w=null,C=null,R=null,T=n.hydrationData!=null,O=Ia(f,n.history.location,p),z=!1,k=null,H;if(O==null&&!n.patchRoutesOnNavigation){let M=En(404,{pathname:n.history.location.pathname}),{matches:B,route:Q}=Hv(f);H=!0,O=B,k={[Q.id]:M}}else if(O&&!n.hydrationData&&dr(O,f,n.history.location.pathname).active&&(O=null),O)if(O.some(M=>M.route.lazy))H=!1;else if(!O.some(M=>M.route.loader))H=!0;else{let M=n.hydrationData?n.hydrationData.loaderData:null,B=n.hydrationData?n.hydrationData.errors:null;if(B){let Q=O.findIndex(le=>B[le.route.id]!==void 0);H=O.slice(0,Q+1).every(le=>!Ed(le.route,M,B))}else H=O.every(Q=>!Ed(Q.route,M,B))}else{H=!1,O=[];let M=dr(null,f,n.history.location.pathname);M.active&&M.matches&&(z=!0,O=M.matches)}let P,A={historyAction:n.history.action,location:n.history.location,matches:O,initialized:H,navigation:Zf,restoreScrollPosition:n.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:n.hydrationData&&n.hydrationData.loaderData||{},actionData:n.hydrationData&&n.hydrationData.actionData||null,errors:n.hydrationData&&n.hydrationData.errors||k,fetchers:new Map,blockers:new Map},G="POP",J=!1,re,ie=!1,Oe=new Map,Ee=null,me=!1,he=!1,fe=new Set,_=new Map,Z=0,$=-1,pe=new Map,N=new Set,Y=new Map,L=new Map,K=new Set,W=new Map,oe,de=null;function ge(){if(x=n.history.listen(({action:M,location:B,delta:Q})=>{if(oe){oe(),oe=void 0;return}St(W.size===0||Q!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let le=Ao({currentLocation:A.location,nextLocation:B,historyAction:M});if(le&&Q!=null){let ce=new Promise(xe=>{oe=xe});n.history.go(Q*-1),zn(le,{state:"blocked",location:B,proceed(){zn(le,{state:"proceeding",proceed:void 0,reset:void 0,location:B}),ce.then(()=>n.history.go(Q))},reset(){let xe=new Map(A.blockers);xe.set(le,eo),je({blockers:xe})}});return}return ue(M,B)}),l){ZE(a,Oe);let M=()=>JE(a,Oe);a.addEventListener("pagehide",M),Ee=()=>a.removeEventListener("pagehide",M)}return A.initialized||ue("POP",A.location,{initialHydration:!0}),P}function ze(){x&&x(),Ee&&Ee(),S.clear(),re&&re.abort(),A.fetchers.forEach((M,B)=>Lt(B)),A.blockers.forEach((M,B)=>cr(B))}function Ze(M){return S.add(M),()=>S.delete(M)}function je(M,B={}){M.matches&&(M.matches=M.matches.map(ce=>{let xe=u[ce.route.id],Re=ce.route;return Re.element!==xe.element||Re.errorElement!==xe.errorElement||Re.hydrateFallbackElement!==xe.hydrateFallbackElement?{...ce,route:xe}:ce})),A={...A,...M};let Q=[],le=[];A.fetchers.forEach((ce,xe)=>{ce.state==="idle"&&(K.has(xe)?Q.push(xe):le.push(xe))}),K.forEach(ce=>{!A.fetchers.has(ce)&&!_.has(ce)&&Q.push(ce)}),[...S].forEach(ce=>ce(A,{deletedFetchers:Q,viewTransitionOpts:B.viewTransitionOpts,flushSync:B.flushSync===!0})),Q.forEach(ce=>Lt(ce)),le.forEach(ce=>A.fetchers.delete(ce))}function ae(M,B,{flushSync:Q}={}){let le=A.actionData!=null&&A.navigation.formMethod!=null&&Qt(A.navigation.formMethod)&&A.navigation.state==="loading"&&M.state?._isRedirect!==!0,ce;B.actionData?Object.keys(B.actionData).length>0?ce=B.actionData:ce=null:le?ce=A.actionData:ce=null;let xe=B.loaderData?Uv(A.loaderData,B.loaderData,B.matches||[],B.errors):A.loaderData,Re=A.blockers;Re.size>0&&(Re=new Map(Re),Re.forEach((we,Ce)=>Re.set(Ce,eo)));let Se=me?!1:To(M,B.matches||A.matches),Te=J===!0||A.navigation.formMethod!=null&&Qt(A.navigation.formMethod)&&M.state?._isRedirect!==!0;h&&(f=h,h=void 0),me||G==="POP"||(G==="PUSH"?n.history.push(M,M.state):G==="REPLACE"&&n.history.replace(M,M.state));let _e;if(G==="POP"){let we=Oe.get(A.location.pathname);we&&we.has(M.pathname)?_e={currentLocation:A.location,nextLocation:M}:Oe.has(M.pathname)&&(_e={currentLocation:M,nextLocation:A.location})}else if(ie){let we=Oe.get(A.location.pathname);we?we.add(M.pathname):(we=new Set([M.pathname]),Oe.set(A.location.pathname,we)),_e={currentLocation:A.location,nextLocation:M}}je({...B,actionData:ce,loaderData:xe,historyAction:G,location:M,initialized:!0,navigation:Zf,revalidation:"idle",restoreScrollPosition:Se,preventScrollReset:Te,blockers:Re},{viewTransitionOpts:_e,flushSync:Q===!0}),G="POP",J=!1,ie=!1,me=!1,he=!1,de?.resolve(),de=null}async function te(M,B){if(typeof M=="number"){n.history.go(M);return}let Q=wd(A.location,A.matches,p,M,B?.fromRouteId,B?.relative),{path:le,submission:ce,error:xe}=Nv(!1,Q,B),Re=A.location,Se=xd(A.location,le,B&&B.state);Se={...Se,...n.history.encodeLocation(Se)};let Te=B&&B.replace!=null?B.replace:void 0,_e="PUSH";Te===!0?_e="REPLACE":Te===!1||ce!=null&&Qt(ce.formMethod)&&ce.formAction===A.location.pathname+A.location.search&&(_e="REPLACE");let we=B&&"preventScrollReset"in B?B.preventScrollReset===!0:void 0,Ce=(B&&B.flushSync)===!0,Ve=Ao({currentLocation:Re,nextLocation:Se,historyAction:_e});if(Ve){zn(Ve,{state:"blocked",location:Se,proceed(){zn(Ve,{state:"proceeding",proceed:void 0,reset:void 0,location:Se}),te(M,B)},reset(){let et=new Map(A.blockers);et.set(Ve,eo),je({blockers:et})}});return}await ue(_e,Se,{submission:ce,pendingError:xe,preventScrollReset:we,replace:B&&B.replace,enableViewTransition:B&&B.viewTransition,flushSync:Ce})}function se(){de||(de=IE()),ni(),je({revalidation:"loading"});let M=de.promise;return A.navigation.state==="submitting"?M:A.navigation.state==="idle"?(ue(A.historyAction,A.location,{startUninterruptedRevalidation:!0}),M):(ue(G||A.historyAction,A.navigation.location,{overrideNavigation:A.navigation,enableViewTransition:ie===!0}),M)}async function ue(M,B,Q){re&&re.abort(),re=null,G=M,me=(Q&&Q.startUninterruptedRevalidation)===!0,fr(A.location,A.matches),J=(Q&&Q.preventScrollReset)===!0,ie=(Q&&Q.enableViewTransition)===!0;let le=h||f,ce=Q&&Q.overrideNavigation,xe=Q?.initialHydration&&A.matches&&A.matches.length>0&&!z?A.matches:Ia(le,B,p),Re=(Q&&Q.flushSync)===!0;if(xe&&A.initialized&&!he&&KE(A.location,B)&&!(Q&&Q.submission&&Qt(Q.submission.formMethod))){ae(B,{matches:xe},{flushSync:Re});return}let Se=dr(xe,le,B.pathname);if(Se.active&&Se.matches&&(xe=Se.matches),!xe){let{error:yt,notFoundMatches:Be,route:at}=Kr(B.pathname);ae(B,{matches:Be,loaderData:{},errors:{[at.id]:yt}},{flushSync:Re});return}re=new AbortController;let Te=Ll(n.history,B,re.signal,Q&&Q.submission),_e=new Ov(n.unstable_getContext?await n.unstable_getContext():void 0),we;if(Q&&Q.pendingError)we=[_r(xe).route.id,{type:"error",error:Q.pendingError}];else if(Q&&Q.submission&&Qt(Q.submission.formMethod)){let yt=await Ne(Te,B,Q.submission,xe,_e,Se.active,Q&&Q.initialHydration===!0,{replace:Q.replace,flushSync:Re});if(yt.shortCircuited)return;if(yt.pendingActionResult){let[Be,at]=yt.pendingActionResult;if(ln(at)&&ho(at.error)&&at.error.status===404){re=null,ae(B,{matches:yt.matches,loaderData:{},errors:{[Be]:at.error}});return}}xe=yt.matches||xe,we=yt.pendingActionResult,ce=Jf(B,Q.submission),Re=!1,Se.active=!1,Te=Ll(n.history,Te.url,Te.signal)}let{shortCircuited:Ce,matches:Ve,loaderData:et,errors:vt}=await Ue(Te,B,xe,_e,Se.active,ce,Q&&Q.submission,Q&&Q.fetcherSubmission,Q&&Q.replace,Q&&Q.initialHydration===!0,Re,we);Ce||(re=null,ae(B,{matches:Ve||xe,...Pv(we),loaderData:et,errors:vt}))}async function Ne(M,B,Q,le,ce,xe,Re,Se={}){ni();let Te=XE(B,Q);if(je({navigation:Te},{flushSync:Se.flushSync===!0}),xe){let Ce=await hr(le,B.pathname,M.signal);if(Ce.type==="aborted")return{shortCircuited:!0};if(Ce.type==="error"){let Ve=_r(Ce.partialMatches).route.id;return{matches:Ce.partialMatches,pendingActionResult:[Ve,{type:"error",error:Ce.error}]}}else if(Ce.matches)le=Ce.matches;else{let{notFoundMatches:Ve,error:et,route:vt}=Kr(B.pathname);return{matches:Ve,pendingActionResult:[vt.id,{type:"error",error:et}]}}}let _e,we=eu(le,B);if(!we.route.action&&!we.route.lazy)_e={type:"error",error:En(405,{method:M.method,pathname:B.pathname,routeId:we.route.id})};else{let Ce=Pl(s,u,M,le,we,Re?[]:i,ce),Ve=await Ra(M,Ce,ce,null);if(_e=Ve[we.route.id],!_e){for(let et of le)if(Ve[et.route.id]){_e=Ve[et.route.id];break}}if(M.signal.aborted)return{shortCircuited:!0}}if(Dr(_e)){let Ce;return Se&&Se.replace!=null?Ce=Se.replace:Ce=Lv(_e.response.headers.get("Location"),new URL(M.url),p)===A.location.pathname+A.location.search,await Jn(M,_e,!0,{submission:Q,replace:Ce}),{shortCircuited:!0}}if(ln(_e)){let Ce=_r(le,we.route.id);return(Se&&Se.replace)!==!0&&(G="PUSH"),{matches:le,pendingActionResult:[Ce.route.id,_e,we.route.id]}}return{matches:le,pendingActionResult:[we.route.id,_e]}}async function Ue(M,B,Q,le,ce,xe,Re,Se,Te,_e,we,Ce){let Ve=xe||Jf(B,Re),et=Re||Se||$v(Ve),vt=!me&&!_e;if(ce){if(vt){let Ct=Me(Ce);je({navigation:Ve,...Ct!==void 0?{actionData:Ct}:{}},{flushSync:we})}let Ke=await hr(Q,B.pathname,M.signal);if(Ke.type==="aborted")return{shortCircuited:!0};if(Ke.type==="error"){let Ct=_r(Ke.partialMatches).route.id;return{matches:Ke.partialMatches,loaderData:{},errors:{[Ct]:Ke.error}}}else if(Ke.matches)Q=Ke.matches;else{let{error:Ct,notFoundMatches:mr,route:hn}=Kr(B.pathname);return{matches:mr,loaderData:{},errors:{[hn.id]:Ct}}}}let yt=h||f,{dsMatches:Be,revalidatingFetchers:at}=Tv(M,le,s,u,n.history,A,Q,et,B,_e?[]:i,_e===!0,he,fe,K,Y,N,yt,p,n.patchRoutesOnNavigation!=null,Ce);if($=++Z,!n.dataStrategy&&!Be.some(Ke=>Ke.shouldLoad)&&at.length===0){let Ke=sr();return ae(B,{matches:Q,loaderData:{},errors:Ce&&ln(Ce[1])?{[Ce[0]]:Ce[1].error}:null,...Pv(Ce),...Ke?{fetchers:new Map(A.fetchers)}:{}},{flushSync:we}),{shortCircuited:!0}}if(vt){let Ke={};if(!ce){Ke.navigation=Ve;let Ct=Me(Ce);Ct!==void 0&&(Ke.actionData=Ct)}at.length>0&&(Ke.fetchers=ot(at)),je(Ke,{flushSync:we})}at.forEach(Ke=>{Ln(Ke.key),Ke.controller&&_.set(Ke.key,Ke.controller)});let kn=()=>at.forEach(Ke=>Ln(Ke.key));re&&re.signal.addEventListener("abort",kn);let{loaderResults:Jt,fetcherResults:Vt}=await Co(Be,at,M,le);if(M.signal.aborted)return{shortCircuited:!0};re&&re.signal.removeEventListener("abort",kn),at.forEach(Ke=>_.delete(Ke.key));let dn=$s(Jt);if(dn)return await Jn(M,dn.result,!0,{replace:Te}),{shortCircuited:!0};if(dn=$s(Vt),dn)return N.add(dn.key),await Jn(M,dn.result,!0,{replace:Te}),{shortCircuited:!0};let{loaderData:Fr,errors:Ca}=kv(A,Q,Jt,Ce,at,Vt);_e&&A.errors&&(Ca={...A.errors,...Ca});let Wn=sr(),ea=ur($),ta=Wn||ea||at.length>0;return{matches:Q,loaderData:Fr,errors:Ca,...ta?{fetchers:new Map(A.fetchers)}:{}}}function Me(M){if(M&&!ln(M[1]))return{[M[0]]:M[1].data};if(A.actionData)return Object.keys(A.actionData).length===0?null:A.actionData}function ot(M){return M.forEach(B=>{let Q=A.fetchers.get(B.key),le=to(void 0,Q?Q.data:void 0);A.fetchers.set(B.key,le)}),new Map(A.fetchers)}async function Cn(M,B,Q,le){Ln(M);let ce=(le&&le.flushSync)===!0,xe=h||f,Re=wd(A.location,A.matches,p,Q,B,le?.relative),Se=Ia(xe,Re,p),Te=dr(Se,xe,Re);if(Te.active&&Te.matches&&(Se=Te.matches),!Se){mt(M,B,En(404,{pathname:Re}),{flushSync:ce});return}let{path:_e,submission:we,error:Ce}=Nv(!0,Re,le);if(Ce){mt(M,B,Ce,{flushSync:ce});return}let Ve=new Ov(n.unstable_getContext?await n.unstable_getContext():void 0),et=(le&&le.preventScrollReset)===!0;if(we&&Qt(we.formMethod)){await qr(M,B,_e,Se,Ve,Te.active,ce,et,we);return}Y.set(M,{routeId:B,path:_e}),await Yr(M,B,_e,Se,Ve,Te.active,ce,et,we)}async function qr(M,B,Q,le,ce,xe,Re,Se,Te){ni(),Y.delete(M);let _e=A.fetchers.get(M);Yt(M,QE(Te,_e),{flushSync:Re});let we=new AbortController,Ce=Ll(n.history,Q,we.signal,Te);if(xe){let pt=await hr(le,new URL(Ce.url).pathname,Ce.signal,M);if(pt.type==="aborted")return;if(pt.type==="error"){mt(M,B,pt.error,{flushSync:Re});return}else if(pt.matches)le=pt.matches;else{mt(M,B,En(404,{pathname:Q}),{flushSync:Re});return}}let Ve=eu(le,Q);if(!Ve.route.action&&!Ve.route.lazy){let pt=En(405,{method:Te.formMethod,pathname:Q,routeId:B});mt(M,B,pt,{flushSync:Re});return}_.set(M,we);let et=Z,vt=Pl(s,u,Ce,le,Ve,i,ce),Be=(await Ra(Ce,vt,ce,M))[Ve.route.id];if(Ce.signal.aborted){_.get(M)===we&&_.delete(M);return}if(K.has(M)){if(Dr(Be)||ln(Be)){Yt(M,Za(void 0));return}}else{if(Dr(Be))if(_.delete(M),$>et){Yt(M,Za(void 0));return}else return N.add(M),Yt(M,to(Te)),Jn(Ce,Be,!1,{fetcherSubmission:Te,preventScrollReset:Se});if(ln(Be)){mt(M,B,Be.error);return}}let at=A.navigation.location||A.location,kn=Ll(n.history,at,we.signal),Jt=h||f,Vt=A.navigation.state!=="idle"?Ia(Jt,A.navigation.location,p):A.matches;Fe(Vt,"Didn't find any matches after fetcher action");let dn=++Z;pe.set(M,dn);let Fr=to(Te,Be.data);A.fetchers.set(M,Fr);let{dsMatches:Ca,revalidatingFetchers:Wn}=Tv(kn,ce,s,u,n.history,A,Vt,Te,at,i,!1,he,fe,K,Y,N,Jt,p,n.patchRoutesOnNavigation!=null,[Ve.route.id,Be]);Wn.filter(pt=>pt.key!==M).forEach(pt=>{let Oa=pt.key,jo=A.fetchers.get(Oa),Mo=to(void 0,jo?jo.data:void 0);A.fetchers.set(Oa,Mo),Ln(Oa),pt.controller&&_.set(Oa,pt.controller)}),je({fetchers:new Map(A.fetchers)});let ea=()=>Wn.forEach(pt=>Ln(pt.key));we.signal.addEventListener("abort",ea);let{loaderResults:ta,fetcherResults:Ke}=await Co(Ca,Wn,kn,ce);if(we.signal.aborted)return;if(we.signal.removeEventListener("abort",ea),pe.delete(M),_.delete(M),Wn.forEach(pt=>_.delete(pt.key)),A.fetchers.has(M)){let pt=Za(Be.data);A.fetchers.set(M,pt)}let Ct=$s(ta);if(Ct)return Jn(kn,Ct.result,!1,{preventScrollReset:Se});if(Ct=$s(Ke),Ct)return N.add(Ct.key),Jn(kn,Ct.result,!1,{preventScrollReset:Se});let{loaderData:mr,errors:hn}=kv(A,Vt,ta,void 0,Wn,Ke);ur(dn),A.navigation.state==="loading"&&dn>$?(Fe(G,"Expected pending action"),re&&re.abort(),ae(A.navigation.location,{matches:Vt,loaderData:mr,errors:hn,fetchers:new Map(A.fetchers)})):(je({errors:hn,loaderData:Uv(A.loaderData,mr,Vt,hn),fetchers:new Map(A.fetchers)}),he=!1)}async function Yr(M,B,Q,le,ce,xe,Re,Se,Te){let _e=A.fetchers.get(M);Yt(M,to(Te,_e?_e.data:void 0),{flushSync:Re});let we=new AbortController,Ce=Ll(n.history,Q,we.signal);if(xe){let at=await hr(le,new URL(Ce.url).pathname,Ce.signal,M);if(at.type==="aborted")return;if(at.type==="error"){mt(M,B,at.error,{flushSync:Re});return}else if(at.matches)le=at.matches;else{mt(M,B,En(404,{pathname:Q}),{flushSync:Re});return}}let Ve=eu(le,Q);_.set(M,we);let et=Z,vt=Pl(s,u,Ce,le,Ve,i,ce),Be=(await Ra(Ce,vt,ce,M))[Ve.route.id];if(_.get(M)===we&&_.delete(M),!Ce.signal.aborted){if(K.has(M)){Yt(M,Za(void 0));return}if(Dr(Be))if($>et){Yt(M,Za(void 0));return}else{N.add(M),await Jn(Ce,Be,!1,{preventScrollReset:Se});return}if(ln(Be)){mt(M,B,Be.error);return}Yt(M,Za(Be.data))}}async function Jn(M,B,Q,{submission:le,fetcherSubmission:ce,preventScrollReset:xe,replace:Re}={}){B.response.headers.has("X-Remix-Revalidate")&&(he=!0);let Se=B.response.headers.get("Location");Fe(Se,"Expected a Location header on the redirect Response"),Se=Lv(Se,new URL(M.url),p);let Te=xd(A.location,Se,{_isRedirect:!0});if(l){let vt=!1;if(B.response.headers.has("X-Remix-Reload-Document"))vt=!0;else if(Pd(Se)){const yt=tE(Se,!0);vt=yt.origin!==a.location.origin||Rn(yt.pathname,p)==null}if(vt){Re?a.location.replace(Se):a.location.assign(Se);return}}re=null;let _e=Re===!0||B.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:we,formAction:Ce,formEncType:Ve}=A.navigation;!le&&!ce&&we&&Ce&&Ve&&(le=$v(A.navigation));let et=le||ce;if(jE.has(B.response.status)&&et&&Qt(et.formMethod))await ue(_e,Te,{submission:{...et,formAction:Se},preventScrollReset:xe||J,enableViewTransition:Q?ie:void 0});else{let vt=Jf(Te,le);await ue(_e,Te,{overrideNavigation:vt,fetcherSubmission:ce,preventScrollReset:xe||J,enableViewTransition:Q?ie:void 0})}}async function Ra(M,B,Q,le){let ce,xe={};try{ce=await BE(m,M,B,le,Q,!1)}catch(Re){return B.filter(Se=>Se.shouldLoad).forEach(Se=>{xe[Se.route.id]={type:"error",error:Re}}),xe}if(M.signal.aborted)return xe;for(let[Re,Se]of Object.entries(ce))if(GE(Se)){let Te=Se.result;xe[Re]={type:"redirect",response:qE(Te,M,Re,B,p)}}else xe[Re]=await VE(Se);return xe}async function Co(M,B,Q,le){let ce=Ra(Q,M,le,null),xe=Promise.all(B.map(async Te=>{if(Te.matches&&Te.match&&Te.request&&Te.controller){let we=(await Ra(Te.request,Te.matches,le,Te.key))[Te.match.route.id];return{[Te.key]:we}}else return Promise.resolve({[Te.key]:{type:"error",error:En(404,{pathname:Te.path})}})})),Re=await ce,Se=(await xe).reduce((Te,_e)=>Object.assign(Te,_e),{});return{loaderResults:Re,fetcherResults:Se}}function ni(){he=!0,Y.forEach((M,B)=>{_.has(B)&&fe.add(B),Ln(B)})}function Yt(M,B,Q={}){A.fetchers.set(M,B),je({fetchers:new Map(A.fetchers)},{flushSync:(Q&&Q.flushSync)===!0})}function mt(M,B,Q,le={}){let ce=_r(A.matches,B);Lt(M),je({errors:{[ce.route.id]:Q},fetchers:new Map(A.fetchers)},{flushSync:(le&&le.flushSync)===!0})}function On(M){return L.set(M,(L.get(M)||0)+1),K.has(M)&&K.delete(M),A.fetchers.get(M)||ME}function Lt(M){let B=A.fetchers.get(M);_.has(M)&&!(B&&B.state==="loading"&&pe.has(M))&&Ln(M),Y.delete(M),pe.delete(M),N.delete(M),K.delete(M),fe.delete(M),A.fetchers.delete(M)}function ku(M){let B=(L.get(M)||0)-1;B<=0?(L.delete(M),K.add(M)):L.set(M,B),je({fetchers:new Map(A.fetchers)})}function Ln(M){let B=_.get(M);B&&(B.abort(),_.delete(M))}function Oo(M){for(let B of M){let Q=On(B),le=Za(Q.data);A.fetchers.set(B,le)}}function sr(){let M=[],B=!1;for(let Q of N){let le=A.fetchers.get(Q);Fe(le,`Expected fetcher: ${Q}`),le.state==="loading"&&(N.delete(Q),M.push(Q),B=!0)}return Oo(M),B}function ur(M){let B=[];for(let[Q,le]of pe)if(le<M){let ce=A.fetchers.get(Q);Fe(ce,`Expected fetcher: ${Q}`),ce.state==="loading"&&(Ln(Q),pe.delete(Q),B.push(Q))}return Oo(B),B.length>0}function In(M,B){let Q=A.blockers.get(M)||eo;return W.get(M)!==B&&W.set(M,B),Q}function cr(M){A.blockers.delete(M),W.delete(M)}function zn(M,B){let Q=A.blockers.get(M)||eo;Fe(Q.state==="unblocked"&&B.state==="blocked"||Q.state==="blocked"&&B.state==="blocked"||Q.state==="blocked"&&B.state==="proceeding"||Q.state==="blocked"&&B.state==="unblocked"||Q.state==="proceeding"&&B.state==="unblocked",`Invalid blocker state transition: ${Q.state} -> ${B.state}`);let le=new Map(A.blockers);le.set(M,B),je({blockers:le})}function Ao({currentLocation:M,nextLocation:B,historyAction:Q}){if(W.size===0)return;W.size>1&&St(!1,"A router only supports one blocker at a time");let le=Array.from(W.entries()),[ce,xe]=le[le.length-1],Re=A.blockers.get(ce);if(!(Re&&Re.state==="proceeding")&&xe({currentLocation:M,nextLocation:B,historyAction:Q}))return ce}function Kr(M){let B=En(404,{pathname:M}),Q=h||f,{matches:le,route:ce}=Hv(Q);return{notFoundMatches:le,route:ce,error:B}}function No(M,B,Q){if(w=M,R=B,C=Q||null,!T&&A.navigation===Zf){T=!0;let le=To(A.location,A.matches);le!=null&&je({restoreScrollPosition:le})}return()=>{w=null,R=null,C=null}}function Gr(M,B){return C&&C(M,B.map(le=>oE(le,A.loaderData)))||M.key}function fr(M,B){if(w&&R){let Q=Gr(M,B);w[Q]=R()}}function To(M,B){if(w){let Q=Gr(M,B),le=w[Q];if(typeof le=="number")return le}return null}function dr(M,B,Q){if(n.patchRoutesOnNavigation)if(M){if(Object.keys(M[0].params).length>0)return{active:!0,matches:Ws(B,Q,p,!0)}}else return{active:!0,matches:Ws(B,Q,p,!0)||[]};return{active:!1,matches:null}}async function hr(M,B,Q,le){if(!n.patchRoutesOnNavigation)return{type:"success",matches:M};let ce=M;for(;;){let xe=h==null,Re=h||f,Se=u;try{await n.patchRoutesOnNavigation({signal:Q,path:B,matches:ce,fetcherKey:le,patch:(we,Ce)=>{Q.aborted||jv(we,Ce,Re,Se,s,!1)}})}catch(we){return{type:"error",error:we,partialMatches:ce}}finally{xe&&!Q.aborted&&(f=[...f])}if(Q.aborted)return{type:"aborted"};let Te=Ia(Re,B,p);if(Te)return{type:"success",matches:Te};let _e=Ws(Re,B,p,!0);if(!_e||ce.length===_e.length&&ce.every((we,Ce)=>we.route.id===_e[Ce].route.id))return{type:"success",matches:null};ce=_e}}function ai(M){u={},h=fo(M,s,void 0,u)}function ri(M,B,Q=!1){let le=h==null;jv(M,B,h||f,u,s,Q),le&&(f=[...f],je({}))}return P={get basename(){return p},get future(){return g},get state(){return A},get routes(){return f},get window(){return a},initialize:ge,subscribe:Ze,enableScrollRestoration:No,navigate:te,fetch:Cn,revalidate:se,createHref:M=>n.history.createHref(M),encodeLocation:M=>n.history.encodeLocation(M),getFetcher:On,deleteFetcher:ku,dispose:ze,getBlocker:In,deleteBlocker:cr,patchRoutes:ri,_internalFetchControllers:_,_internalSetRoutes:ai,_internalSetStateDoNotUseOrYouWillBreakYourApp(M){je(M)}},P}function zE(n){return n!=null&&("formData"in n&&n.formData!=null||"body"in n&&n.body!==void 0)}function wd(n,a,l,i,s,u){let f,h;if(s){f=[];for(let m of a)if(f.push(m),m.route.id===s){h=m;break}}else f=a,h=a[a.length-1];let p=xu(i||".",bu(f),Rn(n.pathname,l)||n.pathname,u==="path");if(i==null&&(p.search=n.search,p.hash=n.hash),(i==null||i===""||i===".")&&h){let m=Hd(p.search);if(h.route.index&&!m)p.search=p.search?p.search.replace(/^\?/,"?index&"):"?index";else if(!h.route.index&&m){let g=new URLSearchParams(p.search),x=g.getAll("index");g.delete("index"),x.filter(w=>w).forEach(w=>g.append("index",w));let S=g.toString();p.search=S?`?${S}`:""}}return l!=="/"&&(p.pathname=xE({basename:l,pathname:p.pathname})),tr(p)}function Nv(n,a,l){if(!l||!zE(l))return{path:a};if(l.formMethod&&!FE(l.formMethod))return{path:a,error:En(405,{method:l.formMethod})};let i=()=>({path:a,error:En(400,{type:"invalid-body"})}),u=(l.formMethod||"get").toUpperCase(),f=e0(a);if(l.body!==void 0){if(l.formEncType==="text/plain"){if(!Qt(u))return i();let x=typeof l.body=="string"?l.body:l.body instanceof FormData||l.body instanceof URLSearchParams?Array.from(l.body.entries()).reduce((S,[w,C])=>`${S}${w}=${C}
|
|
65
|
+
`,""):String(l.body);return{path:a,submission:{formMethod:u,formAction:f,formEncType:l.formEncType,formData:void 0,json:void 0,text:x}}}else if(l.formEncType==="application/json"){if(!Qt(u))return i();try{let x=typeof l.body=="string"?JSON.parse(l.body):l.body;return{path:a,submission:{formMethod:u,formAction:f,formEncType:l.formEncType,formData:void 0,json:x,text:void 0}}}catch{return i()}}}Fe(typeof FormData=="function","FormData is not available in this environment");let h,p;if(l.formData)h=Cd(l.formData),p=l.formData;else if(l.body instanceof FormData)h=Cd(l.body),p=l.body;else if(l.body instanceof URLSearchParams)h=l.body,p=zv(h);else if(l.body==null)h=new URLSearchParams,p=new FormData;else try{h=new URLSearchParams(l.body),p=zv(h)}catch{return i()}let m={formMethod:u,formAction:f,formEncType:l&&l.formEncType||"application/x-www-form-urlencoded",formData:p,json:void 0,text:void 0};if(Qt(m.formMethod))return{path:a,submission:m};let g=Ea(a);return n&&g.search&&Hd(g.search)&&h.append("index",""),g.search=`?${h}`,{path:tr(g),submission:m}}function Tv(n,a,l,i,s,u,f,h,p,m,g,x,S,w,C,R,T,O,z,k){let H=k?ln(k[1])?k[1].error:k[1].data:void 0,P=s.createURL(u.location),A=s.createURL(p),G;if(g&&u.errors){let me=Object.keys(u.errors)[0];G=f.findIndex(he=>he.route.id===me)}else if(k&&ln(k[1])){let me=k[0];G=f.findIndex(he=>he.route.id===me)-1}let J=k?k[1].statusCode:void 0,re=J&&J>=400,ie={currentUrl:P,currentParams:u.matches[0]?.params||{},nextUrl:A,nextParams:f[0].params,...h,actionResult:H,actionStatus:J},Oe=f.map((me,he)=>{let{route:fe}=me,_=null;if(G!=null&&he>G?_=!1:fe.lazy?_=!0:fe.loader==null?_=!1:g?_=Ed(fe,u.loaderData,u.errors):kE(u.loaderData,u.matches[he],me)&&(_=!0),_!==null)return Rd(l,i,n,me,m,a,_);let Z=re?!1:x||P.pathname+P.search===A.pathname+A.search||P.search!==A.search||UE(u.matches[he],me),$={...ie,defaultShouldRevalidate:Z},pe=cu(me,$);return Rd(l,i,n,me,m,a,pe,$)}),Ee=[];return C.forEach((me,he)=>{if(g||!f.some(L=>L.route.id===me.routeId)||w.has(he))return;let fe=u.fetchers.get(he),_=fe&&fe.state!=="idle"&&fe.data===void 0,Z=Ia(T,me.path,O);if(!Z){if(z&&_)return;Ee.push({key:he,routeId:me.routeId,path:me.path,matches:null,match:null,request:null,controller:null});return}if(R.has(he))return;let $=eu(Z,me.path),pe=new AbortController,N=Ll(s,me.path,pe.signal),Y=null;if(S.has(he))S.delete(he),Y=Pl(l,i,N,Z,$,m,a);else if(_)x&&(Y=Pl(l,i,N,Z,$,m,a));else{let L={...ie,defaultShouldRevalidate:re?!1:x};cu($,L)&&(Y=Pl(l,i,N,Z,$,m,a,L))}Y&&Ee.push({key:he,routeId:me.routeId,path:me.path,matches:Y,match:$,request:N,controller:pe})}),{dsMatches:Oe,revalidatingFetchers:Ee}}function Ed(n,a,l){if(n.lazy)return!0;if(!n.loader)return!1;let i=a!=null&&n.id in a,s=l!=null&&l[n.id]!==void 0;return!i&&s?!1:typeof n.loader=="function"&&n.loader.hydrate===!0?!0:!i&&!s}function kE(n,a,l){let i=!a||l.route.id!==a.route.id,s=!n.hasOwnProperty(l.route.id);return i||s}function UE(n,a){let l=n.route.path;return n.pathname!==a.pathname||l!=null&&l.endsWith("*")&&n.params["*"]!==a.params["*"]}function cu(n,a){if(n.route.shouldRevalidate){let l=n.route.shouldRevalidate(a);if(typeof l=="boolean")return l}return a.defaultShouldRevalidate}function jv(n,a,l,i,s,u){let f;if(n){let m=i[n];Fe(m,`No route found to patch children into: routeId = ${n}`),m.children||(m.children=[]),f=m.children}else f=l;let h=[],p=[];if(a.forEach(m=>{let g=f.find(x=>Qy(m,x));g?p.push({existingRoute:g,newRoute:m}):h.push(m)}),h.length>0){let m=fo(h,s,[n||"_","patch",String(f?.length||"0")],i);f.push(...m)}if(u&&p.length>0)for(let m=0;m<p.length;m++){let{existingRoute:g,newRoute:x}=p[m],S=g,[w]=fo([x],s,[],{},!0);Object.assign(S,{element:w.element?w.element:S.element,errorElement:w.errorElement?w.errorElement:S.errorElement,hydrateFallbackElement:w.hydrateFallbackElement?w.hydrateFallbackElement:S.hydrateFallbackElement})}}function Qy(n,a){return"id"in n&&"id"in a&&n.id===a.id?!0:n.index===a.index&&n.path===a.path&&n.caseSensitive===a.caseSensitive?(!n.children||n.children.length===0)&&(!a.children||a.children.length===0)?!0:n.children.every((l,i)=>a.children?.some(s=>Qy(l,s))):!1}var Mv=new WeakMap,Zy=({key:n,route:a,manifest:l,mapRouteProperties:i})=>{let s=l[a.id];if(Fe(s,"No route found in manifest"),!s.lazy||typeof s.lazy!="object")return;let u=s.lazy[n];if(!u)return;let f=Mv.get(s);f||(f={},Mv.set(s,f));let h=f[n];if(h)return h;let p=(async()=>{let m=aE(n),x=s[n]!==void 0&&n!=="hasErrorBoundary";if(m)St(!m,"Route property "+n+" is not a supported lazy route property. This property will be ignored."),f[n]=Promise.resolve();else if(x)St(!1,`Route "${s.id}" has a static property "${n}" defined. The lazy property will be ignored.`);else{let S=await u();S!=null&&(Object.assign(s,{[n]:S}),Object.assign(s,i(s)))}typeof s.lazy=="object"&&(s.lazy[n]=void 0,Object.values(s.lazy).every(S=>S===void 0)&&(s.lazy=void 0))})();return f[n]=p,p},_v=new WeakMap;function PE(n,a,l,i,s){let u=l[n.id];if(Fe(u,"No route found in manifest"),!n.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof n.lazy=="function"){let g=_v.get(u);if(g)return{lazyRoutePromise:g,lazyHandlerPromise:g};let x=(async()=>{Fe(typeof n.lazy=="function","No lazy route function found");let S=await n.lazy(),w={};for(let C in S){let R=S[C];if(R===void 0)continue;let T=lE(C),z=u[C]!==void 0&&C!=="hasErrorBoundary";T?St(!T,"Route property "+C+" is not a supported property to be returned from a lazy route function. This property will be ignored."):z?St(!z,`Route "${u.id}" has a static property "${C}" defined but its lazy function is also returning a value for this property. The lazy route property "${C}" will be ignored.`):w[C]=R}Object.assign(u,w),Object.assign(u,{...i(u),lazy:void 0})})();return _v.set(u,x),x.catch(()=>{}),{lazyRoutePromise:x,lazyHandlerPromise:x}}let f=Object.keys(n.lazy),h=[],p;for(let g of f){if(s&&s.includes(g))continue;let x=Zy({key:g,route:n,manifest:l,mapRouteProperties:i});x&&(h.push(x),g===a&&(p=x))}let m=h.length>0?Promise.all(h).then(()=>{}):void 0;return m?.catch(()=>{}),p?.catch(()=>{}),{lazyRoutePromise:m,lazyHandlerPromise:p}}async function Dv(n){let a=n.matches.filter(s=>s.shouldLoad),l={};return(await Promise.all(a.map(s=>s.resolve()))).forEach((s,u)=>{l[a[u].route.id]=s}),l}async function HE(n){return n.matches.some(a=>a.route.unstable_middleware)?Jy(n,!1,()=>Dv(n),(a,l)=>({[l]:{type:"error",result:a}})):Dv(n)}async function Jy(n,a,l,i){let{matches:s,request:u,params:f,context:h}=n,p={handlerResult:void 0};try{let m=s.flatMap(x=>x.route.unstable_middleware?x.route.unstable_middleware.map(S=>[x.route.id,S]):[]),g=await Iy({request:u,params:f,context:h},m,a,p,l);return a?g:p.handlerResult}catch(m){if(!p.middlewareError)throw m;let g=await i(p.middlewareError.error,p.middlewareError.routeId);return p.handlerResult?Object.assign(p.handlerResult,g):g}}async function Iy(n,a,l,i,s,u=0){let{request:f}=n;if(f.signal.aborted)throw f.signal.reason?f.signal.reason:new Error(`Request aborted without an \`AbortSignal.reason\`: ${f.method} ${f.url}`);let h=a[u];if(!h)return i.handlerResult=await s(),i.handlerResult;let[p,m]=h,g=!1,x,S=async()=>{if(g)throw new Error("You may only call `next()` once per middleware");g=!0,await Iy(n,a,l,i,s,u+1)};try{let w=await m({request:n.request,params:n.params,context:n.context},S);return g?w===void 0?x:w:S()}catch(w){throw i.middlewareError?i.middlewareError.error!==w&&(i.middlewareError={routeId:p,error:w}):i.middlewareError={routeId:p,error:w},w}}function Wy(n,a,l,i,s){let u=Zy({key:"unstable_middleware",route:i.route,manifest:a,mapRouteProperties:n}),f=PE(i.route,Qt(l.method)?"action":"loader",a,n,s);return{middleware:u,route:f.lazyRoutePromise,handler:f.lazyHandlerPromise}}function Rd(n,a,l,i,s,u,f,h=null){let p=!1,m=Wy(n,a,l,i,s);return{...i,_lazyPromises:m,shouldLoad:f,unstable_shouldRevalidateArgs:h,unstable_shouldCallHandler(g){return p=!0,h?typeof g=="boolean"?cu(i,{...h,defaultShouldRevalidate:g}):cu(i,h):f},resolve(g){return p||f||g&&!Qt(l.method)&&(i.route.lazy||i.route.loader)?$E({request:l,match:i,lazyHandlerPromise:m?.handler,lazyRoutePromise:m?.route,handlerOverride:g,scopedContext:u}):Promise.resolve({type:"data",result:void 0})}}}function Pl(n,a,l,i,s,u,f,h=null){return i.map(p=>p.route.id!==s.route.id?{...p,shouldLoad:!1,unstable_shouldRevalidateArgs:h,unstable_shouldCallHandler:()=>!1,_lazyPromises:Wy(n,a,l,p,u),resolve:()=>Promise.resolve({type:"data",result:void 0})}:Rd(n,a,l,p,u,f,!0,h))}async function BE(n,a,l,i,s,u){l.some(m=>m._lazyPromises?.middleware)&&await Promise.all(l.map(m=>m._lazyPromises?.middleware));let f={request:a,params:l[0].params,context:s,matches:l},p=await n({...f,fetcherKey:i,unstable_runClientMiddleware:m=>{let g=f;return Jy(g,!1,()=>m({...g,fetcherKey:i,unstable_runClientMiddleware:()=>{throw new Error("Cannot call `unstable_runClientMiddleware()` from within an `unstable_runClientMiddleware` handler")}}),(x,S)=>({[S]:{type:"error",result:x}}))}});try{await Promise.all(l.flatMap(m=>[m._lazyPromises?.handler,m._lazyPromises?.route]))}catch{}return p}async function $E({request:n,match:a,lazyHandlerPromise:l,lazyRoutePromise:i,handlerOverride:s,scopedContext:u}){let f,h,p=Qt(n.method),m=p?"action":"loader",g=x=>{let S,w=new Promise((T,O)=>S=O);h=()=>S(),n.signal.addEventListener("abort",h);let C=T=>typeof x!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${m}" [routeId: ${a.route.id}]`)):x({request:n,params:a.params,context:u},...T!==void 0?[T]:[]),R=(async()=>{try{return{type:"data",result:await(s?s(O=>C(O)):C())}}catch(T){return{type:"error",result:T}}})();return Promise.race([R,w])};try{let x=p?a.route.action:a.route.loader;if(l||i)if(x){let S,[w]=await Promise.all([g(x).catch(C=>{S=C}),l,i]);if(S!==void 0)throw S;f=w}else{await l;let S=p?a.route.action:a.route.loader;if(S)[f]=await Promise.all([g(S),i]);else if(m==="action"){let w=new URL(n.url),C=w.pathname+w.search;throw En(405,{method:n.method,pathname:C,routeId:a.route.id})}else return{type:"data",result:void 0}}else if(x)f=await g(x);else{let S=new URL(n.url),w=S.pathname+S.search;throw En(404,{pathname:w})}}catch(x){return{type:"error",result:x}}finally{h&&n.signal.removeEventListener("abort",h)}return f}async function VE(n){let{result:a,type:l}=n;if(t0(a)){let i;try{let s=a.headers.get("Content-Type");s&&/\bapplication\/json\b/.test(s)?a.body==null?i=null:i=await a.json():i=await a.text()}catch(s){return{type:"error",error:s}}return l==="error"?{type:"error",error:new Sd(a.status,a.statusText,i),statusCode:a.status,headers:a.headers}:{type:"data",data:i,statusCode:a.status,headers:a.headers}}return l==="error"?Bv(a)?a.data instanceof Error?{type:"error",error:a.data,statusCode:a.init?.status,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"error",error:new Sd(a.init?.status||500,void 0,a.data),statusCode:ho(a)?a.status:void 0,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"error",error:a,statusCode:ho(a)?a.status:void 0}:Bv(a)?{type:"data",data:a.data,statusCode:a.init?.status,headers:a.init?.headers?new Headers(a.init.headers):void 0}:{type:"data",data:a}}function qE(n,a,l,i,s){let u=n.headers.get("Location");if(Fe(u,"Redirects returned/thrown from loaders/actions must have a Location header"),!Pd(u)){let f=i.slice(0,i.findIndex(h=>h.route.id===l)+1);u=wd(new URL(a.url),f,s,u),n.headers.set("Location",u)}return n}function Lv(n,a,l){if(Pd(n)){let i=n,s=i.startsWith("//")?new URL(a.protocol+i):new URL(i),u=Rn(s.pathname,l)!=null;if(s.origin===a.origin&&u)return s.pathname+s.search+s.hash}return n}function Ll(n,a,l,i){let s=n.createURL(e0(a)).toString(),u={signal:l};if(i&&Qt(i.formMethod)){let{formMethod:f,formEncType:h}=i;u.method=f.toUpperCase(),h==="application/json"?(u.headers=new Headers({"Content-Type":h}),u.body=JSON.stringify(i.json)):h==="text/plain"?u.body=i.text:h==="application/x-www-form-urlencoded"&&i.formData?u.body=Cd(i.formData):u.body=i.formData}return new Request(s,u)}function Cd(n){let a=new URLSearchParams;for(let[l,i]of n.entries())a.append(l,typeof i=="string"?i:i.name);return a}function zv(n){let a=new FormData;for(let[l,i]of n.entries())a.append(l,i);return a}function YE(n,a,l,i=!1,s=!1){let u={},f=null,h,p=!1,m={},g=l&&ln(l[1])?l[1].error:void 0;return n.forEach(x=>{if(!(x.route.id in a))return;let S=x.route.id,w=a[S];if(Fe(!Dr(w),"Cannot handle redirect results in processLoaderData"),ln(w)){let C=w.error;if(g!==void 0&&(C=g,g=void 0),f=f||{},s)f[S]=C;else{let R=_r(n,S);f[R.route.id]==null&&(f[R.route.id]=C)}i||(u[S]=Xy),p||(p=!0,h=ho(w.error)?w.error.status:500),w.headers&&(m[S]=w.headers)}else u[S]=w.data,w.statusCode&&w.statusCode!==200&&!p&&(h=w.statusCode),w.headers&&(m[S]=w.headers)}),g!==void 0&&l&&(f={[l[0]]:g},l[2]&&(u[l[2]]=void 0)),{loaderData:u,errors:f,statusCode:h||200,loaderHeaders:m}}function kv(n,a,l,i,s,u){let{loaderData:f,errors:h}=YE(a,l,i);return s.filter(p=>!p.matches||p.matches.some(m=>m.shouldLoad)).forEach(p=>{let{key:m,match:g,controller:x}=p,S=u[m];if(Fe(S,"Did not find corresponding fetcher result"),!(x&&x.signal.aborted))if(ln(S)){let w=_r(n.matches,g?.route.id);h&&h[w.route.id]||(h={...h,[w.route.id]:S.error}),n.fetchers.delete(m)}else if(Dr(S))Fe(!1,"Unhandled fetcher revalidation redirect");else{let w=Za(S.data);n.fetchers.set(m,w)}}),{loaderData:f,errors:h}}function Uv(n,a,l,i){let s=Object.entries(a).filter(([,u])=>u!==Xy).reduce((u,[f,h])=>(u[f]=h,u),{});for(let u of l){let f=u.route.id;if(!a.hasOwnProperty(f)&&n.hasOwnProperty(f)&&u.route.loader&&(s[f]=n[f]),i&&i.hasOwnProperty(f))break}return s}function Pv(n){return n?ln(n[1])?{actionData:{}}:{actionData:{[n[0]]:n[1].data}}:{}}function _r(n,a){return(a?n.slice(0,n.findIndex(i=>i.route.id===a)+1):[...n]).reverse().find(i=>i.route.hasErrorBoundary===!0)||n[0]}function Hv(n){let a=n.length===1?n[0]:n.find(l=>l.index||!l.path||l.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:a}],route:a}}function En(n,{pathname:a,routeId:l,method:i,type:s,message:u}={}){let f="Unknown Server Error",h="Unknown @remix-run/router error";return n===400?(f="Bad Request",i&&a&&l?h=`You made a ${i} request to "${a}" but did not provide a \`loader\` for route "${l}", so there is no way to handle the request.`:s==="invalid-body"&&(h="Unable to encode submission body")):n===403?(f="Forbidden",h=`Route "${l}" does not match URL "${a}"`):n===404?(f="Not Found",h=`No route matches URL "${a}"`):n===405&&(f="Method Not Allowed",i&&a&&l?h=`You made a ${i.toUpperCase()} request to "${a}" but did not provide an \`action\` for route "${l}", so there is no way to handle the request.`:i&&(h=`Invalid request method "${i.toUpperCase()}"`)),new Sd(n||500,f,new Error(h),!0)}function $s(n){let a=Object.entries(n);for(let l=a.length-1;l>=0;l--){let[i,s]=a[l];if(Dr(s))return{key:i,result:s}}}function e0(n){let a=typeof n=="string"?Ea(n):n;return tr({...a,hash:""})}function KE(n,a){return n.pathname!==a.pathname||n.search!==a.search?!1:n.hash===""?a.hash!=="":n.hash===a.hash?!0:a.hash!==""}function GE(n){return t0(n.result)&&TE.has(n.result.status)}function ln(n){return n.type==="error"}function Dr(n){return(n&&n.type)==="redirect"}function Bv(n){return typeof n=="object"&&n!=null&&"type"in n&&"data"in n&&"init"in n&&n.type==="DataWithResponseInit"}function t0(n){return n!=null&&typeof n.status=="number"&&typeof n.statusText=="string"&&typeof n.headers=="object"&&typeof n.body<"u"}function FE(n){return NE.has(n.toUpperCase())}function Qt(n){return OE.has(n.toUpperCase())}function Hd(n){return new URLSearchParams(n).getAll("index").some(a=>a==="")}function eu(n,a){let l=typeof a=="string"?Ea(a).search:a.search;if(n[n.length-1].route.index&&Hd(l||""))return n[n.length-1];let i=Ky(n);return i[i.length-1]}function $v(n){let{formMethod:a,formAction:l,formEncType:i,text:s,formData:u,json:f}=n;if(!(!a||!l||!i)){if(s!=null)return{formMethod:a,formAction:l,formEncType:i,formData:void 0,json:void 0,text:s};if(u!=null)return{formMethod:a,formAction:l,formEncType:i,formData:u,json:void 0,text:void 0};if(f!==void 0)return{formMethod:a,formAction:l,formEncType:i,formData:void 0,json:f,text:void 0}}}function Jf(n,a){return a?{state:"loading",location:n,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}:{state:"loading",location:n,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function XE(n,a){return{state:"submitting",location:n,formMethod:a.formMethod,formAction:a.formAction,formEncType:a.formEncType,formData:a.formData,json:a.json,text:a.text}}function to(n,a){return n?{state:"loading",formMethod:n.formMethod,formAction:n.formAction,formEncType:n.formEncType,formData:n.formData,json:n.json,text:n.text,data:a}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:a}}function QE(n,a){return{state:"submitting",formMethod:n.formMethod,formAction:n.formAction,formEncType:n.formEncType,formData:n.formData,json:n.json,text:n.text,data:a?a.data:void 0}}function Za(n){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:n}}function ZE(n,a){try{let l=n.sessionStorage.getItem(Fy);if(l){let i=JSON.parse(l);for(let[s,u]of Object.entries(i||{}))u&&Array.isArray(u)&&a.set(s,new Set(u||[]))}}catch{}}function JE(n,a){if(a.size>0){let l={};for(let[i,s]of a)l[i]=[...s];try{n.sessionStorage.setItem(Fy,JSON.stringify(l))}catch(i){St(!1,`Failed to save applied view transitions in sessionStorage (${i}).`)}}}function IE(){let n,a,l=new Promise((i,s)=>{n=async u=>{i(u);try{await l}catch{}},a=async u=>{s(u);try{await l}catch{}}});return{promise:l,resolve:n,reject:a}}var Vr=v.createContext(null);Vr.displayName="DataRouter";var bo=v.createContext(null);bo.displayName="DataRouterState";v.createContext(!1);var Bd=v.createContext({isTransitioning:!1});Bd.displayName="ViewTransition";var n0=v.createContext(new Map);n0.displayName="Fetchers";var WE=v.createContext(null);WE.displayName="Await";var _n=v.createContext(null);_n.displayName="Navigation";var Su=v.createContext(null);Su.displayName="Location";var Qn=v.createContext({outlet:null,matches:[],isDataRoute:!1});Qn.displayName="Route";var $d=v.createContext(null);$d.displayName="RouteError";function eR(n,{relative:a}={}){Fe(Xl(),"useHref() may be used only in the context of a <Router> component.");let{basename:l,navigator:i}=v.useContext(_n),{hash:s,pathname:u,search:f}=xo(n,{relative:a}),h=u;return l!=="/"&&(h=u==="/"?l:Kn([l,u])),i.createHref({pathname:h,search:f,hash:s})}function Xl(){return v.useContext(Su)!=null}function ir(){return Fe(Xl(),"useLocation() may be used only in the context of a <Router> component."),v.useContext(Su).location}var a0="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function r0(n){v.useContext(_n).static||v.useLayoutEffect(n)}function wu(){let{isDataRoute:n}=v.useContext(Qn);return n?hR():tR()}function tR(){Fe(Xl(),"useNavigate() may be used only in the context of a <Router> component.");let n=v.useContext(Vr),{basename:a,navigator:l}=v.useContext(_n),{matches:i}=v.useContext(Qn),{pathname:s}=ir(),u=JSON.stringify(bu(i)),f=v.useRef(!1);return r0(()=>{f.current=!0}),v.useCallback((p,m={})=>{if(St(f.current,a0),!f.current)return;if(typeof p=="number"){l.go(p);return}let g=xu(p,JSON.parse(u),s,m.relative==="path");n==null&&a!=="/"&&(g.pathname=g.pathname==="/"?a:Kn([a,g.pathname])),(m.replace?l.replace:l.push)(g,m.state,m)},[a,l,u,s,n])}v.createContext(null);function xo(n,{relative:a}={}){let{matches:l}=v.useContext(Qn),{pathname:i}=ir(),s=JSON.stringify(bu(l));return v.useMemo(()=>xu(n,JSON.parse(s),i,a==="path"),[n,s,i,a])}function nR(n,a,l,i){Fe(Xl(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:s}=v.useContext(_n),{matches:u}=v.useContext(Qn),f=u[u.length-1],h=f?f.params:{},p=f?f.pathname:"/",m=f?f.pathnameBase:"/",g=f&&f.route;{let O=g&&g.path||"";l0(p,!g||O.endsWith("*")||O.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${p}" (under <Route path="${O}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
66
66
|
|
|
67
|
-
Please change the parent <Route path="${O}"> to <Route path="${O==="/"?"*":`${O}/*`}">.`)}let x=ir(),S;S=x;let w=S.pathname||"/",C=w;if(m!=="/"){let O=m.replace(/^\//,"").split("/");C="/"+w.replace(/^\//,"").split("/").slice(O.length).join("/")}let R=Ia(n,{pathname:C});return St(g||R!=null,`No routes matched location "${S.pathname}${S.search}${S.hash}" `),St(R==null||R[R.length-1].route.element!==void 0||R[R.length-1].route.Component!==void 0||R[R.length-1].route.lazy!==void 0,`Matched leaf route at location "${S.pathname}${S.search}${S.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`),oR(R&&R.map(O=>Object.assign({},O,{params:Object.assign({},h,O.params),pathname:Kn([m,s.encodeLocation?s.encodeLocation(O.pathname).pathname:O.pathname]),pathnameBase:O.pathnameBase==="/"?m:Kn([m,s.encodeLocation?s.encodeLocation(O.pathnameBase).pathname:O.pathnameBase])})),u,l,i)}function aR(){let n=dR(),a=ho(n)?`${n.status} ${n.statusText}`:n instanceof Error?n.message:JSON.stringify(n),l=n instanceof Error?n.stack:null,i="rgba(200,200,200, 0.5)",s={padding:"0.5rem",backgroundColor:i},u={padding:"2px 4px",backgroundColor:i},f=null;return console.error("Error handled by React Router default ErrorBoundary:",n),f=v.createElement(v.Fragment,null,v.createElement("p",null,"💿 Hey developer 👋"),v.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",v.createElement("code",{style:u},"ErrorBoundary")," or"," ",v.createElement("code",{style:u},"errorElement")," prop on your route.")),v.createElement(v.Fragment,null,v.createElement("h2",null,"Unexpected Application Error!"),v.createElement("h3",{style:{fontStyle:"italic"}},a),l?v.createElement("pre",{style:s},l):null,f)}var rR=v.createElement(aR,null),lR=class extends v.Component{constructor(n){super(n),this.state={location:n.location,revalidation:n.revalidation,error:n.error}}static getDerivedStateFromError(n){return{error:n}}static getDerivedStateFromProps(n,a){return a.location!==n.location||a.revalidation!=="idle"&&n.revalidation==="idle"?{error:n.error,location:n.location,revalidation:n.revalidation}:{error:n.error!==void 0?n.error:a.error,location:a.location,revalidation:n.revalidation||a.revalidation}}componentDidCatch(n,a){console.error("React Router caught the following error during render",n,a)}render(){return this.state.error!==void 0?v.createElement(Qn.Provider,{value:this.props.routeContext},v.createElement($d.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function iR({routeContext:n,match:a,children:l}){let i=v.useContext(Vr);return i&&i.static&&i.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=a.route.id),v.createElement(Qn.Provider,{value:n},l)}function oR(n,a=[],l=null,i=null){if(n==null){if(!l)return null;if(l.errors)n=l.matches;else if(a.length===0&&!l.initialized&&l.matches.length>0)n=l.matches;else return null}let s=n,u=l?.errors;if(u!=null){let p=s.findIndex(m=>m.route.id&&u?.[m.route.id]!==void 0);Fe(p>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(u).join(",")}`),s=s.slice(0,Math.min(s.length,p+1))}let f=!1,h=-1;if(l)for(let p=0;p<s.length;p++){let m=s[p];if((m.route.HydrateFallback||m.route.hydrateFallbackElement)&&(h=p),m.route.id){let{loaderData:g,errors:x}=l,S=m.route.loader&&!g.hasOwnProperty(m.route.id)&&(!x||x[m.route.id]===void 0);if(m.route.lazy||S){f=!0,h>=0?s=s.slice(0,h+1):s=[s[0]];break}}}return s.reduceRight((p,m,g)=>{let x,S=!1,w=null,C=null;l&&(x=u&&m.route.id?u[m.route.id]:void 0,w=m.route.errorElement||rR,f&&(h<0&&g===0?(l0("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),S=!0,C=null):h===g&&(S=!0,C=m.route.hydrateFallbackElement||null)));let R=a.concat(s.slice(0,g+1)),T=()=>{let O;return x?O=w:S?O=C:m.route.Component?O=v.createElement(m.route.Component,null):m.route.element?O=m.route.element:O=p,v.createElement(iR,{match:m,routeContext:{outlet:p,matches:R,isDataRoute:l!=null},children:O})};return l&&(m.route.ErrorBoundary||m.route.errorElement||g===0)?v.createElement(lR,{location:l.location,revalidation:l.revalidation,component:w,error:x,children:T(),routeContext:{outlet:null,matches:R,isDataRoute:!0}}):T()},null)}function Vd(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function sR(n){let a=v.useContext(Vr);return Fe(a,Vd(n)),a}function uR(n){let a=v.useContext(bo);return Fe(a,Vd(n)),a}function cR(n){let a=v.useContext(Qn);return Fe(a,Vd(n)),a}function qd(n){let a=cR(n),l=a.matches[a.matches.length-1];return Fe(l.route.id,`${n} can only be used on routes that contain a unique "id"`),l.route.id}function fR(){return qd("useRouteId")}function dR(){let n=v.useContext($d),a=uR("useRouteError"),l=qd("useRouteError");return n!==void 0?n:a.errors?.[l]}function hR(){let{router:n}=sR("useNavigate"),a=qd("useNavigate"),l=v.useRef(!1);return r0(()=>{l.current=!0}),v.useCallback(async(s,u={})=>{St(l.current,a0),l.current&&(typeof s=="number"?n.navigate(s):await n.navigate(s,{fromRouteId:a,...u}))},[n,a])}var Vv={};function l0(n,a,l){!a&&!Vv[n]&&(Vv[n]=!0,St(!1,l))}var qv={};function Yv(n,a){!n&&!qv[a]&&(qv[a]=!0,console.warn(a))}function mR(n){let a={hasErrorBoundary:n.hasErrorBoundary||n.ErrorBoundary!=null||n.errorElement!=null};return n.Component&&(n.element&&St(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(a,{element:v.createElement(n.Component),Component:void 0})),n.HydrateFallback&&(n.hydrateFallbackElement&&St(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(a,{hydrateFallbackElement:v.createElement(n.HydrateFallback),HydrateFallback:void 0})),n.ErrorBoundary&&(n.errorElement&&St(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(a,{errorElement:v.createElement(n.ErrorBoundary),ErrorBoundary:void 0})),a}var pR=["HydrateFallback","hydrateFallbackElement"];function gR(n,a){return LE({basename:a?.basename,unstable_getContext:a?.unstable_getContext,future:a?.future,history:Ww({initialEntries:a?.initialEntries,initialIndex:a?.initialIndex}),hydrationData:a?.hydrationData,routes:n,hydrationRouteProperties:pR,mapRouteProperties:mR,dataStrategy:a?.dataStrategy,patchRoutesOnNavigation:a?.patchRoutesOnNavigation}).initialize()}var vR=class{constructor(){this.status="pending",this.promise=new Promise((n,a)=>{this.resolve=l=>{this.status==="pending"&&(this.status="resolved",n(l))},this.reject=l=>{this.status==="pending"&&(this.status="rejected",a(l))}})}};function yR({router:n,flushSync:a}){let[l,i]=v.useState(n.state),[s,u]=v.useState(),[f,h]=v.useState({isTransitioning:!1}),[p,m]=v.useState(),[g,x]=v.useState(),[S,w]=v.useState(),C=v.useRef(new Map),R=v.useCallback((k,{deletedFetchers:H,flushSync:P,viewTransitionOpts:A})=>{k.fetchers.forEach((J,re)=>{J.data!==void 0&&C.current.set(re,J.data)}),H.forEach(J=>C.current.delete(J)),Yv(P===!1||a!=null,'You provided the `flushSync` option to a router update, but you are not using the `<RouterProvider>` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable. Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let G=n.window!=null&&n.window.document!=null&&typeof n.window.document.startViewTransition=="function";if(Yv(A==null||G,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!A||!G){a&&P?a(()=>i(k)):v.startTransition(()=>i(k));return}if(a&&P){a(()=>{g&&(p&&p.resolve(),g.skipTransition()),h({isTransitioning:!0,flushSync:!0,currentLocation:A.currentLocation,nextLocation:A.nextLocation})});let J=n.window.document.startViewTransition(()=>{a(()=>i(k))});J.finished.finally(()=>{a(()=>{m(void 0),x(void 0),u(void 0),h({isTransitioning:!1})})}),a(()=>x(J));return}g?(p&&p.resolve(),g.skipTransition(),w({state:k,currentLocation:A.currentLocation,nextLocation:A.nextLocation})):(u(k),h({isTransitioning:!0,flushSync:!1,currentLocation:A.currentLocation,nextLocation:A.nextLocation}))},[n.window,a,g,p]);v.useLayoutEffect(()=>n.subscribe(R),[n,R]),v.useEffect(()=>{f.isTransitioning&&!f.flushSync&&m(new vR)},[f]),v.useEffect(()=>{if(p&&s&&n.window){let k=s,H=p.promise,P=n.window.document.startViewTransition(async()=>{v.startTransition(()=>i(k)),await H});P.finished.finally(()=>{m(void 0),x(void 0),u(void 0),h({isTransitioning:!1})}),x(P)}},[s,p,n.window]),v.useEffect(()=>{p&&s&&l.location.key===s.location.key&&p.resolve()},[p,g,l.location,s]),v.useEffect(()=>{!f.isTransitioning&&S&&(u(S.state),h({isTransitioning:!0,flushSync:!1,currentLocation:S.currentLocation,nextLocation:S.nextLocation}),w(void 0))},[f.isTransitioning,S]);let T=v.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:k=>n.navigate(k),push:(k,H,P)=>n.navigate(k,{state:H,preventScrollReset:P?.preventScrollReset}),replace:(k,H,P)=>n.navigate(k,{replace:!0,state:H,preventScrollReset:P?.preventScrollReset})}),[n]),O=n.basename||"/",z=v.useMemo(()=>({router:n,navigator:T,static:!1,basename:O}),[n,T,O]);return v.createElement(v.Fragment,null,v.createElement(Vr.Provider,{value:z},v.createElement(bo.Provider,{value:l},v.createElement(n0.Provider,{value:C.current},v.createElement(Bd.Provider,{value:f},v.createElement(wR,{basename:O,location:l.location,navigationType:l.historyAction,navigator:T},v.createElement(bR,{routes:n.routes,future:n.future,state:l})))))),null)}var bR=v.memo(xR);function xR({routes:n,future:a,state:l}){return nR(n,void 0,l,a)}function SR({to:n,replace:a,state:l,relative:i}){Fe(Xl(),"<Navigate> may be used only in the context of a <Router> component.");let{static:s}=v.useContext(_n);St(!s,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:u}=v.useContext(Qn),{pathname:f}=ir(),h=wu(),p=xu(n,bu(u),f,i==="path"),m=JSON.stringify(p);return v.useEffect(()=>{h(JSON.parse(m),{replace:a,state:l,relative:i})},[h,m,i,a,l]),null}function wR({basename:n="/",children:a=null,location:l,navigationType:i="POP",navigator:s,static:u=!1}){Fe(!Xl(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let f=n.replace(/^\/*/,"/"),h=v.useMemo(()=>({basename:f,navigator:s,static:u,future:{}}),[f,s,u]);typeof l=="string"&&(l=Ea(l));let{pathname:p="/",search:m="",hash:g="",state:x=null,key:S="default"}=l,w=v.useMemo(()=>{let C=Rn(p,f);return C==null?null:{location:{pathname:C,search:m,hash:g,state:x,key:S},navigationType:i}},[f,p,m,g,x,S,i]);return St(w!=null,`<Router basename="${f}"> is not able to match the URL "${p}${m}${g}" because it does not start with the basename, so the <Router> won't render anything.`),w==null?null:v.createElement(_n.Provider,{value:h},v.createElement(Su.Provider,{children:a,value:w}))}var tu="get",nu="application/x-www-form-urlencoded";function Eu(n){return n!=null&&typeof n.tagName=="string"}function ER(n){return Eu(n)&&n.tagName.toLowerCase()==="button"}function RR(n){return Eu(n)&&n.tagName.toLowerCase()==="form"}function CR(n){return Eu(n)&&n.tagName.toLowerCase()==="input"}function OR(n){return!!(n.metaKey||n.altKey||n.ctrlKey||n.shiftKey)}function AR(n,a){return n.button===0&&(!a||a==="_self")&&!OR(n)}var Vs=null;function NR(){if(Vs===null)try{new FormData(document.createElement("form"),0),Vs=!1}catch{Vs=!0}return Vs}var TR=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function If(n){return n!=null&&!TR.has(n)?(St(!1,`"${n}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${nu}"`),null):n}function jR(n,a){let l,i,s,u,f;if(RR(n)){let h=n.getAttribute("action");i=h?Rn(h,a):null,l=n.getAttribute("method")||tu,s=If(n.getAttribute("enctype"))||nu,u=new FormData(n)}else if(ER(n)||CR(n)&&(n.type==="submit"||n.type==="image")){let h=n.form;if(h==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let p=n.getAttribute("formaction")||h.getAttribute("action");if(i=p?Rn(p,a):null,l=n.getAttribute("formmethod")||h.getAttribute("method")||tu,s=If(n.getAttribute("formenctype"))||If(h.getAttribute("enctype"))||nu,u=new FormData(h,n),!NR()){let{name:m,type:g,value:x}=n;if(g==="image"){let S=m?`${m}.`:"";u.append(`${S}x`,"0"),u.append(`${S}y`,"0")}else m&&u.append(m,x)}}else{if(Eu(n))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');l=tu,i=null,s=nu,f=n}return u&&s==="text/plain"&&(f=u,u=void 0),{action:i,method:l.toLowerCase(),encType:s,formData:u,body:f}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Yd(n,a){if(n===!1||n===null||typeof n>"u")throw new Error(a)}function MR(n,a,l){let i=typeof n=="string"?new URL(n,typeof window>"u"?"server://singlefetch/":window.location.origin):n;return i.pathname==="/"?i.pathname=`_root.${l}`:a&&Rn(i.pathname,a)==="/"?i.pathname=`${a.replace(/\/$/,"")}/_root.${l}`:i.pathname=`${i.pathname.replace(/\/$/,"")}.${l}`,i}async function _R(n,a){if(n.id in a)return a[n.id];try{let l=await import(n.module);return a[n.id]=l,l}catch(l){return console.error(`Error loading route module \`${n.module}\`, reloading page...`),console.error(l),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function DR(n){return n==null?!1:n.href==null?n.rel==="preload"&&typeof n.imageSrcSet=="string"&&typeof n.imageSizes=="string":typeof n.rel=="string"&&typeof n.href=="string"}async function LR(n,a,l){let i=await Promise.all(n.map(async s=>{let u=a.routes[s.route.id];if(u){let f=await _R(u,l);return f.links?f.links():[]}return[]}));return PR(i.flat(1).filter(DR).filter(s=>s.rel==="stylesheet"||s.rel==="preload").map(s=>s.rel==="stylesheet"?{...s,rel:"prefetch",as:"style"}:{...s,rel:"prefetch"}))}function Kv(n,a,l,i,s,u){let f=(p,m)=>l[m]?p.route.id!==l[m].route.id:!0,h=(p,m)=>l[m].pathname!==p.pathname||l[m].route.path?.endsWith("*")&&l[m].params["*"]!==p.params["*"];return u==="assets"?a.filter((p,m)=>f(p,m)||h(p,m)):u==="data"?a.filter((p,m)=>{let g=i.routes[p.route.id];if(!g||!g.hasLoader)return!1;if(f(p,m)||h(p,m))return!0;if(p.route.shouldRevalidate){let x=p.route.shouldRevalidate({currentUrl:new URL(s.pathname+s.search+s.hash,window.origin),currentParams:l[0]?.params||{},nextUrl:new URL(n,window.origin),nextParams:p.params,defaultShouldRevalidate:!0});if(typeof x=="boolean")return x}return!0}):[]}function zR(n,a,{includeHydrateFallback:l}={}){return kR(n.map(i=>{let s=a.routes[i.route.id];if(!s)return[];let u=[s.module];return s.clientActionModule&&(u=u.concat(s.clientActionModule)),s.clientLoaderModule&&(u=u.concat(s.clientLoaderModule)),l&&s.hydrateFallbackModule&&(u=u.concat(s.hydrateFallbackModule)),s.imports&&(u=u.concat(s.imports)),u}).flat(1))}function kR(n){return[...new Set(n)]}function UR(n){let a={},l=Object.keys(n).sort();for(let i of l)a[i]=n[i];return a}function PR(n,a){let l=new Set;return new Set(a),n.reduce((i,s)=>{let u=JSON.stringify(UR(s));return l.has(u)||(l.add(u),i.push({key:u,link:s})),i},[])}function i0(){let n=v.useContext(Vr);return Yd(n,"You must render this element inside a <DataRouterContext.Provider> element"),n}function HR(){let n=v.useContext(bo);return Yd(n,"You must render this element inside a <DataRouterStateContext.Provider> element"),n}var Kd=v.createContext(void 0);Kd.displayName="FrameworkContext";function o0(){let n=v.useContext(Kd);return Yd(n,"You must render this element inside a <HydratedRouter> element"),n}function BR(n,a){let l=v.useContext(Kd),[i,s]=v.useState(!1),[u,f]=v.useState(!1),{onFocus:h,onBlur:p,onMouseEnter:m,onMouseLeave:g,onTouchStart:x}=a,S=v.useRef(null);v.useEffect(()=>{if(n==="render"&&f(!0),n==="viewport"){let R=O=>{O.forEach(z=>{f(z.isIntersecting)})},T=new IntersectionObserver(R,{threshold:.5});return S.current&&T.observe(S.current),()=>{T.disconnect()}}},[n]),v.useEffect(()=>{if(i){let R=setTimeout(()=>{f(!0)},100);return()=>{clearTimeout(R)}}},[i]);let w=()=>{s(!0)},C=()=>{s(!1),f(!1)};return l?n!=="intent"?[u,S,{}]:[u,S,{onFocus:no(h,w),onBlur:no(p,C),onMouseEnter:no(m,w),onMouseLeave:no(g,C),onTouchStart:no(x,w)}]:[!1,S,{}]}function no(n,a){return l=>{n&&n(l),l.defaultPrevented||a(l)}}function $R({page:n,...a}){let{router:l}=i0(),i=v.useMemo(()=>Ia(l.routes,n,l.basename),[l.routes,n,l.basename]);return i?v.createElement(qR,{page:n,matches:i,...a}):null}function VR(n){let{manifest:a,routeModules:l}=o0(),[i,s]=v.useState([]);return v.useEffect(()=>{let u=!1;return LR(n,a,l).then(f=>{u||s(f)}),()=>{u=!0}},[n,a,l]),i}function qR({page:n,matches:a,...l}){let i=ir(),{manifest:s,routeModules:u}=o0(),{basename:f}=i0(),{loaderData:h,matches:p}=HR(),m=v.useMemo(()=>Kv(n,a,p,s,i,"data"),[n,a,p,s,i]),g=v.useMemo(()=>Kv(n,a,p,s,i,"assets"),[n,a,p,s,i]),x=v.useMemo(()=>{if(n===i.pathname+i.search+i.hash)return[];let C=new Set,R=!1;if(a.forEach(O=>{let z=s.routes[O.route.id];!z||!z.hasLoader||(!m.some(k=>k.route.id===O.route.id)&&O.route.id in h&&u[O.route.id]?.shouldRevalidate||z.hasClientLoader?R=!0:C.add(O.route.id))}),C.size===0)return[];let T=MR(n,f,"data");return R&&C.size>0&&T.searchParams.set("_routes",a.filter(O=>C.has(O.route.id)).map(O=>O.route.id).join(",")),[T.pathname+T.search]},[f,h,i,s,m,a,n,u]),S=v.useMemo(()=>zR(g,s),[g,s]),w=VR(g);return v.createElement(v.Fragment,null,x.map(C=>v.createElement("link",{key:C,rel:"prefetch",as:"fetch",href:C,...l})),S.map(C=>v.createElement("link",{key:C,rel:"modulepreload",href:C,...l})),w.map(({key:C,link:R})=>v.createElement("link",{key:C,...R})))}function YR(...n){return a=>{n.forEach(l=>{typeof l=="function"?l(a):l!=null&&(l.current=a)})}}var s0=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{s0&&(window.__reactRouterVersion="7.7.0")}catch{}var u0=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,c0=v.forwardRef(function({onClick:a,discover:l="render",prefetch:i="none",relative:s,reloadDocument:u,replace:f,state:h,target:p,to:m,preventScrollReset:g,viewTransition:x,...S},w){let{basename:C}=v.useContext(_n),R=typeof m=="string"&&u0.test(m),T,O=!1;if(typeof m=="string"&&R&&(T=m,s0))try{let re=new URL(window.location.href),ie=m.startsWith("//")?new URL(re.protocol+m):new URL(m),Oe=Rn(ie.pathname,C);ie.origin===re.origin&&Oe!=null?m=Oe+ie.search+ie.hash:O=!0}catch{St(!1,`<Link to="${m}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let z=eR(m,{relative:s}),[k,H,P]=BR(i,S),A=XR(m,{replace:f,state:h,target:p,preventScrollReset:g,relative:s,viewTransition:x});function G(re){a&&a(re),re.defaultPrevented||A(re)}let J=v.createElement("a",{...S,...P,href:T||z,onClick:O||u?a:G,ref:YR(w,H),target:p,"data-discover":!R&&l==="render"?"true":void 0});return k&&!R?v.createElement(v.Fragment,null,J,v.createElement($R,{page:z})):J});c0.displayName="Link";var KR=v.forwardRef(function({"aria-current":a="page",caseSensitive:l=!1,className:i="",end:s=!1,style:u,to:f,viewTransition:h,children:p,...m},g){let x=xo(f,{relative:m.relative}),S=ir(),w=v.useContext(bo),{navigator:C,basename:R}=v.useContext(_n),T=w!=null&&WR(x)&&h===!0,O=C.encodeLocation?C.encodeLocation(x).pathname:x.pathname,z=S.pathname,k=w&&w.navigation&&w.navigation.location?w.navigation.location.pathname:null;l||(z=z.toLowerCase(),k=k?k.toLowerCase():null,O=O.toLowerCase()),k&&R&&(k=Rn(k,R)||k);const H=O!=="/"&&O.endsWith("/")?O.length-1:O.length;let P=z===O||!s&&z.startsWith(O)&&z.charAt(H)==="/",A=k!=null&&(k===O||!s&&k.startsWith(O)&&k.charAt(O.length)==="/"),G={isActive:P,isPending:A,isTransitioning:T},J=P?a:void 0,re;typeof i=="function"?re=i(G):re=[i,P?"active":null,A?"pending":null,T?"transitioning":null].filter(Boolean).join(" ");let ie=typeof u=="function"?u(G):u;return v.createElement(c0,{...m,"aria-current":J,className:re,ref:g,style:ie,to:f,viewTransition:h},typeof p=="function"?p(G):p)});KR.displayName="NavLink";var GR=v.forwardRef(({discover:n="render",fetcherKey:a,navigate:l,reloadDocument:i,replace:s,state:u,method:f=tu,action:h,onSubmit:p,relative:m,preventScrollReset:g,viewTransition:x,...S},w)=>{let C=JR(),R=IR(h,{relative:m}),T=f.toLowerCase()==="get"?"get":"post",O=typeof h=="string"&&u0.test(h),z=k=>{if(p&&p(k),k.defaultPrevented)return;k.preventDefault();let H=k.nativeEvent.submitter,P=H?.getAttribute("formmethod")||f;C(H||k.currentTarget,{fetcherKey:a,method:P,navigate:l,replace:s,state:u,relative:m,preventScrollReset:g,viewTransition:x})};return v.createElement("form",{ref:w,method:T,action:R,onSubmit:i?p:z,...S,"data-discover":!O&&n==="render"?"true":void 0})});GR.displayName="Form";function FR(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function f0(n){let a=v.useContext(Vr);return Fe(a,FR(n)),a}function XR(n,{target:a,replace:l,state:i,preventScrollReset:s,relative:u,viewTransition:f}={}){let h=wu(),p=ir(),m=xo(n,{relative:u});return v.useCallback(g=>{if(AR(g,a)){g.preventDefault();let x=l!==void 0?l:tr(p)===tr(m);h(n,{replace:x,state:i,preventScrollReset:s,relative:u,viewTransition:f})}},[p,h,m,l,i,a,n,s,u,f])}var QR=0,ZR=()=>`__${String(++QR)}__`;function JR(){let{router:n}=f0("useSubmit"),{basename:a}=v.useContext(_n),l=fR();return v.useCallback(async(i,s={})=>{let{action:u,method:f,encType:h,formData:p,body:m}=jR(i,a);if(s.navigate===!1){let g=s.fetcherKey||ZR();await n.fetch(g,l,s.action||u,{preventScrollReset:s.preventScrollReset,formData:p,body:m,formMethod:s.method||f,formEncType:s.encType||h,flushSync:s.flushSync})}else await n.navigate(s.action||u,{preventScrollReset:s.preventScrollReset,formData:p,body:m,formMethod:s.method||f,formEncType:s.encType||h,replace:s.replace,state:s.state,fromRouteId:l,flushSync:s.flushSync,viewTransition:s.viewTransition})},[n,a,l])}function IR(n,{relative:a}={}){let{basename:l}=v.useContext(_n),i=v.useContext(Qn);Fe(i,"useFormAction must be used inside a RouteContext");let[s]=i.matches.slice(-1),u={...xo(n||".",{relative:a})},f=ir();if(n==null){u.search=f.search;let h=new URLSearchParams(u.search),p=h.getAll("index");if(p.some(g=>g==="")){h.delete("index"),p.filter(x=>x).forEach(x=>h.append("index",x));let g=h.toString();u.search=g?`?${g}`:""}}return(!n||n===".")&&s.route.index&&(u.search=u.search?u.search.replace(/^\?/,"?index&"):"?index"),l!=="/"&&(u.pathname=u.pathname==="/"?l:Kn([l,u.pathname])),tr(u)}function WR(n,a={}){let l=v.useContext(Bd);Fe(l!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:i}=f0("useViewTransitionState"),s=xo(n,{relative:a.relative});if(!l.isTransitioning)return!1;let u=Rn(l.currentLocation.pathname,i)||l.currentLocation.pathname,f=Rn(l.nextLocation.pathname,i)||l.nextLocation.pathname;return uu(s.pathname,f)!=null||uu(s.pathname,u)!=null}var Ru=$y();const eC=My(Ru);function tC(n){return v.createElement(yR,{flushSync:Ru.flushSync,...n})}function Jt(n,a,{checkForDefaultPrevented:l=!0}={}){return function(s){if(n?.(s),l===!1||!s.defaultPrevented)return a?.(s)}}function Gv(n,a){if(typeof n=="function")return n(a);n!=null&&(n.current=a)}function kr(...n){return a=>{let l=!1;const i=n.map(s=>{const u=Gv(s,a);return!l&&typeof u=="function"&&(l=!0),u});if(l)return()=>{for(let s=0;s<i.length;s++){const u=i[s];typeof u=="function"?u():Gv(n[s],null)}}}}function fn(...n){return v.useCallback(kr(...n),n)}function nC(n,a){const l=v.createContext(a),i=u=>{const{children:f,...h}=u,p=v.useMemo(()=>h,Object.values(h));return y.jsx(l.Provider,{value:p,children:f})};i.displayName=n+"Provider";function s(u){const f=v.useContext(l);if(f)return f;if(a!==void 0)return a;throw new Error(`\`${u}\` must be used within \`${n}\``)}return[i,s]}function Cu(n,a=[]){let l=[];function i(u,f){const h=v.createContext(f),p=l.length;l=[...l,f];const m=x=>{const{scope:S,children:w,...C}=x,R=S?.[n]?.[p]||h,T=v.useMemo(()=>C,Object.values(C));return y.jsx(R.Provider,{value:T,children:w})};m.displayName=u+"Provider";function g(x,S){const w=S?.[n]?.[p]||h,C=v.useContext(w);if(C)return C;if(f!==void 0)return f;throw new Error(`\`${x}\` must be used within \`${u}\``)}return[m,g]}const s=()=>{const u=l.map(f=>v.createContext(f));return function(h){const p=h?.[n]||u;return v.useMemo(()=>({[`__scope${n}`]:{...h,[n]:p}}),[h,p])}};return s.scopeName=n,[i,aC(s,...a)]}function aC(...n){const a=n[0];if(n.length===1)return a;const l=()=>{const i=n.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(u){const f=i.reduce((h,{useScope:p,scopeName:m})=>{const x=p(u)[`__scope${m}`];return{...h,...x}},{});return v.useMemo(()=>({[`__scope${a.scopeName}`]:f}),[f])}};return l.scopeName=a.scopeName,l}var nr=globalThis?.document?v.useLayoutEffect:()=>{},rC=Ly[" useId ".trim().toString()]||(()=>{}),lC=0;function Gn(n){const[a,l]=v.useState(rC());return nr(()=>{l(i=>i??String(lC++))},[n]),n||(a?`radix-${a}`:"")}var iC=Ly[" useInsertionEffect ".trim().toString()]||nr;function Gd({prop:n,defaultProp:a,onChange:l=()=>{},caller:i}){const[s,u,f]=oC({defaultProp:a,onChange:l}),h=n!==void 0,p=h?n:s;{const g=v.useRef(n!==void 0);v.useEffect(()=>{const x=g.current;x!==h&&console.warn(`${i} is changing from ${x?"controlled":"uncontrolled"} to ${h?"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.`),g.current=h},[h,i])}const m=v.useCallback(g=>{if(h){const x=sC(g)?g(n):g;x!==n&&f.current?.(x)}else u(g)},[h,n,u,f]);return[p,m]}function oC({defaultProp:n,onChange:a}){const[l,i]=v.useState(n),s=v.useRef(l),u=v.useRef(a);return iC(()=>{u.current=a},[a]),v.useEffect(()=>{s.current!==l&&(u.current?.(l),s.current=l)},[l,s]),[l,i,u]}function sC(n){return typeof n=="function"}function Ou(n){const a=cC(n),l=v.forwardRef((i,s)=>{const{children:u,...f}=i,h=v.Children.toArray(u),p=h.find(dC);if(p){const m=p.props.children,g=h.map(x=>x===p?v.Children.count(m)>1?v.Children.only(null):v.isValidElement(m)?m.props.children:null:x);return y.jsx(a,{...f,ref:s,children:v.isValidElement(m)?v.cloneElement(m,void 0,g):null})}return y.jsx(a,{...f,ref:s,children:u})});return l.displayName=`${n}.Slot`,l}var uC=Ou("Slot");function cC(n){const a=v.forwardRef((l,i)=>{const{children:s,...u}=l;if(v.isValidElement(s)){const f=mC(s),h=hC(u,s.props);return s.type!==v.Fragment&&(h.ref=i?kr(i,f):f),v.cloneElement(s,h)}return v.Children.count(s)>1?v.Children.only(null):null});return a.displayName=`${n}.SlotClone`,a}var fC=Symbol("radix.slottable");function dC(n){return v.isValidElement(n)&&typeof n.type=="function"&&"__radixId"in n.type&&n.type.__radixId===fC}function hC(n,a){const l={...a};for(const i in a){const s=n[i],u=a[i];/^on[A-Z]/.test(i)?s&&u?l[i]=(...h)=>{const p=u(...h);return s(...h),p}:s&&(l[i]=s):i==="style"?l[i]={...s,...u}:i==="className"&&(l[i]=[s,u].filter(Boolean).join(" "))}return{...n,...l}}function mC(n){let a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning;return l?n.ref:(a=Object.getOwnPropertyDescriptor(n,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning,l?n.props.ref:n.props.ref||n.ref)}var pC=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],dt=pC.reduce((n,a)=>{const l=Ou(`Primitive.${a}`),i=v.forwardRef((s,u)=>{const{asChild:f,...h}=s,p=f?l:a;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),y.jsx(p,{...h,ref:u})});return i.displayName=`Primitive.${a}`,{...n,[a]:i}},{});function gC(n,a){n&&Ru.flushSync(()=>n.dispatchEvent(a))}function Vl(n){const a=v.useRef(n);return v.useEffect(()=>{a.current=n}),v.useMemo(()=>(...l)=>a.current?.(...l),[])}function vC(n,a=globalThis?.document){const l=Vl(n);v.useEffect(()=>{const i=s=>{s.key==="Escape"&&l(s)};return a.addEventListener("keydown",i,{capture:!0}),()=>a.removeEventListener("keydown",i,{capture:!0})},[l,a])}var yC="DismissableLayer",Od="dismissableLayer.update",bC="dismissableLayer.pointerDownOutside",xC="dismissableLayer.focusOutside",Fv,d0=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Fd=v.forwardRef((n,a)=>{const{disableOutsidePointerEvents:l=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:u,onInteractOutside:f,onDismiss:h,...p}=n,m=v.useContext(d0),[g,x]=v.useState(null),S=g?.ownerDocument??globalThis?.document,[,w]=v.useState({}),C=fn(a,G=>x(G)),R=Array.from(m.layers),[T]=[...m.layersWithOutsidePointerEventsDisabled].slice(-1),O=R.indexOf(T),z=g?R.indexOf(g):-1,k=m.layersWithOutsidePointerEventsDisabled.size>0,H=z>=O,P=EC(G=>{const J=G.target,re=[...m.branches].some(ie=>ie.contains(J));!H||re||(s?.(G),f?.(G),G.defaultPrevented||h?.())},S),A=RC(G=>{const J=G.target;[...m.branches].some(ie=>ie.contains(J))||(u?.(G),f?.(G),G.defaultPrevented||h?.())},S);return vC(G=>{z===m.layers.size-1&&(i?.(G),!G.defaultPrevented&&h&&(G.preventDefault(),h()))},S),v.useEffect(()=>{if(g)return l&&(m.layersWithOutsidePointerEventsDisabled.size===0&&(Fv=S.body.style.pointerEvents,S.body.style.pointerEvents="none"),m.layersWithOutsidePointerEventsDisabled.add(g)),m.layers.add(g),Xv(),()=>{l&&m.layersWithOutsidePointerEventsDisabled.size===1&&(S.body.style.pointerEvents=Fv)}},[g,S,l,m]),v.useEffect(()=>()=>{g&&(m.layers.delete(g),m.layersWithOutsidePointerEventsDisabled.delete(g),Xv())},[g,m]),v.useEffect(()=>{const G=()=>w({});return document.addEventListener(Od,G),()=>document.removeEventListener(Od,G)},[]),y.jsx(dt.div,{...p,ref:C,style:{pointerEvents:k?H?"auto":"none":void 0,...n.style},onFocusCapture:Jt(n.onFocusCapture,A.onFocusCapture),onBlurCapture:Jt(n.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Jt(n.onPointerDownCapture,P.onPointerDownCapture)})});Fd.displayName=yC;var SC="DismissableLayerBranch",wC=v.forwardRef((n,a)=>{const l=v.useContext(d0),i=v.useRef(null),s=fn(a,i);return v.useEffect(()=>{const u=i.current;if(u)return l.branches.add(u),()=>{l.branches.delete(u)}},[l.branches]),y.jsx(dt.div,{...n,ref:s})});wC.displayName=SC;function EC(n,a=globalThis?.document){const l=Vl(n),i=v.useRef(!1),s=v.useRef(()=>{});return v.useEffect(()=>{const u=h=>{if(h.target&&!i.current){let p=function(){h0(bC,l,m,{discrete:!0})};const m={originalEvent:h};h.pointerType==="touch"?(a.removeEventListener("click",s.current),s.current=p,a.addEventListener("click",s.current,{once:!0})):p()}else a.removeEventListener("click",s.current);i.current=!1},f=window.setTimeout(()=>{a.addEventListener("pointerdown",u)},0);return()=>{window.clearTimeout(f),a.removeEventListener("pointerdown",u),a.removeEventListener("click",s.current)}},[a,l]),{onPointerDownCapture:()=>i.current=!0}}function RC(n,a=globalThis?.document){const l=Vl(n),i=v.useRef(!1);return v.useEffect(()=>{const s=u=>{u.target&&!i.current&&h0(xC,l,{originalEvent:u},{discrete:!1})};return a.addEventListener("focusin",s),()=>a.removeEventListener("focusin",s)},[a,l]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}function Xv(){const n=new CustomEvent(Od);document.dispatchEvent(n)}function h0(n,a,l,{discrete:i}){const s=l.originalEvent.target,u=new CustomEvent(n,{bubbles:!1,cancelable:!0,detail:l});a&&s.addEventListener(n,a,{once:!0}),i?gC(s,u):s.dispatchEvent(u)}var Wf="focusScope.autoFocusOnMount",ed="focusScope.autoFocusOnUnmount",Qv={bubbles:!1,cancelable:!0},CC="FocusScope",Xd=v.forwardRef((n,a)=>{const{loop:l=!1,trapped:i=!1,onMountAutoFocus:s,onUnmountAutoFocus:u,...f}=n,[h,p]=v.useState(null),m=Vl(s),g=Vl(u),x=v.useRef(null),S=fn(a,R=>p(R)),w=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect(()=>{if(i){let R=function(k){if(w.paused||!h)return;const H=k.target;h.contains(H)?x.current=H:Ja(x.current,{select:!0})},T=function(k){if(w.paused||!h)return;const H=k.relatedTarget;H!==null&&(h.contains(H)||Ja(x.current,{select:!0}))},O=function(k){if(document.activeElement===document.body)for(const P of k)P.removedNodes.length>0&&Ja(h)};document.addEventListener("focusin",R),document.addEventListener("focusout",T);const z=new MutationObserver(O);return h&&z.observe(h,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",R),document.removeEventListener("focusout",T),z.disconnect()}}},[i,h,w.paused]),v.useEffect(()=>{if(h){Jv.add(w);const R=document.activeElement;if(!h.contains(R)){const O=new CustomEvent(Wf,Qv);h.addEventListener(Wf,m),h.dispatchEvent(O),O.defaultPrevented||(OC(MC(m0(h)),{select:!0}),document.activeElement===R&&Ja(h))}return()=>{h.removeEventListener(Wf,m),setTimeout(()=>{const O=new CustomEvent(ed,Qv);h.addEventListener(ed,g),h.dispatchEvent(O),O.defaultPrevented||Ja(R??document.body,{select:!0}),h.removeEventListener(ed,g),Jv.remove(w)},0)}}},[h,m,g,w]);const C=v.useCallback(R=>{if(!l&&!i||w.paused)return;const T=R.key==="Tab"&&!R.altKey&&!R.ctrlKey&&!R.metaKey,O=document.activeElement;if(T&&O){const z=R.currentTarget,[k,H]=AC(z);k&&H?!R.shiftKey&&O===H?(R.preventDefault(),l&&Ja(k,{select:!0})):R.shiftKey&&O===k&&(R.preventDefault(),l&&Ja(H,{select:!0})):O===z&&R.preventDefault()}},[l,i,w.paused]);return y.jsx(dt.div,{tabIndex:-1,...f,ref:S,onKeyDown:C})});Xd.displayName=CC;function OC(n,{select:a=!1}={}){const l=document.activeElement;for(const i of n)if(Ja(i,{select:a}),document.activeElement!==l)return}function AC(n){const a=m0(n),l=Zv(a,n),i=Zv(a.reverse(),n);return[l,i]}function m0(n){const a=[],l=document.createTreeWalker(n,NodeFilter.SHOW_ELEMENT,{acceptNode:i=>{const s=i.tagName==="INPUT"&&i.type==="hidden";return i.disabled||i.hidden||s?NodeFilter.FILTER_SKIP:i.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;l.nextNode();)a.push(l.currentNode);return a}function Zv(n,a){for(const l of n)if(!NC(l,{upTo:a}))return l}function NC(n,{upTo:a}){if(getComputedStyle(n).visibility==="hidden")return!0;for(;n;){if(a!==void 0&&n===a)return!1;if(getComputedStyle(n).display==="none")return!0;n=n.parentElement}return!1}function TC(n){return n instanceof HTMLInputElement&&"select"in n}function Ja(n,{select:a=!1}={}){if(n&&n.focus){const l=document.activeElement;n.focus({preventScroll:!0}),n!==l&&TC(n)&&a&&n.select()}}var Jv=jC();function jC(){let n=[];return{add(a){const l=n[0];a!==l&&l?.pause(),n=Iv(n,a),n.unshift(a)},remove(a){n=Iv(n,a),n[0]?.resume()}}}function Iv(n,a){const l=[...n],i=l.indexOf(a);return i!==-1&&l.splice(i,1),l}function MC(n){return n.filter(a=>a.tagName!=="A")}var _C="Portal",Qd=v.forwardRef((n,a)=>{const{container:l,...i}=n,[s,u]=v.useState(!1);nr(()=>u(!0),[]);const f=l||s&&globalThis?.document?.body;return f?eC.createPortal(y.jsx(dt.div,{...i,ref:a}),f):null});Qd.displayName=_C;function DC(n,a){return v.useReducer((l,i)=>a[l][i]??l,n)}var Ql=n=>{const{present:a,children:l}=n,i=LC(a),s=typeof l=="function"?l({present:i.isPresent}):v.Children.only(l),u=fn(i.ref,zC(s));return typeof l=="function"||i.isPresent?v.cloneElement(s,{ref:u}):null};Ql.displayName="Presence";function LC(n){const[a,l]=v.useState(),i=v.useRef(null),s=v.useRef(n),u=v.useRef("none"),f=n?"mounted":"unmounted",[h,p]=DC(f,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const m=qs(i.current);u.current=h==="mounted"?m:"none"},[h]),nr(()=>{const m=i.current,g=s.current;if(g!==n){const S=u.current,w=qs(m);n?p("MOUNT"):w==="none"||m?.display==="none"?p("UNMOUNT"):p(g&&S!==w?"ANIMATION_OUT":"UNMOUNT"),s.current=n}},[n,p]),nr(()=>{if(a){let m;const g=a.ownerDocument.defaultView??window,x=w=>{const R=qs(i.current).includes(w.animationName);if(w.target===a&&R&&(p("ANIMATION_END"),!s.current)){const T=a.style.animationFillMode;a.style.animationFillMode="forwards",m=g.setTimeout(()=>{a.style.animationFillMode==="forwards"&&(a.style.animationFillMode=T)})}},S=w=>{w.target===a&&(u.current=qs(i.current))};return a.addEventListener("animationstart",S),a.addEventListener("animationcancel",x),a.addEventListener("animationend",x),()=>{g.clearTimeout(m),a.removeEventListener("animationstart",S),a.removeEventListener("animationcancel",x),a.removeEventListener("animationend",x)}}else p("ANIMATION_END")},[a,p]),{isPresent:["mounted","unmountSuspended"].includes(h),ref:v.useCallback(m=>{i.current=m?getComputedStyle(m):null,l(m)},[])}}function qs(n){return n?.animationName||"none"}function zC(n){let a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning;return l?n.ref:(a=Object.getOwnPropertyDescriptor(n,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning,l?n.props.ref:n.props.ref||n.ref)}var td=0;function p0(){v.useEffect(()=>{const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",n[0]??Wv()),document.body.insertAdjacentElement("beforeend",n[1]??Wv()),td++,()=>{td===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(a=>a.remove()),td--}},[])}function Wv(){const n=document.createElement("span");return n.setAttribute("data-radix-focus-guard",""),n.tabIndex=0,n.style.outline="none",n.style.opacity="0",n.style.position="fixed",n.style.pointerEvents="none",n}var Vn=function(){return Vn=Object.assign||function(a){for(var l,i=1,s=arguments.length;i<s;i++){l=arguments[i];for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(a[u]=l[u])}return a},Vn.apply(this,arguments)};function g0(n,a){var l={};for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&a.indexOf(i)<0&&(l[i]=n[i]);if(n!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(n);s<i.length;s++)a.indexOf(i[s])<0&&Object.prototype.propertyIsEnumerable.call(n,i[s])&&(l[i[s]]=n[i[s]]);return l}function kC(n,a,l){if(l||arguments.length===2)for(var i=0,s=a.length,u;i<s;i++)(u||!(i in a))&&(u||(u=Array.prototype.slice.call(a,0,i)),u[i]=a[i]);return n.concat(u||Array.prototype.slice.call(a))}var au="right-scroll-bar-position",ru="width-before-scroll-bar",UC="with-scroll-bars-hidden",PC="--removed-body-scroll-bar-size";function nd(n,a){return typeof n=="function"?n(a):n&&(n.current=a),n}function HC(n,a){var l=v.useState(function(){return{value:n,callback:a,facade:{get current(){return l.value},set current(i){var s=l.value;s!==i&&(l.value=i,l.callback(i,s))}}}})[0];return l.callback=a,l.facade}var BC=typeof window<"u"?v.useLayoutEffect:v.useEffect,ey=new WeakMap;function $C(n,a){var l=HC(null,function(i){return n.forEach(function(s){return nd(s,i)})});return BC(function(){var i=ey.get(l);if(i){var s=new Set(i),u=new Set(n),f=l.current;s.forEach(function(h){u.has(h)||nd(h,null)}),u.forEach(function(h){s.has(h)||nd(h,f)})}ey.set(l,n)},[n]),l}function VC(n){return n}function qC(n,a){a===void 0&&(a=VC);var l=[],i=!1,s={read:function(){if(i)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return l.length?l[l.length-1]:n},useMedium:function(u){var f=a(u,i);return l.push(f),function(){l=l.filter(function(h){return h!==f})}},assignSyncMedium:function(u){for(i=!0;l.length;){var f=l;l=[],f.forEach(u)}l={push:function(h){return u(h)},filter:function(){return l}}},assignMedium:function(u){i=!0;var f=[];if(l.length){var h=l;l=[],h.forEach(u),f=l}var p=function(){var g=f;f=[],g.forEach(u)},m=function(){return Promise.resolve().then(p)};m(),l={push:function(g){f.push(g),m()},filter:function(g){return f=f.filter(g),l}}}};return s}function YC(n){n===void 0&&(n={});var a=qC(null);return a.options=Vn({async:!0,ssr:!1},n),a}var v0=function(n){var a=n.sideCar,l=g0(n,["sideCar"]);if(!a)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var i=a.read();if(!i)throw new Error("Sidecar medium not found");return v.createElement(i,Vn({},l))};v0.isSideCarExport=!0;function KC(n,a){return n.useMedium(a),v0}var y0=YC(),ad=function(){},Au=v.forwardRef(function(n,a){var l=v.useRef(null),i=v.useState({onScrollCapture:ad,onWheelCapture:ad,onTouchMoveCapture:ad}),s=i[0],u=i[1],f=n.forwardProps,h=n.children,p=n.className,m=n.removeScrollBar,g=n.enabled,x=n.shards,S=n.sideCar,w=n.noRelative,C=n.noIsolation,R=n.inert,T=n.allowPinchZoom,O=n.as,z=O===void 0?"div":O,k=n.gapMode,H=g0(n,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=S,A=$C([l,a]),G=Vn(Vn({},H),s);return v.createElement(v.Fragment,null,g&&v.createElement(P,{sideCar:y0,removeScrollBar:m,shards:x,noRelative:w,noIsolation:C,inert:R,setCallbacks:u,allowPinchZoom:!!T,lockRef:l,gapMode:k}),f?v.cloneElement(v.Children.only(h),Vn(Vn({},G),{ref:A})):v.createElement(z,Vn({},G,{className:p,ref:A}),h))});Au.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Au.classNames={fullWidth:ru,zeroRight:au};var GC=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function FC(){if(!document)return null;var n=document.createElement("style");n.type="text/css";var a=GC();return a&&n.setAttribute("nonce",a),n}function XC(n,a){n.styleSheet?n.styleSheet.cssText=a:n.appendChild(document.createTextNode(a))}function QC(n){var a=document.head||document.getElementsByTagName("head")[0];a.appendChild(n)}var ZC=function(){var n=0,a=null;return{add:function(l){n==0&&(a=FC())&&(XC(a,l),QC(a)),n++},remove:function(){n--,!n&&a&&(a.parentNode&&a.parentNode.removeChild(a),a=null)}}},JC=function(){var n=ZC();return function(a,l){v.useEffect(function(){return n.add(a),function(){n.remove()}},[a&&l])}},b0=function(){var n=JC(),a=function(l){var i=l.styles,s=l.dynamic;return n(i,s),null};return a},IC={left:0,top:0,right:0,gap:0},rd=function(n){return parseInt(n||"",10)||0},WC=function(n){var a=window.getComputedStyle(document.body),l=a[n==="padding"?"paddingLeft":"marginLeft"],i=a[n==="padding"?"paddingTop":"marginTop"],s=a[n==="padding"?"paddingRight":"marginRight"];return[rd(l),rd(i),rd(s)]},e2=function(n){if(n===void 0&&(n="margin"),typeof window>"u")return IC;var a=WC(n),l=document.documentElement.clientWidth,i=window.innerWidth;return{left:a[0],top:a[1],right:a[2],gap:Math.max(0,i-l+a[2]-a[0])}},t2=b0(),Hl="data-scroll-locked",n2=function(n,a,l,i){var s=n.left,u=n.top,f=n.right,h=n.gap;return l===void 0&&(l="margin"),`
|
|
67
|
+
Please change the parent <Route path="${O}"> to <Route path="${O==="/"?"*":`${O}/*`}">.`)}let x=ir(),S;S=x;let w=S.pathname||"/",C=w;if(m!=="/"){let O=m.replace(/^\//,"").split("/");C="/"+w.replace(/^\//,"").split("/").slice(O.length).join("/")}let R=Ia(n,{pathname:C});return St(g||R!=null,`No routes matched location "${S.pathname}${S.search}${S.hash}" `),St(R==null||R[R.length-1].route.element!==void 0||R[R.length-1].route.Component!==void 0||R[R.length-1].route.lazy!==void 0,`Matched leaf route at location "${S.pathname}${S.search}${S.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`),oR(R&&R.map(O=>Object.assign({},O,{params:Object.assign({},h,O.params),pathname:Kn([m,s.encodeLocation?s.encodeLocation(O.pathname).pathname:O.pathname]),pathnameBase:O.pathnameBase==="/"?m:Kn([m,s.encodeLocation?s.encodeLocation(O.pathnameBase).pathname:O.pathnameBase])})),u,l,i)}function aR(){let n=dR(),a=ho(n)?`${n.status} ${n.statusText}`:n instanceof Error?n.message:JSON.stringify(n),l=n instanceof Error?n.stack:null,i="rgba(200,200,200, 0.5)",s={padding:"0.5rem",backgroundColor:i},u={padding:"2px 4px",backgroundColor:i},f=null;return console.error("Error handled by React Router default ErrorBoundary:",n),f=v.createElement(v.Fragment,null,v.createElement("p",null,"💿 Hey developer 👋"),v.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",v.createElement("code",{style:u},"ErrorBoundary")," or"," ",v.createElement("code",{style:u},"errorElement")," prop on your route.")),v.createElement(v.Fragment,null,v.createElement("h2",null,"Unexpected Application Error!"),v.createElement("h3",{style:{fontStyle:"italic"}},a),l?v.createElement("pre",{style:s},l):null,f)}var rR=v.createElement(aR,null),lR=class extends v.Component{constructor(n){super(n),this.state={location:n.location,revalidation:n.revalidation,error:n.error}}static getDerivedStateFromError(n){return{error:n}}static getDerivedStateFromProps(n,a){return a.location!==n.location||a.revalidation!=="idle"&&n.revalidation==="idle"?{error:n.error,location:n.location,revalidation:n.revalidation}:{error:n.error!==void 0?n.error:a.error,location:a.location,revalidation:n.revalidation||a.revalidation}}componentDidCatch(n,a){console.error("React Router caught the following error during render",n,a)}render(){return this.state.error!==void 0?v.createElement(Qn.Provider,{value:this.props.routeContext},v.createElement($d.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function iR({routeContext:n,match:a,children:l}){let i=v.useContext(Vr);return i&&i.static&&i.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=a.route.id),v.createElement(Qn.Provider,{value:n},l)}function oR(n,a=[],l=null,i=null){if(n==null){if(!l)return null;if(l.errors)n=l.matches;else if(a.length===0&&!l.initialized&&l.matches.length>0)n=l.matches;else return null}let s=n,u=l?.errors;if(u!=null){let p=s.findIndex(m=>m.route.id&&u?.[m.route.id]!==void 0);Fe(p>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(u).join(",")}`),s=s.slice(0,Math.min(s.length,p+1))}let f=!1,h=-1;if(l)for(let p=0;p<s.length;p++){let m=s[p];if((m.route.HydrateFallback||m.route.hydrateFallbackElement)&&(h=p),m.route.id){let{loaderData:g,errors:x}=l,S=m.route.loader&&!g.hasOwnProperty(m.route.id)&&(!x||x[m.route.id]===void 0);if(m.route.lazy||S){f=!0,h>=0?s=s.slice(0,h+1):s=[s[0]];break}}}return s.reduceRight((p,m,g)=>{let x,S=!1,w=null,C=null;l&&(x=u&&m.route.id?u[m.route.id]:void 0,w=m.route.errorElement||rR,f&&(h<0&&g===0?(l0("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),S=!0,C=null):h===g&&(S=!0,C=m.route.hydrateFallbackElement||null)));let R=a.concat(s.slice(0,g+1)),T=()=>{let O;return x?O=w:S?O=C:m.route.Component?O=v.createElement(m.route.Component,null):m.route.element?O=m.route.element:O=p,v.createElement(iR,{match:m,routeContext:{outlet:p,matches:R,isDataRoute:l!=null},children:O})};return l&&(m.route.ErrorBoundary||m.route.errorElement||g===0)?v.createElement(lR,{location:l.location,revalidation:l.revalidation,component:w,error:x,children:T(),routeContext:{outlet:null,matches:R,isDataRoute:!0}}):T()},null)}function Vd(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function sR(n){let a=v.useContext(Vr);return Fe(a,Vd(n)),a}function uR(n){let a=v.useContext(bo);return Fe(a,Vd(n)),a}function cR(n){let a=v.useContext(Qn);return Fe(a,Vd(n)),a}function qd(n){let a=cR(n),l=a.matches[a.matches.length-1];return Fe(l.route.id,`${n} can only be used on routes that contain a unique "id"`),l.route.id}function fR(){return qd("useRouteId")}function dR(){let n=v.useContext($d),a=uR("useRouteError"),l=qd("useRouteError");return n!==void 0?n:a.errors?.[l]}function hR(){let{router:n}=sR("useNavigate"),a=qd("useNavigate"),l=v.useRef(!1);return r0(()=>{l.current=!0}),v.useCallback(async(s,u={})=>{St(l.current,a0),l.current&&(typeof s=="number"?n.navigate(s):await n.navigate(s,{fromRouteId:a,...u}))},[n,a])}var Vv={};function l0(n,a,l){!a&&!Vv[n]&&(Vv[n]=!0,St(!1,l))}var qv={};function Yv(n,a){!n&&!qv[a]&&(qv[a]=!0,console.warn(a))}function mR(n){let a={hasErrorBoundary:n.hasErrorBoundary||n.ErrorBoundary!=null||n.errorElement!=null};return n.Component&&(n.element&&St(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(a,{element:v.createElement(n.Component),Component:void 0})),n.HydrateFallback&&(n.hydrateFallbackElement&&St(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(a,{hydrateFallbackElement:v.createElement(n.HydrateFallback),HydrateFallback:void 0})),n.ErrorBoundary&&(n.errorElement&&St(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(a,{errorElement:v.createElement(n.ErrorBoundary),ErrorBoundary:void 0})),a}var pR=["HydrateFallback","hydrateFallbackElement"];function gR(n,a){return LE({basename:a?.basename,unstable_getContext:a?.unstable_getContext,future:a?.future,history:Ww({initialEntries:a?.initialEntries,initialIndex:a?.initialIndex}),hydrationData:a?.hydrationData,routes:n,hydrationRouteProperties:pR,mapRouteProperties:mR,dataStrategy:a?.dataStrategy,patchRoutesOnNavigation:a?.patchRoutesOnNavigation}).initialize()}var vR=class{constructor(){this.status="pending",this.promise=new Promise((n,a)=>{this.resolve=l=>{this.status==="pending"&&(this.status="resolved",n(l))},this.reject=l=>{this.status==="pending"&&(this.status="rejected",a(l))}})}};function yR({router:n,flushSync:a}){let[l,i]=v.useState(n.state),[s,u]=v.useState(),[f,h]=v.useState({isTransitioning:!1}),[p,m]=v.useState(),[g,x]=v.useState(),[S,w]=v.useState(),C=v.useRef(new Map),R=v.useCallback((k,{deletedFetchers:H,flushSync:P,viewTransitionOpts:A})=>{k.fetchers.forEach((J,re)=>{J.data!==void 0&&C.current.set(re,J.data)}),H.forEach(J=>C.current.delete(J)),Yv(P===!1||a!=null,'You provided the `flushSync` option to a router update, but you are not using the `<RouterProvider>` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable. Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let G=n.window!=null&&n.window.document!=null&&typeof n.window.document.startViewTransition=="function";if(Yv(A==null||G,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!A||!G){a&&P?a(()=>i(k)):v.startTransition(()=>i(k));return}if(a&&P){a(()=>{g&&(p&&p.resolve(),g.skipTransition()),h({isTransitioning:!0,flushSync:!0,currentLocation:A.currentLocation,nextLocation:A.nextLocation})});let J=n.window.document.startViewTransition(()=>{a(()=>i(k))});J.finished.finally(()=>{a(()=>{m(void 0),x(void 0),u(void 0),h({isTransitioning:!1})})}),a(()=>x(J));return}g?(p&&p.resolve(),g.skipTransition(),w({state:k,currentLocation:A.currentLocation,nextLocation:A.nextLocation})):(u(k),h({isTransitioning:!0,flushSync:!1,currentLocation:A.currentLocation,nextLocation:A.nextLocation}))},[n.window,a,g,p]);v.useLayoutEffect(()=>n.subscribe(R),[n,R]),v.useEffect(()=>{f.isTransitioning&&!f.flushSync&&m(new vR)},[f]),v.useEffect(()=>{if(p&&s&&n.window){let k=s,H=p.promise,P=n.window.document.startViewTransition(async()=>{v.startTransition(()=>i(k)),await H});P.finished.finally(()=>{m(void 0),x(void 0),u(void 0),h({isTransitioning:!1})}),x(P)}},[s,p,n.window]),v.useEffect(()=>{p&&s&&l.location.key===s.location.key&&p.resolve()},[p,g,l.location,s]),v.useEffect(()=>{!f.isTransitioning&&S&&(u(S.state),h({isTransitioning:!0,flushSync:!1,currentLocation:S.currentLocation,nextLocation:S.nextLocation}),w(void 0))},[f.isTransitioning,S]);let T=v.useMemo(()=>({createHref:n.createHref,encodeLocation:n.encodeLocation,go:k=>n.navigate(k),push:(k,H,P)=>n.navigate(k,{state:H,preventScrollReset:P?.preventScrollReset}),replace:(k,H,P)=>n.navigate(k,{replace:!0,state:H,preventScrollReset:P?.preventScrollReset})}),[n]),O=n.basename||"/",z=v.useMemo(()=>({router:n,navigator:T,static:!1,basename:O}),[n,T,O]);return v.createElement(v.Fragment,null,v.createElement(Vr.Provider,{value:z},v.createElement(bo.Provider,{value:l},v.createElement(n0.Provider,{value:C.current},v.createElement(Bd.Provider,{value:f},v.createElement(wR,{basename:O,location:l.location,navigationType:l.historyAction,navigator:T},v.createElement(bR,{routes:n.routes,future:n.future,state:l})))))),null)}var bR=v.memo(xR);function xR({routes:n,future:a,state:l}){return nR(n,void 0,l,a)}function SR({to:n,replace:a,state:l,relative:i}){Fe(Xl(),"<Navigate> may be used only in the context of a <Router> component.");let{static:s}=v.useContext(_n);St(!s,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:u}=v.useContext(Qn),{pathname:f}=ir(),h=wu(),p=xu(n,bu(u),f,i==="path"),m=JSON.stringify(p);return v.useEffect(()=>{h(JSON.parse(m),{replace:a,state:l,relative:i})},[h,m,i,a,l]),null}function wR({basename:n="/",children:a=null,location:l,navigationType:i="POP",navigator:s,static:u=!1}){Fe(!Xl(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let f=n.replace(/^\/*/,"/"),h=v.useMemo(()=>({basename:f,navigator:s,static:u,future:{}}),[f,s,u]);typeof l=="string"&&(l=Ea(l));let{pathname:p="/",search:m="",hash:g="",state:x=null,key:S="default"}=l,w=v.useMemo(()=>{let C=Rn(p,f);return C==null?null:{location:{pathname:C,search:m,hash:g,state:x,key:S},navigationType:i}},[f,p,m,g,x,S,i]);return St(w!=null,`<Router basename="${f}"> is not able to match the URL "${p}${m}${g}" because it does not start with the basename, so the <Router> won't render anything.`),w==null?null:v.createElement(_n.Provider,{value:h},v.createElement(Su.Provider,{children:a,value:w}))}var tu="get",nu="application/x-www-form-urlencoded";function Eu(n){return n!=null&&typeof n.tagName=="string"}function ER(n){return Eu(n)&&n.tagName.toLowerCase()==="button"}function RR(n){return Eu(n)&&n.tagName.toLowerCase()==="form"}function CR(n){return Eu(n)&&n.tagName.toLowerCase()==="input"}function OR(n){return!!(n.metaKey||n.altKey||n.ctrlKey||n.shiftKey)}function AR(n,a){return n.button===0&&(!a||a==="_self")&&!OR(n)}var Vs=null;function NR(){if(Vs===null)try{new FormData(document.createElement("form"),0),Vs=!1}catch{Vs=!0}return Vs}var TR=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function If(n){return n!=null&&!TR.has(n)?(St(!1,`"${n}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${nu}"`),null):n}function jR(n,a){let l,i,s,u,f;if(RR(n)){let h=n.getAttribute("action");i=h?Rn(h,a):null,l=n.getAttribute("method")||tu,s=If(n.getAttribute("enctype"))||nu,u=new FormData(n)}else if(ER(n)||CR(n)&&(n.type==="submit"||n.type==="image")){let h=n.form;if(h==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let p=n.getAttribute("formaction")||h.getAttribute("action");if(i=p?Rn(p,a):null,l=n.getAttribute("formmethod")||h.getAttribute("method")||tu,s=If(n.getAttribute("formenctype"))||If(h.getAttribute("enctype"))||nu,u=new FormData(h,n),!NR()){let{name:m,type:g,value:x}=n;if(g==="image"){let S=m?`${m}.`:"";u.append(`${S}x`,"0"),u.append(`${S}y`,"0")}else m&&u.append(m,x)}}else{if(Eu(n))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');l=tu,i=null,s=nu,f=n}return u&&s==="text/plain"&&(f=u,u=void 0),{action:i,method:l.toLowerCase(),encType:s,formData:u,body:f}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function Yd(n,a){if(n===!1||n===null||typeof n>"u")throw new Error(a)}function MR(n,a,l){let i=typeof n=="string"?new URL(n,typeof window>"u"?"server://singlefetch/":window.location.origin):n;return i.pathname==="/"?i.pathname=`_root.${l}`:a&&Rn(i.pathname,a)==="/"?i.pathname=`${a.replace(/\/$/,"")}/_root.${l}`:i.pathname=`${i.pathname.replace(/\/$/,"")}.${l}`,i}async function _R(n,a){if(n.id in a)return a[n.id];try{let l=await import(n.module);return a[n.id]=l,l}catch(l){return console.error(`Error loading route module \`${n.module}\`, reloading page...`),console.error(l),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function DR(n){return n==null?!1:n.href==null?n.rel==="preload"&&typeof n.imageSrcSet=="string"&&typeof n.imageSizes=="string":typeof n.rel=="string"&&typeof n.href=="string"}async function LR(n,a,l){let i=await Promise.all(n.map(async s=>{let u=a.routes[s.route.id];if(u){let f=await _R(u,l);return f.links?f.links():[]}return[]}));return PR(i.flat(1).filter(DR).filter(s=>s.rel==="stylesheet"||s.rel==="preload").map(s=>s.rel==="stylesheet"?{...s,rel:"prefetch",as:"style"}:{...s,rel:"prefetch"}))}function Kv(n,a,l,i,s,u){let f=(p,m)=>l[m]?p.route.id!==l[m].route.id:!0,h=(p,m)=>l[m].pathname!==p.pathname||l[m].route.path?.endsWith("*")&&l[m].params["*"]!==p.params["*"];return u==="assets"?a.filter((p,m)=>f(p,m)||h(p,m)):u==="data"?a.filter((p,m)=>{let g=i.routes[p.route.id];if(!g||!g.hasLoader)return!1;if(f(p,m)||h(p,m))return!0;if(p.route.shouldRevalidate){let x=p.route.shouldRevalidate({currentUrl:new URL(s.pathname+s.search+s.hash,window.origin),currentParams:l[0]?.params||{},nextUrl:new URL(n,window.origin),nextParams:p.params,defaultShouldRevalidate:!0});if(typeof x=="boolean")return x}return!0}):[]}function zR(n,a,{includeHydrateFallback:l}={}){return kR(n.map(i=>{let s=a.routes[i.route.id];if(!s)return[];let u=[s.module];return s.clientActionModule&&(u=u.concat(s.clientActionModule)),s.clientLoaderModule&&(u=u.concat(s.clientLoaderModule)),l&&s.hydrateFallbackModule&&(u=u.concat(s.hydrateFallbackModule)),s.imports&&(u=u.concat(s.imports)),u}).flat(1))}function kR(n){return[...new Set(n)]}function UR(n){let a={},l=Object.keys(n).sort();for(let i of l)a[i]=n[i];return a}function PR(n,a){let l=new Set;return new Set(a),n.reduce((i,s)=>{let u=JSON.stringify(UR(s));return l.has(u)||(l.add(u),i.push({key:u,link:s})),i},[])}function i0(){let n=v.useContext(Vr);return Yd(n,"You must render this element inside a <DataRouterContext.Provider> element"),n}function HR(){let n=v.useContext(bo);return Yd(n,"You must render this element inside a <DataRouterStateContext.Provider> element"),n}var Kd=v.createContext(void 0);Kd.displayName="FrameworkContext";function o0(){let n=v.useContext(Kd);return Yd(n,"You must render this element inside a <HydratedRouter> element"),n}function BR(n,a){let l=v.useContext(Kd),[i,s]=v.useState(!1),[u,f]=v.useState(!1),{onFocus:h,onBlur:p,onMouseEnter:m,onMouseLeave:g,onTouchStart:x}=a,S=v.useRef(null);v.useEffect(()=>{if(n==="render"&&f(!0),n==="viewport"){let R=O=>{O.forEach(z=>{f(z.isIntersecting)})},T=new IntersectionObserver(R,{threshold:.5});return S.current&&T.observe(S.current),()=>{T.disconnect()}}},[n]),v.useEffect(()=>{if(i){let R=setTimeout(()=>{f(!0)},100);return()=>{clearTimeout(R)}}},[i]);let w=()=>{s(!0)},C=()=>{s(!1),f(!1)};return l?n!=="intent"?[u,S,{}]:[u,S,{onFocus:no(h,w),onBlur:no(p,C),onMouseEnter:no(m,w),onMouseLeave:no(g,C),onTouchStart:no(x,w)}]:[!1,S,{}]}function no(n,a){return l=>{n&&n(l),l.defaultPrevented||a(l)}}function $R({page:n,...a}){let{router:l}=i0(),i=v.useMemo(()=>Ia(l.routes,n,l.basename),[l.routes,n,l.basename]);return i?v.createElement(qR,{page:n,matches:i,...a}):null}function VR(n){let{manifest:a,routeModules:l}=o0(),[i,s]=v.useState([]);return v.useEffect(()=>{let u=!1;return LR(n,a,l).then(f=>{u||s(f)}),()=>{u=!0}},[n,a,l]),i}function qR({page:n,matches:a,...l}){let i=ir(),{manifest:s,routeModules:u}=o0(),{basename:f}=i0(),{loaderData:h,matches:p}=HR(),m=v.useMemo(()=>Kv(n,a,p,s,i,"data"),[n,a,p,s,i]),g=v.useMemo(()=>Kv(n,a,p,s,i,"assets"),[n,a,p,s,i]),x=v.useMemo(()=>{if(n===i.pathname+i.search+i.hash)return[];let C=new Set,R=!1;if(a.forEach(O=>{let z=s.routes[O.route.id];!z||!z.hasLoader||(!m.some(k=>k.route.id===O.route.id)&&O.route.id in h&&u[O.route.id]?.shouldRevalidate||z.hasClientLoader?R=!0:C.add(O.route.id))}),C.size===0)return[];let T=MR(n,f,"data");return R&&C.size>0&&T.searchParams.set("_routes",a.filter(O=>C.has(O.route.id)).map(O=>O.route.id).join(",")),[T.pathname+T.search]},[f,h,i,s,m,a,n,u]),S=v.useMemo(()=>zR(g,s),[g,s]),w=VR(g);return v.createElement(v.Fragment,null,x.map(C=>v.createElement("link",{key:C,rel:"prefetch",as:"fetch",href:C,...l})),S.map(C=>v.createElement("link",{key:C,rel:"modulepreload",href:C,...l})),w.map(({key:C,link:R})=>v.createElement("link",{key:C,...R})))}function YR(...n){return a=>{n.forEach(l=>{typeof l=="function"?l(a):l!=null&&(l.current=a)})}}var s0=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{s0&&(window.__reactRouterVersion="7.7.0")}catch{}var u0=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,c0=v.forwardRef(function({onClick:a,discover:l="render",prefetch:i="none",relative:s,reloadDocument:u,replace:f,state:h,target:p,to:m,preventScrollReset:g,viewTransition:x,...S},w){let{basename:C}=v.useContext(_n),R=typeof m=="string"&&u0.test(m),T,O=!1;if(typeof m=="string"&&R&&(T=m,s0))try{let re=new URL(window.location.href),ie=m.startsWith("//")?new URL(re.protocol+m):new URL(m),Oe=Rn(ie.pathname,C);ie.origin===re.origin&&Oe!=null?m=Oe+ie.search+ie.hash:O=!0}catch{St(!1,`<Link to="${m}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let z=eR(m,{relative:s}),[k,H,P]=BR(i,S),A=XR(m,{replace:f,state:h,target:p,preventScrollReset:g,relative:s,viewTransition:x});function G(re){a&&a(re),re.defaultPrevented||A(re)}let J=v.createElement("a",{...S,...P,href:T||z,onClick:O||u?a:G,ref:YR(w,H),target:p,"data-discover":!R&&l==="render"?"true":void 0});return k&&!R?v.createElement(v.Fragment,null,J,v.createElement($R,{page:z})):J});c0.displayName="Link";var KR=v.forwardRef(function({"aria-current":a="page",caseSensitive:l=!1,className:i="",end:s=!1,style:u,to:f,viewTransition:h,children:p,...m},g){let x=xo(f,{relative:m.relative}),S=ir(),w=v.useContext(bo),{navigator:C,basename:R}=v.useContext(_n),T=w!=null&&WR(x)&&h===!0,O=C.encodeLocation?C.encodeLocation(x).pathname:x.pathname,z=S.pathname,k=w&&w.navigation&&w.navigation.location?w.navigation.location.pathname:null;l||(z=z.toLowerCase(),k=k?k.toLowerCase():null,O=O.toLowerCase()),k&&R&&(k=Rn(k,R)||k);const H=O!=="/"&&O.endsWith("/")?O.length-1:O.length;let P=z===O||!s&&z.startsWith(O)&&z.charAt(H)==="/",A=k!=null&&(k===O||!s&&k.startsWith(O)&&k.charAt(O.length)==="/"),G={isActive:P,isPending:A,isTransitioning:T},J=P?a:void 0,re;typeof i=="function"?re=i(G):re=[i,P?"active":null,A?"pending":null,T?"transitioning":null].filter(Boolean).join(" ");let ie=typeof u=="function"?u(G):u;return v.createElement(c0,{...m,"aria-current":J,className:re,ref:g,style:ie,to:f,viewTransition:h},typeof p=="function"?p(G):p)});KR.displayName="NavLink";var GR=v.forwardRef(({discover:n="render",fetcherKey:a,navigate:l,reloadDocument:i,replace:s,state:u,method:f=tu,action:h,onSubmit:p,relative:m,preventScrollReset:g,viewTransition:x,...S},w)=>{let C=JR(),R=IR(h,{relative:m}),T=f.toLowerCase()==="get"?"get":"post",O=typeof h=="string"&&u0.test(h),z=k=>{if(p&&p(k),k.defaultPrevented)return;k.preventDefault();let H=k.nativeEvent.submitter,P=H?.getAttribute("formmethod")||f;C(H||k.currentTarget,{fetcherKey:a,method:P,navigate:l,replace:s,state:u,relative:m,preventScrollReset:g,viewTransition:x})};return v.createElement("form",{ref:w,method:T,action:R,onSubmit:i?p:z,...S,"data-discover":!O&&n==="render"?"true":void 0})});GR.displayName="Form";function FR(n){return`${n} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function f0(n){let a=v.useContext(Vr);return Fe(a,FR(n)),a}function XR(n,{target:a,replace:l,state:i,preventScrollReset:s,relative:u,viewTransition:f}={}){let h=wu(),p=ir(),m=xo(n,{relative:u});return v.useCallback(g=>{if(AR(g,a)){g.preventDefault();let x=l!==void 0?l:tr(p)===tr(m);h(n,{replace:x,state:i,preventScrollReset:s,relative:u,viewTransition:f})}},[p,h,m,l,i,a,n,s,u,f])}var QR=0,ZR=()=>`__${String(++QR)}__`;function JR(){let{router:n}=f0("useSubmit"),{basename:a}=v.useContext(_n),l=fR();return v.useCallback(async(i,s={})=>{let{action:u,method:f,encType:h,formData:p,body:m}=jR(i,a);if(s.navigate===!1){let g=s.fetcherKey||ZR();await n.fetch(g,l,s.action||u,{preventScrollReset:s.preventScrollReset,formData:p,body:m,formMethod:s.method||f,formEncType:s.encType||h,flushSync:s.flushSync})}else await n.navigate(s.action||u,{preventScrollReset:s.preventScrollReset,formData:p,body:m,formMethod:s.method||f,formEncType:s.encType||h,replace:s.replace,state:s.state,fromRouteId:l,flushSync:s.flushSync,viewTransition:s.viewTransition})},[n,a,l])}function IR(n,{relative:a}={}){let{basename:l}=v.useContext(_n),i=v.useContext(Qn);Fe(i,"useFormAction must be used inside a RouteContext");let[s]=i.matches.slice(-1),u={...xo(n||".",{relative:a})},f=ir();if(n==null){u.search=f.search;let h=new URLSearchParams(u.search),p=h.getAll("index");if(p.some(g=>g==="")){h.delete("index"),p.filter(x=>x).forEach(x=>h.append("index",x));let g=h.toString();u.search=g?`?${g}`:""}}return(!n||n===".")&&s.route.index&&(u.search=u.search?u.search.replace(/^\?/,"?index&"):"?index"),l!=="/"&&(u.pathname=u.pathname==="/"?l:Kn([l,u.pathname])),tr(u)}function WR(n,a={}){let l=v.useContext(Bd);Fe(l!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:i}=f0("useViewTransitionState"),s=xo(n,{relative:a.relative});if(!l.isTransitioning)return!1;let u=Rn(l.currentLocation.pathname,i)||l.currentLocation.pathname,f=Rn(l.nextLocation.pathname,i)||l.nextLocation.pathname;return uu(s.pathname,f)!=null||uu(s.pathname,u)!=null}var Ru=$y();const eC=My(Ru);function tC(n){return v.createElement(yR,{flushSync:Ru.flushSync,...n})}function Zt(n,a,{checkForDefaultPrevented:l=!0}={}){return function(s){if(n?.(s),l===!1||!s.defaultPrevented)return a?.(s)}}function Gv(n,a){if(typeof n=="function")return n(a);n!=null&&(n.current=a)}function kr(...n){return a=>{let l=!1;const i=n.map(s=>{const u=Gv(s,a);return!l&&typeof u=="function"&&(l=!0),u});if(l)return()=>{for(let s=0;s<i.length;s++){const u=i[s];typeof u=="function"?u():Gv(n[s],null)}}}}function fn(...n){return v.useCallback(kr(...n),n)}function nC(n,a){const l=v.createContext(a),i=u=>{const{children:f,...h}=u,p=v.useMemo(()=>h,Object.values(h));return y.jsx(l.Provider,{value:p,children:f})};i.displayName=n+"Provider";function s(u){const f=v.useContext(l);if(f)return f;if(a!==void 0)return a;throw new Error(`\`${u}\` must be used within \`${n}\``)}return[i,s]}function Cu(n,a=[]){let l=[];function i(u,f){const h=v.createContext(f),p=l.length;l=[...l,f];const m=x=>{const{scope:S,children:w,...C}=x,R=S?.[n]?.[p]||h,T=v.useMemo(()=>C,Object.values(C));return y.jsx(R.Provider,{value:T,children:w})};m.displayName=u+"Provider";function g(x,S){const w=S?.[n]?.[p]||h,C=v.useContext(w);if(C)return C;if(f!==void 0)return f;throw new Error(`\`${x}\` must be used within \`${u}\``)}return[m,g]}const s=()=>{const u=l.map(f=>v.createContext(f));return function(h){const p=h?.[n]||u;return v.useMemo(()=>({[`__scope${n}`]:{...h,[n]:p}}),[h,p])}};return s.scopeName=n,[i,aC(s,...a)]}function aC(...n){const a=n[0];if(n.length===1)return a;const l=()=>{const i=n.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(u){const f=i.reduce((h,{useScope:p,scopeName:m})=>{const x=p(u)[`__scope${m}`];return{...h,...x}},{});return v.useMemo(()=>({[`__scope${a.scopeName}`]:f}),[f])}};return l.scopeName=a.scopeName,l}var nr=globalThis?.document?v.useLayoutEffect:()=>{},rC=Ly[" useId ".trim().toString()]||(()=>{}),lC=0;function Gn(n){const[a,l]=v.useState(rC());return nr(()=>{l(i=>i??String(lC++))},[n]),n||(a?`radix-${a}`:"")}var iC=Ly[" useInsertionEffect ".trim().toString()]||nr;function Gd({prop:n,defaultProp:a,onChange:l=()=>{},caller:i}){const[s,u,f]=oC({defaultProp:a,onChange:l}),h=n!==void 0,p=h?n:s;{const g=v.useRef(n!==void 0);v.useEffect(()=>{const x=g.current;x!==h&&console.warn(`${i} is changing from ${x?"controlled":"uncontrolled"} to ${h?"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.`),g.current=h},[h,i])}const m=v.useCallback(g=>{if(h){const x=sC(g)?g(n):g;x!==n&&f.current?.(x)}else u(g)},[h,n,u,f]);return[p,m]}function oC({defaultProp:n,onChange:a}){const[l,i]=v.useState(n),s=v.useRef(l),u=v.useRef(a);return iC(()=>{u.current=a},[a]),v.useEffect(()=>{s.current!==l&&(u.current?.(l),s.current=l)},[l,s]),[l,i,u]}function sC(n){return typeof n=="function"}function Ou(n){const a=cC(n),l=v.forwardRef((i,s)=>{const{children:u,...f}=i,h=v.Children.toArray(u),p=h.find(dC);if(p){const m=p.props.children,g=h.map(x=>x===p?v.Children.count(m)>1?v.Children.only(null):v.isValidElement(m)?m.props.children:null:x);return y.jsx(a,{...f,ref:s,children:v.isValidElement(m)?v.cloneElement(m,void 0,g):null})}return y.jsx(a,{...f,ref:s,children:u})});return l.displayName=`${n}.Slot`,l}var uC=Ou("Slot");function cC(n){const a=v.forwardRef((l,i)=>{const{children:s,...u}=l;if(v.isValidElement(s)){const f=mC(s),h=hC(u,s.props);return s.type!==v.Fragment&&(h.ref=i?kr(i,f):f),v.cloneElement(s,h)}return v.Children.count(s)>1?v.Children.only(null):null});return a.displayName=`${n}.SlotClone`,a}var fC=Symbol("radix.slottable");function dC(n){return v.isValidElement(n)&&typeof n.type=="function"&&"__radixId"in n.type&&n.type.__radixId===fC}function hC(n,a){const l={...a};for(const i in a){const s=n[i],u=a[i];/^on[A-Z]/.test(i)?s&&u?l[i]=(...h)=>{const p=u(...h);return s(...h),p}:s&&(l[i]=s):i==="style"?l[i]={...s,...u}:i==="className"&&(l[i]=[s,u].filter(Boolean).join(" "))}return{...n,...l}}function mC(n){let a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning;return l?n.ref:(a=Object.getOwnPropertyDescriptor(n,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning,l?n.props.ref:n.props.ref||n.ref)}var pC=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],dt=pC.reduce((n,a)=>{const l=Ou(`Primitive.${a}`),i=v.forwardRef((s,u)=>{const{asChild:f,...h}=s,p=f?l:a;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),y.jsx(p,{...h,ref:u})});return i.displayName=`Primitive.${a}`,{...n,[a]:i}},{});function gC(n,a){n&&Ru.flushSync(()=>n.dispatchEvent(a))}function Vl(n){const a=v.useRef(n);return v.useEffect(()=>{a.current=n}),v.useMemo(()=>(...l)=>a.current?.(...l),[])}function vC(n,a=globalThis?.document){const l=Vl(n);v.useEffect(()=>{const i=s=>{s.key==="Escape"&&l(s)};return a.addEventListener("keydown",i,{capture:!0}),()=>a.removeEventListener("keydown",i,{capture:!0})},[l,a])}var yC="DismissableLayer",Od="dismissableLayer.update",bC="dismissableLayer.pointerDownOutside",xC="dismissableLayer.focusOutside",Fv,d0=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Fd=v.forwardRef((n,a)=>{const{disableOutsidePointerEvents:l=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:u,onInteractOutside:f,onDismiss:h,...p}=n,m=v.useContext(d0),[g,x]=v.useState(null),S=g?.ownerDocument??globalThis?.document,[,w]=v.useState({}),C=fn(a,G=>x(G)),R=Array.from(m.layers),[T]=[...m.layersWithOutsidePointerEventsDisabled].slice(-1),O=R.indexOf(T),z=g?R.indexOf(g):-1,k=m.layersWithOutsidePointerEventsDisabled.size>0,H=z>=O,P=EC(G=>{const J=G.target,re=[...m.branches].some(ie=>ie.contains(J));!H||re||(s?.(G),f?.(G),G.defaultPrevented||h?.())},S),A=RC(G=>{const J=G.target;[...m.branches].some(ie=>ie.contains(J))||(u?.(G),f?.(G),G.defaultPrevented||h?.())},S);return vC(G=>{z===m.layers.size-1&&(i?.(G),!G.defaultPrevented&&h&&(G.preventDefault(),h()))},S),v.useEffect(()=>{if(g)return l&&(m.layersWithOutsidePointerEventsDisabled.size===0&&(Fv=S.body.style.pointerEvents,S.body.style.pointerEvents="none"),m.layersWithOutsidePointerEventsDisabled.add(g)),m.layers.add(g),Xv(),()=>{l&&m.layersWithOutsidePointerEventsDisabled.size===1&&(S.body.style.pointerEvents=Fv)}},[g,S,l,m]),v.useEffect(()=>()=>{g&&(m.layers.delete(g),m.layersWithOutsidePointerEventsDisabled.delete(g),Xv())},[g,m]),v.useEffect(()=>{const G=()=>w({});return document.addEventListener(Od,G),()=>document.removeEventListener(Od,G)},[]),y.jsx(dt.div,{...p,ref:C,style:{pointerEvents:k?H?"auto":"none":void 0,...n.style},onFocusCapture:Zt(n.onFocusCapture,A.onFocusCapture),onBlurCapture:Zt(n.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Zt(n.onPointerDownCapture,P.onPointerDownCapture)})});Fd.displayName=yC;var SC="DismissableLayerBranch",wC=v.forwardRef((n,a)=>{const l=v.useContext(d0),i=v.useRef(null),s=fn(a,i);return v.useEffect(()=>{const u=i.current;if(u)return l.branches.add(u),()=>{l.branches.delete(u)}},[l.branches]),y.jsx(dt.div,{...n,ref:s})});wC.displayName=SC;function EC(n,a=globalThis?.document){const l=Vl(n),i=v.useRef(!1),s=v.useRef(()=>{});return v.useEffect(()=>{const u=h=>{if(h.target&&!i.current){let p=function(){h0(bC,l,m,{discrete:!0})};const m={originalEvent:h};h.pointerType==="touch"?(a.removeEventListener("click",s.current),s.current=p,a.addEventListener("click",s.current,{once:!0})):p()}else a.removeEventListener("click",s.current);i.current=!1},f=window.setTimeout(()=>{a.addEventListener("pointerdown",u)},0);return()=>{window.clearTimeout(f),a.removeEventListener("pointerdown",u),a.removeEventListener("click",s.current)}},[a,l]),{onPointerDownCapture:()=>i.current=!0}}function RC(n,a=globalThis?.document){const l=Vl(n),i=v.useRef(!1);return v.useEffect(()=>{const s=u=>{u.target&&!i.current&&h0(xC,l,{originalEvent:u},{discrete:!1})};return a.addEventListener("focusin",s),()=>a.removeEventListener("focusin",s)},[a,l]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}function Xv(){const n=new CustomEvent(Od);document.dispatchEvent(n)}function h0(n,a,l,{discrete:i}){const s=l.originalEvent.target,u=new CustomEvent(n,{bubbles:!1,cancelable:!0,detail:l});a&&s.addEventListener(n,a,{once:!0}),i?gC(s,u):s.dispatchEvent(u)}var Wf="focusScope.autoFocusOnMount",ed="focusScope.autoFocusOnUnmount",Qv={bubbles:!1,cancelable:!0},CC="FocusScope",Xd=v.forwardRef((n,a)=>{const{loop:l=!1,trapped:i=!1,onMountAutoFocus:s,onUnmountAutoFocus:u,...f}=n,[h,p]=v.useState(null),m=Vl(s),g=Vl(u),x=v.useRef(null),S=fn(a,R=>p(R)),w=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect(()=>{if(i){let R=function(k){if(w.paused||!h)return;const H=k.target;h.contains(H)?x.current=H:Ja(x.current,{select:!0})},T=function(k){if(w.paused||!h)return;const H=k.relatedTarget;H!==null&&(h.contains(H)||Ja(x.current,{select:!0}))},O=function(k){if(document.activeElement===document.body)for(const P of k)P.removedNodes.length>0&&Ja(h)};document.addEventListener("focusin",R),document.addEventListener("focusout",T);const z=new MutationObserver(O);return h&&z.observe(h,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",R),document.removeEventListener("focusout",T),z.disconnect()}}},[i,h,w.paused]),v.useEffect(()=>{if(h){Jv.add(w);const R=document.activeElement;if(!h.contains(R)){const O=new CustomEvent(Wf,Qv);h.addEventListener(Wf,m),h.dispatchEvent(O),O.defaultPrevented||(OC(MC(m0(h)),{select:!0}),document.activeElement===R&&Ja(h))}return()=>{h.removeEventListener(Wf,m),setTimeout(()=>{const O=new CustomEvent(ed,Qv);h.addEventListener(ed,g),h.dispatchEvent(O),O.defaultPrevented||Ja(R??document.body,{select:!0}),h.removeEventListener(ed,g),Jv.remove(w)},0)}}},[h,m,g,w]);const C=v.useCallback(R=>{if(!l&&!i||w.paused)return;const T=R.key==="Tab"&&!R.altKey&&!R.ctrlKey&&!R.metaKey,O=document.activeElement;if(T&&O){const z=R.currentTarget,[k,H]=AC(z);k&&H?!R.shiftKey&&O===H?(R.preventDefault(),l&&Ja(k,{select:!0})):R.shiftKey&&O===k&&(R.preventDefault(),l&&Ja(H,{select:!0})):O===z&&R.preventDefault()}},[l,i,w.paused]);return y.jsx(dt.div,{tabIndex:-1,...f,ref:S,onKeyDown:C})});Xd.displayName=CC;function OC(n,{select:a=!1}={}){const l=document.activeElement;for(const i of n)if(Ja(i,{select:a}),document.activeElement!==l)return}function AC(n){const a=m0(n),l=Zv(a,n),i=Zv(a.reverse(),n);return[l,i]}function m0(n){const a=[],l=document.createTreeWalker(n,NodeFilter.SHOW_ELEMENT,{acceptNode:i=>{const s=i.tagName==="INPUT"&&i.type==="hidden";return i.disabled||i.hidden||s?NodeFilter.FILTER_SKIP:i.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;l.nextNode();)a.push(l.currentNode);return a}function Zv(n,a){for(const l of n)if(!NC(l,{upTo:a}))return l}function NC(n,{upTo:a}){if(getComputedStyle(n).visibility==="hidden")return!0;for(;n;){if(a!==void 0&&n===a)return!1;if(getComputedStyle(n).display==="none")return!0;n=n.parentElement}return!1}function TC(n){return n instanceof HTMLInputElement&&"select"in n}function Ja(n,{select:a=!1}={}){if(n&&n.focus){const l=document.activeElement;n.focus({preventScroll:!0}),n!==l&&TC(n)&&a&&n.select()}}var Jv=jC();function jC(){let n=[];return{add(a){const l=n[0];a!==l&&l?.pause(),n=Iv(n,a),n.unshift(a)},remove(a){n=Iv(n,a),n[0]?.resume()}}}function Iv(n,a){const l=[...n],i=l.indexOf(a);return i!==-1&&l.splice(i,1),l}function MC(n){return n.filter(a=>a.tagName!=="A")}var _C="Portal",Qd=v.forwardRef((n,a)=>{const{container:l,...i}=n,[s,u]=v.useState(!1);nr(()=>u(!0),[]);const f=l||s&&globalThis?.document?.body;return f?eC.createPortal(y.jsx(dt.div,{...i,ref:a}),f):null});Qd.displayName=_C;function DC(n,a){return v.useReducer((l,i)=>a[l][i]??l,n)}var Ql=n=>{const{present:a,children:l}=n,i=LC(a),s=typeof l=="function"?l({present:i.isPresent}):v.Children.only(l),u=fn(i.ref,zC(s));return typeof l=="function"||i.isPresent?v.cloneElement(s,{ref:u}):null};Ql.displayName="Presence";function LC(n){const[a,l]=v.useState(),i=v.useRef(null),s=v.useRef(n),u=v.useRef("none"),f=n?"mounted":"unmounted",[h,p]=DC(f,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const m=qs(i.current);u.current=h==="mounted"?m:"none"},[h]),nr(()=>{const m=i.current,g=s.current;if(g!==n){const S=u.current,w=qs(m);n?p("MOUNT"):w==="none"||m?.display==="none"?p("UNMOUNT"):p(g&&S!==w?"ANIMATION_OUT":"UNMOUNT"),s.current=n}},[n,p]),nr(()=>{if(a){let m;const g=a.ownerDocument.defaultView??window,x=w=>{const R=qs(i.current).includes(w.animationName);if(w.target===a&&R&&(p("ANIMATION_END"),!s.current)){const T=a.style.animationFillMode;a.style.animationFillMode="forwards",m=g.setTimeout(()=>{a.style.animationFillMode==="forwards"&&(a.style.animationFillMode=T)})}},S=w=>{w.target===a&&(u.current=qs(i.current))};return a.addEventListener("animationstart",S),a.addEventListener("animationcancel",x),a.addEventListener("animationend",x),()=>{g.clearTimeout(m),a.removeEventListener("animationstart",S),a.removeEventListener("animationcancel",x),a.removeEventListener("animationend",x)}}else p("ANIMATION_END")},[a,p]),{isPresent:["mounted","unmountSuspended"].includes(h),ref:v.useCallback(m=>{i.current=m?getComputedStyle(m):null,l(m)},[])}}function qs(n){return n?.animationName||"none"}function zC(n){let a=Object.getOwnPropertyDescriptor(n.props,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning;return l?n.ref:(a=Object.getOwnPropertyDescriptor(n,"ref")?.get,l=a&&"isReactWarning"in a&&a.isReactWarning,l?n.props.ref:n.props.ref||n.ref)}var td=0;function p0(){v.useEffect(()=>{const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",n[0]??Wv()),document.body.insertAdjacentElement("beforeend",n[1]??Wv()),td++,()=>{td===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(a=>a.remove()),td--}},[])}function Wv(){const n=document.createElement("span");return n.setAttribute("data-radix-focus-guard",""),n.tabIndex=0,n.style.outline="none",n.style.opacity="0",n.style.position="fixed",n.style.pointerEvents="none",n}var Vn=function(){return Vn=Object.assign||function(a){for(var l,i=1,s=arguments.length;i<s;i++){l=arguments[i];for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(a[u]=l[u])}return a},Vn.apply(this,arguments)};function g0(n,a){var l={};for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&a.indexOf(i)<0&&(l[i]=n[i]);if(n!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(n);s<i.length;s++)a.indexOf(i[s])<0&&Object.prototype.propertyIsEnumerable.call(n,i[s])&&(l[i[s]]=n[i[s]]);return l}function kC(n,a,l){if(l||arguments.length===2)for(var i=0,s=a.length,u;i<s;i++)(u||!(i in a))&&(u||(u=Array.prototype.slice.call(a,0,i)),u[i]=a[i]);return n.concat(u||Array.prototype.slice.call(a))}var au="right-scroll-bar-position",ru="width-before-scroll-bar",UC="with-scroll-bars-hidden",PC="--removed-body-scroll-bar-size";function nd(n,a){return typeof n=="function"?n(a):n&&(n.current=a),n}function HC(n,a){var l=v.useState(function(){return{value:n,callback:a,facade:{get current(){return l.value},set current(i){var s=l.value;s!==i&&(l.value=i,l.callback(i,s))}}}})[0];return l.callback=a,l.facade}var BC=typeof window<"u"?v.useLayoutEffect:v.useEffect,ey=new WeakMap;function $C(n,a){var l=HC(null,function(i){return n.forEach(function(s){return nd(s,i)})});return BC(function(){var i=ey.get(l);if(i){var s=new Set(i),u=new Set(n),f=l.current;s.forEach(function(h){u.has(h)||nd(h,null)}),u.forEach(function(h){s.has(h)||nd(h,f)})}ey.set(l,n)},[n]),l}function VC(n){return n}function qC(n,a){a===void 0&&(a=VC);var l=[],i=!1,s={read:function(){if(i)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return l.length?l[l.length-1]:n},useMedium:function(u){var f=a(u,i);return l.push(f),function(){l=l.filter(function(h){return h!==f})}},assignSyncMedium:function(u){for(i=!0;l.length;){var f=l;l=[],f.forEach(u)}l={push:function(h){return u(h)},filter:function(){return l}}},assignMedium:function(u){i=!0;var f=[];if(l.length){var h=l;l=[],h.forEach(u),f=l}var p=function(){var g=f;f=[],g.forEach(u)},m=function(){return Promise.resolve().then(p)};m(),l={push:function(g){f.push(g),m()},filter:function(g){return f=f.filter(g),l}}}};return s}function YC(n){n===void 0&&(n={});var a=qC(null);return a.options=Vn({async:!0,ssr:!1},n),a}var v0=function(n){var a=n.sideCar,l=g0(n,["sideCar"]);if(!a)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var i=a.read();if(!i)throw new Error("Sidecar medium not found");return v.createElement(i,Vn({},l))};v0.isSideCarExport=!0;function KC(n,a){return n.useMedium(a),v0}var y0=YC(),ad=function(){},Au=v.forwardRef(function(n,a){var l=v.useRef(null),i=v.useState({onScrollCapture:ad,onWheelCapture:ad,onTouchMoveCapture:ad}),s=i[0],u=i[1],f=n.forwardProps,h=n.children,p=n.className,m=n.removeScrollBar,g=n.enabled,x=n.shards,S=n.sideCar,w=n.noRelative,C=n.noIsolation,R=n.inert,T=n.allowPinchZoom,O=n.as,z=O===void 0?"div":O,k=n.gapMode,H=g0(n,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),P=S,A=$C([l,a]),G=Vn(Vn({},H),s);return v.createElement(v.Fragment,null,g&&v.createElement(P,{sideCar:y0,removeScrollBar:m,shards:x,noRelative:w,noIsolation:C,inert:R,setCallbacks:u,allowPinchZoom:!!T,lockRef:l,gapMode:k}),f?v.cloneElement(v.Children.only(h),Vn(Vn({},G),{ref:A})):v.createElement(z,Vn({},G,{className:p,ref:A}),h))});Au.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Au.classNames={fullWidth:ru,zeroRight:au};var GC=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function FC(){if(!document)return null;var n=document.createElement("style");n.type="text/css";var a=GC();return a&&n.setAttribute("nonce",a),n}function XC(n,a){n.styleSheet?n.styleSheet.cssText=a:n.appendChild(document.createTextNode(a))}function QC(n){var a=document.head||document.getElementsByTagName("head")[0];a.appendChild(n)}var ZC=function(){var n=0,a=null;return{add:function(l){n==0&&(a=FC())&&(XC(a,l),QC(a)),n++},remove:function(){n--,!n&&a&&(a.parentNode&&a.parentNode.removeChild(a),a=null)}}},JC=function(){var n=ZC();return function(a,l){v.useEffect(function(){return n.add(a),function(){n.remove()}},[a&&l])}},b0=function(){var n=JC(),a=function(l){var i=l.styles,s=l.dynamic;return n(i,s),null};return a},IC={left:0,top:0,right:0,gap:0},rd=function(n){return parseInt(n||"",10)||0},WC=function(n){var a=window.getComputedStyle(document.body),l=a[n==="padding"?"paddingLeft":"marginLeft"],i=a[n==="padding"?"paddingTop":"marginTop"],s=a[n==="padding"?"paddingRight":"marginRight"];return[rd(l),rd(i),rd(s)]},e2=function(n){if(n===void 0&&(n="margin"),typeof window>"u")return IC;var a=WC(n),l=document.documentElement.clientWidth,i=window.innerWidth;return{left:a[0],top:a[1],right:a[2],gap:Math.max(0,i-l+a[2]-a[0])}},t2=b0(),Hl="data-scroll-locked",n2=function(n,a,l,i){var s=n.left,u=n.top,f=n.right,h=n.gap;return l===void 0&&(l="margin"),`
|
|
68
68
|
.`.concat(UC,` {
|
|
69
69
|
overflow: hidden `).concat(i,`;
|
|
70
70
|
padding-right: `).concat(h,"px ").concat(i,`;
|
|
@@ -104,7 +104,7 @@ Please change the parent <Route path="${O}"> to <Route path="${O==="/"?"*":`${O}
|
|
|
104
104
|
`)},ty=function(){var n=parseInt(document.body.getAttribute(Hl)||"0",10);return isFinite(n)?n:0},a2=function(){v.useEffect(function(){return document.body.setAttribute(Hl,(ty()+1).toString()),function(){var n=ty()-1;n<=0?document.body.removeAttribute(Hl):document.body.setAttribute(Hl,n.toString())}},[])},r2=function(n){var a=n.noRelative,l=n.noImportant,i=n.gapMode,s=i===void 0?"margin":i;a2();var u=v.useMemo(function(){return e2(s)},[s]);return v.createElement(t2,{styles:n2(u,!a,s,l?"":"!important")})},Ad=!1;if(typeof window<"u")try{var Ys=Object.defineProperty({},"passive",{get:function(){return Ad=!0,!0}});window.addEventListener("test",Ys,Ys),window.removeEventListener("test",Ys,Ys)}catch{Ad=!1}var jl=Ad?{passive:!1}:!1,l2=function(n){return n.tagName==="TEXTAREA"},x0=function(n,a){if(!(n instanceof Element))return!1;var l=window.getComputedStyle(n);return l[a]!=="hidden"&&!(l.overflowY===l.overflowX&&!l2(n)&&l[a]==="visible")},i2=function(n){return x0(n,"overflowY")},o2=function(n){return x0(n,"overflowX")},ny=function(n,a){var l=a.ownerDocument,i=a;do{typeof ShadowRoot<"u"&&i instanceof ShadowRoot&&(i=i.host);var s=S0(n,i);if(s){var u=w0(n,i),f=u[1],h=u[2];if(f>h)return!0}i=i.parentNode}while(i&&i!==l.body);return!1},s2=function(n){var a=n.scrollTop,l=n.scrollHeight,i=n.clientHeight;return[a,l,i]},u2=function(n){var a=n.scrollLeft,l=n.scrollWidth,i=n.clientWidth;return[a,l,i]},S0=function(n,a){return n==="v"?i2(a):o2(a)},w0=function(n,a){return n==="v"?s2(a):u2(a)},c2=function(n,a){return n==="h"&&a==="rtl"?-1:1},f2=function(n,a,l,i,s){var u=c2(n,window.getComputedStyle(a).direction),f=u*i,h=l.target,p=a.contains(h),m=!1,g=f>0,x=0,S=0;do{if(!h)break;var w=w0(n,h),C=w[0],R=w[1],T=w[2],O=R-T-u*C;(C||O)&&S0(n,h)&&(x+=O,S+=C);var z=h.parentNode;h=z&&z.nodeType===Node.DOCUMENT_FRAGMENT_NODE?z.host:z}while(!p&&h!==document.body||p&&(a.contains(h)||a===h));return(g&&Math.abs(x)<1||!g&&Math.abs(S)<1)&&(m=!0),m},Ks=function(n){return"changedTouches"in n?[n.changedTouches[0].clientX,n.changedTouches[0].clientY]:[0,0]},ay=function(n){return[n.deltaX,n.deltaY]},ry=function(n){return n&&"current"in n?n.current:n},d2=function(n,a){return n[0]===a[0]&&n[1]===a[1]},h2=function(n){return`
|
|
105
105
|
.block-interactivity-`.concat(n,` {pointer-events: none;}
|
|
106
106
|
.allow-interactivity-`).concat(n,` {pointer-events: all;}
|
|
107
|
-
`)},m2=0,Ml=[];function p2(n){var a=v.useRef([]),l=v.useRef([0,0]),i=v.useRef(),s=v.useState(m2++)[0],u=v.useState(b0)[0],f=v.useRef(n);v.useEffect(function(){f.current=n},[n]),v.useEffect(function(){if(n.inert){document.body.classList.add("block-interactivity-".concat(s));var R=kC([n.lockRef.current],(n.shards||[]).map(ry),!0).filter(Boolean);return R.forEach(function(T){return T.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),R.forEach(function(T){return T.classList.remove("allow-interactivity-".concat(s))})}}},[n.inert,n.lockRef.current,n.shards]);var h=v.useCallback(function(R,T){if("touches"in R&&R.touches.length===2||R.type==="wheel"&&R.ctrlKey)return!f.current.allowPinchZoom;var O=Ks(R),z=l.current,k="deltaX"in R?R.deltaX:z[0]-O[0],H="deltaY"in R?R.deltaY:z[1]-O[1],P,A=R.target,G=Math.abs(k)>Math.abs(H)?"h":"v";if("touches"in R&&G==="h"&&A.type==="range")return!1;var J=ny(G,A);if(!J)return!0;if(J?P=G:(P=G==="v"?"h":"v",J=ny(G,A)),!J)return!1;if(!i.current&&"changedTouches"in R&&(k||H)&&(i.current=P),!P)return!0;var re=i.current||P;return f2(re,T,R,re==="h"?k:H)},[]),p=v.useCallback(function(R){var T=R;if(!(!Ml.length||Ml[Ml.length-1]!==u)){var O="deltaY"in T?ay(T):Ks(T),z=a.current.filter(function(P){return P.name===T.type&&(P.target===T.target||T.target===P.shadowParent)&&d2(P.delta,O)})[0];if(z&&z.should){T.cancelable&&T.preventDefault();return}if(!z){var k=(f.current.shards||[]).map(ry).filter(Boolean).filter(function(P){return P.contains(T.target)}),H=k.length>0?h(T,k[0]):!f.current.noIsolation;H&&T.cancelable&&T.preventDefault()}}},[]),m=v.useCallback(function(R,T,O,z){var k={name:R,delta:T,target:O,should:z,shadowParent:g2(O)};a.current.push(k),setTimeout(function(){a.current=a.current.filter(function(H){return H!==k})},1)},[]),g=v.useCallback(function(R){l.current=Ks(R),i.current=void 0},[]),x=v.useCallback(function(R){m(R.type,ay(R),R.target,h(R,n.lockRef.current))},[]),S=v.useCallback(function(R){m(R.type,Ks(R),R.target,h(R,n.lockRef.current))},[]);v.useEffect(function(){return Ml.push(u),n.setCallbacks({onScrollCapture:x,onWheelCapture:x,onTouchMoveCapture:S}),document.addEventListener("wheel",p,jl),document.addEventListener("touchmove",p,jl),document.addEventListener("touchstart",g,jl),function(){Ml=Ml.filter(function(R){return R!==u}),document.removeEventListener("wheel",p,jl),document.removeEventListener("touchmove",p,jl),document.removeEventListener("touchstart",g,jl)}},[]);var w=n.removeScrollBar,C=n.inert;return v.createElement(v.Fragment,null,C?v.createElement(u,{styles:h2(s)}):null,w?v.createElement(r2,{noRelative:n.noRelative,gapMode:n.gapMode}):null)}function g2(n){for(var a=null;n!==null;)n instanceof ShadowRoot&&(a=n.host,n=n.host),n=n.parentNode;return a}const v2=KC(y0,p2);var Zd=v.forwardRef(function(n,a){return v.createElement(Au,Vn({},n,{ref:a,sideCar:v2}))});Zd.classNames=Au.classNames;var y2=function(n){if(typeof document>"u")return null;var a=Array.isArray(n)?n[0]:n;return a.ownerDocument.body},_l=new WeakMap,Gs=new WeakMap,Fs={},ld=0,E0=function(n){return n&&(n.host||E0(n.parentNode))},b2=function(n,a){return a.map(function(l){if(n.contains(l))return l;var i=E0(l);return i&&n.contains(i)?i:(console.error("aria-hidden",l,"in not contained inside",n,". Doing nothing"),null)}).filter(function(l){return!!l})},x2=function(n,a,l,i){var s=b2(a,Array.isArray(n)?n:[n]);Fs[l]||(Fs[l]=new WeakMap);var u=Fs[l],f=[],h=new Set,p=new Set(s),m=function(x){!x||h.has(x)||(h.add(x),m(x.parentNode))};s.forEach(m);var g=function(x){!x||p.has(x)||Array.prototype.forEach.call(x.children,function(S){if(h.has(S))g(S);else try{var w=S.getAttribute(i),C=w!==null&&w!=="false",R=(_l.get(S)||0)+1,T=(u.get(S)||0)+1;_l.set(S,R),u.set(S,T),f.push(S),R===1&&C&&Gs.set(S,!0),T===1&&S.setAttribute(l,"true"),C||S.setAttribute(i,"true")}catch(O){console.error("aria-hidden: cannot operate on ",S,O)}})};return g(a),h.clear(),ld++,function(){f.forEach(function(x){var S=_l.get(x)-1,w=u.get(x)-1;_l.set(x,S),u.set(x,w),S||(Gs.has(x)||x.removeAttribute(i),Gs.delete(x)),w||x.removeAttribute(l)}),ld--,ld||(_l=new WeakMap,_l=new WeakMap,Gs=new WeakMap,Fs={})}},R0=function(n,a,l){l===void 0&&(l="data-aria-hidden");var i=Array.from(Array.isArray(n)?n:[n]),s=y2(n);return s?(i.push.apply(i,Array.from(s.querySelectorAll("[aria-live], script"))),x2(i,s,l,"aria-hidden")):function(){return null}},Nu="Dialog",[C0,Aj]=Cu(Nu),[S2,Dn]=C0(Nu),O0=n=>{const{__scopeDialog:a,children:l,open:i,defaultOpen:s,onOpenChange:u,modal:f=!0}=n,h=v.useRef(null),p=v.useRef(null),[m,g]=Gd({prop:i,defaultProp:s??!1,onChange:u,caller:Nu});return y.jsx(S2,{scope:a,triggerRef:h,contentRef:p,contentId:Gn(),titleId:Gn(),descriptionId:Gn(),open:m,onOpenChange:g,onOpenToggle:v.useCallback(()=>g(x=>!x),[g]),modal:f,children:l})};O0.displayName=Nu;var A0="DialogTrigger",w2=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(A0,l),u=fn(a,s.triggerRef);return y.jsx(dt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":Wd(s.open),...i,ref:u,onClick:
|
|
107
|
+
`)},m2=0,Ml=[];function p2(n){var a=v.useRef([]),l=v.useRef([0,0]),i=v.useRef(),s=v.useState(m2++)[0],u=v.useState(b0)[0],f=v.useRef(n);v.useEffect(function(){f.current=n},[n]),v.useEffect(function(){if(n.inert){document.body.classList.add("block-interactivity-".concat(s));var R=kC([n.lockRef.current],(n.shards||[]).map(ry),!0).filter(Boolean);return R.forEach(function(T){return T.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),R.forEach(function(T){return T.classList.remove("allow-interactivity-".concat(s))})}}},[n.inert,n.lockRef.current,n.shards]);var h=v.useCallback(function(R,T){if("touches"in R&&R.touches.length===2||R.type==="wheel"&&R.ctrlKey)return!f.current.allowPinchZoom;var O=Ks(R),z=l.current,k="deltaX"in R?R.deltaX:z[0]-O[0],H="deltaY"in R?R.deltaY:z[1]-O[1],P,A=R.target,G=Math.abs(k)>Math.abs(H)?"h":"v";if("touches"in R&&G==="h"&&A.type==="range")return!1;var J=ny(G,A);if(!J)return!0;if(J?P=G:(P=G==="v"?"h":"v",J=ny(G,A)),!J)return!1;if(!i.current&&"changedTouches"in R&&(k||H)&&(i.current=P),!P)return!0;var re=i.current||P;return f2(re,T,R,re==="h"?k:H)},[]),p=v.useCallback(function(R){var T=R;if(!(!Ml.length||Ml[Ml.length-1]!==u)){var O="deltaY"in T?ay(T):Ks(T),z=a.current.filter(function(P){return P.name===T.type&&(P.target===T.target||T.target===P.shadowParent)&&d2(P.delta,O)})[0];if(z&&z.should){T.cancelable&&T.preventDefault();return}if(!z){var k=(f.current.shards||[]).map(ry).filter(Boolean).filter(function(P){return P.contains(T.target)}),H=k.length>0?h(T,k[0]):!f.current.noIsolation;H&&T.cancelable&&T.preventDefault()}}},[]),m=v.useCallback(function(R,T,O,z){var k={name:R,delta:T,target:O,should:z,shadowParent:g2(O)};a.current.push(k),setTimeout(function(){a.current=a.current.filter(function(H){return H!==k})},1)},[]),g=v.useCallback(function(R){l.current=Ks(R),i.current=void 0},[]),x=v.useCallback(function(R){m(R.type,ay(R),R.target,h(R,n.lockRef.current))},[]),S=v.useCallback(function(R){m(R.type,Ks(R),R.target,h(R,n.lockRef.current))},[]);v.useEffect(function(){return Ml.push(u),n.setCallbacks({onScrollCapture:x,onWheelCapture:x,onTouchMoveCapture:S}),document.addEventListener("wheel",p,jl),document.addEventListener("touchmove",p,jl),document.addEventListener("touchstart",g,jl),function(){Ml=Ml.filter(function(R){return R!==u}),document.removeEventListener("wheel",p,jl),document.removeEventListener("touchmove",p,jl),document.removeEventListener("touchstart",g,jl)}},[]);var w=n.removeScrollBar,C=n.inert;return v.createElement(v.Fragment,null,C?v.createElement(u,{styles:h2(s)}):null,w?v.createElement(r2,{noRelative:n.noRelative,gapMode:n.gapMode}):null)}function g2(n){for(var a=null;n!==null;)n instanceof ShadowRoot&&(a=n.host,n=n.host),n=n.parentNode;return a}const v2=KC(y0,p2);var Zd=v.forwardRef(function(n,a){return v.createElement(Au,Vn({},n,{ref:a,sideCar:v2}))});Zd.classNames=Au.classNames;var y2=function(n){if(typeof document>"u")return null;var a=Array.isArray(n)?n[0]:n;return a.ownerDocument.body},_l=new WeakMap,Gs=new WeakMap,Fs={},ld=0,E0=function(n){return n&&(n.host||E0(n.parentNode))},b2=function(n,a){return a.map(function(l){if(n.contains(l))return l;var i=E0(l);return i&&n.contains(i)?i:(console.error("aria-hidden",l,"in not contained inside",n,". Doing nothing"),null)}).filter(function(l){return!!l})},x2=function(n,a,l,i){var s=b2(a,Array.isArray(n)?n:[n]);Fs[l]||(Fs[l]=new WeakMap);var u=Fs[l],f=[],h=new Set,p=new Set(s),m=function(x){!x||h.has(x)||(h.add(x),m(x.parentNode))};s.forEach(m);var g=function(x){!x||p.has(x)||Array.prototype.forEach.call(x.children,function(S){if(h.has(S))g(S);else try{var w=S.getAttribute(i),C=w!==null&&w!=="false",R=(_l.get(S)||0)+1,T=(u.get(S)||0)+1;_l.set(S,R),u.set(S,T),f.push(S),R===1&&C&&Gs.set(S,!0),T===1&&S.setAttribute(l,"true"),C||S.setAttribute(i,"true")}catch(O){console.error("aria-hidden: cannot operate on ",S,O)}})};return g(a),h.clear(),ld++,function(){f.forEach(function(x){var S=_l.get(x)-1,w=u.get(x)-1;_l.set(x,S),u.set(x,w),S||(Gs.has(x)||x.removeAttribute(i),Gs.delete(x)),w||x.removeAttribute(l)}),ld--,ld||(_l=new WeakMap,_l=new WeakMap,Gs=new WeakMap,Fs={})}},R0=function(n,a,l){l===void 0&&(l="data-aria-hidden");var i=Array.from(Array.isArray(n)?n:[n]),s=y2(n);return s?(i.push.apply(i,Array.from(s.querySelectorAll("[aria-live], script"))),x2(i,s,l,"aria-hidden")):function(){return null}},Nu="Dialog",[C0,Aj]=Cu(Nu),[S2,Dn]=C0(Nu),O0=n=>{const{__scopeDialog:a,children:l,open:i,defaultOpen:s,onOpenChange:u,modal:f=!0}=n,h=v.useRef(null),p=v.useRef(null),[m,g]=Gd({prop:i,defaultProp:s??!1,onChange:u,caller:Nu});return y.jsx(S2,{scope:a,triggerRef:h,contentRef:p,contentId:Gn(),titleId:Gn(),descriptionId:Gn(),open:m,onOpenChange:g,onOpenToggle:v.useCallback(()=>g(x=>!x),[g]),modal:f,children:l})};O0.displayName=Nu;var A0="DialogTrigger",w2=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(A0,l),u=fn(a,s.triggerRef);return y.jsx(dt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":Wd(s.open),...i,ref:u,onClick:Zt(n.onClick,s.onOpenToggle)})});w2.displayName=A0;var Jd="DialogPortal",[E2,N0]=C0(Jd,{forceMount:void 0}),T0=n=>{const{__scopeDialog:a,forceMount:l,children:i,container:s}=n,u=Dn(Jd,a);return y.jsx(E2,{scope:a,forceMount:l,children:v.Children.map(i,f=>y.jsx(Ql,{present:l||u.open,children:y.jsx(Qd,{asChild:!0,container:s,children:f})}))})};T0.displayName=Jd;var fu="DialogOverlay",j0=v.forwardRef((n,a)=>{const l=N0(fu,n.__scopeDialog),{forceMount:i=l.forceMount,...s}=n,u=Dn(fu,n.__scopeDialog);return u.modal?y.jsx(Ql,{present:i||u.open,children:y.jsx(C2,{...s,ref:a})}):null});j0.displayName=fu;var R2=Ou("DialogOverlay.RemoveScroll"),C2=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(fu,l);return y.jsx(Zd,{as:R2,allowPinchZoom:!0,shards:[s.contentRef],children:y.jsx(dt.div,{"data-state":Wd(s.open),...i,ref:a,style:{pointerEvents:"auto",...i.style}})})}),Ur="DialogContent",M0=v.forwardRef((n,a)=>{const l=N0(Ur,n.__scopeDialog),{forceMount:i=l.forceMount,...s}=n,u=Dn(Ur,n.__scopeDialog);return y.jsx(Ql,{present:i||u.open,children:u.modal?y.jsx(O2,{...s,ref:a}):y.jsx(A2,{...s,ref:a})})});M0.displayName=Ur;var O2=v.forwardRef((n,a)=>{const l=Dn(Ur,n.__scopeDialog),i=v.useRef(null),s=fn(a,l.contentRef,i);return v.useEffect(()=>{const u=i.current;if(u)return R0(u)},[]),y.jsx(_0,{...n,ref:s,trapFocus:l.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Zt(n.onCloseAutoFocus,u=>{u.preventDefault(),l.triggerRef.current?.focus()}),onPointerDownOutside:Zt(n.onPointerDownOutside,u=>{const f=u.detail.originalEvent,h=f.button===0&&f.ctrlKey===!0;(f.button===2||h)&&u.preventDefault()}),onFocusOutside:Zt(n.onFocusOutside,u=>u.preventDefault())})}),A2=v.forwardRef((n,a)=>{const l=Dn(Ur,n.__scopeDialog),i=v.useRef(!1),s=v.useRef(!1);return y.jsx(_0,{...n,ref:a,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:u=>{n.onCloseAutoFocus?.(u),u.defaultPrevented||(i.current||l.triggerRef.current?.focus(),u.preventDefault()),i.current=!1,s.current=!1},onInteractOutside:u=>{n.onInteractOutside?.(u),u.defaultPrevented||(i.current=!0,u.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const f=u.target;l.triggerRef.current?.contains(f)&&u.preventDefault(),u.detail.originalEvent.type==="focusin"&&s.current&&u.preventDefault()}})}),_0=v.forwardRef((n,a)=>{const{__scopeDialog:l,trapFocus:i,onOpenAutoFocus:s,onCloseAutoFocus:u,...f}=n,h=Dn(Ur,l),p=v.useRef(null),m=fn(a,p);return p0(),y.jsxs(y.Fragment,{children:[y.jsx(Xd,{asChild:!0,loop:!0,trapped:i,onMountAutoFocus:s,onUnmountAutoFocus:u,children:y.jsx(Fd,{role:"dialog",id:h.contentId,"aria-describedby":h.descriptionId,"aria-labelledby":h.titleId,"data-state":Wd(h.open),...f,ref:m,onDismiss:()=>h.onOpenChange(!1)})}),y.jsxs(y.Fragment,{children:[y.jsx(N2,{titleId:h.titleId}),y.jsx(j2,{contentRef:p,descriptionId:h.descriptionId})]})]})}),Id="DialogTitle",D0=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(Id,l);return y.jsx(dt.h2,{id:s.titleId,...i,ref:a})});D0.displayName=Id;var L0="DialogDescription",z0=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(L0,l);return y.jsx(dt.p,{id:s.descriptionId,...i,ref:a})});z0.displayName=L0;var k0="DialogClose",U0=v.forwardRef((n,a)=>{const{__scopeDialog:l,...i}=n,s=Dn(k0,l);return y.jsx(dt.button,{type:"button",...i,ref:a,onClick:Zt(n.onClick,()=>s.onOpenChange(!1))})});U0.displayName=k0;function Wd(n){return n?"open":"closed"}var P0="DialogTitleWarning",[Nj,H0]=nC(P0,{contentName:Ur,titleName:Id,docsSlug:"dialog"}),N2=({titleId:n})=>{const a=H0(P0),l=`\`${a.contentName}\` requires a \`${a.titleName}\` for the component to be accessible for screen reader users.
|
|
108
108
|
|
|
109
109
|
If you want to hide the \`${a.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
110
110
|
|
|
@@ -213,7 +213,7 @@ For more information, see https://radix-ui.com/primitives/docs/components/${a.do
|
|
|
213
213
|
*
|
|
214
214
|
* This source code is licensed under the ISC license.
|
|
215
215
|
* See the LICENSE file in the root directory of this source tree.
|
|
216
|
-
*/const sO=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Bl=Pt("x",sO);function Q0(n){var a,l,i="";if(typeof n=="string"||typeof n=="number")i+=n;else if(typeof n=="object")if(Array.isArray(n)){var s=n.length;for(a=0;a<s;a++)n[a]&&(l=Q0(n[a]))&&(i&&(i+=" "),i+=l)}else for(l in n)n[l]&&(i&&(i+=" "),i+=l);return i}function Z0(){for(var n,a,l=0,i="",s=arguments.length;l<s;l++)(n=arguments[l])&&(a=Q0(n))&&(i&&(i+=" "),i+=a);return i}const nh="-",uO=n=>{const a=fO(n),{conflictingClassGroups:l,conflictingClassGroupModifiers:i}=n;return{getClassGroupId:f=>{const h=f.split(nh);return h[0]===""&&h.length!==1&&h.shift(),J0(h,a)||cO(f)},getConflictingClassGroupIds:(f,h)=>{const p=l[f]||[];return h&&i[f]?[...p,...i[f]]:p}}},J0=(n,a)=>{if(n.length===0)return a.classGroupId;const l=n[0],i=a.nextPart.get(l),s=i?J0(n.slice(1),i):void 0;if(s)return s;if(a.validators.length===0)return;const u=n.join(nh);return a.validators.find(({validator:f})=>f(u))?.classGroupId},iy=/^\[(.+)\]$/,cO=n=>{if(iy.test(n)){const a=iy.exec(n)[1],l=a?.substring(0,a.indexOf(":"));if(l)return"arbitrary.."+l}},fO=n=>{const{theme:a,classGroups:l}=n,i={nextPart:new Map,validators:[]};for(const s in l)Td(l[s],i,s,a);return i},Td=(n,a,l,i)=>{n.forEach(s=>{if(typeof s=="string"){const u=s===""?a:oy(a,s);u.classGroupId=l;return}if(typeof s=="function"){if(dO(s)){Td(s(i),a,l,i);return}a.validators.push({validator:s,classGroupId:l});return}Object.entries(s).forEach(([u,f])=>{Td(f,oy(a,u),l,i)})})},oy=(n,a)=>{let l=n;return a.split(nh).forEach(i=>{l.nextPart.has(i)||l.nextPart.set(i,{nextPart:new Map,validators:[]}),l=l.nextPart.get(i)}),l},dO=n=>n.isThemeGetter,hO=n=>{if(n<1)return{get:()=>{},set:()=>{}};let a=0,l=new Map,i=new Map;const s=(u,f)=>{l.set(u,f),a++,a>n&&(a=0,i=l,l=new Map)};return{get(u){let f=l.get(u);if(f!==void 0)return f;if((f=i.get(u))!==void 0)return s(u,f),f},set(u,f){l.has(u)?l.set(u,f):s(u,f)}}},jd="!",Md=":",mO=Md.length,pO=n=>{const{prefix:a,experimentalParseClassName:l}=n;let i=s=>{const u=[];let f=0,h=0,p=0,m;for(let C=0;C<s.length;C++){let R=s[C];if(f===0&&h===0){if(R===Md){u.push(s.slice(p,C)),p=C+mO;continue}if(R==="/"){m=C;continue}}R==="["?f++:R==="]"?f--:R==="("?h++:R===")"&&h--}const g=u.length===0?s:s.substring(p),x=gO(g),S=x!==g,w=m&&m>p?m-p:void 0;return{modifiers:u,hasImportantModifier:S,baseClassName:x,maybePostfixModifierPosition:w}};if(a){const s=a+Md,u=i;i=f=>f.startsWith(s)?u(f.substring(s.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:f,maybePostfixModifierPosition:void 0}}if(l){const s=i;i=u=>l({className:u,parseClassName:s})}return i},gO=n=>n.endsWith(jd)?n.substring(0,n.length-1):n.startsWith(jd)?n.substring(1):n,vO=n=>{const a=Object.fromEntries(n.orderSensitiveModifiers.map(i=>[i,!0]));return i=>{if(i.length<=1)return i;const s=[];let u=[];return i.forEach(f=>{f[0]==="["||a[f]?(s.push(...u.sort(),f),u=[]):u.push(f)}),s.push(...u.sort()),s}},yO=n=>({cache:hO(n.cacheSize),parseClassName:pO(n),sortModifiers:vO(n),...uO(n)}),bO=/\s+/,xO=(n,a)=>{const{parseClassName:l,getClassGroupId:i,getConflictingClassGroupIds:s,sortModifiers:u}=a,f=[],h=n.trim().split(bO);let p="";for(let m=h.length-1;m>=0;m-=1){const g=h[m],{isExternal:x,modifiers:S,hasImportantModifier:w,baseClassName:C,maybePostfixModifierPosition:R}=l(g);if(x){p=g+(p.length>0?" "+p:p);continue}let T=!!R,O=i(T?C.substring(0,R):C);if(!O){if(!T){p=g+(p.length>0?" "+p:p);continue}if(O=i(C),!O){p=g+(p.length>0?" "+p:p);continue}T=!1}const z=u(S).join(":"),k=w?z+jd:z,H=k+O;if(f.includes(H))continue;f.push(H);const P=s(O,T);for(let A=0;A<P.length;++A){const G=P[A];f.push(k+G)}p=g+(p.length>0?" "+p:p)}return p};function SO(){let n=0,a,l,i="";for(;n<arguments.length;)(a=arguments[n++])&&(l=I0(a))&&(i&&(i+=" "),i+=l);return i}const I0=n=>{if(typeof n=="string")return n;let a,l="";for(let i=0;i<n.length;i++)n[i]&&(a=I0(n[i]))&&(l&&(l+=" "),l+=a);return l};function wO(n,...a){let l,i,s,u=f;function f(p){const m=a.reduce((g,x)=>x(g),n());return l=yO(m),i=l.cache.get,s=l.cache.set,u=h,h(p)}function h(p){const m=i(p);if(m)return m;const g=xO(p,l);return s(p,g),g}return function(){return u(SO.apply(null,arguments))}}const jt=n=>{const a=l=>l[n]||[];return a.isThemeGetter=!0,a},W0=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,eb=/^\((?:(\w[\w-]*):)?(.+)\)$/i,EO=/^\d+\/\d+$/,RO=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,CO=/\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$/,OO=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,AO=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,NO=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Dl=n=>EO.test(n),Ye=n=>!!n&&!Number.isNaN(Number(n)),Qa=n=>!!n&&Number.isInteger(Number(n)),id=n=>n.endsWith("%")&&Ye(n.slice(0,-1)),ga=n=>RO.test(n),TO=()=>!0,jO=n=>CO.test(n)&&!OO.test(n),tb=()=>!1,MO=n=>AO.test(n),_O=n=>NO.test(n),DO=n=>!ye(n)&&!be(n),LO=n=>Zl(n,rb,tb),ye=n=>W0.test(n),Mr=n=>Zl(n,lb,jO),od=n=>Zl(n,HO,Ye),sy=n=>Zl(n,nb,tb),zO=n=>Zl(n,ab,_O),Xs=n=>Zl(n,ib,MO),be=n=>eb.test(n),ao=n=>Jl(n,lb),kO=n=>Jl(n,BO),uy=n=>Jl(n,nb),UO=n=>Jl(n,rb),PO=n=>Jl(n,ab),Qs=n=>Jl(n,ib,!0),Zl=(n,a,l)=>{const i=W0.exec(n);return i?i[1]?a(i[1]):l(i[2]):!1},Jl=(n,a,l=!1)=>{const i=eb.exec(n);return i?i[1]?a(i[1]):l:!1},nb=n=>n==="position"||n==="percentage",ab=n=>n==="image"||n==="url",rb=n=>n==="length"||n==="size"||n==="bg-size",lb=n=>n==="length",HO=n=>n==="number",BO=n=>n==="family-name",ib=n=>n==="shadow",$O=()=>{const n=jt("color"),a=jt("font"),l=jt("text"),i=jt("font-weight"),s=jt("tracking"),u=jt("leading"),f=jt("breakpoint"),h=jt("container"),p=jt("spacing"),m=jt("radius"),g=jt("shadow"),x=jt("inset-shadow"),S=jt("text-shadow"),w=jt("drop-shadow"),C=jt("blur"),R=jt("perspective"),T=jt("aspect"),O=jt("ease"),z=jt("animate"),k=()=>["auto","avoid","all","avoid-page","page","left","right","column"],H=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],P=()=>[...H(),be,ye],A=()=>["auto","hidden","clip","visible","scroll"],G=()=>["auto","contain","none"],J=()=>[be,ye,p],re=()=>[Dl,"full","auto",...J()],ie=()=>[Qa,"none","subgrid",be,ye],Oe=()=>["auto",{span:["full",Qa,be,ye]},Qa,be,ye],Ee=()=>[Qa,"auto",be,ye],me=()=>["auto","min","max","fr",be,ye],he=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],fe=()=>["start","end","center","stretch","center-safe","end-safe"],_=()=>["auto",...J()],Z=()=>[Dl,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...J()],$=()=>[n,be,ye],pe=()=>[...H(),uy,sy,{position:[be,ye]}],N=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Y=()=>["auto","cover","contain",UO,LO,{size:[be,ye]}],L=()=>[id,ao,Mr],K=()=>["","none","full",m,be,ye],W=()=>["",Ye,ao,Mr],oe=()=>["solid","dashed","dotted","double"],de=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],ge=()=>[Ye,id,uy,sy],ze=()=>["","none",C,be,ye],Ze=()=>["none",Ye,be,ye],je=()=>["none",Ye,be,ye],ae=()=>[Ye,be,ye],te=()=>[Dl,"full",...J()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ga],breakpoint:[ga],color:[TO],container:[ga],"drop-shadow":[ga],ease:["in","out","in-out"],font:[DO],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ga],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ga],shadow:[ga],spacing:["px",Ye],text:[ga],"text-shadow":[ga],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Dl,ye,be,T]}],container:["container"],columns:[{columns:[Ye,ye,be,h]}],"break-after":[{"break-after":k()}],"break-before":[{"break-before":k()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:P()}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:G()}],"overscroll-x":[{"overscroll-x":G()}],"overscroll-y":[{"overscroll-y":G()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:re()}],"inset-x":[{"inset-x":re()}],"inset-y":[{"inset-y":re()}],start:[{start:re()}],end:[{end:re()}],top:[{top:re()}],right:[{right:re()}],bottom:[{bottom:re()}],left:[{left:re()}],visibility:["visible","invisible","collapse"],z:[{z:[Qa,"auto",be,ye]}],basis:[{basis:[Dl,"full","auto",h,...J()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Ye,Dl,"auto","initial","none",ye]}],grow:[{grow:["",Ye,be,ye]}],shrink:[{shrink:["",Ye,be,ye]}],order:[{order:[Qa,"first","last","none",be,ye]}],"grid-cols":[{"grid-cols":ie()}],"col-start-end":[{col:Oe()}],"col-start":[{"col-start":Ee()}],"col-end":[{"col-end":Ee()}],"grid-rows":[{"grid-rows":ie()}],"row-start-end":[{row:Oe()}],"row-start":[{"row-start":Ee()}],"row-end":[{"row-end":Ee()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":me()}],"auto-rows":[{"auto-rows":me()}],gap:[{gap:J()}],"gap-x":[{"gap-x":J()}],"gap-y":[{"gap-y":J()}],"justify-content":[{justify:[...he(),"normal"]}],"justify-items":[{"justify-items":[...fe(),"normal"]}],"justify-self":[{"justify-self":["auto",...fe()]}],"align-content":[{content:["normal",...he()]}],"align-items":[{items:[...fe(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...fe(),{baseline:["","last"]}]}],"place-content":[{"place-content":he()}],"place-items":[{"place-items":[...fe(),"baseline"]}],"place-self":[{"place-self":["auto",...fe()]}],p:[{p:J()}],px:[{px:J()}],py:[{py:J()}],ps:[{ps:J()}],pe:[{pe:J()}],pt:[{pt:J()}],pr:[{pr:J()}],pb:[{pb:J()}],pl:[{pl:J()}],m:[{m:_()}],mx:[{mx:_()}],my:[{my:_()}],ms:[{ms:_()}],me:[{me:_()}],mt:[{mt:_()}],mr:[{mr:_()}],mb:[{mb:_()}],ml:[{ml:_()}],"space-x":[{"space-x":J()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":J()}],"space-y-reverse":["space-y-reverse"],size:[{size:Z()}],w:[{w:[h,"screen",...Z()]}],"min-w":[{"min-w":[h,"screen","none",...Z()]}],"max-w":[{"max-w":[h,"screen","none","prose",{screen:[f]},...Z()]}],h:[{h:["screen","lh",...Z()]}],"min-h":[{"min-h":["screen","lh","none",...Z()]}],"max-h":[{"max-h":["screen","lh",...Z()]}],"font-size":[{text:["base",l,ao,Mr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[i,be,od]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",id,ye]}],"font-family":[{font:[kO,ye,a]}],"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:[s,be,ye]}],"line-clamp":[{"line-clamp":[Ye,"none",be,od]}],leading:[{leading:[u,...J()]}],"list-image":[{"list-image":["none",be,ye]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",be,ye]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:$()}],"text-color":[{text:$()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...oe(),"wavy"]}],"text-decoration-thickness":[{decoration:[Ye,"from-font","auto",be,Mr]}],"text-decoration-color":[{decoration:$()}],"underline-offset":[{"underline-offset":[Ye,"auto",be,ye]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:J()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",be,ye]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",be,ye]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:pe()}],"bg-repeat":[{bg:N()}],"bg-size":[{bg:Y()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Qa,be,ye],radial:["",be,ye],conic:[Qa,be,ye]},PO,zO]}],"bg-color":[{bg:$()}],"gradient-from-pos":[{from:L()}],"gradient-via-pos":[{via:L()}],"gradient-to-pos":[{to:L()}],"gradient-from":[{from:$()}],"gradient-via":[{via:$()}],"gradient-to":[{to:$()}],rounded:[{rounded:K()}],"rounded-s":[{"rounded-s":K()}],"rounded-e":[{"rounded-e":K()}],"rounded-t":[{"rounded-t":K()}],"rounded-r":[{"rounded-r":K()}],"rounded-b":[{"rounded-b":K()}],"rounded-l":[{"rounded-l":K()}],"rounded-ss":[{"rounded-ss":K()}],"rounded-se":[{"rounded-se":K()}],"rounded-ee":[{"rounded-ee":K()}],"rounded-es":[{"rounded-es":K()}],"rounded-tl":[{"rounded-tl":K()}],"rounded-tr":[{"rounded-tr":K()}],"rounded-br":[{"rounded-br":K()}],"rounded-bl":[{"rounded-bl":K()}],"border-w":[{border:W()}],"border-w-x":[{"border-x":W()}],"border-w-y":[{"border-y":W()}],"border-w-s":[{"border-s":W()}],"border-w-e":[{"border-e":W()}],"border-w-t":[{"border-t":W()}],"border-w-r":[{"border-r":W()}],"border-w-b":[{"border-b":W()}],"border-w-l":[{"border-l":W()}],"divide-x":[{"divide-x":W()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":W()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...oe(),"hidden","none"]}],"divide-style":[{divide:[...oe(),"hidden","none"]}],"border-color":[{border:$()}],"border-color-x":[{"border-x":$()}],"border-color-y":[{"border-y":$()}],"border-color-s":[{"border-s":$()}],"border-color-e":[{"border-e":$()}],"border-color-t":[{"border-t":$()}],"border-color-r":[{"border-r":$()}],"border-color-b":[{"border-b":$()}],"border-color-l":[{"border-l":$()}],"divide-color":[{divide:$()}],"outline-style":[{outline:[...oe(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Ye,be,ye]}],"outline-w":[{outline:["",Ye,ao,Mr]}],"outline-color":[{outline:$()}],shadow:[{shadow:["","none",g,Qs,Xs]}],"shadow-color":[{shadow:$()}],"inset-shadow":[{"inset-shadow":["none",x,Qs,Xs]}],"inset-shadow-color":[{"inset-shadow":$()}],"ring-w":[{ring:W()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:$()}],"ring-offset-w":[{"ring-offset":[Ye,Mr]}],"ring-offset-color":[{"ring-offset":$()}],"inset-ring-w":[{"inset-ring":W()}],"inset-ring-color":[{"inset-ring":$()}],"text-shadow":[{"text-shadow":["none",S,Qs,Xs]}],"text-shadow-color":[{"text-shadow":$()}],opacity:[{opacity:[Ye,be,ye]}],"mix-blend":[{"mix-blend":[...de(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":de()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Ye]}],"mask-image-linear-from-pos":[{"mask-linear-from":ge()}],"mask-image-linear-to-pos":[{"mask-linear-to":ge()}],"mask-image-linear-from-color":[{"mask-linear-from":$()}],"mask-image-linear-to-color":[{"mask-linear-to":$()}],"mask-image-t-from-pos":[{"mask-t-from":ge()}],"mask-image-t-to-pos":[{"mask-t-to":ge()}],"mask-image-t-from-color":[{"mask-t-from":$()}],"mask-image-t-to-color":[{"mask-t-to":$()}],"mask-image-r-from-pos":[{"mask-r-from":ge()}],"mask-image-r-to-pos":[{"mask-r-to":ge()}],"mask-image-r-from-color":[{"mask-r-from":$()}],"mask-image-r-to-color":[{"mask-r-to":$()}],"mask-image-b-from-pos":[{"mask-b-from":ge()}],"mask-image-b-to-pos":[{"mask-b-to":ge()}],"mask-image-b-from-color":[{"mask-b-from":$()}],"mask-image-b-to-color":[{"mask-b-to":$()}],"mask-image-l-from-pos":[{"mask-l-from":ge()}],"mask-image-l-to-pos":[{"mask-l-to":ge()}],"mask-image-l-from-color":[{"mask-l-from":$()}],"mask-image-l-to-color":[{"mask-l-to":$()}],"mask-image-x-from-pos":[{"mask-x-from":ge()}],"mask-image-x-to-pos":[{"mask-x-to":ge()}],"mask-image-x-from-color":[{"mask-x-from":$()}],"mask-image-x-to-color":[{"mask-x-to":$()}],"mask-image-y-from-pos":[{"mask-y-from":ge()}],"mask-image-y-to-pos":[{"mask-y-to":ge()}],"mask-image-y-from-color":[{"mask-y-from":$()}],"mask-image-y-to-color":[{"mask-y-to":$()}],"mask-image-radial":[{"mask-radial":[be,ye]}],"mask-image-radial-from-pos":[{"mask-radial-from":ge()}],"mask-image-radial-to-pos":[{"mask-radial-to":ge()}],"mask-image-radial-from-color":[{"mask-radial-from":$()}],"mask-image-radial-to-color":[{"mask-radial-to":$()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":H()}],"mask-image-conic-pos":[{"mask-conic":[Ye]}],"mask-image-conic-from-pos":[{"mask-conic-from":ge()}],"mask-image-conic-to-pos":[{"mask-conic-to":ge()}],"mask-image-conic-from-color":[{"mask-conic-from":$()}],"mask-image-conic-to-color":[{"mask-conic-to":$()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:pe()}],"mask-repeat":[{mask:N()}],"mask-size":[{mask:Y()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",be,ye]}],filter:[{filter:["","none",be,ye]}],blur:[{blur:ze()}],brightness:[{brightness:[Ye,be,ye]}],contrast:[{contrast:[Ye,be,ye]}],"drop-shadow":[{"drop-shadow":["","none",w,Qs,Xs]}],"drop-shadow-color":[{"drop-shadow":$()}],grayscale:[{grayscale:["",Ye,be,ye]}],"hue-rotate":[{"hue-rotate":[Ye,be,ye]}],invert:[{invert:["",Ye,be,ye]}],saturate:[{saturate:[Ye,be,ye]}],sepia:[{sepia:["",Ye,be,ye]}],"backdrop-filter":[{"backdrop-filter":["","none",be,ye]}],"backdrop-blur":[{"backdrop-blur":ze()}],"backdrop-brightness":[{"backdrop-brightness":[Ye,be,ye]}],"backdrop-contrast":[{"backdrop-contrast":[Ye,be,ye]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Ye,be,ye]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Ye,be,ye]}],"backdrop-invert":[{"backdrop-invert":["",Ye,be,ye]}],"backdrop-opacity":[{"backdrop-opacity":[Ye,be,ye]}],"backdrop-saturate":[{"backdrop-saturate":[Ye,be,ye]}],"backdrop-sepia":[{"backdrop-sepia":["",Ye,be,ye]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":J()}],"border-spacing-x":[{"border-spacing-x":J()}],"border-spacing-y":[{"border-spacing-y":J()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",be,ye]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Ye,"initial",be,ye]}],ease:[{ease:["linear","initial",O,be,ye]}],delay:[{delay:[Ye,be,ye]}],animate:[{animate:["none",z,be,ye]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[R,be,ye]}],"perspective-origin":[{"perspective-origin":P()}],rotate:[{rotate:Ze()}],"rotate-x":[{"rotate-x":Ze()}],"rotate-y":[{"rotate-y":Ze()}],"rotate-z":[{"rotate-z":Ze()}],scale:[{scale:je()}],"scale-x":[{"scale-x":je()}],"scale-y":[{"scale-y":je()}],"scale-z":[{"scale-z":je()}],"scale-3d":["scale-3d"],skew:[{skew:ae()}],"skew-x":[{"skew-x":ae()}],"skew-y":[{"skew-y":ae()}],transform:[{transform:[be,ye,"","none","gpu","cpu"]}],"transform-origin":[{origin:P()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:te()}],"translate-x":[{"translate-x":te()}],"translate-y":[{"translate-y":te()}],"translate-z":[{"translate-z":te()}],"translate-none":["translate-none"],accent:[{accent:$()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:$()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",be,ye]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":J()}],"scroll-mx":[{"scroll-mx":J()}],"scroll-my":[{"scroll-my":J()}],"scroll-ms":[{"scroll-ms":J()}],"scroll-me":[{"scroll-me":J()}],"scroll-mt":[{"scroll-mt":J()}],"scroll-mr":[{"scroll-mr":J()}],"scroll-mb":[{"scroll-mb":J()}],"scroll-ml":[{"scroll-ml":J()}],"scroll-p":[{"scroll-p":J()}],"scroll-px":[{"scroll-px":J()}],"scroll-py":[{"scroll-py":J()}],"scroll-ps":[{"scroll-ps":J()}],"scroll-pe":[{"scroll-pe":J()}],"scroll-pt":[{"scroll-pt":J()}],"scroll-pr":[{"scroll-pr":J()}],"scroll-pb":[{"scroll-pb":J()}],"scroll-pl":[{"scroll-pl":J()}],"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",be,ye]}],fill:[{fill:["none",...$()]}],"stroke-w":[{stroke:[Ye,ao,Mr,od]}],stroke:[{stroke:["none",...$()]}],"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-x","border-w-y","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-x","border-color-y","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"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-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"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},VO=wO($O);function ft(...n){return VO(Z0(n))}const mo=B0,qO=$0,ob=v.forwardRef(({className:n,...a},l)=>y.jsx(eh,{ref:l,className:ft("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",n),...a}));ob.displayName=eh.displayName;const ql=v.forwardRef(({className:n,children:a,...l},i)=>y.jsxs(qO,{children:[y.jsx(ob,{}),y.jsxs(th,{ref:i,className:ft("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-300 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 animate-scale-in",n),...l,children:[a,y.jsxs(M2,{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 transition-all-ease hover:scale-110",children:[y.jsx(Bl,{className:"h-4 w-4"}),y.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ql.displayName=th.displayName;const Yl=({className:n,...a})=>y.jsx("div",{className:ft("flex flex-col space-y-1.5 text-center sm:text-left",n),...a});Yl.displayName="DialogHeader";const po=({className:n,...a})=>y.jsx("div",{className:ft("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",n),...a});po.displayName="DialogFooter";const Kl=v.forwardRef(({className:n,...a},l)=>y.jsx(V0,{ref:l,className:ft("text-lg font-semibold leading-none tracking-tight",n),...a}));Kl.displayName=V0.displayName;const ah=v.forwardRef(({className:n,...a},l)=>y.jsx(q0,{ref:l,className:ft("text-sm text-muted-foreground",n),...a}));ah.displayName=q0.displayName;const cy=n=>typeof n=="boolean"?`${n}`:n===0?"0":n,fy=Z0,rh=(n,a)=>l=>{var i;if(a?.variants==null)return fy(n,l?.class,l?.className);const{variants:s,defaultVariants:u}=a,f=Object.keys(s).map(m=>{const g=l?.[m],x=u?.[m];if(g===null)return null;const S=cy(g)||cy(x);return s[m][S]}),h=l&&Object.entries(l).reduce((m,g)=>{let[x,S]=g;return S===void 0||(m[x]=S),m},{}),p=a==null||(i=a.compoundVariants)===null||i===void 0?void 0:i.reduce((m,g)=>{let{class:x,className:S,...w}=g;return Object.entries(w).every(C=>{let[R,T]=C;return Array.isArray(T)?T.includes({...u,...h}[R]):{...u,...h}[R]===T})?[...m,x,S]:m},[]);return fy(n,f,p,l?.class,l?.className)},YO=rh("inline-flex items-center justify-center gap-2 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 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"border border-destructive/50 text-destructive hover:bg-destructive hover:text-destructive-foreground",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"}}),He=v.forwardRef(({className:n,variant:a,size:l,asChild:i=!1,...s},u)=>{const f=i?uC:"button";return y.jsx(f,{className:ft(YO({variant:a,size:l,className:n})),ref:u,...s})});He.displayName="Button";const Rt=v.forwardRef(({className:n,type:a,...l},i)=>y.jsx("input",{type:a,className:ft("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground 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 md:text-sm",n),ref:i,...l}));Rt.displayName="Input";var KO="Label",sb=v.forwardRef((n,a)=>y.jsx(dt.label,{...n,ref:a,onMouseDown:l=>{l.target.closest("button, input, select, textarea")||(n.onMouseDown?.(l),!l.defaultPrevented&&l.detail>1&&l.preventDefault())}}));sb.displayName=KO;var ub=sb;const GO=rh("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),ct=v.forwardRef(({className:n,...a},l)=>y.jsx(ub,{ref:l,className:ft(GO(),n),...a}));ct.displayName=ub.displayName;function FO(n){const a=v.useRef({value:n,previous:n});return v.useMemo(()=>(a.current.value!==n&&(a.current.previous=a.current.value,a.current.value=n),a.current.previous),[n])}function cb(n){const[a,l]=v.useState(void 0);return nr(()=>{if(n){l({width:n.offsetWidth,height:n.offsetHeight});const i=new ResizeObserver(s=>{if(!Array.isArray(s)||!s.length)return;const u=s[0];let f,h;if("borderBoxSize"in u){const p=u.borderBoxSize,m=Array.isArray(p)?p[0]:p;f=m.inlineSize,h=m.blockSize}else f=n.offsetWidth,h=n.offsetHeight;l({width:f,height:h})});return i.observe(n,{box:"border-box"}),()=>i.unobserve(n)}else l(void 0)},[n]),a}var Tu="Switch",[XO,Tj]=Cu(Tu),[QO,ZO]=XO(Tu),fb=v.forwardRef((n,a)=>{const{__scopeSwitch:l,name:i,checked:s,defaultChecked:u,required:f,disabled:h,value:p="on",onCheckedChange:m,form:g,...x}=n,[S,w]=v.useState(null),C=fn(a,k=>w(k)),R=v.useRef(!1),T=S?g||!!S.closest("form"):!0,[O,z]=Gd({prop:s,defaultProp:u??!1,onChange:m,caller:Tu});return y.jsxs(QO,{scope:l,checked:O,disabled:h,children:[y.jsx(dt.button,{type:"button",role:"switch","aria-checked":O,"aria-required":f,"data-state":pb(O),"data-disabled":h?"":void 0,disabled:h,value:p,...x,ref:C,onClick:Jt(n.onClick,k=>{z(H=>!H),T&&(R.current=k.isPropagationStopped(),R.current||k.stopPropagation())})}),T&&y.jsx(mb,{control:S,bubbles:!R.current,name:i,value:p,checked:O,required:f,disabled:h,form:g,style:{transform:"translateX(-100%)"}})]})});fb.displayName=Tu;var db="SwitchThumb",hb=v.forwardRef((n,a)=>{const{__scopeSwitch:l,...i}=n,s=ZO(db,l);return y.jsx(dt.span,{"data-state":pb(s.checked),"data-disabled":s.disabled?"":void 0,...i,ref:a})});hb.displayName=db;var JO="SwitchBubbleInput",mb=v.forwardRef(({__scopeSwitch:n,control:a,checked:l,bubbles:i=!0,...s},u)=>{const f=v.useRef(null),h=fn(f,u),p=FO(l),m=cb(a);return v.useEffect(()=>{const g=f.current;if(!g)return;const x=window.HTMLInputElement.prototype,w=Object.getOwnPropertyDescriptor(x,"checked").set;if(p!==l&&w){const C=new Event("click",{bubbles:i});w.call(g,l),g.dispatchEvent(C)}},[p,l,i]),y.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:l,...s,tabIndex:-1,ref:h,style:{...s.style,...m,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});mb.displayName=JO;function pb(n){return n?"checked":"unchecked"}var gb=fb,IO=hb;const vb=v.forwardRef(({className:n,...a},l)=>y.jsx(gb,{className:ft("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-all-ease focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",n),...a,ref:l,children:y.jsx(IO,{className:ft("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0 transition-all-ease")})}));vb.displayName=gb.displayName;class WO{baseUrl;apiKey;tempApiKey;constructor(a="/api",l=""){this.baseUrl=a,this.apiKey=l||localStorage.getItem("apiKey")||"",this.tempApiKey=new URLSearchParams(window.location.search).get("tempApiKey")}setBaseUrl(a){this.baseUrl=a}setApiKey(a){this.apiKey=a,a?localStorage.setItem("apiKey",a):localStorage.removeItem("apiKey")}setTempApiKey(a){this.tempApiKey=a}createHeaders(a="application/json"){const l={Accept:"application/json"};return this.tempApiKey?l["X-Temp-API-Key"]=this.tempApiKey:this.apiKey&&(l["X-API-Key"]=this.apiKey),a&&(l["Content-Type"]=a),l}async apiFetch(a,l={}){const i=`${this.baseUrl}${a}`,s={...l,headers:{...this.createHeaders(),...l.headers}};try{const u=await fetch(i,s);if(u.status===401)return localStorage.removeItem("apiKey"),window.dispatchEvent(new CustomEvent("unauthorized")),new Promise(()=>{});if(!u.ok)throw new Error(`API request failed: ${u.status} ${u.statusText}`);if(u.status===204)return{};const f=await u.text();return f?JSON.parse(f):{}}catch(u){throw console.error("API request error:",u),u}}async get(a){return this.apiFetch(a,{method:"GET"})}async post(a,l){return this.apiFetch(a,{method:"POST",body:JSON.stringify(l)})}async put(a,l){return this.apiFetch(a,{method:"PUT",body:JSON.stringify(l)})}async delete(a){return this.apiFetch(a,{method:"DELETE"})}async getConfig(){return this.get("/config")}async updateConfig(a){return this.post("/config",a)}async checkFullAccess(){try{return await this.post("/config/test",{test:!0}),!0}catch(a){return!(a.message&&a.message.includes("403"))}}async getProviders(){return this.get("/api/providers")}async addProvider(a){return this.post("/api/providers",a)}async updateProvider(a,l){return this.post(`/api/providers/${a}`,l)}async deleteProvider(a){return this.delete(`/api/providers/${a}`)}async getTransformers(){return this.get("/api/transformers")}async addTransformer(a){return this.post("/api/transformers",a)}async updateTransformer(a,l){return this.post(`/api/transformers/${a}`,l)}async deleteTransformer(a){return this.delete(`/api/transformers/${a}`)}async getConfigNew(){return this.get("/config")}async saveConfig(a){return this.post("/config",a)}async restartService(){return this.post("/restart",{})}}const Zt=new WO,yb=v.createContext(void 0);function Il(){const n=v.useContext(yb);if(n===void 0)throw new Error("useConfig must be used within a ConfigProvider");return n}function eA({children:n}){const[a,l]=v.useState(null),[i,s]=v.useState(null),[u,f]=v.useState(!1),[h,p]=v.useState(localStorage.getItem("apiKey"));return v.useEffect(()=>{const m=()=>{p(localStorage.getItem("apiKey"))};return window.addEventListener("storage",m),()=>{window.removeEventListener("storage",m)}},[]),v.useEffect(()=>{(async()=>{f(!1),l(null),s(null)})()},[h]),v.useEffect(()=>{(async()=>{if(!u){f(!0);try{const g=await Zt.getConfig(),x={LOG:typeof g.LOG=="boolean"?g.LOG:!1,CLAUDE_PATH:typeof g.CLAUDE_PATH=="string"?g.CLAUDE_PATH:"",HOST:typeof g.HOST=="string"?g.HOST:"127.0.0.1",PORT:typeof g.PORT=="number"?g.PORT:3456,APIKEY:typeof g.APIKEY=="string"?g.APIKEY:"",API_TIMEOUT_MS:typeof g.API_TIMEOUT_MS=="string"?g.API_TIMEOUT_MS:"600000",PROXY_URL:typeof g.PROXY_URL=="string"?g.PROXY_URL:"",transformers:Array.isArray(g.transformers)?g.transformers:[],Providers:Array.isArray(g.Providers)?g.Providers:[],Router:g.Router&&typeof g.Router=="object"?{default:typeof g.Router.default=="string"?g.Router.default:"",background:typeof g.Router.background=="string"?g.Router.background:"",think:typeof g.Router.think=="string"?g.Router.think:"",longContext:typeof g.Router.longContext=="string"?g.Router.longContext:"",longContextThreshold:typeof g.Router.longContextThreshold=="number"?g.Router.longContextThreshold:6e4,webSearch:typeof g.Router.webSearch=="string"?g.Router.webSearch:""}:{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""}};l(x)}catch(g){console.error("Failed to fetch config:",g),g.message!=="Unauthorized"&&(l({LOG:!1,CLAUDE_PATH:"",HOST:"127.0.0.1",PORT:3456,APIKEY:"",API_TIMEOUT_MS:"600000",PROXY_URL:"",transformers:[],Providers:[],Router:{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""}}),s(g))}}})()},[u,h]),v.useEffect(()=>{(async()=>{if(a){const g=await Zt.checkFullAccess();console.log("User has full access:",g)}})()},[a]),y.jsx(yb.Provider,{value:{config:a,setConfig:l,error:i},children:n})}function tA({isOpen:n,onOpenChange:a}){const{t:l}=$r(),{config:i,setConfig:s}=Il();if(!i)return null;const u=h=>{s({...i,LOG:h})},f=h=>{s({...i,CLAUDE_PATH:h.target.value})};return y.jsx(mo,{open:n,onOpenChange:a,children:y.jsxs(ql,{children:[y.jsx(Yl,{children:y.jsx(Kl,{children:l("toplevel.title")})}),y.jsxs("div",{className:"space-y-4 py-4",children:[y.jsxs("div",{className:"flex items-center space-x-2",children:[y.jsx(vb,{id:"log",checked:i.LOG,onCheckedChange:u}),y.jsx(ct,{htmlFor:"log",className:"transition-all-ease hover:scale-[1.02] cursor-pointer",children:l("toplevel.log")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"claude-path",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.claude_path")}),y.jsx(Rt,{id:"claude-path",value:i.CLAUDE_PATH,onChange:f,className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"host",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.host")}),y.jsx(Rt,{id:"host",value:i.HOST,onChange:h=>s({...i,HOST:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"port",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.port")}),y.jsx(Rt,{id:"port",type:"number",value:i.PORT,onChange:h=>s({...i,PORT:parseInt(h.target.value,10)}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"timeout",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.timeout")}),y.jsx(Rt,{id:"timeout",value:i.API_TIMEOUT_MS,onChange:h=>s({...i,API_TIMEOUT_MS:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"proxy-url",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.proxy_url")}),y.jsx(Rt,{id:"proxy-url",value:i.PROXY_URL,onChange:h=>s({...i,PROXY_URL:h.target.value}),placeholder:"http://127.0.0.1:7890",className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"apikey",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.apikey")}),y.jsx(Rt,{id:"apikey",type:"password",value:i.APIKEY,onChange:h=>s({...i,APIKEY:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]})]}),y.jsx(po,{children:y.jsx(He,{onClick:()=>a(!1),className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:l("app.save")})})]})})}const va=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("rounded-lg border bg-card text-card-foreground shadow-sm",n),...a}));va.displayName="Card";const ya=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("flex flex-col space-y-1.5 p-6",n),...a}));ya.displayName="CardHeader";const ba=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("text-2xl font-semibold leading-none tracking-tight",n),...a}));ba.displayName="CardTitle";const bb=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("text-sm text-muted-foreground",n),...a}));bb.displayName="CardDescription";const xa=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("p-6 pt-0",n),...a}));xa.displayName="CardContent";const xb=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("flex items-center p-6 pt-0",n),...a}));xb.displayName="CardFooter";function nA({transformers:n,onEdit:a,onRemove:l}){return!n||!Array.isArray(n)?y.jsx("div",{className:"space-y-3",children:y.jsx("div",{className:"flex items-center justify-center rounded-md border bg-white p-8 text-gray-500",children:"No transformers configured"})}):y.jsx("div",{className:"space-y-3",children:n.map((i,s)=>{if(!i)return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:"Invalid Transformer"}),y.jsx("p",{className:"text-sm text-gray-500",children:"Transformer data is missing"})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",disabled:!0,children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s);const u=i.path||"Unnamed Transformer",f=i.options||{},h=()=>!f||Object.keys(f).length===0?y.jsx("p",{className:"text-sm text-gray-500",children:"No parameters configured"}):y.jsx("div",{className:"flex flex-wrap gap-2 max-h-8 overflow-hidden",children:Object.entries(f).map(([p,m])=>y.jsxs("span",{className:"inline-flex items-center px-2 py-1 rounded-md bg-gray-100 text-xs font-medium text-gray-700 border",children:[y.jsxs("span",{className:"text-gray-600",children:[p,":"]}),y.jsx("span",{className:"ml-1 text-gray-800",children:String(m)})]},p))});return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:u}),h()]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s)})})}function aA(){const{t:n}=$r(),{config:a,setConfig:l}=Il(),[i,s]=v.useState(null),[u,f]=v.useState(null),[h,p]=v.useState(null);if(!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("transformers.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading transformers configuration..."})})]});const m=Array.isArray(a.transformers)?a.transformers:[],g=()=>{p({name:"",path:"",options:{}}),s(m.length)},x=T=>{const O=[...m];O.splice(T,1),l({...a,transformers:O}),f(null)},S=(T,O,z,k)=>{if(T<m.length){const H=[...m];k!==void 0?H[T].options[k]=z:H[T][O]=z,l({...a,transformers:H})}else if(h){const H={...h};k!==void 0?H.options[k]=z:H[O]=z,p(H)}},w=i!==null?i<m.length?m[i]:h:null,C=()=>{if(h&&i===m.length){const T=[...m,h];l({...a,transformers:T})}s(null),p(null)},R=()=>{s(null),p(null)};return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsxs(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:[y.jsxs(ba,{className:"text-lg",children:[n("transformers.title")," ",y.jsxs("span",{className:"text-sm font-normal text-gray-500",children:["(",m.length,")"]})]}),y.jsx(He,{onClick:g,children:n("transformers.add")})]}),y.jsx(xa,{className:"flex-grow overflow-y-auto p-4",children:y.jsx(nA,{transformers:m,onEdit:s,onRemove:f})}),y.jsx(mo,{open:i!==null,onOpenChange:R,children:y.jsxs(ql,{children:[y.jsx(Yl,{children:y.jsx(Kl,{children:n("transformers.edit")})}),w&&i!==null&&y.jsxs("div",{className:"space-y-4 py-4 px-6 max-h-96 overflow-y-auto",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"transformer-path",children:n("transformers.path")}),y.jsx(Rt,{id:"transformer-path",value:w.path||"",onChange:T=>S(i,"path",T.target.value)})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsx(ct,{children:n("transformers.parameters")}),y.jsx(He,{variant:"outline",size:"sm",onClick:()=>{const T=w.options||{},O=`param${Object.keys(T).length+1}`;if(i!==null){const z={...T,[O]:""};if(i<m.length){const k=[...m];k[i].options=z,l({...a,transformers:k})}else h&&p({...h,options:z})}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),Object.entries(w.options||{}).map(([T,O])=>y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(Rt,{value:T,onChange:z=>{const H={...w.options||{}};if(delete H[T],H[z.target.value]=O,i!==null)if(i<m.length){const P=[...m];P[i].options=H,l({...a,transformers:P})}else h&&p({...h,options:H})},className:"flex-1"}),y.jsx(Rt,{value:O,onChange:z=>{i!==null&&S(i,"parameters",z.target.value,T)},className:"flex-1"}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{if(i!==null){const k={...w.options||{}};if(delete k[T],i<m.length){const H=[...m];H[i].options=k,l({...a,transformers:H})}else h&&p({...h,options:k})}},children:y.jsx(Pr,{className:"h-4 w-4"})})]},T))]})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:R,children:n("app.cancel")}),y.jsx(He,{onClick:C,children:n("app.save")})]})]})}),y.jsx(mo,{open:u!==null,onOpenChange:()=>f(null),children:y.jsxs(ql,{children:[y.jsxs(Yl,{children:[y.jsx(Kl,{children:n("transformers.delete")}),y.jsx(ah,{children:n("transformers.delete_transformer_confirm")})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:()=>f(null),children:n("app.cancel")}),y.jsx(He,{variant:"destructive",onClick:()=>u!==null&&x(u),children:n("app.delete")})]})]})})]})}const rA=rh("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 Sb({className:n,variant:a,...l}){return y.jsx("div",{className:ft(rA({variant:a}),n),...l})}function lA({providers:n,onEdit:a,onRemove:l}){return!n||!Array.isArray(n)?y.jsx("div",{className:"space-y-3",children:y.jsx("div",{className:"flex items-center justify-center rounded-md border bg-white p-8 text-gray-500",children:"No providers configured"})}):y.jsx("div",{className:"space-y-3",children:n.map((i,s)=>{if(!i)return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:"Invalid Provider"}),y.jsx("p",{className:"text-sm text-gray-500",children:"Provider data is missing"})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",disabled:!0,children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s);const u=i.name||"Unnamed Provider",f=i.api_base_url||"No API URL",h=Array.isArray(i.models)?i.models:[];return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:u}),y.jsx("p",{className:"text-sm text-gray-500",children:f}),y.jsx("div",{className:"flex flex-wrap gap-2 pt-2",children:h.map((p,m)=>y.jsx(Sb,{variant:"outline",className:"font-normal transition-all-ease hover:scale-105",children:p||"Unnamed Model"},m))})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s)})})}var dy=1,iA=.9,oA=.8,sA=.17,sd=.1,ud=.999,uA=.9999,cA=.99,fA=/[\\\/_+.#"@\[\(\{&]/,dA=/[\\\/_+.#"@\[\(\{&]/g,hA=/[\s-]/,wb=/[\s-]/g;function _d(n,a,l,i,s,u,f){if(u===a.length)return s===n.length?dy:cA;var h=`${s},${u}`;if(f[h]!==void 0)return f[h];for(var p=i.charAt(u),m=l.indexOf(p,s),g=0,x,S,w,C;m>=0;)x=_d(n,a,l,i,m+1,u+1,f),x>g&&(m===s?x*=dy:fA.test(n.charAt(m-1))?(x*=oA,w=n.slice(s,m-1).match(dA),w&&s>0&&(x*=Math.pow(ud,w.length))):hA.test(n.charAt(m-1))?(x*=iA,C=n.slice(s,m-1).match(wb),C&&s>0&&(x*=Math.pow(ud,C.length))):(x*=sA,s>0&&(x*=Math.pow(ud,m-s))),n.charAt(m)!==a.charAt(u)&&(x*=uA)),(x<sd&&l.charAt(m-1)===i.charAt(u+1)||i.charAt(u+1)===i.charAt(u)&&l.charAt(m-1)!==i.charAt(u))&&(S=_d(n,a,l,i,m+1,u+2,f),S*sd>x&&(x=S*sd)),x>g&&(g=x),m=l.indexOf(p,m+1);return f[h]=g,g}function hy(n){return n.toLowerCase().replace(wb," ")}function mA(n,a,l){return n=l&&l.length>0?`${n+" "+l.join(" ")}`:n,_d(n,a,hy(n),hy(a),0,0,{})}var ro='[cmdk-group=""]',cd='[cmdk-group-items=""]',pA='[cmdk-group-heading=""]',Eb='[cmdk-item=""]',my=`${Eb}:not([aria-disabled="true"])`,Dd="cmdk-item-select",zl="data-value",gA=(n,a,l)=>mA(n,a,l),Rb=v.createContext(void 0),So=()=>v.useContext(Rb),Cb=v.createContext(void 0),lh=()=>v.useContext(Cb),Ob=v.createContext(void 0),Ab=v.forwardRef((n,a)=>{let l=kl(()=>{var L,K;return{search:"",value:(K=(L=n.value)!=null?L:n.defaultValue)!=null?K:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),i=kl(()=>new Set),s=kl(()=>new Map),u=kl(()=>new Map),f=kl(()=>new Set),h=Nb(n),{label:p,children:m,value:g,onValueChange:x,filter:S,shouldFilter:w,loop:C,disablePointerSelection:R=!1,vimBindings:T=!0,...O}=n,z=Gn(),k=Gn(),H=Gn(),P=v.useRef(null),A=AA();Hr(()=>{if(g!==void 0){let L=g.trim();l.current.value=L,G.emit()}},[g]),Hr(()=>{A(6,me)},[]);let G=v.useMemo(()=>({subscribe:L=>(f.current.add(L),()=>f.current.delete(L)),snapshot:()=>l.current,setState:(L,K,W)=>{var oe,de,ge,ze;if(!Object.is(l.current[L],K)){if(l.current[L]=K,L==="search")Ee(),ie(),A(1,Oe);else if(L==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let Ze=document.getElementById(H);Ze?Ze.focus():(oe=document.getElementById(z))==null||oe.focus()}if(A(7,()=>{var Ze;l.current.selectedItemId=(Ze=he())==null?void 0:Ze.id,G.emit()}),W||A(5,me),((de=h.current)==null?void 0:de.value)!==void 0){let Ze=K??"";(ze=(ge=h.current).onValueChange)==null||ze.call(ge,Ze);return}}G.emit()}},emit:()=>{f.current.forEach(L=>L())}}),[]),J=v.useMemo(()=>({value:(L,K,W)=>{var oe;K!==((oe=u.current.get(L))==null?void 0:oe.value)&&(u.current.set(L,{value:K,keywords:W}),l.current.filtered.items.set(L,re(K,W)),A(2,()=>{ie(),G.emit()}))},item:(L,K)=>(i.current.add(L),K&&(s.current.has(K)?s.current.get(K).add(L):s.current.set(K,new Set([L]))),A(3,()=>{Ee(),ie(),l.current.value||Oe(),G.emit()}),()=>{u.current.delete(L),i.current.delete(L),l.current.filtered.items.delete(L);let W=he();A(4,()=>{Ee(),W?.getAttribute("id")===L&&Oe(),G.emit()})}),group:L=>(s.current.has(L)||s.current.set(L,new Set),()=>{u.current.delete(L),s.current.delete(L)}),filter:()=>h.current.shouldFilter,label:p||n["aria-label"],getDisablePointerSelection:()=>h.current.disablePointerSelection,listId:z,inputId:H,labelId:k,listInnerRef:P}),[]);function re(L,K){var W,oe;let de=(oe=(W=h.current)==null?void 0:W.filter)!=null?oe:gA;return L?de(L,l.current.search,K):0}function ie(){if(!l.current.search||h.current.shouldFilter===!1)return;let L=l.current.filtered.items,K=[];l.current.filtered.groups.forEach(oe=>{let de=s.current.get(oe),ge=0;de.forEach(ze=>{let Ze=L.get(ze);ge=Math.max(Ze,ge)}),K.push([oe,ge])});let W=P.current;fe().sort((oe,de)=>{var ge,ze;let Ze=oe.getAttribute("id"),je=de.getAttribute("id");return((ge=L.get(je))!=null?ge:0)-((ze=L.get(Ze))!=null?ze:0)}).forEach(oe=>{let de=oe.closest(cd);de?de.appendChild(oe.parentElement===de?oe:oe.closest(`${cd} > *`)):W.appendChild(oe.parentElement===W?oe:oe.closest(`${cd} > *`))}),K.sort((oe,de)=>de[1]-oe[1]).forEach(oe=>{var de;let ge=(de=P.current)==null?void 0:de.querySelector(`${ro}[${zl}="${encodeURIComponent(oe[0])}"]`);ge?.parentElement.appendChild(ge)})}function Oe(){let L=fe().find(W=>W.getAttribute("aria-disabled")!=="true"),K=L?.getAttribute(zl);G.setState("value",K||void 0)}function Ee(){var L,K,W,oe;if(!l.current.search||h.current.shouldFilter===!1){l.current.filtered.count=i.current.size;return}l.current.filtered.groups=new Set;let de=0;for(let ge of i.current){let ze=(K=(L=u.current.get(ge))==null?void 0:L.value)!=null?K:"",Ze=(oe=(W=u.current.get(ge))==null?void 0:W.keywords)!=null?oe:[],je=re(ze,Ze);l.current.filtered.items.set(ge,je),je>0&&de++}for(let[ge,ze]of s.current)for(let Ze of ze)if(l.current.filtered.items.get(Ze)>0){l.current.filtered.groups.add(ge);break}l.current.filtered.count=de}function me(){var L,K,W;let oe=he();oe&&(((L=oe.parentElement)==null?void 0:L.firstChild)===oe&&((W=(K=oe.closest(ro))==null?void 0:K.querySelector(pA))==null||W.scrollIntoView({block:"nearest"})),oe.scrollIntoView({block:"nearest"}))}function he(){var L;return(L=P.current)==null?void 0:L.querySelector(`${Eb}[aria-selected="true"]`)}function fe(){var L;return Array.from(((L=P.current)==null?void 0:L.querySelectorAll(my))||[])}function _(L){let K=fe()[L];K&&G.setState("value",K.getAttribute(zl))}function Z(L){var K;let W=he(),oe=fe(),de=oe.findIndex(ze=>ze===W),ge=oe[de+L];(K=h.current)!=null&&K.loop&&(ge=de+L<0?oe[oe.length-1]:de+L===oe.length?oe[0]:oe[de+L]),ge&&G.setState("value",ge.getAttribute(zl))}function $(L){let K=he(),W=K?.closest(ro),oe;for(;W&&!oe;)W=L>0?CA(W,ro):OA(W,ro),oe=W?.querySelector(my);oe?G.setState("value",oe.getAttribute(zl)):Z(L)}let pe=()=>_(fe().length-1),N=L=>{L.preventDefault(),L.metaKey?pe():L.altKey?$(1):Z(1)},Y=L=>{L.preventDefault(),L.metaKey?_(0):L.altKey?$(-1):Z(-1)};return v.createElement(dt.div,{ref:a,tabIndex:-1,...O,"cmdk-root":"",onKeyDown:L=>{var K;(K=O.onKeyDown)==null||K.call(O,L);let W=L.nativeEvent.isComposing||L.keyCode===229;if(!(L.defaultPrevented||W))switch(L.key){case"n":case"j":{T&&L.ctrlKey&&N(L);break}case"ArrowDown":{N(L);break}case"p":case"k":{T&&L.ctrlKey&&Y(L);break}case"ArrowUp":{Y(L);break}case"Home":{L.preventDefault(),_(0);break}case"End":{L.preventDefault(),pe();break}case"Enter":{L.preventDefault();let oe=he();if(oe){let de=new Event(Dd);oe.dispatchEvent(de)}}}}},v.createElement("label",{"cmdk-label":"",htmlFor:J.inputId,id:J.labelId,style:TA},p),ju(n,L=>v.createElement(Cb.Provider,{value:G},v.createElement(Rb.Provider,{value:J},L))))}),vA=v.forwardRef((n,a)=>{var l,i;let s=Gn(),u=v.useRef(null),f=v.useContext(Ob),h=So(),p=Nb(n),m=(i=(l=p.current)==null?void 0:l.forceMount)!=null?i:f?.forceMount;Hr(()=>{if(!m)return h.item(s,f?.id)},[m]);let g=Tb(s,u,[n.value,n.children,u],n.keywords),x=lh(),S=ar(A=>A.value&&A.value===g.current),w=ar(A=>m||h.filter()===!1?!0:A.search?A.filtered.items.get(s)>0:!0);v.useEffect(()=>{let A=u.current;if(!(!A||n.disabled))return A.addEventListener(Dd,C),()=>A.removeEventListener(Dd,C)},[w,n.onSelect,n.disabled]);function C(){var A,G;R(),(G=(A=p.current).onSelect)==null||G.call(A,g.current)}function R(){x.setState("value",g.current,!0)}if(!w)return null;let{disabled:T,value:O,onSelect:z,forceMount:k,keywords:H,...P}=n;return v.createElement(dt.div,{ref:kr(u,a),...P,id:s,"cmdk-item":"",role:"option","aria-disabled":!!T,"aria-selected":!!S,"data-disabled":!!T,"data-selected":!!S,onPointerMove:T||h.getDisablePointerSelection()?void 0:R,onClick:T?void 0:C},n.children)}),yA=v.forwardRef((n,a)=>{let{heading:l,children:i,forceMount:s,...u}=n,f=Gn(),h=v.useRef(null),p=v.useRef(null),m=Gn(),g=So(),x=ar(w=>s||g.filter()===!1?!0:w.search?w.filtered.groups.has(f):!0);Hr(()=>g.group(f),[]),Tb(f,h,[n.value,n.heading,p]);let S=v.useMemo(()=>({id:f,forceMount:s}),[s]);return v.createElement(dt.div,{ref:kr(h,a),...u,"cmdk-group":"",role:"presentation",hidden:x?void 0:!0},l&&v.createElement("div",{ref:p,"cmdk-group-heading":"","aria-hidden":!0,id:m},l),ju(n,w=>v.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":l?m:void 0},v.createElement(Ob.Provider,{value:S},w))))}),bA=v.forwardRef((n,a)=>{let{alwaysRender:l,...i}=n,s=v.useRef(null),u=ar(f=>!f.search);return!l&&!u?null:v.createElement(dt.div,{ref:kr(s,a),...i,"cmdk-separator":"",role:"separator"})}),xA=v.forwardRef((n,a)=>{let{onValueChange:l,...i}=n,s=n.value!=null,u=lh(),f=ar(m=>m.search),h=ar(m=>m.selectedItemId),p=So();return v.useEffect(()=>{n.value!=null&&u.setState("search",n.value)},[n.value]),v.createElement(dt.input,{ref:a,...i,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":p.listId,"aria-labelledby":p.labelId,"aria-activedescendant":h,id:p.inputId,type:"text",value:s?n.value:f,onChange:m=>{s||u.setState("search",m.target.value),l?.(m.target.value)}})}),SA=v.forwardRef((n,a)=>{let{children:l,label:i="Suggestions",...s}=n,u=v.useRef(null),f=v.useRef(null),h=ar(m=>m.selectedItemId),p=So();return v.useEffect(()=>{if(f.current&&u.current){let m=f.current,g=u.current,x,S=new ResizeObserver(()=>{x=requestAnimationFrame(()=>{let w=m.offsetHeight;g.style.setProperty("--cmdk-list-height",w.toFixed(1)+"px")})});return S.observe(m),()=>{cancelAnimationFrame(x),S.unobserve(m)}}},[]),v.createElement(dt.div,{ref:kr(u,a),...s,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":h,"aria-label":i,id:p.listId},ju(n,m=>v.createElement("div",{ref:kr(f,p.listInnerRef),"cmdk-list-sizer":""},m)))}),wA=v.forwardRef((n,a)=>{let{open:l,onOpenChange:i,overlayClassName:s,contentClassName:u,container:f,...h}=n;return v.createElement(B0,{open:l,onOpenChange:i},v.createElement($0,{container:f},v.createElement(eh,{"cmdk-overlay":"",className:s}),v.createElement(th,{"aria-label":n.label,"cmdk-dialog":"",className:u},v.createElement(Ab,{ref:a,...h}))))}),EA=v.forwardRef((n,a)=>ar(l=>l.filtered.count===0)?v.createElement(dt.div,{ref:a,...n,"cmdk-empty":"",role:"presentation"}):null),RA=v.forwardRef((n,a)=>{let{progress:l,children:i,label:s="Loading...",...u}=n;return v.createElement(dt.div,{ref:a,...u,"cmdk-loading":"",role:"progressbar","aria-valuenow":l,"aria-valuemin":0,"aria-valuemax":100,"aria-label":s},ju(n,f=>v.createElement("div",{"aria-hidden":!0},f)))}),Wl=Object.assign(Ab,{List:SA,Item:vA,Input:xA,Group:yA,Separator:bA,Dialog:wA,Empty:EA,Loading:RA});function CA(n,a){let l=n.nextElementSibling;for(;l;){if(l.matches(a))return l;l=l.nextElementSibling}}function OA(n,a){let l=n.previousElementSibling;for(;l;){if(l.matches(a))return l;l=l.previousElementSibling}}function Nb(n){let a=v.useRef(n);return Hr(()=>{a.current=n}),a}var Hr=typeof window>"u"?v.useEffect:v.useLayoutEffect;function kl(n){let a=v.useRef();return a.current===void 0&&(a.current=n()),a}function ar(n){let a=lh(),l=()=>n(a.snapshot());return v.useSyncExternalStore(a.subscribe,l,l)}function Tb(n,a,l,i=[]){let s=v.useRef(),u=So();return Hr(()=>{var f;let h=(()=>{var m;for(let g of l){if(typeof g=="string")return g.trim();if(typeof g=="object"&&"current"in g)return g.current?(m=g.current.textContent)==null?void 0:m.trim():s.current}})(),p=i.map(m=>m.trim());u.value(n,h,p),(f=a.current)==null||f.setAttribute(zl,h),s.current=h}),s}var AA=()=>{let[n,a]=v.useState(),l=kl(()=>new Map);return Hr(()=>{l.current.forEach(i=>i()),l.current=new Map},[n]),(i,s)=>{l.current.set(i,s),a({})}};function NA(n){let a=n.type;return typeof a=="function"?a(n.props):"render"in a?a.render(n.props):n}function ju({asChild:n,children:a},l){return n&&v.isValidElement(a)?v.cloneElement(NA(a),{ref:a.ref},l(a.props.children)):l(a)}var TA={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function jb({className:n,...a}){return y.jsx(Wl,{"data-slot":"command",className:ft("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",n),...a})}function Mb({className:n,...a}){return y.jsxs("div",{"data-slot":"command-input-wrapper",className:"flex h-9 items-center gap-2 border-b px-3",children:[y.jsx(rO,{className:"size-4 shrink-0 opacity-50"}),y.jsx(Wl.Input,{"data-slot":"command-input",className:ft("placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",n),...a})]})}function _b({className:n,...a}){return y.jsx(Wl.List,{"data-slot":"command-list",className:ft("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",n),...a})}function Db({...n}){return y.jsx(Wl.Empty,{"data-slot":"command-empty",className:"py-6 text-center text-sm",...n})}function Lb({className:n,...a}){return y.jsx(Wl.Group,{"data-slot":"command-group",className:ft("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",n),...a})}function zb({className:n,...a}){return y.jsx(Wl.Item,{"data-slot":"command-item",className:ft("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",n),...a})}const jA=["top","right","bottom","left"],rr=Math.min,un=Math.max,hu=Math.round,Zs=Math.floor,Fn=n=>({x:n,y:n}),MA={left:"right",right:"left",bottom:"top",top:"bottom"},_A={start:"end",end:"start"};function Ld(n,a,l){return un(n,rr(a,l))}function Sa(n,a){return typeof n=="function"?n(a):n}function wa(n){return n.split("-")[0]}function ei(n){return n.split("-")[1]}function ih(n){return n==="x"?"y":"x"}function oh(n){return n==="y"?"height":"width"}const DA=new Set(["top","bottom"]);function Yn(n){return DA.has(wa(n))?"y":"x"}function sh(n){return ih(Yn(n))}function LA(n,a,l){l===void 0&&(l=!1);const i=ei(n),s=sh(n),u=oh(s);let f=s==="x"?i===(l?"end":"start")?"right":"left":i==="start"?"bottom":"top";return a.reference[u]>a.floating[u]&&(f=mu(f)),[f,mu(f)]}function zA(n){const a=mu(n);return[zd(n),a,zd(a)]}function zd(n){return n.replace(/start|end/g,a=>_A[a])}const py=["left","right"],gy=["right","left"],kA=["top","bottom"],UA=["bottom","top"];function PA(n,a,l){switch(n){case"top":case"bottom":return l?a?gy:py:a?py:gy;case"left":case"right":return a?kA:UA;default:return[]}}function HA(n,a,l,i){const s=ei(n);let u=PA(wa(n),l==="start",i);return s&&(u=u.map(f=>f+"-"+s),a&&(u=u.concat(u.map(zd)))),u}function mu(n){return n.replace(/left|right|bottom|top/g,a=>MA[a])}function BA(n){return{top:0,right:0,bottom:0,left:0,...n}}function kb(n){return typeof n!="number"?BA(n):{top:n,right:n,bottom:n,left:n}}function pu(n){const{x:a,y:l,width:i,height:s}=n;return{width:i,height:s,top:l,left:a,right:a+i,bottom:l+s,x:a,y:l}}function vy(n,a,l){let{reference:i,floating:s}=n;const u=Yn(a),f=sh(a),h=oh(f),p=wa(a),m=u==="y",g=i.x+i.width/2-s.width/2,x=i.y+i.height/2-s.height/2,S=i[h]/2-s[h]/2;let w;switch(p){case"top":w={x:g,y:i.y-s.height};break;case"bottom":w={x:g,y:i.y+i.height};break;case"right":w={x:i.x+i.width,y:x};break;case"left":w={x:i.x-s.width,y:x};break;default:w={x:i.x,y:i.y}}switch(ei(a)){case"start":w[f]-=S*(l&&m?-1:1);break;case"end":w[f]+=S*(l&&m?-1:1);break}return w}const $A=async(n,a,l)=>{const{placement:i="bottom",strategy:s="absolute",middleware:u=[],platform:f}=l,h=u.filter(Boolean),p=await(f.isRTL==null?void 0:f.isRTL(a));let m=await f.getElementRects({reference:n,floating:a,strategy:s}),{x:g,y:x}=vy(m,i,p),S=i,w={},C=0;for(let R=0;R<h.length;R++){const{name:T,fn:O}=h[R],{x:z,y:k,data:H,reset:P}=await O({x:g,y:x,initialPlacement:i,placement:S,strategy:s,middlewareData:w,rects:m,platform:f,elements:{reference:n,floating:a}});g=z??g,x=k??x,w={...w,[T]:{...w[T],...H}},P&&C<=50&&(C++,typeof P=="object"&&(P.placement&&(S=P.placement),P.rects&&(m=P.rects===!0?await f.getElementRects({reference:n,floating:a,strategy:s}):P.rects),{x:g,y:x}=vy(m,S,p)),R=-1)}return{x:g,y:x,placement:S,strategy:s,middlewareData:w}};async function go(n,a){var l;a===void 0&&(a={});const{x:i,y:s,platform:u,rects:f,elements:h,strategy:p}=n,{boundary:m="clippingAncestors",rootBoundary:g="viewport",elementContext:x="floating",altBoundary:S=!1,padding:w=0}=Sa(a,n),C=kb(w),T=h[S?x==="floating"?"reference":"floating":x],O=pu(await u.getClippingRect({element:(l=await(u.isElement==null?void 0:u.isElement(T)))==null||l?T:T.contextElement||await(u.getDocumentElement==null?void 0:u.getDocumentElement(h.floating)),boundary:m,rootBoundary:g,strategy:p})),z=x==="floating"?{x:i,y:s,width:f.floating.width,height:f.floating.height}:f.reference,k=await(u.getOffsetParent==null?void 0:u.getOffsetParent(h.floating)),H=await(u.isElement==null?void 0:u.isElement(k))?await(u.getScale==null?void 0:u.getScale(k))||{x:1,y:1}:{x:1,y:1},P=pu(u.convertOffsetParentRelativeRectToViewportRelativeRect?await u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:h,rect:z,offsetParent:k,strategy:p}):z);return{top:(O.top-P.top+C.top)/H.y,bottom:(P.bottom-O.bottom+C.bottom)/H.y,left:(O.left-P.left+C.left)/H.x,right:(P.right-O.right+C.right)/H.x}}const VA=n=>({name:"arrow",options:n,async fn(a){const{x:l,y:i,placement:s,rects:u,platform:f,elements:h,middlewareData:p}=a,{element:m,padding:g=0}=Sa(n,a)||{};if(m==null)return{};const x=kb(g),S={x:l,y:i},w=sh(s),C=oh(w),R=await f.getDimensions(m),T=w==="y",O=T?"top":"left",z=T?"bottom":"right",k=T?"clientHeight":"clientWidth",H=u.reference[C]+u.reference[w]-S[w]-u.floating[C],P=S[w]-u.reference[w],A=await(f.getOffsetParent==null?void 0:f.getOffsetParent(m));let G=A?A[k]:0;(!G||!await(f.isElement==null?void 0:f.isElement(A)))&&(G=h.floating[k]||u.floating[C]);const J=H/2-P/2,re=G/2-R[C]/2-1,ie=rr(x[O],re),Oe=rr(x[z],re),Ee=ie,me=G-R[C]-Oe,he=G/2-R[C]/2+J,fe=Ld(Ee,he,me),_=!p.arrow&&ei(s)!=null&&he!==fe&&u.reference[C]/2-(he<Ee?ie:Oe)-R[C]/2<0,Z=_?he<Ee?he-Ee:he-me:0;return{[w]:S[w]+Z,data:{[w]:fe,centerOffset:he-fe-Z,..._&&{alignmentOffset:Z}},reset:_}}}),qA=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(a){var l,i;const{placement:s,middlewareData:u,rects:f,initialPlacement:h,platform:p,elements:m}=a,{mainAxis:g=!0,crossAxis:x=!0,fallbackPlacements:S,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:C="none",flipAlignment:R=!0,...T}=Sa(n,a);if((l=u.arrow)!=null&&l.alignmentOffset)return{};const O=wa(s),z=Yn(h),k=wa(h)===h,H=await(p.isRTL==null?void 0:p.isRTL(m.floating)),P=S||(k||!R?[mu(h)]:zA(h)),A=C!=="none";!S&&A&&P.push(...HA(h,R,C,H));const G=[h,...P],J=await go(a,T),re=[];let ie=((i=u.flip)==null?void 0:i.overflows)||[];if(g&&re.push(J[O]),x){const he=LA(s,f,H);re.push(J[he[0]],J[he[1]])}if(ie=[...ie,{placement:s,overflows:re}],!re.every(he=>he<=0)){var Oe,Ee;const he=(((Oe=u.flip)==null?void 0:Oe.index)||0)+1,fe=G[he];if(fe&&(!(x==="alignment"?z!==Yn(fe):!1)||ie.every($=>$.overflows[0]>0&&Yn($.placement)===z)))return{data:{index:he,overflows:ie},reset:{placement:fe}};let _=(Ee=ie.filter(Z=>Z.overflows[0]<=0).sort((Z,$)=>Z.overflows[1]-$.overflows[1])[0])==null?void 0:Ee.placement;if(!_)switch(w){case"bestFit":{var me;const Z=(me=ie.filter($=>{if(A){const pe=Yn($.placement);return pe===z||pe==="y"}return!0}).map($=>[$.placement,$.overflows.filter(pe=>pe>0).reduce((pe,N)=>pe+N,0)]).sort(($,pe)=>$[1]-pe[1])[0])==null?void 0:me[0];Z&&(_=Z);break}case"initialPlacement":_=h;break}if(s!==_)return{reset:{placement:_}}}return{}}}};function yy(n,a){return{top:n.top-a.height,right:n.right-a.width,bottom:n.bottom-a.height,left:n.left-a.width}}function by(n){return jA.some(a=>n[a]>=0)}const YA=function(n){return n===void 0&&(n={}),{name:"hide",options:n,async fn(a){const{rects:l}=a,{strategy:i="referenceHidden",...s}=Sa(n,a);switch(i){case"referenceHidden":{const u=await go(a,{...s,elementContext:"reference"}),f=yy(u,l.reference);return{data:{referenceHiddenOffsets:f,referenceHidden:by(f)}}}case"escaped":{const u=await go(a,{...s,altBoundary:!0}),f=yy(u,l.floating);return{data:{escapedOffsets:f,escaped:by(f)}}}default:return{}}}}},Ub=new Set(["left","top"]);async function KA(n,a){const{placement:l,platform:i,elements:s}=n,u=await(i.isRTL==null?void 0:i.isRTL(s.floating)),f=wa(l),h=ei(l),p=Yn(l)==="y",m=Ub.has(f)?-1:1,g=u&&p?-1:1,x=Sa(a,n);let{mainAxis:S,crossAxis:w,alignmentAxis:C}=typeof x=="number"?{mainAxis:x,crossAxis:0,alignmentAxis:null}:{mainAxis:x.mainAxis||0,crossAxis:x.crossAxis||0,alignmentAxis:x.alignmentAxis};return h&&typeof C=="number"&&(w=h==="end"?C*-1:C),p?{x:w*g,y:S*m}:{x:S*m,y:w*g}}const GA=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(a){var l,i;const{x:s,y:u,placement:f,middlewareData:h}=a,p=await KA(a,n);return f===((l=h.offset)==null?void 0:l.placement)&&(i=h.arrow)!=null&&i.alignmentOffset?{}:{x:s+p.x,y:u+p.y,data:{...p,placement:f}}}}},FA=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(a){const{x:l,y:i,placement:s}=a,{mainAxis:u=!0,crossAxis:f=!1,limiter:h={fn:T=>{let{x:O,y:z}=T;return{x:O,y:z}}},...p}=Sa(n,a),m={x:l,y:i},g=await go(a,p),x=Yn(wa(s)),S=ih(x);let w=m[S],C=m[x];if(u){const T=S==="y"?"top":"left",O=S==="y"?"bottom":"right",z=w+g[T],k=w-g[O];w=Ld(z,w,k)}if(f){const T=x==="y"?"top":"left",O=x==="y"?"bottom":"right",z=C+g[T],k=C-g[O];C=Ld(z,C,k)}const R=h.fn({...a,[S]:w,[x]:C});return{...R,data:{x:R.x-l,y:R.y-i,enabled:{[S]:u,[x]:f}}}}}},XA=function(n){return n===void 0&&(n={}),{options:n,fn(a){const{x:l,y:i,placement:s,rects:u,middlewareData:f}=a,{offset:h=0,mainAxis:p=!0,crossAxis:m=!0}=Sa(n,a),g={x:l,y:i},x=Yn(s),S=ih(x);let w=g[S],C=g[x];const R=Sa(h,a),T=typeof R=="number"?{mainAxis:R,crossAxis:0}:{mainAxis:0,crossAxis:0,...R};if(p){const k=S==="y"?"height":"width",H=u.reference[S]-u.floating[k]+T.mainAxis,P=u.reference[S]+u.reference[k]-T.mainAxis;w<H?w=H:w>P&&(w=P)}if(m){var O,z;const k=S==="y"?"width":"height",H=Ub.has(wa(s)),P=u.reference[x]-u.floating[k]+(H&&((O=f.offset)==null?void 0:O[x])||0)+(H?0:T.crossAxis),A=u.reference[x]+u.reference[k]+(H?0:((z=f.offset)==null?void 0:z[x])||0)-(H?T.crossAxis:0);C<P?C=P:C>A&&(C=A)}return{[S]:w,[x]:C}}}},QA=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(a){var l,i;const{placement:s,rects:u,platform:f,elements:h}=a,{apply:p=()=>{},...m}=Sa(n,a),g=await go(a,m),x=wa(s),S=ei(s),w=Yn(s)==="y",{width:C,height:R}=u.floating;let T,O;x==="top"||x==="bottom"?(T=x,O=S===(await(f.isRTL==null?void 0:f.isRTL(h.floating))?"start":"end")?"left":"right"):(O=x,T=S==="end"?"top":"bottom");const z=R-g.top-g.bottom,k=C-g.left-g.right,H=rr(R-g[T],z),P=rr(C-g[O],k),A=!a.middlewareData.shift;let G=H,J=P;if((l=a.middlewareData.shift)!=null&&l.enabled.x&&(J=k),(i=a.middlewareData.shift)!=null&&i.enabled.y&&(G=z),A&&!S){const ie=un(g.left,0),Oe=un(g.right,0),Ee=un(g.top,0),me=un(g.bottom,0);w?J=C-2*(ie!==0||Oe!==0?ie+Oe:un(g.left,g.right)):G=R-2*(Ee!==0||me!==0?Ee+me:un(g.top,g.bottom))}await p({...a,availableWidth:J,availableHeight:G});const re=await f.getDimensions(h.floating);return C!==re.width||R!==re.height?{reset:{rects:!0}}:{}}}};function Mu(){return typeof window<"u"}function ti(n){return Pb(n)?(n.nodeName||"").toLowerCase():"#document"}function cn(n){var a;return(n==null||(a=n.ownerDocument)==null?void 0:a.defaultView)||window}function Zn(n){var a;return(a=(Pb(n)?n.ownerDocument:n.document)||window.document)==null?void 0:a.documentElement}function Pb(n){return Mu()?n instanceof Node||n instanceof cn(n).Node:!1}function jn(n){return Mu()?n instanceof Element||n instanceof cn(n).Element:!1}function Xn(n){return Mu()?n instanceof HTMLElement||n instanceof cn(n).HTMLElement:!1}function xy(n){return!Mu()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof cn(n).ShadowRoot}const ZA=new Set(["inline","contents"]);function wo(n){const{overflow:a,overflowX:l,overflowY:i,display:s}=Mn(n);return/auto|scroll|overlay|hidden|clip/.test(a+i+l)&&!ZA.has(s)}const JA=new Set(["table","td","th"]);function IA(n){return JA.has(ti(n))}const WA=[":popover-open",":modal"];function _u(n){return WA.some(a=>{try{return n.matches(a)}catch{return!1}})}const eN=["transform","translate","scale","rotate","perspective"],tN=["transform","translate","scale","rotate","perspective","filter"],nN=["paint","layout","strict","content"];function uh(n){const a=ch(),l=jn(n)?Mn(n):n;return eN.some(i=>l[i]?l[i]!=="none":!1)||(l.containerType?l.containerType!=="normal":!1)||!a&&(l.backdropFilter?l.backdropFilter!=="none":!1)||!a&&(l.filter?l.filter!=="none":!1)||tN.some(i=>(l.willChange||"").includes(i))||nN.some(i=>(l.contain||"").includes(i))}function aN(n){let a=lr(n);for(;Xn(a)&&!Gl(a);){if(uh(a))return a;if(_u(a))return null;a=lr(a)}return null}function ch(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const rN=new Set(["html","body","#document"]);function Gl(n){return rN.has(ti(n))}function Mn(n){return cn(n).getComputedStyle(n)}function Du(n){return jn(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function lr(n){if(ti(n)==="html")return n;const a=n.assignedSlot||n.parentNode||xy(n)&&n.host||Zn(n);return xy(a)?a.host:a}function Hb(n){const a=lr(n);return Gl(a)?n.ownerDocument?n.ownerDocument.body:n.body:Xn(a)&&wo(a)?a:Hb(a)}function vo(n,a,l){var i;a===void 0&&(a=[]),l===void 0&&(l=!0);const s=Hb(n),u=s===((i=n.ownerDocument)==null?void 0:i.body),f=cn(s);if(u){const h=kd(f);return a.concat(f,f.visualViewport||[],wo(s)?s:[],h&&l?vo(h):[])}return a.concat(s,vo(s,[],l))}function kd(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Bb(n){const a=Mn(n);let l=parseFloat(a.width)||0,i=parseFloat(a.height)||0;const s=Xn(n),u=s?n.offsetWidth:l,f=s?n.offsetHeight:i,h=hu(l)!==u||hu(i)!==f;return h&&(l=u,i=f),{width:l,height:i,$:h}}function fh(n){return jn(n)?n:n.contextElement}function $l(n){const a=fh(n);if(!Xn(a))return Fn(1);const l=a.getBoundingClientRect(),{width:i,height:s,$:u}=Bb(a);let f=(u?hu(l.width):l.width)/i,h=(u?hu(l.height):l.height)/s;return(!f||!Number.isFinite(f))&&(f=1),(!h||!Number.isFinite(h))&&(h=1),{x:f,y:h}}const lN=Fn(0);function $b(n){const a=cn(n);return!ch()||!a.visualViewport?lN:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function iN(n,a,l){return a===void 0&&(a=!1),!l||a&&l!==cn(n)?!1:a}function Br(n,a,l,i){a===void 0&&(a=!1),l===void 0&&(l=!1);const s=n.getBoundingClientRect(),u=fh(n);let f=Fn(1);a&&(i?jn(i)&&(f=$l(i)):f=$l(n));const h=iN(u,l,i)?$b(u):Fn(0);let p=(s.left+h.x)/f.x,m=(s.top+h.y)/f.y,g=s.width/f.x,x=s.height/f.y;if(u){const S=cn(u),w=i&&jn(i)?cn(i):i;let C=S,R=kd(C);for(;R&&i&&w!==C;){const T=$l(R),O=R.getBoundingClientRect(),z=Mn(R),k=O.left+(R.clientLeft+parseFloat(z.paddingLeft))*T.x,H=O.top+(R.clientTop+parseFloat(z.paddingTop))*T.y;p*=T.x,m*=T.y,g*=T.x,x*=T.y,p+=k,m+=H,C=cn(R),R=kd(C)}}return pu({width:g,height:x,x:p,y:m})}function dh(n,a){const l=Du(n).scrollLeft;return a?a.left+l:Br(Zn(n)).left+l}function Vb(n,a,l){l===void 0&&(l=!1);const i=n.getBoundingClientRect(),s=i.left+a.scrollLeft-(l?0:dh(n,i)),u=i.top+a.scrollTop;return{x:s,y:u}}function oN(n){let{elements:a,rect:l,offsetParent:i,strategy:s}=n;const u=s==="fixed",f=Zn(i),h=a?_u(a.floating):!1;if(i===f||h&&u)return l;let p={scrollLeft:0,scrollTop:0},m=Fn(1);const g=Fn(0),x=Xn(i);if((x||!x&&!u)&&((ti(i)!=="body"||wo(f))&&(p=Du(i)),Xn(i))){const w=Br(i);m=$l(i),g.x=w.x+i.clientLeft,g.y=w.y+i.clientTop}const S=f&&!x&&!u?Vb(f,p,!0):Fn(0);return{width:l.width*m.x,height:l.height*m.y,x:l.x*m.x-p.scrollLeft*m.x+g.x+S.x,y:l.y*m.y-p.scrollTop*m.y+g.y+S.y}}function sN(n){return Array.from(n.getClientRects())}function uN(n){const a=Zn(n),l=Du(n),i=n.ownerDocument.body,s=un(a.scrollWidth,a.clientWidth,i.scrollWidth,i.clientWidth),u=un(a.scrollHeight,a.clientHeight,i.scrollHeight,i.clientHeight);let f=-l.scrollLeft+dh(n);const h=-l.scrollTop;return Mn(i).direction==="rtl"&&(f+=un(a.clientWidth,i.clientWidth)-s),{width:s,height:u,x:f,y:h}}function cN(n,a){const l=cn(n),i=Zn(n),s=l.visualViewport;let u=i.clientWidth,f=i.clientHeight,h=0,p=0;if(s){u=s.width,f=s.height;const m=ch();(!m||m&&a==="fixed")&&(h=s.offsetLeft,p=s.offsetTop)}return{width:u,height:f,x:h,y:p}}const fN=new Set(["absolute","fixed"]);function dN(n,a){const l=Br(n,!0,a==="fixed"),i=l.top+n.clientTop,s=l.left+n.clientLeft,u=Xn(n)?$l(n):Fn(1),f=n.clientWidth*u.x,h=n.clientHeight*u.y,p=s*u.x,m=i*u.y;return{width:f,height:h,x:p,y:m}}function Sy(n,a,l){let i;if(a==="viewport")i=cN(n,l);else if(a==="document")i=uN(Zn(n));else if(jn(a))i=dN(a,l);else{const s=$b(n);i={x:a.x-s.x,y:a.y-s.y,width:a.width,height:a.height}}return pu(i)}function qb(n,a){const l=lr(n);return l===a||!jn(l)||Gl(l)?!1:Mn(l).position==="fixed"||qb(l,a)}function hN(n,a){const l=a.get(n);if(l)return l;let i=vo(n,[],!1).filter(h=>jn(h)&&ti(h)!=="body"),s=null;const u=Mn(n).position==="fixed";let f=u?lr(n):n;for(;jn(f)&&!Gl(f);){const h=Mn(f),p=uh(f);!p&&h.position==="fixed"&&(s=null),(u?!p&&!s:!p&&h.position==="static"&&!!s&&fN.has(s.position)||wo(f)&&!p&&qb(n,f))?i=i.filter(g=>g!==f):s=h,f=lr(f)}return a.set(n,i),i}function mN(n){let{element:a,boundary:l,rootBoundary:i,strategy:s}=n;const f=[...l==="clippingAncestors"?_u(a)?[]:hN(a,this._c):[].concat(l),i],h=f[0],p=f.reduce((m,g)=>{const x=Sy(a,g,s);return m.top=un(x.top,m.top),m.right=rr(x.right,m.right),m.bottom=rr(x.bottom,m.bottom),m.left=un(x.left,m.left),m},Sy(a,h,s));return{width:p.right-p.left,height:p.bottom-p.top,x:p.left,y:p.top}}function pN(n){const{width:a,height:l}=Bb(n);return{width:a,height:l}}function gN(n,a,l){const i=Xn(a),s=Zn(a),u=l==="fixed",f=Br(n,!0,u,a);let h={scrollLeft:0,scrollTop:0};const p=Fn(0);function m(){p.x=dh(s)}if(i||!i&&!u)if((ti(a)!=="body"||wo(s))&&(h=Du(a)),i){const w=Br(a,!0,u,a);p.x=w.x+a.clientLeft,p.y=w.y+a.clientTop}else s&&m();u&&!i&&s&&m();const g=s&&!i&&!u?Vb(s,h):Fn(0),x=f.left+h.scrollLeft-p.x-g.x,S=f.top+h.scrollTop-p.y-g.y;return{x,y:S,width:f.width,height:f.height}}function fd(n){return Mn(n).position==="static"}function wy(n,a){if(!Xn(n)||Mn(n).position==="fixed")return null;if(a)return a(n);let l=n.offsetParent;return Zn(n)===l&&(l=l.ownerDocument.body),l}function Yb(n,a){const l=cn(n);if(_u(n))return l;if(!Xn(n)){let s=lr(n);for(;s&&!Gl(s);){if(jn(s)&&!fd(s))return s;s=lr(s)}return l}let i=wy(n,a);for(;i&&IA(i)&&fd(i);)i=wy(i,a);return i&&Gl(i)&&fd(i)&&!uh(i)?l:i||aN(n)||l}const vN=async function(n){const a=this.getOffsetParent||Yb,l=this.getDimensions,i=await l(n.floating);return{reference:gN(n.reference,await a(n.floating),n.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function yN(n){return Mn(n).direction==="rtl"}const bN={convertOffsetParentRelativeRectToViewportRelativeRect:oN,getDocumentElement:Zn,getClippingRect:mN,getOffsetParent:Yb,getElementRects:vN,getClientRects:sN,getDimensions:pN,getScale:$l,isElement:jn,isRTL:yN};function Kb(n,a){return n.x===a.x&&n.y===a.y&&n.width===a.width&&n.height===a.height}function xN(n,a){let l=null,i;const s=Zn(n);function u(){var h;clearTimeout(i),(h=l)==null||h.disconnect(),l=null}function f(h,p){h===void 0&&(h=!1),p===void 0&&(p=1),u();const m=n.getBoundingClientRect(),{left:g,top:x,width:S,height:w}=m;if(h||a(),!S||!w)return;const C=Zs(x),R=Zs(s.clientWidth-(g+S)),T=Zs(s.clientHeight-(x+w)),O=Zs(g),k={rootMargin:-C+"px "+-R+"px "+-T+"px "+-O+"px",threshold:un(0,rr(1,p))||1};let H=!0;function P(A){const G=A[0].intersectionRatio;if(G!==p){if(!H)return f();G?f(!1,G):i=setTimeout(()=>{f(!1,1e-7)},1e3)}G===1&&!Kb(m,n.getBoundingClientRect())&&f(),H=!1}try{l=new IntersectionObserver(P,{...k,root:s.ownerDocument})}catch{l=new IntersectionObserver(P,k)}l.observe(n)}return f(!0),u}function SN(n,a,l,i){i===void 0&&(i={});const{ancestorScroll:s=!0,ancestorResize:u=!0,elementResize:f=typeof ResizeObserver=="function",layoutShift:h=typeof IntersectionObserver=="function",animationFrame:p=!1}=i,m=fh(n),g=s||u?[...m?vo(m):[],...vo(a)]:[];g.forEach(O=>{s&&O.addEventListener("scroll",l,{passive:!0}),u&&O.addEventListener("resize",l)});const x=m&&h?xN(m,l):null;let S=-1,w=null;f&&(w=new ResizeObserver(O=>{let[z]=O;z&&z.target===m&&w&&(w.unobserve(a),cancelAnimationFrame(S),S=requestAnimationFrame(()=>{var k;(k=w)==null||k.observe(a)})),l()}),m&&!p&&w.observe(m),w.observe(a));let C,R=p?Br(n):null;p&&T();function T(){const O=Br(n);R&&!Kb(R,O)&&l(),R=O,C=requestAnimationFrame(T)}return l(),()=>{var O;g.forEach(z=>{s&&z.removeEventListener("scroll",l),u&&z.removeEventListener("resize",l)}),x?.(),(O=w)==null||O.disconnect(),w=null,p&&cancelAnimationFrame(C)}}const wN=GA,EN=FA,RN=qA,CN=QA,ON=YA,Ey=VA,AN=XA,NN=(n,a,l)=>{const i=new Map,s={platform:bN,...l},u={...s.platform,_c:i};return $A(n,a,{...s,platform:u})};var TN=typeof document<"u",jN=function(){},lu=TN?v.useLayoutEffect:jN;function gu(n,a){if(n===a)return!0;if(typeof n!=typeof a)return!1;if(typeof n=="function"&&n.toString()===a.toString())return!0;let l,i,s;if(n&&a&&typeof n=="object"){if(Array.isArray(n)){if(l=n.length,l!==a.length)return!1;for(i=l;i--!==0;)if(!gu(n[i],a[i]))return!1;return!0}if(s=Object.keys(n),l=s.length,l!==Object.keys(a).length)return!1;for(i=l;i--!==0;)if(!{}.hasOwnProperty.call(a,s[i]))return!1;for(i=l;i--!==0;){const u=s[i];if(!(u==="_owner"&&n.$$typeof)&&!gu(n[u],a[u]))return!1}return!0}return n!==n&&a!==a}function Gb(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function Ry(n,a){const l=Gb(n);return Math.round(a*l)/l}function dd(n){const a=v.useRef(n);return lu(()=>{a.current=n}),a}function MN(n){n===void 0&&(n={});const{placement:a="bottom",strategy:l="absolute",middleware:i=[],platform:s,elements:{reference:u,floating:f}={},transform:h=!0,whileElementsMounted:p,open:m}=n,[g,x]=v.useState({x:0,y:0,strategy:l,placement:a,middlewareData:{},isPositioned:!1}),[S,w]=v.useState(i);gu(S,i)||w(i);const[C,R]=v.useState(null),[T,O]=v.useState(null),z=v.useCallback($=>{$!==A.current&&(A.current=$,R($))},[]),k=v.useCallback($=>{$!==G.current&&(G.current=$,O($))},[]),H=u||C,P=f||T,A=v.useRef(null),G=v.useRef(null),J=v.useRef(g),re=p!=null,ie=dd(p),Oe=dd(s),Ee=dd(m),me=v.useCallback(()=>{if(!A.current||!G.current)return;const $={placement:a,strategy:l,middleware:S};Oe.current&&($.platform=Oe.current),NN(A.current,G.current,$).then(pe=>{const N={...pe,isPositioned:Ee.current!==!1};he.current&&!gu(J.current,N)&&(J.current=N,Ru.flushSync(()=>{x(N)}))})},[S,a,l,Oe,Ee]);lu(()=>{m===!1&&J.current.isPositioned&&(J.current.isPositioned=!1,x($=>({...$,isPositioned:!1})))},[m]);const he=v.useRef(!1);lu(()=>(he.current=!0,()=>{he.current=!1}),[]),lu(()=>{if(H&&(A.current=H),P&&(G.current=P),H&&P){if(ie.current)return ie.current(H,P,me);me()}},[H,P,me,ie,re]);const fe=v.useMemo(()=>({reference:A,floating:G,setReference:z,setFloating:k}),[z,k]),_=v.useMemo(()=>({reference:H,floating:P}),[H,P]),Z=v.useMemo(()=>{const $={position:l,left:0,top:0};if(!_.floating)return $;const pe=Ry(_.floating,g.x),N=Ry(_.floating,g.y);return h?{...$,transform:"translate("+pe+"px, "+N+"px)",...Gb(_.floating)>=1.5&&{willChange:"transform"}}:{position:l,left:pe,top:N}},[l,h,_.floating,g.x,g.y]);return v.useMemo(()=>({...g,update:me,refs:fe,elements:_,floatingStyles:Z}),[g,me,fe,_,Z])}const _N=n=>{function a(l){return{}.hasOwnProperty.call(l,"current")}return{name:"arrow",options:n,fn(l){const{element:i,padding:s}=typeof n=="function"?n(l):n;return i&&a(i)?i.current!=null?Ey({element:i.current,padding:s}).fn(l):{}:i?Ey({element:i,padding:s}).fn(l):{}}}},DN=(n,a)=>({...wN(n),options:[n,a]}),LN=(n,a)=>({...EN(n),options:[n,a]}),zN=(n,a)=>({...AN(n),options:[n,a]}),kN=(n,a)=>({...RN(n),options:[n,a]}),UN=(n,a)=>({...CN(n),options:[n,a]}),PN=(n,a)=>({...ON(n),options:[n,a]}),HN=(n,a)=>({..._N(n),options:[n,a]});var BN="Arrow",Fb=v.forwardRef((n,a)=>{const{children:l,width:i=10,height:s=5,...u}=n;return y.jsx(dt.svg,{...u,ref:a,width:i,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:n.asChild?l:y.jsx("polygon",{points:"0,0 30,0 15,10"})})});Fb.displayName=BN;var $N=Fb,hh="Popper",[Xb,Qb]=Cu(hh),[VN,Zb]=Xb(hh),Jb=n=>{const{__scopePopper:a,children:l}=n,[i,s]=v.useState(null);return y.jsx(VN,{scope:a,anchor:i,onAnchorChange:s,children:l})};Jb.displayName=hh;var Ib="PopperAnchor",Wb=v.forwardRef((n,a)=>{const{__scopePopper:l,virtualRef:i,...s}=n,u=Zb(Ib,l),f=v.useRef(null),h=fn(a,f);return v.useEffect(()=>{u.onAnchorChange(i?.current||f.current)}),i?null:y.jsx(dt.div,{...s,ref:h})});Wb.displayName=Ib;var mh="PopperContent",[qN,YN]=Xb(mh),ex=v.forwardRef((n,a)=>{const{__scopePopper:l,side:i="bottom",sideOffset:s=0,align:u="center",alignOffset:f=0,arrowPadding:h=0,avoidCollisions:p=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:x="partial",hideWhenDetached:S=!1,updatePositionStrategy:w="optimized",onPlaced:C,...R}=n,T=Zb(mh,l),[O,z]=v.useState(null),k=fn(a,ge=>z(ge)),[H,P]=v.useState(null),A=cb(H),G=A?.width??0,J=A?.height??0,re=i+(u!=="center"?"-"+u:""),ie=typeof g=="number"?g:{top:0,right:0,bottom:0,left:0,...g},Oe=Array.isArray(m)?m:[m],Ee=Oe.length>0,me={padding:ie,boundary:Oe.filter(GN),altBoundary:Ee},{refs:he,floatingStyles:fe,placement:_,isPositioned:Z,middlewareData:$}=MN({strategy:"fixed",placement:re,whileElementsMounted:(...ge)=>SN(...ge,{animationFrame:w==="always"}),elements:{reference:T.anchor},middleware:[DN({mainAxis:s+J,alignmentAxis:f}),p&&LN({mainAxis:!0,crossAxis:!1,limiter:x==="partial"?zN():void 0,...me}),p&&kN({...me}),UN({...me,apply:({elements:ge,rects:ze,availableWidth:Ze,availableHeight:je})=>{const{width:ae,height:te}=ze.reference,se=ge.floating.style;se.setProperty("--radix-popper-available-width",`${Ze}px`),se.setProperty("--radix-popper-available-height",`${je}px`),se.setProperty("--radix-popper-anchor-width",`${ae}px`),se.setProperty("--radix-popper-anchor-height",`${te}px`)}}),H&&HN({element:H,padding:h}),FN({arrowWidth:G,arrowHeight:J}),S&&PN({strategy:"referenceHidden",...me})]}),[pe,N]=ax(_),Y=Vl(C);nr(()=>{Z&&Y?.()},[Z,Y]);const L=$.arrow?.x,K=$.arrow?.y,W=$.arrow?.centerOffset!==0,[oe,de]=v.useState();return nr(()=>{O&&de(window.getComputedStyle(O).zIndex)},[O]),y.jsx("div",{ref:he.setFloating,"data-radix-popper-content-wrapper":"",style:{...fe,transform:Z?fe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:oe,"--radix-popper-transform-origin":[$.transformOrigin?.x,$.transformOrigin?.y].join(" "),...$.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:n.dir,children:y.jsx(qN,{scope:l,placedSide:pe,onArrowChange:P,arrowX:L,arrowY:K,shouldHideArrow:W,children:y.jsx(dt.div,{"data-side":pe,"data-align":N,...R,ref:k,style:{...R.style,animation:Z?void 0:"none"}})})})});ex.displayName=mh;var tx="PopperArrow",KN={top:"bottom",right:"left",bottom:"top",left:"right"},nx=v.forwardRef(function(a,l){const{__scopePopper:i,...s}=a,u=YN(tx,i),f=KN[u.placedSide];return y.jsx("span",{ref:u.onArrowChange,style:{position:"absolute",left:u.arrowX,top:u.arrowY,[f]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[u.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[u.placedSide],visibility:u.shouldHideArrow?"hidden":void 0},children:y.jsx($N,{...s,ref:l,style:{...s.style,display:"block"}})})});nx.displayName=tx;function GN(n){return n!==null}var FN=n=>({name:"transformOrigin",options:n,fn(a){const{placement:l,rects:i,middlewareData:s}=a,f=s.arrow?.centerOffset!==0,h=f?0:n.arrowWidth,p=f?0:n.arrowHeight,[m,g]=ax(l),x={start:"0%",center:"50%",end:"100%"}[g],S=(s.arrow?.x??0)+h/2,w=(s.arrow?.y??0)+p/2;let C="",R="";return m==="bottom"?(C=f?x:`${S}px`,R=`${-p}px`):m==="top"?(C=f?x:`${S}px`,R=`${i.floating.height+p}px`):m==="right"?(C=`${-p}px`,R=f?x:`${w}px`):m==="left"&&(C=`${i.floating.width+p}px`,R=f?x:`${w}px`),{data:{x:C,y:R}}}});function ax(n){const[a,l="center"]=n.split("-");return[a,l]}var XN=Jb,rx=Wb,QN=ex,ZN=nx,Lu="Popover",[lx,jj]=Cu(Lu,[Qb]),Eo=Qb(),[JN,or]=lx(Lu),ix=n=>{const{__scopePopover:a,children:l,open:i,defaultOpen:s,onOpenChange:u,modal:f=!1}=n,h=Eo(a),p=v.useRef(null),[m,g]=v.useState(!1),[x,S]=Gd({prop:i,defaultProp:s??!1,onChange:u,caller:Lu});return y.jsx(XN,{...h,children:y.jsx(JN,{scope:a,contentId:Gn(),triggerRef:p,open:x,onOpenChange:S,onOpenToggle:v.useCallback(()=>S(w=>!w),[S]),hasCustomAnchor:m,onCustomAnchorAdd:v.useCallback(()=>g(!0),[]),onCustomAnchorRemove:v.useCallback(()=>g(!1),[]),modal:f,children:l})})};ix.displayName=Lu;var ox="PopoverAnchor",IN=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(ox,l),u=Eo(l),{onCustomAnchorAdd:f,onCustomAnchorRemove:h}=s;return v.useEffect(()=>(f(),()=>h()),[f,h]),y.jsx(rx,{...u,...i,ref:a})});IN.displayName=ox;var sx="PopoverTrigger",ux=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(sx,l),u=Eo(l),f=fn(a,s.triggerRef),h=y.jsx(dt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":mx(s.open),...i,ref:f,onClick:Jt(n.onClick,s.onOpenToggle)});return s.hasCustomAnchor?h:y.jsx(rx,{asChild:!0,...u,children:h})});ux.displayName=sx;var ph="PopoverPortal",[WN,eT]=lx(ph,{forceMount:void 0}),cx=n=>{const{__scopePopover:a,forceMount:l,children:i,container:s}=n,u=or(ph,a);return y.jsx(WN,{scope:a,forceMount:l,children:y.jsx(Ql,{present:l||u.open,children:y.jsx(Qd,{asChild:!0,container:s,children:i})})})};cx.displayName=ph;var Fl="PopoverContent",fx=v.forwardRef((n,a)=>{const l=eT(Fl,n.__scopePopover),{forceMount:i=l.forceMount,...s}=n,u=or(Fl,n.__scopePopover);return y.jsx(Ql,{present:i||u.open,children:u.modal?y.jsx(nT,{...s,ref:a}):y.jsx(aT,{...s,ref:a})})});fx.displayName=Fl;var tT=Ou("PopoverContent.RemoveScroll"),nT=v.forwardRef((n,a)=>{const l=or(Fl,n.__scopePopover),i=v.useRef(null),s=fn(a,i),u=v.useRef(!1);return v.useEffect(()=>{const f=i.current;if(f)return R0(f)},[]),y.jsx(Zd,{as:tT,allowPinchZoom:!0,children:y.jsx(dx,{...n,ref:s,trapFocus:l.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Jt(n.onCloseAutoFocus,f=>{f.preventDefault(),u.current||l.triggerRef.current?.focus()}),onPointerDownOutside:Jt(n.onPointerDownOutside,f=>{const h=f.detail.originalEvent,p=h.button===0&&h.ctrlKey===!0,m=h.button===2||p;u.current=m},{checkForDefaultPrevented:!1}),onFocusOutside:Jt(n.onFocusOutside,f=>f.preventDefault(),{checkForDefaultPrevented:!1})})})}),aT=v.forwardRef((n,a)=>{const l=or(Fl,n.__scopePopover),i=v.useRef(!1),s=v.useRef(!1);return y.jsx(dx,{...n,ref:a,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:u=>{n.onCloseAutoFocus?.(u),u.defaultPrevented||(i.current||l.triggerRef.current?.focus(),u.preventDefault()),i.current=!1,s.current=!1},onInteractOutside:u=>{n.onInteractOutside?.(u),u.defaultPrevented||(i.current=!0,u.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const f=u.target;l.triggerRef.current?.contains(f)&&u.preventDefault(),u.detail.originalEvent.type==="focusin"&&s.current&&u.preventDefault()}})}),dx=v.forwardRef((n,a)=>{const{__scopePopover:l,trapFocus:i,onOpenAutoFocus:s,onCloseAutoFocus:u,disableOutsidePointerEvents:f,onEscapeKeyDown:h,onPointerDownOutside:p,onFocusOutside:m,onInteractOutside:g,...x}=n,S=or(Fl,l),w=Eo(l);return p0(),y.jsx(Xd,{asChild:!0,loop:!0,trapped:i,onMountAutoFocus:s,onUnmountAutoFocus:u,children:y.jsx(Fd,{asChild:!0,disableOutsidePointerEvents:f,onInteractOutside:g,onEscapeKeyDown:h,onPointerDownOutside:p,onFocusOutside:m,onDismiss:()=>S.onOpenChange(!1),children:y.jsx(QN,{"data-state":mx(S.open),role:"dialog",id:S.contentId,...w,...x,ref:a,style:{...x.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),hx="PopoverClose",rT=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(hx,l);return y.jsx(dt.button,{type:"button",...i,ref:a,onClick:Jt(n.onClick,()=>s.onOpenChange(!1))})});rT.displayName=hx;var lT="PopoverArrow",iT=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=Eo(l);return y.jsx(ZN,{...s,...i,ref:a})});iT.displayName=lT;function mx(n){return n?"open":"closed"}var oT=ix,sT=ux,uT=cx,cT=fx;function gh({...n}){return y.jsx(oT,{"data-slot":"popover",...n})}function vh({...n}){return y.jsx(sT,{"data-slot":"popover-trigger",...n})}function yh({className:n,align:a="center",sideOffset:l=4,...i}){return y.jsx(uT,{children:y.jsx(cT,{"data-slot":"popover-content",align:a,sideOffset:l,className:ft("bg-popover text-popover-foreground 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-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden animate-fade-in",n),...i})})}function Wa({options:n,value:a,onChange:l,placeholder:i="Select an option...",searchPlaceholder:s="Search...",emptyPlaceholder:u="No options found."}){const[f,h]=v.useState(!1),p=n.find(m=>m.value===a);return y.jsxs(gh,{open:f,onOpenChange:h,children:[y.jsx(vh,{asChild:!0,children:y.jsxs(He,{variant:"outline",role:"combobox","aria-expanded":f,className:"w-full justify-between transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[p?p.label:i,y.jsx(G0,{className:"ml-2 h-4 w-4 shrink-0 opacity-50 transition-transform duration-200 group-data-[state=open]:rotate-180"})]})}),y.jsx(yh,{className:"w-[--radix-popover-trigger-width] p-0 animate-fade-in",children:y.jsxs(jb,{children:[y.jsx(Mb,{placeholder:s}),y.jsxs(_b,{children:[y.jsx(Db,{children:u}),y.jsx(Lb,{children:n.map(m=>y.jsxs(zb,{value:m.value,onSelect:g=>{l(g===a?"":g),h(!1)},className:"transition-all-ease hover:bg-accent hover:text-accent-foreground",children:[y.jsx(K0,{className:ft("mr-2 h-4 w-4 transition-opacity",a===m.value?"opacity-100":"opacity-0")}),m.label]},m.value))})]})]})})]})}const fT=v.forwardRef(({options:n,value:a,onChange:l,onEnter:i,searchPlaceholder:s="Search...",emptyPlaceholder:u="No options found.",inputPlaceholder:f="Type or select..."},h)=>{const[p,m]=v.useState(!1),[g,x]=v.useState(a||""),S=v.useRef(null);v.useImperativeHandle(h,()=>S.current),v.useEffect(()=>{x(a||"")},[a]);const w=O=>{const z=O.target.value;x(z),l(z)},C=O=>{O.key==="Enter"&&g.trim()&&i&&(i(g.trim()),x(""))},R=O=>{x(O),l(O),i&&(i(O),x("")),m(!1)},T=()=>g;return v.useImperativeHandle(h,()=>({...S.current,value:g,getCurrentValue:T,clearInput:()=>{x(""),l("")}})),y.jsxs("div",{className:"relative",children:[y.jsx(Rt,{ref:S,value:g,onChange:w,onKeyDown:C,placeholder:f,className:"pr-10"}),y.jsxs(gh,{open:p,onOpenChange:m,children:[y.jsx(vh,{asChild:!0,children:y.jsx(He,{variant:"ghost",size:"sm",className:"absolute right-0 top-0 h-full px-3 py-2 hover:bg-transparent",children:y.jsx(G0,{className:"h-4 w-4 opacity-50"})})}),y.jsx(yh,{className:"w-[--radix-popover-trigger-width] p-0 animate-fade-in",children:y.jsxs(jb,{children:[y.jsx(Mb,{placeholder:s}),y.jsxs(_b,{children:[y.jsx(Db,{children:u}),y.jsx(Lb,{children:n.map(O=>y.jsxs(zb,{value:O.value,onSelect:()=>R(O.value),className:"transition-all-ease hover:bg-accent hover:text-accent-foreground",children:[y.jsx(K0,{className:ft("mr-2 h-4 w-4 transition-opacity",a===O.value?"opacity-100":"opacity-0")}),O.label]},O.value))})]})]})})]})]})});function dT(){const{t:n}=$r(),{config:a,setConfig:l}=Il(),[i,s]=v.useState(null),[u,f]=v.useState(null),[h,p]=v.useState({}),[m,g]=v.useState({}),[x,S]=v.useState({}),[w,C]=v.useState([]),[R,T]=v.useState(null),[O,z]=v.useState(!1),[k,H]=v.useState([]),[P,A]=v.useState({}),[G,J]=v.useState(null),[re,ie]=v.useState(null),Oe=v.useRef(null);if(v.useEffect(()=>{(async()=>{try{const te=await fetch("https://pub-0dc3e1677e894f07bbea11b17a29e032.r2.dev/providers.json");if(te.ok){const se=await te.json();H(se||[])}else console.error("Failed to fetch provider templates")}catch(te){console.error("Failed to fetch provider templates:",te)}})()},[]),v.useEffect(()=>{(async()=>{try{const te=await Zt.get("/transformers");C(te.transformers)}catch(te){console.error("Failed to fetch transformers:",te)}})()},[]),!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("providers.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading providers configuration..."})})]});const Ee=Array.isArray(a.Providers)?a.Providers:[],me=()=>{const ae={name:"",api_base_url:"",api_key:"",models:[]};s(a.Providers.length),T(ae),z(!0),A(te=>({...te,[a.Providers.length]:!1})),J(null),ie(null)},he=ae=>{const te=a.Providers[ae];s(ae),T(JSON.parse(JSON.stringify(te))),z(!1),A(se=>({...se,[ae]:!1})),J(null),ie(null)},fe=()=>{if(!R)return;if(!R.name||R.name.trim()===""){ie(n("providers.name_required"));return}const ae=R.name.trim();if(a.Providers.some((se,ue)=>!O&&ue===i?!1:se.name.toLowerCase()===ae.toLowerCase())){ie(n("providers.name_duplicate"));return}if(!R.api_key||R.api_key.trim()===""){J(n("providers.api_key_required"));return}if(J(null),ie(null),i!==null&&R){const se=[...a.Providers];O?se.push(R):se[i]=R,l({...a,Providers:se})}i!==null&&A(se=>{const ue={...se};return delete ue[i],ue}),s(null),T(null),z(!1)},_=()=>{i!==null&&(p(ae=>{const te={...ae};return delete te[i],te}),A(ae=>{const te={...ae};return delete te[i],te})),s(null),T(null),z(!1),J(null),ie(null)},Z=ae=>{const te=[...a.Providers];te.splice(ae,1),l({...a,Providers:te}),f(null)},$=(ae,te,se)=>{if(R){const ue={...R,[te]:se};T(ue)}},pe=(ae,te)=>{if(!te||!R)return;const se={...R};se.transformer||(se.transformer={use:[]}),se.transformer.use=[...se.transformer.use,te],T(se)},N=(ae,te)=>{if(!R)return;const se={...R};if(se.transformer){const ue=[...se.transformer.use];ue.splice(te,1),se.transformer.use=ue,ue.length===0&&Object.keys(se.transformer).length===1&&delete se.transformer}T(se)},Y=(ae,te,se)=>{if(!se||!R)return;const ue={...R};ue.transformer||(ue.transformer={use:[]}),ue.transformer[te]||(ue.transformer[te]={use:[]}),ue.transformer[te].use=[...ue.transformer[te].use,se],T(ue)},L=(ae,te,se)=>{if(!R)return;const ue={...R};if(ue.transformer&&ue.transformer[te]){const Ne=[...ue.transformer[te].use];Ne.splice(se,1),ue.transformer[te].use=Ne,Ne.length===0&&Object.keys(ue.transformer[te]).length===1&&delete ue.transformer[te]}T(ue)},K=(ae,te,se,ue)=>{if(!R)return;const Ne={...R};if(Ne.transformer||(Ne.transformer={use:[]}),Ne.transformer.use&&Ne.transformer.use.length>te){const Ue=Ne.transformer.use[te];if(Array.isArray(Ue)){const Me=[...Ue];if(Me.length>1&&typeof Me[1]=="object"&&Me[1]!==null){const Cn={...Me[1],[se]:ue};Me[1]=Cn}else if(Me.length>1){const ot={[se]:ue};Me.splice(1,Me.length-1,ot)}else{const ot={[se]:ue};Me.push(ot)}Ne.transformer.use[te]=Me}else{const Me={[se]:ue};Ne.transformer.use[te]=[Ue,Me]}}T(Ne)},W=(ae,te,se)=>{if(!R)return;const ue={...R};if(!ue.transformer?.use||ue.transformer.use.length<=te)return;const Ne=ue.transformer.use[te];if(Array.isArray(Ne)&&Ne.length>1){const Ue=[...Ne];if(typeof Ue[1]=="object"&&Ue[1]!==null){const Me={...Ue[1]};delete Me[se],Object.keys(Me).length===0?Ue.splice(1,1):Ue[1]=Me,ue.transformer.use[te]=Ue,T(ue)}}},oe=(ae,te,se,ue,Ne)=>{if(!R)return;const Ue={...R};if(Ue.transformer||(Ue.transformer={use:[]}),Ue.transformer[te]||(Ue.transformer[te]={use:[]}),Ue.transformer[te].use&&Ue.transformer[te].use.length>se){const Me=Ue.transformer[te].use[se];if(Array.isArray(Me)){const ot=[...Me];if(ot.length>1&&typeof ot[1]=="object"&&ot[1]!==null){const qr={...ot[1],[ue]:Ne};ot[1]=qr}else if(ot.length>1){const Cn={[ue]:Ne};ot.splice(1,ot.length-1,Cn)}else{const Cn={[ue]:Ne};ot.push(Cn)}Ue.transformer[te].use[se]=ot}else{const ot={[ue]:Ne};Ue.transformer[te].use[se]=[Me,ot]}}T(Ue)},de=(ae,te,se,ue)=>{if(!R)return;const Ne={...R};if(!Ne.transformer?.[te]?.use||Ne.transformer[te].use.length<=se)return;const Ue=Ne.transformer[te].use[se];if(Array.isArray(Ue)&&Ue.length>1){const Me=[...Ue];if(typeof Me[1]=="object"&&Me[1]!==null){const ot={...Me[1]};delete ot[ue],Object.keys(ot).length===0?Me.splice(1,1):Me[1]=ot,Ne.transformer[te].use[se]=Me,T(Ne)}}},ge=(ae,te)=>{if(!te.trim()||!R)return;const se={...R},ue=Array.isArray(se.models)?[...se.models]:[];ue.includes(te.trim())||(ue.push(te.trim()),se.models=ue,T(se))},ze=ae=>{if(ae)try{const te=JSON.parse(ae);if(te){const se=R?.name,ue=JSON.parse(JSON.stringify(te));!O&&se&&(ue.name=se),T(ue)}}catch(te){console.error("Failed to parse template",te)}},Ze=(ae,te)=>{if(!R)return;const se={...R},ue=Array.isArray(se.models)?[...se.models]:[];te>=0&&te<ue.length&&(ue.splice(te,1),se.models=ue,T(se))},je=R||(i!==null?Ee[i]:null);return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsxs(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:[y.jsxs(ba,{className:"text-lg",children:[n("providers.title")," ",y.jsxs("span",{className:"text-sm font-normal text-gray-500",children:["(",Ee.length,")"]})]}),y.jsx(He,{onClick:me,children:n("providers.add")})]}),y.jsx(xa,{className:"flex-grow overflow-y-auto p-4",children:y.jsx(lA,{providers:Ee,onEdit:he,onRemove:f})}),y.jsx(mo,{open:i!==null,onOpenChange:ae=>{ae||_()},children:y.jsxs(ql,{className:"max-h-[80vh] flex flex-col sm:max-w-2xl",children:[y.jsx(Yl,{children:y.jsx(Kl,{children:n("providers.edit")})}),je&&i!==null&&y.jsxs("div",{className:"space-y-4 p-4 overflow-y-auto flex-grow",children:[k.length>0&&y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.import_from_template")}),y.jsx(Wa,{options:k.map(ae=>({label:ae.name,value:JSON.stringify(ae)})),value:"",onChange:ze,placeholder:n("providers.select_template"),emptyPlaceholder:n("providers.no_templates_found")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"name",children:n("providers.name")}),y.jsx(Rt,{id:"name",value:je.name||"",onChange:ae=>{$(i,"name",ae.target.value),re&&ie(null)},className:re?"border-red-500":""}),re&&y.jsx("p",{className:"text-sm text-red-500",children:re})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"api_base_url",children:n("providers.api_base_url")}),y.jsx(Rt,{id:"api_base_url",value:je.api_base_url||"",onChange:ae=>$(i,"api_base_url",ae.target.value)})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"api_key",children:n("providers.api_key")}),y.jsxs("div",{className:"relative",children:[y.jsx(Rt,{id:"api_key",type:P[i||0]?"text":"password",value:je.api_key||"",onChange:ae=>$(i,"api_key",ae.target.value),className:G?"border-red-500":""}),y.jsx(He,{type:"button",variant:"ghost",size:"icon",className:"absolute right-2 top-1/2 transform -translate-y-1/2 h-8 w-8",onClick:()=>{const ae=i||0;A(te=>({...te,[ae]:!te[ae]}))},children:P[i||0]?y.jsx(G2,{className:"h-4 w-4"}):y.jsx(X2,{className:"h-4 w-4"})})]}),G&&y.jsx("p",{className:"text-sm text-red-500",children:G})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"models",children:n("providers.models")}),y.jsxs("div",{className:"space-y-2",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("div",{className:"flex-1",children:h[i]?y.jsx(fT,{ref:Oe,options:(je.models||[]).map(ae=>({label:ae,value:ae})),value:"",onChange:()=>{},onEnter:ae=>{i!==null&&ge(i,ae)},inputPlaceholder:n("providers.models_placeholder")}):y.jsx(Rt,{id:"models",placeholder:n("providers.models_placeholder"),onKeyDown:ae=>{ae.key==="Enter"&&ae.currentTarget.value.trim()&&i!==null&&(ge(i,ae.currentTarget.value),ae.currentTarget.value="")}})}),y.jsx(He,{onClick:()=>{if(h[i]&&Oe.current){const ae=Oe.current,te=ae.getCurrentValue();te&&te.trim()&&i!==null&&(ge(i,te.trim()),ae.clearInput())}else{const ae=document.getElementById("models");ae&&ae.value.trim()&&i!==null&&(ge(i,ae.value),ae.value="")}},children:n("providers.add_model")})]}),y.jsx("div",{className:"flex flex-wrap gap-2 pt-2",children:(je.models||[]).map((ae,te)=>y.jsxs(Sb,{variant:"outline",className:"font-normal flex items-center gap-1",children:[ae,y.jsx("button",{type:"button",className:"ml-1 rounded-full hover:bg-gray-200",onClick:()=>i!==null&&Ze(i,te),children:y.jsx(Bl,{className:"h-3 w-3"})})]},te))})]})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.provider_transformer")}),y.jsx("div",{className:"flex gap-2",children:y.jsx(Wa,{options:w.map(ae=>({label:ae.name,value:ae.name})),value:"",onChange:ae=>{i!==null&&pe(i,ae)},placeholder:n("providers.select_transformer"),emptyPlaceholder:n("providers.no_transformers")})}),je.transformer?.use&&je.transformer.use.length>0&&y.jsxs("div",{className:"space-y-2 mt-2",children:[y.jsx("div",{className:"text-sm font-medium text-gray-700",children:n("providers.selected_transformers")}),je.transformer.use.map((ae,te)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsxs("div",{className:"flex gap-2 items-center mb-2",children:[y.jsx("div",{className:"flex-1 bg-gray-50 rounded p-2 text-sm",children:typeof ae=="string"?ae:Array.isArray(ae)?String(ae[0]):String(ae)}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{i!==null&&N(i,te)},children:y.jsx(Pr,{className:"h-4 w-4"})})]}),y.jsxs("div",{className:"mt-2 pl-4 border-l-2 border-gray-200",children:[y.jsx(ct,{className:"text-sm",children:n("providers.transformer_parameters")}),y.jsxs("div",{className:"space-y-2 mt-1",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx(Rt,{placeholder:n("providers.parameter_name"),value:m[`provider-${i}-transformer-${te}`]?.name||"",onChange:se=>{const ue=`provider-${i}-transformer-${te}`;g(Ne=>({...Ne,[ue]:{...Ne[ue]||{name:"",value:""},name:se.target.value}}))}}),y.jsx(Rt,{placeholder:n("providers.parameter_value"),value:m[`provider-${i}-transformer-${te}`]?.value||"",onChange:se=>{const ue=`provider-${i}-transformer-${te}`;g(Ne=>({...Ne,[ue]:{...Ne[ue]||{name:"",value:""},value:se.target.value}}))}}),y.jsx(He,{size:"sm",onClick:()=>{if(i!==null){const se=`provider-${i}-transformer-${te}`,ue=m[se];ue&&ue.name&&ue.value&&(K(i,te,ue.name,ue.value),g(Ne=>({...Ne,[se]:{name:"",value:""}})))}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),(()=>{if(!je.transformer?.use||je.transformer.use.length<=te)return null;const se=je.transformer.use[te];let ue={};return Array.isArray(se)&&se.length>1&&typeof se[1]=="object"&&se[1]!==null&&(ue=se[1]),Object.keys(ue).length>0?y.jsx("div",{className:"space-y-1",children:Object.entries(ue).map(([Ne,Ue])=>y.jsxs("div",{className:"flex items-center justify-between bg-gray-50 rounded p-2",children:[y.jsxs("div",{className:"text-sm",children:[y.jsxs("span",{className:"font-medium",children:[Ne,":"]})," ",String(Ue)]}),y.jsx(He,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>{i!==null&&W(i,te,Ne)},children:y.jsx(Bl,{className:"h-3 w-3"})})]},Ne))}):null})()]})]})]},te))]})]}),je.models&&je.models.length>0&&y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.model_transformers")}),y.jsx("div",{className:"space-y-3",children:(je.models||[]).map((ae,te)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsx("div",{className:"font-medium text-sm mb-2",children:ae}),y.jsx("div",{className:"flex gap-2",children:y.jsx("div",{className:"flex-1 flex gap-2",children:y.jsx(Wa,{options:w.map(se=>({label:se.name,value:se.name})),value:"",onChange:se=>{i!==null&&Y(i,ae,se)},placeholder:n("providers.select_transformer"),emptyPlaceholder:n("providers.no_transformers")})})}),je.transformer?.[ae]?.use&&je.transformer[ae].use.length>0&&y.jsxs("div",{className:"space-y-2 mt-2",children:[y.jsx("div",{className:"text-sm font-medium text-gray-700",children:n("providers.selected_transformers")}),je.transformer[ae].use.map((se,ue)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsxs("div",{className:"flex gap-2 items-center mb-2",children:[y.jsx("div",{className:"flex-1 bg-gray-50 rounded p-2 text-sm",children:typeof se=="string"?se:Array.isArray(se)?String(se[0]):String(se)}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{i!==null&&L(i,ae,ue)},children:y.jsx(Pr,{className:"h-4 w-4"})})]}),y.jsxs("div",{className:"mt-2 pl-4 border-l-2 border-gray-200",children:[y.jsx(ct,{className:"text-sm",children:n("providers.transformer_parameters")}),y.jsxs("div",{className:"space-y-2 mt-1",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx(Rt,{placeholder:n("providers.parameter_name"),value:x[`model-${i}-${ae}-transformer-${ue}`]?.name||"",onChange:Ne=>{const Ue=`model-${i}-${ae}-transformer-${ue}`;S(Me=>({...Me,[Ue]:{...Me[Ue]||{name:"",value:""},name:Ne.target.value}}))}}),y.jsx(Rt,{placeholder:n("providers.parameter_value"),value:x[`model-${i}-${ae}-transformer-${ue}`]?.value||"",onChange:Ne=>{const Ue=`model-${i}-${ae}-transformer-${ue}`;S(Me=>({...Me,[Ue]:{...Me[Ue]||{name:"",value:""},value:Ne.target.value}}))}}),y.jsx(He,{size:"sm",onClick:()=>{if(i!==null){const Ne=`model-${i}-${ae}-transformer-${ue}`,Ue=x[Ne];Ue&&Ue.name&&Ue.value&&(oe(i,ae,ue,Ue.name,Ue.value),S(Me=>({...Me,[Ne]:{name:"",value:""}})))}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),(()=>{if(!je.transformer?.[ae]?.use||je.transformer[ae].use.length<=ue)return null;const Ne=je.transformer[ae].use[ue];let Ue={};return Array.isArray(Ne)&&Ne.length>1&&typeof Ne[1]=="object"&&Ne[1]!==null&&(Ue=Ne[1]),Object.keys(Ue).length>0?y.jsx("div",{className:"space-y-1",children:Object.entries(Ue).map(([Me,ot])=>y.jsxs("div",{className:"flex items-center justify-between bg-gray-50 rounded p-2",children:[y.jsxs("div",{className:"text-sm",children:[y.jsxs("span",{className:"font-medium",children:[Me,":"]})," ",String(ot)]}),y.jsx(He,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>{i!==null&&de(i,ae,ue,Me)},children:y.jsx(Bl,{className:"h-3 w-3"})})]},Me))}):null})()]})]})]},ue))]})]},te))})]})]}),y.jsx("div",{className:"space-y-3 mt-auto",children:y.jsx("div",{className:"flex justify-end gap-2",children:y.jsx(He,{onClick:fe,children:n("app.save")})})})]})}),y.jsx(mo,{open:u!==null,onOpenChange:()=>f(null),children:y.jsxs(ql,{children:[y.jsxs(Yl,{children:[y.jsx(Kl,{children:n("providers.delete")}),y.jsx(ah,{children:n("providers.delete_provider_confirm")})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:()=>f(null),children:n("providers.cancel")}),y.jsx(He,{variant:"destructive",onClick:()=>u!==null&&Z(u),children:n("providers.delete")})]})]})})]})}function hT(){const{t:n}=$r(),{config:a,setConfig:l}=Il();if(!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("router.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading router configuration..."})})]});const i=a.Router||{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""},s=(h,p)=>{const g={...a.Router||{},[h]:p};l({...a,Router:g})},f=(Array.isArray(a.Providers)?a.Providers:[]).flatMap(h=>{if(!h)return[];const p=Array.isArray(h.models)?h.models:[],m=h.name||"Unknown Provider";return p.map(g=>({value:`${m},${g||"Unknown Model"}`,label:`${m}, ${g||"Unknown Model"}`}))});return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("router.title")})}),y.jsxs(xa,{className:"flex-grow space-y-5 overflow-y-auto p-4",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.default")}),y.jsx(Wa,{options:f,value:i.default||"",onChange:h=>s("default",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.background")}),y.jsx(Wa,{options:f,value:i.background||"",onChange:h=>s("background",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.think")}),y.jsx(Wa,{options:f,value:i.think||"",onChange:h=>s("think",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsx("div",{className:"space-y-2",children:y.jsxs("div",{className:"flex items-center gap-4",children:[y.jsxs("div",{className:"flex-1",children:[y.jsx(ct,{children:n("router.longContext")}),y.jsx(Wa,{options:f,value:i.longContext||"",onChange:h=>s("longContext",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"w-48",children:[y.jsx(ct,{children:n("router.longContextThreshold")}),y.jsx(Rt,{type:"number",value:i.longContextThreshold||6e4,onChange:h=>s("longContextThreshold",parseInt(h.target.value)||6e4),placeholder:"60000"})]})]})}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.webSearch")}),y.jsx(Wa,{options:f,value:i.webSearch||"",onChange:h=>s("webSearch",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]})]})]})}function mT(n,a,l){return a in n?Object.defineProperty(n,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):n[a]=l,n}function Cy(n,a){var l=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);a&&(i=i.filter(function(s){return Object.getOwnPropertyDescriptor(n,s).enumerable})),l.push.apply(l,i)}return l}function Oy(n){for(var a=1;a<arguments.length;a++){var l=arguments[a]!=null?arguments[a]:{};a%2?Cy(Object(l),!0).forEach(function(i){mT(n,i,l[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(l)):Cy(Object(l)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(l,i))})}return n}function pT(n,a){if(n==null)return{};var l={},i=Object.keys(n),s,u;for(u=0;u<i.length;u++)s=i[u],!(a.indexOf(s)>=0)&&(l[s]=n[s]);return l}function gT(n,a){if(n==null)return{};var l=pT(n,a),i,s;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);for(s=0;s<u.length;s++)i=u[s],!(a.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(n,i)&&(l[i]=n[i])}return l}function vT(n,a){return yT(n)||bT(n,a)||xT(n,a)||ST()}function yT(n){if(Array.isArray(n))return n}function bT(n,a){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(n)))){var l=[],i=!0,s=!1,u=void 0;try{for(var f=n[Symbol.iterator](),h;!(i=(h=f.next()).done)&&(l.push(h.value),!(a&&l.length===a));i=!0);}catch(p){s=!0,u=p}finally{try{!i&&f.return!=null&&f.return()}finally{if(s)throw u}}return l}}function xT(n,a){if(n){if(typeof n=="string")return Ay(n,a);var l=Object.prototype.toString.call(n).slice(8,-1);if(l==="Object"&&n.constructor&&(l=n.constructor.name),l==="Map"||l==="Set")return Array.from(n);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return Ay(n,a)}}function Ay(n,a){(a==null||a>n.length)&&(a=n.length);for(var l=0,i=new Array(a);l<a;l++)i[l]=n[l];return i}function ST(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
216
|
+
*/const sO=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Bl=Pt("x",sO);function Q0(n){var a,l,i="";if(typeof n=="string"||typeof n=="number")i+=n;else if(typeof n=="object")if(Array.isArray(n)){var s=n.length;for(a=0;a<s;a++)n[a]&&(l=Q0(n[a]))&&(i&&(i+=" "),i+=l)}else for(l in n)n[l]&&(i&&(i+=" "),i+=l);return i}function Z0(){for(var n,a,l=0,i="",s=arguments.length;l<s;l++)(n=arguments[l])&&(a=Q0(n))&&(i&&(i+=" "),i+=a);return i}const nh="-",uO=n=>{const a=fO(n),{conflictingClassGroups:l,conflictingClassGroupModifiers:i}=n;return{getClassGroupId:f=>{const h=f.split(nh);return h[0]===""&&h.length!==1&&h.shift(),J0(h,a)||cO(f)},getConflictingClassGroupIds:(f,h)=>{const p=l[f]||[];return h&&i[f]?[...p,...i[f]]:p}}},J0=(n,a)=>{if(n.length===0)return a.classGroupId;const l=n[0],i=a.nextPart.get(l),s=i?J0(n.slice(1),i):void 0;if(s)return s;if(a.validators.length===0)return;const u=n.join(nh);return a.validators.find(({validator:f})=>f(u))?.classGroupId},iy=/^\[(.+)\]$/,cO=n=>{if(iy.test(n)){const a=iy.exec(n)[1],l=a?.substring(0,a.indexOf(":"));if(l)return"arbitrary.."+l}},fO=n=>{const{theme:a,classGroups:l}=n,i={nextPart:new Map,validators:[]};for(const s in l)Td(l[s],i,s,a);return i},Td=(n,a,l,i)=>{n.forEach(s=>{if(typeof s=="string"){const u=s===""?a:oy(a,s);u.classGroupId=l;return}if(typeof s=="function"){if(dO(s)){Td(s(i),a,l,i);return}a.validators.push({validator:s,classGroupId:l});return}Object.entries(s).forEach(([u,f])=>{Td(f,oy(a,u),l,i)})})},oy=(n,a)=>{let l=n;return a.split(nh).forEach(i=>{l.nextPart.has(i)||l.nextPart.set(i,{nextPart:new Map,validators:[]}),l=l.nextPart.get(i)}),l},dO=n=>n.isThemeGetter,hO=n=>{if(n<1)return{get:()=>{},set:()=>{}};let a=0,l=new Map,i=new Map;const s=(u,f)=>{l.set(u,f),a++,a>n&&(a=0,i=l,l=new Map)};return{get(u){let f=l.get(u);if(f!==void 0)return f;if((f=i.get(u))!==void 0)return s(u,f),f},set(u,f){l.has(u)?l.set(u,f):s(u,f)}}},jd="!",Md=":",mO=Md.length,pO=n=>{const{prefix:a,experimentalParseClassName:l}=n;let i=s=>{const u=[];let f=0,h=0,p=0,m;for(let C=0;C<s.length;C++){let R=s[C];if(f===0&&h===0){if(R===Md){u.push(s.slice(p,C)),p=C+mO;continue}if(R==="/"){m=C;continue}}R==="["?f++:R==="]"?f--:R==="("?h++:R===")"&&h--}const g=u.length===0?s:s.substring(p),x=gO(g),S=x!==g,w=m&&m>p?m-p:void 0;return{modifiers:u,hasImportantModifier:S,baseClassName:x,maybePostfixModifierPosition:w}};if(a){const s=a+Md,u=i;i=f=>f.startsWith(s)?u(f.substring(s.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:f,maybePostfixModifierPosition:void 0}}if(l){const s=i;i=u=>l({className:u,parseClassName:s})}return i},gO=n=>n.endsWith(jd)?n.substring(0,n.length-1):n.startsWith(jd)?n.substring(1):n,vO=n=>{const a=Object.fromEntries(n.orderSensitiveModifiers.map(i=>[i,!0]));return i=>{if(i.length<=1)return i;const s=[];let u=[];return i.forEach(f=>{f[0]==="["||a[f]?(s.push(...u.sort(),f),u=[]):u.push(f)}),s.push(...u.sort()),s}},yO=n=>({cache:hO(n.cacheSize),parseClassName:pO(n),sortModifiers:vO(n),...uO(n)}),bO=/\s+/,xO=(n,a)=>{const{parseClassName:l,getClassGroupId:i,getConflictingClassGroupIds:s,sortModifiers:u}=a,f=[],h=n.trim().split(bO);let p="";for(let m=h.length-1;m>=0;m-=1){const g=h[m],{isExternal:x,modifiers:S,hasImportantModifier:w,baseClassName:C,maybePostfixModifierPosition:R}=l(g);if(x){p=g+(p.length>0?" "+p:p);continue}let T=!!R,O=i(T?C.substring(0,R):C);if(!O){if(!T){p=g+(p.length>0?" "+p:p);continue}if(O=i(C),!O){p=g+(p.length>0?" "+p:p);continue}T=!1}const z=u(S).join(":"),k=w?z+jd:z,H=k+O;if(f.includes(H))continue;f.push(H);const P=s(O,T);for(let A=0;A<P.length;++A){const G=P[A];f.push(k+G)}p=g+(p.length>0?" "+p:p)}return p};function SO(){let n=0,a,l,i="";for(;n<arguments.length;)(a=arguments[n++])&&(l=I0(a))&&(i&&(i+=" "),i+=l);return i}const I0=n=>{if(typeof n=="string")return n;let a,l="";for(let i=0;i<n.length;i++)n[i]&&(a=I0(n[i]))&&(l&&(l+=" "),l+=a);return l};function wO(n,...a){let l,i,s,u=f;function f(p){const m=a.reduce((g,x)=>x(g),n());return l=yO(m),i=l.cache.get,s=l.cache.set,u=h,h(p)}function h(p){const m=i(p);if(m)return m;const g=xO(p,l);return s(p,g),g}return function(){return u(SO.apply(null,arguments))}}const jt=n=>{const a=l=>l[n]||[];return a.isThemeGetter=!0,a},W0=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,eb=/^\((?:(\w[\w-]*):)?(.+)\)$/i,EO=/^\d+\/\d+$/,RO=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,CO=/\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$/,OO=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,AO=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,NO=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Dl=n=>EO.test(n),Ye=n=>!!n&&!Number.isNaN(Number(n)),Qa=n=>!!n&&Number.isInteger(Number(n)),id=n=>n.endsWith("%")&&Ye(n.slice(0,-1)),ga=n=>RO.test(n),TO=()=>!0,jO=n=>CO.test(n)&&!OO.test(n),tb=()=>!1,MO=n=>AO.test(n),_O=n=>NO.test(n),DO=n=>!ye(n)&&!be(n),LO=n=>Zl(n,rb,tb),ye=n=>W0.test(n),Mr=n=>Zl(n,lb,jO),od=n=>Zl(n,HO,Ye),sy=n=>Zl(n,nb,tb),zO=n=>Zl(n,ab,_O),Xs=n=>Zl(n,ib,MO),be=n=>eb.test(n),ao=n=>Jl(n,lb),kO=n=>Jl(n,BO),uy=n=>Jl(n,nb),UO=n=>Jl(n,rb),PO=n=>Jl(n,ab),Qs=n=>Jl(n,ib,!0),Zl=(n,a,l)=>{const i=W0.exec(n);return i?i[1]?a(i[1]):l(i[2]):!1},Jl=(n,a,l=!1)=>{const i=eb.exec(n);return i?i[1]?a(i[1]):l:!1},nb=n=>n==="position"||n==="percentage",ab=n=>n==="image"||n==="url",rb=n=>n==="length"||n==="size"||n==="bg-size",lb=n=>n==="length",HO=n=>n==="number",BO=n=>n==="family-name",ib=n=>n==="shadow",$O=()=>{const n=jt("color"),a=jt("font"),l=jt("text"),i=jt("font-weight"),s=jt("tracking"),u=jt("leading"),f=jt("breakpoint"),h=jt("container"),p=jt("spacing"),m=jt("radius"),g=jt("shadow"),x=jt("inset-shadow"),S=jt("text-shadow"),w=jt("drop-shadow"),C=jt("blur"),R=jt("perspective"),T=jt("aspect"),O=jt("ease"),z=jt("animate"),k=()=>["auto","avoid","all","avoid-page","page","left","right","column"],H=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],P=()=>[...H(),be,ye],A=()=>["auto","hidden","clip","visible","scroll"],G=()=>["auto","contain","none"],J=()=>[be,ye,p],re=()=>[Dl,"full","auto",...J()],ie=()=>[Qa,"none","subgrid",be,ye],Oe=()=>["auto",{span:["full",Qa,be,ye]},Qa,be,ye],Ee=()=>[Qa,"auto",be,ye],me=()=>["auto","min","max","fr",be,ye],he=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],fe=()=>["start","end","center","stretch","center-safe","end-safe"],_=()=>["auto",...J()],Z=()=>[Dl,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...J()],$=()=>[n,be,ye],pe=()=>[...H(),uy,sy,{position:[be,ye]}],N=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Y=()=>["auto","cover","contain",UO,LO,{size:[be,ye]}],L=()=>[id,ao,Mr],K=()=>["","none","full",m,be,ye],W=()=>["",Ye,ao,Mr],oe=()=>["solid","dashed","dotted","double"],de=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],ge=()=>[Ye,id,uy,sy],ze=()=>["","none",C,be,ye],Ze=()=>["none",Ye,be,ye],je=()=>["none",Ye,be,ye],ae=()=>[Ye,be,ye],te=()=>[Dl,"full",...J()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ga],breakpoint:[ga],color:[TO],container:[ga],"drop-shadow":[ga],ease:["in","out","in-out"],font:[DO],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ga],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ga],shadow:[ga],spacing:["px",Ye],text:[ga],"text-shadow":[ga],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Dl,ye,be,T]}],container:["container"],columns:[{columns:[Ye,ye,be,h]}],"break-after":[{"break-after":k()}],"break-before":[{"break-before":k()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:P()}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:G()}],"overscroll-x":[{"overscroll-x":G()}],"overscroll-y":[{"overscroll-y":G()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:re()}],"inset-x":[{"inset-x":re()}],"inset-y":[{"inset-y":re()}],start:[{start:re()}],end:[{end:re()}],top:[{top:re()}],right:[{right:re()}],bottom:[{bottom:re()}],left:[{left:re()}],visibility:["visible","invisible","collapse"],z:[{z:[Qa,"auto",be,ye]}],basis:[{basis:[Dl,"full","auto",h,...J()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Ye,Dl,"auto","initial","none",ye]}],grow:[{grow:["",Ye,be,ye]}],shrink:[{shrink:["",Ye,be,ye]}],order:[{order:[Qa,"first","last","none",be,ye]}],"grid-cols":[{"grid-cols":ie()}],"col-start-end":[{col:Oe()}],"col-start":[{"col-start":Ee()}],"col-end":[{"col-end":Ee()}],"grid-rows":[{"grid-rows":ie()}],"row-start-end":[{row:Oe()}],"row-start":[{"row-start":Ee()}],"row-end":[{"row-end":Ee()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":me()}],"auto-rows":[{"auto-rows":me()}],gap:[{gap:J()}],"gap-x":[{"gap-x":J()}],"gap-y":[{"gap-y":J()}],"justify-content":[{justify:[...he(),"normal"]}],"justify-items":[{"justify-items":[...fe(),"normal"]}],"justify-self":[{"justify-self":["auto",...fe()]}],"align-content":[{content:["normal",...he()]}],"align-items":[{items:[...fe(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...fe(),{baseline:["","last"]}]}],"place-content":[{"place-content":he()}],"place-items":[{"place-items":[...fe(),"baseline"]}],"place-self":[{"place-self":["auto",...fe()]}],p:[{p:J()}],px:[{px:J()}],py:[{py:J()}],ps:[{ps:J()}],pe:[{pe:J()}],pt:[{pt:J()}],pr:[{pr:J()}],pb:[{pb:J()}],pl:[{pl:J()}],m:[{m:_()}],mx:[{mx:_()}],my:[{my:_()}],ms:[{ms:_()}],me:[{me:_()}],mt:[{mt:_()}],mr:[{mr:_()}],mb:[{mb:_()}],ml:[{ml:_()}],"space-x":[{"space-x":J()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":J()}],"space-y-reverse":["space-y-reverse"],size:[{size:Z()}],w:[{w:[h,"screen",...Z()]}],"min-w":[{"min-w":[h,"screen","none",...Z()]}],"max-w":[{"max-w":[h,"screen","none","prose",{screen:[f]},...Z()]}],h:[{h:["screen","lh",...Z()]}],"min-h":[{"min-h":["screen","lh","none",...Z()]}],"max-h":[{"max-h":["screen","lh",...Z()]}],"font-size":[{text:["base",l,ao,Mr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[i,be,od]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",id,ye]}],"font-family":[{font:[kO,ye,a]}],"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:[s,be,ye]}],"line-clamp":[{"line-clamp":[Ye,"none",be,od]}],leading:[{leading:[u,...J()]}],"list-image":[{"list-image":["none",be,ye]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",be,ye]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:$()}],"text-color":[{text:$()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...oe(),"wavy"]}],"text-decoration-thickness":[{decoration:[Ye,"from-font","auto",be,Mr]}],"text-decoration-color":[{decoration:$()}],"underline-offset":[{"underline-offset":[Ye,"auto",be,ye]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:J()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",be,ye]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",be,ye]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:pe()}],"bg-repeat":[{bg:N()}],"bg-size":[{bg:Y()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Qa,be,ye],radial:["",be,ye],conic:[Qa,be,ye]},PO,zO]}],"bg-color":[{bg:$()}],"gradient-from-pos":[{from:L()}],"gradient-via-pos":[{via:L()}],"gradient-to-pos":[{to:L()}],"gradient-from":[{from:$()}],"gradient-via":[{via:$()}],"gradient-to":[{to:$()}],rounded:[{rounded:K()}],"rounded-s":[{"rounded-s":K()}],"rounded-e":[{"rounded-e":K()}],"rounded-t":[{"rounded-t":K()}],"rounded-r":[{"rounded-r":K()}],"rounded-b":[{"rounded-b":K()}],"rounded-l":[{"rounded-l":K()}],"rounded-ss":[{"rounded-ss":K()}],"rounded-se":[{"rounded-se":K()}],"rounded-ee":[{"rounded-ee":K()}],"rounded-es":[{"rounded-es":K()}],"rounded-tl":[{"rounded-tl":K()}],"rounded-tr":[{"rounded-tr":K()}],"rounded-br":[{"rounded-br":K()}],"rounded-bl":[{"rounded-bl":K()}],"border-w":[{border:W()}],"border-w-x":[{"border-x":W()}],"border-w-y":[{"border-y":W()}],"border-w-s":[{"border-s":W()}],"border-w-e":[{"border-e":W()}],"border-w-t":[{"border-t":W()}],"border-w-r":[{"border-r":W()}],"border-w-b":[{"border-b":W()}],"border-w-l":[{"border-l":W()}],"divide-x":[{"divide-x":W()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":W()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...oe(),"hidden","none"]}],"divide-style":[{divide:[...oe(),"hidden","none"]}],"border-color":[{border:$()}],"border-color-x":[{"border-x":$()}],"border-color-y":[{"border-y":$()}],"border-color-s":[{"border-s":$()}],"border-color-e":[{"border-e":$()}],"border-color-t":[{"border-t":$()}],"border-color-r":[{"border-r":$()}],"border-color-b":[{"border-b":$()}],"border-color-l":[{"border-l":$()}],"divide-color":[{divide:$()}],"outline-style":[{outline:[...oe(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Ye,be,ye]}],"outline-w":[{outline:["",Ye,ao,Mr]}],"outline-color":[{outline:$()}],shadow:[{shadow:["","none",g,Qs,Xs]}],"shadow-color":[{shadow:$()}],"inset-shadow":[{"inset-shadow":["none",x,Qs,Xs]}],"inset-shadow-color":[{"inset-shadow":$()}],"ring-w":[{ring:W()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:$()}],"ring-offset-w":[{"ring-offset":[Ye,Mr]}],"ring-offset-color":[{"ring-offset":$()}],"inset-ring-w":[{"inset-ring":W()}],"inset-ring-color":[{"inset-ring":$()}],"text-shadow":[{"text-shadow":["none",S,Qs,Xs]}],"text-shadow-color":[{"text-shadow":$()}],opacity:[{opacity:[Ye,be,ye]}],"mix-blend":[{"mix-blend":[...de(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":de()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Ye]}],"mask-image-linear-from-pos":[{"mask-linear-from":ge()}],"mask-image-linear-to-pos":[{"mask-linear-to":ge()}],"mask-image-linear-from-color":[{"mask-linear-from":$()}],"mask-image-linear-to-color":[{"mask-linear-to":$()}],"mask-image-t-from-pos":[{"mask-t-from":ge()}],"mask-image-t-to-pos":[{"mask-t-to":ge()}],"mask-image-t-from-color":[{"mask-t-from":$()}],"mask-image-t-to-color":[{"mask-t-to":$()}],"mask-image-r-from-pos":[{"mask-r-from":ge()}],"mask-image-r-to-pos":[{"mask-r-to":ge()}],"mask-image-r-from-color":[{"mask-r-from":$()}],"mask-image-r-to-color":[{"mask-r-to":$()}],"mask-image-b-from-pos":[{"mask-b-from":ge()}],"mask-image-b-to-pos":[{"mask-b-to":ge()}],"mask-image-b-from-color":[{"mask-b-from":$()}],"mask-image-b-to-color":[{"mask-b-to":$()}],"mask-image-l-from-pos":[{"mask-l-from":ge()}],"mask-image-l-to-pos":[{"mask-l-to":ge()}],"mask-image-l-from-color":[{"mask-l-from":$()}],"mask-image-l-to-color":[{"mask-l-to":$()}],"mask-image-x-from-pos":[{"mask-x-from":ge()}],"mask-image-x-to-pos":[{"mask-x-to":ge()}],"mask-image-x-from-color":[{"mask-x-from":$()}],"mask-image-x-to-color":[{"mask-x-to":$()}],"mask-image-y-from-pos":[{"mask-y-from":ge()}],"mask-image-y-to-pos":[{"mask-y-to":ge()}],"mask-image-y-from-color":[{"mask-y-from":$()}],"mask-image-y-to-color":[{"mask-y-to":$()}],"mask-image-radial":[{"mask-radial":[be,ye]}],"mask-image-radial-from-pos":[{"mask-radial-from":ge()}],"mask-image-radial-to-pos":[{"mask-radial-to":ge()}],"mask-image-radial-from-color":[{"mask-radial-from":$()}],"mask-image-radial-to-color":[{"mask-radial-to":$()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":H()}],"mask-image-conic-pos":[{"mask-conic":[Ye]}],"mask-image-conic-from-pos":[{"mask-conic-from":ge()}],"mask-image-conic-to-pos":[{"mask-conic-to":ge()}],"mask-image-conic-from-color":[{"mask-conic-from":$()}],"mask-image-conic-to-color":[{"mask-conic-to":$()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:pe()}],"mask-repeat":[{mask:N()}],"mask-size":[{mask:Y()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",be,ye]}],filter:[{filter:["","none",be,ye]}],blur:[{blur:ze()}],brightness:[{brightness:[Ye,be,ye]}],contrast:[{contrast:[Ye,be,ye]}],"drop-shadow":[{"drop-shadow":["","none",w,Qs,Xs]}],"drop-shadow-color":[{"drop-shadow":$()}],grayscale:[{grayscale:["",Ye,be,ye]}],"hue-rotate":[{"hue-rotate":[Ye,be,ye]}],invert:[{invert:["",Ye,be,ye]}],saturate:[{saturate:[Ye,be,ye]}],sepia:[{sepia:["",Ye,be,ye]}],"backdrop-filter":[{"backdrop-filter":["","none",be,ye]}],"backdrop-blur":[{"backdrop-blur":ze()}],"backdrop-brightness":[{"backdrop-brightness":[Ye,be,ye]}],"backdrop-contrast":[{"backdrop-contrast":[Ye,be,ye]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Ye,be,ye]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Ye,be,ye]}],"backdrop-invert":[{"backdrop-invert":["",Ye,be,ye]}],"backdrop-opacity":[{"backdrop-opacity":[Ye,be,ye]}],"backdrop-saturate":[{"backdrop-saturate":[Ye,be,ye]}],"backdrop-sepia":[{"backdrop-sepia":["",Ye,be,ye]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":J()}],"border-spacing-x":[{"border-spacing-x":J()}],"border-spacing-y":[{"border-spacing-y":J()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",be,ye]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Ye,"initial",be,ye]}],ease:[{ease:["linear","initial",O,be,ye]}],delay:[{delay:[Ye,be,ye]}],animate:[{animate:["none",z,be,ye]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[R,be,ye]}],"perspective-origin":[{"perspective-origin":P()}],rotate:[{rotate:Ze()}],"rotate-x":[{"rotate-x":Ze()}],"rotate-y":[{"rotate-y":Ze()}],"rotate-z":[{"rotate-z":Ze()}],scale:[{scale:je()}],"scale-x":[{"scale-x":je()}],"scale-y":[{"scale-y":je()}],"scale-z":[{"scale-z":je()}],"scale-3d":["scale-3d"],skew:[{skew:ae()}],"skew-x":[{"skew-x":ae()}],"skew-y":[{"skew-y":ae()}],transform:[{transform:[be,ye,"","none","gpu","cpu"]}],"transform-origin":[{origin:P()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:te()}],"translate-x":[{"translate-x":te()}],"translate-y":[{"translate-y":te()}],"translate-z":[{"translate-z":te()}],"translate-none":["translate-none"],accent:[{accent:$()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:$()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",be,ye]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":J()}],"scroll-mx":[{"scroll-mx":J()}],"scroll-my":[{"scroll-my":J()}],"scroll-ms":[{"scroll-ms":J()}],"scroll-me":[{"scroll-me":J()}],"scroll-mt":[{"scroll-mt":J()}],"scroll-mr":[{"scroll-mr":J()}],"scroll-mb":[{"scroll-mb":J()}],"scroll-ml":[{"scroll-ml":J()}],"scroll-p":[{"scroll-p":J()}],"scroll-px":[{"scroll-px":J()}],"scroll-py":[{"scroll-py":J()}],"scroll-ps":[{"scroll-ps":J()}],"scroll-pe":[{"scroll-pe":J()}],"scroll-pt":[{"scroll-pt":J()}],"scroll-pr":[{"scroll-pr":J()}],"scroll-pb":[{"scroll-pb":J()}],"scroll-pl":[{"scroll-pl":J()}],"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",be,ye]}],fill:[{fill:["none",...$()]}],"stroke-w":[{stroke:[Ye,ao,Mr,od]}],stroke:[{stroke:["none",...$()]}],"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-x","border-w-y","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-x","border-color-y","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"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-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"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},VO=wO($O);function ft(...n){return VO(Z0(n))}const mo=B0,qO=$0,ob=v.forwardRef(({className:n,...a},l)=>y.jsx(eh,{ref:l,className:ft("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",n),...a}));ob.displayName=eh.displayName;const ql=v.forwardRef(({className:n,children:a,...l},i)=>y.jsxs(qO,{children:[y.jsx(ob,{}),y.jsxs(th,{ref:i,className:ft("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-300 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 animate-scale-in",n),...l,children:[a,y.jsxs(M2,{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 transition-all-ease hover:scale-110",children:[y.jsx(Bl,{className:"h-4 w-4"}),y.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ql.displayName=th.displayName;const Yl=({className:n,...a})=>y.jsx("div",{className:ft("flex flex-col space-y-1.5 text-center sm:text-left",n),...a});Yl.displayName="DialogHeader";const po=({className:n,...a})=>y.jsx("div",{className:ft("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",n),...a});po.displayName="DialogFooter";const Kl=v.forwardRef(({className:n,...a},l)=>y.jsx(V0,{ref:l,className:ft("text-lg font-semibold leading-none tracking-tight",n),...a}));Kl.displayName=V0.displayName;const ah=v.forwardRef(({className:n,...a},l)=>y.jsx(q0,{ref:l,className:ft("text-sm text-muted-foreground",n),...a}));ah.displayName=q0.displayName;const cy=n=>typeof n=="boolean"?`${n}`:n===0?"0":n,fy=Z0,rh=(n,a)=>l=>{var i;if(a?.variants==null)return fy(n,l?.class,l?.className);const{variants:s,defaultVariants:u}=a,f=Object.keys(s).map(m=>{const g=l?.[m],x=u?.[m];if(g===null)return null;const S=cy(g)||cy(x);return s[m][S]}),h=l&&Object.entries(l).reduce((m,g)=>{let[x,S]=g;return S===void 0||(m[x]=S),m},{}),p=a==null||(i=a.compoundVariants)===null||i===void 0?void 0:i.reduce((m,g)=>{let{class:x,className:S,...w}=g;return Object.entries(w).every(C=>{let[R,T]=C;return Array.isArray(T)?T.includes({...u,...h}[R]):{...u,...h}[R]===T})?[...m,x,S]:m},[]);return fy(n,f,p,l?.class,l?.className)},YO=rh("inline-flex items-center justify-center gap-2 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 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"border border-destructive/50 text-destructive hover:bg-destructive hover:text-destructive-foreground",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"}}),He=v.forwardRef(({className:n,variant:a,size:l,asChild:i=!1,...s},u)=>{const f=i?uC:"button";return y.jsx(f,{className:ft(YO({variant:a,size:l,className:n})),ref:u,...s})});He.displayName="Button";const Rt=v.forwardRef(({className:n,type:a,...l},i)=>y.jsx("input",{type:a,className:ft("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground 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 md:text-sm",n),ref:i,...l}));Rt.displayName="Input";var KO="Label",sb=v.forwardRef((n,a)=>y.jsx(dt.label,{...n,ref:a,onMouseDown:l=>{l.target.closest("button, input, select, textarea")||(n.onMouseDown?.(l),!l.defaultPrevented&&l.detail>1&&l.preventDefault())}}));sb.displayName=KO;var ub=sb;const GO=rh("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),ct=v.forwardRef(({className:n,...a},l)=>y.jsx(ub,{ref:l,className:ft(GO(),n),...a}));ct.displayName=ub.displayName;function FO(n){const a=v.useRef({value:n,previous:n});return v.useMemo(()=>(a.current.value!==n&&(a.current.previous=a.current.value,a.current.value=n),a.current.previous),[n])}function cb(n){const[a,l]=v.useState(void 0);return nr(()=>{if(n){l({width:n.offsetWidth,height:n.offsetHeight});const i=new ResizeObserver(s=>{if(!Array.isArray(s)||!s.length)return;const u=s[0];let f,h;if("borderBoxSize"in u){const p=u.borderBoxSize,m=Array.isArray(p)?p[0]:p;f=m.inlineSize,h=m.blockSize}else f=n.offsetWidth,h=n.offsetHeight;l({width:f,height:h})});return i.observe(n,{box:"border-box"}),()=>i.unobserve(n)}else l(void 0)},[n]),a}var Tu="Switch",[XO,Tj]=Cu(Tu),[QO,ZO]=XO(Tu),fb=v.forwardRef((n,a)=>{const{__scopeSwitch:l,name:i,checked:s,defaultChecked:u,required:f,disabled:h,value:p="on",onCheckedChange:m,form:g,...x}=n,[S,w]=v.useState(null),C=fn(a,k=>w(k)),R=v.useRef(!1),T=S?g||!!S.closest("form"):!0,[O,z]=Gd({prop:s,defaultProp:u??!1,onChange:m,caller:Tu});return y.jsxs(QO,{scope:l,checked:O,disabled:h,children:[y.jsx(dt.button,{type:"button",role:"switch","aria-checked":O,"aria-required":f,"data-state":pb(O),"data-disabled":h?"":void 0,disabled:h,value:p,...x,ref:C,onClick:Zt(n.onClick,k=>{z(H=>!H),T&&(R.current=k.isPropagationStopped(),R.current||k.stopPropagation())})}),T&&y.jsx(mb,{control:S,bubbles:!R.current,name:i,value:p,checked:O,required:f,disabled:h,form:g,style:{transform:"translateX(-100%)"}})]})});fb.displayName=Tu;var db="SwitchThumb",hb=v.forwardRef((n,a)=>{const{__scopeSwitch:l,...i}=n,s=ZO(db,l);return y.jsx(dt.span,{"data-state":pb(s.checked),"data-disabled":s.disabled?"":void 0,...i,ref:a})});hb.displayName=db;var JO="SwitchBubbleInput",mb=v.forwardRef(({__scopeSwitch:n,control:a,checked:l,bubbles:i=!0,...s},u)=>{const f=v.useRef(null),h=fn(f,u),p=FO(l),m=cb(a);return v.useEffect(()=>{const g=f.current;if(!g)return;const x=window.HTMLInputElement.prototype,w=Object.getOwnPropertyDescriptor(x,"checked").set;if(p!==l&&w){const C=new Event("click",{bubbles:i});w.call(g,l),g.dispatchEvent(C)}},[p,l,i]),y.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:l,...s,tabIndex:-1,ref:h,style:{...s.style,...m,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});mb.displayName=JO;function pb(n){return n?"checked":"unchecked"}var gb=fb,IO=hb;const vb=v.forwardRef(({className:n,...a},l)=>y.jsx(gb,{className:ft("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-all-ease focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",n),...a,ref:l,children:y.jsx(IO,{className:ft("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0 transition-all-ease")})}));vb.displayName=gb.displayName;class WO{baseUrl;apiKey;tempApiKey;constructor(a="/api",l=""){this.baseUrl=a,this.apiKey=l||localStorage.getItem("apiKey")||"",this.tempApiKey=new URLSearchParams(window.location.search).get("tempApiKey")}setBaseUrl(a){this.baseUrl=a}setApiKey(a){this.apiKey=a,a?localStorage.setItem("apiKey",a):localStorage.removeItem("apiKey")}setTempApiKey(a){this.tempApiKey=a}createHeaders(a="application/json"){const l={Accept:"application/json"};return this.tempApiKey?l["X-Temp-API-Key"]=this.tempApiKey:this.apiKey&&(l["X-API-Key"]=this.apiKey),a&&(l["Content-Type"]=a),l}async apiFetch(a,l={}){const i=`${this.baseUrl}${a}`,s={...l,headers:{...this.createHeaders(),...l.headers}};try{const u=await fetch(i,s);if(u.status===401)return localStorage.removeItem("apiKey"),window.dispatchEvent(new CustomEvent("unauthorized")),new Promise(()=>{});if(!u.ok)throw new Error(`API request failed: ${u.status} ${u.statusText}`);if(u.status===204)return{};const f=await u.text();return f?JSON.parse(f):{}}catch(u){throw console.error("API request error:",u),u}}async get(a){return this.apiFetch(a,{method:"GET"})}async post(a,l){return this.apiFetch(a,{method:"POST",body:JSON.stringify(l)})}async put(a,l){return this.apiFetch(a,{method:"PUT",body:JSON.stringify(l)})}async delete(a){return this.apiFetch(a,{method:"DELETE"})}async getConfig(){return this.get("/config")}async updateConfig(a){return this.post("/config",a)}async getProviders(){return this.get("/api/providers")}async addProvider(a){return this.post("/api/providers",a)}async updateProvider(a,l){return this.post(`/api/providers/${a}`,l)}async deleteProvider(a){return this.delete(`/api/providers/${a}`)}async getTransformers(){return this.get("/api/transformers")}async addTransformer(a){return this.post("/api/transformers",a)}async updateTransformer(a,l){return this.post(`/api/transformers/${a}`,l)}async deleteTransformer(a){return this.delete(`/api/transformers/${a}`)}async getConfigNew(){return this.get("/config")}async saveConfig(a){return this.post("/config",a)}async restartService(){return this.post("/restart",{})}}const un=new WO,yb=v.createContext(void 0);function Il(){const n=v.useContext(yb);if(n===void 0)throw new Error("useConfig must be used within a ConfigProvider");return n}function eA({children:n}){const[a,l]=v.useState(null),[i,s]=v.useState(null),[u,f]=v.useState(!1),[h,p]=v.useState(localStorage.getItem("apiKey"));return v.useEffect(()=>{const m=()=>{p(localStorage.getItem("apiKey"))};return window.addEventListener("storage",m),()=>{window.removeEventListener("storage",m)}},[]),v.useEffect(()=>{(async()=>{f(!1),l(null),s(null)})()},[h]),v.useEffect(()=>{(async()=>{if(!u){f(!0);try{const g=await un.getConfig(),x={LOG:typeof g.LOG=="boolean"?g.LOG:!1,CLAUDE_PATH:typeof g.CLAUDE_PATH=="string"?g.CLAUDE_PATH:"",HOST:typeof g.HOST=="string"?g.HOST:"127.0.0.1",PORT:typeof g.PORT=="number"?g.PORT:3456,APIKEY:typeof g.APIKEY=="string"?g.APIKEY:"",API_TIMEOUT_MS:typeof g.API_TIMEOUT_MS=="string"?g.API_TIMEOUT_MS:"600000",PROXY_URL:typeof g.PROXY_URL=="string"?g.PROXY_URL:"",transformers:Array.isArray(g.transformers)?g.transformers:[],Providers:Array.isArray(g.Providers)?g.Providers:[],Router:g.Router&&typeof g.Router=="object"?{default:typeof g.Router.default=="string"?g.Router.default:"",background:typeof g.Router.background=="string"?g.Router.background:"",think:typeof g.Router.think=="string"?g.Router.think:"",longContext:typeof g.Router.longContext=="string"?g.Router.longContext:"",longContextThreshold:typeof g.Router.longContextThreshold=="number"?g.Router.longContextThreshold:6e4,webSearch:typeof g.Router.webSearch=="string"?g.Router.webSearch:""}:{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""}};l(x)}catch(g){console.error("Failed to fetch config:",g),g.message!=="Unauthorized"&&(l({LOG:!1,CLAUDE_PATH:"",HOST:"127.0.0.1",PORT:3456,APIKEY:"",API_TIMEOUT_MS:"600000",PROXY_URL:"",transformers:[],Providers:[],Router:{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""}}),s(g))}}})()},[u,h]),y.jsx(yb.Provider,{value:{config:a,setConfig:l,error:i},children:n})}function tA({isOpen:n,onOpenChange:a}){const{t:l}=$r(),{config:i,setConfig:s}=Il();if(!i)return null;const u=h=>{s({...i,LOG:h})},f=h=>{s({...i,CLAUDE_PATH:h.target.value})};return y.jsx(mo,{open:n,onOpenChange:a,children:y.jsxs(ql,{children:[y.jsx(Yl,{children:y.jsx(Kl,{children:l("toplevel.title")})}),y.jsxs("div",{className:"space-y-4 py-4",children:[y.jsxs("div",{className:"flex items-center space-x-2",children:[y.jsx(vb,{id:"log",checked:i.LOG,onCheckedChange:u}),y.jsx(ct,{htmlFor:"log",className:"transition-all-ease hover:scale-[1.02] cursor-pointer",children:l("toplevel.log")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"claude-path",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.claude_path")}),y.jsx(Rt,{id:"claude-path",value:i.CLAUDE_PATH,onChange:f,className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"host",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.host")}),y.jsx(Rt,{id:"host",value:i.HOST,onChange:h=>s({...i,HOST:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"port",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.port")}),y.jsx(Rt,{id:"port",type:"number",value:i.PORT,onChange:h=>s({...i,PORT:parseInt(h.target.value,10)}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"timeout",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.timeout")}),y.jsx(Rt,{id:"timeout",value:i.API_TIMEOUT_MS,onChange:h=>s({...i,API_TIMEOUT_MS:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"proxy-url",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.proxy_url")}),y.jsx(Rt,{id:"proxy-url",value:i.PROXY_URL,onChange:h=>s({...i,PROXY_URL:h.target.value}),placeholder:"http://127.0.0.1:7890",className:"transition-all-ease focus:scale-[1.01]"})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"apikey",className:"transition-all-ease hover:scale-[1.01] cursor-pointer",children:l("toplevel.apikey")}),y.jsx(Rt,{id:"apikey",type:"password",value:i.APIKEY,onChange:h=>s({...i,APIKEY:h.target.value}),className:"transition-all-ease focus:scale-[1.01]"})]})]}),y.jsx(po,{children:y.jsx(He,{onClick:()=>a(!1),className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:l("app.save")})})]})})}const va=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("rounded-lg border bg-card text-card-foreground shadow-sm",n),...a}));va.displayName="Card";const ya=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("flex flex-col space-y-1.5 p-6",n),...a}));ya.displayName="CardHeader";const ba=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("text-2xl font-semibold leading-none tracking-tight",n),...a}));ba.displayName="CardTitle";const bb=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("text-sm text-muted-foreground",n),...a}));bb.displayName="CardDescription";const xa=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("p-6 pt-0",n),...a}));xa.displayName="CardContent";const xb=v.forwardRef(({className:n,...a},l)=>y.jsx("div",{ref:l,className:ft("flex items-center p-6 pt-0",n),...a}));xb.displayName="CardFooter";function nA({transformers:n,onEdit:a,onRemove:l}){return!n||!Array.isArray(n)?y.jsx("div",{className:"space-y-3",children:y.jsx("div",{className:"flex items-center justify-center rounded-md border bg-white p-8 text-gray-500",children:"No transformers configured"})}):y.jsx("div",{className:"space-y-3",children:n.map((i,s)=>{if(!i)return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:"Invalid Transformer"}),y.jsx("p",{className:"text-sm text-gray-500",children:"Transformer data is missing"})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",disabled:!0,children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s);const u=i.path||"Unnamed Transformer",f=i.options||{},h=()=>!f||Object.keys(f).length===0?y.jsx("p",{className:"text-sm text-gray-500",children:"No parameters configured"}):y.jsx("div",{className:"flex flex-wrap gap-2 max-h-8 overflow-hidden",children:Object.entries(f).map(([p,m])=>y.jsxs("span",{className:"inline-flex items-center px-2 py-1 rounded-md bg-gray-100 text-xs font-medium text-gray-700 border",children:[y.jsxs("span",{className:"text-gray-600",children:[p,":"]}),y.jsx("span",{className:"ml-1 text-gray-800",children:String(m)})]},p))});return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:u}),h()]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s)})})}function aA(){const{t:n}=$r(),{config:a,setConfig:l}=Il(),[i,s]=v.useState(null),[u,f]=v.useState(null),[h,p]=v.useState(null);if(!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("transformers.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading transformers configuration..."})})]});const m=Array.isArray(a.transformers)?a.transformers:[],g=()=>{p({name:"",path:"",options:{}}),s(m.length)},x=T=>{const O=[...m];O.splice(T,1),l({...a,transformers:O}),f(null)},S=(T,O,z,k)=>{if(T<m.length){const H=[...m];k!==void 0?H[T].options[k]=z:H[T][O]=z,l({...a,transformers:H})}else if(h){const H={...h};k!==void 0?H.options[k]=z:H[O]=z,p(H)}},w=i!==null?i<m.length?m[i]:h:null,C=()=>{if(h&&i===m.length){const T=[...m,h];l({...a,transformers:T})}s(null),p(null)},R=()=>{s(null),p(null)};return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsxs(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:[y.jsxs(ba,{className:"text-lg",children:[n("transformers.title")," ",y.jsxs("span",{className:"text-sm font-normal text-gray-500",children:["(",m.length,")"]})]}),y.jsx(He,{onClick:g,children:n("transformers.add")})]}),y.jsx(xa,{className:"flex-grow overflow-y-auto p-4",children:y.jsx(nA,{transformers:m,onEdit:s,onRemove:f})}),y.jsx(mo,{open:i!==null,onOpenChange:R,children:y.jsxs(ql,{children:[y.jsx(Yl,{children:y.jsx(Kl,{children:n("transformers.edit")})}),w&&i!==null&&y.jsxs("div",{className:"space-y-4 py-4 px-6 max-h-96 overflow-y-auto",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"transformer-path",children:n("transformers.path")}),y.jsx(Rt,{id:"transformer-path",value:w.path||"",onChange:T=>S(i,"path",T.target.value)})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsxs("div",{className:"flex items-center justify-between",children:[y.jsx(ct,{children:n("transformers.parameters")}),y.jsx(He,{variant:"outline",size:"sm",onClick:()=>{const T=w.options||{},O=`param${Object.keys(T).length+1}`;if(i!==null){const z={...T,[O]:""};if(i<m.length){const k=[...m];k[i].options=z,l({...a,transformers:k})}else h&&p({...h,options:z})}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),Object.entries(w.options||{}).map(([T,O])=>y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(Rt,{value:T,onChange:z=>{const H={...w.options||{}};if(delete H[T],H[z.target.value]=O,i!==null)if(i<m.length){const P=[...m];P[i].options=H,l({...a,transformers:P})}else h&&p({...h,options:H})},className:"flex-1"}),y.jsx(Rt,{value:O,onChange:z=>{i!==null&&S(i,"parameters",z.target.value,T)},className:"flex-1"}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{if(i!==null){const k={...w.options||{}};if(delete k[T],i<m.length){const H=[...m];H[i].options=k,l({...a,transformers:H})}else h&&p({...h,options:k})}},children:y.jsx(Pr,{className:"h-4 w-4"})})]},T))]})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:R,children:n("app.cancel")}),y.jsx(He,{onClick:C,children:n("app.save")})]})]})}),y.jsx(mo,{open:u!==null,onOpenChange:()=>f(null),children:y.jsxs(ql,{children:[y.jsxs(Yl,{children:[y.jsx(Kl,{children:n("transformers.delete")}),y.jsx(ah,{children:n("transformers.delete_transformer_confirm")})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:()=>f(null),children:n("app.cancel")}),y.jsx(He,{variant:"destructive",onClick:()=>u!==null&&x(u),children:n("app.delete")})]})]})})]})}const rA=rh("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 Sb({className:n,variant:a,...l}){return y.jsx("div",{className:ft(rA({variant:a}),n),...l})}function lA({providers:n,onEdit:a,onRemove:l}){return!n||!Array.isArray(n)?y.jsx("div",{className:"space-y-3",children:y.jsx("div",{className:"flex items-center justify-center rounded-md border bg-white p-8 text-gray-500",children:"No providers configured"})}):y.jsx("div",{className:"space-y-3",children:n.map((i,s)=>{if(!i)return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:"Invalid Provider"}),y.jsx("p",{className:"text-sm text-gray-500",children:"Provider data is missing"})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",disabled:!0,children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s);const u=i.name||"Unnamed Provider",f=i.api_base_url||"No API URL",h=Array.isArray(i.models)?i.models:[];return y.jsxs("div",{className:"flex items-start justify-between rounded-md border bg-white p-4 transition-all hover:shadow-md animate-slide-in hover:scale-[1.01]",children:[y.jsxs("div",{className:"flex-1 space-y-1.5",children:[y.jsx("p",{className:"text-md font-semibold text-gray-800",children:u}),y.jsx("p",{className:"text-sm text-gray-500",children:f}),y.jsx("div",{className:"flex flex-wrap gap-2 pt-2",children:h.map((p,m)=>y.jsx(Sb,{variant:"outline",className:"font-normal transition-all-ease hover:scale-105",children:p||"Unnamed Model"},m))})]}),y.jsxs("div",{className:"ml-4 flex flex-shrink-0 items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>a(s),className:"transition-all-ease hover:scale-110",children:y.jsx(du,{className:"h-4 w-4"})}),y.jsx(He,{variant:"destructive",size:"icon",onClick:()=>l(s),className:"transition-all duration-200 hover:scale-110",children:y.jsx(Pr,{className:"h-4 w-4 text-current transition-colors duration-200"})})]})]},s)})})}var dy=1,iA=.9,oA=.8,sA=.17,sd=.1,ud=.999,uA=.9999,cA=.99,fA=/[\\\/_+.#"@\[\(\{&]/,dA=/[\\\/_+.#"@\[\(\{&]/g,hA=/[\s-]/,wb=/[\s-]/g;function _d(n,a,l,i,s,u,f){if(u===a.length)return s===n.length?dy:cA;var h=`${s},${u}`;if(f[h]!==void 0)return f[h];for(var p=i.charAt(u),m=l.indexOf(p,s),g=0,x,S,w,C;m>=0;)x=_d(n,a,l,i,m+1,u+1,f),x>g&&(m===s?x*=dy:fA.test(n.charAt(m-1))?(x*=oA,w=n.slice(s,m-1).match(dA),w&&s>0&&(x*=Math.pow(ud,w.length))):hA.test(n.charAt(m-1))?(x*=iA,C=n.slice(s,m-1).match(wb),C&&s>0&&(x*=Math.pow(ud,C.length))):(x*=sA,s>0&&(x*=Math.pow(ud,m-s))),n.charAt(m)!==a.charAt(u)&&(x*=uA)),(x<sd&&l.charAt(m-1)===i.charAt(u+1)||i.charAt(u+1)===i.charAt(u)&&l.charAt(m-1)!==i.charAt(u))&&(S=_d(n,a,l,i,m+1,u+2,f),S*sd>x&&(x=S*sd)),x>g&&(g=x),m=l.indexOf(p,m+1);return f[h]=g,g}function hy(n){return n.toLowerCase().replace(wb," ")}function mA(n,a,l){return n=l&&l.length>0?`${n+" "+l.join(" ")}`:n,_d(n,a,hy(n),hy(a),0,0,{})}var ro='[cmdk-group=""]',cd='[cmdk-group-items=""]',pA='[cmdk-group-heading=""]',Eb='[cmdk-item=""]',my=`${Eb}:not([aria-disabled="true"])`,Dd="cmdk-item-select",zl="data-value",gA=(n,a,l)=>mA(n,a,l),Rb=v.createContext(void 0),So=()=>v.useContext(Rb),Cb=v.createContext(void 0),lh=()=>v.useContext(Cb),Ob=v.createContext(void 0),Ab=v.forwardRef((n,a)=>{let l=kl(()=>{var L,K;return{search:"",value:(K=(L=n.value)!=null?L:n.defaultValue)!=null?K:"",selectedItemId:void 0,filtered:{count:0,items:new Map,groups:new Set}}}),i=kl(()=>new Set),s=kl(()=>new Map),u=kl(()=>new Map),f=kl(()=>new Set),h=Nb(n),{label:p,children:m,value:g,onValueChange:x,filter:S,shouldFilter:w,loop:C,disablePointerSelection:R=!1,vimBindings:T=!0,...O}=n,z=Gn(),k=Gn(),H=Gn(),P=v.useRef(null),A=AA();Hr(()=>{if(g!==void 0){let L=g.trim();l.current.value=L,G.emit()}},[g]),Hr(()=>{A(6,me)},[]);let G=v.useMemo(()=>({subscribe:L=>(f.current.add(L),()=>f.current.delete(L)),snapshot:()=>l.current,setState:(L,K,W)=>{var oe,de,ge,ze;if(!Object.is(l.current[L],K)){if(l.current[L]=K,L==="search")Ee(),ie(),A(1,Oe);else if(L==="value"){if(document.activeElement.hasAttribute("cmdk-input")||document.activeElement.hasAttribute("cmdk-root")){let Ze=document.getElementById(H);Ze?Ze.focus():(oe=document.getElementById(z))==null||oe.focus()}if(A(7,()=>{var Ze;l.current.selectedItemId=(Ze=he())==null?void 0:Ze.id,G.emit()}),W||A(5,me),((de=h.current)==null?void 0:de.value)!==void 0){let Ze=K??"";(ze=(ge=h.current).onValueChange)==null||ze.call(ge,Ze);return}}G.emit()}},emit:()=>{f.current.forEach(L=>L())}}),[]),J=v.useMemo(()=>({value:(L,K,W)=>{var oe;K!==((oe=u.current.get(L))==null?void 0:oe.value)&&(u.current.set(L,{value:K,keywords:W}),l.current.filtered.items.set(L,re(K,W)),A(2,()=>{ie(),G.emit()}))},item:(L,K)=>(i.current.add(L),K&&(s.current.has(K)?s.current.get(K).add(L):s.current.set(K,new Set([L]))),A(3,()=>{Ee(),ie(),l.current.value||Oe(),G.emit()}),()=>{u.current.delete(L),i.current.delete(L),l.current.filtered.items.delete(L);let W=he();A(4,()=>{Ee(),W?.getAttribute("id")===L&&Oe(),G.emit()})}),group:L=>(s.current.has(L)||s.current.set(L,new Set),()=>{u.current.delete(L),s.current.delete(L)}),filter:()=>h.current.shouldFilter,label:p||n["aria-label"],getDisablePointerSelection:()=>h.current.disablePointerSelection,listId:z,inputId:H,labelId:k,listInnerRef:P}),[]);function re(L,K){var W,oe;let de=(oe=(W=h.current)==null?void 0:W.filter)!=null?oe:gA;return L?de(L,l.current.search,K):0}function ie(){if(!l.current.search||h.current.shouldFilter===!1)return;let L=l.current.filtered.items,K=[];l.current.filtered.groups.forEach(oe=>{let de=s.current.get(oe),ge=0;de.forEach(ze=>{let Ze=L.get(ze);ge=Math.max(Ze,ge)}),K.push([oe,ge])});let W=P.current;fe().sort((oe,de)=>{var ge,ze;let Ze=oe.getAttribute("id"),je=de.getAttribute("id");return((ge=L.get(je))!=null?ge:0)-((ze=L.get(Ze))!=null?ze:0)}).forEach(oe=>{let de=oe.closest(cd);de?de.appendChild(oe.parentElement===de?oe:oe.closest(`${cd} > *`)):W.appendChild(oe.parentElement===W?oe:oe.closest(`${cd} > *`))}),K.sort((oe,de)=>de[1]-oe[1]).forEach(oe=>{var de;let ge=(de=P.current)==null?void 0:de.querySelector(`${ro}[${zl}="${encodeURIComponent(oe[0])}"]`);ge?.parentElement.appendChild(ge)})}function Oe(){let L=fe().find(W=>W.getAttribute("aria-disabled")!=="true"),K=L?.getAttribute(zl);G.setState("value",K||void 0)}function Ee(){var L,K,W,oe;if(!l.current.search||h.current.shouldFilter===!1){l.current.filtered.count=i.current.size;return}l.current.filtered.groups=new Set;let de=0;for(let ge of i.current){let ze=(K=(L=u.current.get(ge))==null?void 0:L.value)!=null?K:"",Ze=(oe=(W=u.current.get(ge))==null?void 0:W.keywords)!=null?oe:[],je=re(ze,Ze);l.current.filtered.items.set(ge,je),je>0&&de++}for(let[ge,ze]of s.current)for(let Ze of ze)if(l.current.filtered.items.get(Ze)>0){l.current.filtered.groups.add(ge);break}l.current.filtered.count=de}function me(){var L,K,W;let oe=he();oe&&(((L=oe.parentElement)==null?void 0:L.firstChild)===oe&&((W=(K=oe.closest(ro))==null?void 0:K.querySelector(pA))==null||W.scrollIntoView({block:"nearest"})),oe.scrollIntoView({block:"nearest"}))}function he(){var L;return(L=P.current)==null?void 0:L.querySelector(`${Eb}[aria-selected="true"]`)}function fe(){var L;return Array.from(((L=P.current)==null?void 0:L.querySelectorAll(my))||[])}function _(L){let K=fe()[L];K&&G.setState("value",K.getAttribute(zl))}function Z(L){var K;let W=he(),oe=fe(),de=oe.findIndex(ze=>ze===W),ge=oe[de+L];(K=h.current)!=null&&K.loop&&(ge=de+L<0?oe[oe.length-1]:de+L===oe.length?oe[0]:oe[de+L]),ge&&G.setState("value",ge.getAttribute(zl))}function $(L){let K=he(),W=K?.closest(ro),oe;for(;W&&!oe;)W=L>0?CA(W,ro):OA(W,ro),oe=W?.querySelector(my);oe?G.setState("value",oe.getAttribute(zl)):Z(L)}let pe=()=>_(fe().length-1),N=L=>{L.preventDefault(),L.metaKey?pe():L.altKey?$(1):Z(1)},Y=L=>{L.preventDefault(),L.metaKey?_(0):L.altKey?$(-1):Z(-1)};return v.createElement(dt.div,{ref:a,tabIndex:-1,...O,"cmdk-root":"",onKeyDown:L=>{var K;(K=O.onKeyDown)==null||K.call(O,L);let W=L.nativeEvent.isComposing||L.keyCode===229;if(!(L.defaultPrevented||W))switch(L.key){case"n":case"j":{T&&L.ctrlKey&&N(L);break}case"ArrowDown":{N(L);break}case"p":case"k":{T&&L.ctrlKey&&Y(L);break}case"ArrowUp":{Y(L);break}case"Home":{L.preventDefault(),_(0);break}case"End":{L.preventDefault(),pe();break}case"Enter":{L.preventDefault();let oe=he();if(oe){let de=new Event(Dd);oe.dispatchEvent(de)}}}}},v.createElement("label",{"cmdk-label":"",htmlFor:J.inputId,id:J.labelId,style:TA},p),ju(n,L=>v.createElement(Cb.Provider,{value:G},v.createElement(Rb.Provider,{value:J},L))))}),vA=v.forwardRef((n,a)=>{var l,i;let s=Gn(),u=v.useRef(null),f=v.useContext(Ob),h=So(),p=Nb(n),m=(i=(l=p.current)==null?void 0:l.forceMount)!=null?i:f?.forceMount;Hr(()=>{if(!m)return h.item(s,f?.id)},[m]);let g=Tb(s,u,[n.value,n.children,u],n.keywords),x=lh(),S=ar(A=>A.value&&A.value===g.current),w=ar(A=>m||h.filter()===!1?!0:A.search?A.filtered.items.get(s)>0:!0);v.useEffect(()=>{let A=u.current;if(!(!A||n.disabled))return A.addEventListener(Dd,C),()=>A.removeEventListener(Dd,C)},[w,n.onSelect,n.disabled]);function C(){var A,G;R(),(G=(A=p.current).onSelect)==null||G.call(A,g.current)}function R(){x.setState("value",g.current,!0)}if(!w)return null;let{disabled:T,value:O,onSelect:z,forceMount:k,keywords:H,...P}=n;return v.createElement(dt.div,{ref:kr(u,a),...P,id:s,"cmdk-item":"",role:"option","aria-disabled":!!T,"aria-selected":!!S,"data-disabled":!!T,"data-selected":!!S,onPointerMove:T||h.getDisablePointerSelection()?void 0:R,onClick:T?void 0:C},n.children)}),yA=v.forwardRef((n,a)=>{let{heading:l,children:i,forceMount:s,...u}=n,f=Gn(),h=v.useRef(null),p=v.useRef(null),m=Gn(),g=So(),x=ar(w=>s||g.filter()===!1?!0:w.search?w.filtered.groups.has(f):!0);Hr(()=>g.group(f),[]),Tb(f,h,[n.value,n.heading,p]);let S=v.useMemo(()=>({id:f,forceMount:s}),[s]);return v.createElement(dt.div,{ref:kr(h,a),...u,"cmdk-group":"",role:"presentation",hidden:x?void 0:!0},l&&v.createElement("div",{ref:p,"cmdk-group-heading":"","aria-hidden":!0,id:m},l),ju(n,w=>v.createElement("div",{"cmdk-group-items":"",role:"group","aria-labelledby":l?m:void 0},v.createElement(Ob.Provider,{value:S},w))))}),bA=v.forwardRef((n,a)=>{let{alwaysRender:l,...i}=n,s=v.useRef(null),u=ar(f=>!f.search);return!l&&!u?null:v.createElement(dt.div,{ref:kr(s,a),...i,"cmdk-separator":"",role:"separator"})}),xA=v.forwardRef((n,a)=>{let{onValueChange:l,...i}=n,s=n.value!=null,u=lh(),f=ar(m=>m.search),h=ar(m=>m.selectedItemId),p=So();return v.useEffect(()=>{n.value!=null&&u.setState("search",n.value)},[n.value]),v.createElement(dt.input,{ref:a,...i,"cmdk-input":"",autoComplete:"off",autoCorrect:"off",spellCheck:!1,"aria-autocomplete":"list",role:"combobox","aria-expanded":!0,"aria-controls":p.listId,"aria-labelledby":p.labelId,"aria-activedescendant":h,id:p.inputId,type:"text",value:s?n.value:f,onChange:m=>{s||u.setState("search",m.target.value),l?.(m.target.value)}})}),SA=v.forwardRef((n,a)=>{let{children:l,label:i="Suggestions",...s}=n,u=v.useRef(null),f=v.useRef(null),h=ar(m=>m.selectedItemId),p=So();return v.useEffect(()=>{if(f.current&&u.current){let m=f.current,g=u.current,x,S=new ResizeObserver(()=>{x=requestAnimationFrame(()=>{let w=m.offsetHeight;g.style.setProperty("--cmdk-list-height",w.toFixed(1)+"px")})});return S.observe(m),()=>{cancelAnimationFrame(x),S.unobserve(m)}}},[]),v.createElement(dt.div,{ref:kr(u,a),...s,"cmdk-list":"",role:"listbox",tabIndex:-1,"aria-activedescendant":h,"aria-label":i,id:p.listId},ju(n,m=>v.createElement("div",{ref:kr(f,p.listInnerRef),"cmdk-list-sizer":""},m)))}),wA=v.forwardRef((n,a)=>{let{open:l,onOpenChange:i,overlayClassName:s,contentClassName:u,container:f,...h}=n;return v.createElement(B0,{open:l,onOpenChange:i},v.createElement($0,{container:f},v.createElement(eh,{"cmdk-overlay":"",className:s}),v.createElement(th,{"aria-label":n.label,"cmdk-dialog":"",className:u},v.createElement(Ab,{ref:a,...h}))))}),EA=v.forwardRef((n,a)=>ar(l=>l.filtered.count===0)?v.createElement(dt.div,{ref:a,...n,"cmdk-empty":"",role:"presentation"}):null),RA=v.forwardRef((n,a)=>{let{progress:l,children:i,label:s="Loading...",...u}=n;return v.createElement(dt.div,{ref:a,...u,"cmdk-loading":"",role:"progressbar","aria-valuenow":l,"aria-valuemin":0,"aria-valuemax":100,"aria-label":s},ju(n,f=>v.createElement("div",{"aria-hidden":!0},f)))}),Wl=Object.assign(Ab,{List:SA,Item:vA,Input:xA,Group:yA,Separator:bA,Dialog:wA,Empty:EA,Loading:RA});function CA(n,a){let l=n.nextElementSibling;for(;l;){if(l.matches(a))return l;l=l.nextElementSibling}}function OA(n,a){let l=n.previousElementSibling;for(;l;){if(l.matches(a))return l;l=l.previousElementSibling}}function Nb(n){let a=v.useRef(n);return Hr(()=>{a.current=n}),a}var Hr=typeof window>"u"?v.useEffect:v.useLayoutEffect;function kl(n){let a=v.useRef();return a.current===void 0&&(a.current=n()),a}function ar(n){let a=lh(),l=()=>n(a.snapshot());return v.useSyncExternalStore(a.subscribe,l,l)}function Tb(n,a,l,i=[]){let s=v.useRef(),u=So();return Hr(()=>{var f;let h=(()=>{var m;for(let g of l){if(typeof g=="string")return g.trim();if(typeof g=="object"&&"current"in g)return g.current?(m=g.current.textContent)==null?void 0:m.trim():s.current}})(),p=i.map(m=>m.trim());u.value(n,h,p),(f=a.current)==null||f.setAttribute(zl,h),s.current=h}),s}var AA=()=>{let[n,a]=v.useState(),l=kl(()=>new Map);return Hr(()=>{l.current.forEach(i=>i()),l.current=new Map},[n]),(i,s)=>{l.current.set(i,s),a({})}};function NA(n){let a=n.type;return typeof a=="function"?a(n.props):"render"in a?a.render(n.props):n}function ju({asChild:n,children:a},l){return n&&v.isValidElement(a)?v.cloneElement(NA(a),{ref:a.ref},l(a.props.children)):l(a)}var TA={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0"};function jb({className:n,...a}){return y.jsx(Wl,{"data-slot":"command",className:ft("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",n),...a})}function Mb({className:n,...a}){return y.jsxs("div",{"data-slot":"command-input-wrapper",className:"flex h-9 items-center gap-2 border-b px-3",children:[y.jsx(rO,{className:"size-4 shrink-0 opacity-50"}),y.jsx(Wl.Input,{"data-slot":"command-input",className:ft("placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",n),...a})]})}function _b({className:n,...a}){return y.jsx(Wl.List,{"data-slot":"command-list",className:ft("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",n),...a})}function Db({...n}){return y.jsx(Wl.Empty,{"data-slot":"command-empty",className:"py-6 text-center text-sm",...n})}function Lb({className:n,...a}){return y.jsx(Wl.Group,{"data-slot":"command-group",className:ft("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",n),...a})}function zb({className:n,...a}){return y.jsx(Wl.Item,{"data-slot":"command-item",className:ft("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",n),...a})}const jA=["top","right","bottom","left"],rr=Math.min,sn=Math.max,hu=Math.round,Zs=Math.floor,Fn=n=>({x:n,y:n}),MA={left:"right",right:"left",bottom:"top",top:"bottom"},_A={start:"end",end:"start"};function Ld(n,a,l){return sn(n,rr(a,l))}function Sa(n,a){return typeof n=="function"?n(a):n}function wa(n){return n.split("-")[0]}function ei(n){return n.split("-")[1]}function ih(n){return n==="x"?"y":"x"}function oh(n){return n==="y"?"height":"width"}const DA=new Set(["top","bottom"]);function Yn(n){return DA.has(wa(n))?"y":"x"}function sh(n){return ih(Yn(n))}function LA(n,a,l){l===void 0&&(l=!1);const i=ei(n),s=sh(n),u=oh(s);let f=s==="x"?i===(l?"end":"start")?"right":"left":i==="start"?"bottom":"top";return a.reference[u]>a.floating[u]&&(f=mu(f)),[f,mu(f)]}function zA(n){const a=mu(n);return[zd(n),a,zd(a)]}function zd(n){return n.replace(/start|end/g,a=>_A[a])}const py=["left","right"],gy=["right","left"],kA=["top","bottom"],UA=["bottom","top"];function PA(n,a,l){switch(n){case"top":case"bottom":return l?a?gy:py:a?py:gy;case"left":case"right":return a?kA:UA;default:return[]}}function HA(n,a,l,i){const s=ei(n);let u=PA(wa(n),l==="start",i);return s&&(u=u.map(f=>f+"-"+s),a&&(u=u.concat(u.map(zd)))),u}function mu(n){return n.replace(/left|right|bottom|top/g,a=>MA[a])}function BA(n){return{top:0,right:0,bottom:0,left:0,...n}}function kb(n){return typeof n!="number"?BA(n):{top:n,right:n,bottom:n,left:n}}function pu(n){const{x:a,y:l,width:i,height:s}=n;return{width:i,height:s,top:l,left:a,right:a+i,bottom:l+s,x:a,y:l}}function vy(n,a,l){let{reference:i,floating:s}=n;const u=Yn(a),f=sh(a),h=oh(f),p=wa(a),m=u==="y",g=i.x+i.width/2-s.width/2,x=i.y+i.height/2-s.height/2,S=i[h]/2-s[h]/2;let w;switch(p){case"top":w={x:g,y:i.y-s.height};break;case"bottom":w={x:g,y:i.y+i.height};break;case"right":w={x:i.x+i.width,y:x};break;case"left":w={x:i.x-s.width,y:x};break;default:w={x:i.x,y:i.y}}switch(ei(a)){case"start":w[f]-=S*(l&&m?-1:1);break;case"end":w[f]+=S*(l&&m?-1:1);break}return w}const $A=async(n,a,l)=>{const{placement:i="bottom",strategy:s="absolute",middleware:u=[],platform:f}=l,h=u.filter(Boolean),p=await(f.isRTL==null?void 0:f.isRTL(a));let m=await f.getElementRects({reference:n,floating:a,strategy:s}),{x:g,y:x}=vy(m,i,p),S=i,w={},C=0;for(let R=0;R<h.length;R++){const{name:T,fn:O}=h[R],{x:z,y:k,data:H,reset:P}=await O({x:g,y:x,initialPlacement:i,placement:S,strategy:s,middlewareData:w,rects:m,platform:f,elements:{reference:n,floating:a}});g=z??g,x=k??x,w={...w,[T]:{...w[T],...H}},P&&C<=50&&(C++,typeof P=="object"&&(P.placement&&(S=P.placement),P.rects&&(m=P.rects===!0?await f.getElementRects({reference:n,floating:a,strategy:s}):P.rects),{x:g,y:x}=vy(m,S,p)),R=-1)}return{x:g,y:x,placement:S,strategy:s,middlewareData:w}};async function go(n,a){var l;a===void 0&&(a={});const{x:i,y:s,platform:u,rects:f,elements:h,strategy:p}=n,{boundary:m="clippingAncestors",rootBoundary:g="viewport",elementContext:x="floating",altBoundary:S=!1,padding:w=0}=Sa(a,n),C=kb(w),T=h[S?x==="floating"?"reference":"floating":x],O=pu(await u.getClippingRect({element:(l=await(u.isElement==null?void 0:u.isElement(T)))==null||l?T:T.contextElement||await(u.getDocumentElement==null?void 0:u.getDocumentElement(h.floating)),boundary:m,rootBoundary:g,strategy:p})),z=x==="floating"?{x:i,y:s,width:f.floating.width,height:f.floating.height}:f.reference,k=await(u.getOffsetParent==null?void 0:u.getOffsetParent(h.floating)),H=await(u.isElement==null?void 0:u.isElement(k))?await(u.getScale==null?void 0:u.getScale(k))||{x:1,y:1}:{x:1,y:1},P=pu(u.convertOffsetParentRelativeRectToViewportRelativeRect?await u.convertOffsetParentRelativeRectToViewportRelativeRect({elements:h,rect:z,offsetParent:k,strategy:p}):z);return{top:(O.top-P.top+C.top)/H.y,bottom:(P.bottom-O.bottom+C.bottom)/H.y,left:(O.left-P.left+C.left)/H.x,right:(P.right-O.right+C.right)/H.x}}const VA=n=>({name:"arrow",options:n,async fn(a){const{x:l,y:i,placement:s,rects:u,platform:f,elements:h,middlewareData:p}=a,{element:m,padding:g=0}=Sa(n,a)||{};if(m==null)return{};const x=kb(g),S={x:l,y:i},w=sh(s),C=oh(w),R=await f.getDimensions(m),T=w==="y",O=T?"top":"left",z=T?"bottom":"right",k=T?"clientHeight":"clientWidth",H=u.reference[C]+u.reference[w]-S[w]-u.floating[C],P=S[w]-u.reference[w],A=await(f.getOffsetParent==null?void 0:f.getOffsetParent(m));let G=A?A[k]:0;(!G||!await(f.isElement==null?void 0:f.isElement(A)))&&(G=h.floating[k]||u.floating[C]);const J=H/2-P/2,re=G/2-R[C]/2-1,ie=rr(x[O],re),Oe=rr(x[z],re),Ee=ie,me=G-R[C]-Oe,he=G/2-R[C]/2+J,fe=Ld(Ee,he,me),_=!p.arrow&&ei(s)!=null&&he!==fe&&u.reference[C]/2-(he<Ee?ie:Oe)-R[C]/2<0,Z=_?he<Ee?he-Ee:he-me:0;return{[w]:S[w]+Z,data:{[w]:fe,centerOffset:he-fe-Z,..._&&{alignmentOffset:Z}},reset:_}}}),qA=function(n){return n===void 0&&(n={}),{name:"flip",options:n,async fn(a){var l,i;const{placement:s,middlewareData:u,rects:f,initialPlacement:h,platform:p,elements:m}=a,{mainAxis:g=!0,crossAxis:x=!0,fallbackPlacements:S,fallbackStrategy:w="bestFit",fallbackAxisSideDirection:C="none",flipAlignment:R=!0,...T}=Sa(n,a);if((l=u.arrow)!=null&&l.alignmentOffset)return{};const O=wa(s),z=Yn(h),k=wa(h)===h,H=await(p.isRTL==null?void 0:p.isRTL(m.floating)),P=S||(k||!R?[mu(h)]:zA(h)),A=C!=="none";!S&&A&&P.push(...HA(h,R,C,H));const G=[h,...P],J=await go(a,T),re=[];let ie=((i=u.flip)==null?void 0:i.overflows)||[];if(g&&re.push(J[O]),x){const he=LA(s,f,H);re.push(J[he[0]],J[he[1]])}if(ie=[...ie,{placement:s,overflows:re}],!re.every(he=>he<=0)){var Oe,Ee;const he=(((Oe=u.flip)==null?void 0:Oe.index)||0)+1,fe=G[he];if(fe&&(!(x==="alignment"?z!==Yn(fe):!1)||ie.every($=>$.overflows[0]>0&&Yn($.placement)===z)))return{data:{index:he,overflows:ie},reset:{placement:fe}};let _=(Ee=ie.filter(Z=>Z.overflows[0]<=0).sort((Z,$)=>Z.overflows[1]-$.overflows[1])[0])==null?void 0:Ee.placement;if(!_)switch(w){case"bestFit":{var me;const Z=(me=ie.filter($=>{if(A){const pe=Yn($.placement);return pe===z||pe==="y"}return!0}).map($=>[$.placement,$.overflows.filter(pe=>pe>0).reduce((pe,N)=>pe+N,0)]).sort(($,pe)=>$[1]-pe[1])[0])==null?void 0:me[0];Z&&(_=Z);break}case"initialPlacement":_=h;break}if(s!==_)return{reset:{placement:_}}}return{}}}};function yy(n,a){return{top:n.top-a.height,right:n.right-a.width,bottom:n.bottom-a.height,left:n.left-a.width}}function by(n){return jA.some(a=>n[a]>=0)}const YA=function(n){return n===void 0&&(n={}),{name:"hide",options:n,async fn(a){const{rects:l}=a,{strategy:i="referenceHidden",...s}=Sa(n,a);switch(i){case"referenceHidden":{const u=await go(a,{...s,elementContext:"reference"}),f=yy(u,l.reference);return{data:{referenceHiddenOffsets:f,referenceHidden:by(f)}}}case"escaped":{const u=await go(a,{...s,altBoundary:!0}),f=yy(u,l.floating);return{data:{escapedOffsets:f,escaped:by(f)}}}default:return{}}}}},Ub=new Set(["left","top"]);async function KA(n,a){const{placement:l,platform:i,elements:s}=n,u=await(i.isRTL==null?void 0:i.isRTL(s.floating)),f=wa(l),h=ei(l),p=Yn(l)==="y",m=Ub.has(f)?-1:1,g=u&&p?-1:1,x=Sa(a,n);let{mainAxis:S,crossAxis:w,alignmentAxis:C}=typeof x=="number"?{mainAxis:x,crossAxis:0,alignmentAxis:null}:{mainAxis:x.mainAxis||0,crossAxis:x.crossAxis||0,alignmentAxis:x.alignmentAxis};return h&&typeof C=="number"&&(w=h==="end"?C*-1:C),p?{x:w*g,y:S*m}:{x:S*m,y:w*g}}const GA=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(a){var l,i;const{x:s,y:u,placement:f,middlewareData:h}=a,p=await KA(a,n);return f===((l=h.offset)==null?void 0:l.placement)&&(i=h.arrow)!=null&&i.alignmentOffset?{}:{x:s+p.x,y:u+p.y,data:{...p,placement:f}}}}},FA=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(a){const{x:l,y:i,placement:s}=a,{mainAxis:u=!0,crossAxis:f=!1,limiter:h={fn:T=>{let{x:O,y:z}=T;return{x:O,y:z}}},...p}=Sa(n,a),m={x:l,y:i},g=await go(a,p),x=Yn(wa(s)),S=ih(x);let w=m[S],C=m[x];if(u){const T=S==="y"?"top":"left",O=S==="y"?"bottom":"right",z=w+g[T],k=w-g[O];w=Ld(z,w,k)}if(f){const T=x==="y"?"top":"left",O=x==="y"?"bottom":"right",z=C+g[T],k=C-g[O];C=Ld(z,C,k)}const R=h.fn({...a,[S]:w,[x]:C});return{...R,data:{x:R.x-l,y:R.y-i,enabled:{[S]:u,[x]:f}}}}}},XA=function(n){return n===void 0&&(n={}),{options:n,fn(a){const{x:l,y:i,placement:s,rects:u,middlewareData:f}=a,{offset:h=0,mainAxis:p=!0,crossAxis:m=!0}=Sa(n,a),g={x:l,y:i},x=Yn(s),S=ih(x);let w=g[S],C=g[x];const R=Sa(h,a),T=typeof R=="number"?{mainAxis:R,crossAxis:0}:{mainAxis:0,crossAxis:0,...R};if(p){const k=S==="y"?"height":"width",H=u.reference[S]-u.floating[k]+T.mainAxis,P=u.reference[S]+u.reference[k]-T.mainAxis;w<H?w=H:w>P&&(w=P)}if(m){var O,z;const k=S==="y"?"width":"height",H=Ub.has(wa(s)),P=u.reference[x]-u.floating[k]+(H&&((O=f.offset)==null?void 0:O[x])||0)+(H?0:T.crossAxis),A=u.reference[x]+u.reference[k]+(H?0:((z=f.offset)==null?void 0:z[x])||0)-(H?T.crossAxis:0);C<P?C=P:C>A&&(C=A)}return{[S]:w,[x]:C}}}},QA=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(a){var l,i;const{placement:s,rects:u,platform:f,elements:h}=a,{apply:p=()=>{},...m}=Sa(n,a),g=await go(a,m),x=wa(s),S=ei(s),w=Yn(s)==="y",{width:C,height:R}=u.floating;let T,O;x==="top"||x==="bottom"?(T=x,O=S===(await(f.isRTL==null?void 0:f.isRTL(h.floating))?"start":"end")?"left":"right"):(O=x,T=S==="end"?"top":"bottom");const z=R-g.top-g.bottom,k=C-g.left-g.right,H=rr(R-g[T],z),P=rr(C-g[O],k),A=!a.middlewareData.shift;let G=H,J=P;if((l=a.middlewareData.shift)!=null&&l.enabled.x&&(J=k),(i=a.middlewareData.shift)!=null&&i.enabled.y&&(G=z),A&&!S){const ie=sn(g.left,0),Oe=sn(g.right,0),Ee=sn(g.top,0),me=sn(g.bottom,0);w?J=C-2*(ie!==0||Oe!==0?ie+Oe:sn(g.left,g.right)):G=R-2*(Ee!==0||me!==0?Ee+me:sn(g.top,g.bottom))}await p({...a,availableWidth:J,availableHeight:G});const re=await f.getDimensions(h.floating);return C!==re.width||R!==re.height?{reset:{rects:!0}}:{}}}};function Mu(){return typeof window<"u"}function ti(n){return Pb(n)?(n.nodeName||"").toLowerCase():"#document"}function cn(n){var a;return(n==null||(a=n.ownerDocument)==null?void 0:a.defaultView)||window}function Zn(n){var a;return(a=(Pb(n)?n.ownerDocument:n.document)||window.document)==null?void 0:a.documentElement}function Pb(n){return Mu()?n instanceof Node||n instanceof cn(n).Node:!1}function jn(n){return Mu()?n instanceof Element||n instanceof cn(n).Element:!1}function Xn(n){return Mu()?n instanceof HTMLElement||n instanceof cn(n).HTMLElement:!1}function xy(n){return!Mu()||typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof cn(n).ShadowRoot}const ZA=new Set(["inline","contents"]);function wo(n){const{overflow:a,overflowX:l,overflowY:i,display:s}=Mn(n);return/auto|scroll|overlay|hidden|clip/.test(a+i+l)&&!ZA.has(s)}const JA=new Set(["table","td","th"]);function IA(n){return JA.has(ti(n))}const WA=[":popover-open",":modal"];function _u(n){return WA.some(a=>{try{return n.matches(a)}catch{return!1}})}const eN=["transform","translate","scale","rotate","perspective"],tN=["transform","translate","scale","rotate","perspective","filter"],nN=["paint","layout","strict","content"];function uh(n){const a=ch(),l=jn(n)?Mn(n):n;return eN.some(i=>l[i]?l[i]!=="none":!1)||(l.containerType?l.containerType!=="normal":!1)||!a&&(l.backdropFilter?l.backdropFilter!=="none":!1)||!a&&(l.filter?l.filter!=="none":!1)||tN.some(i=>(l.willChange||"").includes(i))||nN.some(i=>(l.contain||"").includes(i))}function aN(n){let a=lr(n);for(;Xn(a)&&!Gl(a);){if(uh(a))return a;if(_u(a))return null;a=lr(a)}return null}function ch(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const rN=new Set(["html","body","#document"]);function Gl(n){return rN.has(ti(n))}function Mn(n){return cn(n).getComputedStyle(n)}function Du(n){return jn(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.scrollX,scrollTop:n.scrollY}}function lr(n){if(ti(n)==="html")return n;const a=n.assignedSlot||n.parentNode||xy(n)&&n.host||Zn(n);return xy(a)?a.host:a}function Hb(n){const a=lr(n);return Gl(a)?n.ownerDocument?n.ownerDocument.body:n.body:Xn(a)&&wo(a)?a:Hb(a)}function vo(n,a,l){var i;a===void 0&&(a=[]),l===void 0&&(l=!0);const s=Hb(n),u=s===((i=n.ownerDocument)==null?void 0:i.body),f=cn(s);if(u){const h=kd(f);return a.concat(f,f.visualViewport||[],wo(s)?s:[],h&&l?vo(h):[])}return a.concat(s,vo(s,[],l))}function kd(n){return n.parent&&Object.getPrototypeOf(n.parent)?n.frameElement:null}function Bb(n){const a=Mn(n);let l=parseFloat(a.width)||0,i=parseFloat(a.height)||0;const s=Xn(n),u=s?n.offsetWidth:l,f=s?n.offsetHeight:i,h=hu(l)!==u||hu(i)!==f;return h&&(l=u,i=f),{width:l,height:i,$:h}}function fh(n){return jn(n)?n:n.contextElement}function $l(n){const a=fh(n);if(!Xn(a))return Fn(1);const l=a.getBoundingClientRect(),{width:i,height:s,$:u}=Bb(a);let f=(u?hu(l.width):l.width)/i,h=(u?hu(l.height):l.height)/s;return(!f||!Number.isFinite(f))&&(f=1),(!h||!Number.isFinite(h))&&(h=1),{x:f,y:h}}const lN=Fn(0);function $b(n){const a=cn(n);return!ch()||!a.visualViewport?lN:{x:a.visualViewport.offsetLeft,y:a.visualViewport.offsetTop}}function iN(n,a,l){return a===void 0&&(a=!1),!l||a&&l!==cn(n)?!1:a}function Br(n,a,l,i){a===void 0&&(a=!1),l===void 0&&(l=!1);const s=n.getBoundingClientRect(),u=fh(n);let f=Fn(1);a&&(i?jn(i)&&(f=$l(i)):f=$l(n));const h=iN(u,l,i)?$b(u):Fn(0);let p=(s.left+h.x)/f.x,m=(s.top+h.y)/f.y,g=s.width/f.x,x=s.height/f.y;if(u){const S=cn(u),w=i&&jn(i)?cn(i):i;let C=S,R=kd(C);for(;R&&i&&w!==C;){const T=$l(R),O=R.getBoundingClientRect(),z=Mn(R),k=O.left+(R.clientLeft+parseFloat(z.paddingLeft))*T.x,H=O.top+(R.clientTop+parseFloat(z.paddingTop))*T.y;p*=T.x,m*=T.y,g*=T.x,x*=T.y,p+=k,m+=H,C=cn(R),R=kd(C)}}return pu({width:g,height:x,x:p,y:m})}function dh(n,a){const l=Du(n).scrollLeft;return a?a.left+l:Br(Zn(n)).left+l}function Vb(n,a,l){l===void 0&&(l=!1);const i=n.getBoundingClientRect(),s=i.left+a.scrollLeft-(l?0:dh(n,i)),u=i.top+a.scrollTop;return{x:s,y:u}}function oN(n){let{elements:a,rect:l,offsetParent:i,strategy:s}=n;const u=s==="fixed",f=Zn(i),h=a?_u(a.floating):!1;if(i===f||h&&u)return l;let p={scrollLeft:0,scrollTop:0},m=Fn(1);const g=Fn(0),x=Xn(i);if((x||!x&&!u)&&((ti(i)!=="body"||wo(f))&&(p=Du(i)),Xn(i))){const w=Br(i);m=$l(i),g.x=w.x+i.clientLeft,g.y=w.y+i.clientTop}const S=f&&!x&&!u?Vb(f,p,!0):Fn(0);return{width:l.width*m.x,height:l.height*m.y,x:l.x*m.x-p.scrollLeft*m.x+g.x+S.x,y:l.y*m.y-p.scrollTop*m.y+g.y+S.y}}function sN(n){return Array.from(n.getClientRects())}function uN(n){const a=Zn(n),l=Du(n),i=n.ownerDocument.body,s=sn(a.scrollWidth,a.clientWidth,i.scrollWidth,i.clientWidth),u=sn(a.scrollHeight,a.clientHeight,i.scrollHeight,i.clientHeight);let f=-l.scrollLeft+dh(n);const h=-l.scrollTop;return Mn(i).direction==="rtl"&&(f+=sn(a.clientWidth,i.clientWidth)-s),{width:s,height:u,x:f,y:h}}function cN(n,a){const l=cn(n),i=Zn(n),s=l.visualViewport;let u=i.clientWidth,f=i.clientHeight,h=0,p=0;if(s){u=s.width,f=s.height;const m=ch();(!m||m&&a==="fixed")&&(h=s.offsetLeft,p=s.offsetTop)}return{width:u,height:f,x:h,y:p}}const fN=new Set(["absolute","fixed"]);function dN(n,a){const l=Br(n,!0,a==="fixed"),i=l.top+n.clientTop,s=l.left+n.clientLeft,u=Xn(n)?$l(n):Fn(1),f=n.clientWidth*u.x,h=n.clientHeight*u.y,p=s*u.x,m=i*u.y;return{width:f,height:h,x:p,y:m}}function Sy(n,a,l){let i;if(a==="viewport")i=cN(n,l);else if(a==="document")i=uN(Zn(n));else if(jn(a))i=dN(a,l);else{const s=$b(n);i={x:a.x-s.x,y:a.y-s.y,width:a.width,height:a.height}}return pu(i)}function qb(n,a){const l=lr(n);return l===a||!jn(l)||Gl(l)?!1:Mn(l).position==="fixed"||qb(l,a)}function hN(n,a){const l=a.get(n);if(l)return l;let i=vo(n,[],!1).filter(h=>jn(h)&&ti(h)!=="body"),s=null;const u=Mn(n).position==="fixed";let f=u?lr(n):n;for(;jn(f)&&!Gl(f);){const h=Mn(f),p=uh(f);!p&&h.position==="fixed"&&(s=null),(u?!p&&!s:!p&&h.position==="static"&&!!s&&fN.has(s.position)||wo(f)&&!p&&qb(n,f))?i=i.filter(g=>g!==f):s=h,f=lr(f)}return a.set(n,i),i}function mN(n){let{element:a,boundary:l,rootBoundary:i,strategy:s}=n;const f=[...l==="clippingAncestors"?_u(a)?[]:hN(a,this._c):[].concat(l),i],h=f[0],p=f.reduce((m,g)=>{const x=Sy(a,g,s);return m.top=sn(x.top,m.top),m.right=rr(x.right,m.right),m.bottom=rr(x.bottom,m.bottom),m.left=sn(x.left,m.left),m},Sy(a,h,s));return{width:p.right-p.left,height:p.bottom-p.top,x:p.left,y:p.top}}function pN(n){const{width:a,height:l}=Bb(n);return{width:a,height:l}}function gN(n,a,l){const i=Xn(a),s=Zn(a),u=l==="fixed",f=Br(n,!0,u,a);let h={scrollLeft:0,scrollTop:0};const p=Fn(0);function m(){p.x=dh(s)}if(i||!i&&!u)if((ti(a)!=="body"||wo(s))&&(h=Du(a)),i){const w=Br(a,!0,u,a);p.x=w.x+a.clientLeft,p.y=w.y+a.clientTop}else s&&m();u&&!i&&s&&m();const g=s&&!i&&!u?Vb(s,h):Fn(0),x=f.left+h.scrollLeft-p.x-g.x,S=f.top+h.scrollTop-p.y-g.y;return{x,y:S,width:f.width,height:f.height}}function fd(n){return Mn(n).position==="static"}function wy(n,a){if(!Xn(n)||Mn(n).position==="fixed")return null;if(a)return a(n);let l=n.offsetParent;return Zn(n)===l&&(l=l.ownerDocument.body),l}function Yb(n,a){const l=cn(n);if(_u(n))return l;if(!Xn(n)){let s=lr(n);for(;s&&!Gl(s);){if(jn(s)&&!fd(s))return s;s=lr(s)}return l}let i=wy(n,a);for(;i&&IA(i)&&fd(i);)i=wy(i,a);return i&&Gl(i)&&fd(i)&&!uh(i)?l:i||aN(n)||l}const vN=async function(n){const a=this.getOffsetParent||Yb,l=this.getDimensions,i=await l(n.floating);return{reference:gN(n.reference,await a(n.floating),n.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function yN(n){return Mn(n).direction==="rtl"}const bN={convertOffsetParentRelativeRectToViewportRelativeRect:oN,getDocumentElement:Zn,getClippingRect:mN,getOffsetParent:Yb,getElementRects:vN,getClientRects:sN,getDimensions:pN,getScale:$l,isElement:jn,isRTL:yN};function Kb(n,a){return n.x===a.x&&n.y===a.y&&n.width===a.width&&n.height===a.height}function xN(n,a){let l=null,i;const s=Zn(n);function u(){var h;clearTimeout(i),(h=l)==null||h.disconnect(),l=null}function f(h,p){h===void 0&&(h=!1),p===void 0&&(p=1),u();const m=n.getBoundingClientRect(),{left:g,top:x,width:S,height:w}=m;if(h||a(),!S||!w)return;const C=Zs(x),R=Zs(s.clientWidth-(g+S)),T=Zs(s.clientHeight-(x+w)),O=Zs(g),k={rootMargin:-C+"px "+-R+"px "+-T+"px "+-O+"px",threshold:sn(0,rr(1,p))||1};let H=!0;function P(A){const G=A[0].intersectionRatio;if(G!==p){if(!H)return f();G?f(!1,G):i=setTimeout(()=>{f(!1,1e-7)},1e3)}G===1&&!Kb(m,n.getBoundingClientRect())&&f(),H=!1}try{l=new IntersectionObserver(P,{...k,root:s.ownerDocument})}catch{l=new IntersectionObserver(P,k)}l.observe(n)}return f(!0),u}function SN(n,a,l,i){i===void 0&&(i={});const{ancestorScroll:s=!0,ancestorResize:u=!0,elementResize:f=typeof ResizeObserver=="function",layoutShift:h=typeof IntersectionObserver=="function",animationFrame:p=!1}=i,m=fh(n),g=s||u?[...m?vo(m):[],...vo(a)]:[];g.forEach(O=>{s&&O.addEventListener("scroll",l,{passive:!0}),u&&O.addEventListener("resize",l)});const x=m&&h?xN(m,l):null;let S=-1,w=null;f&&(w=new ResizeObserver(O=>{let[z]=O;z&&z.target===m&&w&&(w.unobserve(a),cancelAnimationFrame(S),S=requestAnimationFrame(()=>{var k;(k=w)==null||k.observe(a)})),l()}),m&&!p&&w.observe(m),w.observe(a));let C,R=p?Br(n):null;p&&T();function T(){const O=Br(n);R&&!Kb(R,O)&&l(),R=O,C=requestAnimationFrame(T)}return l(),()=>{var O;g.forEach(z=>{s&&z.removeEventListener("scroll",l),u&&z.removeEventListener("resize",l)}),x?.(),(O=w)==null||O.disconnect(),w=null,p&&cancelAnimationFrame(C)}}const wN=GA,EN=FA,RN=qA,CN=QA,ON=YA,Ey=VA,AN=XA,NN=(n,a,l)=>{const i=new Map,s={platform:bN,...l},u={...s.platform,_c:i};return $A(n,a,{...s,platform:u})};var TN=typeof document<"u",jN=function(){},lu=TN?v.useLayoutEffect:jN;function gu(n,a){if(n===a)return!0;if(typeof n!=typeof a)return!1;if(typeof n=="function"&&n.toString()===a.toString())return!0;let l,i,s;if(n&&a&&typeof n=="object"){if(Array.isArray(n)){if(l=n.length,l!==a.length)return!1;for(i=l;i--!==0;)if(!gu(n[i],a[i]))return!1;return!0}if(s=Object.keys(n),l=s.length,l!==Object.keys(a).length)return!1;for(i=l;i--!==0;)if(!{}.hasOwnProperty.call(a,s[i]))return!1;for(i=l;i--!==0;){const u=s[i];if(!(u==="_owner"&&n.$$typeof)&&!gu(n[u],a[u]))return!1}return!0}return n!==n&&a!==a}function Gb(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function Ry(n,a){const l=Gb(n);return Math.round(a*l)/l}function dd(n){const a=v.useRef(n);return lu(()=>{a.current=n}),a}function MN(n){n===void 0&&(n={});const{placement:a="bottom",strategy:l="absolute",middleware:i=[],platform:s,elements:{reference:u,floating:f}={},transform:h=!0,whileElementsMounted:p,open:m}=n,[g,x]=v.useState({x:0,y:0,strategy:l,placement:a,middlewareData:{},isPositioned:!1}),[S,w]=v.useState(i);gu(S,i)||w(i);const[C,R]=v.useState(null),[T,O]=v.useState(null),z=v.useCallback($=>{$!==A.current&&(A.current=$,R($))},[]),k=v.useCallback($=>{$!==G.current&&(G.current=$,O($))},[]),H=u||C,P=f||T,A=v.useRef(null),G=v.useRef(null),J=v.useRef(g),re=p!=null,ie=dd(p),Oe=dd(s),Ee=dd(m),me=v.useCallback(()=>{if(!A.current||!G.current)return;const $={placement:a,strategy:l,middleware:S};Oe.current&&($.platform=Oe.current),NN(A.current,G.current,$).then(pe=>{const N={...pe,isPositioned:Ee.current!==!1};he.current&&!gu(J.current,N)&&(J.current=N,Ru.flushSync(()=>{x(N)}))})},[S,a,l,Oe,Ee]);lu(()=>{m===!1&&J.current.isPositioned&&(J.current.isPositioned=!1,x($=>({...$,isPositioned:!1})))},[m]);const he=v.useRef(!1);lu(()=>(he.current=!0,()=>{he.current=!1}),[]),lu(()=>{if(H&&(A.current=H),P&&(G.current=P),H&&P){if(ie.current)return ie.current(H,P,me);me()}},[H,P,me,ie,re]);const fe=v.useMemo(()=>({reference:A,floating:G,setReference:z,setFloating:k}),[z,k]),_=v.useMemo(()=>({reference:H,floating:P}),[H,P]),Z=v.useMemo(()=>{const $={position:l,left:0,top:0};if(!_.floating)return $;const pe=Ry(_.floating,g.x),N=Ry(_.floating,g.y);return h?{...$,transform:"translate("+pe+"px, "+N+"px)",...Gb(_.floating)>=1.5&&{willChange:"transform"}}:{position:l,left:pe,top:N}},[l,h,_.floating,g.x,g.y]);return v.useMemo(()=>({...g,update:me,refs:fe,elements:_,floatingStyles:Z}),[g,me,fe,_,Z])}const _N=n=>{function a(l){return{}.hasOwnProperty.call(l,"current")}return{name:"arrow",options:n,fn(l){const{element:i,padding:s}=typeof n=="function"?n(l):n;return i&&a(i)?i.current!=null?Ey({element:i.current,padding:s}).fn(l):{}:i?Ey({element:i,padding:s}).fn(l):{}}}},DN=(n,a)=>({...wN(n),options:[n,a]}),LN=(n,a)=>({...EN(n),options:[n,a]}),zN=(n,a)=>({...AN(n),options:[n,a]}),kN=(n,a)=>({...RN(n),options:[n,a]}),UN=(n,a)=>({...CN(n),options:[n,a]}),PN=(n,a)=>({...ON(n),options:[n,a]}),HN=(n,a)=>({..._N(n),options:[n,a]});var BN="Arrow",Fb=v.forwardRef((n,a)=>{const{children:l,width:i=10,height:s=5,...u}=n;return y.jsx(dt.svg,{...u,ref:a,width:i,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:n.asChild?l:y.jsx("polygon",{points:"0,0 30,0 15,10"})})});Fb.displayName=BN;var $N=Fb,hh="Popper",[Xb,Qb]=Cu(hh),[VN,Zb]=Xb(hh),Jb=n=>{const{__scopePopper:a,children:l}=n,[i,s]=v.useState(null);return y.jsx(VN,{scope:a,anchor:i,onAnchorChange:s,children:l})};Jb.displayName=hh;var Ib="PopperAnchor",Wb=v.forwardRef((n,a)=>{const{__scopePopper:l,virtualRef:i,...s}=n,u=Zb(Ib,l),f=v.useRef(null),h=fn(a,f);return v.useEffect(()=>{u.onAnchorChange(i?.current||f.current)}),i?null:y.jsx(dt.div,{...s,ref:h})});Wb.displayName=Ib;var mh="PopperContent",[qN,YN]=Xb(mh),ex=v.forwardRef((n,a)=>{const{__scopePopper:l,side:i="bottom",sideOffset:s=0,align:u="center",alignOffset:f=0,arrowPadding:h=0,avoidCollisions:p=!0,collisionBoundary:m=[],collisionPadding:g=0,sticky:x="partial",hideWhenDetached:S=!1,updatePositionStrategy:w="optimized",onPlaced:C,...R}=n,T=Zb(mh,l),[O,z]=v.useState(null),k=fn(a,ge=>z(ge)),[H,P]=v.useState(null),A=cb(H),G=A?.width??0,J=A?.height??0,re=i+(u!=="center"?"-"+u:""),ie=typeof g=="number"?g:{top:0,right:0,bottom:0,left:0,...g},Oe=Array.isArray(m)?m:[m],Ee=Oe.length>0,me={padding:ie,boundary:Oe.filter(GN),altBoundary:Ee},{refs:he,floatingStyles:fe,placement:_,isPositioned:Z,middlewareData:$}=MN({strategy:"fixed",placement:re,whileElementsMounted:(...ge)=>SN(...ge,{animationFrame:w==="always"}),elements:{reference:T.anchor},middleware:[DN({mainAxis:s+J,alignmentAxis:f}),p&&LN({mainAxis:!0,crossAxis:!1,limiter:x==="partial"?zN():void 0,...me}),p&&kN({...me}),UN({...me,apply:({elements:ge,rects:ze,availableWidth:Ze,availableHeight:je})=>{const{width:ae,height:te}=ze.reference,se=ge.floating.style;se.setProperty("--radix-popper-available-width",`${Ze}px`),se.setProperty("--radix-popper-available-height",`${je}px`),se.setProperty("--radix-popper-anchor-width",`${ae}px`),se.setProperty("--radix-popper-anchor-height",`${te}px`)}}),H&&HN({element:H,padding:h}),FN({arrowWidth:G,arrowHeight:J}),S&&PN({strategy:"referenceHidden",...me})]}),[pe,N]=ax(_),Y=Vl(C);nr(()=>{Z&&Y?.()},[Z,Y]);const L=$.arrow?.x,K=$.arrow?.y,W=$.arrow?.centerOffset!==0,[oe,de]=v.useState();return nr(()=>{O&&de(window.getComputedStyle(O).zIndex)},[O]),y.jsx("div",{ref:he.setFloating,"data-radix-popper-content-wrapper":"",style:{...fe,transform:Z?fe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:oe,"--radix-popper-transform-origin":[$.transformOrigin?.x,$.transformOrigin?.y].join(" "),...$.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:n.dir,children:y.jsx(qN,{scope:l,placedSide:pe,onArrowChange:P,arrowX:L,arrowY:K,shouldHideArrow:W,children:y.jsx(dt.div,{"data-side":pe,"data-align":N,...R,ref:k,style:{...R.style,animation:Z?void 0:"none"}})})})});ex.displayName=mh;var tx="PopperArrow",KN={top:"bottom",right:"left",bottom:"top",left:"right"},nx=v.forwardRef(function(a,l){const{__scopePopper:i,...s}=a,u=YN(tx,i),f=KN[u.placedSide];return y.jsx("span",{ref:u.onArrowChange,style:{position:"absolute",left:u.arrowX,top:u.arrowY,[f]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[u.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[u.placedSide],visibility:u.shouldHideArrow?"hidden":void 0},children:y.jsx($N,{...s,ref:l,style:{...s.style,display:"block"}})})});nx.displayName=tx;function GN(n){return n!==null}var FN=n=>({name:"transformOrigin",options:n,fn(a){const{placement:l,rects:i,middlewareData:s}=a,f=s.arrow?.centerOffset!==0,h=f?0:n.arrowWidth,p=f?0:n.arrowHeight,[m,g]=ax(l),x={start:"0%",center:"50%",end:"100%"}[g],S=(s.arrow?.x??0)+h/2,w=(s.arrow?.y??0)+p/2;let C="",R="";return m==="bottom"?(C=f?x:`${S}px`,R=`${-p}px`):m==="top"?(C=f?x:`${S}px`,R=`${i.floating.height+p}px`):m==="right"?(C=`${-p}px`,R=f?x:`${w}px`):m==="left"&&(C=`${i.floating.width+p}px`,R=f?x:`${w}px`),{data:{x:C,y:R}}}});function ax(n){const[a,l="center"]=n.split("-");return[a,l]}var XN=Jb,rx=Wb,QN=ex,ZN=nx,Lu="Popover",[lx,jj]=Cu(Lu,[Qb]),Eo=Qb(),[JN,or]=lx(Lu),ix=n=>{const{__scopePopover:a,children:l,open:i,defaultOpen:s,onOpenChange:u,modal:f=!1}=n,h=Eo(a),p=v.useRef(null),[m,g]=v.useState(!1),[x,S]=Gd({prop:i,defaultProp:s??!1,onChange:u,caller:Lu});return y.jsx(XN,{...h,children:y.jsx(JN,{scope:a,contentId:Gn(),triggerRef:p,open:x,onOpenChange:S,onOpenToggle:v.useCallback(()=>S(w=>!w),[S]),hasCustomAnchor:m,onCustomAnchorAdd:v.useCallback(()=>g(!0),[]),onCustomAnchorRemove:v.useCallback(()=>g(!1),[]),modal:f,children:l})})};ix.displayName=Lu;var ox="PopoverAnchor",IN=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(ox,l),u=Eo(l),{onCustomAnchorAdd:f,onCustomAnchorRemove:h}=s;return v.useEffect(()=>(f(),()=>h()),[f,h]),y.jsx(rx,{...u,...i,ref:a})});IN.displayName=ox;var sx="PopoverTrigger",ux=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(sx,l),u=Eo(l),f=fn(a,s.triggerRef),h=y.jsx(dt.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":mx(s.open),...i,ref:f,onClick:Zt(n.onClick,s.onOpenToggle)});return s.hasCustomAnchor?h:y.jsx(rx,{asChild:!0,...u,children:h})});ux.displayName=sx;var ph="PopoverPortal",[WN,eT]=lx(ph,{forceMount:void 0}),cx=n=>{const{__scopePopover:a,forceMount:l,children:i,container:s}=n,u=or(ph,a);return y.jsx(WN,{scope:a,forceMount:l,children:y.jsx(Ql,{present:l||u.open,children:y.jsx(Qd,{asChild:!0,container:s,children:i})})})};cx.displayName=ph;var Fl="PopoverContent",fx=v.forwardRef((n,a)=>{const l=eT(Fl,n.__scopePopover),{forceMount:i=l.forceMount,...s}=n,u=or(Fl,n.__scopePopover);return y.jsx(Ql,{present:i||u.open,children:u.modal?y.jsx(nT,{...s,ref:a}):y.jsx(aT,{...s,ref:a})})});fx.displayName=Fl;var tT=Ou("PopoverContent.RemoveScroll"),nT=v.forwardRef((n,a)=>{const l=or(Fl,n.__scopePopover),i=v.useRef(null),s=fn(a,i),u=v.useRef(!1);return v.useEffect(()=>{const f=i.current;if(f)return R0(f)},[]),y.jsx(Zd,{as:tT,allowPinchZoom:!0,children:y.jsx(dx,{...n,ref:s,trapFocus:l.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Zt(n.onCloseAutoFocus,f=>{f.preventDefault(),u.current||l.triggerRef.current?.focus()}),onPointerDownOutside:Zt(n.onPointerDownOutside,f=>{const h=f.detail.originalEvent,p=h.button===0&&h.ctrlKey===!0,m=h.button===2||p;u.current=m},{checkForDefaultPrevented:!1}),onFocusOutside:Zt(n.onFocusOutside,f=>f.preventDefault(),{checkForDefaultPrevented:!1})})})}),aT=v.forwardRef((n,a)=>{const l=or(Fl,n.__scopePopover),i=v.useRef(!1),s=v.useRef(!1);return y.jsx(dx,{...n,ref:a,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:u=>{n.onCloseAutoFocus?.(u),u.defaultPrevented||(i.current||l.triggerRef.current?.focus(),u.preventDefault()),i.current=!1,s.current=!1},onInteractOutside:u=>{n.onInteractOutside?.(u),u.defaultPrevented||(i.current=!0,u.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const f=u.target;l.triggerRef.current?.contains(f)&&u.preventDefault(),u.detail.originalEvent.type==="focusin"&&s.current&&u.preventDefault()}})}),dx=v.forwardRef((n,a)=>{const{__scopePopover:l,trapFocus:i,onOpenAutoFocus:s,onCloseAutoFocus:u,disableOutsidePointerEvents:f,onEscapeKeyDown:h,onPointerDownOutside:p,onFocusOutside:m,onInteractOutside:g,...x}=n,S=or(Fl,l),w=Eo(l);return p0(),y.jsx(Xd,{asChild:!0,loop:!0,trapped:i,onMountAutoFocus:s,onUnmountAutoFocus:u,children:y.jsx(Fd,{asChild:!0,disableOutsidePointerEvents:f,onInteractOutside:g,onEscapeKeyDown:h,onPointerDownOutside:p,onFocusOutside:m,onDismiss:()=>S.onOpenChange(!1),children:y.jsx(QN,{"data-state":mx(S.open),role:"dialog",id:S.contentId,...w,...x,ref:a,style:{...x.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),hx="PopoverClose",rT=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=or(hx,l);return y.jsx(dt.button,{type:"button",...i,ref:a,onClick:Zt(n.onClick,()=>s.onOpenChange(!1))})});rT.displayName=hx;var lT="PopoverArrow",iT=v.forwardRef((n,a)=>{const{__scopePopover:l,...i}=n,s=Eo(l);return y.jsx(ZN,{...s,...i,ref:a})});iT.displayName=lT;function mx(n){return n?"open":"closed"}var oT=ix,sT=ux,uT=cx,cT=fx;function gh({...n}){return y.jsx(oT,{"data-slot":"popover",...n})}function vh({...n}){return y.jsx(sT,{"data-slot":"popover-trigger",...n})}function yh({className:n,align:a="center",sideOffset:l=4,...i}){return y.jsx(uT,{children:y.jsx(cT,{"data-slot":"popover-content",align:a,sideOffset:l,className:ft("bg-popover text-popover-foreground 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-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden animate-fade-in",n),...i})})}function Wa({options:n,value:a,onChange:l,placeholder:i="Select an option...",searchPlaceholder:s="Search...",emptyPlaceholder:u="No options found."}){const[f,h]=v.useState(!1),p=n.find(m=>m.value===a);return y.jsxs(gh,{open:f,onOpenChange:h,children:[y.jsx(vh,{asChild:!0,children:y.jsxs(He,{variant:"outline",role:"combobox","aria-expanded":f,className:"w-full justify-between transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[p?p.label:i,y.jsx(G0,{className:"ml-2 h-4 w-4 shrink-0 opacity-50 transition-transform duration-200 group-data-[state=open]:rotate-180"})]})}),y.jsx(yh,{className:"w-[--radix-popover-trigger-width] p-0 animate-fade-in",children:y.jsxs(jb,{children:[y.jsx(Mb,{placeholder:s}),y.jsxs(_b,{children:[y.jsx(Db,{children:u}),y.jsx(Lb,{children:n.map(m=>y.jsxs(zb,{value:m.value,onSelect:g=>{l(g===a?"":g),h(!1)},className:"transition-all-ease hover:bg-accent hover:text-accent-foreground",children:[y.jsx(K0,{className:ft("mr-2 h-4 w-4 transition-opacity",a===m.value?"opacity-100":"opacity-0")}),m.label]},m.value))})]})]})})]})}const fT=v.forwardRef(({options:n,value:a,onChange:l,onEnter:i,searchPlaceholder:s="Search...",emptyPlaceholder:u="No options found.",inputPlaceholder:f="Type or select..."},h)=>{const[p,m]=v.useState(!1),[g,x]=v.useState(a||""),S=v.useRef(null);v.useImperativeHandle(h,()=>S.current),v.useEffect(()=>{x(a||"")},[a]);const w=O=>{const z=O.target.value;x(z),l(z)},C=O=>{O.key==="Enter"&&g.trim()&&i&&(i(g.trim()),x(""))},R=O=>{x(O),l(O),i&&(i(O),x("")),m(!1)},T=()=>g;return v.useImperativeHandle(h,()=>({...S.current,value:g,getCurrentValue:T,clearInput:()=>{x(""),l("")}})),y.jsxs("div",{className:"relative",children:[y.jsx(Rt,{ref:S,value:g,onChange:w,onKeyDown:C,placeholder:f,className:"pr-10"}),y.jsxs(gh,{open:p,onOpenChange:m,children:[y.jsx(vh,{asChild:!0,children:y.jsx(He,{variant:"ghost",size:"sm",className:"absolute right-0 top-0 h-full px-3 py-2 hover:bg-transparent",children:y.jsx(G0,{className:"h-4 w-4 opacity-50"})})}),y.jsx(yh,{className:"w-[--radix-popover-trigger-width] p-0 animate-fade-in",children:y.jsxs(jb,{children:[y.jsx(Mb,{placeholder:s}),y.jsxs(_b,{children:[y.jsx(Db,{children:u}),y.jsx(Lb,{children:n.map(O=>y.jsxs(zb,{value:O.value,onSelect:()=>R(O.value),className:"transition-all-ease hover:bg-accent hover:text-accent-foreground",children:[y.jsx(K0,{className:ft("mr-2 h-4 w-4 transition-opacity",a===O.value?"opacity-100":"opacity-0")}),O.label]},O.value))})]})]})})]})]})});function dT(){const{t:n}=$r(),{config:a,setConfig:l}=Il(),[i,s]=v.useState(null),[u,f]=v.useState(null),[h,p]=v.useState({}),[m,g]=v.useState({}),[x,S]=v.useState({}),[w,C]=v.useState([]),[R,T]=v.useState(null),[O,z]=v.useState(!1),[k,H]=v.useState([]),[P,A]=v.useState({}),[G,J]=v.useState(null),[re,ie]=v.useState(null),Oe=v.useRef(null);if(v.useEffect(()=>{(async()=>{try{const te=await fetch("https://pub-0dc3e1677e894f07bbea11b17a29e032.r2.dev/providers.json");if(te.ok){const se=await te.json();H(se||[])}else console.error("Failed to fetch provider templates")}catch(te){console.error("Failed to fetch provider templates:",te)}})()},[]),v.useEffect(()=>{(async()=>{try{const te=await un.get("/transformers");C(te.transformers)}catch(te){console.error("Failed to fetch transformers:",te)}})()},[]),!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("providers.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading providers configuration..."})})]});const Ee=Array.isArray(a.Providers)?a.Providers:[],me=()=>{const ae={name:"",api_base_url:"",api_key:"",models:[]};s(a.Providers.length),T(ae),z(!0),A(te=>({...te,[a.Providers.length]:!1})),J(null),ie(null)},he=ae=>{const te=a.Providers[ae];s(ae),T(JSON.parse(JSON.stringify(te))),z(!1),A(se=>({...se,[ae]:!1})),J(null),ie(null)},fe=()=>{if(!R)return;if(!R.name||R.name.trim()===""){ie(n("providers.name_required"));return}const ae=R.name.trim();if(a.Providers.some((se,ue)=>!O&&ue===i?!1:se.name.toLowerCase()===ae.toLowerCase())){ie(n("providers.name_duplicate"));return}if(!R.api_key||R.api_key.trim()===""){J(n("providers.api_key_required"));return}if(J(null),ie(null),i!==null&&R){const se=[...a.Providers];O?se.push(R):se[i]=R,l({...a,Providers:se})}i!==null&&A(se=>{const ue={...se};return delete ue[i],ue}),s(null),T(null),z(!1)},_=()=>{i!==null&&(p(ae=>{const te={...ae};return delete te[i],te}),A(ae=>{const te={...ae};return delete te[i],te})),s(null),T(null),z(!1),J(null),ie(null)},Z=ae=>{const te=[...a.Providers];te.splice(ae,1),l({...a,Providers:te}),f(null)},$=(ae,te,se)=>{if(R){const ue={...R,[te]:se};T(ue)}},pe=(ae,te)=>{if(!te||!R)return;const se={...R};se.transformer||(se.transformer={use:[]}),se.transformer.use=[...se.transformer.use,te],T(se)},N=(ae,te)=>{if(!R)return;const se={...R};if(se.transformer){const ue=[...se.transformer.use];ue.splice(te,1),se.transformer.use=ue,ue.length===0&&Object.keys(se.transformer).length===1&&delete se.transformer}T(se)},Y=(ae,te,se)=>{if(!se||!R)return;const ue={...R};ue.transformer||(ue.transformer={use:[]}),ue.transformer[te]||(ue.transformer[te]={use:[]}),ue.transformer[te].use=[...ue.transformer[te].use,se],T(ue)},L=(ae,te,se)=>{if(!R)return;const ue={...R};if(ue.transformer&&ue.transformer[te]){const Ne=[...ue.transformer[te].use];Ne.splice(se,1),ue.transformer[te].use=Ne,Ne.length===0&&Object.keys(ue.transformer[te]).length===1&&delete ue.transformer[te]}T(ue)},K=(ae,te,se,ue)=>{if(!R)return;const Ne={...R};if(Ne.transformer||(Ne.transformer={use:[]}),Ne.transformer.use&&Ne.transformer.use.length>te){const Ue=Ne.transformer.use[te];if(Array.isArray(Ue)){const Me=[...Ue];if(Me.length>1&&typeof Me[1]=="object"&&Me[1]!==null){const Cn={...Me[1],[se]:ue};Me[1]=Cn}else if(Me.length>1){const ot={[se]:ue};Me.splice(1,Me.length-1,ot)}else{const ot={[se]:ue};Me.push(ot)}Ne.transformer.use[te]=Me}else{const Me={[se]:ue};Ne.transformer.use[te]=[Ue,Me]}}T(Ne)},W=(ae,te,se)=>{if(!R)return;const ue={...R};if(!ue.transformer?.use||ue.transformer.use.length<=te)return;const Ne=ue.transformer.use[te];if(Array.isArray(Ne)&&Ne.length>1){const Ue=[...Ne];if(typeof Ue[1]=="object"&&Ue[1]!==null){const Me={...Ue[1]};delete Me[se],Object.keys(Me).length===0?Ue.splice(1,1):Ue[1]=Me,ue.transformer.use[te]=Ue,T(ue)}}},oe=(ae,te,se,ue,Ne)=>{if(!R)return;const Ue={...R};if(Ue.transformer||(Ue.transformer={use:[]}),Ue.transformer[te]||(Ue.transformer[te]={use:[]}),Ue.transformer[te].use&&Ue.transformer[te].use.length>se){const Me=Ue.transformer[te].use[se];if(Array.isArray(Me)){const ot=[...Me];if(ot.length>1&&typeof ot[1]=="object"&&ot[1]!==null){const qr={...ot[1],[ue]:Ne};ot[1]=qr}else if(ot.length>1){const Cn={[ue]:Ne};ot.splice(1,ot.length-1,Cn)}else{const Cn={[ue]:Ne};ot.push(Cn)}Ue.transformer[te].use[se]=ot}else{const ot={[ue]:Ne};Ue.transformer[te].use[se]=[Me,ot]}}T(Ue)},de=(ae,te,se,ue)=>{if(!R)return;const Ne={...R};if(!Ne.transformer?.[te]?.use||Ne.transformer[te].use.length<=se)return;const Ue=Ne.transformer[te].use[se];if(Array.isArray(Ue)&&Ue.length>1){const Me=[...Ue];if(typeof Me[1]=="object"&&Me[1]!==null){const ot={...Me[1]};delete ot[ue],Object.keys(ot).length===0?Me.splice(1,1):Me[1]=ot,Ne.transformer[te].use[se]=Me,T(Ne)}}},ge=(ae,te)=>{if(!te.trim()||!R)return;const se={...R},ue=Array.isArray(se.models)?[...se.models]:[];ue.includes(te.trim())||(ue.push(te.trim()),se.models=ue,T(se))},ze=ae=>{if(ae)try{const te=JSON.parse(ae);if(te){const se=R?.name,ue=JSON.parse(JSON.stringify(te));!O&&se&&(ue.name=se),T(ue)}}catch(te){console.error("Failed to parse template",te)}},Ze=(ae,te)=>{if(!R)return;const se={...R},ue=Array.isArray(se.models)?[...se.models]:[];te>=0&&te<ue.length&&(ue.splice(te,1),se.models=ue,T(se))},je=R||(i!==null?Ee[i]:null);return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsxs(ya,{className:"flex flex-row items-center justify-between border-b p-4",children:[y.jsxs(ba,{className:"text-lg",children:[n("providers.title")," ",y.jsxs("span",{className:"text-sm font-normal text-gray-500",children:["(",Ee.length,")"]})]}),y.jsx(He,{onClick:me,children:n("providers.add")})]}),y.jsx(xa,{className:"flex-grow overflow-y-auto p-4",children:y.jsx(lA,{providers:Ee,onEdit:he,onRemove:f})}),y.jsx(mo,{open:i!==null,onOpenChange:ae=>{ae||_()},children:y.jsxs(ql,{className:"max-h-[80vh] flex flex-col sm:max-w-2xl",children:[y.jsx(Yl,{children:y.jsx(Kl,{children:n("providers.edit")})}),je&&i!==null&&y.jsxs("div",{className:"space-y-4 p-4 overflow-y-auto flex-grow",children:[k.length>0&&y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.import_from_template")}),y.jsx(Wa,{options:k.map(ae=>({label:ae.name,value:JSON.stringify(ae)})),value:"",onChange:ze,placeholder:n("providers.select_template"),emptyPlaceholder:n("providers.no_templates_found")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"name",children:n("providers.name")}),y.jsx(Rt,{id:"name",value:je.name||"",onChange:ae=>{$(i,"name",ae.target.value),re&&ie(null)},className:re?"border-red-500":""}),re&&y.jsx("p",{className:"text-sm text-red-500",children:re})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"api_base_url",children:n("providers.api_base_url")}),y.jsx(Rt,{id:"api_base_url",value:je.api_base_url||"",onChange:ae=>$(i,"api_base_url",ae.target.value)})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"api_key",children:n("providers.api_key")}),y.jsxs("div",{className:"relative",children:[y.jsx(Rt,{id:"api_key",type:P[i||0]?"text":"password",value:je.api_key||"",onChange:ae=>$(i,"api_key",ae.target.value),className:G?"border-red-500":""}),y.jsx(He,{type:"button",variant:"ghost",size:"icon",className:"absolute right-2 top-1/2 transform -translate-y-1/2 h-8 w-8",onClick:()=>{const ae=i||0;A(te=>({...te,[ae]:!te[ae]}))},children:P[i||0]?y.jsx(G2,{className:"h-4 w-4"}):y.jsx(X2,{className:"h-4 w-4"})})]}),G&&y.jsx("p",{className:"text-sm text-red-500",children:G})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"models",children:n("providers.models")}),y.jsxs("div",{className:"space-y-2",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx("div",{className:"flex-1",children:h[i]?y.jsx(fT,{ref:Oe,options:(je.models||[]).map(ae=>({label:ae,value:ae})),value:"",onChange:()=>{},onEnter:ae=>{i!==null&&ge(i,ae)},inputPlaceholder:n("providers.models_placeholder")}):y.jsx(Rt,{id:"models",placeholder:n("providers.models_placeholder"),onKeyDown:ae=>{ae.key==="Enter"&&ae.currentTarget.value.trim()&&i!==null&&(ge(i,ae.currentTarget.value),ae.currentTarget.value="")}})}),y.jsx(He,{onClick:()=>{if(h[i]&&Oe.current){const ae=Oe.current,te=ae.getCurrentValue();te&&te.trim()&&i!==null&&(ge(i,te.trim()),ae.clearInput())}else{const ae=document.getElementById("models");ae&&ae.value.trim()&&i!==null&&(ge(i,ae.value),ae.value="")}},children:n("providers.add_model")})]}),y.jsx("div",{className:"flex flex-wrap gap-2 pt-2",children:(je.models||[]).map((ae,te)=>y.jsxs(Sb,{variant:"outline",className:"font-normal flex items-center gap-1",children:[ae,y.jsx("button",{type:"button",className:"ml-1 rounded-full hover:bg-gray-200",onClick:()=>i!==null&&Ze(i,te),children:y.jsx(Bl,{className:"h-3 w-3"})})]},te))})]})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.provider_transformer")}),y.jsx("div",{className:"flex gap-2",children:y.jsx(Wa,{options:w.map(ae=>({label:ae.name,value:ae.name})),value:"",onChange:ae=>{i!==null&&pe(i,ae)},placeholder:n("providers.select_transformer"),emptyPlaceholder:n("providers.no_transformers")})}),je.transformer?.use&&je.transformer.use.length>0&&y.jsxs("div",{className:"space-y-2 mt-2",children:[y.jsx("div",{className:"text-sm font-medium text-gray-700",children:n("providers.selected_transformers")}),je.transformer.use.map((ae,te)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsxs("div",{className:"flex gap-2 items-center mb-2",children:[y.jsx("div",{className:"flex-1 bg-gray-50 rounded p-2 text-sm",children:typeof ae=="string"?ae:Array.isArray(ae)?String(ae[0]):String(ae)}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{i!==null&&N(i,te)},children:y.jsx(Pr,{className:"h-4 w-4"})})]}),y.jsxs("div",{className:"mt-2 pl-4 border-l-2 border-gray-200",children:[y.jsx(ct,{className:"text-sm",children:n("providers.transformer_parameters")}),y.jsxs("div",{className:"space-y-2 mt-1",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx(Rt,{placeholder:n("providers.parameter_name"),value:m[`provider-${i}-transformer-${te}`]?.name||"",onChange:se=>{const ue=`provider-${i}-transformer-${te}`;g(Ne=>({...Ne,[ue]:{...Ne[ue]||{name:"",value:""},name:se.target.value}}))}}),y.jsx(Rt,{placeholder:n("providers.parameter_value"),value:m[`provider-${i}-transformer-${te}`]?.value||"",onChange:se=>{const ue=`provider-${i}-transformer-${te}`;g(Ne=>({...Ne,[ue]:{...Ne[ue]||{name:"",value:""},value:se.target.value}}))}}),y.jsx(He,{size:"sm",onClick:()=>{if(i!==null){const se=`provider-${i}-transformer-${te}`,ue=m[se];ue&&ue.name&&ue.value&&(K(i,te,ue.name,ue.value),g(Ne=>({...Ne,[se]:{name:"",value:""}})))}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),(()=>{if(!je.transformer?.use||je.transformer.use.length<=te)return null;const se=je.transformer.use[te];let ue={};return Array.isArray(se)&&se.length>1&&typeof se[1]=="object"&&se[1]!==null&&(ue=se[1]),Object.keys(ue).length>0?y.jsx("div",{className:"space-y-1",children:Object.entries(ue).map(([Ne,Ue])=>y.jsxs("div",{className:"flex items-center justify-between bg-gray-50 rounded p-2",children:[y.jsxs("div",{className:"text-sm",children:[y.jsxs("span",{className:"font-medium",children:[Ne,":"]})," ",String(Ue)]}),y.jsx(He,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>{i!==null&&W(i,te,Ne)},children:y.jsx(Bl,{className:"h-3 w-3"})})]},Ne))}):null})()]})]})]},te))]})]}),je.models&&je.models.length>0&&y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("providers.model_transformers")}),y.jsx("div",{className:"space-y-3",children:(je.models||[]).map((ae,te)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsx("div",{className:"font-medium text-sm mb-2",children:ae}),y.jsx("div",{className:"flex gap-2",children:y.jsx("div",{className:"flex-1 flex gap-2",children:y.jsx(Wa,{options:w.map(se=>({label:se.name,value:se.name})),value:"",onChange:se=>{i!==null&&Y(i,ae,se)},placeholder:n("providers.select_transformer"),emptyPlaceholder:n("providers.no_transformers")})})}),je.transformer?.[ae]?.use&&je.transformer[ae].use.length>0&&y.jsxs("div",{className:"space-y-2 mt-2",children:[y.jsx("div",{className:"text-sm font-medium text-gray-700",children:n("providers.selected_transformers")}),je.transformer[ae].use.map((se,ue)=>y.jsxs("div",{className:"border rounded-md p-3",children:[y.jsxs("div",{className:"flex gap-2 items-center mb-2",children:[y.jsx("div",{className:"flex-1 bg-gray-50 rounded p-2 text-sm",children:typeof se=="string"?se:Array.isArray(se)?String(se[0]):String(se)}),y.jsx(He,{variant:"outline",size:"icon",onClick:()=>{i!==null&&L(i,ae,ue)},children:y.jsx(Pr,{className:"h-4 w-4"})})]}),y.jsxs("div",{className:"mt-2 pl-4 border-l-2 border-gray-200",children:[y.jsx(ct,{className:"text-sm",children:n("providers.transformer_parameters")}),y.jsxs("div",{className:"space-y-2 mt-1",children:[y.jsxs("div",{className:"flex gap-2",children:[y.jsx(Rt,{placeholder:n("providers.parameter_name"),value:x[`model-${i}-${ae}-transformer-${ue}`]?.name||"",onChange:Ne=>{const Ue=`model-${i}-${ae}-transformer-${ue}`;S(Me=>({...Me,[Ue]:{...Me[Ue]||{name:"",value:""},name:Ne.target.value}}))}}),y.jsx(Rt,{placeholder:n("providers.parameter_value"),value:x[`model-${i}-${ae}-transformer-${ue}`]?.value||"",onChange:Ne=>{const Ue=`model-${i}-${ae}-transformer-${ue}`;S(Me=>({...Me,[Ue]:{...Me[Ue]||{name:"",value:""},value:Ne.target.value}}))}}),y.jsx(He,{size:"sm",onClick:()=>{if(i!==null){const Ne=`model-${i}-${ae}-transformer-${ue}`,Ue=x[Ne];Ue&&Ue.name&&Ue.value&&(oe(i,ae,ue,Ue.name,Ue.value),S(Me=>({...Me,[Ne]:{name:"",value:""}})))}},children:y.jsx(Nd,{className:"h-4 w-4"})})]}),(()=>{if(!je.transformer?.[ae]?.use||je.transformer[ae].use.length<=ue)return null;const Ne=je.transformer[ae].use[ue];let Ue={};return Array.isArray(Ne)&&Ne.length>1&&typeof Ne[1]=="object"&&Ne[1]!==null&&(Ue=Ne[1]),Object.keys(Ue).length>0?y.jsx("div",{className:"space-y-1",children:Object.entries(Ue).map(([Me,ot])=>y.jsxs("div",{className:"flex items-center justify-between bg-gray-50 rounded p-2",children:[y.jsxs("div",{className:"text-sm",children:[y.jsxs("span",{className:"font-medium",children:[Me,":"]})," ",String(ot)]}),y.jsx(He,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>{i!==null&&de(i,ae,ue,Me)},children:y.jsx(Bl,{className:"h-3 w-3"})})]},Me))}):null})()]})]})]},ue))]})]},te))})]})]}),y.jsx("div",{className:"space-y-3 mt-auto",children:y.jsx("div",{className:"flex justify-end gap-2",children:y.jsx(He,{onClick:fe,children:n("app.save")})})})]})}),y.jsx(mo,{open:u!==null,onOpenChange:()=>f(null),children:y.jsxs(ql,{children:[y.jsxs(Yl,{children:[y.jsx(Kl,{children:n("providers.delete")}),y.jsx(ah,{children:n("providers.delete_provider_confirm")})]}),y.jsxs(po,{children:[y.jsx(He,{variant:"outline",onClick:()=>f(null),children:n("providers.cancel")}),y.jsx(He,{variant:"destructive",onClick:()=>u!==null&&Z(u),children:n("providers.delete")})]})]})})]})}function hT(){const{t:n}=$r(),{config:a,setConfig:l}=Il();if(!a)return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("router.title")})}),y.jsx(xa,{className:"flex-grow flex items-center justify-center p-4",children:y.jsx("div",{className:"text-gray-500",children:"Loading router configuration..."})})]});const i=a.Router||{default:"",background:"",think:"",longContext:"",longContextThreshold:6e4,webSearch:""},s=(h,p)=>{const g={...a.Router||{},[h]:p};l({...a,Router:g})},f=(Array.isArray(a.Providers)?a.Providers:[]).flatMap(h=>{if(!h)return[];const p=Array.isArray(h.models)?h.models:[],m=h.name||"Unknown Provider";return p.map(g=>({value:`${m},${g||"Unknown Model"}`,label:`${m}, ${g||"Unknown Model"}`}))});return y.jsxs(va,{className:"flex h-full flex-col rounded-lg border shadow-sm",children:[y.jsx(ya,{className:"border-b p-4",children:y.jsx(ba,{className:"text-lg",children:n("router.title")})}),y.jsxs(xa,{className:"flex-grow space-y-5 overflow-y-auto p-4",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.default")}),y.jsx(Wa,{options:f,value:i.default||"",onChange:h=>s("default",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.background")}),y.jsx(Wa,{options:f,value:i.background||"",onChange:h=>s("background",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.think")}),y.jsx(Wa,{options:f,value:i.think||"",onChange:h=>s("think",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsx("div",{className:"space-y-2",children:y.jsxs("div",{className:"flex items-center gap-4",children:[y.jsxs("div",{className:"flex-1",children:[y.jsx(ct,{children:n("router.longContext")}),y.jsx(Wa,{options:f,value:i.longContext||"",onChange:h=>s("longContext",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]}),y.jsxs("div",{className:"w-48",children:[y.jsx(ct,{children:n("router.longContextThreshold")}),y.jsx(Rt,{type:"number",value:i.longContextThreshold||6e4,onChange:h=>s("longContextThreshold",parseInt(h.target.value)||6e4),placeholder:"60000"})]})]})}),y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{children:n("router.webSearch")}),y.jsx(Wa,{options:f,value:i.webSearch||"",onChange:h=>s("webSearch",h),placeholder:n("router.selectModel"),searchPlaceholder:n("router.searchModel"),emptyPlaceholder:n("router.noModelFound")})]})]})]})}function mT(n,a,l){return a in n?Object.defineProperty(n,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):n[a]=l,n}function Cy(n,a){var l=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);a&&(i=i.filter(function(s){return Object.getOwnPropertyDescriptor(n,s).enumerable})),l.push.apply(l,i)}return l}function Oy(n){for(var a=1;a<arguments.length;a++){var l=arguments[a]!=null?arguments[a]:{};a%2?Cy(Object(l),!0).forEach(function(i){mT(n,i,l[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(l)):Cy(Object(l)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(l,i))})}return n}function pT(n,a){if(n==null)return{};var l={},i=Object.keys(n),s,u;for(u=0;u<i.length;u++)s=i[u],!(a.indexOf(s)>=0)&&(l[s]=n[s]);return l}function gT(n,a){if(n==null)return{};var l=pT(n,a),i,s;if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);for(s=0;s<u.length;s++)i=u[s],!(a.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(n,i)&&(l[i]=n[i])}return l}function vT(n,a){return yT(n)||bT(n,a)||xT(n,a)||ST()}function yT(n){if(Array.isArray(n))return n}function bT(n,a){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(n)))){var l=[],i=!0,s=!1,u=void 0;try{for(var f=n[Symbol.iterator](),h;!(i=(h=f.next()).done)&&(l.push(h.value),!(a&&l.length===a));i=!0);}catch(p){s=!0,u=p}finally{try{!i&&f.return!=null&&f.return()}finally{if(s)throw u}}return l}}function xT(n,a){if(n){if(typeof n=="string")return Ay(n,a);var l=Object.prototype.toString.call(n).slice(8,-1);if(l==="Object"&&n.constructor&&(l=n.constructor.name),l==="Map"||l==="Set")return Array.from(n);if(l==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(l))return Ay(n,a)}}function Ay(n,a){(a==null||a>n.length)&&(a=n.length);for(var l=0,i=new Array(a);l<a;l++)i[l]=n[l];return i}function ST(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
217
217
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function wT(n,a,l){return a in n?Object.defineProperty(n,a,{value:l,enumerable:!0,configurable:!0,writable:!0}):n[a]=l,n}function Ny(n,a){var l=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);a&&(i=i.filter(function(s){return Object.getOwnPropertyDescriptor(n,s).enumerable})),l.push.apply(l,i)}return l}function Ty(n){for(var a=1;a<arguments.length;a++){var l=arguments[a]!=null?arguments[a]:{};a%2?Ny(Object(l),!0).forEach(function(i){wT(n,i,l[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(l)):Ny(Object(l)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(l,i))})}return n}function ET(){for(var n=arguments.length,a=new Array(n),l=0;l<n;l++)a[l]=arguments[l];return function(i){return a.reduceRight(function(s,u){return u(s)},i)}}function io(n){return function a(){for(var l=this,i=arguments.length,s=new Array(i),u=0;u<i;u++)s[u]=arguments[u];return s.length>=n.length?n.apply(this,s):function(){for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];return a.apply(l,[].concat(s,h))}}}function vu(n){return{}.toString.call(n).includes("Object")}function RT(n){return!Object.keys(n).length}function yo(n){return typeof n=="function"}function CT(n,a){return Object.prototype.hasOwnProperty.call(n,a)}function OT(n,a){return vu(a)||er("changeType"),Object.keys(a).some(function(l){return!CT(n,l)})&&er("changeField"),a}function AT(n){yo(n)||er("selectorType")}function NT(n){yo(n)||vu(n)||er("handlerType"),vu(n)&&Object.values(n).some(function(a){return!yo(a)})&&er("handlersType")}function TT(n){n||er("initialIsRequired"),vu(n)||er("initialType"),RT(n)&&er("initialContent")}function jT(n,a){throw new Error(n[a]||n.default)}var MT={initialIsRequired:"initial state is required",initialType:"initial state should be an object",initialContent:"initial state shouldn't be an empty object",handlerType:"handler should be an object or a function",handlersType:"all handlers should be a functions",selectorType:"selector should be a function",changeType:"provided value of changes should be an object",changeField:'it seams you want to change a field in the state which is not specified in the "initial" state',default:"an unknown error accured in `state-local` package"},er=io(jT)(MT),Js={changes:OT,selector:AT,handler:NT,initial:TT};function _T(n){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Js.initial(n),Js.handler(a);var l={current:n},i=io(zT)(l,a),s=io(LT)(l),u=io(Js.changes)(n),f=io(DT)(l);function h(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(g){return g};return Js.selector(m),m(l.current)}function p(m){ET(i,s,u,f)(m)}return[h,p]}function DT(n,a){return yo(a)?a(n.current):a}function LT(n,a){return n.current=Ty(Ty({},n.current),a),a}function zT(n,a,l){return yo(a)?a(n.current):Object.keys(l).forEach(function(i){var s;return(s=a[i])===null||s===void 0?void 0:s.call(a,n.current[i])}),l}var kT={create:_T},UT={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.52.2/min/vs"}};function PT(n){return function a(){for(var l=this,i=arguments.length,s=new Array(i),u=0;u<i;u++)s[u]=arguments[u];return s.length>=n.length?n.apply(this,s):function(){for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];return a.apply(l,[].concat(s,h))}}}function HT(n){return{}.toString.call(n).includes("Object")}function BT(n){return n||jy("configIsRequired"),HT(n)||jy("configType"),n.urls?($T(),{paths:{vs:n.urls.monacoBase}}):n}function $T(){console.warn(px.deprecation)}function VT(n,a){throw new Error(n[a]||n.default)}var px={configIsRequired:"the configuration object is required",configType:"the configuration object should be an object",default:"an unknown error accured in `@monaco-editor/loader` package",deprecation:`Deprecation warning!
|
|
218
218
|
You are using deprecated way of configuration.
|
|
219
219
|
|
|
@@ -223,7 +223,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
223
223
|
monaco.config({ paths: { vs: '...' } })
|
|
224
224
|
|
|
225
225
|
For more please check the link https://github.com/suren-atoyan/monaco-loader#config
|
|
226
|
-
`},jy=PT(VT)(px),qT={config:BT},YT=function(){for(var a=arguments.length,l=new Array(a),i=0;i<a;i++)l[i]=arguments[i];return function(s){return l.reduceRight(function(u,f){return f(u)},s)}};function gx(n,a){return Object.keys(a).forEach(function(l){a[l]instanceof Object&&n[l]&&Object.assign(a[l],gx(n[l],a[l]))}),Oy(Oy({},n),a)}var KT={type:"cancelation",msg:"operation is manually canceled"};function hd(n){var a=!1,l=new Promise(function(i,s){n.then(function(u){return a?s(KT):i(u)}),n.catch(s)});return l.cancel=function(){return a=!0},l}var GT=kT.create({config:UT,isInitialized:!1,resolve:null,reject:null,monaco:null}),vx=vT(GT,2),Ro=vx[0],zu=vx[1];function FT(n){var a=qT.config(n),l=a.monaco,i=gT(a,["monaco"]);zu(function(s){return{config:gx(s.config,i),monaco:l}})}function XT(){var n=Ro(function(a){var l=a.monaco,i=a.isInitialized,s=a.resolve;return{monaco:l,isInitialized:i,resolve:s}});if(!n.isInitialized){if(zu({isInitialized:!0}),n.monaco)return n.resolve(n.monaco),hd(md);if(window.monaco&&window.monaco.editor)return yx(window.monaco),n.resolve(window.monaco),hd(md);YT(QT,JT)(IT)}return hd(md)}function QT(n){return document.body.appendChild(n)}function ZT(n){var a=document.createElement("script");return n&&(a.src=n),a}function JT(n){var a=Ro(function(i){var s=i.config,u=i.reject;return{config:s,reject:u}}),l=ZT("".concat(a.config.paths.vs,"/loader.js"));return l.onload=function(){return n()},l.onerror=a.reject,l}function IT(){var n=Ro(function(l){var i=l.config,s=l.resolve,u=l.reject;return{config:i,resolve:s,reject:u}}),a=window.require;a.config(n.config),a(["vs/editor/editor.main"],function(l){yx(l),n.resolve(l)},function(l){n.reject(l)})}function yx(n){Ro().monaco||zu({monaco:n})}function WT(){return Ro(function(n){var a=n.monaco;return a})}var md=new Promise(function(n,a){return zu({resolve:n,reject:a})}),bx={config:FT,init:XT,__getMonacoInstance:WT},ej={wrapper:{display:"flex",position:"relative",textAlign:"initial"},fullWidth:{width:"100%"},hide:{display:"none"}},pd=ej,tj={container:{display:"flex",height:"100%",width:"100%",justifyContent:"center",alignItems:"center"}},nj=tj;function aj({children:n}){return Lr.createElement("div",{style:nj.container},n)}var rj=aj,lj=rj;function ij({width:n,height:a,isEditorReady:l,loading:i,_ref:s,className:u,wrapperProps:f}){return Lr.createElement("section",{style:{...pd.wrapper,width:n,height:a},...f},!l&&Lr.createElement(lj,null,i),Lr.createElement("div",{ref:s,style:{...pd.fullWidth,...!l&&pd.hide},className:u}))}var oj=ij,xx=v.memo(oj);function sj(n){v.useEffect(n,[])}var Sx=sj;function uj(n,a,l=!0){let i=v.useRef(!0);v.useEffect(i.current||!l?()=>{i.current=!1}:n,a)}var sn=uj;function so(){}function Ul(n,a,l,i){return cj(n,i)||fj(n,a,l,i)}function cj(n,a){return n.editor.getModel(wx(n,a))}function fj(n,a,l,i){return n.editor.createModel(a,l,i?wx(n,i):void 0)}function wx(n,a){return n.Uri.parse(a)}function dj({original:n,modified:a,language:l,originalLanguage:i,modifiedLanguage:s,originalModelPath:u,modifiedModelPath:f,keepCurrentOriginalModel:h=!1,keepCurrentModifiedModel:p=!1,theme:m="light",loading:g="Loading...",options:x={},height:S="100%",width:w="100%",className:C,wrapperProps:R={},beforeMount:T=so,onMount:O=so}){let[z,k]=v.useState(!1),[H,P]=v.useState(!0),A=v.useRef(null),G=v.useRef(null),J=v.useRef(null),re=v.useRef(O),ie=v.useRef(T),Oe=v.useRef(!1);Sx(()=>{let fe=bx.init();return fe.then(_=>(G.current=_)&&P(!1)).catch(_=>_?.type!=="cancelation"&&console.error("Monaco initialization: error:",_)),()=>A.current?he():fe.cancel()}),sn(()=>{if(A.current&&G.current){let fe=A.current.getOriginalEditor(),_=Ul(G.current,n||"",i||l||"text",u||"");_!==fe.getModel()&&fe.setModel(_)}},[u],z),sn(()=>{if(A.current&&G.current){let fe=A.current.getModifiedEditor(),_=Ul(G.current,a||"",s||l||"text",f||"");_!==fe.getModel()&&fe.setModel(_)}},[f],z),sn(()=>{let fe=A.current.getModifiedEditor();fe.getOption(G.current.editor.EditorOption.readOnly)?fe.setValue(a||""):a!==fe.getValue()&&(fe.executeEdits("",[{range:fe.getModel().getFullModelRange(),text:a||"",forceMoveMarkers:!0}]),fe.pushUndoStop())},[a],z),sn(()=>{A.current?.getModel()?.original.setValue(n||"")},[n],z),sn(()=>{let{original:fe,modified:_}=A.current.getModel();G.current.editor.setModelLanguage(fe,i||l||"text"),G.current.editor.setModelLanguage(_,s||l||"text")},[l,i,s],z),sn(()=>{G.current?.editor.setTheme(m)},[m],z),sn(()=>{A.current?.updateOptions(x)},[x],z);let Ee=v.useCallback(()=>{if(!G.current)return;ie.current(G.current);let fe=Ul(G.current,n||"",i||l||"text",u||""),_=Ul(G.current,a||"",s||l||"text",f||"");A.current?.setModel({original:fe,modified:_})},[l,a,s,n,i,u,f]),me=v.useCallback(()=>{!Oe.current&&J.current&&(A.current=G.current.editor.createDiffEditor(J.current,{automaticLayout:!0,...x}),Ee(),G.current?.editor.setTheme(m),k(!0),Oe.current=!0)},[x,m,Ee]);v.useEffect(()=>{z&&re.current(A.current,G.current)},[z]),v.useEffect(()=>{!H&&!z&&me()},[H,z,me]);function he(){let fe=A.current?.getModel();h||fe?.original?.dispose(),p||fe?.modified?.dispose(),A.current?.dispose()}return Lr.createElement(xx,{width:w,height:S,isEditorReady:z,loading:g,_ref:J,className:C,wrapperProps:R})}var hj=dj;v.memo(hj);function mj(n){let a=v.useRef();return v.useEffect(()=>{a.current=n},[n]),a.current}var pj=mj,Is=new Map;function gj({defaultValue:n,defaultLanguage:a,defaultPath:l,value:i,language:s,path:u,theme:f="light",line:h,loading:p="Loading...",options:m={},overrideServices:g={},saveViewState:x=!0,keepCurrentModel:S=!1,width:w="100%",height:C="100%",className:R,wrapperProps:T={},beforeMount:O=so,onMount:z=so,onChange:k,onValidate:H=so}){let[P,A]=v.useState(!1),[G,J]=v.useState(!0),re=v.useRef(null),ie=v.useRef(null),Oe=v.useRef(null),Ee=v.useRef(z),me=v.useRef(O),he=v.useRef(),fe=v.useRef(i),_=pj(u),Z=v.useRef(!1),$=v.useRef(!1);Sx(()=>{let Y=bx.init();return Y.then(L=>(re.current=L)&&J(!1)).catch(L=>L?.type!=="cancelation"&&console.error("Monaco initialization: error:",L)),()=>ie.current?N():Y.cancel()}),sn(()=>{let Y=Ul(re.current,n||i||"",a||s||"",u||l||"");Y!==ie.current?.getModel()&&(x&&Is.set(_,ie.current?.saveViewState()),ie.current?.setModel(Y),x&&ie.current?.restoreViewState(Is.get(u)))},[u],P),sn(()=>{ie.current?.updateOptions(m)},[m],P),sn(()=>{!ie.current||i===void 0||(ie.current.getOption(re.current.editor.EditorOption.readOnly)?ie.current.setValue(i):i!==ie.current.getValue()&&($.current=!0,ie.current.executeEdits("",[{range:ie.current.getModel().getFullModelRange(),text:i,forceMoveMarkers:!0}]),ie.current.pushUndoStop(),$.current=!1))},[i],P),sn(()=>{let Y=ie.current?.getModel();Y&&s&&re.current?.editor.setModelLanguage(Y,s)},[s],P),sn(()=>{h!==void 0&&ie.current?.revealLine(h)},[h],P),sn(()=>{re.current?.editor.setTheme(f)},[f],P);let pe=v.useCallback(()=>{if(!(!Oe.current||!re.current)&&!Z.current){me.current(re.current);let Y=u||l,L=Ul(re.current,i||n||"",a||s||"",Y||"");ie.current=re.current?.editor.create(Oe.current,{model:L,automaticLayout:!0,...m},g),x&&ie.current.restoreViewState(Is.get(Y)),re.current.editor.setTheme(f),h!==void 0&&ie.current.revealLine(h),A(!0),Z.current=!0}},[n,a,l,i,s,u,m,g,x,f,h]);v.useEffect(()=>{P&&Ee.current(ie.current,re.current)},[P]),v.useEffect(()=>{!G&&!P&&pe()},[G,P,pe]),fe.current=i,v.useEffect(()=>{P&&k&&(he.current?.dispose(),he.current=ie.current?.onDidChangeModelContent(Y=>{$.current||k(ie.current.getValue(),Y)}))},[P,k]),v.useEffect(()=>{if(P){let Y=re.current.editor.onDidChangeMarkers(L=>{let K=ie.current.getModel()?.uri;if(K&&L.find(W=>W.path===K.path)){let W=re.current.editor.getModelMarkers({resource:K});H?.(W)}});return()=>{Y?.dispose()}}return()=>{}},[P,H]);function N(){he.current?.dispose(),S?x&&Is.set(u,ie.current.saveViewState()):ie.current.getModel()?.dispose(),ie.current.dispose()}return Lr.createElement(xx,{width:w,height:C,isEditorReady:P,loading:p,_ref:Oe,className:R,wrapperProps:T})}var vj=gj,yj=v.memo(vj),bj=yj;function xj({open:n,onOpenChange:a,showToast:l}){const{t:i}=$r(),{config:s}=Il(),[u,f]=v.useState(""),[h,p]=v.useState(!1),[m,g]=v.useState(!1),[x,S]=v.useState(!1),w=v.useRef(null);v.useEffect(()=>{s&&n&&f(JSON.stringify(s,null,2))},[s,n]),v.useEffect(()=>{if(n)g(!0),requestAnimationFrame(()=>{S(!0)});else{S(!1);const O=setTimeout(()=>{g(!1)},300);return()=>clearTimeout(O)}},[n]);const C=(O,z,k)=>{if(O&&typeof O=="object"&&"success"in O){const H=O;return H.success?(l&&l(H.message||z,"success"),!0):(l&&l(H.message||k,"error"),!1)}else return l&&l(z,"success"),!0},R=async()=>{if(u)try{p(!0);const O=JSON.parse(u),z=await Zt.updateConfig(O);C(z,i("app.config_saved_success"),i("app.config_saved_failed"))&&a(!1)}catch(O){console.error("Failed to save config:",O),l&&l(i("app.config_saved_failed")+": "+O.message,"error")}finally{p(!1)}},T=async()=>{if(u)try{p(!0);const O=JSON.parse(u),z=await Zt.updateConfig(O);if(C(z,i("app.config_saved_success"),i("app.config_saved_failed"))){const H=await Zt.restartService();C(H,i("app.config_saved_restart_success"),i("app.config_saved_restart_failed")),a(!1)}}catch(O){console.error("Failed to save config and restart:",O),l&&l(i("app.config_saved_restart_failed")+": "+O.message,"error")}finally{p(!1)}};return!m&&!n?null:y.jsxs(y.Fragment,{children:[(m||n)&&y.jsx("div",{className:`fixed inset-0 z-50 transition-all duration-300 ease-out ${x&&n?"bg-black/50 opacity-100":"bg-black/0 opacity-0 pointer-events-none"}`,onClick:()=>a(!1)}),y.jsxs("div",{ref:w,className:`fixed bottom-0 left-0 right-0 z-50 flex flex-col bg-white shadow-2xl transition-all duration-300 ease-out transform ${x&&n?"translate-y-0":"translate-y-full"}`,style:{height:"100vh",maxHeight:"100vh"},children:[y.jsxs("div",{className:"flex items-center justify-between border-b p-4",children:[y.jsx("h2",{className:"text-lg font-semibold",children:i("json_editor.title")}),y.jsxs("div",{className:"flex gap-2",children:[y.jsxs(He,{variant:"outline",size:"sm",onClick:()=>a(!1),disabled:h,children:[y.jsx(Bl,{className:"h-4 w-4 mr-2"}),i("json_editor.cancel")]}),y.jsxs(He,{variant:"outline",size:"sm",onClick:R,disabled:h,children:[y.jsx(X0,{className:"h-4 w-4 mr-2"}),i(h?"json_editor.saving":"json_editor.save")]}),y.jsxs(He,{variant:"default",size:"sm",onClick:T,disabled:h,children:[y.jsx(F0,{className:"h-4 w-4 mr-2"}),i(h?"json_editor.saving":"json_editor.save_and_restart")]})]})]}),y.jsx("div",{className:"flex-1 min-h-0 bg-gray-50",children:y.jsx(bj,{height:"100%",defaultLanguage:"json",value:u,onChange:O=>f(O||""),theme:"vs",options:{minimap:{enabled:!0},fontSize:14,scrollBeyondLastLine:!1,automaticLayout:!0,wordWrap:"on",formatOnPaste:!0,formatOnType:!0,suggest:{showKeywords:!0,showSnippets:!0}}})})]})]})}function Sj({message:n,type:a,onClose:l}){v.useEffect(()=>{const u=setTimeout(()=>{l()},3e3);return()=>clearTimeout(u)},[l]);const i=()=>{switch(a){case"success":return y.jsx(V2,{className:"h-5 w-5 text-green-500"});case"error":return y.jsx(Y2,{className:"h-5 w-5 text-red-500"});case"warning":return y.jsx(B2,{className:"h-5 w-5 text-yellow-500"});default:return null}},s=()=>{switch(a){case"success":return"bg-green-100 border-green-200";case"error":return"bg-red-100 border-red-200";case"warning":return"bg-yellow-100 border-yellow-200";default:return"bg-gray-100 border-gray-200"}};return y.jsxs("div",{className:`fixed top-4 right-4 z-50 flex items-center justify-between p-4 rounded-lg border shadow-lg ${s()} transition-all duration-300 ease-in-out`,children:[y.jsxs("div",{className:"flex items-center space-x-2",children:[i(),y.jsx("span",{className:"text-sm font-medium",children:n})]}),y.jsx("button",{onClick:l,className:"ml-4 text-gray-500 hover:text-gray-700 focus:outline-none",children:y.jsx(Bl,{className:"h-4 w-4"})})]})}function wj(){const{t:n,i18n:a}=$r(),l=wu(),{config:i,error:s}=Il(),[u,f]=v.useState(!1),[h,p]=v.useState(!1),[m,g]=v.useState(!0),[x,S]=v.useState(null);v.useEffect(()=>{(async()=>{if(i){g(!1);return}if(!localStorage.getItem("apiKey")){g(!1);return}try{await Zt.getConfig()}catch(z){console.error("Error checking auth:",z),z.message==="Unauthorized"&&l("/login")}finally{g(!1)}})();const T=()=>{l("/login")};return window.addEventListener("unauthorized",T),()=>{window.removeEventListener("unauthorized",T)}},[i,l]);const w=async()=>{if(!i){S({message:n("app.config_missing"),type:"error"});return}try{const R=await Zt.updateConfig(i);if(console.log("Config saved successfully"),R&&typeof R=="object"&&"success"in R){const T=R;T.success?S({message:T.message||n("app.config_saved_success"),type:"success"}):S({message:T.message||n("app.config_saved_failed"),type:"error"})}else S({message:n("app.config_saved_success"),type:"success"})}catch(R){console.error("Failed to save config:",R),S({message:n("app.config_saved_failed")+": "+R.message,type:"error"})}},C=async()=>{if(!i){S({message:n("app.config_missing"),type:"error"});return}try{const R=await Zt.updateConfig(i);let T=!0;if(R&&typeof R=="object"&&"success"in R){const O=R;O.success||(T=!1,S({message:O.message||n("app.config_saved_failed"),type:"error"}))}if(T){const O=await Zt.restartService();if(console.log("Config saved and service restarted successfully"),O&&typeof O=="object"&&"success"in O){const z=O;z.success&&S({message:z.message||n("app.config_saved_restart_success"),type:"success"})}else S({message:n("app.config_saved_restart_success"),type:"success"})}}catch(R){console.error("Failed to save config and restart:",R),S({message:n("app.config_saved_restart_failed")+": "+R.message,type:"error"})}};return m?y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsx("div",{className:"text-gray-500",children:"Loading application..."})}):s?y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsxs("div",{className:"text-red-500",children:["Error: ",s.message]})}):i?y.jsxs("div",{className:"h-screen bg-gray-50 font-sans",children:[y.jsxs("header",{className:"flex h-16 items-center justify-between border-b bg-white px-6",children:[y.jsx("h1",{className:"text-xl font-semibold text-gray-800",children:n("app.title")}),y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>f(!0),className:"transition-all-ease hover:scale-110",children:y.jsx(iO,{className:"h-5 w-5"})}),y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>p(!0),className:"transition-all-ease hover:scale-110",children:y.jsx(Z2,{className:"h-5 w-5"})}),y.jsxs(gh,{children:[y.jsx(vh,{asChild:!0,children:y.jsx(He,{variant:"ghost",size:"icon",className:"transition-all-ease hover:scale-110",children:y.jsx(I2,{className:"h-5 w-5"})})}),y.jsx(yh,{className:"w-32 p-2",children:y.jsxs("div",{className:"space-y-1",children:[y.jsx(He,{variant:a.language.startsWith("en")?"default":"ghost",className:"w-full justify-start transition-all-ease hover:scale-[1.02]",onClick:()=>a.changeLanguage("en"),children:"English"}),y.jsx(He,{variant:a.language.startsWith("zh")?"default":"ghost",className:"w-full justify-start transition-all-ease hover:scale-[1.02]",onClick:()=>a.changeLanguage("zh"),children:"中文"})]})})]}),y.jsxs(He,{onClick:w,variant:"outline",className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[y.jsx(X0,{className:"mr-2 h-4 w-4"}),n("app.save")]}),y.jsxs(He,{onClick:C,className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[y.jsx(F0,{className:"mr-2 h-4 w-4"}),n("app.save_and_restart")]})]})]}),y.jsxs("main",{className:"flex h-[calc(100vh-4rem)] gap-4 p-4",children:[y.jsx("div",{className:"w-3/5",children:y.jsx(dT,{})}),y.jsxs("div",{className:"flex w-2/5 flex-col gap-4",children:[y.jsx("div",{className:"h-3/5",children:y.jsx(hT,{})}),y.jsx("div",{className:"flex-1",children:y.jsx(aA,{})})]})]}),y.jsx(tA,{isOpen:u,onOpenChange:f}),y.jsx(xj,{open:h,onOpenChange:p,showToast:(R,T)=>S({message:R,type:T})}),x&&y.jsx(Sj,{message:x.message,type:x.type,onClose:()=>S(null)})]}):y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsx("div",{className:"text-gray-500",children:"Loading configuration..."})})}function Ej(){const{t:n}=$r(),a=wu(),[l,i]=v.useState(""),[s,u]=v.useState(""),[f,h]=v.useState(!1);v.useEffect(()=>{(async()=>{if(localStorage.getItem("apiKey")){h(!0);try{await Zt.getConfig(),a("/dashboard")}catch{localStorage.removeItem("apiKey")}finally{h(!1)}}})();const g=()=>{a("/login")};return window.addEventListener("unauthorized",g),()=>{window.removeEventListener("unauthorized",g)}},[a]);const p=async m=>{m.preventDefault();try{Zt.setApiKey(l),window.dispatchEvent(new StorageEvent("storage",{key:"apiKey",newValue:l,url:window.location.href})),await Zt.getConfig(),a("/dashboard")}catch(g){Zt.setApiKey(""),g.message&&g.message.includes("401")?u(n("login.invalidApiKey")):a("/dashboard")}};return f?y.jsx("div",{className:"flex min-h-screen items-center justify-center bg-gray-50",children:y.jsxs(va,{className:"w-full max-w-md",children:[y.jsx(ya,{className:"space-y-1",children:y.jsx(ba,{className:"text-2xl",children:n("login.title")})}),y.jsxs(xa,{children:[y.jsx("div",{className:"flex justify-center py-8",children:y.jsx("div",{className:"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent"})}),y.jsx("p",{className:"text-center text-sm text-gray-500",children:n("login.validating")})]})]})}):y.jsx("div",{className:"flex min-h-screen items-center justify-center bg-gray-50",children:y.jsxs(va,{className:"w-full max-w-md",children:[y.jsxs(ya,{className:"space-y-1",children:[y.jsx(ba,{className:"text-2xl",children:n("login.title")}),y.jsx(bb,{children:n("login.description")})]}),y.jsxs("form",{onSubmit:p,children:[y.jsxs(xa,{className:"space-y-4",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"apiKey",children:n("login.apiKey")}),y.jsx(Rt,{id:"apiKey",type:"password",value:l,onChange:m=>i(m.target.value),placeholder:n("login.apiKeyPlaceholder")})]}),s&&y.jsx("div",{className:"text-sm text-red-500",children:s})]}),y.jsx(xb,{children:y.jsx(He,{className:"w-full",type:"submit",children:n("login.signIn")})})]})]})})}const Rj=({children:n})=>n,Cj=({children:n})=>n,Oj=gR([{path:"/",element:y.jsx(SR,{to:"/dashboard",replace:!0})},{path:"/login",element:y.jsx(Cj,{children:y.jsx(Ej,{})})},{path:"/dashboard",element:y.jsx(Rj,{children:y.jsx(wj,{})})}],{initialEntries:["/dashboard"]});Zw.createRoot(document.getElementById("root")).render(y.jsx(v.StrictMode,{children:y.jsx(eA,{children:y.jsx(tC,{router:Oj})})}));</script>
|
|
226
|
+
`},jy=PT(VT)(px),qT={config:BT},YT=function(){for(var a=arguments.length,l=new Array(a),i=0;i<a;i++)l[i]=arguments[i];return function(s){return l.reduceRight(function(u,f){return f(u)},s)}};function gx(n,a){return Object.keys(a).forEach(function(l){a[l]instanceof Object&&n[l]&&Object.assign(a[l],gx(n[l],a[l]))}),Oy(Oy({},n),a)}var KT={type:"cancelation",msg:"operation is manually canceled"};function hd(n){var a=!1,l=new Promise(function(i,s){n.then(function(u){return a?s(KT):i(u)}),n.catch(s)});return l.cancel=function(){return a=!0},l}var GT=kT.create({config:UT,isInitialized:!1,resolve:null,reject:null,monaco:null}),vx=vT(GT,2),Ro=vx[0],zu=vx[1];function FT(n){var a=qT.config(n),l=a.monaco,i=gT(a,["monaco"]);zu(function(s){return{config:gx(s.config,i),monaco:l}})}function XT(){var n=Ro(function(a){var l=a.monaco,i=a.isInitialized,s=a.resolve;return{monaco:l,isInitialized:i,resolve:s}});if(!n.isInitialized){if(zu({isInitialized:!0}),n.monaco)return n.resolve(n.monaco),hd(md);if(window.monaco&&window.monaco.editor)return yx(window.monaco),n.resolve(window.monaco),hd(md);YT(QT,JT)(IT)}return hd(md)}function QT(n){return document.body.appendChild(n)}function ZT(n){var a=document.createElement("script");return n&&(a.src=n),a}function JT(n){var a=Ro(function(i){var s=i.config,u=i.reject;return{config:s,reject:u}}),l=ZT("".concat(a.config.paths.vs,"/loader.js"));return l.onload=function(){return n()},l.onerror=a.reject,l}function IT(){var n=Ro(function(l){var i=l.config,s=l.resolve,u=l.reject;return{config:i,resolve:s,reject:u}}),a=window.require;a.config(n.config),a(["vs/editor/editor.main"],function(l){yx(l),n.resolve(l)},function(l){n.reject(l)})}function yx(n){Ro().monaco||zu({monaco:n})}function WT(){return Ro(function(n){var a=n.monaco;return a})}var md=new Promise(function(n,a){return zu({resolve:n,reject:a})}),bx={config:FT,init:XT,__getMonacoInstance:WT},ej={wrapper:{display:"flex",position:"relative",textAlign:"initial"},fullWidth:{width:"100%"},hide:{display:"none"}},pd=ej,tj={container:{display:"flex",height:"100%",width:"100%",justifyContent:"center",alignItems:"center"}},nj=tj;function aj({children:n}){return Lr.createElement("div",{style:nj.container},n)}var rj=aj,lj=rj;function ij({width:n,height:a,isEditorReady:l,loading:i,_ref:s,className:u,wrapperProps:f}){return Lr.createElement("section",{style:{...pd.wrapper,width:n,height:a},...f},!l&&Lr.createElement(lj,null,i),Lr.createElement("div",{ref:s,style:{...pd.fullWidth,...!l&&pd.hide},className:u}))}var oj=ij,xx=v.memo(oj);function sj(n){v.useEffect(n,[])}var Sx=sj;function uj(n,a,l=!0){let i=v.useRef(!0);v.useEffect(i.current||!l?()=>{i.current=!1}:n,a)}var on=uj;function so(){}function Ul(n,a,l,i){return cj(n,i)||fj(n,a,l,i)}function cj(n,a){return n.editor.getModel(wx(n,a))}function fj(n,a,l,i){return n.editor.createModel(a,l,i?wx(n,i):void 0)}function wx(n,a){return n.Uri.parse(a)}function dj({original:n,modified:a,language:l,originalLanguage:i,modifiedLanguage:s,originalModelPath:u,modifiedModelPath:f,keepCurrentOriginalModel:h=!1,keepCurrentModifiedModel:p=!1,theme:m="light",loading:g="Loading...",options:x={},height:S="100%",width:w="100%",className:C,wrapperProps:R={},beforeMount:T=so,onMount:O=so}){let[z,k]=v.useState(!1),[H,P]=v.useState(!0),A=v.useRef(null),G=v.useRef(null),J=v.useRef(null),re=v.useRef(O),ie=v.useRef(T),Oe=v.useRef(!1);Sx(()=>{let fe=bx.init();return fe.then(_=>(G.current=_)&&P(!1)).catch(_=>_?.type!=="cancelation"&&console.error("Monaco initialization: error:",_)),()=>A.current?he():fe.cancel()}),on(()=>{if(A.current&&G.current){let fe=A.current.getOriginalEditor(),_=Ul(G.current,n||"",i||l||"text",u||"");_!==fe.getModel()&&fe.setModel(_)}},[u],z),on(()=>{if(A.current&&G.current){let fe=A.current.getModifiedEditor(),_=Ul(G.current,a||"",s||l||"text",f||"");_!==fe.getModel()&&fe.setModel(_)}},[f],z),on(()=>{let fe=A.current.getModifiedEditor();fe.getOption(G.current.editor.EditorOption.readOnly)?fe.setValue(a||""):a!==fe.getValue()&&(fe.executeEdits("",[{range:fe.getModel().getFullModelRange(),text:a||"",forceMoveMarkers:!0}]),fe.pushUndoStop())},[a],z),on(()=>{A.current?.getModel()?.original.setValue(n||"")},[n],z),on(()=>{let{original:fe,modified:_}=A.current.getModel();G.current.editor.setModelLanguage(fe,i||l||"text"),G.current.editor.setModelLanguage(_,s||l||"text")},[l,i,s],z),on(()=>{G.current?.editor.setTheme(m)},[m],z),on(()=>{A.current?.updateOptions(x)},[x],z);let Ee=v.useCallback(()=>{if(!G.current)return;ie.current(G.current);let fe=Ul(G.current,n||"",i||l||"text",u||""),_=Ul(G.current,a||"",s||l||"text",f||"");A.current?.setModel({original:fe,modified:_})},[l,a,s,n,i,u,f]),me=v.useCallback(()=>{!Oe.current&&J.current&&(A.current=G.current.editor.createDiffEditor(J.current,{automaticLayout:!0,...x}),Ee(),G.current?.editor.setTheme(m),k(!0),Oe.current=!0)},[x,m,Ee]);v.useEffect(()=>{z&&re.current(A.current,G.current)},[z]),v.useEffect(()=>{!H&&!z&&me()},[H,z,me]);function he(){let fe=A.current?.getModel();h||fe?.original?.dispose(),p||fe?.modified?.dispose(),A.current?.dispose()}return Lr.createElement(xx,{width:w,height:S,isEditorReady:z,loading:g,_ref:J,className:C,wrapperProps:R})}var hj=dj;v.memo(hj);function mj(n){let a=v.useRef();return v.useEffect(()=>{a.current=n},[n]),a.current}var pj=mj,Is=new Map;function gj({defaultValue:n,defaultLanguage:a,defaultPath:l,value:i,language:s,path:u,theme:f="light",line:h,loading:p="Loading...",options:m={},overrideServices:g={},saveViewState:x=!0,keepCurrentModel:S=!1,width:w="100%",height:C="100%",className:R,wrapperProps:T={},beforeMount:O=so,onMount:z=so,onChange:k,onValidate:H=so}){let[P,A]=v.useState(!1),[G,J]=v.useState(!0),re=v.useRef(null),ie=v.useRef(null),Oe=v.useRef(null),Ee=v.useRef(z),me=v.useRef(O),he=v.useRef(),fe=v.useRef(i),_=pj(u),Z=v.useRef(!1),$=v.useRef(!1);Sx(()=>{let Y=bx.init();return Y.then(L=>(re.current=L)&&J(!1)).catch(L=>L?.type!=="cancelation"&&console.error("Monaco initialization: error:",L)),()=>ie.current?N():Y.cancel()}),on(()=>{let Y=Ul(re.current,n||i||"",a||s||"",u||l||"");Y!==ie.current?.getModel()&&(x&&Is.set(_,ie.current?.saveViewState()),ie.current?.setModel(Y),x&&ie.current?.restoreViewState(Is.get(u)))},[u],P),on(()=>{ie.current?.updateOptions(m)},[m],P),on(()=>{!ie.current||i===void 0||(ie.current.getOption(re.current.editor.EditorOption.readOnly)?ie.current.setValue(i):i!==ie.current.getValue()&&($.current=!0,ie.current.executeEdits("",[{range:ie.current.getModel().getFullModelRange(),text:i,forceMoveMarkers:!0}]),ie.current.pushUndoStop(),$.current=!1))},[i],P),on(()=>{let Y=ie.current?.getModel();Y&&s&&re.current?.editor.setModelLanguage(Y,s)},[s],P),on(()=>{h!==void 0&&ie.current?.revealLine(h)},[h],P),on(()=>{re.current?.editor.setTheme(f)},[f],P);let pe=v.useCallback(()=>{if(!(!Oe.current||!re.current)&&!Z.current){me.current(re.current);let Y=u||l,L=Ul(re.current,i||n||"",a||s||"",Y||"");ie.current=re.current?.editor.create(Oe.current,{model:L,automaticLayout:!0,...m},g),x&&ie.current.restoreViewState(Is.get(Y)),re.current.editor.setTheme(f),h!==void 0&&ie.current.revealLine(h),A(!0),Z.current=!0}},[n,a,l,i,s,u,m,g,x,f,h]);v.useEffect(()=>{P&&Ee.current(ie.current,re.current)},[P]),v.useEffect(()=>{!G&&!P&&pe()},[G,P,pe]),fe.current=i,v.useEffect(()=>{P&&k&&(he.current?.dispose(),he.current=ie.current?.onDidChangeModelContent(Y=>{$.current||k(ie.current.getValue(),Y)}))},[P,k]),v.useEffect(()=>{if(P){let Y=re.current.editor.onDidChangeMarkers(L=>{let K=ie.current.getModel()?.uri;if(K&&L.find(W=>W.path===K.path)){let W=re.current.editor.getModelMarkers({resource:K});H?.(W)}});return()=>{Y?.dispose()}}return()=>{}},[P,H]);function N(){he.current?.dispose(),S?x&&Is.set(u,ie.current.saveViewState()):ie.current.getModel()?.dispose(),ie.current.dispose()}return Lr.createElement(xx,{width:w,height:C,isEditorReady:P,loading:p,_ref:Oe,className:R,wrapperProps:T})}var vj=gj,yj=v.memo(vj),bj=yj;function xj({open:n,onOpenChange:a,showToast:l}){const{t:i}=$r(),{config:s}=Il(),[u,f]=v.useState(""),[h,p]=v.useState(!1),[m,g]=v.useState(!1),[x,S]=v.useState(!1),w=v.useRef(null);v.useEffect(()=>{s&&n&&f(JSON.stringify(s,null,2))},[s,n]),v.useEffect(()=>{if(n)g(!0),requestAnimationFrame(()=>{S(!0)});else{S(!1);const O=setTimeout(()=>{g(!1)},300);return()=>clearTimeout(O)}},[n]);const C=(O,z,k)=>{if(O&&typeof O=="object"&&"success"in O){const H=O;return H.success?(l&&l(H.message||z,"success"),!0):(l&&l(H.message||k,"error"),!1)}else return l&&l(z,"success"),!0},R=async()=>{if(u)try{p(!0);const O=JSON.parse(u),z=await un.updateConfig(O);C(z,i("app.config_saved_success"),i("app.config_saved_failed"))&&a(!1)}catch(O){console.error("Failed to save config:",O),l&&l(i("app.config_saved_failed")+": "+O.message,"error")}finally{p(!1)}},T=async()=>{if(u)try{p(!0);const O=JSON.parse(u),z=await un.updateConfig(O);if(C(z,i("app.config_saved_success"),i("app.config_saved_failed"))){const H=await un.restartService();C(H,i("app.config_saved_restart_success"),i("app.config_saved_restart_failed")),a(!1)}}catch(O){console.error("Failed to save config and restart:",O),l&&l(i("app.config_saved_restart_failed")+": "+O.message,"error")}finally{p(!1)}};return!m&&!n?null:y.jsxs(y.Fragment,{children:[(m||n)&&y.jsx("div",{className:`fixed inset-0 z-50 transition-all duration-300 ease-out ${x&&n?"bg-black/50 opacity-100":"bg-black/0 opacity-0 pointer-events-none"}`,onClick:()=>a(!1)}),y.jsxs("div",{ref:w,className:`fixed bottom-0 left-0 right-0 z-50 flex flex-col bg-white shadow-2xl transition-all duration-300 ease-out transform ${x&&n?"translate-y-0":"translate-y-full"}`,style:{height:"100vh",maxHeight:"100vh"},children:[y.jsxs("div",{className:"flex items-center justify-between border-b p-4",children:[y.jsx("h2",{className:"text-lg font-semibold",children:i("json_editor.title")}),y.jsxs("div",{className:"flex gap-2",children:[y.jsxs(He,{variant:"outline",size:"sm",onClick:()=>a(!1),disabled:h,children:[y.jsx(Bl,{className:"h-4 w-4 mr-2"}),i("json_editor.cancel")]}),y.jsxs(He,{variant:"outline",size:"sm",onClick:R,disabled:h,children:[y.jsx(X0,{className:"h-4 w-4 mr-2"}),i(h?"json_editor.saving":"json_editor.save")]}),y.jsxs(He,{variant:"default",size:"sm",onClick:T,disabled:h,children:[y.jsx(F0,{className:"h-4 w-4 mr-2"}),i(h?"json_editor.saving":"json_editor.save_and_restart")]})]})]}),y.jsx("div",{className:"flex-1 min-h-0 bg-gray-50",children:y.jsx(bj,{height:"100%",defaultLanguage:"json",value:u,onChange:O=>f(O||""),theme:"vs",options:{minimap:{enabled:!0},fontSize:14,scrollBeyondLastLine:!1,automaticLayout:!0,wordWrap:"on",formatOnPaste:!0,formatOnType:!0,suggest:{showKeywords:!0,showSnippets:!0}}})})]})]})}function Sj({message:n,type:a,onClose:l}){v.useEffect(()=>{const u=setTimeout(()=>{l()},3e3);return()=>clearTimeout(u)},[l]);const i=()=>{switch(a){case"success":return y.jsx(V2,{className:"h-5 w-5 text-green-500"});case"error":return y.jsx(Y2,{className:"h-5 w-5 text-red-500"});case"warning":return y.jsx(B2,{className:"h-5 w-5 text-yellow-500"});default:return null}},s=()=>{switch(a){case"success":return"bg-green-100 border-green-200";case"error":return"bg-red-100 border-red-200";case"warning":return"bg-yellow-100 border-yellow-200";default:return"bg-gray-100 border-gray-200"}};return y.jsxs("div",{className:`fixed top-4 right-4 z-50 flex items-center justify-between p-4 rounded-lg border shadow-lg ${s()} transition-all duration-300 ease-in-out`,children:[y.jsxs("div",{className:"flex items-center space-x-2",children:[i(),y.jsx("span",{className:"text-sm font-medium",children:n})]}),y.jsx("button",{onClick:l,className:"ml-4 text-gray-500 hover:text-gray-700 focus:outline-none",children:y.jsx(Bl,{className:"h-4 w-4"})})]})}function wj(){const{t:n,i18n:a}=$r(),l=wu(),{config:i,error:s}=Il(),[u,f]=v.useState(!1),[h,p]=v.useState(!1),[m,g]=v.useState(!0),[x,S]=v.useState(null);v.useEffect(()=>{(async()=>{if(i){g(!1);return}if(!localStorage.getItem("apiKey")){g(!1);return}try{await un.getConfig()}catch(z){console.error("Error checking auth:",z),z.message==="Unauthorized"&&l("/login")}finally{g(!1)}})();const T=()=>{l("/login")};return window.addEventListener("unauthorized",T),()=>{window.removeEventListener("unauthorized",T)}},[i,l]);const w=async()=>{if(!i){S({message:n("app.config_missing"),type:"error"});return}try{const R=await un.updateConfig(i);if(console.log("Config saved successfully"),R&&typeof R=="object"&&"success"in R){const T=R;T.success?S({message:T.message||n("app.config_saved_success"),type:"success"}):S({message:T.message||n("app.config_saved_failed"),type:"error"})}else S({message:n("app.config_saved_success"),type:"success"})}catch(R){console.error("Failed to save config:",R),S({message:n("app.config_saved_failed")+": "+R.message,type:"error"})}},C=async()=>{if(!i){S({message:n("app.config_missing"),type:"error"});return}try{const R=await un.updateConfig(i);let T=!0;if(R&&typeof R=="object"&&"success"in R){const O=R;O.success||(T=!1,S({message:O.message||n("app.config_saved_failed"),type:"error"}))}if(T){const O=await un.restartService();if(console.log("Config saved and service restarted successfully"),O&&typeof O=="object"&&"success"in O){const z=O;z.success&&S({message:z.message||n("app.config_saved_restart_success"),type:"success"})}else S({message:n("app.config_saved_restart_success"),type:"success"})}}catch(R){console.error("Failed to save config and restart:",R),S({message:n("app.config_saved_restart_failed")+": "+R.message,type:"error"})}};return m?y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsx("div",{className:"text-gray-500",children:"Loading application..."})}):s?y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsxs("div",{className:"text-red-500",children:["Error: ",s.message]})}):i?y.jsxs("div",{className:"h-screen bg-gray-50 font-sans",children:[y.jsxs("header",{className:"flex h-16 items-center justify-between border-b bg-white px-6",children:[y.jsx("h1",{className:"text-xl font-semibold text-gray-800",children:n("app.title")}),y.jsxs("div",{className:"flex items-center gap-2",children:[y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>f(!0),className:"transition-all-ease hover:scale-110",children:y.jsx(iO,{className:"h-5 w-5"})}),y.jsx(He,{variant:"ghost",size:"icon",onClick:()=>p(!0),className:"transition-all-ease hover:scale-110",children:y.jsx(Z2,{className:"h-5 w-5"})}),y.jsxs(gh,{children:[y.jsx(vh,{asChild:!0,children:y.jsx(He,{variant:"ghost",size:"icon",className:"transition-all-ease hover:scale-110",children:y.jsx(I2,{className:"h-5 w-5"})})}),y.jsx(yh,{className:"w-32 p-2",children:y.jsxs("div",{className:"space-y-1",children:[y.jsx(He,{variant:a.language.startsWith("en")?"default":"ghost",className:"w-full justify-start transition-all-ease hover:scale-[1.02]",onClick:()=>a.changeLanguage("en"),children:"English"}),y.jsx(He,{variant:a.language.startsWith("zh")?"default":"ghost",className:"w-full justify-start transition-all-ease hover:scale-[1.02]",onClick:()=>a.changeLanguage("zh"),children:"中文"})]})})]}),y.jsxs(He,{onClick:w,variant:"outline",className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[y.jsx(X0,{className:"mr-2 h-4 w-4"}),n("app.save")]}),y.jsxs(He,{onClick:C,className:"transition-all-ease hover:scale-[1.02] active:scale-[0.98]",children:[y.jsx(F0,{className:"mr-2 h-4 w-4"}),n("app.save_and_restart")]})]})]}),y.jsxs("main",{className:"flex h-[calc(100vh-4rem)] gap-4 p-4",children:[y.jsx("div",{className:"w-3/5",children:y.jsx(dT,{})}),y.jsxs("div",{className:"flex w-2/5 flex-col gap-4",children:[y.jsx("div",{className:"h-3/5",children:y.jsx(hT,{})}),y.jsx("div",{className:"flex-1",children:y.jsx(aA,{})})]})]}),y.jsx(tA,{isOpen:u,onOpenChange:f}),y.jsx(xj,{open:h,onOpenChange:p,showToast:(R,T)=>S({message:R,type:T})}),x&&y.jsx(Sj,{message:x.message,type:x.type,onClose:()=>S(null)})]}):y.jsx("div",{className:"h-screen bg-gray-50 font-sans flex items-center justify-center",children:y.jsx("div",{className:"text-gray-500",children:"Loading configuration..."})})}function Ej(){const{t:n}=$r(),a=wu(),[l,i]=v.useState(""),[s,u]=v.useState(""),[f,h]=v.useState(!1);v.useEffect(()=>{(async()=>{if(localStorage.getItem("apiKey")){h(!0);try{await un.getConfig(),a("/dashboard")}catch{localStorage.removeItem("apiKey")}finally{h(!1)}}})();const g=()=>{a("/login")};return window.addEventListener("unauthorized",g),()=>{window.removeEventListener("unauthorized",g)}},[a]);const p=async m=>{m.preventDefault();try{un.setApiKey(l),window.dispatchEvent(new StorageEvent("storage",{key:"apiKey",newValue:l,url:window.location.href})),await un.getConfig(),a("/dashboard")}catch(g){un.setApiKey(""),g.message&&g.message.includes("401")?u(n("login.invalidApiKey")):a("/dashboard")}};return f?y.jsx("div",{className:"flex min-h-screen items-center justify-center bg-gray-50",children:y.jsxs(va,{className:"w-full max-w-md",children:[y.jsx(ya,{className:"space-y-1",children:y.jsx(ba,{className:"text-2xl",children:n("login.title")})}),y.jsxs(xa,{children:[y.jsx("div",{className:"flex justify-center py-8",children:y.jsx("div",{className:"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent"})}),y.jsx("p",{className:"text-center text-sm text-gray-500",children:n("login.validating")})]})]})}):y.jsx("div",{className:"flex min-h-screen items-center justify-center bg-gray-50",children:y.jsxs(va,{className:"w-full max-w-md",children:[y.jsxs(ya,{className:"space-y-1",children:[y.jsx(ba,{className:"text-2xl",children:n("login.title")}),y.jsx(bb,{children:n("login.description")})]}),y.jsxs("form",{onSubmit:p,children:[y.jsxs(xa,{className:"space-y-4",children:[y.jsxs("div",{className:"space-y-2",children:[y.jsx(ct,{htmlFor:"apiKey",children:n("login.apiKey")}),y.jsx(Rt,{id:"apiKey",type:"password",value:l,onChange:m=>i(m.target.value),placeholder:n("login.apiKeyPlaceholder")})]}),s&&y.jsx("div",{className:"text-sm text-red-500",children:s})]}),y.jsx(xb,{children:y.jsx(He,{className:"w-full",type:"submit",children:n("login.signIn")})})]})]})})}const Rj=({children:n})=>n,Cj=({children:n})=>n,Oj=gR([{path:"/",element:y.jsx(SR,{to:"/dashboard",replace:!0})},{path:"/login",element:y.jsx(Cj,{children:y.jsx(Ej,{})})},{path:"/dashboard",element:y.jsx(Rj,{children:y.jsx(wj,{})})}],{initialEntries:["/dashboard"]});Zw.createRoot(document.getElementById("root")).render(y.jsx(v.StrictMode,{children:y.jsx(eA,{children:y.jsx(tC,{router:Oj})})}));</script>
|
|
227
227
|
<style rel="stylesheet" crossorigin>/*! tailwindcss v4.1.11 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-duration:initial;--tw-ease:initial;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-100:oklch(93.6% .032 17.717);--color-red-200:oklch(88.5% .062 18.334);--color-red-500:oklch(63.7% .237 25.331);--color-yellow-100:oklch(97.3% .071 103.193);--color-yellow-200:oklch(94.5% .129 101.54);--color-yellow-500:oklch(79.5% .184 86.047);--color-green-100:oklch(96.2% .044 156.743);--color-green-200:oklch(92.5% .084 155.995);--color-green-500:oklch(72.3% .219 149.579);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-200:oklch(92.8% .006 264.531);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-600:oklch(44.6% .03 256.802);--color-gray-700:oklch(37.3% .034 259.733);--color-gray-800:oklch(27.8% .033 256.848);--color-black:#000;--color-white:#fff;--spacing:.25rem;--container-md:28rem;--container-lg:32rem;--container-2xl:42rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height: 1.5 ;--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75/1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--tracking-tight:-.025em;--tracking-widest:.1em;--ease-out:cubic-bezier(0,0,.2,1);--ease-in-out:cubic-bezier(.4,0,.2,1);--animate-spin:spin 1s linear infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}*{border-color:var(--border);outline-color:var(--ring)}@supports (color:color-mix(in lab,red,red)){*{outline-color:color-mix(in oklab,var(--ring)50%,transparent)}}body{background-color:var(--background);color:var(--foreground)}}@layer components;@layer utilities{.pointer-events-none{pointer-events:none}.sr-only{clip:rect(0,0,0,0);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.inset-0{inset:calc(var(--spacing)*0)}.top-0{top:calc(var(--spacing)*0)}.top-1\/2{top:50%}.top-4{top:calc(var(--spacing)*4)}.top-\[50\%\]{top:50%}.right-0{right:calc(var(--spacing)*0)}.right-2{right:calc(var(--spacing)*2)}.right-4{right:calc(var(--spacing)*4)}.bottom-0{bottom:calc(var(--spacing)*0)}.left-0{left:calc(var(--spacing)*0)}.left-\[50\%\]{left:50%}.z-50{z-index:50}.-mx-1{margin-inline:calc(var(--spacing)*-1)}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-auto{margin-top:auto}.mr-2{margin-right:calc(var(--spacing)*2)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.ml-1{margin-left:calc(var(--spacing)*1)}.ml-2{margin-left:calc(var(--spacing)*2)}.ml-4{margin-left:calc(var(--spacing)*4)}.ml-auto{margin-left:auto}.block{display:block}.flex{display:flex}.grid{display:grid}.inline-flex{display:inline-flex}.size-4{width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.h-3{height:calc(var(--spacing)*3)}.h-3\/5{height:60%}.h-4{height:calc(var(--spacing)*4)}.h-5{height:calc(var(--spacing)*5)}.h-6{height:calc(var(--spacing)*6)}.h-8{height:calc(var(--spacing)*8)}.h-9{height:calc(var(--spacing)*9)}.h-10{height:calc(var(--spacing)*10)}.h-11{height:calc(var(--spacing)*11)}.h-16{height:calc(var(--spacing)*16)}.h-\[calc\(100vh-4rem\)\]{height:calc(100vh - 4rem)}.h-full{height:100%}.h-px{height:1px}.h-screen{height:100vh}.max-h-8{max-height:calc(var(--spacing)*8)}.max-h-96{max-height:calc(var(--spacing)*96)}.max-h-\[80vh\]{max-height:80vh}.max-h-\[300px\]{max-height:300px}.min-h-0{min-height:calc(var(--spacing)*0)}.min-h-screen{min-height:100vh}.w-2\/5{width:40%}.w-3{width:calc(var(--spacing)*3)}.w-3\/5{width:60%}.w-4{width:calc(var(--spacing)*4)}.w-5{width:calc(var(--spacing)*5)}.w-6{width:calc(var(--spacing)*6)}.w-8{width:calc(var(--spacing)*8)}.w-10{width:calc(var(--spacing)*10)}.w-11{width:calc(var(--spacing)*11)}.w-32{width:calc(var(--spacing)*32)}.w-48{width:calc(var(--spacing)*48)}.w-72{width:calc(var(--spacing)*72)}.w-\[--radix-popover-trigger-width\]{width:--radix-popover-trigger-width}.w-full{width:100%}.max-w-lg{max-width:var(--container-lg)}.max-w-md{max-width:var(--container-md)}.flex-1{flex:1}.flex-shrink-0,.shrink-0{flex-shrink:0}.flex-grow{flex-grow:1}.origin-\(--radix-popover-content-transform-origin\){transform-origin:var(--radix-popover-content-transform-origin)}.translate-x-\[-50\%\]{--tw-translate-x:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.-translate-y-1\/2{--tw-translate-y: -50% ;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-0{--tw-translate-y:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-50\%\]{--tw-translate-y:-50%;translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-full{--tw-translate-y:100%;translate:var(--tw-translate-x)var(--tw-translate-y)}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.scroll-py-1{scroll-padding-block:calc(var(--spacing)*1)}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-start{align-items:flex-start}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.gap-1{gap:calc(var(--spacing)*1)}.gap-2{gap:calc(var(--spacing)*2)}.gap-4{gap:calc(var(--spacing)*4)}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-1\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1.5)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1.5)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*2)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*3)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*4)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*5)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*5)*calc(1 - var(--tw-space-y-reverse)))}:where(.space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*2)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-x-reverse)))}.overflow-hidden{overflow:hidden}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-full{border-radius:3.40282e38px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-sm{border-radius:calc(var(--radius) - 4px)}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-4{border-style:var(--tw-border-style);border-width:4px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-l-2{border-left-style:var(--tw-border-style);border-left-width:2px}.border-destructive\/50{border-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.border-destructive\/50{border-color:color-mix(in oklab,var(--destructive)50%,transparent)}}.border-gray-200{border-color:var(--color-gray-200)}.border-green-200{border-color:var(--color-green-200)}.border-input{border-color:var(--input)}.border-primary{border-color:var(--primary)}.border-red-200{border-color:var(--color-red-200)}.border-red-500{border-color:var(--color-red-500)}.border-transparent{border-color:#0000}.border-yellow-200{border-color:var(--color-yellow-200)}.border-t-transparent{border-top-color:#0000}.bg-background{background-color:var(--background)}.bg-black\/0{background-color:#0000}@supports (color:color-mix(in lab,red,red)){.bg-black\/0{background-color:color-mix(in oklab,var(--color-black)0%,transparent)}}.bg-black\/50{background-color:#00000080}@supports (color:color-mix(in lab,red,red)){.bg-black\/50{background-color:color-mix(in oklab,var(--color-black)50%,transparent)}}.bg-black\/80{background-color:#000c}@supports (color:color-mix(in lab,red,red)){.bg-black\/80{background-color:color-mix(in oklab,var(--color-black)80%,transparent)}}.bg-border{background-color:var(--border)}.bg-card{background-color:var(--card)}.bg-destructive{background-color:var(--destructive)}.bg-gray-50{background-color:var(--color-gray-50)}.bg-gray-100{background-color:var(--color-gray-100)}.bg-green-100{background-color:var(--color-green-100)}.bg-popover{background-color:var(--popover)}.bg-primary{background-color:var(--primary)}.bg-red-100{background-color:var(--color-red-100)}.bg-secondary{background-color:var(--secondary)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-yellow-100{background-color:var(--color-yellow-100)}.p-0{padding:calc(var(--spacing)*0)}.p-1{padding:calc(var(--spacing)*1)}.p-2{padding:calc(var(--spacing)*2)}.p-3{padding:calc(var(--spacing)*3)}.p-4{padding:calc(var(--spacing)*4)}.p-6{padding:calc(var(--spacing)*6)}.p-8{padding:calc(var(--spacing)*8)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-2\.5{padding-inline:calc(var(--spacing)*2.5)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.px-6{padding-inline:calc(var(--spacing)*6)}.px-8{padding-inline:calc(var(--spacing)*8)}.py-0\.5{padding-block:calc(var(--spacing)*.5)}.py-1{padding-block:calc(var(--spacing)*1)}.py-1\.5{padding-block:calc(var(--spacing)*1.5)}.py-2{padding-block:calc(var(--spacing)*2)}.py-3{padding-block:calc(var(--spacing)*3)}.py-4{padding-block:calc(var(--spacing)*4)}.py-6{padding-block:calc(var(--spacing)*6)}.py-8{padding-block:calc(var(--spacing)*8)}.pt-0{padding-top:calc(var(--spacing)*0)}.pt-2{padding-top:calc(var(--spacing)*2)}.pr-10{padding-right:calc(var(--spacing)*10)}.pl-4{padding-left:calc(var(--spacing)*4)}.text-center{text-align:center}.font-sans{font-family:var(--font-sans)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-none{--tw-leading:1;line-height:1}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-tight{--tw-tracking:var(--tracking-tight);letter-spacing:var(--tracking-tight)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.whitespace-nowrap{white-space:nowrap}.text-card-foreground{color:var(--card-foreground)}.text-current{color:currentColor}.text-destructive{color:var(--destructive)}.text-destructive-foreground{color:var(--destructive-foreground)}.text-foreground{color:var(--foreground)}.text-gray-500{color:var(--color-gray-500)}.text-gray-600{color:var(--color-gray-600)}.text-gray-700{color:var(--color-gray-700)}.text-gray-800{color:var(--color-gray-800)}.text-green-500{color:var(--color-green-500)}.text-muted-foreground{color:var(--muted-foreground)}.text-popover-foreground{color:var(--popover-foreground)}.text-primary{color:var(--primary)}.text-primary-foreground{color:var(--primary-foreground)}.text-red-500{color:var(--color-red-500)}.text-secondary-foreground{color:var(--secondary-foreground)}.text-yellow-500{color:var(--color-yellow-500)}.underline-offset-4{text-underline-offset:4px}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-70{opacity:.7}.opacity-100{opacity:1}.shadow-2xl{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-0{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ring-offset-background{--tw-ring-offset-color:var(--background)}.outline-hidden{--tw-outline-style:none;outline-style:none}@media (forced-colors:active){.outline-hidden{outline-offset:2px;outline:2px solid #0000}}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.select-none{-webkit-user-select:none;user-select:none}.group-data-\[state\=open\]\:rotate-180:is(:where(.group)[data-state=open] *){rotate:180deg}.peer-disabled\:cursor-not-allowed:is(:where(.peer):disabled~*){cursor:not-allowed}.peer-disabled\:opacity-70:is(:where(.peer):disabled~*){opacity:.7}.file\:border-0::file-selector-button{border-style:var(--tw-border-style);border-width:0}.file\:bg-transparent::file-selector-button{background-color:#0000}.file\:text-sm::file-selector-button{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.file\:font-medium::file-selector-button{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.file\:text-foreground::file-selector-button{color:var(--foreground)}.placeholder\:text-muted-foreground::placeholder{color:var(--muted-foreground)}@media (hover:hover){.hover\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x)var(--tw-scale-y)}.hover\:scale-\[1\.01\]:hover{scale:1.01}.hover\:scale-\[1\.02\]:hover{scale:1.02}.hover\:bg-accent:hover{background-color:var(--accent)}.hover\:bg-destructive:hover,.hover\:bg-destructive\/80:hover{background-color:var(--destructive)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-destructive\/80:hover{background-color:color-mix(in oklab,var(--destructive)80%,transparent)}}.hover\:bg-gray-200:hover{background-color:var(--color-gray-200)}.hover\:bg-primary\/80:hover{background-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-primary\/80:hover{background-color:color-mix(in oklab,var(--primary)80%,transparent)}}.hover\:bg-primary\/90:hover{background-color:var(--primary)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-primary\/90:hover{background-color:color-mix(in oklab,var(--primary)90%,transparent)}}.hover\:bg-secondary\/80:hover{background-color:var(--secondary)}@supports (color:color-mix(in lab,red,red)){.hover\:bg-secondary\/80:hover{background-color:color-mix(in oklab,var(--secondary)80%,transparent)}}.hover\:bg-transparent:hover{background-color:#0000}.hover\:text-accent-foreground:hover{color:var(--accent-foreground)}.hover\:text-destructive-foreground:hover{color:var(--destructive-foreground)}.hover\:text-gray-700:hover{color:var(--color-gray-700)}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:shadow-md:hover{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}}.focus\:scale-\[1\.01\]:focus{scale:1.01}.focus\:ring-2:focus{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus\:ring-ring:focus{--tw-ring-color:var(--ring)}.focus\:ring-offset-2:focus{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(2px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.focus-visible\:ring-ring:focus-visible{--tw-ring-color:var(--ring)}.focus-visible\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}.focus-visible\:ring-offset-background:focus-visible{--tw-ring-offset-color:var(--background)}.focus-visible\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.active\:scale-\[0\.98\]:active{scale:.98}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-50:disabled{opacity:.5}.data-\[disabled\=true\]\:pointer-events-none[data-disabled=true]{pointer-events:none}.data-\[disabled\=true\]\:opacity-50[data-disabled=true]{opacity:.5}.data-\[selected\=true\]\:bg-accent[data-selected=true]{background-color:var(--accent)}.data-\[selected\=true\]\:text-accent-foreground[data-selected=true]{color:var(--accent-foreground)}:is(.\*\*\:data-\[slot\=command-input-wrapper\]\:h-12 *)[data-slot=command-input-wrapper]{height:calc(var(--spacing)*12)}.data-\[state\=checked\]\:translate-x-5[data-state=checked]{--tw-translate-x:calc(var(--spacing)*5);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[state\=checked\]\:bg-primary[data-state=checked]{background-color:var(--primary)}.data-\[state\=open\]\:bg-accent[data-state=open]{background-color:var(--accent)}.data-\[state\=open\]\:text-muted-foreground[data-state=open]{color:var(--muted-foreground)}.data-\[state\=unchecked\]\:translate-x-0[data-state=unchecked]{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}.data-\[state\=unchecked\]\:bg-input[data-state=unchecked]{background-color:var(--input)}@media (min-width:40rem){.sm\:max-w-2xl{max-width:var(--container-2xl)}.sm\:flex-row{flex-direction:row}.sm\:justify-end{justify-content:flex-end}:where(.sm\:space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*2)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-x-reverse)))}.sm\:rounded-lg{border-radius:var(--radius)}.sm\:text-left{text-align:left}}@media (min-width:48rem){.md\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}}.\[\&_\[cmdk-group-heading\]\]\:px-2 [cmdk-group-heading]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-group-heading\]\]\:py-1\.5 [cmdk-group-heading]{padding-block:calc(var(--spacing)*1.5)}.\[\&_\[cmdk-group-heading\]\]\:text-xs [cmdk-group-heading]{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.\[\&_\[cmdk-group-heading\]\]\:font-medium [cmdk-group-heading]{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.\[\&_\[cmdk-group-heading\]\]\:text-muted-foreground [cmdk-group-heading]{color:var(--muted-foreground)}.\[\&_\[cmdk-group\]\]\:px-2 [cmdk-group]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-group\]\:not\(\[hidden\]\)_\~\[cmdk-group\]\]\:pt-0 [cmdk-group]:not([hidden])~[cmdk-group]{padding-top:calc(var(--spacing)*0)}.\[\&_\[cmdk-input-wrapper\]_svg\]\:h-5 [cmdk-input-wrapper] svg{height:calc(var(--spacing)*5)}.\[\&_\[cmdk-input-wrapper\]_svg\]\:w-5 [cmdk-input-wrapper] svg{width:calc(var(--spacing)*5)}.\[\&_\[cmdk-input\]\]\:h-12 [cmdk-input]{height:calc(var(--spacing)*12)}.\[\&_\[cmdk-item\]\]\:px-2 [cmdk-item]{padding-inline:calc(var(--spacing)*2)}.\[\&_\[cmdk-item\]\]\:py-3 [cmdk-item]{padding-block:calc(var(--spacing)*3)}.\[\&_\[cmdk-item\]_svg\]\:h-5 [cmdk-item] svg{height:calc(var(--spacing)*5)}.\[\&_\[cmdk-item\]_svg\]\:w-5 [cmdk-item] svg{width:calc(var(--spacing)*5)}.\[\&_svg\]\:pointer-events-none svg{pointer-events:none}.\[\&_svg\]\:size-4 svg{width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&_svg\]\:shrink-0 svg{flex-shrink:0}.\[\&_svg\:not\(\[class\*\=\'size-\'\]\)\]\:size-4 svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}.\[\&_svg\:not\(\[class\*\=\'text-\'\]\)\]\:text-muted-foreground svg:not([class*=text-]){color:var(--muted-foreground)}}:root{--radius:.625rem;--background:oklch(100% 0 0);--foreground:oklch(14.5% 0 0);--card:oklch(100% 0 0);--card-foreground:oklch(14.5% 0 0);--popover:oklch(100% 0 0);--popover-foreground:oklch(14.5% 0 0);--primary:oklch(20.5% 0 0);--primary-foreground:oklch(98.5% 0 0);--secondary:oklch(97% 0 0);--secondary-foreground:oklch(20.5% 0 0);--muted:oklch(97% 0 0);--muted-foreground:oklch(55.6% 0 0);--accent:oklch(97% 0 0);--accent-foreground:oklch(20.5% 0 0);--destructive:oklch(57.7% .245 27.325);--destructive-foreground:oklch(98.5% 0 0);--border:oklch(92.2% 0 0);--input:oklch(92.2% 0 0);--ring:oklch(70.8% 0 0);--chart-1:oklch(64.6% .222 41.116);--chart-2:oklch(60% .118 184.704);--chart-3:oklch(39.8% .07 227.392);--chart-4:oklch(82.8% .189 84.429);--chart-5:oklch(76.9% .188 70.08);--sidebar:oklch(98.5% 0 0);--sidebar-foreground:oklch(14.5% 0 0);--sidebar-primary:oklch(20.5% 0 0);--sidebar-primary-foreground:oklch(98.5% 0 0);--sidebar-accent:oklch(97% 0 0);--sidebar-accent-foreground:oklch(20.5% 0 0);--sidebar-border:oklch(92.2% 0 0);--sidebar-ring:oklch(70.8% 0 0)}.dark{--background:oklch(14.5% 0 0);--foreground:oklch(98.5% 0 0);--card:oklch(20.5% 0 0);--card-foreground:oklch(98.5% 0 0);--popover:oklch(20.5% 0 0);--popover-foreground:oklch(98.5% 0 0);--primary:oklch(92.2% 0 0);--primary-foreground:oklch(20.5% 0 0);--secondary:oklch(26.9% 0 0);--secondary-foreground:oklch(98.5% 0 0);--muted:oklch(26.9% 0 0);--muted-foreground:oklch(70.8% 0 0);--accent:oklch(26.9% 0 0);--accent-foreground:oklch(98.5% 0 0);--destructive:oklch(70.4% .191 22.216);--destructive-foreground:oklch(98.5% 0 0);--border:oklch(100% 0 0/.1);--input:oklch(100% 0 0/.15);--ring:oklch(55.6% 0 0);--chart-1:oklch(48.8% .243 264.376);--chart-2:oklch(69.6% .17 162.48);--chart-3:oklch(76.9% .188 70.08);--chart-4:oklch(62.7% .265 303.9);--chart-5:oklch(64.5% .246 16.439);--sidebar:oklch(20.5% 0 0);--sidebar-foreground:oklch(98.5% 0 0);--sidebar-primary:oklch(48.8% .243 264.376);--sidebar-primary-foreground:oklch(98.5% 0 0);--sidebar-accent:oklch(26.9% 0 0);--sidebar-accent-foreground:oklch(98.5% 0 0);--sidebar-border:oklch(100% 0 0/.1);--sidebar-ring:oklch(55.6% 0 0)}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-space-x-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@keyframes spin{to{transform:rotate(360deg)}}@keyframes fadeIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes scaleIn{0%{opacity:0;transform:scale(.95)}to{opacity:1;transform:scale(1)}}@keyframes slideIn{0%{opacity:0;transform:translate(20px)}to{opacity:1;transform:translate(0)}}.animate-fade-in{animation:fadeIn .2s ease-out forwards}.animate-scale-in{animation:scaleIn .2s cubic-bezier(.34,1.56,.64,1) forwards}.animate-slide-in{animation:slideIn .3s cubic-bezier(.34,1.56,.64,1) forwards}.transition-all-ease{transition:all .2s cubic-bezier(.34,1.56,.64,1)}</style>
|
|
228
228
|
</head>
|
|
229
229
|
<body>
|