@inertiaui/modal-react 0.1.4 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/inertiaui-modal.js +2703 -4279
- package/dist/inertiaui-modal.umd.cjs +17 -22
- package/package.json +4 -3
- package/src/HeadlessModal.jsx +15 -5
- package/src/Modal.jsx +34 -7
- package/src/ModalLink.jsx +11 -20
- package/src/ModalRenderer.jsx +12 -12
- package/src/ModalRoot.jsx +286 -76
- package/src/helpers.js +2 -36
- package/src/inertiauiModal.js +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(W,
|
|
1
|
+
(function(W,f){typeof exports=="object"&&typeof module<"u"?f(exports,require("react"),require("axios"),require("@inertiajs/react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","axios","@inertiajs/react","react-dom"],f):(W=typeof globalThis<"u"?globalThis:W||self,f(W.InertiaUIModal={},W.React,W.Axios,W.react,W.ReactDOM))})(this,function(W,f,me,tt,Jo){"use strict";var rc=Object.defineProperty;var nc=(W,f,me)=>f in W?rc(W,f,{enumerable:!0,configurable:!0,writable:!0,value:me}):W[f]=me;var ce=(W,f,me)=>nc(W,typeof f!="symbol"?f+"":f,me);function Qo(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const r in t)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,n.get?n:{enumerable:!0,get:()=>t[r]})}}return e.default=t,Object.freeze(e)}const rt=Qo(f),Et={type:"modal",navigate:!1,modal:{closeButton:!0,closeExplicitly:!1,maxWidth:"2xl",paddingClasses:"p-4 sm:p-6",panelClasses:"bg-white rounded",position:"center"},slideover:{closeButton:!0,closeExplicitly:!1,maxWidth:"md",paddingClasses:"p-4 sm:p-6",panelClasses:"bg-white min-h-screen",position:"right"}};class Zo{constructor(){this.config={},this.reset()}reset(){this.config=JSON.parse(JSON.stringify(Et))}put(e,r){if(typeof e=="object"){this.config={type:e.type??Et.type,modal:{...Et.modal,...e.modal??{}},slideover:{...Et.slideover,...e.slideover??{}}};return}const n=e.split(".");let o=this.config;for(let i=0;i<n.length-1;i++)o=o[n[i]]=o[n[i]]||{};o[n[n.length-1]]=r}get(e){if(typeof e>"u")return this.config;const r=e.split(".");let n=this.config;for(const o of r){if(n[o]===void 0)return null;n=n[o]}return n}}const St=new Zo,ei=()=>St.reset(),ti=(t,e)=>St.put(t,e),Xt=t=>St.get(t),Ue=(t,e)=>St.get(t?`slideover.${e}`:`modal.${e}`);var Jt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ri(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function ni(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var o=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,o.get?o:{enumerable:!0,get:function(){return t[n]}})}),r}var Qt={exports:{}},nt={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var Jr;function oi(){if(Jr)return nt;Jr=1;var t=f,e=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function l(u,a,p){var s,g={},m=null,E=null;p!==void 0&&(m=""+p),a.key!==void 0&&(m=""+a.key),a.ref!==void 0&&(E=a.ref);for(s in a)n.call(a,s)&&!i.hasOwnProperty(s)&&(g[s]=a[s]);if(u&&u.defaultProps)for(s in a=u.defaultProps,a)g[s]===void 0&&(g[s]=a[s]);return{$$typeof:e,type:u,key:m,ref:E,props:g,_owner:o.current}}return nt.Fragment=r,nt.jsx=l,nt.jsxs=l,nt}var ot={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,30 +14,25 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),G=M.length-1,
|
|
21
|
-
`+M[G].replace(" at new "," at ");return
|
|
17
|
+
*/var Qr;function ii(){return Qr||(Qr=1,process.env.NODE_ENV!=="production"&&function(){var t=f,e=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),l=Symbol.for("react.provider"),u=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),p=Symbol.for("react.suspense"),s=Symbol.for("react.suspense_list"),g=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),E=Symbol.for("react.offscreen"),d=Symbol.iterator,v="@@iterator";function y(c){if(c===null||typeof c!="object")return null;var S=d&&c[d]||c[v];return typeof S=="function"?S:null}var h=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function b(c){{for(var S=arguments.length,O=new Array(S>1?S-1:0),A=1;A<S;A++)O[A-1]=arguments[A];w("error",c,O)}}function w(c,S,O){{var A=h.ReactDebugCurrentFrame,N=A.getStackAddendum();N!==""&&(S+="%s",O=O.concat([N]));var L=O.map(function(I){return String(I)});L.unshift("Warning: "+S),Function.prototype.apply.call(console[c],console,L)}}var x=!1,P=!1,D=!1,_=!1,U=!1,H;H=Symbol.for("react.module.reference");function j(c){return!!(typeof c=="string"||typeof c=="function"||c===n||c===i||U||c===o||c===p||c===s||_||c===E||x||P||D||typeof c=="object"&&c!==null&&(c.$$typeof===m||c.$$typeof===g||c.$$typeof===l||c.$$typeof===u||c.$$typeof===a||c.$$typeof===H||c.getModuleId!==void 0))}function z(c,S,O){var A=c.displayName;if(A)return A;var N=S.displayName||S.name||"";return N!==""?O+"("+N+")":O}function V(c){return c.displayName||"Context"}function C(c){if(c==null)return null;if(typeof c.tag=="number"&&b("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case n:return"Fragment";case r:return"Portal";case i:return"Profiler";case o:return"StrictMode";case p:return"Suspense";case s:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case u:var S=c;return V(S)+".Consumer";case l:var O=c;return V(O._context)+".Provider";case a:return z(c,c.render,"ForwardRef");case g:var A=c.displayName||null;return A!==null?A:C(c.type)||"Memo";case m:{var N=c,L=N._payload,I=N._init;try{return C(I(L))}catch{return null}}}return null}var T=Object.assign,k=0,oe,ue,ve,Z,se,q,Ne;function J(){}J.__reactDisabledLog=!0;function Vr(){{if(k===0){oe=console.log,ue=console.info,ve=console.warn,Z=console.error,se=console.group,q=console.groupCollapsed,Ne=console.groupEnd;var c={configurable:!0,enumerable:!0,value:J,writable:!0};Object.defineProperties(console,{info:c,log:c,warn:c,error:c,group:c,groupCollapsed:c,groupEnd:c})}k++}}function je(){{if(k--,k===0){var c={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:T({},c,{value:oe}),info:T({},c,{value:ue}),warn:T({},c,{value:ve}),error:T({},c,{value:Z}),group:T({},c,{value:se}),groupCollapsed:T({},c,{value:q}),groupEnd:T({},c,{value:Ne})})}k<0&&b("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var gt=h.ReactCurrentDispatcher,Le;function be(c,S,O){{if(Le===void 0)try{throw Error()}catch(N){var A=N.stack.trim().match(/\n( *(at )?)/);Le=A&&A[1]||""}return`
|
|
18
|
+
`+Le+c}}var we=!1,zt;{var Ms=typeof WeakMap=="function"?WeakMap:Map;zt=new Ms}function jo(c,S){if(!c||we)return"";{var O=zt.get(c);if(O!==void 0)return O}var A;we=!0;var N=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var L;L=gt.current,gt.current=null,Vr();try{if(S){var I=function(){throw Error()};if(Object.defineProperty(I.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(I,[])}catch(ne){A=ne}Reflect.construct(c,[],I)}else{try{I.call()}catch(ne){A=ne}c.call(I.prototype)}}else{try{throw Error()}catch(ne){A=ne}c()}}catch(ne){if(ne&&A&&typeof ne.stack=="string"){for(var M=ne.stack.split(`
|
|
19
|
+
`),te=A.stack.split(`
|
|
20
|
+
`),G=M.length-1,Y=te.length-1;G>=1&&Y>=0&&M[G]!==te[Y];)Y--;for(;G>=1&&Y>=0;G--,Y--)if(M[G]!==te[Y]){if(G!==1||Y!==1)do if(G--,Y--,Y<0||M[G]!==te[Y]){var ae=`
|
|
21
|
+
`+M[G].replace(" at new "," at ");return c.displayName&&ae.includes("<anonymous>")&&(ae=ae.replace("<anonymous>",c.displayName)),typeof c=="function"&&zt.set(c,ae),ae}while(G>=1&&Y>=0);break}}}finally{we=!1,gt.current=L,je(),Error.prepareStackTrace=N}var et=c?c.displayName||c.name:"",We=et?be(et):"";return typeof c=="function"&&zt.set(c,We),We}function Is(c,S,O){return jo(c,!1)}function _s(c){var S=c.prototype;return!!(S&&S.isReactComponent)}function Yt(c,S,O){if(c==null)return"";if(typeof c=="function")return jo(c,_s(c));if(typeof c=="string")return be(c);switch(c){case p:return be("Suspense");case s:return be("SuspenseList")}if(typeof c=="object")switch(c.$$typeof){case a:return Is(c.render);case g:return Yt(c.type,S,O);case m:{var A=c,N=A._payload,L=A._init;try{return Yt(L(N),S,O)}catch{}}}return""}var bt=Object.prototype.hasOwnProperty,Lo={},Wo=h.ReactDebugCurrentFrame;function Kt(c){if(c){var S=c._owner,O=Yt(c.type,c._source,S?S.type:null);Wo.setExtraStackFrame(O)}else Wo.setExtraStackFrame(null)}function Ds(c,S,O,A,N){{var L=Function.call.bind(bt);for(var I in c)if(L(c,I)){var M=void 0;try{if(typeof c[I]!="function"){var te=Error((A||"React class")+": "+O+" type `"+I+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof c[I]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw te.name="Invariant Violation",te}M=c[I](S,I,A,O,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(G){M=G}M&&!(M instanceof Error)&&(Kt(N),b("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",A||"React class",O,I,typeof M),Kt(null)),M instanceof Error&&!(M.message in Lo)&&(Lo[M.message]=!0,Kt(N),b("Failed %s type: %s",O,M.message),Kt(null))}}}var ks=Array.isArray;function qr(c){return ks(c)}function Ns(c){{var S=typeof Symbol=="function"&&Symbol.toStringTag,O=S&&c[Symbol.toStringTag]||c.constructor.name||"Object";return O}}function js(c){try{return Uo(c),!1}catch{return!0}}function Uo(c){return""+c}function Bo(c){if(js(c))return b("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Ns(c)),Uo(c)}var wt=h.ReactCurrentOwner,Ls={key:!0,ref:!0,__self:!0,__source:!0},Ro,Ho,Gr;Gr={};function Ws(c){if(bt.call(c,"ref")){var S=Object.getOwnPropertyDescriptor(c,"ref").get;if(S&&S.isReactWarning)return!1}return c.ref!==void 0}function Us(c){if(bt.call(c,"key")){var S=Object.getOwnPropertyDescriptor(c,"key").get;if(S&&S.isReactWarning)return!1}return c.key!==void 0}function Bs(c,S){if(typeof c.ref=="string"&&wt.current&&S&&wt.current.stateNode!==S){var O=C(wt.current.type);Gr[O]||(b('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',C(wt.current.type),c.ref),Gr[O]=!0)}}function Rs(c,S){{var O=function(){Ro||(Ro=!0,b("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",S))};O.isReactWarning=!0,Object.defineProperty(c,"key",{get:O,configurable:!0})}}function Hs(c,S){{var O=function(){Ho||(Ho=!0,b("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",S))};O.isReactWarning=!0,Object.defineProperty(c,"ref",{get:O,configurable:!0})}}var Vs=function(c,S,O,A,N,L,I){var M={$$typeof:e,type:c,key:S,ref:O,props:I,_owner:L};return M._store={},Object.defineProperty(M._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(M,"_self",{configurable:!1,enumerable:!1,writable:!1,value:A}),Object.defineProperty(M,"_source",{configurable:!1,enumerable:!1,writable:!1,value:N}),Object.freeze&&(Object.freeze(M.props),Object.freeze(M)),M};function qs(c,S,O,A,N){{var L,I={},M=null,te=null;O!==void 0&&(Bo(O),M=""+O),Us(S)&&(Bo(S.key),M=""+S.key),Ws(S)&&(te=S.ref,Bs(S,N));for(L in S)bt.call(S,L)&&!Ls.hasOwnProperty(L)&&(I[L]=S[L]);if(c&&c.defaultProps){var G=c.defaultProps;for(L in G)I[L]===void 0&&(I[L]=G[L])}if(M||te){var Y=typeof c=="function"?c.displayName||c.name||"Unknown":c;M&&Rs(I,Y),te&&Hs(I,Y)}return Vs(c,M,te,N,A,wt.current,I)}}var zr=h.ReactCurrentOwner,Vo=h.ReactDebugCurrentFrame;function Ze(c){if(c){var S=c._owner,O=Yt(c.type,c._source,S?S.type:null);Vo.setExtraStackFrame(O)}else Vo.setExtraStackFrame(null)}var Yr;Yr=!1;function Kr(c){return typeof c=="object"&&c!==null&&c.$$typeof===e}function qo(){{if(zr.current){var c=C(zr.current.type);if(c)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+c+"`."}return""}}function Gs(c){return""}var Go={};function zs(c){{var S=qo();if(!S){var O=typeof c=="string"?c:c.displayName||c.name;O&&(S=`
|
|
24
24
|
|
|
25
|
-
Check the top-level render call using <`+
|
|
25
|
+
Check the top-level render call using <`+O+">.")}return S}}function zo(c,S){{if(!c._store||c._store.validated||c.key!=null)return;c._store.validated=!0;var O=zs(S);if(Go[O])return;Go[O]=!0;var A="";c&&c._owner&&c._owner!==zr.current&&(A=" It was passed a child from "+C(c._owner.type)+"."),Ze(c),b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',O,A),Ze(null)}}function Yo(c,S){{if(typeof c!="object")return;if(qr(c))for(var O=0;O<c.length;O++){var A=c[O];Kr(A)&&zo(A,S)}else if(Kr(c))c._store&&(c._store.validated=!0);else if(c){var N=y(c);if(typeof N=="function"&&N!==c.entries)for(var L=N.call(c),I;!(I=L.next()).done;)Kr(I.value)&&zo(I.value,S)}}}function Ys(c){{var S=c.type;if(S==null||typeof S=="string")return;var O;if(typeof S=="function")O=S.propTypes;else if(typeof S=="object"&&(S.$$typeof===a||S.$$typeof===g))O=S.propTypes;else return;if(O){var A=C(S);Ds(O,c.props,"prop",A,c)}else if(S.PropTypes!==void 0&&!Yr){Yr=!0;var N=C(S);b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",N||"Unknown")}typeof S.getDefaultProps=="function"&&!S.getDefaultProps.isReactClassApproved&&b("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Ks(c){{for(var S=Object.keys(c.props),O=0;O<S.length;O++){var A=S[O];if(A!=="children"&&A!=="key"){Ze(c),b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",A),Ze(null);break}}c.ref!==null&&(Ze(c),b("Invalid attribute `ref` supplied to `React.Fragment`."),Ze(null))}}var Ko={};function Xo(c,S,O,A,N,L){{var I=j(c);if(!I){var M="";(c===void 0||typeof c=="object"&&c!==null&&Object.keys(c).length===0)&&(M+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var te=Gs();te?M+=te:M+=qo();var G;c===null?G="null":qr(c)?G="array":c!==void 0&&c.$$typeof===e?(G="<"+(C(c.type)||"Unknown")+" />",M=" Did you accidentally export a JSX literal instead of a component?"):G=typeof c,b("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",G,M)}var Y=qs(c,S,O,N,L);if(Y==null)return Y;if(I){var ae=S.children;if(ae!==void 0)if(A)if(qr(ae)){for(var et=0;et<ae.length;et++)Yo(ae[et],c);Object.freeze&&Object.freeze(ae)}else b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Yo(ae,c)}if(bt.call(S,"key")){var We=C(c),ne=Object.keys(S).filter(function(tc){return tc!=="key"}),Xr=ne.length>0?"{key: someKey, "+ne.join(": ..., ")+": ...}":"{key: someKey}";if(!Ko[We+Xr]){var ec=ne.length>0?"{"+ne.join(": ..., ")+": ...}":"{}";b(`A props object containing a "key" prop is being spread into JSX:
|
|
26
26
|
let props = %s;
|
|
27
27
|
<%s {...props} />
|
|
28
28
|
React keys must be passed directly to JSX without using spread:
|
|
29
29
|
let props = %s;
|
|
30
|
-
<%s key={someKey} {...props} />`,Rn,Je,Ud,Je),pa[Je+Rn]=!0}}return d===n?Id(J):Dd(J),J}}function Ld(d,E,A){return ma(d,E,A,!0)}function kd(d,E,A){return ma(d,E,A,!1)}var jd=kd,Bd=Ld;yt.Fragment=n,yt.jsx=jd,yt.jsxs=Bd}()),yt}process.env.NODE_ENV==="production"?Er.exports=Sa():Er.exports=xa();var R=Er.exports;function kn(e,t){return function(){return e.apply(t,arguments)}}const{toString:Oa}=Object.prototype,{getPrototypeOf:Sr}=Object,Lt=(e=>t=>{const r=Oa.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),pe=e=>(e=e.toLowerCase(),t=>Lt(t)===e),kt=e=>t=>typeof t===e,{isArray:Xe}=Array,ht=kt("undefined");function Aa(e){return e!==null&&!ht(e)&&e.constructor!==null&&!ht(e.constructor)&&ue(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const jn=pe("ArrayBuffer");function Ta(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&jn(e.buffer),t}const Pa=kt("string"),ue=kt("function"),Bn=kt("number"),jt=e=>e!==null&&typeof e=="object",Ca=e=>e===!0||e===!1,Bt=e=>{if(Lt(e)!=="object")return!1;const t=Sr(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},Fa=pe("Date"),$a=pe("File"),_a=pe("Blob"),Na=pe("FileList"),Ma=e=>jt(e)&&ue(e.pipe),Ra=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||ue(e.append)&&((t=Lt(e))==="formdata"||t==="object"&&ue(e.toString)&&e.toString()==="[object FormData]"))},Da=pe("URLSearchParams"),[Ia,La,ka,ja]=["ReadableStream","Request","Response","Headers"].map(pe),Ba=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function vt(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,o;if(typeof e!="object"&&(e=[e]),Xe(e))for(n=0,o=e.length;n<o;n++)t.call(null,e[n],n,e);else{const i=r?Object.getOwnPropertyNames(e):Object.keys(e),a=i.length;let s;for(n=0;n<a;n++)s=i[n],t.call(null,e[s],s,e)}}function Un(e,t){t=t.toLowerCase();const r=Object.keys(e);let n=r.length,o;for(;n-- >0;)if(o=r[n],t===o.toLowerCase())return o;return null}const Ie=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Wn=e=>!ht(e)&&e!==Ie;function xr(){const{caseless:e}=Wn(this)&&this||{},t={},r=(n,o)=>{const i=e&&Un(t,o)||o;Bt(t[i])&&Bt(n)?t[i]=xr(t[i],n):Bt(n)?t[i]=xr({},n):Xe(n)?t[i]=n.slice():t[i]=n};for(let n=0,o=arguments.length;n<o;n++)arguments[n]&&vt(arguments[n],r);return t}const Ua=(e,t,r,{allOwnKeys:n}={})=>(vt(t,(o,i)=>{r&&ue(o)?e[i]=kn(o,r):e[i]=o},{allOwnKeys:n}),e),Wa=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Ha=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},qa=(e,t,r,n)=>{let o,i,a;const s={};if(t=t||{},e==null)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)a=o[i],(!n||n(a,e,t))&&!s[a]&&(t[a]=e[a],s[a]=!0);e=r!==!1&&Sr(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},Va=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},za=e=>{if(!e)return null;if(Xe(e))return e;let t=e.length;if(!Bn(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},Ga=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Sr(Uint8Array)),Ka=(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let o;for(;(o=n.next())&&!o.done;){const i=o.value;t.call(e,i[0],i[1])}},Ja=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},Ya=pe("HTMLFormElement"),Xa=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,o){return n.toUpperCase()+o}),Hn=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),Qa=pe("RegExp"),qn=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};vt(r,(o,i)=>{let a;(a=t(o,i,e))!==!1&&(n[i]=a||o)}),Object.defineProperties(e,n)},Za=e=>{qn(e,(t,r)=>{if(ue(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=e[r];if(ue(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},es=(e,t)=>{const r={},n=o=>{o.forEach(i=>{r[i]=!0})};return Xe(e)?n(e):n(String(e).split(t)),r},ts=()=>{},rs=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,Or="abcdefghijklmnopqrstuvwxyz",Vn="0123456789",zn={DIGIT:Vn,ALPHA:Or,ALPHA_DIGIT:Or+Or.toUpperCase()+Vn},ns=(e=16,t=zn.ALPHA_DIGIT)=>{let r="";const{length:n}=t;for(;e--;)r+=t[Math.random()*n|0];return r};function os(e){return!!(e&&ue(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const is=e=>{const t=new Array(10),r=(n,o)=>{if(jt(n)){if(t.indexOf(n)>=0)return;if(!("toJSON"in n)){t[o]=n;const i=Xe(n)?[]:{};return vt(n,(a,s)=>{const l=r(a,o+1);!ht(l)&&(i[s]=l)}),t[o]=void 0,i}}return n};return r(e,0)},as=pe("AsyncFunction"),ss=e=>e&&(jt(e)||ue(e))&&ue(e.then)&&ue(e.catch),Gn=((e,t)=>e?setImmediate:t?((r,n)=>(Ie.addEventListener("message",({source:o,data:i})=>{o===Ie&&i===r&&n.length&&n.shift()()},!1),o=>{n.push(o),Ie.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",ue(Ie.postMessage)),ls=typeof queueMicrotask<"u"?queueMicrotask.bind(Ie):typeof process<"u"&&process.nextTick||Gn,b={isArray:Xe,isArrayBuffer:jn,isBuffer:Aa,isFormData:Ra,isArrayBufferView:Ta,isString:Pa,isNumber:Bn,isBoolean:Ca,isObject:jt,isPlainObject:Bt,isReadableStream:Ia,isRequest:La,isResponse:ka,isHeaders:ja,isUndefined:ht,isDate:Fa,isFile:$a,isBlob:_a,isRegExp:Qa,isFunction:ue,isStream:Ma,isURLSearchParams:Da,isTypedArray:Ga,isFileList:Na,forEach:vt,merge:xr,extend:Ua,trim:Ba,stripBOM:Wa,inherits:Ha,toFlatObject:qa,kindOf:Lt,kindOfTest:pe,endsWith:Va,toArray:za,forEachEntry:Ka,matchAll:Ja,isHTMLForm:Ya,hasOwnProperty:Hn,hasOwnProp:Hn,reduceDescriptors:qn,freezeMethods:Za,toObjectSet:es,toCamelCase:Xa,noop:ts,toFiniteNumber:rs,findKey:Un,global:Ie,isContextDefined:Wn,ALPHABET:zn,generateString:ns,isSpecCompliantForm:os,toJSONObject:is,isAsyncFn:as,isThenable:ss,setImmediate:Gn,asap:ls};function $(e,t,r,n,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),r&&(this.config=r),n&&(this.request=n),o&&(this.response=o,this.status=o.status?o.status:null)}b.inherits($,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:b.toJSONObject(this.config),code:this.code,status:this.status}}});const Kn=$.prototype,Jn={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Jn[e]={value:e}}),Object.defineProperties($,Jn),Object.defineProperty(Kn,"isAxiosError",{value:!0}),$.from=(e,t,r,n,o,i)=>{const a=Object.create(Kn);return b.toFlatObject(e,a,function(l){return l!==Error.prototype},s=>s!=="isAxiosError"),$.call(a,e.message,t,r,n,o),a.cause=e,a.name=e.name,i&&Object.assign(a,i),a};const us=null;function Ar(e){return b.isPlainObject(e)||b.isArray(e)}function Yn(e){return b.endsWith(e,"[]")?e.slice(0,-2):e}function Xn(e,t,r){return e?e.concat(t).map(function(o,i){return o=Yn(o),!r&&i?"["+o+"]":o}).join(r?".":""):t}function cs(e){return b.isArray(e)&&!e.some(Ar)}const fs=b.toFlatObject(b,{},null,function(t){return/^is[A-Z]/.test(t)});function Ut(e,t,r){if(!b.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=b.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,y){return!b.isUndefined(y[m])});const n=r.metaTokens,o=r.visitor||u,i=r.dots,a=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&b.isSpecCompliantForm(t);if(!b.isFunction(o))throw new TypeError("visitor must be a function");function f(c){if(c===null)return"";if(b.isDate(c))return c.toISOString();if(!l&&b.isBlob(c))throw new $("Blob is not supported. Use a Buffer instead.");return b.isArrayBuffer(c)||b.isTypedArray(c)?l&&typeof Blob=="function"?new Blob([c]):Buffer.from(c):c}function u(c,m,y){let w=c;if(c&&!y&&typeof c=="object"){if(b.endsWith(m,"{}"))m=n?m:m.slice(0,-2),c=JSON.stringify(c);else if(b.isArray(c)&&cs(c)||(b.isFileList(c)||b.endsWith(m,"[]"))&&(w=b.toArray(c)))return m=Yn(m),w.forEach(function(x,O){!(b.isUndefined(x)||x===null)&&t.append(a===!0?Xn([m],O,i):a===null?m:m+"[]",f(x))}),!1}return Ar(c)?!0:(t.append(Xn(y,m,i),f(c)),!1)}const h=[],v=Object.assign(fs,{defaultVisitor:u,convertValue:f,isVisitable:Ar});function g(c,m){if(!b.isUndefined(c)){if(h.indexOf(c)!==-1)throw Error("Circular reference detected in "+m.join("."));h.push(c),b.forEach(c,function(w,S){(!(b.isUndefined(w)||w===null)&&o.call(t,w,b.isString(S)?S.trim():S,m,v))===!0&&g(w,m?m.concat(S):[S])}),h.pop()}}if(!b.isObject(e))throw new TypeError("data must be an object");return g(e),t}function Qn(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return t[n]})}function Tr(e,t){this._pairs=[],e&&Ut(e,this,t)}const Zn=Tr.prototype;Zn.append=function(t,r){this._pairs.push([t,r])},Zn.toString=function(t){const r=t?function(n){return t.call(this,n,Qn)}:Qn;return this._pairs.map(function(o){return r(o[0])+"="+r(o[1])},"").join("&")};function ds(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function eo(e,t,r){if(!t)return e;const n=r&&r.encode||ds,o=r&&r.serialize;let i;if(o?i=o(t,r):i=b.isURLSearchParams(t)?t.toString():new Tr(t,r).toString(n),i){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class to{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){b.forEach(this.handlers,function(n){n!==null&&t(n)})}}const ro={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},ps={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Tr,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Pr=typeof window<"u"&&typeof document<"u",Cr=typeof navigator=="object"&&navigator||void 0,ms=Pr&&(!Cr||["ReactNative","NativeScript","NS"].indexOf(Cr.product)<0),ys=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",hs=Pr&&window.location.href||"http://localhost",ie={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Pr,hasStandardBrowserEnv:ms,hasStandardBrowserWebWorkerEnv:ys,navigator:Cr,origin:hs},Symbol.toStringTag,{value:"Module"})),...ps};function vs(e,t){return Ut(e,new ie.classes.URLSearchParams,Object.assign({visitor:function(r,n,o,i){return ie.isNode&&b.isBuffer(r)?(this.append(n,r.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},t))}function gs(e){return b.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function bs(e){const t={},r=Object.keys(e);let n;const o=r.length;let i;for(n=0;n<o;n++)i=r[n],t[i]=e[i];return t}function no(e){function t(r,n,o,i){let a=r[i++];if(a==="__proto__")return!0;const s=Number.isFinite(+a),l=i>=r.length;return a=!a&&b.isArray(o)?o.length:a,l?(b.hasOwnProp(o,a)?o[a]=[o[a],n]:o[a]=n,!s):((!o[a]||!b.isObject(o[a]))&&(o[a]=[]),t(r,n,o[a],i)&&b.isArray(o[a])&&(o[a]=bs(o[a])),!s)}if(b.isFormData(e)&&b.isFunction(e.entries)){const r={};return b.forEachEntry(e,(n,o)=>{t(gs(n),o,r,0)}),r}return null}function ws(e,t,r){if(b.isString(e))try{return(t||JSON.parse)(e),b.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(0,JSON.stringify)(e)}const gt={transitional:ro,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",o=n.indexOf("application/json")>-1,i=b.isObject(t);if(i&&b.isHTMLForm(t)&&(t=new FormData(t)),b.isFormData(t))return o?JSON.stringify(no(t)):t;if(b.isArrayBuffer(t)||b.isBuffer(t)||b.isStream(t)||b.isFile(t)||b.isBlob(t)||b.isReadableStream(t))return t;if(b.isArrayBufferView(t))return t.buffer;if(b.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let s;if(i){if(n.indexOf("application/x-www-form-urlencoded")>-1)return vs(t,this.formSerializer).toString();if((s=b.isFileList(t))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Ut(s?{"files[]":t}:t,l&&new l,this.formSerializer)}}return i||o?(r.setContentType("application/json",!1),ws(t)):t}],transformResponse:[function(t){const r=this.transitional||gt.transitional,n=r&&r.forcedJSONParsing,o=this.responseType==="json";if(b.isResponse(t)||b.isReadableStream(t))return t;if(t&&b.isString(t)&&(n&&!this.responseType||o)){const a=!(r&&r.silentJSONParsing)&&o;try{return JSON.parse(t)}catch(s){if(a)throw s.name==="SyntaxError"?$.from(s,$.ERR_BAD_RESPONSE,this,null,this.response):s}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ie.classes.FormData,Blob:ie.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};b.forEach(["delete","get","head","post","put","patch"],e=>{gt.headers[e]={}});const Es=b.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Ss=e=>{const t={};let r,n,o;return e&&e.split(`
|
|
31
|
-
`)
|
|
32
|
-
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(o=>n.set(o)),n}static accessor(t){const n=(this[oo]=this[oo]={accessors:{}}).accessors,o=this.prototype;function i(a){const s=bt(a);n[s]||(Ts(o,a),n[s]=!0)}return b.isArray(t)?t.forEach(i):i(t),this}}ae.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),b.reduceDescriptors(ae.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}}),b.freezeMethods(ae);function $r(e,t){const r=this||gt,n=t||r,o=ae.from(n.headers);let i=n.data;return b.forEach(e,function(s){i=s.call(r,i,o.normalize(),t?t.status:void 0)}),o.normalize(),i}function io(e){return!!(e&&e.__CANCEL__)}function Qe(e,t,r){$.call(this,e??"canceled",$.ERR_CANCELED,t,r),this.name="CanceledError"}b.inherits(Qe,$,{__CANCEL__:!0});function ao(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new $("Request failed with status code "+r.status,[$.ERR_BAD_REQUEST,$.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function Ps(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Cs(e,t){e=e||10;const r=new Array(e),n=new Array(e);let o=0,i=0,a;return t=t!==void 0?t:1e3,function(l){const f=Date.now(),u=n[i];a||(a=f),r[o]=l,n[o]=f;let h=i,v=0;for(;h!==o;)v+=r[h++],h=h%e;if(o=(o+1)%e,o===i&&(i=(i+1)%e),f-a<t)return;const g=u&&f-u;return g?Math.round(v*1e3/g):void 0}}function Fs(e,t){let r=0,n=1e3/t,o,i;const a=(f,u=Date.now())=>{r=u,o=null,i&&(clearTimeout(i),i=null),e.apply(null,f)};return[(...f)=>{const u=Date.now(),h=u-r;h>=n?a(f,u):(o=f,i||(i=setTimeout(()=>{i=null,a(o)},n-h)))},()=>o&&a(o)]}const Ht=(e,t,r=3)=>{let n=0;const o=Cs(50,250);return Fs(i=>{const a=i.loaded,s=i.lengthComputable?i.total:void 0,l=a-n,f=o(l),u=a<=s;n=a;const h={loaded:a,total:s,progress:s?a/s:void 0,bytes:l,rate:f||void 0,estimated:f&&s&&u?(s-a)/f:void 0,event:i,lengthComputable:s!=null,[t?"download":"upload"]:!0};e(h)},r)},so=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},lo=e=>(...t)=>b.asap(()=>e(...t)),$s=ie.hasStandardBrowserEnv?function(){const t=ie.navigator&&/(msie|trident)/i.test(ie.navigator.userAgent),r=document.createElement("a");let n;function o(i){let a=i;return t&&(r.setAttribute("href",a),a=r.href),r.setAttribute("href",a),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=o(window.location.href),function(a){const s=b.isString(a)?o(a):a;return s.protocol===n.protocol&&s.host===n.host}}():function(){return function(){return!0}}(),_s=ie.hasStandardBrowserEnv?{write(e,t,r,n,o,i){const a=[e+"="+encodeURIComponent(t)];b.isNumber(r)&&a.push("expires="+new Date(r).toGMTString()),b.isString(n)&&a.push("path="+n),b.isString(o)&&a.push("domain="+o),i===!0&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Ns(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Ms(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function uo(e,t){return e&&!Ns(t)?Ms(e,t):t}const co=e=>e instanceof ae?{...e}:e;function Le(e,t){t=t||{};const r={};function n(f,u,h){return b.isPlainObject(f)&&b.isPlainObject(u)?b.merge.call({caseless:h},f,u):b.isPlainObject(u)?b.merge({},u):b.isArray(u)?u.slice():u}function o(f,u,h){if(b.isUndefined(u)){if(!b.isUndefined(f))return n(void 0,f,h)}else return n(f,u,h)}function i(f,u){if(!b.isUndefined(u))return n(void 0,u)}function a(f,u){if(b.isUndefined(u)){if(!b.isUndefined(f))return n(void 0,f)}else return n(void 0,u)}function s(f,u,h){if(h in t)return n(f,u);if(h in e)return n(void 0,f)}const l={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(f,u)=>o(co(f),co(u),!0)};return b.forEach(Object.keys(Object.assign({},e,t)),function(u){const h=l[u]||o,v=h(e[u],t[u],u);b.isUndefined(v)&&h!==s||(r[u]=v)}),r}const fo=e=>{const t=Le({},e);let{data:r,withXSRFToken:n,xsrfHeaderName:o,xsrfCookieName:i,headers:a,auth:s}=t;t.headers=a=ae.from(a),t.url=eo(uo(t.baseURL,t.url),e.params,e.paramsSerializer),s&&a.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):"")));let l;if(b.isFormData(r)){if(ie.hasStandardBrowserEnv||ie.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[f,...u]=l?l.split(";").map(h=>h.trim()).filter(Boolean):[];a.setContentType([f||"multipart/form-data",...u].join("; "))}}if(ie.hasStandardBrowserEnv&&(n&&b.isFunction(n)&&(n=n(t)),n||n!==!1&&$s(t.url))){const f=o&&i&&_s.read(i);f&&a.set(o,f)}return t},Rs=typeof XMLHttpRequest<"u"&&function(e){return new Promise(function(r,n){const o=fo(e);let i=o.data;const a=ae.from(o.headers).normalize();let{responseType:s,onUploadProgress:l,onDownloadProgress:f}=o,u,h,v,g,c;function m(){g&&g(),c&&c(),o.cancelToken&&o.cancelToken.unsubscribe(u),o.signal&&o.signal.removeEventListener("abort",u)}let y=new XMLHttpRequest;y.open(o.method.toUpperCase(),o.url,!0),y.timeout=o.timeout;function w(){if(!y)return;const x=ae.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),T={data:!s||s==="text"||s==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:x,config:e,request:y};ao(function(_){r(_),m()},function(_){n(_),m()},T),y=null}"onloadend"in y?y.onloadend=w:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(w)},y.onabort=function(){y&&(n(new $("Request aborted",$.ECONNABORTED,e,y)),y=null)},y.onerror=function(){n(new $("Network Error",$.ERR_NETWORK,e,y)),y=null},y.ontimeout=function(){let O=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const T=o.transitional||ro;o.timeoutErrorMessage&&(O=o.timeoutErrorMessage),n(new $(O,T.clarifyTimeoutError?$.ETIMEDOUT:$.ECONNABORTED,e,y)),y=null},i===void 0&&a.setContentType(null),"setRequestHeader"in y&&b.forEach(a.toJSON(),function(O,T){y.setRequestHeader(T,O)}),b.isUndefined(o.withCredentials)||(y.withCredentials=!!o.withCredentials),s&&s!=="json"&&(y.responseType=o.responseType),f&&([v,c]=Ht(f,!0),y.addEventListener("progress",v)),l&&y.upload&&([h,g]=Ht(l),y.upload.addEventListener("progress",h),y.upload.addEventListener("loadend",g)),(o.cancelToken||o.signal)&&(u=x=>{y&&(n(!x||x.type?new Qe(null,e,y):x),y.abort(),y=null)},o.cancelToken&&o.cancelToken.subscribe(u),o.signal&&(o.signal.aborted?u():o.signal.addEventListener("abort",u)));const S=Ps(o.url);if(S&&ie.protocols.indexOf(S)===-1){n(new $("Unsupported protocol "+S+":",$.ERR_BAD_REQUEST,e));return}y.send(i||null)})},Ds=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,o;const i=function(f){if(!o){o=!0,s();const u=f instanceof Error?f:this.reason;n.abort(u instanceof $?u:new Qe(u instanceof Error?u.message:u))}};let a=t&&setTimeout(()=>{a=null,i(new $(`timeout ${t} of ms exceeded`,$.ETIMEDOUT))},t);const s=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(f=>{f.unsubscribe?f.unsubscribe(i):f.removeEventListener("abort",i)}),e=null)};e.forEach(f=>f.addEventListener("abort",i));const{signal:l}=n;return l.unsubscribe=()=>b.asap(s),l}},Is=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let n=0,o;for(;n<r;)o=n+t,yield e.slice(n,o),n=o},Ls=async function*(e,t){for await(const r of ks(e))yield*Is(r,t)},ks=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},po=(e,t,r,n)=>{const o=Ls(e,t);let i=0,a,s=l=>{a||(a=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:f,value:u}=await o.next();if(f){s(),l.close();return}let h=u.byteLength;if(r){let v=i+=h;r(v)}l.enqueue(new Uint8Array(u))}catch(f){throw s(f),f}},cancel(l){return s(l),o.return()}},{highWaterMark:2})},qt=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",mo=qt&&typeof ReadableStream=="function",js=qt&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),yo=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Bs=mo&&yo(()=>{let e=!1;const t=new Request(ie.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),ho=64*1024,_r=mo&&yo(()=>b.isReadableStream(new Response("").body)),Vt={stream:_r&&(e=>e.body)};qt&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Vt[t]&&(Vt[t]=b.isFunction(e[t])?r=>r[t]():(r,n)=>{throw new $(`Response type '${t}' is not supported`,$.ERR_NOT_SUPPORT,n)})})})(new Response);const Us=async e=>{if(e==null)return 0;if(b.isBlob(e))return e.size;if(b.isSpecCompliantForm(e))return(await new Request(ie.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(b.isArrayBufferView(e)||b.isArrayBuffer(e))return e.byteLength;if(b.isURLSearchParams(e)&&(e=e+""),b.isString(e))return(await js(e)).byteLength},Ws=async(e,t)=>{const r=b.toFiniteNumber(e.getContentLength());return r??Us(t)},Nr={http:us,xhr:Rs,fetch:qt&&(async e=>{let{url:t,method:r,data:n,signal:o,cancelToken:i,timeout:a,onDownloadProgress:s,onUploadProgress:l,responseType:f,headers:u,withCredentials:h="same-origin",fetchOptions:v}=fo(e);f=f?(f+"").toLowerCase():"text";let g=Ds([o,i&&i.toAbortSignal()],a),c;const m=g&&g.unsubscribe&&(()=>{g.unsubscribe()});let y;try{if(l&&Bs&&r!=="get"&&r!=="head"&&(y=await Ws(u,n))!==0){let T=new Request(t,{method:"POST",body:n,duplex:"half"}),P;if(b.isFormData(n)&&(P=T.headers.get("content-type"))&&u.setContentType(P),T.body){const[_,j]=so(y,Ht(lo(l)));n=po(T.body,ho,_,j)}}b.isString(h)||(h=h?"include":"omit");const w="credentials"in Request.prototype;c=new Request(t,{...v,signal:g,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:w?h:void 0});let S=await fetch(c);const x=_r&&(f==="stream"||f==="response");if(_r&&(s||x&&m)){const T={};["status","statusText","headers"].forEach(H=>{T[H]=S[H]});const P=b.toFiniteNumber(S.headers.get("content-length")),[_,j]=s&&so(P,Ht(lo(s),!0))||[];S=new Response(po(S.body,ho,_,()=>{j&&j(),m&&m()}),T)}f=f||"text";let O=await Vt[b.findKey(Vt,f)||"text"](S,e);return!x&&m&&m(),await new Promise((T,P)=>{ao(T,P,{data:O,headers:ae.from(S.headers),status:S.status,statusText:S.statusText,config:e,request:c})})}catch(w){throw m&&m(),w&&w.name==="TypeError"&&/fetch/i.test(w.message)?Object.assign(new $("Network Error",$.ERR_NETWORK,e,c),{cause:w.cause||w}):$.from(w,w&&w.code,e,c)}})};b.forEach(Nr,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const vo=e=>`- ${e}`,Hs=e=>b.isFunction(e)||e===null||e===!1,go={getAdapter:e=>{e=b.isArray(e)?e:[e];const{length:t}=e;let r,n;const o={};for(let i=0;i<t;i++){r=e[i];let a;if(n=r,!Hs(r)&&(n=Nr[(a=String(r)).toLowerCase()],n===void 0))throw new $(`Unknown adapter '${a}'`);if(n)break;o[a||"#"+i]=n}if(!n){const i=Object.entries(o).map(([s,l])=>`adapter ${s} `+(l===!1?"is not supported by the environment":"is not available in the build"));let a=t?i.length>1?`since :
|
|
33
|
-
`+i.map(vo).join(`
|
|
34
|
-
`):" "+vo(i[0]):"as no adapter specified";throw new $("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return n},adapters:Nr};function Mr(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Qe(null,e)}function bo(e){return Mr(e),e.headers=ae.from(e.headers),e.data=$r.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),go.getAdapter(e.adapter||gt.adapter)(e).then(function(n){return Mr(e),n.data=$r.call(e,e.transformResponse,n),n.headers=ae.from(n.headers),n},function(n){return io(n)||(Mr(e),n&&n.response&&(n.response.data=$r.call(e,e.transformResponse,n.response),n.response.headers=ae.from(n.response.headers))),Promise.reject(n)})}const wo="1.7.7",Rr={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Rr[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const Eo={};Rr.transitional=function(t,r,n){function o(i,a){return"[Axios v"+wo+"] Transitional option '"+i+"'"+a+(n?". "+n:"")}return(i,a,s)=>{if(t===!1)throw new $(o(a," has been removed"+(r?" in "+r:"")),$.ERR_DEPRECATED);return r&&!Eo[a]&&(Eo[a]=!0,console.warn(o(a," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(i,a,s):!0}};function qs(e,t,r){if(typeof e!="object")throw new $("options must be an object",$.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let o=n.length;for(;o-- >0;){const i=n[o],a=t[i];if(a){const s=e[i],l=s===void 0||a(s,i,e);if(l!==!0)throw new $("option "+i+" must be "+l,$.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new $("Unknown option "+i,$.ERR_BAD_OPTION)}}const Dr={assertOptions:qs,validators:Rr},Ae=Dr.validators;class ke{constructor(t){this.defaults=t,this.interceptors={request:new to,response:new to}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let o;Error.captureStackTrace?Error.captureStackTrace(o={}):o=new Error;const i=o.stack?o.stack.replace(/^.+\n/,""):"";try{n.stack?i&&!String(n.stack).endsWith(i.replace(/^.+\n.+\n/,""))&&(n.stack+=`
|
|
35
|
-
`+i):n.stack=i}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Le(this.defaults,r);const{transitional:n,paramsSerializer:o,headers:i}=r;n!==void 0&&Dr.assertOptions(n,{silentJSONParsing:Ae.transitional(Ae.boolean),forcedJSONParsing:Ae.transitional(Ae.boolean),clarifyTimeoutError:Ae.transitional(Ae.boolean)},!1),o!=null&&(b.isFunction(o)?r.paramsSerializer={serialize:o}:Dr.assertOptions(o,{encode:Ae.function,serialize:Ae.function},!0)),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a=i&&b.merge(i.common,i[r.method]);i&&b.forEach(["delete","get","head","post","put","patch","common"],c=>{delete i[c]}),r.headers=ae.concat(a,i);const s=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(r)===!1||(l=l&&m.synchronous,s.unshift(m.fulfilled,m.rejected))});const f=[];this.interceptors.response.forEach(function(m){f.push(m.fulfilled,m.rejected)});let u,h=0,v;if(!l){const c=[bo.bind(this),void 0];for(c.unshift.apply(c,s),c.push.apply(c,f),v=c.length,u=Promise.resolve(r);h<v;)u=u.then(c[h++],c[h++]);return u}v=s.length;let g=r;for(h=0;h<v;){const c=s[h++],m=s[h++];try{g=c(g)}catch(y){m.call(this,y);break}}try{u=bo.call(this,g)}catch(c){return Promise.reject(c)}for(h=0,v=f.length;h<v;)u=u.then(f[h++],f[h++]);return u}getUri(t){t=Le(this.defaults,t);const r=uo(t.baseURL,t.url);return eo(r,t.params,t.paramsSerializer)}}b.forEach(["delete","get","head","options"],function(t){ke.prototype[t]=function(r,n){return this.request(Le(n||{},{method:t,url:r,data:(n||{}).data}))}}),b.forEach(["post","put","patch"],function(t){function r(n){return function(i,a,s){return this.request(Le(s||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:a}))}}ke.prototype[t]=r(),ke.prototype[t+"Form"]=r(!0)});class Ir{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(i){r=i});const n=this;this.promise.then(o=>{if(!n._listeners)return;let i=n._listeners.length;for(;i-- >0;)n._listeners[i](o);n._listeners=null}),this.promise.then=o=>{let i;const a=new Promise(s=>{n.subscribe(s),i=s}).then(o);return a.cancel=function(){n.unsubscribe(i)},a},t(function(i,a,s){n.reason||(n.reason=new Qe(i,a,s),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Ir(function(o){t=o}),cancel:t}}}function Vs(e){return function(r){return e.apply(null,r)}}function zs(e){return b.isObject(e)&&e.isAxiosError===!0}const Lr={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Lr).forEach(([e,t])=>{Lr[t]=e});function So(e){const t=new ke(e),r=kn(ke.prototype.request,t);return b.extend(r,ke.prototype,t,{allOwnKeys:!0}),b.extend(r,t,null,{allOwnKeys:!0}),r.create=function(o){return So(Le(e,o))},r}const z=So(gt);z.Axios=ke,z.CanceledError=Qe,z.CancelToken=Ir,z.isCancel=io,z.VERSION=wo,z.toFormData=Ut,z.AxiosError=$,z.Cancel=z.CanceledError,z.all=function(t){return Promise.all(t)},z.spread=Vs,z.isAxiosError=zs,z.mergeConfig=Le,z.AxiosHeaders=ae,z.formToJSON=e=>no(b.isHTMLForm(e)?new FormData(e):e),z.getAdapter=go.getAdapter,z.HttpStatusCode=Lr,z.default=z;function Gs(e,t){return Array.isArray(e)?e.filter(r=>!t.includes(r)):Object.keys(e).reduce((r,n)=>(t.includes(n)||(r[n]=e[n]),r),{})}function xo(e,t){return Array.isArray(e)?e.filter(r=>t.includes(r)):t.reduce((r,n)=>(n in e&&(r[n]=e[n]),r),{})}function Ks(e){return Array.isArray(e)?e.filter(t=>t!==null):Object.keys(e).reduce((t,r)=>(r in e&&e[r]!==null&&(t[r]=e[r]),t),{})}function Js(e=3,t=100){const r=()=>De.router.page||null;return new Promise((n,o)=>{let i=r();if(i){n(i);return}let a=e*1e3/t;const s=setInterval(()=>{i=r(),i&&(clearInterval(s),n(i)),--a<=0&&(clearInterval(s),o(new Error("Inertia page not available")))},t)})}var Ys=function(t){return Xs(t)&&!Qs(t)};function Xs(e){return!!e&&typeof e=="object"}function Qs(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||tl(e)}var Zs=typeof Symbol=="function"&&Symbol.for,el=Zs?Symbol.for("react.element"):60103;function tl(e){return e.$$typeof===el}function rl(e){return Array.isArray(e)?[]:{}}function wt(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Ze(rl(e),e,t):e}function nl(e,t,r){return e.concat(t).map(function(n){return wt(n,r)})}function ol(e,t){if(!t.customMerge)return Ze;var r=t.customMerge(e);return typeof r=="function"?r:Ze}function il(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function Oo(e){return Object.keys(e).concat(il(e))}function Ao(e,t){try{return t in e}catch{return!1}}function al(e,t){return Ao(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function sl(e,t,r){var n={};return r.isMergeableObject(e)&&Oo(e).forEach(function(o){n[o]=wt(e[o],r)}),Oo(t).forEach(function(o){al(e,o)||(Ao(e,o)&&r.isMergeableObject(t[o])?n[o]=ol(o,r)(e[o],t[o],r):n[o]=wt(t[o],r))}),n}function Ze(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||nl,r.isMergeableObject=r.isMergeableObject||Ys,r.cloneUnlessOtherwiseSpecified=wt;var n=Array.isArray(t),o=Array.isArray(e),i=n===o;return i?n?r.arrayMerge(e,t,r):sl(e,t,r):wt(t,r)}Ze.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(n,o){return Ze(n,o,r)},{})};var ll=Ze,ul=ll;const cl=wa(ul);var fl=Error,dl=EvalError,pl=RangeError,ml=ReferenceError,To=SyntaxError,Et=TypeError,yl=URIError,hl=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;t[r]=o;for(r in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var i=Object.getOwnPropertySymbols(t);if(i.length!==1||i[0]!==r||!Object.prototype.propertyIsEnumerable.call(t,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var a=Object.getOwnPropertyDescriptor(t,r);if(a.value!==o||a.enumerable!==!0)return!1}return!0},Po=typeof Symbol<"u"&&Symbol,vl=hl,gl=function(){return typeof Po!="function"||typeof Symbol!="function"||typeof Po("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:vl()},kr={__proto__:null,foo:{}},bl=Object,wl=function(){return{__proto__:kr}.foo===kr.foo&&!(kr instanceof bl)},El="Function.prototype.bind called on incompatible ",Sl=Object.prototype.toString,xl=Math.max,Ol="[object Function]",Co=function(t,r){for(var n=[],o=0;o<t.length;o+=1)n[o]=t[o];for(var i=0;i<r.length;i+=1)n[i+t.length]=r[i];return n},Al=function(t,r){for(var n=[],o=r,i=0;o<t.length;o+=1,i+=1)n[i]=t[o];return n},Tl=function(e,t){for(var r="",n=0;n<e.length;n+=1)r+=e[n],n+1<e.length&&(r+=t);return r},Pl=function(t){var r=this;if(typeof r!="function"||Sl.apply(r)!==Ol)throw new TypeError(El+r);for(var n=Al(arguments,1),o,i=function(){if(this instanceof o){var u=r.apply(this,Co(n,arguments));return Object(u)===u?u:this}return r.apply(t,Co(n,arguments))},a=xl(0,r.length-n.length),s=[],l=0;l<a;l++)s[l]="$"+l;if(o=Function("binder","return function ("+Tl(s,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var f=function(){};f.prototype=r.prototype,o.prototype=new f,f.prototype=null}return o},Cl=Pl,jr=Function.prototype.bind||Cl,Fl=Function.prototype.call,$l=Object.prototype.hasOwnProperty,_l=jr,Nl=_l.call(Fl,$l),N,Ml=fl,Rl=dl,Dl=pl,Il=ml,et=To,tt=Et,Ll=yl,Fo=Function,Br=function(e){try{return Fo('"use strict"; return ('+e+").constructor;")()}catch{}},je=Object.getOwnPropertyDescriptor;if(je)try{je({},"")}catch{je=null}var Ur=function(){throw new tt},kl=je?function(){try{return arguments.callee,Ur}catch{try{return je(arguments,"callee").get}catch{return Ur}}}():Ur,rt=gl(),jl=wl(),Q=Object.getPrototypeOf||(jl?function(e){return e.__proto__}:null),nt={},Bl=typeof Uint8Array>"u"||!Q?N:Q(Uint8Array),Be={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?N:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?N:ArrayBuffer,"%ArrayIteratorPrototype%":rt&&Q?Q([][Symbol.iterator]()):N,"%AsyncFromSyncIteratorPrototype%":N,"%AsyncFunction%":nt,"%AsyncGenerator%":nt,"%AsyncGeneratorFunction%":nt,"%AsyncIteratorPrototype%":nt,"%Atomics%":typeof Atomics>"u"?N:Atomics,"%BigInt%":typeof BigInt>"u"?N:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?N:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?N:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?N:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Ml,"%eval%":eval,"%EvalError%":Rl,"%Float32Array%":typeof Float32Array>"u"?N:Float32Array,"%Float64Array%":typeof Float64Array>"u"?N:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?N:FinalizationRegistry,"%Function%":Fo,"%GeneratorFunction%":nt,"%Int8Array%":typeof Int8Array>"u"?N:Int8Array,"%Int16Array%":typeof Int16Array>"u"?N:Int16Array,"%Int32Array%":typeof Int32Array>"u"?N:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":rt&&Q?Q(Q([][Symbol.iterator]())):N,"%JSON%":typeof JSON=="object"?JSON:N,"%Map%":typeof Map>"u"?N:Map,"%MapIteratorPrototype%":typeof Map>"u"||!rt||!Q?N:Q(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?N:Promise,"%Proxy%":typeof Proxy>"u"?N:Proxy,"%RangeError%":Dl,"%ReferenceError%":Il,"%Reflect%":typeof Reflect>"u"?N:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?N:Set,"%SetIteratorPrototype%":typeof Set>"u"||!rt||!Q?N:Q(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?N:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":rt&&Q?Q(""[Symbol.iterator]()):N,"%Symbol%":rt?Symbol:N,"%SyntaxError%":et,"%ThrowTypeError%":kl,"%TypedArray%":Bl,"%TypeError%":tt,"%Uint8Array%":typeof Uint8Array>"u"?N:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?N:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?N:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?N:Uint32Array,"%URIError%":Ll,"%WeakMap%":typeof WeakMap>"u"?N:WeakMap,"%WeakRef%":typeof WeakRef>"u"?N:WeakRef,"%WeakSet%":typeof WeakSet>"u"?N:WeakSet};if(Q)try{null.error}catch(e){var Ul=Q(Q(e));Be["%Error.prototype%"]=Ul}var Wl=function e(t){var r;if(t==="%AsyncFunction%")r=Br("async function () {}");else if(t==="%GeneratorFunction%")r=Br("function* () {}");else if(t==="%AsyncGeneratorFunction%")r=Br("async function* () {}");else if(t==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(t==="%AsyncIteratorPrototype%"){var o=e("%AsyncGenerator%");o&&Q&&(r=Q(o.prototype))}return Be[t]=r,r},$o={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},St=jr,zt=Nl,Hl=St.call(Function.call,Array.prototype.concat),ql=St.call(Function.apply,Array.prototype.splice),_o=St.call(Function.call,String.prototype.replace),Gt=St.call(Function.call,String.prototype.slice),Vl=St.call(Function.call,RegExp.prototype.exec),zl=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Gl=/\\(\\)?/g,Kl=function(t){var r=Gt(t,0,1),n=Gt(t,-1);if(r==="%"&&n!=="%")throw new et("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new et("invalid intrinsic syntax, expected opening `%`");var o=[];return _o(t,zl,function(i,a,s,l){o[o.length]=s?_o(l,Gl,"$1"):a||i}),o},Jl=function(t,r){var n=t,o;if(zt($o,n)&&(o=$o[n],n="%"+o[0]+"%"),zt(Be,n)){var i=Be[n];if(i===nt&&(i=Wl(n)),typeof i>"u"&&!r)throw new tt("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new et("intrinsic "+t+" does not exist!")},ot=function(t,r){if(typeof t!="string"||t.length===0)throw new tt("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new tt('"allowMissing" argument must be a boolean');if(Vl(/^%?[^%]*%?$/,t)===null)throw new et("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Kl(t),o=n.length>0?n[0]:"",i=Jl("%"+o+"%",r),a=i.name,s=i.value,l=!1,f=i.alias;f&&(o=f[0],ql(n,Hl([0,1],f)));for(var u=1,h=!0;u<n.length;u+=1){var v=n[u],g=Gt(v,0,1),c=Gt(v,-1);if((g==='"'||g==="'"||g==="`"||c==='"'||c==="'"||c==="`")&&g!==c)throw new et("property names with quotes must have matching quotes");if((v==="constructor"||!h)&&(l=!0),o+="."+v,a="%"+o+"%",zt(Be,a))s=Be[a];else if(s!=null){if(!(v in s)){if(!r)throw new tt("base intrinsic for "+t+" exists, but the property is not available.");return}if(je&&u+1>=n.length){var m=je(s,v);h=!!m,h&&"get"in m&&!("originalValue"in m.get)?s=m.get:s=s[v]}else h=zt(s,v),s=s[v];h&&!l&&(Be[a]=s)}}return s},No={exports:{}},Wr,Mo;function Hr(){if(Mo)return Wr;Mo=1;var e=ot,t=e("%Object.defineProperty%",!0)||!1;if(t)try{t({},"a",{value:1})}catch{t=!1}return Wr=t,Wr}var Yl=ot,Kt=Yl("%Object.getOwnPropertyDescriptor%",!0);if(Kt)try{Kt([],"length")}catch{Kt=null}var Ro=Kt,Do=Hr(),Xl=To,it=Et,Io=Ro,Ql=function(t,r,n){if(!t||typeof t!="object"&&typeof t!="function")throw new it("`obj` must be an object or a function`");if(typeof r!="string"&&typeof r!="symbol")throw new it("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new it("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new it("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new it("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new it("`loose`, if provided, must be a boolean");var o=arguments.length>3?arguments[3]:null,i=arguments.length>4?arguments[4]:null,a=arguments.length>5?arguments[5]:null,s=arguments.length>6?arguments[6]:!1,l=!!Io&&Io(t,r);if(Do)Do(t,r,{configurable:a===null&&l?l.configurable:!a,enumerable:o===null&&l?l.enumerable:!o,value:n,writable:i===null&&l?l.writable:!i});else if(s||!o&&!i&&!a)t[r]=n;else throw new Xl("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},qr=Hr(),Lo=function(){return!!qr};Lo.hasArrayLengthDefineBug=function(){if(!qr)return null;try{return qr([],"length",{value:1}).length!==1}catch{return!0}};var Zl=Lo,eu=ot,ko=Ql,tu=Zl(),jo=Ro,Bo=Et,ru=eu("%Math.floor%"),nu=function(t,r){if(typeof t!="function")throw new Bo("`fn` is not a function");if(typeof r!="number"||r<0||r>4294967295||ru(r)!==r)throw new Bo("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],o=!0,i=!0;if("length"in t&&jo){var a=jo(t,"length");a&&!a.configurable&&(o=!1),a&&!a.writable&&(i=!1)}return(o||i||!n)&&(tu?ko(t,"length",r,!0,!0):ko(t,"length",r)),t};(function(e){var t=jr,r=ot,n=nu,o=Et,i=r("%Function.prototype.apply%"),a=r("%Function.prototype.call%"),s=r("%Reflect.apply%",!0)||t.call(a,i),l=Hr(),f=r("%Math.max%");e.exports=function(v){if(typeof v!="function")throw new o("a function is required");var g=s(t,a,arguments);return n(g,1+f(0,v.length-(arguments.length-1)),!0)};var u=function(){return s(t,i,arguments)};l?l(e.exports,"apply",{value:u}):e.exports.apply=u})(No);var ou=No.exports,Uo=ot,Wo=ou,iu=Wo(Uo("String.prototype.indexOf")),au=function(t,r){var n=Uo(t,!!r);return typeof n=="function"&&iu(t,".prototype.")>-1?Wo(n):n};const su=Ea(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var Vr=typeof Map=="function"&&Map.prototype,zr=Object.getOwnPropertyDescriptor&&Vr?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Jt=Vr&&zr&&typeof zr.get=="function"?zr.get:null,Ho=Vr&&Map.prototype.forEach,Gr=typeof Set=="function"&&Set.prototype,Kr=Object.getOwnPropertyDescriptor&&Gr?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Yt=Gr&&Kr&&typeof Kr.get=="function"?Kr.get:null,qo=Gr&&Set.prototype.forEach,lu=typeof WeakMap=="function"&&WeakMap.prototype,xt=lu?WeakMap.prototype.has:null,uu=typeof WeakSet=="function"&&WeakSet.prototype,Ot=uu?WeakSet.prototype.has:null,cu=typeof WeakRef=="function"&&WeakRef.prototype,Vo=cu?WeakRef.prototype.deref:null,fu=Boolean.prototype.valueOf,du=Object.prototype.toString,pu=Function.prototype.toString,mu=String.prototype.match,Jr=String.prototype.slice,Te=String.prototype.replace,yu=String.prototype.toUpperCase,zo=String.prototype.toLowerCase,Go=RegExp.prototype.test,Ko=Array.prototype.concat,he=Array.prototype.join,hu=Array.prototype.slice,Jo=Math.floor,Yr=typeof BigInt=="function"?BigInt.prototype.valueOf:null,Xr=Object.getOwnPropertySymbols,Qr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,at=typeof Symbol=="function"&&typeof Symbol.iterator=="object",te=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===at||!0)?Symbol.toStringTag:null,Yo=Object.prototype.propertyIsEnumerable,Xo=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function Qo(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||Go.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-Jo(-e):Jo(e);if(n!==e){var o=String(n),i=Jr.call(t,o.length+1);return Te.call(o,r,"$&_")+"."+Te.call(Te.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Te.call(t,r,"$&_")}var Zr=su,Zo=Zr.custom,ei=ni(Zo)?Zo:null,vu=function e(t,r,n,o){var i=r||{};if(Pe(i,"quoteStyle")&&i.quoteStyle!=="single"&&i.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(Pe(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var a=Pe(i,"customInspect")?i.customInspect:!0;if(typeof a!="boolean"&&a!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(Pe(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(Pe(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var s=i.numericSeparator;if(typeof t>"u")return"undefined";if(t===null)return"null";if(typeof t=="boolean")return t?"true":"false";if(typeof t=="string")return ii(t,i);if(typeof t=="number"){if(t===0)return 1/0/t>0?"0":"-0";var l=String(t);return s?Qo(t,l):l}if(typeof t=="bigint"){var f=String(t)+"n";return s?Qo(t,f):f}var u=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=u&&u>0&&typeof t=="object")return en(t)?"[Array]":"[Object]";var h=Du(i,n);if(typeof o>"u")o=[];else if(oi(o,t)>=0)return"[Circular]";function v(C,L,K){if(L&&(o=hu.call(o),o.push(L)),K){var ce={depth:i.depth};return Pe(i,"quoteStyle")&&(ce.quoteStyle=i.quoteStyle),e(C,ce,n+1,o)}return e(C,i,n+1,o)}if(typeof t=="function"&&!ri(t)){var g=Tu(t),c=Xt(t,v);return"[Function"+(g?": "+g:" (anonymous)")+"]"+(c.length>0?" { "+he.call(c,", ")+" }":"")}if(ni(t)){var m=at?Te.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):Qr.call(t);return typeof t=="object"&&!at?At(m):m}if(Nu(t)){for(var y="<"+zo.call(String(t.nodeName)),w=t.attributes||[],S=0;S<w.length;S++)y+=" "+w[S].name+"="+ti(gu(w[S].value),"double",i);return y+=">",t.childNodes&&t.childNodes.length&&(y+="..."),y+="</"+zo.call(String(t.nodeName))+">",y}if(en(t)){if(t.length===0)return"[]";var x=Xt(t,v);return h&&!Ru(x)?"["+rn(x,h)+"]":"[ "+he.call(x,", ")+" ]"}if(wu(t)){var O=Xt(t,v);return!("cause"in Error.prototype)&&"cause"in t&&!Yo.call(t,"cause")?"{ ["+String(t)+"] "+he.call(Ko.call("[cause]: "+v(t.cause),O),", ")+" }":O.length===0?"["+String(t)+"]":"{ ["+String(t)+"] "+he.call(O,", ")+" }"}if(typeof t=="object"&&a){if(ei&&typeof t[ei]=="function"&&Zr)return Zr(t,{depth:u-n});if(a!=="symbol"&&typeof t.inspect=="function")return t.inspect()}if(Pu(t)){var T=[];return Ho&&Ho.call(t,function(C,L){T.push(v(L,t,!0)+" => "+v(C,t))}),ai("Map",Jt.call(t),T,h)}if($u(t)){var P=[];return qo&&qo.call(t,function(C){P.push(v(C,t))}),ai("Set",Yt.call(t),P,h)}if(Cu(t))return tn("WeakMap");if(_u(t))return tn("WeakSet");if(Fu(t))return tn("WeakRef");if(Su(t))return At(v(Number(t)));if(Ou(t))return At(v(Yr.call(t)));if(xu(t))return At(fu.call(t));if(Eu(t))return At(v(String(t)));if(typeof window<"u"&&t===window)return"{ [object Window] }";if(typeof globalThis<"u"&&t===globalThis||typeof wr<"u"&&t===wr)return"{ [object globalThis] }";if(!bu(t)&&!ri(t)){var _=Xt(t,v),j=Xo?Xo(t)===Object.prototype:t instanceof Object||t.constructor===Object,H=t instanceof Object?"":"null prototype",I=!j&&te&&Object(t)===t&&te in t?Jr.call(Ce(t),8,-1):H?"Object":"",X=j||typeof t.constructor!="function"?"":t.constructor.name?t.constructor.name+" ":"",Z=X+(I||H?"["+he.call(Ko.call([],I||[],H||[]),": ")+"] ":"");return _.length===0?Z+"{}":h?Z+"{"+rn(_,h)+"}":Z+"{ "+he.call(_,", ")+" }"}return String(t)};function ti(e,t,r){var n=(r.quoteStyle||t)==="double"?'"':"'";return n+e+n}function gu(e){return Te.call(String(e),/"/g,""")}function en(e){return Ce(e)==="[object Array]"&&(!te||!(typeof e=="object"&&te in e))}function bu(e){return Ce(e)==="[object Date]"&&(!te||!(typeof e=="object"&&te in e))}function ri(e){return Ce(e)==="[object RegExp]"&&(!te||!(typeof e=="object"&&te in e))}function wu(e){return Ce(e)==="[object Error]"&&(!te||!(typeof e=="object"&&te in e))}function Eu(e){return Ce(e)==="[object String]"&&(!te||!(typeof e=="object"&&te in e))}function Su(e){return Ce(e)==="[object Number]"&&(!te||!(typeof e=="object"&&te in e))}function xu(e){return Ce(e)==="[object Boolean]"&&(!te||!(typeof e=="object"&&te in e))}function ni(e){if(at)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!Qr)return!1;try{return Qr.call(e),!0}catch{}return!1}function Ou(e){if(!e||typeof e!="object"||!Yr)return!1;try{return Yr.call(e),!0}catch{}return!1}var Au=Object.prototype.hasOwnProperty||function(e){return e in this};function Pe(e,t){return Au.call(e,t)}function Ce(e){return du.call(e)}function Tu(e){if(e.name)return e.name;var t=mu.call(pu.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}function oi(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}function Pu(e){if(!Jt||!e||typeof e!="object")return!1;try{Jt.call(e);try{Yt.call(e)}catch{return!0}return e instanceof Map}catch{}return!1}function Cu(e){if(!xt||!e||typeof e!="object")return!1;try{xt.call(e,xt);try{Ot.call(e,Ot)}catch{return!0}return e instanceof WeakMap}catch{}return!1}function Fu(e){if(!Vo||!e||typeof e!="object")return!1;try{return Vo.call(e),!0}catch{}return!1}function $u(e){if(!Yt||!e||typeof e!="object")return!1;try{Yt.call(e);try{Jt.call(e)}catch{return!0}return e instanceof Set}catch{}return!1}function _u(e){if(!Ot||!e||typeof e!="object")return!1;try{Ot.call(e,Ot);try{xt.call(e,xt)}catch{return!0}return e instanceof WeakSet}catch{}return!1}function Nu(e){return!e||typeof e!="object"?!1:typeof HTMLElement<"u"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function ii(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return ii(Jr.call(e,0,t.maxStringLength),t)+n}var o=Te.call(Te.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,Mu);return ti(o,"single",t)}function Mu(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+yu.call(t.toString(16))}function At(e){return"Object("+e+")"}function tn(e){return e+" { ? }"}function ai(e,t,r,n){var o=n?rn(r,n):he.call(r,", ");return e+" ("+t+") {"+o+"}"}function Ru(e){for(var t=0;t<e.length;t++)if(oi(e[t],`
|
|
36
|
-
`)>=0)return!1;return!0}function Du(e,t){var r;if(e.indent===" ")r=" ";else if(typeof e.indent=="number"&&e.indent>0)r=he.call(Array(e.indent+1)," ");else return null;return{base:r,prev:he.call(Array(t+1),r)}}function rn(e,t){if(e.length===0)return"";var r=`
|
|
37
|
-
`+t.prev+t.base;return r+he.call(e,","+r)+`
|
|
38
|
-
`+t.prev}function Xt(e,t){var r=en(e),n=[];if(r){n.length=e.length;for(var o=0;o<e.length;o++)n[o]=Pe(e,o)?t(e[o],e):""}var i=typeof Xr=="function"?Xr(e):[],a;if(at){a={};for(var s=0;s<i.length;s++)a["$"+i[s]]=i[s]}for(var l in e)Pe(e,l)&&(r&&String(Number(l))===l&&l<e.length||at&&a["$"+l]instanceof Symbol||(Go.call(/[^\w$]/,l)?n.push(t(l,e)+": "+t(e[l],e)):n.push(l+": "+t(e[l],e))));if(typeof Xr=="function")for(var f=0;f<i.length;f++)Yo.call(e,i[f])&&n.push("["+t(i[f])+"]: "+t(e[i[f]],e));return n}var si=ot,st=au,Iu=vu,Lu=Et,Qt=si("%WeakMap%",!0),Zt=si("%Map%",!0),ku=st("WeakMap.prototype.get",!0),ju=st("WeakMap.prototype.set",!0),Bu=st("WeakMap.prototype.has",!0),Uu=st("Map.prototype.get",!0),Wu=st("Map.prototype.set",!0),Hu=st("Map.prototype.has",!0),nn=function(e,t){for(var r=e,n;(n=r.next)!==null;r=n)if(n.key===t)return r.next=n.next,n.next=e.next,e.next=n,n},qu=function(e,t){var r=nn(e,t);return r&&r.value},Vu=function(e,t,r){var n=nn(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}},zu=function(e,t){return!!nn(e,t)},Gu=function(){var t,r,n,o={assert:function(i){if(!o.has(i))throw new Lu("Side channel does not contain "+Iu(i))},get:function(i){if(Qt&&i&&(typeof i=="object"||typeof i=="function")){if(t)return ku(t,i)}else if(Zt){if(r)return Uu(r,i)}else if(n)return qu(n,i)},has:function(i){if(Qt&&i&&(typeof i=="object"||typeof i=="function")){if(t)return Bu(t,i)}else if(Zt){if(r)return Hu(r,i)}else if(n)return zu(n,i);return!1},set:function(i,a){Qt&&i&&(typeof i=="object"||typeof i=="function")?(t||(t=new Qt),ju(t,i,a)):Zt?(r||(r=new Zt),Wu(r,i,a)):(n||(n={key:{},next:null}),Vu(n,i,a))}};return o},Ku=String.prototype.replace,Ju=/%20/g,on={RFC1738:"RFC1738",RFC3986:"RFC3986"},an={default:on.RFC3986,formatters:{RFC1738:function(e){return Ku.call(e,Ju,"+")},RFC3986:function(e){return String(e)}},RFC1738:on.RFC1738,RFC3986:on.RFC3986},Yu=an,sn=Object.prototype.hasOwnProperty,Ue=Array.isArray,ve=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),Xu=function(t){for(;t.length>1;){var r=t.pop(),n=r.obj[r.prop];if(Ue(n)){for(var o=[],i=0;i<n.length;++i)typeof n[i]<"u"&&o.push(n[i]);r.obj[r.prop]=o}}},li=function(t,r){for(var n=r&&r.plainObjects?Object.create(null):{},o=0;o<t.length;++o)typeof t[o]<"u"&&(n[o]=t[o]);return n},Qu=function e(t,r,n){if(!r)return t;if(typeof r!="object"){if(Ue(t))t.push(r);else if(t&&typeof t=="object")(n&&(n.plainObjects||n.allowPrototypes)||!sn.call(Object.prototype,r))&&(t[r]=!0);else return[t,r];return t}if(!t||typeof t!="object")return[t].concat(r);var o=t;return Ue(t)&&!Ue(r)&&(o=li(t,n)),Ue(t)&&Ue(r)?(r.forEach(function(i,a){if(sn.call(t,a)){var s=t[a];s&&typeof s=="object"&&i&&typeof i=="object"?t[a]=e(s,i,n):t.push(i)}else t[a]=i}),t):Object.keys(r).reduce(function(i,a){var s=r[a];return sn.call(i,a)?i[a]=e(i[a],s,n):i[a]=s,i},o)},Zu=function(t,r){return Object.keys(r).reduce(function(n,o){return n[o]=r[o],n},t)},ec=function(e,t,r){var n=e.replace(/\+/g," ");if(r==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},ln=1024,tc=function(t,r,n,o,i){if(t.length===0)return t;var a=t;if(typeof t=="symbol"?a=Symbol.prototype.toString.call(t):typeof t!="string"&&(a=String(t)),n==="iso-8859-1")return escape(a).replace(/%u[0-9a-f]{4}/gi,function(g){return"%26%23"+parseInt(g.slice(2),16)+"%3B"});for(var s="",l=0;l<a.length;l+=ln){for(var f=a.length>=ln?a.slice(l,l+ln):a,u=[],h=0;h<f.length;++h){var v=f.charCodeAt(h);if(v===45||v===46||v===95||v===126||v>=48&&v<=57||v>=65&&v<=90||v>=97&&v<=122||i===Yu.RFC1738&&(v===40||v===41)){u[u.length]=f.charAt(h);continue}if(v<128){u[u.length]=ve[v];continue}if(v<2048){u[u.length]=ve[192|v>>6]+ve[128|v&63];continue}if(v<55296||v>=57344){u[u.length]=ve[224|v>>12]+ve[128|v>>6&63]+ve[128|v&63];continue}h+=1,v=65536+((v&1023)<<10|f.charCodeAt(h)&1023),u[u.length]=ve[240|v>>18]+ve[128|v>>12&63]+ve[128|v>>6&63]+ve[128|v&63]}s+=u.join("")}return s},rc=function(t){for(var r=[{obj:{o:t},prop:"o"}],n=[],o=0;o<r.length;++o)for(var i=r[o],a=i.obj[i.prop],s=Object.keys(a),l=0;l<s.length;++l){var f=s[l],u=a[f];typeof u=="object"&&u!==null&&n.indexOf(u)===-1&&(r.push({obj:a,prop:f}),n.push(u))}return Xu(r),t},nc=function(t){return Object.prototype.toString.call(t)==="[object RegExp]"},oc=function(t){return!t||typeof t!="object"?!1:!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},ic=function(t,r){return[].concat(t,r)},ac=function(t,r){if(Ue(t)){for(var n=[],o=0;o<t.length;o+=1)n.push(r(t[o]));return n}return r(t)},ui={arrayToObject:li,assign:Zu,combine:ic,compact:rc,decode:ec,encode:tc,isBuffer:oc,isRegExp:nc,maybeMap:ac,merge:Qu},ci=Gu,er=ui,Tt=an,sc=Object.prototype.hasOwnProperty,fi={brackets:function(t){return t+"[]"},comma:"comma",indices:function(t,r){return t+"["+r+"]"},repeat:function(t){return t}},ge=Array.isArray,lc=Array.prototype.push,di=function(e,t){lc.apply(e,ge(t)?t:[t])},uc=Date.prototype.toISOString,pi=Tt.default,Y={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:er.encode,encodeValuesOnly:!1,format:pi,formatter:Tt.formatters[pi],indices:!1,serializeDate:function(t){return uc.call(t)},skipNulls:!1,strictNullHandling:!1},cc=function(t){return typeof t=="string"||typeof t=="number"||typeof t=="boolean"||typeof t=="symbol"||typeof t=="bigint"},un={},fc=function e(t,r,n,o,i,a,s,l,f,u,h,v,g,c,m,y,w,S){for(var x=t,O=S,T=0,P=!1;(O=O.get(un))!==void 0&&!P;){var _=O.get(t);if(T+=1,typeof _<"u"){if(_===T)throw new RangeError("Cyclic object value");P=!0}typeof O.get(un)>"u"&&(T=0)}if(typeof u=="function"?x=u(r,x):x instanceof Date?x=g(x):n==="comma"&&ge(x)&&(x=er.maybeMap(x,function(U){return U instanceof Date?g(U):U})),x===null){if(a)return f&&!y?f(r,Y.encoder,w,"key",c):r;x=""}if(cc(x)||er.isBuffer(x)){if(f){var j=y?r:f(r,Y.encoder,w,"key",c);return[m(j)+"="+m(f(x,Y.encoder,w,"value",c))]}return[m(r)+"="+m(String(x))]}var H=[];if(typeof x>"u")return H;var I;if(n==="comma"&&ge(x))y&&f&&(x=er.maybeMap(x,f)),I=[{value:x.length>0?x.join(",")||null:void 0}];else if(ge(u))I=u;else{var X=Object.keys(x);I=h?X.sort(h):X}var Z=l?r.replace(/\./g,"%2E"):r,C=o&&ge(x)&&x.length===1?Z+"[]":Z;if(i&&ge(x)&&x.length===0)return C+"[]";for(var L=0;L<I.length;++L){var K=I[L],ce=typeof K=="object"&&typeof K.value<"u"?K.value:x[K];if(!(s&&ce===null)){var ye=v&&l?K.replace(/\./g,"%2E"):K,we=ge(x)?typeof n=="function"?n(C,ye):C:C+(v?"."+ye:"["+ye+"]");S.set(t,T);var re=ci();re.set(un,S),di(H,e(ce,we,n,o,i,a,s,l,n==="comma"&&y&&ge(x)?null:f,u,h,v,g,c,m,y,w,re))}}return H},dc=function(t){if(!t)return Y;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.encodeDotInKeys<"u"&&typeof t.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(t.encoder!==null&&typeof t.encoder<"u"&&typeof t.encoder!="function")throw new TypeError("Encoder has to be a function.");var r=t.charset||Y.charset;if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=Tt.default;if(typeof t.format<"u"){if(!sc.call(Tt.formatters,t.format))throw new TypeError("Unknown format option provided.");n=t.format}var o=Tt.formatters[n],i=Y.filter;(typeof t.filter=="function"||ge(t.filter))&&(i=t.filter);var a;if(t.arrayFormat in fi?a=t.arrayFormat:"indices"in t?a=t.indices?"indices":"repeat":a=Y.arrayFormat,"commaRoundTrip"in t&&typeof t.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var s=typeof t.allowDots>"u"?t.encodeDotInKeys===!0?!0:Y.allowDots:!!t.allowDots;return{addQueryPrefix:typeof t.addQueryPrefix=="boolean"?t.addQueryPrefix:Y.addQueryPrefix,allowDots:s,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:Y.allowEmptyArrays,arrayFormat:a,charset:r,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:Y.charsetSentinel,commaRoundTrip:t.commaRoundTrip,delimiter:typeof t.delimiter>"u"?Y.delimiter:t.delimiter,encode:typeof t.encode=="boolean"?t.encode:Y.encode,encodeDotInKeys:typeof t.encodeDotInKeys=="boolean"?t.encodeDotInKeys:Y.encodeDotInKeys,encoder:typeof t.encoder=="function"?t.encoder:Y.encoder,encodeValuesOnly:typeof t.encodeValuesOnly=="boolean"?t.encodeValuesOnly:Y.encodeValuesOnly,filter:i,format:n,formatter:o,serializeDate:typeof t.serializeDate=="function"?t.serializeDate:Y.serializeDate,skipNulls:typeof t.skipNulls=="boolean"?t.skipNulls:Y.skipNulls,sort:typeof t.sort=="function"?t.sort:null,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:Y.strictNullHandling}},pc=function(e,t){var r=e,n=dc(t),o,i;typeof n.filter=="function"?(i=n.filter,r=i("",r)):ge(n.filter)&&(i=n.filter,o=i);var a=[];if(typeof r!="object"||r===null)return"";var s=fi[n.arrayFormat],l=s==="comma"&&n.commaRoundTrip;o||(o=Object.keys(r)),n.sort&&o.sort(n.sort);for(var f=ci(),u=0;u<o.length;++u){var h=o[u];n.skipNulls&&r[h]===null||di(a,fc(r[h],h,s,l,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,f))}var v=a.join(n.delimiter),g=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?g+="utf8=%26%2310003%3B&":g+="utf8=%E2%9C%93&"),v.length>0?g+v:""},lt=ui,cn=Object.prototype.hasOwnProperty,mc=Array.isArray,V={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:lt.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1},yc=function(e){return e.replace(/&#(\d+);/g,function(t,r){return String.fromCharCode(parseInt(r,10))})},mi=function(e,t){return e&&typeof e=="string"&&t.comma&&e.indexOf(",")>-1?e.split(","):e},hc="utf8=%26%2310003%3B",vc="utf8=%E2%9C%93",gc=function(t,r){var n={__proto__:null},o=r.ignoreQueryPrefix?t.replace(/^\?/,""):t;o=o.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var i=r.parameterLimit===1/0?void 0:r.parameterLimit,a=o.split(r.delimiter,i),s=-1,l,f=r.charset;if(r.charsetSentinel)for(l=0;l<a.length;++l)a[l].indexOf("utf8=")===0&&(a[l]===vc?f="utf-8":a[l]===hc&&(f="iso-8859-1"),s=l,l=a.length);for(l=0;l<a.length;++l)if(l!==s){var u=a[l],h=u.indexOf("]="),v=h===-1?u.indexOf("="):h+1,g,c;v===-1?(g=r.decoder(u,V.decoder,f,"key"),c=r.strictNullHandling?null:""):(g=r.decoder(u.slice(0,v),V.decoder,f,"key"),c=lt.maybeMap(mi(u.slice(v+1),r),function(y){return r.decoder(y,V.decoder,f,"value")})),c&&r.interpretNumericEntities&&f==="iso-8859-1"&&(c=yc(c)),u.indexOf("[]=")>-1&&(c=mc(c)?[c]:c);var m=cn.call(n,g);m&&r.duplicates==="combine"?n[g]=lt.combine(n[g],c):(!m||r.duplicates==="last")&&(n[g]=c)}return n},bc=function(e,t,r,n){for(var o=n?t:mi(t,r),i=e.length-1;i>=0;--i){var a,s=e[i];if(s==="[]"&&r.parseArrays)a=r.allowEmptyArrays&&(o===""||r.strictNullHandling&&o===null)?[]:[].concat(o);else{a=r.plainObjects?Object.create(null):{};var l=s.charAt(0)==="["&&s.charAt(s.length-1)==="]"?s.slice(1,-1):s,f=r.decodeDotInKeys?l.replace(/%2E/g,"."):l,u=parseInt(f,10);!r.parseArrays&&f===""?a={0:o}:!isNaN(u)&&s!==f&&String(u)===f&&u>=0&&r.parseArrays&&u<=r.arrayLimit?(a=[],a[u]=o):f!=="__proto__"&&(a[f]=o)}o=a}return o},wc=function(t,r,n,o){if(t){var i=n.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,a=/(\[[^[\]]*])/,s=/(\[[^[\]]*])/g,l=n.depth>0&&a.exec(i),f=l?i.slice(0,l.index):i,u=[];if(f){if(!n.plainObjects&&cn.call(Object.prototype,f)&&!n.allowPrototypes)return;u.push(f)}for(var h=0;n.depth>0&&(l=s.exec(i))!==null&&h<n.depth;){if(h+=1,!n.plainObjects&&cn.call(Object.prototype,l[1].slice(1,-1))&&!n.allowPrototypes)return;u.push(l[1])}if(l){if(n.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+n.depth+" and strictDepth is true");u.push("["+i.slice(l.index)+"]")}return bc(u,r,n,o)}},Ec=function(t){if(!t)return V;if(typeof t.allowEmptyArrays<"u"&&typeof t.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof t.decodeDotInKeys<"u"&&typeof t.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(t.decoder!==null&&typeof t.decoder<"u"&&typeof t.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof t.charset<"u"&&t.charset!=="utf-8"&&t.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=typeof t.charset>"u"?V.charset:t.charset,n=typeof t.duplicates>"u"?V.duplicates:t.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var o=typeof t.allowDots>"u"?t.decodeDotInKeys===!0?!0:V.allowDots:!!t.allowDots;return{allowDots:o,allowEmptyArrays:typeof t.allowEmptyArrays=="boolean"?!!t.allowEmptyArrays:V.allowEmptyArrays,allowPrototypes:typeof t.allowPrototypes=="boolean"?t.allowPrototypes:V.allowPrototypes,allowSparse:typeof t.allowSparse=="boolean"?t.allowSparse:V.allowSparse,arrayLimit:typeof t.arrayLimit=="number"?t.arrayLimit:V.arrayLimit,charset:r,charsetSentinel:typeof t.charsetSentinel=="boolean"?t.charsetSentinel:V.charsetSentinel,comma:typeof t.comma=="boolean"?t.comma:V.comma,decodeDotInKeys:typeof t.decodeDotInKeys=="boolean"?t.decodeDotInKeys:V.decodeDotInKeys,decoder:typeof t.decoder=="function"?t.decoder:V.decoder,delimiter:typeof t.delimiter=="string"||lt.isRegExp(t.delimiter)?t.delimiter:V.delimiter,depth:typeof t.depth=="number"||t.depth===!1?+t.depth:V.depth,duplicates:n,ignoreQueryPrefix:t.ignoreQueryPrefix===!0,interpretNumericEntities:typeof t.interpretNumericEntities=="boolean"?t.interpretNumericEntities:V.interpretNumericEntities,parameterLimit:typeof t.parameterLimit=="number"?t.parameterLimit:V.parameterLimit,parseArrays:t.parseArrays!==!1,plainObjects:typeof t.plainObjects=="boolean"?t.plainObjects:V.plainObjects,strictDepth:typeof t.strictDepth=="boolean"?!!t.strictDepth:V.strictDepth,strictNullHandling:typeof t.strictNullHandling=="boolean"?t.strictNullHandling:V.strictNullHandling}},Sc=function(e,t){var r=Ec(t);if(e===""||e===null||typeof e>"u")return r.plainObjects?Object.create(null):{};for(var n=typeof e=="string"?gc(e,r):e,o=r.plainObjects?Object.create(null):{},i=Object.keys(n),a=0;a<i.length;++a){var s=i[a],l=wc(s,n[s],r,typeof e=="string");o=lt.merge(o,l,r)}return r.allowSparse===!0?o:lt.compact(o)},xc=pc,Oc=Sc,Ac=an,yi={formats:Ac,parse:Oc,stringify:xc},Tc={exports:{}};/* NProgress, (c) 2013, 2014 Rico Sta. Cruz - http://ricostacruz.com/nprogress
|
|
39
|
-
* @license MIT */(function(e,t){(function(r,n){e.exports=n()})(wr,function(){var r={};r.version="0.2.0";var n=r.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,barSelector:'[role="bar"]',spinnerSelector:'[role="spinner"]',parent:"body",template:'<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'};r.configure=function(c){var m,y;for(m in c)y=c[m],y!==void 0&&c.hasOwnProperty(m)&&(n[m]=y);return this},r.status=null,r.set=function(c){var m=r.isStarted();c=o(c,n.minimum,1),r.status=c===1?null:c;var y=r.render(!m),w=y.querySelector(n.barSelector),S=n.speed,x=n.easing;return y.offsetWidth,s(function(O){n.positionUsing===""&&(n.positionUsing=r.getPositioningCSS()),l(w,a(c,S,x)),c===1?(l(y,{transition:"none",opacity:1}),y.offsetWidth,setTimeout(function(){l(y,{transition:"all "+S+"ms linear",opacity:0}),setTimeout(function(){r.remove(),O()},S)},S)):setTimeout(O,S)}),this},r.isStarted=function(){return typeof r.status=="number"},r.start=function(){r.status||r.set(0);var c=function(){setTimeout(function(){r.status&&(r.trickle(),c())},n.trickleSpeed)};return n.trickle&&c(),this},r.done=function(c){return!c&&!r.status?this:r.inc(.3+.5*Math.random()).set(1)},r.inc=function(c){var m=r.status;return m?(typeof c!="number"&&(c=(1-m)*o(Math.random()*m,.1,.95)),m=o(m+c,0,.994),r.set(m)):r.start()},r.trickle=function(){return r.inc(Math.random()*n.trickleRate)},function(){var c=0,m=0;r.promise=function(y){return!y||y.state()==="resolved"?this:(m===0&&r.start(),c++,m++,y.always(function(){m--,m===0?(c=0,r.done()):r.set((c-m)/c)}),this)}}(),r.render=function(c){if(r.isRendered())return document.getElementById("nprogress");u(document.documentElement,"nprogress-busy");var m=document.createElement("div");m.id="nprogress",m.innerHTML=n.template;var y=m.querySelector(n.barSelector),w=c?"-100":i(r.status||0),S=document.querySelector(n.parent),x;return l(y,{transition:"all 0 linear",transform:"translate3d("+w+"%,0,0)"}),n.showSpinner||(x=m.querySelector(n.spinnerSelector),x&&g(x)),S!=document.body&&u(S,"nprogress-custom-parent"),S.appendChild(m),m},r.remove=function(){h(document.documentElement,"nprogress-busy"),h(document.querySelector(n.parent),"nprogress-custom-parent");var c=document.getElementById("nprogress");c&&g(c)},r.isRendered=function(){return!!document.getElementById("nprogress")},r.getPositioningCSS=function(){var c=document.body.style,m="WebkitTransform"in c?"Webkit":"MozTransform"in c?"Moz":"msTransform"in c?"ms":"OTransform"in c?"O":"";return m+"Perspective"in c?"translate3d":m+"Transform"in c?"translate":"margin"};function o(c,m,y){return c<m?m:c>y?y:c}function i(c){return(-1+c)*100}function a(c,m,y){var w;return n.positionUsing==="translate3d"?w={transform:"translate3d("+i(c)+"%,0,0)"}:n.positionUsing==="translate"?w={transform:"translate("+i(c)+"%,0)"}:w={"margin-left":i(c)+"%"},w.transition="all "+m+"ms "+y,w}var s=function(){var c=[];function m(){var y=c.shift();y&&y(m)}return function(y){c.push(y),c.length==1&&m()}}(),l=function(){var c=["Webkit","O","Moz","ms"],m={};function y(O){return O.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(T,P){return P.toUpperCase()})}function w(O){var T=document.body.style;if(O in T)return O;for(var P=c.length,_=O.charAt(0).toUpperCase()+O.slice(1),j;P--;)if(j=c[P]+_,j in T)return j;return O}function S(O){return O=y(O),m[O]||(m[O]=w(O))}function x(O,T,P){T=S(T),O.style[T]=P}return function(O,T){var P=arguments,_,j;if(P.length==2)for(_ in T)j=T[_],j!==void 0&&T.hasOwnProperty(_)&&x(O,_,j);else x(O,P[1],P[2])}}();function f(c,m){var y=typeof c=="string"?c:v(c);return y.indexOf(" "+m+" ")>=0}function u(c,m){var y=v(c),w=y+m;f(y,m)||(c.className=w.substring(1))}function h(c,m){var y=v(c),w;f(c,m)&&(w=y.replace(" "+m+" "," "),c.className=w.substring(1,w.length-1))}function v(c){return(" "+(c.className||"")+" ").replace(/\s+/gi," ")}function g(c){c&&c.parentNode&&c.parentNode.removeChild(c)}return r})})(Tc);function Pc(e,t,r,n="brackets"){let o=/^https?:\/\//.test(t.toString()),i=o||t.toString().startsWith("/"),a=!i&&!t.toString().startsWith("#")&&!t.toString().startsWith("?"),s=t.toString().includes("?")||e==="get"&&Object.keys(r).length,l=t.toString().includes("#"),f=new URL(t.toString(),"http://localhost");return e==="get"&&Object.keys(r).length&&(f.search=yi.stringify(cl(yi.parse(f.search,{ignoreQueryPrefix:!0}),r),{encodeValuesOnly:!0,arrayFormat:n}),r={}),[[o?`${f.protocol}//${f.host}`:"",i?f.pathname:"",a?f.pathname.substring(1):"",s?f.search:"",l?f.hash:""].join(""),r]}const tr=p.createContext(null);tr.displayName="ModalStackContext";const Cc=({children:e})=>{const[t,r]=p.useState([]),[n,o]=p.useState({});class i{constructor(c,m,y,w,S){Se(this,"updateStack",c=>{r(m=>{const y=c([...m]);return y.forEach((w,S)=>{y[S].index=S,y[S].onTopOfStack=S===y.length-1}),y})});Se(this,"setOpen",c=>{c?this.open=!0:this.close()});Se(this,"close",()=>{this.updateStack(c=>c.map(m=>{var y;return m.id===this.id&&(Object.keys(m.listeners).forEach(w=>{m.off(w)}),m.open=!1,(y=m.onCloseCallback)==null||y.call(m)),m}))});Se(this,"afterLeave",()=>{this.open||this.updateStack(c=>c.filter(m=>{var y;return m.id!==this.id?!0:((y=m.afterLeaveCallback)==null||y.call(m),!1)}))});Se(this,"on",(c,m)=>{this.listeners[c]=this.listeners[c]??[],this.listeners[c].push(m)});Se(this,"off",(c,m)=>{var y;m?this.listeners[c]=((y=this.listeners[c])==null?void 0:y.filter(w=>w!==m))??[]:delete this.listeners[c]});Se(this,"emit",(c,...m)=>{var y;return console.log("Emitting",c,"with args",m),(y=this.listeners[c])==null||y.forEach(w=>w(...m)),"OK"});Se(this,"registerEventListenersFromProps",c=>{const m=[];return Object.keys(c).filter(y=>y.startsWith("on")).forEach(y=>{const w=y.replace(/^on/,"").replace(/^./,S=>S.toLowerCase()).replace(/([A-Z])/g,"-$1").toLowerCase();this.on(w,c[y]),m.push(()=>this.off(w,c[y]))}),()=>m.forEach(y=>y())});Se(this,"reload",(c={})=>{let m=Object.keys(this.response.props);c.only&&(m=xo(m,c.only)),c.except&&(m=Gs(m,c.except)),z.get(this.response.url,{headers:{Accept:"text/html, application/xhtml+xml","X-Inertia":!0,"X-Inertia-Partial-Component":this.response.component,"X-Inertia-Version":this.response.version,"X-Inertia-Partial-Data":m.join(",")}}).then(y=>{Object.assign(this.componentProps,y.data.props),r(w=>[...w])})});this.id=i.generateId(),this.open=!0,this.listeners={},this.component=c,this.componentProps=m.props,this.response=m,this.modalProps=y,this.onCloseCallback=w,this.afterLeaveCallback=S,this.index=-1,this.getParentModal=()=>null,this.getChildModal=()=>null,this.onTopOfStack=!0}static generateId(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?`inertiaui_modal_${crypto.randomUUID()}`:`inertiaui_modal_${Date.now().toString(36)}_${Math.random().toString(36).substr(2,9)}`}}const a=(g,c,m,y,w)=>{const S=new i(g,c,m,y,w);return r(x=>{const O=[...x,S];return O.forEach((T,P)=>{T.index=P,T.onTopOfStack=P===O.length-1}),O.forEach((T,P)=>{T.getParentModal=()=>P>0?O[P-1]:null,T.getChildModal=()=>P<O.length-1?O[P+1]:null}),O}),S};function s(g,c,m,y){if(!n[g])throw new Error(`The local modal "${g}" has not been registered.`);const w=a(null,{},c,m,y);return w.name=g,n[g].callback(w),w}const l=(g,c={})=>f(g,c.method??"get",c.data??{},c.headers??{},c.config??{},c.onClose,c.onAfterLeave,c.queryStringArrayFormat??"brackets"),f=(g,c,m={},y={},w={},S=null,x=null,O="brackets")=>new Promise((T,P)=>{if(g.startsWith("#")){const H=s(g.substring(1),w,S,x);T(H);return}const[_,j]=Pc(c,g||"",m,O);Js().then(H=>{z({url:_,method:c,data:j,headers:{...y,Accept:"text/html, application/xhtml+xml","X-Requested-With":"XMLHttpRequest","X-Inertia":!0,"X-Inertia-Version":H.version,"X-InertiaUI-Modal":!0}}).then(I=>{De.router.resolveComponent(I.data.component).then(X=>{T(a(X,I.data,w,S,x))})}).catch(I=>{P(I)})})}),v={stack:t,localModals:n,push:a,reset:()=>r([]),visit:f,visitModal:l,registerLocalModal:(g,c)=>{o(m=>({...m,[g]:{name:g,callback:c}}))},removeLocalModal:g=>{o(c=>{const m={...c};return delete m[g],m})}};return R.jsx(tr.Provider,{value:v,children:e})},rr=()=>{const e=p.useContext(tr);if(e===null)throw new Error("useModalStack must be used within a ModalStackProvider");return e},hi=["closeButton","closeExplicitly","maxWidth","paddingClasses","panelClasses","position","slideover"],Fc=({children:e})=>{const t=p.useContext(tr).stack;return R.jsxs(R.Fragment,{children:[e,t.length>0&&R.jsx(gi,{index:0})]})},fn=p.createContext(null);fn.displayName="ModalIndexContext";const vi=()=>{const e=p.useContext(fn);if(e===void 0)throw new Error("useModalIndex must be used within a ModalIndexProvider");return e},gi=({index:e})=>{const{stack:t}=rr(),r=t[e];return!r||!r.component?null:R.jsx(fn.Provider,{value:e,children:R.jsx(r.component,{...r.componentProps,onModalEvent:(...n)=>r.emit(...n)})})},dn=p.forwardRef(({name:e,children:t,...r},n)=>{const o=vi(),{stack:i,registerLocalModal:a,removeLocalModal:s}=rr(),[l,f]=p.useState(null),u=p.useMemo(()=>e?l:i[o]),h=p.useMemo(()=>(u==null?void 0:u.modalProps.slideover)??r.slideover??Dn("type")==="slideover",[r.slideover]),v=p.useMemo(()=>({slideover:h,closeButton:r.closeButton??Ye(h,"closeButton"),closeExplicitly:r.closeExplicitly??Ye(h,"closeExplicitly"),maxWidth:r.maxWidth??Ye(h,"maxWidth"),paddingClasses:r.paddingClasses??Ye(h,"paddingClasses"),panelClasses:r.panelClasses??Ye(h,"panelClasses"),position:r.position??Ye(h,"position"),...u==null?void 0:u.modalProps}),[r,u==null?void 0:u.modalProps]);return p.useEffect(()=>{if(e){let g=null;return a(e,c=>{g=c.registerEventListenersFromProps(r),f(c)}),()=>{g==null||g(),g=null,s(e)}}return u.registerEventListenersFromProps(r)},[e]),p.useImperativeHandle(n,()=>({afterLeave:()=>u.afterLeave(),close:()=>u.close(),emit:(...g)=>u.emit(...g),getChildModal:()=>u.getChildModal(),getParentModal:()=>u.getParentModal(),index:u==null?void 0:u.index,isOpen:u==null?void 0:u.open,modalContext:u,modalProps:v,reload:()=>u.reload(),setOpen:()=>u.setOpen()}),[u]),u&&R.jsxs(R.Fragment,{children:[typeof t=="function"?t({afterLeave:u.afterLeave,close:u.close,emit:u.emit,getChildModal:u.getChildModal,getParentModal:u.getParentModal,index:u.index,isOpen:u.open,modalContext:u,modalProps:v,reload:u.reload,setOpen:u.setOpen}):t,i[u.index+1]&&R.jsx(gi,{index:u.index+1})]})});dn.displayName="HeadlessModal";function bi(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(r=bi(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function nr(){for(var e,t,r=0,n="",o=arguments.length;r<o;r++)(e=arguments[r])&&(t=bi(e))&&(n&&(n+=" "),n+=t);return n}var $c=Object.defineProperty,_c=(e,t,r)=>t in e?$c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,pn=(e,t,r)=>(_c(e,typeof t!="symbol"?t+"":t,r),r);let Nc=class{constructor(){pn(this,"current",this.detect()),pn(this,"handoffState","pending"),pn(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},We=new Nc;function or(e){return We.isServer?null:e instanceof Node?e.ownerDocument:e!=null&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}function ir(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function Fe(){let e=[],t={addEventListener(r,n,o,i){return r.addEventListener(n,o,i),t.add(()=>r.removeEventListener(n,o,i))},requestAnimationFrame(...r){let n=requestAnimationFrame(...r);return t.add(()=>cancelAnimationFrame(n))},nextFrame(...r){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...r))},setTimeout(...r){let n=setTimeout(...r);return t.add(()=>clearTimeout(n))},microTask(...r){let n={current:!0};return ir(()=>{n.current&&r[0]()}),t.add(()=>{n.current=!1})},style(r,n,o){let i=r.style.getPropertyValue(n);return Object.assign(r.style,{[n]:o}),this.add(()=>{Object.assign(r.style,{[n]:i})})},group(r){let n=Fe();return r(n),this.add(()=>n.dispose())},add(r){return e.includes(r)||e.push(r),()=>{let n=e.indexOf(r);if(n>=0)for(let o of e.splice(n,1))o()}},dispose(){for(let r of e.splice(0))r()}};return t}function mn(){let[e]=p.useState(Fe);return p.useEffect(()=>()=>e.dispose(),[e]),e}let ne=(e,t)=>{We.isServer?p.useEffect(e,t):p.useLayoutEffect(e,t)};function He(e){let t=p.useRef(e);return ne(()=>{t.current=e},[e]),t}let q=function(e){let t=He(e);return p.useCallback((...r)=>t.current(...r),[t])},Mc=p.createContext(void 0);function Rc(){return p.useContext(Mc)}function yn(...e){return Array.from(new Set(e.flatMap(t=>typeof t=="string"?t.split(" "):[]))).filter(Boolean).join(" ")}function $e(e,t,...r){if(e in t){let o=t[e];return typeof o=="function"?o(...r):o}let n=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(o=>`"${o}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,$e),n}var ar=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(ar||{}),_e=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(_e||{});function fe({ourProps:e,theirProps:t,slot:r,defaultTag:n,features:o,visible:i=!0,name:a,mergeRefs:s}){s=s??Dc;let l=wi(t,e);if(i)return sr(l,r,n,a,s);let f=o??0;if(f&2){let{static:u=!1,...h}=l;if(u)return sr(h,r,n,a,s)}if(f&1){let{unmount:u=!0,...h}=l;return $e(u?0:1,{0(){return null},1(){return sr({...h,hidden:!0,style:{display:"none"}},r,n,a,s)}})}return sr(l,r,n,a,s)}function sr(e,t={},r,n,o){let{as:i=r,children:a,refName:s="ref",...l}=hn(e,["unmount","static"]),f=e.ref!==void 0?{[s]:e.ref}:{},u=typeof a=="function"?a(t):a;"className"in l&&l.className&&typeof l.className=="function"&&(l.className=l.className(t)),l["aria-labelledby"]&&l["aria-labelledby"]===l.id&&(l["aria-labelledby"]=void 0);let h={};if(t){let v=!1,g=[];for(let[c,m]of Object.entries(t))typeof m=="boolean"&&(v=!0),m===!0&&g.push(c.replace(/([A-Z])/g,y=>`-${y.toLowerCase()}`));if(v){h["data-headlessui-state"]=g.join(" ");for(let c of g)h[`data-${c}`]=""}}if(i===p.Fragment&&(Object.keys(qe(l)).length>0||Object.keys(qe(h)).length>0))if(!p.isValidElement(u)||Array.isArray(u)&&u.length>1){if(Object.keys(qe(l)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${n} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(qe(l)).concat(Object.keys(qe(h))).map(v=>` - ${v}`).join(`
|
|
40
|
-
`),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(v=>` - ${v}`).join(`
|
|
30
|
+
<%s key={someKey} {...props} />`,Xr,We,ec,We),Ko[We+Xr]=!0}}return c===n?Ks(Y):Ys(Y),Y}}function Xs(c,S,O){return Xo(c,S,O,!0)}function Js(c,S,O){return Xo(c,S,O,!1)}var Qs=Js,Zs=Xs;ot.Fragment=n,ot.jsx=Qs,ot.jsxs=Zs}()),ot}process.env.NODE_ENV==="production"?Qt.exports=oi():Qt.exports=ii();var $=Qt.exports;function ai(t,e){return Array.isArray(t)?t.filter(r=>!e.includes(r)):Object.keys(t).reduce((r,n)=>(e.includes(n)||(r[n]=t[n]),r),{})}function Zr(t,e){return Array.isArray(t)?t.filter(r=>e.includes(r)):e.reduce((r,n)=>(n in t&&(r[n]=t[n]),r),{})}function li(t){return Array.isArray(t)?t.filter(e=>e!==null):Object.keys(t).reduce((e,r)=>(r in t&&t[r]!==null&&(e[r]=t[r]),e),{})}function ui(t,e=3,r=10){return new Promise((n,o)=>{const i=t();if(i){n(i);return}let l=e*1e3/r;const u=setInterval(()=>{const a=t();a&&(clearInterval(u),n(a)),--l<=0&&(clearInterval(u),o(new Error("Condition not met in time")))},r)})}var si=function(e){return ci(e)&&!fi(e)};function ci(t){return!!t&&typeof t=="object"}function fi(t){var e=Object.prototype.toString.call(t);return e==="[object RegExp]"||e==="[object Date]"||yi(t)}var di=typeof Symbol=="function"&&Symbol.for,pi=di?Symbol.for("react.element"):60103;function yi(t){return t.$$typeof===pi}function vi(t){return Array.isArray(t)?[]:{}}function it(t,e){return e.clone!==!1&&e.isMergeableObject(t)?Be(vi(t),t,e):t}function mi(t,e,r){return t.concat(e).map(function(n){return it(n,r)})}function hi(t,e){if(!e.customMerge)return Be;var r=e.customMerge(t);return typeof r=="function"?r:Be}function gi(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter(function(e){return Object.propertyIsEnumerable.call(t,e)}):[]}function en(t){return Object.keys(t).concat(gi(t))}function tn(t,e){try{return e in t}catch{return!1}}function bi(t,e){return tn(t,e)&&!(Object.hasOwnProperty.call(t,e)&&Object.propertyIsEnumerable.call(t,e))}function wi(t,e,r){var n={};return r.isMergeableObject(t)&&en(t).forEach(function(o){n[o]=it(t[o],r)}),en(e).forEach(function(o){bi(t,o)||(tn(t,o)&&r.isMergeableObject(e[o])?n[o]=hi(o,r)(t[o],e[o],r):n[o]=it(e[o],r))}),n}function Be(t,e,r){r=r||{},r.arrayMerge=r.arrayMerge||mi,r.isMergeableObject=r.isMergeableObject||si,r.cloneUnlessOtherwiseSpecified=it;var n=Array.isArray(e),o=Array.isArray(t),i=n===o;return i?n?r.arrayMerge(t,e,r):wi(t,e,r):it(e,r)}Be.all=function(e,r){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(n,o){return Be(n,o,r)},{})};var Ei=Be,Si=Ei;const xi=ri(Si);var Oi=Error,Pi=EvalError,Ai=RangeError,Ti=ReferenceError,rn=SyntaxError,at=TypeError,$i=URIError,Ci=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;e[r]=o;for(r in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var i=Object.getOwnPropertySymbols(e);if(i.length!==1||i[0]!==r||!Object.prototype.propertyIsEnumerable.call(e,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var l=Object.getOwnPropertyDescriptor(e,r);if(l.value!==o||l.enumerable!==!0)return!1}return!0},nn=typeof Symbol<"u"&&Symbol,Fi=Ci,Mi=function(){return typeof nn!="function"||typeof Symbol!="function"||typeof nn("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Fi()},Zt={__proto__:null,foo:{}},Ii=Object,_i=function(){return{__proto__:Zt}.foo===Zt.foo&&!(Zt instanceof Ii)},Di="Function.prototype.bind called on incompatible ",ki=Object.prototype.toString,Ni=Math.max,ji="[object Function]",on=function(e,r){for(var n=[],o=0;o<e.length;o+=1)n[o]=e[o];for(var i=0;i<r.length;i+=1)n[i+e.length]=r[i];return n},Li=function(e,r){for(var n=[],o=r,i=0;o<e.length;o+=1,i+=1)n[i]=e[o];return n},Wi=function(t,e){for(var r="",n=0;n<t.length;n+=1)r+=t[n],n+1<t.length&&(r+=e);return r},Ui=function(e){var r=this;if(typeof r!="function"||ki.apply(r)!==ji)throw new TypeError(Di+r);for(var n=Li(arguments,1),o,i=function(){if(this instanceof o){var s=r.apply(this,on(n,arguments));return Object(s)===s?s:this}return r.apply(e,on(n,arguments))},l=Ni(0,r.length-n.length),u=[],a=0;a<l;a++)u[a]="$"+a;if(o=Function("binder","return function ("+Wi(u,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var p=function(){};p.prototype=r.prototype,o.prototype=new p,p.prototype=null}return o},Bi=Ui,er=Function.prototype.bind||Bi,Ri=Function.prototype.call,Hi=Object.prototype.hasOwnProperty,Vi=er,qi=Vi.call(Ri,Hi),F,Gi=Oi,zi=Pi,Yi=Ai,Ki=Ti,Re=rn,He=at,Xi=$i,an=Function,tr=function(t){try{return an('"use strict"; return ('+t+").constructor;")()}catch{}},$e=Object.getOwnPropertyDescriptor;if($e)try{$e({},"")}catch{$e=null}var rr=function(){throw new He},Ji=$e?function(){try{return arguments.callee,rr}catch{try{return $e(arguments,"callee").get}catch{return rr}}}():rr,Ve=Mi(),Qi=_i(),X=Object.getPrototypeOf||(Qi?function(t){return t.__proto__}:null),qe={},Zi=typeof Uint8Array>"u"||!X?F:X(Uint8Array),Ce={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?F:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?F:ArrayBuffer,"%ArrayIteratorPrototype%":Ve&&X?X([][Symbol.iterator]()):F,"%AsyncFromSyncIteratorPrototype%":F,"%AsyncFunction%":qe,"%AsyncGenerator%":qe,"%AsyncGeneratorFunction%":qe,"%AsyncIteratorPrototype%":qe,"%Atomics%":typeof Atomics>"u"?F:Atomics,"%BigInt%":typeof BigInt>"u"?F:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?F:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?F:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?F:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Gi,"%eval%":eval,"%EvalError%":zi,"%Float32Array%":typeof Float32Array>"u"?F:Float32Array,"%Float64Array%":typeof Float64Array>"u"?F:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?F:FinalizationRegistry,"%Function%":an,"%GeneratorFunction%":qe,"%Int8Array%":typeof Int8Array>"u"?F:Int8Array,"%Int16Array%":typeof Int16Array>"u"?F:Int16Array,"%Int32Array%":typeof Int32Array>"u"?F:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Ve&&X?X(X([][Symbol.iterator]())):F,"%JSON%":typeof JSON=="object"?JSON:F,"%Map%":typeof Map>"u"?F:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Ve||!X?F:X(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?F:Promise,"%Proxy%":typeof Proxy>"u"?F:Proxy,"%RangeError%":Yi,"%ReferenceError%":Ki,"%Reflect%":typeof Reflect>"u"?F:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?F:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Ve||!X?F:X(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?F:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Ve&&X?X(""[Symbol.iterator]()):F,"%Symbol%":Ve?Symbol:F,"%SyntaxError%":Re,"%ThrowTypeError%":Ji,"%TypedArray%":Zi,"%TypeError%":He,"%Uint8Array%":typeof Uint8Array>"u"?F:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?F:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?F:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?F:Uint32Array,"%URIError%":Xi,"%WeakMap%":typeof WeakMap>"u"?F:WeakMap,"%WeakRef%":typeof WeakRef>"u"?F:WeakRef,"%WeakSet%":typeof WeakSet>"u"?F:WeakSet};if(X)try{null.error}catch(t){var ea=X(X(t));Ce["%Error.prototype%"]=ea}var ta=function t(e){var r;if(e==="%AsyncFunction%")r=tr("async function () {}");else if(e==="%GeneratorFunction%")r=tr("function* () {}");else if(e==="%AsyncGeneratorFunction%")r=tr("async function* () {}");else if(e==="%AsyncGenerator%"){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(e==="%AsyncIteratorPrototype%"){var o=t("%AsyncGenerator%");o&&X&&(r=X(o.prototype))}return Ce[e]=r,r},ln={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},lt=er,xt=qi,ra=lt.call(Function.call,Array.prototype.concat),na=lt.call(Function.apply,Array.prototype.splice),un=lt.call(Function.call,String.prototype.replace),Ot=lt.call(Function.call,String.prototype.slice),oa=lt.call(Function.call,RegExp.prototype.exec),ia=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,aa=/\\(\\)?/g,la=function(e){var r=Ot(e,0,1),n=Ot(e,-1);if(r==="%"&&n!=="%")throw new Re("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new Re("invalid intrinsic syntax, expected opening `%`");var o=[];return un(e,ia,function(i,l,u,a){o[o.length]=u?un(a,aa,"$1"):l||i}),o},ua=function(e,r){var n=e,o;if(xt(ln,n)&&(o=ln[n],n="%"+o[0]+"%"),xt(Ce,n)){var i=Ce[n];if(i===qe&&(i=ta(n)),typeof i>"u"&&!r)throw new He("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new Re("intrinsic "+e+" does not exist!")},Ge=function(e,r){if(typeof e!="string"||e.length===0)throw new He("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new He('"allowMissing" argument must be a boolean');if(oa(/^%?[^%]*%?$/,e)===null)throw new Re("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=la(e),o=n.length>0?n[0]:"",i=ua("%"+o+"%",r),l=i.name,u=i.value,a=!1,p=i.alias;p&&(o=p[0],na(n,ra([0,1],p)));for(var s=1,g=!0;s<n.length;s+=1){var m=n[s],E=Ot(m,0,1),d=Ot(m,-1);if((E==='"'||E==="'"||E==="`"||d==='"'||d==="'"||d==="`")&&E!==d)throw new Re("property names with quotes must have matching quotes");if((m==="constructor"||!g)&&(a=!0),o+="."+m,l="%"+o+"%",xt(Ce,l))u=Ce[l];else if(u!=null){if(!(m in u)){if(!r)throw new He("base intrinsic for "+e+" exists, but the property is not available.");return}if($e&&s+1>=n.length){var v=$e(u,m);g=!!v,g&&"get"in v&&!("originalValue"in v.get)?u=v.get:u=u[m]}else g=xt(u,m),u=u[m];g&&!a&&(Ce[l]=u)}}return u},sn={exports:{}},nr,cn;function or(){if(cn)return nr;cn=1;var t=Ge,e=t("%Object.defineProperty%",!0)||!1;if(e)try{e({},"a",{value:1})}catch{e=!1}return nr=e,nr}var sa=Ge,Pt=sa("%Object.getOwnPropertyDescriptor%",!0);if(Pt)try{Pt([],"length")}catch{Pt=null}var fn=Pt,dn=or(),ca=rn,ze=at,pn=fn,fa=function(e,r,n){if(!e||typeof e!="object"&&typeof e!="function")throw new ze("`obj` must be an object or a function`");if(typeof r!="string"&&typeof r!="symbol")throw new ze("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new ze("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new ze("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new ze("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new ze("`loose`, if provided, must be a boolean");var o=arguments.length>3?arguments[3]:null,i=arguments.length>4?arguments[4]:null,l=arguments.length>5?arguments[5]:null,u=arguments.length>6?arguments[6]:!1,a=!!pn&&pn(e,r);if(dn)dn(e,r,{configurable:l===null&&a?a.configurable:!l,enumerable:o===null&&a?a.enumerable:!o,value:n,writable:i===null&&a?a.writable:!i});else if(u||!o&&!i&&!l)e[r]=n;else throw new ca("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},ir=or(),yn=function(){return!!ir};yn.hasArrayLengthDefineBug=function(){if(!ir)return null;try{return ir([],"length",{value:1}).length!==1}catch{return!0}};var da=yn,pa=Ge,vn=fa,ya=da(),mn=fn,hn=at,va=pa("%Math.floor%"),ma=function(e,r){if(typeof e!="function")throw new hn("`fn` is not a function");if(typeof r!="number"||r<0||r>4294967295||va(r)!==r)throw new hn("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],o=!0,i=!0;if("length"in e&&mn){var l=mn(e,"length");l&&!l.configurable&&(o=!1),l&&!l.writable&&(i=!1)}return(o||i||!n)&&(ya?vn(e,"length",r,!0,!0):vn(e,"length",r)),e};(function(t){var e=er,r=Ge,n=ma,o=at,i=r("%Function.prototype.apply%"),l=r("%Function.prototype.call%"),u=r("%Reflect.apply%",!0)||e.call(l,i),a=or(),p=r("%Math.max%");t.exports=function(m){if(typeof m!="function")throw new o("a function is required");var E=u(e,l,arguments);return n(E,1+p(0,m.length-(arguments.length-1)),!0)};var s=function(){return u(e,i,arguments)};a?a(t.exports,"apply",{value:s}):t.exports.apply=s})(sn);var ha=sn.exports,gn=Ge,bn=ha,ga=bn(gn("String.prototype.indexOf")),ba=function(e,r){var n=gn(e,!!r);return typeof n=="function"&&ga(e,".prototype.")>-1?bn(n):n};const wa=ni(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var ar=typeof Map=="function"&&Map.prototype,lr=Object.getOwnPropertyDescriptor&&ar?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,At=ar&&lr&&typeof lr.get=="function"?lr.get:null,wn=ar&&Map.prototype.forEach,ur=typeof Set=="function"&&Set.prototype,sr=Object.getOwnPropertyDescriptor&&ur?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Tt=ur&&sr&&typeof sr.get=="function"?sr.get:null,En=ur&&Set.prototype.forEach,Ea=typeof WeakMap=="function"&&WeakMap.prototype,ut=Ea?WeakMap.prototype.has:null,Sa=typeof WeakSet=="function"&&WeakSet.prototype,st=Sa?WeakSet.prototype.has:null,xa=typeof WeakRef=="function"&&WeakRef.prototype,Sn=xa?WeakRef.prototype.deref:null,Oa=Boolean.prototype.valueOf,Pa=Object.prototype.toString,Aa=Function.prototype.toString,Ta=String.prototype.match,cr=String.prototype.slice,Ee=String.prototype.replace,$a=String.prototype.toUpperCase,xn=String.prototype.toLowerCase,On=RegExp.prototype.test,Pn=Array.prototype.concat,fe=Array.prototype.join,Ca=Array.prototype.slice,An=Math.floor,fr=typeof BigInt=="function"?BigInt.prototype.valueOf:null,dr=Object.getOwnPropertySymbols,pr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,Ye=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Q=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===Ye||!0)?Symbol.toStringTag:null,Tn=Object.prototype.propertyIsEnumerable,$n=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(t){return t.__proto__}:null);function Cn(t,e){if(t===1/0||t===-1/0||t!==t||t&&t>-1e3&&t<1e3||On.call(/e/,e))return e;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof t=="number"){var n=t<0?-An(-t):An(t);if(n!==t){var o=String(n),i=cr.call(e,o.length+1);return Ee.call(o,r,"$&_")+"."+Ee.call(Ee.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Ee.call(e,r,"$&_")}var yr=wa,Fn=yr.custom,Mn=Dn(Fn)?Fn:null,Fa=function t(e,r,n,o){var i=r||{};if(Se(i,"quoteStyle")&&i.quoteStyle!=="single"&&i.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(Se(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var l=Se(i,"customInspect")?i.customInspect:!0;if(typeof l!="boolean"&&l!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(Se(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(Se(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var u=i.numericSeparator;if(typeof e>"u")return"undefined";if(e===null)return"null";if(typeof e=="boolean")return e?"true":"false";if(typeof e=="string")return Nn(e,i);if(typeof e=="number"){if(e===0)return 1/0/e>0?"0":"-0";var a=String(e);return u?Cn(e,a):a}if(typeof e=="bigint"){var p=String(e)+"n";return u?Cn(e,p):p}var s=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=s&&s>0&&typeof e=="object")return vr(e)?"[Array]":"[Object]";var g=Ya(i,n);if(typeof o>"u")o=[];else if(kn(o,e)>=0)return"[Circular]";function m(C,T,k){if(T&&(o=Ca.call(o),o.push(T)),k){var oe={depth:i.depth};return Se(i,"quoteStyle")&&(oe.quoteStyle=i.quoteStyle),t(C,oe,n+1,o)}return t(C,i,n+1,o)}if(typeof e=="function"&&!_n(e)){var E=Wa(e),d=$t(e,m);return"[Function"+(E?": "+E:" (anonymous)")+"]"+(d.length>0?" { "+fe.call(d,", ")+" }":"")}if(Dn(e)){var v=Ye?Ee.call(String(e),/^(Symbol\(.*\))_[^)]*$/,"$1"):pr.call(e);return typeof e=="object"&&!Ye?ct(v):v}if(qa(e)){for(var y="<"+xn.call(String(e.nodeName)),h=e.attributes||[],b=0;b<h.length;b++)y+=" "+h[b].name+"="+In(Ma(h[b].value),"double",i);return y+=">",e.childNodes&&e.childNodes.length&&(y+="..."),y+="</"+xn.call(String(e.nodeName))+">",y}if(vr(e)){if(e.length===0)return"[]";var w=$t(e,m);return g&&!za(w)?"["+hr(w,g)+"]":"[ "+fe.call(w,", ")+" ]"}if(_a(e)){var x=$t(e,m);return!("cause"in Error.prototype)&&"cause"in e&&!Tn.call(e,"cause")?"{ ["+String(e)+"] "+fe.call(Pn.call("[cause]: "+m(e.cause),x),", ")+" }":x.length===0?"["+String(e)+"]":"{ ["+String(e)+"] "+fe.call(x,", ")+" }"}if(typeof e=="object"&&l){if(Mn&&typeof e[Mn]=="function"&&yr)return yr(e,{depth:s-n});if(l!=="symbol"&&typeof e.inspect=="function")return e.inspect()}if(Ua(e)){var P=[];return wn&&wn.call(e,function(C,T){P.push(m(T,e,!0)+" => "+m(C,e))}),jn("Map",At.call(e),P,g)}if(Ha(e)){var D=[];return En&&En.call(e,function(C){D.push(m(C,e))}),jn("Set",Tt.call(e),D,g)}if(Ba(e))return mr("WeakMap");if(Va(e))return mr("WeakSet");if(Ra(e))return mr("WeakRef");if(ka(e))return ct(m(Number(e)));if(ja(e))return ct(m(fr.call(e)));if(Na(e))return ct(Oa.call(e));if(Da(e))return ct(m(String(e)));if(typeof window<"u"&&e===window)return"{ [object Window] }";if(typeof globalThis<"u"&&e===globalThis||typeof Jt<"u"&&e===Jt)return"{ [object globalThis] }";if(!Ia(e)&&!_n(e)){var _=$t(e,m),U=$n?$n(e)===Object.prototype:e instanceof Object||e.constructor===Object,H=e instanceof Object?"":"null prototype",j=!U&&Q&&Object(e)===e&&Q in e?cr.call(xe(e),8,-1):H?"Object":"",z=U||typeof e.constructor!="function"?"":e.constructor.name?e.constructor.name+" ":"",V=z+(j||H?"["+fe.call(Pn.call([],j||[],H||[]),": ")+"] ":"");return _.length===0?V+"{}":g?V+"{"+hr(_,g)+"}":V+"{ "+fe.call(_,", ")+" }"}return String(e)};function In(t,e,r){var n=(r.quoteStyle||e)==="double"?'"':"'";return n+t+n}function Ma(t){return Ee.call(String(t),/"/g,""")}function vr(t){return xe(t)==="[object Array]"&&(!Q||!(typeof t=="object"&&Q in t))}function Ia(t){return xe(t)==="[object Date]"&&(!Q||!(typeof t=="object"&&Q in t))}function _n(t){return xe(t)==="[object RegExp]"&&(!Q||!(typeof t=="object"&&Q in t))}function _a(t){return xe(t)==="[object Error]"&&(!Q||!(typeof t=="object"&&Q in t))}function Da(t){return xe(t)==="[object String]"&&(!Q||!(typeof t=="object"&&Q in t))}function ka(t){return xe(t)==="[object Number]"&&(!Q||!(typeof t=="object"&&Q in t))}function Na(t){return xe(t)==="[object Boolean]"&&(!Q||!(typeof t=="object"&&Q in t))}function Dn(t){if(Ye)return t&&typeof t=="object"&&t instanceof Symbol;if(typeof t=="symbol")return!0;if(!t||typeof t!="object"||!pr)return!1;try{return pr.call(t),!0}catch{}return!1}function ja(t){if(!t||typeof t!="object"||!fr)return!1;try{return fr.call(t),!0}catch{}return!1}var La=Object.prototype.hasOwnProperty||function(t){return t in this};function Se(t,e){return La.call(t,e)}function xe(t){return Pa.call(t)}function Wa(t){if(t.name)return t.name;var e=Ta.call(Aa.call(t),/^function\s*([\w$]+)/);return e?e[1]:null}function kn(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function Ua(t){if(!At||!t||typeof t!="object")return!1;try{At.call(t);try{Tt.call(t)}catch{return!0}return t instanceof Map}catch{}return!1}function Ba(t){if(!ut||!t||typeof t!="object")return!1;try{ut.call(t,ut);try{st.call(t,st)}catch{return!0}return t instanceof WeakMap}catch{}return!1}function Ra(t){if(!Sn||!t||typeof t!="object")return!1;try{return Sn.call(t),!0}catch{}return!1}function Ha(t){if(!Tt||!t||typeof t!="object")return!1;try{Tt.call(t);try{At.call(t)}catch{return!0}return t instanceof Set}catch{}return!1}function Va(t){if(!st||!t||typeof t!="object")return!1;try{st.call(t,st);try{ut.call(t,ut)}catch{return!0}return t instanceof WeakSet}catch{}return!1}function qa(t){return!t||typeof t!="object"?!1:typeof HTMLElement<"u"&&t instanceof HTMLElement?!0:typeof t.nodeName=="string"&&typeof t.getAttribute=="function"}function Nn(t,e){if(t.length>e.maxStringLength){var r=t.length-e.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return Nn(cr.call(t,0,e.maxStringLength),e)+n}var o=Ee.call(Ee.call(t,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,Ga);return In(o,"single",e)}function Ga(t){var e=t.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[e];return r?"\\"+r:"\\x"+(e<16?"0":"")+$a.call(e.toString(16))}function ct(t){return"Object("+t+")"}function mr(t){return t+" { ? }"}function jn(t,e,r,n){var o=n?hr(r,n):fe.call(r,", ");return t+" ("+e+") {"+o+"}"}function za(t){for(var e=0;e<t.length;e++)if(kn(t[e],`
|
|
31
|
+
`)>=0)return!1;return!0}function Ya(t,e){var r;if(t.indent===" ")r=" ";else if(typeof t.indent=="number"&&t.indent>0)r=fe.call(Array(t.indent+1)," ");else return null;return{base:r,prev:fe.call(Array(e+1),r)}}function hr(t,e){if(t.length===0)return"";var r=`
|
|
32
|
+
`+e.prev+e.base;return r+fe.call(t,","+r)+`
|
|
33
|
+
`+e.prev}function $t(t,e){var r=vr(t),n=[];if(r){n.length=t.length;for(var o=0;o<t.length;o++)n[o]=Se(t,o)?e(t[o],t):""}var i=typeof dr=="function"?dr(t):[],l;if(Ye){l={};for(var u=0;u<i.length;u++)l["$"+i[u]]=i[u]}for(var a in t)Se(t,a)&&(r&&String(Number(a))===a&&a<t.length||Ye&&l["$"+a]instanceof Symbol||(On.call(/[^\w$]/,a)?n.push(e(a,t)+": "+e(t[a],t)):n.push(a+": "+e(t[a],t))));if(typeof dr=="function")for(var p=0;p<i.length;p++)Tn.call(t,i[p])&&n.push("["+e(i[p])+"]: "+e(t[i[p]],t));return n}var Ln=Ge,Ke=ba,Ka=Fa,Xa=at,Ct=Ln("%WeakMap%",!0),Ft=Ln("%Map%",!0),Ja=Ke("WeakMap.prototype.get",!0),Qa=Ke("WeakMap.prototype.set",!0),Za=Ke("WeakMap.prototype.has",!0),el=Ke("Map.prototype.get",!0),tl=Ke("Map.prototype.set",!0),rl=Ke("Map.prototype.has",!0),gr=function(t,e){for(var r=t,n;(n=r.next)!==null;r=n)if(n.key===e)return r.next=n.next,n.next=t.next,t.next=n,n},nl=function(t,e){var r=gr(t,e);return r&&r.value},ol=function(t,e,r){var n=gr(t,e);n?n.value=r:t.next={key:e,next:t.next,value:r}},il=function(t,e){return!!gr(t,e)},al=function(){var e,r,n,o={assert:function(i){if(!o.has(i))throw new Xa("Side channel does not contain "+Ka(i))},get:function(i){if(Ct&&i&&(typeof i=="object"||typeof i=="function")){if(e)return Ja(e,i)}else if(Ft){if(r)return el(r,i)}else if(n)return nl(n,i)},has:function(i){if(Ct&&i&&(typeof i=="object"||typeof i=="function")){if(e)return Za(e,i)}else if(Ft){if(r)return rl(r,i)}else if(n)return il(n,i);return!1},set:function(i,l){Ct&&i&&(typeof i=="object"||typeof i=="function")?(e||(e=new Ct),Qa(e,i,l)):Ft?(r||(r=new Ft),tl(r,i,l)):(n||(n={key:{},next:null}),ol(n,i,l))}};return o},ll=String.prototype.replace,ul=/%20/g,br={RFC1738:"RFC1738",RFC3986:"RFC3986"},wr={default:br.RFC3986,formatters:{RFC1738:function(t){return ll.call(t,ul,"+")},RFC3986:function(t){return String(t)}},RFC1738:br.RFC1738,RFC3986:br.RFC3986},sl=wr,Er=Object.prototype.hasOwnProperty,Fe=Array.isArray,de=function(){for(var t=[],e=0;e<256;++e)t.push("%"+((e<16?"0":"")+e.toString(16)).toUpperCase());return t}(),cl=function(e){for(;e.length>1;){var r=e.pop(),n=r.obj[r.prop];if(Fe(n)){for(var o=[],i=0;i<n.length;++i)typeof n[i]<"u"&&o.push(n[i]);r.obj[r.prop]=o}}},Wn=function(e,r){for(var n=r&&r.plainObjects?Object.create(null):{},o=0;o<e.length;++o)typeof e[o]<"u"&&(n[o]=e[o]);return n},fl=function t(e,r,n){if(!r)return e;if(typeof r!="object"){if(Fe(e))e.push(r);else if(e&&typeof e=="object")(n&&(n.plainObjects||n.allowPrototypes)||!Er.call(Object.prototype,r))&&(e[r]=!0);else return[e,r];return e}if(!e||typeof e!="object")return[e].concat(r);var o=e;return Fe(e)&&!Fe(r)&&(o=Wn(e,n)),Fe(e)&&Fe(r)?(r.forEach(function(i,l){if(Er.call(e,l)){var u=e[l];u&&typeof u=="object"&&i&&typeof i=="object"?e[l]=t(u,i,n):e.push(i)}else e[l]=i}),e):Object.keys(r).reduce(function(i,l){var u=r[l];return Er.call(i,l)?i[l]=t(i[l],u,n):i[l]=u,i},o)},dl=function(e,r){return Object.keys(r).reduce(function(n,o){return n[o]=r[o],n},e)},pl=function(t,e,r){var n=t.replace(/\+/g," ");if(r==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch{return n}},Sr=1024,yl=function(e,r,n,o,i){if(e.length===0)return e;var l=e;if(typeof e=="symbol"?l=Symbol.prototype.toString.call(e):typeof e!="string"&&(l=String(e)),n==="iso-8859-1")return escape(l).replace(/%u[0-9a-f]{4}/gi,function(E){return"%26%23"+parseInt(E.slice(2),16)+"%3B"});for(var u="",a=0;a<l.length;a+=Sr){for(var p=l.length>=Sr?l.slice(a,a+Sr):l,s=[],g=0;g<p.length;++g){var m=p.charCodeAt(g);if(m===45||m===46||m===95||m===126||m>=48&&m<=57||m>=65&&m<=90||m>=97&&m<=122||i===sl.RFC1738&&(m===40||m===41)){s[s.length]=p.charAt(g);continue}if(m<128){s[s.length]=de[m];continue}if(m<2048){s[s.length]=de[192|m>>6]+de[128|m&63];continue}if(m<55296||m>=57344){s[s.length]=de[224|m>>12]+de[128|m>>6&63]+de[128|m&63];continue}g+=1,m=65536+((m&1023)<<10|p.charCodeAt(g)&1023),s[s.length]=de[240|m>>18]+de[128|m>>12&63]+de[128|m>>6&63]+de[128|m&63]}u+=s.join("")}return u},vl=function(e){for(var r=[{obj:{o:e},prop:"o"}],n=[],o=0;o<r.length;++o)for(var i=r[o],l=i.obj[i.prop],u=Object.keys(l),a=0;a<u.length;++a){var p=u[a],s=l[p];typeof s=="object"&&s!==null&&n.indexOf(s)===-1&&(r.push({obj:l,prop:p}),n.push(s))}return cl(r),e},ml=function(e){return Object.prototype.toString.call(e)==="[object RegExp]"},hl=function(e){return!e||typeof e!="object"?!1:!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},gl=function(e,r){return[].concat(e,r)},bl=function(e,r){if(Fe(e)){for(var n=[],o=0;o<e.length;o+=1)n.push(r(e[o]));return n}return r(e)},Un={arrayToObject:Wn,assign:dl,combine:gl,compact:vl,decode:pl,encode:yl,isBuffer:hl,isRegExp:ml,maybeMap:bl,merge:fl},Bn=al,Mt=Un,ft=wr,wl=Object.prototype.hasOwnProperty,Rn={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,r){return e+"["+r+"]"},repeat:function(e){return e}},pe=Array.isArray,El=Array.prototype.push,Hn=function(t,e){El.apply(t,pe(e)?e:[e])},Sl=Date.prototype.toISOString,Vn=ft.default,K={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Mt.encode,encodeValuesOnly:!1,format:Vn,formatter:ft.formatters[Vn],indices:!1,serializeDate:function(e){return Sl.call(e)},skipNulls:!1,strictNullHandling:!1},xl=function(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||typeof e=="symbol"||typeof e=="bigint"},xr={},Ol=function t(e,r,n,o,i,l,u,a,p,s,g,m,E,d,v,y,h,b){for(var w=e,x=b,P=0,D=!1;(x=x.get(xr))!==void 0&&!D;){var _=x.get(e);if(P+=1,typeof _<"u"){if(_===P)throw new RangeError("Cyclic object value");D=!0}typeof x.get(xr)>"u"&&(P=0)}if(typeof s=="function"?w=s(r,w):w instanceof Date?w=E(w):n==="comma"&&pe(w)&&(w=Mt.maybeMap(w,function(se){return se instanceof Date?E(se):se})),w===null){if(l)return p&&!y?p(r,K.encoder,h,"key",d):r;w=""}if(xl(w)||Mt.isBuffer(w)){if(p){var U=y?r:p(r,K.encoder,h,"key",d);return[v(U)+"="+v(p(w,K.encoder,h,"value",d))]}return[v(r)+"="+v(String(w))]}var H=[];if(typeof w>"u")return H;var j;if(n==="comma"&&pe(w))y&&p&&(w=Mt.maybeMap(w,p)),j=[{value:w.length>0?w.join(",")||null:void 0}];else if(pe(s))j=s;else{var z=Object.keys(w);j=g?z.sort(g):z}var V=a?r.replace(/\./g,"%2E"):r,C=o&&pe(w)&&w.length===1?V+"[]":V;if(i&&pe(w)&&w.length===0)return C+"[]";for(var T=0;T<j.length;++T){var k=j[T],oe=typeof k=="object"&&typeof k.value<"u"?k.value:w[k];if(!(u&&oe===null)){var ue=m&&a?k.replace(/\./g,"%2E"):k,ve=pe(w)?typeof n=="function"?n(C,ue):C:C+(m?"."+ue:"["+ue+"]");b.set(e,P);var Z=Bn();Z.set(xr,b),Hn(H,t(oe,ve,n,o,i,l,u,a,n==="comma"&&y&&pe(w)?null:p,s,g,m,E,d,v,y,h,Z))}}return H},Pl=function(e){if(!e)return K;if(typeof e.allowEmptyArrays<"u"&&typeof e.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof e.encodeDotInKeys<"u"&&typeof e.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(e.encoder!==null&&typeof e.encoder<"u"&&typeof e.encoder!="function")throw new TypeError("Encoder has to be a function.");var r=e.charset||K.charset;if(typeof e.charset<"u"&&e.charset!=="utf-8"&&e.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=ft.default;if(typeof e.format<"u"){if(!wl.call(ft.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var o=ft.formatters[n],i=K.filter;(typeof e.filter=="function"||pe(e.filter))&&(i=e.filter);var l;if(e.arrayFormat in Rn?l=e.arrayFormat:"indices"in e?l=e.indices?"indices":"repeat":l=K.arrayFormat,"commaRoundTrip"in e&&typeof e.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var u=typeof e.allowDots>"u"?e.encodeDotInKeys===!0?!0:K.allowDots:!!e.allowDots;return{addQueryPrefix:typeof e.addQueryPrefix=="boolean"?e.addQueryPrefix:K.addQueryPrefix,allowDots:u,allowEmptyArrays:typeof e.allowEmptyArrays=="boolean"?!!e.allowEmptyArrays:K.allowEmptyArrays,arrayFormat:l,charset:r,charsetSentinel:typeof e.charsetSentinel=="boolean"?e.charsetSentinel:K.charsetSentinel,commaRoundTrip:e.commaRoundTrip,delimiter:typeof e.delimiter>"u"?K.delimiter:e.delimiter,encode:typeof e.encode=="boolean"?e.encode:K.encode,encodeDotInKeys:typeof e.encodeDotInKeys=="boolean"?e.encodeDotInKeys:K.encodeDotInKeys,encoder:typeof e.encoder=="function"?e.encoder:K.encoder,encodeValuesOnly:typeof e.encodeValuesOnly=="boolean"?e.encodeValuesOnly:K.encodeValuesOnly,filter:i,format:n,formatter:o,serializeDate:typeof e.serializeDate=="function"?e.serializeDate:K.serializeDate,skipNulls:typeof e.skipNulls=="boolean"?e.skipNulls:K.skipNulls,sort:typeof e.sort=="function"?e.sort:null,strictNullHandling:typeof e.strictNullHandling=="boolean"?e.strictNullHandling:K.strictNullHandling}},Al=function(t,e){var r=t,n=Pl(e),o,i;typeof n.filter=="function"?(i=n.filter,r=i("",r)):pe(n.filter)&&(i=n.filter,o=i);var l=[];if(typeof r!="object"||r===null)return"";var u=Rn[n.arrayFormat],a=u==="comma"&&n.commaRoundTrip;o||(o=Object.keys(r)),n.sort&&o.sort(n.sort);for(var p=Bn(),s=0;s<o.length;++s){var g=o[s];n.skipNulls&&r[g]===null||Hn(l,Ol(r[g],g,u,a,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,p))}var m=l.join(n.delimiter),E=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?E+="utf8=%26%2310003%3B&":E+="utf8=%E2%9C%93&"),m.length>0?E+m:""},Xe=Un,Or=Object.prototype.hasOwnProperty,Tl=Array.isArray,R={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:Xe.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1},$l=function(t){return t.replace(/&#(\d+);/g,function(e,r){return String.fromCharCode(parseInt(r,10))})},qn=function(t,e){return t&&typeof t=="string"&&e.comma&&t.indexOf(",")>-1?t.split(","):t},Cl="utf8=%26%2310003%3B",Fl="utf8=%E2%9C%93",Ml=function(e,r){var n={__proto__:null},o=r.ignoreQueryPrefix?e.replace(/^\?/,""):e;o=o.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var i=r.parameterLimit===1/0?void 0:r.parameterLimit,l=o.split(r.delimiter,i),u=-1,a,p=r.charset;if(r.charsetSentinel)for(a=0;a<l.length;++a)l[a].indexOf("utf8=")===0&&(l[a]===Fl?p="utf-8":l[a]===Cl&&(p="iso-8859-1"),u=a,a=l.length);for(a=0;a<l.length;++a)if(a!==u){var s=l[a],g=s.indexOf("]="),m=g===-1?s.indexOf("="):g+1,E,d;m===-1?(E=r.decoder(s,R.decoder,p,"key"),d=r.strictNullHandling?null:""):(E=r.decoder(s.slice(0,m),R.decoder,p,"key"),d=Xe.maybeMap(qn(s.slice(m+1),r),function(y){return r.decoder(y,R.decoder,p,"value")})),d&&r.interpretNumericEntities&&p==="iso-8859-1"&&(d=$l(d)),s.indexOf("[]=")>-1&&(d=Tl(d)?[d]:d);var v=Or.call(n,E);v&&r.duplicates==="combine"?n[E]=Xe.combine(n[E],d):(!v||r.duplicates==="last")&&(n[E]=d)}return n},Il=function(t,e,r,n){for(var o=n?e:qn(e,r),i=t.length-1;i>=0;--i){var l,u=t[i];if(u==="[]"&&r.parseArrays)l=r.allowEmptyArrays&&(o===""||r.strictNullHandling&&o===null)?[]:[].concat(o);else{l=r.plainObjects?Object.create(null):{};var a=u.charAt(0)==="["&&u.charAt(u.length-1)==="]"?u.slice(1,-1):u,p=r.decodeDotInKeys?a.replace(/%2E/g,"."):a,s=parseInt(p,10);!r.parseArrays&&p===""?l={0:o}:!isNaN(s)&&u!==p&&String(s)===p&&s>=0&&r.parseArrays&&s<=r.arrayLimit?(l=[],l[s]=o):p!=="__proto__"&&(l[p]=o)}o=l}return o},_l=function(e,r,n,o){if(e){var i=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,l=/(\[[^[\]]*])/,u=/(\[[^[\]]*])/g,a=n.depth>0&&l.exec(i),p=a?i.slice(0,a.index):i,s=[];if(p){if(!n.plainObjects&&Or.call(Object.prototype,p)&&!n.allowPrototypes)return;s.push(p)}for(var g=0;n.depth>0&&(a=u.exec(i))!==null&&g<n.depth;){if(g+=1,!n.plainObjects&&Or.call(Object.prototype,a[1].slice(1,-1))&&!n.allowPrototypes)return;s.push(a[1])}if(a){if(n.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+n.depth+" and strictDepth is true");s.push("["+i.slice(a.index)+"]")}return Il(s,r,n,o)}},Dl=function(e){if(!e)return R;if(typeof e.allowEmptyArrays<"u"&&typeof e.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof e.decodeDotInKeys<"u"&&typeof e.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(e.decoder!==null&&typeof e.decoder<"u"&&typeof e.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof e.charset<"u"&&e.charset!=="utf-8"&&e.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=typeof e.charset>"u"?R.charset:e.charset,n=typeof e.duplicates>"u"?R.duplicates:e.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var o=typeof e.allowDots>"u"?e.decodeDotInKeys===!0?!0:R.allowDots:!!e.allowDots;return{allowDots:o,allowEmptyArrays:typeof e.allowEmptyArrays=="boolean"?!!e.allowEmptyArrays:R.allowEmptyArrays,allowPrototypes:typeof e.allowPrototypes=="boolean"?e.allowPrototypes:R.allowPrototypes,allowSparse:typeof e.allowSparse=="boolean"?e.allowSparse:R.allowSparse,arrayLimit:typeof e.arrayLimit=="number"?e.arrayLimit:R.arrayLimit,charset:r,charsetSentinel:typeof e.charsetSentinel=="boolean"?e.charsetSentinel:R.charsetSentinel,comma:typeof e.comma=="boolean"?e.comma:R.comma,decodeDotInKeys:typeof e.decodeDotInKeys=="boolean"?e.decodeDotInKeys:R.decodeDotInKeys,decoder:typeof e.decoder=="function"?e.decoder:R.decoder,delimiter:typeof e.delimiter=="string"||Xe.isRegExp(e.delimiter)?e.delimiter:R.delimiter,depth:typeof e.depth=="number"||e.depth===!1?+e.depth:R.depth,duplicates:n,ignoreQueryPrefix:e.ignoreQueryPrefix===!0,interpretNumericEntities:typeof e.interpretNumericEntities=="boolean"?e.interpretNumericEntities:R.interpretNumericEntities,parameterLimit:typeof e.parameterLimit=="number"?e.parameterLimit:R.parameterLimit,parseArrays:e.parseArrays!==!1,plainObjects:typeof e.plainObjects=="boolean"?e.plainObjects:R.plainObjects,strictDepth:typeof e.strictDepth=="boolean"?!!e.strictDepth:R.strictDepth,strictNullHandling:typeof e.strictNullHandling=="boolean"?e.strictNullHandling:R.strictNullHandling}},kl=function(t,e){var r=Dl(e);if(t===""||t===null||typeof t>"u")return r.plainObjects?Object.create(null):{};for(var n=typeof t=="string"?Ml(t,r):t,o=r.plainObjects?Object.create(null):{},i=Object.keys(n),l=0;l<i.length;++l){var u=i[l],a=_l(u,n[u],r,typeof t=="string");o=Xe.merge(o,a,r)}return r.allowSparse===!0?o:Xe.compact(o)},Nl=Al,jl=kl,Ll=wr,Gn={formats:Ll,parse:jl,stringify:Nl},Wl={exports:{}};/* NProgress, (c) 2013, 2014 Rico Sta. Cruz - http://ricostacruz.com/nprogress
|
|
34
|
+
* @license MIT */(function(t,e){(function(r,n){t.exports=n()})(Jt,function(){var r={};r.version="0.2.0";var n=r.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,barSelector:'[role="bar"]',spinnerSelector:'[role="spinner"]',parent:"body",template:'<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'};r.configure=function(d){var v,y;for(v in d)y=d[v],y!==void 0&&d.hasOwnProperty(v)&&(n[v]=y);return this},r.status=null,r.set=function(d){var v=r.isStarted();d=o(d,n.minimum,1),r.status=d===1?null:d;var y=r.render(!v),h=y.querySelector(n.barSelector),b=n.speed,w=n.easing;return y.offsetWidth,u(function(x){n.positionUsing===""&&(n.positionUsing=r.getPositioningCSS()),a(h,l(d,b,w)),d===1?(a(y,{transition:"none",opacity:1}),y.offsetWidth,setTimeout(function(){a(y,{transition:"all "+b+"ms linear",opacity:0}),setTimeout(function(){r.remove(),x()},b)},b)):setTimeout(x,b)}),this},r.isStarted=function(){return typeof r.status=="number"},r.start=function(){r.status||r.set(0);var d=function(){setTimeout(function(){r.status&&(r.trickle(),d())},n.trickleSpeed)};return n.trickle&&d(),this},r.done=function(d){return!d&&!r.status?this:r.inc(.3+.5*Math.random()).set(1)},r.inc=function(d){var v=r.status;return v?(typeof d!="number"&&(d=(1-v)*o(Math.random()*v,.1,.95)),v=o(v+d,0,.994),r.set(v)):r.start()},r.trickle=function(){return r.inc(Math.random()*n.trickleRate)},function(){var d=0,v=0;r.promise=function(y){return!y||y.state()==="resolved"?this:(v===0&&r.start(),d++,v++,y.always(function(){v--,v===0?(d=0,r.done()):r.set((d-v)/d)}),this)}}(),r.render=function(d){if(r.isRendered())return document.getElementById("nprogress");s(document.documentElement,"nprogress-busy");var v=document.createElement("div");v.id="nprogress",v.innerHTML=n.template;var y=v.querySelector(n.barSelector),h=d?"-100":i(r.status||0),b=document.querySelector(n.parent),w;return a(y,{transition:"all 0 linear",transform:"translate3d("+h+"%,0,0)"}),n.showSpinner||(w=v.querySelector(n.spinnerSelector),w&&E(w)),b!=document.body&&s(b,"nprogress-custom-parent"),b.appendChild(v),v},r.remove=function(){g(document.documentElement,"nprogress-busy"),g(document.querySelector(n.parent),"nprogress-custom-parent");var d=document.getElementById("nprogress");d&&E(d)},r.isRendered=function(){return!!document.getElementById("nprogress")},r.getPositioningCSS=function(){var d=document.body.style,v="WebkitTransform"in d?"Webkit":"MozTransform"in d?"Moz":"msTransform"in d?"ms":"OTransform"in d?"O":"";return v+"Perspective"in d?"translate3d":v+"Transform"in d?"translate":"margin"};function o(d,v,y){return d<v?v:d>y?y:d}function i(d){return(-1+d)*100}function l(d,v,y){var h;return n.positionUsing==="translate3d"?h={transform:"translate3d("+i(d)+"%,0,0)"}:n.positionUsing==="translate"?h={transform:"translate("+i(d)+"%,0)"}:h={"margin-left":i(d)+"%"},h.transition="all "+v+"ms "+y,h}var u=function(){var d=[];function v(){var y=d.shift();y&&y(v)}return function(y){d.push(y),d.length==1&&v()}}(),a=function(){var d=["Webkit","O","Moz","ms"],v={};function y(x){return x.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(P,D){return D.toUpperCase()})}function h(x){var P=document.body.style;if(x in P)return x;for(var D=d.length,_=x.charAt(0).toUpperCase()+x.slice(1),U;D--;)if(U=d[D]+_,U in P)return U;return x}function b(x){return x=y(x),v[x]||(v[x]=h(x))}function w(x,P,D){P=b(P),x.style[P]=D}return function(x,P){var D=arguments,_,U;if(D.length==2)for(_ in P)U=P[_],U!==void 0&&P.hasOwnProperty(_)&&w(x,_,U);else w(x,D[1],D[2])}}();function p(d,v){var y=typeof d=="string"?d:m(d);return y.indexOf(" "+v+" ")>=0}function s(d,v){var y=m(d),h=y+v;p(y,v)||(d.className=h.substring(1))}function g(d,v){var y=m(d),h;p(d,v)&&(h=y.replace(" "+v+" "," "),d.className=h.substring(1,h.length-1))}function m(d){return(" "+(d.className||"")+" ").replace(/\s+/gi," ")}function E(d){d&&d.parentNode&&d.parentNode.removeChild(d)}return r})})(Wl);function Ul(t,e,r,n="brackets"){let o=/^https?:\/\//.test(e.toString()),i=o||e.toString().startsWith("/"),l=!i&&!e.toString().startsWith("#")&&!e.toString().startsWith("?"),u=e.toString().includes("?")||t==="get"&&Object.keys(r).length,a=e.toString().includes("#"),p=new URL(e.toString(),"http://localhost");return t==="get"&&Object.keys(r).length&&(p.search=Gn.stringify(xi(Gn.parse(p.search,{ignoreQueryPrefix:!0}),r),{encodeValuesOnly:!0,arrayFormat:n}),r={}),[[o?`${p.protocol}//${p.host}`:"",i?p.pathname:"",l?p.pathname.substring(1):"",u?p.search:"",a?p.hash:""].join(""),r]}const It=f.createContext(null);It.displayName="ModalStackContext";let zn=null,Yn=null,Pr=null,Ar=null,Tr=[];const Kn=({children:t})=>{const[e,r]=f.useState([]),[n,o]=f.useState({}),i=v=>{r(y=>{const h=v([...y]),b=w=>{var x;return h.length<2?!0:((x=h.map(P=>({id:P.id,shouldRender:P.shouldRender})).reverse().find(P=>P.shouldRender))==null?void 0:x.id)===w};return h.forEach((w,x)=>{h[x].onTopOfStack=b(w.id),h[x].getParentModal=()=>x<1?null:h.slice(0,x).reverse().find(P=>P.isOpen),h[x].getChildModal=()=>x===h.length-1?null:h.slice(x+1).find(P=>P.isOpen)}),h})};f.useEffect(()=>{Tr=e},[e]);class l{constructor(y,h,b,w,x){ce(this,"update",(y,h,b)=>{i(w=>w.map(x=>(x.id===this.id&&(x.modalProps=y,x.onCloseCallback=h,x.afterLeaveCallback=b),x)))});ce(this,"show",()=>{i(y=>y.map(h=>(h.id===this.id&&!h.isOpen&&(h.isOpen=!0,h.shouldRender=!0),h)))});ce(this,"setOpen",y=>{y?this.show():this.close()});ce(this,"close",()=>{console.log("Closing",this.id),i(y=>y.map(h=>{var b;return h.id===this.id&&h.isOpen&&(Object.keys(h.listeners).forEach(w=>{h.off(w)}),h.isOpen=!1,(b=h.onCloseCallback)==null||b.call(h)),h}))});ce(this,"afterLeave",()=>{console.log("After leave",this.id),!this.isOpen&&i(y=>{const h=y.map(b=>{var w;return b.id===this.id&&!b.isOpen&&(b.shouldRender=!1,(w=b.afterLeaveCallback)==null||w.call(b),b.afterLeaveCallback=null),b});return this.index===0?[]:h})});ce(this,"on",(y,h)=>{this.listeners[y]=this.listeners[y]??[],this.listeners[y].push(h)});ce(this,"off",(y,h)=>{var b;h?this.listeners[y]=((b=this.listeners[y])==null?void 0:b.filter(w=>w!==h))??[]:delete this.listeners[y]});ce(this,"emit",(y,...h)=>{var b;(b=this.listeners[y])==null||b.forEach(w=>w(...h))});ce(this,"registerEventListenersFromProps",y=>{const h=[];return Object.keys(y).filter(b=>b.startsWith("on")).forEach(b=>{const w=b.replace(/^on/,"").replace(/^./,x=>x.toLowerCase()).replace(/([A-Z])/g,"-$1").toLowerCase();this.on(w,y[b]),h.push(()=>this.off(w,y[b]))}),()=>h.forEach(b=>b())});ce(this,"reload",(y={})=>{var b;let h=Object.keys(this.response.props);y.only&&(h=Zr(h,y.only)),y.except&&(h=ai(h,y.except)),(b=this.response)!=null&&b.url&&me.get(this.response.url,{headers:{Accept:"text/html, application/xhtml+xml","X-Inertia":!0,"X-Inertia-Partial-Component":this.response.component,"X-Inertia-Version":this.response.version,"X-Inertia-Partial-Data":h.join(","),"X-InertiaUI-Modal":!0,"X-InertiaUI-Modal-Use-Router":0}}).then(w=>{Object.assign(this.componentProps,w.data.props),i(x=>x)})});this.id=l.generateId(),this.isOpen=!1,this.shouldRender=!1,this.listeners={},this.component=y,this.componentProps=h.props,this.response=h,this.modalProps=b,this.onCloseCallback=w,this.afterLeaveCallback=x,this.index=-1,this.getParentModal=()=>null,this.getChildModal=()=>null,this.onTopOfStack=!0}static generateId(){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?`inertiaui_modal_${crypto.randomUUID()}`:`inertiaui_modal_${Date.now().toString(36)}_${Math.random().toString(36).substr(2,9)}`}}const u=(v,y={},h=null,b=null)=>Yn(v.component).then(w=>a(w,v,y,h,b)),a=(v,y,h,b,w)=>{const x=new l(v,y,h,b,w);return x.index=e.length,i(P=>[...P,x]),x.show(),x};function p(v,y,h,b){if(!n[v])throw new Error(`The local modal "${v}" has not been registered.`);const w=a(null,{},y,h,b);return w.name=v,n[v].callback(w),w}const s=(v,y={})=>g(v,y.method??"get",y.data??{},y.headers??{},y.config??{},y.onClose,y.onAfterLeave,y.queryStringArrayFormat??"brackets"),g=(v,y,h={},b={},w={},x=null,P=null,D="brackets",_=!1)=>new Promise((U,H)=>{if(v.startsWith("#")){U(p(v.substring(1),w,x,P));return}const[j,z]=Ul(y,v||"",h,D);let V=_&&e.length===0;if(e.length===0&&(Pr=typeof window<"u"?window.location.href:""),b={...b,Accept:"text/html, application/xhtml+xml","X-Requested-With":"XMLHttpRequest","X-Inertia":!0,"X-Inertia-Version":zn,"X-InertiaUI-Modal":!0,"X-InertiaUI-Modal-Use-Router":V?1:0},V)return tt.router.visit(j,{method:y,data:z,headers:b,preserveScroll:!0,preserveState:!0,onError:H,onFinish:()=>{ui(()=>Ar).then(C=>{const T=C.onCloseCallback,k=C.afterLeaveCallback;C.update(w,()=>{x==null||x(),T==null||T()},()=>{P==null||P(),k==null||k()}),U(C),Ar=null})}});me({url:j,method:y,data:z,headers:b}).then(C=>U(u(C.data,w,x,P))).catch(C=>{H(C)})}),d={stack:e,localModals:n,push:a,pushFromResponseData:u,closeAll:()=>{console.log("Closing all modals",{stack:e,localStackCopy:Tr}),Tr.reverse().forEach(v=>v.close())},reset:()=>i(()=>[]),visit:g,visitModal:s,registerLocalModal:(v,y)=>{o(h=>({...h,[v]:{name:v,callback:y}}))},removeLocalModal:v=>{o(y=>{const h={...y};return delete h[v],h})}};return $.jsx(It.Provider,{value:d,children:t})},_t=()=>{const t=f.useContext(It);if(t===null)throw new Error("useModalStack must be used within a ModalStackProvider");return t},Xn=["closeButton","closeExplicitly","maxWidth","paddingClasses","panelClasses","position","slideover"],Bl=(t,e)=>{e.initialPage&&(zn=e.initialPage.version),e.resolveComponent&&(Yn=e.resolveComponent);const r=({Component:n,props:o,key:i})=>{const l=()=>{const u=f.createElement(n,{key:i,...o});return typeof n.layout=="function"?n.layout(u):Array.isArray(n.layout)?n.layout.concat(u).reverse().reduce((p,s)=>f.createElement(s,o,p)):u};return $.jsxs($.Fragment,{children:[l(),$.jsx(Jn,{})]})};return $.jsx(Kn,{children:$.jsx(t,{...e,children:r})})},Jn=({children:t})=>{const e=f.useContext(It);let r=!1,n=!1;f.useEffect(()=>tt.router.on("start",()=>r=!0),[]),f.useEffect(()=>tt.router.on("finish",()=>r=!1),[]),f.useEffect(()=>tt.router.on("navigate",function(i){const l=i.detail.page.props._inertiaui_modal;if(!l){n&&e.closeAll();return}n=l,Pr=l.baseUrl,e.pushFromResponseData(l,{},()=>{if(!l.baseUrl){console.error("No base url in modal response data so cannot navigate back");return}!r&&window.location.href!==l.baseUrl&&tt.router.visit(l.baseUrl,{preserveScroll:!0,preserveState:!0})}).then(u=>{Ar=u})}),[]);const o=i=>(i.headers["X-InertiaUI-Modal-Base-Url"]=Pr,i);return f.useEffect(()=>(me.interceptors.request.use(o),()=>me.interceptors.request.eject(o)),[]),$.jsxs($.Fragment,{children:[t,e.stack.length>0&&$.jsx(Zn,{index:0})]})},$r=f.createContext(null);$r.displayName="ModalIndexContext";const Qn=()=>{const t=f.useContext($r);if(t===void 0)throw new Error("useModalIndex must be used within a ModalIndexProvider");return t},Zn=({index:t})=>{const{stack:e}=_t(),r=f.useMemo(()=>e[t],[e,t]);return(r==null?void 0:r.component)&&$.jsx($r.Provider,{value:t,children:$.jsx(r.component,{...r.componentProps,onModalEvent:(...n)=>r.emit(...n)})})},Cr=f.forwardRef(({name:t,children:e,...r},n)=>{const o=Qn(),{stack:i,registerLocalModal:l,removeLocalModal:u}=_t(),[a,p]=f.useState(null),s=f.useMemo(()=>t?a:i[o],[t,a,o,i]),g=f.useMemo(()=>{var d;return(d=i.find(v=>v.shouldRender&&v.index>(s==null?void 0:s.index)))==null?void 0:d.index},[o,i]),m=f.useMemo(()=>(s==null?void 0:s.modalProps.slideover)??r.slideover??Xt("type")==="slideover",[r.slideover]),E=f.useMemo(()=>({slideover:m,closeButton:r.closeButton??Ue(m,"closeButton"),closeExplicitly:r.closeExplicitly??Ue(m,"closeExplicitly"),maxWidth:r.maxWidth??Ue(m,"maxWidth"),paddingClasses:r.paddingClasses??Ue(m,"paddingClasses"),panelClasses:r.panelClasses??Ue(m,"panelClasses"),position:r.position??Ue(m,"position"),...s==null?void 0:s.modalProps}),[r,s==null?void 0:s.modalProps]);return f.useEffect(()=>{if(t){let d=null;return l(t,v=>{d=v.registerEventListenersFromProps(r),p(v)}),()=>{d==null||d(),d=null,u(t)}}return s.registerEventListenersFromProps(r)},[t]),f.useImperativeHandle(n,()=>({afterLeave:()=>s.afterLeave(),close:()=>s.close(),emit:(...d)=>s.emit(...d),getChildModal:()=>s.getChildModal(),getParentModal:()=>s.getParentModal(),id:s==null?void 0:s.id,index:s==null?void 0:s.index,isOpen:s==null?void 0:s.isOpen,modalContext:s,modalProps:E,onTopOfStack:s==null?void 0:s.onTopOfStack,reload:()=>s.reload(),setOpen:()=>s.setOpen(),shouldRender:s==null?void 0:s.shouldRender}),[s]),(s==null?void 0:s.shouldRender)&&$.jsxs($.Fragment,{children:[typeof e=="function"?e({afterLeave:s.afterLeave,close:s.close,emit:s.emit,getChildModal:s.getChildModal,getParentModal:s.getParentModal,id:s.id,index:s.index,isOpen:s.isOpen,modalContext:s,modalProps:E,onTopOfStack:s.onTopOfStack,reload:s.reload,setOpen:s.setOpen,shouldRender:s.shouldRender}):e,g&&$.jsx(Zn,{index:g})]})});Cr.displayName="HeadlessModal";function eo(t){var e,r,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t)){var o=t.length;for(e=0;e<o;e++)t[e]&&(r=eo(t[e]))&&(n&&(n+=" "),n+=r)}else for(r in t)t[r]&&(n&&(n+=" "),n+=r);return n}function Dt(){for(var t,e,r=0,n="",o=arguments.length;r<o;r++)(t=arguments[r])&&(e=eo(t))&&(n&&(n+=" "),n+=e);return n}var Rl=Object.defineProperty,Hl=(t,e,r)=>e in t?Rl(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,Fr=(t,e,r)=>(Hl(t,typeof e!="symbol"?e+"":e,r),r);let Vl=class{constructor(){Fr(this,"current",this.detect()),Fr(this,"handoffState","pending"),Fr(this,"currentId",0)}set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},Me=new Vl;function kt(t){return Me.isServer?null:t instanceof Node?t.ownerDocument:t!=null&&t.hasOwnProperty("current")&&t.current instanceof Node?t.current.ownerDocument:document}function Nt(t){typeof queueMicrotask=="function"?queueMicrotask(t):Promise.resolve().then(t).catch(e=>setTimeout(()=>{throw e}))}function Oe(){let t=[],e={addEventListener(r,n,o,i){return r.addEventListener(n,o,i),e.add(()=>r.removeEventListener(n,o,i))},requestAnimationFrame(...r){let n=requestAnimationFrame(...r);return e.add(()=>cancelAnimationFrame(n))},nextFrame(...r){return e.requestAnimationFrame(()=>e.requestAnimationFrame(...r))},setTimeout(...r){let n=setTimeout(...r);return e.add(()=>clearTimeout(n))},microTask(...r){let n={current:!0};return Nt(()=>{n.current&&r[0]()}),e.add(()=>{n.current=!1})},style(r,n,o){let i=r.style.getPropertyValue(n);return Object.assign(r.style,{[n]:o}),this.add(()=>{Object.assign(r.style,{[n]:i})})},group(r){let n=Oe();return r(n),this.add(()=>n.dispose())},add(r){return t.includes(r)||t.push(r),()=>{let n=t.indexOf(r);if(n>=0)for(let o of t.splice(n,1))o()}},dispose(){for(let r of t.splice(0))r()}};return e}function Mr(){let[t]=f.useState(Oe);return f.useEffect(()=>()=>t.dispose(),[t]),t}let ee=(t,e)=>{Me.isServer?f.useEffect(t,e):f.useLayoutEffect(t,e)};function Ie(t){let e=f.useRef(t);return ee(()=>{e.current=t},[t]),e}let B=function(t){let e=Ie(t);return f.useCallback((...r)=>e.current(...r),[e])},ql=f.createContext(void 0);function Gl(){return f.useContext(ql)}function Ir(...t){return Array.from(new Set(t.flatMap(e=>typeof e=="string"?e.split(" "):[]))).filter(Boolean).join(" ")}function Pe(t,e,...r){if(t in e){let o=e[t];return typeof o=="function"?o(...r):o}let n=new Error(`Tried to handle "${t}" but there is no handler defined. Only defined handlers are: ${Object.keys(e).map(o=>`"${o}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,Pe),n}var jt=(t=>(t[t.None=0]="None",t[t.RenderStrategy=1]="RenderStrategy",t[t.Static=2]="Static",t))(jt||{}),Ae=(t=>(t[t.Unmount=0]="Unmount",t[t.Hidden=1]="Hidden",t))(Ae||{});function ie(){let t=Yl();return f.useCallback(e=>zl({mergeRefs:t,...e}),[t])}function zl({ourProps:t,theirProps:e,slot:r,defaultTag:n,features:o,visible:i=!0,name:l,mergeRefs:u}){u=u??Kl;let a=to(e,t);if(i)return Lt(a,r,n,l,u);let p=o??0;if(p&2){let{static:s=!1,...g}=a;if(s)return Lt(g,r,n,l,u)}if(p&1){let{unmount:s=!0,...g}=a;return Pe(s?0:1,{0(){return null},1(){return Lt({...g,hidden:!0,style:{display:"none"}},r,n,l,u)}})}return Lt(a,r,n,l,u)}function Lt(t,e={},r,n,o){let{as:i=r,children:l,refName:u="ref",...a}=_r(t,["unmount","static"]),p=t.ref!==void 0?{[u]:t.ref}:{},s=typeof l=="function"?l(e):l;"className"in a&&a.className&&typeof a.className=="function"&&(a.className=a.className(e)),a["aria-labelledby"]&&a["aria-labelledby"]===a.id&&(a["aria-labelledby"]=void 0);let g={};if(e){let m=!1,E=[];for(let[d,v]of Object.entries(e))typeof v=="boolean"&&(m=!0),v===!0&&E.push(d.replace(/([A-Z])/g,y=>`-${y.toLowerCase()}`));if(m){g["data-headlessui-state"]=E.join(" ");for(let d of E)g[`data-${d}`]=""}}if(i===f.Fragment&&(Object.keys(_e(a)).length>0||Object.keys(_e(g)).length>0))if(!f.isValidElement(s)||Array.isArray(s)&&s.length>1){if(Object.keys(_e(a)).length>0)throw new Error(['Passing props on "Fragment"!',"",`The current component <${n} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(_e(a)).concat(Object.keys(_e(g))).map(m=>` - ${m}`).join(`
|
|
35
|
+
`),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(m=>` - ${m}`).join(`
|
|
41
36
|
`)].join(`
|
|
42
|
-
`))}else{let v=u.props,g=v==null?void 0:v.className,c=typeof g=="function"?(...w)=>yn(g(...w),l.className):yn(g,l.className),m=c?{className:c}:{},y=wi(u.props,qe(hn(l,["ref"])));for(let w in h)w in y&&delete h[w];return p.cloneElement(u,Object.assign({},y,h,f,{ref:o(u.ref,f.ref)},m))}return p.createElement(i,Object.assign({},hn(l,["ref"]),i!==p.Fragment&&f,i!==p.Fragment&&h),u)}function Dc(...e){return e.every(t=>t==null)?void 0:t=>{for(let r of e)r!=null&&(typeof r=="function"?r(t):r.current=t)}}function wi(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},r={};for(let n of e)for(let o in n)o.startsWith("on")&&typeof n[o]=="function"?(r[o]!=null||(r[o]=[]),r[o].push(n[o])):t[o]=n[o];if(t.disabled||t["aria-disabled"])for(let n in r)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(n)&&(r[n]=[o=>{var i;return(i=o==null?void 0:o.preventDefault)==null?void 0:i.call(o)}]);for(let n in r)Object.assign(t,{[n](o,...i){let a=r[n];for(let s of a){if((o instanceof Event||(o==null?void 0:o.nativeEvent)instanceof Event)&&o.defaultPrevented)return;s(o,...i)}}});return t}function se(e){var t;return Object.assign(p.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function qe(e){let t=Object.assign({},e);for(let r in t)t[r]===void 0&&delete t[r];return t}function hn(e,t=[]){let r=Object.assign({},e);for(let n of t)n in r&&delete r[n];return r}let Ic="span";var lr=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(lr||{});function Lc(e,t){var r;let{features:n=1,...o}=e,i={ref:t,"aria-hidden":(n&2)===2?!0:(r=o["aria-hidden"])!=null?r:void 0,hidden:(n&4)===4?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(n&4)===4&&(n&2)!==2&&{display:"none"}}};return fe({ourProps:i,theirProps:o,slot:{},defaultTag:Ic,name:"Hidden"})}let vn=se(Lc),Ei=Symbol();function kc(e,t=!0){return Object.assign(e,{[Ei]:t})}function be(...e){let t=p.useRef(e);p.useEffect(()=>{t.current=e},[e]);let r=q(n=>{for(let o of t.current)o!=null&&(typeof o=="function"?o(n):o.current=n)});return e.every(n=>n==null||(n==null?void 0:n[Ei]))?void 0:r}let gn=p.createContext(null);gn.displayName="DescriptionContext";function Si(){let e=p.useContext(gn);if(e===null){let t=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(t,Si),t}return e}function jc(){let[e,t]=p.useState([]);return[e.length>0?e.join(" "):void 0,p.useMemo(()=>function(r){let n=q(i=>(t(a=>[...a,i]),()=>t(a=>{let s=a.slice(),l=s.indexOf(i);return l!==-1&&s.splice(l,1),s}))),o=p.useMemo(()=>({register:n,slot:r.slot,name:r.name,props:r.props,value:r.value}),[n,r.slot,r.name,r.props,r.value]);return p.createElement(gn.Provider,{value:o},r.children)},[t])]}let Bc="p";function Uc(e,t){let r=p.useId(),n=Rc(),{id:o=`headlessui-description-${r}`,...i}=e,a=Si(),s=be(t);ne(()=>a.register(o),[o,a.register]);let l=n||!1,f=p.useMemo(()=>({...a.slot,disabled:l}),[a.slot,l]),u={ref:s,...a.props,id:o};return fe({ourProps:u,theirProps:i,slot:f,defaultTag:Bc,name:a.name||"Description"})}let Wc=se(Uc),Hc=Object.assign(Wc,{});var xi=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(xi||{});let qc=p.createContext(()=>{});function Vc({value:e,children:t}){return p.createElement(qc.Provider,{value:e},t)}let zc=class extends Map{constructor(t){super(),this.factory=t}get(t){let r=super.get(t);return r===void 0&&(r=this.factory(t),this.set(t,r)),r}};function Oi(e,t){let r=e(),n=new Set;return{getSnapshot(){return r},subscribe(o){return n.add(o),()=>n.delete(o)},dispatch(o,...i){let a=t[o].call(r,...i);a&&(r=a,n.forEach(s=>s()))}}}function Ai(e){return p.useSyncExternalStore(e.subscribe,e.getSnapshot,e.getSnapshot)}let Gc=new zc(()=>Oi(()=>[],{ADD(e){return this.includes(e)?this:[...this,e]},REMOVE(e){let t=this.indexOf(e);if(t===-1)return this;let r=this.slice();return r.splice(t,1),r}}));function ut(e,t){let r=Gc.get(t),n=p.useId(),o=Ai(r);if(ne(()=>{if(e)return r.dispatch("ADD",n),()=>r.dispatch("REMOVE",n)},[r,e]),!e)return!1;let i=o.indexOf(n),a=o.length;return i===-1&&(i=a,a+=1),i===a-1}let bn=new Map,Pt=new Map;function Ti(e){var t;let r=(t=Pt.get(e))!=null?t:0;return Pt.set(e,r+1),r!==0?()=>Pi(e):(bn.set(e,{"aria-hidden":e.getAttribute("aria-hidden"),inert:e.inert}),e.setAttribute("aria-hidden","true"),e.inert=!0,()=>Pi(e))}function Pi(e){var t;let r=(t=Pt.get(e))!=null?t:1;if(r===1?Pt.delete(e):Pt.set(e,r-1),r!==1)return;let n=bn.get(e);n&&(n["aria-hidden"]===null?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n["aria-hidden"]),e.inert=n.inert,bn.delete(e))}function Kc(e,{allowed:t,disallowed:r}={}){let n=ut(e,"inert-others");ne(()=>{var o,i;if(!n)return;let a=Fe();for(let l of(o=r==null?void 0:r())!=null?o:[])l&&a.add(Ti(l));let s=(i=t==null?void 0:t())!=null?i:[];for(let l of s){if(!l)continue;let f=or(l);if(!f)continue;let u=l.parentElement;for(;u&&u!==f.body;){for(let h of u.children)s.some(v=>h.contains(v))||a.add(Ti(h));u=u.parentElement}}return a.dispose},[n,t,r])}function Jc(e,t,r){let n=He(o=>{let i=o.getBoundingClientRect();i.x===0&&i.y===0&&i.width===0&&i.height===0&&r()});p.useEffect(()=>{if(!e)return;let o=t===null?null:t instanceof HTMLElement?t:t.current;if(!o)return;let i=Fe();if(typeof ResizeObserver<"u"){let a=new ResizeObserver(()=>n.current(o));a.observe(o),i.add(()=>a.disconnect())}if(typeof IntersectionObserver<"u"){let a=new IntersectionObserver(()=>n.current(o));a.observe(o),i.add(()=>a.disconnect())}return()=>i.dispose()},[t,n,e])}let ur=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(","),Yc=["[data-autofocus]"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var xe=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e[e.AutoFocus=64]="AutoFocus",e))(xe||{}),wn=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(wn||{}),Xc=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(Xc||{});function Qc(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(ur)).sort((t,r)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}function Zc(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(Yc)).sort((t,r)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}var Ci=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Ci||{});function ef(e,t=0){var r;return e===((r=or(e))==null?void 0:r.body)?!1:$e(t,{0(){return e.matches(ur)},1(){let n=e;for(;n!==null;){if(n.matches(ur))return!0;n=n.parentElement}return!1}})}var tf=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(tf||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));function Oe(e){e==null||e.focus({preventScroll:!0})}let rf=["textarea","input"].join(",");function nf(e){var t,r;return(r=(t=e==null?void 0:e.matches)==null?void 0:t.call(e,rf))!=null?r:!1}function of(e,t=r=>r){return e.slice().sort((r,n)=>{let o=t(r),i=t(n);if(o===null||i===null)return 0;let a=o.compareDocumentPosition(i);return a&Node.DOCUMENT_POSITION_FOLLOWING?-1:a&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function Ct(e,t,{sorted:r=!0,relativeTo:n=null,skipElements:o=[]}={}){let i=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,a=Array.isArray(e)?r?of(e):e:t&64?Zc(e):Qc(e);o.length>0&&a.length>1&&(a=a.filter(g=>!o.some(c=>c!=null&&"current"in c?(c==null?void 0:c.current)===g:c===g))),n=n??i.activeElement;let s=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),l=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,a.indexOf(n))-1;if(t&4)return Math.max(0,a.indexOf(n))+1;if(t&8)return a.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),f=t&32?{preventScroll:!0}:{},u=0,h=a.length,v;do{if(u>=h||u+h<=0)return 0;let g=l+u;if(t&16)g=(g+h)%h;else{if(g<0)return 3;if(g>=h)return 1}v=a[g],v==null||v.focus(f),u+=s}while(v!==i.activeElement);return t&6&&nf(v)&&v.select(),2}function Fi(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function af(){return/Android/gi.test(window.navigator.userAgent)}function sf(){return Fi()||af()}function Ft(e,t,r,n){let o=He(r);p.useEffect(()=>{if(!e)return;function i(a){o.current(a)}return document.addEventListener(t,i,n),()=>document.removeEventListener(t,i,n)},[e,t,n])}function $i(e,t,r,n){let o=He(r);p.useEffect(()=>{if(!e)return;function i(a){o.current(a)}return window.addEventListener(t,i,n),()=>window.removeEventListener(t,i,n)},[e,t,n])}const _i=30;function lf(e,t,r){let n=ut(e,"outside-click"),o=He(r),i=p.useCallback(function(l,f){if(l.defaultPrevented)return;let u=f(l);if(u===null||!u.getRootNode().contains(u)||!u.isConnected)return;let h=function v(g){return typeof g=="function"?v(g()):Array.isArray(g)||g instanceof Set?g:[g]}(t);for(let v of h)if(v!==null&&(v.contains(u)||l.composed&&l.composedPath().includes(v)))return;return!ef(u,Ci.Loose)&&u.tabIndex!==-1&&l.preventDefault(),o.current(l,u)},[o,t]),a=p.useRef(null);Ft(n,"pointerdown",l=>{var f,u;a.current=((u=(f=l.composedPath)==null?void 0:f.call(l))==null?void 0:u[0])||l.target},!0),Ft(n,"mousedown",l=>{var f,u;a.current=((u=(f=l.composedPath)==null?void 0:f.call(l))==null?void 0:u[0])||l.target},!0),Ft(n,"click",l=>{sf()||a.current&&(i(l,()=>a.current),a.current=null)},!0);let s=p.useRef({x:0,y:0});Ft(n,"touchstart",l=>{s.current.x=l.touches[0].clientX,s.current.y=l.touches[0].clientY},!0),Ft(n,"touchend",l=>{let f={x:l.changedTouches[0].clientX,y:l.changedTouches[0].clientY};if(!(Math.abs(f.x-s.current.x)>=_i||Math.abs(f.y-s.current.y)>=_i))return i(l,()=>l.target instanceof HTMLElement?l.target:null)},!0),$i(n,"blur",l=>i(l,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function $t(...e){return p.useMemo(()=>or(...e),[...e])}function Ni(e,t,r,n){let o=He(r);p.useEffect(()=>{e=e??window;function i(a){o.current(a)}return e.addEventListener(t,i,n),()=>e.removeEventListener(t,i,n)},[e,t,n])}function uf(){let e;return{before({doc:t}){var r;let n=t.documentElement,o=(r=t.defaultView)!=null?r:window;e=Math.max(0,o.innerWidth-n.clientWidth)},after({doc:t,d:r}){let n=t.documentElement,o=Math.max(0,n.clientWidth-n.offsetWidth),i=Math.max(0,e-o);r.style(n,"paddingRight",`${i}px`)}}}function cf(){return Fi()?{before({doc:e,d:t,meta:r}){function n(o){return r.containers.flatMap(i=>i()).some(i=>i.contains(o))}t.microTask(()=>{var o;if(window.getComputedStyle(e.documentElement).scrollBehavior!=="auto"){let s=Fe();s.style(e.documentElement,"scrollBehavior","auto"),t.add(()=>t.microTask(()=>s.dispose()))}let i=(o=window.scrollY)!=null?o:window.pageYOffset,a=null;t.addEventListener(e,"click",s=>{if(s.target instanceof HTMLElement)try{let l=s.target.closest("a");if(!l)return;let{hash:f}=new URL(l.href),u=e.querySelector(f);u&&!n(u)&&(a=u)}catch{}},!0),t.addEventListener(e,"touchstart",s=>{if(s.target instanceof HTMLElement)if(n(s.target)){let l=s.target;for(;l.parentElement&&n(l.parentElement);)l=l.parentElement;t.style(l,"overscrollBehavior","contain")}else t.style(s.target,"touchAction","none")}),t.addEventListener(e,"touchmove",s=>{if(s.target instanceof HTMLElement){if(s.target.tagName==="INPUT")return;if(n(s.target)){let l=s.target;for(;l.parentElement&&l.dataset.headlessuiPortal!==""&&!(l.scrollHeight>l.clientHeight||l.scrollWidth>l.clientWidth);)l=l.parentElement;l.dataset.headlessuiPortal===""&&s.preventDefault()}else s.preventDefault()}},{passive:!1}),t.add(()=>{var s;let l=(s=window.scrollY)!=null?s:window.pageYOffset;i!==l&&window.scrollTo(0,i),a&&a.isConnected&&(a.scrollIntoView({block:"nearest"}),a=null)})})}}:{}}function ff(){return{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}}function df(e){let t={};for(let r of e)Object.assign(t,r(t));return t}let Ve=Oi(()=>new Map,{PUSH(e,t){var r;let n=(r=this.get(e))!=null?r:{doc:e,count:0,d:Fe(),meta:new Set};return n.count++,n.meta.add(t),this.set(e,n),this},POP(e,t){let r=this.get(e);return r&&(r.count--,r.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:r}){let n={doc:e,d:t,meta:df(r)},o=[cf(),uf(),ff()];o.forEach(({before:i})=>i==null?void 0:i(n)),o.forEach(({after:i})=>i==null?void 0:i(n))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});Ve.subscribe(()=>{let e=Ve.getSnapshot(),t=new Map;for(let[r]of e)t.set(r,r.documentElement.style.overflow);for(let r of e.values()){let n=t.get(r.doc)==="hidden",o=r.count!==0;(o&&!n||!o&&n)&&Ve.dispatch(r.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",r),r.count===0&&Ve.dispatch("TEARDOWN",r)}});function pf(e,t,r=()=>({containers:[]})){let n=Ai(Ve),o=t?n.get(t):void 0,i=o?o.count>0:!1;return ne(()=>{if(!(!t||!e))return Ve.dispatch("PUSH",t,r),()=>Ve.dispatch("POP",t,r)},[e,t]),i}function mf(e,t,r=()=>[document.body]){let n=ut(e,"scroll-lock");pf(n,t,o=>{var i;return{containers:[...(i=o.containers)!=null?i:[],r]}})}function yf(e=0){let[t,r]=p.useState(e),n=p.useCallback(l=>r(l),[t]),o=p.useCallback(l=>r(f=>f|l),[t]),i=p.useCallback(l=>(t&l)===l,[t]),a=p.useCallback(l=>r(f=>f&~l),[r]),s=p.useCallback(l=>r(f=>f^l),[r]);return{flags:t,setFlag:n,addFlag:o,hasFlag:i,removeFlag:a,toggleFlag:s}}var Mi,Ri;typeof process<"u"&&typeof globalThis<"u"&&typeof Element<"u"&&((Mi=process==null?void 0:process.env)==null?void 0:Mi.NODE_ENV)==="test"&&typeof((Ri=Element==null?void 0:Element.prototype)==null?void 0:Ri.getAnimations)>"u"&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join(`
|
|
43
|
-
`)),[]});var hf=(e=>(e[e.None=0]="None",e[e.Closed=1]="Closed",e[e.Enter=2]="Enter",e[e.Leave=4]="Leave",e))(hf||{});function vf(e){let t={};for(let r in e)e[r]===!0&&(t[`data-${r}`]="");return t}function gf(e,t,r,n){let[o,i]=p.useState(r),{hasFlag:a,addFlag:s,removeFlag:l}=yf(e&&o?3:0),f=p.useRef(!1),u=p.useRef(!1),h=mn();return ne(()=>{var v;if(e){if(r&&i(!0),!t){r&&s(3);return}return(v=n==null?void 0:n.start)==null||v.call(n,r),bf(t,{inFlight:f,prepare(){u.current?u.current=!1:u.current=f.current,f.current=!0,!u.current&&(r?(s(3),l(4)):(s(4),l(2)))},run(){u.current?r?(l(3),s(4)):(l(4),s(3)):r?l(1):s(1)},done(){var g;u.current&&typeof t.getAnimations=="function"&&t.getAnimations().length>0||(f.current=!1,l(7),r||i(!1),(g=n==null?void 0:n.end)==null||g.call(n,r))}})}},[e,r,t,h]),e?[o,{closed:a(1),enter:a(2),leave:a(4),transition:a(2)||a(4)}]:[r,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function bf(e,{prepare:t,run:r,done:n,inFlight:o}){let i=Fe();return Ef(e,{prepare:t,inFlight:o}),i.nextFrame(()=>{r(),i.requestAnimationFrame(()=>{i.add(wf(e,n))})}),i.dispose}function wf(e,t){var r,n;let o=Fe();if(!e)return o.dispose;let i=!1;o.add(()=>{i=!0});let a=(n=(r=e.getAnimations)==null?void 0:r.call(e).filter(s=>s instanceof CSSTransition))!=null?n:[];return a.length===0?(t(),o.dispose):(Promise.allSettled(a.map(s=>s.finished)).then(()=>{i||t()}),o.dispose)}function Ef(e,{inFlight:t,prepare:r}){if(t!=null&&t.current){r();return}let n=e.style.transition;e.style.transition="none",r(),e.offsetHeight,e.style.transition=n}function En(e,t){let r=p.useRef([]),n=q(e);p.useEffect(()=>{let o=[...r.current];for(let[i,a]of t.entries())if(r.current[i]!==a){let s=n(t,o);return r.current=t,s}},[n,...t])}let cr=p.createContext(null);cr.displayName="OpenClosedContext";var me=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(me||{});function fr(){return p.useContext(cr)}function Sf({value:e,children:t}){return p.createElement(cr.Provider,{value:e},t)}function xf({children:e}){return p.createElement(cr.Provider,{value:null},e)}function Of(e){function t(){document.readyState!=="loading"&&(e(),document.removeEventListener("DOMContentLoaded",t))}typeof window<"u"&&typeof document<"u"&&(document.addEventListener("DOMContentLoaded",t),t())}let Ne=[];Of(()=>{function e(t){if(!(t.target instanceof HTMLElement)||t.target===document.body||Ne[0]===t.target)return;let r=t.target;r=r.closest(ur),Ne.unshift(r??t.target),Ne=Ne.filter(n=>n!=null&&n.isConnected),Ne.splice(10)}window.addEventListener("click",e,{capture:!0}),window.addEventListener("mousedown",e,{capture:!0}),window.addEventListener("focus",e,{capture:!0}),document.body.addEventListener("click",e,{capture:!0}),document.body.addEventListener("mousedown",e,{capture:!0}),document.body.addEventListener("focus",e,{capture:!0})});function Di(e){let t=q(e),r=p.useRef(!1);p.useEffect(()=>(r.current=!1,()=>{r.current=!0,ir(()=>{r.current&&t()})}),[t])}function Af(){let e=typeof document>"u";return"useSyncExternalStore"in pt?(t=>t.useSyncExternalStore)(pt)(()=>()=>{},()=>!1,()=>!e):!1}function _t(){let e=Af(),[t,r]=pt.useState(We.isHandoffComplete);return t&&We.isHandoffComplete===!1&&r(!1),pt.useEffect(()=>{t!==!0&&r(!0)},[t]),pt.useEffect(()=>We.handoff(),[]),e?!1:t}let Ii=p.createContext(!1);function Tf(){return p.useContext(Ii)}function Li(e){return p.createElement(Ii.Provider,{value:e.force},e.children)}function Pf(e){let t=Tf(),r=p.useContext(ji),n=$t(e),[o,i]=p.useState(()=>{var a;if(!t&&r!==null)return(a=r.current)!=null?a:null;if(We.isServer)return null;let s=n==null?void 0:n.getElementById("headlessui-portal-root");if(s)return s;if(n===null)return null;let l=n.createElement("div");return l.setAttribute("id","headlessui-portal-root"),n.body.appendChild(l)});return p.useEffect(()=>{o!==null&&(n!=null&&n.body.contains(o)||n==null||n.body.appendChild(o))},[o,n]),p.useEffect(()=>{t||r!==null&&i(r.current)},[r,i,t]),o}let ki=p.Fragment,Cf=se(function(e,t){let r=e,n=p.useRef(null),o=be(kc(u=>{n.current=u}),t),i=$t(n),a=Pf(n),[s]=p.useState(()=>{var u;return We.isServer?null:(u=i==null?void 0:i.createElement("div"))!=null?u:null}),l=p.useContext(Sn),f=_t();return ne(()=>{!a||!s||a.contains(s)||(s.setAttribute("data-headlessui-portal",""),a.appendChild(s))},[a,s]),ne(()=>{if(s&&l)return l.register(s)},[l,s]),Di(()=>{var u;!a||!s||(s instanceof Node&&a.contains(s)&&a.removeChild(s),a.childNodes.length<=0&&((u=a.parentElement)==null||u.removeChild(a)))}),f?!a||!s?null:ya.createPortal(fe({ourProps:{ref:o},theirProps:r,slot:{},defaultTag:ki,name:"Portal"}),s):null});function Ff(e,t){let r=be(t),{enabled:n=!0,...o}=e;return n?p.createElement(Cf,{...o,ref:r}):fe({ourProps:{ref:r},theirProps:o,slot:{},defaultTag:ki,name:"Portal"})}let $f=p.Fragment,ji=p.createContext(null);function _f(e,t){let{target:r,...n}=e,o={ref:be(t)};return p.createElement(ji.Provider,{value:r},fe({ourProps:o,theirProps:n,defaultTag:$f,name:"Popover.Group"}))}let Sn=p.createContext(null);function Nf(){let e=p.useContext(Sn),t=p.useRef([]),r=q(i=>(t.current.push(i),e&&e.register(i),()=>n(i))),n=q(i=>{let a=t.current.indexOf(i);a!==-1&&t.current.splice(a,1),e&&e.unregister(i)}),o=p.useMemo(()=>({register:r,unregister:n,portals:t}),[r,n,t]);return[t,p.useMemo(()=>function({children:i}){return p.createElement(Sn.Provider,{value:o},i)},[o])]}let Mf=se(Ff),Bi=se(_f),Rf=Object.assign(Mf,{Group:Bi});function Df(e,t=typeof document<"u"?document.defaultView:null,r){let n=ut(e,"escape");Ni(t,"keydown",o=>{n&&(o.defaultPrevented||o.key===xi.Escape&&r(o))})}function If(){var e;let[t]=p.useState(()=>typeof window<"u"&&typeof window.matchMedia=="function"?window.matchMedia("(pointer: coarse)"):null),[r,n]=p.useState((e=t==null?void 0:t.matches)!=null?e:!1);return ne(()=>{if(!t)return;function o(i){n(i.matches)}return t.addEventListener("change",o),()=>t.removeEventListener("change",o)},[t]),r}function Lf({defaultContainers:e=[],portals:t,mainTreeNode:r}={}){let n=$t(r),o=q(()=>{var i,a;let s=[];for(let l of e)l!==null&&(l instanceof HTMLElement?s.push(l):"current"in l&&l.current instanceof HTMLElement&&s.push(l.current));if(t!=null&&t.current)for(let l of t.current)s.push(l);for(let l of(i=n==null?void 0:n.querySelectorAll("html > *, body > *"))!=null?i:[])l!==document.body&&l!==document.head&&l instanceof HTMLElement&&l.id!=="headlessui-portal-root"&&(r&&(l.contains(r)||l.contains((a=r==null?void 0:r.getRootNode())==null?void 0:a.host))||s.some(f=>l.contains(f))||s.push(l));return s});return{resolveContainers:o,contains:q(i=>o().some(a=>a.contains(i)))}}let Ui=p.createContext(null);function Wi({children:e,node:t}){let[r,n]=p.useState(null),o=Hi(t??r);return p.createElement(Ui.Provider,{value:o},e,o===null&&p.createElement(vn,{features:lr.Hidden,ref:i=>{var a,s;if(i){for(let l of(s=(a=or(i))==null?void 0:a.querySelectorAll("html > *, body > *"))!=null?s:[])if(l!==document.body&&l!==document.head&&l instanceof HTMLElement&&l!=null&&l.contains(i)){n(l);break}}}}))}function Hi(e=null){var t;return(t=p.useContext(Ui))!=null?t:e}function xn(){let e=p.useRef(!1);return ne(()=>(e.current=!0,()=>{e.current=!1}),[]),e}var Nt=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(Nt||{});function kf(){let e=p.useRef(0);return $i(!0,"keydown",t=>{t.key==="Tab"&&(e.current=t.shiftKey?1:0)},!0),e}function qi(e){if(!e)return new Set;if(typeof e=="function")return new Set(e());let t=new Set;for(let r of e.current)r.current instanceof HTMLElement&&t.add(r.current);return t}let jf="div";var ze=(e=>(e[e.None=0]="None",e[e.InitialFocus=1]="InitialFocus",e[e.TabLock=2]="TabLock",e[e.FocusLock=4]="FocusLock",e[e.RestoreFocus=8]="RestoreFocus",e[e.AutoFocus=16]="AutoFocus",e))(ze||{});function Bf(e,t){let r=p.useRef(null),n=be(r,t),{initialFocus:o,initialFocusFallback:i,containers:a,features:s=15,...l}=e;_t()||(s=0);let f=$t(r);qf(s,{ownerDocument:f});let u=Vf(s,{ownerDocument:f,container:r,initialFocus:o,initialFocusFallback:i});zf(s,{ownerDocument:f,container:r,containers:a,previousActiveElement:u});let h=kf(),v=q(w=>{let S=r.current;S&&(x=>x())(()=>{$e(h.current,{[Nt.Forwards]:()=>{Ct(S,xe.First,{skipElements:[w.relatedTarget,i]})},[Nt.Backwards]:()=>{Ct(S,xe.Last,{skipElements:[w.relatedTarget,i]})}})})}),g=ut(!!(s&2),"focus-trap#tab-lock"),c=mn(),m=p.useRef(!1),y={ref:n,onKeyDown(w){w.key=="Tab"&&(m.current=!0,c.requestAnimationFrame(()=>{m.current=!1}))},onBlur(w){if(!(s&4))return;let S=qi(a);r.current instanceof HTMLElement&&S.add(r.current);let x=w.relatedTarget;x instanceof HTMLElement&&x.dataset.headlessuiFocusGuard!=="true"&&(Vi(S,x)||(m.current?Ct(r.current,$e(h.current,{[Nt.Forwards]:()=>xe.Next,[Nt.Backwards]:()=>xe.Previous})|xe.WrapAround,{relativeTo:w.target}):w.target instanceof HTMLElement&&Oe(w.target)))}};return p.createElement(p.Fragment,null,g&&p.createElement(vn,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:v,features:lr.Focusable}),fe({ourProps:y,theirProps:l,defaultTag:jf,name:"FocusTrap"}),g&&p.createElement(vn,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:v,features:lr.Focusable}))}let Uf=se(Bf),Wf=Object.assign(Uf,{features:ze});function Hf(e=!0){let t=p.useRef(Ne.slice());return En(([r],[n])=>{n===!0&&r===!1&&ir(()=>{t.current.splice(0)}),n===!1&&r===!0&&(t.current=Ne.slice())},[e,Ne,t]),q(()=>{var r;return(r=t.current.find(n=>n!=null&&n.isConnected))!=null?r:null})}function qf(e,{ownerDocument:t}){let r=!!(e&8),n=Hf(r);En(()=>{r||(t==null?void 0:t.activeElement)===(t==null?void 0:t.body)&&Oe(n())},[r]),Di(()=>{r&&Oe(n())})}function Vf(e,{ownerDocument:t,container:r,initialFocus:n,initialFocusFallback:o}){let i=p.useRef(null),a=ut(!!(e&1),"focus-trap#initial-focus"),s=xn();return En(()=>{if(e===0)return;if(!a){o!=null&&o.current&&Oe(o.current);return}let l=r.current;l&&ir(()=>{if(!s.current)return;let f=t==null?void 0:t.activeElement;if(n!=null&&n.current){if((n==null?void 0:n.current)===f){i.current=f;return}}else if(l.contains(f)){i.current=f;return}if(n!=null&&n.current)Oe(n.current);else{if(e&16){if(Ct(l,xe.First|xe.AutoFocus)!==wn.Error)return}else if(Ct(l,xe.First)!==wn.Error)return;if(o!=null&&o.current&&(Oe(o.current),(t==null?void 0:t.activeElement)===o.current))return;console.warn("There are no focusable elements inside the <FocusTrap />")}i.current=t==null?void 0:t.activeElement})},[o,a,e]),i}function zf(e,{ownerDocument:t,container:r,containers:n,previousActiveElement:o}){let i=xn(),a=!!(e&4);Ni(t==null?void 0:t.defaultView,"focus",s=>{if(!a||!i.current)return;let l=qi(n);r.current instanceof HTMLElement&&l.add(r.current);let f=o.current;if(!f)return;let u=s.target;u&&u instanceof HTMLElement?Vi(l,u)?(o.current=u,Oe(u)):(s.preventDefault(),s.stopPropagation(),Oe(f)):Oe(o.current)},!0)}function Vi(e,t){for(let r of e)if(r.contains(t))return!0;return!1}function zi(e){var t;return!!(e.enter||e.enterFrom||e.enterTo||e.leave||e.leaveFrom||e.leaveTo)||((t=e.as)!=null?t:Ki)!==p.Fragment||p.Children.count(e.children)===1}let dr=p.createContext(null);dr.displayName="TransitionContext";var Gf=(e=>(e.Visible="visible",e.Hidden="hidden",e))(Gf||{});function Kf(){let e=p.useContext(dr);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}function Jf(){let e=p.useContext(pr);if(e===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}let pr=p.createContext(null);pr.displayName="NestingContext";function mr(e){return"children"in e?mr(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function Gi(e,t){let r=He(e),n=p.useRef([]),o=xn(),i=mn(),a=q((g,c=_e.Hidden)=>{let m=n.current.findIndex(({el:y})=>y===g);m!==-1&&($e(c,{[_e.Unmount](){n.current.splice(m,1)},[_e.Hidden](){n.current[m].state="hidden"}}),i.microTask(()=>{var y;!mr(n)&&o.current&&((y=r.current)==null||y.call(r))}))}),s=q(g=>{let c=n.current.find(({el:m})=>m===g);return c?c.state!=="visible"&&(c.state="visible"):n.current.push({el:g,state:"visible"}),()=>a(g,_e.Unmount)}),l=p.useRef([]),f=p.useRef(Promise.resolve()),u=p.useRef({enter:[],leave:[]}),h=q((g,c,m)=>{l.current.splice(0),t&&(t.chains.current[c]=t.chains.current[c].filter(([y])=>y!==g)),t==null||t.chains.current[c].push([g,new Promise(y=>{l.current.push(y)})]),t==null||t.chains.current[c].push([g,new Promise(y=>{Promise.all(u.current[c].map(([w,S])=>S)).then(()=>y())})]),c==="enter"?f.current=f.current.then(()=>t==null?void 0:t.wait.current).then(()=>m(c)):m(c)}),v=q((g,c,m)=>{Promise.all(u.current[c].splice(0).map(([y,w])=>w)).then(()=>{var y;(y=l.current.shift())==null||y()}).then(()=>m(c))});return p.useMemo(()=>({children:n,register:s,unregister:a,onStart:h,onStop:v,wait:f,chains:u}),[s,a,n,h,v,u,f])}let Ki=p.Fragment,Ji=ar.RenderStrategy;function Yf(e,t){var r,n;let{transition:o=!0,beforeEnter:i,afterEnter:a,beforeLeave:s,afterLeave:l,enter:f,enterFrom:u,enterTo:h,entered:v,leave:g,leaveFrom:c,leaveTo:m,...y}=e,[w,S]=p.useState(null),x=p.useRef(null),O=zi(e),T=be(...O?[x,t,S]:t===null?[]:[t]),P=(r=y.unmount)==null||r?_e.Unmount:_e.Hidden,{show:_,appear:j,initial:H}=Kf(),[I,X]=p.useState(_?"visible":"hidden"),Z=Jf(),{register:C,unregister:L}=Z;ne(()=>C(x),[C,x]),ne(()=>{if(P===_e.Hidden&&x.current){if(_&&I!=="visible"){X("visible");return}return $e(I,{hidden:()=>L(x),visible:()=>C(x)})}},[I,x,C,L,_,P]);let K=_t();ne(()=>{if(O&&K&&I==="visible"&&x.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[x,I,K,O]);let ce=H&&!j,ye=j&&_&&H,we=p.useRef(!1),re=Gi(()=>{we.current||(X("hidden"),L(x))},Z),U=q(Ke=>{we.current=!0;let Re=Ke?"enter":"leave";re.onStart(x,Re,Ee=>{Ee==="enter"?i==null||i():Ee==="leave"&&(s==null||s())})}),Me=q(Ke=>{let Re=Ke?"enter":"leave";we.current=!1,re.onStop(x,Re,Ee=>{Ee==="enter"?a==null||a():Ee==="leave"&&(l==null||l())}),Re==="leave"&&!mr(re)&&(X("hidden"),L(x))});p.useEffect(()=>{O&&o||(U(_),Me(_))},[_,O,o]);let hr=!(!o||!O||!K||ce),[,ee]=gf(hr,w,_,{start:U,end:Me}),Pn=qe({ref:T,className:((n=yn(y.className,ye&&f,ye&&u,ee.enter&&f,ee.enter&&ee.closed&&u,ee.enter&&!ee.closed&&h,ee.leave&&g,ee.leave&&!ee.closed&&c,ee.leave&&ee.closed&&m,!ee.transition&&_&&v))==null?void 0:n.trim())||void 0,...vf(ee)}),Ge=0;return I==="visible"&&(Ge|=me.Open),I==="hidden"&&(Ge|=me.Closed),ee.enter&&(Ge|=me.Opening),ee.leave&&(Ge|=me.Closing),p.createElement(pr.Provider,{value:re},p.createElement(Sf,{value:Ge},fe({ourProps:Pn,theirProps:y,defaultTag:Ki,features:Ji,visible:I==="visible",name:"Transition.Child"})))}function Xf(e,t){let{show:r,appear:n=!1,unmount:o=!0,...i}=e,a=p.useRef(null),s=zi(e),l=be(...s?[a,t]:t===null?[]:[t]);_t();let f=fr();if(r===void 0&&f!==null&&(r=(f&me.Open)===me.Open),r===void 0)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[u,h]=p.useState(r?"visible":"hidden"),v=Gi(()=>{r||h("hidden")}),[g,c]=p.useState(!0),m=p.useRef([r]);ne(()=>{g!==!1&&m.current[m.current.length-1]!==r&&(m.current.push(r),c(!1))},[m,r]);let y=p.useMemo(()=>({show:r,appear:n,initial:g}),[r,n,g]);ne(()=>{r?h("visible"):!mr(v)&&a.current!==null&&h("hidden")},[r,v]);let w={unmount:o},S=q(()=>{var O;g&&c(!1),(O=e.beforeEnter)==null||O.call(e)}),x=q(()=>{var O;g&&c(!1),(O=e.beforeLeave)==null||O.call(e)});return p.createElement(pr.Provider,{value:v},p.createElement(dr.Provider,{value:y},fe({ourProps:{...w,as:p.Fragment,children:p.createElement(Yi,{ref:l,...w,...i,beforeEnter:S,beforeLeave:x})},theirProps:{},defaultTag:p.Fragment,features:Ji,visible:u==="visible",name:"Transition"})))}function Qf(e,t){let r=p.useContext(dr)!==null,n=fr()!==null;return p.createElement(p.Fragment,null,!r&&n?p.createElement(On,{ref:t,...e}):p.createElement(Yi,{ref:t,...e}))}let On=se(Xf),Yi=se(Yf),ct=se(Qf),Xi=Object.assign(On,{Child:ct,Root:On});var Zf=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Zf||{}),ed=(e=>(e[e.SetTitleId=0]="SetTitleId",e))(ed||{});let td={0(e,t){return e.titleId===t.id?e:{...e,titleId:t.id}}},An=p.createContext(null);An.displayName="DialogContext";function yr(e){let t=p.useContext(An);if(t===null){let r=new Error(`<${e} /> is missing a parent <Dialog /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,yr),r}return t}function rd(e,t){return $e(t.type,td,e,t)}let Qi=se(function(e,t){let r=p.useId(),{id:n=`headlessui-dialog-${r}`,open:o,onClose:i,initialFocus:a,role:s="dialog",autoFocus:l=!0,__demoMode:f=!1,unmount:u=!1,...h}=e,v=p.useRef(!1);s=function(){return s==="dialog"||s==="alertdialog"?s:(v.current||(v.current=!0,console.warn(`Invalid role [${s}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)),"dialog")}();let g=fr();o===void 0&&g!==null&&(o=(g&me.Open)===me.Open);let c=p.useRef(null),m=be(c,t),y=$t(c),w=o?0:1,[S,x]=p.useReducer(rd,{titleId:null,descriptionId:null,panelRef:p.createRef()}),O=q(()=>i(!1)),T=q(U=>x({type:0,id:U})),P=_t()?w===0:!1,[_,j]=Nf(),H={get current(){var U;return(U=S.panelRef.current)!=null?U:c.current}},I=Hi(),{resolveContainers:X}=Lf({mainTreeNode:I,portals:_,defaultContainers:[H]}),Z=g!==null?(g&me.Closing)===me.Closing:!1;Kc(f||Z?!1:P,{allowed:q(()=>{var U,Me;return[(Me=(U=c.current)==null?void 0:U.closest("[data-headlessui-portal]"))!=null?Me:null]}),disallowed:q(()=>{var U;return[(U=I==null?void 0:I.closest("body > *:not(#headlessui-portal-root)"))!=null?U:null]})}),lf(P,X,U=>{U.preventDefault(),O()}),Df(P,y==null?void 0:y.defaultView,U=>{U.preventDefault(),U.stopPropagation(),document.activeElement&&"blur"in document.activeElement&&typeof document.activeElement.blur=="function"&&document.activeElement.blur(),O()}),mf(f||Z?!1:P,y,X),Jc(P,c,O);let[C,L]=jc(),K=p.useMemo(()=>[{dialogState:w,close:O,setTitleId:T,unmount:u},S],[w,S,O,T,u]),ce=p.useMemo(()=>({open:w===0}),[w]),ye={ref:m,id:n,role:s,tabIndex:-1,"aria-modal":f?void 0:w===0?!0:void 0,"aria-labelledby":S.titleId,"aria-describedby":C,unmount:u},we=!If(),re=ze.None;return P&&!f&&(re|=ze.RestoreFocus,re|=ze.TabLock,l&&(re|=ze.AutoFocus),we&&(re|=ze.InitialFocus)),p.createElement(xf,null,p.createElement(Li,{force:!0},p.createElement(Rf,null,p.createElement(An.Provider,{value:K},p.createElement(Bi,{target:c},p.createElement(Li,{force:!1},p.createElement(L,{slot:ce},p.createElement(j,null,p.createElement(Wf,{initialFocus:a,initialFocusFallback:c,containers:X,features:re},p.createElement(Vc,{value:O},fe({ourProps:ye,theirProps:h,slot:ce,defaultTag:nd,features:od,visible:w===0,name:"Dialog"})))))))))))}),nd="div",od=ar.RenderStrategy|ar.Static;function id(e,t){let{transition:r=!1,open:n,...o}=e,i=fr(),a=e.hasOwnProperty("open")||i!==null,s=e.hasOwnProperty("onClose");if(!a&&!s)throw new Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!a)throw new Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!s)throw new Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if(!i&&typeof e.open!="boolean")throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${e.open}`);if(typeof e.onClose!="function")throw new Error(`You provided an \`onClose\` prop to the \`Dialog\`, but the value is not a function. Received: ${e.onClose}`);return(n!==void 0||r)&&!o.static?p.createElement(Wi,null,p.createElement(Xi,{show:n,transition:r,unmount:o.unmount},p.createElement(Qi,{ref:t,...o}))):p.createElement(Wi,null,p.createElement(Qi,{ref:t,open:n,...o}))}let ad="div";function sd(e,t){let r=p.useId(),{id:n=`headlessui-dialog-panel-${r}`,transition:o=!1,...i}=e,[{dialogState:a,unmount:s},l]=yr("Dialog.Panel"),f=be(t,l.panelRef),u=p.useMemo(()=>({open:a===0}),[a]),h=q(g=>{g.stopPropagation()}),v={ref:f,id:n,onClick:h};return p.createElement(o?ct:p.Fragment,{...o?{unmount:s}:{}},fe({ourProps:v,theirProps:i,slot:u,defaultTag:ad,name:"Dialog.Panel"}))}let ld="div";function ud(e,t){let{transition:r=!1,...n}=e,[{dialogState:o,unmount:i}]=yr("Dialog.Backdrop"),a=p.useMemo(()=>({open:o===0}),[o]),s={ref:t,"aria-hidden":!0};return p.createElement(r?ct:p.Fragment,{...r?{unmount:i}:{}},fe({ourProps:s,theirProps:n,slot:a,defaultTag:ld,name:"Dialog.Backdrop"}))}let cd="h2";function fd(e,t){let r=p.useId(),{id:n=`headlessui-dialog-title-${r}`,...o}=e,[{dialogState:i,setTitleId:a}]=yr("Dialog.Title"),s=be(t);p.useEffect(()=>(a(n),()=>a(null)),[n,a]);let l=p.useMemo(()=>({open:i===0}),[i]);return fe({ourProps:{ref:s,id:n},theirProps:o,slot:l,defaultTag:cd,name:"Dialog.Title"})}let dd=se(id),Tn=se(sd);se(ud);let pd=se(fd),md=Object.assign(dd,{Panel:Tn,Title:pd,Description:Hc});function Zi({onClick:e}){return R.jsxs("button",{type:"button",className:"im-close-button text-gray-400 hover:text-gray-500",onClick:e,children:[R.jsx("span",{className:"sr-only",children:"Close"}),R.jsx("svg",{className:"size-6",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor","aria-hidden":"true",children:R.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})]})}const yd=({modalContext:e,modalProps:t,children:r})=>R.jsx("div",{className:"im-modal-container fixed inset-0 z-40 overflow-y-auto p-4",children:R.jsx("div",{className:nr("im-modal-positioner flex min-h-full justify-center",{"items-start":t.position==="top","items-center":t.position==="center","items-end":t.position==="bottom"}),children:R.jsx(ct,{enterFrom:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",enterTo:"opacity-100 translate-y-0 sm:scale-100",leaveFrom:"opacity-100 translate-y-0 sm:scale-100",leaveTo:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",afterLeave:e.afterLeave,className:nr("im-modal-wrapper w-full transition duration-300 ease-in-out",e.onTopOfStack?"":"blur-sm",{"sm:max-w-sm":t.maxWidth==="sm","sm:max-w-md":t.maxWidth==="md","sm:max-w-md md:max-w-lg":t.maxWidth==="lg","sm:max-w-md md:max-w-xl":t.maxWidth==="xl","sm:max-w-md md:max-w-xl lg:max-w-2xl":t.maxWidth==="2xl","sm:max-w-md md:max-w-xl lg:max-w-3xl":t.maxWidth==="3xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-4xl":t.maxWidth==="4xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl":t.maxWidth==="5xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-6xl":t.maxWidth==="6xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-7xl":t.maxWidth==="7xl"}),children:R.jsxs(Tn,{className:`im-modal-content relative ${t.paddingClasses} ${t.panelClasses}`,children:[t.closeButton&&R.jsx("div",{className:"absolute right-0 top-0 pr-3 pt-3",children:R.jsx(Zi,{onClick:e.close})}),typeof r=="function"?r({modalContext:e,modalProps:t}):r]})})})}),hd=({modalContext:e,modalProps:t,children:r})=>R.jsx("div",{className:"im-slideover-container fixed inset-0 z-40 overflow-y-auto overflow-x-hidden",children:R.jsx("div",{className:nr("im-slideover-positioner flex min-h-full items-center",{"justify-start":t.position==="left","justify-end":t.position==="right"}),children:R.jsx(ct,{enterFrom:`opacity-0 ${t.position==="left"?"-translate-x-full":"translate-x-full"}`,enterTo:"opacity-100 translate-x-0",leaveFrom:"opacity-100 translate-x-0",leaveTo:`opacity-0 ${t.position==="left"?"-translate-x-full":"translate-x-full"}`,afterLeave:e.afterLeave,className:nr("im-slideover-wrapper w-full transition duration-300 ease-in-out",e.onTopOfStack?"":"blur-sm",{"sm:max-w-sm":t.maxWidth==="sm","sm:max-w-md":t.maxWidth==="md","sm:max-w-md md:max-w-lg":t.maxWidth==="lg","sm:max-w-md md:max-w-xl":t.maxWidth==="xl","sm:max-w-md md:max-w-xl lg:max-w-2xl":t.maxWidth==="2xl","sm:max-w-md md:max-w-xl lg:max-w-3xl":t.maxWidth==="3xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-4xl":t.maxWidth==="4xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl":t.maxWidth==="5xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-6xl":t.maxWidth==="6xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-7xl":t.maxWidth==="7xl"}),children:R.jsxs(Tn,{className:`im-slideover-content relative ${t.paddingClasses} ${t.panelClasses}`,children:[t.closeButton&&R.jsx("div",{className:"absolute right-0 top-0 pr-3 pt-3",children:R.jsx(Zi,{onClick:e.close})}),typeof r=="function"?r({modalContext:e,modalProps:t}):r]})})})}),ea=p.forwardRef(({name:e,children:t,...r},n)=>{const o=a=>typeof t=="function"?t(a):t,i=p.useRef(null);return p.useImperativeHandle(n,()=>i.current,[i]),R.jsx(dn,{ref:i,name:e,...r,children:({afterLeave:a,close:s,emit:l,getChildModal:f,getParentModal:u,modalContext:h,modalProps:v,reload:g})=>R.jsx(Xi,{appear:!0,show:h.open??!1,children:R.jsxs(md,{as:"div",className:"im-dialog relative z-20",onClose:()=>v.closeExplicitly?null:s(),"data-inertiaui-modal-id":h.id,"data-inertiaui-modal-index":h.index,children:[h.index===0?R.jsx(ct,{enter:"transition transform ease-in-out duration-300",enterFrom:"opacity-0",enterTo:"opacity-100",leave:"transition transform ease-in-out duration-300",leaveFrom:"opacity-100",leaveTo:"opacity-0",children:h.onTopOfStack?R.jsx("div",{className:"im-backdrop fixed inset-0 z-30 bg-black/75","aria-hidden":"true"}):R.jsx("div",{})}):null,h.index>0&&h.onTopOfStack?R.jsx("div",{className:"im-backdrop fixed inset-0 z-30 bg-black/75"}):null,v.slideover?R.jsx(hd,{modalContext:h,modalProps:v,children:o({afterLeave:a,close:s,emit:l,getChildModal:f,getParentModal:u,modalContext:h,modalProps:v,reload:g})}):R.jsx(yd,{modalContext:h,modalProps:v,children:o({afterLeave:a,close:s,emit:l,getChildModal:f,getParentModal:u,modalContext:h,modalProps:v,reload:g})})]})})})});ea.displayName="Modal";const vd=({href:e,method:t="get",data:r={},as:n="a",fragment:o=null,headers:i={},queryStringArrayFormat:a="brackets",onAfterLeave:s=null,onBlur:l=null,onClose:f=null,onError:u=null,onFocus:h=null,onStart:v=null,onSuccess:g=null,children:c,...m})=>{const[y,w]=p.useState(!1),[S,x]=p.useState(null),{stack:O,visit:T}=rr(),P={},_={};Object.keys(m).forEach(C=>{hi.includes(C)||(C.startsWith("on")&&typeof m[C]=="function"?C.toLowerCase()in window?P[C]=m[C]:_[C]=m[C]:P[C]=m[C])}),p.useEffect(()=>{o&&window.location.hash===`#${o}`&&Z()},[o]);const[j,H]=p.useState(!1);p.useEffect(()=>{S&&(S.onTopOfStack&&j?h==null||h():!S.onTopOfStack&&!j&&(l==null||l()),H(!S.onTopOfStack))},[O]);const I=p.useCallback(C=>{o&&C===0&&(window.location.hash=""),f==null||f()},[f,o]),X=p.useCallback(()=>{x(null),s==null||s()},[s]),Z=p.useCallback(C=>{C==null||C.preventDefault(),!y&&(e.startsWith("#")||(w(!0),v==null||v()),T(e,t,r,i,Ks(xo(m,hi)),()=>I(O.length),X,a).then(L=>{x(L),o&&L.index===0&&(window.location.hash=o),L.registerEventListenersFromProps(_),g==null||g()}).catch(L=>{console.error(L),u==null||u(L)}).finally(()=>w(!1)))},[e,t,r,i,a,m,I,X]);return R.jsx(n,{...P,href:e,onClick:Z,children:typeof c=="function"?c({loading:y}):c})};W.HeadlessModal=dn,W.Modal=ea,W.ModalLink=vd,W.ModalRoot=Fc,W.ModalStackProvider=Cc,W.getConfig=Dn,W.putConfig=ba,W.resetConfig=ga,W.useModalIndex=vi,W.useModalStack=rr,Object.defineProperty(W,Symbol.toStringTag,{value:"Module"})});
|
|
37
|
+
`))}else{let m=s.props,E=m==null?void 0:m.className,d=typeof E=="function"?(...h)=>Ir(E(...h),a.className):Ir(E,a.className),v=d?{className:d}:{},y=to(s.props,_e(_r(a,["ref"])));for(let h in g)h in y&&delete g[h];return f.cloneElement(s,Object.assign({},y,g,p,{ref:o(s.ref,p.ref)},v))}return f.createElement(i,Object.assign({},_r(a,["ref"]),i!==f.Fragment&&p,i!==f.Fragment&&g),s)}function Yl(){let t=f.useRef([]),e=f.useCallback(r=>{for(let n of t.current)n!=null&&(typeof n=="function"?n(r):n.current=r)},[]);return(...r)=>{if(!r.every(n=>n==null))return t.current=r,e}}function Kl(...t){return t.every(e=>e==null)?void 0:e=>{for(let r of t)r!=null&&(typeof r=="function"?r(e):r.current=e)}}function to(...t){if(t.length===0)return{};if(t.length===1)return t[0];let e={},r={};for(let n of t)for(let o in n)o.startsWith("on")&&typeof n[o]=="function"?(r[o]!=null||(r[o]=[]),r[o].push(n[o])):e[o]=n[o];if(e.disabled||e["aria-disabled"])for(let n in r)/^(on(?:Click|Pointer|Mouse|Key)(?:Down|Up|Press)?)$/.test(n)&&(r[n]=[o=>{var i;return(i=o==null?void 0:o.preventDefault)==null?void 0:i.call(o)}]);for(let n in r)Object.assign(e,{[n](o,...i){let l=r[n];for(let u of l){if((o instanceof Event||(o==null?void 0:o.nativeEvent)instanceof Event)&&o.defaultPrevented)return;u(o,...i)}}});return e}function re(t){var e;return Object.assign(f.forwardRef(t),{displayName:(e=t.displayName)!=null?e:t.name})}function _e(t){let e=Object.assign({},t);for(let r in e)e[r]===void 0&&delete e[r];return e}function _r(t,e=[]){let r=Object.assign({},t);for(let n of e)n in r&&delete r[n];return r}let Xl="span";var Wt=(t=>(t[t.None=1]="None",t[t.Focusable=2]="Focusable",t[t.Hidden=4]="Hidden",t))(Wt||{});function Jl(t,e){var r;let{features:n=1,...o}=t,i={ref:e,"aria-hidden":(n&2)===2?!0:(r=o["aria-hidden"])!=null?r:void 0,hidden:(n&4)===4?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(n&4)===4&&(n&2)!==2&&{display:"none"}}};return ie()({ourProps:i,theirProps:o,slot:{},defaultTag:Xl,name:"Hidden"})}let Dr=re(Jl),ro=Symbol();function Ql(t,e=!0){return Object.assign(t,{[ro]:e})}function ye(...t){let e=f.useRef(t);f.useEffect(()=>{e.current=t},[t]);let r=B(n=>{for(let o of e.current)o!=null&&(typeof o=="function"?o(n):o.current=n)});return t.every(n=>n==null||(n==null?void 0:n[ro]))?void 0:r}let kr=f.createContext(null);kr.displayName="DescriptionContext";function no(){let t=f.useContext(kr);if(t===null){let e=new Error("You used a <Description /> component, but it is not inside a relevant parent.");throw Error.captureStackTrace&&Error.captureStackTrace(e,no),e}return t}function Zl(){let[t,e]=f.useState([]);return[t.length>0?t.join(" "):void 0,f.useMemo(()=>function(r){let n=B(i=>(e(l=>[...l,i]),()=>e(l=>{let u=l.slice(),a=u.indexOf(i);return a!==-1&&u.splice(a,1),u}))),o=f.useMemo(()=>({register:n,slot:r.slot,name:r.name,props:r.props,value:r.value}),[n,r.slot,r.name,r.props,r.value]);return f.createElement(kr.Provider,{value:o},r.children)},[e])]}let eu="p";function tu(t,e){let r=f.useId(),n=Gl(),{id:o=`headlessui-description-${r}`,...i}=t,l=no(),u=ye(e);ee(()=>l.register(o),[o,l.register]);let a=n||!1,p=f.useMemo(()=>({...l.slot,disabled:a}),[l.slot,a]),s={ref:u,...l.props,id:o};return ie()({ourProps:s,theirProps:i,slot:p,defaultTag:eu,name:l.name||"Description"})}let ru=re(tu),nu=Object.assign(ru,{});var oo=(t=>(t.Space=" ",t.Enter="Enter",t.Escape="Escape",t.Backspace="Backspace",t.Delete="Delete",t.ArrowLeft="ArrowLeft",t.ArrowUp="ArrowUp",t.ArrowRight="ArrowRight",t.ArrowDown="ArrowDown",t.Home="Home",t.End="End",t.PageUp="PageUp",t.PageDown="PageDown",t.Tab="Tab",t))(oo||{});let ou=f.createContext(()=>{});function iu({value:t,children:e}){return f.createElement(ou.Provider,{value:t},e)}let au=class extends Map{constructor(e){super(),this.factory=e}get(e){let r=super.get(e);return r===void 0&&(r=this.factory(e),this.set(e,r)),r}};function io(t,e){let r=t(),n=new Set;return{getSnapshot(){return r},subscribe(o){return n.add(o),()=>n.delete(o)},dispatch(o,...i){let l=e[o].call(r,...i);l&&(r=l,n.forEach(u=>u()))}}}function ao(t){return f.useSyncExternalStore(t.subscribe,t.getSnapshot,t.getSnapshot)}let lu=new au(()=>io(()=>[],{ADD(t){return this.includes(t)?this:[...this,t]},REMOVE(t){let e=this.indexOf(t);if(e===-1)return this;let r=this.slice();return r.splice(e,1),r}}));function Je(t,e){let r=lu.get(e),n=f.useId(),o=ao(r);if(ee(()=>{if(t)return r.dispatch("ADD",n),()=>r.dispatch("REMOVE",n)},[r,t]),!t)return!1;let i=o.indexOf(n),l=o.length;return i===-1&&(i=l,l+=1),i===l-1}let Nr=new Map,dt=new Map;function lo(t){var e;let r=(e=dt.get(t))!=null?e:0;return dt.set(t,r+1),r!==0?()=>uo(t):(Nr.set(t,{"aria-hidden":t.getAttribute("aria-hidden"),inert:t.inert}),t.setAttribute("aria-hidden","true"),t.inert=!0,()=>uo(t))}function uo(t){var e;let r=(e=dt.get(t))!=null?e:1;if(r===1?dt.delete(t):dt.set(t,r-1),r!==1)return;let n=Nr.get(t);n&&(n["aria-hidden"]===null?t.removeAttribute("aria-hidden"):t.setAttribute("aria-hidden",n["aria-hidden"]),t.inert=n.inert,Nr.delete(t))}function uu(t,{allowed:e,disallowed:r}={}){let n=Je(t,"inert-others");ee(()=>{var o,i;if(!n)return;let l=Oe();for(let a of(o=r==null?void 0:r())!=null?o:[])a&&l.add(lo(a));let u=(i=e==null?void 0:e())!=null?i:[];for(let a of u){if(!a)continue;let p=kt(a);if(!p)continue;let s=a.parentElement;for(;s&&s!==p.body;){for(let g of s.children)u.some(m=>g.contains(m))||l.add(lo(g));s=s.parentElement}}return l.dispose},[n,e,r])}function su(t,e,r){let n=Ie(o=>{let i=o.getBoundingClientRect();i.x===0&&i.y===0&&i.width===0&&i.height===0&&r()});f.useEffect(()=>{if(!t)return;let o=e===null?null:e instanceof HTMLElement?e:e.current;if(!o)return;let i=Oe();if(typeof ResizeObserver<"u"){let l=new ResizeObserver(()=>n.current(o));l.observe(o),i.add(()=>l.disconnect())}if(typeof IntersectionObserver<"u"){let l=new IntersectionObserver(()=>n.current(o));l.observe(o),i.add(()=>l.disconnect())}return()=>i.dispose()},[e,n,t])}let Ut=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(t=>`${t}:not([tabindex='-1'])`).join(","),cu=["[data-autofocus]"].map(t=>`${t}:not([tabindex='-1'])`).join(",");var he=(t=>(t[t.First=1]="First",t[t.Previous=2]="Previous",t[t.Next=4]="Next",t[t.Last=8]="Last",t[t.WrapAround=16]="WrapAround",t[t.NoScroll=32]="NoScroll",t[t.AutoFocus=64]="AutoFocus",t))(he||{}),jr=(t=>(t[t.Error=0]="Error",t[t.Overflow=1]="Overflow",t[t.Success=2]="Success",t[t.Underflow=3]="Underflow",t))(jr||{}),fu=(t=>(t[t.Previous=-1]="Previous",t[t.Next=1]="Next",t))(fu||{});function du(t=document.body){return t==null?[]:Array.from(t.querySelectorAll(Ut)).sort((e,r)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}function pu(t=document.body){return t==null?[]:Array.from(t.querySelectorAll(cu)).sort((e,r)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}var so=(t=>(t[t.Strict=0]="Strict",t[t.Loose=1]="Loose",t))(so||{});function yu(t,e=0){var r;return t===((r=kt(t))==null?void 0:r.body)?!1:Pe(e,{0(){return t.matches(Ut)},1(){let n=t;for(;n!==null;){if(n.matches(Ut))return!0;n=n.parentElement}return!1}})}var vu=(t=>(t[t.Keyboard=0]="Keyboard",t[t.Mouse=1]="Mouse",t))(vu||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",t=>{t.metaKey||t.altKey||t.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",t=>{t.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:t.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));function ge(t){t==null||t.focus({preventScroll:!0})}let mu=["textarea","input"].join(",");function hu(t){var e,r;return(r=(e=t==null?void 0:t.matches)==null?void 0:e.call(t,mu))!=null?r:!1}function gu(t,e=r=>r){return t.slice().sort((r,n)=>{let o=e(r),i=e(n);if(o===null||i===null)return 0;let l=o.compareDocumentPosition(i);return l&Node.DOCUMENT_POSITION_FOLLOWING?-1:l&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function pt(t,e,{sorted:r=!0,relativeTo:n=null,skipElements:o=[]}={}){let i=Array.isArray(t)?t.length>0?t[0].ownerDocument:document:t.ownerDocument,l=Array.isArray(t)?r?gu(t):t:e&64?pu(t):du(t);o.length>0&&l.length>1&&(l=l.filter(E=>!o.some(d=>d!=null&&"current"in d?(d==null?void 0:d.current)===E:d===E))),n=n??i.activeElement;let u=(()=>{if(e&5)return 1;if(e&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),a=(()=>{if(e&1)return 0;if(e&2)return Math.max(0,l.indexOf(n))-1;if(e&4)return Math.max(0,l.indexOf(n))+1;if(e&8)return l.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),p=e&32?{preventScroll:!0}:{},s=0,g=l.length,m;do{if(s>=g||s+g<=0)return 0;let E=a+s;if(e&16)E=(E+g)%g;else{if(E<0)return 3;if(E>=g)return 1}m=l[E],m==null||m.focus(p),s+=u}while(m!==i.activeElement);return e&6&&hu(m)&&m.select(),2}function co(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function bu(){return/Android/gi.test(window.navigator.userAgent)}function wu(){return co()||bu()}function yt(t,e,r,n){let o=Ie(r);f.useEffect(()=>{if(!t)return;function i(l){o.current(l)}return document.addEventListener(e,i,n),()=>document.removeEventListener(e,i,n)},[t,e,n])}function fo(t,e,r,n){let o=Ie(r);f.useEffect(()=>{if(!t)return;function i(l){o.current(l)}return window.addEventListener(e,i,n),()=>window.removeEventListener(e,i,n)},[t,e,n])}const po=30;function Eu(t,e,r){let n=Je(t,"outside-click"),o=Ie(r),i=f.useCallback(function(a,p){if(a.defaultPrevented)return;let s=p(a);if(s===null||!s.getRootNode().contains(s)||!s.isConnected)return;let g=function m(E){return typeof E=="function"?m(E()):Array.isArray(E)||E instanceof Set?E:[E]}(e);for(let m of g)if(m!==null&&(m.contains(s)||a.composed&&a.composedPath().includes(m)))return;return!yu(s,so.Loose)&&s.tabIndex!==-1&&a.preventDefault(),o.current(a,s)},[o,e]),l=f.useRef(null);yt(n,"pointerdown",a=>{var p,s;l.current=((s=(p=a.composedPath)==null?void 0:p.call(a))==null?void 0:s[0])||a.target},!0),yt(n,"mousedown",a=>{var p,s;l.current=((s=(p=a.composedPath)==null?void 0:p.call(a))==null?void 0:s[0])||a.target},!0),yt(n,"click",a=>{wu()||l.current&&(i(a,()=>l.current),l.current=null)},!0);let u=f.useRef({x:0,y:0});yt(n,"touchstart",a=>{u.current.x=a.touches[0].clientX,u.current.y=a.touches[0].clientY},!0),yt(n,"touchend",a=>{let p={x:a.changedTouches[0].clientX,y:a.changedTouches[0].clientY};if(!(Math.abs(p.x-u.current.x)>=po||Math.abs(p.y-u.current.y)>=po))return i(a,()=>a.target instanceof HTMLElement?a.target:null)},!0),fo(n,"blur",a=>i(a,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function vt(...t){return f.useMemo(()=>kt(...t),[...t])}function yo(t,e,r,n){let o=Ie(r);f.useEffect(()=>{t=t??window;function i(l){o.current(l)}return t.addEventListener(e,i,n),()=>t.removeEventListener(e,i,n)},[t,e,n])}function Su(){let t;return{before({doc:e}){var r;let n=e.documentElement,o=(r=e.defaultView)!=null?r:window;t=Math.max(0,o.innerWidth-n.clientWidth)},after({doc:e,d:r}){let n=e.documentElement,o=Math.max(0,n.clientWidth-n.offsetWidth),i=Math.max(0,t-o);r.style(n,"paddingRight",`${i}px`)}}}function xu(){return co()?{before({doc:t,d:e,meta:r}){function n(o){return r.containers.flatMap(i=>i()).some(i=>i.contains(o))}e.microTask(()=>{var o;if(window.getComputedStyle(t.documentElement).scrollBehavior!=="auto"){let u=Oe();u.style(t.documentElement,"scrollBehavior","auto"),e.add(()=>e.microTask(()=>u.dispose()))}let i=(o=window.scrollY)!=null?o:window.pageYOffset,l=null;e.addEventListener(t,"click",u=>{if(u.target instanceof HTMLElement)try{let a=u.target.closest("a");if(!a)return;let{hash:p}=new URL(a.href),s=t.querySelector(p);s&&!n(s)&&(l=s)}catch{}},!0),e.addEventListener(t,"touchstart",u=>{if(u.target instanceof HTMLElement)if(n(u.target)){let a=u.target;for(;a.parentElement&&n(a.parentElement);)a=a.parentElement;e.style(a,"overscrollBehavior","contain")}else e.style(u.target,"touchAction","none")}),e.addEventListener(t,"touchmove",u=>{if(u.target instanceof HTMLElement){if(u.target.tagName==="INPUT")return;if(n(u.target)){let a=u.target;for(;a.parentElement&&a.dataset.headlessuiPortal!==""&&!(a.scrollHeight>a.clientHeight||a.scrollWidth>a.clientWidth);)a=a.parentElement;a.dataset.headlessuiPortal===""&&u.preventDefault()}else u.preventDefault()}},{passive:!1}),e.add(()=>{var u;let a=(u=window.scrollY)!=null?u:window.pageYOffset;i!==a&&window.scrollTo(0,i),l&&l.isConnected&&(l.scrollIntoView({block:"nearest"}),l=null)})})}}:{}}function Ou(){return{before({doc:t,d:e}){e.style(t.documentElement,"overflow","hidden")}}}function Pu(t){let e={};for(let r of t)Object.assign(e,r(e));return e}let De=io(()=>new Map,{PUSH(t,e){var r;let n=(r=this.get(t))!=null?r:{doc:t,count:0,d:Oe(),meta:new Set};return n.count++,n.meta.add(e),this.set(t,n),this},POP(t,e){let r=this.get(t);return r&&(r.count--,r.meta.delete(e)),this},SCROLL_PREVENT({doc:t,d:e,meta:r}){let n={doc:t,d:e,meta:Pu(r)},o=[xu(),Su(),Ou()];o.forEach(({before:i})=>i==null?void 0:i(n)),o.forEach(({after:i})=>i==null?void 0:i(n))},SCROLL_ALLOW({d:t}){t.dispose()},TEARDOWN({doc:t}){this.delete(t)}});De.subscribe(()=>{let t=De.getSnapshot(),e=new Map;for(let[r]of t)e.set(r,r.documentElement.style.overflow);for(let r of t.values()){let n=e.get(r.doc)==="hidden",o=r.count!==0;(o&&!n||!o&&n)&&De.dispatch(r.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",r),r.count===0&&De.dispatch("TEARDOWN",r)}});function Au(t,e,r=()=>({containers:[]})){let n=ao(De),o=e?n.get(e):void 0,i=o?o.count>0:!1;return ee(()=>{if(!(!e||!t))return De.dispatch("PUSH",e,r),()=>De.dispatch("POP",e,r)},[t,e]),i}function Tu(t,e,r=()=>[document.body]){let n=Je(t,"scroll-lock");Au(n,e,o=>{var i;return{containers:[...(i=o.containers)!=null?i:[],r]}})}function $u(t=0){let[e,r]=f.useState(t),n=f.useCallback(a=>r(a),[e]),o=f.useCallback(a=>r(p=>p|a),[e]),i=f.useCallback(a=>(e&a)===a,[e]),l=f.useCallback(a=>r(p=>p&~a),[r]),u=f.useCallback(a=>r(p=>p^a),[r]);return{flags:e,setFlag:n,addFlag:o,hasFlag:i,removeFlag:l,toggleFlag:u}}var vo,mo;typeof process<"u"&&typeof globalThis<"u"&&typeof Element<"u"&&((vo=process==null?void 0:process.env)==null?void 0:vo.NODE_ENV)==="test"&&typeof((mo=Element==null?void 0:Element.prototype)==null?void 0:mo.getAnimations)>"u"&&(Element.prototype.getAnimations=function(){return console.warn(["Headless UI has polyfilled `Element.prototype.getAnimations` for your tests.","Please install a proper polyfill e.g. `jsdom-testing-mocks`, to silence these warnings.","","Example usage:","```js","import { mockAnimationsApi } from 'jsdom-testing-mocks'","mockAnimationsApi()","```"].join(`
|
|
38
|
+
`)),[]});var Cu=(t=>(t[t.None=0]="None",t[t.Closed=1]="Closed",t[t.Enter=2]="Enter",t[t.Leave=4]="Leave",t))(Cu||{});function Fu(t){let e={};for(let r in t)t[r]===!0&&(e[`data-${r}`]="");return e}function Mu(t,e,r,n){let[o,i]=f.useState(r),{hasFlag:l,addFlag:u,removeFlag:a}=$u(t&&o?3:0),p=f.useRef(!1),s=f.useRef(!1),g=Mr();return ee(()=>{var m;if(t){if(r&&i(!0),!e){r&&u(3);return}return(m=n==null?void 0:n.start)==null||m.call(n,r),Iu(e,{inFlight:p,prepare(){s.current?s.current=!1:s.current=p.current,p.current=!0,!s.current&&(r?(u(3),a(4)):(u(4),a(2)))},run(){s.current?r?(a(3),u(4)):(a(4),u(3)):r?a(1):u(1)},done(){var E;s.current&&typeof e.getAnimations=="function"&&e.getAnimations().length>0||(p.current=!1,a(7),r||i(!1),(E=n==null?void 0:n.end)==null||E.call(n,r))}})}},[t,r,e,g]),t?[o,{closed:l(1),enter:l(2),leave:l(4),transition:l(2)||l(4)}]:[r,{closed:void 0,enter:void 0,leave:void 0,transition:void 0}]}function Iu(t,{prepare:e,run:r,done:n,inFlight:o}){let i=Oe();return Du(t,{prepare:e,inFlight:o}),i.nextFrame(()=>{r(),i.requestAnimationFrame(()=>{i.add(_u(t,n))})}),i.dispose}function _u(t,e){var r,n;let o=Oe();if(!t)return o.dispose;let i=!1;o.add(()=>{i=!0});let l=(n=(r=t.getAnimations)==null?void 0:r.call(t).filter(u=>u instanceof CSSTransition))!=null?n:[];return l.length===0?(e(),o.dispose):(Promise.allSettled(l.map(u=>u.finished)).then(()=>{i||e()}),o.dispose)}function Du(t,{inFlight:e,prepare:r}){if(e!=null&&e.current){r();return}let n=t.style.transition;t.style.transition="none",r(),t.offsetHeight,t.style.transition=n}function Lr(t,e){let r=f.useRef([]),n=B(t);f.useEffect(()=>{let o=[...r.current];for(let[i,l]of e.entries())if(r.current[i]!==l){let u=n(e,o);return r.current=e,u}},[n,...e])}let Bt=f.createContext(null);Bt.displayName="OpenClosedContext";var le=(t=>(t[t.Open=1]="Open",t[t.Closed=2]="Closed",t[t.Closing=4]="Closing",t[t.Opening=8]="Opening",t))(le||{});function Rt(){return f.useContext(Bt)}function ku({value:t,children:e}){return f.createElement(Bt.Provider,{value:t},e)}function Nu({children:t}){return f.createElement(Bt.Provider,{value:null},t)}function ju(t){function e(){document.readyState!=="loading"&&(t(),document.removeEventListener("DOMContentLoaded",e))}typeof window<"u"&&typeof document<"u"&&(document.addEventListener("DOMContentLoaded",e),e())}let Te=[];ju(()=>{function t(e){if(!(e.target instanceof HTMLElement)||e.target===document.body||Te[0]===e.target)return;let r=e.target;r=r.closest(Ut),Te.unshift(r??e.target),Te=Te.filter(n=>n!=null&&n.isConnected),Te.splice(10)}window.addEventListener("click",t,{capture:!0}),window.addEventListener("mousedown",t,{capture:!0}),window.addEventListener("focus",t,{capture:!0}),document.body.addEventListener("click",t,{capture:!0}),document.body.addEventListener("mousedown",t,{capture:!0}),document.body.addEventListener("focus",t,{capture:!0})});function ho(t){let e=B(t),r=f.useRef(!1);f.useEffect(()=>(r.current=!1,()=>{r.current=!0,Nt(()=>{r.current&&e()})}),[e])}function Lu(){let t=typeof document>"u";return"useSyncExternalStore"in rt?(e=>e.useSyncExternalStore)(rt)(()=>()=>{},()=>!1,()=>!t):!1}function mt(){let t=Lu(),[e,r]=rt.useState(Me.isHandoffComplete);return e&&Me.isHandoffComplete===!1&&r(!1),rt.useEffect(()=>{e!==!0&&r(!0)},[e]),rt.useEffect(()=>Me.handoff(),[]),t?!1:e}let go=f.createContext(!1);function Wu(){return f.useContext(go)}function bo(t){return f.createElement(go.Provider,{value:t.force},t.children)}function Uu(t){let e=Wu(),r=f.useContext(Eo),n=vt(t),[o,i]=f.useState(()=>{var l;if(!e&&r!==null)return(l=r.current)!=null?l:null;if(Me.isServer)return null;let u=n==null?void 0:n.getElementById("headlessui-portal-root");if(u)return u;if(n===null)return null;let a=n.createElement("div");return a.setAttribute("id","headlessui-portal-root"),n.body.appendChild(a)});return f.useEffect(()=>{o!==null&&(n!=null&&n.body.contains(o)||n==null||n.body.appendChild(o))},[o,n]),f.useEffect(()=>{e||r!==null&&i(r.current)},[r,i,e]),o}let wo=f.Fragment,Bu=re(function(t,e){let r=t,n=f.useRef(null),o=ye(Ql(g=>{n.current=g}),e),i=vt(n),l=Uu(n),[u]=f.useState(()=>{var g;return Me.isServer?null:(g=i==null?void 0:i.createElement("div"))!=null?g:null}),a=f.useContext(Wr),p=mt();ee(()=>{!l||!u||l.contains(u)||(u.setAttribute("data-headlessui-portal",""),l.appendChild(u))},[l,u]),ee(()=>{if(u&&a)return a.register(u)},[a,u]),ho(()=>{var g;!l||!u||(u instanceof Node&&l.contains(u)&&l.removeChild(u),l.childNodes.length<=0&&((g=l.parentElement)==null||g.removeChild(l)))});let s=ie();return p?!l||!u?null:Jo.createPortal(s({ourProps:{ref:o},theirProps:r,slot:{},defaultTag:wo,name:"Portal"}),u):null});function Ru(t,e){let r=ye(e),{enabled:n=!0,...o}=t,i=ie();return n?f.createElement(Bu,{...o,ref:r}):i({ourProps:{ref:r},theirProps:o,slot:{},defaultTag:wo,name:"Portal"})}let Hu=f.Fragment,Eo=f.createContext(null);function Vu(t,e){let{target:r,...n}=t,o={ref:ye(e)},i=ie();return f.createElement(Eo.Provider,{value:r},i({ourProps:o,theirProps:n,defaultTag:Hu,name:"Popover.Group"}))}let Wr=f.createContext(null);function qu(){let t=f.useContext(Wr),e=f.useRef([]),r=B(i=>(e.current.push(i),t&&t.register(i),()=>n(i))),n=B(i=>{let l=e.current.indexOf(i);l!==-1&&e.current.splice(l,1),t&&t.unregister(i)}),o=f.useMemo(()=>({register:r,unregister:n,portals:e}),[r,n,e]);return[e,f.useMemo(()=>function({children:i}){return f.createElement(Wr.Provider,{value:o},i)},[o])]}let Gu=re(Ru),So=re(Vu),zu=Object.assign(Gu,{Group:So});function Yu(t,e=typeof document<"u"?document.defaultView:null,r){let n=Je(t,"escape");yo(e,"keydown",o=>{n&&(o.defaultPrevented||o.key===oo.Escape&&r(o))})}function Ku(){var t;let[e]=f.useState(()=>typeof window<"u"&&typeof window.matchMedia=="function"?window.matchMedia("(pointer: coarse)"):null),[r,n]=f.useState((t=e==null?void 0:e.matches)!=null?t:!1);return ee(()=>{if(!e)return;function o(i){n(i.matches)}return e.addEventListener("change",o),()=>e.removeEventListener("change",o)},[e]),r}function Xu({defaultContainers:t=[],portals:e,mainTreeNode:r}={}){let n=vt(r),o=B(()=>{var i,l;let u=[];for(let a of t)a!==null&&(a instanceof HTMLElement?u.push(a):"current"in a&&a.current instanceof HTMLElement&&u.push(a.current));if(e!=null&&e.current)for(let a of e.current)u.push(a);for(let a of(i=n==null?void 0:n.querySelectorAll("html > *, body > *"))!=null?i:[])a!==document.body&&a!==document.head&&a instanceof HTMLElement&&a.id!=="headlessui-portal-root"&&(r&&(a.contains(r)||a.contains((l=r==null?void 0:r.getRootNode())==null?void 0:l.host))||u.some(p=>a.contains(p))||u.push(a));return u});return{resolveContainers:o,contains:B(i=>o().some(l=>l.contains(i)))}}let xo=f.createContext(null);function Oo({children:t,node:e}){let[r,n]=f.useState(null),o=Po(e??r);return f.createElement(xo.Provider,{value:o},t,o===null&&f.createElement(Dr,{features:Wt.Hidden,ref:i=>{var l,u;if(i){for(let a of(u=(l=kt(i))==null?void 0:l.querySelectorAll("html > *, body > *"))!=null?u:[])if(a!==document.body&&a!==document.head&&a instanceof HTMLElement&&a!=null&&a.contains(i)){n(a);break}}}}))}function Po(t=null){var e;return(e=f.useContext(xo))!=null?e:t}function Ur(){let t=f.useRef(!1);return ee(()=>(t.current=!0,()=>{t.current=!1}),[]),t}var ht=(t=>(t[t.Forwards=0]="Forwards",t[t.Backwards=1]="Backwards",t))(ht||{});function Ju(){let t=f.useRef(0);return fo(!0,"keydown",e=>{e.key==="Tab"&&(t.current=e.shiftKey?1:0)},!0),t}function Ao(t){if(!t)return new Set;if(typeof t=="function")return new Set(t());let e=new Set;for(let r of t.current)r.current instanceof HTMLElement&&e.add(r.current);return e}let Qu="div";var ke=(t=>(t[t.None=0]="None",t[t.InitialFocus=1]="InitialFocus",t[t.TabLock=2]="TabLock",t[t.FocusLock=4]="FocusLock",t[t.RestoreFocus=8]="RestoreFocus",t[t.AutoFocus=16]="AutoFocus",t))(ke||{});function Zu(t,e){let r=f.useRef(null),n=ye(r,e),{initialFocus:o,initialFocusFallback:i,containers:l,features:u=15,...a}=t;mt()||(u=0);let p=vt(r);ns(u,{ownerDocument:p});let s=os(u,{ownerDocument:p,container:r,initialFocus:o,initialFocusFallback:i});is(u,{ownerDocument:p,container:r,containers:l,previousActiveElement:s});let g=Ju(),m=B(b=>{let w=r.current;w&&(x=>x())(()=>{Pe(g.current,{[ht.Forwards]:()=>{pt(w,he.First,{skipElements:[b.relatedTarget,i]})},[ht.Backwards]:()=>{pt(w,he.Last,{skipElements:[b.relatedTarget,i]})}})})}),E=Je(!!(u&2),"focus-trap#tab-lock"),d=Mr(),v=f.useRef(!1),y={ref:n,onKeyDown(b){b.key=="Tab"&&(v.current=!0,d.requestAnimationFrame(()=>{v.current=!1}))},onBlur(b){if(!(u&4))return;let w=Ao(l);r.current instanceof HTMLElement&&w.add(r.current);let x=b.relatedTarget;x instanceof HTMLElement&&x.dataset.headlessuiFocusGuard!=="true"&&(To(w,x)||(v.current?pt(r.current,Pe(g.current,{[ht.Forwards]:()=>he.Next,[ht.Backwards]:()=>he.Previous})|he.WrapAround,{relativeTo:b.target}):b.target instanceof HTMLElement&&ge(b.target)))}},h=ie();return f.createElement(f.Fragment,null,E&&f.createElement(Dr,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:m,features:Wt.Focusable}),h({ourProps:y,theirProps:a,defaultTag:Qu,name:"FocusTrap"}),E&&f.createElement(Dr,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:m,features:Wt.Focusable}))}let es=re(Zu),ts=Object.assign(es,{features:ke});function rs(t=!0){let e=f.useRef(Te.slice());return Lr(([r],[n])=>{n===!0&&r===!1&&Nt(()=>{e.current.splice(0)}),n===!1&&r===!0&&(e.current=Te.slice())},[t,Te,e]),B(()=>{var r;return(r=e.current.find(n=>n!=null&&n.isConnected))!=null?r:null})}function ns(t,{ownerDocument:e}){let r=!!(t&8),n=rs(r);Lr(()=>{r||(e==null?void 0:e.activeElement)===(e==null?void 0:e.body)&&ge(n())},[r]),ho(()=>{r&&ge(n())})}function os(t,{ownerDocument:e,container:r,initialFocus:n,initialFocusFallback:o}){let i=f.useRef(null),l=Je(!!(t&1),"focus-trap#initial-focus"),u=Ur();return Lr(()=>{if(t===0)return;if(!l){o!=null&&o.current&&ge(o.current);return}let a=r.current;a&&Nt(()=>{if(!u.current)return;let p=e==null?void 0:e.activeElement;if(n!=null&&n.current){if((n==null?void 0:n.current)===p){i.current=p;return}}else if(a.contains(p)){i.current=p;return}if(n!=null&&n.current)ge(n.current);else{if(t&16){if(pt(a,he.First|he.AutoFocus)!==jr.Error)return}else if(pt(a,he.First)!==jr.Error)return;if(o!=null&&o.current&&(ge(o.current),(e==null?void 0:e.activeElement)===o.current))return;console.warn("There are no focusable elements inside the <FocusTrap />")}i.current=e==null?void 0:e.activeElement})},[o,l,t]),i}function is(t,{ownerDocument:e,container:r,containers:n,previousActiveElement:o}){let i=Ur(),l=!!(t&4);yo(e==null?void 0:e.defaultView,"focus",u=>{if(!l||!i.current)return;let a=Ao(n);r.current instanceof HTMLElement&&a.add(r.current);let p=o.current;if(!p)return;let s=u.target;s&&s instanceof HTMLElement?To(a,s)?(o.current=s,ge(s)):(u.preventDefault(),u.stopPropagation(),ge(p)):ge(o.current)},!0)}function To(t,e){for(let r of t)if(r.contains(e))return!0;return!1}function $o(t){var e;return!!(t.enter||t.enterFrom||t.enterTo||t.leave||t.leaveFrom||t.leaveTo)||((e=t.as)!=null?e:Fo)!==f.Fragment||f.Children.count(t.children)===1}let Ht=f.createContext(null);Ht.displayName="TransitionContext";var as=(t=>(t.Visible="visible",t.Hidden="hidden",t))(as||{});function ls(){let t=f.useContext(Ht);if(t===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}function us(){let t=f.useContext(Vt);if(t===null)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}let Vt=f.createContext(null);Vt.displayName="NestingContext";function qt(t){return"children"in t?qt(t.children):t.current.filter(({el:e})=>e.current!==null).filter(({state:e})=>e==="visible").length>0}function Co(t,e){let r=Ie(t),n=f.useRef([]),o=Ur(),i=Mr(),l=B((E,d=Ae.Hidden)=>{let v=n.current.findIndex(({el:y})=>y===E);v!==-1&&(Pe(d,{[Ae.Unmount](){n.current.splice(v,1)},[Ae.Hidden](){n.current[v].state="hidden"}}),i.microTask(()=>{var y;!qt(n)&&o.current&&((y=r.current)==null||y.call(r))}))}),u=B(E=>{let d=n.current.find(({el:v})=>v===E);return d?d.state!=="visible"&&(d.state="visible"):n.current.push({el:E,state:"visible"}),()=>l(E,Ae.Unmount)}),a=f.useRef([]),p=f.useRef(Promise.resolve()),s=f.useRef({enter:[],leave:[]}),g=B((E,d,v)=>{a.current.splice(0),e&&(e.chains.current[d]=e.chains.current[d].filter(([y])=>y!==E)),e==null||e.chains.current[d].push([E,new Promise(y=>{a.current.push(y)})]),e==null||e.chains.current[d].push([E,new Promise(y=>{Promise.all(s.current[d].map(([h,b])=>b)).then(()=>y())})]),d==="enter"?p.current=p.current.then(()=>e==null?void 0:e.wait.current).then(()=>v(d)):v(d)}),m=B((E,d,v)=>{Promise.all(s.current[d].splice(0).map(([y,h])=>h)).then(()=>{var y;(y=a.current.shift())==null||y()}).then(()=>v(d))});return f.useMemo(()=>({children:n,register:u,unregister:l,onStart:g,onStop:m,wait:p,chains:s}),[u,l,n,g,m,s,p])}let Fo=f.Fragment,Mo=jt.RenderStrategy;function ss(t,e){var r,n;let{transition:o=!0,beforeEnter:i,afterEnter:l,beforeLeave:u,afterLeave:a,enter:p,enterFrom:s,enterTo:g,entered:m,leave:E,leaveFrom:d,leaveTo:v,...y}=t,[h,b]=f.useState(null),w=f.useRef(null),x=$o(t),P=ye(...x?[w,e,b]:e===null?[]:[e]),D=(r=y.unmount)==null||r?Ae.Unmount:Ae.Hidden,{show:_,appear:U,initial:H}=ls(),[j,z]=f.useState(_?"visible":"hidden"),V=us(),{register:C,unregister:T}=V;ee(()=>C(w),[C,w]),ee(()=>{if(D===Ae.Hidden&&w.current){if(_&&j!=="visible"){z("visible");return}return Pe(j,{hidden:()=>T(w),visible:()=>C(w)})}},[j,w,C,T,_,D]);let k=mt();ee(()=>{if(x&&k&&j==="visible"&&w.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[w,j,k,x]);let oe=H&&!U,ue=U&&_&&H,ve=f.useRef(!1),Z=Co(()=>{ve.current||(z("hidden"),T(w))},V),se=B(Le=>{ve.current=!0;let be=Le?"enter":"leave";Z.onStart(w,be,we=>{we==="enter"?i==null||i():we==="leave"&&(u==null||u())})}),q=B(Le=>{let be=Le?"enter":"leave";ve.current=!1,Z.onStop(w,be,we=>{we==="enter"?l==null||l():we==="leave"&&(a==null||a())}),be==="leave"&&!qt(Z)&&(z("hidden"),T(w))});f.useEffect(()=>{x&&o||(se(_),q(_))},[_,x,o]);let Ne=!(!o||!x||!k||oe),[,J]=Mu(Ne,h,_,{start:se,end:q}),Vr=_e({ref:P,className:((n=Ir(y.className,ue&&p,ue&&s,J.enter&&p,J.enter&&J.closed&&s,J.enter&&!J.closed&&g,J.leave&&E,J.leave&&!J.closed&&d,J.leave&&J.closed&&v,!J.transition&&_&&m))==null?void 0:n.trim())||void 0,...Fu(J)}),je=0;j==="visible"&&(je|=le.Open),j==="hidden"&&(je|=le.Closed),J.enter&&(je|=le.Opening),J.leave&&(je|=le.Closing);let gt=ie();return f.createElement(Vt.Provider,{value:Z},f.createElement(ku,{value:je},gt({ourProps:Vr,theirProps:y,defaultTag:Fo,features:Mo,visible:j==="visible",name:"Transition.Child"})))}function cs(t,e){let{show:r,appear:n=!1,unmount:o=!0,...i}=t,l=f.useRef(null),u=$o(t),a=ye(...u?[l,e]:e===null?[]:[e]);mt();let p=Rt();if(r===void 0&&p!==null&&(r=(p&le.Open)===le.Open),r===void 0)throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[s,g]=f.useState(r?"visible":"hidden"),m=Co(()=>{r||g("hidden")}),[E,d]=f.useState(!0),v=f.useRef([r]);ee(()=>{E!==!1&&v.current[v.current.length-1]!==r&&(v.current.push(r),d(!1))},[v,r]);let y=f.useMemo(()=>({show:r,appear:n,initial:E}),[r,n,E]);ee(()=>{r?g("visible"):!qt(m)&&l.current!==null&&g("hidden")},[r,m]);let h={unmount:o},b=B(()=>{var P;E&&d(!1),(P=t.beforeEnter)==null||P.call(t)}),w=B(()=>{var P;E&&d(!1),(P=t.beforeLeave)==null||P.call(t)}),x=ie();return f.createElement(Vt.Provider,{value:m},f.createElement(Ht.Provider,{value:y},x({ourProps:{...h,as:f.Fragment,children:f.createElement(Io,{ref:a,...h,...i,beforeEnter:b,beforeLeave:w})},theirProps:{},defaultTag:f.Fragment,features:Mo,visible:s==="visible",name:"Transition"})))}function fs(t,e){let r=f.useContext(Ht)!==null,n=Rt()!==null;return f.createElement(f.Fragment,null,!r&&n?f.createElement(Br,{ref:e,...t}):f.createElement(Io,{ref:e,...t}))}let Br=re(cs),Io=re(ss),Qe=re(fs),_o=Object.assign(Br,{Child:Qe,Root:Br});var ds=(t=>(t[t.Open=0]="Open",t[t.Closed=1]="Closed",t))(ds||{}),ps=(t=>(t[t.SetTitleId=0]="SetTitleId",t))(ps||{});let ys={0(t,e){return t.titleId===e.id?t:{...t,titleId:e.id}}},Rr=f.createContext(null);Rr.displayName="DialogContext";function Gt(t){let e=f.useContext(Rr);if(e===null){let r=new Error(`<${t} /> is missing a parent <Dialog /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,Gt),r}return e}function vs(t,e){return Pe(e.type,ys,t,e)}let Do=re(function(t,e){let r=f.useId(),{id:n=`headlessui-dialog-${r}`,open:o,onClose:i,initialFocus:l,role:u="dialog",autoFocus:a=!0,__demoMode:p=!1,unmount:s=!1,...g}=t,m=f.useRef(!1);u=function(){return u==="dialog"||u==="alertdialog"?u:(m.current||(m.current=!0,console.warn(`Invalid role [${u}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)),"dialog")}();let E=Rt();o===void 0&&E!==null&&(o=(E&le.Open)===le.Open);let d=f.useRef(null),v=ye(d,e),y=vt(d),h=o?0:1,[b,w]=f.useReducer(vs,{titleId:null,descriptionId:null,panelRef:f.createRef()}),x=B(()=>i(!1)),P=B(q=>w({type:0,id:q})),D=mt()?h===0:!1,[_,U]=qu(),H={get current(){var q;return(q=b.panelRef.current)!=null?q:d.current}},j=Po(),{resolveContainers:z}=Xu({mainTreeNode:j,portals:_,defaultContainers:[H]}),V=E!==null?(E&le.Closing)===le.Closing:!1;uu(p||V?!1:D,{allowed:B(()=>{var q,Ne;return[(Ne=(q=d.current)==null?void 0:q.closest("[data-headlessui-portal]"))!=null?Ne:null]}),disallowed:B(()=>{var q;return[(q=j==null?void 0:j.closest("body > *:not(#headlessui-portal-root)"))!=null?q:null]})}),Eu(D,z,q=>{q.preventDefault(),x()}),Yu(D,y==null?void 0:y.defaultView,q=>{q.preventDefault(),q.stopPropagation(),document.activeElement&&"blur"in document.activeElement&&typeof document.activeElement.blur=="function"&&document.activeElement.blur(),x()}),Tu(p||V?!1:D,y,z),su(D,d,x);let[C,T]=Zl(),k=f.useMemo(()=>[{dialogState:h,close:x,setTitleId:P,unmount:s},b],[h,b,x,P,s]),oe=f.useMemo(()=>({open:h===0}),[h]),ue={ref:v,id:n,role:u,tabIndex:-1,"aria-modal":p?void 0:h===0?!0:void 0,"aria-labelledby":b.titleId,"aria-describedby":C,unmount:s},ve=!Ku(),Z=ke.None;D&&!p&&(Z|=ke.RestoreFocus,Z|=ke.TabLock,a&&(Z|=ke.AutoFocus),ve&&(Z|=ke.InitialFocus));let se=ie();return f.createElement(Nu,null,f.createElement(bo,{force:!0},f.createElement(zu,null,f.createElement(Rr.Provider,{value:k},f.createElement(So,{target:d},f.createElement(bo,{force:!1},f.createElement(T,{slot:oe},f.createElement(U,null,f.createElement(ts,{initialFocus:l,initialFocusFallback:d,containers:z,features:Z},f.createElement(iu,{value:x},se({ourProps:ue,theirProps:g,slot:oe,defaultTag:ms,features:hs,visible:h===0,name:"Dialog"})))))))))))}),ms="div",hs=jt.RenderStrategy|jt.Static;function gs(t,e){let{transition:r=!1,open:n,...o}=t,i=Rt(),l=t.hasOwnProperty("open")||i!==null,u=t.hasOwnProperty("onClose");if(!l&&!u)throw new Error("You have to provide an `open` and an `onClose` prop to the `Dialog` component.");if(!l)throw new Error("You provided an `onClose` prop to the `Dialog`, but forgot an `open` prop.");if(!u)throw new Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");if(!i&&typeof t.open!="boolean")throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${t.open}`);if(typeof t.onClose!="function")throw new Error(`You provided an \`onClose\` prop to the \`Dialog\`, but the value is not a function. Received: ${t.onClose}`);return(n!==void 0||r)&&!o.static?f.createElement(Oo,null,f.createElement(_o,{show:n,transition:r,unmount:o.unmount},f.createElement(Do,{ref:e,...o}))):f.createElement(Oo,null,f.createElement(Do,{ref:e,open:n,...o}))}let bs="div";function ws(t,e){let r=f.useId(),{id:n=`headlessui-dialog-panel-${r}`,transition:o=!1,...i}=t,[{dialogState:l,unmount:u},a]=Gt("Dialog.Panel"),p=ye(e,a.panelRef),s=f.useMemo(()=>({open:l===0}),[l]),g=B(y=>{y.stopPropagation()}),m={ref:p,id:n,onClick:g},E=o?Qe:f.Fragment,d=o?{unmount:u}:{},v=ie();return f.createElement(E,{...d},v({ourProps:m,theirProps:i,slot:s,defaultTag:bs,name:"Dialog.Panel"}))}let Es="div";function Ss(t,e){let{transition:r=!1,...n}=t,[{dialogState:o,unmount:i}]=Gt("Dialog.Backdrop"),l=f.useMemo(()=>({open:o===0}),[o]),u={ref:e,"aria-hidden":!0},a=r?Qe:f.Fragment,p=r?{unmount:i}:{},s=ie();return f.createElement(a,{...p},s({ourProps:u,theirProps:n,slot:l,defaultTag:Es,name:"Dialog.Backdrop"}))}let xs="h2";function Os(t,e){let r=f.useId(),{id:n=`headlessui-dialog-title-${r}`,...o}=t,[{dialogState:i,setTitleId:l}]=Gt("Dialog.Title"),u=ye(e);f.useEffect(()=>(l(n),()=>l(null)),[n,l]);let a=f.useMemo(()=>({open:i===0}),[i]),p={ref:u,id:n};return ie()({ourProps:p,theirProps:o,slot:a,defaultTag:xs,name:"Dialog.Title"})}let Ps=re(gs),Hr=re(ws);re(Ss);let As=re(Os),Ts=Object.assign(Ps,{Panel:Hr,Title:As,Description:nu});function ko({onClick:t}){return $.jsxs("button",{type:"button",className:"im-close-button text-gray-400 hover:text-gray-500",onClick:t,children:[$.jsx("span",{className:"sr-only",children:"Close"}),$.jsx("svg",{className:"size-6",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"2",stroke:"currentColor","aria-hidden":"true",children:$.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})]})}const $s=({modalContext:t,modalProps:e,children:r})=>$.jsx("div",{className:"im-modal-container fixed inset-0 z-40 overflow-y-auto p-4",children:$.jsx("div",{className:Dt("im-modal-positioner flex min-h-full justify-center",{"items-start":e.position==="top","items-center":e.position==="center","items-end":e.position==="bottom"}),children:$.jsx(Qe,{enterFrom:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",enterTo:"opacity-100 translate-y-0 sm:scale-100",leaveFrom:"opacity-100 translate-y-0 sm:scale-100",leaveTo:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",afterLeave:t.afterLeave,className:Dt("im-modal-wrapper w-full transition duration-300 ease-in-out",t.onTopOfStack?"":"blur-sm",{"sm:max-w-sm":e.maxWidth==="sm","sm:max-w-md":e.maxWidth==="md","sm:max-w-md md:max-w-lg":e.maxWidth==="lg","sm:max-w-md md:max-w-xl":e.maxWidth==="xl","sm:max-w-md md:max-w-xl lg:max-w-2xl":e.maxWidth==="2xl","sm:max-w-md md:max-w-xl lg:max-w-3xl":e.maxWidth==="3xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-4xl":e.maxWidth==="4xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl":e.maxWidth==="5xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-6xl":e.maxWidth==="6xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-7xl":e.maxWidth==="7xl"}),children:$.jsxs(Hr,{className:`im-modal-content relative ${e.paddingClasses} ${e.panelClasses}`,children:[e.closeButton&&$.jsx("div",{className:"absolute right-0 top-0 pr-3 pt-3",children:$.jsx(ko,{onClick:t.close})}),typeof r=="function"?r({modalContext:t,modalProps:e}):r]})})})}),Cs=({modalContext:t,modalProps:e,children:r})=>$.jsx("div",{className:"im-slideover-container fixed inset-0 z-40 overflow-y-auto overflow-x-hidden",children:$.jsx("div",{className:Dt("im-slideover-positioner flex min-h-full items-center",{"justify-start":e.position==="left","justify-end":e.position==="right"}),children:$.jsx(Qe,{enterFrom:`opacity-0 ${e.position==="left"?"-translate-x-full":"translate-x-full"}`,enterTo:"opacity-100 translate-x-0",leaveFrom:"opacity-100 translate-x-0",leaveTo:`opacity-0 ${e.position==="left"?"-translate-x-full":"translate-x-full"}`,afterLeave:t.afterLeave,className:Dt("im-slideover-wrapper w-full transition duration-300 ease-in-out",t.onTopOfStack?"":"blur-sm",{"sm:max-w-sm":e.maxWidth==="sm","sm:max-w-md":e.maxWidth==="md","sm:max-w-md md:max-w-lg":e.maxWidth==="lg","sm:max-w-md md:max-w-xl":e.maxWidth==="xl","sm:max-w-md md:max-w-xl lg:max-w-2xl":e.maxWidth==="2xl","sm:max-w-md md:max-w-xl lg:max-w-3xl":e.maxWidth==="3xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-4xl":e.maxWidth==="4xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl":e.maxWidth==="5xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-6xl":e.maxWidth==="6xl","sm:max-w-md md:max-w-xl lg:max-w-3xl xl:max-w-5xl 2xl:max-w-7xl":e.maxWidth==="7xl"}),children:$.jsxs(Hr,{className:`im-slideover-content relative ${e.paddingClasses} ${e.panelClasses}`,children:[e.closeButton&&$.jsx("div",{className:"absolute right-0 top-0 pr-3 pt-3",children:$.jsx(ko,{onClick:t.close})}),typeof r=="function"?r({modalContext:t,modalProps:e}):r]})})})}),No=f.forwardRef(({name:t,children:e,...r},n)=>{const o=l=>typeof e=="function"?e(l):e,i=f.useRef(null);return f.useImperativeHandle(n,()=>i.current,[i]),$.jsx(Cr,{ref:i,name:t,...r,children:({afterLeave:l,close:u,emit:a,getChildModal:p,getParentModal:s,id:g,index:m,isOpen:E,modalContext:d,modalProps:v,onTopOfStack:y,reload:h,setOpen:b,shouldRender:w})=>$.jsx(_o,{appear:!0,show:E??!1,children:$.jsxs(Ts,{as:"div",className:"im-dialog relative z-20",onClose:()=>v.closeExplicitly?null:u(),"data-inertiaui-modal-id":g,"data-inertiaui-modal-index":m,children:[m===0?$.jsx(Qe,{enter:"transition transform ease-in-out duration-300",enterFrom:"opacity-0",enterTo:"opacity-100",leave:"transition transform ease-in-out duration-300",leaveFrom:"opacity-100",leaveTo:"opacity-0",children:y?$.jsx("div",{className:"im-backdrop fixed inset-0 z-30 bg-black/75","aria-hidden":"true"}):$.jsx("div",{})}):null,m>0&&y?$.jsx("div",{className:"im-backdrop fixed inset-0 z-30 bg-black/75"}):null,v.slideover?$.jsx(Cs,{modalContext:d,modalProps:v,children:o({afterLeave:l,close:u,emit:a,getChildModal:p,getParentModal:s,id:g,index:m,isOpen:E,modalContext:d,modalProps:v,onTopOfStack:y,reload:h,setOpen:b,shouldRender:w})}):$.jsx($s,{modalContext:d,modalProps:v,children:o({afterLeave:l,close:u,emit:a,getChildModal:p,getParentModal:s,id:g,index:m,isOpen:E,modalContext:d,modalProps:v,onTopOfStack:y,reload:h,setOpen:b,shouldRender:w})})]})})})});No.displayName="Modal";const Fs=({href:t,method:e="get",data:r={},as:n="a",headers:o={},queryStringArrayFormat:i="brackets",onAfterLeave:l=null,onBlur:u=null,onClose:a=null,onError:p=null,onFocus:s=null,onStart:g=null,onSuccess:m=null,navigate:E=null,children:d,...v})=>{const[y,h]=f.useState(!1),[b,w]=f.useState(null),{stack:x,visit:P}=_t(),D=f.useMemo(()=>E??Xt("navigate"),[E]),_={},U={};Object.keys(v).forEach(T=>{Xn.includes(T)||(T.startsWith("on")&&typeof v[T]=="function"?T.toLowerCase()in window?_[T]=v[T]:U[T]=v[T]:_[T]=v[T])});const[H,j]=f.useState(!1);f.useEffect(()=>{b&&(b.onTopOfStack&&H?s==null||s():!b.onTopOfStack&&!H&&(u==null||u()),j(!b.onTopOfStack))},[x]);const z=f.useCallback(()=>{a==null||a()},[a]),V=f.useCallback(()=>{w(null),l==null||l()},[l]),C=f.useCallback(T=>{T==null||T.preventDefault(),!y&&(t.startsWith("#")||(h(!0),g==null||g()),P(t,e,r,o,li(Zr(v,Xn)),()=>z(x.length),V,i,D).then(k=>{w(k),k.registerEventListenersFromProps(U),m==null||m()}).catch(k=>{console.error(k),p==null||p(k)}).finally(()=>h(!1)))},[t,e,r,o,i,v,z,V]);return $.jsx(n,{..._,href:t,onClick:C,children:typeof d=="function"?d({loading:y}):d})};W.HeadlessModal=Cr,W.Modal=No,W.ModalLink=Fs,W.ModalRoot=Jn,W.ModalStackProvider=Kn,W.getConfig=Xt,W.putConfig=ti,W.renderApp=Bl,W.resetConfig=ei,W.useModalIndex=Qn,W.useModalStack=_t,Object.defineProperty(W,Symbol.toStringTag,{value:"Module"})});
|