@devmoods/postgres-admin 0.6.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,78 +0,0 @@
1
- var Og=t=>{throw TypeError(t)};var Ch=(t,r,a)=>r.has(t)||Og("Cannot "+a);var L=(t,r,a)=>(Ch(t,r,"read from private field"),a?a.call(t):r.get(t)),De=(t,r,a)=>r.has(t)?Og("Cannot add the same private member more than once"):r instanceof WeakSet?r.add(t):r.set(t,a),me=(t,r,a,i)=>(Ch(t,r,"write to private field"),i?i.call(t,a):r.set(t,a),a),Ue=(t,r,a)=>(Ch(t,r,"access private method"),a);var ic=(t,r,a,i)=>({set _(o){me(t,r,o,a)},get _(){return L(t,r,i)}});function Dw(t,r){for(var a=0;a<r.length;a++){const i=r[a];if(typeof i!="string"&&!Array.isArray(i)){for(const o in i)if(o!=="default"&&!(o in t)){const s=Object.getOwnPropertyDescriptor(i,o);s&&Object.defineProperty(t,o,s.get?s:{enumerable:!0,get:()=>i[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const r=document.createElement("link").relList;if(r&&r.supports&&r.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const s of o)if(s.type==="childList")for(const f of s.addedNodes)f.tagName==="LINK"&&f.rel==="modulepreload"&&i(f)}).observe(document,{childList:!0,subtree:!0});function a(o){const s={};return o.integrity&&(s.integrity=o.integrity),o.referrerPolicy&&(s.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?s.credentials="include":o.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function i(o){if(o.ep)return;o.ep=!0;const s=a(o);fetch(o.href,s)}})();function Kc(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Th={exports:{}},ao={};/**
2
- * @license React
3
- * react-jsx-runtime.production.js
4
- *
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */var Cg;function Aw(){if(Cg)return ao;Cg=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function a(i,o,s){var f=null;if(s!==void 0&&(f=""+s),o.key!==void 0&&(f=""+o.key),"key"in o){s={};for(var d in o)d!=="key"&&(s[d]=o[d])}else s=o;return o=s.ref,{$$typeof:t,type:i,key:f,ref:o!==void 0?o:null,props:s}}return ao.Fragment=r,ao.jsx=a,ao.jsxs=a,ao}var Tg;function Mw(){return Tg||(Tg=1,Th.exports=Aw()),Th.exports}var D=Mw(),Rh={exports:{}},He={};/**
10
- * @license React
11
- * react.production.js
12
- *
13
- * Copyright (c) Meta Platforms, Inc. and affiliates.
14
- *
15
- * This source code is licensed under the MIT license found in the
16
- * LICENSE file in the root directory of this source tree.
17
- */var Rg;function jw(){if(Rg)return He;Rg=1;var t=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),f=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),v=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),S=Symbol.iterator;function p(M){return M===null||typeof M!="object"?null:(M=S&&M[S]||M["@@iterator"],typeof M=="function"?M:null)}var g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},w=Object.assign,x={};function R(M,F,se){this.props=M,this.context=F,this.refs=x,this.updater=se||g}R.prototype.isReactComponent={},R.prototype.setState=function(M,F){if(typeof M!="object"&&typeof M!="function"&&M!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,M,F,"setState")},R.prototype.forceUpdate=function(M){this.updater.enqueueForceUpdate(this,M,"forceUpdate")};function T(){}T.prototype=R.prototype;function A(M,F,se){this.props=M,this.context=F,this.refs=x,this.updater=se||g}var N=A.prototype=new T;N.constructor=A,w(N,R.prototype),N.isPureReactComponent=!0;var j=Array.isArray,O={H:null,A:null,T:null,S:null},q=Object.prototype.hasOwnProperty;function B(M,F,se,de,ce,ge){return se=ge.ref,{$$typeof:t,type:M,key:F,ref:se!==void 0?se:null,props:ge}}function V(M,F){return B(M.type,F,void 0,void 0,void 0,M.props)}function z(M){return typeof M=="object"&&M!==null&&M.$$typeof===t}function X(M){var F={"=":"=0",":":"=2"};return"$"+M.replace(/[=:]/g,function(se){return F[se]})}var te=/\/+/g;function fe(M,F){return typeof M=="object"&&M!==null&&M.key!=null?X(""+M.key):F.toString(36)}function Z(){}function ae(M){switch(M.status){case"fulfilled":return M.value;case"rejected":throw M.reason;default:switch(typeof M.status=="string"?M.then(Z,Z):(M.status="pending",M.then(function(F){M.status==="pending"&&(M.status="fulfilled",M.value=F)},function(F){M.status==="pending"&&(M.status="rejected",M.reason=F)})),M.status){case"fulfilled":return M.value;case"rejected":throw M.reason}}throw M}function ie(M,F,se,de,ce){var ge=typeof M;(ge==="undefined"||ge==="boolean")&&(M=null);var Te=!1;if(M===null)Te=!0;else switch(ge){case"bigint":case"string":case"number":Te=!0;break;case"object":switch(M.$$typeof){case t:case r:Te=!0;break;case y:return Te=M._init,ie(Te(M._payload),F,se,de,ce)}}if(Te)return ce=ce(M),Te=de===""?"."+fe(M,0):de,j(ce)?(se="",Te!=null&&(se=Te.replace(te,"$&/")+"/"),ie(ce,F,se,"",function(je){return je})):ce!=null&&(z(ce)&&(ce=V(ce,se+(ce.key==null||M&&M.key===ce.key?"":(""+ce.key).replace(te,"$&/")+"/")+Te)),F.push(ce)),1;Te=0;var mt=de===""?".":de+":";if(j(M))for(var _e=0;_e<M.length;_e++)de=M[_e],ge=mt+fe(de,_e),Te+=ie(de,F,se,ge,ce);else if(_e=p(M),typeof _e=="function")for(M=_e.call(M),_e=0;!(de=M.next()).done;)de=de.value,ge=mt+fe(de,_e++),Te+=ie(de,F,se,ge,ce);else if(ge==="object"){if(typeof M.then=="function")return ie(ae(M),F,se,de,ce);throw F=String(M),Error("Objects are not valid as a React child (found: "+(F==="[object Object]"?"object with keys {"+Object.keys(M).join(", ")+"}":F)+"). If you meant to render a collection of children, use an array instead.")}return Te}function U(M,F,se){if(M==null)return M;var de=[],ce=0;return ie(M,de,"","",function(ge){return F.call(se,ge,ce++)}),de}function I(M){if(M._status===-1){var F=M._result;F=F(),F.then(function(se){(M._status===0||M._status===-1)&&(M._status=1,M._result=se)},function(se){(M._status===0||M._status===-1)&&(M._status=2,M._result=se)}),M._status===-1&&(M._status=0,M._result=F)}if(M._status===1)return M._result.default;throw M._result}var ne=typeof reportError=="function"?reportError:function(M){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var F=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof M=="object"&&M!==null&&typeof M.message=="string"?String(M.message):String(M),error:M});if(!window.dispatchEvent(F))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",M);return}console.error(M)};function K(){}return He.Children={map:U,forEach:function(M,F,se){U(M,function(){F.apply(this,arguments)},se)},count:function(M){var F=0;return U(M,function(){F++}),F},toArray:function(M){return U(M,function(F){return F})||[]},only:function(M){if(!z(M))throw Error("React.Children.only expected to receive a single React element child.");return M}},He.Component=R,He.Fragment=a,He.Profiler=o,He.PureComponent=A,He.StrictMode=i,He.Suspense=h,He.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=O,He.act=function(){throw Error("act(...) is not supported in production builds of React.")},He.cache=function(M){return function(){return M.apply(null,arguments)}},He.cloneElement=function(M,F,se){if(M==null)throw Error("The argument must be a React element, but you passed "+M+".");var de=w({},M.props),ce=M.key,ge=void 0;if(F!=null)for(Te in F.ref!==void 0&&(ge=void 0),F.key!==void 0&&(ce=""+F.key),F)!q.call(F,Te)||Te==="key"||Te==="__self"||Te==="__source"||Te==="ref"&&F.ref===void 0||(de[Te]=F[Te]);var Te=arguments.length-2;if(Te===1)de.children=se;else if(1<Te){for(var mt=Array(Te),_e=0;_e<Te;_e++)mt[_e]=arguments[_e+2];de.children=mt}return B(M.type,ce,void 0,void 0,ge,de)},He.createContext=function(M){return M={$$typeof:f,_currentValue:M,_currentValue2:M,_threadCount:0,Provider:null,Consumer:null},M.Provider=M,M.Consumer={$$typeof:s,_context:M},M},He.createElement=function(M,F,se){var de,ce={},ge=null;if(F!=null)for(de in F.key!==void 0&&(ge=""+F.key),F)q.call(F,de)&&de!=="key"&&de!=="__self"&&de!=="__source"&&(ce[de]=F[de]);var Te=arguments.length-2;if(Te===1)ce.children=se;else if(1<Te){for(var mt=Array(Te),_e=0;_e<Te;_e++)mt[_e]=arguments[_e+2];ce.children=mt}if(M&&M.defaultProps)for(de in Te=M.defaultProps,Te)ce[de]===void 0&&(ce[de]=Te[de]);return B(M,ge,void 0,void 0,null,ce)},He.createRef=function(){return{current:null}},He.forwardRef=function(M){return{$$typeof:d,render:M}},He.isValidElement=z,He.lazy=function(M){return{$$typeof:y,_payload:{_status:-1,_result:M},_init:I}},He.memo=function(M,F){return{$$typeof:v,type:M,compare:F===void 0?null:F}},He.startTransition=function(M){var F=O.T,se={};O.T=se;try{var de=M(),ce=O.S;ce!==null&&ce(se,de),typeof de=="object"&&de!==null&&typeof de.then=="function"&&de.then(K,ne)}catch(ge){ne(ge)}finally{O.T=F}},He.unstable_useCacheRefresh=function(){return O.H.useCacheRefresh()},He.use=function(M){return O.H.use(M)},He.useActionState=function(M,F,se){return O.H.useActionState(M,F,se)},He.useCallback=function(M,F){return O.H.useCallback(M,F)},He.useContext=function(M){return O.H.useContext(M)},He.useDebugValue=function(){},He.useDeferredValue=function(M,F){return O.H.useDeferredValue(M,F)},He.useEffect=function(M,F){return O.H.useEffect(M,F)},He.useId=function(){return O.H.useId()},He.useImperativeHandle=function(M,F,se){return O.H.useImperativeHandle(M,F,se)},He.useInsertionEffect=function(M,F){return O.H.useInsertionEffect(M,F)},He.useLayoutEffect=function(M,F){return O.H.useLayoutEffect(M,F)},He.useMemo=function(M,F){return O.H.useMemo(M,F)},He.useOptimistic=function(M,F){return O.H.useOptimistic(M,F)},He.useReducer=function(M,F,se){return O.H.useReducer(M,F,se)},He.useRef=function(M){return O.H.useRef(M)},He.useState=function(M){return O.H.useState(M)},He.useSyncExternalStore=function(M,F,se){return O.H.useSyncExternalStore(M,F,se)},He.useTransition=function(){return O.H.useTransition()},He.version="19.0.0",He}var Dg;function Gc(){return Dg||(Dg=1,Rh.exports=jw()),Rh.exports}var E=Gc();const Nr=Kc(E),_w=Dw({__proto__:null,default:Nr},[E]),C1=6e4,T1=36e5,Ag=Symbol.for("constructDateFrom");function R1(t,r){return typeof t=="function"?t(r):t&&typeof t=="object"&&Ag in t?t[Ag](r):t instanceof Date?new t.constructor(r):new Date(r)}function Eo(t,r){return R1(r||t,t)}function Nw(t,r){const a=+Eo(t)-+Eo(r);return a<0?-1:a>0?1:a}function D1(t){return t instanceof Date||typeof t=="object"&&Object.prototype.toString.call(t)==="[object Date]"}function Qa(t,r){const a=t<0?"-":"",i=Math.abs(t).toString().padStart(r,"0");return a+i}function Mg(t,r){const a=Eo(t,r==null?void 0:r.in);if(isNaN(+a))throw new RangeError("Invalid time value");const i=(r==null?void 0:r.format)??"extended",o=(r==null?void 0:r.representation)??"complete";let s="",f="";const d=i==="extended"?"-":"",h=i==="extended"?":":"";if(o!=="time"){const v=Qa(a.getDate(),2),y=Qa(a.getMonth()+1,2);s=`${Qa(a.getFullYear(),4)}${d}${y}${d}${v}`}if(o!=="date"){const v=a.getTimezoneOffset();if(v!==0){const x=Math.abs(v),R=Qa(Math.trunc(x/60),2),T=Qa(x%60,2);f=`${v<0?"+":"-"}${R}:${T}`}else f="Z";const y=Qa(a.getHours(),2),S=Qa(a.getMinutes(),2),p=Qa(a.getSeconds(),2),g=s===""?"":"T",w=[y,S,p].join(h);s=`${s}${g}${w}${f}`}return s}function zw(t,r){const a=()=>R1(r==null?void 0:r.in,NaN),o=$w(t);let s;if(o.date){const v=Bw(o.date,2);s=Pw(v.restDateString,v.year)}if(!s||isNaN(+s))return a();const f=+s;let d=0,h;if(o.time&&(d=qw(o.time),isNaN(d)))return a();if(o.timezone){if(h=kw(o.timezone),isNaN(h))return a()}else{const v=new Date(f+d),y=Eo(0,r==null?void 0:r.in);return y.setFullYear(v.getUTCFullYear(),v.getUTCMonth(),v.getUTCDate()),y.setHours(v.getUTCHours(),v.getUTCMinutes(),v.getUTCSeconds(),v.getUTCMilliseconds()),y}return Eo(f+d+h,r==null?void 0:r.in)}const lc={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Lw=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,Hw=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Uw=/^([+-])(\d{2})(?::?(\d{2}))?$/;function $w(t){const r={},a=t.split(lc.dateTimeDelimiter);let i;if(a.length>2)return r;if(/:/.test(a[0])?i=a[0]:(r.date=a[0],i=a[1],lc.timeZoneDelimiter.test(r.date)&&(r.date=t.split(lc.timeZoneDelimiter)[0],i=t.substr(r.date.length,t.length))),i){const o=lc.timezone.exec(i);o?(r.time=i.replace(o[1],""),r.timezone=o[1]):r.time=i}return r}function Bw(t,r){const a=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+r)+"})|(\\d{2}|[+-]\\d{"+(2+r)+"})$)"),i=t.match(a);if(!i)return{year:NaN,restDateString:""};const o=i[1]?parseInt(i[1]):null,s=i[2]?parseInt(i[2]):null;return{year:s===null?o:s*100,restDateString:t.slice((i[1]||i[2]).length)}}function Pw(t,r){if(r===null)return new Date(NaN);const a=t.match(Lw);if(!a)return new Date(NaN);const i=!!a[4],o=io(a[1]),s=io(a[2])-1,f=io(a[3]),d=io(a[4]),h=io(a[5])-1;if(i)return Kw(r,d,h)?Fw(r,d,h):new Date(NaN);{const v=new Date(0);return!Yw(r,s,f)||!Qw(r,o)?new Date(NaN):(v.setUTCFullYear(r,s,Math.max(o,f)),v)}}function io(t){return t?parseInt(t):1}function qw(t){const r=t.match(Hw);if(!r)return NaN;const a=Dh(r[1]),i=Dh(r[2]),o=Dh(r[3]);return Gw(a,i,o)?a*T1+i*C1+o*1e3:NaN}function Dh(t){return t&&parseFloat(t.replace(",","."))||0}function kw(t){if(t==="Z")return 0;const r=t.match(Uw);if(!r)return 0;const a=r[1]==="+"?-1:1,i=parseInt(r[2]),o=r[3]&&parseInt(r[3])||0;return Xw(i,o)?a*(i*T1+o*C1):NaN}function Fw(t,r,a){const i=new Date(0);i.setUTCFullYear(t,0,4);const o=i.getUTCDay()||7,s=(r-1)*7+a+1-o;return i.setUTCDate(i.getUTCDate()+s),i}const Vw=[31,null,31,30,31,30,31,31,30,31,30,31];function A1(t){return t%400===0||t%4===0&&t%100!==0}function Yw(t,r,a){return r>=0&&r<=11&&a>=1&&a<=(Vw[r]||(A1(t)?29:28))}function Qw(t,r){return r>=1&&r<=(A1(t)?366:365)}function Kw(t,r,a){return r>=1&&r<=53&&a>=0&&a<=6}function Gw(t,r,a){return t===24?r===0&&a===0:a>=0&&a<60&&r>=0&&r<60&&t>=0&&t<25}function Xw(t,r){return r>=0&&r<=59}const M1={email:Zw,date:_g,"date-time":_g},jg={"credit-card-number":Iw};function Zw(t){if(!t)return!1;const r=t.split("@");return!(r.length!==2||!r[1].includes(".")||r[0].substr(-1)===".")}function _g(t){if(!t)return!1;const r=zw(t);return isNaN(r.getTime())?!1:D1(r)}function Iw(t){return typeof t!="string"?"":t.replace(/\D+/g,"")}const Jw=j1();function j1(t=0){let r=t;const a=()=>++r;return a.reset=()=>r=0,a}function Ww(t){return t.length===0?void 0:t[t.length-1]}function Xc(t,r){if(!Array.isArray(r))return t;const a=new Set(r),i=new Set(t),o=[];for(const s of r)i.has(s)&&o.push(s);for(const s of t)a.has(s)||o.push(s);return o}function _1(t,r){if(!t)throw new Error("Invariant failed")}function N1(t,r){if(!t){console.warn(r);try{throw new Error(r)}catch{}}}function gn(t){return t.type==="object"||!!t.properties||Array.isArray(t.required)||Array.isArray(t.allOf)||!!(t.if&&gn(t.if))}function lm(t,r="schema must be of type object"){if(!t||!gn(t))throw new Error(r)}function si(t){return t.type==="string"||typeof t.const=="string"}function Zc(t){return t.type==="number"}function Ic(t){return t.type==="integer"}function jo(t){return t.type==="boolean"||typeof t.const=="boolean"}function ga(t){return t.type==="array"}function Fm(t){return t.type==="null"}function eO(t,r){if(t.$bitiforms&&t.$bitiforms.widget){const a=t.$bitiforms.widget;if(!Object.prototype.hasOwnProperty.call(r,a))throw new Error(`Unknown widget ${a}`);return r[a]}if(Fm(t))return E.Fragment;if(ga(t))return si(t.items)?r.CheckboxGroupWidget:r.ArrayWidget;if(gn(t))return r.ObjectWidget;if(jo(t))return r.CheckboxWidget;if(si(t)){if(t.enum||t.oneOf)return r.RadioGroupWidget;if(t.format&&t.format.startsWith("date"))return r.DateWidget}return Zc(t)||Ic(t)?r.NumberWidget:r.TextInputWidget}function tO(t,r){const a=eO(t,r);if(a==null)throw new Error(`Resolved widget is undefined for schema ${JSON.stringify(t)}`);return a}const nO={"wizard.next":"Continue","wizard.prev":"Go back","wizard.fixErrorsBeforeContinue":"Fix the errors above before continuing","errors.required":"Must be filled in","errors.radiogroup.required":"Select an element","errors.checkbox.required":"Must be checked","errors.minItems":"You must select at least {count}","errors.maxLength":"The maximum length is {maxLength}","errors.minLength":"The minimum length is {minLength}","errors.minimum":"Minimum value is {minimum}","errors.invalidFormat.email":"Not a valid email address","arrayfield.remove":"Remove item","arrayfield.add":"Add item"},rO=M1,Ga={widgets:{},formats:rO,texts:nO,resolveWidget:tO},Vm=E.createContext(Ga);Vm.displayName="FormConfigContext";function Ym(){return E.useContext(Vm)}function aO({widgets:t=Ga.widgets,texts:r=Ga.texts,formats:a=Ga.formats,resolveWidget:i=Ga.resolveWidget,children:o}){const s=E.useMemo(()=>({widgets:{...Ga.widgets,...t},texts:{...Ga.texts,...r},formats:{...Ga.formats,...a},resolveWidget:i}),[t,r,a,i]);return D.jsx(Vm.Provider,{value:s,children:o})}const z1=E.createContext({});z1.displayName="FormValuesContext";const Qm=E.createContext(!1);Qm.displayName="RevealErrorsContext";function Jc(){const t=E.useContext(Qm),[r,a]=E.useState(!1),i=E.useCallback(()=>a(!0),[]);return E.useEffect(()=>{a(t)},[t]),{value:r,enable:i}}const Km=E.createContext(null);Km.displayName="UpdateValuesContext";function L1(t){const r=E.useContext(Km);if(r==null)throw new Error("Not wrapped in UpdateValuesContext.Provider");return E.useCallback(a=>r(t,a),[t,r])}const H1=E.createContext(null);H1.displayName="FormRendererContext";function pr(t){return t==null?!1:Array.isArray(t)?t.length===0?!1:t.some(r=>pr(r)):U1(t)?!0:typeof t=="object"?Object.keys(t).some(r=>pr(t[r])):typeof t=="string"}function U1(t){return!!(t&&typeof t=="object"&&!Array.isArray(t)&&typeof t.message=="string"&&t.args)}function Wc(t,r){return t.map(a=>U1(a)?iO((r==null?void 0:r[a.message])??a.message,a.args):(r==null?void 0:r[a])||a).join(", ")}function iO(t,r){const a=Object.keys(r).join("|");return(t||"").replace(new RegExp(`{(${a})}`,"g"),(i,o)=>r[o]??i)}const lO=M1;function $1({formats:t=lO}={}){function r(p,g,w){if(typeof p.const<"u"&&p.const!==g)return[mn("errors.const",p,{value:p.const})];const x=[];if(uc(g))return w?(x.push(Dr("errors.required",p)),x):[];const R=g.length;if(p.minLength&&R<p.minLength&&x.push(mn("errors.minLength",p,{minLength:p.minLength})),p.maxLength&&R>p.maxLength&&x.push(mn("errors.maxLength",p,{maxLength:p.maxLength})),p.enum&&!p.enum.includes(g)&&x.push(mn("errors.oneOf",p,{values:p.enum})),p.oneOf&&!p.oneOf.some(T=>!pr(y(T,g,!0)))&&x.push(mn("errors.oneOf",p,{})),p.format){const T=p.format;N1(Object.prototype.hasOwnProperty.call(t,T),`${T} format validator is not implemented.`);const A=t[T];A!=null&&!A(g)&&x.push(Dr(`errors.invalidFormat.${p.format}`,p))}return x}function a(p,g,w){if(typeof p.const<"u"&&p.const!==g)return[mn("errors.const",p,{value:p.const})];const x=[];return uc(g)?w?(x.push(Dr("errors.required",p)),x):[]:(p.enum&&!p.enum.includes(g)&&x.push(mn("errors.oneOf",p,{values:p.enum})),x)}function i(p,g,w){if(typeof p.const<"u"&&p.const!==g)return[mn("errors.const",p,{value:p.const})];const x=[];if(uc(g)||isNaN(g))return w?(x.push(Dr("errors.required",p)),x):[];const R=parseFloat(`${g}`);return p.minimum&&R<p.minimum&&x.push(mn("errors.minimum",p,{minimum:p.minimum})),p.maximum&&R>p.maximum&&x.push(mn("errors.maximum",p,{maximum:p.maximum})),x}function o(p,g,w){if(typeof p.const<"u"&&p.const!==g)return[mn("errors.const",p,{value:p.const})];const x=[];if(uc(g)||isNaN(g))return w?(x.push(Dr("errors.required",p)),x):[];const R=parseFloat(`${g}`);return Number.isInteger(R)||x.push(Dr("errors.notAnInteger",p)),p.minimum&&R<p.minimum&&x.push(mn("errors.minimum",p,{minimum:p.minimum})),p.maximum&&R>p.maximum&&x.push(mn("errors.maximum",p,{maximum:p.maximum})),x}function s(p,g){const w={all:[],items:[]};if(p.minItems&&p.minItems>0&&(g||[]).length<p.minItems&&w.all.push(mn("errors.minItems",p,{count:p.minItems})),p.maxItems&&(g||[]).length>p.maxItems&&w.all.push(mn("errors.maxItems",p,{count:p.maxItems})),p.contains){const x=p.contains;(!Array.isArray(g)||g.every(R=>pr(y(x,R,!1))))&&w.all.push(Dr("errors.notContains",p))}return g&&g.length>0&&(w.items=g.map(x=>{const R=zr(p.items,x),T=y(R,x,!1);return gn(R)?{_id:x._id,...T}:T})),w}function f(p,g){const w=p.properties||{},x=Object.keys(w).reduce((R,T)=>(R[T]=y(w[T],(g||{})[T],(p.required||[]).includes(T)),R),{_all:[]});if(p.anyOf){let R=!1;for(const T of p.anyOf)if(!pr(f(T,g))){R=!0;break}R||(x._all=[Dr("errors.anyOf",p)])}return x}function d(p,g){return g==null?[]:[Dr("errors.shouldBeNull",p)]}const h=new WeakMap,v=new WeakMap;function y(p,g,w){const x=R=>{const T=h.get(p);if(T!==void 0&&T===g)return v.get(p);const A=R();return h.set(p,g),v.set(p,A),A};if(gn(p))return f(p,g);if(si(p))return x(()=>r(p,g,w));if(jo(p))return x(()=>a(p,g,w));if(Zc(p))return x(()=>i(p,g,w));if(Ic(p))return x(()=>o(p,g,w));if(ga(p))return s(p,g);if(Fm(p))return d(p,g);throw new Error(`validateSchema() got invalid schema ${JSON.stringify(p)}`)}function S(p,g){return y(p,g,!0)}return{validateSchema:S}}function mn(t,r,a){return{message:Dr(t,r),args:a}}function Dr(t,r){var a,i;return((i=(a=r.$bitiforms)==null?void 0:a.errorMessages)==null?void 0:i[t])||t}function uc(t){return typeof t=="string"?t.trim()==="":t==null}let Ah;function uO(){return Ah==null&&(Ah=$1().validateSchema),Ah}function oO(t,r){if(!gn(t))throw new Error("Tried to evaluate an if that is not a ObjectSchema");const a=uO()(t,r);return!pr(a)}function zr(t,r){const a=t.$bitiforms||{};if(gn(t)){const i={...t.properties||{}},o=[...t.required||[]];for(const f of Object.keys(i))i[f]=zr(i[f],(r||{})[f]);if(t.if){t.then!=null&&lm(t.then,`schemas using \`if\` should also have \`then\` of type object: ${JSON.stringify(t)}`);const f=oO(t.if,r)?t.then:t.else;N1(typeof(f==null?void 0:f.$bitiforms)>"u",`$bitiforms must not be set on branched schemas.
18
- Got schema ${JSON.stringify(f,null,2)}`);const d=f!=null?zr(f,r):null;d&&(lm(d,`then and else schemas must be object schemas: ${JSON.stringify(d,null,2)}`),d.required&&o.push(...d.required),Object.assign(i,d.properties))}if(t.allOf)for(const f of t.allOf){const d=zr(f,r);gn(d)&&(d.required&&o.push(...d.required),Object.assign(i,d.properties))}const s={type:"object",properties:i,$bitiforms:a,required:[...new Set(o)]};return t.title&&(s.title=t.title),t.description&&(s.description=t.description),s}return t}function Mh(t,r={}){const a=[];for(const i of t){const o=zr(i,r);sO(o)&&a.push(o)}return a}function sO(t){return!!(gn(t)&&t.properties&&Object.keys(t.properties).length>0)}function cO(t,r){if(Array.isArray(t))return Mh(t,r);const a=Object.keys(t.properties||{}).length>0;if(Array.isArray(t.allOf)){const{allOf:i,...o}=t;return Mh(a?[o].concat(i):i,r)}if(a)return Mh([t],r);throw new Error("resolveBaseSchema() either takes an array of ObjectSchemas or an ObjectSchema with an .allOf property.")}function fO(t){const r={type:"object",properties:{}},a=[];for(const i of t)Object.assign(r.properties,i.properties),i.required&&a.push(...i.required);return a.length>0&&(r.required=[...new Set(a)]),r}function Pl(t,r){if(gn(t)){const a=t.properties||{};return{...r||lo(t),...Object.keys(a).reduce((i,o)=>(i[o]=Pl(a[o],(r||{})[o]),i),{})}}return ga(t)?gn(t.items)?(r||lo(t)).map(a=>{const i=a||lo(t.items);return{...i,_id:i._id==null?Jw():i._id,...Pl(zr(t.items,i),i)}}):(r||lo(t)).map(a=>Pl(t.items,a)):Object.prototype.hasOwnProperty.call(t,"const")?t.const:r??lo(t)}function lo(t){if(Object.prototype.hasOwnProperty.call(t,"default"))return t.default;if(gn(t))return{};if(si(t))return"";if(jo(t)||Zc(t)||Ic(t)||Fm(t))return null;if(ga(t))return[];throw new Error(`getDefaultValue invalid schema ${JSON.stringify(t)}`)}function um(t,r){if(gn(t)){const a=t.properties||{};return Object.keys(a).reduce((i,o)=>(i[o]=um(a[o],r[o]),i),{})}return ga(t)?(r||[]).map(a=>um(zr(t.items,a),a)):si(t)&&t.format&&jg[t.format]?jg[t.format](r):r}const dO=(t,r,a)=>(t||[]).find(i=>i._id===r)||a;function hO({id:t,name:r,path:a,value:i,schema:o,errors:s,disabled:f,texts:d,renderAddButton:h,renderItem:v,renderContainer:y}){const[S]=E.useState(()=>{var j;return j1((j=Ww(i))==null?void 0:j._id)}),p=L1(a),g=E.useCallback(()=>{p(j=>j.concat({_id:S(),...Pl(zr(o.items,{}),{})}))},[S,o.items,p]),w=E.useCallback(j=>{p(O=>O.filter(q=>q._id!==j))},[p]),x=E.useCallback((j,O)=>{p(q=>q.map(B=>{if(B._id===j){const V={...B,[O.target.name]:O.target.value};return Pl(zr(o.items,V),V)}return B}))},[p,o.items]),R=Jc();lm(o.items);const T=!!(R.value&&s&&s.all.length>0),A=i.length,N=D.jsxs(D.Fragment,{children:[i.map((j,O)=>D.jsx(mO,{id:j._id,path:`${a}/${O}`,parentId:t,parentName:r,item:j,onFieldChange:x,render:v,index:O,onRemove:w,schema:o.items,errors:s,texts:d},j._id)),h({disabled:f,onClick:g,itemCount:A,texts:d})]});return D.jsx(D.Fragment,{children:y({schema:o,name:r,id:t,children:N,errors:T?Wc(s.all,d):null,itemCount:A,texts:d})})}const mO=E.memo(function({parentId:t,parentName:r,path:a,render:i,id:o,index:s,texts:f,onRemove:d,item:h,schema:v,onFieldChange:y,errors:S}){var T;const p=zr(v,h),g=p.properties||{},w=Xc(Object.keys(g),(T=v.$bitiforms)==null?void 0:T.propertyOrder),x=dO(S.items,o,{}),R=w.reduce((A,N)=>(A[N]={path:`${a}/${N}`,schema:(p.properties||{})[N],id:`${t}__${N}__${o}`,name:`${r}__${N}__${o}`,onChange:j=>y(o,{target:{name:N,value:j.target.value}}),value:h[N],errors:x[N],texts:f},A),{});return D.jsx(D.Fragment,{children:i==null?void 0:i({fields:R,index:s,id:o,path:a,onRemove:()=>{d(o)},texts:f})})}),Gm=E.memo(function(t){const{texts:r,resolveWidget:a,widgets:i}=Ym();_1(typeof t.name=="string"&&t.name.trim()!=="");const o=a(t.schema,i);return D.jsx(E.Suspense,{fallback:D.jsx("div",{}),children:D.jsx(o,{...t,texts:r})})});var jh,Ng;function vO(){if(Ng)return jh;Ng=1;var t=typeof Element<"u",r=typeof Map=="function",a=typeof Set=="function",i=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function o(s,f){if(s===f)return!0;if(s&&f&&typeof s=="object"&&typeof f=="object"){if(s.constructor!==f.constructor)return!1;var d,h,v;if(Array.isArray(s)){if(d=s.length,d!=f.length)return!1;for(h=d;h--!==0;)if(!o(s[h],f[h]))return!1;return!0}var y;if(r&&s instanceof Map&&f instanceof Map){if(s.size!==f.size)return!1;for(y=s.entries();!(h=y.next()).done;)if(!f.has(h.value[0]))return!1;for(y=s.entries();!(h=y.next()).done;)if(!o(h.value[1],f.get(h.value[0])))return!1;return!0}if(a&&s instanceof Set&&f instanceof Set){if(s.size!==f.size)return!1;for(y=s.entries();!(h=y.next()).done;)if(!f.has(h.value[0]))return!1;return!0}if(i&&ArrayBuffer.isView(s)&&ArrayBuffer.isView(f)){if(d=s.length,d!=f.length)return!1;for(h=d;h--!==0;)if(s[h]!==f[h])return!1;return!0}if(s.constructor===RegExp)return s.source===f.source&&s.flags===f.flags;if(s.valueOf!==Object.prototype.valueOf&&typeof s.valueOf=="function"&&typeof f.valueOf=="function")return s.valueOf()===f.valueOf();if(s.toString!==Object.prototype.toString&&typeof s.toString=="function"&&typeof f.toString=="function")return s.toString()===f.toString();if(v=Object.keys(s),d=v.length,d!==Object.keys(f).length)return!1;for(h=d;h--!==0;)if(!Object.prototype.hasOwnProperty.call(f,v[h]))return!1;if(t&&s instanceof Element)return!1;for(h=d;h--!==0;)if(!((v[h]==="_owner"||v[h]==="__v"||v[h]==="__o")&&s.$$typeof)&&!o(s[v[h]],f[v[h]]))return!1;return!0}return s!==s&&f!==f}return jh=function(f,d){try{return o(f,d)}catch(h){if((h.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw h}},jh}var pO=vO();const bc=Kc(pO);class Dc{static from(r){if(r==="")return new Dc([]);r.startsWith("/")||(r=`/${r}`);const[,...a]=r.split("/");return new Dc(a.map(i=>i.replace(/~1/g,"/").replace(/~0/g,"~")))}constructor(r){this.tokens=r}toString(){return this.tokens.length===0?"":`/${this.tokens.map(r=>r.replace(/~/g,"~0").replace(/\//g,"~1")).join("/")}`}toPath(){return this.tokens}}function yO(t,r,a){const i=(typeof r=="string"?Dc.from(r):r).toPath(),o=(s,f,d,h)=>{let v,y=f[h];return f.length>h?(Array.isArray(s)?(y=parseInt(y,10),v=s.slice()):v={...s},v[y]=o(s[y]!==void 0?s[y]:{},f,d,h+1),v):typeof d=="function"?d(s):d};return o(t,i,a,0)}let Ac=class extends Error{constructor(r){super("SubmissionError"),this.errors=r}};const zg=1,Lg=2,Hg=4,Ug=5,$g=6,Bg=7,Pg=8,gO={};function bO(t){const r=E.useId();return t||r}function SO({name:t,initialValues:r=gO,schema:a,disabled:i,onSubmit:o,onFormValuesChanged:s}){const f=xO(),d=bO(t);function h(j,O){function q(B){const V=Nh(a,B.values,!1,f());let z=!0;bc(V.steps,B.steps)&&(z=!1,V.steps=B.steps);let X=!0;bc(V.values,B.values)&&(X=!1,V.values=B.values);let te=!0;return bc(V.errors,B.errors)&&(te=!1,V.errors=B.errors),!z&&!X&&!te?B:{...B,...V}}switch(O.type){case zg:return{...j,submissionState:"not-submitted",submissionErrors:{},revealAllErrors:!1};case Lg:return q(j);case Hg:return{...j,submissionState:"submitting"};case Ug:return{...j,submissionState:"submitted"};case $g:{const B=O.error;return{...j,submissionState:"failed",submissionErrors:B instanceof Ac?B.errors:{},revealAllErrors:!0}}case Bg:return{...j,revealAllErrors:O.value};case Pg:return q({...j,values:yO(j.values,O.path,O.updater)});default:return j}}const v=E.useRef(!0);E.useEffect(()=>(v.current=!0,()=>{v.current=!1}),[]);const[y,S]=E.useReducer(h,void 0,()=>{const{steps:j,errors:O,values:q}=Nh(a,r,!1,f());return{values:q,steps:j,touched:{},errors:O,submissionState:"not-submitted",submissionErrors:{},revealAllErrors:!1}});E.useEffect(()=>{s==null||s(y.values)},[y.values,s]),E.useEffect(()=>{S({type:Lg})},[a]);const p=E.useCallback(j=>{S({type:Bg,value:j})},[]),g=E.useCallback((j,O)=>{S({type:Pg,path:j,updater:O})},[]),w=E.useCallback(j=>{if(i)return;const{name:O,value:q}=j.target;g("",B=>({...B,[O]:q}))},[i,g]),x=async j=>{var V;if(!v.current||i)return;(V=j.preventDefault)==null||V.call(j),S({type:Hg});const{errors:O,values:q}=Nh(a,y.values,!0,f()),B=!pr(O);try{if(await(o==null?void 0:o({values:q,errors:O,isValid:B}))===!1)throw new Ac({});S({type:Ug})}catch(z){S({type:$g,error:z})}},R=()=>y.steps.map(j=>{const{properties:O={},$bitiforms:q={}}=j,B=Xc(Object.keys(O),q.propertyOrder).reduce((V,z)=>(V[z]={path:z,schema:O[z],value:y.values[z],id:`form-${d}-${z}`,name:z,errors:y.errors[z],onChange:w,disabled:i},V),{});return{isValid:()=>!Object.keys(B).some(V=>pr(B[V].errors)),fields:B}}),T=E.useCallback(()=>{v.current&&S({type:zg})},[]),A=R(),N={name:d,errors:y.errors,steps:A,values:y.values,onSubmit:x,submissionState:y.submissionState,clearSubmission:T,submissionErrors:y.submissionErrors,revealAllErrors:p,schema:a};return[N,{revealAllErrors:y.revealAllErrors,values:N.values,updateValues:g}]}function _h({revealAllErrors:t,values:r,updateValues:a,children:i}){return D.jsx(Km.Provider,{value:a,children:D.jsx(Qm.Provider,{value:t,children:D.jsx(z1.Provider,{value:r,children:i})})})}function B1({render:t,component:r,element:a,...i}){const[o,s]=SO(i);if(typeof t=="function"&&r)throw new Error("one of render or component must be provided, but not both");if(typeof t=="function")return D.jsx(_h,{...s,children:t(o)});if(a)return D.jsx(_h,{...s,children:D.jsx(H1.Provider,{value:o,children:a})});if(r)return D.jsx(_h,{...s,children:D.jsx(r,{...o})});throw new Error("one of render or component must be provided")}function xO(){const{formats:t}=Ym(),r=E.useRef();function a(){return r.current==null&&(r.current=$1({formats:t})),r.current}return a}function Nh(t,r,a,i){const o=cO(t,r),s=fO(o);let f=Pl(s,r);a&&(f=um(s,f));const d=i.validateSchema(s,f);return{steps:o,values:f,errors:d}}function EO({id:t,name:r,path:a,value:i,schema:o,errors:s,disabled:f,texts:d}){const h=L1(a),v=E.useCallback((p,g)=>{h(w=>({...w,[p]:g}))},[h]),y=o.$bitiforms||{},S=o.properties||{};return D.jsxs("div",{"data-bitiforms-object":!0,role:"group","data-field-path":a,children:[o.title&&D.jsx("legend",{"data-bitiforms-object-title":!0,children:o.title}),o.description&&D.jsx("div",{"data-bitiforms-object-description":!0,children:o.description}),D.jsx("div",{"data-bitiforms-object-fields":!0,children:Xc(Object.keys(S),y.propertyOrder).map(p=>{const g=`${r}_${p}`;return D.jsx(wO,{path:`${a}/${p}`,field:p,schema:S[p],value:i[p],id:`${t}_${p}`,errors:s[p],name:g,onChange:v,disabled:f,texts:d},g)})})]})}const wO=E.memo(function({field:t,onChange:r,...a}){return D.jsx(Gm,{...a,onChange:i=>r(t,i.target.value)})});function OO(t){var a;if(!t.enum)return[];const r=[];for(let i=0;i<t.enum.length;i++)r.push([t.enum[i],((a=t.$enumNames)==null?void 0:a[i])||t.enum[i]]);return r}function P1(t){return E.useMemo(()=>{if(si(t)){const r=o=>o,a=o=>o;let i=[];return t.enum?i=OO(t):t.oneOf&&(i=t.oneOf.map(o=>{const s=o.const?o.const:o.enum?o.enum[0]:null;return[s||"",o.title||s||""]})),{values:i,fromSchemaValue:a,toSchemaValue:r}}if(jo(t))return{values:[["yes","Yes"],["no","No"]],fromSchemaValue:r=>r===!0?"yes":r===!1?"no":null,toSchemaValue:r=>{switch(r){case"yes":return!0;case"no":return!1;default:return null}}};if(Zc(t)||Ic(t)){const r=i=>parseInt(i??"",10),a=[];for(let i=t.minimum??0;i<=(t.maximum??20);i++)a.push([`${i}`,`${i}`]);return{values:a,fromSchemaValue:i=>`${i}`,toSchemaValue:r}}throw new Error("Invalid schema given to SelectWidget")},[t])}const CO=t=>t;function _o(t,r=CO){const a=t.name,i=Jc(),o=()=>{i.enable()},s=d=>{const h=r(d.target.value);t.onChange({target:{name:a,value:h}})},f=i.value?Wc(t.errors,t.texts):void 0;return{onBlur:o,onChange:s,error:f,schema:t.schema,$bitiforms:t.schema.$bitiforms||{},id:t.id,name:t.name,value:t.value,disabled:t.disabled}}var q1={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},qg=Nr.createContext&&Nr.createContext(q1),TO=["attr","size","title"];function RO(t,r){if(t==null)return{};var a=DO(t,r),i,o;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(o=0;o<s.length;o++)i=s[o],!(r.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(t,i)&&(a[i]=t[i])}return a}function DO(t,r){if(t==null)return{};var a={};for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)){if(r.indexOf(i)>=0)continue;a[i]=t[i]}return a}function Mc(){return Mc=Object.assign?Object.assign.bind():function(t){for(var r=1;r<arguments.length;r++){var a=arguments[r];for(var i in a)Object.prototype.hasOwnProperty.call(a,i)&&(t[i]=a[i])}return t},Mc.apply(this,arguments)}function kg(t,r){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);r&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),a.push.apply(a,i)}return a}function jc(t){for(var r=1;r<arguments.length;r++){var a=arguments[r]!=null?arguments[r]:{};r%2?kg(Object(a),!0).forEach(function(i){AO(t,i,a[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):kg(Object(a)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(a,i))})}return t}function AO(t,r,a){return r=MO(r),r in t?Object.defineProperty(t,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[r]=a,t}function MO(t){var r=jO(t,"string");return typeof r=="symbol"?r:r+""}function jO(t,r){if(typeof t!="object"||!t)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var i=a.call(t,r||"default");if(typeof i!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(t)}function k1(t){return t&&t.map((r,a)=>Nr.createElement(r.tag,jc({key:a},r.attr),k1(r.child)))}function Jt(t){return r=>Nr.createElement(_O,Mc({attr:jc({},t.attr)},r),k1(t.child))}function _O(t){var r=a=>{var{attr:i,size:o,title:s}=t,f=RO(t,TO),d=o||a.size||"1em",h;return a.className&&(h=a.className),t.className&&(h=(h?h+" ":"")+t.className),Nr.createElement("svg",Mc({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},a.attr,i,f,{className:h,style:jc(jc({color:t.color||a.color},a.style),t.style),height:d,width:d,xmlns:"http://www.w3.org/2000/svg"}),s&&Nr.createElement("title",null,s),t.children)};return qg!==void 0?Nr.createElement(qg.Consumer,null,a=>r(a)):r(q1)}function NO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M346.5 240H272v-74.5c0-8.8-7.2-16-16-16s-16 7.2-16 16V240h-74.5c-8.8 0-16 6-16 16s7.5 16 16 16H240v74.5c0 9.5 7 16 16 16s16-7.2 16-16V272h74.5c8.8 0 16-7.2 16-16s-7.2-16-16-16z"},child:[]},{tag:"path",attr:{d:"M256 76c48.1 0 93.3 18.7 127.3 52.7S436 207.9 436 256s-18.7 93.3-52.7 127.3S304.1 436 256 436c-48.1 0-93.3-18.7-127.3-52.7S76 304.1 76 256s18.7-93.3 52.7-127.3S207.9 76 256 76m0-28C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48z"},child:[]}]})(t)}function zO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M368.5 240H272v-96.5c0-8.8-7.2-16-16-16s-16 7.2-16 16V240h-96.5c-8.8 0-16 7.2-16 16 0 4.4 1.8 8.4 4.7 11.3 2.9 2.9 6.9 4.7 11.3 4.7H240v96.5c0 4.4 1.8 8.4 4.7 11.3 2.9 2.9 6.9 4.7 11.3 4.7 8.8 0 16-7.2 16-16V272h96.5c8.8 0 16-7.2 16-16s-7.2-16-16-16z"},child:[]}]})(t)}function LO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 48C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48zm17.2 109.6l-3.1 115.1c-.2 8.2-5.9 14.8-14.1 14.8s-13.9-6.6-14.1-14.8l-3.1-115.1c-.2-9.6 7.5-17.6 17.2-17.6 9.6 0 17.4 7.9 17.2 17.6zM256 354c-10.7 0-19.1-8.1-19.1-18.4s8.4-18.4 19.1-18.4c10.7 0 19.1 8.1 19.1 18.4S266.7 354 256 354z"},child:[]}]})(t)}function HO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 294.1L383 167c9.4-9.4 24.6-9.4 33.9 0s9.3 24.6 0 34L273 345c-9.1 9.1-23.7 9.3-33.1.7L95 201.1c-4.7-4.7-7-10.9-7-17s2.3-12.3 7-17c9.4-9.4 24.6-9.4 33.9 0l127.1 127z"},child:[]}]})(t)}function UO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 48C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48zm106.5 150.5L228.8 332.8h-.1c-1.7 1.7-6.3 5.5-11.6 5.5-3.8 0-8.1-2.1-11.7-5.7l-56-56c-1.6-1.6-1.6-4.1 0-5.7l17.8-17.8c.8-.8 1.8-1.2 2.8-1.2 1 0 2 .4 2.8 1.2l44.4 44.4 122-122.9c.8-.8 1.8-1.2 2.8-1.2 1.1 0 2.1.4 2.8 1.2l17.5 18.1c1.8 1.7 1.8 4.2.2 5.8z"},child:[]}]})(t)}function $O(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M362.6 192.9L345 174.8c-.7-.8-1.8-1.2-2.8-1.2-1.1 0-2.1.4-2.8 1.2l-122 122.9-44.4-44.4c-.8-.8-1.8-1.2-2.8-1.2-1 0-2 .4-2.8 1.2l-17.8 17.8c-1.6 1.6-1.6 4.1 0 5.7l56 56c3.6 3.6 8 5.7 11.7 5.7 5.3 0 9.9-3.9 11.6-5.5h.1l133.7-134.4c1.4-1.7 1.4-4.2-.1-5.7z"},child:[]}]})(t)}function Xm(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M278.6 256l68.2-68.2c6.2-6.2 6.2-16.4 0-22.6-6.2-6.2-16.4-6.2-22.6 0L256 233.4l-68.2-68.2c-6.2-6.2-16.4-6.2-22.6 0-3.1 3.1-4.7 7.2-4.7 11.3 0 4.1 1.6 8.2 4.7 11.3l68.2 68.2-68.2 68.2c-3.1 3.1-4.7 7.2-4.7 11.3 0 4.1 1.6 8.2 4.7 11.3 6.2 6.2 16.4 6.2 22.6 0l68.2-68.2 68.2 68.2c6.2 6.2 16.4 6.2 22.6 0 6.2-6.2 6.2-16.4 0-22.6L278.6 256z"},child:[]}]})(t)}function BO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M88.3 68.1c-5.6-5.5-14.6-5.5-20.1.1-5.5 5.5-5.5 14.5 0 20l355.5 355.7c3.7 3.7 9 4.9 13.7 3.6 2.4-.6 4.6-1.9 6.4-3.7 5.5-5.5 5.5-14.5 0-20L88.3 68.1zM260.2 345.9c-53 2.4-96.6-41.2-94.1-94.1.6-12.2 3.6-23.8 8.6-34.3L121.3 164c-27.7 21.4-55.4 48.9-85.1 81.3-5.5 6.1-5.6 15.2-.1 21.3C101 338.3 158.2 400 255.8 400c29.7 0 57.1-7.4 82.3-19.2l-43.5-43.5c-10.6 5-22.2 8-34.4 8.6zM475.8 266c5.3-5.8 5.6-14.6.5-20.7C424 181.8 351.5 112 255.8 112c-29.1 0-56 6.6-82 19l43.7 43.7c10.5-5 22.1-8.1 34.3-8.6 53-2.4 96.6 41.2 94.1 94.1-.6 12.2-3.6 23.8-8.6 34.3l53.5 53.5c33-25.3 61.3-55.9 85-82z"},child:[]},{tag:"path",attr:{d:"M192.2 260.9c2.4 31.3 27.6 56.5 58.9 58.9 8.2.6 16.1-.3 23.4-2.6l-79.8-79.8c-2.2 7.4-3.1 15.3-2.5 23.5zM320 256c0-1.3-.1-2.6-.1-3.9-5.6 2.5-11.7 3.9-18.2 3.9-1.1 0-2.1 0-3.1-.1l18.6 18.7c1.8-5.9 2.8-12.2 2.8-18.6zM256 209c0-6 1.1-11.7 3.1-16.9-1 0-2-.1-3.1-.1-6.4 0-12.6 1-18.5 2.8l18.7 18.7c-.1-1.5-.2-3-.2-4.5z"},child:[]}]})(t)}function PO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M255.8 112c-80.4 0-143.8 50.6-219.6 133.3-5.5 6.1-5.6 15.2-.1 21.3C101 338.3 158.2 400 255.8 400c96.4 0 168.7-77.7 220.1-134 5.3-5.8 5.6-14.6.5-20.7C424 181.8 351.5 112 255.8 112zm4.4 233.9c-53 2.4-96.6-41.2-94.1-94.1 2.1-46.2 39.5-83.6 85.7-85.7 53-2.4 96.6 41.2 94.1 94.1-2.1 46.2-39.5 83.6-85.7 85.7z"},child:[]},{tag:"path",attr:{d:"M256 209c0-6 1.1-11.7 3.1-16.9-1 0-2-.1-3.1-.1-36.9 0-66.6 31.4-63.8 68.9 2.4 31.3 27.6 56.5 58.9 58.9 37.5 2.8 68.9-26.9 68.9-63.8 0-1.3-.1-2.6-.1-3.9-5.6 2.5-11.7 3.9-18.2 3.9-25.2 0-45.7-21.1-45.7-47z"},child:[]}]})(t)}function Fg(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M256 48C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48zm19 304h-38.2V207.9H275V352zm-19.1-159.8c-11.3 0-20.5-8.6-20.5-20s9.3-19.9 20.5-19.9c11.4 0 20.7 8.5 20.7 19.9s-9.3 20-20.7 20z"},child:[]}]})(t)}function qO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M368.5 240h-225c-8.8 0-16 7.2-16 16 0 4.4 1.8 8.4 4.7 11.3 2.9 2.9 6.9 4.7 11.3 4.7h225c8.8 0 16-7.2 16-16s-7.2-16-16-16z"},child:[]}]})(t)}function kO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M443.5 420.2L336.7 312.4c20.9-26.2 33.5-59.4 33.5-95.5 0-84.5-68.5-153-153.1-153S64 132.5 64 217s68.5 153 153.1 153c36.6 0 70.1-12.8 96.5-34.2l106.1 107.1c3.2 3.4 7.6 5.1 11.9 5.1 4.1 0 8.2-1.5 11.3-4.5 6.6-6.3 6.8-16.7.6-23.3zm-226.4-83.1c-32.1 0-62.3-12.5-85-35.2-22.7-22.7-35.2-52.9-35.2-84.9 0-32.1 12.5-62.3 35.2-84.9 22.7-22.7 52.9-35.2 85-35.2s62.3 12.5 85 35.2c22.7 22.7 35.2 52.9 35.2 84.9 0 32.1-12.5 62.3-35.2 84.9-22.7 22.7-52.9 35.2-85 35.2z"},child:[]}]})(t)}function FO(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M228.9 79.9L51.8 403.1C40.6 423.3 55.5 448 78.9 448h354.3c23.3 0 38.2-24.7 27.1-44.9L283.1 79.9c-11.7-21.2-42.5-21.2-54.2 0zM273.6 214L270 336h-28l-3.6-122h35.2zM256 402.4c-10.7 0-19.1-8.1-19.1-18.4s8.4-18.4 19.1-18.4 19.1 8.1 19.1 18.4-8.4 18.4-19.1 18.4z"},child:[]}]})(t)}var zh={exports:{}};/*!
19
- Copyright (c) 2018 Jed Watson.
20
- Licensed under the MIT License (MIT), see
21
- http://jedwatson.github.io/classnames
22
- */var Vg;function VO(){return Vg||(Vg=1,function(t){(function(){var r={}.hasOwnProperty;function a(){for(var s="",f=0;f<arguments.length;f++){var d=arguments[f];d&&(s=o(s,i(d)))}return s}function i(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return a.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var f="";for(var d in s)r.call(s,d)&&s[d]&&(f=o(f,d));return f}function o(s,f){return f?s?s+" "+f:s+f:s}t.exports?(a.default=a,t.exports=a):window.classNames=a})()}(zh)),zh.exports}var YO=VO();const $e=Kc(YO);function QO(t){throw new Error(`The prop "${t}" is required`)}const F1=t=>GO(t,"-");function V1(t,r=[],a={}){for(const i of Object.keys(t)){const o=t[i],s=r.concat([F1(i)]);typeof o=="object"&&o!=null?V1(o,s,a):a[s.join("-")]=o}return a}function Y1(t,r,a=[]){return new Proxy(t,{get(i,o,s){const f=a.concat(o.toString()),d=Reflect.get(i,o,s);return d&&typeof d=="object"&&!Array.isArray(d)?Y1(d,r,f):r(f,d)}})}function Q1(t){return Y1(t,r=>`var(--${r.map(F1).join("-")})`)}function KO(t,r){if(t!=null)if(typeof t=="function")t(r);else try{t.current=r}catch{throw new Error(`Cannot assign value "${r}" to ref "${t}"`)}}function K1(...t){return E.useMemo(()=>t.every(r=>r==null)?null:r=>{t.forEach(a=>{KO(a,r)})},[...t])}function Zm(t,r){const a=E.createContext(r);return a.displayName=t,a}function GO(t,r){return t.replace(/([a-z\d])([A-Z])/g,`$1${r}$2`).replace(/([A-Z]+)([A-Z][a-z\d]+)/g,`$1${r}$2`).toLowerCase()}function om(t){return t==null?[]:Array.isArray(t)?t:[t]}var uo={alert:"BZ7qn",title:"hdHDi",closeButton:"SgstT",content:"Q9Sh5",error:"VGIpm",success:"DlYCJ",info:"rHcuC",warning:"OC-ol",none:"xqeOj"};const XO={success:UO,error:LO,warning:FO,info:Fg,none:Fg};function Im({intent:t="none",title:r,onClose:a,children:i,...o}){const s=XO[t];return D.jsxs("div",{...o,className:$e(uo.alert,o.className,uo[t]),children:[a&&D.jsx("button",{type:"button",onClick:a,className:uo.closeButton,"aria-label":"Close",children:D.jsx(Xm,{})}),D.jsxs("div",{className:uo.title,children:[D.jsx(s,{}),r]}),typeof i<"u"&&D.jsx("div",{className:uo.content,children:i})]})}function ZO(){var t;return typeof window<"u"&&!!((t=window.document)!=null&&t.createElement)}const wo=ZO(),G1=wo?E.useLayoutEffect:E.useEffect;var Lh={badge:"xeHAL","badge-danger":"cgE-K","badge-warning":"_0U-VJ","badge-success":"ZgKwX","badge-pill":"OBQRM",notificationBadge:"LzQDv"};const Yg=({as:t="span",intent:r="none",pill:a=!1,className:i,ref:o,...s})=>D.jsx(t,{ref:o,...s,className:$e(Lh.badge,Lh[`badge-${r}`],a&&Lh["badge-pill"],i)});var oc={root:"mtrF8",contained:"W8YVd","intent-danger":"_3UX8S","intent-none":"-HhPB",text:"_2LiTf",outlined:"_9x9uq","size-s":"_5jbkc","size-m":"tf6zw","size-l":"_7vljf"};const IO=t=>{let r=wo?t.map(a=>window.matchMedia(a).matches):t.map(()=>!0);return{subscribe(a){if(!wo)return()=>{};const i=t.map(s=>window.matchMedia(s));r=i.map(s=>s.matches);const o=()=>{r=t.map(s=>window.matchMedia(s).matches),a()};for(const s of i)s.addEventListener("change",o);return()=>{for(const s of i)s.removeEventListener("change",o)}},getSnapshot(){return r},getServerSnapshot(){return r}}};function X1(t){const r=om(t),a=r.join("/"),i=E.useMemo(()=>IO(r),[a]),[o,s]=E.useState(()=>i.getSnapshot());return E.useEffect(()=>{i.subscribe(()=>s(i.getSnapshot()))},[i,s]),Array.isArray(t)?o:o[0]}function JO(t,r){const a=()=>{if(!wo)return r;try{return JSON.parse(window.localStorage.getItem(t)||"null")??r}catch{return r}},[i,o]=E.useState(a);return E.useEffect(()=>{if(wo)try{i!==void 0?window.localStorage.setItem(t,JSON.stringify(i)):window.localStorage.removeItem(t)}catch{}},[t,i]),E.useEffect(()=>{const s=f=>{if(!(f.key!==t||f.storageArea!==window.localStorage))try{f.newValue!=null&&o(JSON.parse(f.newValue))}catch{}};return window.addEventListener("storage",s),()=>{window.removeEventListener("storage",s)}},[t]),[i,o]}const Hh=t=>`screen and (min-width: ${t})`,WO=[Hh("0px"),Hh("600px"),Hh("1200px")];function eC(t){return JSON.parse(JSON.stringify(t),(r,a)=>{if(typeof a=="string"&&a.startsWith("#")){const[i,o,s,f]=oC(a);return`hsla(${i}, ${o*.9}%, ${100-s}%, ${f})`}return a})}function Z1(t){return tC(t)}function tC(t){const{id:r=`theme-${new Date().getTime()*Math.random()}`,...a}=t,{primary:i="#0074d9",secondary:o="#a2c14e",danger:s="#d2322d",...f}=a.colors||{},d="#fff",h={"05":"#f9fafb",10:"#f3f4f6",20:"#e5e7eb",30:"#d1d5db",40:"#9ca3af",50:"#6b7280",60:"#4b5563",70:"#374151",80:"#1f2937",90:"#111827",95:"#030712"},v={"05":"#fef2f2",10:"#fee2e2",20:"#fecaca",30:"#fca5a5",40:"#f87171",50:"#ef4444",60:"#dc2626",70:"#b91c1c",80:"#991b1b",90:"#7f1d1d",95:"#450a0a"};return{id:r,tokens:{...a,spacing:{auto:"auto",none:"0px",xxs:"2px",xs:"4px",s:"8px",m:"16px",l:"24px",xl:"32px",xxl:"64px",...a.spacing},fonts:{base:"Inter",...a.fonts},colors:{gray:h,red:v,linkText:"#000000",primaryText:"#1f2937",primary:i,secondary:o,primaryLight:fr(i,20),primaryDark:fr(i,-20),secondaryLight:fr(o,20),secondaryDark:fr(o,-20),danger:s,dangerLight:fr(s,20),dangerDark:fr(s,-20),warning:"#fbbf24",warningTint:fr("#fff3cd",-10),warningLight:"#fff3cd",success:"#047857",successTint:fr("#d4edda",-10),successLight:"#d4edda",info:"#0c5460",infoTint:fr("#d1ecf1",-10),infoLight:"#d1ecf1",white:d,formsBorder:h[30],formsBorderHover:h[40],formsBorderFocus:"transparent",formsBorderDisabled:"#ccc",formsBorderError:v[60],formsBorderWidth:"1px",formsBorderRadius:"4px",formsPadding:"8px",formsBackground:h["05"],formsBackgroundHover:d,formsBackgroundFocus:d,formsBackgroundDisabled:h[10],formsBackgroundError:v["05"],formsText:h[60],formsTextDisabled:h[50],formsTextError:h[60],formsTextPlaceholder:h[40],formsError:v[60],formsShadow:"0 1px 3px 0 rgba(0, 0, 0, 0.05), 0 1px 2px -1px rgba(0, 0, 0, 0.06)",selection:{background:fr(i,10),text:"#fff"},...f},shadows:{elevation0:"none",elevation1:"0 1px 2px rgba(0, 0, 0, 0.1), 0 1px 4px rgba(0, 0, 0, 0.1)",elevation2:"0px 3px 1px -2px rgba(0,0,0,0.2),0px 2px 2px 0px rgba(0,0,0,0.14),0px 1px 5px 0px rgba(0,0,0,0.12)",...a.shadows},borderRadius:{s:"4px",...a.borderRadius},focusRing:{width:"2px",color:"rgba(64, 122, 230, 0.6)",...a.focusRing},zIndex:Array.from({length:10}).map((y,S)=>S*100),cursor:{pointer:"pointer",...a.cursor}},breakpoints:WO}}const sm=Z1({id:"dmk-default",colors:{primary:"#0074d9",secondary:"#a2c14e"}}),I1=E.createContext({theme:sm,setTheme:()=>{},darkMode:!1,setDarkMode:()=>!1,tokens:Q1(sm.tokens)});function nC({theme:t=sm,children:r,injectCssCustomProperties:a=!0,allowDarkMode:i=!1,respectDefaultDarkMode:o=!1,themeColor:s="var(--theme-color)"}){const[f,d]=E.useState(t);E.useEffect(()=>{d(t)},[t]);const h=E.useMemo(()=>eC(f),[f]),v=X1("(prefers-color-scheme: dark)"),[y,S]=JO("dmk-dark-mode",o?v:!1),p=y&&i?h:f;E.useEffect(()=>{const w=document.createElement("div");w.style.background=s,document.body.appendChild(w);const x=window.getComputedStyle(w).backgroundColor;document.body.removeChild(w);let R=document.querySelector('meta[name="theme-color"]');R==null&&(R=document.createElement("meta"),R.setAttribute("name","theme-color"),document.head.appendChild(R)),R.setAttribute("content",x)},[y,s]),E.useInsertionEffect(()=>{a&&iC(V1(p.tokens)),document.body.setAttribute("data-mode",y?"dark":"light")},[p,a,y]);const g=E.useMemo(()=>({theme:p,tokens:Q1(p.tokens),setTheme:d,darkMode:y,setDarkMode:S}),[p,y,S]);return D.jsx(I1,{value:g,children:D.jsx(aC,{breakpoints:t.breakpoints,children:r})})}function rC(){return E.use(I1)}function J1(){return E.use(eS)}function W1(){const{tokens:t}=rC();return t}const eS=Zm("BreakpointsContext",[!1,!1,!0]);function aC({breakpoints:t,children:r}){const a=X1(t);return D.jsx(eS,{value:a,children:r})}function iC(t){for(const r of Object.keys(t))document.documentElement.style.setProperty(`--${r}`,t[r])}function fr(t,r){return`#${t.replace(/^#/,"").replace(/../g,a=>`0${Math.min(255,Math.max(0,parseInt(a,16)+r)).toString(16)}`.slice(-2))}`}function lC(t){t.startsWith("#")&&(t=t.slice(1));let[r,a,i,o]=[0,0,0,1];if(t.length===3)r=parseInt(`${t[0]}${t[0]}`,16),a=parseInt(`${t[1]}${t[1]}`,16),i=parseInt(`${t[2]}${t[2]}`,16),o=1;else if(t.length===4)r=parseInt(`${t[0]}${t[0]}`,16),a=parseInt(`${t[1]}${t[1]}`,16),i=parseInt(`${t[2]}${t[2]}`,16),o=parseInt(`${t[3]}${t[3]}`,16),o=+(o/255).toFixed(3);else if(t.length===6)r=parseInt(`${t[0]}${t[1]}`,16),a=parseInt(`${t[2]}${t[3]}`,16),i=parseInt(`${t[4]}${t[5]}`,16),o=1;else if(t.length===8)r=parseInt(`${t[0]}${t[1]}`,16),a=parseInt(`${t[2]}${t[3]}`,16),i=parseInt(`${t[4]}${t[5]}`,16),o=parseInt(`${t[6]}${t[7]}`,16),o=+(o/255).toFixed(3);else throw new Error(`Invalid hex: ${t}`);return[r,a,i,o]}function uC(t,r,a,i){t/=255,r/=255,a/=255;const o=Math.min(t,r,a),s=Math.max(t,r,a),f=s-o;let[d,h,v]=[0,0,0];return f===0?d=0:s===t?d=(r-a)/f%6:s===r?d=(a-t)/f+2:d=(t-r)/f+4,d=Math.round(d*60),d<0&&(d+=360),v=(s+o)/2,h=f===0?0:f/(1-Math.abs(2*v-1)),h=+(h*100).toFixed(1),v=+(v*100).toFixed(1),[d,h,v,i]}function oC(t){return uC(...lC(t))}const ci=({as:t="button",variant:r="contained",intent:a="none",className:i,color:o,style:s,size:f,...d})=>{const h=tS({variant:r,intent:a,color:o,className:i,style:s,size:f});return D.jsx(t,{type:t==="button"?"button":void 0,onTouchStart:()=>{},...d,...h})};function tS({variant:t="contained",intent:r="none",color:a,style:i,size:o="m",className:s}={}){return{style:{...a&&{"--Button-color":a,"--Button-hoverColor":fr(a,20)},...i},className:$e(oc.root,oc[t],oc[`intent-${r}`],oc[`size-${o}`],s)}}var Uh={root:"nwF8S",checkbox:"_076Ml",hiddenCheckbox:"vULBC"},sc={vstack:"f-weF","stack--spacing-none":"_4n4EX",hstack:"O-Obi","stack--spacing-xxs":"FpVz1","stack--spacing-xs":"yXJ18","stack--spacing-s":"fvPFs","stack--spacing-m":"_9zB8n","stack--spacing-l":"Fh5sy","stack--spacing-xl":"_1cgrL","stack--spacing-xxl":"nfwQY",wrap:"NcK99"};function Jm(t){const r=J1();return Array.isArray(t)?nS(r,t):t}function bo(t){const r=J1();return t.map(a=>Array.isArray(a)?nS(r,a):a)}function nS(t,r){for(let a=t.length-1;a>=0;a-=1)if(t[a])return r[a];throw new Error("Invalid breakpoint config. At least one of them should have min-width: 0px")}function sC({height:t="m",horizontal:r=!1}){const[a,i]=bo([t,r]),o=W1();return D.jsx("div",{style:{flexGrow:0,flexShrink:0,[i?"width":"height"]:typeof a=="number"?a:o.spacing[a].valueOf()}})}function cC(t){const r=W1(),{alignItems:a,alignSelf:i,justifyContent:o,paddingLeft:s,paddingRight:f,paddingTop:d,paddingBottom:h,paddingX:v,paddingY:y,padding:S,marginLeft:p,marginRight:g,marginTop:w,marginBottom:x,marginX:R,marginY:T,margin:A,...N}=t,[j,O,q]=bo([o,a,i]),[B,V,z,X,te,fe,Z]=bo([s,f,d,h,v,y,S]).map(se=>typeof se=="number"||se==null?se:r.spacing[se]),[ae,ie,U,I,ne,K,M]=bo([p,g,w,x,R,T,A]).map(se=>typeof se=="number"||se==null?se:r.spacing[se]),F={};return te!=null&&(F.paddingLeft=te.valueOf(),F.paddingRight=te.valueOf()),fe!=null&&(F.paddingTop=fe.valueOf(),F.paddingBottom=fe.valueOf()),B!=null&&(F.paddingLeft=B.valueOf()),V!=null&&(F.paddingRight=V.valueOf()),z!=null&&(F.paddingTop=z.valueOf()),X!=null&&(F.paddingBottom=X.valueOf()),Z!=null&&(F.padding=Z.valueOf()),ne!=null&&(F.marginLeft=ne.valueOf(),F.marginRight=ne.valueOf()),K!=null&&(F.marginTop=U==null?void 0:U.valueOf(),F.marginBottom=I==null?void 0:I.valueOf()),ae!=null&&(F.marginLeft=ae.valueOf()),ie!=null&&(F.marginRight=ie.valueOf()),U!=null&&(F.marginTop=U.valueOf()),I!=null&&(F.marginBottom=I.valueOf()),M!=null&&(F.margin=M.valueOf()),j!=null&&(F.justifyContent=j),O!=null&&(F.alignItems=O),q!=null&&(F.alignSelf=q),[F,N]}const Ur=function({as:t="div",spacing:r="m",justifyContent:a="flex-start",alignItems:i="stretch",horizontal:o=!1,wrap:s=!1,...f}){const[d,h,v]=bo([o,r,s]),[y,S]=cC({alignItems:i,justifyContent:a,...f});return D.jsx(t,{...S,className:$e(d?sc.hstack:sc.vstack,v&&sc.wrap,f.className,typeof h!="number"&&sc[`stack--spacing-${h}`]),style:{...y,...f.style}})},fC=Zm("CheckboxGroupContext",null);function rS({children:t,error:r,style:a,className:i,indeterminate:o,...s}){const f=dC(s);return D.jsxs("label",{"aria-disabled":f.disabled,"data-error":r,className:$e(Uh.root,i),style:a,children:[D.jsx("input",{type:"checkbox",...s,className:$e("dmk-visually-hidden",Uh.hiddenCheckbox),"aria-checked":f.checked,"aria-invalid":r?"true":"false","data-indeterminate":o,...f}),D.jsx("span",{className:Uh.checkbox}),D.jsx("span",{children:t})]})}function dC(t){const r=E.use(fC);return r==null?t:{value:t.value,name:r.name,checked:r.isChecked(t.value),disabled:r.disabled,onChange:r.onChange}}var Ll={root:"QAwiK",static:"xse-M",circle:"bWHVH",indeterminate:"uxHDU","circular-rotate":"fvokD",circleStatic:"aGrAV",circleIndeterminate:"vIA5t","circular-dash":"pIgMi"};function hC({size:t=52,thickness:r=2,value:a,color:i="var(--CircularProgress-color)",...o}){const s={},f={},d={};if(typeof a=="number"){const h=2*Math.PI*((t-r)/2);s.strokeDasharray=h.toFixed(3),d["aria-valuenow"]=Math.round(a),s.strokeDashoffset=`${((100-a)/100*h).toFixed(3)}px`,f.transform="rotate(-90deg)"}return D.jsx("div",{className:$e(Ll.root,{[Ll.indeterminate]:a==null,[Ll.static]:typeof a=="number"}),style:{color:i,width:t,height:t,...f},role:"progressbar",...d,...o,children:D.jsx("svg",{viewBox:`${t/2} ${t/2} ${t} ${t}`,children:D.jsx("circle",{className:$e(Ll.circle,{[Ll.circleIndeterminate]:a==null,[Ll.circleStatic]:typeof a=="number"}),style:s,cx:t,cy:t,r:(t-r)/2,fill:"none",strokeWidth:r})})})}var mC=Object.defineProperty,vC=Object.defineProperties,pC=Object.getOwnPropertyDescriptors,_c=Object.getOwnPropertySymbols,aS=Object.prototype.hasOwnProperty,iS=Object.prototype.propertyIsEnumerable,Qg=(t,r,a)=>r in t?mC(t,r,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[r]=a,oe=(t,r)=>{for(var a in r||(r={}))aS.call(r,a)&&Qg(t,a,r[a]);if(_c)for(var a of _c(r))iS.call(r,a)&&Qg(t,a,r[a]);return t},we=(t,r)=>vC(t,pC(r)),Ge=(t,r)=>{var a={};for(var i in t)aS.call(t,i)&&r.indexOf(i)<0&&(a[i]=t[i]);if(t!=null&&_c)for(var i of _c(t))r.indexOf(i)<0&&iS.call(t,i)&&(a[i]=t[i]);return a},yC=Object.defineProperty,gC=Object.defineProperties,bC=Object.getOwnPropertyDescriptors,Nc=Object.getOwnPropertySymbols,lS=Object.prototype.hasOwnProperty,uS=Object.prototype.propertyIsEnumerable,Kg=(t,r,a)=>r in t?yC(t,r,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[r]=a,lt=(t,r)=>{for(var a in r||(r={}))lS.call(r,a)&&Kg(t,a,r[a]);if(Nc)for(var a of Nc(r))uS.call(r,a)&&Kg(t,a,r[a]);return t},Yt=(t,r)=>gC(t,bC(r)),oS=(t,r)=>{var a={};for(var i in t)lS.call(t,i)&&r.indexOf(i)<0&&(a[i]=t[i]);if(t!=null&&Nc)for(var i of Nc(t))r.indexOf(i)<0&&uS.call(t,i)&&(a[i]=t[i]);return a};function Sc(...t){}function sS(t,r){if(SC(t)){const a=xC(r)?r():r;return t(a)}return t}function SC(t){return typeof t=="function"}function xC(t){return typeof t=="function"}function va(t,r){return typeof Object.hasOwn=="function"?Object.hasOwn(t,r):Object.prototype.hasOwnProperty.call(t,r)}function Bn(...t){return(...r)=>{for(const a of t)typeof a=="function"&&a(...r)}}function EC(t){return t.normalize("NFD").replace(/[\u0300-\u036f]/g,"")}function wC(t,r){const a=lt({},t);for(const i of r)va(a,i)&&delete a[i];return a}function OC(t,r){const a={};for(const i of r)va(t,i)&&(a[i]=t[i]);return a}function cS(t){return t}function Wt(t,r){if(!t)throw typeof r!="string"?new Error("Invariant failed"):new Error(r)}function CC(t){return Object.keys(t)}function fS(t,...r){const a=typeof t=="function"?t(...r):t;return a==null?!1:!a}function No(t){return t.disabled||t["aria-disabled"]===!0||t["aria-disabled"]==="true"}function iu(t){const r={};for(const a in t)t[a]!==void 0&&(r[a]=t[a]);return r}function et(...t){for(const r of t)if(r!==void 0)return r}function cm(t,r){typeof t=="function"?t(r):t&&(t.current=r)}function TC(t){return!t||!E.isValidElement(t)?!1:"ref"in t.props||"ref"in t}function RC(t){return TC(t)?oe({},t.props).ref||t.ref:null}function DC(t,r){const a=oe({},t);for(const i in r){if(!va(r,i))continue;if(i==="className"){const s="className";a[s]=t[s]?`${t[s]} ${r[s]}`:r[s];continue}if(i==="style"){const s="style";a[s]=t[s]?oe(oe({},t[s]),r[s]):r[s];continue}const o=r[i];if(typeof o=="function"&&i.startsWith("on")){const s=t[i];if(typeof s=="function"){a[i]=(...f)=>{o(...f),s(...f)};continue}}a[i]=o}return a}var lu=AC();function AC(){var t;return typeof window<"u"&&!!((t=window.document)!=null&&t.createElement)}function yt(t){return t?"self"in t?t.document:t.ownerDocument||document:document}function dS(t){return t?"self"in t?t.self:yt(t).defaultView||window:self}function ba(t,r=!1){const{activeElement:a}=yt(t);if(!(a!=null&&a.nodeName))return null;if(Wm(a)&&a.contentDocument)return ba(a.contentDocument.body,r);if(r){const i=a.getAttribute("aria-activedescendant");if(i){const o=yt(a).getElementById(i);if(o)return o}}return a}function Lt(t,r){return t===r||t.contains(r)}function Wm(t){return t.tagName==="IFRAME"}function fi(t){const r=t.tagName.toLowerCase();return r==="button"?!0:r==="input"&&t.type?MC.indexOf(t.type)!==-1:!1}var MC=["button","color","file","image","reset","submit"];function hS(t){if(typeof t.checkVisibility=="function")return t.checkVisibility();const r=t;return r.offsetWidth>0||r.offsetHeight>0||t.getClientRects().length>0}function Sa(t){try{const r=t instanceof HTMLInputElement&&t.selectionStart!==null,a=t.tagName==="TEXTAREA";return r||a||!1}catch{return!1}}function fm(t){return t.isContentEditable||Sa(t)}function jC(t){if(Sa(t))return t.value;if(t.isContentEditable){const r=yt(t).createRange();return r.selectNodeContents(t),r.toString()}return""}function _C(t){let r=0,a=0;if(Sa(t))r=t.selectionStart||0,a=t.selectionEnd||0;else if(t.isContentEditable){const i=yt(t).getSelection();if(i!=null&&i.rangeCount&&i.anchorNode&&Lt(t,i.anchorNode)&&i.focusNode&&Lt(t,i.focusNode)){const o=i.getRangeAt(0),s=o.cloneRange();s.selectNodeContents(t),s.setEnd(o.startContainer,o.startOffset),r=s.toString().length,s.setEnd(o.endContainer,o.endOffset),a=s.toString().length}}return{start:r,end:a}}function ev(t,r){const a=["dialog","menu","listbox","tree","grid"],i=t==null?void 0:t.getAttribute("role");return i&&a.indexOf(i)!==-1?i:r}function mS(t,r){var a;const i={menu:"menuitem",listbox:"option",tree:"treeitem"},o=ev(t);return o&&(a=i[o])!=null?a:r}function vS(t){if(!t)return null;const r=a=>a==="auto"||a==="scroll";if(t.clientHeight&&t.scrollHeight>t.clientHeight){const{overflowY:a}=getComputedStyle(t);if(r(a))return t}else if(t.clientWidth&&t.scrollWidth>t.clientWidth){const{overflowX:a}=getComputedStyle(t);if(r(a))return t}return vS(t.parentElement)||document.scrollingElement||document.body}function pS(t,r){const a=t.map((o,s)=>[s,o]);let i=!1;return a.sort(([o,s],[f,d])=>{const h=r(s),v=r(d);return h===v||!h||!v?0:NC(h,v)?(o>f&&(i=!0),-1):(o<f&&(i=!0),1)}),i?a.map(([o,s])=>s):t}function NC(t,r){return!!(r.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_PRECEDING)}function zC(){return lu&&!!navigator.maxTouchPoints}function tv(){return lu?/mac|iphone|ipad|ipod/i.test(navigator.platform):!1}function nv(){return lu&&tv()&&/apple/i.test(navigator.vendor)}function LC(){return lu&&/firefox\//i.test(navigator.userAgent)}function HC(){return lu&&navigator.platform.startsWith("Mac")&&!zC()}function yS(t){return!!(t.currentTarget&&!Lt(t.currentTarget,t.target))}function Hn(t){return t.target===t.currentTarget}function UC(t){const r=t.currentTarget;if(!r)return!1;const a=tv();if(a&&!t.metaKey||!a&&!t.ctrlKey)return!1;const i=r.tagName.toLowerCase();return i==="a"||i==="button"&&r.type==="submit"||i==="input"&&r.type==="submit"}function $C(t){const r=t.currentTarget;if(!r)return!1;const a=r.tagName.toLowerCase();return t.altKey?a==="a"||a==="button"&&r.type==="submit"||a==="input"&&r.type==="submit":!1}function BC(t,r,a){const i=new Event(r,a);return t.dispatchEvent(i)}function Hl(t,r){const a=new FocusEvent("blur",r),i=t.dispatchEvent(a),o=Yt(lt({},r),{bubbles:!0});return t.dispatchEvent(new FocusEvent("focusout",o)),i}function PC(t,r,a){const i=new KeyboardEvent(r,a);return t.dispatchEvent(i)}function Gg(t,r){const a=new MouseEvent("click",r);return t.dispatchEvent(a)}function $l(t,r){const a=r||t.currentTarget,i=t.relatedTarget;return!i||!Lt(a,i)}function So(t,r,a,i){const s=(d=>{const h=requestAnimationFrame(d);return()=>cancelAnimationFrame(h)})(()=>{t.removeEventListener(r,f,!0),a()}),f=()=>{s(),a()};return t.addEventListener(r,f,{once:!0,capture:!0}),s}function Zt(t,r,a,i=window){const o=[];try{i.document.addEventListener(t,r,a);for(const f of Array.from(i.frames))o.push(Zt(t,r,a,f))}catch{}return()=>{try{i.document.removeEventListener(t,r,a)}catch{}for(const f of o)f()}}var rv=oe({},_w),Xg=rv.useId;rv.useDeferredValue;var Zg=rv.useInsertionEffect,ct=lu?E.useLayoutEffect:E.useEffect;function gS(t){const r=E.useRef(t);return ct(()=>{r.current=t}),r}function Ye(t){const r=E.useRef(()=>{throw new Error("Cannot call an event handler while rendering.")});return Zg?Zg(()=>{r.current=t}):r.current=t,E.useCallback((...a)=>{var i;return(i=r.current)==null?void 0:i.call(r,...a)},[])}function qC(t){const[r,a]=E.useState(null);return ct(()=>{if(r==null||!t)return;let i=null;return t(o=>(i=o,r)),()=>{t(i)}},[r,t]),[r,a]}function Ht(...t){return E.useMemo(()=>{if(t.some(Boolean))return r=>{for(const a of t)cm(a,r)}},t)}function Ji(t){if(Xg){const i=Xg();return t||i}const[r,a]=E.useState(t);return ct(()=>{if(t||r)return;const i=Math.random().toString(36).slice(2,8);a(`id-${i}`)},[t,r]),t||r}function av(t,r){const a=s=>{if(typeof s=="string")return s},[i,o]=E.useState(()=>a(r));return ct(()=>{const s=t&&"current"in t?t.current:t;o((s==null?void 0:s.tagName.toLowerCase())||a(r))},[t,r]),i}function ef(t,r){const a=E.useRef(!1);E.useEffect(()=>{if(a.current)return t();a.current=!0},r),E.useEffect(()=>()=>{a.current=!1},[])}function kC(){return E.useReducer(()=>[],[])}function Un(t){return Ye(typeof t=="function"?t:()=>t)}function yn(t,r,a=[]){const i=E.useCallback(o=>(t.wrapElement&&(o=t.wrapElement(o)),r(o)),[...a,t.wrapElement]);return we(oe({},t),{wrapElement:i})}function iv(t=!1,r){const[a,i]=E.useState(null);return{portalRef:Ht(i,r),portalNode:a,domReady:!t||a}}function bS(t,r,a){const i=t.onLoadedMetadataCapture,o=E.useMemo(()=>Object.assign(()=>{},we(oe({},i),{[r]:a})),[i,r,a]);return[i==null?void 0:i[r],{onLoadedMetadataCapture:o}]}function lv(){return E.useEffect(()=>{Zt("mousemove",VC,!0),Zt("mousedown",cc,!0),Zt("mouseup",cc,!0),Zt("keydown",cc,!0),Zt("scroll",cc,!0)},[]),Ye(()=>uv)}var uv=!1,Ig=0,Jg=0;function FC(t){const r=t.movementX||t.screenX-Ig,a=t.movementY||t.screenY-Jg;return Ig=t.screenX,Jg=t.screenY,r||a||!1}function VC(t){FC(t)&&(uv=!0)}function cc(){uv=!1}function Xe(t){const r=E.forwardRef((a,i)=>t(we(oe({},a),{ref:i})));return r.displayName=t.displayName||t.name,r}function ov(t,r){return E.memo(t,r)}function Ie(t,r){const a=r,{wrapElement:i,render:o}=a,s=Ge(a,["wrapElement","render"]),f=Ht(r.ref,RC(o));let d;if(E.isValidElement(o)){const h=we(oe({},o.props),{ref:f});d=E.cloneElement(o,DC(s,h))}else o?d=o(s):d=D.jsx(t,oe({},s));return i?i(d):d}function tt(t){const r=(a={})=>t(a);return r.displayName=t.name,r}function xa(t=[],r=[]){const a=E.createContext(void 0),i=E.createContext(void 0),o=()=>E.useContext(a),s=(v=!1)=>{const y=E.useContext(i),S=o();return v?y:y||S},f=()=>{const v=E.useContext(i),y=o();if(!(v&&v===y))return y},d=v=>t.reduceRight((y,S)=>D.jsx(S,we(oe({},v),{children:y})),D.jsx(a.Provider,oe({},v)));return{context:a,scopedContext:i,useContext:o,useScopedContext:s,useProviderContext:f,ContextProvider:d,ScopedContextProvider:v=>D.jsx(d,we(oe({},v),{children:r.reduceRight((y,S)=>D.jsx(S,we(oe({},v),{children:y})),D.jsx(i.Provider,oe({},v)))}))}}var zo=xa(),YC=zo.useContext;zo.useScopedContext;zo.useProviderContext;var QC=zo.ContextProvider,KC=zo.ScopedContextProvider,Lo=xa([QC],[KC]),tf=Lo.useContext;Lo.useScopedContext;var GC=Lo.useProviderContext,nf=Lo.ContextProvider,sv=Lo.ScopedContextProvider,XC=E.createContext(void 0),ZC=E.createContext(void 0);function Wi(t,r){const a=t.__unstableInternals;return Wt(a,"Invalid store"),a[r]}function $r(t,...r){let a=t,i=a,o=Symbol(),s=Sc;const f=new Set,d=new Set,h=new Set,v=new Set,y=new Set,S=new WeakMap,p=new WeakMap,g=V=>(h.add(V),()=>h.delete(V)),w=()=>{const V=f.size,z=Symbol();f.add(z);const X=()=>{f.delete(z),!f.size&&s()};if(V)return X;const te=CC(a).map(ae=>Bn(...r.map(ie=>{var U;const I=(U=ie==null?void 0:ie.getState)==null?void 0:U.call(ie);if(I&&va(I,ae))return pa(ie,[ae],ne=>{q(ae,ne[ae],!0)})}))),fe=[];for(const ae of h)fe.push(ae());const Z=r.map(cv);return s=Bn(...te,...fe,...Z),X},x=(V,z,X=v)=>(X.add(z),p.set(z,V),()=>{var te;(te=S.get(z))==null||te(),S.delete(z),p.delete(z),X.delete(z)}),R=(V,z)=>x(V,z),T=(V,z)=>(S.set(z,z(a,a)),x(V,z)),A=(V,z)=>(S.set(z,z(a,i)),x(V,z,y)),N=V=>$r(OC(a,V),B),j=V=>$r(wC(a,V),B),O=()=>a,q=(V,z,X=!1)=>{var te;if(!va(a,V))return;const fe=sS(z,a[V]);if(fe===a[V])return;if(!X)for(const U of r)(te=U==null?void 0:U.setState)==null||te.call(U,V,fe);const Z=a;a=Yt(lt({},a),{[V]:fe});const ae=Symbol();o=ae,d.add(V);const ie=(U,I,ne)=>{var K;const M=p.get(U),F=se=>ne?ne.has(se):se===V;(!M||M.some(F))&&((K=S.get(U))==null||K(),S.set(U,U(a,I)))};for(const U of v)ie(U,Z);queueMicrotask(()=>{if(o!==ae)return;const U=a;for(const I of y)ie(I,i,d);i=U,d.clear()})},B={getState:O,setState:q,__unstableInternals:{setup:g,init:w,subscribe:R,sync:T,batch:A,pick:N,omit:j}};return B}function ha(t,...r){if(t)return Wi(t,"setup")(...r)}function cv(t,...r){if(t)return Wi(t,"init")(...r)}function fv(t,...r){if(t)return Wi(t,"subscribe")(...r)}function pa(t,...r){if(t)return Wi(t,"sync")(...r)}function dm(t,...r){if(t)return Wi(t,"batch")(...r)}function dv(t,...r){if(t)return Wi(t,"omit")(...r)}function IC(t,...r){if(t)return Wi(t,"pick")(...r)}function hv(...t){const r=t.reduce((i,o)=>{var s;const f=(s=o==null?void 0:o.getState)==null?void 0:s.call(o);return f?Object.assign(i,f):i},{}),a=$r(r,...t);return Object.assign({},...t,a)}var $h={exports:{}},Bh={};/**
23
- * @license React
24
- * use-sync-external-store-shim.production.js
25
- *
26
- * Copyright (c) Meta Platforms, Inc. and affiliates.
27
- *
28
- * This source code is licensed under the MIT license found in the
29
- * LICENSE file in the root directory of this source tree.
30
- */var Wg;function JC(){if(Wg)return Bh;Wg=1;var t=Gc();function r(S,p){return S===p&&(S!==0||1/S===1/p)||S!==S&&p!==p}var a=typeof Object.is=="function"?Object.is:r,i=t.useState,o=t.useEffect,s=t.useLayoutEffect,f=t.useDebugValue;function d(S,p){var g=p(),w=i({inst:{value:g,getSnapshot:p}}),x=w[0].inst,R=w[1];return s(function(){x.value=g,x.getSnapshot=p,h(x)&&R({inst:x})},[S,g,p]),o(function(){return h(x)&&R({inst:x}),S(function(){h(x)&&R({inst:x})})},[S]),f(g),g}function h(S){var p=S.getSnapshot;S=S.value;try{var g=p();return!a(S,g)}catch{return!0}}function v(S,p){return p()}var y=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?v:d;return Bh.useSyncExternalStore=t.useSyncExternalStore!==void 0?t.useSyncExternalStore:y,Bh}var eb;function WC(){return eb||(eb=1,$h.exports=JC()),$h.exports}var eT=WC();const tT=Kc(eT);var{useSyncExternalStore:SS}=tT,xS=()=>()=>{};function Pt(t,r=cS){const a=E.useCallback(o=>t?fv(t,null,o):xS(),[t]),i=()=>{const o=typeof r=="string"?r:null,s=typeof r=="function"?r:null,f=t==null?void 0:t.getState();if(s)return s(f);if(f&&o&&va(f,o))return f[o]};return SS(a,i,i)}function nT(t,r){const a=E.useRef({}),i=E.useCallback(s=>t?fv(t,null,s):xS(),[t]),o=()=>{const s=t==null?void 0:t.getState();let f=!1;const d=a.current;for(const h in r){const v=r[h];if(typeof v=="function"){const y=v(s);y!==d[h]&&(d[h]=y,f=!0)}if(typeof v=="string"){if(!s||!va(s,v))continue;const y=s[v];y!==d[h]&&(d[h]=y,f=!0)}}return f&&(a.current=oe({},d)),a.current};return SS(i,o,o)}function Xt(t,r,a,i){const o=va(r,a)?r[a]:void 0,s=i?r[i]:void 0,f=gS({value:o,setValue:s});ct(()=>pa(t,[a],(d,h)=>{const{value:v,setValue:y}=f.current;y&&d[a]!==h[a]&&d[a]!==v&&y(d[a])}),[t,a]),ct(()=>{if(o!==void 0)return t.setState(a,o),dm(t,[a],()=>{o!==void 0&&t.setState(a,o)})})}function mv(t,r){const[a,i]=E.useState(()=>t(r));ct(()=>cv(a),[a]);const o=E.useCallback(d=>Pt(a,d),[a]),s=E.useMemo(()=>we(oe({},a),{useState:o}),[a,o]),f=Ye(()=>{i(d=>t(oe(oe({},r),d.getState())))});return[s,f]}function rT(t){var r;const a=t.find(s=>!!s.element),i=[...t].reverse().find(s=>!!s.element);let o=(r=a==null?void 0:a.element)==null?void 0:r.parentElement;for(;o&&(i!=null&&i.element);){if(i&&o.contains(i.element))return o;o=o.parentElement}return yt(o).body}function aT(t){return t==null?void 0:t.__unstablePrivateStore}function iT(t={}){var r;t.store;const a=(r=t.store)==null?void 0:r.getState(),i=et(t.items,a==null?void 0:a.items,t.defaultItems,[]),o=new Map(i.map(p=>[p.id,p])),s={items:i,renderedItems:et(a==null?void 0:a.renderedItems,[])},f=aT(t.store),d=$r({items:i,renderedItems:s.renderedItems},f),h=$r(s,t.store),v=p=>{const g=pS(p,w=>w.element);d.setState("renderedItems",g),h.setState("renderedItems",g)};ha(h,()=>cv(d)),ha(d,()=>dm(d,["items"],p=>{h.setState("items",p.items)})),ha(d,()=>dm(d,["renderedItems"],p=>{let g=!0,w=requestAnimationFrame(()=>{const{renderedItems:A}=h.getState();p.renderedItems!==A&&v(p.renderedItems)});if(typeof IntersectionObserver!="function")return()=>cancelAnimationFrame(w);const x=()=>{if(g){g=!1;return}cancelAnimationFrame(w),w=requestAnimationFrame(()=>v(p.renderedItems))},R=rT(p.renderedItems),T=new IntersectionObserver(x,{root:R});for(const A of p.renderedItems)A.element&&T.observe(A.element);return()=>{cancelAnimationFrame(w),T.disconnect()}}));const y=(p,g,w=!1)=>{let x;return g(T=>{const A=T.findIndex(({id:j})=>j===p.id),N=T.slice();if(A!==-1){x=T[A];const j=lt(lt({},x),p);N[A]=j,o.set(p.id,j)}else N.push(p),o.set(p.id,p);return N}),()=>{g(T=>{if(!x)return w&&o.delete(p.id),T.filter(({id:j})=>j!==p.id);const A=T.findIndex(({id:j})=>j===p.id);if(A===-1)return T;const N=T.slice();return N[A]=x,o.set(p.id,x),N})}},S=p=>y(p,g=>d.setState("items",g),!0);return Yt(lt({},h),{registerItem:S,renderItem:p=>Bn(S(p),y(p,g=>d.setState("renderedItems",g))),item:p=>{if(!p)return null;let g=o.get(p);if(!g){const{items:w}=d.getState();g=w.find(x=>x.id===p),g&&o.set(p,g)}return g||null},__unstablePrivateStore:d})}function lT(t,r,a){return ef(r,[a.store]),Xt(t,a,"items","setItems"),t}function ES(t){const r=[];for(const a of t)r.push(...a);return r}function hm(t){return t.slice().reverse()}var uT={id:null};function sa(t,r){return t.find(a=>r?!a.disabled&&a.id!==r:!a.disabled)}function oT(t,r){return t.filter(a=>r?!a.disabled&&a.id!==r:!a.disabled)}function tb(t,r){return t.filter(a=>a.rowId===r)}function sT(t,r,a=!1){const i=t.findIndex(o=>o.id===r);return[...t.slice(i+1),...a?[uT]:[],...t.slice(0,i)]}function wS(t){const r=[];for(const a of t){const i=r.find(o=>{var s;return((s=o[0])==null?void 0:s.rowId)===a.rowId});i?i.push(a):r.push([a])}return r}function OS(t){let r=0;for(const{length:a}of t)a>r&&(r=a);return r}function cT(t){return{id:"__EMPTY_ITEM__",disabled:!0,rowId:t}}function fT(t,r,a){const i=OS(t);for(const o of t)for(let s=0;s<i;s+=1){const f=o[s];if(!f||a&&f.disabled){const h=s===0&&a?sa(o):o[s-1];o[s]=h&&r!==h.id&&a?h:cT(h==null?void 0:h.rowId)}}return t}function dT(t){const r=wS(t),a=OS(r),i=[];for(let o=0;o<a;o+=1)for(const s of r){const f=s[o];f&&i.push(Yt(lt({},f),{rowId:f.rowId?`${o}`:void 0}))}return i}function hT(t={}){var r;const a=(r=t.store)==null?void 0:r.getState(),i=iT(t),o=et(t.activeId,a==null?void 0:a.activeId,t.defaultActiveId),s=Yt(lt({},i.getState()),{id:et(t.id,a==null?void 0:a.id,`id-${Math.random().toString(36).slice(2,8)}`),activeId:o,baseElement:et(a==null?void 0:a.baseElement,null),includesBaseElement:et(t.includesBaseElement,a==null?void 0:a.includesBaseElement,o===null),moves:et(a==null?void 0:a.moves,0),orientation:et(t.orientation,a==null?void 0:a.orientation,"both"),rtl:et(t.rtl,a==null?void 0:a.rtl,!1),virtualFocus:et(t.virtualFocus,a==null?void 0:a.virtualFocus,!1),focusLoop:et(t.focusLoop,a==null?void 0:a.focusLoop,!1),focusWrap:et(t.focusWrap,a==null?void 0:a.focusWrap,!1),focusShift:et(t.focusShift,a==null?void 0:a.focusShift,!1)}),f=$r(s,i,t.store);ha(f,()=>pa(f,["renderedItems","activeId"],h=>{f.setState("activeId",v=>{var y;return v!==void 0?v:(y=sa(h.renderedItems))==null?void 0:y.id})}));const d=(h="next",v={})=>{var y,S;const p=f.getState(),{skip:g=0,activeId:w=p.activeId,focusShift:x=p.focusShift,focusLoop:R=p.focusLoop,focusWrap:T=p.focusWrap,includesBaseElement:A=p.includesBaseElement,renderedItems:N=p.renderedItems,rtl:j=p.rtl}=v,O=h==="up"||h==="down",q=h==="next"||h==="down",B=q?j&&!O:!j||O,V=x&&!g;let z=O?ES(fT(wS(N),w,V)):N;if(z=B?hm(z):z,z=O?dT(z):z,w==null)return(y=sa(z))==null?void 0:y.id;const X=z.find(K=>K.id===w);if(!X)return(S=sa(z))==null?void 0:S.id;const te=z.some(K=>K.rowId),fe=z.indexOf(X),Z=z.slice(fe+1),ae=tb(Z,X.rowId);if(g){const K=oT(ae,w),M=K.slice(g)[0]||K[K.length-1];return M==null?void 0:M.id}const ie=R&&(O?R!=="horizontal":R!=="vertical"),U=te&&T&&(O?T!=="horizontal":T!=="vertical"),I=q?(!te||O)&&ie&&A:O?A:!1;if(ie){const K=U&&!I?z:tb(z,X.rowId),M=sT(K,w,I),F=sa(M,w);return F==null?void 0:F.id}if(U){const K=sa(I?ae:Z,w);return I?(K==null?void 0:K.id)||null:K==null?void 0:K.id}const ne=sa(ae,w);return!ne&&I?null:ne==null?void 0:ne.id};return Yt(lt(lt({},i),f),{setBaseElement:h=>f.setState("baseElement",h),setActiveId:h=>f.setState("activeId",h),move:h=>{h!==void 0&&(f.setState("activeId",h),f.setState("moves",v=>v+1))},first:()=>{var h;return(h=sa(f.getState().renderedItems))==null?void 0:h.id},last:()=>{var h;return(h=sa(hm(f.getState().renderedItems)))==null?void 0:h.id},next:h=>(h!==void 0&&typeof h=="number"&&(h={skip:h}),d("next",h)),previous:h=>(h!==void 0&&typeof h=="number"&&(h={skip:h}),d("previous",h)),down:h=>(h!==void 0&&typeof h=="number"&&(h={skip:h}),d("down",h)),up:h=>(h!==void 0&&typeof h=="number"&&(h={skip:h}),d("up",h))})}function mT(t,r,a){return t=lT(t,r,a),Xt(t,a,"activeId","setActiveId"),Xt(t,a,"includesBaseElement"),Xt(t,a,"virtualFocus"),Xt(t,a,"orientation"),Xt(t,a,"rtl"),Xt(t,a,"focusLoop"),Xt(t,a,"focusWrap"),Xt(t,a,"focusShift"),t}function CS(t={}){const r=hv(t.store,dv(t.disclosure,["contentElement","disclosureElement"])),a=r==null?void 0:r.getState(),i=et(t.open,a==null?void 0:a.open,t.defaultOpen,!1),o=et(t.animated,a==null?void 0:a.animated,!1),s={open:i,animated:o,animating:!!o&&i,mounted:i,contentElement:et(a==null?void 0:a.contentElement,null),disclosureElement:et(a==null?void 0:a.disclosureElement,null)},f=$r(s,r);return ha(f,()=>pa(f,["animated","animating"],d=>{d.animated||f.setState("animating",!1)})),ha(f,()=>fv(f,["open"],()=>{f.getState().animated&&f.setState("animating",!0)})),ha(f,()=>pa(f,["open","animating"],d=>{f.setState("mounted",d.open||d.animating)})),Yt(lt({},f),{disclosure:t.disclosure,setOpen:d=>f.setState("open",d),show:()=>f.setState("open",!0),hide:()=>f.setState("open",!1),toggle:()=>f.setState("open",d=>!d),stopAnimation:()=>f.setState("animating",!1),setContentElement:d=>f.setState("contentElement",d),setDisclosureElement:d=>f.setState("disclosureElement",d)})}function TS(t,r,a){return ef(r,[a.store,a.disclosure]),Xt(t,a,"open","setOpen"),Xt(t,a,"mounted","setMounted"),Xt(t,a,"animated"),Object.assign(t,{disclosure:a.disclosure})}function vT(t={}){const[r,a]=mv(CS,t);return TS(r,a,t)}function RS(t={}){return CS(t)}function DS(t,r,a){return TS(t,r,a)}function pT(t={}){const[r,a]=mv(RS,t);return DS(r,a,t)}function yT(t={}){var r=t,{popover:a}=r,i=oS(r,["popover"]);const o=hv(i.store,dv(a,["arrowElement","anchorElement","contentElement","popoverElement","disclosureElement"])),s=o==null?void 0:o.getState(),f=RS(Yt(lt({},i),{store:o})),d=et(i.placement,s==null?void 0:s.placement,"bottom"),h=Yt(lt({},f.getState()),{placement:d,currentPlacement:d,anchorElement:et(s==null?void 0:s.anchorElement,null),popoverElement:et(s==null?void 0:s.popoverElement,null),arrowElement:et(s==null?void 0:s.arrowElement,null),rendered:Symbol("rendered")}),v=$r(h,f,o);return Yt(lt(lt({},f),v),{setAnchorElement:y=>v.setState("anchorElement",y),setPopoverElement:y=>v.setState("popoverElement",y),setArrowElement:y=>v.setState("arrowElement",y),render:()=>v.setState("rendered",Symbol("rendered"))})}function gT(t,r,a){return ef(r,[a.popover]),Xt(t,a,"placement"),DS(t,r,a)}var Ho=xa();Ho.useContext;Ho.useScopedContext;var vv=Ho.useProviderContext,bT=Ho.ContextProvider,ST=Ho.ScopedContextProvider,rf=xa([bT],[ST]),xT=rf.useScopedContext,af=rf.useProviderContext,ET=rf.ContextProvider,pv=rf.ScopedContextProvider,AS=E.createContext(void 0),wT=E.createContext(void 0),Uo=xa([ET],[pv]);Uo.useContext;Uo.useScopedContext;var lf=Uo.useProviderContext,MS=Uo.ContextProvider,uf=Uo.ScopedContextProvider;E.createContext(void 0);var OT=xa([MS,nf],[uf,sv]),CT=OT.useProviderContext;E.createContext(void 0);E.createContext(!1);var TT="div",jS=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=lf();return i=i||s,o=we(oe({},o),{ref:Ht(i==null?void 0:i.setAnchorElement,o.ref)}),o});Xe(function(r){const a=jS(r);return Ie(TT,a)});var RT={id:null};function DT(t,r,a=!1){const i=t.findIndex(o=>o.id===r);return[...t.slice(i+1),...a?[RT]:[],...t.slice(0,i)]}function AT(t,r){return t.find(a=>!a.disabled)}function Ia(t,r){return r&&t.item(r)||null}function MT(t){const r=[];for(const a of t){const i=r.find(o=>{var s;return((s=o[0])==null?void 0:s.rowId)===a.rowId});i?i.push(a):r.push([a])}return r}function jT(t,r=!1){if(Sa(t))t.setSelectionRange(r?t.value.length:0,t.value.length);else if(t.isContentEditable){const a=yt(t).getSelection();a==null||a.selectAllChildren(t),r&&(a==null||a.collapseToEnd())}}var mm=Symbol("FOCUS_SILENTLY");function _T(t){t[mm]=!0,t.focus({preventScroll:!0})}function NT(t){const r=t[mm];return delete t[mm],r}function xo(t,r,a){return!(!r||r===a||!t.item(r.id))}var _S=E.createContext(!0),of="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], summary, iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false'])";function zT(t){return Number.parseInt(t.getAttribute("tabindex")||"0",10)<0}function yr(t){return!(!t.matches(of)||!hS(t)||t.closest("[inert]"))}function zc(t){if(!yr(t)||zT(t))return!1;if(!("form"in t)||!t.form||t.checked||t.type!=="radio")return!0;const r=t.form.elements.namedItem(t.name);if(!r||!("length"in r))return!0;const a=ba(t);return!a||a===t||!("form"in a)||a.form!==t.form||a.name!==t.name}function yv(t,r){const a=Array.from(t.querySelectorAll(of));r&&a.unshift(t);const i=a.filter(yr);return i.forEach((o,s)=>{if(Wm(o)&&o.contentDocument){const f=o.contentDocument.body;i.splice(s,1,...yv(f))}}),i}function sf(t,r,a){const i=Array.from(t.querySelectorAll(of)),o=i.filter(zc);return r&&zc(t)&&o.unshift(t),o.forEach((s,f)=>{if(Wm(s)&&s.contentDocument){const d=s.contentDocument.body,h=sf(d,!1,a);o.splice(f,1,...h)}}),!o.length&&a?i:o}function LT(t,r,a){const[i]=sf(t,r,a);return i||null}function HT(t,r,a,i){const o=ba(t),s=yv(t,r),f=s.indexOf(o);return s.slice(f+1).find(zc)||null||null||null}function Ph(t,r){return HT(document.body,!1)}function UT(t,r,a,i){const o=ba(t),s=yv(t,r).reverse(),f=s.indexOf(o);return s.slice(f+1).find(zc)||null||null||null}function nb(t,r){return UT(document.body,!1)}function $T(t){for(;t&&!yr(t);)t=t.closest(of);return t||null}function Lc(t){const r=ba(t);if(!r)return!1;if(r===t)return!0;const a=r.getAttribute("aria-activedescendant");return a?a===t.id:!1}function oi(t){const r=ba(t);if(!r)return!1;if(Lt(t,r))return!0;const a=r.getAttribute("aria-activedescendant");return!a||!("id"in t)?!1:a===t.id?!0:!!t.querySelector(`#${CSS.escape(a)}`)}function NS(t){!oi(t)&&yr(t)&&t.focus()}function BT(t){var r;const a=(r=t.getAttribute("tabindex"))!=null?r:"";t.setAttribute("data-tabindex",a),t.setAttribute("tabindex","-1")}function PT(t,r){const a=sf(t,r);for(const i of a)BT(i)}function qT(t){const r=t.querySelectorAll("[data-tabindex]"),a=i=>{const o=i.getAttribute("data-tabindex");i.removeAttribute("data-tabindex"),o?i.setAttribute("tabindex",o):i.removeAttribute("tabindex")};t.hasAttribute("data-tabindex")&&a(t);for(const i of r)a(i)}function kT(t,r){"scrollIntoView"in t?(t.focus({preventScroll:!0}),t.scrollIntoView(lt({block:"nearest",inline:"nearest"},r))):t.focus()}var FT="div",rb=nv(),VT=["text","search","url","tel","email","password","number","date","month","week","time","datetime","datetime-local"],zS=Symbol("safariFocusAncestor");function YT(t){return t?!!t[zS]:!1}function ab(t,r){t&&(t[zS]=r)}function QT(t){const{tagName:r,readOnly:a,type:i}=t;return r==="TEXTAREA"&&!a||r==="SELECT"&&!a?!0:r==="INPUT"&&!a?VT.includes(i):!!(t.isContentEditable||t.getAttribute("role")==="combobox"&&t.dataset.name)}function KT(t){return"labels"in t?t.labels:null}function ib(t){return t.tagName.toLowerCase()==="input"&&t.type?t.type==="radio"||t.type==="checkbox":!1}function GT(t){return t?t==="button"||t==="summary"||t==="input"||t==="select"||t==="textarea"||t==="a":!0}function XT(t){return t?t==="button"||t==="input"||t==="select"||t==="textarea":!0}function ZT(t,r,a,i,o){return t?r?a&&!i?-1:void 0:a?o:o||0:o}function qh(t,r){return Ye(a=>{t==null||t(a),!a.defaultPrevented&&r&&(a.stopPropagation(),a.preventDefault())})}var gv=!0;function IT(t){const r=t.target;r&&"hasAttribute"in r&&(r.hasAttribute("data-focus-visible")||(gv=!1))}function JT(t){t.metaKey||t.ctrlKey||t.altKey||(gv=!0)}var $o=tt(function(r){var a=r,{focusable:i=!0,accessibleWhenDisabled:o,autoFocus:s,onFocusVisible:f}=a,d=Ge(a,["focusable","accessibleWhenDisabled","autoFocus","onFocusVisible"]);const h=E.useRef(null);E.useEffect(()=>{i&&(Zt("mousedown",IT,!0),Zt("keydown",JT,!0))},[i]),rb&&E.useEffect(()=>{if(!i)return;const U=h.current;if(!U||!ib(U))return;const I=KT(U);if(!I)return;const ne=()=>queueMicrotask(()=>U.focus());for(const K of I)K.addEventListener("mouseup",ne);return()=>{for(const K of I)K.removeEventListener("mouseup",ne)}},[i]);const v=i&&No(d),y=!!v&&!o,[S,p]=E.useState(!1);E.useEffect(()=>{i&&y&&S&&p(!1)},[i,y,S]),E.useEffect(()=>{if(!i||!S)return;const U=h.current;if(!U||typeof IntersectionObserver>"u")return;const I=new IntersectionObserver(()=>{yr(U)||p(!1)});return I.observe(U),()=>I.disconnect()},[i,S]);const g=qh(d.onKeyPressCapture,v),w=qh(d.onMouseDownCapture,v),x=qh(d.onClickCapture,v),R=d.onMouseDown,T=Ye(U=>{if(R==null||R(U),U.defaultPrevented||!i)return;const I=U.currentTarget;if(!rb||yS(U)||!fi(I)&&!ib(I))return;let ne=!1;const K=()=>{ne=!0},M={capture:!0,once:!0};I.addEventListener("focusin",K,M);const F=$T(I.parentElement);ab(F,!0),So(I,"mouseup",()=>{I.removeEventListener("focusin",K,!0),ab(F,!1),!ne&&NS(I)})}),A=(U,I)=>{if(I&&(U.currentTarget=I),!i)return;const ne=U.currentTarget;ne&&Lc(ne)&&(f==null||f(U),!U.defaultPrevented&&(ne.dataset.focusVisible="true",p(!0)))},N=d.onKeyDownCapture,j=Ye(U=>{if(N==null||N(U),U.defaultPrevented||!i||S||U.metaKey||U.altKey||U.ctrlKey||!Hn(U))return;const I=U.currentTarget;So(I,"focusout",()=>A(U,I))}),O=d.onFocusCapture,q=Ye(U=>{if(O==null||O(U),U.defaultPrevented||!i)return;if(!Hn(U)){p(!1);return}const I=U.currentTarget,ne=()=>A(U,I);gv||QT(U.target)?So(U.target,"focusout",ne):p(!1)}),B=d.onBlur,V=Ye(U=>{B==null||B(U),i&&$l(U)&&p(!1)}),z=E.useContext(_S),X=Ye(U=>{i&&s&&U&&z&&queueMicrotask(()=>{Lc(U)||yr(U)&&U.focus()})}),te=av(h),fe=i&&GT(te),Z=i&&XT(te),ae=d.style,ie=E.useMemo(()=>y?oe({pointerEvents:"none"},ae):ae,[y,ae]);return d=we(oe({"data-focus-visible":i&&S||void 0,"data-autofocus":s||void 0,"aria-disabled":v||void 0},d),{ref:Ht(h,X,d.ref),style:ie,tabIndex:ZT(i,y,fe,Z,d.tabIndex),disabled:Z&&y?!0:void 0,contentEditable:v?void 0:d.contentEditable,onKeyPressCapture:g,onClickCapture:x,onMouseDownCapture:w,onMouseDown:T,onKeyDownCapture:j,onFocusCapture:q,onBlur:V}),iu(d)});Xe(function(r){const a=$o(r);return Ie(FT,a)});var WT="div";function eR(t){return t.some(r=>!!r.rowId)}function tR(t){const r=t.target;return r&&!Sa(r)?!1:t.key.length===1&&!t.ctrlKey&&!t.metaKey}function nR(t){return t.key==="Shift"||t.key==="Control"||t.key==="Alt"||t.key==="Meta"}function lb(t,r,a){return Ye(i=>{var o;if(r==null||r(i),i.defaultPrevented||i.isPropagationStopped()||!Hn(i)||nR(i)||tR(i))return;const s=t.getState(),f=(o=Ia(t,s.activeId))==null?void 0:o.element;if(!f)return;const d=i,h=Ge(d,["view"]),v=a==null?void 0:a.current;f!==v&&f.focus(),PC(f,i.type,h)||i.preventDefault(),i.currentTarget.contains(f)&&i.stopPropagation()})}function rR(t){return AT(ES(hm(MT(t))))}function aR(t){const[r,a]=E.useState(!1),i=E.useCallback(()=>a(!0),[]),o=t.useState(s=>Ia(t,s.activeId));return E.useEffect(()=>{const s=o==null?void 0:o.element;r&&s&&(a(!1),s.focus({preventScroll:!0}))},[o,r]),i}var LS=tt(function(r){var a=r,{store:i,composite:o=!0,focusOnMove:s=o,moveOnKeyPress:f=!0}=a,d=Ge(a,["store","composite","focusOnMove","moveOnKeyPress"]);const h=GC();i=i||h,Wt(i,!1);const v=E.useRef(null),y=E.useRef(null),S=aR(i),p=i.useState("moves"),[,g]=qC(o?i.setBaseElement:null);E.useEffect(()=>{var Z;if(!i||!p||!o||!s)return;const{activeId:ae}=i.getState(),ie=(Z=Ia(i,ae))==null?void 0:Z.element;ie&&kT(ie)},[i,p,o,s]),ct(()=>{if(!i||!p||!o)return;const{baseElement:Z,activeId:ae}=i.getState();if(!(ae===null)||!Z)return;const U=y.current;y.current=null,U&&Hl(U,{relatedTarget:Z}),Lc(Z)||Z.focus()},[i,p,o]);const w=i.useState("activeId"),x=i.useState("virtualFocus");ct(()=>{var Z;if(!i||!o||!x)return;const ae=y.current;if(y.current=null,!ae)return;const U=((Z=Ia(i,w))==null?void 0:Z.element)||ba(ae);U!==ae&&Hl(ae,{relatedTarget:U})},[i,w,x,o]);const R=lb(i,d.onKeyDownCapture,y),T=lb(i,d.onKeyUpCapture,y),A=d.onFocusCapture,N=Ye(Z=>{if(A==null||A(Z),Z.defaultPrevented||!i)return;const{virtualFocus:ae}=i.getState();if(!ae)return;const ie=Z.relatedTarget,U=NT(Z.currentTarget);Hn(Z)&&U&&(Z.stopPropagation(),y.current=ie)}),j=d.onFocus,O=Ye(Z=>{if(j==null||j(Z),Z.defaultPrevented||!o||!i)return;const{relatedTarget:ae}=Z,{virtualFocus:ie}=i.getState();ie?Hn(Z)&&!xo(i,ae)&&queueMicrotask(S):Hn(Z)&&i.setActiveId(null)}),q=d.onBlurCapture,B=Ye(Z=>{var ae;if(q==null||q(Z),Z.defaultPrevented||!i)return;const{virtualFocus:ie,activeId:U}=i.getState();if(!ie)return;const I=(ae=Ia(i,U))==null?void 0:ae.element,ne=Z.relatedTarget,K=xo(i,ne),M=y.current;y.current=null,Hn(Z)&&K?(ne===I?M&&M!==ne&&Hl(M,Z):I?Hl(I,Z):M&&Hl(M,Z),Z.stopPropagation()):!xo(i,Z.target)&&I&&Hl(I,Z)}),V=d.onKeyDown,z=Un(f),X=Ye(Z=>{var ae;if(V==null||V(Z),Z.defaultPrevented||!i||!Hn(Z))return;const{orientation:ie,renderedItems:U,activeId:I}=i.getState(),ne=Ia(i,I);if((ae=ne==null?void 0:ne.element)!=null&&ae.isConnected)return;const K=ie!=="horizontal",M=ie!=="vertical",F=eR(U);if((Z.key==="ArrowLeft"||Z.key==="ArrowRight"||Z.key==="Home"||Z.key==="End")&&Sa(Z.currentTarget))return;const ge={ArrowUp:(F||K)&&(()=>{if(F){const Te=rR(U);return Te==null?void 0:Te.id}return i==null?void 0:i.last()}),ArrowRight:(F||M)&&i.first,ArrowDown:(F||K)&&i.first,ArrowLeft:(F||M)&&i.last,Home:i.first,End:i.last,PageUp:i.first,PageDown:i.last}[Z.key];if(ge){const Te=ge();if(Te!==void 0){if(!z(Z))return;Z.preventDefault(),i.move(Te)}}});d=yn(d,Z=>D.jsx(nf,{value:i,children:Z}),[i]);const te=i.useState(Z=>{var ae;if(i&&o&&Z.virtualFocus)return(ae=Ia(i,Z.activeId))==null?void 0:ae.id});d=we(oe({"aria-activedescendant":te},d),{ref:Ht(v,g,d.ref),onKeyDownCapture:R,onKeyUpCapture:T,onFocusCapture:N,onFocus:O,onBlurCapture:B,onKeyDown:X});const fe=i.useState(Z=>o&&(Z.virtualFocus||Z.activeId===null));return d=$o(oe({focusable:fe},d)),d});Xe(function(r){const a=LS(r);return Ie(WT,a)});var iR="button";function ub(t){if(!t.isTrusted)return!1;const r=t.currentTarget;return t.key==="Enter"?fi(r)||r.tagName==="SUMMARY"||r.tagName==="A":t.key===" "?fi(r)||r.tagName==="SUMMARY"||r.tagName==="INPUT"||r.tagName==="SELECT":!1}var lR=Symbol("command"),bv=tt(function(r){var a=r,{clickOnEnter:i=!0,clickOnSpace:o=!0}=a,s=Ge(a,["clickOnEnter","clickOnSpace"]);const f=E.useRef(null),[d,h]=E.useState(!1);E.useEffect(()=>{f.current&&h(fi(f.current))},[]);const[v,y]=E.useState(!1),S=E.useRef(!1),p=No(s),[g,w]=bS(s,lR,!0),x=s.onKeyDown,R=Ye(N=>{x==null||x(N);const j=N.currentTarget;if(N.defaultPrevented||g||p||!Hn(N)||Sa(j)||j.isContentEditable)return;const O=i&&N.key==="Enter",q=o&&N.key===" ",B=N.key==="Enter"&&!i,V=N.key===" "&&!o;if(B||V){N.preventDefault();return}if(O||q){const z=ub(N);if(O){if(!z){N.preventDefault();const X=N,te=Ge(X,["view"]),fe=()=>Gg(j,te);LC()?So(j,"keyup",fe):queueMicrotask(fe)}}else q&&(S.current=!0,z||(N.preventDefault(),y(!0)))}}),T=s.onKeyUp,A=Ye(N=>{if(T==null||T(N),N.defaultPrevented||g||p||N.metaKey)return;const j=o&&N.key===" ";if(S.current&&j&&(S.current=!1,!ub(N))){N.preventDefault(),y(!1);const O=N.currentTarget,q=N,B=Ge(q,["view"]);queueMicrotask(()=>Gg(O,B))}});return s=we(oe(oe({"data-active":v||void 0,type:d?"button":void 0},w),s),{ref:Ht(f,s.ref),onKeyDown:R,onKeyUp:A}),s=$o(s),s});Xe(function(r){const a=bv(r);return Ie(iR,a)});var HS="button",Sv=tt(function(r){const a=E.useRef(null),i=av(a,HS),[o,s]=E.useState(()=>!!i&&fi({tagName:i,type:r.type}));return E.useEffect(()=>{a.current&&s(fi(a.current))},[]),r=we(oe({role:!o&&i!=="a"?"button":void 0},r),{ref:Ht(a,r.ref)}),r=bv(r),r});Xe(function(r){const a=Sv(r);return Ie(HS,a)});var uR="button",oR=Symbol("disclosure"),US=tt(function(r){var a=r,{store:i,toggleOnClick:o=!0}=a,s=Ge(a,["store","toggleOnClick"]);const f=vv();i=i||f,Wt(i,!1);const d=E.useRef(null),[h,v]=E.useState(!1),y=i.useState("disclosureElement"),S=i.useState("open");E.useEffect(()=>{let A=y===d.current;y!=null&&y.isConnected||(i==null||i.setDisclosureElement(d.current),A=!0),v(S&&A)},[y,i,S]);const p=s.onClick,g=Un(o),[w,x]=bS(s,oR,!0),R=Ye(A=>{p==null||p(A),!A.defaultPrevented&&(w||g(A)&&(i==null||i.setDisclosureElement(A.currentTarget),i==null||i.toggle()))}),T=i.useState("contentElement");return s=we(oe(oe({"aria-expanded":h,"aria-controls":T==null?void 0:T.id},x),s),{ref:Ht(d,s.ref),onClick:R}),s=Sv(s),s});Xe(function(r){const a=US(r);return Ie(uR,a)});var sR="button",$S=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=af();i=i||s,Wt(i,!1);const f=i.useState("contentElement");return o=oe({"aria-haspopup":ev(f,"dialog")},o),o=US(oe({store:i},o)),o});Xe(function(r){const a=$S(r);return Ie(sR,a)});var cR="div";function BS(t){const r=t.relatedTarget;return(r==null?void 0:r.nodeType)===Node.ELEMENT_NODE?r:null}function fR(t){const r=BS(t);return r?Lt(t.currentTarget,r):!1}var vm=Symbol("composite-hover");function dR(t){let r=BS(t);if(!r)return!1;do{if(va(r,vm)&&r[vm])return!0;r=r.parentElement}while(r);return!1}var PS=tt(function(r){var a=r,{store:i,focusOnHover:o=!0,blurOnHoverEnd:s=!!o}=a,f=Ge(a,["store","focusOnHover","blurOnHoverEnd"]);const d=tf();i=i||d,Wt(i,!1);const h=lv(),v=f.onMouseMove,y=Un(o),S=Ye(R=>{if(v==null||v(R),!R.defaultPrevented&&h()&&y(R)){if(!oi(R.currentTarget)){const T=i==null?void 0:i.getState().baseElement;T&&!Lc(T)&&T.focus()}i==null||i.setActiveId(R.currentTarget.id)}}),p=f.onMouseLeave,g=Un(s),w=Ye(R=>{var T;p==null||p(R),!R.defaultPrevented&&h()&&(fR(R)||dR(R)||y(R)&&g(R)&&(i==null||i.setActiveId(null),(T=i==null?void 0:i.getState().baseElement)==null||T.focus()))}),x=E.useCallback(R=>{R&&(R[vm]=!0)},[]);return f=we(oe({},f),{ref:Ht(x,f.ref),onMouseMove:S,onMouseLeave:w}),iu(f)});ov(Xe(function(r){const a=PS(r);return Ie(cR,a)}));var hR="div",qS=tt(function(r){var a=r,{store:i,shouldRegisterItem:o=!0,getItem:s=cS,element:f}=a,d=Ge(a,["store","shouldRegisterItem","getItem","element"]);const h=YC();i=i||h;const v=Ji(d.id),y=E.useRef(f);return E.useEffect(()=>{const S=y.current;if(!v||!S||!o)return;const p=s({id:v,element:S});return i==null?void 0:i.renderItem(p)},[v,o,s,i]),d=we(oe({},d),{ref:Ht(y,d.ref)}),iu(d)});Xe(function(r){const a=qS(r);return Ie(hR,a)});var mR="button";function vR(t){return fm(t)?!0:t.tagName==="INPUT"&&!fi(t)}function pR(t,r=!1){const a=t.clientHeight,{top:i}=t.getBoundingClientRect(),o=Math.max(a*.875,a-40)*1.5,s=r?a-o+i:o+i;return t.tagName==="HTML"?s+t.scrollTop:s}function yR(t,r=!1){const{top:a}=t.getBoundingClientRect();return r?a+t.clientHeight:a}function ob(t,r,a,i=!1){var o;if(!r||!a)return;const{renderedItems:s}=r.getState(),f=vS(t);if(!f)return;const d=pR(f,i);let h,v;for(let y=0;y<s.length;y+=1){const S=h;if(h=a(y),!h)break;if(h===S)continue;const p=(o=Ia(r,h))==null?void 0:o.element;if(!p)continue;const w=yR(p,i)-d,x=Math.abs(w);if(i&&w<=0||!i&&w>=0){v!==void 0&&v<x&&(h=S);break}v=x}return h}function gR(t,r){return Hn(t)?!1:xo(r,t.target)}var kS=tt(function(r){var a=r,{store:i,rowId:o,preventScrollOnKeyDown:s=!1,moveOnKeyPress:f=!0,tabbable:d=!1,getItem:h,"aria-setsize":v,"aria-posinset":y}=a,S=Ge(a,["store","rowId","preventScrollOnKeyDown","moveOnKeyPress","tabbable","getItem","aria-setsize","aria-posinset"]);const p=tf();i=i||p;const g=Ji(S.id),w=E.useRef(null),x=E.useContext(ZC),T=No(S)&&!S.accessibleWhenDisabled,{rowId:A,baseElement:N,isActiveItem:j,ariaSetSize:O,ariaPosInSet:q,isTabbable:B}=nT(i,{rowId(K){if(o)return o;if(K&&x!=null&&x.baseElement&&x.baseElement===K.baseElement)return x.id},baseElement(K){return(K==null?void 0:K.baseElement)||void 0},isActiveItem(K){return!!K&&K.activeId===g},ariaSetSize(K){if(v!=null)return v;if(K&&x!=null&&x.ariaSetSize&&x.baseElement===K.baseElement)return x.ariaSetSize},ariaPosInSet(K){if(y!=null)return y;if(!K||!(x!=null&&x.ariaPosInSet)||x.baseElement!==K.baseElement)return;const M=K.renderedItems.filter(F=>F.rowId===A);return x.ariaPosInSet+M.findIndex(F=>F.id===g)},isTabbable(K){if(!(K!=null&&K.renderedItems.length))return!0;if(K.virtualFocus)return!1;if(d)return!0;if(K.activeId===null)return!1;const M=i==null?void 0:i.item(K.activeId);return M!=null&&M.disabled||!(M!=null&&M.element)?!0:K.activeId===g}}),V=E.useCallback(K=>{var M;const F=we(oe({},K),{id:g||K.id,rowId:A,disabled:!!T,children:(M=K.element)==null?void 0:M.textContent});return h?h(F):F},[g,A,T,h]),z=S.onFocus,X=E.useRef(!1),te=Ye(K=>{if(z==null||z(K),K.defaultPrevented||yS(K)||!g||!i||gR(K,i))return;const{virtualFocus:M,baseElement:F}=i.getState();if(i.setActiveId(g),fm(K.currentTarget)&&jT(K.currentTarget),!M||!Hn(K)||vR(K.currentTarget)||!(F!=null&&F.isConnected))return;nv()&&K.currentTarget.hasAttribute("data-autofocus")&&K.currentTarget.scrollIntoView({block:"nearest",inline:"nearest"}),X.current=!0,K.relatedTarget===F||xo(i,K.relatedTarget)?_T(F):F.focus()}),fe=S.onBlurCapture,Z=Ye(K=>{if(fe==null||fe(K),K.defaultPrevented)return;const M=i==null?void 0:i.getState();M!=null&&M.virtualFocus&&X.current&&(X.current=!1,K.preventDefault(),K.stopPropagation())}),ae=S.onKeyDown,ie=Un(s),U=Un(f),I=Ye(K=>{if(ae==null||ae(K),K.defaultPrevented||!Hn(K)||!i)return;const{currentTarget:M}=K,F=i.getState(),se=i.item(g),de=!!(se!=null&&se.rowId),ce=F.orientation!=="horizontal",ge=F.orientation!=="vertical",Te=()=>!!(de||ge||!F.baseElement||!Sa(F.baseElement)),_e={ArrowUp:(de||ce)&&i.up,ArrowRight:(de||ge)&&i.next,ArrowDown:(de||ce)&&i.down,ArrowLeft:(de||ge)&&i.previous,Home:()=>{if(Te())return!de||K.ctrlKey?i==null?void 0:i.first():i==null?void 0:i.previous(-1)},End:()=>{if(Te())return!de||K.ctrlKey?i==null?void 0:i.last():i==null?void 0:i.next(-1)},PageUp:()=>ob(M,i,i==null?void 0:i.up,!0),PageDown:()=>ob(M,i,i==null?void 0:i.down)}[K.key];if(_e){if(fm(M)){const Ne=_C(M),Mt=ge&&K.key==="ArrowLeft",bn=ge&&K.key==="ArrowRight",ft=ce&&K.key==="ArrowUp",ln=ce&&K.key==="ArrowDown";if(bn||ln){const{length:Cn}=jC(M);if(Ne.end!==Cn)return}else if((Mt||ft)&&Ne.start!==0)return}const je=_e();if(ie(K)||je!==void 0){if(!U(K))return;K.preventDefault(),i.move(je)}}}),ne=E.useMemo(()=>({id:g,baseElement:N}),[g,N]);return S=yn(S,K=>D.jsx(XC.Provider,{value:ne,children:K}),[ne]),S=we(oe({id:g,"data-active-item":j||void 0},S),{ref:Ht(w,S.ref),tabIndex:B?S.tabIndex:-1,onFocus:te,onBlurCapture:Z,onKeyDown:I}),S=bv(S),S=qS(we(oe({store:i},S),{getItem:V,shouldRegisterItem:g?S.shouldRegisterItem:!1})),iu(we(oe({},S),{"aria-setsize":O,"aria-posinset":q}))});ov(Xe(function(r){const a=kS(r);return Ie(mR,a)}));var kh={exports:{}},rn={};/**
31
- * @license React
32
- * react-dom.production.js
33
- *
34
- * Copyright (c) Meta Platforms, Inc. and affiliates.
35
- *
36
- * This source code is licensed under the MIT license found in the
37
- * LICENSE file in the root directory of this source tree.
38
- */var sb;function bR(){if(sb)return rn;sb=1;var t=Gc();function r(h){var v="https://react.dev/errors/"+h;if(1<arguments.length){v+="?args[]="+encodeURIComponent(arguments[1]);for(var y=2;y<arguments.length;y++)v+="&args[]="+encodeURIComponent(arguments[y])}return"Minified React error #"+h+"; visit "+v+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(){}var i={d:{f:a,r:function(){throw Error(r(522))},D:a,C:a,L:a,m:a,X:a,S:a,M:a},p:0,findDOMNode:null},o=Symbol.for("react.portal");function s(h,v,y){var S=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:S==null?null:""+S,children:h,containerInfo:v,implementation:y}}var f=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function d(h,v){if(h==="font")return"";if(typeof v=="string")return v==="use-credentials"?v:""}return rn.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,rn.createPortal=function(h,v){var y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!v||v.nodeType!==1&&v.nodeType!==9&&v.nodeType!==11)throw Error(r(299));return s(h,v,null,y)},rn.flushSync=function(h){var v=f.T,y=i.p;try{if(f.T=null,i.p=2,h)return h()}finally{f.T=v,i.p=y,i.d.f()}},rn.preconnect=function(h,v){typeof h=="string"&&(v?(v=v.crossOrigin,v=typeof v=="string"?v==="use-credentials"?v:"":void 0):v=null,i.d.C(h,v))},rn.prefetchDNS=function(h){typeof h=="string"&&i.d.D(h)},rn.preinit=function(h,v){if(typeof h=="string"&&v&&typeof v.as=="string"){var y=v.as,S=d(y,v.crossOrigin),p=typeof v.integrity=="string"?v.integrity:void 0,g=typeof v.fetchPriority=="string"?v.fetchPriority:void 0;y==="style"?i.d.S(h,typeof v.precedence=="string"?v.precedence:void 0,{crossOrigin:S,integrity:p,fetchPriority:g}):y==="script"&&i.d.X(h,{crossOrigin:S,integrity:p,fetchPriority:g,nonce:typeof v.nonce=="string"?v.nonce:void 0})}},rn.preinitModule=function(h,v){if(typeof h=="string")if(typeof v=="object"&&v!==null){if(v.as==null||v.as==="script"){var y=d(v.as,v.crossOrigin);i.d.M(h,{crossOrigin:y,integrity:typeof v.integrity=="string"?v.integrity:void 0,nonce:typeof v.nonce=="string"?v.nonce:void 0})}}else v==null&&i.d.M(h)},rn.preload=function(h,v){if(typeof h=="string"&&typeof v=="object"&&v!==null&&typeof v.as=="string"){var y=v.as,S=d(y,v.crossOrigin);i.d.L(h,y,{crossOrigin:S,integrity:typeof v.integrity=="string"?v.integrity:void 0,nonce:typeof v.nonce=="string"?v.nonce:void 0,type:typeof v.type=="string"?v.type:void 0,fetchPriority:typeof v.fetchPriority=="string"?v.fetchPriority:void 0,referrerPolicy:typeof v.referrerPolicy=="string"?v.referrerPolicy:void 0,imageSrcSet:typeof v.imageSrcSet=="string"?v.imageSrcSet:void 0,imageSizes:typeof v.imageSizes=="string"?v.imageSizes:void 0,media:typeof v.media=="string"?v.media:void 0})}},rn.preloadModule=function(h,v){if(typeof h=="string")if(v){var y=d(v.as,v.crossOrigin);i.d.m(h,{as:typeof v.as=="string"&&v.as!=="script"?v.as:void 0,crossOrigin:y,integrity:typeof v.integrity=="string"?v.integrity:void 0})}else i.d.m(h)},rn.requestFormReset=function(h){i.d.r(h)},rn.unstable_batchedUpdates=function(h,v){return h(v)},rn.useFormState=function(h,v,y){return f.H.useFormState(h,v,y)},rn.useFormStatus=function(){return f.H.useHostTransitionStatus()},rn.version="19.0.0",rn}var cb;function FS(){if(cb)return kh.exports;cb=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),kh.exports=bR(),kh.exports}var Hc=FS(),SR="div";function fb(t,r){const a=setTimeout(r,t);return()=>clearTimeout(a)}function xR(t){let r=requestAnimationFrame(()=>{r=requestAnimationFrame(t)});return()=>cancelAnimationFrame(r)}function db(...t){return t.join(", ").split(", ").reduce((r,a)=>{const i=a.endsWith("ms")?1:1e3,o=Number.parseFloat(a||"0s")*i;return o>r?o:r},0)}function xv(t,r,a){return!a&&r!==!1&&(!t||!!r)}var Ev=tt(function(r){var a=r,{store:i,alwaysVisible:o}=a,s=Ge(a,["store","alwaysVisible"]);const f=vv();i=i||f,Wt(i,!1);const d=E.useRef(null),h=Ji(s.id),[v,y]=E.useState(null),S=i.useState("open"),p=i.useState("mounted"),g=i.useState("animated"),w=i.useState("contentElement"),x=Pt(i.disclosure,"contentElement");ct(()=>{d.current&&(i==null||i.setContentElement(d.current))},[i]),ct(()=>{let N;return i==null||i.setState("animated",j=>(N=j,!0)),()=>{N!==void 0&&(i==null||i.setState("animated",N))}},[i]),ct(()=>{if(g){if(!(w!=null&&w.isConnected)){y(null);return}return xR(()=>{y(S?"enter":p?"leave":null)})}},[g,w,S,p]),ct(()=>{if(!i||!g||!v||!w)return;const N=()=>i==null?void 0:i.setState("animating",!1),j=()=>Hc.flushSync(N);if(v==="leave"&&S||v==="enter"&&!S)return;if(typeof g=="number")return fb(g,j);const{transitionDuration:O,animationDuration:q,transitionDelay:B,animationDelay:V}=getComputedStyle(w),{transitionDuration:z="0",animationDuration:X="0",transitionDelay:te="0",animationDelay:fe="0"}=x?getComputedStyle(x):{},Z=db(B,V,te,fe),ae=db(O,q,z,X),ie=Z+ae;if(!ie){v==="enter"&&i.setState("animated",!1),N();return}const U=1e3/60,I=Math.max(ie-U,0);return fb(I,j)},[i,g,w,x,S,v]),s=yn(s,N=>D.jsx(pv,{value:i,children:N}),[i]);const R=xv(p,s.hidden,o),T=s.style,A=E.useMemo(()=>R?we(oe({},T),{display:"none"}):T,[R,T]);return s=we(oe({id:h,"data-open":S||void 0,"data-enter":v==="enter"||void 0,"data-leave":v==="leave"||void 0,hidden:R},s),{ref:Ht(h?i.setContentElement:null,d,s.ref),style:A}),iu(s)}),ER=Xe(function(r){const a=Ev(r);return Ie(SR,a)});Xe(function(r){var a=r,{unmountOnHide:i}=a,o=Ge(a,["unmountOnHide"]);const s=vv(),f=o.store||s;return Pt(f,h=>!i||(h==null?void 0:h.mounted))===!1?null:D.jsx(ER,oe({},o))});function VS(t,...r){if(!t)return!1;const a=t.getAttribute("data-backdrop");return a==null?!1:a===""||a==="true"||!r.length?!0:r.some(i=>a===i)}var Fh=new WeakMap;function Bo(t,r,a){Fh.has(t)||Fh.set(t,new Map);const i=Fh.get(t),o=i.get(r);if(!o)return i.set(r,a()),()=>{var d;(d=i.get(r))==null||d(),i.delete(r)};const s=a(),f=()=>{s(),o(),i.delete(r)};return i.set(r,f),()=>{i.get(r)===f&&(s(),i.set(r,o))}}function wv(t,r,a){return Bo(t,r,()=>{const o=t.getAttribute(r);return t.setAttribute(r,a),()=>{o==null?t.removeAttribute(r):t.setAttribute(r,o)}})}function Gi(t,r,a){return Bo(t,r,()=>{const o=r in t,s=t[r];return t[r]=a,()=>{o?t[r]=s:delete t[r]}})}function pm(t,r){return t?Bo(t,"style",()=>{const i=t.style.cssText;return Object.assign(t.style,r),()=>{t.style.cssText=i}}):()=>{}}function wR(t,r,a){return t?Bo(t,r,()=>{const o=t.style.getPropertyValue(r);return t.style.setProperty(r,a),()=>{o?t.style.setProperty(r,o):t.style.removeProperty(r)}}):()=>{}}var OR=["SCRIPT","STYLE"];function ym(t){return`__ariakit-dialog-snapshot-${t}`}function CR(t,r){const a=yt(r),i=ym(t);if(!a.body[i])return!0;do{if(r===a.body)return!1;if(r[i])return!0;if(!r.parentElement)return!1;r=r.parentElement}while(!0)}function TR(t,r,a){return OR.includes(r.tagName)||!CR(t,r)?!1:!a.some(i=>i&&Lt(r,i))}function Ov(t,r,a,i){for(let o of r){if(!(o!=null&&o.isConnected))continue;const s=r.some(h=>!h||h===o?!1:h.contains(o)),f=yt(o),d=o;for(;o.parentElement&&o!==f.body;){if(i==null||i(o.parentElement,d),!s)for(const h of o.parentElement.children)TR(t,h,r)&&a(h,d);o=o.parentElement}}}function RR(t,r){const{body:a}=yt(r[0]),i=[];return Ov(t,r,s=>{i.push(Gi(s,ym(t),!0))}),Bn(Gi(a,ym(t),!0),()=>{for(const s of i)s()})}function nu(t="",r=!1){return`__ariakit-dialog-${r?"ancestor":"outside"}${t?`-${t}`:""}`}function DR(t,r=""){return Bn(Gi(t,nu(),!0),Gi(t,nu(r),!0))}function YS(t,r=""){return Bn(Gi(t,nu("",!0),!0),Gi(t,nu(r,!0),!0))}function Cv(t,r){const a=nu(r,!0);if(t[a])return!0;const i=nu(r);do{if(t[i])return!0;if(!t.parentElement)return!1;t=t.parentElement}while(!0)}function hb(t,r){const a=[],i=r.map(s=>s==null?void 0:s.id);return Ov(t,r,s=>{VS(s,...i)||a.unshift(DR(s,t))},(s,f)=>{f.hasAttribute("data-dialog")&&f.id!==t||a.unshift(YS(s,t))}),()=>{for(const s of a)s()}}var AR="div",MR=["a","button","details","dialog","div","form","h1","h2","h3","h4","h5","h6","header","img","input","label","li","nav","ol","p","section","select","span","summary","textarea","ul","svg"];tt(function(r){return r});var Uc=Xe(function(r){return Ie(AR,r)});Object.assign(Uc,MR.reduce((t,r)=>(t[r]=Xe(function(i){return Ie(r,i)}),t),{}));function jR({store:t,backdrop:r,alwaysVisible:a,hidden:i}){const o=E.useRef(null),s=vT({disclosure:t}),f=Pt(t,"contentElement");E.useEffect(()=>{const v=o.current,y=f;v&&y&&(v.style.zIndex=getComputedStyle(y).zIndex)},[f]),ct(()=>{const v=f==null?void 0:f.id;if(!v)return;const y=o.current;if(y)return YS(y,v)},[f]);const d=Ev({ref:o,store:s,role:"presentation","data-backdrop":(f==null?void 0:f.id)||"",alwaysVisible:a,hidden:i??void 0,style:{position:"fixed",top:0,right:0,bottom:0,left:0}});if(!r)return null;if(E.isValidElement(r))return D.jsx(Uc,we(oe({},d),{render:r}));const h=typeof r!="boolean"?r:"div";return D.jsx(Uc,we(oe({},d),{render:D.jsx(h,{})}))}function _R(t,...r){if(!t)return!1;const a=t.getAttribute("data-focus-trap");return a==null?!1:r.length?a===""?!1:r.some(i=>a===i):!0}function NR(t){return wv(t,"aria-hidden","true")}function QS(){return"inert"in HTMLElement.prototype}function KS(t,r){if(!("style"in t))return Sc;if(QS())return Gi(t,"inert",!0);const i=sf(t,!0).map(o=>{if(r!=null&&r.some(f=>f&&Lt(f,o)))return Sc;const s=Bo(o,"focus",()=>(o.focus=Sc,()=>{delete o.focus}));return Bn(wv(o,"tabindex","-1"),s)});return Bn(...i,NR(t),pm(t,{pointerEvents:"none",userSelect:"none",cursor:"default"}))}function zR(t,r){const a=[],i=r.map(s=>s==null?void 0:s.id);return Ov(t,r,s=>{VS(s,...i)||_R(s,...i)||a.unshift(KS(s,r))},s=>{s.hasAttribute("role")&&(r.some(f=>f&&Lt(f,s))||a.unshift(wv(s,"role","none")))}),()=>{for(const s of a)s()}}function LR({attribute:t,contentId:r,contentElement:a,enabled:i}){const[o,s]=kC(),f=E.useCallback(()=>{if(!i||!a)return!1;const{body:d}=yt(a),h=d.getAttribute(t);return!h||h===r},[o,i,a,t,r]);return E.useEffect(()=>{if(!i||!r||!a)return;const{body:d}=yt(a);if(f())return d.setAttribute(t,r),()=>d.removeAttribute(t);const h=new MutationObserver(()=>Hc.flushSync(s));return h.observe(d,{attributeFilter:[t]}),()=>h.disconnect()},[o,i,r,a,f,t]),f}function HR(t){const r=t.getBoundingClientRect().left;return Math.round(r)+t.scrollLeft?"paddingLeft":"paddingRight"}function UR(t,r,a){const i=LR({attribute:"data-dialog-prevent-body-scroll",contentElement:t,contentId:r,enabled:a});E.useEffect(()=>{if(!i()||!t)return;const o=yt(t),s=dS(t),{documentElement:f,body:d}=o,h=f.style.getPropertyValue("--scrollbar-width"),v=h?Number.parseInt(h):s.innerWidth-f.clientWidth,y=()=>wR(f,"--scrollbar-width",`${v}px`),S=HR(f),p=()=>pm(d,{overflow:"hidden",[S]:`${v}px`}),g=()=>{var x,R;const{scrollX:T,scrollY:A,visualViewport:N}=s,j=(x=N==null?void 0:N.offsetLeft)!=null?x:0,O=(R=N==null?void 0:N.offsetTop)!=null?R:0,q=pm(d,{position:"fixed",overflow:"hidden",top:`${-(A-Math.floor(O))}px`,left:`${-(T-Math.floor(j))}px`,right:"0",[S]:`${v}px`});return()=>{q(),s.scrollTo({left:T,top:A,behavior:"instant"})}},w=tv()&&!HC();return Bn(y(),w?g():p())},[i,t])}var mb=E.createContext({});function $R(t){const r=E.useContext(mb),[a,i]=E.useState([]),o=E.useCallback(d=>{var h;return i(v=>[...v,d]),Bn((h=r.add)==null?void 0:h.call(r,d),()=>{i(v=>v.filter(y=>y!==d))})},[r]);ct(()=>pa(t,["open","contentElement"],d=>{var h;if(d.open&&d.contentElement)return(h=r.add)==null?void 0:h.call(r,t)}),[t,r]);const s=E.useMemo(()=>({store:t,add:o}),[t,o]);return{wrapElement:E.useCallback(d=>D.jsx(mb.Provider,{value:s,children:d}),[s]),nestedDialogs:a}}function BR(t){const r=E.useRef();return E.useEffect(()=>{if(!t){r.current=null;return}return Zt("mousedown",i=>{r.current=i.target},!0)},[t]),r}function PR(t){return t.tagName==="HTML"?!0:Lt(yt(t).body,t)}function qR(t,r){if(!t)return!1;if(Lt(t,r))return!0;const a=r.getAttribute("aria-activedescendant");if(a){const i=yt(t).getElementById(a);if(i)return Lt(t,i)}return!1}function kR(t,r){if(!("clientY"in t))return!1;const a=r.getBoundingClientRect();return a.width===0||a.height===0?!1:a.top<=t.clientY&&t.clientY<=a.top+a.height&&a.left<=t.clientX&&t.clientX<=a.left+a.width}function Vh({store:t,type:r,listener:a,capture:i,domReady:o}){const s=Ye(a),f=Pt(t,"open"),d=E.useRef(!1);ct(()=>{if(!f||!o)return;const{contentElement:h}=t.getState();if(!h)return;const v=()=>{d.current=!0};return h.addEventListener("focusin",v,!0),()=>h.removeEventListener("focusin",v,!0)},[t,f,o]),E.useEffect(()=>f?Zt(r,v=>{const{contentElement:y,disclosureElement:S}=t.getState(),p=v.target;!y||!p||!PR(p)||Lt(y,p)||qR(S,p)||p.hasAttribute("data-focus-trap")||kR(v,y)||d.current&&!Cv(p,y.id)||YT(p)||s(v)},i):void 0,[f,i])}function Yh(t,r){return typeof t=="function"?t(r):!!t}function FR(t,r,a){const i=Pt(t,"open"),o=BR(i),s={store:t,domReady:a,capture:!0};Vh(we(oe({},s),{type:"click",listener:f=>{const{contentElement:d}=t.getState(),h=o.current;h&&hS(h)&&Cv(h,d==null?void 0:d.id)&&Yh(r,f)&&t.hide()}})),Vh(we(oe({},s),{type:"focusin",listener:f=>{const{contentElement:d}=t.getState();d&&f.target!==yt(d)&&Yh(r,f)&&t.hide()}})),Vh(we(oe({},s),{type:"contextmenu",listener:f=>{Yh(r,f)&&t.hide()}}))}function VR(t,r){const i=yt(t).createElement("button");return i.type="button",i.tabIndex=-1,i.textContent="Dismiss popup",Object.assign(i.style,{border:"0px",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0px",position:"absolute",whiteSpace:"nowrap",width:"1px"}),i.addEventListener("click",r),t.prepend(i),()=>{i.removeEventListener("click",r),i.remove()}}var YR="div",GS=tt(function(r){var a=r,{autoFocusOnShow:i=!0}=a,o=Ge(a,["autoFocusOnShow"]);return o=yn(o,s=>D.jsx(_S.Provider,{value:i,children:s}),[i]),o});Xe(function(r){const a=GS(r);return Ie(YR,a)});var gm=E.createContext(0);function QR({level:t,children:r}){const a=E.useContext(gm),i=Math.max(Math.min(t||a+1,6),1);return D.jsx(gm.Provider,{value:i,children:r})}var KR="span",XS=tt(function(r){return r=we(oe({},r),{style:oe({border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},r.style)}),r});Xe(function(r){const a=XS(r);return Ie(KR,a)});var GR="span",XR=tt(function(r){return r=we(oe({"data-focus-trap":"",tabIndex:0,"aria-hidden":!0},r),{style:oe({position:"fixed",top:0,left:0},r.style)}),r=XS(r),r}),fc=Xe(function(r){const a=XR(r);return Ie(GR,a)}),vb=E.createContext(null),ZR="div";function IR(t){return yt(t).body}function JR(t,r){return r?typeof r=="function"?r(t):r:yt(t).createElement("div")}function WR(t="id"){return`${t?`${t}-`:""}${Math.random().toString(36).slice(2,8)}`}function Ka(t){queueMicrotask(()=>{t==null||t.focus()})}var ZS=tt(function(r){var a=r,{preserveTabOrder:i,preserveTabOrderAnchor:o,portalElement:s,portalRef:f,portal:d=!0}=a,h=Ge(a,["preserveTabOrder","preserveTabOrderAnchor","portalElement","portalRef","portal"]);const v=E.useRef(null),y=Ht(v,h.ref),S=E.useContext(vb),[p,g]=E.useState(null),[w,x]=E.useState(null),R=E.useRef(null),T=E.useRef(null),A=E.useRef(null),N=E.useRef(null);return ct(()=>{const j=v.current;if(!j||!d){g(null);return}const O=JR(j,s);if(!O){g(null);return}const q=O.isConnected;if(q||(S||IR(j)).appendChild(O),O.id||(O.id=j.id?`portal/${j.id}`:WR()),g(O),cm(f,O),!q)return()=>{O.remove(),cm(f,null)}},[d,s,S,f]),ct(()=>{if(!d||!i||!o)return;const O=yt(o).createElement("span");return O.style.position="fixed",o.insertAdjacentElement("afterend",O),x(O),()=>{O.remove(),x(null)}},[d,i,o]),E.useEffect(()=>{if(!p||!i)return;let j=0;const O=q=>{if(!$l(q))return;const B=q.type==="focusin";if(cancelAnimationFrame(j),B)return qT(p);j=requestAnimationFrame(()=>{PT(p,!0)})};return p.addEventListener("focusin",O,!0),p.addEventListener("focusout",O,!0),()=>{cancelAnimationFrame(j),p.removeEventListener("focusin",O,!0),p.removeEventListener("focusout",O,!0)}},[p,i]),h=yn(h,j=>{if(j=D.jsx(vb.Provider,{value:p||S,children:j}),!d)return j;if(!p)return D.jsx("span",{ref:y,id:h.id,style:{position:"fixed"},hidden:!0});j=D.jsxs(D.Fragment,{children:[i&&p&&D.jsx(fc,{ref:T,"data-focus-trap":h.id,className:"__focus-trap-inner-before",onFocus:q=>{$l(q,p)?Ka(Ph()):Ka(R.current)}}),j,i&&p&&D.jsx(fc,{ref:A,"data-focus-trap":h.id,className:"__focus-trap-inner-after",onFocus:q=>{$l(q,p)?Ka(nb()):Ka(N.current)}})]}),p&&(j=Hc.createPortal(j,p));let O=D.jsxs(D.Fragment,{children:[i&&p&&D.jsx(fc,{ref:R,"data-focus-trap":h.id,className:"__focus-trap-outer-before",onFocus:q=>{!(q.relatedTarget===N.current)&&$l(q,p)?Ka(T.current):Ka(nb())}}),i&&D.jsx("span",{"aria-owns":p==null?void 0:p.id,style:{position:"fixed"}}),i&&p&&D.jsx(fc,{ref:N,"data-focus-trap":h.id,className:"__focus-trap-outer-after",onFocus:q=>{if($l(q,p))Ka(A.current);else{const B=Ph();if(B===T.current){requestAnimationFrame(()=>{var V;return(V=Ph())==null?void 0:V.focus()});return}Ka(B)}}})]});return w&&i&&(O=Hc.createPortal(O,w)),D.jsxs(D.Fragment,{children:[O,j]})},[p,S,d,h.id,i,w]),h=we(oe({},h),{ref:y}),h});Xe(function(r){const a=ZS(r);return Ie(ZR,a)});var eD="div",pb=nv();function tD(t){const r=ba();return!r||t&&Lt(t,r)?!1:!!yr(r)}function yb(t,r=!1){if(!t)return null;const a="current"in t?t.current:t;return a?r?yr(a)?a:null:a:null}var IS=tt(function(r){var a=r,{store:i,open:o,onClose:s,focusable:f=!0,modal:d=!0,portal:h=!!d,backdrop:v=!!d,hideOnEscape:y=!0,hideOnInteractOutside:S=!0,getPersistentElements:p,preventBodyScroll:g=!!d,autoFocusOnShow:w=!0,autoFocusOnHide:x=!0,initialFocus:R,finalFocus:T,unmountOnHide:A,unstable_treeSnapshotKey:N}=a,j=Ge(a,["store","open","onClose","focusable","modal","portal","backdrop","hideOnEscape","hideOnInteractOutside","getPersistentElements","preventBodyScroll","autoFocusOnShow","autoFocusOnHide","initialFocus","finalFocus","unmountOnHide","unstable_treeSnapshotKey"]);const O=af(),q=E.useRef(null),B=pT({store:i||O,open:o,setOpen(be){if(be)return;const Fe=q.current;if(!Fe)return;const xt=new Event("close",{bubbles:!1,cancelable:!0});s&&Fe.addEventListener("close",s,{once:!0}),Fe.dispatchEvent(xt),xt.defaultPrevented&&B.setOpen(!0)}}),{portalRef:V,domReady:z}=iv(h,j.portalRef),X=j.preserveTabOrder,te=Pt(B,be=>X&&!d&&be.mounted),fe=Ji(j.id),Z=Pt(B,"open"),ae=Pt(B,"mounted"),ie=Pt(B,"contentElement"),U=xv(ae,j.hidden,j.alwaysVisible);UR(ie,fe,g&&!U),FR(B,S,z);const{wrapElement:I,nestedDialogs:ne}=$R(B);j=yn(j,I,[I]),ct(()=>{if(!Z)return;const be=q.current,Fe=ba(be,!0);Fe&&Fe.tagName!=="BODY"&&(be&&Lt(be,Fe)||B.setDisclosureElement(Fe))},[B,Z]),pb&&E.useEffect(()=>{if(!ae)return;const{disclosureElement:be}=B.getState();if(!be||!fi(be))return;const Fe=()=>{let xt=!1;const Le=()=>{xt=!0},Rt={capture:!0,once:!0};be.addEventListener("focusin",Le,Rt),So(be,"mouseup",()=>{be.removeEventListener("focusin",Le,!0),!xt&&NS(be)})};return be.addEventListener("mousedown",Fe),()=>{be.removeEventListener("mousedown",Fe)}},[B,ae]),E.useEffect(()=>{if(!ae||!z)return;const be=q.current;if(!be)return;const Fe=dS(be),xt=Fe.visualViewport||Fe,Le=()=>{var Rt,un;const jt=(un=(Rt=Fe.visualViewport)==null?void 0:Rt.height)!=null?un:Fe.innerHeight;be.style.setProperty("--dialog-viewport-height",`${jt}px`)};return Le(),xt.addEventListener("resize",Le),()=>{xt.removeEventListener("resize",Le)}},[ae,z]),E.useEffect(()=>{if(!d||!ae||!z)return;const be=q.current;if(!(!be||be.querySelector("[data-dialog-dismiss]")))return VR(be,B.hide)},[B,d,ae,z]),ct(()=>{if(!QS()||Z||!ae||!z)return;const be=q.current;if(be)return KS(be)},[Z,ae,z]);const K=Z&&z;ct(()=>{if(!fe||!K)return;const be=q.current;return RR(fe,[be])},[fe,K,N]);const M=Ye(p);ct(()=>{if(!fe||!K)return;const{disclosureElement:be}=B.getState(),Fe=q.current,xt=M()||[],Le=[Fe,...xt,...ne.map(Rt=>Rt.getState().contentElement)];return d?Bn(hb(fe,Le),zR(fe,Le)):hb(fe,[be,...Le])},[fe,B,K,M,ne,d,N]);const F=!!w,se=Un(w),[de,ce]=E.useState(!1);E.useEffect(()=>{if(!Z||!F||!z||!(ie!=null&&ie.isConnected))return;const be=yb(R,!0)||ie.querySelector("[data-autofocus=true],[autofocus]")||LT(ie,!0,h&&te)||ie,Fe=yr(be);se(Fe?be:null)&&(ce(!0),queueMicrotask(()=>{be.focus(),pb&&be.scrollIntoView({block:"nearest",inline:"nearest"})}))},[Z,F,z,ie,R,h,te,se]);const ge=!!x,Te=Un(x),[mt,_e]=E.useState(!1);E.useEffect(()=>{if(Z)return _e(!0),()=>_e(!1)},[Z]);const je=E.useCallback((be,Fe=!0)=>{const{disclosureElement:xt}=B.getState();if(tD(be))return;let Le=yb(T)||xt;if(Le!=null&&Le.id){const un=yt(Le),jt=`[aria-activedescendant="${Le.id}"]`,on=un.querySelector(jt);on&&(Le=on)}if(Le&&!yr(Le)){const un=Le.closest("[data-dialog]");if(un!=null&&un.id){const jt=yt(un),on=`[aria-controls~="${un.id}"]`,sn=jt.querySelector(on);sn&&(Le=sn)}}const Rt=Le&&yr(Le);if(!Rt&&Fe){requestAnimationFrame(()=>je(be,!1));return}Te(Rt?Le:null)&&Rt&&(Le==null||Le.focus())},[B,T,Te]),Ne=E.useRef(!1);ct(()=>{if(Z||!mt||!ge)return;const be=q.current;Ne.current=!0,je(be)},[Z,mt,z,ge,je]),E.useEffect(()=>{if(!mt||!ge)return;const be=q.current;return()=>{if(Ne.current){Ne.current=!1;return}je(be)}},[mt,ge,je]);const Mt=Un(y);E.useEffect(()=>!z||!ae?void 0:Zt("keydown",Fe=>{if(Fe.key!=="Escape"||Fe.defaultPrevented)return;const xt=q.current;if(!xt||Cv(xt))return;const Le=Fe.target;if(!Le)return;const{disclosureElement:Rt}=B.getState();!!(Le.tagName==="BODY"||Lt(xt,Le)||!Rt||Lt(Rt,Le))&&Mt(Fe)&&B.hide()},!0),[B,z,ae,Mt]),j=yn(j,be=>D.jsx(QR,{level:d?1:void 0,children:be}),[d]);const bn=j.hidden,ft=j.alwaysVisible;j=yn(j,be=>v?D.jsxs(D.Fragment,{children:[D.jsx(jR,{store:B,backdrop:v,hidden:bn,alwaysVisible:ft}),be]}):be,[B,v,bn,ft]);const[ln,Cn]=E.useState(),[en,Pn]=E.useState();return j=yn(j,be=>D.jsx(pv,{value:B,children:D.jsx(AS.Provider,{value:Cn,children:D.jsx(wT.Provider,{value:Pn,children:be})})}),[B]),j=we(oe({id:fe,"data-dialog":"",role:"dialog",tabIndex:f?-1:void 0,"aria-labelledby":ln,"aria-describedby":en},j),{ref:Ht(q,j.ref)}),j=GS(we(oe({},j),{autoFocusOnShow:de})),j=Ev(oe({store:B},j)),j=$o(we(oe({},j),{focusable:f})),j=ZS(we(oe({portal:h},j),{portalRef:V,preserveTabOrder:te})),j});function cf(t,r=af){return Xe(function(i){const o=r(),s=i.store||o;return Pt(s,d=>!i.unmountOnHide||(d==null?void 0:d.mounted)||!!i.open)?D.jsx(t,oe({},i)):null})}var nD=cf(Xe(function(r){const a=IS(r);return Ie(eD,a)}),af);const di=Math.min,Ln=Math.max,$c=Math.round,dc=Math.floor,Lr=t=>({x:t,y:t}),rD={left:"right",right:"left",bottom:"top",top:"bottom"},aD={start:"end",end:"start"};function bm(t,r,a){return Ln(t,di(r,a))}function hi(t,r){return typeof t=="function"?t(r):t}function ya(t){return t.split("-")[0]}function uu(t){return t.split("-")[1]}function Tv(t){return t==="x"?"y":"x"}function Rv(t){return t==="y"?"height":"width"}function mi(t){return["top","bottom"].includes(ya(t))?"y":"x"}function Dv(t){return Tv(mi(t))}function iD(t,r,a){a===void 0&&(a=!1);const i=uu(t),o=Dv(t),s=Rv(o);let f=o==="x"?i===(a?"end":"start")?"right":"left":i==="start"?"bottom":"top";return r.reference[s]>r.floating[s]&&(f=Bc(f)),[f,Bc(f)]}function lD(t){const r=Bc(t);return[Sm(t),r,Sm(r)]}function Sm(t){return t.replace(/start|end/g,r=>aD[r])}function uD(t,r,a){const i=["left","right"],o=["right","left"],s=["top","bottom"],f=["bottom","top"];switch(t){case"top":case"bottom":return a?r?o:i:r?i:o;case"left":case"right":return r?s:f;default:return[]}}function oD(t,r,a,i){const o=uu(t);let s=uD(ya(t),a==="start",i);return o&&(s=s.map(f=>f+"-"+o),r&&(s=s.concat(s.map(Sm)))),s}function Bc(t){return t.replace(/left|right|bottom|top/g,r=>rD[r])}function sD(t){return{top:0,right:0,bottom:0,left:0,...t}}function JS(t){return typeof t!="number"?sD(t):{top:t,right:t,bottom:t,left:t}}function Pc(t){const{x:r,y:a,width:i,height:o}=t;return{width:i,height:o,top:a,left:r,right:r+i,bottom:a+o,x:r,y:a}}function gb(t,r,a){let{reference:i,floating:o}=t;const s=mi(r),f=Dv(r),d=Rv(f),h=ya(r),v=s==="y",y=i.x+i.width/2-o.width/2,S=i.y+i.height/2-o.height/2,p=i[d]/2-o[d]/2;let g;switch(h){case"top":g={x:y,y:i.y-o.height};break;case"bottom":g={x:y,y:i.y+i.height};break;case"right":g={x:i.x+i.width,y:S};break;case"left":g={x:i.x-o.width,y:S};break;default:g={x:i.x,y:i.y}}switch(uu(r)){case"start":g[f]-=p*(a&&v?-1:1);break;case"end":g[f]+=p*(a&&v?-1:1);break}return g}const cD=async(t,r,a)=>{const{placement:i="bottom",strategy:o="absolute",middleware:s=[],platform:f}=a,d=s.filter(Boolean),h=await(f.isRTL==null?void 0:f.isRTL(r));let v=await f.getElementRects({reference:t,floating:r,strategy:o}),{x:y,y:S}=gb(v,i,h),p=i,g={},w=0;for(let x=0;x<d.length;x++){const{name:R,fn:T}=d[x],{x:A,y:N,data:j,reset:O}=await T({x:y,y:S,initialPlacement:i,placement:p,strategy:o,middlewareData:g,rects:v,platform:f,elements:{reference:t,floating:r}});y=A??y,S=N??S,g={...g,[R]:{...g[R],...j}},O&&w<=50&&(w++,typeof O=="object"&&(O.placement&&(p=O.placement),O.rects&&(v=O.rects===!0?await f.getElementRects({reference:t,floating:r,strategy:o}):O.rects),{x:y,y:S}=gb(v,p,h)),x=-1)}return{x:y,y:S,placement:p,strategy:o,middlewareData:g}};async function Av(t,r){var a;r===void 0&&(r={});const{x:i,y:o,platform:s,rects:f,elements:d,strategy:h}=t,{boundary:v="clippingAncestors",rootBoundary:y="viewport",elementContext:S="floating",altBoundary:p=!1,padding:g=0}=hi(r,t),w=JS(g),R=d[p?S==="floating"?"reference":"floating":S],T=Pc(await s.getClippingRect({element:(a=await(s.isElement==null?void 0:s.isElement(R)))==null||a?R:R.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(d.floating)),boundary:v,rootBoundary:y,strategy:h})),A=S==="floating"?{x:i,y:o,width:f.floating.width,height:f.floating.height}:f.reference,N=await(s.getOffsetParent==null?void 0:s.getOffsetParent(d.floating)),j=await(s.isElement==null?void 0:s.isElement(N))?await(s.getScale==null?void 0:s.getScale(N))||{x:1,y:1}:{x:1,y:1},O=Pc(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:d,rect:A,offsetParent:N,strategy:h}):A);return{top:(T.top-O.top+w.top)/j.y,bottom:(O.bottom-T.bottom+w.bottom)/j.y,left:(T.left-O.left+w.left)/j.x,right:(O.right-T.right+w.right)/j.x}}const fD=t=>({name:"arrow",options:t,async fn(r){const{x:a,y:i,placement:o,rects:s,platform:f,elements:d,middlewareData:h}=r,{element:v,padding:y=0}=hi(t,r)||{};if(v==null)return{};const S=JS(y),p={x:a,y:i},g=Dv(o),w=Rv(g),x=await f.getDimensions(v),R=g==="y",T=R?"top":"left",A=R?"bottom":"right",N=R?"clientHeight":"clientWidth",j=s.reference[w]+s.reference[g]-p[g]-s.floating[w],O=p[g]-s.reference[g],q=await(f.getOffsetParent==null?void 0:f.getOffsetParent(v));let B=q?q[N]:0;(!B||!await(f.isElement==null?void 0:f.isElement(q)))&&(B=d.floating[N]||s.floating[w]);const V=j/2-O/2,z=B/2-x[w]/2-1,X=di(S[T],z),te=di(S[A],z),fe=X,Z=B-x[w]-te,ae=B/2-x[w]/2+V,ie=bm(fe,ae,Z),U=!h.arrow&&uu(o)!=null&&ae!==ie&&s.reference[w]/2-(ae<fe?X:te)-x[w]/2<0,I=U?ae<fe?ae-fe:ae-Z:0;return{[g]:p[g]+I,data:{[g]:ie,centerOffset:ae-ie-I,...U&&{alignmentOffset:I}},reset:U}}}),dD=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(r){var a,i;const{placement:o,middlewareData:s,rects:f,initialPlacement:d,platform:h,elements:v}=r,{mainAxis:y=!0,crossAxis:S=!0,fallbackPlacements:p,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:w="none",flipAlignment:x=!0,...R}=hi(t,r);if((a=s.arrow)!=null&&a.alignmentOffset)return{};const T=ya(o),A=mi(d),N=ya(d)===d,j=await(h.isRTL==null?void 0:h.isRTL(v.floating)),O=p||(N||!x?[Bc(d)]:lD(d)),q=w!=="none";!p&&q&&O.push(...oD(d,x,w,j));const B=[d,...O],V=await Av(r,R),z=[];let X=((i=s.flip)==null?void 0:i.overflows)||[];if(y&&z.push(V[T]),S){const ae=iD(o,f,j);z.push(V[ae[0]],V[ae[1]])}if(X=[...X,{placement:o,overflows:z}],!z.every(ae=>ae<=0)){var te,fe;const ae=(((te=s.flip)==null?void 0:te.index)||0)+1,ie=B[ae];if(ie)return{data:{index:ae,overflows:X},reset:{placement:ie}};let U=(fe=X.filter(I=>I.overflows[0]<=0).sort((I,ne)=>I.overflows[1]-ne.overflows[1])[0])==null?void 0:fe.placement;if(!U)switch(g){case"bestFit":{var Z;const I=(Z=X.filter(ne=>{if(q){const K=mi(ne.placement);return K===A||K==="y"}return!0}).map(ne=>[ne.placement,ne.overflows.filter(K=>K>0).reduce((K,M)=>K+M,0)]).sort((ne,K)=>ne[1]-K[1])[0])==null?void 0:Z[0];I&&(U=I);break}case"initialPlacement":U=d;break}if(o!==U)return{reset:{placement:U}}}return{}}}};async function hD(t,r){const{placement:a,platform:i,elements:o}=t,s=await(i.isRTL==null?void 0:i.isRTL(o.floating)),f=ya(a),d=uu(a),h=mi(a)==="y",v=["left","top"].includes(f)?-1:1,y=s&&h?-1:1,S=hi(r,t);let{mainAxis:p,crossAxis:g,alignmentAxis:w}=typeof S=="number"?{mainAxis:S,crossAxis:0,alignmentAxis:null}:{mainAxis:S.mainAxis||0,crossAxis:S.crossAxis||0,alignmentAxis:S.alignmentAxis};return d&&typeof w=="number"&&(g=d==="end"?w*-1:w),h?{x:g*y,y:p*v}:{x:p*v,y:g*y}}const mD=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(r){var a,i;const{x:o,y:s,placement:f,middlewareData:d}=r,h=await hD(r,t);return f===((a=d.offset)==null?void 0:a.placement)&&(i=d.arrow)!=null&&i.alignmentOffset?{}:{x:o+h.x,y:s+h.y,data:{...h,placement:f}}}}},vD=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(r){const{x:a,y:i,placement:o}=r,{mainAxis:s=!0,crossAxis:f=!1,limiter:d={fn:R=>{let{x:T,y:A}=R;return{x:T,y:A}}},...h}=hi(t,r),v={x:a,y:i},y=await Av(r,h),S=mi(ya(o)),p=Tv(S);let g=v[p],w=v[S];if(s){const R=p==="y"?"top":"left",T=p==="y"?"bottom":"right",A=g+y[R],N=g-y[T];g=bm(A,g,N)}if(f){const R=S==="y"?"top":"left",T=S==="y"?"bottom":"right",A=w+y[R],N=w-y[T];w=bm(A,w,N)}const x=d.fn({...r,[p]:g,[S]:w});return{...x,data:{x:x.x-a,y:x.y-i,enabled:{[p]:s,[S]:f}}}}}},pD=function(t){return t===void 0&&(t={}),{options:t,fn(r){const{x:a,y:i,placement:o,rects:s,middlewareData:f}=r,{offset:d=0,mainAxis:h=!0,crossAxis:v=!0}=hi(t,r),y={x:a,y:i},S=mi(o),p=Tv(S);let g=y[p],w=y[S];const x=hi(d,r),R=typeof x=="number"?{mainAxis:x,crossAxis:0}:{mainAxis:0,crossAxis:0,...x};if(h){const N=p==="y"?"height":"width",j=s.reference[p]-s.floating[N]+R.mainAxis,O=s.reference[p]+s.reference[N]-R.mainAxis;g<j?g=j:g>O&&(g=O)}if(v){var T,A;const N=p==="y"?"width":"height",j=["top","left"].includes(ya(o)),O=s.reference[S]-s.floating[N]+(j&&((T=f.offset)==null?void 0:T[S])||0)+(j?0:R.crossAxis),q=s.reference[S]+s.reference[N]+(j?0:((A=f.offset)==null?void 0:A[S])||0)-(j?R.crossAxis:0);w<O?w=O:w>q&&(w=q)}return{[p]:g,[S]:w}}}},yD=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(r){var a,i;const{placement:o,rects:s,platform:f,elements:d}=r,{apply:h=()=>{},...v}=hi(t,r),y=await Av(r,v),S=ya(o),p=uu(o),g=mi(o)==="y",{width:w,height:x}=s.floating;let R,T;S==="top"||S==="bottom"?(R=S,T=p===(await(f.isRTL==null?void 0:f.isRTL(d.floating))?"start":"end")?"left":"right"):(T=S,R=p==="end"?"top":"bottom");const A=x-y.top-y.bottom,N=w-y.left-y.right,j=di(x-y[R],A),O=di(w-y[T],N),q=!r.middlewareData.shift;let B=j,V=O;if((a=r.middlewareData.shift)!=null&&a.enabled.x&&(V=N),(i=r.middlewareData.shift)!=null&&i.enabled.y&&(B=A),q&&!p){const X=Ln(y.left,0),te=Ln(y.right,0),fe=Ln(y.top,0),Z=Ln(y.bottom,0);g?V=w-2*(X!==0||te!==0?X+te:Ln(y.left,y.right)):B=x-2*(fe!==0||Z!==0?fe+Z:Ln(y.top,y.bottom))}await h({...r,availableWidth:V,availableHeight:B});const z=await f.getDimensions(d.floating);return w!==z.width||x!==z.height?{reset:{rects:!0}}:{}}}};function ff(){return typeof window<"u"}function ou(t){return WS(t)?(t.nodeName||"").toLowerCase():"#document"}function $n(t){var r;return(t==null||(r=t.ownerDocument)==null?void 0:r.defaultView)||window}function qr(t){var r;return(r=(WS(t)?t.ownerDocument:t.document)||window.document)==null?void 0:r.documentElement}function WS(t){return ff()?t instanceof Node||t instanceof $n(t).Node:!1}function gr(t){return ff()?t instanceof Element||t instanceof $n(t).Element:!1}function Br(t){return ff()?t instanceof HTMLElement||t instanceof $n(t).HTMLElement:!1}function bb(t){return!ff()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof $n(t).ShadowRoot}function Po(t){const{overflow:r,overflowX:a,overflowY:i,display:o}=br(t);return/auto|scroll|overlay|hidden|clip/.test(r+i+a)&&!["inline","contents"].includes(o)}function gD(t){return["table","td","th"].includes(ou(t))}function df(t){return[":popover-open",":modal"].some(r=>{try{return t.matches(r)}catch{return!1}})}function Mv(t){const r=jv(),a=gr(t)?br(t):t;return a.transform!=="none"||a.perspective!=="none"||(a.containerType?a.containerType!=="normal":!1)||!r&&(a.backdropFilter?a.backdropFilter!=="none":!1)||!r&&(a.filter?a.filter!=="none":!1)||["transform","perspective","filter"].some(i=>(a.willChange||"").includes(i))||["paint","layout","strict","content"].some(i=>(a.contain||"").includes(i))}function bD(t){let r=vi(t);for(;Br(r)&&!ru(r);){if(Mv(r))return r;if(df(r))return null;r=vi(r)}return null}function jv(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ru(t){return["html","body","#document"].includes(ou(t))}function br(t){return $n(t).getComputedStyle(t)}function hf(t){return gr(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function vi(t){if(ou(t)==="html")return t;const r=t.assignedSlot||t.parentNode||bb(t)&&t.host||qr(t);return bb(r)?r.host:r}function ex(t){const r=vi(t);return ru(r)?t.ownerDocument?t.ownerDocument.body:t.body:Br(r)&&Po(r)?r:ex(r)}function Oo(t,r,a){var i;r===void 0&&(r=[]),a===void 0&&(a=!0);const o=ex(t),s=o===((i=t.ownerDocument)==null?void 0:i.body),f=$n(o);if(s){const d=xm(f);return r.concat(f,f.visualViewport||[],Po(o)?o:[],d&&a?Oo(d):[])}return r.concat(o,Oo(o,[],a))}function xm(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function tx(t){const r=br(t);let a=parseFloat(r.width)||0,i=parseFloat(r.height)||0;const o=Br(t),s=o?t.offsetWidth:a,f=o?t.offsetHeight:i,d=$c(a)!==s||$c(i)!==f;return d&&(a=s,i=f),{width:a,height:i,$:d}}function _v(t){return gr(t)?t:t.contextElement}function ql(t){const r=_v(t);if(!Br(r))return Lr(1);const a=r.getBoundingClientRect(),{width:i,height:o,$:s}=tx(r);let f=(s?$c(a.width):a.width)/i,d=(s?$c(a.height):a.height)/o;return(!f||!Number.isFinite(f))&&(f=1),(!d||!Number.isFinite(d))&&(d=1),{x:f,y:d}}const SD=Lr(0);function nx(t){const r=$n(t);return!jv()||!r.visualViewport?SD:{x:r.visualViewport.offsetLeft,y:r.visualViewport.offsetTop}}function xD(t,r,a){return r===void 0&&(r=!1),!a||r&&a!==$n(t)?!1:r}function Xi(t,r,a,i){r===void 0&&(r=!1),a===void 0&&(a=!1);const o=t.getBoundingClientRect(),s=_v(t);let f=Lr(1);r&&(i?gr(i)&&(f=ql(i)):f=ql(t));const d=xD(s,a,i)?nx(s):Lr(0);let h=(o.left+d.x)/f.x,v=(o.top+d.y)/f.y,y=o.width/f.x,S=o.height/f.y;if(s){const p=$n(s),g=i&&gr(i)?$n(i):i;let w=p,x=xm(w);for(;x&&i&&g!==w;){const R=ql(x),T=x.getBoundingClientRect(),A=br(x),N=T.left+(x.clientLeft+parseFloat(A.paddingLeft))*R.x,j=T.top+(x.clientTop+parseFloat(A.paddingTop))*R.y;h*=R.x,v*=R.y,y*=R.x,S*=R.y,h+=N,v+=j,w=$n(x),x=xm(w)}}return Pc({width:y,height:S,x:h,y:v})}function Nv(t,r){const a=hf(t).scrollLeft;return r?r.left+a:Xi(qr(t)).left+a}function rx(t,r,a){a===void 0&&(a=!1);const i=t.getBoundingClientRect(),o=i.left+r.scrollLeft-(a?0:Nv(t,i)),s=i.top+r.scrollTop;return{x:o,y:s}}function ED(t){let{elements:r,rect:a,offsetParent:i,strategy:o}=t;const s=o==="fixed",f=qr(i),d=r?df(r.floating):!1;if(i===f||d&&s)return a;let h={scrollLeft:0,scrollTop:0},v=Lr(1);const y=Lr(0),S=Br(i);if((S||!S&&!s)&&((ou(i)!=="body"||Po(f))&&(h=hf(i)),Br(i))){const g=Xi(i);v=ql(i),y.x=g.x+i.clientLeft,y.y=g.y+i.clientTop}const p=f&&!S&&!s?rx(f,h,!0):Lr(0);return{width:a.width*v.x,height:a.height*v.y,x:a.x*v.x-h.scrollLeft*v.x+y.x+p.x,y:a.y*v.y-h.scrollTop*v.y+y.y+p.y}}function wD(t){return Array.from(t.getClientRects())}function OD(t){const r=qr(t),a=hf(t),i=t.ownerDocument.body,o=Ln(r.scrollWidth,r.clientWidth,i.scrollWidth,i.clientWidth),s=Ln(r.scrollHeight,r.clientHeight,i.scrollHeight,i.clientHeight);let f=-a.scrollLeft+Nv(t);const d=-a.scrollTop;return br(i).direction==="rtl"&&(f+=Ln(r.clientWidth,i.clientWidth)-o),{width:o,height:s,x:f,y:d}}function CD(t,r){const a=$n(t),i=qr(t),o=a.visualViewport;let s=i.clientWidth,f=i.clientHeight,d=0,h=0;if(o){s=o.width,f=o.height;const v=jv();(!v||v&&r==="fixed")&&(d=o.offsetLeft,h=o.offsetTop)}return{width:s,height:f,x:d,y:h}}function TD(t,r){const a=Xi(t,!0,r==="fixed"),i=a.top+t.clientTop,o=a.left+t.clientLeft,s=Br(t)?ql(t):Lr(1),f=t.clientWidth*s.x,d=t.clientHeight*s.y,h=o*s.x,v=i*s.y;return{width:f,height:d,x:h,y:v}}function Sb(t,r,a){let i;if(r==="viewport")i=CD(t,a);else if(r==="document")i=OD(qr(t));else if(gr(r))i=TD(r,a);else{const o=nx(t);i={x:r.x-o.x,y:r.y-o.y,width:r.width,height:r.height}}return Pc(i)}function ax(t,r){const a=vi(t);return a===r||!gr(a)||ru(a)?!1:br(a).position==="fixed"||ax(a,r)}function RD(t,r){const a=r.get(t);if(a)return a;let i=Oo(t,[],!1).filter(d=>gr(d)&&ou(d)!=="body"),o=null;const s=br(t).position==="fixed";let f=s?vi(t):t;for(;gr(f)&&!ru(f);){const d=br(f),h=Mv(f);!h&&d.position==="fixed"&&(o=null),(s?!h&&!o:!h&&d.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Po(f)&&!h&&ax(t,f))?i=i.filter(y=>y!==f):o=d,f=vi(f)}return r.set(t,i),i}function DD(t){let{element:r,boundary:a,rootBoundary:i,strategy:o}=t;const f=[...a==="clippingAncestors"?df(r)?[]:RD(r,this._c):[].concat(a),i],d=f[0],h=f.reduce((v,y)=>{const S=Sb(r,y,o);return v.top=Ln(S.top,v.top),v.right=di(S.right,v.right),v.bottom=di(S.bottom,v.bottom),v.left=Ln(S.left,v.left),v},Sb(r,d,o));return{width:h.right-h.left,height:h.bottom-h.top,x:h.left,y:h.top}}function AD(t){const{width:r,height:a}=tx(t);return{width:r,height:a}}function MD(t,r,a){const i=Br(r),o=qr(r),s=a==="fixed",f=Xi(t,!0,s,r);let d={scrollLeft:0,scrollTop:0};const h=Lr(0);if(i||!i&&!s)if((ou(r)!=="body"||Po(o))&&(d=hf(r)),i){const p=Xi(r,!0,s,r);h.x=p.x+r.clientLeft,h.y=p.y+r.clientTop}else o&&(h.x=Nv(o));const v=o&&!i&&!s?rx(o,d):Lr(0),y=f.left+d.scrollLeft-h.x-v.x,S=f.top+d.scrollTop-h.y-v.y;return{x:y,y:S,width:f.width,height:f.height}}function Qh(t){return br(t).position==="static"}function xb(t,r){if(!Br(t)||br(t).position==="fixed")return null;if(r)return r(t);let a=t.offsetParent;return qr(t)===a&&(a=a.ownerDocument.body),a}function ix(t,r){const a=$n(t);if(df(t))return a;if(!Br(t)){let o=vi(t);for(;o&&!ru(o);){if(gr(o)&&!Qh(o))return o;o=vi(o)}return a}let i=xb(t,r);for(;i&&gD(i)&&Qh(i);)i=xb(i,r);return i&&ru(i)&&Qh(i)&&!Mv(i)?a:i||bD(t)||a}const jD=async function(t){const r=this.getOffsetParent||ix,a=this.getDimensions,i=await a(t.floating);return{reference:MD(t.reference,await r(t.floating),t.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}};function _D(t){return br(t).direction==="rtl"}const ND={convertOffsetParentRelativeRectToViewportRelativeRect:ED,getDocumentElement:qr,getClippingRect:DD,getOffsetParent:ix,getElementRects:jD,getClientRects:wD,getDimensions:AD,getScale:ql,isElement:gr,isRTL:_D};function zD(t,r){let a=null,i;const o=qr(t);function s(){var d;clearTimeout(i),(d=a)==null||d.disconnect(),a=null}function f(d,h){d===void 0&&(d=!1),h===void 0&&(h=1),s();const{left:v,top:y,width:S,height:p}=t.getBoundingClientRect();if(d||r(),!S||!p)return;const g=dc(y),w=dc(o.clientWidth-(v+S)),x=dc(o.clientHeight-(y+p)),R=dc(v),A={rootMargin:-g+"px "+-w+"px "+-x+"px "+-R+"px",threshold:Ln(0,di(1,h))||1};let N=!0;function j(O){const q=O[0].intersectionRatio;if(q!==h){if(!N)return f();q?f(!1,q):i=setTimeout(()=>{f(!1,1e-7)},1e3)}N=!1}try{a=new IntersectionObserver(j,{...A,root:o.ownerDocument})}catch{a=new IntersectionObserver(j,A)}a.observe(t)}return f(!0),s}function LD(t,r,a,i){i===void 0&&(i={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:f=typeof ResizeObserver=="function",layoutShift:d=typeof IntersectionObserver=="function",animationFrame:h=!1}=i,v=_v(t),y=o||s?[...v?Oo(v):[],...Oo(r)]:[];y.forEach(T=>{o&&T.addEventListener("scroll",a,{passive:!0}),s&&T.addEventListener("resize",a)});const S=v&&d?zD(v,a):null;let p=-1,g=null;f&&(g=new ResizeObserver(T=>{let[A]=T;A&&A.target===v&&g&&(g.unobserve(r),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var N;(N=g)==null||N.observe(r)})),a()}),v&&!h&&g.observe(v),g.observe(r));let w,x=h?Xi(t):null;h&&R();function R(){const T=Xi(t);x&&(T.x!==x.x||T.y!==x.y||T.width!==x.width||T.height!==x.height)&&a(),x=T,w=requestAnimationFrame(R)}return a(),()=>{var T;y.forEach(A=>{o&&A.removeEventListener("scroll",a),s&&A.removeEventListener("resize",a)}),S==null||S(),(T=g)==null||T.disconnect(),g=null,h&&cancelAnimationFrame(w)}}const HD=mD,UD=vD,$D=dD,BD=yD,PD=fD,qD=pD,kD=(t,r,a)=>{const i=new Map,o={platform:ND,...a},s={...o.platform,_c:i};return cD(t,r,{...o,platform:s})};var FD="div";function Eb(t=0,r=0,a=0,i=0){if(typeof DOMRect=="function")return new DOMRect(t,r,a,i);const o={x:t,y:r,width:a,height:i,top:r,right:t+a,bottom:r+i,left:t};return we(oe({},o),{toJSON:()=>o})}function VD(t){if(!t)return Eb();const{x:r,y:a,width:i,height:o}=t;return Eb(r,a,i,o)}function YD(t,r){return{contextElement:t||void 0,getBoundingClientRect:()=>{const i=t,o=r==null?void 0:r(i);return o||!i?VD(o):i.getBoundingClientRect()}}}function QD(t){return/^(?:top|bottom|left|right)(?:-(?:start|end))?$/.test(t)}function wb(t){const r=window.devicePixelRatio||1;return Math.round(t*r)/r}function KD(t,r){return HD(({placement:a})=>{var i;const o=((t==null?void 0:t.clientHeight)||0)/2,s=typeof r.gutter=="number"?r.gutter+o:(i=r.gutter)!=null?i:o;return{crossAxis:!!a.split("-")[1]?void 0:r.shift,mainAxis:s,alignmentAxis:r.shift}})}function GD(t){if(t.flip===!1)return;const r=typeof t.flip=="string"?t.flip.split(" "):void 0;return Wt(!r||r.every(QD),!1),$D({padding:t.overflowPadding,fallbackPlacements:r})}function XD(t){if(!(!t.slide&&!t.overlap))return UD({mainAxis:t.slide,crossAxis:t.overlap,padding:t.overflowPadding,limiter:qD()})}function ZD(t){return BD({padding:t.overflowPadding,apply({elements:r,availableWidth:a,availableHeight:i,rects:o}){const s=r.floating,f=Math.round(o.reference.width);a=Math.floor(a),i=Math.floor(i),s.style.setProperty("--popover-anchor-width",`${f}px`),s.style.setProperty("--popover-available-width",`${a}px`),s.style.setProperty("--popover-available-height",`${i}px`),t.sameWidth&&(s.style.width=`${f}px`),t.fitViewport&&(s.style.maxWidth=`${a}px`,s.style.maxHeight=`${i}px`)}})}function ID(t,r){if(t)return PD({element:t,padding:r.arrowPadding})}var lx=tt(function(r){var a=r,{store:i,modal:o=!1,portal:s=!!o,preserveTabOrder:f=!0,autoFocusOnShow:d=!0,wrapperProps:h,fixed:v=!1,flip:y=!0,shift:S=0,slide:p=!0,overlap:g=!1,sameWidth:w=!1,fitViewport:x=!1,gutter:R,arrowPadding:T=4,overflowPadding:A=8,getAnchorRect:N,updatePosition:j}=a,O=Ge(a,["store","modal","portal","preserveTabOrder","autoFocusOnShow","wrapperProps","fixed","flip","shift","slide","overlap","sameWidth","fitViewport","gutter","arrowPadding","overflowPadding","getAnchorRect","updatePosition"]);const q=lf();i=i||q,Wt(i,!1);const B=i.useState("arrowElement"),V=i.useState("anchorElement"),z=i.useState("disclosureElement"),X=i.useState("popoverElement"),te=i.useState("contentElement"),fe=i.useState("placement"),Z=i.useState("mounted"),ae=i.useState("rendered"),ie=E.useRef(null),[U,I]=E.useState(!1),{portalRef:ne,domReady:K}=iv(s,O.portalRef),M=Ye(N),F=Ye(j),se=!!j;ct(()=>{if(!(X!=null&&X.isConnected))return;X.style.setProperty("--popover-overflow-padding",`${A}px`);const ce=YD(V,M),ge=async()=>{if(!Z)return;B||(ie.current=ie.current||document.createElement("div"));const _e=B||ie.current,je=[KD(_e,{gutter:R,shift:S}),GD({flip:y,overflowPadding:A}),XD({slide:p,shift:S,overlap:g,overflowPadding:A}),ID(_e,{arrowPadding:T}),ZD({sameWidth:w,fitViewport:x,overflowPadding:A})],Ne=await kD(ce,X,{placement:fe,strategy:v?"fixed":"absolute",middleware:je});i==null||i.setState("currentPlacement",Ne.placement),I(!0);const Mt=wb(Ne.x),bn=wb(Ne.y);if(Object.assign(X.style,{top:"0",left:"0",transform:`translate3d(${Mt}px,${bn}px,0)`}),_e&&Ne.middlewareData.arrow){const{x:ft,y:ln}=Ne.middlewareData.arrow,Cn=Ne.placement.split("-")[0],en=_e.clientWidth/2,Pn=_e.clientHeight/2,be=ft!=null?ft+en:-en,Fe=ln!=null?ln+Pn:-Pn;X.style.setProperty("--popover-transform-origin",{top:`${be}px calc(100% + ${Pn}px)`,bottom:`${be}px ${-Pn}px`,left:`calc(100% + ${en}px) ${Fe}px`,right:`${-en}px ${Fe}px`}[Cn]),Object.assign(_e.style,{left:ft!=null?`${ft}px`:"",top:ln!=null?`${ln}px`:"",[Cn]:"100%"})}},mt=LD(ce,X,async()=>{se?(await F({updatePosition:ge}),I(!0)):await ge()},{elementResize:typeof ResizeObserver=="function"});return()=>{I(!1),mt()}},[i,ae,X,B,V,X,fe,Z,K,v,y,S,p,g,w,x,R,T,A,M,se,F]),ct(()=>{if(!Z||!K||!(X!=null&&X.isConnected)||!(te!=null&&te.isConnected))return;const ce=()=>{X.style.zIndex=getComputedStyle(te).zIndex};ce();let ge=requestAnimationFrame(()=>{ge=requestAnimationFrame(ce)});return()=>cancelAnimationFrame(ge)},[Z,K,X,te]);const de=v?"fixed":"absolute";return O=yn(O,ce=>D.jsx("div",we(oe({},h),{style:oe({position:de,top:0,left:0,width:"max-content"},h==null?void 0:h.style),ref:i==null?void 0:i.setPopoverElement,children:ce})),[i,de,h]),O=yn(O,ce=>D.jsx(uf,{value:i,children:ce}),[i]),O=we(oe({"data-placing":!U||void 0},O),{style:oe({position:"relative"},O.style)}),O=IS(we(oe({store:i,modal:o,portal:s,preserveTabOrder:f,preserveTabOrderAnchor:z||V,autoFocusOnShow:U&&d},O),{portalRef:ne})),O});cf(Xe(function(r){const a=lx(r);return Ie(FD,a)}),lf);var JD="hr",ux=tt(function(r){var a=r,{orientation:i="horizontal"}=a,o=Ge(a,["orientation"]);return o=oe({role:"separator","aria-orientation":i},o),o});Xe(function(r){const a=ux(r);return Ie(JD,a)});var WD="hr",ox=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=tf();i=i||s,Wt(i,!1);const f=i.useState(d=>d.orientation==="horizontal"?"vertical":"horizontal");return o=ux(we(oe({},o),{orientation:f})),o});Xe(function(r){const a=ox(r);return Ie(WD,a)});var eA="button",tA=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=xT();i=i||s;const f=o.onClick,d=Ye(v=>{f==null||f(v),!v.defaultPrevented&&(i==null||i.hide())}),h=E.useMemo(()=>D.jsxs("svg",{"aria-label":"Dismiss popup",display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",children:[D.jsx("line",{x1:"4",y1:"4",x2:"12",y2:"12"}),D.jsx("line",{x1:"4",y1:"12",x2:"12",y2:"4"})]}),[]);return o=we(oe({"data-dialog-dismiss":"",children:h},o),{onClick:d}),o=Sv(o),o}),nA=Xe(function(r){const a=tA(r);return Ie(eA,a)}),rA="h1",sx=tt(function(r){const a=E.useRef(null),i=E.useContext(gm)||1,o=`h${i}`,s=av(a,o),f=E.useMemo(()=>!!s&&/^h\d$/.test(s),[s]);return r=we(oe({render:D.jsx(o,{}),role:f?void 0:"heading","aria-level":f?void 0:i},r),{ref:Ht(a,r.ref)}),r});Xe(function(r){const a=sx(r);return Ie(rA,a)});var aA="h1",iA=tt(function(r){var a=r,i=Ge(a,["store"]);const o=E.useContext(AS),s=Ji(i.id);return ct(()=>(o==null||o(s),()=>o==null?void 0:o(void 0)),[o,s]),i=oe({id:s},i),i=sx(i),i}),lA=Xe(function(r){const a=iA(r);return Ie(aA,a)}),uA="div",da="";function Kh(){da=""}function oA(t){const r=t.target;return r&&Sa(r)?!1:t.key===" "&&da.length?!0:t.key.length===1&&!t.ctrlKey&&!t.altKey&&!t.metaKey&&/^[\p{Letter}\p{Number}]$/u.test(t.key)}function sA(t,r){if(Hn(t))return!0;const a=t.target;return a?r.some(o=>o.element===a):!1}function cA(t){return t.filter(r=>!r.disabled)}function xc(t,r){var a;const i=((a=t.element)==null?void 0:a.textContent)||t.children||"value"in t&&t.value;return i?EC(i).trim().toLowerCase().startsWith(r.toLowerCase()):!1}function fA(t,r,a){if(!a)return t;const i=t.find(o=>o.id===a);return!i||!xc(i,r)||da!==r&&xc(i,da)?t:(da=r,DT(t.filter(o=>xc(o,da)),a).filter(o=>o.id!==a))}var zv=tt(function(r){var a=r,{store:i,typeahead:o=!0}=a,s=Ge(a,["store","typeahead"]);const f=tf();i=i||f,Wt(i,!1);const d=s.onKeyDownCapture,h=E.useRef(0),v=Ye(y=>{if(d==null||d(y),y.defaultPrevented||!o||!i)return;if(!oA(y))return Kh();const{renderedItems:S,items:p,activeId:g,id:w}=i.getState();let x=cA(p.length>S.length?p:S);const R=yt(y.currentTarget),T=`[data-offscreen-id="${w}"]`,A=R.querySelectorAll(T);for(const O of A){const q=O.ariaDisabled==="true"||"disabled"in O&&!!O.disabled;x.push({id:O.id,element:O,disabled:q})}if(A.length&&(x=pS(x,O=>O.element)),!sA(y,x))return Kh();y.preventDefault(),window.clearTimeout(h.current),h.current=window.setTimeout(()=>{da=""},500);const N=y.key.toLowerCase();da+=N,x=fA(x,N,g);const j=x.find(O=>xc(O,da));j?i.move(j.id):Kh()});return s=we(oe({},s),{onKeyDownCapture:v}),iu(s)});Xe(function(r){const a=zv(r);return Ie(uA,a)});var dA="button",cx=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=lf();i=i||s,Wt(i,!1);const f=o.onClick,d=Ye(h=>{i==null||i.setAnchorElement(h.currentTarget),f==null||f(h)});return o=yn(o,h=>D.jsx(uf,{value:i,children:h}),[i]),o=we(oe({},o),{onClick:d}),o=jS(oe({store:i},o)),o=$S(oe({store:i},o)),o});Xe(function(r){const a=cx(r);return Ie(dA,a)});var fx=xa([nf],[sv]),hA=fx.useContext,mA=fx.useScopedContext;E.createContext(void 0);var qo=xa([MS],[uf]);qo.useContext;qo.useScopedContext;var Lv=qo.useProviderContext,vA=qo.ContextProvider,dx=qo.ScopedContextProvider,ko=xa([nf,vA],[sv,dx]),hx=ko.useContext,pA=ko.useScopedContext,mf=ko.useProviderContext,mx=ko.ContextProvider,yA=ko.ScopedContextProvider;E.createContext(void 0);function gA(t={}){var r;const a=(r=t.store)==null?void 0:r.getState(),i=yT(Yt(lt({},t),{placement:et(t.placement,a==null?void 0:a.placement,"bottom")})),o=et(t.timeout,a==null?void 0:a.timeout,500),s=Yt(lt({},i.getState()),{timeout:o,showTimeout:et(t.showTimeout,a==null?void 0:a.showTimeout),hideTimeout:et(t.hideTimeout,a==null?void 0:a.hideTimeout),autoFocusOnShow:et(a==null?void 0:a.autoFocusOnShow,!1)}),f=$r(s,i,t.store);return Yt(lt(lt({},i),f),{setAutoFocusOnShow:d=>f.setState("autoFocusOnShow",d)})}function bA(t,r,a){return Xt(t,a,"timeout"),Xt(t,a,"showTimeout"),Xt(t,a,"hideTimeout"),gT(t,r,a)}function SA(t={}){var r=t,{combobox:a,parent:i,menubar:o}=r,s=oS(r,["combobox","parent","menubar"]);const f=!!o&&!i,d=hv(s.store,IC(i,["values"]),dv(a,["arrowElement","anchorElement","contentElement","popoverElement","disclosureElement"])),h=d.getState(),v=hT(Yt(lt({},s),{store:d,orientation:et(s.orientation,h.orientation,"vertical")})),y=gA(Yt(lt({},s),{store:d,placement:et(s.placement,h.placement,"bottom-start"),timeout:et(s.timeout,h.timeout,f?0:150),hideTimeout:et(s.hideTimeout,h.hideTimeout,0)})),S=Yt(lt(lt({},v.getState()),y.getState()),{initialFocus:et(h.initialFocus,"container"),values:et(s.values,h.values,s.defaultValues,{})}),p=$r(S,v,y,d);return ha(p,()=>pa(p,["mounted"],g=>{g.mounted||p.setState("activeId",null)})),ha(p,()=>pa(i,["orientation"],g=>{p.setState("placement",g.orientation==="vertical"?"right-start":"bottom-start")})),Yt(lt(lt(lt({},v),y),p),{combobox:a,parent:i,menubar:o,hideAll:()=>{y.hide(),i==null||i.hideAll()},setInitialFocus:g=>p.setState("initialFocus",g),setValues:g=>p.setState("values",g),setValue:(g,w)=>{g!=="__proto__"&&g!=="constructor"&&(Array.isArray(g)||p.setState("values",x=>{const R=x[g],T=sS(w,R);return T===R?x:Yt(lt({},x),{[g]:T!==void 0&&T})}))}})}function xA(t,r,a){return ef(r,[a.combobox,a.parent,a.menubar]),Xt(t,a,"values","setValues"),Object.assign(bA(mT(t,r,a),r,a),{combobox:a.combobox,parent:a.parent,menubar:a.menubar})}function EA(t={}){const r=hx(),a=hA(),i=CT();t=we(oe({},t),{parent:t.parent!==void 0?t.parent:r,menubar:t.menubar!==void 0?t.menubar:a,combobox:t.combobox!==void 0?t.combobox:i});const[o,s]=mv(SA,t);return xA(o,s,t)}var wA="div";function OA(t){var r=t,{store:a}=r,i=Ge(r,["store"]);const[o,s]=E.useState(void 0),f=i["aria-label"],d=Pt(a,"disclosureElement"),h=Pt(a,"contentElement");return E.useEffect(()=>{const v=d;if(!v)return;const y=h;if(!y)return;f||y.hasAttribute("aria-label")?s(void 0):v.id&&s(v.id)},[f,d,h]),o}var vx=tt(function(r){var a=r,{store:i,alwaysVisible:o,composite:s}=a,f=Ge(a,["store","alwaysVisible","composite"]);const d=mf();i=i||d,Wt(i,!1);const h=i.parent,v=i.menubar,y=!!h,S=Ji(f.id),p=f.onKeyDown,g=i.useState(B=>B.placement.split("-")[0]),w=i.useState(B=>B.orientation==="both"?void 0:B.orientation),x=w!=="vertical",R=Pt(v,B=>!!B&&B.orientation!=="vertical"),T=Ye(B=>{if(p==null||p(B),!B.defaultPrevented){if(y||v&&!x){const z={ArrowRight:()=>g==="left"&&!x,ArrowLeft:()=>g==="right"&&!x,ArrowUp:()=>g==="bottom"&&x,ArrowDown:()=>g==="top"&&x}[B.key];if(z!=null&&z())return B.stopPropagation(),B.preventDefault(),i==null?void 0:i.hide()}if(v){const z={ArrowRight:()=>{if(R)return v.next()},ArrowLeft:()=>{if(R)return v.previous()},ArrowDown:()=>{if(!R)return v.next()},ArrowUp:()=>{if(!R)return v.previous()}}[B.key],X=z==null?void 0:z();X!==void 0&&(B.stopPropagation(),B.preventDefault(),v.move(X))}}});f=yn(f,B=>D.jsx(yA,{value:i,children:B}),[i]);const A=OA(oe({store:i},f)),N=i.useState("mounted"),j=xv(N,f.hidden,o),O=j?we(oe({},f.style),{display:"none"}):f.style;f=we(oe({id:S,"aria-labelledby":A,hidden:j},f),{ref:Ht(S?i.setContentElement:null,f.ref),style:O,onKeyDown:T});const q=!!i.combobox;return s=s??!q,s&&(f=oe({role:"menu","aria-orientation":w},f)),f=LS(oe({store:i,composite:s},f)),f=zv(oe({store:i,typeahead:!q},f)),f});Xe(function(r){const a=vx(r);return Ie(wA,a)});function Gh(t){return[t.clientX,t.clientY]}function Ob(t,r){const[a,i]=t;let o=!1;const s=r.length;for(let f=s,d=0,h=f-1;d<f;h=d++){const[v,y]=r[d],[S,p]=r[h],[,g]=r[h===0?f-1:h-1]||[0,0],w=(y-p)*(a-v)-(v-S)*(i-y);if(p<y){if(i>=p&&i<y){if(w===0)return!0;w>0&&(i===p?i>g&&(o=!o):o=!o)}}else if(y<p){if(i>y&&i<=p){if(w===0)return!0;w<0&&(i===p?i<g&&(o=!o):o=!o)}}else if(i===y&&(a>=S&&a<=v||a>=v&&a<=S))return!0}return o}function CA(t,r){const{top:a,right:i,bottom:o,left:s}=r,[f,d]=t,h=f<s?"left":f>i?"right":null,v=d<a?"top":d>o?"bottom":null;return[h,v]}function Cb(t,r){const a=t.getBoundingClientRect(),{top:i,right:o,bottom:s,left:f}=a,[d,h]=CA(r,a),v=[r];return d?(h!=="top"&&v.push([d==="left"?f:o,i]),v.push([d==="left"?o:f,i]),v.push([d==="left"?o:f,s]),h!=="bottom"&&v.push([d==="left"?f:o,s])):h==="top"?(v.push([f,i]),v.push([f,s]),v.push([o,s]),v.push([o,i])):(v.push([f,s]),v.push([f,i]),v.push([o,i]),v.push([o,s])),v}var TA="div";function px(t,r,a,i){return oi(r)?!0:t?!!(Lt(r,t)||a&&Lt(a,t)||i!=null&&i.some(o=>px(t,o,a))):!1}function RA(t){var r=t,{store:a}=r,i=Ge(r,["store"]);const[o,s]=E.useState(!1),f=a.useState("mounted");E.useEffect(()=>{f||s(!1)},[f]);const d=i.onFocus,h=Ye(y=>{d==null||d(y),!y.defaultPrevented&&s(!0)}),v=E.useRef(null);return E.useEffect(()=>pa(a,["anchorElement"],y=>{v.current=y.anchorElement}),[]),i=we(oe({autoFocusOnHide:o,finalFocus:v},i),{onFocus:h}),i}var Tb=E.createContext(null),yx=tt(function(r){var a=r,{store:i,modal:o=!1,portal:s=!!o,hideOnEscape:f=!0,hideOnHoverOutside:d=!0,disablePointerEventsOnApproach:h=!!d}=a,v=Ge(a,["store","modal","portal","hideOnEscape","hideOnHoverOutside","disablePointerEventsOnApproach"]);const y=Lv();i=i||y,Wt(i,!1);const S=E.useRef(null),[p,g]=E.useState([]),w=E.useRef(0),x=E.useRef(null),{portalRef:R,domReady:T}=iv(s,v.portalRef),A=lv(),N=!!d,j=Un(d),O=!!h,q=Un(h),B=i.useState("open"),V=i.useState("mounted");E.useEffect(()=>{if(!T||!V||!N&&!O)return;const Z=S.current;return Z?Bn(Zt("mousemove",ie=>{if(!i||!A())return;const{anchorElement:U,hideTimeout:I,timeout:ne}=i.getState(),K=x.current,[M]=ie.composedPath(),F=U;if(px(M,Z,F,p)){x.current=M&&F&&Lt(F,M)?Gh(ie):null,window.clearTimeout(w.current),w.current=0;return}if(!w.current){if(K){const se=Gh(ie),de=Cb(Z,K);if(Ob(se,de)){if(x.current=se,!q(ie))return;ie.preventDefault(),ie.stopPropagation();return}}j(ie)&&(w.current=window.setTimeout(()=>{w.current=0,i==null||i.hide()},I??ne))}},!0),()=>clearTimeout(w.current)):void 0},[i,A,T,V,N,O,p,q,j]),E.useEffect(()=>{if(!T||!V||!O)return;const Z=ae=>{const ie=S.current;if(!ie)return;const U=x.current;if(!U)return;const I=Cb(ie,U);if(Ob(Gh(ae),I)){if(!q(ae))return;ae.preventDefault(),ae.stopPropagation()}};return Bn(Zt("mouseenter",Z,!0),Zt("mouseover",Z,!0),Zt("mouseout",Z,!0),Zt("mouseleave",Z,!0))},[T,V,O,q]),E.useEffect(()=>{T&&(B||i==null||i.setAutoFocusOnShow(!1))},[i,T,B]);const z=gS(B);E.useEffect(()=>{if(T)return()=>{z.current||i==null||i.setAutoFocusOnShow(!1)}},[i,T]);const X=E.useContext(Tb);ct(()=>{if(o||!s||!V||!T)return;const Z=S.current;if(Z)return X==null?void 0:X(Z)},[o,s,V,T]);const te=E.useCallback(Z=>{g(ie=>[...ie,Z]);const ae=X==null?void 0:X(Z);return()=>{g(ie=>ie.filter(U=>U!==Z)),ae==null||ae()}},[X]);v=yn(v,Z=>D.jsx(dx,{value:i,children:D.jsx(Tb.Provider,{value:te,children:Z})}),[i,te]),v=we(oe({},v),{ref:Ht(S,v.ref)}),v=RA(oe({store:i},v));const fe=i.useState(Z=>o||Z.autoFocusOnShow);return v=lx(we(oe({store:i,modal:o,portal:s,autoFocusOnShow:fe},v),{portalRef:R,hideOnEscape(Z){return fS(f,Z)?!1:(requestAnimationFrame(()=>{requestAnimationFrame(()=>{i==null||i.hide()})}),!0)}})),v});cf(Xe(function(r){const a=yx(r);return Ie(TA,a)}),Lv);var DA="div",AA=tt(function(r){var a=r,{store:i,modal:o=!1,portal:s=!!o,hideOnEscape:f=!0,autoFocusOnShow:d=!0,hideOnHoverOutside:h,alwaysVisible:v}=a,y=Ge(a,["store","modal","portal","hideOnEscape","autoFocusOnShow","hideOnHoverOutside","alwaysVisible"]);const S=mf();i=i||S,Wt(i,!1);const p=E.useRef(null),g=i.parent,w=i.menubar,x=!!g,R=!!w&&!x;y=we(oe({},y),{ref:Ht(p,y.ref)});const T=vx(oe({store:i,alwaysVisible:v},y)),{"aria-labelledby":A}=T;y=Ge(T,["aria-labelledby"]);const[j,O]=E.useState(),q=i.useState("autoFocusOnShow"),B=i.useState("initialFocus"),V=i.useState("baseElement"),z=i.useState("renderedItems");E.useEffect(()=>{let U=!1;return O(I=>{var ne,K,M;if(U||!q)return;if((ne=I==null?void 0:I.current)!=null&&ne.isConnected)return I;const F=E.createRef();switch(B){case"first":F.current=((K=z.find(se=>!se.disabled&&se.element))==null?void 0:K.element)||null;break;case"last":F.current=((M=[...z].reverse().find(se=>!se.disabled&&se.element))==null?void 0:M.element)||null;break;default:F.current=V}return F}),()=>{U=!0}},[i,q,B,z,V]);const X=x?!1:o,te=!!d,fe=!!j||!!y.initialFocus||!!X,Z=Pt(i.combobox||i,"contentElement"),ae=Pt((g==null?void 0:g.combobox)||g,"contentElement"),ie=E.useMemo(()=>{if(!ae||!Z)return;const U=Z.getAttribute("role"),I=ae.getAttribute("role");if(!((I==="menu"||I==="menubar")&&U==="menu"))return ae},[Z,ae]);return ie!==void 0&&(y=oe({preserveTabOrderAnchor:ie},y)),y=yx(we(oe({store:i,alwaysVisible:v,initialFocus:j,autoFocusOnShow:te?fe&&d:q||!!X},y),{hideOnEscape(U){return fS(f,U)?!1:(i==null||i.hideAll(),!0)},hideOnHoverOutside(U){const I=i==null?void 0:i.getState().disclosureElement;return(typeof h=="function"?h(U):h??(x?!0:R?I?!oi(I):!0:!1))?U.defaultPrevented||!x||!I||(BC(I,"mouseout",U),!oi(I))?!0:(requestAnimationFrame(()=>{oi(I)||i==null||i.hide()}),!1):!1},modal:X,portal:s,backdrop:x?!1:y.backdrop})),y=oe({"aria-labelledby":A},y),y}),MA=cf(Xe(function(r){const a=AA(r);return Ie(DA,a)}),mf);function jA(t={}){const r=EA(t);return D.jsx(mx,{value:r,children:t.children})}var _A="a",gx=tt(function(r){var a=r,{store:i,showOnHover:o=!0}=a,s=Ge(a,["store","showOnHover"]);const f=Lv();i=i||f,Wt(i,!1);const d=No(s),h=E.useRef(0);E.useEffect(()=>()=>window.clearTimeout(h.current),[]),E.useEffect(()=>Zt("mouseleave",T=>{if(!i)return;const{anchorElement:A}=i.getState();A&&T.target===A&&(window.clearTimeout(h.current),h.current=0)},!0),[i]);const v=s.onMouseMove,y=Un(o),S=lv(),p=Ye(R=>{if(v==null||v(R),d||!i||R.defaultPrevented||h.current||!S()||!y(R))return;const T=R.currentTarget;i.setAnchorElement(T),i.setDisclosureElement(T);const{showTimeout:A,timeout:N}=i.getState(),j=()=>{h.current=0,S()&&(i==null||i.setAnchorElement(T),i==null||i.show(),queueMicrotask(()=>{i==null||i.setDisclosureElement(T)}))},O=A??N;O===0?j():h.current=window.setTimeout(j,O)}),g=s.onClick,w=Ye(R=>{g==null||g(R),i&&(window.clearTimeout(h.current),h.current=0)}),x=E.useCallback(R=>{if(!i)return;const{anchorElement:T}=i.getState();T!=null&&T.isConnected||i.setAnchorElement(R)},[i]);return s=we(oe({},s),{ref:Ht(x,s.ref),onMouseMove:p,onClick:w}),s=$o(s),s});Xe(function(r){const a=gx(r);return Ie(_A,a)});var NA="button";function zA(t,r){return{ArrowDown:r==="bottom"||r==="top"?"first":!1,ArrowUp:r==="bottom"||r==="top"?"last":!1,ArrowRight:r==="right"?"first":!1,ArrowLeft:r==="left"?"first":!1}[t.key]}function Rb(t,r){return!!(t!=null&&t.some(a=>!a.element||a.element===r?!1:a.element.getAttribute("aria-expanded")==="true"))}var LA=tt(function(r){var a=r,{store:i,focusable:o,accessibleWhenDisabled:s,showOnHover:f}=a,d=Ge(a,["store","focusable","accessibleWhenDisabled","showOnHover"]);const h=mf();i=i||h,Wt(i,!1);const v=E.useRef(null),y=i.parent,S=i.menubar,p=!!y,g=!!S&&!p,w=No(d),x=()=>{const te=v.current;te&&(i==null||i.setDisclosureElement(te),i==null||i.setAnchorElement(te),i==null||i.show())},R=d.onFocus,T=Ye(te=>{if(R==null||R(te),w||te.defaultPrevented||(i==null||i.setAutoFocusOnShow(!1),i==null||i.setActiveId(null),!S)||!g)return;const{items:fe}=S.getState();Rb(fe,te.currentTarget)&&x()}),A=Pt(i,te=>te.placement.split("-")[0]),N=d.onKeyDown,j=Ye(te=>{if(N==null||N(te),w||te.defaultPrevented)return;const fe=zA(te,A);fe&&(te.preventDefault(),x(),i==null||i.setAutoFocusOnShow(!0),i==null||i.setInitialFocus(fe))}),O=d.onClick,q=Ye(te=>{if(O==null||O(te),te.defaultPrevented||!i)return;const fe=!te.detail,{open:Z}=i.getState();(!Z||fe)&&((!p||fe)&&i.setAutoFocusOnShow(!0),i.setInitialFocus(fe?"first":"container")),p&&x()});d=yn(d,te=>D.jsx(mx,{value:i,children:te}),[i]),p&&(d=we(oe({},d),{render:D.jsx(Uc.div,{render:d.render})}));const B=Ji(d.id),V=Pt((y==null?void 0:y.combobox)||y,"contentElement"),z=p||g?mS(V,"menuitem"):void 0,X=i.useState("contentElement");return d=we(oe({id:B,role:z,"aria-haspopup":ev(X,"menu")},d),{ref:Ht(v,d.ref),onFocus:T,onKeyDown:j,onClick:q}),d=gx(we(oe({store:i,focusable:o,accessibleWhenDisabled:s},d),{showOnHover:te=>{if(!(()=>{if(typeof f=="function")return f(te);if(f!=null)return f;if(p)return!0;if(!S)return!1;const{items:ie}=S.getState();return g&&Rb(ie)})())return!1;const ae=g?S:y;return ae&&ae.setActiveId(te.currentTarget.id),!0}})),d=cx(oe({store:i,toggleOnClick:!p,focusable:o,accessibleWhenDisabled:s},d)),d=zv(oe({store:i,typeahead:g},d)),d}),HA=Xe(function(r){const a=LA(r);return Ie(NA,a)}),UA="div";function $A(t,r,a){var i;if(!t)return!1;if(oi(t))return!0;const o=r==null?void 0:r.find(h=>{var v;return h.element===a?!1:((v=h.element)==null?void 0:v.getAttribute("aria-expanded"))==="true"}),s=(i=o==null?void 0:o.element)==null?void 0:i.getAttribute("aria-controls");if(!s)return!1;const d=yt(t).getElementById(s);return d?oi(d)?!0:!!d.querySelector("[role=menuitem][aria-expanded=true]"):!1}var BA=tt(function(r){var a=r,{store:i,hideOnClick:o=!0,preventScrollOnKeyDown:s=!0,focusOnHover:f,blurOnHoverEnd:d}=a,h=Ge(a,["store","hideOnClick","preventScrollOnKeyDown","focusOnHover","blurOnHoverEnd"]);const v=pA(!0),y=mA();i=i||v||y,Wt(i,!1);const S=h.onClick,p=Un(o),g="hideAll"in i?i.hideAll:void 0,w=!!g,x=Ye(A=>{S==null||S(A),!(A.defaultPrevented||$C(A)||UC(A)||!g||A.currentTarget.getAttribute("aria-haspopup")==="menu")&&p(A)&&g()}),R=Pt(i,A=>"contentElement"in A?A.contentElement:null),T=mS(R,"menuitem");return h=we(oe({role:T},h),{onClick:x}),h=kS(oe({store:i,preventScrollOnKeyDown:s},h)),h=PS(we(oe({store:i},h),{focusOnHover(A){const N=()=>typeof f=="function"?f(A):f??!0;if(!i||!N())return!1;const{baseElement:j,items:O}=i.getState();return w?(A.currentTarget.hasAttribute("aria-expanded")&&A.currentTarget.focus(),!0):$A(j,O,A.currentTarget)?(A.currentTarget.focus(),!0):!1},blurOnHoverEnd(A){return typeof d=="function"?d(A):d??w}})),h}),PA=ov(Xe(function(r){const a=BA(r);return Ie(UA,a)})),qA="hr",kA=tt(function(r){var a=r,{store:i}=a,o=Ge(a,["store"]);const s=hx();return i=i||s,o=ox(oe({store:i},o)),o}),FA=Xe(function(r){const a=kA(r);return Ie(qA,a)}),Pr={legend:"BjkL4",label:"IogM9",errorText:"iCPgd",textErrorMessage:"_1r4K2",helperText:"aW7kV",fieldSet:"LwRcp"};function VA({error:t,className:r,...a}){return D.jsx("fieldset",{...a,className:$e(Pr.fieldSet,t&&Pr.hasError,r)})}function YA({error:t,className:r,...a}){return D.jsx("div",{...a,className:$e(Pr.helperText,t&&Pr.hasError,r)})}function bx({error:t,className:r,...a}){return D.jsx("label",{...a,className:$e(Pr.label,t&&Pr.hasError,r)})}function Sx({error:t,className:r,...a}){return D.jsx("div",{...a,className:$e(Pr.legend,t&&Pr.hasError,r)})}function Fo({className:t,...r}){return D.jsx("p",{...r,className:$e(Pr.errorText,Pr.textErrorMessage,t)})}var oo={root:"_0bZjG",inputContainer:"f-ccT",input:"BQJSS",startAdornment:"pFIPb",endAdornment:"MBy3g"};const vf=function({as:t="input",label:r,disabled:a,error:i,hint:o,size:s,multiline:f,startAdornment:d,endAdornment:h,id:v,style:y,className:S,inputClassName:p,...g}){const w=t==="input"?f?"textarea":"input":t,x=E.useId(),R=v||x;return D.jsxs("div",{className:$e(oo.root,S),style:{maxWidth:s,...y},"data-error":!!i,"aria-disabled":!!a,id:v?`${v}-container`:void 0,children:[r&&D.jsx(bx,{htmlFor:R,children:r}),o&&D.jsx(YA,{id:`${R}_hint`,children:o}),D.jsxs("div",{className:$e(oo.inputContainer),children:[d&&D.jsx("div",{className:oo.startAdornment,children:d}),D.jsx(w,{disabled:a,id:R,...g,"aria-describedby":$e(g["aria-describedby"],o&&`${R}_hint`,i&&`${R}_error`),"aria-invalid":!!i,className:$e(oo.input,p)}),h&&D.jsx("div",{className:oo.endAdornment,children:h})]}),i&&D.jsx(Fo,{id:`${R}_error`,role:"alert",children:i})]})};function QA({value:t,ref:r,...a}){const i=E.useRef(void 0),o=K1(r,i),s=()=>{var v,y,S;(y=(v=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value"))==null?void 0:v.set)==null||y.call(i.current,"");const h=new Event("input",{bubbles:!0});(S=i.current)==null||S.dispatchEvent(h)},f=h=>{var v;h.key==="Escape"&&s(),(v=a.onKeyDown)==null||v.call(a,h)},d=(t??"").length>0;return D.jsx(vf,{ref:o,...a,type:"search",onKeyDown:f,value:t,startAdornment:D.jsx(kO,{size:24,style:{marginTop:6}}),endAdornment:D.jsx("button",{type:"button",onClick:s,tabIndex:-1,style:{marginTop:6,opacity:d?1:0,pointerEvents:d?void 0:"none"},children:D.jsx(Xm,{size:32,style:{opacity:.75}})})})}var so={root:"hhIFY",button:"LYR4G",value:"afH1B",hidden:"vxf23",hiddenText:"gO-kQ",numberInput:"MdvMX"};function KA({id:t,name:r,value:a,defaultValue:i,onChange:o,min:s=-1/0,max:f=1/0,step:d=1,disabled:h,error:v,className:y,style:S,onFocus:p,...g}){const w=a!==void 0,x=E.useRef(null),[R,T]=E.useState((w?a:i)??"");w&&a!==R&&T(a);const A=Number(f),N=Number(s),j=Number(d),O=z=>{const X=XA(z,N,A);T(X);const te=new Event("change"),fe={writable:!1,value:{name:r,value:X}};Object.defineProperty(te,"target",fe),Object.defineProperty(te,"currentTarget",fe),o==null||o(te)},q=z=>{const X=Number(R)||0;z.key==="Home"?(z.preventDefault(),O(`${N}`)):z.key==="End"&&A<1/0?(z.preventDefault(),O(`${A}`)):z.key==="ArrowUp"?(z.preventDefault(),O(`${X+j}`)):z.key==="ArrowDown"&&(z.preventDefault(),O(`${X-j}`))},B=z=>{O(z.target.value)},V=z=>()=>{var te;const X=Number(R)||0;O(X+z),GA()||((te=x.current)==null||te.focus())};return D.jsxs("div",{className:$e(so.root,y),"aria-valuenow":Number(a||0),"aria-valuemin":N===-1/0?void 0:N,"aria-valuemax":A===1/0?void 0:A,tabIndex:-1,style:S,"aria-invalid":!!v,"aria-disabled":!!h,id:t?`${t}-container`:void 0,children:[D.jsx("button",{type:"button",onClick:V(-j),className:$e(so.button),disabled:h||Number(R||0)<=N,"aria-label":"Decrease",tabIndex:-1,children:D.jsx(qO,{})}),D.jsx("input",{ref:x,id:t,role:"spinbutton",type:"tel",inputMode:"numeric",pattern:"[0-9]*",className:$e(so.value,so.numberInput),name:r,min:N,max:A,value:R,onChange:B,onKeyDown:q,disabled:h,onFocus:z=>{var X;(X=x.current)==null||X.select(),p==null||p(z)},...g}),D.jsx("button",{type:"button",onClick:V(j),className:so.button,disabled:h||Number(R||0)>=A,"aria-label":"Increase",tabIndex:-1,children:D.jsx(zO,{})})]})}function GA(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}function XA(t,r,a){const i=typeof t=="string"?parseFloat(t):t;return t==="-"?t:isNaN(i)?"":Math.max(r,Math.min(a,i))}var oa={backdrop:"JKTsp",dialog:"hTxsM",header:"Y-99i",withTitle:"_51P42",title:"GprBx",content:"G5k-W",closeButton:"xWVnm"};function xx({title:t,isOpen:r=!0,onDismiss:a,initialFocusRef:i,className:o,style:s,children:f}){return D.jsxs(nD,{initialFocus:i,open:r,onClose:()=>a==null?void 0:a(),backdrop:D.jsx("div",{className:oa.backdrop}),modal:!0,hideOnInteractOutside:!!a,hideOnEscape:!!a,className:$e(oa.dialog,oa.withTitle,o),style:{"--transition-opacity":1,...s},children:[D.jsxs("header",{className:$e(oa.header,oa.withTitle),children:[t&&D.jsx(lA,{className:oa.title,children:t}),D.jsx(nA,{className:oa.closeButton,style:{display:a?void 0:"none"},children:D.jsx(Xm,{})})]}),D.jsx("section",{className:$e(oa.content,oa.withTitle),children:f})]})}var hc={menuButton:"uQnDM",list:"_5sdh-",listItem:"cYlZh",separator:"WSXYE"};function ZA({items:t,label:r="Menu",buttonProps:a={},arrow:i=!0}){const{className:o,style:s}=tS(a);return D.jsxs(jA,{children:[D.jsx(HA,{className:$e(hc.menuButton,o),style:s,children:D.jsxs("span",{className:"dmk-text-with-icon",children:[r,i&&D.jsx(HO,{className:"dmk-margin-left-xxs"})]})}),D.jsx(MA,{className:hc.list,children:t.map(({action:f,label:d,selected:h,separator:v},y)=>v?D.jsx(FA,{className:hc.separator},y):D.jsxs(PA,{onClick:f,className:hc.listItem,disabled:!f,children:[d," ",h&&D.jsx($O,{})]},y))})]})}class Ex extends E.Component{constructor(){super(...arguments),this.state={error:null},this.resetErrorBoundary=()=>{var r,a;(a=(r=this.props).onReset)==null||a.call(r),this.setState({error:null})}}static getDerivedStateFromError(r){return{error:r}}componentDidCatch(r,a){this.props.onError&&this.props.onError(r,a)}render(){return this.state.error?E.isValidElement(this.props.fallback)?this.props.fallback:typeof this.props.fallback=="function"?this.props.fallback({error:this.state.error,resetErrorBoundary:this.resetErrorBoundary}):null:this.props.children}}Ex.defaultProps={fallback:D.jsx("div",{className:"dmk-padding-m",children:D.jsx(Im,{intent:"error",title:"Error",children:D.jsx("p",{children:"An error occurred"})})}),onError:(t,r)=>console.error(t,r)};var Db={hamburgerButton:"wJ6xF",open:"kEzf7"};function IA({open:t=!1,className:r,...a}){return D.jsxs("button",{...a,className:$e(Db.hamburgerButton,!!t&&Db.open,r),children:[D.jsx("div",{}),D.jsx("div",{}),D.jsx("div",{}),D.jsx("div",{})]})}var Ec={root:"_2NpgS",radio:"qytUm",input:"_9AxBc",radioGroup:"xYP4R"};const JA=function({as:t=tM,name:r,value:a,onChange:i,disabled:o,children:s,error:f,variant:d="normal",...h}){const v=E.useMemo(()=>({name:r,disabled:o,isChecked:y=>a===y,onChange:i}),[r,a,i,o]);return D.jsx(wx,{value:v,children:D.jsx(t,{role:"radiogroup","data-radio-group":r,"data-variant":d,...h,"data-error":!!f,"aria-disabled":!!o,className:$e(Ec.radioGroup,h.className),children:s})})},wx=Zm("RadioGroupContext",null);function WA({children:t,className:r,style:a,error:i,...o}){const s=eM(o);return D.jsxs("label",{className:$e(Ec.root,r),"data-checked":s.checked,"data-error":i,"aria-disabled":s.disabled,style:a,children:[D.jsx("input",{...o,className:$e("dmk-visually-hidden",Ec.input),"aria-checked":s.checked,"aria-invalid":i?"true":"false",type:"radio",...s}),D.jsx("span",{className:Ec.radio,"aria-hidden":"true"}),D.jsx("span",{children:typeof t=="function"?t(s.checked):t})]})}function eM(t){const r=E.use(wx);return r==null?t:{value:t.value,name:r.name,checked:r.isChecked(t.value),disabled:r.disabled,onChange:r.onChange}}const tM=function(t){return D.jsx(Ur,{spacing:"s",...t})};var dr={root:"piq-R",sidebar:"Og3fR",mobile:"muuLM",overlay:"xZmuk",header:"JYx2J",contentContainer:"_5UdA1",content:"xV9Cb",sidebarMenuItem:"xAYHd",sidebarSectionHeading:"tt-vd"};function Hv(t=!1){const[r,a]=E.useState(t),i=E.useCallback(()=>a(f=>!f),[]),o=E.useCallback(()=>a(!0),[]),s=E.useCallback(()=>a(!1),[]);return E.useMemo(()=>({value:r,toggle:i,enable:o,disable:s}),[r,i,o,s])}function nM(t){const r=E.useRef(void 0);return G1(()=>{r.current=t},[t]),r.current}const Ox=E.createContext(null);function Cx(){const t=E.use(Ox);if(t==null)throw new Error("MenuOpenContext not available");return t}function rM({header:t,sidebar:r,children:a,className:i,maxWidth:o,headerHeight:s,style:f}){const d=Jm([!0,!1,!1]),h=Hv(!d),v=nM(h.value);return G1(()=>{!d&&!v?h.enable():d&&v&&h.disable()},[d,h,v]),D.jsx(Ox,{value:h,children:D.jsxs("div",{className:$e(dr.root,i,d&&dr.mobile),style:{"--max-width":o,"--header-height":s,...f},children:[t,d&&h.value&&D.jsx("div",{className:dr.overlay,onClick:h.disable}),D.jsxs("aside",{className:$e(dr.sidebar,d&&dr.mobile),"data-open":h.value,children:[d&&D.jsx(Ur,{horizontal:!0,justifyContent:"flex-end",className:"dmk-margin-bottom-l",children:D.jsx(Tx,{})}),r]}),D.jsx("main",{className:$e(dr.contentContainer,d&&dr.mobile),children:D.jsx("div",{className:dr.content,children:a})})]})})}function Tx(){const t=Cx();return D.jsx(IA,{open:t.value,onClick:t.toggle})}function aM({logo:t,children:r,className:a,style:i}){const o=Jm([!0,!1,!1]);return D.jsxs(Ur,{horizontal:[!1,!0,!0],justifyContent:"space-between",alignItems:"center",className:$e(dr.header,o&&dr.mobile,a),style:i,children:[D.jsxs(Ur,{horizontal:!0,alignItems:"center",justifyContent:"space-between",children:[o&&D.jsx(Tx,{}),t]}),r]})}const iM=function({as:t="a",onClick:r,className:a,...i}){const o=Cx(),s=Jm([!0,!1,!1]);return D.jsx(t,{...i,className:$e(dr.sidebarMenuItem,a),draggable:!1,onClick:f=>{r==null||r(f),!f.defaultPrevented&&s&&o.disable()}})};function lM(t){return Jt({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M12 2.25a.75.75 0 0 1 .75.75v16.19l6.22-6.22a.75.75 0 1 1 1.06 1.06l-7.5 7.5a.75.75 0 0 1-1.06 0l-7.5-7.5a.75.75 0 1 1 1.06-1.06l6.22 6.22V3a.75.75 0 0 1 .75-.75Z",clipRule:"evenodd"},child:[]}]})(t)}function uM(t){return Jt({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M11.47 2.47a.75.75 0 0 1 1.06 0l7.5 7.5a.75.75 0 1 1-1.06 1.06l-6.22-6.22V21a.75.75 0 0 1-1.5 0V4.81l-6.22 6.22a.75.75 0 1 1-1.06-1.06l7.5-7.5Z",clipRule:"evenodd"},child:[]}]})(t)}function Rx(t){return Jt({tag:"svg",attr:{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},child:[{tag:"path",attr:{fillRule:"evenodd",d:"M11.47 4.72a.75.75 0 0 1 1.06 0l3.75 3.75a.75.75 0 0 1-1.06 1.06L12 6.31 8.78 9.53a.75.75 0 0 1-1.06-1.06l3.75-3.75Zm-3.75 9.75a.75.75 0 0 1 1.06 0L12 17.69l3.22-3.22a.75.75 0 1 1 1.06 1.06l-3.75 3.75a.75.75 0 0 1-1.06 0l-3.75-3.75a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"},child:[]}]})(t)}var co={root:"ScOVn",selectContainer:"o18SG",arrow:"LsR6O",select:"f1zqA",label:"sVIZA",hint:"_1hf0-"};function Dx({style:t,className:r,error:a,hint:i,label:o,value:s,disabled:f,children:d,placeholder:h,ref:v,...y}){return D.jsxs("div",{className:$e(co.root,r),"data-error":!!a,"aria-disabled":!!f,style:t,children:[o&&D.jsx(bx,{htmlFor:y.id,children:o}),i&&D.jsx("div",{className:co.hint,id:`${y.id}_hint`,children:i}),D.jsxs("div",{className:$e(co.selectContainer),children:[D.jsxs("select",{ref:v,...y,disabled:f,value:s===null?"":s,className:$e(co.select),"aria-invalid":!!a,"aria-describedby":$e(y["aria-describedby"],i&&`${y.id}_hint`),children:[h&&D.jsx("option",{value:"",children:h}),d]}),D.jsx("div",{className:co.arrow,"aria-hidden":!0,role:"presentation",children:D.jsx(Rx,{})})]}),a&&D.jsx(Fo,{role:"alert",children:a})]})}var oM={visuallyHidden:"zZoQC"};const sM=function({as:t="div",className:r,ref:a,...i}){return D.jsx(t,{ref:a,...i,className:$e(oM.visuallyHidden,r)})};var Uv={root:"_7x-oj",scrollableContainer:"Sc0YX",sortPrioIndicator:"tKRSW"};function cM(t){return D.jsx("div",{...t,className:$e(Uv.scrollableContainer,t.className)})}function fM({ref:t,renderHeaderRow:r,renderRow:a,items:i,caption:o,footer:s,columnWidthFixedAfterFirstRender:f=!0,...d}){const h=E.useRef(null),v=K1(t,h),y=E.useRef(null);return E.useLayoutEffect(()=>{var w;if(!f)return;const S=Array.from(((w=h.current)==null?void 0:w.querySelectorAll("th"))??[]),p=S.map(x=>window.getComputedStyle(x).width);(y.current==null||p.length!==y.current.length)&&(y.current=p);const g=JSON.stringify(p)!==JSON.stringify(y.current);if(y.current&&g)for(let x=0;x<S.length;x++)S[x].style.width=y.current[x]}),D.jsxs("table",{ref:v,...d,className:$e(Uv.root,d.className),children:[o&&D.jsx(sM,{as:"caption",children:o}),D.jsx("thead",{children:r()}),i&&i.length>0&&D.jsx("tbody",{children:(i||[]).map(a)}),s!=null&&D.jsx("tfoot",{children:s})]})}const dM=[10,20,50,100];function hM({limit:t,onLimitChange:r,page:a,onPageChange:i,total:o,limits:s=dM}){const f=Math.ceil(o/Math.max(1,t)),d=t*(Math.max(1,a)-1);return D.jsxs(Ur,{horizontal:!0,alignItems:"center",children:[D.jsxs("span",{style:{whiteSpace:"nowrap"},children:[D.jsx("span",{className:"dmk-text-semibold",children:d+1})," to"," ",D.jsx("span",{className:"dmk-text-semibold",children:Math.min(d+t,o)})," ","of ",D.jsx("span",{className:"dmk-text-semibold",children:o})]}),D.jsx(KA,{name:"page",value:a,onChange:h=>i(+h.currentTarget.value||1),min:1,max:f}),D.jsx("div",{className:"dmk-margin-left-auto",children:D.jsx(ZA,{label:`${t} per page`,items:s.map(h=>({label:`${h} per page`,action:()=>r(h),selected:h===t})),buttonProps:{variant:"text",size:"s"}})})]})}const mM=(t,r)=>typeof t=="string"?t.localeCompare(r):D1(t)?Nw(t,r):t<r?-1:t>r?1:0,vM=Symbol();function pM(t,r={},a=void 0,i=mM){const o=om(t),s=(f,d)=>{var h;if(typeof f=="function")return om(f(d));if(f===vM)return[d];if(typeof f=="string"&&typeof d=="object"&&d!=null){const v=f.at(0)==="-"?f.slice(1):f;return v in r?[(h=r[v])==null?void 0:h.call(r,d,a)]:[d[v]]}return[d]};return function(f){return f.slice().sort((d,h)=>{if(o.length===0)return i(d,h);for(const v of o){const y=s(v,d),S=s(v,h);for(let p=0;p<y.length;p++){const g=y[p],w=S[p],x=i(g,w);if(x!==0)return typeof v=="string"&&v.at(0)==="-"?x*-1:x}}return 0})}}function yM({multi:t=!0,keys:r}={}){function a(i,o){if(o.column==null)return[];const s=`-${String(o.column)}`;return i.includes(s)?i.filter(f=>f!==s):i.includes(o.column)?i.map(f=>f===o.column?s:f):!t||!o.shiftKey?[o.column]:i.concat([o.column])}return function(i=[],o=void 0){const[s,f]=E.useReducer(a,i),d=E.useMemo(()=>pM(s,r,o),[s,o]);function h(S){const p=s.length>1;let g;return(g=s.indexOf(S))>-1?D.jsx(Xh,{direction:"asc",priority:p?g+1:null}):(g=s.indexOf(`-${String(S)}`))>-1?D.jsx(Xh,{direction:"desc",priority:p?g+1:null}):D.jsx(Xh,{})}function v(S,p){return D.jsxs(D.Fragment,{children:[p??S," ",h(S)]})}function y(S,p){return{"data-sortable":!0,onClick:g=>{f({column:S,shiftKey:g.shiftKey})},children:v(S,p)}}return{sortColumns:s,onSortColumnClick:f,sorted:d,renderSortColumnLabel:v,renderSortingColumnArrow:h,getSortingColumnHeaderProps:y,getThProps:y}}}function Xh({direction:t,priority:r}){return t==null?D.jsx(Rx,{className:"dmk-text-muted"}):D.jsxs(D.Fragment,{children:[t==="asc"?D.jsx(uM,{}):D.jsx(lM,{})," ",r!=null&&D.jsx("sup",{className:Uv.sortPrioIndicator,children:r})]})}var gM=Object.defineProperty,bM=Object.defineProperties,SM=Object.getOwnPropertyDescriptors,qc=Object.getOwnPropertySymbols,Ax=Object.prototype.hasOwnProperty,Mx=Object.prototype.propertyIsEnumerable,Em=(t,r,a)=>r in t?gM(t,r,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[r]=a,mc=(t,r)=>{for(var a in r||(r={}))Ax.call(r,a)&&Em(t,a,r[a]);if(qc)for(var a of qc(r))Mx.call(r,a)&&Em(t,a,r[a]);return t},xM=(t,r)=>bM(t,SM(r)),EM=(t,r)=>{var a={};for(var i in t)Ax.call(t,i)&&r.indexOf(i)<0&&(a[i]=t[i]);if(t!=null&&qc)for(var i of qc(t))r.indexOf(i)<0&&Mx.call(t,i)&&(a[i]=t[i]);return a},wM=(t,r,a)=>(Em(t,r+"",a),a),Bl=(t,r,a)=>new Promise((i,o)=>{var s=h=>{try{d(a.next(h))}catch(v){o(v)}},f=h=>{try{d(a.throw(h))}catch(v){o(v)}},d=h=>h.done?i(h.value):Promise.resolve(h.value).then(s,f);d((a=a.apply(t,r)).next())});const OM=()=>RM({max:5,isRetriable:t=>t instanceof jx?t.response.status===503:t instanceof _x,getDelay:t=>500*t}),CM=()=>globalThis.crypto.randomUUID();function TM(t={}){var r=t,{getRootUrl:a=()=>"",timeout:i=0,retryOn:o=OM,headers:s={},requestIdHeaderName:f="X-Request-ID",getRequestId:d=CM,json:h=!0}=r,v=EM(r,["getRootUrl","timeout","retryOn","headers","requestIdHeaderName","getRequestId","json"]);const y=[];function S(p){return Bl(this,arguments,function*(g,w={}){var x;const R=(x=w.json)!=null?x:h,T=yield a(g),A=yield Bl(this,null,function*(){const j=new Headers;j.set(f,d()),R&&(j.set("Accept","application/json"),w.method!=="GET"&&typeof w.body=="string"&&j.set("Content-Type","application/json"));for(const[O,q]of Object.entries(mc(mc({},s),w.headers)))j.set(O,q);return new Request(`${T}${g}`,xM(mc(mc({credentials:"include"},v),w),{headers:j}))}),N=w.retryOn||o();return jM(()=>Bl(this,null,function*(){var j,O;const q=(O=(j=w.timeout)!=null?j:i)!=null?O:0,B=yield Bl(this,null,function*(){for(const z of y)z.request&&(yield z.request(A));return q?AM(fetch(A),q):fetch(A)}),V=R?yield B.clone().json().then(z=>z,()=>{}):void 0;B.jsonData=V;for(const z of y)z.response&&(yield z.response(B));if(B.status<200||B.status>=400)throw new jx(B);return B}),N)})}return S.intercept=p=>(y.push(p),()=>{const g=y.indexOf(p);g>=0&&y.splice(g,1)}),S}class jx extends Error{constructor(r){const a=`${r.status} ${r.statusText} at ${r.url}`;super(a),wM(this,"response"),this.name=this.constructor.name,this.response=r}}class _x extends Error{constructor(r){super(r),this.name=this.constructor.name}}function RM({max:t,isRetriable:r,getDelay:a}){let i=0;return function(o){return Bl(this,null,function*(){return i++,r(o)&&i<t?(yield MM(a(i)),!0):!1})}}function DM(t=1e3){let r;return{start(){return new Promise((a,i)=>{r=setTimeout(()=>{i(new _x("Timeout"))},t)})},clear(){clearTimeout(r)}}}function AM(t,r){const{start:a,clear:i}=DM(r);return Promise.race([a(),t]).finally(i)}function MM(t){return new Promise(r=>setTimeout(r,t))}function jM(t,r=()=>!0){const a=(...i)=>Bl(this,null,function*(){try{return yield t(...i)}catch(o){if(yield r(o))return a();throw o}});return a()}function _M(t,r){const[a,i]=E.useState(t),o=E.useRef(Date.now());return E.useEffect(()=>{const s=setTimeout(()=>{Date.now()-o.current>=r&&(i(t),o.current=Date.now())},r-(Date.now()-o.current));return()=>{clearTimeout(s)}},[t,r]),a}const NM=({fields:t,onRemove:r,texts:a,path:i})=>D.jsxs("div",{"data-bitiforms-array-item":!0,"data-field-path":i,children:[Object.keys(t).map(o=>D.jsx(Gm,{...t[o]},o)),D.jsx(ci,{className:"dmk-margin-top-m",variant:"outlined",intent:"danger",type:"button",onClick:r,"data-bitiforms-array-remove-button":!0,children:(a||{})["arrayfield.remove"]??"Remove"})]}),zM=({disabled:t,onClick:r,texts:a})=>D.jsx(Ur,{as:"footer",horizontal:!0,alignItems:"center",className:"dmk-margin-top-l","data-bitiforms-array-add-button":!0,children:!t&&D.jsx(ci,{variant:"outlined",onClick:r,children:(a||{})["arrayfield.add"]??"Add"})}),LM=({schema:t,id:r,name:a,children:i,errors:o,itemCount:s})=>D.jsxs("div",{"data-bitiforms-array-field":a,children:[t.title&&D.jsxs("h3",{id:`${r}_title`,className:"dmk-text-title2 dmk-margin-bottom-s",children:[t.title," ",D.jsxs("span",{"data-bitiforms-array-item-count":!0,children:["(",s,")"]})]}),t.description&&D.jsx("div",{id:`${r}_description`,children:t.description}),o&&D.jsx("div",{children:o}),i]});function HM(t){return D.jsx(hO,{...t,renderItem:NM,renderAddButton:zM,renderContainer:LM})}function Nx(t){return D.jsx("div",{"data-bitiforms-description":!0,...t})}function UM({onChange:t,id:r,name:a,value:i,errors:o,schema:s,texts:f,disabled:d,path:h}){const v=Jc();_1(BM(s),`CheckboxGroupWidget must be given a schema of type 'object' or 'array'. ${JSON.stringify(s)} given.`);const y=w=>x=>ga(s)&&Array.isArray(i)?t({target:{name:a,value:PM(i,w,x.currentTarget.checked)}}):t({target:{name:a,value:{...i,[w]:x.currentTarget.checked}}}),S=()=>{v.enable()},p=v.value,g=$M(o,s);return D.jsxs(VA,{"aria-labelledby":`${r}-legend`,"data-bitiforms-checkboxgroup":!0,"data-field-path":h,children:[s.title&&D.jsx(Sx,{id:`${r}-legend`,children:s.title}),s.description&&D.jsx(Nx,{id:`${r}_description`,children:s.description}),D.jsx(Ur,{spacing:"s",children:qM(s).map(([w,x])=>{const R=Array.isArray(i)?i.includes(w):i[w]===!0,T=Array.isArray(i)?!R&&g.length>0?"invalid":void 0:pr(o[w])?"invalid":void 0;return D.jsx(rS,{id:`${r}_${w}`,checked:R,value:w,error:p?!!T:void 0,onChange:y(w),onBlur:S,disabled:d,children:x},w)})}),p&&g.length>0&&D.jsx(Fo,{role:"alert",children:Wc(g,f)})]})}function $M(t,r){return pr(t)?ga(r)?t.all:["errors.checkboxGroup.invalid"]:[]}function BM(t){return!!(ga(t)&&si(t.items)&&t.items.enum||gn(t)&&Object.values(t.properties||{}).every(jo))}function PM(t,r,a){const i=new Set(t);return a?[...i.add(r)]:(i.delete(r),[...i])}function qM(t){var r;if(ga(t)&&si(t.items)&&t.items.enum){const a=[];for(let i=0;i<t.items.enum.length;i++)a.push([t.items.enum[i],((r=t.items.$enumNames)==null?void 0:r[i])||t.items.enum[i]]);return a}return gn(t)?Xc(Object.keys(t.properties||{}),(t.$bitiforms||{}).propertyOrder).map(a=>[a,t.properties[a].title]):[]}function kM({name:t,value:r,onChange:a,schema:i,errors:o,texts:s,path:f}){const d=Jc(),h=y=>{const{checked:S}=y.currentTarget;return a({target:{name:t,value:S}})},v=d.value&&pr(o);return D.jsxs("div",{"data-field-path":f,children:[D.jsx(rS,{checked:r||!1,onChange:h,onBlur:d.enable,error:v,children:i.title}),v&&D.jsx(Fo,{role:"alert",children:s==null?void 0:s["errors.checkbox.required"]})]})}function FM(t){const{onBlur:r,onChange:a,error:i,schema:o,id:s,name:f,value:d,disabled:h,$bitiforms:v}=_o(t);return D.jsx(vf,{"data-field-path":t.path,name:f,type:"date",id:s,label:o.title,hint:o.description,error:i,value:d??"",onChange:a,onBlur:r,disabled:h,...v.widgetProps})}function VM({schema:t,path:r}){return!t.title&&!t.description&&!t.const?null:D.jsxs("div",{"data-bitiforms-helptext":!0,"data-field-path":r,children:[t.title&&D.jsx("h4",{children:t.title}),t.description||t.const||""]})}const YM=()=>null;function QM({suffix:t="",...r}){const{$bitiforms:a,onBlur:i,onChange:o,error:s,schema:f,id:d,name:h,value:v,disabled:y}=_o(r,KM),S=f.minimum||0,p=f.maximum||Number.MAX_SAFE_INTEGER,g=w=>{const x=w.currentTarget.name;switch(w.key){case"ArrowDown":return o({target:{name:x,value:Math.max(+v-1,S)}});case"ArrowUp":return o({target:{name:x,value:Math.min(+v+1,p)}})}};return D.jsx(vf,{"data-field-path":r.path,type:"tel",inputMode:"numeric",pattern:"[0-9]*",id:d,name:h,autoComplete:"off",placeholder:a.placeholder,error:s,label:f.title,autoFocus:a.autoFocus,...a.widgetProps,hint:f.description,value:v==null||v===""?"":v,onBlur:i,onChange:w=>{o({target:{name:w.currentTarget.name,value:w.currentTarget.value}})},onKeyDown:g,min:S,max:p,disabled:y,endAdornment:t})}function KM(t){if(typeof t=="number")return t;let r=t;const a=t.lastIndexOf(",");if(a>-1&&(r=r.slice(0,a)),r=r.replace(/\D+/g,""),r.trim()==="")return null;const i=r.slice(0,15);return parseInt(i,10)}function GM(t){return D.jsx(EO,{...t})}const XM={email:"email"};function ZM(t){return t.type==="string"&&t.format&&XM[t.format]||"text"}function zx({type:t,...r}){const{$bitiforms:a,onBlur:i,onChange:o,error:s,schema:f,id:d,name:h,value:v,disabled:y}=_o(r),S=ZM(f);return D.jsx(vf,{"data-field-path":r.path,type:t||S,id:d,name:h,placeholder:a.placeholder,error:s,label:f.title,autoFocus:a.autoFocus,hint:f.description,value:v??"",startAdornment:r.startAdornment,endAdornment:r.endAdornment,onBlur:i,onChange:o,disabled:y,...a.widgetProps,autoComplete:typeof a.autoComplete=="string"?a.autoComplete:a.autoComplete===!1?"off":"on"})}function IM(t){const r=Hv(!1);return D.jsx(zx,{...t,type:r.value?"text":"password",endAdornment:D.jsx(ci,{tabIndex:-1,variant:"text",style:{fontSize:32,lineHeight:1,padding:0},onClick:r.toggle,children:r.value?D.jsx(PO,{}):D.jsx(BO,{})})})}const JM=({value:t,label:r,disabled:a})=>D.jsx(WA,{value:t,disabled:a,children:r});function WM({className:t,renderOption:r=JM,texts:a,...i}){const{values:o,fromSchemaValue:s,toSchemaValue:f}=P1(i.schema),{onBlur:d,onChange:h,schema:v,id:y,error:S,name:p,value:g,disabled:w}=_o(i,f);return D.jsxs("div",{"aria-labelledby":`${y}-legend`,"data-field-path":i.path,children:[D.jsx(Sx,{error:!!S,id:`${y}-legend`,children:v.title}),v.description&&D.jsx(Nx,{id:`${y}_description`,children:v.description}),D.jsx(JA,{name:p,id:y,className:t,error:!!S,value:s(g)??"",onChange:h,onBlur:d,disabled:w,children:o.map(([x,R],T)=>D.jsx(E.Fragment,{children:r({value:x,label:R,disabled:w||!1,index:T})},x))}),S&&D.jsx(Fo,{children:a==null?void 0:a["errors.radiogroup.required"]})]})}function e4(t){const{values:r,fromSchemaValue:a,toSchemaValue:i}=P1(t.schema),{id:o,name:s,$bitiforms:f,error:d,schema:h,onChange:v,onBlur:y,value:S,disabled:p}=_o(t,i);return D.jsx(Dx,{"data-field-path":t.path,id:o,name:s,label:h.title,autoFocus:f.autoFocus,error:d,hint:h.description,value:a(S),onChange:v,onBlur:y,disabled:p,children:r.map(([g,w])=>D.jsx("option",{value:g,children:w},g))})}function t4({errors:t,onClose:r,title:a="Failed to submit"}){const{texts:i}=Ym(),o=Object.values(t);return D.jsx(Im,{intent:"error",title:a,onClose:r,children:D.jsx("ul",{children:o.map((s,f)=>D.jsx("li",{children:Wc([s],i)},f))})})}const n4={ArrayWidget:HM,ObjectWidget:GM,CheckboxWidget:kM,CheckboxGroupWidget:UM,DateWidget:FM,HelpTextWidget:VM,HiddenWidget:YM,NumberWidget:QM,PasswordWidget:IM,RadioGroupWidget:WM,SelectWidget:e4,TextInputWidget:zx};var su=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Zi=typeof window>"u"||"Deno"in globalThis;function tr(){}function r4(t,r){return typeof t=="function"?t(r):t}function wm(t){return typeof t=="number"&&t>=0&&t!==1/0}function Lx(t,r){return Math.max(t+(r||0)-Date.now(),0)}function kl(t,r){return typeof t=="function"?t(r):t}function vr(t,r){return typeof t=="function"?t(r):t}function Ab(t,r){const{type:a="all",exact:i,fetchStatus:o,predicate:s,queryKey:f,stale:d}=t;if(f){if(i){if(r.queryHash!==$v(f,r.options))return!1}else if(!Co(r.queryKey,f))return!1}if(a!=="all"){const h=r.isActive();if(a==="active"&&!h||a==="inactive"&&h)return!1}return!(typeof d=="boolean"&&r.isStale()!==d||o&&o!==r.state.fetchStatus||s&&!s(r))}function Mb(t,r){const{exact:a,status:i,predicate:o,mutationKey:s}=t;if(s){if(!r.options.mutationKey)return!1;if(a){if(Ii(r.options.mutationKey)!==Ii(s))return!1}else if(!Co(r.options.mutationKey,s))return!1}return!(i&&r.state.status!==i||o&&!o(r))}function $v(t,r){return((r==null?void 0:r.queryKeyHashFn)||Ii)(t)}function Ii(t){return JSON.stringify(t,(r,a)=>Om(a)?Object.keys(a).sort().reduce((i,o)=>(i[o]=a[o],i),{}):a)}function Co(t,r){return t===r?!0:typeof t!=typeof r?!1:t&&r&&typeof t=="object"&&typeof r=="object"?!Object.keys(r).some(a=>!Co(t[a],r[a])):!1}function Hx(t,r){if(t===r)return t;const a=jb(t)&&jb(r);if(a||Om(t)&&Om(r)){const i=a?t:Object.keys(t),o=i.length,s=a?r:Object.keys(r),f=s.length,d=a?[]:{};let h=0;for(let v=0;v<f;v++){const y=a?v:s[v];(!a&&i.includes(y)||a)&&t[y]===void 0&&r[y]===void 0?(d[y]=void 0,h++):(d[y]=Hx(t[y],r[y]),d[y]===t[y]&&t[y]!==void 0&&h++)}return o===f&&h===o?t:d}return r}function kc(t,r){if(!r||Object.keys(t).length!==Object.keys(r).length)return!1;for(const a in t)if(t[a]!==r[a])return!1;return!0}function jb(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function Om(t){if(!_b(t))return!1;const r=t.constructor;if(r===void 0)return!0;const a=r.prototype;return!(!_b(a)||!a.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function _b(t){return Object.prototype.toString.call(t)==="[object Object]"}function a4(t){return new Promise(r=>{setTimeout(r,t)})}function Cm(t,r,a){return typeof a.structuralSharing=="function"?a.structuralSharing(t,r):a.structuralSharing!==!1?Hx(t,r):r}function i4(t,r,a=0){const i=[...t,r];return a&&i.length>a?i.slice(1):i}function l4(t,r,a=0){const i=[r,...t];return a&&i.length>a?i.slice(0,-1):i}var Bv=Symbol();function Ux(t,r){return!t.queryFn&&(r!=null&&r.initialPromise)?()=>r.initialPromise:!t.queryFn||t.queryFn===Bv?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}var qi,Wa,Fl,h1,u4=(h1=class extends su{constructor(){super();De(this,qi);De(this,Wa);De(this,Fl);me(this,Fl,r=>{if(!Zi&&window.addEventListener){const a=()=>r();return window.addEventListener("visibilitychange",a,!1),()=>{window.removeEventListener("visibilitychange",a)}}})}onSubscribe(){L(this,Wa)||this.setEventListener(L(this,Fl))}onUnsubscribe(){var r;this.hasListeners()||((r=L(this,Wa))==null||r.call(this),me(this,Wa,void 0))}setEventListener(r){var a;me(this,Fl,r),(a=L(this,Wa))==null||a.call(this),me(this,Wa,r(i=>{typeof i=="boolean"?this.setFocused(i):this.onFocus()}))}setFocused(r){L(this,qi)!==r&&(me(this,qi,r),this.onFocus())}onFocus(){const r=this.isFocused();this.listeners.forEach(a=>{a(r)})}isFocused(){var r;return typeof L(this,qi)=="boolean"?L(this,qi):((r=globalThis.document)==null?void 0:r.visibilityState)!=="hidden"}},qi=new WeakMap,Wa=new WeakMap,Fl=new WeakMap,h1),Pv=new u4,Vl,ei,Yl,m1,o4=(m1=class extends su{constructor(){super();De(this,Vl,!0);De(this,ei);De(this,Yl);me(this,Yl,r=>{if(!Zi&&window.addEventListener){const a=()=>r(!0),i=()=>r(!1);return window.addEventListener("online",a,!1),window.addEventListener("offline",i,!1),()=>{window.removeEventListener("online",a),window.removeEventListener("offline",i)}}})}onSubscribe(){L(this,ei)||this.setEventListener(L(this,Yl))}onUnsubscribe(){var r;this.hasListeners()||((r=L(this,ei))==null||r.call(this),me(this,ei,void 0))}setEventListener(r){var a;me(this,Yl,r),(a=L(this,ei))==null||a.call(this),me(this,ei,r(this.setOnline.bind(this)))}setOnline(r){L(this,Vl)!==r&&(me(this,Vl,r),this.listeners.forEach(i=>{i(r)}))}isOnline(){return L(this,Vl)}},Vl=new WeakMap,ei=new WeakMap,Yl=new WeakMap,m1),Fc=new o4;function Tm(){let t,r;const a=new Promise((o,s)=>{t=o,r=s});a.status="pending",a.catch(()=>{});function i(o){Object.assign(a,o),delete a.resolve,delete a.reject}return a.resolve=o=>{i({status:"fulfilled",value:o}),t(o)},a.reject=o=>{i({status:"rejected",reason:o}),r(o)},a}function s4(t){return Math.min(1e3*2**t,3e4)}function $x(t){return(t??"online")==="online"?Fc.isOnline():!0}var Bx=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function Zh(t){return t instanceof Bx}function Px(t){let r=!1,a=0,i=!1,o;const s=Tm(),f=x=>{var R;i||(p(new Bx(x)),(R=t.abort)==null||R.call(t))},d=()=>{r=!0},h=()=>{r=!1},v=()=>Pv.isFocused()&&(t.networkMode==="always"||Fc.isOnline())&&t.canRun(),y=()=>$x(t.networkMode)&&t.canRun(),S=x=>{var R;i||(i=!0,(R=t.onSuccess)==null||R.call(t,x),o==null||o(),s.resolve(x))},p=x=>{var R;i||(i=!0,(R=t.onError)==null||R.call(t,x),o==null||o(),s.reject(x))},g=()=>new Promise(x=>{var R;o=T=>{(i||v())&&x(T)},(R=t.onPause)==null||R.call(t)}).then(()=>{var x;o=void 0,i||(x=t.onContinue)==null||x.call(t)}),w=()=>{if(i)return;let x;const R=a===0?t.initialPromise:void 0;try{x=R??t.fn()}catch(T){x=Promise.reject(T)}Promise.resolve(x).then(S).catch(T=>{var q;if(i)return;const A=t.retry??(Zi?0:3),N=t.retryDelay??s4,j=typeof N=="function"?N(a,T):N,O=A===!0||typeof A=="number"&&a<A||typeof A=="function"&&A(a,T);if(r||!O){p(T);return}a++,(q=t.onFail)==null||q.call(t,a,T),a4(j).then(()=>v()?void 0:g()).then(()=>{r?p(T):w()})})};return{promise:s,cancel:f,continue:()=>(o==null||o(),s),cancelRetry:d,continueRetry:h,canStart:y,start:()=>(y()?w():g().then(w),s)}}function c4(){let t=[],r=0,a=d=>{d()},i=d=>{d()},o=d=>setTimeout(d,0);const s=d=>{r?t.push(d):o(()=>{a(d)})},f=()=>{const d=t;t=[],d.length&&o(()=>{i(()=>{d.forEach(h=>{a(h)})})})};return{batch:d=>{let h;r++;try{h=d()}finally{r--,r||f()}return h},batchCalls:d=>(...h)=>{s(()=>{d(...h)})},schedule:s,setNotifyFunction:d=>{a=d},setBatchNotifyFunction:d=>{i=d},setScheduler:d=>{o=d}}}var Bt=c4(),ki,v1,qx=(v1=class{constructor(){De(this,ki)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),wm(this.gcTime)&&me(this,ki,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(Zi?1/0:5*60*1e3))}clearGcTimeout(){L(this,ki)&&(clearTimeout(L(this,ki)),me(this,ki,void 0))}},ki=new WeakMap,v1),Ql,Kl,er,an,Ro,Fi,hr,ca,p1,f4=(p1=class extends qx{constructor(r){super();De(this,hr);De(this,Ql);De(this,Kl);De(this,er);De(this,an);De(this,Ro);De(this,Fi);me(this,Fi,!1),me(this,Ro,r.defaultOptions),this.setOptions(r.options),this.observers=[],me(this,er,r.cache),this.queryKey=r.queryKey,this.queryHash=r.queryHash,me(this,Ql,d4(this.options)),this.state=r.state??L(this,Ql),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var r;return(r=L(this,an))==null?void 0:r.promise}setOptions(r){this.options={...L(this,Ro),...r},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&L(this,er).remove(this)}setData(r,a){const i=Cm(this.state.data,r,this.options);return Ue(this,hr,ca).call(this,{data:i,type:"success",dataUpdatedAt:a==null?void 0:a.updatedAt,manual:a==null?void 0:a.manual}),i}setState(r,a){Ue(this,hr,ca).call(this,{type:"setState",state:r,setStateOptions:a})}cancel(r){var i,o;const a=(i=L(this,an))==null?void 0:i.promise;return(o=L(this,an))==null||o.cancel(r),a?a.then(tr).catch(tr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(L(this,Ql))}isActive(){return this.observers.some(r=>vr(r.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Bv||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(r=>r.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(r=0){return this.state.isInvalidated||this.state.data===void 0||!Lx(this.state.dataUpdatedAt,r)}onFocus(){var a;const r=this.observers.find(i=>i.shouldFetchOnWindowFocus());r==null||r.refetch({cancelRefetch:!1}),(a=L(this,an))==null||a.continue()}onOnline(){var a;const r=this.observers.find(i=>i.shouldFetchOnReconnect());r==null||r.refetch({cancelRefetch:!1}),(a=L(this,an))==null||a.continue()}addObserver(r){this.observers.includes(r)||(this.observers.push(r),this.clearGcTimeout(),L(this,er).notify({type:"observerAdded",query:this,observer:r}))}removeObserver(r){this.observers.includes(r)&&(this.observers=this.observers.filter(a=>a!==r),this.observers.length||(L(this,an)&&(L(this,Fi)?L(this,an).cancel({revert:!0}):L(this,an).cancelRetry()),this.scheduleGc()),L(this,er).notify({type:"observerRemoved",query:this,observer:r}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ue(this,hr,ca).call(this,{type:"invalidate"})}fetch(r,a){var h,v,y;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(a!=null&&a.cancelRefetch))this.cancel({silent:!0});else if(L(this,an))return L(this,an).continueRetry(),L(this,an).promise}if(r&&this.setOptions(r),!this.options.queryFn){const S=this.observers.find(p=>p.options.queryFn);S&&this.setOptions(S.options)}const i=new AbortController,o=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(me(this,Fi,!0),i.signal)})},s=()=>{const S=Ux(this.options,a),p={queryKey:this.queryKey,meta:this.meta};return o(p),me(this,Fi,!1),this.options.persister?this.options.persister(S,p,this):S(p)},f={fetchOptions:a,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:s};o(f),(h=this.options.behavior)==null||h.onFetch(f,this),me(this,Kl,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((v=f.fetchOptions)==null?void 0:v.meta))&&Ue(this,hr,ca).call(this,{type:"fetch",meta:(y=f.fetchOptions)==null?void 0:y.meta});const d=S=>{var p,g,w,x;Zh(S)&&S.silent||Ue(this,hr,ca).call(this,{type:"error",error:S}),Zh(S)||((g=(p=L(this,er).config).onError)==null||g.call(p,S,this),(x=(w=L(this,er).config).onSettled)==null||x.call(w,this.state.data,S,this)),this.scheduleGc()};return me(this,an,Px({initialPromise:a==null?void 0:a.initialPromise,fn:f.fetchFn,abort:i.abort.bind(i),onSuccess:S=>{var p,g,w,x;if(S===void 0){d(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(S)}catch(R){d(R);return}(g=(p=L(this,er).config).onSuccess)==null||g.call(p,S,this),(x=(w=L(this,er).config).onSettled)==null||x.call(w,S,this.state.error,this),this.scheduleGc()},onError:d,onFail:(S,p)=>{Ue(this,hr,ca).call(this,{type:"failed",failureCount:S,error:p})},onPause:()=>{Ue(this,hr,ca).call(this,{type:"pause"})},onContinue:()=>{Ue(this,hr,ca).call(this,{type:"continue"})},retry:f.options.retry,retryDelay:f.options.retryDelay,networkMode:f.options.networkMode,canRun:()=>!0})),L(this,an).start()}},Ql=new WeakMap,Kl=new WeakMap,er=new WeakMap,an=new WeakMap,Ro=new WeakMap,Fi=new WeakMap,hr=new WeakSet,ca=function(r){const a=i=>{switch(r.type){case"failed":return{...i,fetchFailureCount:r.failureCount,fetchFailureReason:r.error};case"pause":return{...i,fetchStatus:"paused"};case"continue":return{...i,fetchStatus:"fetching"};case"fetch":return{...i,...kx(i.data,this.options),fetchMeta:r.meta??null};case"success":return{...i,data:r.data,dataUpdateCount:i.dataUpdateCount+1,dataUpdatedAt:r.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!r.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const o=r.error;return Zh(o)&&o.revert&&L(this,Kl)?{...L(this,Kl),fetchStatus:"idle"}:{...i,error:o,errorUpdateCount:i.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:i.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"};case"invalidate":return{...i,isInvalidated:!0};case"setState":return{...i,...r.state}}};this.state=a(this.state),Bt.batch(()=>{this.observers.forEach(i=>{i.onQueryUpdate()}),L(this,er).notify({query:this,type:"updated",action:r})})},p1);function kx(t,r){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:$x(r.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function d4(t){const r=typeof t.initialData=="function"?t.initialData():t.initialData,a=r!==void 0,i=a?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:r,dataUpdateCount:0,dataUpdatedAt:a?i??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:a?"success":"pending",fetchStatus:"idle"}}var Ar,y1,h4=(y1=class extends su{constructor(r={}){super();De(this,Ar);this.config=r,me(this,Ar,new Map)}build(r,a,i){const o=a.queryKey,s=a.queryHash??$v(o,a);let f=this.get(s);return f||(f=new f4({cache:this,queryKey:o,queryHash:s,options:r.defaultQueryOptions(a),state:i,defaultOptions:r.getQueryDefaults(o)}),this.add(f)),f}add(r){L(this,Ar).has(r.queryHash)||(L(this,Ar).set(r.queryHash,r),this.notify({type:"added",query:r}))}remove(r){const a=L(this,Ar).get(r.queryHash);a&&(r.destroy(),a===r&&L(this,Ar).delete(r.queryHash),this.notify({type:"removed",query:r}))}clear(){Bt.batch(()=>{this.getAll().forEach(r=>{this.remove(r)})})}get(r){return L(this,Ar).get(r)}getAll(){return[...L(this,Ar).values()]}find(r){const a={exact:!0,...r};return this.getAll().find(i=>Ab(a,i))}findAll(r={}){const a=this.getAll();return Object.keys(r).length>0?a.filter(i=>Ab(r,i)):a}notify(r){Bt.batch(()=>{this.listeners.forEach(a=>{a(r)})})}onFocus(){Bt.batch(()=>{this.getAll().forEach(r=>{r.onFocus()})})}onOnline(){Bt.batch(()=>{this.getAll().forEach(r=>{r.onOnline()})})}},Ar=new WeakMap,y1),Mr,vn,Vi,jr,Xa,g1,m4=(g1=class extends qx{constructor(r){super();De(this,jr);De(this,Mr);De(this,vn);De(this,Vi);this.mutationId=r.mutationId,me(this,vn,r.mutationCache),me(this,Mr,[]),this.state=r.state||Fx(),this.setOptions(r.options),this.scheduleGc()}setOptions(r){this.options=r,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(r){L(this,Mr).includes(r)||(L(this,Mr).push(r),this.clearGcTimeout(),L(this,vn).notify({type:"observerAdded",mutation:this,observer:r}))}removeObserver(r){me(this,Mr,L(this,Mr).filter(a=>a!==r)),this.scheduleGc(),L(this,vn).notify({type:"observerRemoved",mutation:this,observer:r})}optionalRemove(){L(this,Mr).length||(this.state.status==="pending"?this.scheduleGc():L(this,vn).remove(this))}continue(){var r;return((r=L(this,Vi))==null?void 0:r.continue())??this.execute(this.state.variables)}async execute(r){var o,s,f,d,h,v,y,S,p,g,w,x,R,T,A,N,j,O,q,B;me(this,Vi,Px({fn:()=>this.options.mutationFn?this.options.mutationFn(r):Promise.reject(new Error("No mutationFn found")),onFail:(V,z)=>{Ue(this,jr,Xa).call(this,{type:"failed",failureCount:V,error:z})},onPause:()=>{Ue(this,jr,Xa).call(this,{type:"pause"})},onContinue:()=>{Ue(this,jr,Xa).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>L(this,vn).canRun(this)}));const a=this.state.status==="pending",i=!L(this,Vi).canStart();try{if(!a){Ue(this,jr,Xa).call(this,{type:"pending",variables:r,isPaused:i}),await((s=(o=L(this,vn).config).onMutate)==null?void 0:s.call(o,r,this));const z=await((d=(f=this.options).onMutate)==null?void 0:d.call(f,r));z!==this.state.context&&Ue(this,jr,Xa).call(this,{type:"pending",context:z,variables:r,isPaused:i})}const V=await L(this,Vi).start();return await((v=(h=L(this,vn).config).onSuccess)==null?void 0:v.call(h,V,r,this.state.context,this)),await((S=(y=this.options).onSuccess)==null?void 0:S.call(y,V,r,this.state.context)),await((g=(p=L(this,vn).config).onSettled)==null?void 0:g.call(p,V,null,this.state.variables,this.state.context,this)),await((x=(w=this.options).onSettled)==null?void 0:x.call(w,V,null,r,this.state.context)),Ue(this,jr,Xa).call(this,{type:"success",data:V}),V}catch(V){try{throw await((T=(R=L(this,vn).config).onError)==null?void 0:T.call(R,V,r,this.state.context,this)),await((N=(A=this.options).onError)==null?void 0:N.call(A,V,r,this.state.context)),await((O=(j=L(this,vn).config).onSettled)==null?void 0:O.call(j,void 0,V,this.state.variables,this.state.context,this)),await((B=(q=this.options).onSettled)==null?void 0:B.call(q,void 0,V,r,this.state.context)),V}finally{Ue(this,jr,Xa).call(this,{type:"error",error:V})}}finally{L(this,vn).runNext(this)}}},Mr=new WeakMap,vn=new WeakMap,Vi=new WeakMap,jr=new WeakSet,Xa=function(r){const a=i=>{switch(r.type){case"failed":return{...i,failureCount:r.failureCount,failureReason:r.error};case"pause":return{...i,isPaused:!0};case"continue":return{...i,isPaused:!1};case"pending":return{...i,context:r.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:r.isPaused,status:"pending",variables:r.variables,submittedAt:Date.now()};case"success":return{...i,data:r.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...i,data:void 0,error:r.error,failureCount:i.failureCount+1,failureReason:r.error,isPaused:!1,status:"error"}}};this.state=a(this.state),Bt.batch(()=>{L(this,Mr).forEach(i=>{i.onMutationUpdate(r)}),L(this,vn).notify({mutation:this,type:"updated",action:r})})},g1);function Fx(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Nn,Do,b1,v4=(b1=class extends su{constructor(r={}){super();De(this,Nn);De(this,Do);this.config=r,me(this,Nn,new Map),me(this,Do,Date.now())}build(r,a,i){const o=new m4({mutationCache:this,mutationId:++ic(this,Do)._,options:r.defaultMutationOptions(a),state:i});return this.add(o),o}add(r){const a=vc(r),i=L(this,Nn).get(a)??[];i.push(r),L(this,Nn).set(a,i),this.notify({type:"added",mutation:r})}remove(r){var i;const a=vc(r);if(L(this,Nn).has(a)){const o=(i=L(this,Nn).get(a))==null?void 0:i.filter(s=>s!==r);o&&(o.length===0?L(this,Nn).delete(a):L(this,Nn).set(a,o))}this.notify({type:"removed",mutation:r})}canRun(r){var i;const a=(i=L(this,Nn).get(vc(r)))==null?void 0:i.find(o=>o.state.status==="pending");return!a||a===r}runNext(r){var i;const a=(i=L(this,Nn).get(vc(r)))==null?void 0:i.find(o=>o!==r&&o.state.isPaused);return(a==null?void 0:a.continue())??Promise.resolve()}clear(){Bt.batch(()=>{this.getAll().forEach(r=>{this.remove(r)})})}getAll(){return[...L(this,Nn).values()].flat()}find(r){const a={exact:!0,...r};return this.getAll().find(i=>Mb(a,i))}findAll(r={}){return this.getAll().filter(a=>Mb(r,a))}notify(r){Bt.batch(()=>{this.listeners.forEach(a=>{a(r)})})}resumePausedMutations(){const r=this.getAll().filter(a=>a.state.isPaused);return Bt.batch(()=>Promise.all(r.map(a=>a.continue().catch(tr))))}},Nn=new WeakMap,Do=new WeakMap,b1);function vc(t){var r;return((r=t.options.scope)==null?void 0:r.id)??String(t.mutationId)}function Nb(t){return{onFetch:(r,a)=>{var y,S,p,g,w;const i=r.options,o=(p=(S=(y=r.fetchOptions)==null?void 0:y.meta)==null?void 0:S.fetchMore)==null?void 0:p.direction,s=((g=r.state.data)==null?void 0:g.pages)||[],f=((w=r.state.data)==null?void 0:w.pageParams)||[];let d={pages:[],pageParams:[]},h=0;const v=async()=>{let x=!1;const R=N=>{Object.defineProperty(N,"signal",{enumerable:!0,get:()=>(r.signal.aborted?x=!0:r.signal.addEventListener("abort",()=>{x=!0}),r.signal)})},T=Ux(r.options,r.fetchOptions),A=async(N,j,O)=>{if(x)return Promise.reject();if(j==null&&N.pages.length)return Promise.resolve(N);const q={queryKey:r.queryKey,pageParam:j,direction:O?"backward":"forward",meta:r.options.meta};R(q);const B=await T(q),{maxPages:V}=r.options,z=O?l4:i4;return{pages:z(N.pages,B,V),pageParams:z(N.pageParams,j,V)}};if(o&&s.length){const N=o==="backward",j=N?p4:zb,O={pages:s,pageParams:f},q=j(i,O);d=await A(O,q,N)}else{const N=t??s.length;do{const j=h===0?f[0]??i.initialPageParam:zb(i,d);if(h>0&&j==null)break;d=await A(d,j),h++}while(h<N)}return d};r.options.persister?r.fetchFn=()=>{var x,R;return(R=(x=r.options).persister)==null?void 0:R.call(x,v,{queryKey:r.queryKey,meta:r.options.meta,signal:r.signal},a)}:r.fetchFn=v}}}function zb(t,{pages:r,pageParams:a}){const i=r.length-1;return r.length>0?t.getNextPageParam(r[i],r,a[i],a):void 0}function p4(t,{pages:r,pageParams:a}){var i;return r.length>0?(i=t.getPreviousPageParam)==null?void 0:i.call(t,r[0],r,a[0],a):void 0}var Tt,ti,ni,Gl,Xl,ri,Zl,Il,S1,y4=(S1=class{constructor(t={}){De(this,Tt);De(this,ti);De(this,ni);De(this,Gl);De(this,Xl);De(this,ri);De(this,Zl);De(this,Il);me(this,Tt,t.queryCache||new h4),me(this,ti,t.mutationCache||new v4),me(this,ni,t.defaultOptions||{}),me(this,Gl,new Map),me(this,Xl,new Map),me(this,ri,0)}mount(){ic(this,ri)._++,L(this,ri)===1&&(me(this,Zl,Pv.subscribe(async t=>{t&&(await this.resumePausedMutations(),L(this,Tt).onFocus())})),me(this,Il,Fc.subscribe(async t=>{t&&(await this.resumePausedMutations(),L(this,Tt).onOnline())})))}unmount(){var t,r;ic(this,ri)._--,L(this,ri)===0&&((t=L(this,Zl))==null||t.call(this),me(this,Zl,void 0),(r=L(this,Il))==null||r.call(this),me(this,Il,void 0))}isFetching(t){return L(this,Tt).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return L(this,ti).findAll({...t,status:"pending"}).length}getQueryData(t){var a;const r=this.defaultQueryOptions({queryKey:t});return(a=L(this,Tt).get(r.queryHash))==null?void 0:a.state.data}ensureQueryData(t){const r=this.getQueryData(t.queryKey);if(r===void 0)return this.fetchQuery(t);{const a=this.defaultQueryOptions(t),i=L(this,Tt).build(this,a);return t.revalidateIfStale&&i.isStaleByTime(kl(a.staleTime,i))&&this.prefetchQuery(a),Promise.resolve(r)}}getQueriesData(t){return L(this,Tt).findAll(t).map(({queryKey:r,state:a})=>{const i=a.data;return[r,i]})}setQueryData(t,r,a){const i=this.defaultQueryOptions({queryKey:t}),o=L(this,Tt).get(i.queryHash),s=o==null?void 0:o.state.data,f=r4(r,s);if(f!==void 0)return L(this,Tt).build(this,i).setData(f,{...a,manual:!0})}setQueriesData(t,r,a){return Bt.batch(()=>L(this,Tt).findAll(t).map(({queryKey:i})=>[i,this.setQueryData(i,r,a)]))}getQueryState(t){var a;const r=this.defaultQueryOptions({queryKey:t});return(a=L(this,Tt).get(r.queryHash))==null?void 0:a.state}removeQueries(t){const r=L(this,Tt);Bt.batch(()=>{r.findAll(t).forEach(a=>{r.remove(a)})})}resetQueries(t,r){const a=L(this,Tt),i={type:"active",...t};return Bt.batch(()=>(a.findAll(t).forEach(o=>{o.reset()}),this.refetchQueries(i,r)))}cancelQueries(t,r={}){const a={revert:!0,...r},i=Bt.batch(()=>L(this,Tt).findAll(t).map(o=>o.cancel(a)));return Promise.all(i).then(tr).catch(tr)}invalidateQueries(t,r={}){return Bt.batch(()=>{if(L(this,Tt).findAll(t).forEach(i=>{i.invalidate()}),(t==null?void 0:t.refetchType)==="none")return Promise.resolve();const a={...t,type:(t==null?void 0:t.refetchType)??(t==null?void 0:t.type)??"active"};return this.refetchQueries(a,r)})}refetchQueries(t,r={}){const a={...r,cancelRefetch:r.cancelRefetch??!0},i=Bt.batch(()=>L(this,Tt).findAll(t).filter(o=>!o.isDisabled()).map(o=>{let s=o.fetch(void 0,a);return a.throwOnError||(s=s.catch(tr)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(i).then(tr)}fetchQuery(t){const r=this.defaultQueryOptions(t);r.retry===void 0&&(r.retry=!1);const a=L(this,Tt).build(this,r);return a.isStaleByTime(kl(r.staleTime,a))?a.fetch(r):Promise.resolve(a.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(tr).catch(tr)}fetchInfiniteQuery(t){return t.behavior=Nb(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(tr).catch(tr)}ensureInfiniteQueryData(t){return t.behavior=Nb(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return Fc.isOnline()?L(this,ti).resumePausedMutations():Promise.resolve()}getQueryCache(){return L(this,Tt)}getMutationCache(){return L(this,ti)}getDefaultOptions(){return L(this,ni)}setDefaultOptions(t){me(this,ni,t)}setQueryDefaults(t,r){L(this,Gl).set(Ii(t),{queryKey:t,defaultOptions:r})}getQueryDefaults(t){const r=[...L(this,Gl).values()],a={};return r.forEach(i=>{Co(t,i.queryKey)&&Object.assign(a,i.defaultOptions)}),a}setMutationDefaults(t,r){L(this,Xl).set(Ii(t),{mutationKey:t,defaultOptions:r})}getMutationDefaults(t){const r=[...L(this,Xl).values()];let a={};return r.forEach(i=>{Co(t,i.mutationKey)&&(a={...a,...i.defaultOptions})}),a}defaultQueryOptions(t){if(t._defaulted)return t;const r={...L(this,ni).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return r.queryHash||(r.queryHash=$v(r.queryKey,r)),r.refetchOnReconnect===void 0&&(r.refetchOnReconnect=r.networkMode!=="always"),r.throwOnError===void 0&&(r.throwOnError=!!r.suspense),!r.networkMode&&r.persister&&(r.networkMode="offlineFirst"),r.queryFn===Bv&&(r.enabled=!1),r}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...L(this,ni).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){L(this,Tt).clear(),L(this,ti).clear()}},Tt=new WeakMap,ti=new WeakMap,ni=new WeakMap,Gl=new WeakMap,Xl=new WeakMap,ri=new WeakMap,Zl=new WeakMap,Il=new WeakMap,S1),wn,Ke,Ao,pn,Yi,Jl,ai,_r,Mo,Wl,eu,Qi,Ki,ii,tu,nt,yo,Rm,Dm,Am,Mm,jm,_m,Nm,Yx,x1,Vx=(x1=class extends su{constructor(r,a){super();De(this,nt);De(this,wn);De(this,Ke);De(this,Ao);De(this,pn);De(this,Yi);De(this,Jl);De(this,ai);De(this,_r);De(this,Mo);De(this,Wl);De(this,eu);De(this,Qi);De(this,Ki);De(this,ii);De(this,tu,new Set);this.options=a,me(this,wn,r),me(this,_r,null),me(this,ai,Tm()),this.options.experimental_prefetchInRender||L(this,ai).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(a)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(L(this,Ke).addObserver(this),Lb(L(this,Ke),this.options)?Ue(this,nt,yo).call(this):this.updateResult(),Ue(this,nt,Mm).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return zm(L(this,Ke),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return zm(L(this,Ke),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Ue(this,nt,jm).call(this),Ue(this,nt,_m).call(this),L(this,Ke).removeObserver(this)}setOptions(r,a){const i=this.options,o=L(this,Ke);if(this.options=L(this,wn).defaultQueryOptions(r),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof vr(this.options.enabled,L(this,Ke))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Ue(this,nt,Nm).call(this),L(this,Ke).setOptions(this.options),i._defaulted&&!kc(this.options,i)&&L(this,wn).getQueryCache().notify({type:"observerOptionsUpdated",query:L(this,Ke),observer:this});const s=this.hasListeners();s&&Hb(L(this,Ke),o,this.options,i)&&Ue(this,nt,yo).call(this),this.updateResult(a),s&&(L(this,Ke)!==o||vr(this.options.enabled,L(this,Ke))!==vr(i.enabled,L(this,Ke))||kl(this.options.staleTime,L(this,Ke))!==kl(i.staleTime,L(this,Ke)))&&Ue(this,nt,Rm).call(this);const f=Ue(this,nt,Dm).call(this);s&&(L(this,Ke)!==o||vr(this.options.enabled,L(this,Ke))!==vr(i.enabled,L(this,Ke))||f!==L(this,ii))&&Ue(this,nt,Am).call(this,f)}getOptimisticResult(r){const a=L(this,wn).getQueryCache().build(L(this,wn),r),i=this.createResult(a,r);return b4(this,i)&&(me(this,pn,i),me(this,Jl,this.options),me(this,Yi,L(this,Ke).state)),i}getCurrentResult(){return L(this,pn)}trackResult(r,a){const i={};return Object.keys(r).forEach(o=>{Object.defineProperty(i,o,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(o),a==null||a(o),r[o])})}),i}trackProp(r){L(this,tu).add(r)}getCurrentQuery(){return L(this,Ke)}refetch({...r}={}){return this.fetch({...r})}fetchOptimistic(r){const a=L(this,wn).defaultQueryOptions(r),i=L(this,wn).getQueryCache().build(L(this,wn),a);return i.fetch().then(()=>this.createResult(i,a))}fetch(r){return Ue(this,nt,yo).call(this,{...r,cancelRefetch:r.cancelRefetch??!0}).then(()=>(this.updateResult(),L(this,pn)))}createResult(r,a){var V;const i=L(this,Ke),o=this.options,s=L(this,pn),f=L(this,Yi),d=L(this,Jl),v=r!==i?r.state:L(this,Ao),{state:y}=r;let S={...y},p=!1,g;if(a._optimisticResults){const z=this.hasListeners(),X=!z&&Lb(r,a),te=z&&Hb(r,i,a,o);(X||te)&&(S={...S,...kx(y.data,r.options)}),a._optimisticResults==="isRestoring"&&(S.fetchStatus="idle")}let{error:w,errorUpdatedAt:x,status:R}=S;if(a.select&&S.data!==void 0)if(s&&S.data===(f==null?void 0:f.data)&&a.select===L(this,Mo))g=L(this,Wl);else try{me(this,Mo,a.select),g=a.select(S.data),g=Cm(s==null?void 0:s.data,g,a),me(this,Wl,g),me(this,_r,null)}catch(z){me(this,_r,z)}else g=S.data;if(a.placeholderData!==void 0&&g===void 0&&R==="pending"){let z;if(s!=null&&s.isPlaceholderData&&a.placeholderData===(d==null?void 0:d.placeholderData))z=s.data;else if(z=typeof a.placeholderData=="function"?a.placeholderData((V=L(this,eu))==null?void 0:V.state.data,L(this,eu)):a.placeholderData,a.select&&z!==void 0)try{z=a.select(z),me(this,_r,null)}catch(X){me(this,_r,X)}z!==void 0&&(R="success",g=Cm(s==null?void 0:s.data,z,a),p=!0)}L(this,_r)&&(w=L(this,_r),g=L(this,Wl),x=Date.now(),R="error");const T=S.fetchStatus==="fetching",A=R==="pending",N=R==="error",j=A&&T,O=g!==void 0,B={status:R,fetchStatus:S.fetchStatus,isPending:A,isSuccess:R==="success",isError:N,isInitialLoading:j,isLoading:j,data:g,dataUpdatedAt:S.dataUpdatedAt,error:w,errorUpdatedAt:x,failureCount:S.fetchFailureCount,failureReason:S.fetchFailureReason,errorUpdateCount:S.errorUpdateCount,isFetched:S.dataUpdateCount>0||S.errorUpdateCount>0,isFetchedAfterMount:S.dataUpdateCount>v.dataUpdateCount||S.errorUpdateCount>v.errorUpdateCount,isFetching:T,isRefetching:T&&!A,isLoadingError:N&&!O,isPaused:S.fetchStatus==="paused",isPlaceholderData:p,isRefetchError:N&&O,isStale:qv(r,a),refetch:this.refetch,promise:L(this,ai)};if(this.options.experimental_prefetchInRender){const z=fe=>{B.status==="error"?fe.reject(B.error):B.data!==void 0&&fe.resolve(B.data)},X=()=>{const fe=me(this,ai,B.promise=Tm());z(fe)},te=L(this,ai);switch(te.status){case"pending":r.queryHash===i.queryHash&&z(te);break;case"fulfilled":(B.status==="error"||B.data!==te.value)&&X();break;case"rejected":(B.status!=="error"||B.error!==te.reason)&&X();break}}return B}updateResult(r){const a=L(this,pn),i=this.createResult(L(this,Ke),this.options);if(me(this,Yi,L(this,Ke).state),me(this,Jl,this.options),L(this,Yi).data!==void 0&&me(this,eu,L(this,Ke)),kc(i,a))return;me(this,pn,i);const o={},s=()=>{if(!a)return!0;const{notifyOnChangeProps:f}=this.options,d=typeof f=="function"?f():f;if(d==="all"||!d&&!L(this,tu).size)return!0;const h=new Set(d??L(this,tu));return this.options.throwOnError&&h.add("error"),Object.keys(L(this,pn)).some(v=>{const y=v;return L(this,pn)[y]!==a[y]&&h.has(y)})};(r==null?void 0:r.listeners)!==!1&&s()&&(o.listeners=!0),Ue(this,nt,Yx).call(this,{...o,...r})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Ue(this,nt,Mm).call(this)}},wn=new WeakMap,Ke=new WeakMap,Ao=new WeakMap,pn=new WeakMap,Yi=new WeakMap,Jl=new WeakMap,ai=new WeakMap,_r=new WeakMap,Mo=new WeakMap,Wl=new WeakMap,eu=new WeakMap,Qi=new WeakMap,Ki=new WeakMap,ii=new WeakMap,tu=new WeakMap,nt=new WeakSet,yo=function(r){Ue(this,nt,Nm).call(this);let a=L(this,Ke).fetch(this.options,r);return r!=null&&r.throwOnError||(a=a.catch(tr)),a},Rm=function(){Ue(this,nt,jm).call(this);const r=kl(this.options.staleTime,L(this,Ke));if(Zi||L(this,pn).isStale||!wm(r))return;const i=Lx(L(this,pn).dataUpdatedAt,r)+1;me(this,Qi,setTimeout(()=>{L(this,pn).isStale||this.updateResult()},i))},Dm=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(L(this,Ke)):this.options.refetchInterval)??!1},Am=function(r){Ue(this,nt,_m).call(this),me(this,ii,r),!(Zi||vr(this.options.enabled,L(this,Ke))===!1||!wm(L(this,ii))||L(this,ii)===0)&&me(this,Ki,setInterval(()=>{(this.options.refetchIntervalInBackground||Pv.isFocused())&&Ue(this,nt,yo).call(this)},L(this,ii)))},Mm=function(){Ue(this,nt,Rm).call(this),Ue(this,nt,Am).call(this,Ue(this,nt,Dm).call(this))},jm=function(){L(this,Qi)&&(clearTimeout(L(this,Qi)),me(this,Qi,void 0))},_m=function(){L(this,Ki)&&(clearInterval(L(this,Ki)),me(this,Ki,void 0))},Nm=function(){const r=L(this,wn).getQueryCache().build(L(this,wn),this.options);if(r===L(this,Ke))return;const a=L(this,Ke);me(this,Ke,r),me(this,Ao,r.state),this.hasListeners()&&(a==null||a.removeObserver(this),r.addObserver(this))},Yx=function(r){Bt.batch(()=>{r.listeners&&this.listeners.forEach(a=>{a(L(this,pn))}),L(this,wn).getQueryCache().notify({query:L(this,Ke),type:"observerResultsUpdated"})})},x1);function g4(t,r){return vr(r.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&r.retryOnMount===!1)}function Lb(t,r){return g4(t,r)||t.state.data!==void 0&&zm(t,r,r.refetchOnMount)}function zm(t,r,a){if(vr(r.enabled,t)!==!1){const i=typeof a=="function"?a(t):a;return i==="always"||i!==!1&&qv(t,r)}return!1}function Hb(t,r,a,i){return(t!==r||vr(i.enabled,t)===!1)&&(!a.suspense||t.state.status!=="error")&&qv(t,a)}function qv(t,r){return vr(r.enabled,t)!==!1&&t.isStaleByTime(kl(r.staleTime,t))}function b4(t,r){return!kc(t.getCurrentResult(),r)}var li,ui,On,fa,ma,wc,Lm,E1,S4=(E1=class extends su{constructor(a,i){super();De(this,ma);De(this,li);De(this,ui);De(this,On);De(this,fa);me(this,li,a),this.setOptions(i),this.bindMethods(),Ue(this,ma,wc).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(a){var o;const i=this.options;this.options=L(this,li).defaultMutationOptions(a),kc(this.options,i)||L(this,li).getMutationCache().notify({type:"observerOptionsUpdated",mutation:L(this,On),observer:this}),i!=null&&i.mutationKey&&this.options.mutationKey&&Ii(i.mutationKey)!==Ii(this.options.mutationKey)?this.reset():((o=L(this,On))==null?void 0:o.state.status)==="pending"&&L(this,On).setOptions(this.options)}onUnsubscribe(){var a;this.hasListeners()||(a=L(this,On))==null||a.removeObserver(this)}onMutationUpdate(a){Ue(this,ma,wc).call(this),Ue(this,ma,Lm).call(this,a)}getCurrentResult(){return L(this,ui)}reset(){var a;(a=L(this,On))==null||a.removeObserver(this),me(this,On,void 0),Ue(this,ma,wc).call(this),Ue(this,ma,Lm).call(this)}mutate(a,i){var o;return me(this,fa,i),(o=L(this,On))==null||o.removeObserver(this),me(this,On,L(this,li).getMutationCache().build(L(this,li),this.options)),L(this,On).addObserver(this),L(this,On).execute(a)}},li=new WeakMap,ui=new WeakMap,On=new WeakMap,fa=new WeakMap,ma=new WeakSet,wc=function(){var i;const a=((i=L(this,On))==null?void 0:i.state)??Fx();me(this,ui,{...a,isPending:a.status==="pending",isSuccess:a.status==="success",isError:a.status==="error",isIdle:a.status==="idle",mutate:this.mutate,reset:this.reset})},Lm=function(a){Bt.batch(()=>{var i,o,s,f,d,h,v,y;if(L(this,fa)&&this.hasListeners()){const S=L(this,ui).variables,p=L(this,ui).context;(a==null?void 0:a.type)==="success"?((o=(i=L(this,fa)).onSuccess)==null||o.call(i,a.data,S,p),(f=(s=L(this,fa)).onSettled)==null||f.call(s,a.data,null,S,p)):(a==null?void 0:a.type)==="error"&&((h=(d=L(this,fa)).onError)==null||h.call(d,a.error,S,p),(y=(v=L(this,fa)).onSettled)==null||y.call(v,void 0,a.error,S,p))}this.listeners.forEach(S=>{S(L(this,ui))})})},E1),Qx=E.createContext(void 0),pf=t=>{const r=E.useContext(Qx);if(!r)throw new Error("No QueryClient set, use QueryClientProvider to set one");return r},x4=({client:t,children:r})=>(E.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),D.jsx(Qx.Provider,{value:t,children:r})),Kx=E.createContext(!1),E4=()=>E.useContext(Kx);Kx.Provider;function w4(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var O4=E.createContext(w4()),C4=()=>E.useContext(O4);function Gx(t,r){return typeof t=="function"?t(...r):!!t}function Hm(){}var T4=(t,r)=>{(t.suspense||t.throwOnError||t.experimental_prefetchInRender)&&(r.isReset()||(t.retryOnMount=!1))},R4=t=>{E.useEffect(()=>{t.clearReset()},[t])},D4=({result:t,errorResetBoundary:r,throwOnError:a,query:i})=>t.isError&&!r.isReset()&&!t.isFetching&&i&&Gx(a,[t.error,i]),A4=(t,r)=>r.state.data===void 0,M4=t=>{t.suspense&&(t.staleTime===void 0&&(t.staleTime=1e3),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3)))},j4=(t,r)=>t.isLoading&&t.isFetching&&!r,_4=(t,r)=>(t==null?void 0:t.suspense)&&r.isPending,Ub=(t,r,a)=>r.fetchOptimistic(t).catch(()=>{a.clearReset()});function Xx(t,r,a){var y,S,p,g,w;const i=pf(),o=E4(),s=C4(),f=i.defaultQueryOptions(t);(S=(y=i.getDefaultOptions().queries)==null?void 0:y._experimental_beforeQuery)==null||S.call(y,f),f._optimisticResults=o?"isRestoring":"optimistic",M4(f),T4(f,s),R4(s);const d=!i.getQueryCache().get(f.queryHash),[h]=E.useState(()=>new r(i,f)),v=h.getOptimisticResult(f);if(E.useSyncExternalStore(E.useCallback(x=>{const R=o?Hm:h.subscribe(Bt.batchCalls(x));return h.updateResult(),R},[h,o]),()=>h.getCurrentResult(),()=>h.getCurrentResult()),E.useEffect(()=>{h.setOptions(f,{listeners:!1})},[f,h]),_4(f,v))throw Ub(f,h,s);if(D4({result:v,errorResetBoundary:s,throwOnError:f.throwOnError,query:i.getQueryCache().get(f.queryHash)}))throw v.error;if((g=(p=i.getDefaultOptions().queries)==null?void 0:p._experimental_afterQuery)==null||g.call(p,f,v),f.experimental_prefetchInRender&&!Zi&&j4(v,o)){const x=d?Ub(f,h,s):(w=i.getQueryCache().get(f.queryHash))==null?void 0:w.promise;x==null||x.catch(Hm).finally(()=>{h.updateResult()})}return f.notifyOnChangeProps?v:h.trackResult(v)}function N4(t,r){return Xx(t,Vx)}function kv(t,r){return Xx({...t,enabled:!0,suspense:!0,throwOnError:A4,placeholderData:void 0},Vx)}function Zx(t,r){const a=pf(),[i]=E.useState(()=>new S4(a,t));E.useEffect(()=>{i.setOptions(t)},[i,t]);const o=E.useSyncExternalStore(E.useCallback(f=>i.subscribe(Bt.batchCalls(f)),[i]),()=>i.getCurrentResult(),()=>i.getCurrentResult()),s=E.useCallback((f,d)=>{i.mutate(f,d).catch(Hm)},[i]);if(o.error&&Gx(i.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:s,mutateAsync:o.mutate}}var Ih={exports:{}},fo={},Jh={exports:{}},Wh={};/**
39
- * @license React
40
- * scheduler.production.js
41
- *
42
- * Copyright (c) Meta Platforms, Inc. and affiliates.
43
- *
44
- * This source code is licensed under the MIT license found in the
45
- * LICENSE file in the root directory of this source tree.
46
- */var $b;function z4(){return $b||($b=1,function(t){function r(U,I){var ne=U.length;U.push(I);e:for(;0<ne;){var K=ne-1>>>1,M=U[K];if(0<o(M,I))U[K]=I,U[ne]=M,ne=K;else break e}}function a(U){return U.length===0?null:U[0]}function i(U){if(U.length===0)return null;var I=U[0],ne=U.pop();if(ne!==I){U[0]=ne;e:for(var K=0,M=U.length,F=M>>>1;K<F;){var se=2*(K+1)-1,de=U[se],ce=se+1,ge=U[ce];if(0>o(de,ne))ce<M&&0>o(ge,de)?(U[K]=ge,U[ce]=ne,K=ce):(U[K]=de,U[se]=ne,K=se);else if(ce<M&&0>o(ge,ne))U[K]=ge,U[ce]=ne,K=ce;else break e}}return I}function o(U,I){var ne=U.sortIndex-I.sortIndex;return ne!==0?ne:U.id-I.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var s=performance;t.unstable_now=function(){return s.now()}}else{var f=Date,d=f.now();t.unstable_now=function(){return f.now()-d}}var h=[],v=[],y=1,S=null,p=3,g=!1,w=!1,x=!1,R=typeof setTimeout=="function"?setTimeout:null,T=typeof clearTimeout=="function"?clearTimeout:null,A=typeof setImmediate<"u"?setImmediate:null;function N(U){for(var I=a(v);I!==null;){if(I.callback===null)i(v);else if(I.startTime<=U)i(v),I.sortIndex=I.expirationTime,r(h,I);else break;I=a(v)}}function j(U){if(x=!1,N(U),!w)if(a(h)!==null)w=!0,ae();else{var I=a(v);I!==null&&ie(j,I.startTime-U)}}var O=!1,q=-1,B=5,V=-1;function z(){return!(t.unstable_now()-V<B)}function X(){if(O){var U=t.unstable_now();V=U;var I=!0;try{e:{w=!1,x&&(x=!1,T(q),q=-1),g=!0;var ne=p;try{t:{for(N(U),S=a(h);S!==null&&!(S.expirationTime>U&&z());){var K=S.callback;if(typeof K=="function"){S.callback=null,p=S.priorityLevel;var M=K(S.expirationTime<=U);if(U=t.unstable_now(),typeof M=="function"){S.callback=M,N(U),I=!0;break t}S===a(h)&&i(h),N(U)}else i(h);S=a(h)}if(S!==null)I=!0;else{var F=a(v);F!==null&&ie(j,F.startTime-U),I=!1}}break e}finally{S=null,p=ne,g=!1}I=void 0}}finally{I?te():O=!1}}}var te;if(typeof A=="function")te=function(){A(X)};else if(typeof MessageChannel<"u"){var fe=new MessageChannel,Z=fe.port2;fe.port1.onmessage=X,te=function(){Z.postMessage(null)}}else te=function(){R(X,0)};function ae(){O||(O=!0,te())}function ie(U,I){q=R(function(){U(t.unstable_now())},I)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(U){U.callback=null},t.unstable_continueExecution=function(){w||g||(w=!0,ae())},t.unstable_forceFrameRate=function(U){0>U||125<U?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):B=0<U?Math.floor(1e3/U):5},t.unstable_getCurrentPriorityLevel=function(){return p},t.unstable_getFirstCallbackNode=function(){return a(h)},t.unstable_next=function(U){switch(p){case 1:case 2:case 3:var I=3;break;default:I=p}var ne=p;p=I;try{return U()}finally{p=ne}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(U,I){switch(U){case 1:case 2:case 3:case 4:case 5:break;default:U=3}var ne=p;p=U;try{return I()}finally{p=ne}},t.unstable_scheduleCallback=function(U,I,ne){var K=t.unstable_now();switch(typeof ne=="object"&&ne!==null?(ne=ne.delay,ne=typeof ne=="number"&&0<ne?K+ne:K):ne=K,U){case 1:var M=-1;break;case 2:M=250;break;case 5:M=1073741823;break;case 4:M=1e4;break;default:M=5e3}return M=ne+M,U={id:y++,callback:I,priorityLevel:U,startTime:ne,expirationTime:M,sortIndex:-1},ne>K?(U.sortIndex=ne,r(v,U),a(h)===null&&U===a(v)&&(x?(T(q),q=-1):x=!0,ie(j,ne-K))):(U.sortIndex=M,r(h,U),w||g||(w=!0,ae())),U},t.unstable_shouldYield=z,t.unstable_wrapCallback=function(U){var I=p;return function(){var ne=p;p=I;try{return U.apply(this,arguments)}finally{p=ne}}}}(Wh)),Wh}var Bb;function L4(){return Bb||(Bb=1,Jh.exports=z4()),Jh.exports}/**
47
- * @license React
48
- * react-dom-client.production.js
49
- *
50
- * Copyright (c) Meta Platforms, Inc. and affiliates.
51
- *
52
- * This source code is licensed under the MIT license found in the
53
- * LICENSE file in the root directory of this source tree.
54
- */var Pb;function H4(){if(Pb)return fo;Pb=1;var t=L4(),r=Gc(),a=FS();function i(e){var n="https://react.dev/errors/"+e;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)n+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+e+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}var s=Symbol.for("react.element"),f=Symbol.for("react.transitional.element"),d=Symbol.for("react.portal"),h=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),y=Symbol.for("react.profiler"),S=Symbol.for("react.provider"),p=Symbol.for("react.consumer"),g=Symbol.for("react.context"),w=Symbol.for("react.forward_ref"),x=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),T=Symbol.for("react.memo"),A=Symbol.for("react.lazy"),N=Symbol.for("react.offscreen"),j=Symbol.for("react.memo_cache_sentinel"),O=Symbol.iterator;function q(e){return e===null||typeof e!="object"?null:(e=O&&e[O]||e["@@iterator"],typeof e=="function"?e:null)}var B=Symbol.for("react.client.reference");function V(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===B?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case h:return"Fragment";case d:return"Portal";case y:return"Profiler";case v:return"StrictMode";case x:return"Suspense";case R:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case g:return(e.displayName||"Context")+".Provider";case p:return(e._context.displayName||"Context")+".Consumer";case w:var n=e.render;return e=e.displayName,e||(e=n.displayName||n.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case T:return n=e.displayName||null,n!==null?n:V(e.type)||"Memo";case A:n=e._payload,e=e._init;try{return V(e(n))}catch{}}return null}var z=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,X=Object.assign,te,fe;function Z(e){if(te===void 0)try{throw Error()}catch(l){var n=l.stack.trim().match(/\n( *(at )?)/);te=n&&n[1]||"",fe=-1<l.stack.indexOf(`
55
- at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
56
- `+te+e+fe}var ae=!1;function ie(e,n){if(!e||ae)return"";ae=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var u={DetermineComponentFrameRoot:function(){try{if(n){var le=function(){throw Error()};if(Object.defineProperty(le.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(le,[])}catch(W){var G=W}Reflect.construct(e,[],le)}else{try{le.call()}catch(W){G=W}e.call(le.prototype)}}else{try{throw Error()}catch(W){G=W}(le=e())&&typeof le.catch=="function"&&le.catch(function(){})}}catch(W){if(W&&G&&typeof W.stack=="string")return[W.stack,G.stack]}return[null,null]}};u.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var c=Object.getOwnPropertyDescriptor(u.DetermineComponentFrameRoot,"name");c&&c.configurable&&Object.defineProperty(u.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var m=u.DetermineComponentFrameRoot(),b=m[0],C=m[1];if(b&&C){var _=b.split(`
57
- `),P=C.split(`
58
- `);for(c=u=0;u<_.length&&!_[u].includes("DetermineComponentFrameRoot");)u++;for(;c<P.length&&!P[c].includes("DetermineComponentFrameRoot");)c++;if(u===_.length||c===P.length)for(u=_.length-1,c=P.length-1;1<=u&&0<=c&&_[u]!==P[c];)c--;for(;1<=u&&0<=c;u--,c--)if(_[u]!==P[c]){if(u!==1||c!==1)do if(u--,c--,0>c||_[u]!==P[c]){var ee=`
59
- `+_[u].replace(" at new "," at ");return e.displayName&&ee.includes("<anonymous>")&&(ee=ee.replace("<anonymous>",e.displayName)),ee}while(1<=u&&0<=c);break}}}finally{ae=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?Z(l):""}function U(e){switch(e.tag){case 26:case 27:case 5:return Z(e.type);case 16:return Z("Lazy");case 13:return Z("Suspense");case 19:return Z("SuspenseList");case 0:case 15:return e=ie(e.type,!1),e;case 11:return e=ie(e.type.render,!1),e;case 1:return e=ie(e.type,!0),e;default:return""}}function I(e){try{var n="";do n+=U(e),e=e.return;while(e);return n}catch(l){return`
60
- Error generating stack: `+l.message+`
61
- `+l.stack}}function ne(e){var n=e,l=e;if(e.alternate)for(;n.return;)n=n.return;else{e=n;do n=e,n.flags&4098&&(l=n.return),e=n.return;while(e)}return n.tag===3?l:null}function K(e){if(e.tag===13){var n=e.memoizedState;if(n===null&&(e=e.alternate,e!==null&&(n=e.memoizedState)),n!==null)return n.dehydrated}return null}function M(e){if(ne(e)!==e)throw Error(i(188))}function F(e){var n=e.alternate;if(!n){if(n=ne(e),n===null)throw Error(i(188));return n!==e?null:e}for(var l=e,u=n;;){var c=l.return;if(c===null)break;var m=c.alternate;if(m===null){if(u=c.return,u!==null){l=u;continue}break}if(c.child===m.child){for(m=c.child;m;){if(m===l)return M(c),e;if(m===u)return M(c),n;m=m.sibling}throw Error(i(188))}if(l.return!==u.return)l=c,u=m;else{for(var b=!1,C=c.child;C;){if(C===l){b=!0,l=c,u=m;break}if(C===u){b=!0,u=c,l=m;break}C=C.sibling}if(!b){for(C=m.child;C;){if(C===l){b=!0,l=m,u=c;break}if(C===u){b=!0,u=m,l=c;break}C=C.sibling}if(!b)throw Error(i(189))}}if(l.alternate!==u)throw Error(i(190))}if(l.tag!==3)throw Error(i(188));return l.stateNode.current===l?e:n}function se(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e;for(e=e.child;e!==null;){if(n=se(e),n!==null)return n;e=e.sibling}return null}var de=Array.isArray,ce=a.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ge={pending:!1,data:null,method:null,action:null},Te=[],mt=-1;function _e(e){return{current:e}}function je(e){0>mt||(e.current=Te[mt],Te[mt]=null,mt--)}function Ne(e,n){mt++,Te[mt]=e.current,e.current=n}var Mt=_e(null),bn=_e(null),ft=_e(null),ln=_e(null);function Cn(e,n){switch(Ne(ft,n),Ne(bn,e),Ne(Mt,null),e=n.nodeType,e){case 9:case 11:n=(n=n.documentElement)&&(n=n.namespaceURI)?Wy(n):0;break;default:if(e=e===8?n.parentNode:n,n=e.tagName,e=e.namespaceURI)e=Wy(e),n=eg(e,n);else switch(n){case"svg":n=1;break;case"math":n=2;break;default:n=0}}je(Mt),Ne(Mt,n)}function en(){je(Mt),je(bn),je(ft)}function Pn(e){e.memoizedState!==null&&Ne(ln,e);var n=Mt.current,l=eg(n,e.type);n!==l&&(Ne(bn,e),Ne(Mt,l))}function be(e){bn.current===e&&(je(Mt),je(bn)),ln.current===e&&(je(ln),Wu._currentValue=ge)}var Fe=Object.prototype.hasOwnProperty,xt=t.unstable_scheduleCallback,Le=t.unstable_cancelCallback,Rt=t.unstable_shouldYield,un=t.unstable_requestPaint,jt=t.unstable_now,on=t.unstable_getCurrentPriorityLevel,sn=t.unstable_ImmediatePriority,cu=t.unstable_UserBlockingPriority,wa=t.unstable_NormalPriority,bf=t.unstable_LowPriority,rr=t.unstable_IdlePriority,Go=t.log,Xo=t.unstable_setDisableYieldValue,Oa=null,cn=null;function Zo(e){if(cn&&typeof cn.onCommitFiberRoot=="function")try{cn.onCommitFiberRoot(Oa,e,void 0,(e.current.flags&128)===128)}catch{}}function Tn(e){if(typeof Go=="function"&&Xo(e),cn&&typeof cn.setStrictMode=="function")try{cn.setStrictMode(Oa,e)}catch{}}var tn=Math.clz32?Math.clz32:Io,fu=Math.log,Sf=Math.LN2;function Io(e){return e>>>=0,e===0?32:31-(fu(e)/Sf|0)|0}var rl=128,yi=4194304;function qn(e){var n=e&42;if(n!==0)return n;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: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&4194176;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 Fr(e,n){var l=e.pendingLanes;if(l===0)return 0;var u=0,c=e.suspendedLanes,m=e.pingedLanes,b=e.warmLanes;e=e.finishedLanes!==0;var C=l&134217727;return C!==0?(l=C&~c,l!==0?u=qn(l):(m&=C,m!==0?u=qn(m):e||(b=C&~b,b!==0&&(u=qn(b))))):(C=l&~c,C!==0?u=qn(C):m!==0?u=qn(m):e||(b=l&~b,b!==0&&(u=qn(b)))),u===0?0:n!==0&&n!==u&&!(n&c)&&(c=u&-u,b=n&-n,c>=b||c===32&&(b&4194176)!==0)?n:u}function gi(e,n){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&n)===0}function xf(e,n){switch(e){case 1:case 2:case 4:case 8:return n+250;case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return n+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 H(){var e=rl;return rl<<=1,!(rl&4194176)&&(rl=128),e}function Y(){var e=yi;return yi<<=1,!(yi&62914560)&&(yi=4194304),e}function J(e){for(var n=[],l=0;31>l;l++)n.push(e);return n}function ue(e,n){e.pendingLanes|=n,n!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function ve(e,n,l,u,c,m){var b=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var C=e.entanglements,_=e.expirationTimes,P=e.hiddenUpdates;for(l=b&~l;0<l;){var ee=31-tn(l),le=1<<ee;C[ee]=0,_[ee]=-1;var G=P[ee];if(G!==null)for(P[ee]=null,ee=0;ee<G.length;ee++){var W=G[ee];W!==null&&(W.lane&=-536870913)}l&=~le}u!==0&&Ee(e,u,0),m!==0&&c===0&&e.tag!==0&&(e.suspendedLanes|=m&~(b&~n))}function Ee(e,n,l){e.pendingLanes|=n,e.suspendedLanes&=~n;var u=31-tn(n);e.entangledLanes|=n,e.entanglements[u]=e.entanglements[u]|1073741824|l&4194218}function Me(e,n){var l=e.entangledLanes|=n;for(e=e.entanglements;l;){var u=31-tn(l),c=1<<u;c&n|e[u]&n&&(e[u]|=n),l&=~c}}function pe(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function Se(){var e=ce.p;return e!==0?e:(e=window.event,e===void 0?32:gg(e.type))}function he(e,n){var l=ce.p;try{return ce.p=e,n()}finally{ce.p=l}}var Re=Math.random().toString(36).slice(2),Ce="__reactFiber$"+Re,Be="__reactProps$"+Re,vt="__reactContainer$"+Re,ut="__reactEvents$"+Re,ot="__reactListeners$"+Re,Dt="__reactHandles$"+Re,Vr="__reactResources$"+Re,ar="__reactMarker$"+Re;function Rn(e){delete e[Ce],delete e[Be],delete e[ut],delete e[ot],delete e[Dt]}function qt(e){var n=e[Ce];if(n)return n;for(var l=e.parentNode;l;){if(n=l[vt]||l[Ce]){if(l=n.alternate,n.child!==null||l!==null&&l.child!==null)for(e=rg(e);e!==null;){if(l=e[Ce])return l;e=rg(e)}return n}e=l,l=e.parentNode}return null}function Er(e){if(e=e[Ce]||e[vt]){var n=e.tag;if(n===5||n===6||n===13||n===26||n===27||n===3)return e}return null}function ir(e){var n=e.tag;if(n===5||n===26||n===27||n===6)return e.stateNode;throw Error(i(33))}function Sn(e){var n=e[Vr];return n||(n=e[Vr]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function gt(e){e[ar]=!0}var bi=new Set,rt={};function pt(e,n){lr(e,n),lr(e+"Capture",n)}function lr(e,n){for(rt[e]=n,e=0;e<n.length;e++)bi.add(n[e])}var fn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Et=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]*$"),Yr={},du={};function Ef(e){return Fe.call(du,e)?!0:Fe.call(Yr,e)?!1:Et.test(e)?du[e]=!0:(Yr[e]=!0,!1)}function Jo(e,n,l){if(Ef(n))if(l===null)e.removeAttribute(n);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(n);return;case"boolean":var u=n.toLowerCase().slice(0,5);if(u!=="data-"&&u!=="aria-"){e.removeAttribute(n);return}}e.setAttribute(n,""+l)}}function Wo(e,n,l){if(l===null)e.removeAttribute(n);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttribute(n,""+l)}}function Qr(e,n,l,u){if(u===null)e.removeAttribute(l);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(n,l,""+u)}}function kn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function np(e){var n=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function w2(e){var n=np(e)?"checked":"value",l=Object.getOwnPropertyDescriptor(e.constructor.prototype,n),u=""+e[n];if(!e.hasOwnProperty(n)&&typeof l<"u"&&typeof l.get=="function"&&typeof l.set=="function"){var c=l.get,m=l.set;return Object.defineProperty(e,n,{configurable:!0,get:function(){return c.call(this)},set:function(b){u=""+b,m.call(this,b)}}),Object.defineProperty(e,n,{enumerable:l.enumerable}),{getValue:function(){return u},setValue:function(b){u=""+b},stopTracking:function(){e._valueTracker=null,delete e[n]}}}}function es(e){e._valueTracker||(e._valueTracker=w2(e))}function rp(e){if(!e)return!1;var n=e._valueTracker;if(!n)return!0;var l=n.getValue(),u="";return e&&(u=np(e)?e.checked?"true":"false":e.value),e=u,e!==l?(n.setValue(e),!0):!1}function ts(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 O2=/[\n"\\]/g;function Fn(e){return e.replace(O2,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function wf(e,n,l,u,c,m,b,C){e.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.type=b:e.removeAttribute("type"),n!=null?b==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+kn(n)):e.value!==""+kn(n)&&(e.value=""+kn(n)):b!=="submit"&&b!=="reset"||e.removeAttribute("value"),n!=null?Of(e,b,kn(n)):l!=null?Of(e,b,kn(l)):u!=null&&e.removeAttribute("value"),c==null&&m!=null&&(e.defaultChecked=!!m),c!=null&&(e.checked=c&&typeof c!="function"&&typeof c!="symbol"),C!=null&&typeof C!="function"&&typeof C!="symbol"&&typeof C!="boolean"?e.name=""+kn(C):e.removeAttribute("name")}function ap(e,n,l,u,c,m,b,C){if(m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"&&(e.type=m),n!=null||l!=null){if(!(m!=="submit"&&m!=="reset"||n!=null))return;l=l!=null?""+kn(l):"",n=n!=null?""+kn(n):l,C||n===e.value||(e.value=n),e.defaultValue=n}u=u??c,u=typeof u!="function"&&typeof u!="symbol"&&!!u,e.checked=C?e.checked:!!u,e.defaultChecked=!!u,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(e.name=b)}function Of(e,n,l){n==="number"&&ts(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function al(e,n,l,u){if(e=e.options,n){n={};for(var c=0;c<l.length;c++)n["$"+l[c]]=!0;for(l=0;l<e.length;l++)c=n.hasOwnProperty("$"+e[l].value),e[l].selected!==c&&(e[l].selected=c),c&&u&&(e[l].defaultSelected=!0)}else{for(l=""+kn(l),n=null,c=0;c<e.length;c++){if(e[c].value===l){e[c].selected=!0,u&&(e[c].defaultSelected=!0);return}n!==null||e[c].disabled||(n=e[c])}n!==null&&(n.selected=!0)}}function ip(e,n,l){if(n!=null&&(n=""+kn(n),n!==e.value&&(e.value=n),l==null)){e.defaultValue!==n&&(e.defaultValue=n);return}e.defaultValue=l!=null?""+kn(l):""}function lp(e,n,l,u){if(n==null){if(u!=null){if(l!=null)throw Error(i(92));if(de(u)){if(1<u.length)throw Error(i(93));u=u[0]}l=u}l==null&&(l=""),n=l}l=kn(n),e.defaultValue=l,u=e.textContent,u===l&&u!==""&&u!==null&&(e.value=u)}function il(e,n){if(n){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=n;return}}e.textContent=n}var C2=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 up(e,n,l){var u=n.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?u?e.setProperty(n,""):n==="float"?e.cssFloat="":e[n]="":u?e.setProperty(n,l):typeof l!="number"||l===0||C2.has(n)?n==="float"?e.cssFloat=l:e[n]=(""+l).trim():e[n]=l+"px"}function op(e,n,l){if(n!=null&&typeof n!="object")throw Error(i(62));if(e=e.style,l!=null){for(var u in l)!l.hasOwnProperty(u)||n!=null&&n.hasOwnProperty(u)||(u.indexOf("--")===0?e.setProperty(u,""):u==="float"?e.cssFloat="":e[u]="");for(var c in n)u=n[c],n.hasOwnProperty(c)&&l[c]!==u&&up(e,c,u)}else for(var m in n)n.hasOwnProperty(m)&&up(e,m,n[m])}function Cf(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 T2=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"]]),R2=/^[\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 ns(e){return R2.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Tf=null;function Rf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ll=null,ul=null;function sp(e){var n=Er(e);if(n&&(e=n.stateNode)){var l=e[Be]||null;e:switch(e=n.stateNode,n.type){case"input":if(wf(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),n=l.name,l.type==="radio"&&n!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Fn(""+n)+'"][type="radio"]'),n=0;n<l.length;n++){var u=l[n];if(u!==e&&u.form===e.form){var c=u[Be]||null;if(!c)throw Error(i(90));wf(u,c.value,c.defaultValue,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name)}}for(n=0;n<l.length;n++)u=l[n],u.form===e.form&&rp(u)}break e;case"textarea":ip(e,l.value,l.defaultValue);break e;case"select":n=l.value,n!=null&&al(e,!!l.multiple,n,!1)}}}var Df=!1;function cp(e,n,l){if(Df)return e(n,l);Df=!0;try{var u=e(n);return u}finally{if(Df=!1,(ll!==null||ul!==null)&&(Bs(),ll&&(n=ll,e=ul,ul=ll=null,sp(n),e)))for(n=0;n<e.length;n++)sp(e[n])}}function hu(e,n){var l=e.stateNode;if(l===null)return null;var u=l[Be]||null;if(u===null)return null;l=u[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(u=!u.disabled)||(e=e.type,u=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!u;break e;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(i(231,n,typeof l));return l}var Af=!1;if(fn)try{var mu={};Object.defineProperty(mu,"passive",{get:function(){Af=!0}}),window.addEventListener("test",mu,mu),window.removeEventListener("test",mu,mu)}catch{Af=!1}var Ca=null,Mf=null,rs=null;function fp(){if(rs)return rs;var e,n=Mf,l=n.length,u,c="value"in Ca?Ca.value:Ca.textContent,m=c.length;for(e=0;e<l&&n[e]===c[e];e++);var b=l-e;for(u=1;u<=b&&n[l-u]===c[m-u];u++);return rs=c.slice(e,1<u?1-u:void 0)}function as(e){var n=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&n===13&&(e=13)):e=n,e===10&&(e=13),32<=e||e===13?e:0}function is(){return!0}function dp(){return!1}function xn(e){function n(l,u,c,m,b){this._reactName=l,this._targetInst=c,this.type=u,this.nativeEvent=m,this.target=b,this.currentTarget=null;for(var C in e)e.hasOwnProperty(C)&&(l=e[C],this[C]=l?l(m):m[C]);return this.isDefaultPrevented=(m.defaultPrevented!=null?m.defaultPrevented:m.returnValue===!1)?is:dp,this.isPropagationStopped=dp,this}return X(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=is)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=is)},persist:function(){},isPersistent:is}),n}var Si={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ls=xn(Si),vu=X({},Si,{view:0,detail:0}),D2=xn(vu),jf,_f,pu,us=X({},vu,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:zf,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!==pu&&(pu&&e.type==="mousemove"?(jf=e.screenX-pu.screenX,_f=e.screenY-pu.screenY):_f=jf=0,pu=e),jf)},movementY:function(e){return"movementY"in e?e.movementY:_f}}),hp=xn(us),A2=X({},us,{dataTransfer:0}),M2=xn(A2),j2=X({},vu,{relatedTarget:0}),Nf=xn(j2),_2=X({},Si,{animationName:0,elapsedTime:0,pseudoElement:0}),N2=xn(_2),z2=X({},Si,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),L2=xn(z2),H2=X({},Si,{data:0}),mp=xn(H2),U2={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},$2={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"},B2={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function P2(e){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(e):(e=B2[e])?!!n[e]:!1}function zf(){return P2}var q2=X({},vu,{key:function(e){if(e.key){var n=U2[e.key]||e.key;if(n!=="Unidentified")return n}return e.type==="keypress"?(e=as(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?$2[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:zf,charCode:function(e){return e.type==="keypress"?as(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?as(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),k2=xn(q2),F2=X({},us,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),vp=xn(F2),V2=X({},vu,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:zf}),Y2=xn(V2),Q2=X({},Si,{propertyName:0,elapsedTime:0,pseudoElement:0}),K2=xn(Q2),G2=X({},us,{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}),X2=xn(G2),Z2=X({},Si,{newState:0,oldState:0}),I2=xn(Z2),J2=[9,13,27,32],Lf=fn&&"CompositionEvent"in window,yu=null;fn&&"documentMode"in document&&(yu=document.documentMode);var W2=fn&&"TextEvent"in window&&!yu,pp=fn&&(!Lf||yu&&8<yu&&11>=yu),yp=" ",gp=!1;function bp(e,n){switch(e){case"keyup":return J2.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Sp(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ol=!1;function eE(e,n){switch(e){case"compositionend":return Sp(n);case"keypress":return n.which!==32?null:(gp=!0,yp);case"textInput":return e=n.data,e===yp&&gp?null:e;default:return null}}function tE(e,n){if(ol)return e==="compositionend"||!Lf&&bp(e,n)?(e=fp(),rs=Mf=Ca=null,ol=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return pp&&n.locale!=="ko"?null:n.data;default:return null}}var nE={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 xp(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n==="input"?!!nE[e.type]:n==="textarea"}function Ep(e,n,l,u){ll?ul?ul.push(u):ul=[u]:ll=u,n=Vs(n,"onChange"),0<n.length&&(l=new ls("onChange","change",null,l,u),e.push({event:l,listeners:n}))}var gu=null,bu=null;function rE(e){Gy(e,0)}function os(e){var n=ir(e);if(rp(n))return e}function wp(e,n){if(e==="change")return n}var Op=!1;if(fn){var Hf;if(fn){var Uf="oninput"in document;if(!Uf){var Cp=document.createElement("div");Cp.setAttribute("oninput","return;"),Uf=typeof Cp.oninput=="function"}Hf=Uf}else Hf=!1;Op=Hf&&(!document.documentMode||9<document.documentMode)}function Tp(){gu&&(gu.detachEvent("onpropertychange",Rp),bu=gu=null)}function Rp(e){if(e.propertyName==="value"&&os(bu)){var n=[];Ep(n,bu,e,Rf(e)),cp(rE,n)}}function aE(e,n,l){e==="focusin"?(Tp(),gu=n,bu=l,gu.attachEvent("onpropertychange",Rp)):e==="focusout"&&Tp()}function iE(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return os(bu)}function lE(e,n){if(e==="click")return os(n)}function uE(e,n){if(e==="input"||e==="change")return os(n)}function oE(e,n){return e===n&&(e!==0||1/e===1/n)||e!==e&&n!==n}var Dn=typeof Object.is=="function"?Object.is:oE;function Su(e,n){if(Dn(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;var l=Object.keys(e),u=Object.keys(n);if(l.length!==u.length)return!1;for(u=0;u<l.length;u++){var c=l[u];if(!Fe.call(n,c)||!Dn(e[c],n[c]))return!1}return!0}function Dp(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Ap(e,n){var l=Dp(e);e=0;for(var u;l;){if(l.nodeType===3){if(u=e+l.textContent.length,e<=n&&u>=n)return{node:l,offset:n-e};e=u}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Dp(l)}}function Mp(e,n){return e&&n?e===n?!0:e&&e.nodeType===3?!1:n&&n.nodeType===3?Mp(e,n.parentNode):"contains"in e?e.contains(n):e.compareDocumentPosition?!!(e.compareDocumentPosition(n)&16):!1:!1}function jp(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var n=ts(e.document);n instanceof e.HTMLIFrameElement;){try{var l=typeof n.contentWindow.location.href=="string"}catch{l=!1}if(l)e=n.contentWindow;else break;n=ts(e.document)}return n}function $f(e){var n=e&&e.nodeName&&e.nodeName.toLowerCase();return n&&(n==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||n==="textarea"||e.contentEditable==="true")}function sE(e,n){var l=jp(n);n=e.focusedElem;var u=e.selectionRange;if(l!==n&&n&&n.ownerDocument&&Mp(n.ownerDocument.documentElement,n)){if(u!==null&&$f(n)){if(e=u.start,l=u.end,l===void 0&&(l=e),"selectionStart"in n)n.selectionStart=e,n.selectionEnd=Math.min(l,n.value.length);else if(l=(e=n.ownerDocument||document)&&e.defaultView||window,l.getSelection){l=l.getSelection();var c=n.textContent.length,m=Math.min(u.start,c);u=u.end===void 0?m:Math.min(u.end,c),!l.extend&&m>u&&(c=u,u=m,m=c),c=Ap(n,m);var b=Ap(n,u);c&&b&&(l.rangeCount!==1||l.anchorNode!==c.node||l.anchorOffset!==c.offset||l.focusNode!==b.node||l.focusOffset!==b.offset)&&(e=e.createRange(),e.setStart(c.node,c.offset),l.removeAllRanges(),m>u?(l.addRange(e),l.extend(b.node,b.offset)):(e.setEnd(b.node,b.offset),l.addRange(e)))}}for(e=[],l=n;l=l.parentNode;)l.nodeType===1&&e.push({element:l,left:l.scrollLeft,top:l.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<e.length;n++)l=e[n],l.element.scrollLeft=l.left,l.element.scrollTop=l.top}}var cE=fn&&"documentMode"in document&&11>=document.documentMode,sl=null,Bf=null,xu=null,Pf=!1;function _p(e,n,l){var u=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Pf||sl==null||sl!==ts(u)||(u=sl,"selectionStart"in u&&$f(u)?u={start:u.selectionStart,end:u.selectionEnd}:(u=(u.ownerDocument&&u.ownerDocument.defaultView||window).getSelection(),u={anchorNode:u.anchorNode,anchorOffset:u.anchorOffset,focusNode:u.focusNode,focusOffset:u.focusOffset}),xu&&Su(xu,u)||(xu=u,u=Vs(Bf,"onSelect"),0<u.length&&(n=new ls("onSelect","select",null,n,l),e.push({event:n,listeners:u}),n.target=sl)))}function xi(e,n){var l={};return l[e.toLowerCase()]=n.toLowerCase(),l["Webkit"+e]="webkit"+n,l["Moz"+e]="moz"+n,l}var cl={animationend:xi("Animation","AnimationEnd"),animationiteration:xi("Animation","AnimationIteration"),animationstart:xi("Animation","AnimationStart"),transitionrun:xi("Transition","TransitionRun"),transitionstart:xi("Transition","TransitionStart"),transitioncancel:xi("Transition","TransitionCancel"),transitionend:xi("Transition","TransitionEnd")},qf={},Np={};fn&&(Np=document.createElement("div").style,"AnimationEvent"in window||(delete cl.animationend.animation,delete cl.animationiteration.animation,delete cl.animationstart.animation),"TransitionEvent"in window||delete cl.transitionend.transition);function Ei(e){if(qf[e])return qf[e];if(!cl[e])return e;var n=cl[e],l;for(l in n)if(n.hasOwnProperty(l)&&l in Np)return qf[e]=n[l];return e}var zp=Ei("animationend"),Lp=Ei("animationiteration"),Hp=Ei("animationstart"),fE=Ei("transitionrun"),dE=Ei("transitionstart"),hE=Ei("transitioncancel"),Up=Ei("transitionend"),$p=new Map,Bp="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 scrollEnd toggle touchMove waiting wheel".split(" ");function ur(e,n){$p.set(e,n),pt(n,[e])}var Vn=[],fl=0,kf=0;function ss(){for(var e=fl,n=kf=fl=0;n<e;){var l=Vn[n];Vn[n++]=null;var u=Vn[n];Vn[n++]=null;var c=Vn[n];Vn[n++]=null;var m=Vn[n];if(Vn[n++]=null,u!==null&&c!==null){var b=u.pending;b===null?c.next=c:(c.next=b.next,b.next=c),u.pending=c}m!==0&&Pp(l,c,m)}}function cs(e,n,l,u){Vn[fl++]=e,Vn[fl++]=n,Vn[fl++]=l,Vn[fl++]=u,kf|=u,e.lanes|=u,e=e.alternate,e!==null&&(e.lanes|=u)}function Ff(e,n,l,u){return cs(e,n,l,u),fs(e)}function Ta(e,n){return cs(e,null,null,n),fs(e)}function Pp(e,n,l){e.lanes|=l;var u=e.alternate;u!==null&&(u.lanes|=l);for(var c=!1,m=e.return;m!==null;)m.childLanes|=l,u=m.alternate,u!==null&&(u.childLanes|=l),m.tag===22&&(e=m.stateNode,e===null||e._visibility&1||(c=!0)),e=m,m=m.return;c&&n!==null&&e.tag===3&&(m=e.stateNode,c=31-tn(l),m=m.hiddenUpdates,e=m[c],e===null?m[c]=[n]:e.push(n),n.lane=l|536870912)}function fs(e){if(50<Qu)throw Qu=0,Xd=null,Error(i(185));for(var n=e.return;n!==null;)e=n,n=e.return;return e.tag===3?e.stateNode:null}var dl={},qp=new WeakMap;function Yn(e,n){if(typeof e=="object"&&e!==null){var l=qp.get(e);return l!==void 0?l:(n={value:e,source:n,stack:I(n)},qp.set(e,n),n)}return{value:e,source:n,stack:I(n)}}var hl=[],ml=0,ds=null,hs=0,Qn=[],Kn=0,wi=null,Kr=1,Gr="";function Oi(e,n){hl[ml++]=hs,hl[ml++]=ds,ds=e,hs=n}function kp(e,n,l){Qn[Kn++]=Kr,Qn[Kn++]=Gr,Qn[Kn++]=wi,wi=e;var u=Kr;e=Gr;var c=32-tn(u)-1;u&=~(1<<c),l+=1;var m=32-tn(n)+c;if(30<m){var b=c-c%5;m=(u&(1<<b)-1).toString(32),u>>=b,c-=b,Kr=1<<32-tn(n)+c|l<<c|u,Gr=m+e}else Kr=1<<m|l<<c|u,Gr=e}function Vf(e){e.return!==null&&(Oi(e,1),kp(e,1,0))}function Yf(e){for(;e===ds;)ds=hl[--ml],hl[ml]=null,hs=hl[--ml],hl[ml]=null;for(;e===wi;)wi=Qn[--Kn],Qn[Kn]=null,Gr=Qn[--Kn],Qn[Kn]=null,Kr=Qn[--Kn],Qn[Kn]=null}var dn=null,Qt=null,Je=!1,or=null,wr=!1,Qf=Error(i(519));function Ci(e){var n=Error(i(418,""));throw Ou(Yn(n,e)),Qf}function Fp(e){var n=e.stateNode,l=e.type,u=e.memoizedProps;switch(n[Ce]=e,n[Be]=u,l){case"dialog":Qe("cancel",n),Qe("close",n);break;case"iframe":case"object":case"embed":Qe("load",n);break;case"video":case"audio":for(l=0;l<Gu.length;l++)Qe(Gu[l],n);break;case"source":Qe("error",n);break;case"img":case"image":case"link":Qe("error",n),Qe("load",n);break;case"details":Qe("toggle",n);break;case"input":Qe("invalid",n),ap(n,u.value,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name,!0),es(n);break;case"select":Qe("invalid",n);break;case"textarea":Qe("invalid",n),lp(n,u.value,u.defaultValue,u.children),es(n)}l=u.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||n.textContent===""+l||u.suppressHydrationWarning===!0||Jy(n.textContent,l)?(u.popover!=null&&(Qe("beforetoggle",n),Qe("toggle",n)),u.onScroll!=null&&Qe("scroll",n),u.onScrollEnd!=null&&Qe("scrollend",n),u.onClick!=null&&(n.onclick=Ys),n=!0):n=!1,n||Ci(e)}function Vp(e){for(dn=e.return;dn;)switch(dn.tag){case 3:case 27:wr=!0;return;case 5:case 13:wr=!1;return;default:dn=dn.return}}function Eu(e){if(e!==dn)return!1;if(!Je)return Vp(e),Je=!0,!1;var n=!1,l;if((l=e.tag!==3&&e.tag!==27)&&((l=e.tag===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||dh(e.type,e.memoizedProps)),l=!l),l&&(n=!0),n&&Qt&&Ci(e),Vp(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(i(317));e:{for(e=e.nextSibling,n=0;e;){if(e.nodeType===8)if(l=e.data,l==="/$"){if(n===0){Qt=cr(e.nextSibling);break e}n--}else l!=="$"&&l!=="$!"&&l!=="$?"||n++;e=e.nextSibling}Qt=null}}else Qt=dn?cr(e.stateNode.nextSibling):null;return!0}function wu(){Qt=dn=null,Je=!1}function Ou(e){or===null?or=[e]:or.push(e)}var Cu=Error(i(460)),Yp=Error(i(474)),Kf={then:function(){}};function Qp(e){return e=e.status,e==="fulfilled"||e==="rejected"}function ms(){}function Kp(e,n,l){switch(l=e[l],l===void 0?e.push(n):l!==n&&(n.then(ms,ms),n=l),n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,e===Cu?Error(i(483)):e;default:if(typeof n.status=="string")n.then(ms,ms);else{if(e=dt,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=n,e.status="pending",e.then(function(u){if(n.status==="pending"){var c=n;c.status="fulfilled",c.value=u}},function(u){if(n.status==="pending"){var c=n;c.status="rejected",c.reason=u}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw e=n.reason,e===Cu?Error(i(483)):e}throw Tu=n,Cu}}var Tu=null;function Gp(){if(Tu===null)throw Error(i(459));var e=Tu;return Tu=null,e}var vl=null,Ru=0;function vs(e){var n=Ru;return Ru+=1,vl===null&&(vl=[]),Kp(vl,e,n)}function Du(e,n){n=n.props.ref,e.ref=n!==void 0?n:null}function ps(e,n){throw n.$$typeof===s?Error(i(525)):(e=Object.prototype.toString.call(n),Error(i(31,e==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":e)))}function Xp(e){var n=e._init;return n(e._payload)}function Zp(e){function n(k,$){if(e){var Q=k.deletions;Q===null?(k.deletions=[$],k.flags|=16):Q.push($)}}function l(k,$){if(!e)return null;for(;$!==null;)n(k,$),$=$.sibling;return null}function u(k){for(var $=new Map;k!==null;)k.key!==null?$.set(k.key,k):$.set(k.index,k),k=k.sibling;return $}function c(k,$){return k=$a(k,$),k.index=0,k.sibling=null,k}function m(k,$,Q){return k.index=Q,e?(Q=k.alternate,Q!==null?(Q=Q.index,Q<$?(k.flags|=33554434,$):Q):(k.flags|=33554434,$)):(k.flags|=1048576,$)}function b(k){return e&&k.alternate===null&&(k.flags|=33554434),k}function C(k,$,Q,re){return $===null||$.tag!==6?($=qd(Q,k.mode,re),$.return=k,$):($=c($,Q),$.return=k,$)}function _(k,$,Q,re){var ye=Q.type;return ye===h?ee(k,$,Q.props.children,re,Q.key):$!==null&&($.elementType===ye||typeof ye=="object"&&ye!==null&&ye.$$typeof===A&&Xp(ye)===$.type)?($=c($,Q.props),Du($,Q),$.return=k,$):($=zs(Q.type,Q.key,Q.props,null,k.mode,re),Du($,Q),$.return=k,$)}function P(k,$,Q,re){return $===null||$.tag!==4||$.stateNode.containerInfo!==Q.containerInfo||$.stateNode.implementation!==Q.implementation?($=kd(Q,k.mode,re),$.return=k,$):($=c($,Q.children||[]),$.return=k,$)}function ee(k,$,Q,re,ye){return $===null||$.tag!==7?($=Li(Q,k.mode,re,ye),$.return=k,$):($=c($,Q),$.return=k,$)}function le(k,$,Q){if(typeof $=="string"&&$!==""||typeof $=="number"||typeof $=="bigint")return $=qd(""+$,k.mode,Q),$.return=k,$;if(typeof $=="object"&&$!==null){switch($.$$typeof){case f:return Q=zs($.type,$.key,$.props,null,k.mode,Q),Du(Q,$),Q.return=k,Q;case d:return $=kd($,k.mode,Q),$.return=k,$;case A:var re=$._init;return $=re($._payload),le(k,$,Q)}if(de($)||q($))return $=Li($,k.mode,Q,null),$.return=k,$;if(typeof $.then=="function")return le(k,vs($),Q);if($.$$typeof===g)return le(k,js(k,$),Q);ps(k,$)}return null}function G(k,$,Q,re){var ye=$!==null?$.key:null;if(typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint")return ye!==null?null:C(k,$,""+Q,re);if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case f:return Q.key===ye?_(k,$,Q,re):null;case d:return Q.key===ye?P(k,$,Q,re):null;case A:return ye=Q._init,Q=ye(Q._payload),G(k,$,Q,re)}if(de(Q)||q(Q))return ye!==null?null:ee(k,$,Q,re,null);if(typeof Q.then=="function")return G(k,$,vs(Q),re);if(Q.$$typeof===g)return G(k,$,js(k,Q),re);ps(k,Q)}return null}function W(k,$,Q,re,ye){if(typeof re=="string"&&re!==""||typeof re=="number"||typeof re=="bigint")return k=k.get(Q)||null,C($,k,""+re,ye);if(typeof re=="object"&&re!==null){switch(re.$$typeof){case f:return k=k.get(re.key===null?Q:re.key)||null,_($,k,re,ye);case d:return k=k.get(re.key===null?Q:re.key)||null,P($,k,re,ye);case A:var ke=re._init;return re=ke(re._payload),W(k,$,Q,re,ye)}if(de(re)||q(re))return k=k.get(Q)||null,ee($,k,re,ye,null);if(typeof re.then=="function")return W(k,$,Q,vs(re),ye);if(re.$$typeof===g)return W(k,$,Q,js($,re),ye);ps($,re)}return null}function xe(k,$,Q,re){for(var ye=null,ke=null,Oe=$,Ae=$=0,Vt=null;Oe!==null&&Ae<Q.length;Ae++){Oe.index>Ae?(Vt=Oe,Oe=null):Vt=Oe.sibling;var We=G(k,Oe,Q[Ae],re);if(We===null){Oe===null&&(Oe=Vt);break}e&&Oe&&We.alternate===null&&n(k,Oe),$=m(We,$,Ae),ke===null?ye=We:ke.sibling=We,ke=We,Oe=Vt}if(Ae===Q.length)return l(k,Oe),Je&&Oi(k,Ae),ye;if(Oe===null){for(;Ae<Q.length;Ae++)Oe=le(k,Q[Ae],re),Oe!==null&&($=m(Oe,$,Ae),ke===null?ye=Oe:ke.sibling=Oe,ke=Oe);return Je&&Oi(k,Ae),ye}for(Oe=u(Oe);Ae<Q.length;Ae++)Vt=W(Oe,k,Ae,Q[Ae],re),Vt!==null&&(e&&Vt.alternate!==null&&Oe.delete(Vt.key===null?Ae:Vt.key),$=m(Vt,$,Ae),ke===null?ye=Vt:ke.sibling=Vt,ke=Vt);return e&&Oe.forEach(function(Ya){return n(k,Ya)}),Je&&Oi(k,Ae),ye}function ze(k,$,Q,re){if(Q==null)throw Error(i(151));for(var ye=null,ke=null,Oe=$,Ae=$=0,Vt=null,We=Q.next();Oe!==null&&!We.done;Ae++,We=Q.next()){Oe.index>Ae?(Vt=Oe,Oe=null):Vt=Oe.sibling;var Ya=G(k,Oe,We.value,re);if(Ya===null){Oe===null&&(Oe=Vt);break}e&&Oe&&Ya.alternate===null&&n(k,Oe),$=m(Ya,$,Ae),ke===null?ye=Ya:ke.sibling=Ya,ke=Ya,Oe=Vt}if(We.done)return l(k,Oe),Je&&Oi(k,Ae),ye;if(Oe===null){for(;!We.done;Ae++,We=Q.next())We=le(k,We.value,re),We!==null&&($=m(We,$,Ae),ke===null?ye=We:ke.sibling=We,ke=We);return Je&&Oi(k,Ae),ye}for(Oe=u(Oe);!We.done;Ae++,We=Q.next())We=W(Oe,k,Ae,We.value,re),We!==null&&(e&&We.alternate!==null&&Oe.delete(We.key===null?Ae:We.key),$=m(We,$,Ae),ke===null?ye=We:ke.sibling=We,ke=We);return e&&Oe.forEach(function(Rw){return n(k,Rw)}),Je&&Oi(k,Ae),ye}function Ct(k,$,Q,re){if(typeof Q=="object"&&Q!==null&&Q.type===h&&Q.key===null&&(Q=Q.props.children),typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case f:e:{for(var ye=Q.key;$!==null;){if($.key===ye){if(ye=Q.type,ye===h){if($.tag===7){l(k,$.sibling),re=c($,Q.props.children),re.return=k,k=re;break e}}else if($.elementType===ye||typeof ye=="object"&&ye!==null&&ye.$$typeof===A&&Xp(ye)===$.type){l(k,$.sibling),re=c($,Q.props),Du(re,Q),re.return=k,k=re;break e}l(k,$);break}else n(k,$);$=$.sibling}Q.type===h?(re=Li(Q.props.children,k.mode,re,Q.key),re.return=k,k=re):(re=zs(Q.type,Q.key,Q.props,null,k.mode,re),Du(re,Q),re.return=k,k=re)}return b(k);case d:e:{for(ye=Q.key;$!==null;){if($.key===ye)if($.tag===4&&$.stateNode.containerInfo===Q.containerInfo&&$.stateNode.implementation===Q.implementation){l(k,$.sibling),re=c($,Q.children||[]),re.return=k,k=re;break e}else{l(k,$);break}else n(k,$);$=$.sibling}re=kd(Q,k.mode,re),re.return=k,k=re}return b(k);case A:return ye=Q._init,Q=ye(Q._payload),Ct(k,$,Q,re)}if(de(Q))return xe(k,$,Q,re);if(q(Q)){if(ye=q(Q),typeof ye!="function")throw Error(i(150));return Q=ye.call(Q),ze(k,$,Q,re)}if(typeof Q.then=="function")return Ct(k,$,vs(Q),re);if(Q.$$typeof===g)return Ct(k,$,js(k,Q),re);ps(k,Q)}return typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint"?(Q=""+Q,$!==null&&$.tag===6?(l(k,$.sibling),re=c($,Q),re.return=k,k=re):(l(k,$),re=qd(Q,k.mode,re),re.return=k,k=re),b(k)):l(k,$)}return function(k,$,Q,re){try{Ru=0;var ye=Ct(k,$,Q,re);return vl=null,ye}catch(Oe){if(Oe===Cu)throw Oe;var ke=In(29,Oe,null,k.mode);return ke.lanes=re,ke.return=k,ke}finally{}}}var Ti=Zp(!0),Ip=Zp(!1),pl=_e(null),ys=_e(0);function Jp(e,n){e=ia,Ne(ys,e),Ne(pl,n),ia=e|n.baseLanes}function Gf(){Ne(ys,ia),Ne(pl,pl.current)}function Xf(){ia=ys.current,je(pl),je(ys)}var Gn=_e(null),Or=null;function Ra(e){var n=e.alternate;Ne(Ut,Ut.current&1),Ne(Gn,e),Or===null&&(n===null||pl.current!==null||n.memoizedState!==null)&&(Or=e)}function Wp(e){if(e.tag===22){if(Ne(Ut,Ut.current),Ne(Gn,e),Or===null){var n=e.alternate;n!==null&&n.memoizedState!==null&&(Or=e)}}else Da()}function Da(){Ne(Ut,Ut.current),Ne(Gn,Gn.current)}function Xr(e){je(Gn),Or===e&&(Or=null),je(Ut)}var Ut=_e(0);function gs(e){for(var n=e;n!==null;){if(n.tag===13){var l=n.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return n}else if(n.tag===19&&n.memoizedProps.revealOrder!==void 0){if(n.flags&128)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var mE=typeof AbortController<"u"?AbortController:function(){var e=[],n=this.signal={aborted:!1,addEventListener:function(l,u){e.push(u)}};this.abort=function(){n.aborted=!0,e.forEach(function(l){return l()})}},vE=t.unstable_scheduleCallback,pE=t.unstable_NormalPriority,$t={$$typeof:g,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Zf(){return{controller:new mE,data:new Map,refCount:0}}function Au(e){e.refCount--,e.refCount===0&&vE(pE,function(){e.controller.abort()})}var Mu=null,If=0,yl=0,gl=null;function yE(e,n){if(Mu===null){var l=Mu=[];If=0,yl=rh(),gl={status:"pending",value:void 0,then:function(u){l.push(u)}}}return If++,n.then(e0,e0),n}function e0(){if(--If===0&&Mu!==null){gl!==null&&(gl.status="fulfilled");var e=Mu;Mu=null,yl=0,gl=null;for(var n=0;n<e.length;n++)(0,e[n])()}}function gE(e,n){var l=[],u={status:"pending",value:null,reason:null,then:function(c){l.push(c)}};return e.then(function(){u.status="fulfilled",u.value=n;for(var c=0;c<l.length;c++)(0,l[c])(n)},function(c){for(u.status="rejected",u.reason=c,c=0;c<l.length;c++)(0,l[c])(void 0)}),u}var t0=z.S;z.S=function(e,n){typeof n=="object"&&n!==null&&typeof n.then=="function"&&yE(e,n),t0!==null&&t0(e,n)};var Ri=_e(null);function Jf(){var e=Ri.current;return e!==null?e:dt.pooledCache}function bs(e,n){n===null?Ne(Ri,Ri.current):Ne(Ri,n.pool)}function n0(){var e=Jf();return e===null?null:{parent:$t._currentValue,pool:e}}var Aa=0,Pe=null,at=null,_t=null,Ss=!1,bl=!1,Di=!1,xs=0,ju=0,Sl=null,bE=0;function At(){throw Error(i(321))}function Wf(e,n){if(n===null)return!1;for(var l=0;l<n.length&&l<e.length;l++)if(!Dn(e[l],n[l]))return!1;return!0}function ed(e,n,l,u,c,m){return Aa=m,Pe=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,z.H=e===null||e.memoizedState===null?Ai:Ma,Di=!1,m=l(u,c),Di=!1,bl&&(m=a0(n,l,u,c)),r0(e),m}function r0(e){z.H=Cr;var n=at!==null&&at.next!==null;if(Aa=0,_t=at=Pe=null,Ss=!1,ju=0,Sl=null,n)throw Error(i(300));e===null||kt||(e=e.dependencies,e!==null&&Ms(e)&&(kt=!0))}function a0(e,n,l,u){Pe=e;var c=0;do{if(bl&&(Sl=null),ju=0,bl=!1,25<=c)throw Error(i(301));if(c+=1,_t=at=null,e.updateQueue!=null){var m=e.updateQueue;m.lastEffect=null,m.events=null,m.stores=null,m.memoCache!=null&&(m.memoCache.index=0)}z.H=Mi,m=n(l,u)}while(bl);return m}function SE(){var e=z.H,n=e.useState()[0];return n=typeof n.then=="function"?_u(n):n,e=e.useState()[0],(at!==null?at.memoizedState:null)!==e&&(Pe.flags|=1024),n}function td(){var e=xs!==0;return xs=0,e}function nd(e,n,l){n.updateQueue=e.updateQueue,n.flags&=-2053,e.lanes&=~l}function rd(e){if(Ss){for(e=e.memoizedState;e!==null;){var n=e.queue;n!==null&&(n.pending=null),e=e.next}Ss=!1}Aa=0,_t=at=Pe=null,bl=!1,ju=xs=0,Sl=null}function En(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return _t===null?Pe.memoizedState=_t=e:_t=_t.next=e,_t}function Nt(){if(at===null){var e=Pe.alternate;e=e!==null?e.memoizedState:null}else e=at.next;var n=_t===null?Pe.memoizedState:_t.next;if(n!==null)_t=n,at=e;else{if(e===null)throw Pe.alternate===null?Error(i(467)):Error(i(310));at=e,e={memoizedState:at.memoizedState,baseState:at.baseState,baseQueue:at.baseQueue,queue:at.queue,next:null},_t===null?Pe.memoizedState=_t=e:_t=_t.next=e}return _t}var Es;Es=function(){return{lastEffect:null,events:null,stores:null,memoCache:null}};function _u(e){var n=ju;return ju+=1,Sl===null&&(Sl=[]),e=Kp(Sl,e,n),n=Pe,(_t===null?n.memoizedState:_t.next)===null&&(n=n.alternate,z.H=n===null||n.memoizedState===null?Ai:Ma),e}function ws(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return _u(e);if(e.$$typeof===g)return nn(e)}throw Error(i(438,String(e)))}function ad(e){var n=null,l=Pe.updateQueue;if(l!==null&&(n=l.memoCache),n==null){var u=Pe.alternate;u!==null&&(u=u.updateQueue,u!==null&&(u=u.memoCache,u!=null&&(n={data:u.data.map(function(c){return c.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),l===null&&(l=Es(),Pe.updateQueue=l),l.memoCache=n,l=n.data[n.index],l===void 0)for(l=n.data[n.index]=Array(e),u=0;u<e;u++)l[u]=j;return n.index++,l}function Zr(e,n){return typeof n=="function"?n(e):n}function Os(e){var n=Nt();return id(n,at,e)}function id(e,n,l){var u=e.queue;if(u===null)throw Error(i(311));u.lastRenderedReducer=l;var c=e.baseQueue,m=u.pending;if(m!==null){if(c!==null){var b=c.next;c.next=m.next,m.next=b}n.baseQueue=c=m,u.pending=null}if(m=e.baseState,c===null)e.memoizedState=m;else{n=c.next;var C=b=null,_=null,P=n,ee=!1;do{var le=P.lane&-536870913;if(le!==P.lane?(Ze&le)===le:(Aa&le)===le){var G=P.revertLane;if(G===0)_!==null&&(_=_.next={lane:0,revertLane:0,action:P.action,hasEagerState:P.hasEagerState,eagerState:P.eagerState,next:null}),le===yl&&(ee=!0);else if((Aa&G)===G){P=P.next,G===yl&&(ee=!0);continue}else le={lane:0,revertLane:P.revertLane,action:P.action,hasEagerState:P.hasEagerState,eagerState:P.eagerState,next:null},_===null?(C=_=le,b=m):_=_.next=le,Pe.lanes|=G,Ba|=G;le=P.action,Di&&l(m,le),m=P.hasEagerState?P.eagerState:l(m,le)}else G={lane:le,revertLane:P.revertLane,action:P.action,hasEagerState:P.hasEagerState,eagerState:P.eagerState,next:null},_===null?(C=_=G,b=m):_=_.next=G,Pe.lanes|=le,Ba|=le;P=P.next}while(P!==null&&P!==n);if(_===null?b=m:_.next=C,!Dn(m,e.memoizedState)&&(kt=!0,ee&&(l=gl,l!==null)))throw l;e.memoizedState=m,e.baseState=b,e.baseQueue=_,u.lastRenderedState=m}return c===null&&(u.lanes=0),[e.memoizedState,u.dispatch]}function ld(e){var n=Nt(),l=n.queue;if(l===null)throw Error(i(311));l.lastRenderedReducer=e;var u=l.dispatch,c=l.pending,m=n.memoizedState;if(c!==null){l.pending=null;var b=c=c.next;do m=e(m,b.action),b=b.next;while(b!==c);Dn(m,n.memoizedState)||(kt=!0),n.memoizedState=m,n.baseQueue===null&&(n.baseState=m),l.lastRenderedState=m}return[m,u]}function i0(e,n,l){var u=Pe,c=Nt(),m=Je;if(m){if(l===void 0)throw Error(i(407));l=l()}else l=n();var b=!Dn((at||c).memoizedState,l);if(b&&(c.memoizedState=l,kt=!0),c=c.queue,sd(o0.bind(null,u,c,e),[e]),c.getSnapshot!==n||b||_t!==null&&_t.memoizedState.tag&1){if(u.flags|=2048,xl(9,u0.bind(null,u,c,l,n),{destroy:void 0},null),dt===null)throw Error(i(349));m||Aa&60||l0(u,n,l)}return l}function l0(e,n,l){e.flags|=16384,e={getSnapshot:n,value:l},n=Pe.updateQueue,n===null?(n=Es(),Pe.updateQueue=n,n.stores=[e]):(l=n.stores,l===null?n.stores=[e]:l.push(e))}function u0(e,n,l,u){n.value=l,n.getSnapshot=u,s0(n)&&c0(e)}function o0(e,n,l){return l(function(){s0(n)&&c0(e)})}function s0(e){var n=e.getSnapshot;e=e.value;try{var l=n();return!Dn(e,l)}catch{return!0}}function c0(e){var n=Ta(e,2);n!==null&&hn(n,e,2)}function ud(e){var n=En();if(typeof e=="function"){var l=e;if(e=l(),Di){Tn(!0);try{l()}finally{Tn(!1)}}}return n.memoizedState=n.baseState=e,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zr,lastRenderedState:e},n}function f0(e,n,l,u){return e.baseState=l,id(e,at,typeof u=="function"?u:Zr)}function xE(e,n,l,u,c){if(Rs(e))throw Error(i(485));if(e=n.action,e!==null){var m={payload:c,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){m.listeners.push(b)}};z.T!==null?l(!0):m.isTransition=!1,u(m),l=n.pending,l===null?(m.next=n.pending=m,d0(n,m)):(m.next=l.next,n.pending=l.next=m)}}function d0(e,n){var l=n.action,u=n.payload,c=e.state;if(n.isTransition){var m=z.T,b={};z.T=b;try{var C=l(c,u),_=z.S;_!==null&&_(b,C),h0(e,n,C)}catch(P){od(e,n,P)}finally{z.T=m}}else try{m=l(c,u),h0(e,n,m)}catch(P){od(e,n,P)}}function h0(e,n,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(u){m0(e,n,u)},function(u){return od(e,n,u)}):m0(e,n,l)}function m0(e,n,l){n.status="fulfilled",n.value=l,v0(n),e.state=l,n=e.pending,n!==null&&(l=n.next,l===n?e.pending=null:(l=l.next,n.next=l,d0(e,l)))}function od(e,n,l){var u=e.pending;if(e.pending=null,u!==null){u=u.next;do n.status="rejected",n.reason=l,v0(n),n=n.next;while(n!==u)}e.action=null}function v0(e){e=e.listeners;for(var n=0;n<e.length;n++)(0,e[n])()}function p0(e,n){return n}function y0(e,n){if(Je){var l=dt.formState;if(l!==null){e:{var u=Pe;if(Je){if(Qt){t:{for(var c=Qt,m=wr;c.nodeType!==8;){if(!m){c=null;break t}if(c=cr(c.nextSibling),c===null){c=null;break t}}m=c.data,c=m==="F!"||m==="F"?c:null}if(c){Qt=cr(c.nextSibling),u=c.data==="F!";break e}}Ci(u)}u=!1}u&&(n=l[0])}}return l=En(),l.memoizedState=l.baseState=n,u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:p0,lastRenderedState:n},l.queue=u,l=L0.bind(null,Pe,u),u.dispatch=l,u=ud(!1),m=md.bind(null,Pe,!1,u.queue),u=En(),c={state:n,dispatch:null,action:e,pending:null},u.queue=c,l=xE.bind(null,Pe,c,m,l),c.dispatch=l,u.memoizedState=e,[n,l,!1]}function g0(e){var n=Nt();return b0(n,at,e)}function b0(e,n,l){n=id(e,n,p0)[0],e=Os(Zr)[0],n=typeof n=="object"&&n!==null&&typeof n.then=="function"?_u(n):n;var u=Nt(),c=u.queue,m=c.dispatch;return l!==u.memoizedState&&(Pe.flags|=2048,xl(9,EE.bind(null,c,l),{destroy:void 0},null)),[n,m,e]}function EE(e,n){e.action=n}function S0(e){var n=Nt(),l=at;if(l!==null)return b0(n,l,e);Nt(),n=n.memoizedState,l=Nt();var u=l.queue.dispatch;return l.memoizedState=e,[n,u,!1]}function xl(e,n,l,u){return e={tag:e,create:n,inst:l,deps:u,next:null},n=Pe.updateQueue,n===null&&(n=Es(),Pe.updateQueue=n),l=n.lastEffect,l===null?n.lastEffect=e.next=e:(u=l.next,l.next=e,e.next=u,n.lastEffect=e),e}function x0(){return Nt().memoizedState}function Cs(e,n,l,u){var c=En();Pe.flags|=e,c.memoizedState=xl(1|n,l,{destroy:void 0},u===void 0?null:u)}function Ts(e,n,l,u){var c=Nt();u=u===void 0?null:u;var m=c.memoizedState.inst;at!==null&&u!==null&&Wf(u,at.memoizedState.deps)?c.memoizedState=xl(n,l,m,u):(Pe.flags|=e,c.memoizedState=xl(1|n,l,m,u))}function E0(e,n){Cs(8390656,8,e,n)}function sd(e,n){Ts(2048,8,e,n)}function w0(e,n){return Ts(4,2,e,n)}function O0(e,n){return Ts(4,4,e,n)}function C0(e,n){if(typeof n=="function"){e=e();var l=n(e);return function(){typeof l=="function"?l():n(null)}}if(n!=null)return e=e(),n.current=e,function(){n.current=null}}function T0(e,n,l){l=l!=null?l.concat([e]):null,Ts(4,4,C0.bind(null,n,e),l)}function cd(){}function R0(e,n){var l=Nt();n=n===void 0?null:n;var u=l.memoizedState;return n!==null&&Wf(n,u[1])?u[0]:(l.memoizedState=[e,n],e)}function D0(e,n){var l=Nt();n=n===void 0?null:n;var u=l.memoizedState;if(n!==null&&Wf(n,u[1]))return u[0];if(u=e(),Di){Tn(!0);try{e()}finally{Tn(!1)}}return l.memoizedState=[u,n],u}function fd(e,n,l){return l===void 0||Aa&1073741824?e.memoizedState=n:(e.memoizedState=l,e=My(),Pe.lanes|=e,Ba|=e,l)}function A0(e,n,l,u){return Dn(l,n)?l:pl.current!==null?(e=fd(e,l,u),Dn(e,n)||(kt=!0),e):Aa&42?(e=My(),Pe.lanes|=e,Ba|=e,n):(kt=!0,e.memoizedState=l)}function M0(e,n,l,u,c){var m=ce.p;ce.p=m!==0&&8>m?m:8;var b=z.T,C={};z.T=C,md(e,!1,n,l);try{var _=c(),P=z.S;if(P!==null&&P(C,_),_!==null&&typeof _=="object"&&typeof _.then=="function"){var ee=gE(_,u);Nu(e,n,ee,_n(e))}else Nu(e,n,u,_n(e))}catch(le){Nu(e,n,{then:function(){},status:"rejected",reason:le},_n())}finally{ce.p=m,z.T=b}}function wE(){}function dd(e,n,l,u){if(e.tag!==5)throw Error(i(476));var c=j0(e).queue;M0(e,c,n,ge,l===null?wE:function(){return _0(e),l(u)})}function j0(e){var n=e.memoizedState;if(n!==null)return n;n={memoizedState:ge,baseState:ge,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zr,lastRenderedState:ge},next:null};var l={};return n.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Zr,lastRenderedState:l},next:null},e.memoizedState=n,e=e.alternate,e!==null&&(e.memoizedState=n),n}function _0(e){var n=j0(e).next.queue;Nu(e,n,{},_n())}function hd(){return nn(Wu)}function N0(){return Nt().memoizedState}function z0(){return Nt().memoizedState}function OE(e){for(var n=e.return;n!==null;){switch(n.tag){case 24:case 3:var l=_n();e=Na(l);var u=za(n,e,l);u!==null&&(hn(u,n,l),Hu(u,n,l)),n={cache:Zf()},e.payload=n;return}n=n.return}}function CE(e,n,l){var u=_n();l={lane:u,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null},Rs(e)?H0(n,l):(l=Ff(e,n,l,u),l!==null&&(hn(l,e,u),U0(l,n,u)))}function L0(e,n,l){var u=_n();Nu(e,n,l,u)}function Nu(e,n,l,u){var c={lane:u,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null};if(Rs(e))H0(n,c);else{var m=e.alternate;if(e.lanes===0&&(m===null||m.lanes===0)&&(m=n.lastRenderedReducer,m!==null))try{var b=n.lastRenderedState,C=m(b,l);if(c.hasEagerState=!0,c.eagerState=C,Dn(C,b))return cs(e,n,c,0),dt===null&&ss(),!1}catch{}finally{}if(l=Ff(e,n,c,u),l!==null)return hn(l,e,u),U0(l,n,u),!0}return!1}function md(e,n,l,u){if(u={lane:2,revertLane:rh(),action:u,hasEagerState:!1,eagerState:null,next:null},Rs(e)){if(n)throw Error(i(479))}else n=Ff(e,l,u,2),n!==null&&hn(n,e,2)}function Rs(e){var n=e.alternate;return e===Pe||n!==null&&n===Pe}function H0(e,n){bl=Ss=!0;var l=e.pending;l===null?n.next=n:(n.next=l.next,l.next=n),e.pending=n}function U0(e,n,l){if(l&4194176){var u=n.lanes;u&=e.pendingLanes,l|=u,n.lanes=l,Me(e,l)}}var Cr={readContext:nn,use:ws,useCallback:At,useContext:At,useEffect:At,useImperativeHandle:At,useLayoutEffect:At,useInsertionEffect:At,useMemo:At,useReducer:At,useRef:At,useState:At,useDebugValue:At,useDeferredValue:At,useTransition:At,useSyncExternalStore:At,useId:At};Cr.useCacheRefresh=At,Cr.useMemoCache=At,Cr.useHostTransitionStatus=At,Cr.useFormState=At,Cr.useActionState=At,Cr.useOptimistic=At;var Ai={readContext:nn,use:ws,useCallback:function(e,n){return En().memoizedState=[e,n===void 0?null:n],e},useContext:nn,useEffect:E0,useImperativeHandle:function(e,n,l){l=l!=null?l.concat([e]):null,Cs(4194308,4,C0.bind(null,n,e),l)},useLayoutEffect:function(e,n){return Cs(4194308,4,e,n)},useInsertionEffect:function(e,n){Cs(4,2,e,n)},useMemo:function(e,n){var l=En();n=n===void 0?null:n;var u=e();if(Di){Tn(!0);try{e()}finally{Tn(!1)}}return l.memoizedState=[u,n],u},useReducer:function(e,n,l){var u=En();if(l!==void 0){var c=l(n);if(Di){Tn(!0);try{l(n)}finally{Tn(!1)}}}else c=n;return u.memoizedState=u.baseState=c,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:c},u.queue=e,e=e.dispatch=CE.bind(null,Pe,e),[u.memoizedState,e]},useRef:function(e){var n=En();return e={current:e},n.memoizedState=e},useState:function(e){e=ud(e);var n=e.queue,l=L0.bind(null,Pe,n);return n.dispatch=l,[e.memoizedState,l]},useDebugValue:cd,useDeferredValue:function(e,n){var l=En();return fd(l,e,n)},useTransition:function(){var e=ud(!1);return e=M0.bind(null,Pe,e.queue,!0,!1),En().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,n,l){var u=Pe,c=En();if(Je){if(l===void 0)throw Error(i(407));l=l()}else{if(l=n(),dt===null)throw Error(i(349));Ze&60||l0(u,n,l)}c.memoizedState=l;var m={value:l,getSnapshot:n};return c.queue=m,E0(o0.bind(null,u,m,e),[e]),u.flags|=2048,xl(9,u0.bind(null,u,m,l,n),{destroy:void 0},null),l},useId:function(){var e=En(),n=dt.identifierPrefix;if(Je){var l=Gr,u=Kr;l=(u&~(1<<32-tn(u)-1)).toString(32)+l,n=":"+n+"R"+l,l=xs++,0<l&&(n+="H"+l.toString(32)),n+=":"}else l=bE++,n=":"+n+"r"+l.toString(32)+":";return e.memoizedState=n},useCacheRefresh:function(){return En().memoizedState=OE.bind(null,Pe)}};Ai.useMemoCache=ad,Ai.useHostTransitionStatus=hd,Ai.useFormState=y0,Ai.useActionState=y0,Ai.useOptimistic=function(e){var n=En();n.memoizedState=n.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=l,n=md.bind(null,Pe,!0,l),l.dispatch=n,[e,n]};var Ma={readContext:nn,use:ws,useCallback:R0,useContext:nn,useEffect:sd,useImperativeHandle:T0,useInsertionEffect:w0,useLayoutEffect:O0,useMemo:D0,useReducer:Os,useRef:x0,useState:function(){return Os(Zr)},useDebugValue:cd,useDeferredValue:function(e,n){var l=Nt();return A0(l,at.memoizedState,e,n)},useTransition:function(){var e=Os(Zr)[0],n=Nt().memoizedState;return[typeof e=="boolean"?e:_u(e),n]},useSyncExternalStore:i0,useId:N0};Ma.useCacheRefresh=z0,Ma.useMemoCache=ad,Ma.useHostTransitionStatus=hd,Ma.useFormState=g0,Ma.useActionState=g0,Ma.useOptimistic=function(e,n){var l=Nt();return f0(l,at,e,n)};var Mi={readContext:nn,use:ws,useCallback:R0,useContext:nn,useEffect:sd,useImperativeHandle:T0,useInsertionEffect:w0,useLayoutEffect:O0,useMemo:D0,useReducer:ld,useRef:x0,useState:function(){return ld(Zr)},useDebugValue:cd,useDeferredValue:function(e,n){var l=Nt();return at===null?fd(l,e,n):A0(l,at.memoizedState,e,n)},useTransition:function(){var e=ld(Zr)[0],n=Nt().memoizedState;return[typeof e=="boolean"?e:_u(e),n]},useSyncExternalStore:i0,useId:N0};Mi.useCacheRefresh=z0,Mi.useMemoCache=ad,Mi.useHostTransitionStatus=hd,Mi.useFormState=S0,Mi.useActionState=S0,Mi.useOptimistic=function(e,n){var l=Nt();return at!==null?f0(l,at,e,n):(l.baseState=e,[e,l.queue.dispatch])};function vd(e,n,l,u){n=e.memoizedState,l=l(u,n),l=l==null?n:X({},n,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var pd={isMounted:function(e){return(e=e._reactInternals)?ne(e)===e:!1},enqueueSetState:function(e,n,l){e=e._reactInternals;var u=_n(),c=Na(u);c.payload=n,l!=null&&(c.callback=l),n=za(e,c,u),n!==null&&(hn(n,e,u),Hu(n,e,u))},enqueueReplaceState:function(e,n,l){e=e._reactInternals;var u=_n(),c=Na(u);c.tag=1,c.payload=n,l!=null&&(c.callback=l),n=za(e,c,u),n!==null&&(hn(n,e,u),Hu(n,e,u))},enqueueForceUpdate:function(e,n){e=e._reactInternals;var l=_n(),u=Na(l);u.tag=2,n!=null&&(u.callback=n),n=za(e,u,l),n!==null&&(hn(n,e,l),Hu(n,e,l))}};function $0(e,n,l,u,c,m,b){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(u,m,b):n.prototype&&n.prototype.isPureReactComponent?!Su(l,u)||!Su(c,m):!0}function B0(e,n,l,u){e=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(l,u),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(l,u),n.state!==e&&pd.enqueueReplaceState(n,n.state,null)}function ji(e,n){var l=n;if("ref"in n){l={};for(var u in n)u!=="ref"&&(l[u]=n[u])}if(e=e.defaultProps){l===n&&(l=X({},l));for(var c in e)l[c]===void 0&&(l[c]=e[c])}return l}var Ds=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=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(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function P0(e){Ds(e)}function q0(e){console.error(e)}function k0(e){Ds(e)}function As(e,n){try{var l=e.onUncaughtError;l(n.value,{componentStack:n.stack})}catch(u){setTimeout(function(){throw u})}}function F0(e,n,l){try{var u=e.onCaughtError;u(l.value,{componentStack:l.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(c){setTimeout(function(){throw c})}}function yd(e,n,l){return l=Na(l),l.tag=3,l.payload={element:null},l.callback=function(){As(e,n)},l}function V0(e){return e=Na(e),e.tag=3,e}function Y0(e,n,l,u){var c=l.type.getDerivedStateFromError;if(typeof c=="function"){var m=u.value;e.payload=function(){return c(m)},e.callback=function(){F0(n,l,u)}}var b=l.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(e.callback=function(){F0(n,l,u),typeof c!="function"&&(Pa===null?Pa=new Set([this]):Pa.add(this));var C=u.stack;this.componentDidCatch(u.value,{componentStack:C!==null?C:""})})}function TE(e,n,l,u,c){if(l.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){if(n=l.alternate,n!==null&&Lu(n,l,c,!0),l=Gn.current,l!==null){switch(l.tag){case 13:return Or===null?Jd():l.alternate===null&&Ot===0&&(Ot=3),l.flags&=-257,l.flags|=65536,l.lanes=c,u===Kf?l.flags|=16384:(n=l.updateQueue,n===null?l.updateQueue=new Set([u]):n.add(u),eh(e,u,c)),!1;case 22:return l.flags|=65536,u===Kf?l.flags|=16384:(n=l.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([u])},l.updateQueue=n):(l=n.retryQueue,l===null?n.retryQueue=new Set([u]):l.add(u)),eh(e,u,c)),!1}throw Error(i(435,l.tag))}return eh(e,u,c),Jd(),!1}if(Je)return n=Gn.current,n!==null?(!(n.flags&65536)&&(n.flags|=256),n.flags|=65536,n.lanes=c,u!==Qf&&(e=Error(i(422),{cause:u}),Ou(Yn(e,l)))):(u!==Qf&&(n=Error(i(423),{cause:u}),Ou(Yn(n,l))),e=e.current.alternate,e.flags|=65536,c&=-c,e.lanes|=c,u=Yn(u,l),c=yd(e.stateNode,u,c),_d(e,c),Ot!==4&&(Ot=2)),!1;var m=Error(i(520),{cause:u});if(m=Yn(m,l),Vu===null?Vu=[m]:Vu.push(m),Ot!==4&&(Ot=2),n===null)return!0;u=Yn(u,l),l=n;do{switch(l.tag){case 3:return l.flags|=65536,e=c&-c,l.lanes|=e,e=yd(l.stateNode,u,e),_d(l,e),!1;case 1:if(n=l.type,m=l.stateNode,(l.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||m!==null&&typeof m.componentDidCatch=="function"&&(Pa===null||!Pa.has(m))))return l.flags|=65536,c&=-c,l.lanes|=c,c=V0(c),Y0(c,e,l,u),_d(l,c),!1}l=l.return}while(l!==null);return!1}var Q0=Error(i(461)),kt=!1;function Kt(e,n,l,u){n.child=e===null?Ip(n,null,l,u):Ti(n,e.child,l,u)}function K0(e,n,l,u,c){l=l.render;var m=n.ref;if("ref"in u){var b={};for(var C in u)C!=="ref"&&(b[C]=u[C])}else b=u;return Ni(n),u=ed(e,n,l,b,m,c),C=td(),e!==null&&!kt?(nd(e,n,c),Ir(e,n,c)):(Je&&C&&Vf(n),n.flags|=1,Kt(e,n,u,c),n.child)}function G0(e,n,l,u,c){if(e===null){var m=l.type;return typeof m=="function"&&!Pd(m)&&m.defaultProps===void 0&&l.compare===null?(n.tag=15,n.type=m,X0(e,n,m,u,c)):(e=zs(l.type,null,u,n,n.mode,c),e.ref=n.ref,e.return=n,n.child=e)}if(m=e.child,!Td(e,c)){var b=m.memoizedProps;if(l=l.compare,l=l!==null?l:Su,l(b,u)&&e.ref===n.ref)return Ir(e,n,c)}return n.flags|=1,e=$a(m,u),e.ref=n.ref,e.return=n,n.child=e}function X0(e,n,l,u,c){if(e!==null){var m=e.memoizedProps;if(Su(m,u)&&e.ref===n.ref)if(kt=!1,n.pendingProps=u=m,Td(e,c))e.flags&131072&&(kt=!0);else return n.lanes=e.lanes,Ir(e,n,c)}return gd(e,n,l,u,c)}function Z0(e,n,l){var u=n.pendingProps,c=u.children,m=(n.stateNode._pendingVisibility&2)!==0,b=e!==null?e.memoizedState:null;if(zu(e,n),u.mode==="hidden"||m){if(n.flags&128){if(u=b!==null?b.baseLanes|l:l,e!==null){for(c=n.child=e.child,m=0;c!==null;)m=m|c.lanes|c.childLanes,c=c.sibling;n.childLanes=m&~u}else n.childLanes=0,n.child=null;return I0(e,n,u,l)}if(l&536870912)n.memoizedState={baseLanes:0,cachePool:null},e!==null&&bs(n,b!==null?b.cachePool:null),b!==null?Jp(n,b):Gf(),Wp(n);else return n.lanes=n.childLanes=536870912,I0(e,n,b!==null?b.baseLanes|l:l,l)}else b!==null?(bs(n,b.cachePool),Jp(n,b),Da(),n.memoizedState=null):(e!==null&&bs(n,null),Gf(),Da());return Kt(e,n,c,l),n.child}function I0(e,n,l,u){var c=Jf();return c=c===null?null:{parent:$t._currentValue,pool:c},n.memoizedState={baseLanes:l,cachePool:c},e!==null&&bs(n,null),Gf(),Wp(n),e!==null&&Lu(e,n,u,!0),null}function zu(e,n){var l=n.ref;if(l===null)e!==null&&e.ref!==null&&(n.flags|=2097664);else{if(typeof l!="function"&&typeof l!="object")throw Error(i(284));(e===null||e.ref!==l)&&(n.flags|=2097664)}}function gd(e,n,l,u,c){return Ni(n),l=ed(e,n,l,u,void 0,c),u=td(),e!==null&&!kt?(nd(e,n,c),Ir(e,n,c)):(Je&&u&&Vf(n),n.flags|=1,Kt(e,n,l,c),n.child)}function J0(e,n,l,u,c,m){return Ni(n),n.updateQueue=null,l=a0(n,u,l,c),r0(e),u=td(),e!==null&&!kt?(nd(e,n,m),Ir(e,n,m)):(Je&&u&&Vf(n),n.flags|=1,Kt(e,n,l,m),n.child)}function W0(e,n,l,u,c){if(Ni(n),n.stateNode===null){var m=dl,b=l.contextType;typeof b=="object"&&b!==null&&(m=nn(b)),m=new l(u,m),n.memoizedState=m.state!==null&&m.state!==void 0?m.state:null,m.updater=pd,n.stateNode=m,m._reactInternals=n,m=n.stateNode,m.props=u,m.state=n.memoizedState,m.refs={},Md(n),b=l.contextType,m.context=typeof b=="object"&&b!==null?nn(b):dl,m.state=n.memoizedState,b=l.getDerivedStateFromProps,typeof b=="function"&&(vd(n,l,b,u),m.state=n.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof m.getSnapshotBeforeUpdate=="function"||typeof m.UNSAFE_componentWillMount!="function"&&typeof m.componentWillMount!="function"||(b=m.state,typeof m.componentWillMount=="function"&&m.componentWillMount(),typeof m.UNSAFE_componentWillMount=="function"&&m.UNSAFE_componentWillMount(),b!==m.state&&pd.enqueueReplaceState(m,m.state,null),$u(n,u,m,c),Uu(),m.state=n.memoizedState),typeof m.componentDidMount=="function"&&(n.flags|=4194308),u=!0}else if(e===null){m=n.stateNode;var C=n.memoizedProps,_=ji(l,C);m.props=_;var P=m.context,ee=l.contextType;b=dl,typeof ee=="object"&&ee!==null&&(b=nn(ee));var le=l.getDerivedStateFromProps;ee=typeof le=="function"||typeof m.getSnapshotBeforeUpdate=="function",C=n.pendingProps!==C,ee||typeof m.UNSAFE_componentWillReceiveProps!="function"&&typeof m.componentWillReceiveProps!="function"||(C||P!==b)&&B0(n,m,u,b),_a=!1;var G=n.memoizedState;m.state=G,$u(n,u,m,c),Uu(),P=n.memoizedState,C||G!==P||_a?(typeof le=="function"&&(vd(n,l,le,u),P=n.memoizedState),(_=_a||$0(n,l,_,u,G,P,b))?(ee||typeof m.UNSAFE_componentWillMount!="function"&&typeof m.componentWillMount!="function"||(typeof m.componentWillMount=="function"&&m.componentWillMount(),typeof m.UNSAFE_componentWillMount=="function"&&m.UNSAFE_componentWillMount()),typeof m.componentDidMount=="function"&&(n.flags|=4194308)):(typeof m.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=u,n.memoizedState=P),m.props=u,m.state=P,m.context=b,u=_):(typeof m.componentDidMount=="function"&&(n.flags|=4194308),u=!1)}else{m=n.stateNode,jd(e,n),b=n.memoizedProps,ee=ji(l,b),m.props=ee,le=n.pendingProps,G=m.context,P=l.contextType,_=dl,typeof P=="object"&&P!==null&&(_=nn(P)),C=l.getDerivedStateFromProps,(P=typeof C=="function"||typeof m.getSnapshotBeforeUpdate=="function")||typeof m.UNSAFE_componentWillReceiveProps!="function"&&typeof m.componentWillReceiveProps!="function"||(b!==le||G!==_)&&B0(n,m,u,_),_a=!1,G=n.memoizedState,m.state=G,$u(n,u,m,c),Uu();var W=n.memoizedState;b!==le||G!==W||_a||e!==null&&e.dependencies!==null&&Ms(e.dependencies)?(typeof C=="function"&&(vd(n,l,C,u),W=n.memoizedState),(ee=_a||$0(n,l,ee,u,G,W,_)||e!==null&&e.dependencies!==null&&Ms(e.dependencies))?(P||typeof m.UNSAFE_componentWillUpdate!="function"&&typeof m.componentWillUpdate!="function"||(typeof m.componentWillUpdate=="function"&&m.componentWillUpdate(u,W,_),typeof m.UNSAFE_componentWillUpdate=="function"&&m.UNSAFE_componentWillUpdate(u,W,_)),typeof m.componentDidUpdate=="function"&&(n.flags|=4),typeof m.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof m.componentDidUpdate!="function"||b===e.memoizedProps&&G===e.memoizedState||(n.flags|=4),typeof m.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&G===e.memoizedState||(n.flags|=1024),n.memoizedProps=u,n.memoizedState=W),m.props=u,m.state=W,m.context=_,u=ee):(typeof m.componentDidUpdate!="function"||b===e.memoizedProps&&G===e.memoizedState||(n.flags|=4),typeof m.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&G===e.memoizedState||(n.flags|=1024),u=!1)}return m=u,zu(e,n),u=(n.flags&128)!==0,m||u?(m=n.stateNode,l=u&&typeof l.getDerivedStateFromError!="function"?null:m.render(),n.flags|=1,e!==null&&u?(n.child=Ti(n,e.child,null,c),n.child=Ti(n,null,l,c)):Kt(e,n,l,c),n.memoizedState=m.state,e=n.child):e=Ir(e,n,c),e}function ey(e,n,l,u){return wu(),n.flags|=256,Kt(e,n,l,u),n.child}var bd={dehydrated:null,treeContext:null,retryLane:0};function Sd(e){return{baseLanes:e,cachePool:n0()}}function xd(e,n,l){return e=e!==null?e.childLanes&~l:0,n&&(e|=Jn),e}function ty(e,n,l){var u=n.pendingProps,c=!1,m=(n.flags&128)!==0,b;if((b=m)||(b=e!==null&&e.memoizedState===null?!1:(Ut.current&2)!==0),b&&(c=!0,n.flags&=-129),b=(n.flags&32)!==0,n.flags&=-33,e===null){if(Je){if(c?Ra(n):Da(),Je){var C=Qt,_;if(_=C){e:{for(_=C,C=wr;_.nodeType!==8;){if(!C){C=null;break e}if(_=cr(_.nextSibling),_===null){C=null;break e}}C=_}C!==null?(n.memoizedState={dehydrated:C,treeContext:wi!==null?{id:Kr,overflow:Gr}:null,retryLane:536870912},_=In(18,null,null,0),_.stateNode=C,_.return=n,n.child=_,dn=n,Qt=null,_=!0):_=!1}_||Ci(n)}if(C=n.memoizedState,C!==null&&(C=C.dehydrated,C!==null))return C.data==="$!"?n.lanes=16:n.lanes=536870912,null;Xr(n)}return C=u.children,u=u.fallback,c?(Da(),c=n.mode,C=wd({mode:"hidden",children:C},c),u=Li(u,c,l,null),C.return=n,u.return=n,C.sibling=u,n.child=C,c=n.child,c.memoizedState=Sd(l),c.childLanes=xd(e,b,l),n.memoizedState=bd,u):(Ra(n),Ed(n,C))}if(_=e.memoizedState,_!==null&&(C=_.dehydrated,C!==null)){if(m)n.flags&256?(Ra(n),n.flags&=-257,n=Od(e,n,l)):n.memoizedState!==null?(Da(),n.child=e.child,n.flags|=128,n=null):(Da(),c=u.fallback,C=n.mode,u=wd({mode:"visible",children:u.children},C),c=Li(c,C,l,null),c.flags|=2,u.return=n,c.return=n,u.sibling=c,n.child=u,Ti(n,e.child,null,l),u=n.child,u.memoizedState=Sd(l),u.childLanes=xd(e,b,l),n.memoizedState=bd,n=c);else if(Ra(n),C.data==="$!"){if(b=C.nextSibling&&C.nextSibling.dataset,b)var P=b.dgst;b=P,u=Error(i(419)),u.stack="",u.digest=b,Ou({value:u,source:null,stack:null}),n=Od(e,n,l)}else if(kt||Lu(e,n,l,!1),b=(l&e.childLanes)!==0,kt||b){if(b=dt,b!==null){if(u=l&-l,u&42)u=1;else switch(u){case 2:u=1;break;case 8:u=4;break;case 32:u=16;break;case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:u=64;break;case 268435456:u=134217728;break;default:u=0}if(u=u&(b.suspendedLanes|l)?0:u,u!==0&&u!==_.retryLane)throw _.retryLane=u,Ta(e,u),hn(b,e,u),Q0}C.data==="$?"||Jd(),n=Od(e,n,l)}else C.data==="$?"?(n.flags|=128,n.child=e.child,n=qE.bind(null,e),C._reactRetry=n,n=null):(e=_.treeContext,Qt=cr(C.nextSibling),dn=n,Je=!0,or=null,wr=!1,e!==null&&(Qn[Kn++]=Kr,Qn[Kn++]=Gr,Qn[Kn++]=wi,Kr=e.id,Gr=e.overflow,wi=n),n=Ed(n,u.children),n.flags|=4096);return n}return c?(Da(),c=u.fallback,C=n.mode,_=e.child,P=_.sibling,u=$a(_,{mode:"hidden",children:u.children}),u.subtreeFlags=_.subtreeFlags&31457280,P!==null?c=$a(P,c):(c=Li(c,C,l,null),c.flags|=2),c.return=n,u.return=n,u.sibling=c,n.child=u,u=c,c=n.child,C=e.child.memoizedState,C===null?C=Sd(l):(_=C.cachePool,_!==null?(P=$t._currentValue,_=_.parent!==P?{parent:P,pool:P}:_):_=n0(),C={baseLanes:C.baseLanes|l,cachePool:_}),c.memoizedState=C,c.childLanes=xd(e,b,l),n.memoizedState=bd,u):(Ra(n),l=e.child,e=l.sibling,l=$a(l,{mode:"visible",children:u.children}),l.return=n,l.sibling=null,e!==null&&(b=n.deletions,b===null?(n.deletions=[e],n.flags|=16):b.push(e)),n.child=l,n.memoizedState=null,l)}function Ed(e,n){return n=wd({mode:"visible",children:n},e.mode),n.return=e,e.child=n}function wd(e,n){return Ry(e,n,0,null)}function Od(e,n,l){return Ti(n,e.child,null,l),e=Ed(n,n.pendingProps.children),e.flags|=2,n.memoizedState=null,e}function ny(e,n,l){e.lanes|=n;var u=e.alternate;u!==null&&(u.lanes|=n),Dd(e.return,n,l)}function Cd(e,n,l,u,c){var m=e.memoizedState;m===null?e.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:u,tail:l,tailMode:c}:(m.isBackwards=n,m.rendering=null,m.renderingStartTime=0,m.last=u,m.tail=l,m.tailMode=c)}function ry(e,n,l){var u=n.pendingProps,c=u.revealOrder,m=u.tail;if(Kt(e,n,u.children,l),u=Ut.current,u&2)u=u&1|2,n.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=n.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&ny(e,l,n);else if(e.tag===19)ny(e,l,n);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===n)break e;for(;e.sibling===null;){if(e.return===null||e.return===n)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}u&=1}switch(Ne(Ut,u),c){case"forwards":for(l=n.child,c=null;l!==null;)e=l.alternate,e!==null&&gs(e)===null&&(c=l),l=l.sibling;l=c,l===null?(c=n.child,n.child=null):(c=l.sibling,l.sibling=null),Cd(n,!1,c,l,m);break;case"backwards":for(l=null,c=n.child,n.child=null;c!==null;){if(e=c.alternate,e!==null&&gs(e)===null){n.child=c;break}e=c.sibling,c.sibling=l,l=c,c=e}Cd(n,!0,l,null,m);break;case"together":Cd(n,!1,null,null,void 0);break;default:n.memoizedState=null}return n.child}function Ir(e,n,l){if(e!==null&&(n.dependencies=e.dependencies),Ba|=n.lanes,!(l&n.childLanes))if(e!==null){if(Lu(e,n,l,!1),(l&n.childLanes)===0)return null}else return null;if(e!==null&&n.child!==e.child)throw Error(i(153));if(n.child!==null){for(e=n.child,l=$a(e,e.pendingProps),n.child=l,l.return=n;e.sibling!==null;)e=e.sibling,l=l.sibling=$a(e,e.pendingProps),l.return=n;l.sibling=null}return n.child}function Td(e,n){return e.lanes&n?!0:(e=e.dependencies,!!(e!==null&&Ms(e)))}function RE(e,n,l){switch(n.tag){case 3:Cn(n,n.stateNode.containerInfo),ja(n,$t,e.memoizedState.cache),wu();break;case 27:case 5:Pn(n);break;case 4:Cn(n,n.stateNode.containerInfo);break;case 10:ja(n,n.type,n.memoizedProps.value);break;case 13:var u=n.memoizedState;if(u!==null)return u.dehydrated!==null?(Ra(n),n.flags|=128,null):l&n.child.childLanes?ty(e,n,l):(Ra(n),e=Ir(e,n,l),e!==null?e.sibling:null);Ra(n);break;case 19:var c=(e.flags&128)!==0;if(u=(l&n.childLanes)!==0,u||(Lu(e,n,l,!1),u=(l&n.childLanes)!==0),c){if(u)return ry(e,n,l);n.flags|=128}if(c=n.memoizedState,c!==null&&(c.rendering=null,c.tail=null,c.lastEffect=null),Ne(Ut,Ut.current),u)break;return null;case 22:case 23:return n.lanes=0,Z0(e,n,l);case 24:ja(n,$t,e.memoizedState.cache)}return Ir(e,n,l)}function ay(e,n,l){if(e!==null)if(e.memoizedProps!==n.pendingProps)kt=!0;else{if(!Td(e,l)&&!(n.flags&128))return kt=!1,RE(e,n,l);kt=!!(e.flags&131072)}else kt=!1,Je&&n.flags&1048576&&kp(n,hs,n.index);switch(n.lanes=0,n.tag){case 16:e:{e=n.pendingProps;var u=n.elementType,c=u._init;if(u=c(u._payload),n.type=u,typeof u=="function")Pd(u)?(e=ji(u,e),n.tag=1,n=W0(null,n,u,e,l)):(n.tag=0,n=gd(null,n,u,e,l));else{if(u!=null){if(c=u.$$typeof,c===w){n.tag=11,n=K0(null,n,u,e,l);break e}else if(c===T){n.tag=14,n=G0(null,n,u,e,l);break e}}throw n=V(u)||u,Error(i(306,n,""))}}return n;case 0:return gd(e,n,n.type,n.pendingProps,l);case 1:return u=n.type,c=ji(u,n.pendingProps),W0(e,n,u,c,l);case 3:e:{if(Cn(n,n.stateNode.containerInfo),e===null)throw Error(i(387));var m=n.pendingProps;c=n.memoizedState,u=c.element,jd(e,n),$u(n,m,null,l);var b=n.memoizedState;if(m=b.cache,ja(n,$t,m),m!==c.cache&&Ad(n,[$t],l,!0),Uu(),m=b.element,c.isDehydrated)if(c={element:m,isDehydrated:!1,cache:b.cache},n.updateQueue.baseState=c,n.memoizedState=c,n.flags&256){n=ey(e,n,m,l);break e}else if(m!==u){u=Yn(Error(i(424)),n),Ou(u),n=ey(e,n,m,l);break e}else for(Qt=cr(n.stateNode.containerInfo.firstChild),dn=n,Je=!0,or=null,wr=!0,l=Ip(n,null,m,l),n.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(wu(),m===u){n=Ir(e,n,l);break e}Kt(e,n,m,l)}n=n.child}return n;case 26:return zu(e,n),e===null?(l=ug(n.type,null,n.pendingProps,null))?n.memoizedState=l:Je||(l=n.type,e=n.pendingProps,u=Qs(ft.current).createElement(l),u[Ce]=n,u[Be]=e,Gt(u,l,e),gt(u),n.stateNode=u):n.memoizedState=ug(n.type,e.memoizedProps,n.pendingProps,e.memoizedState),null;case 27:return Pn(n),e===null&&Je&&(u=n.stateNode=ag(n.type,n.pendingProps,ft.current),dn=n,wr=!0,Qt=cr(u.firstChild)),u=n.pendingProps.children,e!==null||Je?Kt(e,n,u,l):n.child=Ti(n,null,u,l),zu(e,n),n.child;case 5:return e===null&&Je&&((c=u=Qt)&&(u=rw(u,n.type,n.pendingProps,wr),u!==null?(n.stateNode=u,dn=n,Qt=cr(u.firstChild),wr=!1,c=!0):c=!1),c||Ci(n)),Pn(n),c=n.type,m=n.pendingProps,b=e!==null?e.memoizedProps:null,u=m.children,dh(c,m)?u=null:b!==null&&dh(c,b)&&(n.flags|=32),n.memoizedState!==null&&(c=ed(e,n,SE,null,null,l),Wu._currentValue=c),zu(e,n),Kt(e,n,u,l),n.child;case 6:return e===null&&Je&&((e=l=Qt)&&(l=aw(l,n.pendingProps,wr),l!==null?(n.stateNode=l,dn=n,Qt=null,e=!0):e=!1),e||Ci(n)),null;case 13:return ty(e,n,l);case 4:return Cn(n,n.stateNode.containerInfo),u=n.pendingProps,e===null?n.child=Ti(n,null,u,l):Kt(e,n,u,l),n.child;case 11:return K0(e,n,n.type,n.pendingProps,l);case 7:return Kt(e,n,n.pendingProps,l),n.child;case 8:return Kt(e,n,n.pendingProps.children,l),n.child;case 12:return Kt(e,n,n.pendingProps.children,l),n.child;case 10:return u=n.pendingProps,ja(n,n.type,u.value),Kt(e,n,u.children,l),n.child;case 9:return c=n.type._context,u=n.pendingProps.children,Ni(n),c=nn(c),u=u(c),n.flags|=1,Kt(e,n,u,l),n.child;case 14:return G0(e,n,n.type,n.pendingProps,l);case 15:return X0(e,n,n.type,n.pendingProps,l);case 19:return ry(e,n,l);case 22:return Z0(e,n,l);case 24:return Ni(n),u=nn($t),e===null?(c=Jf(),c===null&&(c=dt,m=Zf(),c.pooledCache=m,m.refCount++,m!==null&&(c.pooledCacheLanes|=l),c=m),n.memoizedState={parent:u,cache:c},Md(n),ja(n,$t,c)):(e.lanes&l&&(jd(e,n),$u(n,null,null,l),Uu()),c=e.memoizedState,m=n.memoizedState,c.parent!==u?(c={parent:u,cache:u},n.memoizedState=c,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=c),ja(n,$t,u)):(u=m.cache,ja(n,$t,u),u!==c.cache&&Ad(n,[$t],l,!0))),Kt(e,n,n.pendingProps.children,l),n.child;case 29:throw n.pendingProps}throw Error(i(156,n.tag))}var Rd=_e(null),_i=null,Jr=null;function ja(e,n,l){Ne(Rd,n._currentValue),n._currentValue=l}function Wr(e){e._currentValue=Rd.current,je(Rd)}function Dd(e,n,l){for(;e!==null;){var u=e.alternate;if((e.childLanes&n)!==n?(e.childLanes|=n,u!==null&&(u.childLanes|=n)):u!==null&&(u.childLanes&n)!==n&&(u.childLanes|=n),e===l)break;e=e.return}}function Ad(e,n,l,u){var c=e.child;for(c!==null&&(c.return=e);c!==null;){var m=c.dependencies;if(m!==null){var b=c.child;m=m.firstContext;e:for(;m!==null;){var C=m;m=c;for(var _=0;_<n.length;_++)if(C.context===n[_]){m.lanes|=l,C=m.alternate,C!==null&&(C.lanes|=l),Dd(m.return,l,e),u||(b=null);break e}m=C.next}}else if(c.tag===18){if(b=c.return,b===null)throw Error(i(341));b.lanes|=l,m=b.alternate,m!==null&&(m.lanes|=l),Dd(b,l,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 Lu(e,n,l,u){e=null;for(var c=n,m=!1;c!==null;){if(!m){if(c.flags&524288)m=!0;else if(c.flags&262144)break}if(c.tag===10){var b=c.alternate;if(b===null)throw Error(i(387));if(b=b.memoizedProps,b!==null){var C=c.type;Dn(c.pendingProps.value,b.value)||(e!==null?e.push(C):e=[C])}}else if(c===ln.current){if(b=c.alternate,b===null)throw Error(i(387));b.memoizedState.memoizedState!==c.memoizedState.memoizedState&&(e!==null?e.push(Wu):e=[Wu])}c=c.return}e!==null&&Ad(n,e,l,u),n.flags|=262144}function Ms(e){for(e=e.firstContext;e!==null;){if(!Dn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Ni(e){_i=e,Jr=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function nn(e){return iy(_i,e)}function js(e,n){return _i===null&&Ni(e),iy(e,n)}function iy(e,n){var l=n._currentValue;if(n={context:n,memoizedValue:l,next:null},Jr===null){if(e===null)throw Error(i(308));Jr=n,e.dependencies={lanes:0,firstContext:n},e.flags|=524288}else Jr=Jr.next=n;return l}var _a=!1;function Md(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function jd(e,n){e=e.updateQueue,n.updateQueue===e&&(n.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Na(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function za(e,n,l){var u=e.updateQueue;if(u===null)return null;if(u=u.shared,St&2){var c=u.pending;return c===null?n.next=n:(n.next=c.next,c.next=n),u.pending=n,n=fs(e),Pp(e,null,l),n}return cs(e,u,n,l),fs(e)}function Hu(e,n,l){if(n=n.updateQueue,n!==null&&(n=n.shared,(l&4194176)!==0)){var u=n.lanes;u&=e.pendingLanes,l|=u,n.lanes=l,Me(e,l)}}function _d(e,n){var l=e.updateQueue,u=e.alternate;if(u!==null&&(u=u.updateQueue,l===u)){var c=null,m=null;if(l=l.firstBaseUpdate,l!==null){do{var b={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};m===null?c=m=b:m=m.next=b,l=l.next}while(l!==null);m===null?c=m=n:m=m.next=n}else c=m=n;l={baseState:u.baseState,firstBaseUpdate:c,lastBaseUpdate:m,shared:u.shared,callbacks:u.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=n:e.next=n,l.lastBaseUpdate=n}var Nd=!1;function Uu(){if(Nd){var e=gl;if(e!==null)throw e}}function $u(e,n,l,u){Nd=!1;var c=e.updateQueue;_a=!1;var m=c.firstBaseUpdate,b=c.lastBaseUpdate,C=c.shared.pending;if(C!==null){c.shared.pending=null;var _=C,P=_.next;_.next=null,b===null?m=P:b.next=P,b=_;var ee=e.alternate;ee!==null&&(ee=ee.updateQueue,C=ee.lastBaseUpdate,C!==b&&(C===null?ee.firstBaseUpdate=P:C.next=P,ee.lastBaseUpdate=_))}if(m!==null){var le=c.baseState;b=0,ee=P=_=null,C=m;do{var G=C.lane&-536870913,W=G!==C.lane;if(W?(Ze&G)===G:(u&G)===G){G!==0&&G===yl&&(Nd=!0),ee!==null&&(ee=ee.next={lane:0,tag:C.tag,payload:C.payload,callback:null,next:null});e:{var xe=e,ze=C;G=n;var Ct=l;switch(ze.tag){case 1:if(xe=ze.payload,typeof xe=="function"){le=xe.call(Ct,le,G);break e}le=xe;break e;case 3:xe.flags=xe.flags&-65537|128;case 0:if(xe=ze.payload,G=typeof xe=="function"?xe.call(Ct,le,G):xe,G==null)break e;le=X({},le,G);break e;case 2:_a=!0}}G=C.callback,G!==null&&(e.flags|=64,W&&(e.flags|=8192),W=c.callbacks,W===null?c.callbacks=[G]:W.push(G))}else W={lane:G,tag:C.tag,payload:C.payload,callback:C.callback,next:null},ee===null?(P=ee=W,_=le):ee=ee.next=W,b|=G;if(C=C.next,C===null){if(C=c.shared.pending,C===null)break;W=C,C=W.next,W.next=null,c.lastBaseUpdate=W,c.shared.pending=null}}while(!0);ee===null&&(_=le),c.baseState=_,c.firstBaseUpdate=P,c.lastBaseUpdate=ee,m===null&&(c.shared.lanes=0),Ba|=b,e.lanes=b,e.memoizedState=le}}function ly(e,n){if(typeof e!="function")throw Error(i(191,e));e.call(n)}function uy(e,n){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)ly(l[e],n)}function Bu(e,n){try{var l=n.updateQueue,u=l!==null?l.lastEffect:null;if(u!==null){var c=u.next;l=c;do{if((l.tag&e)===e){u=void 0;var m=l.create,b=l.inst;u=m(),b.destroy=u}l=l.next}while(l!==c)}}catch(C){st(n,n.return,C)}}function La(e,n,l){try{var u=n.updateQueue,c=u!==null?u.lastEffect:null;if(c!==null){var m=c.next;u=m;do{if((u.tag&e)===e){var b=u.inst,C=b.destroy;if(C!==void 0){b.destroy=void 0,c=n;var _=l;try{C()}catch(P){st(c,_,P)}}}u=u.next}while(u!==m)}}catch(P){st(n,n.return,P)}}function oy(e){var n=e.updateQueue;if(n!==null){var l=e.stateNode;try{uy(n,l)}catch(u){st(e,e.return,u)}}}function sy(e,n,l){l.props=ji(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(u){st(e,n,u)}}function zi(e,n){try{var l=e.ref;if(l!==null){var u=e.stateNode;switch(e.tag){case 26:case 27:case 5:var c=u;break;default:c=u}typeof l=="function"?e.refCleanup=l(c):l.current=c}}catch(m){st(e,n,m)}}function An(e,n){var l=e.ref,u=e.refCleanup;if(l!==null)if(typeof u=="function")try{u()}catch(c){st(e,n,c)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(c){st(e,n,c)}else l.current=null}function cy(e){var n=e.type,l=e.memoizedProps,u=e.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":l.autoFocus&&u.focus();break e;case"img":l.src?u.src=l.src:l.srcSet&&(u.srcset=l.srcSet)}}catch(c){st(e,e.return,c)}}function fy(e,n,l){try{var u=e.stateNode;JE(u,e.type,l,n),u[Be]=n}catch(c){st(e,e.return,c)}}function dy(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27||e.tag===4}function zd(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||dy(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==27&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Ld(e,n,l){var u=e.tag;if(u===5||u===6)e=e.stateNode,n?l.nodeType===8?l.parentNode.insertBefore(e,n):l.insertBefore(e,n):(l.nodeType===8?(n=l.parentNode,n.insertBefore(e,l)):(n=l,n.appendChild(e)),l=l._reactRootContainer,l!=null||n.onclick!==null||(n.onclick=Ys));else if(u!==4&&u!==27&&(e=e.child,e!==null))for(Ld(e,n,l),e=e.sibling;e!==null;)Ld(e,n,l),e=e.sibling}function _s(e,n,l){var u=e.tag;if(u===5||u===6)e=e.stateNode,n?l.insertBefore(e,n):l.appendChild(e);else if(u!==4&&u!==27&&(e=e.child,e!==null))for(_s(e,n,l),e=e.sibling;e!==null;)_s(e,n,l),e=e.sibling}var ea=!1,wt=!1,Hd=!1,hy=typeof WeakSet=="function"?WeakSet:Set,Ft=null,my=!1;function DE(e,n){if(e=e.containerInfo,ch=Js,e=jp(e),$f(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else e:{l=(l=e.ownerDocument)&&l.defaultView||window;var u=l.getSelection&&l.getSelection();if(u&&u.rangeCount!==0){l=u.anchorNode;var c=u.anchorOffset,m=u.focusNode;u=u.focusOffset;try{l.nodeType,m.nodeType}catch{l=null;break e}var b=0,C=-1,_=-1,P=0,ee=0,le=e,G=null;t:for(;;){for(var W;le!==l||c!==0&&le.nodeType!==3||(C=b+c),le!==m||u!==0&&le.nodeType!==3||(_=b+u),le.nodeType===3&&(b+=le.nodeValue.length),(W=le.firstChild)!==null;)G=le,le=W;for(;;){if(le===e)break t;if(G===l&&++P===c&&(C=b),G===m&&++ee===u&&(_=b),(W=le.nextSibling)!==null)break;le=G,G=le.parentNode}le=W}l=C===-1||_===-1?null:{start:C,end:_}}else l=null}l=l||{start:0,end:0}}else l=null;for(fh={focusedElem:e,selectionRange:l},Js=!1,Ft=n;Ft!==null;)if(n=Ft,e=n.child,(n.subtreeFlags&1028)!==0&&e!==null)e.return=n,Ft=e;else for(;Ft!==null;){switch(n=Ft,m=n.alternate,e=n.flags,n.tag){case 0:break;case 11:case 15:break;case 1:if(e&1024&&m!==null){e=void 0,l=n,c=m.memoizedProps,m=m.memoizedState,u=l.stateNode;try{var xe=ji(l.type,c,l.elementType===l.type);e=u.getSnapshotBeforeUpdate(xe,m),u.__reactInternalSnapshotBeforeUpdate=e}catch(ze){st(l,l.return,ze)}}break;case 3:if(e&1024){if(e=n.stateNode.containerInfo,l=e.nodeType,l===9)vh(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":vh(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=n.sibling,e!==null){e.return=n.return,Ft=e;break}Ft=n.return}return xe=my,my=!1,xe}function vy(e,n,l){var u=l.flags;switch(l.tag){case 0:case 11:case 15:na(e,l),u&4&&Bu(5,l);break;case 1:if(na(e,l),u&4)if(e=l.stateNode,n===null)try{e.componentDidMount()}catch(C){st(l,l.return,C)}else{var c=ji(l.type,n.memoizedProps);n=n.memoizedState;try{e.componentDidUpdate(c,n,e.__reactInternalSnapshotBeforeUpdate)}catch(C){st(l,l.return,C)}}u&64&&oy(l),u&512&&zi(l,l.return);break;case 3:if(na(e,l),u&64&&(u=l.updateQueue,u!==null)){if(e=null,l.child!==null)switch(l.child.tag){case 27:case 5:e=l.child.stateNode;break;case 1:e=l.child.stateNode}try{uy(u,e)}catch(C){st(l,l.return,C)}}break;case 26:na(e,l),u&512&&zi(l,l.return);break;case 27:case 5:na(e,l),n===null&&u&4&&cy(l),u&512&&zi(l,l.return);break;case 12:na(e,l);break;case 13:na(e,l),u&4&&gy(e,l);break;case 22:if(c=l.memoizedState!==null||ea,!c){n=n!==null&&n.memoizedState!==null||wt;var m=ea,b=wt;ea=c,(wt=n)&&!b?Ha(e,l,(l.subtreeFlags&8772)!==0):na(e,l),ea=m,wt=b}u&512&&(l.memoizedProps.mode==="manual"?zi(l,l.return):An(l,l.return));break;default:na(e,l)}}function py(e){var n=e.alternate;n!==null&&(e.alternate=null,py(n)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(n=e.stateNode,n!==null&&Rn(n)),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 zt=null,Mn=!1;function ta(e,n,l){for(l=l.child;l!==null;)yy(e,n,l),l=l.sibling}function yy(e,n,l){if(cn&&typeof cn.onCommitFiberUnmount=="function")try{cn.onCommitFiberUnmount(Oa,l)}catch{}switch(l.tag){case 26:wt||An(l,n),ta(e,n,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:wt||An(l,n);var u=zt,c=Mn;for(zt=l.stateNode,ta(e,n,l),l=l.stateNode,n=l.attributes;n.length;)l.removeAttributeNode(n[0]);Rn(l),zt=u,Mn=c;break;case 5:wt||An(l,n);case 6:c=zt;var m=Mn;if(zt=null,ta(e,n,l),zt=c,Mn=m,zt!==null)if(Mn)try{e=zt,u=l.stateNode,e.nodeType===8?e.parentNode.removeChild(u):e.removeChild(u)}catch(b){st(l,n,b)}else try{zt.removeChild(l.stateNode)}catch(b){st(l,n,b)}break;case 18:zt!==null&&(Mn?(n=zt,l=l.stateNode,n.nodeType===8?mh(n.parentNode,l):n.nodeType===1&&mh(n,l),ro(n)):mh(zt,l.stateNode));break;case 4:u=zt,c=Mn,zt=l.stateNode.containerInfo,Mn=!0,ta(e,n,l),zt=u,Mn=c;break;case 0:case 11:case 14:case 15:wt||La(2,l,n),wt||La(4,l,n),ta(e,n,l);break;case 1:wt||(An(l,n),u=l.stateNode,typeof u.componentWillUnmount=="function"&&sy(l,n,u)),ta(e,n,l);break;case 21:ta(e,n,l);break;case 22:wt||An(l,n),wt=(u=wt)||l.memoizedState!==null,ta(e,n,l),wt=u;break;default:ta(e,n,l)}}function gy(e,n){if(n.memoizedState===null&&(e=n.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{ro(e)}catch(l){st(n,n.return,l)}}function AE(e){switch(e.tag){case 13:case 19:var n=e.stateNode;return n===null&&(n=e.stateNode=new hy),n;case 22:return e=e.stateNode,n=e._retryCache,n===null&&(n=e._retryCache=new hy),n;default:throw Error(i(435,e.tag))}}function Ud(e,n){var l=AE(e);n.forEach(function(u){var c=kE.bind(null,e,u);l.has(u)||(l.add(u),u.then(c,c))})}function Xn(e,n){var l=n.deletions;if(l!==null)for(var u=0;u<l.length;u++){var c=l[u],m=e,b=n,C=b;e:for(;C!==null;){switch(C.tag){case 27:case 5:zt=C.stateNode,Mn=!1;break e;case 3:zt=C.stateNode.containerInfo,Mn=!0;break e;case 4:zt=C.stateNode.containerInfo,Mn=!0;break e}C=C.return}if(zt===null)throw Error(i(160));yy(m,b,c),zt=null,Mn=!1,m=c.alternate,m!==null&&(m.return=null),c.return=null}if(n.subtreeFlags&13878)for(n=n.child;n!==null;)by(n,e),n=n.sibling}var sr=null;function by(e,n){var l=e.alternate,u=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Xn(n,e),Zn(e),u&4&&(La(3,e,e.return),Bu(3,e),La(5,e,e.return));break;case 1:Xn(n,e),Zn(e),u&512&&(wt||l===null||An(l,l.return)),u&64&&ea&&(e=e.updateQueue,e!==null&&(u=e.callbacks,u!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?u:l.concat(u))));break;case 26:var c=sr;if(Xn(n,e),Zn(e),u&512&&(wt||l===null||An(l,l.return)),u&4){var m=l!==null?l.memoizedState:null;if(u=e.memoizedState,l===null)if(u===null)if(e.stateNode===null){e:{u=e.type,l=e.memoizedProps,c=c.ownerDocument||c;t:switch(u){case"title":m=c.getElementsByTagName("title")[0],(!m||m[ar]||m[Ce]||m.namespaceURI==="http://www.w3.org/2000/svg"||m.hasAttribute("itemprop"))&&(m=c.createElement(u),c.head.insertBefore(m,c.querySelector("head > title"))),Gt(m,u,l),m[Ce]=e,gt(m),u=m;break e;case"link":var b=cg("link","href",c).get(u+(l.href||""));if(b){for(var C=0;C<b.length;C++)if(m=b[C],m.getAttribute("href")===(l.href==null?null:l.href)&&m.getAttribute("rel")===(l.rel==null?null:l.rel)&&m.getAttribute("title")===(l.title==null?null:l.title)&&m.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){b.splice(C,1);break t}}m=c.createElement(u),Gt(m,u,l),c.head.appendChild(m);break;case"meta":if(b=cg("meta","content",c).get(u+(l.content||""))){for(C=0;C<b.length;C++)if(m=b[C],m.getAttribute("content")===(l.content==null?null:""+l.content)&&m.getAttribute("name")===(l.name==null?null:l.name)&&m.getAttribute("property")===(l.property==null?null:l.property)&&m.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&m.getAttribute("charset")===(l.charSet==null?null:l.charSet)){b.splice(C,1);break t}}m=c.createElement(u),Gt(m,u,l),c.head.appendChild(m);break;default:throw Error(i(468,u))}m[Ce]=e,gt(m),u=m}e.stateNode=u}else fg(c,e.type,e.stateNode);else e.stateNode=sg(c,u,e.memoizedProps);else m!==u?(m===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):m.count--,u===null?fg(c,e.type,e.stateNode):sg(c,u,e.memoizedProps)):u===null&&e.stateNode!==null&&fy(e,e.memoizedProps,l.memoizedProps)}break;case 27:if(u&4&&e.alternate===null){c=e.stateNode,m=e.memoizedProps;try{for(var _=c.firstChild;_;){var P=_.nextSibling,ee=_.nodeName;_[ar]||ee==="HEAD"||ee==="BODY"||ee==="SCRIPT"||ee==="STYLE"||ee==="LINK"&&_.rel.toLowerCase()==="stylesheet"||c.removeChild(_),_=P}for(var le=e.type,G=c.attributes;G.length;)c.removeAttributeNode(G[0]);Gt(c,le,m),c[Ce]=e,c[Be]=m}catch(xe){st(e,e.return,xe)}}case 5:if(Xn(n,e),Zn(e),u&512&&(wt||l===null||An(l,l.return)),e.flags&32){c=e.stateNode;try{il(c,"")}catch(xe){st(e,e.return,xe)}}u&4&&e.stateNode!=null&&(c=e.memoizedProps,fy(e,c,l!==null?l.memoizedProps:c)),u&1024&&(Hd=!0);break;case 6:if(Xn(n,e),Zn(e),u&4){if(e.stateNode===null)throw Error(i(162));u=e.memoizedProps,l=e.stateNode;try{l.nodeValue=u}catch(xe){st(e,e.return,xe)}}break;case 3:if(Xs=null,c=sr,sr=Ks(n.containerInfo),Xn(n,e),sr=c,Zn(e),u&4&&l!==null&&l.memoizedState.isDehydrated)try{ro(n.containerInfo)}catch(xe){st(e,e.return,xe)}Hd&&(Hd=!1,Sy(e));break;case 4:u=sr,sr=Ks(e.stateNode.containerInfo),Xn(n,e),Zn(e),sr=u;break;case 12:Xn(n,e),Zn(e);break;case 13:Xn(n,e),Zn(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(Qd=jt()),u&4&&(u=e.updateQueue,u!==null&&(e.updateQueue=null,Ud(e,u)));break;case 22:if(u&512&&(wt||l===null||An(l,l.return)),_=e.memoizedState!==null,P=l!==null&&l.memoizedState!==null,ee=ea,le=wt,ea=ee||_,wt=le||P,Xn(n,e),wt=le,ea=ee,Zn(e),n=e.stateNode,n._current=e,n._visibility&=-3,n._visibility|=n._pendingVisibility&2,u&8192&&(n._visibility=_?n._visibility&-2:n._visibility|1,_&&(n=ea||wt,l===null||P||n||El(e)),e.memoizedProps===null||e.memoizedProps.mode!=="manual"))e:for(l=null,n=e;;){if(n.tag===5||n.tag===26||n.tag===27){if(l===null){P=l=n;try{if(c=P.stateNode,_)m=c.style,typeof m.setProperty=="function"?m.setProperty("display","none","important"):m.display="none";else{b=P.stateNode,C=P.memoizedProps.style;var W=C!=null&&C.hasOwnProperty("display")?C.display:null;b.style.display=W==null||typeof W=="boolean"?"":(""+W).trim()}}catch(xe){st(P,P.return,xe)}}}else if(n.tag===6){if(l===null){P=n;try{P.stateNode.nodeValue=_?"":P.memoizedProps}catch(xe){st(P,P.return,xe)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===e)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break e;for(;n.sibling===null;){if(n.return===null||n.return===e)break e;l===n&&(l=null),n=n.return}l===n&&(l=null),n.sibling.return=n.return,n=n.sibling}u&4&&(u=e.updateQueue,u!==null&&(l=u.retryQueue,l!==null&&(u.retryQueue=null,Ud(e,l))));break;case 19:Xn(n,e),Zn(e),u&4&&(u=e.updateQueue,u!==null&&(e.updateQueue=null,Ud(e,u)));break;case 21:break;default:Xn(n,e),Zn(e)}}function Zn(e){var n=e.flags;if(n&2){try{if(e.tag!==27){e:{for(var l=e.return;l!==null;){if(dy(l)){var u=l;break e}l=l.return}throw Error(i(160))}switch(u.tag){case 27:var c=u.stateNode,m=zd(e);_s(e,m,c);break;case 5:var b=u.stateNode;u.flags&32&&(il(b,""),u.flags&=-33);var C=zd(e);_s(e,C,b);break;case 3:case 4:var _=u.stateNode.containerInfo,P=zd(e);Ld(e,P,_);break;default:throw Error(i(161))}}}catch(ee){st(e,e.return,ee)}e.flags&=-3}n&4096&&(e.flags&=-4097)}function Sy(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var n=e;Sy(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),e=e.sibling}}function na(e,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)vy(e,n.alternate,n),n=n.sibling}function El(e){for(e=e.child;e!==null;){var n=e;switch(n.tag){case 0:case 11:case 14:case 15:La(4,n,n.return),El(n);break;case 1:An(n,n.return);var l=n.stateNode;typeof l.componentWillUnmount=="function"&&sy(n,n.return,l),El(n);break;case 26:case 27:case 5:An(n,n.return),El(n);break;case 22:An(n,n.return),n.memoizedState===null&&El(n);break;default:El(n)}e=e.sibling}}function Ha(e,n,l){for(l=l&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var u=n.alternate,c=e,m=n,b=m.flags;switch(m.tag){case 0:case 11:case 15:Ha(c,m,l),Bu(4,m);break;case 1:if(Ha(c,m,l),u=m,c=u.stateNode,typeof c.componentDidMount=="function")try{c.componentDidMount()}catch(P){st(u,u.return,P)}if(u=m,c=u.updateQueue,c!==null){var C=u.stateNode;try{var _=c.shared.hiddenCallbacks;if(_!==null)for(c.shared.hiddenCallbacks=null,c=0;c<_.length;c++)ly(_[c],C)}catch(P){st(u,u.return,P)}}l&&b&64&&oy(m),zi(m,m.return);break;case 26:case 27:case 5:Ha(c,m,l),l&&u===null&&b&4&&cy(m),zi(m,m.return);break;case 12:Ha(c,m,l);break;case 13:Ha(c,m,l),l&&b&4&&gy(c,m);break;case 22:m.memoizedState===null&&Ha(c,m,l),zi(m,m.return);break;default:Ha(c,m,l)}n=n.sibling}}function $d(e,n){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(e=n.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&Au(l))}function Bd(e,n){e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Au(e))}function Ua(e,n,l,u){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)xy(e,n,l,u),n=n.sibling}function xy(e,n,l,u){var c=n.flags;switch(n.tag){case 0:case 11:case 15:Ua(e,n,l,u),c&2048&&Bu(9,n);break;case 3:Ua(e,n,l,u),c&2048&&(e=null,n.alternate!==null&&(e=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==e&&(n.refCount++,e!=null&&Au(e)));break;case 12:if(c&2048){Ua(e,n,l,u),e=n.stateNode;try{var m=n.memoizedProps,b=m.id,C=m.onPostCommit;typeof C=="function"&&C(b,n.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(_){st(n,n.return,_)}}else Ua(e,n,l,u);break;case 23:break;case 22:m=n.stateNode,n.memoizedState!==null?m._visibility&4?Ua(e,n,l,u):Pu(e,n):m._visibility&4?Ua(e,n,l,u):(m._visibility|=4,wl(e,n,l,u,(n.subtreeFlags&10256)!==0)),c&2048&&$d(n.alternate,n);break;case 24:Ua(e,n,l,u),c&2048&&Bd(n.alternate,n);break;default:Ua(e,n,l,u)}}function wl(e,n,l,u,c){for(c=c&&(n.subtreeFlags&10256)!==0,n=n.child;n!==null;){var m=e,b=n,C=l,_=u,P=b.flags;switch(b.tag){case 0:case 11:case 15:wl(m,b,C,_,c),Bu(8,b);break;case 23:break;case 22:var ee=b.stateNode;b.memoizedState!==null?ee._visibility&4?wl(m,b,C,_,c):Pu(m,b):(ee._visibility|=4,wl(m,b,C,_,c)),c&&P&2048&&$d(b.alternate,b);break;case 24:wl(m,b,C,_,c),c&&P&2048&&Bd(b.alternate,b);break;default:wl(m,b,C,_,c)}n=n.sibling}}function Pu(e,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var l=e,u=n,c=u.flags;switch(u.tag){case 22:Pu(l,u),c&2048&&$d(u.alternate,u);break;case 24:Pu(l,u),c&2048&&Bd(u.alternate,u);break;default:Pu(l,u)}n=n.sibling}}var qu=8192;function Ol(e){if(e.subtreeFlags&qu)for(e=e.child;e!==null;)Ey(e),e=e.sibling}function Ey(e){switch(e.tag){case 26:Ol(e),e.flags&qu&&e.memoizedState!==null&&yw(sr,e.memoizedState,e.memoizedProps);break;case 5:Ol(e);break;case 3:case 4:var n=sr;sr=Ks(e.stateNode.containerInfo),Ol(e),sr=n;break;case 22:e.memoizedState===null&&(n=e.alternate,n!==null&&n.memoizedState!==null?(n=qu,qu=16777216,Ol(e),qu=n):Ol(e));break;default:Ol(e)}}function wy(e){var n=e.alternate;if(n!==null&&(e=n.child,e!==null)){n.child=null;do n=e.sibling,e.sibling=null,e=n;while(e!==null)}}function ku(e){var n=e.deletions;if(e.flags&16){if(n!==null)for(var l=0;l<n.length;l++){var u=n[l];Ft=u,Cy(u,e)}wy(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Oy(e),e=e.sibling}function Oy(e){switch(e.tag){case 0:case 11:case 15:ku(e),e.flags&2048&&La(9,e,e.return);break;case 3:ku(e);break;case 12:ku(e);break;case 22:var n=e.stateNode;e.memoizedState!==null&&n._visibility&4&&(e.return===null||e.return.tag!==13)?(n._visibility&=-5,Ns(e)):ku(e);break;default:ku(e)}}function Ns(e){var n=e.deletions;if(e.flags&16){if(n!==null)for(var l=0;l<n.length;l++){var u=n[l];Ft=u,Cy(u,e)}wy(e)}for(e=e.child;e!==null;){switch(n=e,n.tag){case 0:case 11:case 15:La(8,n,n.return),Ns(n);break;case 22:l=n.stateNode,l._visibility&4&&(l._visibility&=-5,Ns(n));break;default:Ns(n)}e=e.sibling}}function Cy(e,n){for(;Ft!==null;){var l=Ft;switch(l.tag){case 0:case 11:case 15:La(8,l,n);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var u=l.memoizedState.cachePool.pool;u!=null&&u.refCount++}break;case 24:Au(l.memoizedState.cache)}if(u=l.child,u!==null)u.return=l,Ft=u;else e:for(l=e;Ft!==null;){u=Ft;var c=u.sibling,m=u.return;if(py(u),u===l){Ft=null;break e}if(c!==null){c.return=m,Ft=c;break e}Ft=m}}}function ME(e,n,l,u){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=u,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function In(e,n,l,u){return new ME(e,n,l,u)}function Pd(e){return e=e.prototype,!(!e||!e.isReactComponent)}function $a(e,n){var l=e.alternate;return l===null?(l=In(e.tag,n,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=n,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&31457280,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,n=e.dependencies,l.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function Ty(e,n){e.flags&=31457282;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=n,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,n=l.dependencies,e.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),e}function zs(e,n,l,u,c,m){var b=0;if(u=e,typeof e=="function")Pd(e)&&(b=1);else if(typeof e=="string")b=vw(e,l,Mt.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case h:return Li(l.children,c,m,n);case v:b=8,c|=24;break;case y:return e=In(12,l,n,c|2),e.elementType=y,e.lanes=m,e;case x:return e=In(13,l,n,c),e.elementType=x,e.lanes=m,e;case R:return e=In(19,l,n,c),e.elementType=R,e.lanes=m,e;case N:return Ry(l,c,m,n);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case S:case g:b=10;break e;case p:b=9;break e;case w:b=11;break e;case T:b=14;break e;case A:b=16,u=null;break e}b=29,l=Error(i(130,e===null?"null":typeof e,"")),u=null}return n=In(b,l,n,c),n.elementType=e,n.type=u,n.lanes=m,n}function Li(e,n,l,u){return e=In(7,e,u,n),e.lanes=l,e}function Ry(e,n,l,u){e=In(22,e,u,n),e.elementType=N,e.lanes=l;var c={_visibility:1,_pendingVisibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null,_current:null,detach:function(){var m=c._current;if(m===null)throw Error(i(456));if(!(c._pendingVisibility&2)){var b=Ta(m,2);b!==null&&(c._pendingVisibility|=2,hn(b,m,2))}},attach:function(){var m=c._current;if(m===null)throw Error(i(456));if(c._pendingVisibility&2){var b=Ta(m,2);b!==null&&(c._pendingVisibility&=-3,hn(b,m,2))}}};return e.stateNode=c,e}function qd(e,n,l){return e=In(6,e,null,n),e.lanes=l,e}function kd(e,n,l){return n=In(4,e.children!==null?e.children:[],e.key,n),n.lanes=l,n.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},n}function ra(e){e.flags|=4}function Dy(e,n){if(n.type!=="stylesheet"||n.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!dg(n)){if(n=Gn.current,n!==null&&((Ze&4194176)===Ze?Or!==null:(Ze&62914560)!==Ze&&!(Ze&536870912)||n!==Or))throw Tu=Kf,Yp;e.flags|=8192}}function Ls(e,n){n!==null&&(e.flags|=4),e.flags&16384&&(n=e.tag!==22?Y():536870912,e.lanes|=n,Tl|=n)}function Fu(e,n){if(!Je)switch(e.tailMode){case"hidden":n=e.tail;for(var l=null;n!==null;)n.alternate!==null&&(l=n),n=n.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var u=null;l!==null;)l.alternate!==null&&(u=l),l=l.sibling;u===null?n||e.tail===null?e.tail=null:e.tail.sibling=null:u.sibling=null}}function bt(e){var n=e.alternate!==null&&e.alternate.child===e.child,l=0,u=0;if(n)for(var c=e.child;c!==null;)l|=c.lanes|c.childLanes,u|=c.subtreeFlags&31457280,u|=c.flags&31457280,c.return=e,c=c.sibling;else for(c=e.child;c!==null;)l|=c.lanes|c.childLanes,u|=c.subtreeFlags,u|=c.flags,c.return=e,c=c.sibling;return e.subtreeFlags|=u,e.childLanes=l,n}function jE(e,n,l){var u=n.pendingProps;switch(Yf(n),n.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return bt(n),null;case 1:return bt(n),null;case 3:return l=n.stateNode,u=null,e!==null&&(u=e.memoizedState.cache),n.memoizedState.cache!==u&&(n.flags|=2048),Wr($t),en(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(Eu(n)?ra(n):e===null||e.memoizedState.isDehydrated&&!(n.flags&256)||(n.flags|=1024,or!==null&&(Zd(or),or=null))),bt(n),null;case 26:return l=n.memoizedState,e===null?(ra(n),l!==null?(bt(n),Dy(n,l)):(bt(n),n.flags&=-16777217)):l?l!==e.memoizedState?(ra(n),bt(n),Dy(n,l)):(bt(n),n.flags&=-16777217):(e.memoizedProps!==u&&ra(n),bt(n),n.flags&=-16777217),null;case 27:be(n),l=ft.current;var c=n.type;if(e!==null&&n.stateNode!=null)e.memoizedProps!==u&&ra(n);else{if(!u){if(n.stateNode===null)throw Error(i(166));return bt(n),null}e=Mt.current,Eu(n)?Fp(n):(e=ag(c,u,l),n.stateNode=e,ra(n))}return bt(n),null;case 5:if(be(n),l=n.type,e!==null&&n.stateNode!=null)e.memoizedProps!==u&&ra(n);else{if(!u){if(n.stateNode===null)throw Error(i(166));return bt(n),null}if(e=Mt.current,Eu(n))Fp(n);else{switch(c=Qs(ft.current),e){case 1:e=c.createElementNS("http://www.w3.org/2000/svg",l);break;case 2:e=c.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;default:switch(l){case"svg":e=c.createElementNS("http://www.w3.org/2000/svg",l);break;case"math":e=c.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;case"script":e=c.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof u.is=="string"?c.createElement("select",{is:u.is}):c.createElement("select"),u.multiple?e.multiple=!0:u.size&&(e.size=u.size);break;default:e=typeof u.is=="string"?c.createElement(l,{is:u.is}):c.createElement(l)}}e[Ce]=n,e[Be]=u;e:for(c=n.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===n)break e;for(;c.sibling===null;){if(c.return===null||c.return===n)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}n.stateNode=e;e:switch(Gt(e,l,u),l){case"button":case"input":case"select":case"textarea":e=!!u.autoFocus;break e;case"img":e=!0;break e;default:e=!1}e&&ra(n)}}return bt(n),n.flags&=-16777217,null;case 6:if(e&&n.stateNode!=null)e.memoizedProps!==u&&ra(n);else{if(typeof u!="string"&&n.stateNode===null)throw Error(i(166));if(e=ft.current,Eu(n)){if(e=n.stateNode,l=n.memoizedProps,u=null,c=dn,c!==null)switch(c.tag){case 27:case 5:u=c.memoizedProps}e[Ce]=n,e=!!(e.nodeValue===l||u!==null&&u.suppressHydrationWarning===!0||Jy(e.nodeValue,l)),e||Ci(n)}else e=Qs(e).createTextNode(u),e[Ce]=n,n.stateNode=e}return bt(n),null;case 13:if(u=n.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(c=Eu(n),u!==null&&u.dehydrated!==null){if(e===null){if(!c)throw Error(i(318));if(c=n.memoizedState,c=c!==null?c.dehydrated:null,!c)throw Error(i(317));c[Ce]=n}else wu(),!(n.flags&128)&&(n.memoizedState=null),n.flags|=4;bt(n),c=!1}else or!==null&&(Zd(or),or=null),c=!0;if(!c)return n.flags&256?(Xr(n),n):(Xr(n),null)}if(Xr(n),n.flags&128)return n.lanes=l,n;if(l=u!==null,e=e!==null&&e.memoizedState!==null,l){u=n.child,c=null,u.alternate!==null&&u.alternate.memoizedState!==null&&u.alternate.memoizedState.cachePool!==null&&(c=u.alternate.memoizedState.cachePool.pool);var m=null;u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(m=u.memoizedState.cachePool.pool),m!==c&&(u.flags|=2048)}return l!==e&&l&&(n.child.flags|=8192),Ls(n,n.updateQueue),bt(n),null;case 4:return en(),e===null&&uh(n.stateNode.containerInfo),bt(n),null;case 10:return Wr(n.type),bt(n),null;case 19:if(je(Ut),c=n.memoizedState,c===null)return bt(n),null;if(u=(n.flags&128)!==0,m=c.rendering,m===null)if(u)Fu(c,!1);else{if(Ot!==0||e!==null&&e.flags&128)for(e=n.child;e!==null;){if(m=gs(e),m!==null){for(n.flags|=128,Fu(c,!1),e=m.updateQueue,n.updateQueue=e,Ls(n,e),n.subtreeFlags=0,e=l,l=n.child;l!==null;)Ty(l,e),l=l.sibling;return Ne(Ut,Ut.current&1|2),n.child}e=e.sibling}c.tail!==null&&jt()>Hs&&(n.flags|=128,u=!0,Fu(c,!1),n.lanes=4194304)}else{if(!u)if(e=gs(m),e!==null){if(n.flags|=128,u=!0,e=e.updateQueue,n.updateQueue=e,Ls(n,e),Fu(c,!0),c.tail===null&&c.tailMode==="hidden"&&!m.alternate&&!Je)return bt(n),null}else 2*jt()-c.renderingStartTime>Hs&&l!==536870912&&(n.flags|=128,u=!0,Fu(c,!1),n.lanes=4194304);c.isBackwards?(m.sibling=n.child,n.child=m):(e=c.last,e!==null?e.sibling=m:n.child=m,c.last=m)}return c.tail!==null?(n=c.tail,c.rendering=n,c.tail=n.sibling,c.renderingStartTime=jt(),n.sibling=null,e=Ut.current,Ne(Ut,u?e&1|2:e&1),n):(bt(n),null);case 22:case 23:return Xr(n),Xf(),u=n.memoizedState!==null,e!==null?e.memoizedState!==null!==u&&(n.flags|=8192):u&&(n.flags|=8192),u?l&536870912&&!(n.flags&128)&&(bt(n),n.subtreeFlags&6&&(n.flags|=8192)):bt(n),l=n.updateQueue,l!==null&&Ls(n,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),u=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(u=n.memoizedState.cachePool.pool),u!==l&&(n.flags|=2048),e!==null&&je(Ri),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),n.memoizedState.cache!==l&&(n.flags|=2048),Wr($t),bt(n),null;case 25:return null}throw Error(i(156,n.tag))}function _E(e,n){switch(Yf(n),n.tag){case 1:return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 3:return Wr($t),en(),e=n.flags,e&65536&&!(e&128)?(n.flags=e&-65537|128,n):null;case 26:case 27:case 5:return be(n),null;case 13:if(Xr(n),e=n.memoizedState,e!==null&&e.dehydrated!==null){if(n.alternate===null)throw Error(i(340));wu()}return e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 19:return je(Ut),null;case 4:return en(),null;case 10:return Wr(n.type),null;case 22:case 23:return Xr(n),Xf(),e!==null&&je(Ri),e=n.flags,e&65536?(n.flags=e&-65537|128,n):null;case 24:return Wr($t),null;case 25:return null;default:return null}}function Ay(e,n){switch(Yf(n),n.tag){case 3:Wr($t),en();break;case 26:case 27:case 5:be(n);break;case 4:en();break;case 13:Xr(n);break;case 19:je(Ut);break;case 10:Wr(n.type);break;case 22:case 23:Xr(n),Xf(),e!==null&&je(Ri);break;case 24:Wr($t)}}var NE={getCacheForType:function(e){var n=nn($t),l=n.data.get(e);return l===void 0&&(l=e(),n.data.set(e,l)),l}},zE=typeof WeakMap=="function"?WeakMap:Map,St=0,dt=null,Ve=null,Ze=0,ht=0,jn=null,aa=!1,Cl=!1,Fd=!1,ia=0,Ot=0,Ba=0,Hi=0,Vd=0,Jn=0,Tl=0,Vu=null,Tr=null,Yd=!1,Qd=0,Hs=1/0,Us=null,Pa=null,$s=!1,Ui=null,Yu=0,Kd=0,Gd=null,Qu=0,Xd=null;function _n(){if(St&2&&Ze!==0)return Ze&-Ze;if(z.T!==null){var e=yl;return e!==0?e:rh()}return Se()}function My(){Jn===0&&(Jn=!(Ze&536870912)||Je?H():536870912);var e=Gn.current;return e!==null&&(e.flags|=32),Jn}function hn(e,n,l){(e===dt&&ht===2||e.cancelPendingCommit!==null)&&(Rl(e,0),la(e,Ze,Jn,!1)),ue(e,l),(!(St&2)||e!==dt)&&(e===dt&&(!(St&2)&&(Hi|=l),Ot===4&&la(e,Ze,Jn,!1)),Rr(e))}function jy(e,n,l){if(St&6)throw Error(i(327));var u=!l&&(n&60)===0&&(n&e.expiredLanes)===0||gi(e,n),c=u?UE(e,n):Wd(e,n,!0),m=u;do{if(c===0){Cl&&!u&&la(e,n,0,!1);break}else if(c===6)la(e,n,0,!aa);else{if(l=e.current.alternate,m&&!LE(l)){c=Wd(e,n,!1),m=!1;continue}if(c===2){if(m=n,e.errorRecoveryDisabledLanes&m)var b=0;else b=e.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){n=b;e:{var C=e;c=Vu;var _=C.current.memoizedState.isDehydrated;if(_&&(Rl(C,b).flags|=256),b=Wd(C,b,!1),b!==2){if(Fd&&!_){C.errorRecoveryDisabledLanes|=m,Hi|=m,c=4;break e}m=Tr,Tr=c,m!==null&&Zd(m)}c=b}if(m=!1,c!==2)continue}}if(c===1){Rl(e,0),la(e,n,0,!0);break}e:{switch(u=e,c){case 0:case 1:throw Error(i(345));case 4:if((n&4194176)===n){la(u,n,Jn,!aa);break e}break;case 2:Tr=null;break;case 3:case 5:break;default:throw Error(i(329))}if(u.finishedWork=l,u.finishedLanes=n,(n&62914560)===n&&(m=Qd+300-jt(),10<m)){if(la(u,n,Jn,!aa),Fr(u,0)!==0)break e;u.timeoutHandle=tg(_y.bind(null,u,l,Tr,Us,Yd,n,Jn,Hi,Tl,aa,2,-0,0),m);break e}_y(u,l,Tr,Us,Yd,n,Jn,Hi,Tl,aa,0,-0,0)}}break}while(!0);Rr(e)}function Zd(e){Tr===null?Tr=e:Tr.push.apply(Tr,e)}function _y(e,n,l,u,c,m,b,C,_,P,ee,le,G){var W=n.subtreeFlags;if((W&8192||(W&16785408)===16785408)&&(Ju={stylesheets:null,count:0,unsuspend:pw},Ey(n),n=gw(),n!==null)){e.cancelPendingCommit=n(By.bind(null,e,l,u,c,b,C,_,1,le,G)),la(e,m,b,!P);return}By(e,l,u,c,b,C,_,ee,le,G)}function LE(e){for(var n=e;;){var l=n.tag;if((l===0||l===11||l===15)&&n.flags&16384&&(l=n.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var u=0;u<l.length;u++){var c=l[u],m=c.getSnapshot;c=c.value;try{if(!Dn(m(),c))return!1}catch{return!1}}if(l=n.child,n.subtreeFlags&16384&&l!==null)l.return=n,n=l;else{if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}function la(e,n,l,u){n&=~Vd,n&=~Hi,e.suspendedLanes|=n,e.pingedLanes&=~n,u&&(e.warmLanes|=n),u=e.expirationTimes;for(var c=n;0<c;){var m=31-tn(c),b=1<<m;u[m]=-1,c&=~b}l!==0&&Ee(e,l,n)}function Bs(){return St&6?!0:(Ku(0),!1)}function Id(){if(Ve!==null){if(ht===0)var e=Ve.return;else e=Ve,Jr=_i=null,rd(e),vl=null,Ru=0,e=Ve;for(;e!==null;)Ay(e.alternate,e),e=e.return;Ve=null}}function Rl(e,n){e.finishedWork=null,e.finishedLanes=0;var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,ew(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),Id(),dt=e,Ve=l=$a(e.current,null),Ze=n,ht=0,jn=null,aa=!1,Cl=gi(e,n),Fd=!1,Tl=Jn=Vd=Hi=Ba=Ot=0,Tr=Vu=null,Yd=!1,n&8&&(n|=n&32);var u=e.entangledLanes;if(u!==0)for(e=e.entanglements,u&=n;0<u;){var c=31-tn(u),m=1<<c;n|=e[c],u&=~m}return ia=n,ss(),l}function Ny(e,n){Pe=null,z.H=Cr,n===Cu?(n=Gp(),ht=3):n===Yp?(n=Gp(),ht=4):ht=n===Q0?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,jn=n,Ve===null&&(Ot=1,As(e,Yn(n,e.current)))}function zy(){var e=z.H;return z.H=Cr,e===null?Cr:e}function Ly(){var e=z.A;return z.A=NE,e}function Jd(){Ot=4,aa||(Ze&4194176)!==Ze&&Gn.current!==null||(Cl=!0),!(Ba&134217727)&&!(Hi&134217727)||dt===null||la(dt,Ze,Jn,!1)}function Wd(e,n,l){var u=St;St|=2;var c=zy(),m=Ly();(dt!==e||Ze!==n)&&(Us=null,Rl(e,n)),n=!1;var b=Ot;e:do try{if(ht!==0&&Ve!==null){var C=Ve,_=jn;switch(ht){case 8:Id(),b=6;break e;case 3:case 2:case 6:Gn.current===null&&(n=!0);var P=ht;if(ht=0,jn=null,Dl(e,C,_,P),l&&Cl){b=0;break e}break;default:P=ht,ht=0,jn=null,Dl(e,C,_,P)}}HE(),b=Ot;break}catch(ee){Ny(e,ee)}while(!0);return n&&e.shellSuspendCounter++,Jr=_i=null,St=u,z.H=c,z.A=m,Ve===null&&(dt=null,Ze=0,ss()),b}function HE(){for(;Ve!==null;)Hy(Ve)}function UE(e,n){var l=St;St|=2;var u=zy(),c=Ly();dt!==e||Ze!==n?(Us=null,Hs=jt()+500,Rl(e,n)):Cl=gi(e,n);e:do try{if(ht!==0&&Ve!==null){n=Ve;var m=jn;t:switch(ht){case 1:ht=0,jn=null,Dl(e,n,m,1);break;case 2:if(Qp(m)){ht=0,jn=null,Uy(n);break}n=function(){ht===2&&dt===e&&(ht=7),Rr(e)},m.then(n,n);break e;case 3:ht=7;break e;case 4:ht=5;break e;case 7:Qp(m)?(ht=0,jn=null,Uy(n)):(ht=0,jn=null,Dl(e,n,m,7));break;case 5:var b=null;switch(Ve.tag){case 26:b=Ve.memoizedState;case 5:case 27:var C=Ve;if(!b||dg(b)){ht=0,jn=null;var _=C.sibling;if(_!==null)Ve=_;else{var P=C.return;P!==null?(Ve=P,Ps(P)):Ve=null}break t}}ht=0,jn=null,Dl(e,n,m,5);break;case 6:ht=0,jn=null,Dl(e,n,m,6);break;case 8:Id(),Ot=6;break e;default:throw Error(i(462))}}$E();break}catch(ee){Ny(e,ee)}while(!0);return Jr=_i=null,z.H=u,z.A=c,St=l,Ve!==null?0:(dt=null,Ze=0,ss(),Ot)}function $E(){for(;Ve!==null&&!Rt();)Hy(Ve)}function Hy(e){var n=ay(e.alternate,e,ia);e.memoizedProps=e.pendingProps,n===null?Ps(e):Ve=n}function Uy(e){var n=e,l=n.alternate;switch(n.tag){case 15:case 0:n=J0(l,n,n.pendingProps,n.type,void 0,Ze);break;case 11:n=J0(l,n,n.pendingProps,n.type.render,n.ref,Ze);break;case 5:rd(n);default:Ay(l,n),n=Ve=Ty(n,ia),n=ay(l,n,ia)}e.memoizedProps=e.pendingProps,n===null?Ps(e):Ve=n}function Dl(e,n,l,u){Jr=_i=null,rd(n),vl=null,Ru=0;var c=n.return;try{if(TE(e,c,n,l,Ze)){Ot=1,As(e,Yn(l,e.current)),Ve=null;return}}catch(m){if(c!==null)throw Ve=c,m;Ot=1,As(e,Yn(l,e.current)),Ve=null;return}n.flags&32768?(Je||u===1?e=!0:Cl||Ze&536870912?e=!1:(aa=e=!0,(u===2||u===3||u===6)&&(u=Gn.current,u!==null&&u.tag===13&&(u.flags|=16384))),$y(n,e)):Ps(n)}function Ps(e){var n=e;do{if(n.flags&32768){$y(n,aa);return}e=n.return;var l=jE(n.alternate,n,ia);if(l!==null){Ve=l;return}if(n=n.sibling,n!==null){Ve=n;return}Ve=n=e}while(n!==null);Ot===0&&(Ot=5)}function $y(e,n){do{var l=_E(e.alternate,e);if(l!==null){l.flags&=32767,Ve=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!n&&(e=e.sibling,e!==null)){Ve=e;return}Ve=e=l}while(e!==null);Ot=6,Ve=null}function By(e,n,l,u,c,m,b,C,_,P){var ee=z.T,le=ce.p;try{ce.p=2,z.T=null,BE(e,n,l,u,le,c,m,b,C,_,P)}finally{z.T=ee,ce.p=le}}function BE(e,n,l,u,c,m,b,C){do Al();while(Ui!==null);if(St&6)throw Error(i(327));var _=e.finishedWork;if(u=e.finishedLanes,_===null)return null;if(e.finishedWork=null,e.finishedLanes=0,_===e.current)throw Error(i(177));e.callbackNode=null,e.callbackPriority=0,e.cancelPendingCommit=null;var P=_.lanes|_.childLanes;if(P|=kf,ve(e,u,P,m,b,C),e===dt&&(Ve=dt=null,Ze=0),!(_.subtreeFlags&10256)&&!(_.flags&10256)||$s||($s=!0,Kd=P,Gd=l,FE(wa,function(){return Al(),null})),l=(_.flags&15990)!==0,_.subtreeFlags&15990||l?(l=z.T,z.T=null,m=ce.p,ce.p=2,b=St,St|=4,DE(e,_),by(_,e),sE(fh,e.containerInfo),Js=!!ch,fh=ch=null,e.current=_,vy(e,_.alternate,_),un(),St=b,ce.p=m,z.T=l):e.current=_,$s?($s=!1,Ui=e,Yu=u):Py(e,P),P=e.pendingLanes,P===0&&(Pa=null),Zo(_.stateNode),Rr(e),n!==null)for(c=e.onRecoverableError,_=0;_<n.length;_++)P=n[_],c(P.value,{componentStack:P.stack});return Yu&3&&Al(),P=e.pendingLanes,u&4194218&&P&42?e===Xd?Qu++:(Qu=0,Xd=e):Qu=0,Ku(0),null}function Py(e,n){(e.pooledCacheLanes&=n)===0&&(n=e.pooledCache,n!=null&&(e.pooledCache=null,Au(n)))}function Al(){if(Ui!==null){var e=Ui,n=Kd;Kd=0;var l=pe(Yu),u=z.T,c=ce.p;try{if(ce.p=32>l?32:l,z.T=null,Ui===null)var m=!1;else{l=Gd,Gd=null;var b=Ui,C=Yu;if(Ui=null,Yu=0,St&6)throw Error(i(331));var _=St;if(St|=4,Oy(b.current),xy(b,b.current,C,l),St=_,Ku(0,!1),cn&&typeof cn.onPostCommitFiberRoot=="function")try{cn.onPostCommitFiberRoot(Oa,b)}catch{}m=!0}return m}finally{ce.p=c,z.T=u,Py(e,n)}}return!1}function qy(e,n,l){n=Yn(l,n),n=yd(e.stateNode,n,2),e=za(e,n,2),e!==null&&(ue(e,2),Rr(e))}function st(e,n,l){if(e.tag===3)qy(e,e,l);else for(;n!==null;){if(n.tag===3){qy(n,e,l);break}else if(n.tag===1){var u=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof u.componentDidCatch=="function"&&(Pa===null||!Pa.has(u))){e=Yn(l,e),l=V0(2),u=za(n,l,2),u!==null&&(Y0(l,u,n,e),ue(u,2),Rr(u));break}}n=n.return}}function eh(e,n,l){var u=e.pingCache;if(u===null){u=e.pingCache=new zE;var c=new Set;u.set(n,c)}else c=u.get(n),c===void 0&&(c=new Set,u.set(n,c));c.has(l)||(Fd=!0,c.add(l),e=PE.bind(null,e,n,l),n.then(e,e))}function PE(e,n,l){var u=e.pingCache;u!==null&&u.delete(n),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,dt===e&&(Ze&l)===l&&(Ot===4||Ot===3&&(Ze&62914560)===Ze&&300>jt()-Qd?!(St&2)&&Rl(e,0):Vd|=l,Tl===Ze&&(Tl=0)),Rr(e)}function ky(e,n){n===0&&(n=Y()),e=Ta(e,n),e!==null&&(ue(e,n),Rr(e))}function qE(e){var n=e.memoizedState,l=0;n!==null&&(l=n.retryLane),ky(e,l)}function kE(e,n){var l=0;switch(e.tag){case 13:var u=e.stateNode,c=e.memoizedState;c!==null&&(l=c.retryLane);break;case 19:u=e.stateNode;break;case 22:u=e.stateNode._retryCache;break;default:throw Error(i(314))}u!==null&&u.delete(n),ky(e,l)}function FE(e,n){return xt(e,n)}var qs=null,Ml=null,th=!1,ks=!1,nh=!1,$i=0;function Rr(e){e!==Ml&&e.next===null&&(Ml===null?qs=Ml=e:Ml=Ml.next=e),ks=!0,th||(th=!0,YE(VE))}function Ku(e,n){if(!nh&&ks){nh=!0;do for(var l=!1,u=qs;u!==null;){if(e!==0){var c=u.pendingLanes;if(c===0)var m=0;else{var b=u.suspendedLanes,C=u.pingedLanes;m=(1<<31-tn(42|e)+1)-1,m&=c&~(b&~C),m=m&201326677?m&201326677|1:m?m|2:0}m!==0&&(l=!0,Yy(u,m))}else m=Ze,m=Fr(u,u===dt?m:0),!(m&3)||gi(u,m)||(l=!0,Yy(u,m));u=u.next}while(l);nh=!1}}function VE(){ks=th=!1;var e=0;$i!==0&&(WE()&&(e=$i),$i=0);for(var n=jt(),l=null,u=qs;u!==null;){var c=u.next,m=Fy(u,n);m===0?(u.next=null,l===null?qs=c:l.next=c,c===null&&(Ml=l)):(l=u,(e!==0||m&3)&&(ks=!0)),u=c}Ku(e)}function Fy(e,n){for(var l=e.suspendedLanes,u=e.pingedLanes,c=e.expirationTimes,m=e.pendingLanes&-62914561;0<m;){var b=31-tn(m),C=1<<b,_=c[b];_===-1?(!(C&l)||C&u)&&(c[b]=xf(C,n)):_<=n&&(e.expiredLanes|=C),m&=~C}if(n=dt,l=Ze,l=Fr(e,e===n?l:0),u=e.callbackNode,l===0||e===n&&ht===2||e.cancelPendingCommit!==null)return u!==null&&u!==null&&Le(u),e.callbackNode=null,e.callbackPriority=0;if(!(l&3)||gi(e,l)){if(n=l&-l,n===e.callbackPriority)return n;switch(u!==null&&Le(u),pe(l)){case 2:case 8:l=cu;break;case 32:l=wa;break;case 268435456:l=rr;break;default:l=wa}return u=Vy.bind(null,e),l=xt(l,u),e.callbackPriority=n,e.callbackNode=l,n}return u!==null&&u!==null&&Le(u),e.callbackPriority=2,e.callbackNode=null,2}function Vy(e,n){var l=e.callbackNode;if(Al()&&e.callbackNode!==l)return null;var u=Ze;return u=Fr(e,e===dt?u:0),u===0?null:(jy(e,u,n),Fy(e,jt()),e.callbackNode!=null&&e.callbackNode===l?Vy.bind(null,e):null)}function Yy(e,n){if(Al())return null;jy(e,n,!0)}function YE(e){tw(function(){St&6?xt(sn,e):e()})}function rh(){return $i===0&&($i=H()),$i}function Qy(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:ns(""+e)}function Ky(e,n){var l=n.ownerDocument.createElement("input");return l.name=n.name,l.value=n.value,e.id&&l.setAttribute("form",e.id),n.parentNode.insertBefore(l,n),e=new FormData(e),l.parentNode.removeChild(l),e}function QE(e,n,l,u,c){if(n==="submit"&&l&&l.stateNode===c){var m=Qy((c[Be]||null).action),b=u.submitter;b&&(n=(n=b[Be]||null)?Qy(n.formAction):b.getAttribute("formAction"),n!==null&&(m=n,b=null));var C=new ls("action","action",null,u,c);e.push({event:C,listeners:[{instance:null,listener:function(){if(u.defaultPrevented){if($i!==0){var _=b?Ky(c,b):new FormData(c);dd(l,{pending:!0,data:_,method:c.method,action:m},null,_)}}else typeof m=="function"&&(C.preventDefault(),_=b?Ky(c,b):new FormData(c),dd(l,{pending:!0,data:_,method:c.method,action:m},m,_))},currentTarget:c}]})}}for(var ah=0;ah<Bp.length;ah++){var ih=Bp[ah],KE=ih.toLowerCase(),GE=ih[0].toUpperCase()+ih.slice(1);ur(KE,"on"+GE)}ur(zp,"onAnimationEnd"),ur(Lp,"onAnimationIteration"),ur(Hp,"onAnimationStart"),ur("dblclick","onDoubleClick"),ur("focusin","onFocus"),ur("focusout","onBlur"),ur(fE,"onTransitionRun"),ur(dE,"onTransitionStart"),ur(hE,"onTransitionCancel"),ur(Up,"onTransitionEnd"),lr("onMouseEnter",["mouseout","mouseover"]),lr("onMouseLeave",["mouseout","mouseover"]),lr("onPointerEnter",["pointerout","pointerover"]),lr("onPointerLeave",["pointerout","pointerover"]),pt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),pt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),pt("onBeforeInput",["compositionend","keypress","textInput","paste"]),pt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),pt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),pt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Gu="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(" "),XE=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Gu));function Gy(e,n){n=(n&4)!==0;for(var l=0;l<e.length;l++){var u=e[l],c=u.event;u=u.listeners;e:{var m=void 0;if(n)for(var b=u.length-1;0<=b;b--){var C=u[b],_=C.instance,P=C.currentTarget;if(C=C.listener,_!==m&&c.isPropagationStopped())break e;m=C,c.currentTarget=P;try{m(c)}catch(ee){Ds(ee)}c.currentTarget=null,m=_}else for(b=0;b<u.length;b++){if(C=u[b],_=C.instance,P=C.currentTarget,C=C.listener,_!==m&&c.isPropagationStopped())break e;m=C,c.currentTarget=P;try{m(c)}catch(ee){Ds(ee)}c.currentTarget=null,m=_}}}}function Qe(e,n){var l=n[ut];l===void 0&&(l=n[ut]=new Set);var u=e+"__bubble";l.has(u)||(Xy(n,e,2,!1),l.add(u))}function lh(e,n,l){var u=0;n&&(u|=4),Xy(l,e,u,n)}var Fs="_reactListening"+Math.random().toString(36).slice(2);function uh(e){if(!e[Fs]){e[Fs]=!0,bi.forEach(function(l){l!=="selectionchange"&&(XE.has(l)||lh(l,!1,e),lh(l,!0,e))});var n=e.nodeType===9?e:e.ownerDocument;n===null||n[Fs]||(n[Fs]=!0,lh("selectionchange",!1,n))}}function Xy(e,n,l,u){switch(gg(n)){case 2:var c=xw;break;case 8:c=Ew;break;default:c=Sh}l=c.bind(null,n,l,e),c=void 0,!Af||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(c=!0),u?c!==void 0?e.addEventListener(n,l,{capture:!0,passive:c}):e.addEventListener(n,l,!0):c!==void 0?e.addEventListener(n,l,{passive:c}):e.addEventListener(n,l,!1)}function oh(e,n,l,u,c){var m=u;if(!(n&1)&&!(n&2)&&u!==null)e:for(;;){if(u===null)return;var b=u.tag;if(b===3||b===4){var C=u.stateNode.containerInfo;if(C===c||C.nodeType===8&&C.parentNode===c)break;if(b===4)for(b=u.return;b!==null;){var _=b.tag;if((_===3||_===4)&&(_=b.stateNode.containerInfo,_===c||_.nodeType===8&&_.parentNode===c))return;b=b.return}for(;C!==null;){if(b=qt(C),b===null)return;if(_=b.tag,_===5||_===6||_===26||_===27){u=m=b;continue e}C=C.parentNode}}u=u.return}cp(function(){var P=m,ee=Rf(l),le=[];e:{var G=$p.get(e);if(G!==void 0){var W=ls,xe=e;switch(e){case"keypress":if(as(l)===0)break e;case"keydown":case"keyup":W=k2;break;case"focusin":xe="focus",W=Nf;break;case"focusout":xe="blur",W=Nf;break;case"beforeblur":case"afterblur":W=Nf;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":W=hp;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":W=M2;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":W=Y2;break;case zp:case Lp:case Hp:W=N2;break;case Up:W=K2;break;case"scroll":case"scrollend":W=D2;break;case"wheel":W=X2;break;case"copy":case"cut":case"paste":W=L2;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":W=vp;break;case"toggle":case"beforetoggle":W=I2}var ze=(n&4)!==0,Ct=!ze&&(e==="scroll"||e==="scrollend"),k=ze?G!==null?G+"Capture":null:G;ze=[];for(var $=P,Q;$!==null;){var re=$;if(Q=re.stateNode,re=re.tag,re!==5&&re!==26&&re!==27||Q===null||k===null||(re=hu($,k),re!=null&&ze.push(Xu($,re,Q))),Ct)break;$=$.return}0<ze.length&&(G=new W(G,xe,null,l,ee),le.push({event:G,listeners:ze}))}}if(!(n&7)){e:{if(G=e==="mouseover"||e==="pointerover",W=e==="mouseout"||e==="pointerout",G&&l!==Tf&&(xe=l.relatedTarget||l.fromElement)&&(qt(xe)||xe[vt]))break e;if((W||G)&&(G=ee.window===ee?ee:(G=ee.ownerDocument)?G.defaultView||G.parentWindow:window,W?(xe=l.relatedTarget||l.toElement,W=P,xe=xe?qt(xe):null,xe!==null&&(Ct=ne(xe),ze=xe.tag,xe!==Ct||ze!==5&&ze!==27&&ze!==6)&&(xe=null)):(W=null,xe=P),W!==xe)){if(ze=hp,re="onMouseLeave",k="onMouseEnter",$="mouse",(e==="pointerout"||e==="pointerover")&&(ze=vp,re="onPointerLeave",k="onPointerEnter",$="pointer"),Ct=W==null?G:ir(W),Q=xe==null?G:ir(xe),G=new ze(re,$+"leave",W,l,ee),G.target=Ct,G.relatedTarget=Q,re=null,qt(ee)===P&&(ze=new ze(k,$+"enter",xe,l,ee),ze.target=Q,ze.relatedTarget=Ct,re=ze),Ct=re,W&&xe)t:{for(ze=W,k=xe,$=0,Q=ze;Q;Q=jl(Q))$++;for(Q=0,re=k;re;re=jl(re))Q++;for(;0<$-Q;)ze=jl(ze),$--;for(;0<Q-$;)k=jl(k),Q--;for(;$--;){if(ze===k||k!==null&&ze===k.alternate)break t;ze=jl(ze),k=jl(k)}ze=null}else ze=null;W!==null&&Zy(le,G,W,ze,!1),xe!==null&&Ct!==null&&Zy(le,Ct,xe,ze,!0)}}e:{if(G=P?ir(P):window,W=G.nodeName&&G.nodeName.toLowerCase(),W==="select"||W==="input"&&G.type==="file")var ye=wp;else if(xp(G))if(Op)ye=uE;else{ye=iE;var ke=aE}else W=G.nodeName,!W||W.toLowerCase()!=="input"||G.type!=="checkbox"&&G.type!=="radio"?P&&Cf(P.elementType)&&(ye=wp):ye=lE;if(ye&&(ye=ye(e,P))){Ep(le,ye,l,ee);break e}ke&&ke(e,G,P),e==="focusout"&&P&&G.type==="number"&&P.memoizedProps.value!=null&&Of(G,"number",G.value)}switch(ke=P?ir(P):window,e){case"focusin":(xp(ke)||ke.contentEditable==="true")&&(sl=ke,Bf=P,xu=null);break;case"focusout":xu=Bf=sl=null;break;case"mousedown":Pf=!0;break;case"contextmenu":case"mouseup":case"dragend":Pf=!1,_p(le,l,ee);break;case"selectionchange":if(cE)break;case"keydown":case"keyup":_p(le,l,ee)}var Oe;if(Lf)e:{switch(e){case"compositionstart":var Ae="onCompositionStart";break e;case"compositionend":Ae="onCompositionEnd";break e;case"compositionupdate":Ae="onCompositionUpdate";break e}Ae=void 0}else ol?bp(e,l)&&(Ae="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(Ae="onCompositionStart");Ae&&(pp&&l.locale!=="ko"&&(ol||Ae!=="onCompositionStart"?Ae==="onCompositionEnd"&&ol&&(Oe=fp()):(Ca=ee,Mf="value"in Ca?Ca.value:Ca.textContent,ol=!0)),ke=Vs(P,Ae),0<ke.length&&(Ae=new mp(Ae,e,null,l,ee),le.push({event:Ae,listeners:ke}),Oe?Ae.data=Oe:(Oe=Sp(l),Oe!==null&&(Ae.data=Oe)))),(Oe=W2?eE(e,l):tE(e,l))&&(Ae=Vs(P,"onBeforeInput"),0<Ae.length&&(ke=new mp("onBeforeInput","beforeinput",null,l,ee),le.push({event:ke,listeners:Ae}),ke.data=Oe)),QE(le,e,P,l,ee)}Gy(le,n)})}function Xu(e,n,l){return{instance:e,listener:n,currentTarget:l}}function Vs(e,n){for(var l=n+"Capture",u=[];e!==null;){var c=e,m=c.stateNode;c=c.tag,c!==5&&c!==26&&c!==27||m===null||(c=hu(e,l),c!=null&&u.unshift(Xu(e,c,m)),c=hu(e,n),c!=null&&u.push(Xu(e,c,m))),e=e.return}return u}function jl(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Zy(e,n,l,u,c){for(var m=n._reactName,b=[];l!==null&&l!==u;){var C=l,_=C.alternate,P=C.stateNode;if(C=C.tag,_!==null&&_===u)break;C!==5&&C!==26&&C!==27||P===null||(_=P,c?(P=hu(l,m),P!=null&&b.unshift(Xu(l,P,_))):c||(P=hu(l,m),P!=null&&b.push(Xu(l,P,_)))),l=l.return}b.length!==0&&e.push({event:n,listeners:b})}var ZE=/\r\n?/g,IE=/\u0000|\uFFFD/g;function Iy(e){return(typeof e=="string"?e:""+e).replace(ZE,`
62
- `).replace(IE,"")}function Jy(e,n){return n=Iy(n),Iy(e)===n}function Ys(){}function it(e,n,l,u,c,m){switch(l){case"children":typeof u=="string"?n==="body"||n==="textarea"&&u===""||il(e,u):(typeof u=="number"||typeof u=="bigint")&&n!=="body"&&il(e,""+u);break;case"className":Wo(e,"class",u);break;case"tabIndex":Wo(e,"tabindex",u);break;case"dir":case"role":case"viewBox":case"width":case"height":Wo(e,l,u);break;case"style":op(e,u,m);break;case"data":if(n!=="object"){Wo(e,"data",u);break}case"src":case"href":if(u===""&&(n!=="a"||l!=="href")){e.removeAttribute(l);break}if(u==null||typeof u=="function"||typeof u=="symbol"||typeof u=="boolean"){e.removeAttribute(l);break}u=ns(""+u),e.setAttribute(l,u);break;case"action":case"formAction":if(typeof u=="function"){e.setAttribute(l,"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 m=="function"&&(l==="formAction"?(n!=="input"&&it(e,n,"name",c.name,c,null),it(e,n,"formEncType",c.formEncType,c,null),it(e,n,"formMethod",c.formMethod,c,null),it(e,n,"formTarget",c.formTarget,c,null)):(it(e,n,"encType",c.encType,c,null),it(e,n,"method",c.method,c,null),it(e,n,"target",c.target,c,null)));if(u==null||typeof u=="symbol"||typeof u=="boolean"){e.removeAttribute(l);break}u=ns(""+u),e.setAttribute(l,u);break;case"onClick":u!=null&&(e.onclick=Ys);break;case"onScroll":u!=null&&Qe("scroll",e);break;case"onScrollEnd":u!=null&&Qe("scrollend",e);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(i(61));if(l=u.__html,l!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=l}}break;case"multiple":e.multiple=u&&typeof u!="function"&&typeof u!="symbol";break;case"muted":e.muted=u&&typeof u!="function"&&typeof u!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(u==null||typeof u=="function"||typeof u=="boolean"||typeof u=="symbol"){e.removeAttribute("xlink:href");break}l=ns(""+u),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":u!=null&&typeof u!="function"&&typeof u!="symbol"?e.setAttribute(l,""+u):e.removeAttribute(l);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":u&&typeof u!="function"&&typeof u!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":u===!0?e.setAttribute(l,""):u!==!1&&u!=null&&typeof u!="function"&&typeof u!="symbol"?e.setAttribute(l,u):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":u!=null&&typeof u!="function"&&typeof u!="symbol"&&!isNaN(u)&&1<=u?e.setAttribute(l,u):e.removeAttribute(l);break;case"rowSpan":case"start":u==null||typeof u=="function"||typeof u=="symbol"||isNaN(u)?e.removeAttribute(l):e.setAttribute(l,u);break;case"popover":Qe("beforetoggle",e),Qe("toggle",e),Jo(e,"popover",u);break;case"xlinkActuate":Qr(e,"http://www.w3.org/1999/xlink","xlink:actuate",u);break;case"xlinkArcrole":Qr(e,"http://www.w3.org/1999/xlink","xlink:arcrole",u);break;case"xlinkRole":Qr(e,"http://www.w3.org/1999/xlink","xlink:role",u);break;case"xlinkShow":Qr(e,"http://www.w3.org/1999/xlink","xlink:show",u);break;case"xlinkTitle":Qr(e,"http://www.w3.org/1999/xlink","xlink:title",u);break;case"xlinkType":Qr(e,"http://www.w3.org/1999/xlink","xlink:type",u);break;case"xmlBase":Qr(e,"http://www.w3.org/XML/1998/namespace","xml:base",u);break;case"xmlLang":Qr(e,"http://www.w3.org/XML/1998/namespace","xml:lang",u);break;case"xmlSpace":Qr(e,"http://www.w3.org/XML/1998/namespace","xml:space",u);break;case"is":Jo(e,"is",u);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=T2.get(l)||l,Jo(e,l,u))}}function sh(e,n,l,u,c,m){switch(l){case"style":op(e,u,m);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(i(61));if(l=u.__html,l!=null){if(c.children!=null)throw Error(i(60));e.innerHTML=l}}break;case"children":typeof u=="string"?il(e,u):(typeof u=="number"||typeof u=="bigint")&&il(e,""+u);break;case"onScroll":u!=null&&Qe("scroll",e);break;case"onScrollEnd":u!=null&&Qe("scrollend",e);break;case"onClick":u!=null&&(e.onclick=Ys);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!rt.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(c=l.endsWith("Capture"),n=l.slice(2,c?l.length-7:void 0),m=e[Be]||null,m=m!=null?m[l]:null,typeof m=="function"&&e.removeEventListener(n,m,c),typeof u=="function")){typeof m!="function"&&m!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(n,u,c);break e}l in e?e[l]=u:u===!0?e.setAttribute(l,""):Jo(e,l,u)}}}function Gt(e,n,l){switch(n){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 u=!1,c=!1,m;for(m in l)if(l.hasOwnProperty(m)){var b=l[m];if(b!=null)switch(m){case"src":u=!0;break;case"srcSet":c=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(i(137,n));default:it(e,n,m,b,l,null)}}c&&it(e,n,"srcSet",l.srcSet,l,null),u&&it(e,n,"src",l.src,l,null);return;case"input":Qe("invalid",e);var C=m=b=c=null,_=null,P=null;for(u in l)if(l.hasOwnProperty(u)){var ee=l[u];if(ee!=null)switch(u){case"name":c=ee;break;case"type":b=ee;break;case"checked":_=ee;break;case"defaultChecked":P=ee;break;case"value":m=ee;break;case"defaultValue":C=ee;break;case"children":case"dangerouslySetInnerHTML":if(ee!=null)throw Error(i(137,n));break;default:it(e,n,u,ee,l,null)}}ap(e,m,C,_,P,b,c,!1),es(e);return;case"select":Qe("invalid",e),u=b=m=null;for(c in l)if(l.hasOwnProperty(c)&&(C=l[c],C!=null))switch(c){case"value":m=C;break;case"defaultValue":b=C;break;case"multiple":u=C;default:it(e,n,c,C,l,null)}n=m,l=b,e.multiple=!!u,n!=null?al(e,!!u,n,!1):l!=null&&al(e,!!u,l,!0);return;case"textarea":Qe("invalid",e),m=c=u=null;for(b in l)if(l.hasOwnProperty(b)&&(C=l[b],C!=null))switch(b){case"value":u=C;break;case"defaultValue":c=C;break;case"children":m=C;break;case"dangerouslySetInnerHTML":if(C!=null)throw Error(i(91));break;default:it(e,n,b,C,l,null)}lp(e,u,c,m),es(e);return;case"option":for(_ in l)if(l.hasOwnProperty(_)&&(u=l[_],u!=null))switch(_){case"selected":e.selected=u&&typeof u!="function"&&typeof u!="symbol";break;default:it(e,n,_,u,l,null)}return;case"dialog":Qe("cancel",e),Qe("close",e);break;case"iframe":case"object":Qe("load",e);break;case"video":case"audio":for(u=0;u<Gu.length;u++)Qe(Gu[u],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(P in l)if(l.hasOwnProperty(P)&&(u=l[P],u!=null))switch(P){case"children":case"dangerouslySetInnerHTML":throw Error(i(137,n));default:it(e,n,P,u,l,null)}return;default:if(Cf(n)){for(ee in l)l.hasOwnProperty(ee)&&(u=l[ee],u!==void 0&&sh(e,n,ee,u,l,void 0));return}}for(C in l)l.hasOwnProperty(C)&&(u=l[C],u!=null&&it(e,n,C,u,l,null))}function JE(e,n,l,u){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var c=null,m=null,b=null,C=null,_=null,P=null,ee=null;for(W in l){var le=l[W];if(l.hasOwnProperty(W)&&le!=null)switch(W){case"checked":break;case"value":break;case"defaultValue":_=le;default:u.hasOwnProperty(W)||it(e,n,W,null,u,le)}}for(var G in u){var W=u[G];if(le=l[G],u.hasOwnProperty(G)&&(W!=null||le!=null))switch(G){case"type":m=W;break;case"name":c=W;break;case"checked":P=W;break;case"defaultChecked":ee=W;break;case"value":b=W;break;case"defaultValue":C=W;break;case"children":case"dangerouslySetInnerHTML":if(W!=null)throw Error(i(137,n));break;default:W!==le&&it(e,n,G,W,u,le)}}wf(e,b,C,_,P,ee,m,c);return;case"select":W=b=C=G=null;for(m in l)if(_=l[m],l.hasOwnProperty(m)&&_!=null)switch(m){case"value":break;case"multiple":W=_;default:u.hasOwnProperty(m)||it(e,n,m,null,u,_)}for(c in u)if(m=u[c],_=l[c],u.hasOwnProperty(c)&&(m!=null||_!=null))switch(c){case"value":G=m;break;case"defaultValue":C=m;break;case"multiple":b=m;default:m!==_&&it(e,n,c,m,u,_)}n=C,l=b,u=W,G!=null?al(e,!!l,G,!1):!!u!=!!l&&(n!=null?al(e,!!l,n,!0):al(e,!!l,l?[]:"",!1));return;case"textarea":W=G=null;for(C in l)if(c=l[C],l.hasOwnProperty(C)&&c!=null&&!u.hasOwnProperty(C))switch(C){case"value":break;case"children":break;default:it(e,n,C,null,u,c)}for(b in u)if(c=u[b],m=l[b],u.hasOwnProperty(b)&&(c!=null||m!=null))switch(b){case"value":G=c;break;case"defaultValue":W=c;break;case"children":break;case"dangerouslySetInnerHTML":if(c!=null)throw Error(i(91));break;default:c!==m&&it(e,n,b,c,u,m)}ip(e,G,W);return;case"option":for(var xe in l)if(G=l[xe],l.hasOwnProperty(xe)&&G!=null&&!u.hasOwnProperty(xe))switch(xe){case"selected":e.selected=!1;break;default:it(e,n,xe,null,u,G)}for(_ in u)if(G=u[_],W=l[_],u.hasOwnProperty(_)&&G!==W&&(G!=null||W!=null))switch(_){case"selected":e.selected=G&&typeof G!="function"&&typeof G!="symbol";break;default:it(e,n,_,G,u,W)}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 ze in l)G=l[ze],l.hasOwnProperty(ze)&&G!=null&&!u.hasOwnProperty(ze)&&it(e,n,ze,null,u,G);for(P in u)if(G=u[P],W=l[P],u.hasOwnProperty(P)&&G!==W&&(G!=null||W!=null))switch(P){case"children":case"dangerouslySetInnerHTML":if(G!=null)throw Error(i(137,n));break;default:it(e,n,P,G,u,W)}return;default:if(Cf(n)){for(var Ct in l)G=l[Ct],l.hasOwnProperty(Ct)&&G!==void 0&&!u.hasOwnProperty(Ct)&&sh(e,n,Ct,void 0,u,G);for(ee in u)G=u[ee],W=l[ee],!u.hasOwnProperty(ee)||G===W||G===void 0&&W===void 0||sh(e,n,ee,G,u,W);return}}for(var k in l)G=l[k],l.hasOwnProperty(k)&&G!=null&&!u.hasOwnProperty(k)&&it(e,n,k,null,u,G);for(le in u)G=u[le],W=l[le],!u.hasOwnProperty(le)||G===W||G==null&&W==null||it(e,n,le,G,u,W)}var ch=null,fh=null;function Qs(e){return e.nodeType===9?e:e.ownerDocument}function Wy(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 eg(e,n){if(e===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&n==="foreignObject"?0:e}function dh(e,n){return e==="textarea"||e==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.children=="bigint"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var hh=null;function WE(){var e=window.event;return e&&e.type==="popstate"?e===hh?!1:(hh=e,!0):(hh=null,!1)}var tg=typeof setTimeout=="function"?setTimeout:void 0,ew=typeof clearTimeout=="function"?clearTimeout:void 0,ng=typeof Promise=="function"?Promise:void 0,tw=typeof queueMicrotask=="function"?queueMicrotask:typeof ng<"u"?function(e){return ng.resolve(null).then(e).catch(nw)}:tg;function nw(e){setTimeout(function(){throw e})}function mh(e,n){var l=n,u=0;do{var c=l.nextSibling;if(e.removeChild(l),c&&c.nodeType===8)if(l=c.data,l==="/$"){if(u===0){e.removeChild(c),ro(n);return}u--}else l!=="$"&&l!=="$?"&&l!=="$!"||u++;l=c}while(l);ro(n)}function vh(e){var n=e.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var l=n;switch(n=n.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":vh(l),Rn(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function rw(e,n,l,u){for(;e.nodeType===1;){var c=l;if(e.nodeName.toLowerCase()!==n.toLowerCase()){if(!u&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(u){if(!e[ar])switch(n){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(m=e.getAttribute("rel"),m==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(m!==c.rel||e.getAttribute("href")!==(c.href==null?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(m=e.getAttribute("src"),(m!==(c.src==null?null:c.src)||e.getAttribute("type")!==(c.type==null?null:c.type)||e.getAttribute("crossorigin")!==(c.crossOrigin==null?null:c.crossOrigin))&&m&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(n==="input"&&e.type==="hidden"){var m=c.name==null?null:""+c.name;if(c.type==="hidden"&&e.getAttribute("name")===m)return e}else return e;if(e=cr(e.nextSibling),e===null)break}return null}function aw(e,n,l){if(n==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=cr(e.nextSibling),e===null))return null;return e}function cr(e){for(;e!=null;e=e.nextSibling){var n=e.nodeType;if(n===1||n===3)break;if(n===8){if(n=e.data,n==="$"||n==="$!"||n==="$?"||n==="F!"||n==="F")break;if(n==="/$")return null}}return e}function rg(e){e=e.previousSibling;for(var n=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"){if(n===0)return e;n--}else l==="/$"&&n++}e=e.previousSibling}return null}function ag(e,n,l){switch(n=Qs(l),e){case"html":if(e=n.documentElement,!e)throw Error(i(452));return e;case"head":if(e=n.head,!e)throw Error(i(453));return e;case"body":if(e=n.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}var Wn=new Map,ig=new Set;function Ks(e){return typeof e.getRootNode=="function"?e.getRootNode():e.ownerDocument}var ua=ce.d;ce.d={f:iw,r:lw,D:uw,C:ow,L:sw,m:cw,X:dw,S:fw,M:hw};function iw(){var e=ua.f(),n=Bs();return e||n}function lw(e){var n=Er(e);n!==null&&n.tag===5&&n.type==="form"?_0(n):ua.r(e)}var _l=typeof document>"u"?null:document;function lg(e,n,l){var u=_l;if(u&&typeof n=="string"&&n){var c=Fn(n);c='link[rel="'+e+'"][href="'+c+'"]',typeof l=="string"&&(c+='[crossorigin="'+l+'"]'),ig.has(c)||(ig.add(c),e={rel:e,crossOrigin:l,href:n},u.querySelector(c)===null&&(n=u.createElement("link"),Gt(n,"link",e),gt(n),u.head.appendChild(n)))}}function uw(e){ua.D(e),lg("dns-prefetch",e,null)}function ow(e,n){ua.C(e,n),lg("preconnect",e,n)}function sw(e,n,l){ua.L(e,n,l);var u=_l;if(u&&e&&n){var c='link[rel="preload"][as="'+Fn(n)+'"]';n==="image"&&l&&l.imageSrcSet?(c+='[imagesrcset="'+Fn(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(c+='[imagesizes="'+Fn(l.imageSizes)+'"]')):c+='[href="'+Fn(e)+'"]';var m=c;switch(n){case"style":m=Nl(e);break;case"script":m=zl(e)}Wn.has(m)||(e=X({rel:"preload",href:n==="image"&&l&&l.imageSrcSet?void 0:e,as:n},l),Wn.set(m,e),u.querySelector(c)!==null||n==="style"&&u.querySelector(Zu(m))||n==="script"&&u.querySelector(Iu(m))||(n=u.createElement("link"),Gt(n,"link",e),gt(n),u.head.appendChild(n)))}}function cw(e,n){ua.m(e,n);var l=_l;if(l&&e){var u=n&&typeof n.as=="string"?n.as:"script",c='link[rel="modulepreload"][as="'+Fn(u)+'"][href="'+Fn(e)+'"]',m=c;switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":m=zl(e)}if(!Wn.has(m)&&(e=X({rel:"modulepreload",href:e},n),Wn.set(m,e),l.querySelector(c)===null)){switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Iu(m)))return}u=l.createElement("link"),Gt(u,"link",e),gt(u),l.head.appendChild(u)}}}function fw(e,n,l){ua.S(e,n,l);var u=_l;if(u&&e){var c=Sn(u).hoistableStyles,m=Nl(e);n=n||"default";var b=c.get(m);if(!b){var C={loading:0,preload:null};if(b=u.querySelector(Zu(m)))C.loading=5;else{e=X({rel:"stylesheet",href:e,"data-precedence":n},l),(l=Wn.get(m))&&ph(e,l);var _=b=u.createElement("link");gt(_),Gt(_,"link",e),_._p=new Promise(function(P,ee){_.onload=P,_.onerror=ee}),_.addEventListener("load",function(){C.loading|=1}),_.addEventListener("error",function(){C.loading|=2}),C.loading|=4,Gs(b,n,u)}b={type:"stylesheet",instance:b,count:1,state:C},c.set(m,b)}}}function dw(e,n){ua.X(e,n);var l=_l;if(l&&e){var u=Sn(l).hoistableScripts,c=zl(e),m=u.get(c);m||(m=l.querySelector(Iu(c)),m||(e=X({src:e,async:!0},n),(n=Wn.get(c))&&yh(e,n),m=l.createElement("script"),gt(m),Gt(m,"link",e),l.head.appendChild(m)),m={type:"script",instance:m,count:1,state:null},u.set(c,m))}}function hw(e,n){ua.M(e,n);var l=_l;if(l&&e){var u=Sn(l).hoistableScripts,c=zl(e),m=u.get(c);m||(m=l.querySelector(Iu(c)),m||(e=X({src:e,async:!0,type:"module"},n),(n=Wn.get(c))&&yh(e,n),m=l.createElement("script"),gt(m),Gt(m,"link",e),l.head.appendChild(m)),m={type:"script",instance:m,count:1,state:null},u.set(c,m))}}function ug(e,n,l,u){var c=(c=ft.current)?Ks(c):null;if(!c)throw Error(i(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(n=Nl(l.href),l=Sn(c).hoistableStyles,u=l.get(n),u||(u={type:"style",instance:null,count:0,state:null},l.set(n,u)),u):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=Nl(l.href);var m=Sn(c).hoistableStyles,b=m.get(e);if(b||(c=c.ownerDocument||c,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},m.set(e,b),(m=c.querySelector(Zu(e)))&&!m._p&&(b.instance=m,b.state.loading=5),Wn.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Wn.set(e,l),m||mw(c,e,l,b.state))),n&&u===null)throw Error(i(528,""));return b}if(n&&u!==null)throw Error(i(529,""));return null;case"script":return n=l.async,l=l.src,typeof l=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=zl(l),l=Sn(c).hoistableScripts,u=l.get(n),u||(u={type:"script",instance:null,count:0,state:null},l.set(n,u)),u):{type:"void",instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Nl(e){return'href="'+Fn(e)+'"'}function Zu(e){return'link[rel="stylesheet"]['+e+"]"}function og(e){return X({},e,{"data-precedence":e.precedence,precedence:null})}function mw(e,n,l,u){e.querySelector('link[rel="preload"][as="style"]['+n+"]")?u.loading=1:(n=e.createElement("link"),u.preload=n,n.addEventListener("load",function(){return u.loading|=1}),n.addEventListener("error",function(){return u.loading|=2}),Gt(n,"link",l),gt(n),e.head.appendChild(n))}function zl(e){return'[src="'+Fn(e)+'"]'}function Iu(e){return"script[async]"+e}function sg(e,n,l){if(n.count++,n.instance===null)switch(n.type){case"style":var u=e.querySelector('style[data-href~="'+Fn(l.href)+'"]');if(u)return n.instance=u,gt(u),u;var c=X({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return u=(e.ownerDocument||e).createElement("style"),gt(u),Gt(u,"style",c),Gs(u,l.precedence,e),n.instance=u;case"stylesheet":c=Nl(l.href);var m=e.querySelector(Zu(c));if(m)return n.state.loading|=4,n.instance=m,gt(m),m;u=og(l),(c=Wn.get(c))&&ph(u,c),m=(e.ownerDocument||e).createElement("link"),gt(m);var b=m;return b._p=new Promise(function(C,_){b.onload=C,b.onerror=_}),Gt(m,"link",u),n.state.loading|=4,Gs(m,l.precedence,e),n.instance=m;case"script":return m=zl(l.src),(c=e.querySelector(Iu(m)))?(n.instance=c,gt(c),c):(u=l,(c=Wn.get(m))&&(u=X({},l),yh(u,c)),e=e.ownerDocument||e,c=e.createElement("script"),gt(c),Gt(c,"link",u),e.head.appendChild(c),n.instance=c);case"void":return null;default:throw Error(i(443,n.type))}else n.type==="stylesheet"&&!(n.state.loading&4)&&(u=n.instance,n.state.loading|=4,Gs(u,l.precedence,e));return n.instance}function Gs(e,n,l){for(var u=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),c=u.length?u[u.length-1]:null,m=c,b=0;b<u.length;b++){var C=u[b];if(C.dataset.precedence===n)m=C;else if(m!==c)break}m?m.parentNode.insertBefore(e,m.nextSibling):(n=l.nodeType===9?l.head:l,n.insertBefore(e,n.firstChild))}function ph(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.title==null&&(e.title=n.title)}function yh(e,n){e.crossOrigin==null&&(e.crossOrigin=n.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=n.referrerPolicy),e.integrity==null&&(e.integrity=n.integrity)}var Xs=null;function cg(e,n,l){if(Xs===null){var u=new Map,c=Xs=new Map;c.set(l,u)}else c=Xs,u=c.get(l),u||(u=new Map,c.set(l,u));if(u.has(e))return u;for(u.set(e,null),l=l.getElementsByTagName(e),c=0;c<l.length;c++){var m=l[c];if(!(m[ar]||m[Ce]||e==="link"&&m.getAttribute("rel")==="stylesheet")&&m.namespaceURI!=="http://www.w3.org/2000/svg"){var b=m.getAttribute(n)||"";b=e+b;var C=u.get(b);C?C.push(m):u.set(b,[m])}}return u}function fg(e,n,l){e=e.ownerDocument||e,e.head.insertBefore(l,n==="title"?e.querySelector("head > title"):null)}function vw(e,n,l){if(l===1||n.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof n.precedence!="string"||typeof n.href!="string"||n.href==="")break;return!0;case"link":if(typeof n.rel!="string"||typeof n.href!="string"||n.href===""||n.onLoad||n.onError)break;switch(n.rel){case"stylesheet":return e=n.disabled,typeof n.precedence=="string"&&e==null;default:return!0}case"script":if(n.async&&typeof n.async!="function"&&typeof n.async!="symbol"&&!n.onLoad&&!n.onError&&n.src&&typeof n.src=="string")return!0}return!1}function dg(e){return!(e.type==="stylesheet"&&!(e.state.loading&3))}var Ju=null;function pw(){}function yw(e,n,l){if(Ju===null)throw Error(i(475));var u=Ju;if(n.type==="stylesheet"&&(typeof l.media!="string"||matchMedia(l.media).matches!==!1)&&!(n.state.loading&4)){if(n.instance===null){var c=Nl(l.href),m=e.querySelector(Zu(c));if(m){e=m._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(u.count++,u=Zs.bind(u),e.then(u,u)),n.state.loading|=4,n.instance=m,gt(m);return}m=e.ownerDocument||e,l=og(l),(c=Wn.get(c))&&ph(l,c),m=m.createElement("link"),gt(m);var b=m;b._p=new Promise(function(C,_){b.onload=C,b.onerror=_}),Gt(m,"link",l),n.instance=m}u.stylesheets===null&&(u.stylesheets=new Map),u.stylesheets.set(n,e),(e=n.state.preload)&&!(n.state.loading&3)&&(u.count++,n=Zs.bind(u),e.addEventListener("load",n),e.addEventListener("error",n))}}function gw(){if(Ju===null)throw Error(i(475));var e=Ju;return e.stylesheets&&e.count===0&&gh(e,e.stylesheets),0<e.count?function(n){var l=setTimeout(function(){if(e.stylesheets&&gh(e,e.stylesheets),e.unsuspend){var u=e.unsuspend;e.unsuspend=null,u()}},6e4);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(l)}}:null}function Zs(){if(this.count--,this.count===0){if(this.stylesheets)gh(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Is=null;function gh(e,n){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Is=new Map,n.forEach(bw,e),Is=null,Zs.call(e))}function bw(e,n){if(!(n.state.loading&4)){var l=Is.get(e);if(l)var u=l.get(null);else{l=new Map,Is.set(e,l);for(var c=e.querySelectorAll("link[data-precedence],style[data-precedence]"),m=0;m<c.length;m++){var b=c[m];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(l.set(b.dataset.precedence,b),u=b)}u&&l.set(null,u)}c=n.instance,b=c.getAttribute("data-precedence"),m=l.get(b)||u,m===u&&l.set(null,c),l.set(b,c),this.count++,u=Zs.bind(this),c.addEventListener("load",u),c.addEventListener("error",u),m?m.parentNode.insertBefore(c,m.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(c,e.firstChild)),n.state.loading|=4}}var Wu={$$typeof:g,Provider:null,Consumer:null,_currentValue:ge,_currentValue2:ge,_threadCount:0};function Sw(e,n,l,u,c,m,b,C){this.tag=1,this.containerInfo=e,this.finishedWork=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=J(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.finishedLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=J(0),this.hiddenUpdates=J(null),this.identifierPrefix=u,this.onUncaughtError=c,this.onCaughtError=m,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=C,this.incompleteTransitions=new Map}function hg(e,n,l,u,c,m,b,C,_,P,ee,le){return e=new Sw(e,n,l,b,C,_,P,le),n=1,m===!0&&(n|=24),m=In(3,null,null,n),e.current=m,m.stateNode=e,n=Zf(),n.refCount++,e.pooledCache=n,n.refCount++,m.memoizedState={element:u,isDehydrated:l,cache:n},Md(m),e}function mg(e){return e?(e=dl,e):dl}function vg(e,n,l,u,c,m){c=mg(c),u.context===null?u.context=c:u.pendingContext=c,u=Na(n),u.payload={element:l},m=m===void 0?null:m,m!==null&&(u.callback=m),l=za(e,u,n),l!==null&&(hn(l,e,n),Hu(l,e,n))}function pg(e,n){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<n?l:n}}function bh(e,n){pg(e,n),(e=e.alternate)&&pg(e,n)}function yg(e){if(e.tag===13){var n=Ta(e,67108864);n!==null&&hn(n,e,67108864),bh(e,67108864)}}var Js=!0;function xw(e,n,l,u){var c=z.T;z.T=null;var m=ce.p;try{ce.p=2,Sh(e,n,l,u)}finally{ce.p=m,z.T=c}}function Ew(e,n,l,u){var c=z.T;z.T=null;var m=ce.p;try{ce.p=8,Sh(e,n,l,u)}finally{ce.p=m,z.T=c}}function Sh(e,n,l,u){if(Js){var c=xh(u);if(c===null)oh(e,n,u,Ws,l),bg(e,u);else if(Ow(c,e,n,l,u))u.stopPropagation();else if(bg(e,u),n&4&&-1<ww.indexOf(e)){for(;c!==null;){var m=Er(c);if(m!==null)switch(m.tag){case 3:if(m=m.stateNode,m.current.memoizedState.isDehydrated){var b=qn(m.pendingLanes);if(b!==0){var C=m;for(C.pendingLanes|=2,C.entangledLanes|=2;b;){var _=1<<31-tn(b);C.entanglements[1]|=_,b&=~_}Rr(m),!(St&6)&&(Hs=jt()+500,Ku(0))}}break;case 13:C=Ta(m,2),C!==null&&hn(C,m,2),Bs(),bh(m,2)}if(m=xh(u),m===null&&oh(e,n,u,Ws,l),m===c)break;c=m}c!==null&&u.stopPropagation()}else oh(e,n,u,null,l)}}function xh(e){return e=Rf(e),Eh(e)}var Ws=null;function Eh(e){if(Ws=null,e=qt(e),e!==null){var n=ne(e);if(n===null)e=null;else{var l=n.tag;if(l===13){if(e=K(n),e!==null)return e;e=null}else if(l===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;e=null}else n!==e&&(e=null)}}return Ws=e,null}function gg(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(on()){case sn:return 2;case cu:return 8;case wa:case bf:return 32;case rr:return 268435456;default:return 32}default:return 32}}var wh=!1,qa=null,ka=null,Fa=null,eo=new Map,to=new Map,Va=[],ww="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 bg(e,n){switch(e){case"focusin":case"focusout":qa=null;break;case"dragenter":case"dragleave":ka=null;break;case"mouseover":case"mouseout":Fa=null;break;case"pointerover":case"pointerout":eo.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":to.delete(n.pointerId)}}function no(e,n,l,u,c,m){return e===null||e.nativeEvent!==m?(e={blockedOn:n,domEventName:l,eventSystemFlags:u,nativeEvent:m,targetContainers:[c]},n!==null&&(n=Er(n),n!==null&&yg(n)),e):(e.eventSystemFlags|=u,n=e.targetContainers,c!==null&&n.indexOf(c)===-1&&n.push(c),e)}function Ow(e,n,l,u,c){switch(n){case"focusin":return qa=no(qa,e,n,l,u,c),!0;case"dragenter":return ka=no(ka,e,n,l,u,c),!0;case"mouseover":return Fa=no(Fa,e,n,l,u,c),!0;case"pointerover":var m=c.pointerId;return eo.set(m,no(eo.get(m)||null,e,n,l,u,c)),!0;case"gotpointercapture":return m=c.pointerId,to.set(m,no(to.get(m)||null,e,n,l,u,c)),!0}return!1}function Sg(e){var n=qt(e.target);if(n!==null){var l=ne(n);if(l!==null){if(n=l.tag,n===13){if(n=K(l),n!==null){e.blockedOn=n,he(e.priority,function(){if(l.tag===13){var u=_n(),c=Ta(l,u);c!==null&&hn(c,l,u),bh(l,u)}});return}}else if(n===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ec(e){if(e.blockedOn!==null)return!1;for(var n=e.targetContainers;0<n.length;){var l=xh(e.nativeEvent);if(l===null){l=e.nativeEvent;var u=new l.constructor(l.type,l);Tf=u,l.target.dispatchEvent(u),Tf=null}else return n=Er(l),n!==null&&yg(n),e.blockedOn=l,!1;n.shift()}return!0}function xg(e,n,l){ec(e)&&l.delete(n)}function Cw(){wh=!1,qa!==null&&ec(qa)&&(qa=null),ka!==null&&ec(ka)&&(ka=null),Fa!==null&&ec(Fa)&&(Fa=null),eo.forEach(xg),to.forEach(xg)}function tc(e,n){e.blockedOn===n&&(e.blockedOn=null,wh||(wh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Cw)))}var nc=null;function Eg(e){nc!==e&&(nc=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){nc===e&&(nc=null);for(var n=0;n<e.length;n+=3){var l=e[n],u=e[n+1],c=e[n+2];if(typeof u!="function"){if(Eh(u||l)===null)continue;break}var m=Er(l);m!==null&&(e.splice(n,3),n-=3,dd(m,{pending:!0,data:c,method:l.method,action:u},u,c))}}))}function ro(e){function n(_){return tc(_,e)}qa!==null&&tc(qa,e),ka!==null&&tc(ka,e),Fa!==null&&tc(Fa,e),eo.forEach(n),to.forEach(n);for(var l=0;l<Va.length;l++){var u=Va[l];u.blockedOn===e&&(u.blockedOn=null)}for(;0<Va.length&&(l=Va[0],l.blockedOn===null);)Sg(l),l.blockedOn===null&&Va.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(u=0;u<l.length;u+=3){var c=l[u],m=l[u+1],b=c[Be]||null;if(typeof m=="function")b||Eg(l);else if(b){var C=null;if(m&&m.hasAttribute("formAction")){if(c=m,b=m[Be]||null)C=b.formAction;else if(Eh(c)!==null)continue}else C=b.action;typeof C=="function"?l[u+1]=C:(l.splice(u,3),u-=3),Eg(l)}}}function Oh(e){this._internalRoot=e}rc.prototype.render=Oh.prototype.render=function(e){var n=this._internalRoot;if(n===null)throw Error(i(409));var l=n.current,u=_n();vg(l,u,e,n,null,null)},rc.prototype.unmount=Oh.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var n=e.containerInfo;e.tag===0&&Al(),vg(e.current,2,null,e,null,null),Bs(),n[vt]=null}};function rc(e){this._internalRoot=e}rc.prototype.unstable_scheduleHydration=function(e){if(e){var n=Se();e={blockedOn:null,target:e,priority:n};for(var l=0;l<Va.length&&n!==0&&n<Va[l].priority;l++);Va.splice(l,0,e),l===0&&Sg(e)}};var wg=r.version;if(wg!=="19.0.0")throw Error(i(527,wg,"19.0.0"));ce.findDOMNode=function(e){var n=e._reactInternals;if(n===void 0)throw typeof e.render=="function"?Error(i(188)):(e=Object.keys(e).join(","),Error(i(268,e)));return e=F(n),e=e!==null?se(e):null,e=e===null?null:e.stateNode,e};var Tw={bundleType:0,version:"19.0.0",rendererPackageName:"react-dom",currentDispatcherRef:z,findFiberByHostInstance:qt,reconcilerVersion:"19.0.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ac=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ac.isDisabled&&ac.supportsFiber)try{Oa=ac.inject(Tw),cn=ac}catch{}}return fo.createRoot=function(e,n){if(!o(e))throw Error(i(299));var l=!1,u="",c=P0,m=q0,b=k0,C=null;return n!=null&&(n.unstable_strictMode===!0&&(l=!0),n.identifierPrefix!==void 0&&(u=n.identifierPrefix),n.onUncaughtError!==void 0&&(c=n.onUncaughtError),n.onCaughtError!==void 0&&(m=n.onCaughtError),n.onRecoverableError!==void 0&&(b=n.onRecoverableError),n.unstable_transitionCallbacks!==void 0&&(C=n.unstable_transitionCallbacks)),n=hg(e,1,!1,null,null,l,u,c,m,b,C,null),e[vt]=n.current,uh(e.nodeType===8?e.parentNode:e),new Oh(n)},fo.hydrateRoot=function(e,n,l){if(!o(e))throw Error(i(299));var u=!1,c="",m=P0,b=q0,C=k0,_=null,P=null;return l!=null&&(l.unstable_strictMode===!0&&(u=!0),l.identifierPrefix!==void 0&&(c=l.identifierPrefix),l.onUncaughtError!==void 0&&(m=l.onUncaughtError),l.onCaughtError!==void 0&&(b=l.onCaughtError),l.onRecoverableError!==void 0&&(C=l.onRecoverableError),l.unstable_transitionCallbacks!==void 0&&(_=l.unstable_transitionCallbacks),l.formState!==void 0&&(P=l.formState)),n=hg(e,1,!0,n,l??null,u,c,m,b,C,_,P),n.context=mg(null),l=n.current,u=_n(),c=Na(u),c.callback=null,za(l,c,u),n.current.lanes=u,ue(n,u),Rr(n),e[vt]=n.current,uh(e),new rc(n)},fo.version="19.0.0",fo}var qb;function U4(){if(qb)return Ih.exports;qb=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(r){console.error(r)}}return t(),Ih.exports=H4(),Ih.exports}var $4=U4(),ho={},kb;function B4(){if(kb)return ho;kb=1,Object.defineProperty(ho,"__esModule",{value:!0}),ho.parse=f,ho.serialize=v;const t=/^[\u0021-\u003A\u003C\u003E-\u007E]+$/,r=/^[\u0021-\u003A\u003C-\u007E]*$/,a=/^([.]?[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)([.][a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/i,i=/^[\u0020-\u003A\u003D-\u007E]*$/,o=Object.prototype.toString,s=(()=>{const p=function(){};return p.prototype=Object.create(null),p})();function f(p,g){const w=new s,x=p.length;if(x<2)return w;const R=(g==null?void 0:g.decode)||y;let T=0;do{const A=p.indexOf("=",T);if(A===-1)break;const N=p.indexOf(";",T),j=N===-1?x:N;if(A>j){T=p.lastIndexOf(";",A-1)+1;continue}const O=d(p,T,A),q=h(p,A,O),B=p.slice(O,q);if(w[B]===void 0){let V=d(p,A+1,j),z=h(p,j,V);const X=R(p.slice(V,z));w[B]=X}T=j+1}while(T<x);return w}function d(p,g,w){do{const x=p.charCodeAt(g);if(x!==32&&x!==9)return g}while(++g<w);return w}function h(p,g,w){for(;g>w;){const x=p.charCodeAt(--g);if(x!==32&&x!==9)return g+1}return w}function v(p,g,w){const x=(w==null?void 0:w.encode)||encodeURIComponent;if(!t.test(p))throw new TypeError(`argument name is invalid: ${p}`);const R=x(g);if(!r.test(R))throw new TypeError(`argument val is invalid: ${g}`);let T=p+"="+R;if(!w)return T;if(w.maxAge!==void 0){if(!Number.isInteger(w.maxAge))throw new TypeError(`option maxAge is invalid: ${w.maxAge}`);T+="; Max-Age="+w.maxAge}if(w.domain){if(!a.test(w.domain))throw new TypeError(`option domain is invalid: ${w.domain}`);T+="; Domain="+w.domain}if(w.path){if(!i.test(w.path))throw new TypeError(`option path is invalid: ${w.path}`);T+="; Path="+w.path}if(w.expires){if(!S(w.expires)||!Number.isFinite(w.expires.valueOf()))throw new TypeError(`option expires is invalid: ${w.expires}`);T+="; Expires="+w.expires.toUTCString()}if(w.httpOnly&&(T+="; HttpOnly"),w.secure&&(T+="; Secure"),w.partitioned&&(T+="; Partitioned"),w.priority)switch(typeof w.priority=="string"?w.priority.toLowerCase():void 0){case"low":T+="; Priority=Low";break;case"medium":T+="; Priority=Medium";break;case"high":T+="; Priority=High";break;default:throw new TypeError(`option priority is invalid: ${w.priority}`)}if(w.sameSite)switch(typeof w.sameSite=="string"?w.sameSite.toLowerCase():w.sameSite){case!0:case"strict":T+="; SameSite=Strict";break;case"lax":T+="; SameSite=Lax";break;case"none":T+="; SameSite=None";break;default:throw new TypeError(`option sameSite is invalid: ${w.sameSite}`)}return T}function y(p){if(p.indexOf("%")===-1)return p;try{return decodeURIComponent(p)}catch{return p}}function S(p){return o.call(p)==="[object Date]"}return ho}B4();/**
63
- * react-router v7.0.2
64
- *
65
- * Copyright (c) Remix Software Inc.
66
- *
67
- * This source code is licensed under the MIT license found in the
68
- * LICENSE.md file in the root directory of this source tree.
69
- *
70
- * @license MIT
71
- */var Fb="popstate";function P4(t={}){function r(i,o){let{pathname:s,search:f,hash:d}=i.location;return To("",{pathname:s,search:f,hash:d},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function a(i,o){return typeof o=="string"?o:pi(o)}return k4(r,a,null,t)}function qe(t,r){if(t===!1||t===null||typeof t>"u")throw new Error(r)}function It(t,r){if(!t){typeof console<"u"&&console.warn(r);try{throw new Error(r)}catch{}}}function q4(){return Math.random().toString(36).substring(2,10)}function Vb(t,r){return{usr:t.state,key:t.key,idx:r}}function To(t,r,a=null,i){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof r=="string"?Ea(r):r,state:a,key:r&&r.key||i||q4()}}function pi({pathname:t="/",search:r="",hash:a=""}){return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),a&&a!=="#"&&(t+=a.charAt(0)==="#"?a:"#"+a),t}function Ea(t){let r={};if(t){let a=t.indexOf("#");a>=0&&(r.hash=t.substring(a),t=t.substring(0,a));let i=t.indexOf("?");i>=0&&(r.search=t.substring(i),t=t.substring(0,i)),t&&(r.pathname=t)}return r}function k4(t,r,a,i={}){let{window:o=document.defaultView,v5Compat:s=!1}=i,f=o.history,d="POP",h=null,v=y();v==null&&(v=0,f.replaceState({...f.state,idx:v},""));function y(){return(f.state||{idx:null}).idx}function S(){d="POP";let R=y(),T=R==null?null:R-v;v=R,h&&h({action:d,location:x.location,delta:T})}function p(R,T){d="PUSH";let A=To(x.location,R,T);v=y()+1;let N=Vb(A,v),j=x.createHref(A);try{f.pushState(N,"",j)}catch(O){if(O instanceof DOMException&&O.name==="DataCloneError")throw O;o.location.assign(j)}s&&h&&h({action:d,location:x.location,delta:1})}function g(R,T){d="REPLACE";let A=To(x.location,R,T);v=y();let N=Vb(A,v),j=x.createHref(A);f.replaceState(N,"",j),s&&h&&h({action:d,location:x.location,delta:0})}function w(R){let T=o.location.origin!=="null"?o.location.origin:o.location.href,A=typeof R=="string"?R:pi(R);return A=A.replace(/ $/,"%20"),qe(T,`No window.location.(origin|href) available to create URL for href: ${A}`),new URL(A,T)}let x={get action(){return d},get location(){return t(o,f)},listen(R){if(h)throw new Error("A history only accepts one active listener");return o.addEventListener(Fb,S),h=R,()=>{o.removeEventListener(Fb,S),h=null}},createHref(R){return r(o,R)},createURL:w,encodeLocation(R){let T=w(R);return{pathname:T.pathname,search:T.search,hash:T.hash}},push:p,replace:g,go(R){return f.go(R)}};return x}var F4=new Set(["lazy","caseSensitive","path","id","index","children"]);function V4(t){return t.index===!0}function Vc(t,r,a=[],i={}){return t.map((o,s)=>{let f=[...a,String(s)],d=typeof o.id=="string"?o.id:f.join("-");if(qe(o.index!==!0||!o.children,"Cannot specify children on an index route"),qe(!i[d],`Found a route id collision on id "${d}". Route id's must be globally unique within Data Router usages`),V4(o)){let h={...o,...r(o),id:d};return i[d]=h,h}else{let h={...o,...r(o),id:d,children:void 0};return i[d]=h,o.children&&(h.children=Vc(o.children,r,f,i)),h}})}function Ja(t,r,a="/"){return Oc(t,r,a,!1)}function Oc(t,r,a,i){let o=typeof r=="string"?Ea(r):r,s=Sr(o.pathname||"/",a);if(s==null)return null;let f=Ix(t);Q4(f);let d=null;for(let h=0;d==null&&h<f.length;++h){let v=r5(s);d=t5(f[h],v,i)}return d}function Y4(t,r){let{route:a,pathname:i,params:o}=t;return{id:a.id,pathname:i,params:o,data:r[a.id],handle:a.handle}}function Ix(t,r=[],a=[],i=""){let o=(s,f,d)=>{let h={relativePath:d===void 0?s.path||"":d,caseSensitive:s.caseSensitive===!0,childrenIndex:f,route:s};h.relativePath.startsWith("/")&&(qe(h.relativePath.startsWith(i),`Absolute route path "${h.relativePath}" nested under path "${i}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),h.relativePath=h.relativePath.slice(i.length));let v=Hr([i,h.relativePath]),y=a.concat(h);s.children&&s.children.length>0&&(qe(s.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${v}".`),Ix(s.children,r,y,v)),!(s.path==null&&!s.index)&&r.push({path:v,score:W4(v,s.index),routesMeta:y})};return t.forEach((s,f)=>{var d;if(s.path===""||!((d=s.path)!=null&&d.includes("?")))o(s,f);else for(let h of Jx(s.path))o(s,f,h)}),r}function Jx(t){let r=t.split("/");if(r.length===0)return[];let[a,...i]=r,o=a.endsWith("?"),s=a.replace(/\?$/,"");if(i.length===0)return o?[s,""]:[s];let f=Jx(i.join("/")),d=[];return d.push(...f.map(h=>h===""?s:[s,h].join("/"))),o&&d.push(...f),d.map(h=>t.startsWith("/")&&h===""?"/":h)}function Q4(t){t.sort((r,a)=>r.score!==a.score?a.score-r.score:e5(r.routesMeta.map(i=>i.childrenIndex),a.routesMeta.map(i=>i.childrenIndex)))}var K4=/^:[\w-]+$/,G4=3,X4=2,Z4=1,I4=10,J4=-2,Yb=t=>t==="*";function W4(t,r){let a=t.split("/"),i=a.length;return a.some(Yb)&&(i+=J4),r&&(i+=X4),a.filter(o=>!Yb(o)).reduce((o,s)=>o+(K4.test(s)?G4:s===""?Z4:I4),i)}function e5(t,r){return t.length===r.length&&t.slice(0,-1).every((i,o)=>i===r[o])?t[t.length-1]-r[r.length-1]:0}function t5(t,r,a=!1){let{routesMeta:i}=t,o={},s="/",f=[];for(let d=0;d<i.length;++d){let h=i[d],v=d===i.length-1,y=s==="/"?r:r.slice(s.length)||"/",S=Yc({path:h.relativePath,caseSensitive:h.caseSensitive,end:v},y),p=h.route;if(!S&&v&&a&&!i[i.length-1].route.index&&(S=Yc({path:h.relativePath,caseSensitive:h.caseSensitive,end:!1},y)),!S)return null;Object.assign(o,S.params),f.push({params:o,pathname:Hr([s,S.pathname]),pathnameBase:l5(Hr([s,S.pathnameBase])),route:p}),S.pathnameBase!=="/"&&(s=Hr([s,S.pathnameBase]))}return f}function Yc(t,r){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[a,i]=n5(t.path,t.caseSensitive,t.end),o=r.match(a);if(!o)return null;let s=o[0],f=s.replace(/(.)\/+$/,"$1"),d=o.slice(1);return{params:i.reduce((v,{paramName:y,isOptional:S},p)=>{if(y==="*"){let w=d[p]||"";f=s.slice(0,s.length-w.length).replace(/(.)\/+$/,"$1")}const g=d[p];return S&&!g?v[y]=void 0:v[y]=(g||"").replace(/%2F/g,"/"),v},{}),pathname:s,pathnameBase:f,pattern:t}}function n5(t,r=!1,a=!0){It(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let i=[],o="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(f,d,h)=>(i.push({paramName:d,isOptional:h!=null}),h?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(i.push({paramName:"*"}),o+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):a?o+="\\/*$":t!==""&&t!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,r?void 0:"i"),i]}function r5(t){try{return t.split("/").map(r=>decodeURIComponent(r).replace(/\//g,"%2F")).join("/")}catch(r){return It(!1,`The URL path "${t}" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding (${r}).`),t}}function Sr(t,r){if(r==="/")return t;if(!t.toLowerCase().startsWith(r.toLowerCase()))return null;let a=r.endsWith("/")?r.length-1:r.length,i=t.charAt(a);return i&&i!=="/"?null:t.slice(a)||"/"}function a5(t,r="/"){let{pathname:a,search:i="",hash:o=""}=typeof t=="string"?Ea(t):t;return{pathname:a?a.startsWith("/")?a:i5(a,r):r,search:u5(i),hash:o5(o)}}function i5(t,r){let a=r.replace(/\/+$/,"").split("/");return t.split("/").forEach(o=>{o===".."?a.length>1&&a.pop():o!=="."&&a.push(o)}),a.length>1?a.join("/"):"/"}function em(t,r,a,i){return`Cannot include a '${t}' character in a manually specified \`to.${r}\` field [${JSON.stringify(i)}]. Please separate it out to the \`to.${a}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Wx(t){return t.filter((r,a)=>a===0||r.route.path&&r.route.path.length>0)}function Fv(t){let r=Wx(t);return r.map((a,i)=>i===r.length-1?a.pathname:a.pathnameBase)}function Vv(t,r,a,i=!1){let o;typeof t=="string"?o=Ea(t):(o={...t},qe(!o.pathname||!o.pathname.includes("?"),em("?","pathname","search",o)),qe(!o.pathname||!o.pathname.includes("#"),em("#","pathname","hash",o)),qe(!o.search||!o.search.includes("#"),em("#","search","hash",o)));let s=t===""||o.pathname==="",f=s?"/":o.pathname,d;if(f==null)d=a;else{let S=r.length-1;if(!i&&f.startsWith("..")){let p=f.split("/");for(;p[0]==="..";)p.shift(),S-=1;o.pathname=p.join("/")}d=S>=0?r[S]:"/"}let h=a5(o,d),v=f&&f!=="/"&&f.endsWith("/"),y=(s||f===".")&&a.endsWith("/");return!h.pathname.endsWith("/")&&(v||y)&&(h.pathname+="/"),h}var Hr=t=>t.join("/").replace(/\/\/+/g,"/"),l5=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),u5=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,o5=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,Qc=class{constructor(t,r,a,i=!1){this.status=t,this.statusText=r||"",this.internal=i,a instanceof Error?(this.data=a.toString(),this.error=a):this.data=a}};function yf(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}var e2=["POST","PUT","PATCH","DELETE"],s5=new Set(e2),c5=["GET",...e2],f5=new Set(c5),d5=new Set([301,302,303,307,308]),h5=new Set([307,308]),tm={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},m5={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},mo={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},Yv=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,v5=t=>({hasErrorBoundary:!!t.hasErrorBoundary}),t2="remix-router-transitions",n2=Symbol("ResetLoaderData");function p5(t){const r=t.window?t.window:typeof window<"u"?window:void 0,a=typeof r<"u"&&typeof r.document<"u"&&typeof r.document.createElement<"u";qe(t.routes.length>0,"You must provide a non-empty routes array to createRouter");let i=t.mapRouteProperties||v5,o={},s=Vc(t.routes,i,void 0,o),f,d=t.basename||"/",h=t.dataStrategy||x5,v=t.patchRoutesOnNavigation,y={...t.future},S=null,p=new Set,g=null,w=null,x=null,R=t.hydrationData!=null,T=Ja(s,t.history.location,d),A=null;if(T==null&&!v){let H=nr(404,{pathname:t.history.location.pathname}),{matches:Y,route:J}=n1(s);T=Y,A={[J.id]:H}}T&&!t.hydrationData&&qn(T,s,t.history.location.pathname).active&&(T=null);let N;if(T)if(T.some(H=>H.route.lazy))N=!1;else if(!T.some(H=>H.route.loader))N=!0;else{let H=t.hydrationData?t.hydrationData.loaderData:null,Y=t.hydrationData?t.hydrationData.errors:null;if(Y){let J=T.findIndex(ue=>Y[ue.route.id]!==void 0);N=T.slice(0,J+1).every(ue=>!$m(ue.route,H,Y))}else N=T.every(J=>!$m(J.route,H,Y))}else{N=!1,T=[];let H=qn(null,s,t.history.location.pathname);H.active&&H.matches&&(T=H.matches)}let j,O={historyAction:t.history.action,location:t.history.location,matches:T,initialized:N,navigation:tm,restoreScrollPosition:t.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:t.hydrationData&&t.hydrationData.loaderData||{},actionData:t.hydrationData&&t.hydrationData.actionData||null,errors:t.hydrationData&&t.hydrationData.errors||A,fetchers:new Map,blockers:new Map},q="POP",B=!1,V,z=!1,X=new Map,te=null,fe=!1,Z=!1,ae=new Set,ie=new Map,U=0,I=-1,ne=new Map,K=new Set,M=new Map,F=new Map,se=new Set,de=new Map,ce,ge=null;function Te(){if(S=t.history.listen(({action:H,location:Y,delta:J})=>{if(ce){ce(),ce=void 0;return}It(de.size===0||J!=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 ue=tn({currentLocation:O.location,nextLocation:Y,historyAction:H});if(ue&&J!=null){let ve=new Promise(Ee=>{ce=Ee});t.history.go(J*-1),Tn(ue,{state:"blocked",location:Y,proceed(){Tn(ue,{state:"proceeding",proceed:void 0,reset:void 0,location:Y}),ve.then(()=>t.history.go(J))},reset(){let Ee=new Map(O.blockers);Ee.set(ue,mo),je({blockers:Ee})}});return}return ft(H,Y)}),a){_5(r,X);let H=()=>N5(r,X);r.addEventListener("pagehide",H),te=()=>r.removeEventListener("pagehide",H)}return O.initialized||ft("POP",O.location,{initialHydration:!0}),j}function mt(){S&&S(),te&&te(),p.clear(),V&&V.abort(),O.fetchers.forEach((H,Y)=>wa(Y)),O.blockers.forEach((H,Y)=>Zo(Y))}function _e(H){return p.add(H),()=>p.delete(H)}function je(H,Y={}){O={...O,...H};let J=[],ue=[];O.fetchers.forEach((ve,Ee)=>{ve.state==="idle"&&(se.has(Ee)?J.push(Ee):ue.push(Ee))}),[...p].forEach(ve=>ve(O,{deletedFetchers:J,viewTransitionOpts:Y.viewTransitionOpts,flushSync:Y.flushSync===!0})),J.forEach(ve=>wa(ve)),ue.forEach(ve=>O.fetchers.delete(ve))}function Ne(H,Y,{flushSync:J}={}){var he,Re;let ue=O.actionData!=null&&O.navigation.formMethod!=null&&mr(O.navigation.formMethod)&&O.navigation.state==="loading"&&((he=H.state)==null?void 0:he._isRedirect)!==!0,ve;Y.actionData?Object.keys(Y.actionData).length>0?ve=Y.actionData:ve=null:ue?ve=O.actionData:ve=null;let Ee=Y.loaderData?e1(O.loaderData,Y.loaderData,Y.matches||[],Y.errors):O.loaderData,Me=O.blockers;Me.size>0&&(Me=new Map(Me),Me.forEach((Ce,Be)=>Me.set(Be,mo)));let pe=B===!0||O.navigation.formMethod!=null&&mr(O.navigation.formMethod)&&((Re=H.state)==null?void 0:Re._isRedirect)!==!0;f&&(s=f,f=void 0),fe||q==="POP"||(q==="PUSH"?t.history.push(H,H.state):q==="REPLACE"&&t.history.replace(H,H.state));let Se;if(q==="POP"){let Ce=X.get(O.location.pathname);Ce&&Ce.has(H.pathname)?Se={currentLocation:O.location,nextLocation:H}:X.has(H.pathname)&&(Se={currentLocation:H,nextLocation:O.location})}else if(z){let Ce=X.get(O.location.pathname);Ce?Ce.add(H.pathname):(Ce=new Set([H.pathname]),X.set(O.location.pathname,Ce)),Se={currentLocation:O.location,nextLocation:H}}je({...Y,actionData:ve,loaderData:Ee,historyAction:q,location:H,initialized:!0,navigation:tm,revalidation:"idle",restoreScrollPosition:yi(H,Y.matches||O.matches),preventScrollReset:pe,blockers:Me},{viewTransitionOpts:Se,flushSync:J===!0}),q="POP",B=!1,z=!1,fe=!1,Z=!1,ge==null||ge.resolve(),ge=null}async function Mt(H,Y){if(typeof H=="number"){t.history.go(H);return}let J=Um(O.location,O.matches,d,H,Y==null?void 0:Y.fromRouteId,Y==null?void 0:Y.relative),{path:ue,submission:ve,error:Ee}=Qb(!1,J,Y),Me=O.location,pe=To(O.location,ue,Y&&Y.state);pe={...pe,...t.history.encodeLocation(pe)};let Se=Y&&Y.replace!=null?Y.replace:void 0,he="PUSH";Se===!0?he="REPLACE":Se===!1||ve!=null&&mr(ve.formMethod)&&ve.formAction===O.location.pathname+O.location.search&&(he="REPLACE");let Re=Y&&"preventScrollReset"in Y?Y.preventScrollReset===!0:void 0,Ce=(Y&&Y.flushSync)===!0,Be=tn({currentLocation:Me,nextLocation:pe,historyAction:he});if(Be){Tn(Be,{state:"blocked",location:pe,proceed(){Tn(Be,{state:"proceeding",proceed:void 0,reset:void 0,location:pe}),Mt(H,Y)},reset(){let vt=new Map(O.blockers);vt.set(Be,mo),je({blockers:vt})}});return}await ft(he,pe,{submission:ve,pendingError:Ee,preventScrollReset:Re,replace:Y&&Y.replace,enableViewTransition:Y&&Y.viewTransition,flushSync:Ce})}function bn(){ge||(ge=z5()),jt(),je({revalidation:"loading"});let H=ge.promise;return O.navigation.state==="submitting"?H:O.navigation.state==="idle"?(ft(O.historyAction,O.location,{startUninterruptedRevalidation:!0}),H):(ft(q||O.historyAction,O.navigation.location,{overrideNavigation:O.navigation,enableViewTransition:z===!0}),H)}async function ft(H,Y,J){V&&V.abort(),V=null,q=H,fe=(J&&J.startUninterruptedRevalidation)===!0,rl(O.location,O.matches),B=(J&&J.preventScrollReset)===!0,z=(J&&J.enableViewTransition)===!0;let ue=f||s,ve=J&&J.overrideNavigation,Ee=Ja(ue,Y,d),Me=(J&&J.flushSync)===!0,pe=qn(Ee,ue,Y.pathname);if(pe.active&&pe.matches&&(Ee=pe.matches),!Ee){let{error:ut,notFoundMatches:ot,route:Dt}=fu(Y.pathname);Ne(Y,{matches:ot,loaderData:{},errors:{[Dt.id]:ut}},{flushSync:Me});return}if(O.initialized&&!Z&&R5(O.location,Y)&&!(J&&J.submission&&mr(J.submission.formMethod))){Ne(Y,{matches:Ee},{flushSync:Me});return}V=new AbortController;let Se=Ul(t.history,Y,V.signal,J&&J.submission),he;if(J&&J.pendingError)he=[Bi(Ee).route.id,{type:"error",error:J.pendingError}];else if(J&&J.submission&&mr(J.submission.formMethod)){let ut=await ln(Se,Y,J.submission,Ee,pe.active,{replace:J.replace,flushSync:Me});if(ut.shortCircuited)return;if(ut.pendingActionResult){let[ot,Dt]=ut.pendingActionResult;if(zn(Dt)&&yf(Dt.error)&&Dt.error.status===404){V=null,Ne(Y,{matches:ut.matches,loaderData:{},errors:{[ot]:Dt.error}});return}}Ee=ut.matches||Ee,he=ut.pendingActionResult,ve=nm(Y,J.submission),Me=!1,pe.active=!1,Se=Ul(t.history,Se.url,Se.signal)}let{shortCircuited:Re,matches:Ce,loaderData:Be,errors:vt}=await Cn(Se,Y,Ee,pe.active,ve,J&&J.submission,J&&J.fetcherSubmission,J&&J.replace,J&&J.initialHydration===!0,Me,he);Re||(V=null,Ne(Y,{matches:Ce||Ee,...t1(he),loaderData:Be,errors:vt}))}async function ln(H,Y,J,ue,ve,Ee={}){jt();let Me=M5(Y,J);if(je({navigation:Me},{flushSync:Ee.flushSync===!0}),ve){let he=await Fr(ue,Y.pathname,H.signal);if(he.type==="aborted")return{shortCircuited:!0};if(he.type==="error"){let Re=Bi(he.partialMatches).route.id;return{matches:he.partialMatches,pendingActionResult:[Re,{type:"error",error:he.error}]}}else if(he.matches)ue=he.matches;else{let{notFoundMatches:Re,error:Ce,route:Be}=fu(Y.pathname);return{matches:Re,pendingActionResult:[Be.id,{type:"error",error:Ce}]}}}let pe,Se=go(ue,Y);if(!Se.route.action&&!Se.route.lazy)pe={type:"error",error:nr(405,{method:H.method,pathname:Y.pathname,routeId:Se.route.id})};else if(pe=(await Rt("action",O,H,[Se],ue,null))[Se.route.id],H.signal.aborted)return{shortCircuited:!0};if(Pi(pe)){let he;return Ee&&Ee.replace!=null?he=Ee.replace:he=Ib(pe.response.headers.get("Location"),new URL(H.url),d)===O.location.pathname+O.location.search,await Le(H,pe,!0,{submission:J,replace:he}),{shortCircuited:!0}}if(zn(pe)){let he=Bi(ue,Se.route.id);return(Ee&&Ee.replace)!==!0&&(q="PUSH"),{matches:ue,pendingActionResult:[he.route.id,pe]}}return{matches:ue,pendingActionResult:[Se.route.id,pe]}}async function Cn(H,Y,J,ue,ve,Ee,Me,pe,Se,he,Re){let Ce=ve||nm(Y,Ee),Be=Ee||Me||a1(Ce),vt=!fe&&!Se;if(ue){if(vt){let pt=en(Re);je({navigation:Ce,...pt!==void 0?{actionData:pt}:{}},{flushSync:he})}let rt=await Fr(J,Y.pathname,H.signal);if(rt.type==="aborted")return{shortCircuited:!0};if(rt.type==="error"){let pt=Bi(rt.partialMatches).route.id;return{matches:rt.partialMatches,loaderData:{},errors:{[pt]:rt.error}}}else if(rt.matches)J=rt.matches;else{let{error:pt,notFoundMatches:lr,route:fn}=fu(Y.pathname);return{matches:lr,loaderData:{},errors:{[fn.id]:pt}}}}let ut=f||s,[ot,Dt]=Gb(t.history,O,J,Be,Y,Se===!0,Z,ae,se,M,K,ut,d,Re);if(I=++U,ot.length===0&&Dt.length===0){let rt=Xo();return Ne(Y,{matches:J,loaderData:{},errors:Re&&zn(Re[1])?{[Re[0]]:Re[1].error}:null,...t1(Re),...rt?{fetchers:new Map(O.fetchers)}:{}},{flushSync:he}),{shortCircuited:!0}}if(vt){let rt={};if(!ue){rt.navigation=Ce;let pt=en(Re);pt!==void 0&&(rt.actionData=pt)}Dt.length>0&&(rt.fetchers=Pn(Dt)),je(rt,{flushSync:he})}Dt.forEach(rt=>{rr(rt.key),rt.controller&&ie.set(rt.key,rt.controller)});let Vr=()=>Dt.forEach(rt=>rr(rt.key));V&&V.signal.addEventListener("abort",Vr);let{loaderResults:ar,fetcherResults:Rn}=await un(O,J,ot,Dt,H);if(H.signal.aborted)return{shortCircuited:!0};V&&V.signal.removeEventListener("abort",Vr),Dt.forEach(rt=>ie.delete(rt.key));let qt=pc(ar);if(qt)return await Le(H,qt.result,!0,{replace:pe}),{shortCircuited:!0};if(qt=pc(Rn),qt)return K.add(qt.key),await Le(H,qt.result,!0,{replace:pe}),{shortCircuited:!0};let{loaderData:Er,errors:ir}=Wb(O,J,ar,Re,Dt,Rn);Se&&O.errors&&(ir={...O.errors,...ir});let Sn=Xo(),gt=Oa(I),bi=Sn||gt||Dt.length>0;return{matches:J,loaderData:Er,errors:ir,...bi?{fetchers:new Map(O.fetchers)}:{}}}function en(H){if(H&&!zn(H[1]))return{[H[0]]:H[1].data};if(O.actionData)return Object.keys(O.actionData).length===0?null:O.actionData}function Pn(H){return H.forEach(Y=>{let J=O.fetchers.get(Y.key),ue=vo(void 0,J?J.data:void 0);O.fetchers.set(Y.key,ue)}),new Map(O.fetchers)}async function be(H,Y,J,ue){rr(H);let ve=(ue&&ue.flushSync)===!0,Ee=f||s,Me=Um(O.location,O.matches,d,J,Y,ue==null?void 0:ue.relative),pe=Ja(Ee,Me,d),Se=qn(pe,Ee,Me);if(Se.active&&Se.matches&&(pe=Se.matches),!pe){sn(H,Y,nr(404,{pathname:Me}),{flushSync:ve});return}let{path:he,submission:Re,error:Ce}=Qb(!0,Me,ue);if(Ce){sn(H,Y,Ce,{flushSync:ve});return}let Be=go(pe,he),vt=(ue&&ue.preventScrollReset)===!0;if(Re&&mr(Re.formMethod)){await Fe(H,Y,he,Be,pe,Se.active,ve,vt,Re);return}M.set(H,{routeId:Y,path:he}),await xt(H,Y,he,Be,pe,Se.active,ve,vt,Re)}async function Fe(H,Y,J,ue,ve,Ee,Me,pe,Se){jt(),M.delete(H);function he(Et){if(!Et.route.action&&!Et.route.lazy){let Yr=nr(405,{method:Se.formMethod,pathname:J,routeId:Y});return sn(H,Y,Yr,{flushSync:Me}),!0}return!1}if(!Ee&&he(ue))return;let Re=O.fetchers.get(H);on(H,j5(Se,Re),{flushSync:Me});let Ce=new AbortController,Be=Ul(t.history,J,Ce.signal,Se);if(Ee){let Et=await Fr(ve,J,Be.signal);if(Et.type==="aborted")return;if(Et.type==="error"){sn(H,Y,Et.error,{flushSync:Me});return}else if(Et.matches){if(ve=Et.matches,ue=go(ve,J),he(ue))return}else{sn(H,Y,nr(404,{pathname:J}),{flushSync:Me});return}}ie.set(H,Ce);let vt=U,ot=(await Rt("action",O,Be,[ue],ve,H))[ue.route.id];if(Be.signal.aborted){ie.get(H)===Ce&&ie.delete(H);return}if(se.has(H)){if(Pi(ot)||zn(ot)){on(H,Za(void 0));return}}else{if(Pi(ot))if(ie.delete(H),I>vt){on(H,Za(void 0));return}else return K.add(H),on(H,vo(Se)),Le(Be,ot,!1,{fetcherSubmission:Se,preventScrollReset:pe});if(zn(ot)){sn(H,Y,ot.error);return}}let Dt=O.navigation.location||O.location,Vr=Ul(t.history,Dt,Ce.signal),ar=f||s,Rn=O.navigation.state!=="idle"?Ja(ar,O.navigation.location,d):O.matches;qe(Rn,"Didn't find any matches after fetcher action");let qt=++U;ne.set(H,qt);let Er=vo(Se,ot.data);O.fetchers.set(H,Er);let[ir,Sn]=Gb(t.history,O,Rn,Se,Dt,!1,Z,ae,se,M,K,ar,d,[ue.route.id,ot]);Sn.filter(Et=>Et.key!==H).forEach(Et=>{let Yr=Et.key,du=O.fetchers.get(Yr),Ef=vo(void 0,du?du.data:void 0);O.fetchers.set(Yr,Ef),rr(Yr),Et.controller&&ie.set(Yr,Et.controller)}),je({fetchers:new Map(O.fetchers)});let gt=()=>Sn.forEach(Et=>rr(Et.key));Ce.signal.addEventListener("abort",gt);let{loaderResults:bi,fetcherResults:rt}=await un(O,Rn,ir,Sn,Vr);if(Ce.signal.aborted)return;Ce.signal.removeEventListener("abort",gt),ne.delete(H),ie.delete(H),Sn.forEach(Et=>ie.delete(Et.key));let pt=pc(bi);if(pt)return Le(Vr,pt.result,!1,{preventScrollReset:pe});if(pt=pc(rt),pt)return K.add(pt.key),Le(Vr,pt.result,!1,{preventScrollReset:pe});let{loaderData:lr,errors:fn}=Wb(O,Rn,bi,void 0,Sn,rt);if(O.fetchers.has(H)){let Et=Za(ot.data);O.fetchers.set(H,Et)}Oa(qt),O.navigation.state==="loading"&&qt>I?(qe(q,"Expected pending action"),V&&V.abort(),Ne(O.navigation.location,{matches:Rn,loaderData:lr,errors:fn,fetchers:new Map(O.fetchers)})):(je({errors:fn,loaderData:e1(O.loaderData,lr,Rn,fn),fetchers:new Map(O.fetchers)}),Z=!1)}async function xt(H,Y,J,ue,ve,Ee,Me,pe,Se){let he=O.fetchers.get(H);on(H,vo(Se,he?he.data:void 0),{flushSync:Me});let Re=new AbortController,Ce=Ul(t.history,J,Re.signal);if(Ee){let ot=await Fr(ve,J,Ce.signal);if(ot.type==="aborted")return;if(ot.type==="error"){sn(H,Y,ot.error,{flushSync:Me});return}else if(ot.matches)ve=ot.matches,ue=go(ve,J);else{sn(H,Y,nr(404,{pathname:J}),{flushSync:Me});return}}ie.set(H,Re);let Be=U,ut=(await Rt("loader",O,Ce,[ue],ve,H))[ue.route.id];if(ie.get(H)===Re&&ie.delete(H),!Ce.signal.aborted){if(se.has(H)){on(H,Za(void 0));return}if(Pi(ut))if(I>Be){on(H,Za(void 0));return}else{K.add(H),await Le(Ce,ut,!1,{preventScrollReset:pe});return}if(zn(ut)){sn(H,Y,ut.error);return}on(H,Za(ut.data))}}async function Le(H,Y,J,{submission:ue,fetcherSubmission:ve,preventScrollReset:Ee,replace:Me}={}){Y.response.headers.has("X-Remix-Revalidate")&&(Z=!0);let pe=Y.response.headers.get("Location");qe(pe,"Expected a Location header on the redirect Response"),pe=Ib(pe,new URL(H.url),d);let Se=To(O.location,pe,{_isRedirect:!0});if(a){let ut=!1;if(Y.response.headers.has("X-Remix-Reload-Document"))ut=!0;else if(Yv.test(pe)){const ot=t.history.createURL(pe);ut=ot.origin!==r.location.origin||Sr(ot.pathname,d)==null}if(ut){Me?r.location.replace(pe):r.location.assign(pe);return}}V=null;let he=Me===!0||Y.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:Re,formAction:Ce,formEncType:Be}=O.navigation;!ue&&!ve&&Re&&Ce&&Be&&(ue=a1(O.navigation));let vt=ue||ve;if(h5.has(Y.response.status)&&vt&&mr(vt.formMethod))await ft(he,Se,{submission:{...vt,formAction:pe},preventScrollReset:Ee||B,enableViewTransition:J?z:void 0});else{let ut=nm(Se,ue);await ft(he,Se,{overrideNavigation:ut,fetcherSubmission:ve,preventScrollReset:Ee||B,enableViewTransition:J?z:void 0})}}async function Rt(H,Y,J,ue,ve,Ee){let Me,pe={};try{Me=await E5(h,H,Y,J,ue,ve,Ee,o,i)}catch(Se){return ue.forEach(he=>{pe[he.route.id]={type:"error",error:Se}}),pe}for(let[Se,he]of Object.entries(Me))if(D5(he)){let Re=he.result;pe[Se]={type:"redirect",response:C5(Re,J,Se,ve,d)}}else pe[Se]=await O5(he);return pe}async function un(H,Y,J,ue,ve){let Ee=Rt("loader",H,ve,J,Y,null),Me=Promise.all(ue.map(async he=>{if(he.matches&&he.match&&he.controller){let Ce=(await Rt("loader",H,Ul(t.history,he.path,he.controller.signal),[he.match],he.matches,he.key))[he.match.route.id];return{[he.key]:Ce}}else return Promise.resolve({[he.key]:{type:"error",error:nr(404,{pathname:he.path})}})})),pe=await Ee,Se=(await Me).reduce((he,Re)=>Object.assign(he,Re),{});return{loaderResults:pe,fetcherResults:Se}}function jt(){Z=!0,M.forEach((H,Y)=>{ie.has(Y)&&ae.add(Y),rr(Y)})}function on(H,Y,J={}){O.fetchers.set(H,Y),je({fetchers:new Map(O.fetchers)},{flushSync:(J&&J.flushSync)===!0})}function sn(H,Y,J,ue={}){let ve=Bi(O.matches,Y);wa(H),je({errors:{[ve.route.id]:J},fetchers:new Map(O.fetchers)},{flushSync:(ue&&ue.flushSync)===!0})}function cu(H){return F.set(H,(F.get(H)||0)+1),se.has(H)&&se.delete(H),O.fetchers.get(H)||m5}function wa(H){let Y=O.fetchers.get(H);ie.has(H)&&!(Y&&Y.state==="loading"&&ne.has(H))&&rr(H),M.delete(H),ne.delete(H),K.delete(H),se.delete(H),ae.delete(H),O.fetchers.delete(H)}function bf(H){let Y=(F.get(H)||0)-1;Y<=0?(F.delete(H),se.add(H)):F.set(H,Y),je({fetchers:new Map(O.fetchers)})}function rr(H){let Y=ie.get(H);Y&&(Y.abort(),ie.delete(H))}function Go(H){for(let Y of H){let J=cu(Y),ue=Za(J.data);O.fetchers.set(Y,ue)}}function Xo(){let H=[],Y=!1;for(let J of K){let ue=O.fetchers.get(J);qe(ue,`Expected fetcher: ${J}`),ue.state==="loading"&&(K.delete(J),H.push(J),Y=!0)}return Go(H),Y}function Oa(H){let Y=[];for(let[J,ue]of ne)if(ue<H){let ve=O.fetchers.get(J);qe(ve,`Expected fetcher: ${J}`),ve.state==="loading"&&(rr(J),ne.delete(J),Y.push(J))}return Go(Y),Y.length>0}function cn(H,Y){let J=O.blockers.get(H)||mo;return de.get(H)!==Y&&de.set(H,Y),J}function Zo(H){O.blockers.delete(H),de.delete(H)}function Tn(H,Y){let J=O.blockers.get(H)||mo;qe(J.state==="unblocked"&&Y.state==="blocked"||J.state==="blocked"&&Y.state==="blocked"||J.state==="blocked"&&Y.state==="proceeding"||J.state==="blocked"&&Y.state==="unblocked"||J.state==="proceeding"&&Y.state==="unblocked",`Invalid blocker state transition: ${J.state} -> ${Y.state}`);let ue=new Map(O.blockers);ue.set(H,Y),je({blockers:ue})}function tn({currentLocation:H,nextLocation:Y,historyAction:J}){if(de.size===0)return;de.size>1&&It(!1,"A router only supports one blocker at a time");let ue=Array.from(de.entries()),[ve,Ee]=ue[ue.length-1],Me=O.blockers.get(ve);if(!(Me&&Me.state==="proceeding")&&Ee({currentLocation:H,nextLocation:Y,historyAction:J}))return ve}function fu(H){let Y=nr(404,{pathname:H}),J=f||s,{matches:ue,route:ve}=n1(J);return{notFoundMatches:ue,route:ve,error:Y}}function Sf(H,Y,J){if(g=H,x=Y,w=J||null,!R&&O.navigation===tm){R=!0;let ue=yi(O.location,O.matches);ue!=null&&je({restoreScrollPosition:ue})}return()=>{g=null,x=null,w=null}}function Io(H,Y){return w&&w(H,Y.map(ue=>Y4(ue,O.loaderData)))||H.key}function rl(H,Y){if(g&&x){let J=Io(H,Y);g[J]=x()}}function yi(H,Y){if(g){let J=Io(H,Y),ue=g[J];if(typeof ue=="number")return ue}return null}function qn(H,Y,J){if(v)if(H){if(Object.keys(H[0].params).length>0)return{active:!0,matches:Oc(Y,J,d,!0)}}else return{active:!0,matches:Oc(Y,J,d,!0)||[]};return{active:!1,matches:null}}async function Fr(H,Y,J){if(!v)return{type:"success",matches:H};let ue=H;for(;;){let ve=f==null,Ee=f||s,Me=o;try{await v({path:Y,matches:ue,patch:(he,Re)=>{J.aborted||Zb(he,Re,Ee,Me,i)}})}catch(he){return{type:"error",error:he,partialMatches:ue}}finally{ve&&!J.aborted&&(s=[...s])}if(J.aborted)return{type:"aborted"};let pe=Ja(Ee,Y,d);if(pe)return{type:"success",matches:pe};let Se=Oc(Ee,Y,d,!0);if(!Se||ue.length===Se.length&&ue.every((he,Re)=>he.route.id===Se[Re].route.id))return{type:"success",matches:null};ue=Se}}function gi(H){o={},f=Vc(H,i,void 0,o)}function xf(H,Y){let J=f==null;Zb(H,Y,f||s,o,i),J&&(s=[...s],je({}))}return j={get basename(){return d},get future(){return y},get state(){return O},get routes(){return s},get window(){return r},initialize:Te,subscribe:_e,enableScrollRestoration:Sf,navigate:Mt,fetch:be,revalidate:bn,createHref:H=>t.history.createHref(H),encodeLocation:H=>t.history.encodeLocation(H),getFetcher:cu,deleteFetcher:bf,dispose:mt,getBlocker:cn,deleteBlocker:Zo,patchRoutes:xf,_internalFetchControllers:ie,_internalSetRoutes:gi},j}function y5(t){return t!=null&&("formData"in t&&t.formData!=null||"body"in t&&t.body!==void 0)}function Um(t,r,a,i,o,s){let f,d;if(o){f=[];for(let v of r)if(f.push(v),v.route.id===o){d=v;break}}else f=r,d=r[r.length-1];let h=Vv(i||".",Fv(f),Sr(t.pathname,a)||t.pathname,s==="path");if(i==null&&(h.search=t.search,h.hash=t.hash),(i==null||i===""||i===".")&&d){let v=Qv(h.search);if(d.route.index&&!v)h.search=h.search?h.search.replace(/^\?/,"?index&"):"?index";else if(!d.route.index&&v){let y=new URLSearchParams(h.search),S=y.getAll("index");y.delete("index"),S.filter(g=>g).forEach(g=>y.append("index",g));let p=y.toString();h.search=p?`?${p}`:""}}return a!=="/"&&(h.pathname=h.pathname==="/"?a:Hr([a,h.pathname])),pi(h)}function Qb(t,r,a){if(!a||!y5(a))return{path:r};if(a.formMethod&&!A5(a.formMethod))return{path:r,error:nr(405,{method:a.formMethod})};let i=()=>({path:r,error:nr(400,{type:"invalid-body"})}),s=(a.formMethod||"get").toUpperCase(),f=a2(r);if(a.body!==void 0){if(a.formEncType==="text/plain"){if(!mr(s))return i();let S=typeof a.body=="string"?a.body:a.body instanceof FormData||a.body instanceof URLSearchParams?Array.from(a.body.entries()).reduce((p,[g,w])=>`${p}${g}=${w}
72
- `,""):String(a.body);return{path:r,submission:{formMethod:s,formAction:f,formEncType:a.formEncType,formData:void 0,json:void 0,text:S}}}else if(a.formEncType==="application/json"){if(!mr(s))return i();try{let S=typeof a.body=="string"?JSON.parse(a.body):a.body;return{path:r,submission:{formMethod:s,formAction:f,formEncType:a.formEncType,formData:void 0,json:S,text:void 0}}}catch{return i()}}}qe(typeof FormData=="function","FormData is not available in this environment");let d,h;if(a.formData)d=Bm(a.formData),h=a.formData;else if(a.body instanceof FormData)d=Bm(a.body),h=a.body;else if(a.body instanceof URLSearchParams)d=a.body,h=Jb(d);else if(a.body==null)d=new URLSearchParams,h=new FormData;else try{d=new URLSearchParams(a.body),h=Jb(d)}catch{return i()}let v={formMethod:s,formAction:f,formEncType:a&&a.formEncType||"application/x-www-form-urlencoded",formData:h,json:void 0,text:void 0};if(mr(v.formMethod))return{path:r,submission:v};let y=Ea(r);return t&&y.search&&Qv(y.search)&&d.append("index",""),y.search=`?${d}`,{path:pi(y),submission:v}}function Kb(t,r,a=!1){let i=t.findIndex(o=>o.route.id===r);return i>=0?t.slice(0,a?i+1:i):t}function Gb(t,r,a,i,o,s,f,d,h,v,y,S,p,g){let w=g?zn(g[1])?g[1].error:g[1].data:void 0,x=t.createURL(r.location),R=t.createURL(o),T=a;s&&r.errors?T=Kb(a,Object.keys(r.errors)[0],!0):g&&zn(g[1])&&(T=Kb(a,g[0]));let A=g?g[1].statusCode:void 0,N=A&&A>=400,j=T.filter((q,B)=>{let{route:V}=q;if(V.lazy)return!0;if(V.loader==null)return!1;if(s)return $m(V,r.loaderData,r.errors);if(g5(r.loaderData,r.matches[B],q))return!0;let z=r.matches[B],X=q;return Xb(q,{currentUrl:x,currentParams:z.params,nextUrl:R,nextParams:X.params,...i,actionResult:w,actionStatus:A,defaultShouldRevalidate:N?!1:f||x.pathname+x.search===R.pathname+R.search||x.search!==R.search||b5(z,X)})}),O=[];return v.forEach((q,B)=>{if(s||!a.some(fe=>fe.route.id===q.routeId)||h.has(B))return;let V=Ja(S,q.path,p);if(!V){O.push({key:B,routeId:q.routeId,path:q.path,matches:null,match:null,controller:null});return}let z=r.fetchers.get(B),X=go(V,q.path),te=!1;y.has(B)?te=!1:d.has(B)?(d.delete(B),te=!0):z&&z.state!=="idle"&&z.data===void 0?te=f:te=Xb(X,{currentUrl:x,currentParams:r.matches[r.matches.length-1].params,nextUrl:R,nextParams:a[a.length-1].params,...i,actionResult:w,actionStatus:A,defaultShouldRevalidate:N?!1:f}),te&&O.push({key:B,routeId:q.routeId,path:q.path,matches:V,match:X,controller:new AbortController})}),[j,O]}function $m(t,r,a){if(t.lazy)return!0;if(!t.loader)return!1;let i=r!=null&&r[t.id]!==void 0,o=a!=null&&a[t.id]!==void 0;return!i&&o?!1:typeof t.loader=="function"&&t.loader.hydrate===!0?!0:!i&&!o}function g5(t,r,a){let i=!r||a.route.id!==r.route.id,o=!t.hasOwnProperty(a.route.id);return i||o}function b5(t,r){let a=t.route.path;return t.pathname!==r.pathname||a!=null&&a.endsWith("*")&&t.params["*"]!==r.params["*"]}function Xb(t,r){if(t.route.shouldRevalidate){let a=t.route.shouldRevalidate(r);if(typeof a=="boolean")return a}return r.defaultShouldRevalidate}function Zb(t,r,a,i,o){let s;if(t){let h=i[t];qe(h,`No route found to patch children into: routeId = ${t}`),h.children||(h.children=[]),s=h.children}else s=a;let f=r.filter(h=>!s.some(v=>r2(h,v))),d=Vc(f,o,[t||"_","patch",String((s==null?void 0:s.length)||"0")],i);s.push(...d)}function r2(t,r){return"id"in t&&"id"in r&&t.id===r.id?!0:t.index===r.index&&t.path===r.path&&t.caseSensitive===r.caseSensitive?(!t.children||t.children.length===0)&&(!r.children||r.children.length===0)?!0:t.children.every((a,i)=>{var o;return(o=r.children)==null?void 0:o.some(s=>r2(a,s))}):!1}async function S5(t,r,a){if(!t.lazy)return;let i=await t.lazy();if(!t.lazy)return;let o=a[t.id];qe(o,"No route found in manifest");let s={};for(let f in i){let h=o[f]!==void 0&&f!=="hasErrorBoundary";It(!h,`Route "${o.id}" has a static property "${f}" defined but its lazy function is also returning a value for this property. The lazy route property "${f}" will be ignored.`),!h&&!F4.has(f)&&(s[f]=i[f])}Object.assign(o,s),Object.assign(o,{...r(o),lazy:void 0})}async function x5({matches:t}){let r=t.filter(i=>i.shouldLoad);return(await Promise.all(r.map(i=>i.resolve()))).reduce((i,o,s)=>Object.assign(i,{[r[s].route.id]:o}),{})}async function E5(t,r,a,i,o,s,f,d,h,v){let y=s.map(g=>g.route.lazy?S5(g.route,h,d):void 0),S=s.map((g,w)=>{let x=y[w],R=o.some(A=>A.route.id===g.route.id);return{...g,shouldLoad:R,resolve:async A=>(A&&i.method==="GET"&&(g.route.lazy||g.route.loader)&&(R=!0),R?w5(r,i,g,x,A,v):Promise.resolve({type:"data",result:void 0}))}}),p=await t({matches:S,request:i,params:s[0].params,fetcherKey:f,context:v});try{await Promise.all(y)}catch{}return p}async function w5(t,r,a,i,o,s){let f,d,h=v=>{let y,S=new Promise((w,x)=>y=x);d=()=>y(),r.signal.addEventListener("abort",d);let p=w=>typeof v!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${t}" [routeId: ${a.route.id}]`)):v({request:r,params:a.params,context:s},...w!==void 0?[w]:[]),g=(async()=>{try{return{type:"data",result:await(o?o(x=>p(x)):p())}}catch(w){return{type:"error",result:w}}})();return Promise.race([g,S])};try{let v=a.route[t];if(i)if(v){let y,[S]=await Promise.all([h(v).catch(p=>{y=p}),i]);if(y!==void 0)throw y;f=S}else if(await i,v=a.route[t],v)f=await h(v);else if(t==="action"){let y=new URL(r.url),S=y.pathname+y.search;throw nr(405,{method:r.method,pathname:S,routeId:a.route.id})}else return{type:"data",result:void 0};else if(v)f=await h(v);else{let y=new URL(r.url),S=y.pathname+y.search;throw nr(404,{pathname:S})}}catch(v){return{type:"error",result:v}}finally{d&&r.signal.removeEventListener("abort",d)}return f}async function O5(t){var i,o,s,f;let{result:r,type:a}=t;if(i2(r)){let d;try{let h=r.headers.get("Content-Type");h&&/\bapplication\/json\b/.test(h)?r.body==null?d=null:d=await r.json():d=await r.text()}catch(h){return{type:"error",error:h}}return a==="error"?{type:"error",error:new Qc(r.status,r.statusText,d),statusCode:r.status,headers:r.headers}:{type:"data",data:d,statusCode:r.status,headers:r.headers}}if(a==="error"){if(r1(r)){if(r.data instanceof Error)return{type:"error",error:r.data,statusCode:(i=r.init)==null?void 0:i.status};r=new Qc(((o=r.init)==null?void 0:o.status)||500,void 0,r.data)}return{type:"error",error:r,statusCode:yf(r)?r.status:void 0}}return r1(r)?{type:"data",data:r.data,statusCode:(s=r.init)==null?void 0:s.status,headers:(f=r.init)!=null&&f.headers?new Headers(r.init.headers):void 0}:{type:"data",data:r}}function C5(t,r,a,i,o){let s=t.headers.get("Location");if(qe(s,"Redirects returned/thrown from loaders/actions must have a Location header"),!Yv.test(s)){let f=i.slice(0,i.findIndex(d=>d.route.id===a)+1);s=Um(new URL(r.url),f,o,s),t.headers.set("Location",s)}return t}function Ib(t,r,a){if(Yv.test(t)){let i=t,o=i.startsWith("//")?new URL(r.protocol+i):new URL(i),s=Sr(o.pathname,a)!=null;if(o.origin===r.origin&&s)return o.pathname+o.search+o.hash}return t}function Ul(t,r,a,i){let o=t.createURL(a2(r)).toString(),s={signal:a};if(i&&mr(i.formMethod)){let{formMethod:f,formEncType:d}=i;s.method=f.toUpperCase(),d==="application/json"?(s.headers=new Headers({"Content-Type":d}),s.body=JSON.stringify(i.json)):d==="text/plain"?s.body=i.text:d==="application/x-www-form-urlencoded"&&i.formData?s.body=Bm(i.formData):s.body=i.formData}return new Request(o,s)}function Bm(t){let r=new URLSearchParams;for(let[a,i]of t.entries())r.append(a,typeof i=="string"?i:i.name);return r}function Jb(t){let r=new FormData;for(let[a,i]of t.entries())r.append(a,i);return r}function T5(t,r,a,i=!1,o=!1){let s={},f=null,d,h=!1,v={},y=a&&zn(a[1])?a[1].error:void 0;return t.forEach(S=>{if(!(S.route.id in r))return;let p=S.route.id,g=r[p];if(qe(!Pi(g),"Cannot handle redirect results in processLoaderData"),zn(g)){let w=g.error;if(y!==void 0&&(w=y,y=void 0),f=f||{},o)f[p]=w;else{let x=Bi(t,p);f[x.route.id]==null&&(f[x.route.id]=w)}i||(s[p]=n2),h||(h=!0,d=yf(g.error)?g.error.status:500),g.headers&&(v[p]=g.headers)}else s[p]=g.data,g.statusCode&&g.statusCode!==200&&!h&&(d=g.statusCode),g.headers&&(v[p]=g.headers)}),y!==void 0&&a&&(f={[a[0]]:y},s[a[0]]=void 0),{loaderData:s,errors:f,statusCode:d||200,loaderHeaders:v}}function Wb(t,r,a,i,o,s){let{loaderData:f,errors:d}=T5(r,a,i);return o.forEach(h=>{let{key:v,match:y,controller:S}=h,p=s[v];if(qe(p,"Did not find corresponding fetcher result"),!(S&&S.signal.aborted))if(zn(p)){let g=Bi(t.matches,y==null?void 0:y.route.id);d&&d[g.route.id]||(d={...d,[g.route.id]:p.error}),t.fetchers.delete(v)}else if(Pi(p))qe(!1,"Unhandled fetcher revalidation redirect");else{let g=Za(p.data);t.fetchers.set(v,g)}}),{loaderData:f,errors:d}}function e1(t,r,a,i){let o=Object.entries(r).filter(([,s])=>s!==n2).reduce((s,[f,d])=>(s[f]=d,s),{});for(let s of a){let f=s.route.id;if(!r.hasOwnProperty(f)&&t.hasOwnProperty(f)&&s.route.loader&&(o[f]=t[f]),i&&i.hasOwnProperty(f))break}return o}function t1(t){return t?zn(t[1])?{actionData:{}}:{actionData:{[t[0]]:t[1].data}}:{}}function Bi(t,r){return(r?t.slice(0,t.findIndex(i=>i.route.id===r)+1):[...t]).reverse().find(i=>i.route.hasErrorBoundary===!0)||t[0]}function n1(t){let r=t.length===1?t[0]:t.find(a=>a.index||!a.path||a.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:r}],route:r}}function nr(t,{pathname:r,routeId:a,method:i,type:o,message:s}={}){let f="Unknown Server Error",d="Unknown @remix-run/router error";return t===400?(f="Bad Request",i&&r&&a?d=`You made a ${i} request to "${r}" but did not provide a \`loader\` for route "${a}", so there is no way to handle the request.`:o==="invalid-body"&&(d="Unable to encode submission body")):t===403?(f="Forbidden",d=`Route "${a}" does not match URL "${r}"`):t===404?(f="Not Found",d=`No route matches URL "${r}"`):t===405&&(f="Method Not Allowed",i&&r&&a?d=`You made a ${i.toUpperCase()} request to "${r}" but did not provide an \`action\` for route "${a}", so there is no way to handle the request.`:i&&(d=`Invalid request method "${i.toUpperCase()}"`)),new Qc(t||500,f,new Error(d),!0)}function pc(t){let r=Object.entries(t);for(let a=r.length-1;a>=0;a--){let[i,o]=r[a];if(Pi(o))return{key:i,result:o}}}function a2(t){let r=typeof t=="string"?Ea(t):t;return pi({...r,hash:""})}function R5(t,r){return t.pathname!==r.pathname||t.search!==r.search?!1:t.hash===""?r.hash!=="":t.hash===r.hash?!0:r.hash!==""}function D5(t){return i2(t.result)&&d5.has(t.result.status)}function zn(t){return t.type==="error"}function Pi(t){return(t&&t.type)==="redirect"}function r1(t){return typeof t=="object"&&t!=null&&"type"in t&&"data"in t&&"init"in t&&t.type==="DataWithResponseInit"}function i2(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.headers=="object"&&typeof t.body<"u"}function A5(t){return f5.has(t.toUpperCase())}function mr(t){return s5.has(t.toUpperCase())}function Qv(t){return new URLSearchParams(t).getAll("index").some(r=>r==="")}function go(t,r){let a=typeof r=="string"?Ea(r).search:r.search;if(t[t.length-1].route.index&&Qv(a||""))return t[t.length-1];let i=Wx(t);return i[i.length-1]}function a1(t){let{formMethod:r,formAction:a,formEncType:i,text:o,formData:s,json:f}=t;if(!(!r||!a||!i)){if(o!=null)return{formMethod:r,formAction:a,formEncType:i,formData:void 0,json:void 0,text:o};if(s!=null)return{formMethod:r,formAction:a,formEncType:i,formData:s,json:void 0,text:void 0};if(f!==void 0)return{formMethod:r,formAction:a,formEncType:i,formData:void 0,json:f,text:void 0}}}function nm(t,r){return r?{state:"loading",location:t,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}:{state:"loading",location:t,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function M5(t,r){return{state:"submitting",location:t,formMethod:r.formMethod,formAction:r.formAction,formEncType:r.formEncType,formData:r.formData,json:r.json,text:r.text}}function vo(t,r){return t?{state:"loading",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:r}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:r}}function j5(t,r){return{state:"submitting",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:r?r.data:void 0}}function Za(t){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function _5(t,r){try{let a=t.sessionStorage.getItem(t2);if(a){let i=JSON.parse(a);for(let[o,s]of Object.entries(i||{}))s&&Array.isArray(s)&&r.set(o,new Set(s||[]))}}catch{}}function N5(t,r){if(r.size>0){let a={};for(let[i,o]of r)a[i]=[...o];try{t.sessionStorage.setItem(t2,JSON.stringify(a))}catch(i){It(!1,`Failed to save applied view transitions in sessionStorage (${i}).`)}}}function z5(){let t,r,a=new Promise((i,o)=>{t=async s=>{i(s);try{await a}catch{}},r=async s=>{o(s);try{await a}catch{}}});return{promise:a,resolve:t,reject:r}}var el=E.createContext(null);el.displayName="DataRouter";var Vo=E.createContext(null);Vo.displayName="DataRouterState";var Kv=E.createContext({isTransitioning:!1});Kv.displayName="ViewTransition";var l2=E.createContext(new Map);l2.displayName="Fetchers";var L5=E.createContext(null);L5.displayName="Await";var kr=E.createContext(null);kr.displayName="Navigation";var Yo=E.createContext(null);Yo.displayName="Location";var xr=E.createContext({outlet:null,matches:[],isDataRoute:!1});xr.displayName="Route";var Gv=E.createContext(null);Gv.displayName="RouteError";function H5(t,{relative:r}={}){qe(Qo(),"useHref() may be used only in the context of a <Router> component.");let{basename:a,navigator:i}=E.useContext(kr),{hash:o,pathname:s,search:f}=Ko(t,{relative:r}),d=s;return a!=="/"&&(d=s==="/"?a:Hr([a,s])),i.createHref({pathname:d,search:f,hash:o})}function Qo(){return E.useContext(Yo)!=null}function tl(){return qe(Qo(),"useLocation() may be used only in the context of a <Router> component."),E.useContext(Yo).location}var u2="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function o2(t){E.useContext(kr).static||E.useLayoutEffect(t)}function Xv(){let{isDataRoute:t}=E.useContext(xr);return t?Z5():U5()}function U5(){qe(Qo(),"useNavigate() may be used only in the context of a <Router> component.");let t=E.useContext(el),{basename:r,navigator:a}=E.useContext(kr),{matches:i}=E.useContext(xr),{pathname:o}=tl(),s=JSON.stringify(Fv(i)),f=E.useRef(!1);return o2(()=>{f.current=!0}),E.useCallback((h,v={})=>{if(It(f.current,u2),!f.current)return;if(typeof h=="number"){a.go(h);return}let y=Vv(h,JSON.parse(s),o,v.relative==="path");t==null&&r!=="/"&&(y.pathname=y.pathname==="/"?r:Hr([r,y.pathname])),(v.replace?a.replace:a.push)(y,v.state,v)},[r,a,s,o,t])}var $5=E.createContext(null);function B5(t){let r=E.useContext(xr).outlet;return r&&E.createElement($5.Provider,{value:t},r)}function s2(){let{matches:t}=E.useContext(xr),r=t[t.length-1];return r?r.params:{}}function Ko(t,{relative:r}={}){let{matches:a}=E.useContext(xr),{pathname:i}=tl(),o=JSON.stringify(Fv(a));return E.useMemo(()=>Vv(t,JSON.parse(o),i,r==="path"),[t,o,i,r])}function P5(t,r){return c2(t,r)}function c2(t,r,a,i){var T;qe(Qo(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=E.useContext(kr),{matches:s}=E.useContext(xr),f=s[s.length-1],d=f?f.params:{},h=f?f.pathname:"/",v=f?f.pathnameBase:"/",y=f&&f.route;{let A=y&&y.path||"";d2(h,!y||A.endsWith("*")||A.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${h}" (under <Route path="${A}">) 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.
73
-
74
- Please change the parent <Route path="${A}"> to <Route path="${A==="/"?"*":`${A}/*`}">.`)}let S=tl(),p;if(r){let A=typeof r=="string"?Ea(r):r;qe(v==="/"||((T=A.pathname)==null?void 0:T.startsWith(v)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${v}" but pathname "${A.pathname}" was given in the \`location\` prop.`),p=A}else p=S;let g=p.pathname||"/",w=g;if(v!=="/"){let A=v.replace(/^\//,"").split("/");w="/"+g.replace(/^\//,"").split("/").slice(A.length).join("/")}let x=Ja(t,{pathname:w});It(y||x!=null,`No routes matched location "${p.pathname}${p.search}${p.hash}" `),It(x==null||x[x.length-1].route.element!==void 0||x[x.length-1].route.Component!==void 0||x[x.length-1].route.lazy!==void 0,`Matched leaf route at location "${p.pathname}${p.search}${p.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.`);let R=Y5(x&&x.map(A=>Object.assign({},A,{params:Object.assign({},d,A.params),pathname:Hr([v,o.encodeLocation?o.encodeLocation(A.pathname).pathname:A.pathname]),pathnameBase:A.pathnameBase==="/"?v:Hr([v,o.encodeLocation?o.encodeLocation(A.pathnameBase).pathname:A.pathnameBase])})),s,a,i);return r&&R?E.createElement(Yo.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...p},navigationType:"POP"}},R):R}function q5(){let t=f2(),r=yf(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),a=t instanceof Error?t.stack:null,i="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:i},s={padding:"2px 4px",backgroundColor:i},f=null;return console.error("Error handled by React Router default ErrorBoundary:",t),f=E.createElement(E.Fragment,null,E.createElement("p",null,"💿 Hey developer 👋"),E.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",E.createElement("code",{style:s},"ErrorBoundary")," or"," ",E.createElement("code",{style:s},"errorElement")," prop on your route.")),E.createElement(E.Fragment,null,E.createElement("h2",null,"Unexpected Application Error!"),E.createElement("h3",{style:{fontStyle:"italic"}},r),a?E.createElement("pre",{style:o},a):null,f)}var k5=E.createElement(q5,null),F5=class extends E.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?E.createElement(xr.Provider,{value:this.props.routeContext},E.createElement(Gv.Provider,{value:this.state.error,children:this.props.component})):this.props.children}};function V5({routeContext:t,match:r,children:a}){let i=E.useContext(el);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),E.createElement(xr.Provider,{value:t},a)}function Y5(t,r=[],a=null,i=null){if(t==null){if(!a)return null;if(a.errors)t=a.matches;else if(r.length===0&&!a.initialized&&a.matches.length>0)t=a.matches;else return null}let o=t,s=a==null?void 0:a.errors;if(s!=null){let h=o.findIndex(v=>v.route.id&&(s==null?void 0:s[v.route.id])!==void 0);qe(h>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),o=o.slice(0,Math.min(o.length,h+1))}let f=!1,d=-1;if(a)for(let h=0;h<o.length;h++){let v=o[h];if((v.route.HydrateFallback||v.route.hydrateFallbackElement)&&(d=h),v.route.id){let{loaderData:y,errors:S}=a,p=v.route.loader&&!y.hasOwnProperty(v.route.id)&&(!S||S[v.route.id]===void 0);if(v.route.lazy||p){f=!0,d>=0?o=o.slice(0,d+1):o=[o[0]];break}}}return o.reduceRight((h,v,y)=>{let S,p=!1,g=null,w=null;a&&(S=s&&v.route.id?s[v.route.id]:void 0,g=v.route.errorElement||k5,f&&(d<0&&y===0?(d2("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),p=!0,w=null):d===y&&(p=!0,w=v.route.hydrateFallbackElement||null)));let x=r.concat(o.slice(0,y+1)),R=()=>{let T;return S?T=g:p?T=w:v.route.Component?T=E.createElement(v.route.Component,null):v.route.element?T=v.route.element:T=h,E.createElement(V5,{match:v,routeContext:{outlet:h,matches:x,isDataRoute:a!=null},children:T})};return a&&(v.route.ErrorBoundary||v.route.errorElement||y===0)?E.createElement(F5,{location:a.location,revalidation:a.revalidation,component:g,error:S,children:R(),routeContext:{outlet:null,matches:x,isDataRoute:!0}}):R()},null)}function Zv(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Q5(t){let r=E.useContext(el);return qe(r,Zv(t)),r}function K5(t){let r=E.useContext(Vo);return qe(r,Zv(t)),r}function G5(t){let r=E.useContext(xr);return qe(r,Zv(t)),r}function Iv(t){let r=G5(t),a=r.matches[r.matches.length-1];return qe(a.route.id,`${t} can only be used on routes that contain a unique "id"`),a.route.id}function X5(){return Iv("useRouteId")}function f2(){var i;let t=E.useContext(Gv),r=K5("useRouteError"),a=Iv("useRouteError");return t!==void 0?t:(i=r.errors)==null?void 0:i[a]}function Z5(){let{router:t}=Q5("useNavigate"),r=Iv("useNavigate"),a=E.useRef(!1);return o2(()=>{a.current=!0}),E.useCallback(async(o,s={})=>{It(a.current,u2),a.current&&(typeof o=="number"?t.navigate(o):await t.navigate(o,{fromRouteId:r,...s}))},[t,r])}var i1={};function d2(t,r,a){!r&&!i1[t]&&(i1[t]=!0,It(!1,a))}var l1={};function u1(t,r){!t&&!l1[r]&&(l1[r]=!0,console.warn(r))}function I5(t){let r={hasErrorBoundary:t.hasErrorBoundary||t.ErrorBoundary!=null||t.errorElement!=null};return t.Component&&(t.element&&It(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(r,{element:E.createElement(t.Component),Component:void 0})),t.HydrateFallback&&(t.hydrateFallbackElement&&It(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(r,{hydrateFallbackElement:E.createElement(t.HydrateFallback),HydrateFallback:void 0})),t.ErrorBoundary&&(t.errorElement&&It(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(r,{errorElement:E.createElement(t.ErrorBoundary),ErrorBoundary:void 0})),r}var J5=class{constructor(){this.status="pending",this.promise=new Promise((t,r)=>{this.resolve=a=>{this.status==="pending"&&(this.status="resolved",t(a))},this.reject=a=>{this.status==="pending"&&(this.status="rejected",r(a))}})}};function W5({router:t,flushSync:r}){let[a,i]=E.useState(t.state),[o,s]=E.useState(),[f,d]=E.useState({isTransitioning:!1}),[h,v]=E.useState(),[y,S]=E.useState(),[p,g]=E.useState(),w=E.useRef(new Map),x=E.useCallback((N,{deletedFetchers:j,flushSync:O,viewTransitionOpts:q})=>{j.forEach(V=>w.current.delete(V)),N.fetchers.forEach((V,z)=>{V.data!==void 0&&w.current.set(z,V.data)}),u1(O===!1||r!=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 B=t.window!=null&&t.window.document!=null&&typeof t.window.document.startViewTransition=="function";if(u1(q==null||B,"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."),!q||!B){r&&O?r(()=>i(N)):E.startTransition(()=>i(N));return}if(r&&O){r(()=>{y&&(h&&h.resolve(),y.skipTransition()),d({isTransitioning:!0,flushSync:!0,currentLocation:q.currentLocation,nextLocation:q.nextLocation})});let V=t.window.document.startViewTransition(()=>{r(()=>i(N))});V.finished.finally(()=>{r(()=>{v(void 0),S(void 0),s(void 0),d({isTransitioning:!1})})}),r(()=>S(V));return}y?(h&&h.resolve(),y.skipTransition(),g({state:N,currentLocation:q.currentLocation,nextLocation:q.nextLocation})):(s(N),d({isTransitioning:!0,flushSync:!1,currentLocation:q.currentLocation,nextLocation:q.nextLocation}))},[t.window,r,y,h]);E.useLayoutEffect(()=>t.subscribe(x),[t,x]),E.useEffect(()=>{f.isTransitioning&&!f.flushSync&&v(new J5)},[f]),E.useEffect(()=>{if(h&&o&&t.window){let N=o,j=h.promise,O=t.window.document.startViewTransition(async()=>{E.startTransition(()=>i(N)),await j});O.finished.finally(()=>{v(void 0),S(void 0),s(void 0),d({isTransitioning:!1})}),S(O)}},[o,h,t.window]),E.useEffect(()=>{h&&o&&a.location.key===o.location.key&&h.resolve()},[h,y,a.location,o]),E.useEffect(()=>{!f.isTransitioning&&p&&(s(p.state),d({isTransitioning:!0,flushSync:!1,currentLocation:p.currentLocation,nextLocation:p.nextLocation}),g(void 0))},[f.isTransitioning,p]);let R=E.useMemo(()=>({createHref:t.createHref,encodeLocation:t.encodeLocation,go:N=>t.navigate(N),push:(N,j,O)=>t.navigate(N,{state:j,preventScrollReset:O==null?void 0:O.preventScrollReset}),replace:(N,j,O)=>t.navigate(N,{replace:!0,state:j,preventScrollReset:O==null?void 0:O.preventScrollReset})}),[t]),T=t.basename||"/",A=E.useMemo(()=>({router:t,navigator:R,static:!1,basename:T}),[t,R,T]);return E.createElement(E.Fragment,null,E.createElement(el.Provider,{value:A},E.createElement(Vo.Provider,{value:a},E.createElement(l2.Provider,{value:w.current},E.createElement(Kv.Provider,{value:f},E.createElement(r3,{basename:T,location:a.location,navigationType:a.historyAction,navigator:R},E.createElement(e3,{routes:t.routes,future:t.future,state:a})))))),null)}var e3=E.memo(t3);function t3({routes:t,future:r,state:a}){return c2(t,void 0,a,r)}function n3(t){return B5(t.context)}function Cc(t){qe(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function r3({basename:t="/",children:r=null,location:a,navigationType:i="POP",navigator:o,static:s=!1}){qe(!Qo(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let f=t.replace(/^\/*/,"/"),d=E.useMemo(()=>({basename:f,navigator:o,static:s,future:{}}),[f,o,s]);typeof a=="string"&&(a=Ea(a));let{pathname:h="/",search:v="",hash:y="",state:S=null,key:p="default"}=a,g=E.useMemo(()=>{let w=Sr(h,f);return w==null?null:{location:{pathname:w,search:v,hash:y,state:S,key:p},navigationType:i}},[f,h,v,y,S,p,i]);return It(g!=null,`<Router basename="${f}"> is not able to match the URL "${h}${v}${y}" because it does not start with the basename, so the <Router> won't render anything.`),g==null?null:E.createElement(kr.Provider,{value:d},E.createElement(Yo.Provider,{children:r,value:g}))}function a3({children:t,location:r}){return P5(Pm(t),r)}function Pm(t,r=[]){let a=[];return E.Children.forEach(t,(i,o)=>{if(!E.isValidElement(i))return;let s=[...r,o];if(i.type===E.Fragment){a.push.apply(a,Pm(i.props.children,s));return}qe(i.type===Cc,`[${typeof i.type=="string"?i.type:i.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),qe(!i.props.index||!i.props.children,"An index route cannot have child routes.");let f={id:i.props.id||s.join("-"),caseSensitive:i.props.caseSensitive,element:i.props.element,Component:i.props.Component,index:i.props.index,path:i.props.path,loader:i.props.loader,action:i.props.action,hydrateFallbackElement:i.props.hydrateFallbackElement,HydrateFallback:i.props.HydrateFallback,errorElement:i.props.errorElement,ErrorBoundary:i.props.ErrorBoundary,hasErrorBoundary:i.props.hasErrorBoundary===!0||i.props.ErrorBoundary!=null||i.props.errorElement!=null,shouldRevalidate:i.props.shouldRevalidate,handle:i.props.handle,lazy:i.props.lazy};i.props.children&&(f.children=Pm(i.props.children,s)),a.push(f)}),a}var Tc="get",Rc="application/x-www-form-urlencoded";function gf(t){return t!=null&&typeof t.tagName=="string"}function i3(t){return gf(t)&&t.tagName.toLowerCase()==="button"}function l3(t){return gf(t)&&t.tagName.toLowerCase()==="form"}function u3(t){return gf(t)&&t.tagName.toLowerCase()==="input"}function o3(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function s3(t,r){return t.button===0&&(!r||r==="_self")&&!o3(t)}var yc=null;function c3(){if(yc===null)try{new FormData(document.createElement("form"),0),yc=!1}catch{yc=!0}return yc}var f3=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function rm(t){return t!=null&&!f3.has(t)?(It(!1,`"${t}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Rc}"`),null):t}function d3(t,r){let a,i,o,s,f;if(l3(t)){let d=t.getAttribute("action");i=d?Sr(d,r):null,a=t.getAttribute("method")||Tc,o=rm(t.getAttribute("enctype"))||Rc,s=new FormData(t)}else if(i3(t)||u3(t)&&(t.type==="submit"||t.type==="image")){let d=t.form;if(d==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let h=t.getAttribute("formaction")||d.getAttribute("action");if(i=h?Sr(h,r):null,a=t.getAttribute("formmethod")||d.getAttribute("method")||Tc,o=rm(t.getAttribute("formenctype"))||rm(d.getAttribute("enctype"))||Rc,s=new FormData(d,t),!c3()){let{name:v,type:y,value:S}=t;if(y==="image"){let p=v?`${v}.`:"";s.append(`${p}x`,"0"),s.append(`${p}y`,"0")}else v&&s.append(v,S)}}else{if(gf(t))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');a=Tc,i=null,o=Rc,f=t}return s&&o==="text/plain"&&(f=s,s=void 0),{action:i,method:a.toLowerCase(),encType:o,formData:s,body:f}}function Jv(t,r){if(t===!1||t===null||typeof t>"u")throw new Error(r)}async function h3(t,r){if(t.id in r)return r[t.id];try{let a=await import(t.module);return r[t.id]=a,a}catch(a){return console.error(`Error loading route module \`${t.module}\`, reloading page...`),console.error(a),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function m3(t){return t==null?!1:t.href==null?t.rel==="preload"&&typeof t.imageSrcSet=="string"&&typeof t.imageSizes=="string":typeof t.rel=="string"&&typeof t.href=="string"}async function v3(t,r,a){let i=await Promise.all(t.map(async o=>{let s=r.routes[o.route.id];if(s){let f=await h3(s,a);return f.links?f.links():[]}return[]}));return b3(i.flat(1).filter(m3).filter(o=>o.rel==="stylesheet"||o.rel==="preload").map(o=>o.rel==="stylesheet"?{...o,rel:"prefetch",as:"style"}:{...o,rel:"prefetch"}))}function o1(t,r,a,i,o,s){let f=(h,v)=>a[v]?h.route.id!==a[v].route.id:!0,d=(h,v)=>{var y;return a[v].pathname!==h.pathname||((y=a[v].route.path)==null?void 0:y.endsWith("*"))&&a[v].params["*"]!==h.params["*"]};return s==="assets"?r.filter((h,v)=>f(h,v)||d(h,v)):s==="data"?r.filter((h,v)=>{var S;let y=i.routes[h.route.id];if(!y||!y.hasLoader)return!1;if(f(h,v)||d(h,v))return!0;if(h.route.shouldRevalidate){let p=h.route.shouldRevalidate({currentUrl:new URL(o.pathname+o.search+o.hash,window.origin),currentParams:((S=a[0])==null?void 0:S.params)||{},nextUrl:new URL(t,window.origin),nextParams:h.params,defaultShouldRevalidate:!0});if(typeof p=="boolean")return p}return!0}):[]}function p3(t,r){return y3(t.map(a=>{let i=r.routes[a.route.id];if(!i)return[];let o=[i.module];return i.imports&&(o=o.concat(i.imports)),o}).flat(1))}function y3(t){return[...new Set(t)]}function g3(t){let r={},a=Object.keys(t).sort();for(let i of a)r[i]=t[i];return r}function b3(t,r){let a=new Set;return new Set(r),t.reduce((i,o)=>{let s=JSON.stringify(g3(o));return a.has(s)||(a.add(s),i.push({key:s,link:o})),i},[])}function S3(t){let r=typeof t=="string"?new URL(t,typeof window>"u"?"server://singlefetch/":window.location.origin):t;return r.pathname==="/"?r.pathname="_root.data":r.pathname=`${r.pathname.replace(/\/$/,"")}.data`,r}function x3(){let t=E.useContext(el);return Jv(t,"You must render this element inside a <DataRouterContext.Provider> element"),t}function E3(){let t=E.useContext(Vo);return Jv(t,"You must render this element inside a <DataRouterStateContext.Provider> element"),t}var Wv=E.createContext(void 0);Wv.displayName="FrameworkContext";function h2(){let t=E.useContext(Wv);return Jv(t,"You must render this element inside a <HydratedRouter> element"),t}function w3(t,r){let a=E.useContext(Wv),[i,o]=E.useState(!1),[s,f]=E.useState(!1),{onFocus:d,onBlur:h,onMouseEnter:v,onMouseLeave:y,onTouchStart:S}=r,p=E.useRef(null);E.useEffect(()=>{if(t==="render"&&f(!0),t==="viewport"){let x=T=>{T.forEach(A=>{f(A.isIntersecting)})},R=new IntersectionObserver(x,{threshold:.5});return p.current&&R.observe(p.current),()=>{R.disconnect()}}},[t]),E.useEffect(()=>{if(i){let x=setTimeout(()=>{f(!0)},100);return()=>{clearTimeout(x)}}},[i]);let g=()=>{o(!0)},w=()=>{o(!1),f(!1)};return a?t!=="intent"?[s,p,{}]:[s,p,{onFocus:po(d,g),onBlur:po(h,w),onMouseEnter:po(v,g),onMouseLeave:po(y,w),onTouchStart:po(S,g)}]:[!1,p,{}]}function po(t,r){return a=>{t&&t(a),a.defaultPrevented||r(a)}}function O3({page:t,...r}){let{router:a}=x3(),i=E.useMemo(()=>Ja(a.routes,t,a.basename),[a.routes,t,a.basename]);return i?E.createElement(T3,{page:t,matches:i,...r}):(console.warn(`Tried to prefetch ${t} but no routes matched.`),null)}function C3(t){let{manifest:r,routeModules:a}=h2(),[i,o]=E.useState([]);return E.useEffect(()=>{let s=!1;return v3(t,r,a).then(f=>{s||o(f)}),()=>{s=!0}},[t,r,a]),i}function T3({page:t,matches:r,...a}){let i=tl(),{manifest:o,routeModules:s}=h2(),{loaderData:f,matches:d}=E3(),h=E.useMemo(()=>o1(t,r,d,o,i,"data"),[t,r,d,o,i]),v=E.useMemo(()=>o1(t,r,d,o,i,"assets"),[t,r,d,o,i]),y=E.useMemo(()=>{if(t===i.pathname+i.search+i.hash)return[];let g=new Set,w=!1;if(r.forEach(R=>{var A;let T=o.routes[R.route.id];!T||!T.hasLoader||(!h.some(N=>N.route.id===R.route.id)&&R.route.id in f&&((A=s[R.route.id])!=null&&A.shouldRevalidate)||T.hasClientLoader?w=!0:g.add(R.route.id))}),g.size===0)return[];let x=S3(t);return w&&g.size>0&&x.searchParams.set("_routes",r.filter(R=>g.has(R.route.id)).map(R=>R.route.id).join(",")),[x.pathname+x.search]},[f,i,o,h,r,t,s]),S=E.useMemo(()=>p3(v,o),[v,o]),p=C3(v);return E.createElement(E.Fragment,null,y.map(g=>E.createElement("link",{key:g,rel:"prefetch",as:"fetch",href:g,...a})),S.map(g=>E.createElement("link",{key:g,rel:"modulepreload",href:g,...a})),p.map(({key:g,link:w})=>E.createElement("link",{key:g,...w})))}function R3(...t){return r=>{t.forEach(a=>{typeof a=="function"?a(r):a!=null&&(a.current=r)})}}var m2=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{m2&&(window.__reactRouterVersion="7.0.2")}catch{}function D3(t,r){return p5({basename:r==null?void 0:r.basename,future:r==null?void 0:r.future,history:P4({window:r==null?void 0:r.window}),hydrationData:(r==null?void 0:r.hydrationData)||A3(),routes:t,mapRouteProperties:I5,dataStrategy:r==null?void 0:r.dataStrategy,patchRoutesOnNavigation:r==null?void 0:r.patchRoutesOnNavigation,window:r==null?void 0:r.window}).initialize()}function A3(){let t=window==null?void 0:window.__staticRouterHydrationData;return t&&t.errors&&(t={...t,errors:M3(t.errors)}),t}function M3(t){if(!t)return null;let r=Object.entries(t),a={};for(let[i,o]of r)if(o&&o.__type==="RouteErrorResponse")a[i]=new Qc(o.status,o.statusText,o.data,o.internal===!0);else if(o&&o.__type==="Error"){if(o.__subType){let s=window[o.__subType];if(typeof s=="function")try{let f=new s(o.message);f.stack="",a[i]=f}catch{}}if(a[i]==null){let s=new Error(o.message);s.stack="",a[i]=s}}else a[i]=o;return a}var v2=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,au=E.forwardRef(function({onClick:r,discover:a="render",prefetch:i="none",relative:o,reloadDocument:s,replace:f,state:d,target:h,to:v,preventScrollReset:y,viewTransition:S,...p},g){let{basename:w}=E.useContext(kr),x=typeof v=="string"&&v2.test(v),R,T=!1;if(typeof v=="string"&&x&&(R=v,m2))try{let z=new URL(window.location.href),X=v.startsWith("//")?new URL(z.protocol+v):new URL(v),te=Sr(X.pathname,w);X.origin===z.origin&&te!=null?v=te+X.search+X.hash:T=!0}catch{It(!1,`<Link to="${v}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}let A=H5(v,{relative:o}),[N,j,O]=w3(i,p),q=N3(v,{replace:f,state:d,target:h,preventScrollReset:y,relative:o,viewTransition:S});function B(z){r&&r(z),z.defaultPrevented||q(z)}let V=E.createElement("a",{...p,...O,href:R||A,onClick:T||s?r:B,ref:R3(g,j),target:h,"data-discover":!x&&a==="render"?"true":void 0});return N&&!x?E.createElement(E.Fragment,null,V,E.createElement(O3,{page:A})):V});au.displayName="Link";var p2=E.forwardRef(function({"aria-current":r="page",caseSensitive:a=!1,className:i="",end:o=!1,style:s,to:f,viewTransition:d,children:h,...v},y){let S=Ko(f,{relative:v.relative}),p=tl(),g=E.useContext(Vo),{navigator:w,basename:x}=E.useContext(kr),R=g!=null&&$3(S)&&d===!0,T=w.encodeLocation?w.encodeLocation(S).pathname:S.pathname,A=p.pathname,N=g&&g.navigation&&g.navigation.location?g.navigation.location.pathname:null;a||(A=A.toLowerCase(),N=N?N.toLowerCase():null,T=T.toLowerCase()),N&&x&&(N=Sr(N,x)||N);const j=T!=="/"&&T.endsWith("/")?T.length-1:T.length;let O=A===T||!o&&A.startsWith(T)&&A.charAt(j)==="/",q=N!=null&&(N===T||!o&&N.startsWith(T)&&N.charAt(T.length)==="/"),B={isActive:O,isPending:q,isTransitioning:R},V=O?r:void 0,z;typeof i=="function"?z=i(B):z=[i,O?"active":null,q?"pending":null,R?"transitioning":null].filter(Boolean).join(" ");let X=typeof s=="function"?s(B):s;return E.createElement(au,{...v,"aria-current":V,className:z,ref:y,style:X,to:f,viewTransition:d},typeof h=="function"?h(B):h)});p2.displayName="NavLink";var j3=E.forwardRef(({discover:t="render",fetcherKey:r,navigate:a,reloadDocument:i,replace:o,state:s,method:f=Tc,action:d,onSubmit:h,relative:v,preventScrollReset:y,viewTransition:S,...p},g)=>{let w=H3(),x=U3(d,{relative:v}),R=f.toLowerCase()==="get"?"get":"post",T=typeof d=="string"&&v2.test(d),A=N=>{if(h&&h(N),N.defaultPrevented)return;N.preventDefault();let j=N.nativeEvent.submitter,O=(j==null?void 0:j.getAttribute("formmethod"))||f;w(j||N.currentTarget,{fetcherKey:r,method:O,navigate:a,replace:o,state:s,relative:v,preventScrollReset:y,viewTransition:S})};return E.createElement("form",{ref:g,method:R,action:x,onSubmit:i?h:A,...p,"data-discover":!T&&t==="render"?"true":void 0})});j3.displayName="Form";function _3(t){return`${t} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function y2(t){let r=E.useContext(el);return qe(r,_3(t)),r}function N3(t,{target:r,replace:a,state:i,preventScrollReset:o,relative:s,viewTransition:f}={}){let d=Xv(),h=tl(),v=Ko(t,{relative:s});return E.useCallback(y=>{if(s3(y,r)){y.preventDefault();let S=a!==void 0?a:pi(h)===pi(v);d(t,{replace:S,state:i,preventScrollReset:o,relative:s,viewTransition:f})}},[h,d,v,a,i,r,t,o,s,f])}var z3=0,L3=()=>`__${String(++z3)}__`;function H3(){let{router:t}=y2("useSubmit"),{basename:r}=E.useContext(kr),a=X5();return E.useCallback(async(i,o={})=>{let{action:s,method:f,encType:d,formData:h,body:v}=d3(i,r);if(o.navigate===!1){let y=o.fetcherKey||L3();await t.fetch(y,a,o.action||s,{preventScrollReset:o.preventScrollReset,formData:h,body:v,formMethod:o.method||f,formEncType:o.encType||d,flushSync:o.flushSync})}else await t.navigate(o.action||s,{preventScrollReset:o.preventScrollReset,formData:h,body:v,formMethod:o.method||f,formEncType:o.encType||d,replace:o.replace,state:o.state,fromRouteId:a,flushSync:o.flushSync,viewTransition:o.viewTransition})},[t,r,a])}function U3(t,{relative:r}={}){let{basename:a}=E.useContext(kr),i=E.useContext(xr);qe(i,"useFormAction must be used inside a RouteContext");let[o]=i.matches.slice(-1),s={...Ko(t||".",{relative:r})},f=tl();if(t==null){s.search=f.search;let d=new URLSearchParams(s.search),h=d.getAll("index");if(h.some(y=>y==="")){d.delete("index"),h.filter(S=>S).forEach(S=>d.append("index",S));let y=d.toString();s.search=y?`?${y}`:""}}return(!t||t===".")&&o.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),a!=="/"&&(s.pathname=s.pathname==="/"?a:Hr([a,s.pathname])),pi(s)}function $3(t,r={}){let a=E.useContext(Kv);qe(a!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:i}=y2("useViewTransitionState"),o=Ko(t,{relative:r.relative});if(!a.isTransitioning)return!1;let s=Sr(a.currentLocation.pathname,i)||a.currentLocation.pathname,f=Sr(a.nextLocation.pathname,i)||a.nextLocation.pathname;return Yc(o.pathname,f)!=null||Yc(o.pathname,s)!=null}new TextEncoder;const B3=["number","string","datetime","date","format-string","yes-no","boolean","json"];var w1;const nl=TM({getRootUrl:()=>{var t;return`/${(t=document.querySelector('meta[name="x-basename"]'))==null?void 0:t.getAttribute("content")}/api`},headers:{"X-CSRF-Token":((w1=document.querySelector('meta[name="csrf-token"]'))==null?void 0:w1.getAttribute("content"))??""}});async function P3(){return nl("/tables")}async function q3(t,r,a,i,o){const s=new URLSearchParams;for(const f of r)s.append("order",f);return s.append("limit",a.toString()),s.append("page",i.toString()),o&&s.append("search",o),nl(`/tables/${t}?${s.toString()}`)}async function k3(t,r){return nl(`/tables/${t}/${r}`)}async function F3(t,r){return nl(`/tables/${t}/${r}`,{method:"DELETE"})}async function V3(t,r){return nl(`/tables/${t}`,{method:"POST",body:JSON.stringify(r)})}async function Y3(t,r,a){return nl(`/tables/${t}/${r}`,{method:"PUT",body:JSON.stringify(a)})}async function Q3(t,r){return nl(`/tables/${t}/suggestions/${r}`)}function ep(){return kv({queryKey:["database"],queryFn:async()=>{var i,o;const t=await P3(),r=[],a={};for(const s of((i=t.jsonData)==null?void 0:i.tables)??[])r.push(s.tableName),a[s.tableName]=s;return{tableIds:r,tables:a,rowCounts:((o=t.jsonData)==null?void 0:o.rowCounts)??{}}}})}function K3(t,{order:r,limit:a,page:i,search:o}){return kv({queryKey:["tables",t,{order:r,limit:a,page:i,search:o}],queryFn:()=>q3(t,r,a,i,o).then(s=>s.jsonData)})}function G3(t){const r=pf();return Zx({mutationFn:async({pk:a,data:i})=>a==null?V3(t,i):Y3(t,a,i),onSuccess:()=>{r.invalidateQueries({queryKey:["tables",t]})}})}function X3(t){const r=pf();return Zx({mutationFn:a=>F3(t,a),onSuccess:()=>{r.invalidateQueries({queryKey:["tables",t]})}})}function Z3(t,r){return kv({queryKey:["tables",t,"rows",r],queryFn:()=>r==null?{}:k3(t,r).then(a=>a.jsonData)})}function I3(t,r){return N4({queryKey:["foreign-key-options",t,r],queryFn:()=>Q3(t,r).then(a=>a.jsonData)})}const J3=t=>t.name?String(t.name):t.title?String(t.title):t.slug?String(t.slug):JSON.stringify(t);function W3(t){var f;const r=(f=t.schema.$bitiforms)==null?void 0:f.widgetProps,{foreignTable:a,foreignColumn:i}=r||{},{data:o=[]}=I3(a,i),s=(t.value||"").toString();return console.log({options:o,stringValue:s}),D.jsx(Dx,{label:t.schema.title,hint:t.schema.description,value:s,onChange:d=>{t.onChange({target:{name:t.name,value:Number(d.target.value)}})},children:o.map(d=>D.jsxs("option",{value:String(d.id),children:[String(d.id),": ",J3(d)]},String(d.id)))})}const s1=t=>{let r;const a=new Set,i=(v,y)=>{const S=typeof v=="function"?v(r):v;if(!Object.is(S,r)){const p=r;r=y??(typeof S!="object"||S===null)?S:Object.assign({},r,S),a.forEach(g=>g(r,p))}},o=()=>r,d={setState:i,getState:o,getInitialState:()=>h,subscribe:v=>(a.add(v),()=>a.delete(v))},h=r=t(i,o,d);return d},e6=t=>t?s1(t):s1,t6=t=>t;function g2(t,r=t6){const a=Nr.useSyncExternalStore(t.subscribe,()=>r(t.getState()),()=>r(t.getInitialState()));return Nr.useDebugValue(a),a}const c1={BASE_URL:"/%7B%7B%20basename%20%7D%7D",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_PORT:"5190"},qm=new Map,gc=t=>{const r=qm.get(t);return r?Object.fromEntries(Object.entries(r.stores).map(([a,i])=>[a,i.getState()])):{}},n6=(t,r,a)=>{if(t===void 0)return{type:"untracked",connection:r.connect(a)};const i=qm.get(a.name);if(i)return{type:"tracked",store:t,...i};const o={connection:r.connect(a),stores:{}};return qm.set(a.name,o),{type:"tracked",store:t,...o}},r6=(t,r={})=>(a,i,o)=>{const{enabled:s,anonymousActionType:f,store:d,...h}=r;let v;try{v=(s??(c1?"production":void 0)!=="production")&&window.__REDUX_DEVTOOLS_EXTENSION__}catch{}if(!v)return t(a,i,o);const{connection:y,...S}=n6(d,v,h);let p=!0;o.setState=(x,R,T)=>{const A=a(x,R);if(!p)return A;const N=T===void 0?{type:f||"anonymous"}:typeof T=="string"?{type:T}:T;return d===void 0?(y==null||y.send(N,i()),A):(y==null||y.send({...N,type:`${d}/${N.type}`},{...gc(h.name),[d]:o.getState()}),A)};const g=(...x)=>{const R=p;p=!1,a(...x),p=R},w=t(o.setState,i,o);if(S.type==="untracked"?y==null||y.init(w):(S.stores[S.store]=o,y==null||y.init(Object.fromEntries(Object.entries(S.stores).map(([x,R])=>[x,x===S.store?w:R.getState()])))),o.dispatchFromDevtools&&typeof o.dispatch=="function"){let x=!1;const R=o.dispatch;o.dispatch=(...T)=>{(c1?"production":void 0)!=="production"&&T[0].type==="__setState"&&!x&&(console.warn('[zustand devtools middleware] "__setState" action type is reserved to set state from the devtools. Avoid using it.'),x=!0),R(...T)}}return y.subscribe(x=>{var R;switch(x.type){case"ACTION":if(typeof x.payload!="string"){console.error("[zustand devtools middleware] Unsupported action format");return}return am(x.payload,T=>{if(T.type==="__setState"){if(d===void 0){g(T.state);return}Object.keys(T.state).length!==1&&console.error(`
75
- [zustand devtools middleware] Unsupported __setState action format.
76
- When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),
77
- and value of this only key should be a state object. Example: { "type": "__setState", "state": { "abc123Store": { "foo": "bar" } } }
78
- `);const A=T.state[d];if(A==null)return;JSON.stringify(o.getState())!==JSON.stringify(A)&&g(A);return}o.dispatchFromDevtools&&typeof o.dispatch=="function"&&o.dispatch(T)});case"DISPATCH":switch(x.payload.type){case"RESET":return g(w),d===void 0?y==null?void 0:y.init(o.getState()):y==null?void 0:y.init(gc(h.name));case"COMMIT":if(d===void 0){y==null||y.init(o.getState());return}return y==null?void 0:y.init(gc(h.name));case"ROLLBACK":return am(x.state,T=>{if(d===void 0){g(T),y==null||y.init(o.getState());return}g(T[d]),y==null||y.init(gc(h.name))});case"JUMP_TO_STATE":case"JUMP_TO_ACTION":return am(x.state,T=>{if(d===void 0){g(T);return}JSON.stringify(o.getState())!==JSON.stringify(T[d])&&g(T[d])});case"IMPORT_STATE":{const{nextLiftedState:T}=x.payload,A=(R=T.computedStates.slice(-1)[0])==null?void 0:R.state;if(!A)return;g(d===void 0?A:A[d]),y==null||y.send(null,T);return}case"PAUSE_RECORDING":return p=!p}return}}),w},a6=r6,am=(t,r)=>{let a;try{a=JSON.parse(t)}catch(i){console.error("[zustand devtools middleware] Could not parse the received json",i)}a!==void 0&&r(a)};function i6(t,r){let a;try{a=t()}catch{return}return{getItem:o=>{var s;const f=h=>h===null?null:JSON.parse(h,void 0),d=(s=a.getItem(o))!=null?s:null;return d instanceof Promise?d.then(f):f(d)},setItem:(o,s)=>a.setItem(o,JSON.stringify(s,void 0)),removeItem:o=>a.removeItem(o)}}const km=t=>r=>{try{const a=t(r);return a instanceof Promise?a:{then(i){return km(i)(a)},catch(i){return this}}}catch(a){return{then(i){return this},catch(i){return km(i)(a)}}}},l6=(t,r)=>(a,i,o)=>{let s={storage:i6(()=>localStorage),partialize:x=>x,version:0,merge:(x,R)=>({...R,...x}),...r},f=!1;const d=new Set,h=new Set;let v=s.storage;if(!v)return t((...x)=>{console.warn(`[zustand persist middleware] Unable to update item '${s.name}', the given storage is currently unavailable.`),a(...x)},i,o);const y=()=>{const x=s.partialize({...i()});return v.setItem(s.name,{state:x,version:s.version})},S=o.setState;o.setState=(x,R)=>{S(x,R),y()};const p=t((...x)=>{a(...x),y()},i,o);o.getInitialState=()=>p;let g;const w=()=>{var x,R;if(!v)return;f=!1,d.forEach(A=>{var N;return A((N=i())!=null?N:p)});const T=((R=s.onRehydrateStorage)==null?void 0:R.call(s,(x=i())!=null?x:p))||void 0;return km(v.getItem.bind(v))(s.name).then(A=>{if(A)if(typeof A.version=="number"&&A.version!==s.version){if(s.migrate){const N=s.migrate(A.state,A.version);return N instanceof Promise?N.then(j=>[!0,j]):[!0,N]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,A.state];return[!1,void 0]}).then(A=>{var N;const[j,O]=A;if(g=s.merge(O,(N=i())!=null?N:p),a(g,!0),j)return y()}).then(()=>{T==null||T(g,void 0),g=i(),f=!0,h.forEach(A=>A(g))}).catch(A=>{T==null||T(void 0,A)})};return o.persist={setOptions:x=>{s={...s,...x},x.storage&&(v=x.storage)},clearStorage:()=>{v==null||v.removeItem(s.name)},getOptions:()=>s,rehydrate:()=>w(),hasHydrated:()=>f,onHydrate:x=>(d.add(x),()=>{d.delete(x)}),onFinishHydration:x=>(h.add(x),()=>{h.delete(x)})},s.skipHydration||w(),g||p},u6=l6,o6={displayName:"",columns:{},sortBy:[],page:1,limit:10,search:""};function s6(t){return e6(a6(u6(r=>({config:Object.fromEntries(Object.values(t.tables).map(a=>[a.tableName,{...o6,displayName:a.tableName,columns:Object.fromEntries(a.columnNames.concat(a.relatedColumnNames).map(i=>{var o;return[i,{displayName:i,displayType:((o=a.columnMetadata[i])==null?void 0:o.displayType)??"string",valueTemplate:void 0,visible:!0}]}))}])),setConfig:(a,i)=>{r(o=>({config:{...o.config,[a]:{...o.config[a],...i}}}))}}),{name:`tableConfig:${btoa(t.tableIds.join(","))}`})))}const b2=E.createContext(null);function c6({children:t,database:r}){const[a]=E.useState(()=>s6(r));return D.jsx(b2.Provider,{value:a,children:t})}const S2=()=>{const t=E.useContext(b2);if(t==null)throw new Error("useTableConfig must be used within a StoreProvider");return t},x2=()=>{const t=S2();return g2(t,r=>r.config)},tp=()=>{const t=S2();return g2(t,r=>r.setConfig)};function f6(){const{data:t}=ep();return D.jsx("div",{className:"sidebar-menu",children:D.jsx("ul",{children:(t.tableIds||[]).map(r=>D.jsx("li",{children:D.jsx(iM,{as:p2,to:r,children:r})},r))})})}function d6(){var r;const{data:t}=ep();return D.jsx(c6,{database:t,children:D.jsx(rM,{headerHeight:"64px",header:D.jsx(aM,{style:{"--header-color":"var(--colors-white)","--header-background":"#2a2f3b",color:"var(--colors-white)"},logo:D.jsx("span",{className:"logo",children:(r=document.querySelector('meta[name="x-title"]'))==null?void 0:r.getAttribute("content")}),children:null}),sidebar:D.jsx(f6,{}),children:D.jsx(n3,{})})})}function h6(){const t=f2();return D.jsx(Im,{title:"Error",intent:"error",children:t.message})}function m6(){return D.jsx("div",{children:"Welcome!"})}function v6(t){return Jt({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M262.29 192.31a64 64 0 1 0 57.4 57.4 64.13 64.13 0 0 0-57.4-57.4zM416.39 256a154.34 154.34 0 0 1-1.53 20.79l45.21 35.46a10.81 10.81 0 0 1 2.45 13.75l-42.77 74a10.81 10.81 0 0 1-13.14 4.59l-44.9-18.08a16.11 16.11 0 0 0-15.17 1.75A164.48 164.48 0 0 1 325 400.8a15.94 15.94 0 0 0-8.82 12.14l-6.73 47.89a11.08 11.08 0 0 1-10.68 9.17h-85.54a11.11 11.11 0 0 1-10.69-8.87l-6.72-47.82a16.07 16.07 0 0 0-9-12.22 155.3 155.3 0 0 1-21.46-12.57 16 16 0 0 0-15.11-1.71l-44.89 18.07a10.81 10.81 0 0 1-13.14-4.58l-42.77-74a10.8 10.8 0 0 1 2.45-13.75l38.21-30a16.05 16.05 0 0 0 6-14.08c-.36-4.17-.58-8.33-.58-12.5s.21-8.27.58-12.35a16 16 0 0 0-6.07-13.94l-38.19-30A10.81 10.81 0 0 1 49.48 186l42.77-74a10.81 10.81 0 0 1 13.14-4.59l44.9 18.08a16.11 16.11 0 0 0 15.17-1.75A164.48 164.48 0 0 1 187 111.2a15.94 15.94 0 0 0 8.82-12.14l6.73-47.89A11.08 11.08 0 0 1 213.23 42h85.54a11.11 11.11 0 0 1 10.69 8.87l6.72 47.82a16.07 16.07 0 0 0 9 12.22 155.3 155.3 0 0 1 21.46 12.57 16 16 0 0 0 15.11 1.71l44.89-18.07a10.81 10.81 0 0 1 13.14 4.58l42.77 74a10.8 10.8 0 0 1-2.45 13.75l-38.21 30a16.05 16.05 0 0 0-6.05 14.08c.33 4.14.55 8.3.55 12.47z"},child:[]}]})(t)}function E2({onSubmit:t,steps:r,submissionErrors:a,submissionState:i,clearSubmission:o,submitButtonText:s="Submit"}){const f=d=>{d.preventDefault(),t(d)};return D.jsxs(Ur,{as:"form",onSubmit:f,noValidate:!0,children:[i==="failed"&&D.jsx(t4,{errors:a,onClose:o}),r.flatMap(d=>Object.keys(d.fields).map(h=>D.jsx(Gm,{...d.fields[h]},h))),D.jsx(sC,{height:"s"}),s!=null&&D.jsx(ci,{type:"submit",style:{alignSelf:"flex-start"},disabled:i==="submitting",children:i==="submitting"?"Submitting...":s})]})}function f1({table:t}){const{pk:r=null}=s2(),a=Xv(),i=G3(t.tableName),{data:o={},isLoading:s}=Z3(t.tableName,r),f=async({values:h,isValid:v})=>{if(!v)throw new Ac({});await i.mutateAsync({pk:r,data:h}),a("..",{replace:!0})},d=r==null?"Add row":`Edit row ${r}`;return D.jsx(xx,{title:d,isOpen:!0,onDismiss:()=>a("..",{replace:!0}),children:s?D.jsx(hC,{}):D.jsx(B1,{initialValues:o,schema:t.schema,name:t.tableName,component:E2,onSubmit:f})})}function p6({table:t}){const r=Xv(),a=()=>r("..",{replace:!0});return D.jsx(D.Fragment,{children:D.jsx(xx,{title:`UI for ${t.tableName}`,onDismiss:a,children:D.jsx(y6,{table:t,onSubmit:a})})})}function y6({table:t,onSubmit:r}){const a=x2(),i=a[t.tableName],o=tp(),s=E.useMemo(()=>({type:"object",properties:{displayName:{type:"string",title:"Display name"},columns:{type:"object",properties:Object.fromEntries(t.columnNames.concat(t.relatedColumnNames).map(h=>[h,{type:"object",title:`Column ${h}`,properties:{displayName:{type:"string",title:"Display name"},displayType:{type:"string",title:"Display type",enum:[""].concat(Array.from(B3)),$bitiforms:{widget:"SelectWidget"}},visible:{type:"boolean",title:"Visible"}},if:{properties:{displayType:{const:"format-string"}}},then:{type:"object",properties:{valueTemplate:{title:"Value template",type:"string",description:`Use placeholders like {{ ${h} }}`}}}}]))}}}),[t.columnNames,t.relatedColumnNames]),f=E.useCallback(h=>{bc(h,a)||o(t.tableName,h)},[t.tableName,o,a]),d=async({values:h,isValid:v,errors:y})=>{if(console.log(h,y),!v)throw new Ac({});f(h),r()};return i?D.jsx(B1,{initialValues:i,schema:s,onSubmit:d,render:h=>D.jsx(E2,{...h,submitButtonText:"Save"})}):null}function g6(t,r){return t.replace(/\{\{\s*(\w+)\s*\}\}/g,(a,i)=>{if(Object.prototype.hasOwnProperty.call(r,i)){const o=r[i];return o==null?"":String(o)}return a})}const im=t=>D.jsx("pre",{style:{maxWidth:250},children:JSON.stringify(t)});function d1(t,r,a){const i=r[t];switch(a.displayType){case"format-string":return g6(a.valueTemplate||"",r);case"yes-no":return i?"Yes":"No";case"datetime":return typeof i!="string"?im(i):Mg(new Date(i));case"date":return typeof i!="string"?im(i):Mg(new Date(i),{representation:"date"});case"number":return String(i);case"string":return String(i);default:return im(i)}}function b6(t,r,a,i){const o=r[t];if(o===null)return D.jsx(Yg,{style:{opacity:.4},children:"NULL"});const s=a.columnMetadata[t]||void 0,f=i[a.tableName].columns[t];if(s&&s.foreignKeys.length>0){const d=s.foreignKeys.at(0),h=o;return D.jsx(au,{to:`/${d==null?void 0:d.table}/edit/${h}`,children:D.jsx(Yg,{children:d1(t,r,f)})})}return d1(t,r,i[a.tableName].columns[t])}const S6=yM({multi:!0});function x6(){const{tableId:t=QO()}=s2(),{data:r}=ep(),a=r==null?void 0:r.tables[t];return D.jsx(E6,{table:a,rowCount:r.rowCounts[t]},t)}function E6({table:t,rowCount:r}){const a=x2(),i=a[t.tableName],o=_M(i.search,500),s=tp(),{sortColumns:f,getThProps:d}=S6(i.sortBy);E.useEffect(()=>{s(t.tableName,{sortBy:f})},[f,t.tableName,s]);const{data:h}=K3(t.tableName,{page:i.page,limit:i.limit,order:f,search:o}),v=Object.keys(i.columns).filter(y=>i.columns[y].visible);return t?D.jsxs("main",{"data-detail-view":!0,children:[D.jsxs(Ur,{horizontal:!0,justifyContent:"space-between",children:[D.jsxs(Ur,{horizontal:!0,className:"dmk-margin-bottom-l",spacing:"xs",children:[D.jsxs("div",{children:[D.jsx("h1",{className:"dmk-text-title2",children:i.displayName}),D.jsxs("div",{className:"dmk-text-subhead dmk-text-muted dmk-margin-top-s",children:[r," rows"]})]}),D.jsx(ci,{as:au,to:"config",variant:"text",size:"s",children:D.jsx(v6,{className:"dmk-margin-right-xs"})})]}),D.jsxs(ci,{as:au,to:"new",variant:"outlined",size:"s",children:[D.jsx(NO,{className:"dmk-margin-right-xs"})," Insert row"]})]}),D.jsx("div",{className:"dmk-margin-bottom-l",children:D.jsx(QA,{value:i.search,onChange:y=>s(t.tableName,{search:y.currentTarget.value})})}),D.jsx(cM,{className:"database-table-browser",children:D.jsx(fM,{renderHeaderRow:()=>D.jsxs("tr",{children:[v.map(y=>D.jsx("th",{...d(y,i.columns[y].displayName)},y)),D.jsx("th",{style:{width:200}})]}),renderRow:y=>D.jsx(O6,{table:t,row:y,visibleColumns:v,tableConfig:a},String(y.id)),items:h})}),D.jsx(w6,{limit:i.limit,page:i.page,total:r,table:t})]}):null}const w6=E.memo(function({limit:r,page:a,total:i,table:o}){const s=tp();return D.jsxs(D.Fragment,{children:[D.jsx("div",{className:"dmk-margin-top-l",children:D.jsx(hM,{limit:r,onLimitChange:f=>s(o.tableName,{limit:f}),page:a,onPageChange:f=>s(o.tableName,{page:f}),total:i,limits:[10,50,100,500]})}),D.jsxs(a3,{children:[D.jsx(Cc,{path:"new",element:D.jsx(f1,{table:o})}),D.jsx(Cc,{path:"config",element:D.jsx(p6,{table:o})}),D.jsx(Cc,{path:"edit/:pk",element:D.jsx(f1,{table:o})})]})]})}),O6=E.memo(function({table:r,tableConfig:a,row:i,visibleColumns:o}){const s=X3(r.tableName),f=Hv(),d=()=>{f.value?s.mutate(String(i.id)):(f.enable(),setTimeout(()=>f.disable(),3e3))};return D.jsxs("tr",{children:[o.map(h=>D.jsx("td",{children:b6(h,i,r,a)},h)),D.jsxs("td",{children:[D.jsx(ci,{as:au,size:"s",variant:"text",to:`edit/${i.id}`,children:"Edit"}),D.jsx(ci,{size:"s",variant:"text",intent:"danger",disabled:s.isPending,onClick:d,children:f.value?"Sure?":"Delete"})]})]},String(i.id))});var O1;const C6=D3([{path:"/",element:D.jsx(d6,{}),children:[{path:":tableId/*",element:D.jsx(x6,{}),errorElement:D.jsx(h6,{})},{index:!0,element:D.jsx(m6,{})}]}],{basename:`/${((O1=document.querySelector('meta[name="x-basename"]'))==null?void 0:O1.getAttribute("content"))??""}`}),T6=Z1({colors:{primary:"#2a2f3b"}}),R6=new y4({defaultOptions:{queries:{retry:!1,refetchOnWindowFocus:!1}}}),D6={...n4,ForeignKeyWidget:W3};$4.createRoot(document.getElementById("root")).render(D.jsx(E.StrictMode,{children:D.jsx(Ex,{children:D.jsx(aO,{widgets:D6,children:D.jsx(x4,{client:R6,children:D.jsx(nC,{theme:T6,children:D.jsx(W5,{router:C6})})})})})}));