@toa.io/extensions.introspection 1.0.0-alpha.306 → 1.0.0-alpha.308
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/package.json +5 -5
- package/transpiled/Composition.js +12 -2
- package/transpiled/Composition.js.map +1 -1
- package/ui/dist/_app/immutable/chunks/{CB6qHsyu.js → BizxCnFA.js} +1 -1
- package/ui/dist/_app/immutable/chunks/{K6eu_fpK.js → BvrbTWE5.js} +1 -1
- package/ui/dist/_app/immutable/chunks/{BmMhn2QK.js → C4dbyEfF.js} +1 -1
- package/ui/dist/_app/immutable/chunks/CVI-G-nc.js +1 -0
- package/ui/dist/_app/immutable/chunks/{C7j91YQ-.js → CfwVa1wg.js} +2 -2
- package/ui/dist/_app/immutable/chunks/{CBoY9kBO.js → CyuNt1Yc.js} +1 -1
- package/ui/dist/_app/immutable/chunks/{Cyx235dG.js → DXPoxRl1.js} +1 -1
- package/ui/dist/_app/immutable/chunks/EttRBGeu.js +1 -0
- package/ui/dist/_app/immutable/chunks/{BYGx-tUu.js → mN1X6kWf.js} +1 -1
- package/ui/dist/_app/immutable/entry/{app._nBtHSlX.js → app.DkI63irP.js} +2 -2
- package/ui/dist/_app/immutable/entry/start.B8fkM05S.js +1 -0
- package/ui/dist/_app/immutable/nodes/{0.jrtR8xep.js → 0.BOiirZZ5.js} +1 -1
- package/ui/dist/_app/immutable/nodes/{1.DcxTn8Wv.js → 1.DO-EUw5i.js} +1 -1
- package/ui/dist/_app/immutable/nodes/{2.C0fg7g4t.js → 2.CCD_51dX.js} +1 -1
- package/ui/dist/_app/immutable/nodes/3.Yjra7El3.js +1 -0
- package/ui/dist/_app/immutable/nodes/4.CCtpGkWO.js +1 -0
- package/ui/dist/_app/immutable/nodes/{5.G5Augfai.js → 5.Cu46fsYa.js} +1 -1
- package/ui/dist/_app/version.json +1 -1
- package/ui/dist/index.html +12 -12
- package/ui/dist/_app/immutable/chunks/CMJYA4Le.js +0 -1
- package/ui/dist/_app/immutable/chunks/X3sfW33Q.js +0 -1
- package/ui/dist/_app/immutable/entry/start.BIK196Vd.js +0 -1
- package/ui/dist/_app/immutable/nodes/3.PPZqOKXF.js +0 -1
- package/ui/dist/_app/immutable/nodes/4.DtCrZa9O.js +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toa.io/extensions.introspection",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.308",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Toa Introspection",
|
|
6
6
|
"author": "temich <tema.gurtovoy@gmail.com>",
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"!**/.env*"
|
|
28
28
|
],
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@toa.io/core": "1.0.0-alpha.
|
|
31
|
-
"@toa.io/definitions": "1.0.0-alpha.
|
|
30
|
+
"@toa.io/core": "1.0.0-alpha.308",
|
|
31
|
+
"@toa.io/definitions": "1.0.0-alpha.308",
|
|
32
32
|
"@toa.io/generic": "1.0.0-alpha.304",
|
|
33
|
-
"@toa.io/norm": "1.0.0-alpha.
|
|
33
|
+
"@toa.io/norm": "1.0.0-alpha.308",
|
|
34
34
|
"@toa.io/schemas": "1.0.0-alpha.304",
|
|
35
35
|
"openspan": "1.0.0-alpha.305"
|
|
36
36
|
},
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"prepack": "npm run build:ui",
|
|
41
41
|
"features": "TSX_TSCONFIG_PATH=features/steps/tsconfig.json NODE_OPTIONS=--import=tsx cucumber-js --tags 'not @skip and not @shutdown' && TOA_INTROSPECTION_INTERVAL=3600 TSX_TSCONFIG_PATH=features/steps/tsconfig.json NODE_OPTIONS=--import=tsx cucumber-js --tags 'not @skip and @shutdown'"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "66eb0d54032f60e6ead9e13fd9e21fb60c611277"
|
|
44
44
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { readdirSync } from 'node:fs';
|
|
2
2
|
import { resolve } from 'node:path';
|
|
3
3
|
import { Connector } from '@toa.io/core';
|
|
4
|
+
import { environment, NAMESPACE, SIGNALS } from '@toa.io/definitions/extensions.introspection';
|
|
4
5
|
/** Hosts the introspection components in the explorer process. */
|
|
5
6
|
export class Composition extends Connector {
|
|
6
7
|
host;
|
|
@@ -18,9 +19,17 @@ export class Composition extends Connector {
|
|
|
18
19
|
export function find() {
|
|
19
20
|
return entries().map((entry) => resolve(ROOT, entry.name));
|
|
20
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* The components this process hosts, which is what the deployment provisioned for it: a
|
|
24
|
+
* deployment that has not asked for halts is rendered nothing for the signals component — no
|
|
25
|
+
* storage address among the rest — so a process that hosted it would fail to boot on a pointer
|
|
26
|
+
* nobody wrote.
|
|
27
|
+
*/
|
|
21
28
|
function entries() {
|
|
22
|
-
const entries = readdirSync(ROOT, { withFileTypes: true });
|
|
23
|
-
|
|
29
|
+
const entries = readdirSync(ROOT, { withFileTypes: true }).filter((entry) => entry.isDirectory());
|
|
30
|
+
if (environment()?.halt === true)
|
|
31
|
+
return entries;
|
|
32
|
+
return entries.filter((entry) => entry.name !== SIGNALS_COMPONENT);
|
|
24
33
|
}
|
|
25
34
|
/** The components this extension ships, where they are, for the process that runs them. */
|
|
26
35
|
export function components() {
|
|
@@ -28,4 +37,5 @@ export function components() {
|
|
|
28
37
|
return { labels: entries().map((entry) => entry.name.replace('.', '-')), paths };
|
|
29
38
|
}
|
|
30
39
|
const ROOT = resolve(import.meta.dirname, '../components/');
|
|
40
|
+
const SIGNALS_COMPONENT = `${NAMESPACE}.${SIGNALS}`;
|
|
31
41
|
//# sourceMappingURL=Composition.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Composition.js","sourceRoot":"","sources":["../source/Composition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAe,MAAM,SAAS,CAAA;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;
|
|
1
|
+
{"version":3,"file":"Composition.js","sourceRoot":"","sources":["../source/Composition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAe,MAAM,SAAS,CAAA;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AACxC,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,8CAA8C,CAAA;AAG9F,kEAAkE;AAClE,MAAM,OAAO,WAAY,SAAQ,SAAS;IACvB,IAAI,CAAM;IAE3B,YAAmB,IAAU;QAC3B,KAAK,EAAE,CAAA;QACP,IAAI,CAAC,IAAI,GAAG,IAAI,CAAA;IAClB,CAAC;IAEkB,KAAK,CAAC,IAAI;QAC3B,MAAM,KAAK,GAAG,IAAI,EAAE,CAAA;QACpB,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAA;QAEtD,MAAM,WAAW,CAAC,OAAO,EAAE,CAAA;QAE3B,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,CAAA;IAC3B,CAAC;CACF;AAED,MAAM,UAAU,IAAI;IAClB,OAAO,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC,CAAA;AAC5D,CAAC;AAED;;;;;GAKG;AACH,SAAS,OAAO;IACd,MAAM,OAAO,GAAG,WAAW,CAAC,IAAI,EAAE,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAC1E,KAAK,CAAC,WAAW,EAAE,CACpB,CAAA;IAED,IAAI,WAAW,EAAE,EAAE,IAAI,KAAK,IAAI;QAAE,OAAO,OAAO,CAAA;IAEhD,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,KAAK,iBAAiB,CAAC,CAAA;AACpE,CAAC;AAED,2FAA2F;AAC3F,MAAM,UAAU,UAAU;IACxB,MAAM,KAAK,GAAG,IAAI,EAAE,CAAA;IAEpB,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,CAAA;AAClF,CAAC;AAOD,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,IAAI,CAAC,OAAO,EAAE,gBAAgB,CAAC,CAAA;AAE3D,MAAM,iBAAiB,GAAG,GAAG,SAAS,IAAI,OAAO,EAAE,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./sTot5bBi.js";import{a as e}from"./
|
|
1
|
+
import"./sTot5bBi.js";import{a as e}from"./C4dbyEfF.js";var t={get data(){return e.data},get error(){return e.error},get form(){return e.form},get params(){return e.params},get route(){return e.route},get state(){return e.state},get status(){return e.status},get url(){return e.url}};export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as e,At as t,C as n,Ct as r,D as i,E as a,F as o,J as s,M as c,O as l,Ot as u,P as d,St as f,T as p,V as m,X as h,Y as g,_,_t as v,a as y,at as b,b as x,ct as S,d as C,dt as w,et as T,ft as E,h as D,i as O,j as k,k as A,kt as j,l as M,m as ee,mt as N,nt as P,o as F,p as te,rt as ne,s as I,st as L,tt as R,u as z,x as B,yt as V,z as H}from"./sTot5bBi.js";import"./CMJYA4Le.js";import"./xihTtKlq.js";import{F as U,N as W,r as re,t as ie}from"./C7j91YQ-.js";import{$ as ae,A as G,C as oe,E as se,G as ce,H as le,J as ue,K as de,O as K,Q as q,T as fe,V as pe,W as me,Y as he,Z as J,_t as ge,b as _e,c as ve,dt as ye,et as be,f as xe,g as Se,ht as Ce,j as we,k as Y,m as Te,mt as Ee,nt as De,p as Oe,pt as ke,q as X,rt as Ae,st as Z,t as je,tt as Q,u as Me,w as Ne}from"./BYGx-tUu.js";function Pe(e){return e!==null&&!(e instanceof Error)}var Fe=new Set([`$$slots`,`$$events`,`$$legacy`]);function Ie(e,t){let n=y(t,Fe),r=[[`rect`,{x:`14`,y:`3`,width:`5`,height:`18`,rx:`1`}],[`rect`,{x:`5`,y:`3`,width:`5`,height:`18`,rx:`1`}]];U(e,F({name:`pause`},()=>n,{get iconNode(){return r}}))}function Le(e,t){return setTimeout(t,e)}var Re=1,ze=9,Be=11;function Ve(e){return ke(e)&&e.nodeType===Re&&typeof e.nodeName==`string`}function He(e){return ke(e)&&e.nodeType===ze}function Ue(e){return ke(e)&&e.constructor?.name===`VisualViewport`}function We(e){return ke(e)&&e.nodeType!==void 0}function Ge(e){return We(e)&&e.nodeType===Be&&`host`in e}function Ke(e,t){if(!e||!t||!Ve(e)||!Ve(t))return!1;let n=t.getRootNode?.();if(e===t||e.contains(t))return!0;if(n&&Ge(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function qe(e){return He(e)?e:Ue(e)?e.document:e?.ownerDocument??document}function Je(e){return Ge(e)?Je(e.host):He(e)?e.defaultView??window:Ve(e)?e.ownerDocument?.defaultView??window:window}function Ye(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}var Xe=class{element;#e=S(()=>this.element.current?this.element.current.getRootNode()??document:document);get root(){return m(this.#e)}set root(e){b(this.#e,e)}constructor(e){this.element=typeof e==`function`?Z(e):e}getDocument=()=>qe(this.root);getWindow=()=>this.getDocument().defaultView??window;getActiveElement=()=>Ye(this.root);isActiveElement=e=>e===this.getActiveElement();getElementById(e){return this.root.getElementById(e)}querySelector=e=>this.root?this.root.querySelector(e):null;querySelectorAll=e=>this.root?this.root.querySelectorAll(e):[];setTimeout=(e,t)=>this.getWindow().setTimeout(e,t);clearTimeout=e=>this.getWindow().clearTimeout(e)},Ze=typeof document<`u`,Qe=$e();function $e(){return Ze&&window?.navigator?.userAgent&&(/iP(ad|hone|od)/.test(window.navigator.userAgent)||window?.navigator?.maxTouchPoints>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function et(e){return e instanceof HTMLElement}function tt(e){return e instanceof Element||e instanceof SVGElement}var nt=me({component:`dialog`,parts:[`content`,`trigger`,`overlay`,`title`,`description`,`close`,`cancel`,`action`]}),$=new q(`Dialog.Root | AlertDialog.Root`),rt=class e{static create(t){let n=$.getOr(null);return $.set(new e(t,n))}opts;#e=L(null);get triggerNode(){return m(this.#e)}set triggerNode(e){b(this.#e,e,!0)}#t=L(null);get contentNode(){return m(this.#t)}set contentNode(e){b(this.#t,e,!0)}#n=L(null);get overlayNode(){return m(this.#n)}set overlayNode(e){b(this.#n,e,!0)}#r=L(null);get descriptionNode(){return m(this.#r)}set descriptionNode(e){b(this.#r,e,!0)}#i=L(void 0);get contentId(){return m(this.#i)}set contentId(e){b(this.#i,e,!0)}#a=L(void 0);get titleId(){return m(this.#a)}set titleId(e){b(this.#a,e,!0)}#o=L(void 0);get triggerId(){return m(this.#o)}set triggerId(e){b(this.#o,e,!0)}#s=L(void 0);get descriptionId(){return m(this.#s)}set descriptionId(e){b(this.#s,e,!0)}#c=L(null);get cancelNode(){return m(this.#c)}set cancelNode(e){b(this.#c,e,!0)}#l=L(0);get nestedOpenCount(){return m(this.#l)}set nestedOpenCount(e){b(this.#l,e,!0)}depth;parent;contentPresence;overlayPresence;constructor(e,t){this.opts=e,this.parent=t,this.depth=t?t.depth+1:0,this.handleOpen=this.handleOpen.bind(this),this.handleClose=this.handleClose.bind(this),this.contentPresence=new we({ref:Z(()=>this.contentNode),open:this.opts.open,enabled:!0,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new we({ref:Z(()=>this.overlayNode),open:this.opts.open,enabled:!0}),J(()=>this.opts.open.current,e=>{this.parent&&(e?this.parent.incrementNested():this.parent.decrementNested())},{lazy:!0}),he(()=>{this.opts.open.current&&this.parent?.decrementNested()})}handleOpen(){this.opts.open.current||(this.opts.open.current=!0)}handleClose(){this.opts.open.current&&(this.opts.open.current=!1)}getBitsAttr=e=>nt.getAttr(e,this.opts.variant.current);incrementNested(){this.nestedOpenCount++,this.parent?.incrementNested()}decrementNested(){this.nestedOpenCount!==0&&(this.nestedOpenCount--,this.parent?.decrementNested())}#u=S(()=>({"data-state":ce(this.opts.open.current)}));get sharedProps(){return m(this.#u)}set sharedProps(e){b(this.#u,e)}},it=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>{this.root.triggerNode=e,this.root.triggerId=e?.id}),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleOpen()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleOpen())}#e=S(()=>({id:this.opts.id.current,"aria-haspopup":`dialog`,"aria-expanded":le(this.root.opts.open.current),"aria-controls":this.root.contentId,[this.root.getBitsAttr(`trigger`)]:``,onkeydown:this.onkeydown,onclick:this.onclick,disabled:this.opts.disabled.current?!0:void 0,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},at=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.titleId=this.opts.id.current,this.attachment=X(this.opts.ref),J.pre(()=>this.opts.id.current,e=>{this.root.titleId=e})}#e=S(()=>({id:this.opts.id.current,role:`heading`,"aria-level":this.opts.level.current,[this.root.getBitsAttr(`title`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},ot=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.descriptionId=this.opts.id.current,this.attachment=X(this.opts.ref,e=>{this.root.descriptionNode=e}),J.pre(()=>this.opts.id.current,e=>{this.root.descriptionId=e})}#e=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`description`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},st=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>{this.root.contentNode=e,this.root.contentId=e?.id})}#e=S(()=>({open:this.root.opts.open.current}));get snippetProps(){return m(this.#e)}set snippetProps(e){b(this.#e,e)}#t=S(()=>({id:this.opts.id.current,role:this.root.opts.variant.current===`alert-dialog`?`alertdialog`:`dialog`,"aria-modal":`true`,"aria-describedby":this.root.descriptionId,"aria-labelledby":this.root.titleId,[this.root.getBitsAttr(`content`)]:``,style:{pointerEvents:`auto`,outline:this.root.opts.variant.current===`alert-dialog`?`none`:void 0,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount,contain:`layout style`},tabindex:this.root.opts.variant.current===`alert-dialog`?-1:void 0,"data-nested-open":pe(this.root.nestedOpenCount>0),"data-nested":pe(this.root.parent!==null),...de(this.root.contentPresence.transitionStatus),...this.root.sharedProps,...this.attachment}));get props(){return m(this.#t)}set props(e){b(this.#t,e)}get shouldRender(){return this.root.contentPresence.shouldRender}},ct=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>this.root.overlayNode=e)}#e=S(()=>({open:this.root.opts.open.current}));get snippetProps(){return m(this.#e)}set snippetProps(e){b(this.#e,e)}#t=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`overlay`)]:``,style:{pointerEvents:`auto`,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount},"data-nested-open":pe(this.root.nestedOpenCount>0),"data-nested":pe(this.root.parent!==null),...de(this.root.overlayPresence.transitionStatus),...this.root.sharedProps,...this.attachment}));get props(){return m(this.#t)}set props(e){b(this.#t,e)}get shouldRender(){return this.root.overlayPresence.shouldRender}},lt=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>this.root.cancelNode=e),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleClose()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleClose())}#e=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`cancel`)]:``,onclick:this.onclick,onkeydown:this.onkeydown,tabindex:0,disabled:this.opts.disabled.current,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}};function ut(n,i){r(i,!0);let a=O(i,`open`,15,!1),o=O(i,`onOpenChange`,3,G),s=O(i,`onOpenChangeComplete`,3,G);rt.create({variant:Z(()=>`alert-dialog`),open:Z(()=>a(),e=>{a(e),o()(e)}),onOpenChangeComplete:Z(()=>s())});var c=k(),l=R(c);B(l,()=>i.children??t),e(n,c),f()}var dt=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`child`,`children`,`level`]),ft=c(`<div><!></div>`);function pt(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`level`,3,2),u=y(i,dt),p=at.create({id:Z(()=>s()),level:Z(()=>l()),ref:Z(()=>c(),e=>c(e))}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=ft();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}var mt=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`children`,`child`,`disabled`]),ht=c(`<button><!></button>`);function gt(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`disabled`,3,!1),u=y(i,mt),p=lt.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e)),disabled:Z(()=>!!l())}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=ht();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}function _t(n,r){var i=k(),a=R(i);p(a,()=>r.children,n=>{var i=k(),a=R(i);B(a,()=>r.children??t),e(n,i)}),e(n,i)}var vt=new q(`BitsConfig`);function yt(){let e=new bt(null,{});return vt.getOr(e).opts}var bt=class{opts;constructor(e,t){let n=xt(e,t);this.opts={defaultPortalTo:n(e=>e.defaultPortalTo),defaultLocale:n(e=>e.defaultLocale)}}};function xt(e,t){return n=>Z(()=>{let r=n(t)?.current;if(r!==void 0)return r;if(e!==null)return n(e.opts)?.current})}function St(e,t){return n=>{let r=yt();return Z(()=>{let i=n();if(i!==void 0)return i;let a=e(r).current;return a===void 0?t:a})}}var Ct=St(e=>e.defaultPortalTo,`body`);function wt(n,o){r(o,!0);let s=Ct(()=>o.to),c=V(),l=S(u);function u(){if(!Ze||o.disabled)return null;let e=null;return e=typeof s.current==`string`?document.querySelector(s.current):s.current,e}let d;function p(){d&&=(A(d),null)}J([()=>m(l),()=>o.disabled],([e,t])=>{if(!e||t){p();return}return d=i(_t,{target:e,props:{children:o.children},context:c}),()=>{p()}});var h=k(),g=R(h),_=n=>{var r=k(),i=R(r);B(i,()=>o.children??t),e(n,r)};a(g,e=>{o.disabled&&e(_)}),e(n,h),f()}var Tt=class{eventName;options;constructor(e,t={bubbles:!0,cancelable:!0}){this.eventName=e,this.options=t}createEvent(e){return new CustomEvent(this.eventName,{...this.options,detail:e})}dispatch(e,t){let n=this.createEvent(t);return e.dispatchEvent(n),n}listen(e,t,n){return H(e,this.eventName,e=>{t(e)},n)}};function Et(e,t=500){let n=null,r=(...r)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...r)},t)};return r.destroy=()=>{n!==null&&(clearTimeout(n),n=null)},r}function Dt(e,t){return e===t||e.contains(t)}function Ot(e){return e?.ownerDocument??document}function kt(e,t){let{clientX:n,clientY:r}=e,i=t.getBoundingClientRect();return n<i.left||n>i.right||r<i.top||r>i.bottom}var At=[`input:not([inert]):not([inert] *)`,`select:not([inert]):not([inert] *)`,`textarea:not([inert]):not([inert] *)`,`a[href]:not([inert]):not([inert] *)`,`area[href]:not([inert]):not([inert] *)`,`button:not([inert]):not([inert] *)`,`[tabindex]:not(slot):not([inert]):not([inert] *)`,`audio[controls]:not([inert]):not([inert] *)`,`video[controls]:not([inert]):not([inert] *)`,`[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`,`details>summary:first-of-type:not([inert]):not([inert] *)`,`details:not([inert]):not([inert] *)`],jt=At.join(`,`),Mt=typeof Element>`u`,Nt=Mt?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Pt=!Mt&&Element.prototype.getRootNode?function(e){return e?.getRootNode?.call(e)}:function(e){return e?.ownerDocument},Ft=function(e,t){t===void 0&&(t=!0);var n=e?.getAttribute?.call(e,`inert`);return n===``||n===`true`||t&&e&&(typeof e.closest==`function`?e.closest(`[inert]`):Ft(e.parentNode))},It=function(e){var t=e?.getAttribute?.call(e,`contenteditable`);return t===``||t===`true`},Lt=function(e,t,n){if(Ft(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(jt));return t&&Nt.call(e,jt)&&r.unshift(e),r=r.filter(n),r},Rt=function(e,t,n){for(var r=[],i=Array.from(e);i.length;){var a=i.shift();if(!Ft(a,!1)){if(a.tagName===`SLOT`){var o=a.assignedElements(),s=Rt(o.length?o:a.children,!0,n);n.flatten?r.push.apply(r,s):r.push({scopeParent:a,candidates:s})}else{Nt.call(a,jt)&&n.filter(a)&&(t||!e.includes(a))&&r.push(a);var c=a.shadowRoot||typeof n.getShadowRoot==`function`&&n.getShadowRoot(a),l=!Ft(c,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(a));if(c&&l){var u=Rt(c===!0?a.children:c.children,!0,n);n.flatten?r.push.apply(r,u):r.push({scopeParent:a,candidates:u})}else i.unshift.apply(i,a.children)}}}return r},zt=function(e){return!isNaN(parseInt(e.getAttribute(`tabindex`),10))},Bt=function(e){if(!e)throw Error(`No node provided`);return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||It(e))&&!zt(e)?0:e.tabIndex},Vt=function(e,t){var n=Bt(e);return n<0&&t&&!zt(e)?0:n},Ht=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},Ut=function(e){return e.tagName===`INPUT`},Wt=function(e){return Ut(e)&&e.type===`hidden`},Gt=function(e){return e.tagName===`DETAILS`&&Array.prototype.slice.apply(e.children).some(function(e){return e.tagName===`SUMMARY`})},Kt=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},qt=function(e){if(!e.name)return!0;var t=e.form||Pt(e),n=function(e){return t.querySelectorAll(`input[type="radio"][name="`+e+`"]`)},r;if(typeof window<`u`&&window.CSS!==void 0&&typeof window.CSS.escape==`function`)r=n(window.CSS.escape(e.name));else try{r=n(e.name)}catch(e){return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`,e.message),!1}var i=Kt(r,e.form);return!i||i===e},Jt=function(e){return Ut(e)&&e.type===`radio`},Yt=function(e){return Jt(e)&&!qt(e)},Xt=function(e){var t=e&&Pt(e),n=t?.host,r=!1;if(t&&t!==e){var i,a,o;for(r=!!((i=n)!=null&&(a=i.ownerDocument)!=null&&a.contains(n)||e!=null&&(o=e.ownerDocument)!=null&&o.contains(e));!r&&n;){var s,c;t=Pt(n),n=t?.host,r=!!((s=n)!=null&&(c=s.ownerDocument)!=null&&c.contains(n))}}return r},Zt=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return n===0&&r===0},Qt=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if(n===`full-native`&&`checkVisibility`in e)return!e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});var i=getComputedStyle(e).visibility;if(i===`hidden`||i===`collapse`)return!0;var a=Nt.call(e,`details>summary:first-of-type`)?e.parentElement:e;if(Nt.call(a,`details:not([open]) *`))return!0;if(!n||n===`full`||n===`full-native`||n===`legacy-full`){if(typeof r==`function`){for(var o=e;e;){var s=e.parentElement,c=Pt(e);if(s&&!s.shadowRoot&&r(s)===!0)return Zt(e);e=e.assignedSlot?e.assignedSlot:!s&&c!==e.ownerDocument?c.host:s}e=o}if(Xt(e))return!e.getClientRects().length;if(n!==`legacy-full`)return!0}else if(n===`non-zero-area`)return Zt(e);return!1},$t=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName===`FIELDSET`&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if(r.tagName===`LEGEND`)return Nt.call(t,`fieldset[disabled] *`)?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},en=function(e,t){return!(t.disabled||Wt(t)||Qt(t,e)||Gt(t)||$t(t))},tn=function(e,t){return!(Yt(t)||Bt(t)<0||!en(e,t))},nn=function(e){var t=parseInt(e.getAttribute(`tabindex`),10);return!!(isNaN(t)||t>=0)},rn=function(e){var t=[],n=[];return e.forEach(function(e,r){var i=!!e.scopeParent,a=i?e.scopeParent:e,o=Vt(a,i),s=i?rn(e.candidates):a;o===0?i?t.push.apply(t,s):t.push(a):n.push({documentOrder:r,tabIndex:o,item:e,isScope:i,content:s})}),n.sort(Ht).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)},an=function(e,t){return t||={},rn(t.getShadowRoot?Rt([e],t.includeContainer,{filter:tn.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:nn}):Lt(e,t.includeContainer,tn.bind(null,t)))},on=function(e,t){return t||={},t.getShadowRoot?Rt([e],t.includeContainer,{filter:en.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):Lt(e,t.includeContainer,en.bind(null,t))},sn=At.concat(`iframe:not([inert]):not([inert] *)`).join(`,`),cn=function(e,t){if(t||={},!e)throw Error(`No node provided`);return Nt.call(e,sn)!==!1&&en(t,e)},ln=`data-context-menu-trigger`,un=`data-context-menu-content`;new q(`Menu.Root`),new q(`Menu.Root | Menu.Sub`),new q(`Menu.Content`),new q(`Menu.Group | Menu.RadioGroup`),new q(`Menu.RadioGroup`),new q(`Menu.CheckboxGroup`),new Tt(`bitsmenuopen`,{bubbles:!1,cancelable:!0}),me({component:`menu`,parts:[`trigger`,`content`,`sub-trigger`,`item`,`group`,`group-heading`,`checkbox-group`,`checkbox-item`,`radio-group`,`radio-item`,`separator`,`sub-content`,`arrow`]}),globalThis.bitsDismissableLayers??=new Map;var dn=class e{static create(t){return new e(t)}opts;#e;#t;#n={pointerdown:!1};#r=!1;#i=!1;#a=void 0;#o;#s=G;constructor(e){this.opts=e,this.#t=e.interactOutsideBehavior,this.#e=e.onInteractOutside,this.#o=e.onFocusOutside,h(()=>{this.#a=Ot(this.opts.ref.current)});let t=G,n=null,r=!1,i=()=>{n!=null&&(clearTimeout(n),n=null)},a=()=>{i(),this.#g(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),t()};J([()=>this.opts.enabled.current,()=>this.opts.ref.current],()=>{if(!(!this.opts.enabled.current||!this.opts.ref.current))return i(),n=Le(1,()=>{n=null,!(r||!this.opts.ref.current)&&(globalThis.bitsDismissableLayers.set(this,this.#t),t(),t=this.#l())}),a}),he(()=>{r=!0,i(),this.#g.destroy(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),this.#s(),t()})}#c=e=>{e.defaultPrevented||this.opts.ref.current&&ue(()=>{!this.opts.ref.current||this.#h(e.target)||e.target&&!this.#i&&this.#o.current?.(e)})};#l(){return De(H(this.#a,`pointerdown`,De(this.#f,this.#m),{capture:!0}),H(this.#a,`pointerdown`,De(this.#p,this.#d)),H(this.#a,`focusin`,this.#c))}#u=e=>{let t=e;t.defaultPrevented&&(t=hn(e)),this.#e.current(e)};#d=Et(e=>{if(!this.opts.ref.current){this.#s();return}let t=this.opts.isValidEvent.current(e,this.opts.ref.current)||mn(e,this.opts.ref.current);if(!this.#r||this.#_()||!t){this.#s();return}let n=e;if(n.defaultPrevented&&(n=hn(n)),this.#t.current!==`close`&&this.#t.current!==`defer-otherwise-close`){this.#s();return}e.pointerType===`touch`?(this.#s(),this.#s=H(this.#a,`click`,this.#u,{once:!0})):this.#e.current(n)},10);#f=e=>{this.#n[e.type]=!0};#p=e=>{this.#n[e.type]=!1};#m=()=>{this.opts.ref.current&&(this.#r=pn(this.opts.ref.current))};#h=e=>this.opts.ref.current?Dt(this.opts.ref.current,e):!1;#g=Et(()=>{for(let e in this.#n)this.#n[e]=!1;this.#r=!1},20);#_(){return Object.values(this.#n).some(Boolean)}#v=()=>{this.#i=!0};#y=()=>{this.#i=!1};props={onfocuscapture:this.#v,onblurcapture:this.#y}};function fn(e=[...globalThis.bitsDismissableLayers]){return e.findLast(([e,{current:t}])=>t===`close`||t===`ignore`)}function pn(e){let t=[...globalThis.bitsDismissableLayers],n=fn(t);if(n)return n[0].opts.ref.current===e;let[r]=t[0];return r.opts.ref.current===e}function mn(e,t){let n=e.target;if(!tt(n))return!1;let r=!!n.closest(`[${ln}]`),i=!!t.closest(`[${un}]`);return`button`in e&&e.button>0&&!r?!1:`button`in e&&e.button===0&&r&&i?!0:r&&i?!1:Ot(n).documentElement.contains(n)&&!Dt(t,n)&&kt(e,t)}function hn(e){let t=e.currentTarget,n=e.target,r;r=e instanceof PointerEvent?new PointerEvent(e.type,e):new PointerEvent(`pointerdown`,e);let i=!1;return new Proxy(r,{get:(r,a)=>a===`currentTarget`?t:a===`target`?n:a===`preventDefault`?()=>{i=!0,typeof r.preventDefault==`function`&&r.preventDefault()}:a===`defaultPrevented`?i:a in r?r[a]:e[a]})}function gn(n,i){r(i,!0);let a=O(i,`interactOutsideBehavior`,3,`close`),o=O(i,`onInteractOutside`,3,G),s=O(i,`onFocusOutside`,3,G),c=O(i,`isValidEvent`,3,()=>!1),l=dn.create({id:Z(()=>i.id),interactOutsideBehavior:Z(()=>a()),onInteractOutside:Z(()=>o()),enabled:Z(()=>i.enabled),onFocusOutside:Z(()=>s()),isValidEvent:Z(()=>c()),ref:i.ref});var u=k(),d=R(u);B(d,()=>i.children??t,()=>({props:l.props})),e(n,u),f()}globalThis.bitsEscapeLayers??=new Map;var _n=class e{static create(t){return new e(t)}opts;domContext;constructor(e){this.opts=e,this.domContext=new Xe(this.opts.ref);let t=G;J(()=>e.enabled.current,n=>(n&&(globalThis.bitsEscapeLayers.set(this,e.escapeKeydownBehavior),t=this.#e()),()=>{t(),globalThis.bitsEscapeLayers.delete(this)}))}#e=()=>H(this.domContext.getDocument(),`keydown`,this.#t,{passive:!1});#t=e=>{if(e.key!==`Escape`||!vn(this))return;let t=new KeyboardEvent(e.type,e);e.preventDefault();let n=this.opts.escapeKeydownBehavior.current;(n===`close`||n===`defer-otherwise-close`)&&this.opts.onEscapeKeydown.current(t)}};function vn(e){let t=[...globalThis.bitsEscapeLayers],n=t.findLast(([e,{current:t}])=>t===`close`||t===`ignore`);if(n)return n[0]===e;let[r]=t[0];return r===e}function yn(n,i){r(i,!0);let a=O(i,`escapeKeydownBehavior`,3,`close`),o=O(i,`onEscapeKeydown`,3,G);_n.create({escapeKeydownBehavior:Z(()=>a()),onEscapeKeydown:Z(()=>o()),enabled:Z(()=>i.enabled),ref:i.ref});var s=k(),c=R(s);B(c,()=>i.children??t),e(n,s),f()}var bn=class e{static instance;#e=ye([]);#t=new WeakMap;#n=new WeakMap;static getInstance(){return this.instance||=new e,this.instance}register(e){let t=this.getActive();t&&t!==e&&t.pause();let n=document.activeElement;n&&n!==document.body&&this.#n.set(e,n),this.#e.current=this.#e.current.filter(t=>t!==e),this.#e.current.unshift(e)}unregister(e){this.#e.current=this.#e.current.filter(t=>t!==e);let t=this.getActive();t&&t.resume()}getActive(){return this.#e.current[0]}setFocusMemory(e,t){this.#t.set(e,t)}getFocusMemory(e){return this.#t.get(e)}isActiveScope(e){return this.getActive()===e}setPreFocusMemory(e,t){this.#n.set(e,t)}getPreFocusMemory(e){return this.#n.get(e)}clearPreFocusMemory(e){this.#n.delete(e)}},xn=class e{#e=!1;#t=null;#n=bn.getInstance();#r=[];#i;constructor(e){this.#i=e}get paused(){return this.#e}pause(){this.#e=!0}resume(){this.#e=!1}#a(){for(let e of this.#r)e();this.#r=[]}mount(e){this.#t&&this.unmount(),this.#t=e,this.#n.register(this),this.#c(),this.#o()}unmount(){this.#t&&=(this.#a(),this.#s(),this.#n.unregister(this),this.#n.clearPreFocusMemory(this),null)}#o(){if(!this.#t)return;let e=new CustomEvent(`focusScope.onOpenAutoFocus`,{bubbles:!1,cancelable:!0});this.#i.onOpenAutoFocus.current(e),e.defaultPrevented||requestAnimationFrame(()=>{if(!this.#t)return;let e=this.#u();e?(e.focus(),this.#n.setFocusMemory(this,e)):this.#t.focus()})}#s(){let e=new CustomEvent(`focusScope.onCloseAutoFocus`,{bubbles:!1,cancelable:!0});if(this.#i.onCloseAutoFocus.current?.(e),!e.defaultPrevented){let e=this.#n.getPreFocusMemory(this);if(e&&document.contains(e))try{e.focus()}catch{document.body.focus()}}}#c(){if(!this.#t||!this.#i.trap.current)return;let e=this.#t,t=e.ownerDocument;this.#r.push(H(t,`focusin`,t=>{if(this.#e||!this.#n.isActiveScope(this))return;let n=t.target;if(n){if(e.contains(n))this.#n.setFocusMemory(this,n);else{let n=this.#n.getFocusMemory(this);if(n&&e.contains(n)&&cn(n))t.preventDefault(),n.focus();else{let t=this.#u(),n=this.#d()[0];(t||n||e).focus()}}}},{capture:!0}),H(e,`keydown`,e=>{if(!this.#i.loop||this.#e||e.key!==`Tab`||!this.#n.isActiveScope(this))return;let n=this.#l();if(n.length===0)return;let r=n[0],i=n[n.length-1];!e.shiftKey&&t.activeElement===i?(e.preventDefault(),r.focus()):e.shiftKey&&t.activeElement===r&&(e.preventDefault(),i.focus())}));let n=new MutationObserver(()=>{let t=this.#n.getFocusMemory(this);if(t&&!e.contains(t)){let t=this.#u(),n=this.#d()[0],r=t||n;r?(r.focus(),this.#n.setFocusMemory(this,r)):e.focus()}});n.observe(e,{childList:!0,subtree:!0}),this.#r.push(()=>n.disconnect())}#l(){return this.#t?an(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}#u(){return this.#l()[0]||null}#d(){return this.#t?on(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}static use(t){let n=null;return J([()=>t.ref.current,()=>t.enabled.current],([r,i])=>{r&&i?(n||=new e(t),n.mount(r)):n&&=(n.unmount(),null)}),he(()=>{n?.unmount()}),{get props(){return{tabindex:-1}}}}};function Sn(n,i){r(i,!0);let a=O(i,`enabled`,3,!1),o=O(i,`trapFocus`,3,!1),s=O(i,`loop`,3,!1),c=O(i,`onCloseAutoFocus`,3,G),l=O(i,`onOpenAutoFocus`,3,G),u=xn.use({enabled:Z(()=>a()),trap:Z(()=>o()),loop:s(),onCloseAutoFocus:Z(()=>c()),onOpenAutoFocus:Z(()=>l()),ref:i.ref});var d=k(),p=R(d);B(p,()=>i.focusScope??t,()=>({props:u.props})),e(n,d),f()}var Cn=()=>{};globalThis.bitsTextSelectionLayers??=new Map;var wn=class e{static create(t){return new e(t)}opts;domContext;#e=G;#t=!1;#n=Cn;#r=Cn;constructor(e){this.opts=e,this.domContext=new Xe(e.ref);let t=G;J(()=>[this.opts.enabled.current,this.opts.onPointerDown.current,this.opts.onPointerUp.current],([e,n,r])=>(this.#t=e,this.#n=n,this.#r=r,e&&(globalThis.bitsTextSelectionLayers.set(this,this.opts.enabled),t(),t=this.#i()),()=>{this.#t=!1,t(),this.#s(),globalThis.bitsTextSelectionLayers.delete(this)}))}#i(){return De(H(this.domContext.getDocument(),`pointerdown`,this.#o),H(this.domContext.getDocument(),`pointerup`,Ae(this.#s,this.#a)))}#a=e=>{this.#r(e)};#o=e=>{if(!this.#t)return;let t=this.opts.ref.current,n=e.target;!et(t)||!et(n)||!On(this)||!Ke(t,n)||(this.#n(e),!e.defaultPrevented&&(this.#e=En(t,this.domContext.getDocument().body)))};#s=()=>{this.#e(),this.#e=G}},Tn=e=>e.style.userSelect||e.style.webkitUserSelect;function En(e,t){let n=Tn(t),r=Tn(e);return Dn(t,`none`),Dn(e,`text`),()=>{Dn(t,n),Dn(e,r)}}function Dn(e,t){e.style.userSelect=t,e.style.webkitUserSelect=t}function On(e){let t=[...globalThis.bitsTextSelectionLayers];if(!t.length)return!1;let n=t.at(-1);return n?n[0]===e:!1}function kn(n,i){r(i,!0);let a=O(i,`preventOverflowTextSelection`,3,!0),o=O(i,`onPointerDown`,3,G),s=O(i,`onPointerUp`,3,G);wn.create({id:Z(()=>i.id),onPointerDown:Z(()=>o()),onPointerUp:Z(()=>s()),enabled:Z(()=>i.enabled&&a()),ref:i.ref});var c=k(),l=R(c);B(l,()=>i.children??t),e(n,c),f()}globalThis.bitsIdCounter??={current:0};function An(e=`bits`){return globalThis.bitsIdCounter.current++,`${e}-${globalThis.bitsIdCounter.current}`}var jn=class{#e;#t=0;#n=L();#r;constructor(e){this.#e=e}#i(){--this.#t,this.#r&&this.#t<=0&&(this.#r(),b(this.#n,void 0),this.#r=void 0)}get(...e){return this.#t+=1,m(this.#n)===void 0&&(this.#r=s(()=>{b(this.#n,this.#e(...e),!0)})),h(()=>()=>{this.#i()}),m(this.#n)}},Mn=new ae,Nn=L(null),Pn=null,Fn=null,In=!1,Ln=Z(()=>{for(let e of Mn.values())if(e)return!0;return!1}),Rn=null,zn=new jn(()=>{function e(){document.body.setAttribute(`style`,m(Nn)??``),document.body.style.removeProperty(`--scrollbar-width`),Qe&&Pn?.(),b(Nn,null)}function t(){Fn!==null&&(window.clearTimeout(Fn),Fn=null)}function n(e,n){t(),In=!0,Rn=Date.now();let r=Rn,i=()=>{Fn=null,Rn===r&&(Vn(Mn)?In=!1:(In=!1,n()))},a=e===null?24:e;Fn=window.setTimeout(i,a)}function r(){m(Nn)===null&&Mn.size===0&&!In&&b(Nn,document.body.getAttribute(`style`),!0)}return J(()=>Ln.current,()=>{if(!Ln.current)return;r(),In=!1;let e=getComputedStyle(document.documentElement),t=getComputedStyle(document.body),n=e.scrollbarGutter?.includes(`stable`)||t.scrollbarGutter?.includes(`stable`),i=window.innerWidth-document.documentElement.clientWidth,a={padding:Number.parseInt(t.paddingRight??`0`,10)+i,margin:Number.parseInt(t.marginRight??`0`,10)};i>0&&!n&&(document.body.style.paddingRight=`${a.padding}px`,document.body.style.marginRight=`${a.margin}px`,document.body.style.setProperty(`--scrollbar-width`,`${i}px`)),document.body.style.overflow=`hidden`,Qe&&(Pn=H(document,`touchmove`,e=>{e.target===document.documentElement&&(e.touches.length>1||e.preventDefault())},{passive:!1})),ue(()=>{document.body.style.pointerEvents=`none`,document.body.style.overflow=`hidden`})}),he(()=>()=>{Pn?.()}),{get lockMap(){return Mn},resetBodyStyle:e,scheduleCleanupIfNoNewLocks:n,cancelPendingCleanup:t,ensureInitialStyleCaptured:r}}),Bn=class{#e=An();#t;#n=()=>null;#r;locked;constructor(e,t=()=>null){this.#t=e,this.#n=t,this.#r=zn.get(),this.#r&&(this.#r.cancelPendingCleanup(),this.#r.ensureInitialStyleCaptured(),this.#r.lockMap.set(this.#e,this.#t??!1),this.locked=Z(()=>this.#r.lockMap.get(this.#e)??!1,e=>this.#r.lockMap.set(this.#e,e)),he(()=>{if(this.#r.lockMap.delete(this.#e),Vn(this.#r.lockMap))return;let e=this.#n();this.#r.scheduleCleanupIfNoNewLocks(e,()=>{this.#r.resetBodyStyle()})}))}};function Vn(e){for(let[t,n]of e)if(n)return!0;return!1}function Hn(e,t){r(t,!0);let n=O(t,`preventScroll`,3,!0),i=O(t,`restoreScrollDelay`,3,null);n()&&new Bn(n(),()=>i()),f()}var Un=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`children`,`child`,`ref`,`forceMount`,`interactOutsideBehavior`,`onCloseAutoFocus`,`onEscapeKeydown`,`onOpenAutoFocus`,`onInteractOutside`,`preventScroll`,`trapFocus`,`restoreScrollDelay`]),Wn=c(`<!> <!>`,1),Gn=c(`<!> <div><!></div>`,1);function Kn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`forceMount`,3,!1),u=O(i,`interactOutsideBehavior`,3,`ignore`),p=O(i,`onCloseAutoFocus`,3,G),h=O(i,`onEscapeKeydown`,3,G),g=O(i,`onOpenAutoFocus`,3,G),_=O(i,`onInteractOutside`,3,G),v=O(i,`preventScroll`,3,!0),b=O(i,`trapFocus`,3,!0),x=O(i,`restoreScrollDelay`,3,null),w=y(i,Un),E=st.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),D=S(()=>Q(w,E.props));var A=k(),M=R(A),ee=n=>{Sn(n,{get ref(){return E.opts.ref},loop:!0,get trapFocus(){return b()},get enabled(){return E.root.opts.open.current},get onCloseAutoFocus(){return p()},onOpenAutoFocus:e=>{g()(e),!e.defaultPrevented&&(e.preventDefault(),Le(0,()=>E.opts.ref.current?.focus()))},focusScope:(n,r)=>{let o=()=>(r?.()).props;yn(n,F(()=>m(D),{get enabled(){return E.root.opts.open.current},get ref(){return E.opts.ref},onEscapeKeydown:e=>{h()(e),!e.defaultPrevented&&E.root.handleClose()},children:(n,r)=>{gn(n,F(()=>m(D),{get ref(){return E.opts.ref},get enabled(){return E.root.opts.open.current},get interactOutsideBehavior(){return u()},onInteractOutside:e=>{_()(e),!e.defaultPrevented&&E.root.handleClose()},children:(n,r)=>{kn(n,F(()=>m(D),{get ref(){return E.opts.ref},get enabled(){return E.root.opts.open.current},children:(n,r)=>{var s=k(),c=R(s),l=t=>{var n=Wn(),r=R(n),s=e=>{Hn(e,{get preventScroll(){return v()},get restoreScrollDelay(){return x()}})};a(r,e=>{E.root.opts.open.current&&e(s)});var c=P(r,2);{let e=S(()=>({props:Q(m(D),o()),...E.snippetProps}));B(c,()=>i.child,()=>m(e))}e(t,n)},u=n=>{var r=Gn(),a=R(r);Hn(a,{get preventScroll(){return v()}});var s=P(a,2);C(s,e=>({...e}),[()=>Q(m(D),o())]);var c=T(s);B(c,()=>i.children??t),j(s),e(n,r)};a(c,e=>{i.child?e(l):e(u,-1)}),e(n,s)},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{focusScope:!0}})};a(M,e=>{(E.shouldRender||l())&&e(ee)}),e(n,A),f()}var qn=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`forceMount`,`child`,`children`,`ref`]),Jn=c(`<div><!></div>`);function Yn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`forceMount`,3,!1),l=O(i,`ref`,15,null),u=y(i,qn),p=ct.create({id:Z(()=>s()),ref:Z(()=>l(),e=>l(e))}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=n=>{var r=k(),o=R(r),s=t=>{var n=k(),r=R(n);{let e=S(()=>({props:Q(m(h)),...p.snippetProps}));B(r,()=>i.child,()=>m(e))}e(t,n)},c=n=>{var r=Jn();C(r,e=>({...e}),[()=>Q(m(h))]);var a=T(r);B(a,()=>i.children??t,()=>p.snippetProps),j(r),e(n,r)};a(o,e=>{i.child?e(s):e(c,-1)}),e(n,r)};a(_,e=>{(p.shouldRender||c())&&e(v)}),e(n,g),f()}var Xn=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`children`,`child`,`disabled`]),Zn=c(`<button><!></button>`);function Qn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`disabled`,3,!1),u=y(i,Xn),p=it.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e)),disabled:Z(()=>!!l())}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=Zn();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}var $n=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`children`,`child`,`ref`]),er=c(`<div><!></div>`);function tr(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=y(i,$n),u=ot.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),p=S(()=>Q(l,u.props));var h=k(),g=R(h),_=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(p)})),e(t,n)},v=n=>{var r=er();C(r,()=>({...m(p)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(g,e=>{i.child?e(_):e(v,-1)}),e(n,h),f()}var nr=me({component:`label`,parts:[`root`]}),rr=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=X(this.opts.ref),this.onmousedown=this.onmousedown.bind(this)}onmousedown(e){e.detail>1&&e.preventDefault()}#e=S(()=>({id:this.opts.id.current,[nr.root]:``,onmousedown:this.onmousedown,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},ir=new Set([`$$slots`,`$$events`,`$$legacy`,`children`,`child`,`id`,`ref`,`for`]),ar=c(`<label><!></label>`);function or(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=y(i,ir),u=rr.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),p=S(()=>Q(l,u.props,{for:i.for}));var h=k(),g=R(h),_=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(p)})),e(t,n)},v=n=>{var r=ar();C(r,()=>({...m(p),for:i.for}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(g,e=>{i.child?e(_):e(v,-1)}),e(n,h),f()}var sr=me({component:`progress`,parts:[`root`]}),cr=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=X(this.opts.ref)}#e=S(()=>({role:`progressbar`,value:this.opts.value.current,"aria-valuemin":this.opts.min.current,"aria-valuemax":this.opts.max.current,"aria-valuenow":this.opts.value.current===null?void 0:this.opts.value.current,"data-value":this.opts.value.current===null?void 0:this.opts.value.current,"data-state":lr(this.opts.value.current,this.opts.max.current),"data-max":this.opts.max.current,"data-min":this.opts.min.current,"data-indeterminate":this.opts.value.current===null?``:void 0,[sr.root]:``,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}};function lr(e,t){return e===null?`indeterminate`:e===t?`loaded`:`loading`}var ur=new Set([`$$slots`,`$$events`,`$$legacy`,`child`,`children`,`value`,`max`,`min`,`id`,`ref`]),dr=c(`<div><!></div>`);function fr(n,i){let o=d();r(i,!0);let s=O(i,`value`,3,0),c=O(i,`max`,3,100),l=O(i,`min`,3,0),u=O(i,`id`,19,()=>Y(o)),p=O(i,`ref`,15,null),h=y(i,ur),g=cr.create({value:Z(()=>s()),max:Z(()=>c()),min:Z(()=>l()),id:Z(()=>u()),ref:Z(()=>p(),e=>p(e))}),_=S(()=>Q(h,g.props));var v=k(),b=R(v),x=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(_)})),e(t,n)},w=n=>{var r=dr();C(r,()=>({...m(_)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(b,e=>{i.child?e(x):e(w,-1)}),e(n,v),f()}var pr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function mr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,pr);var o=k(),s=R(o);{let e=S(()=>K(`gap-2 text-sm leading-none font-medium group-data-[disabled=true]:opacity-50 peer-disabled:opacity-50 flex items-center select-none group-data-[disabled=true]:pointer-events-none peer-disabled:cursor-not-allowed`,n.class));x(s,()=>or,(t,n)=>{n(t,F({"data-slot":`label`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var hr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`value`,`type`,`files`,`class`,`data-slot`]),gr=c(`<input/>`);function _r(t,n){r(n,!0);let i=O(n,`ref`,15,null),o=O(n,`value`,15),s=O(n,`files`,15),c=O(n,`data-slot`,3,`input`),l=y(n,hr);var u=k(),d=R(u),p=t=>{var r=gr();C(r,e=>({"data-slot":c(),class:e,type:`file`,...l}),[()=>K(`h-8 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors file:h-6 file:text-sm file:font-medium focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:bg-input/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,n.class)],void 0,void 0,void 0,!0),I(r,e=>i(e),()=>i()),M(r,s),z(r,o),e(t,r)},m=t=>{var r=gr();C(r,e=>({"data-slot":c(),class:e,type:n.type,...l}),[()=>K(`h-8 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors file:h-6 file:text-sm file:font-medium focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:bg-input/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,n.class)],void 0,void 0,void 0,!0),I(r,e=>i(e),()=>i()),z(r,o),e(t,r)};a(d,e=>{n.type===`file`?e(p):e(m,-1)}),e(t,u),f()}var vr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`variant`,`size`]);function yr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`variant`,3,`outline`),o=O(n,`size`,3,`default`),s=y(n,vr);var c=k(),l=R(c);{let e=S(()=>K(se({variant:a(),size:o()}),`cn-alert-dialog-cancel`,n.class));x(l,()=>gt,(t,n)=>{n(t,F({"data-slot":`alert-dialog-cancel`,get class(){return m(e)}},()=>s,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,c),f()}var br=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function xr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,br);var o=k(),s=R(o);{let e=S(()=>K(`bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 fixed inset-0 z-50`,n.class));x(s,()=>Yn,(t,n)=>{n(t,F({"data-slot":`alert-dialog-overlay`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var Sr=new Set([`$$slots`,`$$events`,`$$legacy`]);function Cr(t,n){let r=y(n,Sr);var i=k(),a=R(i);x(a,()=>wt,(e,t)=>{t(e,F(()=>r))}),e(t,i)}var wr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`size`,`portalProps`]),Tr=c(`<!> <!>`,1);function Er(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`size`,3,`default`),o=y(n,wr);Cr(t,F(()=>n.portalProps,{children:(t,r)=>{var s=Tr(),c=R(s);xr(c,{});var l=P(c,2);{let e=S(()=>K(`gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 outline-none`,n.class));x(l,()=>Kn,(t,n)=>{n(t,F({"data-slot":`alert-dialog-content`,get"data-size"(){return a()},get class(){return m(e)}},()=>o,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,s)},$$slots:{default:!0}})),f()}var Dr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function Or(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Dr);var o=k(),s=R(o);{let e=S(()=>K(`text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,n.class));x(s,()=>tr,(t,n)=>{n(t,F({"data-slot":`alert-dialog-description`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var kr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`children`]),Ar=c(`<div><!></div>`);function jr(n,i){r(i,!0);let a=O(i,`ref`,15,null),o=y(i,kr);var s=Ar();C(s,e=>({"data-slot":`alert-dialog-footer`,class:e,...o}),[()=>K(`-mx-4 -mb-4 rounded-b-xl border-t bg-muted/50 p-4 flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end`,i.class)]);var c=T(s);B(c,()=>i.children??t),j(s),I(s,e=>a(e),()=>a()),e(n,s),f()}var Mr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`children`]),Nr=c(`<div><!></div>`);function Pr(n,i){r(i,!0);let a=O(i,`ref`,15,null),o=y(i,Mr);var s=Nr();C(s,e=>({"data-slot":`alert-dialog-header`,class:e,...o}),[()=>K(`grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]`,i.class)]);var c=T(s);B(c,()=>i.children??t),j(s),I(s,e=>a(e),()=>a()),e(n,s),f()}var Fr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function Ir(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Fr);var o=k(),s=R(o);{let e=S(()=>K(`text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2`,n.class));x(s,()=>pt,(t,n)=>{n(t,F({"data-slot":`alert-dialog-title`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var Lr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`]);function Rr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Lr);var o=k(),s=R(o);x(s,()=>Qn,(e,t)=>{t(e,F({"data-slot":`alert-dialog-trigger`},()=>a,{get ref(){return i()},set ref(e){i(e)}}))}),e(t,o),f()}var zr=new Set([`$$slots`,`$$events`,`$$legacy`,`open`]);function Br(t,n){r(n,!0);let i=O(n,`open`,15,!1),a=y(n,zr);var o=k(),s=R(o);x(s,()=>ut,(e,t)=>{t(e,F(()=>a,{get open(){return i()},set open(e){i(e)}}))}),e(t,o),f()}var Vr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`max`,`value`]),Hr=c(`<div data-slot="progress-indicator" class="bg-primary size-full flex-1 transition-all"></div>`);function Ur(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`max`,3,100),o=y(n,Vr);var s=k(),c=R(s);{let t=S(()=>K(`h-1 rounded-full bg-muted relative flex w-full items-center overflow-x-hidden`,n.class));x(c,()=>fr,(r,s)=>{s(r,F({"data-slot":`progress`,get class(){return m(t)},get value(){return n.value},get max(){return a()}},()=>o,{get ref(){return i()},set ref(e){i(e)},children:(t,r)=>{var i=Hr();g(()=>te(i,`transform: translateX(-${100-100*(n.value??0)/(a()??1)}%)`)),e(t,i)},$$slots:{default:!0}}))})}e(t,s),f()}var Wr=new Set([`$$slots`,`$$events`,`$$legacy`,`name`,`duration`,`label`,`variant`,`children`,`position`,`align`,`portal`,`onclick`,`onpress`,`class`,`message`]),Gr=c(`<div><div class="text-xs text-muted-foreground"><!></div> <!></div>`),Kr=c(`<!> <!>`,1);function qr(n,i){r(i,!0);let s=()=>E(m(U),`$countdown`,c),[c,u]=w(),d=O(i,`name`,3,`hold`),p=O(i,`duration`,3,800),x=O(i,`variant`,3,`ghost`),C=O(i,`position`,3,`left`),A=O(i,`align`,3,`center`),M=O(i,`portal`,3,!0),I=y(i,Wr),z=L(!1),V=L(!1),H=L(null),U=L(ne(v(p()))),W=S(()=>Math.round((1-s()/p())*100));h(()=>{s()===0&&se()});function ie(e){ce(e),e.altKey?se(!0):G()}function ae(e){e.key===` `&&G()}function G(){m(z)||(i.onpress?.(),b(z,!0),b(V,!0),N(b(U,re(p(),60),!0),`$countdown`,c),m(H)&&clearTimeout(m(H)))}function oe(){m(z)&&(b(H,setTimeout(()=>{b(V,!1)},m(W)>20?200:1e3),!0),b(z,!1),N(b(U,v(p()),!0),`$countdown`,c))}function se(e=!1){!m(z)&&!e||(i.onclick?.(),b(z,!1),b(H,setTimeout(()=>{b(V,!1),N(b(U,v(p()),!0),`$countdown`,c)},300),!0))}function ce(e){e.preventDefault(),e.stopPropagation()}function le(e,t){if(t)return document.body.appendChild(e),{destroy:()=>e.remove()}}var ue=Kr(),de=R(ue);{let n=S(()=>K(`select-none`,i.class)),r=S(()=>`anchor-name: --${d()};`);fe(de,F({get variant(){return x()}},()=>I,{get class(){return m(n)},onpointerdown:ie,onkeydown:ae,oncontextmenu:ce,onpointerup:oe,onpointerleave:oe,onkeyup:oe,get style(){return m(r)},children:(n,r)=>{var a=k(),o=R(a);B(o,()=>i.children??t),e(n,a)},$$slots:{default:!0}}))}var q=P(de,2),pe=t=>{var n=Gr(),r=T(n),s=T(r),c=t=>{var n=k(),r=R(n);B(r,()=>i.message),e(t,n)},u=t=>{var n=o();g(()=>l(n,i.label)),e(t,n)};a(s,e=>{i.message?e(c):e(u,-1)}),j(r),Ur(P(r,2),{get value(){return m(W)},class:`h-1 [&_div[data-slot=progress-indicator]]:bg-destructive/90 [&_div[data-slot=progress-indicator]]:transition-none`}),j(n),_(n,(e,t)=>le?.(e,t),M),g(e=>{ee(n,1,e),te(n,`position-anchor: --${d()}; position-area: ${C()} ${A()};`)},[()=>D(K(`fixed z-1002 w-fit min-w-26 transition-all ease-in-out space-y-1`,`bg-background/85 p-2 pt-1 rounded-md`,`starting:scale-0`))]),e(t,n)};a(q,e=>{m(V)&&e(pe)}),e(n,ue),f(),u()}var Jr=7e3,Yr=c(`<!> `,1),Xr=c(`<!> <!>`,1),Zr=c(`<p id="introspection-halt-error" class="text-destructive text-sm"> </p>`),Qr=c(` <!>`,1),$r=c(`<!> <div class="grid grid-cols-2 gap-4"><div class="flex flex-col gap-1.5"><!> <!> <p id="introspection-halt-hint"> </p></div> <div class="flex flex-col gap-1.5"><!> <!> <p id="introspection-halt-quiescence-hint"> </p></div></div> <!> <!>`,1);function ei(t,n){r(n,!0);let i=()=>E(Ce,`$configuration`,c),s=()=>E(ie,`$dict`,c),[c,d]=w(),p=S(()=>Pe(i())?i().halt??null:null),h=L(!1),_=L(ne({})),v=L(null),y=L(!1),C=L(!1),O=null,A=S(()=>m(_).duration??(m(p)===null?void 0:ae(600,m(p).duration))),M=S(()=>m(_).quiescence??(m(p)===null?void 0:ae(60,m(p).quiescence))),N=S(()=>m(p)!==null&&re(m(A),m(p).duration)),F=S(()=>m(p)!==null&&re(m(M),m(p).quiescence)),te=S(()=>m(N)&&m(F)),I=S(()=>m(v)!==null);function z(e){U(),b(C,!1),b(_,{},!0)}function B(){!m(te)||m(I)||(b(C,!1),b(v,9,!0),O=setInterval(V,1e3))}function V(){m(v)!==null&&(b(v,m(v)-1),!(m(v)>0)&&(W(),b(y,!0),H()))}async function H(){let e=await Ee(m(A),m(M));b(y,!1),b(C,e instanceof Error),m(C)?U():b(h,!1)}function U(){W(),b(v,null),b(y,!1)}function W(){O!==null&&clearInterval(O),O=null}function re(e,[t,n]){return e!==void 0&&Number.isInteger(e)&&e>=t&&e<=n}function ae(e,[t,n]){return Math.min(n,Math.max(t,e))}var G=k(),oe=R(G),ce=t=>{var n=k(),r=R(n);x(r,()=>Br,(t,n)=>{n(t,{onOpenChange:z,get open(){return m(h)},set open(e){b(h,e,!0)},children:(t,n)=>{var r=Xr(),i=R(r);{let t=S(()=>[se({variant:`ghost`}),`text-destructive hover:text-destructive`]);x(i,()=>Rr,(n,r)=>{r(n,{id:`introspection-halt-button`,get class(){return m(t)},children:(t,n)=>{var r=Yr(),i=R(r);Ie(i,{});var a=P(i);g(()=>l(a,` ${s().nav.halt??``}`)),e(t,r)},$$slots:{default:!0}})})}var c=P(i,2);x(c,()=>Er,(t,n)=>{n(t,{children:(t,n)=>{var r=$r(),i=R(r);x(i,()=>Pr,(t,n)=>{n(t,{children:(t,n)=>{var r=Xr(),i=R(r);x(i,()=>Ir,(t,n)=>{n(t,{children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.title)),e(t,r)},$$slots:{default:!0}})});var a=P(i,2);x(a,()=>Or,(t,n)=>{n(t,{children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.description)),e(t,r)},$$slots:{default:!0}})}),e(t,r)},$$slots:{default:!0}})});var c=P(i,2),d=T(c),f=T(d);mr(f,{for:`introspection-halt-input`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.interval)),e(t,r)},$$slots:{default:!0}});var h=P(f,2),b=()=>m(A),w=e=>m(_).duration=e;{let e=S(()=>!m(N));_r(h,{id:`introspection-halt-input`,type:`number`,inputmode:`numeric`,get min(){return m(p).duration[0]},get max(){return m(p).duration[1]},step:`1`,get disabled(){return m(I)},get value(){return b()},set value(e){w(e)},get"aria-invalid"(){return m(e)},"aria-describedby":`introspection-halt-hint`})}var E=P(h,2),O=T(E,!0);j(E),j(d);var ne=P(d,2),L=T(ne);mr(L,{for:`introspection-halt-quiescence-input`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.quiescence)),e(t,r)},$$slots:{default:!0}});var z=P(L,2),V=()=>m(M),H=e=>m(_).quiescence=e;{let e=S(()=>!m(F));_r(z,{id:`introspection-halt-quiescence-input`,type:`number`,inputmode:`numeric`,get min(){return m(p).quiescence[0]},get max(){return m(p).quiescence[1]},step:`1`,get disabled(){return m(I)},get value(){return V()},set value(e){H(e)},get"aria-invalid"(){return m(e)},"aria-describedby":`introspection-halt-quiescence-hint`})}var W=P(z,2),re=T(W,!0);j(W),j(ne),j(c);var ie=P(c,2),ae=t=>{var n=Zr(),r=T(n,!0);j(n),g(()=>l(r,s().halt.failed)),e(t,n)};a(ie,e=>{m(C)&&e(ae)});var G=P(ie,2);x(G,()=>jr,(t,n)=>{n(t,{children:(t,n)=>{var r=Xr(),i=R(r),c=t=>{fe(t,{id:`introspection-halt-cancel-button`,variant:`outline`,get disabled(){return m(y)},onclick:U,children:(t,n)=>{u();var r=Qr(),i=R(r),a=P(i);Ne(a,{id:`introspection-halt-countdown`,variant:`destructive`,class:`tabular-nums`,children:(t,n)=>{u();var r=o();g(()=>l(r,m(v))),e(t,r)},$$slots:{default:!0}}),g(()=>l(i,`${s().halt.cancel??``} `)),e(t,r)},$$slots:{default:!0}})},d=t=>{var n=k(),r=R(n);x(r,()=>yr,(t,n)=>{n(t,{id:`introspection-halt-cancel-button`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.cancel)),e(t,r)},$$slots:{default:!0}})}),e(t,n)};a(i,e=>{m(I)?e(c):e(d,-1)});var f=P(i,2);{let t=S(()=>!m(te)||m(I));qr(f,{id:`introspection-halt-confirm-button`,variant:`destructive`,portal:!1,position:`top`,get duration(){return Jr},get label(){return s().halt.hold},get disabled(){return m(t)},onclick:B,children:(t,n)=>{u();var r=o();g(()=>l(r,s().nav.halt)),e(t,r)},$$slots:{default:!0}})}e(t,r)},$$slots:{default:!0}})}),g((e,t)=>{ee(E,1,D([`text-xs`,m(N)?`text-muted-foreground`:`text-destructive`])),l(O,e),ee(W,1,D([`text-xs`,m(F)?`text-muted-foreground`:`text-destructive`])),l(re,t)},[()=>s().halt.bounds(m(p).duration[0],m(p).duration[1]),()=>s().halt.bounds(m(p).quiescence[0],m(p).quiescence[1])]),e(t,r)},$$slots:{default:!0}})}),e(t,r)},$$slots:{default:!0}})}),e(t,n)};a(oe,e=>{m(p)!==null&&e(ce)}),e(t,G),f(),d()}var ti=new Set([`$$slots`,`$$events`,`$$legacy`,`class`]),ni=c(`<p class="text-muted-foreground py-20 text-center"> </p>`),ri=c(`<section class="flex flex-col gap-2"><div class="text-muted-foreground flex items-center gap-3"><span class="text-xs font-medium tracking-wide uppercase"> </span> <!></div> <!></section>`),ii=c(`<div></div>`);function ai(t,i){r(i,!0);let o=()=>E(ge,`$nodes`,u),s=()=>E(Oe,`$query`,u),c=()=>E(ve,`$dict`,u),[u,d]=w(),p=y(i,ti),_=new be,v=S(()=>Pe(o())?o():[]),b=S(()=>m(v).map(e=>({node:e,rank:Te(e,s())})).filter(e=>e.rank>0).sort(D));h(()=>{let e=m(b).length===1?Me(m(b)[0].node):null;return xe.set(e===null?null:()=>_.add(e)),()=>xe.set(null)});function D(e,t){return t.rank-e.rank||e.node.namespace.localeCompare(t.node.namespace)||e.node.component.localeCompare(t.node.component)}function O(e){return[{id:`user`,label:c().space.user,of:e.filter(e=>!Se(e.node))},{id:`system`,label:c().space.system,of:e.filter(e=>Se(e.node))}].filter(e=>e.of.length>0)}W(t,{get store(){return ge},awaited:t=>{var r=k(),o=R(r),s=t=>{var n=ni(),r=T(n,!0);j(n),g(()=>l(r,c().nodes.empty)),e(t,n)},u=t=>{var n=ni(),r=T(n,!0);j(n),g(()=>l(r,c().nodes.nomatch)),e(t,n)},d=t=>{var r=ii();C(r,()=>({class:[`flex flex-col gap-6`,i.class],...p})),n(r,21,()=>O(m(b)),e=>e.id,(t,r)=>{var i=ri(),a=T(i),o=T(a),s=T(o,!0);j(o);var c=P(o,2);oe(c,{class:`flex-1`}),j(a);var u=P(a,2);x(u,()=>_e,(t,i)=>{i(t,{class:`gap-2`,children:(t,i)=>{var a=k(),o=R(a);n(o,17,()=>m(r).of,e=>e.node.id,(e,t)=>{let n=S(()=>Me(m(t).node));var r=()=>_.has(m(n)),i=e=>e?_.add(m(n)):_.delete(m(n));je(e,{get node(){return m(t).node},get open(){return r()},set open(e){i(e)}})}),e(t,a)},$$slots:{default:!0}})}),j(i),g(()=>l(s,m(r).label)),e(t,i)}),j(r),e(t,r)};a(o,e=>{m(v).length===0?e(s):m(b).length===0?e(u,1):e(d,-1)}),e(t,r)},$$slots:{awaited:!0}}),f(),d()}export{Xe as a,et as i,ei as n,Je as o,_r as r,ai as t};
|
|
1
|
+
import{A as e,At as t,C as n,Ct as r,D as i,E as a,F as o,J as s,M as c,O as l,Ot as u,P as d,St as f,T as p,V as m,X as h,Y as g,_,_t as v,a as y,at as b,b as x,ct as S,d as C,dt as w,et as T,ft as E,h as D,i as O,j as k,k as A,kt as j,l as M,m as ee,mt as N,nt as P,o as F,p as te,rt as ne,s as I,st as L,tt as R,u as z,x as B,yt as V,z as H}from"./sTot5bBi.js";import"./EttRBGeu.js";import"./xihTtKlq.js";import{F as U,N as W,r as re,t as ie}from"./CfwVa1wg.js";import{$ as ae,A as G,C as oe,E as se,G as ce,H as le,J as ue,K as de,O as K,Q as q,T as fe,V as pe,W as me,Y as he,Z as J,_t as ge,b as _e,c as ve,dt as ye,et as be,f as xe,g as Se,ht as Ce,j as we,k as Y,m as Te,mt as Ee,nt as De,p as Oe,pt as ke,q as X,rt as Ae,st as Z,t as je,tt as Q,u as Me,w as Ne}from"./mN1X6kWf.js";function Pe(e){return e!==null&&!(e instanceof Error)}var Fe=new Set([`$$slots`,`$$events`,`$$legacy`]);function Ie(e,t){let n=y(t,Fe),r=[[`rect`,{x:`14`,y:`3`,width:`5`,height:`18`,rx:`1`}],[`rect`,{x:`5`,y:`3`,width:`5`,height:`18`,rx:`1`}]];U(e,F({name:`pause`},()=>n,{get iconNode(){return r}}))}function Le(e,t){return setTimeout(t,e)}var Re=1,ze=9,Be=11;function Ve(e){return ke(e)&&e.nodeType===Re&&typeof e.nodeName==`string`}function He(e){return ke(e)&&e.nodeType===ze}function Ue(e){return ke(e)&&e.constructor?.name===`VisualViewport`}function We(e){return ke(e)&&e.nodeType!==void 0}function Ge(e){return We(e)&&e.nodeType===Be&&`host`in e}function Ke(e,t){if(!e||!t||!Ve(e)||!Ve(t))return!1;let n=t.getRootNode?.();if(e===t||e.contains(t))return!0;if(n&&Ge(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function qe(e){return He(e)?e:Ue(e)?e.document:e?.ownerDocument??document}function Je(e){return Ge(e)?Je(e.host):He(e)?e.defaultView??window:Ve(e)?e.ownerDocument?.defaultView??window:window}function Ye(e){let t=e.activeElement;for(;t?.shadowRoot;){let e=t.shadowRoot.activeElement;if(e===t)break;t=e}return t}var Xe=class{element;#e=S(()=>this.element.current?this.element.current.getRootNode()??document:document);get root(){return m(this.#e)}set root(e){b(this.#e,e)}constructor(e){this.element=typeof e==`function`?Z(e):e}getDocument=()=>qe(this.root);getWindow=()=>this.getDocument().defaultView??window;getActiveElement=()=>Ye(this.root);isActiveElement=e=>e===this.getActiveElement();getElementById(e){return this.root.getElementById(e)}querySelector=e=>this.root?this.root.querySelector(e):null;querySelectorAll=e=>this.root?this.root.querySelectorAll(e):[];setTimeout=(e,t)=>this.getWindow().setTimeout(e,t);clearTimeout=e=>this.getWindow().clearTimeout(e)},Ze=typeof document<`u`,Qe=$e();function $e(){return Ze&&window?.navigator?.userAgent&&(/iP(ad|hone|od)/.test(window.navigator.userAgent)||window?.navigator?.maxTouchPoints>2&&/iPad|Macintosh/.test(window?.navigator.userAgent))}function et(e){return e instanceof HTMLElement}function tt(e){return e instanceof Element||e instanceof SVGElement}var nt=me({component:`dialog`,parts:[`content`,`trigger`,`overlay`,`title`,`description`,`close`,`cancel`,`action`]}),$=new q(`Dialog.Root | AlertDialog.Root`),rt=class e{static create(t){let n=$.getOr(null);return $.set(new e(t,n))}opts;#e=L(null);get triggerNode(){return m(this.#e)}set triggerNode(e){b(this.#e,e,!0)}#t=L(null);get contentNode(){return m(this.#t)}set contentNode(e){b(this.#t,e,!0)}#n=L(null);get overlayNode(){return m(this.#n)}set overlayNode(e){b(this.#n,e,!0)}#r=L(null);get descriptionNode(){return m(this.#r)}set descriptionNode(e){b(this.#r,e,!0)}#i=L(void 0);get contentId(){return m(this.#i)}set contentId(e){b(this.#i,e,!0)}#a=L(void 0);get titleId(){return m(this.#a)}set titleId(e){b(this.#a,e,!0)}#o=L(void 0);get triggerId(){return m(this.#o)}set triggerId(e){b(this.#o,e,!0)}#s=L(void 0);get descriptionId(){return m(this.#s)}set descriptionId(e){b(this.#s,e,!0)}#c=L(null);get cancelNode(){return m(this.#c)}set cancelNode(e){b(this.#c,e,!0)}#l=L(0);get nestedOpenCount(){return m(this.#l)}set nestedOpenCount(e){b(this.#l,e,!0)}depth;parent;contentPresence;overlayPresence;constructor(e,t){this.opts=e,this.parent=t,this.depth=t?t.depth+1:0,this.handleOpen=this.handleOpen.bind(this),this.handleClose=this.handleClose.bind(this),this.contentPresence=new we({ref:Z(()=>this.contentNode),open:this.opts.open,enabled:!0,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),this.overlayPresence=new we({ref:Z(()=>this.overlayNode),open:this.opts.open,enabled:!0}),J(()=>this.opts.open.current,e=>{this.parent&&(e?this.parent.incrementNested():this.parent.decrementNested())},{lazy:!0}),he(()=>{this.opts.open.current&&this.parent?.decrementNested()})}handleOpen(){this.opts.open.current||(this.opts.open.current=!0)}handleClose(){this.opts.open.current&&(this.opts.open.current=!1)}getBitsAttr=e=>nt.getAttr(e,this.opts.variant.current);incrementNested(){this.nestedOpenCount++,this.parent?.incrementNested()}decrementNested(){this.nestedOpenCount!==0&&(this.nestedOpenCount--,this.parent?.decrementNested())}#u=S(()=>({"data-state":ce(this.opts.open.current)}));get sharedProps(){return m(this.#u)}set sharedProps(e){b(this.#u,e)}},it=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>{this.root.triggerNode=e,this.root.triggerId=e?.id}),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleOpen()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleOpen())}#e=S(()=>({id:this.opts.id.current,"aria-haspopup":`dialog`,"aria-expanded":le(this.root.opts.open.current),"aria-controls":this.root.contentId,[this.root.getBitsAttr(`trigger`)]:``,onkeydown:this.onkeydown,onclick:this.onclick,disabled:this.opts.disabled.current?!0:void 0,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},at=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.titleId=this.opts.id.current,this.attachment=X(this.opts.ref),J.pre(()=>this.opts.id.current,e=>{this.root.titleId=e})}#e=S(()=>({id:this.opts.id.current,role:`heading`,"aria-level":this.opts.level.current,[this.root.getBitsAttr(`title`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},ot=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.root.descriptionId=this.opts.id.current,this.attachment=X(this.opts.ref,e=>{this.root.descriptionNode=e}),J.pre(()=>this.opts.id.current,e=>{this.root.descriptionId=e})}#e=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`description`)]:``,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},st=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>{this.root.contentNode=e,this.root.contentId=e?.id})}#e=S(()=>({open:this.root.opts.open.current}));get snippetProps(){return m(this.#e)}set snippetProps(e){b(this.#e,e)}#t=S(()=>({id:this.opts.id.current,role:this.root.opts.variant.current===`alert-dialog`?`alertdialog`:`dialog`,"aria-modal":`true`,"aria-describedby":this.root.descriptionId,"aria-labelledby":this.root.titleId,[this.root.getBitsAttr(`content`)]:``,style:{pointerEvents:`auto`,outline:this.root.opts.variant.current===`alert-dialog`?`none`:void 0,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount,contain:`layout style`},tabindex:this.root.opts.variant.current===`alert-dialog`?-1:void 0,"data-nested-open":pe(this.root.nestedOpenCount>0),"data-nested":pe(this.root.parent!==null),...de(this.root.contentPresence.transitionStatus),...this.root.sharedProps,...this.attachment}));get props(){return m(this.#t)}set props(e){b(this.#t,e)}get shouldRender(){return this.root.contentPresence.shouldRender}},ct=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>this.root.overlayNode=e)}#e=S(()=>({open:this.root.opts.open.current}));get snippetProps(){return m(this.#e)}set snippetProps(e){b(this.#e,e)}#t=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`overlay`)]:``,style:{pointerEvents:`auto`,"--bits-dialog-depth":this.root.depth,"--bits-dialog-nested-count":this.root.nestedOpenCount},"data-nested-open":pe(this.root.nestedOpenCount>0),"data-nested":pe(this.root.parent!==null),...de(this.root.overlayPresence.transitionStatus),...this.root.sharedProps,...this.attachment}));get props(){return m(this.#t)}set props(e){b(this.#t,e)}get shouldRender(){return this.root.overlayPresence.shouldRender}},lt=class e{static create(t){return new e(t,$.get())}opts;root;attachment;constructor(e,t){this.opts=e,this.root=t,this.attachment=X(this.opts.ref,e=>this.root.cancelNode=e),this.onclick=this.onclick.bind(this),this.onkeydown=this.onkeydown.bind(this)}onclick(e){this.opts.disabled.current||e.button>0||this.root.handleClose()}onkeydown(e){this.opts.disabled.current||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),this.root.handleClose())}#e=S(()=>({id:this.opts.id.current,[this.root.getBitsAttr(`cancel`)]:``,onclick:this.onclick,onkeydown:this.onkeydown,tabindex:0,disabled:this.opts.disabled.current,...this.root.sharedProps,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}};function ut(n,i){r(i,!0);let a=O(i,`open`,15,!1),o=O(i,`onOpenChange`,3,G),s=O(i,`onOpenChangeComplete`,3,G);rt.create({variant:Z(()=>`alert-dialog`),open:Z(()=>a(),e=>{a(e),o()(e)}),onOpenChangeComplete:Z(()=>s())});var c=k(),l=R(c);B(l,()=>i.children??t),e(n,c),f()}var dt=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`child`,`children`,`level`]),ft=c(`<div><!></div>`);function pt(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`level`,3,2),u=y(i,dt),p=at.create({id:Z(()=>s()),level:Z(()=>l()),ref:Z(()=>c(),e=>c(e))}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=ft();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}var mt=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`children`,`child`,`disabled`]),ht=c(`<button><!></button>`);function gt(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`disabled`,3,!1),u=y(i,mt),p=lt.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e)),disabled:Z(()=>!!l())}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=ht();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}function _t(n,r){var i=k(),a=R(i);p(a,()=>r.children,n=>{var i=k(),a=R(i);B(a,()=>r.children??t),e(n,i)}),e(n,i)}var vt=new q(`BitsConfig`);function yt(){let e=new bt(null,{});return vt.getOr(e).opts}var bt=class{opts;constructor(e,t){let n=xt(e,t);this.opts={defaultPortalTo:n(e=>e.defaultPortalTo),defaultLocale:n(e=>e.defaultLocale)}}};function xt(e,t){return n=>Z(()=>{let r=n(t)?.current;if(r!==void 0)return r;if(e!==null)return n(e.opts)?.current})}function St(e,t){return n=>{let r=yt();return Z(()=>{let i=n();if(i!==void 0)return i;let a=e(r).current;return a===void 0?t:a})}}var Ct=St(e=>e.defaultPortalTo,`body`);function wt(n,o){r(o,!0);let s=Ct(()=>o.to),c=V(),l=S(u);function u(){if(!Ze||o.disabled)return null;let e=null;return e=typeof s.current==`string`?document.querySelector(s.current):s.current,e}let d;function p(){d&&=(A(d),null)}J([()=>m(l),()=>o.disabled],([e,t])=>{if(!e||t){p();return}return d=i(_t,{target:e,props:{children:o.children},context:c}),()=>{p()}});var h=k(),g=R(h),_=n=>{var r=k(),i=R(r);B(i,()=>o.children??t),e(n,r)};a(g,e=>{o.disabled&&e(_)}),e(n,h),f()}var Tt=class{eventName;options;constructor(e,t={bubbles:!0,cancelable:!0}){this.eventName=e,this.options=t}createEvent(e){return new CustomEvent(this.eventName,{...this.options,detail:e})}dispatch(e,t){let n=this.createEvent(t);return e.dispatchEvent(n),n}listen(e,t,n){return H(e,this.eventName,e=>{t(e)},n)}};function Et(e,t=500){let n=null,r=(...r)=>{n!==null&&clearTimeout(n),n=setTimeout(()=>{e(...r)},t)};return r.destroy=()=>{n!==null&&(clearTimeout(n),n=null)},r}function Dt(e,t){return e===t||e.contains(t)}function Ot(e){return e?.ownerDocument??document}function kt(e,t){let{clientX:n,clientY:r}=e,i=t.getBoundingClientRect();return n<i.left||n>i.right||r<i.top||r>i.bottom}var At=[`input:not([inert]):not([inert] *)`,`select:not([inert]):not([inert] *)`,`textarea:not([inert]):not([inert] *)`,`a[href]:not([inert]):not([inert] *)`,`area[href]:not([inert]):not([inert] *)`,`button:not([inert]):not([inert] *)`,`[tabindex]:not(slot):not([inert]):not([inert] *)`,`audio[controls]:not([inert]):not([inert] *)`,`video[controls]:not([inert]):not([inert] *)`,`[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`,`details>summary:first-of-type:not([inert]):not([inert] *)`,`details:not([inert]):not([inert] *)`],jt=At.join(`,`),Mt=typeof Element>`u`,Nt=Mt?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Pt=!Mt&&Element.prototype.getRootNode?function(e){return e?.getRootNode?.call(e)}:function(e){return e?.ownerDocument},Ft=function(e,t){t===void 0&&(t=!0);var n=e?.getAttribute?.call(e,`inert`);return n===``||n===`true`||t&&e&&(typeof e.closest==`function`?e.closest(`[inert]`):Ft(e.parentNode))},It=function(e){var t=e?.getAttribute?.call(e,`contenteditable`);return t===``||t===`true`},Lt=function(e,t,n){if(Ft(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(jt));return t&&Nt.call(e,jt)&&r.unshift(e),r=r.filter(n),r},Rt=function(e,t,n){for(var r=[],i=Array.from(e);i.length;){var a=i.shift();if(!Ft(a,!1)){if(a.tagName===`SLOT`){var o=a.assignedElements(),s=Rt(o.length?o:a.children,!0,n);n.flatten?r.push.apply(r,s):r.push({scopeParent:a,candidates:s})}else{Nt.call(a,jt)&&n.filter(a)&&(t||!e.includes(a))&&r.push(a);var c=a.shadowRoot||typeof n.getShadowRoot==`function`&&n.getShadowRoot(a),l=!Ft(c,!1)&&(!n.shadowRootFilter||n.shadowRootFilter(a));if(c&&l){var u=Rt(c===!0?a.children:c.children,!0,n);n.flatten?r.push.apply(r,u):r.push({scopeParent:a,candidates:u})}else i.unshift.apply(i,a.children)}}}return r},zt=function(e){return!isNaN(parseInt(e.getAttribute(`tabindex`),10))},Bt=function(e){if(!e)throw Error(`No node provided`);return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||It(e))&&!zt(e)?0:e.tabIndex},Vt=function(e,t){var n=Bt(e);return n<0&&t&&!zt(e)?0:n},Ht=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},Ut=function(e){return e.tagName===`INPUT`},Wt=function(e){return Ut(e)&&e.type===`hidden`},Gt=function(e){return e.tagName===`DETAILS`&&Array.prototype.slice.apply(e.children).some(function(e){return e.tagName===`SUMMARY`})},Kt=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},qt=function(e){if(!e.name)return!0;var t=e.form||Pt(e),n=function(e){return t.querySelectorAll(`input[type="radio"][name="`+e+`"]`)},r;if(typeof window<`u`&&window.CSS!==void 0&&typeof window.CSS.escape==`function`)r=n(window.CSS.escape(e.name));else try{r=n(e.name)}catch(e){return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`,e.message),!1}var i=Kt(r,e.form);return!i||i===e},Jt=function(e){return Ut(e)&&e.type===`radio`},Yt=function(e){return Jt(e)&&!qt(e)},Xt=function(e){var t=e&&Pt(e),n=t?.host,r=!1;if(t&&t!==e){var i,a,o;for(r=!!((i=n)!=null&&(a=i.ownerDocument)!=null&&a.contains(n)||e!=null&&(o=e.ownerDocument)!=null&&o.contains(e));!r&&n;){var s,c;t=Pt(n),n=t?.host,r=!!((s=n)!=null&&(c=s.ownerDocument)!=null&&c.contains(n))}}return r},Zt=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return n===0&&r===0},Qt=function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if(n===`full-native`&&`checkVisibility`in e)return!e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});var i=getComputedStyle(e).visibility;if(i===`hidden`||i===`collapse`)return!0;var a=Nt.call(e,`details>summary:first-of-type`)?e.parentElement:e;if(Nt.call(a,`details:not([open]) *`))return!0;if(!n||n===`full`||n===`full-native`||n===`legacy-full`){if(typeof r==`function`){for(var o=e;e;){var s=e.parentElement,c=Pt(e);if(s&&!s.shadowRoot&&r(s)===!0)return Zt(e);e=e.assignedSlot?e.assignedSlot:!s&&c!==e.ownerDocument?c.host:s}e=o}if(Xt(e))return!e.getClientRects().length;if(n!==`legacy-full`)return!0}else if(n===`non-zero-area`)return Zt(e);return!1},$t=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName===`FIELDSET`&&t.disabled){for(var n=0;n<t.children.length;n++){var r=t.children.item(n);if(r.tagName===`LEGEND`)return Nt.call(t,`fieldset[disabled] *`)?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},en=function(e,t){return!(t.disabled||Wt(t)||Qt(t,e)||Gt(t)||$t(t))},tn=function(e,t){return!(Yt(t)||Bt(t)<0||!en(e,t))},nn=function(e){var t=parseInt(e.getAttribute(`tabindex`),10);return!!(isNaN(t)||t>=0)},rn=function(e){var t=[],n=[];return e.forEach(function(e,r){var i=!!e.scopeParent,a=i?e.scopeParent:e,o=Vt(a,i),s=i?rn(e.candidates):a;o===0?i?t.push.apply(t,s):t.push(a):n.push({documentOrder:r,tabIndex:o,item:e,isScope:i,content:s})}),n.sort(Ht).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)},an=function(e,t){return t||={},rn(t.getShadowRoot?Rt([e],t.includeContainer,{filter:tn.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:nn}):Lt(e,t.includeContainer,tn.bind(null,t)))},on=function(e,t){return t||={},t.getShadowRoot?Rt([e],t.includeContainer,{filter:en.bind(null,t),flatten:!0,getShadowRoot:t.getShadowRoot}):Lt(e,t.includeContainer,en.bind(null,t))},sn=At.concat(`iframe:not([inert]):not([inert] *)`).join(`,`),cn=function(e,t){if(t||={},!e)throw Error(`No node provided`);return Nt.call(e,sn)!==!1&&en(t,e)},ln=`data-context-menu-trigger`,un=`data-context-menu-content`;new q(`Menu.Root`),new q(`Menu.Root | Menu.Sub`),new q(`Menu.Content`),new q(`Menu.Group | Menu.RadioGroup`),new q(`Menu.RadioGroup`),new q(`Menu.CheckboxGroup`),new Tt(`bitsmenuopen`,{bubbles:!1,cancelable:!0}),me({component:`menu`,parts:[`trigger`,`content`,`sub-trigger`,`item`,`group`,`group-heading`,`checkbox-group`,`checkbox-item`,`radio-group`,`radio-item`,`separator`,`sub-content`,`arrow`]}),globalThis.bitsDismissableLayers??=new Map;var dn=class e{static create(t){return new e(t)}opts;#e;#t;#n={pointerdown:!1};#r=!1;#i=!1;#a=void 0;#o;#s=G;constructor(e){this.opts=e,this.#t=e.interactOutsideBehavior,this.#e=e.onInteractOutside,this.#o=e.onFocusOutside,h(()=>{this.#a=Ot(this.opts.ref.current)});let t=G,n=null,r=!1,i=()=>{n!=null&&(clearTimeout(n),n=null)},a=()=>{i(),this.#g(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),t()};J([()=>this.opts.enabled.current,()=>this.opts.ref.current],()=>{if(!(!this.opts.enabled.current||!this.opts.ref.current))return i(),n=Le(1,()=>{n=null,!(r||!this.opts.ref.current)&&(globalThis.bitsDismissableLayers.set(this,this.#t),t(),t=this.#l())}),a}),he(()=>{r=!0,i(),this.#g.destroy(),globalThis.bitsDismissableLayers.delete(this),this.#d.destroy(),this.#s(),t()})}#c=e=>{e.defaultPrevented||this.opts.ref.current&&ue(()=>{!this.opts.ref.current||this.#h(e.target)||e.target&&!this.#i&&this.#o.current?.(e)})};#l(){return De(H(this.#a,`pointerdown`,De(this.#f,this.#m),{capture:!0}),H(this.#a,`pointerdown`,De(this.#p,this.#d)),H(this.#a,`focusin`,this.#c))}#u=e=>{let t=e;t.defaultPrevented&&(t=hn(e)),this.#e.current(e)};#d=Et(e=>{if(!this.opts.ref.current){this.#s();return}let t=this.opts.isValidEvent.current(e,this.opts.ref.current)||mn(e,this.opts.ref.current);if(!this.#r||this.#_()||!t){this.#s();return}let n=e;if(n.defaultPrevented&&(n=hn(n)),this.#t.current!==`close`&&this.#t.current!==`defer-otherwise-close`){this.#s();return}e.pointerType===`touch`?(this.#s(),this.#s=H(this.#a,`click`,this.#u,{once:!0})):this.#e.current(n)},10);#f=e=>{this.#n[e.type]=!0};#p=e=>{this.#n[e.type]=!1};#m=()=>{this.opts.ref.current&&(this.#r=pn(this.opts.ref.current))};#h=e=>this.opts.ref.current?Dt(this.opts.ref.current,e):!1;#g=Et(()=>{for(let e in this.#n)this.#n[e]=!1;this.#r=!1},20);#_(){return Object.values(this.#n).some(Boolean)}#v=()=>{this.#i=!0};#y=()=>{this.#i=!1};props={onfocuscapture:this.#v,onblurcapture:this.#y}};function fn(e=[...globalThis.bitsDismissableLayers]){return e.findLast(([e,{current:t}])=>t===`close`||t===`ignore`)}function pn(e){let t=[...globalThis.bitsDismissableLayers],n=fn(t);if(n)return n[0].opts.ref.current===e;let[r]=t[0];return r.opts.ref.current===e}function mn(e,t){let n=e.target;if(!tt(n))return!1;let r=!!n.closest(`[${ln}]`),i=!!t.closest(`[${un}]`);return`button`in e&&e.button>0&&!r?!1:`button`in e&&e.button===0&&r&&i?!0:r&&i?!1:Ot(n).documentElement.contains(n)&&!Dt(t,n)&&kt(e,t)}function hn(e){let t=e.currentTarget,n=e.target,r;r=e instanceof PointerEvent?new PointerEvent(e.type,e):new PointerEvent(`pointerdown`,e);let i=!1;return new Proxy(r,{get:(r,a)=>a===`currentTarget`?t:a===`target`?n:a===`preventDefault`?()=>{i=!0,typeof r.preventDefault==`function`&&r.preventDefault()}:a===`defaultPrevented`?i:a in r?r[a]:e[a]})}function gn(n,i){r(i,!0);let a=O(i,`interactOutsideBehavior`,3,`close`),o=O(i,`onInteractOutside`,3,G),s=O(i,`onFocusOutside`,3,G),c=O(i,`isValidEvent`,3,()=>!1),l=dn.create({id:Z(()=>i.id),interactOutsideBehavior:Z(()=>a()),onInteractOutside:Z(()=>o()),enabled:Z(()=>i.enabled),onFocusOutside:Z(()=>s()),isValidEvent:Z(()=>c()),ref:i.ref});var u=k(),d=R(u);B(d,()=>i.children??t,()=>({props:l.props})),e(n,u),f()}globalThis.bitsEscapeLayers??=new Map;var _n=class e{static create(t){return new e(t)}opts;domContext;constructor(e){this.opts=e,this.domContext=new Xe(this.opts.ref);let t=G;J(()=>e.enabled.current,n=>(n&&(globalThis.bitsEscapeLayers.set(this,e.escapeKeydownBehavior),t=this.#e()),()=>{t(),globalThis.bitsEscapeLayers.delete(this)}))}#e=()=>H(this.domContext.getDocument(),`keydown`,this.#t,{passive:!1});#t=e=>{if(e.key!==`Escape`||!vn(this))return;let t=new KeyboardEvent(e.type,e);e.preventDefault();let n=this.opts.escapeKeydownBehavior.current;(n===`close`||n===`defer-otherwise-close`)&&this.opts.onEscapeKeydown.current(t)}};function vn(e){let t=[...globalThis.bitsEscapeLayers],n=t.findLast(([e,{current:t}])=>t===`close`||t===`ignore`);if(n)return n[0]===e;let[r]=t[0];return r===e}function yn(n,i){r(i,!0);let a=O(i,`escapeKeydownBehavior`,3,`close`),o=O(i,`onEscapeKeydown`,3,G);_n.create({escapeKeydownBehavior:Z(()=>a()),onEscapeKeydown:Z(()=>o()),enabled:Z(()=>i.enabled),ref:i.ref});var s=k(),c=R(s);B(c,()=>i.children??t),e(n,s),f()}var bn=class e{static instance;#e=ye([]);#t=new WeakMap;#n=new WeakMap;static getInstance(){return this.instance||=new e,this.instance}register(e){let t=this.getActive();t&&t!==e&&t.pause();let n=document.activeElement;n&&n!==document.body&&this.#n.set(e,n),this.#e.current=this.#e.current.filter(t=>t!==e),this.#e.current.unshift(e)}unregister(e){this.#e.current=this.#e.current.filter(t=>t!==e);let t=this.getActive();t&&t.resume()}getActive(){return this.#e.current[0]}setFocusMemory(e,t){this.#t.set(e,t)}getFocusMemory(e){return this.#t.get(e)}isActiveScope(e){return this.getActive()===e}setPreFocusMemory(e,t){this.#n.set(e,t)}getPreFocusMemory(e){return this.#n.get(e)}clearPreFocusMemory(e){this.#n.delete(e)}},xn=class e{#e=!1;#t=null;#n=bn.getInstance();#r=[];#i;constructor(e){this.#i=e}get paused(){return this.#e}pause(){this.#e=!0}resume(){this.#e=!1}#a(){for(let e of this.#r)e();this.#r=[]}mount(e){this.#t&&this.unmount(),this.#t=e,this.#n.register(this),this.#c(),this.#o()}unmount(){this.#t&&=(this.#a(),this.#s(),this.#n.unregister(this),this.#n.clearPreFocusMemory(this),null)}#o(){if(!this.#t)return;let e=new CustomEvent(`focusScope.onOpenAutoFocus`,{bubbles:!1,cancelable:!0});this.#i.onOpenAutoFocus.current(e),e.defaultPrevented||requestAnimationFrame(()=>{if(!this.#t)return;let e=this.#u();e?(e.focus(),this.#n.setFocusMemory(this,e)):this.#t.focus()})}#s(){let e=new CustomEvent(`focusScope.onCloseAutoFocus`,{bubbles:!1,cancelable:!0});if(this.#i.onCloseAutoFocus.current?.(e),!e.defaultPrevented){let e=this.#n.getPreFocusMemory(this);if(e&&document.contains(e))try{e.focus()}catch{document.body.focus()}}}#c(){if(!this.#t||!this.#i.trap.current)return;let e=this.#t,t=e.ownerDocument;this.#r.push(H(t,`focusin`,t=>{if(this.#e||!this.#n.isActiveScope(this))return;let n=t.target;if(n){if(e.contains(n))this.#n.setFocusMemory(this,n);else{let n=this.#n.getFocusMemory(this);if(n&&e.contains(n)&&cn(n))t.preventDefault(),n.focus();else{let t=this.#u(),n=this.#d()[0];(t||n||e).focus()}}}},{capture:!0}),H(e,`keydown`,e=>{if(!this.#i.loop||this.#e||e.key!==`Tab`||!this.#n.isActiveScope(this))return;let n=this.#l();if(n.length===0)return;let r=n[0],i=n[n.length-1];!e.shiftKey&&t.activeElement===i?(e.preventDefault(),r.focus()):e.shiftKey&&t.activeElement===r&&(e.preventDefault(),i.focus())}));let n=new MutationObserver(()=>{let t=this.#n.getFocusMemory(this);if(t&&!e.contains(t)){let t=this.#u(),n=this.#d()[0],r=t||n;r?(r.focus(),this.#n.setFocusMemory(this,r)):e.focus()}});n.observe(e,{childList:!0,subtree:!0}),this.#r.push(()=>n.disconnect())}#l(){return this.#t?an(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}#u(){return this.#l()[0]||null}#d(){return this.#t?on(this.#t,{includeContainer:!1,getShadowRoot:!0}):[]}static use(t){let n=null;return J([()=>t.ref.current,()=>t.enabled.current],([r,i])=>{r&&i?(n||=new e(t),n.mount(r)):n&&=(n.unmount(),null)}),he(()=>{n?.unmount()}),{get props(){return{tabindex:-1}}}}};function Sn(n,i){r(i,!0);let a=O(i,`enabled`,3,!1),o=O(i,`trapFocus`,3,!1),s=O(i,`loop`,3,!1),c=O(i,`onCloseAutoFocus`,3,G),l=O(i,`onOpenAutoFocus`,3,G),u=xn.use({enabled:Z(()=>a()),trap:Z(()=>o()),loop:s(),onCloseAutoFocus:Z(()=>c()),onOpenAutoFocus:Z(()=>l()),ref:i.ref});var d=k(),p=R(d);B(p,()=>i.focusScope??t,()=>({props:u.props})),e(n,d),f()}var Cn=()=>{};globalThis.bitsTextSelectionLayers??=new Map;var wn=class e{static create(t){return new e(t)}opts;domContext;#e=G;#t=!1;#n=Cn;#r=Cn;constructor(e){this.opts=e,this.domContext=new Xe(e.ref);let t=G;J(()=>[this.opts.enabled.current,this.opts.onPointerDown.current,this.opts.onPointerUp.current],([e,n,r])=>(this.#t=e,this.#n=n,this.#r=r,e&&(globalThis.bitsTextSelectionLayers.set(this,this.opts.enabled),t(),t=this.#i()),()=>{this.#t=!1,t(),this.#s(),globalThis.bitsTextSelectionLayers.delete(this)}))}#i(){return De(H(this.domContext.getDocument(),`pointerdown`,this.#o),H(this.domContext.getDocument(),`pointerup`,Ae(this.#s,this.#a)))}#a=e=>{this.#r(e)};#o=e=>{if(!this.#t)return;let t=this.opts.ref.current,n=e.target;!et(t)||!et(n)||!On(this)||!Ke(t,n)||(this.#n(e),!e.defaultPrevented&&(this.#e=En(t,this.domContext.getDocument().body)))};#s=()=>{this.#e(),this.#e=G}},Tn=e=>e.style.userSelect||e.style.webkitUserSelect;function En(e,t){let n=Tn(t),r=Tn(e);return Dn(t,`none`),Dn(e,`text`),()=>{Dn(t,n),Dn(e,r)}}function Dn(e,t){e.style.userSelect=t,e.style.webkitUserSelect=t}function On(e){let t=[...globalThis.bitsTextSelectionLayers];if(!t.length)return!1;let n=t.at(-1);return n?n[0]===e:!1}function kn(n,i){r(i,!0);let a=O(i,`preventOverflowTextSelection`,3,!0),o=O(i,`onPointerDown`,3,G),s=O(i,`onPointerUp`,3,G);wn.create({id:Z(()=>i.id),onPointerDown:Z(()=>o()),onPointerUp:Z(()=>s()),enabled:Z(()=>i.enabled&&a()),ref:i.ref});var c=k(),l=R(c);B(l,()=>i.children??t),e(n,c),f()}globalThis.bitsIdCounter??={current:0};function An(e=`bits`){return globalThis.bitsIdCounter.current++,`${e}-${globalThis.bitsIdCounter.current}`}var jn=class{#e;#t=0;#n=L();#r;constructor(e){this.#e=e}#i(){--this.#t,this.#r&&this.#t<=0&&(this.#r(),b(this.#n,void 0),this.#r=void 0)}get(...e){return this.#t+=1,m(this.#n)===void 0&&(this.#r=s(()=>{b(this.#n,this.#e(...e),!0)})),h(()=>()=>{this.#i()}),m(this.#n)}},Mn=new ae,Nn=L(null),Pn=null,Fn=null,In=!1,Ln=Z(()=>{for(let e of Mn.values())if(e)return!0;return!1}),Rn=null,zn=new jn(()=>{function e(){document.body.setAttribute(`style`,m(Nn)??``),document.body.style.removeProperty(`--scrollbar-width`),Qe&&Pn?.(),b(Nn,null)}function t(){Fn!==null&&(window.clearTimeout(Fn),Fn=null)}function n(e,n){t(),In=!0,Rn=Date.now();let r=Rn,i=()=>{Fn=null,Rn===r&&(Vn(Mn)?In=!1:(In=!1,n()))},a=e===null?24:e;Fn=window.setTimeout(i,a)}function r(){m(Nn)===null&&Mn.size===0&&!In&&b(Nn,document.body.getAttribute(`style`),!0)}return J(()=>Ln.current,()=>{if(!Ln.current)return;r(),In=!1;let e=getComputedStyle(document.documentElement),t=getComputedStyle(document.body),n=e.scrollbarGutter?.includes(`stable`)||t.scrollbarGutter?.includes(`stable`),i=window.innerWidth-document.documentElement.clientWidth,a={padding:Number.parseInt(t.paddingRight??`0`,10)+i,margin:Number.parseInt(t.marginRight??`0`,10)};i>0&&!n&&(document.body.style.paddingRight=`${a.padding}px`,document.body.style.marginRight=`${a.margin}px`,document.body.style.setProperty(`--scrollbar-width`,`${i}px`)),document.body.style.overflow=`hidden`,Qe&&(Pn=H(document,`touchmove`,e=>{e.target===document.documentElement&&(e.touches.length>1||e.preventDefault())},{passive:!1})),ue(()=>{document.body.style.pointerEvents=`none`,document.body.style.overflow=`hidden`})}),he(()=>()=>{Pn?.()}),{get lockMap(){return Mn},resetBodyStyle:e,scheduleCleanupIfNoNewLocks:n,cancelPendingCleanup:t,ensureInitialStyleCaptured:r}}),Bn=class{#e=An();#t;#n=()=>null;#r;locked;constructor(e,t=()=>null){this.#t=e,this.#n=t,this.#r=zn.get(),this.#r&&(this.#r.cancelPendingCleanup(),this.#r.ensureInitialStyleCaptured(),this.#r.lockMap.set(this.#e,this.#t??!1),this.locked=Z(()=>this.#r.lockMap.get(this.#e)??!1,e=>this.#r.lockMap.set(this.#e,e)),he(()=>{if(this.#r.lockMap.delete(this.#e),Vn(this.#r.lockMap))return;let e=this.#n();this.#r.scheduleCleanupIfNoNewLocks(e,()=>{this.#r.resetBodyStyle()})}))}};function Vn(e){for(let[t,n]of e)if(n)return!0;return!1}function Hn(e,t){r(t,!0);let n=O(t,`preventScroll`,3,!0),i=O(t,`restoreScrollDelay`,3,null);n()&&new Bn(n(),()=>i()),f()}var Un=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`children`,`child`,`ref`,`forceMount`,`interactOutsideBehavior`,`onCloseAutoFocus`,`onEscapeKeydown`,`onOpenAutoFocus`,`onInteractOutside`,`preventScroll`,`trapFocus`,`restoreScrollDelay`]),Wn=c(`<!> <!>`,1),Gn=c(`<!> <div><!></div>`,1);function Kn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`forceMount`,3,!1),u=O(i,`interactOutsideBehavior`,3,`ignore`),p=O(i,`onCloseAutoFocus`,3,G),h=O(i,`onEscapeKeydown`,3,G),g=O(i,`onOpenAutoFocus`,3,G),_=O(i,`onInteractOutside`,3,G),v=O(i,`preventScroll`,3,!0),b=O(i,`trapFocus`,3,!0),x=O(i,`restoreScrollDelay`,3,null),w=y(i,Un),E=st.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),D=S(()=>Q(w,E.props));var A=k(),M=R(A),ee=n=>{Sn(n,{get ref(){return E.opts.ref},loop:!0,get trapFocus(){return b()},get enabled(){return E.root.opts.open.current},get onCloseAutoFocus(){return p()},onOpenAutoFocus:e=>{g()(e),!e.defaultPrevented&&(e.preventDefault(),Le(0,()=>E.opts.ref.current?.focus()))},focusScope:(n,r)=>{let o=()=>(r?.()).props;yn(n,F(()=>m(D),{get enabled(){return E.root.opts.open.current},get ref(){return E.opts.ref},onEscapeKeydown:e=>{h()(e),!e.defaultPrevented&&E.root.handleClose()},children:(n,r)=>{gn(n,F(()=>m(D),{get ref(){return E.opts.ref},get enabled(){return E.root.opts.open.current},get interactOutsideBehavior(){return u()},onInteractOutside:e=>{_()(e),!e.defaultPrevented&&E.root.handleClose()},children:(n,r)=>{kn(n,F(()=>m(D),{get ref(){return E.opts.ref},get enabled(){return E.root.opts.open.current},children:(n,r)=>{var s=k(),c=R(s),l=t=>{var n=Wn(),r=R(n),s=e=>{Hn(e,{get preventScroll(){return v()},get restoreScrollDelay(){return x()}})};a(r,e=>{E.root.opts.open.current&&e(s)});var c=P(r,2);{let e=S(()=>({props:Q(m(D),o()),...E.snippetProps}));B(c,()=>i.child,()=>m(e))}e(t,n)},u=n=>{var r=Gn(),a=R(r);Hn(a,{get preventScroll(){return v()}});var s=P(a,2);C(s,e=>({...e}),[()=>Q(m(D),o())]);var c=T(s);B(c,()=>i.children??t),j(s),e(n,r)};a(c,e=>{i.child?e(l):e(u,-1)}),e(n,s)},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{default:!0}}))},$$slots:{focusScope:!0}})};a(M,e=>{(E.shouldRender||l())&&e(ee)}),e(n,A),f()}var qn=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`forceMount`,`child`,`children`,`ref`]),Jn=c(`<div><!></div>`);function Yn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`forceMount`,3,!1),l=O(i,`ref`,15,null),u=y(i,qn),p=ct.create({id:Z(()=>s()),ref:Z(()=>l(),e=>l(e))}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=n=>{var r=k(),o=R(r),s=t=>{var n=k(),r=R(n);{let e=S(()=>({props:Q(m(h)),...p.snippetProps}));B(r,()=>i.child,()=>m(e))}e(t,n)},c=n=>{var r=Jn();C(r,e=>({...e}),[()=>Q(m(h))]);var a=T(r);B(a,()=>i.children??t,()=>p.snippetProps),j(r),e(n,r)};a(o,e=>{i.child?e(s):e(c,-1)}),e(n,r)};a(_,e=>{(p.shouldRender||c())&&e(v)}),e(n,g),f()}var Xn=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`ref`,`children`,`child`,`disabled`]),Zn=c(`<button><!></button>`);function Qn(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=O(i,`disabled`,3,!1),u=y(i,Xn),p=it.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e)),disabled:Z(()=>!!l())}),h=S(()=>Q(u,p.props));var g=k(),_=R(g),v=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(h)})),e(t,n)},b=n=>{var r=Zn();C(r,()=>({...m(h)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(_,e=>{i.child?e(v):e(b,-1)}),e(n,g),f()}var $n=new Set([`$$slots`,`$$events`,`$$legacy`,`id`,`children`,`child`,`ref`]),er=c(`<div><!></div>`);function tr(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=y(i,$n),u=ot.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),p=S(()=>Q(l,u.props));var h=k(),g=R(h),_=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(p)})),e(t,n)},v=n=>{var r=er();C(r,()=>({...m(p)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(g,e=>{i.child?e(_):e(v,-1)}),e(n,h),f()}var nr=me({component:`label`,parts:[`root`]}),rr=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=X(this.opts.ref),this.onmousedown=this.onmousedown.bind(this)}onmousedown(e){e.detail>1&&e.preventDefault()}#e=S(()=>({id:this.opts.id.current,[nr.root]:``,onmousedown:this.onmousedown,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}},ir=new Set([`$$slots`,`$$events`,`$$legacy`,`children`,`child`,`id`,`ref`,`for`]),ar=c(`<label><!></label>`);function or(n,i){let o=d();r(i,!0);let s=O(i,`id`,19,()=>Y(o)),c=O(i,`ref`,15,null),l=y(i,ir),u=rr.create({id:Z(()=>s()),ref:Z(()=>c(),e=>c(e))}),p=S(()=>Q(l,u.props,{for:i.for}));var h=k(),g=R(h),_=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(p)})),e(t,n)},v=n=>{var r=ar();C(r,()=>({...m(p),for:i.for}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(g,e=>{i.child?e(_):e(v,-1)}),e(n,h),f()}var sr=me({component:`progress`,parts:[`root`]}),cr=class e{static create(t){return new e(t)}opts;attachment;constructor(e){this.opts=e,this.attachment=X(this.opts.ref)}#e=S(()=>({role:`progressbar`,value:this.opts.value.current,"aria-valuemin":this.opts.min.current,"aria-valuemax":this.opts.max.current,"aria-valuenow":this.opts.value.current===null?void 0:this.opts.value.current,"data-value":this.opts.value.current===null?void 0:this.opts.value.current,"data-state":lr(this.opts.value.current,this.opts.max.current),"data-max":this.opts.max.current,"data-min":this.opts.min.current,"data-indeterminate":this.opts.value.current===null?``:void 0,[sr.root]:``,...this.attachment}));get props(){return m(this.#e)}set props(e){b(this.#e,e)}};function lr(e,t){return e===null?`indeterminate`:e===t?`loaded`:`loading`}var ur=new Set([`$$slots`,`$$events`,`$$legacy`,`child`,`children`,`value`,`max`,`min`,`id`,`ref`]),dr=c(`<div><!></div>`);function fr(n,i){let o=d();r(i,!0);let s=O(i,`value`,3,0),c=O(i,`max`,3,100),l=O(i,`min`,3,0),u=O(i,`id`,19,()=>Y(o)),p=O(i,`ref`,15,null),h=y(i,ur),g=cr.create({value:Z(()=>s()),max:Z(()=>c()),min:Z(()=>l()),id:Z(()=>u()),ref:Z(()=>p(),e=>p(e))}),_=S(()=>Q(h,g.props));var v=k(),b=R(v),x=t=>{var n=k(),r=R(n);B(r,()=>i.child,()=>({props:m(_)})),e(t,n)},w=n=>{var r=dr();C(r,()=>({...m(_)}));var a=T(r);B(a,()=>i.children??t),j(r),e(n,r)};a(b,e=>{i.child?e(x):e(w,-1)}),e(n,v),f()}var pr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function mr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,pr);var o=k(),s=R(o);{let e=S(()=>K(`gap-2 text-sm leading-none font-medium group-data-[disabled=true]:opacity-50 peer-disabled:opacity-50 flex items-center select-none group-data-[disabled=true]:pointer-events-none peer-disabled:cursor-not-allowed`,n.class));x(s,()=>or,(t,n)=>{n(t,F({"data-slot":`label`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var hr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`value`,`type`,`files`,`class`,`data-slot`]),gr=c(`<input/>`);function _r(t,n){r(n,!0);let i=O(n,`ref`,15,null),o=O(n,`value`,15),s=O(n,`files`,15),c=O(n,`data-slot`,3,`input`),l=y(n,hr);var u=k(),d=R(u),p=t=>{var r=gr();C(r,e=>({"data-slot":c(),class:e,type:`file`,...l}),[()=>K(`h-8 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors file:h-6 file:text-sm file:font-medium focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:bg-input/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,n.class)],void 0,void 0,void 0,!0),I(r,e=>i(e),()=>i()),M(r,s),z(r,o),e(t,r)},m=t=>{var r=gr();C(r,e=>({"data-slot":c(),class:e,type:n.type,...l}),[()=>K(`h-8 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors file:h-6 file:text-sm file:font-medium focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:bg-input/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent file:text-foreground placeholder:text-muted-foreground disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,n.class)],void 0,void 0,void 0,!0),I(r,e=>i(e),()=>i()),z(r,o),e(t,r)};a(d,e=>{n.type===`file`?e(p):e(m,-1)}),e(t,u),f()}var vr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`variant`,`size`]);function yr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`variant`,3,`outline`),o=O(n,`size`,3,`default`),s=y(n,vr);var c=k(),l=R(c);{let e=S(()=>K(se({variant:a(),size:o()}),`cn-alert-dialog-cancel`,n.class));x(l,()=>gt,(t,n)=>{n(t,F({"data-slot":`alert-dialog-cancel`,get class(){return m(e)}},()=>s,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,c),f()}var br=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function xr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,br);var o=k(),s=R(o);{let e=S(()=>K(`bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0 fixed inset-0 z-50`,n.class));x(s,()=>Yn,(t,n)=>{n(t,F({"data-slot":`alert-dialog-overlay`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var Sr=new Set([`$$slots`,`$$events`,`$$legacy`]);function Cr(t,n){let r=y(n,Sr);var i=k(),a=R(i);x(a,()=>wt,(e,t)=>{t(e,F(()=>r))}),e(t,i)}var wr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`size`,`portalProps`]),Tr=c(`<!> <!>`,1);function Er(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`size`,3,`default`),o=y(n,wr);Cr(t,F(()=>n.portalProps,{children:(t,r)=>{var s=Tr(),c=R(s);xr(c,{});var l=P(c,2);{let e=S(()=>K(`gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 outline-none`,n.class));x(l,()=>Kn,(t,n)=>{n(t,F({"data-slot":`alert-dialog-content`,get"data-size"(){return a()},get class(){return m(e)}},()=>o,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,s)},$$slots:{default:!0}})),f()}var Dr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function Or(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Dr);var o=k(),s=R(o);{let e=S(()=>K(`text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,n.class));x(s,()=>tr,(t,n)=>{n(t,F({"data-slot":`alert-dialog-description`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var kr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`children`]),Ar=c(`<div><!></div>`);function jr(n,i){r(i,!0);let a=O(i,`ref`,15,null),o=y(i,kr);var s=Ar();C(s,e=>({"data-slot":`alert-dialog-footer`,class:e,...o}),[()=>K(`-mx-4 -mb-4 rounded-b-xl border-t bg-muted/50 p-4 flex flex-col-reverse gap-2 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end`,i.class)]);var c=T(s);B(c,()=>i.children??t),j(s),I(s,e=>a(e),()=>a()),e(n,s),f()}var Mr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`children`]),Nr=c(`<div><!></div>`);function Pr(n,i){r(i,!0);let a=O(i,`ref`,15,null),o=y(i,Mr);var s=Nr();C(s,e=>({"data-slot":`alert-dialog-header`,class:e,...o}),[()=>K(`grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]`,i.class)]);var c=T(s);B(c,()=>i.children??t),j(s),I(s,e=>a(e),()=>a()),e(n,s),f()}var Fr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`]);function Ir(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Fr);var o=k(),s=R(o);{let e=S(()=>K(`text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2`,n.class));x(s,()=>pt,(t,n)=>{n(t,F({"data-slot":`alert-dialog-title`,get class(){return m(e)}},()=>a,{get ref(){return i()},set ref(e){i(e)}}))})}e(t,o),f()}var Lr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`]);function Rr(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=y(n,Lr);var o=k(),s=R(o);x(s,()=>Qn,(e,t)=>{t(e,F({"data-slot":`alert-dialog-trigger`},()=>a,{get ref(){return i()},set ref(e){i(e)}}))}),e(t,o),f()}var zr=new Set([`$$slots`,`$$events`,`$$legacy`,`open`]);function Br(t,n){r(n,!0);let i=O(n,`open`,15,!1),a=y(n,zr);var o=k(),s=R(o);x(s,()=>ut,(e,t)=>{t(e,F(()=>a,{get open(){return i()},set open(e){i(e)}}))}),e(t,o),f()}var Vr=new Set([`$$slots`,`$$events`,`$$legacy`,`ref`,`class`,`max`,`value`]),Hr=c(`<div data-slot="progress-indicator" class="bg-primary size-full flex-1 transition-all"></div>`);function Ur(t,n){r(n,!0);let i=O(n,`ref`,15,null),a=O(n,`max`,3,100),o=y(n,Vr);var s=k(),c=R(s);{let t=S(()=>K(`h-1 rounded-full bg-muted relative flex w-full items-center overflow-x-hidden`,n.class));x(c,()=>fr,(r,s)=>{s(r,F({"data-slot":`progress`,get class(){return m(t)},get value(){return n.value},get max(){return a()}},()=>o,{get ref(){return i()},set ref(e){i(e)},children:(t,r)=>{var i=Hr();g(()=>te(i,`transform: translateX(-${100-100*(n.value??0)/(a()??1)}%)`)),e(t,i)},$$slots:{default:!0}}))})}e(t,s),f()}var Wr=new Set([`$$slots`,`$$events`,`$$legacy`,`name`,`duration`,`label`,`variant`,`children`,`position`,`align`,`portal`,`onclick`,`onpress`,`class`,`message`]),Gr=c(`<div><div class="text-xs text-muted-foreground"><!></div> <!></div>`),Kr=c(`<!> <!>`,1);function qr(n,i){r(i,!0);let s=()=>E(m(U),`$countdown`,c),[c,u]=w(),d=O(i,`name`,3,`hold`),p=O(i,`duration`,3,800),x=O(i,`variant`,3,`ghost`),C=O(i,`position`,3,`left`),A=O(i,`align`,3,`center`),M=O(i,`portal`,3,!0),I=y(i,Wr),z=L(!1),V=L(!1),H=L(null),U=L(ne(v(p()))),W=S(()=>Math.round((1-s()/p())*100));h(()=>{s()===0&&se()});function ie(e){ce(e),e.altKey?se(!0):G()}function ae(e){e.key===` `&&G()}function G(){m(z)||(i.onpress?.(),b(z,!0),b(V,!0),N(b(U,re(p(),60),!0),`$countdown`,c),m(H)&&clearTimeout(m(H)))}function oe(){m(z)&&(b(H,setTimeout(()=>{b(V,!1)},m(W)>20?200:1e3),!0),b(z,!1),N(b(U,v(p()),!0),`$countdown`,c))}function se(e=!1){!m(z)&&!e||(i.onclick?.(),b(z,!1),b(H,setTimeout(()=>{b(V,!1),N(b(U,v(p()),!0),`$countdown`,c)},300),!0))}function ce(e){e.preventDefault(),e.stopPropagation()}function le(e,t){if(t)return document.body.appendChild(e),{destroy:()=>e.remove()}}var ue=Kr(),de=R(ue);{let n=S(()=>K(`select-none`,i.class)),r=S(()=>`anchor-name: --${d()};`);fe(de,F({get variant(){return x()}},()=>I,{get class(){return m(n)},onpointerdown:ie,onkeydown:ae,oncontextmenu:ce,onpointerup:oe,onpointerleave:oe,onkeyup:oe,get style(){return m(r)},children:(n,r)=>{var a=k(),o=R(a);B(o,()=>i.children??t),e(n,a)},$$slots:{default:!0}}))}var q=P(de,2),pe=t=>{var n=Gr(),r=T(n),s=T(r),c=t=>{var n=k(),r=R(n);B(r,()=>i.message),e(t,n)},u=t=>{var n=o();g(()=>l(n,i.label)),e(t,n)};a(s,e=>{i.message?e(c):e(u,-1)}),j(r),Ur(P(r,2),{get value(){return m(W)},class:`h-1 [&_div[data-slot=progress-indicator]]:bg-destructive/90 [&_div[data-slot=progress-indicator]]:transition-none`}),j(n),_(n,(e,t)=>le?.(e,t),M),g(e=>{ee(n,1,e),te(n,`position-anchor: --${d()}; position-area: ${C()} ${A()};`)},[()=>D(K(`fixed z-1002 w-fit min-w-26 transition-all ease-in-out space-y-1`,`bg-background/85 p-2 pt-1 rounded-md`,`starting:scale-0`))]),e(t,n)};a(q,e=>{m(V)&&e(pe)}),e(n,ue),f(),u()}var Jr=7e3,Yr=c(`<!> `,1),Xr=c(`<!> <!>`,1),Zr=c(`<p id="introspection-halt-error" class="text-destructive text-sm"> </p>`),Qr=c(` <!>`,1),$r=c(`<!> <div class="grid grid-cols-2 gap-4"><div class="flex flex-col gap-1.5"><!> <!> <p id="introspection-halt-hint"> </p></div> <div class="flex flex-col gap-1.5"><!> <!> <p id="introspection-halt-quiescence-hint"> </p></div></div> <!> <!>`,1);function ei(t,n){r(n,!0);let i=()=>E(Ce,`$configuration`,c),s=()=>E(ie,`$dict`,c),[c,d]=w(),p=S(()=>Pe(i())?i().halt??null:null),h=L(!1),_=L(ne({})),v=L(null),y=L(!1),C=L(!1),O=null,A=S(()=>m(_).duration??(m(p)===null?void 0:ae(600,m(p).duration))),M=S(()=>m(_).quiescence??(m(p)===null?void 0:ae(60,m(p).quiescence))),N=S(()=>m(p)!==null&&re(m(A),m(p).duration)),F=S(()=>m(p)!==null&&re(m(M),m(p).quiescence)),te=S(()=>m(N)&&m(F)),I=S(()=>m(v)!==null);function z(e){U(),b(C,!1),b(_,{},!0)}function B(){!m(te)||m(I)||(b(C,!1),b(v,9,!0),O=setInterval(V,1e3))}function V(){m(v)!==null&&(b(v,m(v)-1),!(m(v)>0)&&(W(),b(y,!0),H()))}async function H(){let e=await Ee(m(A),m(M));b(y,!1),b(C,e instanceof Error),m(C)?U():b(h,!1)}function U(){W(),b(v,null),b(y,!1)}function W(){O!==null&&clearInterval(O),O=null}function re(e,[t,n]){return e!==void 0&&Number.isInteger(e)&&e>=t&&e<=n}function ae(e,[t,n]){return Math.min(n,Math.max(t,e))}var G=k(),oe=R(G),ce=t=>{var n=k(),r=R(n);x(r,()=>Br,(t,n)=>{n(t,{onOpenChange:z,get open(){return m(h)},set open(e){b(h,e,!0)},children:(t,n)=>{var r=Xr(),i=R(r);{let t=S(()=>[se({variant:`ghost`}),`text-destructive hover:text-destructive`]);x(i,()=>Rr,(n,r)=>{r(n,{id:`introspection-halt-button`,get class(){return m(t)},children:(t,n)=>{var r=Yr(),i=R(r);Ie(i,{});var a=P(i);g(()=>l(a,` ${s().nav.halt??``}`)),e(t,r)},$$slots:{default:!0}})})}var c=P(i,2);x(c,()=>Er,(t,n)=>{n(t,{children:(t,n)=>{var r=$r(),i=R(r);x(i,()=>Pr,(t,n)=>{n(t,{children:(t,n)=>{var r=Xr(),i=R(r);x(i,()=>Ir,(t,n)=>{n(t,{children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.title)),e(t,r)},$$slots:{default:!0}})});var a=P(i,2);x(a,()=>Or,(t,n)=>{n(t,{children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.description)),e(t,r)},$$slots:{default:!0}})}),e(t,r)},$$slots:{default:!0}})});var c=P(i,2),d=T(c),f=T(d);mr(f,{for:`introspection-halt-input`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.interval)),e(t,r)},$$slots:{default:!0}});var h=P(f,2),b=()=>m(A),w=e=>m(_).duration=e;{let e=S(()=>!m(N));_r(h,{id:`introspection-halt-input`,type:`number`,inputmode:`numeric`,get min(){return m(p).duration[0]},get max(){return m(p).duration[1]},step:`1`,get disabled(){return m(I)},get value(){return b()},set value(e){w(e)},get"aria-invalid"(){return m(e)},"aria-describedby":`introspection-halt-hint`})}var E=P(h,2),O=T(E,!0);j(E),j(d);var ne=P(d,2),L=T(ne);mr(L,{for:`introspection-halt-quiescence-input`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.quiescence)),e(t,r)},$$slots:{default:!0}});var z=P(L,2),V=()=>m(M),H=e=>m(_).quiescence=e;{let e=S(()=>!m(F));_r(z,{id:`introspection-halt-quiescence-input`,type:`number`,inputmode:`numeric`,get min(){return m(p).quiescence[0]},get max(){return m(p).quiescence[1]},step:`1`,get disabled(){return m(I)},get value(){return V()},set value(e){H(e)},get"aria-invalid"(){return m(e)},"aria-describedby":`introspection-halt-quiescence-hint`})}var W=P(z,2),re=T(W,!0);j(W),j(ne),j(c);var ie=P(c,2),ae=t=>{var n=Zr(),r=T(n,!0);j(n),g(()=>l(r,s().halt.failed)),e(t,n)};a(ie,e=>{m(C)&&e(ae)});var G=P(ie,2);x(G,()=>jr,(t,n)=>{n(t,{children:(t,n)=>{var r=Xr(),i=R(r),c=t=>{fe(t,{id:`introspection-halt-cancel-button`,variant:`outline`,get disabled(){return m(y)},onclick:U,children:(t,n)=>{u();var r=Qr(),i=R(r),a=P(i);Ne(a,{id:`introspection-halt-countdown`,variant:`destructive`,class:`tabular-nums`,children:(t,n)=>{u();var r=o();g(()=>l(r,m(v))),e(t,r)},$$slots:{default:!0}}),g(()=>l(i,`${s().halt.cancel??``} `)),e(t,r)},$$slots:{default:!0}})},d=t=>{var n=k(),r=R(n);x(r,()=>yr,(t,n)=>{n(t,{id:`introspection-halt-cancel-button`,children:(t,n)=>{u();var r=o();g(()=>l(r,s().halt.cancel)),e(t,r)},$$slots:{default:!0}})}),e(t,n)};a(i,e=>{m(I)?e(c):e(d,-1)});var f=P(i,2);{let t=S(()=>!m(te)||m(I));qr(f,{id:`introspection-halt-confirm-button`,variant:`destructive`,portal:!1,position:`top`,get duration(){return Jr},get label(){return s().halt.hold},get disabled(){return m(t)},onclick:B,children:(t,n)=>{u();var r=o();g(()=>l(r,s().nav.halt)),e(t,r)},$$slots:{default:!0}})}e(t,r)},$$slots:{default:!0}})}),g((e,t)=>{ee(E,1,D([`text-xs`,m(N)?`text-muted-foreground`:`text-destructive`])),l(O,e),ee(W,1,D([`text-xs`,m(F)?`text-muted-foreground`:`text-destructive`])),l(re,t)},[()=>s().halt.bounds(m(p).duration[0],m(p).duration[1]),()=>s().halt.bounds(m(p).quiescence[0],m(p).quiescence[1])]),e(t,r)},$$slots:{default:!0}})}),e(t,r)},$$slots:{default:!0}})}),e(t,n)};a(oe,e=>{m(p)!==null&&e(ce)}),e(t,G),f(),d()}var ti=new Set([`$$slots`,`$$events`,`$$legacy`,`class`]),ni=c(`<p class="text-muted-foreground py-20 text-center"> </p>`),ri=c(`<section class="flex flex-col gap-2"><div class="text-muted-foreground flex items-center gap-3"><span class="text-xs font-medium tracking-wide uppercase"> </span> <!></div> <!></section>`),ii=c(`<div></div>`);function ai(t,i){r(i,!0);let o=()=>E(ge,`$nodes`,u),s=()=>E(Oe,`$query`,u),c=()=>E(ve,`$dict`,u),[u,d]=w(),p=y(i,ti),_=new be,v=S(()=>Pe(o())?o():[]),b=S(()=>m(v).map(e=>({node:e,rank:Te(e,s())})).filter(e=>e.rank>0).sort(D));h(()=>{let e=m(b).length===1?Me(m(b)[0].node):null;return xe.set(e===null?null:()=>_.add(e)),()=>xe.set(null)});function D(e,t){return t.rank-e.rank||e.node.namespace.localeCompare(t.node.namespace)||e.node.component.localeCompare(t.node.component)}function O(e){return[{id:`user`,label:c().space.user,of:e.filter(e=>!Se(e.node))},{id:`system`,label:c().space.system,of:e.filter(e=>Se(e.node))}].filter(e=>e.of.length>0)}W(t,{get store(){return ge},awaited:t=>{var r=k(),o=R(r),s=t=>{var n=ni(),r=T(n,!0);j(n),g(()=>l(r,c().nodes.empty)),e(t,n)},u=t=>{var n=ni(),r=T(n,!0);j(n),g(()=>l(r,c().nodes.nomatch)),e(t,n)},d=t=>{var r=ii();C(r,()=>({class:[`flex flex-col gap-6`,i.class],...p})),n(r,21,()=>O(m(b)),e=>e.id,(t,r)=>{var i=ri(),a=T(i),o=T(a),s=T(o,!0);j(o);var c=P(o,2);oe(c,{class:`flex-1`}),j(a);var u=P(a,2);x(u,()=>_e,(t,i)=>{i(t,{class:`gap-2`,children:(t,i)=>{var a=k(),o=R(a);n(o,17,()=>m(r).of,e=>e.node.id,(e,t)=>{let n=S(()=>Me(m(t).node));var r=()=>_.has(m(n)),i=e=>e?_.add(m(n)):_.delete(m(n));je(e,{get node(){return m(t).node},get open(){return r()},set open(e){i(e)}})}),e(t,a)},$$slots:{default:!0}})}),j(i),g(()=>l(s,m(r).label)),e(t,i)}),j(r),e(t,r)};a(o,e=>{m(v).length===0?e(s):m(b).length===0?e(u,1):e(d,-1)}),e(t,r)},$$slots:{awaited:!0}}),f(),d()}export{Xe as a,et as i,ei as n,Je as o,_r as r,ai as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{H as e,U as t,V as n,at as r,n as i,st as a,t as o,vt as s}from"./sTot5bBi.js";import{t as c}from"./CMJYA4Le.js";var l=class{constructor(e,t){this.status=e,this.body=typeof t==`string`?{message:t}:t||{message:`Error: ${e}`}}toString(){return JSON.stringify(this.body)}},u=class{constructor(e,t){try{new Headers({location:t})}catch{throw Error(`Invalid redirect location ${JSON.stringify(t)}: this string contains characters that cannot be used in HTTP headers`)}this.status=e,this.location=t}},d=class extends Error{constructor(e,t,n){super(n),this.status=e,this.text=t}};new URL(`sveltekit-internal://`);function f(e,t){return e===`/`||t===`ignore`?e:t===`never`?e.endsWith(`/`)?e.slice(0,-1):e:t===`always`&&!e.endsWith(`/`)?e+`/`:e}function p(e){return e.split(`%25`).map(decodeURI).join(`%25`)}function ee(e){for(let t in e)e[t]=decodeURIComponent(e[t]);return e}function m({href:e}){return e.split(`#`)[0]}function h(){}function g(...e){let t=5381;for(let n of e)if(typeof n==`string`){let e=n.length;for(;e;)t=t*33^n.charCodeAt(--e)}else if(ArrayBuffer.isView(n)){let e=new Uint8Array(n.buffer,n.byteOffset,n.byteLength),r=e.length;for(;r;)t=t*33^e[--r]}else throw TypeError(`value must be a string or TypedArray`);return(t>>>0).toString(36)}new TextEncoder;function _(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}var te=window.fetch;window.fetch=(e,t)=>((e instanceof Request?e.method:t?.method||`GET`)!==`GET`&&v.delete(b(e)),te(e,t));var v=new Map;function y(e,t){let n=b(e,t),r=document.querySelector(n);if(r?.textContent){r.remove();let{body:e,...t}=JSON.parse(r.textContent);r.getAttribute(`data-b64`)!==null&&(e=_(e));let i=r.getAttribute(`data-ttl`);return i&&v.set(n,{body:e,init:t,ttl:1e3*Number(i)}),Promise.resolve(new Response(e,t))}return window.fetch(e,t)}function ne(e,t,n){if(v.size>0){let t=b(e,n),r=v.get(t);if(r){if(performance.now()<r.ttl&&[`default`,`force-cache`,`only-if-cached`,void 0].includes(n?.cache))return new Response(r.body,r.init);v.delete(t)}}return window.fetch(t,n)}function b(e,t){let n=`script[data-sveltekit-fetched][data-url=${JSON.stringify(e instanceof Request?e.url:e)}]`;if(t?.headers||t?.body){let e=[];t.headers&&e.push([...new Headers(t.headers)].join(`,`)),t.body&&(typeof t.body==`string`||ArrayBuffer.isView(t.body))&&e.push(t.body),n+=`[data-hash="${g(...e)}"]`}return n}var re=/^(\[)?(\.\.\.)?(\w+)(?:=(\w+))?(\])?$/,ie=/^\/\((?:[^)]+)\)$/;function ae(e){let t=[];return{pattern:e===`/`||ie.test(e)?/^\/$/:RegExp(`^${se(e).map(e=>{let n=/^\[\.\.\.(\w+)(?:=(\w+))?\]$/.exec(e);if(n)return t.push({name:n[1],matcher:n[2],optional:!1,rest:!0,chained:!0}),`(?:/([^]*))?`;let r=/^\[\[(\w+)(?:=(\w+))?\]\]$/.exec(e);if(r)return t.push({name:r[1],matcher:r[2],optional:!0,rest:!1,chained:!0}),`(?:/([^/]+))?`;if(!e)return;let i=e.split(/\[(.+?)\](?!\])/);return`/`+i.map((e,n)=>{if(n%2){if(e.startsWith(`x+`))return le(String.fromCharCode(parseInt(e.slice(2),16)));if(e.startsWith(`u+`))return le(String.fromCharCode(...e.slice(2).split(`-`).map(e=>parseInt(e,16))));let[,r,a,o,s]=re.exec(e);return t.push({name:o,matcher:s,optional:!!r,rest:!!a,chained:a?n===1&&i[0]===``:!1}),a?`([^]*?)`:r?`([^/]*)?`:`([^/]+?)`}return le(e)}).join(``)}).join(``)}/?$`),params:t}}function oe(e){return e!==``&&!/^\([^)]+\)$/.test(e)}function se(e){return e.slice(1).split(`/`).filter(oe)}function ce(e,t,n){let r={},i=e.slice(1),a=i.filter(e=>e!==void 0),o=0;for(let e=0;e<t.length;e+=1){let s=t[e],c=i[e-o];if(s.chained&&s.rest&&o&&(c=i.slice(e-o,e+1).filter(e=>e).join(`/`),o=0),c===void 0){if(s.rest)c=``;else continue}if(!s.matcher||n[s.matcher](c)){r[s.name]=c;let n=t[e+1],l=i[e+1];n&&!n.rest&&n.optional&&l&&s.chained&&(o=0),!n&&!l&&Object.keys(r).length===a.length&&(o=0);continue}if(s.optional&&s.chained){o++;continue}return}if(!o)return r}function le(e){return e.normalize().replace(/[[\]]/g,`\\$&`).replace(/%/g,`%25`).replace(/\//g,`%2[Ff]`).replace(/\?/g,`%3[Ff]`).replace(/#/g,`%23`).replace(/[.*+?^${}()|\\]/g,`\\$&`)}function ue({nodes:e,server_loads:t,dictionary:n,matchers:r}){let i=new Set(t);return Object.entries(n).map(([t,[n,i,s]])=>{let{pattern:c,params:l}=ae(t),u={id:t,exec:e=>{let t=c.exec(e);if(t)return ce(t,l,r)},errors:[1,...s||[]].map(t=>e[t]),layouts:[0,...i||[]].map(o),leaf:a(n)};return u.errors.length=u.layouts.length=Math.max(u.errors.length,u.layouts.length),u});function a(t){let n=t<0;return n&&(t=~t),[n,e[t]]}function o(t){return t===void 0?t:[i.has(t),e[t]]}}function de(e,t=JSON.parse){try{return t(sessionStorage[e])}catch{}}function fe(e,t,n=JSON.stringify){let r=n(t);try{sessionStorage[e]=r}catch{}}var x=globalThis.__sveltekit_tf7kse?.base??`/.introspection`,pe=globalThis.__sveltekit_tf7kse?.assets??x??``,me=`sveltekit:snapshot`,he=`sveltekit:scroll`,ge=`sveltekit:states`,S=`sveltekit:history`,C=`sveltekit:navigation`,w={tap:1,hover:2,viewport:3,eager:4,off:-1,false:-1},_e=location.origin;function ve(e){if(e instanceof URL)return e;let t=document.baseURI;if(!t){let e=document.getElementsByTagName(`base`);t=e.length?e[0].href:document.URL}return new URL(e,t)}function T(){return{x:pageXOffset,y:pageYOffset}}function E(e,t){return e.getAttribute(`data-sveltekit-${t}`)}var ye={...w,"":w.hover};function be(e){let t=e.assignedSlot??e.parentNode;return t?.nodeType===11&&(t=t.host),t}function xe(e,t){for(;e&&e!==t;){if(e.nodeName.toUpperCase()===`A`&&e.hasAttribute(`href`))return e;e=be(e)}}function Se(e,t,n){let r;try{if(r=new URL(e instanceof SVGAElement?e.href.baseVal:e.href,document.baseURI),n&&r.hash.match(/^#[^/]/)){let e=location.hash.split(`#`)[1]||`/`;r.hash=`#${e}${r.hash}`}}catch{}let i=e instanceof SVGAElement?e.target.baseVal:e.target,a=!r||!!i||O(r,t,n)||(e.getAttribute(`rel`)||``).split(/\s+/).includes(`external`),o=r?.origin===_e&&e.hasAttribute(`download`);return{url:r,external:a,target:i,download:o}}function D(e){let t=null,n=null,r=null,i=null,a=null,o=null,s=e;for(;s&&s!==document.documentElement;)r===null&&(r=E(s,`preload-code`)),i===null&&(i=E(s,`preload-data`)),t===null&&(t=E(s,`keepfocus`)),n===null&&(n=E(s,`noscroll`)),a===null&&(a=E(s,`reload`)),o===null&&(o=E(s,`replacestate`)),s=be(s);function c(e){switch(e){case``:case`true`:return!0;case`off`:case`false`:return!1;default:return}}return{preload_code:ye[r??`off`],preload_data:ye[i??`off`],keepfocus:c(t),noscroll:c(n),reload:c(a),replace_state:c(o)}}function Ce(e){let t=s(e),n=!0;function r(){n=!0,t.update(e=>e)}function i(e){n=!1,t.set(e)}function a(e){let r;return t.subscribe(t=>{(r===void 0||n&&t!==r)&&e(r=t)})}return{notify:r,set:i,subscribe:a}}var we={v:h};function Te(){let{set:e,subscribe:t}=s(!1),n;async function r(){clearTimeout(n);try{let t=await fetch(`${pe}/_app/version.json`,{headers:{pragma:`no-cache`,"cache-control":`no-cache`}});if(!t.ok)return!1;let r=(await t.json()).version!==c;return r&&(e(!0),we.v(),clearTimeout(n)),r}catch{return!1}}return{subscribe:t,check:r}}function O(e,t,n){return e.origin!==_e||!e.pathname.startsWith(t)?!0:n?e.pathname!==location.pathname:!1}function Ee(e){}var De=new Set([`load`,`prerender`,`csr`,`ssr`,`trailingSlash`,`config`]);[...De],[...new Set([...De])];function Oe(e){return e.filter(e=>e!=null)}function k(e,t){return e+`/`+t}function ke(e){return e instanceof l||e instanceof d?e.status:500}function Ae(e){return e instanceof d?e.text:`Internal Error`}var A,j,je,Me=i.toString().includes(`$$`)||/function \w+\(\) \{\}/.test(i.toString()),Ne=`a:`;Me?(A={data:{},form:null,error:null,params:{},route:{id:null},state:{},status:-1,url:new URL(Ne)},j={current:null},je={current:!1}):(A=new class{#e=a({});get data(){return n(this.#e)}set data(e){r(this.#e,e)}#t=a(null);get form(){return n(this.#t)}set form(e){r(this.#t,e)}#n=a(null);get error(){return n(this.#n)}set error(e){r(this.#n,e)}#r=a({});get params(){return n(this.#r)}set params(e){r(this.#r,e)}#i=a({id:null});get route(){return n(this.#i)}set route(e){r(this.#i,e)}#a=a({});get state(){return n(this.#a)}set state(e){r(this.#a,e)}#o=a(-1);get status(){return n(this.#o)}set status(e){r(this.#o,e)}#s=a(new URL(Ne));get url(){return n(this.#s)}set url(e){r(this.#s,e)}},j=new class{#e=a(null);get current(){return n(this.#e)}set current(e){r(this.#e,e)}},je=new class{#e=a(!1);get current(){return n(this.#e)}set current(e){r(this.#e,e)}},we.v=()=>je.current=!0);function Pe(e){Object.assign(A,e)}var{onMount:Fe,tick:Ie}=o,Le=new Set([`icon`,`shortcut icon`,`apple-touch-icon`]),M=null,N=de(`sveltekit:scroll`)??{},P=de(`sveltekit:snapshot`)??{},F={url:Ce({}),page:Ce({}),navigating:s(null),updated:Te()};function Re(e){N[e]=T()}function ze(e,t){let n=e+1;for(;N[n];)delete N[n],n+=1;for(n=t+1;P[n];)delete P[n],n+=1}function I(e,t=!1){return t?location.replace(e.href):location.href=e.href,new Promise(h)}async function Be(){if(`serviceWorker`in navigator){let e=await navigator.serviceWorker.getRegistration(x||`/`);e&&await e.update()}}var Ve,He,L,R,Ue,z,We={},Ge={},B=[],V=[],H=null;function U(){H?.fork?.then(e=>e?.discard()),H=null,Q={element:void 0,href:void 0}}var Ke=new Map,qe=new Set,Je=new Set,W=new Set,G={branch:[],error:null,url:null,nav:null},Ye=!1,Xe=!1,Ze=!0,K=!1,q=!1,Qe=!1,$e=!1,et,J,Y,X,tt=new Set,nt=new Map,rt=new Map;async function it(e,t,n){if(globalThis.__sveltekit_tf7kse.data){let{q:e={},p:t={},l:n={},f:r={}}=globalThis.__sveltekit_tf7kse.data;for(let t in e)We[t]=e[t];for(let e in n)We[e]=n[e];for(let e in r)We[e]=r[e];for(let e in t)Ge[e]=t[e]}document.URL!==location.href&&(location.href=location.href),z=e,await e.hooks.init?.(),Ve=ue(e),R=document.documentElement,Ue=t,He=e.nodes[0],L=e.nodes[1],He(),L(),J=history.state?.[S],Y=history.state?.[C],J||(J=Y=Date.now(),history.replaceState({...history.state,[S]:J,[C]:Y},``));let r=N[J];function i(){r&&(history.scrollRestoration=`manual`,scrollTo(r.x,r.y))}n?(i(),await Ft(Ue,n)):(await Z({type:`enter`,url:ve(z.hash?Vt(new URL(location.href)):location.href),replace_state:!0}),i()),Pt()}function at(){B.length=0,$e=!1}function ot(e){V.some(e=>e?.snapshot)&&(P[e]=V.map(e=>e?.snapshot?.capture()))}function st(e){P[e]?.forEach((e,t)=>{V[t]?.snapshot?.restore(e)})}function ct(){Re(J),fe(he,N),ot(Y),fe(me,P)}async function lt(e,n,r,i){let a,o;n.invalidateAll&&U(),await Z({type:`goto`,url:ve(e),keepfocus:n.keepFocus,noscroll:n.noScroll,replace_state:n.replaceState,state:n.state,redirect_count:r,nav_token:i,accept:()=>{if(n.invalidateAll){$e=!0,a=new Set;for(let[e,t]of nt)for(let[n,r]of t)r.resource?.reset(),a.add(k(e,n));o=new Set;for(let[e,t]of rt)for(let n of t.keys())o.add(k(e,n))}n.invalidate&&n.invalidate.forEach(Nt)}}),n.invalidateAll&&t().then(t).then(()=>{for(let[e,t]of nt)for(let[n,{resource:r}]of t)a?.has(k(e,n))&&r.start();for(let[e,t]of rt)for(let[n,{resource:r}]of t)o?.has(k(e,n))&&r.reconnect()})}async function ut(e){if(e.id!==H?.id){U();let t={};tt.add(t),H={id:e.id,token:t,promise:bt({...e,preload:t}).then(e=>(tt.delete(t),e.type===`loaded`&&e.state.error&&U(),e)),fork:null}}return H.promise}async function dt(e){let t=(await wt(e,!1))?.route;t&&await Promise.all([...t.layouts,t.leaf].filter(Boolean).map(e=>e[1]()))}async function ft(e,t,n){let r={params:G.params,route:{id:G.route?.id??null},url:new URL(location.href)};if(G={...e.state,nav:r},Pe(e.props.page),et=new z.root({target:t,props:{...e.props,stores:F,components:V},hydrate:n,sync:!1,transformError:void 0}),await Promise.resolve(),n){let e={from:null,to:{...r,scroll:N[J]??T()},willUnload:!1,type:`enter`,complete:Promise.resolve()};W.forEach(t=>t(e))}st(Y),Xe=!0}async function pt({url:e,params:t,branch:n,errors:r,status:i,error:a,route:o,form:s}){let c=`never`;if(x&&(e.pathname===x||e.pathname===x+`/`))c=`always`;else for(let e of n)e?.slash!==void 0&&(c=e.slash);e.pathname=f(e.pathname,c),e.search=e.search;let l={type:`loaded`,state:{url:e,params:t,branch:n,error:a,route:o},props:{constructors:Oe(n).map(e=>e.node.component),page:Bt(A)}};s!==void 0&&(l.props.form=s);let u={},d=!A,p=0;for(let e=0;e<Math.max(n.length,G.branch.length);e+=1){let t=n[e],r=G.branch[e];t?.data!==r?.data&&(d=!0),t&&(u={...u,...t.data},d&&(l.props[`data_${p}`]=u),p+=1)}return(!G.url||e.href!==G.url.href||G.error!==a||s!==void 0&&s!==A.form||d)&&(l.props.page={error:a,params:t,route:{id:o?.id??null},state:{},status:i,url:new URL(e),form:s??null,data:d?u:A.data}),l}async function mt({loader:e,parent:t,url:n,params:r,route:i,server_data_node:a}){let o={dependencies:new Set,params:new Set,parent:!1,route:!1,url:!1,search_params:new Set},s=await e();return{node:s,loader:e,server:a,universal:s.universal?.load?{type:`data`,data:null,uses:o}:null,data:a?.data??null,slash:s.universal?.trailingSlash??a?.slash}}function ht(e,t,n){let r=e instanceof Request?e.url:e,i=new URL(r,n);return i.origin===n.origin&&(r=i.href.slice(n.origin.length)),{resolved:i,promise:Xe?ne(r,i.href,t):y(r,t)}}function gt(e,t,n,r,i,a){if($e)return!0;if(!i)return!1;if(i.parent&&e||i.route&&t||i.url&&n)return!0;for(let e of i.search_params)if(r.has(e))return!0;for(let e of i.params)if(a[e]!==G.params[e])return!0;for(let e of i.dependencies)if(B.some(t=>t(new URL(e))))return!0;return!1}function _t(e,t){return e?.type===`data`?e:e?.type===`skip`?t??null:null}function vt(e,t){if(!e)return new Set(t.searchParams.keys());let n=new Set([...e.searchParams.keys(),...t.searchParams.keys()]);for(let r of n){let i=e.searchParams.getAll(r),a=t.searchParams.getAll(r);i.every(e=>a.includes(e))&&a.every(e=>i.includes(e))&&n.delete(r)}return n}function yt({error:e,url:t,route:n,params:r}){return{type:`loaded`,state:{error:e,url:t,route:n,params:r,branch:[]},props:{page:Bt(A),constructors:[]}}}async function bt({id:e,invalidating:t,url:n,params:r,route:i,preload:a}){if(H?.id===e)return tt.delete(H.token),H.promise;let{errors:o,layouts:s,leaf:c}=i,d=[...s,c];o.forEach(e=>e?.().catch(h)),d.forEach(e=>e?.[1]().catch(h));let f=G.url?e!==Et(G.url):!1,p=G.route?i.id!==G.route.id:!1,ee=vt(G.url,n),m=!1,g=d.map(async(e,t)=>{if(!e)return;let a=G.branch[t];return e[1]===a?.loader&&!gt(m,p,f,ee,a.universal?.uses,r)?a:(m=!0,mt({loader:e[1],url:n,params:r,route:i,parent:async()=>{let e={};for(let n=0;n<t;n+=1)Object.assign(e,(await g[n])?.data);return e},server_data_node:_t(e[0]?{type:`skip`}:null,e[0]?a?.server:void 0)}))});for(let e of g)e.catch(h);let _=[];for(let e=0;e<d.length;e+=1)if(d[e])try{_.push(await g[e])}catch(t){if(t instanceof u)return{type:`redirect`,location:t.location};if(a&&tt.has(a))return yt({error:await $(t,{params:r,url:n,route:{id:i.id}}),url:n,params:r,route:i});let s=ke(t),c;if(t instanceof l)c=t.body;else{if(await F.updated.check())return await Be(),await I(n);c=await $(t,{params:r,url:n,route:{id:i.id}})}let d=await xt(e,_,o);return d?pt({url:n,params:r,branch:_.slice(0,d.idx).concat(d.node),errors:o,status:s,error:c,route:i}):await Ot(n,{id:i.id},c,s)}else _.push(void 0);return pt({url:n,params:r,branch:_,errors:o,status:200,error:null,route:i,form:t?void 0:null})}async function xt(e,t,n){for(;e--;)if(n[e]){let r=e;for(;!t[r];)--r;try{return{idx:r+1,node:{node:await n[e](),loader:n[e],data:{},server:null,universal:null}}}catch{continue}}}async function St({status:e,error:t,url:n,route:r}){let i={};try{return pt({url:n,params:i,branch:[await mt({loader:He,url:n,params:i,route:r,parent:()=>Promise.resolve({}),server_data_node:_t(null)}),{node:await L(),loader:L,universal:null,server:null,data:null}],status:e,error:t,errors:[],route:null})}catch(t){if(t instanceof u){await lt(new URL(t.location,location.href),{},0);return}let a=await z.get_error_template(),o=await $(t,{url:n,params:i,route:r}),s=a({status:e,message:String(o?.message??``).replace(/&/g,`&`).replace(/</g,`<`).replace(/>/g,`>`)}),c=new DOMParser().parseFromString(s,`text/html`);throw document.documentElement.replaceChild(document.adoptNode(c.head),document.head),document.documentElement.replaceChild(document.adoptNode(c.body),document.body),t}}async function Ct(e){let t=e.href;if(Ke.has(t))return Ke.get(t);let n;try{let r=(async()=>{let t=await z.hooks.reroute({url:new URL(e),fetch:async(t,n)=>ht(t,n,e).promise})??e;if(typeof t==`string`){let n=new URL(e);z.hash?n.hash=t:n.pathname=t,t=n}return t})();Ke.set(t,r),n=await r}catch{Ke.delete(t);return}return n}async function wt(e,t){if(e&&!O(e,x,z.hash)){let n=await Ct(e);if(!n)return;let r=Tt(n);for(let n of Ve){let i=n.exec(r);if(i)return{id:Et(e),invalidating:t,route:n,params:ee(i),url:e}}}}function Tt(e){return p(z.hash?e.hash.replace(/^#/,``).replace(/[?#].+/,``):e.pathname.slice(x.length))||`/`}function Et(e){return(z.hash?e.hash.replace(/^#/,``):e.pathname)+e.search}function Dt({url:e,type:t,intent:n,delta:r,event:i,scroll:a}){let o=!1,s=zt(G,n,e,t,a??null);r!==void 0&&(s.navigation.delta=r),i!==void 0&&(s.navigation.event=i);let c={...s.navigation,cancel:()=>{o=!0,s.reject(Error(`navigation cancelled`))}};return K||qe.forEach(e=>e(c)),o?null:s}async function Z({type:n,url:r,popped:i,keepfocus:a,noscroll:o,replace_state:s,state:c={},redirect_count:l=0,nav_token:u={},accept:f=h,block:p=h,event:ee}){let m=X;X=u;let g=await wt(r,!1),_=n===`enter`?zt(G,g,r,n):Dt({url:r,type:n,delta:i?.delta,intent:g,scroll:i?.scroll,event:ee});if(!_){p(),X===u&&(X=m);return}let te=J,v=Y;f(),K=!0,Xe&&_.navigation.type!==`enter`&&F.navigating.set(j.current=_.navigation);let y=g&&await bt(g);if(!y){if(O(r,x,z.hash))return await I(r,s);y=await Ot(r,{id:null},await $(new d(404,`Not Found`,`Not found: ${r.pathname}`),{url:r,params:{},route:{id:null}}),404,s)}if(r=g?.url||r,X!==u){_.reject(Error(`navigation aborted`));return}if(!y)return;if(y.type===`redirect`){if(l<20){await Z({type:n,url:new URL(y.location,r),popped:i,keepfocus:a,noscroll:o,replace_state:s,state:c,redirect_count:l+1,nav_token:u}),_.fulfil(void 0);return}if(y=await St({status:500,error:await $(Error(`Redirect loop`),{url:r,params:{},route:{id:null}}),url:r,route:{id:null}}),!y)return}else if(y.props.page.status>=400&&await F.updated.check())return await Be(),await I(r,s);if(at(),Re(te),ot(v),y.props.page.url.pathname!==r.pathname&&(r.pathname=y.props.page.url.pathname),c=i?i.state:c,!i){let e=+!s,t={[S]:J+=e,[C]:Y+=e,[ge]:c};(s?history.replaceState:history.pushState).call(history,t,``,r),s||ze(J,Y)}let ne=g&&H?.id===g.id?H.fork:null;H?.fork&&!ne?U():(H=null,Q={element:void 0,href:void 0}),y.props.page.state=c;let b;if(Xe){let t=(await Promise.all(Array.from(Je,e=>e(_.navigation)))).filter(e=>typeof e==`function`);if(t.length>0){function e(){t.forEach(e=>{W.delete(e)})}t.push(e),t.forEach(e=>{W.add(e)})}let n=_.navigation.to;G={...y.state,nav:{params:n.params,route:n.route,url:n.url}},y.props.page&&(y.props.page.url=r),!a&&document.activeElement instanceof HTMLElement&&document.activeElement!==document.body&&document.activeElement.blur();let i=ne&&await ne;i?b=i.commit():(M=null,et.$set(y.props),M&&Object.assign(y.props.page,M),Pe(y.props.page),b=e?.()),Qe=!0}else await ft(y,Ue,!1);let{activeElement:re}=document;if(await b,await t(),await t(),X!==u){_.reject(Error(`navigation aborted`));return}y.props.page&&M&&Object.assign(y.props.page,M);let ie=null;if(Ze){let e=i?i.scroll:o?T():null;e?scrollTo(e.x,e.y):(ie=r.hash&&document.getElementById(Ht(r)))?ie.scrollIntoView():scrollTo(0,0)}let ae=document.activeElement!==re&&document.activeElement!==document.body;!a&&!ae&&Rt(r,!ie),Ze=!0,K=!1,_.fulfil(void 0),_.navigation.to&&(_.navigation.to.scroll=T()),W.forEach(e=>e(_.navigation)),n===`popstate`&&st(Y),F.navigating.set(j.current=null)}async function Ot(e,t,n,r,i){return e.origin===_e&&e.pathname===location.pathname&&!Ye?await St({status:r,error:n,url:e,route:t}):await I(e,i)}var Q={element:void 0,href:void 0};function kt(){let e,t;R.addEventListener(`mousemove`,t=>{let n=t.target;clearTimeout(e),e=setTimeout(()=>{i(n,w.hover)},20)});function n(e){e.defaultPrevented||i(e.composedPath()[0],w.tap)}R.addEventListener(`mousedown`,n),R.addEventListener(`touchstart`,n,{passive:!0});let r=new IntersectionObserver(e=>{for(let t of e)t.isIntersecting&&(dt(new URL(t.target.href)),r.unobserve(t.target))},{threshold:0});async function i(e,n){let r=xe(e,R),i=r===Q.element&&r?.href===Q.href&&n>=t;if(!r||i)return;let{url:a,external:o,download:s}=Se(r,x,z.hash);if(o||s)return;let c=D(r),l=a&&Et(G.url)===Et(a);if(!(c.reload||l)){if(n<=c.preload_data){Q={element:r,href:r.href},t=w.tap;let e=await wt(a,!1);if(!e)return;ut(e)}else n<=c.preload_code&&(Q={element:r,href:r.href},t=n,dt(a))}}function a(){r.disconnect();for(let e of R.querySelectorAll(`a`)){let{url:t,external:n,download:i}=Se(e,x,z.hash);if(n||i)continue;let a=D(e);a.reload||(a.preload_code===w.viewport&&r.observe(e),a.preload_code===w.eager&&dt(t))}}W.add(a),a()}function $(e,t){if(e instanceof l)return e.body;let n=ke(e),r=Ae(e);return z.hooks.handleError({error:e,event:t,status:n,message:r})??{message:r}}function At(e,t){Fe(()=>(e.add(t),()=>{e.delete(t)}))}function jt(e){At(Je,e)}function Mt(e,t={}){return e=new URL(ve(e)),e.origin===_e?lt(e,t,0):Promise.reject(Error(`goto: invalid URL`))}function Nt(e){if(typeof e==`function`)B.push(e);else{let{href:t}=new URL(e,location.href);B.push(e=>e.href===t)}}function Pt(){history.scrollRestoration=`manual`,addEventListener(`beforeunload`,e=>{let t=!1;if(ct(),!K){let e=zt(G,void 0,null,`leave`),n={...e.navigation,cancel:()=>{t=!0,e.reject(Error(`navigation cancelled`))}};qe.forEach(e=>e(n))}t?(e.preventDefault(),e.returnValue=``):history.scrollRestoration=`auto`}),addEventListener(`visibilitychange`,()=>{document.visibilityState===`hidden`&&ct()}),navigator.connection?.saveData||kt(),R.addEventListener(`click`,async t=>{if(t.button||t.which!==1||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.defaultPrevented)return;let n=xe(t.composedPath()[0],R);if(!n)return;let{url:r,external:i,target:a,download:o}=Se(n,x,z.hash);if(!r)return;if(a===`_parent`||a===`_top`){if(window.parent!==window)return}else if(a&&a!==`_self`)return;let s=D(n);if(!(n instanceof SVGAElement)&&r.protocol!==location.protocol&&r.protocol!==`https:`&&r.protocol!==`http:`||o)return;let[c,l]=(z.hash?r.hash.replace(/^#/,``):r.href).split(`#`),u=c===m(location);if(i||s.reload&&(!u||!l)){Dt({url:r,type:`link`,event:t})?K=!0:t.preventDefault();return}if(l!==void 0&&u){let[,i]=G.url.href.split(`#`);if(i===l){if(t.preventDefault(),l===``||l===`top`&&n.ownerDocument.getElementById(`top`)===null)scrollTo({top:0});else{let e=n.ownerDocument.getElementById(decodeURIComponent(l));e&&(e.scrollIntoView(),e.focus())}return}if(q=!0,Re(J),e(r),!s.replace_state)return;q=!1}t.preventDefault(),await new Promise(e=>{requestAnimationFrame(()=>{setTimeout(e,0)}),setTimeout(e,100)}),await Z({type:`link`,url:r,keepfocus:s.keepfocus,noscroll:s.noscroll,replace_state:s.replace_state??r.href===location.href,event:t})}),R.addEventListener(`submit`,e=>{if(e.defaultPrevented)return;let t=HTMLFormElement.prototype.cloneNode.call(e.target),n=e.submitter;if((n?.formTarget||t.target)===`_blank`||(n?.formMethod||t.method)!==`get`)return;let r=new URL(n?.hasAttribute(`formaction`)&&n?.formAction||t.action);if(O(r,x,!1))return;let i=e.target,a=D(i);if(a.reload)return;e.preventDefault(),e.stopPropagation();let o=new FormData(i,n);r.search=new URLSearchParams(o).toString(),Z({type:`form`,url:r,keepfocus:a.keepfocus,noscroll:a.noscroll,replace_state:a.replace_state??r.href===location.href,event:e})}),addEventListener(`popstate`,async t=>{if(!Lt){if(t.state?.[`sveltekit:history`]){let n=t.state[S];if(X={},n===J)return;let r=N[n],i=t.state[`sveltekit:states`]??{},a=new URL(t.state[`sveltekit:pageurl`]??location.href),o=t.state[C],s=G.url?m(location)===m(G.url):!1;if(o===Y&&(Qe||s)){i!==A.state&&(A.state=i),e(a),N[J]=T(),r&&scrollTo(r.x,r.y),J=n;return}let c=n-J;await Z({type:`popstate`,url:a,popped:{state:i,scroll:r,delta:c},accept:()=>{J=n,Y=o},block:()=>{history.go(-c)},nav_token:X,event:t})}else q||(e(new URL(location.href)),z.hash&&location.reload())}}),addEventListener(`hashchange`,()=>{q&&(q=!1,history.replaceState({...history.state,[S]:++J,[C]:Y},``,location.href))});for(let e of document.querySelectorAll(`link`))Le.has(e.rel)&&(e.href=e.href);addEventListener(`pageshow`,e=>{e.persisted&&F.navigating.set(j.current=null)});function e(e){G.url=A.url=e,F.page.set(Bt(A)),F.page.notify()}}async function Ft(e,{status:t=200,error:n,node_ids:r,params:i,route:a,server_route:o,data:s,form:c}){Ye=!0;let l=new URL(location.href),d;({params:i={},route:a={id:null}}=await wt(l,!1)||{}),d=Ve.find(({id:e})=>e===a.id);let f,p=!0;try{let e=r.map(async(t,n)=>{let r=s[n];return r?.uses&&(r.uses=It(r.uses)),mt({loader:z.nodes[t],url:l,params:i,route:a,parent:async()=>{let t={};for(let r=0;r<n;r+=1)Object.assign(t,(await e[r]).data);return t},server_data_node:_t(r)})}),o=await Promise.all(e);if(d){let e=d.layouts;for(let t=0;t<e.length;t++)e[t]||o.splice(t,0,void 0)}f=await pt({url:l,params:i,branch:o,status:t,error:n,errors:d?.errors,form:c,route:d??null})}catch(t){if(t instanceof u)return await I(new URL(t.location,location.href));f=await St({status:ke(t),error:await $(t,{url:l,params:i,route:a}),url:l,route:a}),e.textContent=``,p=!1}f&&(f.props.page&&(f.props.page.state={}),await ft(f,e,p))}function It(e){return{dependencies:new Set(e?.dependencies??[]),params:new Set(e?.params??[]),parent:!!e?.parent,route:!!e?.route,url:!!e?.url,search_params:new Set(e?.search_params??[])}}var Lt=!1;function Rt(e,t=!0){let n=document.querySelector(`[autofocus]`);if(n)n.focus();else{let n=Ht(e);if(n&&document.getElementById(n)){let{x:r,y:i}=T();setTimeout(()=>{let a=history.state;Lt=!0,location.replace(new URL(`#${n}`,location.href)),history.replaceState(a,``,e),t&&scrollTo(r,i),Lt=!1})}else{let e=document.body,t=e.getAttribute(`tabindex`);e.tabIndex=-1,e.focus({preventScroll:!0,focusVisible:!1}),t===null?e.removeAttribute(`tabindex`):e.setAttribute(`tabindex`,t)}let r=getSelection();if(r&&r.type!==`None`){let e=[];for(let t=0;t<r.rangeCount;t+=1)e.push(r.getRangeAt(t));setTimeout(()=>{if(r.rangeCount===e.length){for(let t=0;t<r.rangeCount;t+=1){let n=e[t],i=r.getRangeAt(t);if(n.commonAncestorContainer!==i.commonAncestorContainer||n.startContainer!==i.startContainer||n.endContainer!==i.endContainer||n.startOffset!==i.startOffset||n.endOffset!==i.endOffset)return}r.removeAllRanges()}})}}}function zt(e,t,n,r,i=null){let a,o,s=new Promise((e,t)=>{a=e,o=t});return s.catch(h),{navigation:{from:{params:e.params,route:{id:e.route?.id??null},url:e.url,scroll:T()},to:n&&{params:t?.params??null,route:{id:t?.route?.id??null},url:n,scroll:i},willUnload:!t,type:r,complete:s},fulfil:a,reject:o}}function Bt(e){return{data:e.data,error:e.error,form:e.form,params:e.params,route:e.route,state:e.state,status:e.status,url:e.url}}function Vt(e){let t=new URL(e);return t.hash=decodeURIComponent(e.hash),t}function Ht(e){let t;if(z.hash){let[,,n]=e.hash.split(`#`,3);t=n??``}else t=e.hash.slice(1);return decodeURIComponent(t)}export{A as a,j as i,jt as n,Ee as o,it as r,x as s,Mt as t};
|
|
1
|
+
import{H as e,U as t,V as n,at as r,n as i,st as a,t as o,vt as s}from"./sTot5bBi.js";import{t as c}from"./EttRBGeu.js";var l=class{constructor(e,t){this.status=e,this.body=typeof t==`string`?{message:t}:t||{message:`Error: ${e}`}}toString(){return JSON.stringify(this.body)}},u=class{constructor(e,t){try{new Headers({location:t})}catch{throw Error(`Invalid redirect location ${JSON.stringify(t)}: this string contains characters that cannot be used in HTTP headers`)}this.status=e,this.location=t}},d=class extends Error{constructor(e,t,n){super(n),this.status=e,this.text=t}};new URL(`sveltekit-internal://`);function f(e,t){return e===`/`||t===`ignore`?e:t===`never`?e.endsWith(`/`)?e.slice(0,-1):e:t===`always`&&!e.endsWith(`/`)?e+`/`:e}function p(e){return e.split(`%25`).map(decodeURI).join(`%25`)}function ee(e){for(let t in e)e[t]=decodeURIComponent(e[t]);return e}function m({href:e}){return e.split(`#`)[0]}function h(){}function g(...e){let t=5381;for(let n of e)if(typeof n==`string`){let e=n.length;for(;e;)t=t*33^n.charCodeAt(--e)}else if(ArrayBuffer.isView(n)){let e=new Uint8Array(n.buffer,n.byteOffset,n.byteLength),r=e.length;for(;r;)t=t*33^e[--r]}else throw TypeError(`value must be a string or TypedArray`);return(t>>>0).toString(36)}new TextEncoder;function _(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}var te=window.fetch;window.fetch=(e,t)=>((e instanceof Request?e.method:t?.method||`GET`)!==`GET`&&v.delete(b(e)),te(e,t));var v=new Map;function y(e,t){let n=b(e,t),r=document.querySelector(n);if(r?.textContent){r.remove();let{body:e,...t}=JSON.parse(r.textContent);r.getAttribute(`data-b64`)!==null&&(e=_(e));let i=r.getAttribute(`data-ttl`);return i&&v.set(n,{body:e,init:t,ttl:1e3*Number(i)}),Promise.resolve(new Response(e,t))}return window.fetch(e,t)}function ne(e,t,n){if(v.size>0){let t=b(e,n),r=v.get(t);if(r){if(performance.now()<r.ttl&&[`default`,`force-cache`,`only-if-cached`,void 0].includes(n?.cache))return new Response(r.body,r.init);v.delete(t)}}return window.fetch(t,n)}function b(e,t){let n=`script[data-sveltekit-fetched][data-url=${JSON.stringify(e instanceof Request?e.url:e)}]`;if(t?.headers||t?.body){let e=[];t.headers&&e.push([...new Headers(t.headers)].join(`,`)),t.body&&(typeof t.body==`string`||ArrayBuffer.isView(t.body))&&e.push(t.body),n+=`[data-hash="${g(...e)}"]`}return n}var re=/^(\[)?(\.\.\.)?(\w+)(?:=(\w+))?(\])?$/,ie=/^\/\((?:[^)]+)\)$/;function ae(e){let t=[];return{pattern:e===`/`||ie.test(e)?/^\/$/:RegExp(`^${se(e).map(e=>{let n=/^\[\.\.\.(\w+)(?:=(\w+))?\]$/.exec(e);if(n)return t.push({name:n[1],matcher:n[2],optional:!1,rest:!0,chained:!0}),`(?:/([^]*))?`;let r=/^\[\[(\w+)(?:=(\w+))?\]\]$/.exec(e);if(r)return t.push({name:r[1],matcher:r[2],optional:!0,rest:!1,chained:!0}),`(?:/([^/]+))?`;if(!e)return;let i=e.split(/\[(.+?)\](?!\])/);return`/`+i.map((e,n)=>{if(n%2){if(e.startsWith(`x+`))return le(String.fromCharCode(parseInt(e.slice(2),16)));if(e.startsWith(`u+`))return le(String.fromCharCode(...e.slice(2).split(`-`).map(e=>parseInt(e,16))));let[,r,a,o,s]=re.exec(e);return t.push({name:o,matcher:s,optional:!!r,rest:!!a,chained:a?n===1&&i[0]===``:!1}),a?`([^]*?)`:r?`([^/]*)?`:`([^/]+?)`}return le(e)}).join(``)}).join(``)}/?$`),params:t}}function oe(e){return e!==``&&!/^\([^)]+\)$/.test(e)}function se(e){return e.slice(1).split(`/`).filter(oe)}function ce(e,t,n){let r={},i=e.slice(1),a=i.filter(e=>e!==void 0),o=0;for(let e=0;e<t.length;e+=1){let s=t[e],c=i[e-o];if(s.chained&&s.rest&&o&&(c=i.slice(e-o,e+1).filter(e=>e).join(`/`),o=0),c===void 0){if(s.rest)c=``;else continue}if(!s.matcher||n[s.matcher](c)){r[s.name]=c;let n=t[e+1],l=i[e+1];n&&!n.rest&&n.optional&&l&&s.chained&&(o=0),!n&&!l&&Object.keys(r).length===a.length&&(o=0);continue}if(s.optional&&s.chained){o++;continue}return}if(!o)return r}function le(e){return e.normalize().replace(/[[\]]/g,`\\$&`).replace(/%/g,`%25`).replace(/\//g,`%2[Ff]`).replace(/\?/g,`%3[Ff]`).replace(/#/g,`%23`).replace(/[.*+?^${}()|\\]/g,`\\$&`)}function ue({nodes:e,server_loads:t,dictionary:n,matchers:r}){let i=new Set(t);return Object.entries(n).map(([t,[n,i,s]])=>{let{pattern:c,params:l}=ae(t),u={id:t,exec:e=>{let t=c.exec(e);if(t)return ce(t,l,r)},errors:[1,...s||[]].map(t=>e[t]),layouts:[0,...i||[]].map(o),leaf:a(n)};return u.errors.length=u.layouts.length=Math.max(u.errors.length,u.layouts.length),u});function a(t){let n=t<0;return n&&(t=~t),[n,e[t]]}function o(t){return t===void 0?t:[i.has(t),e[t]]}}function de(e,t=JSON.parse){try{return t(sessionStorage[e])}catch{}}function fe(e,t,n=JSON.stringify){let r=n(t);try{sessionStorage[e]=r}catch{}}var x=globalThis.__sveltekit_lnd27m?.base??`/.introspection`,pe=globalThis.__sveltekit_lnd27m?.assets??x??``,me=`sveltekit:snapshot`,he=`sveltekit:scroll`,ge=`sveltekit:states`,S=`sveltekit:history`,C=`sveltekit:navigation`,w={tap:1,hover:2,viewport:3,eager:4,off:-1,false:-1},_e=location.origin;function ve(e){if(e instanceof URL)return e;let t=document.baseURI;if(!t){let e=document.getElementsByTagName(`base`);t=e.length?e[0].href:document.URL}return new URL(e,t)}function T(){return{x:pageXOffset,y:pageYOffset}}function E(e,t){return e.getAttribute(`data-sveltekit-${t}`)}var ye={...w,"":w.hover};function be(e){let t=e.assignedSlot??e.parentNode;return t?.nodeType===11&&(t=t.host),t}function xe(e,t){for(;e&&e!==t;){if(e.nodeName.toUpperCase()===`A`&&e.hasAttribute(`href`))return e;e=be(e)}}function Se(e,t,n){let r;try{if(r=new URL(e instanceof SVGAElement?e.href.baseVal:e.href,document.baseURI),n&&r.hash.match(/^#[^/]/)){let e=location.hash.split(`#`)[1]||`/`;r.hash=`#${e}${r.hash}`}}catch{}let i=e instanceof SVGAElement?e.target.baseVal:e.target,a=!r||!!i||O(r,t,n)||(e.getAttribute(`rel`)||``).split(/\s+/).includes(`external`),o=r?.origin===_e&&e.hasAttribute(`download`);return{url:r,external:a,target:i,download:o}}function D(e){let t=null,n=null,r=null,i=null,a=null,o=null,s=e;for(;s&&s!==document.documentElement;)r===null&&(r=E(s,`preload-code`)),i===null&&(i=E(s,`preload-data`)),t===null&&(t=E(s,`keepfocus`)),n===null&&(n=E(s,`noscroll`)),a===null&&(a=E(s,`reload`)),o===null&&(o=E(s,`replacestate`)),s=be(s);function c(e){switch(e){case``:case`true`:return!0;case`off`:case`false`:return!1;default:return}}return{preload_code:ye[r??`off`],preload_data:ye[i??`off`],keepfocus:c(t),noscroll:c(n),reload:c(a),replace_state:c(o)}}function Ce(e){let t=s(e),n=!0;function r(){n=!0,t.update(e=>e)}function i(e){n=!1,t.set(e)}function a(e){let r;return t.subscribe(t=>{(r===void 0||n&&t!==r)&&e(r=t)})}return{notify:r,set:i,subscribe:a}}var we={v:h};function Te(){let{set:e,subscribe:t}=s(!1),n;async function r(){clearTimeout(n);try{let t=await fetch(`${pe}/_app/version.json`,{headers:{pragma:`no-cache`,"cache-control":`no-cache`}});if(!t.ok)return!1;let r=(await t.json()).version!==c;return r&&(e(!0),we.v(),clearTimeout(n)),r}catch{return!1}}return{subscribe:t,check:r}}function O(e,t,n){return e.origin!==_e||!e.pathname.startsWith(t)?!0:n?e.pathname!==location.pathname:!1}function Ee(e){}var De=new Set([`load`,`prerender`,`csr`,`ssr`,`trailingSlash`,`config`]);[...De],[...new Set([...De])];function Oe(e){return e.filter(e=>e!=null)}function k(e,t){return e+`/`+t}function ke(e){return e instanceof l||e instanceof d?e.status:500}function Ae(e){return e instanceof d?e.text:`Internal Error`}var A,j,je,Me=i.toString().includes(`$$`)||/function \w+\(\) \{\}/.test(i.toString()),Ne=`a:`;Me?(A={data:{},form:null,error:null,params:{},route:{id:null},state:{},status:-1,url:new URL(Ne)},j={current:null},je={current:!1}):(A=new class{#e=a({});get data(){return n(this.#e)}set data(e){r(this.#e,e)}#t=a(null);get form(){return n(this.#t)}set form(e){r(this.#t,e)}#n=a(null);get error(){return n(this.#n)}set error(e){r(this.#n,e)}#r=a({});get params(){return n(this.#r)}set params(e){r(this.#r,e)}#i=a({id:null});get route(){return n(this.#i)}set route(e){r(this.#i,e)}#a=a({});get state(){return n(this.#a)}set state(e){r(this.#a,e)}#o=a(-1);get status(){return n(this.#o)}set status(e){r(this.#o,e)}#s=a(new URL(Ne));get url(){return n(this.#s)}set url(e){r(this.#s,e)}},j=new class{#e=a(null);get current(){return n(this.#e)}set current(e){r(this.#e,e)}},je=new class{#e=a(!1);get current(){return n(this.#e)}set current(e){r(this.#e,e)}},we.v=()=>je.current=!0);function Pe(e){Object.assign(A,e)}var{onMount:Fe,tick:Ie}=o,Le=new Set([`icon`,`shortcut icon`,`apple-touch-icon`]),M=null,N=de(`sveltekit:scroll`)??{},P=de(`sveltekit:snapshot`)??{},F={url:Ce({}),page:Ce({}),navigating:s(null),updated:Te()};function Re(e){N[e]=T()}function ze(e,t){let n=e+1;for(;N[n];)delete N[n],n+=1;for(n=t+1;P[n];)delete P[n],n+=1}function I(e,t=!1){return t?location.replace(e.href):location.href=e.href,new Promise(h)}async function Be(){if(`serviceWorker`in navigator){let e=await navigator.serviceWorker.getRegistration(x||`/`);e&&await e.update()}}var Ve,He,L,R,Ue,z,We={},Ge={},B=[],V=[],H=null;function U(){H?.fork?.then(e=>e?.discard()),H=null,Q={element:void 0,href:void 0}}var Ke=new Map,qe=new Set,Je=new Set,W=new Set,G={branch:[],error:null,url:null,nav:null},Ye=!1,Xe=!1,Ze=!0,K=!1,q=!1,Qe=!1,$e=!1,et,J,Y,X,tt=new Set,nt=new Map,rt=new Map;async function it(e,t,n){if(globalThis.__sveltekit_lnd27m.data){let{q:e={},p:t={},l:n={},f:r={}}=globalThis.__sveltekit_lnd27m.data;for(let t in e)We[t]=e[t];for(let e in n)We[e]=n[e];for(let e in r)We[e]=r[e];for(let e in t)Ge[e]=t[e]}document.URL!==location.href&&(location.href=location.href),z=e,await e.hooks.init?.(),Ve=ue(e),R=document.documentElement,Ue=t,He=e.nodes[0],L=e.nodes[1],He(),L(),J=history.state?.[S],Y=history.state?.[C],J||(J=Y=Date.now(),history.replaceState({...history.state,[S]:J,[C]:Y},``));let r=N[J];function i(){r&&(history.scrollRestoration=`manual`,scrollTo(r.x,r.y))}n?(i(),await Ft(Ue,n)):(await Z({type:`enter`,url:ve(z.hash?Vt(new URL(location.href)):location.href),replace_state:!0}),i()),Pt()}function at(){B.length=0,$e=!1}function ot(e){V.some(e=>e?.snapshot)&&(P[e]=V.map(e=>e?.snapshot?.capture()))}function st(e){P[e]?.forEach((e,t)=>{V[t]?.snapshot?.restore(e)})}function ct(){Re(J),fe(he,N),ot(Y),fe(me,P)}async function lt(e,n,r,i){let a,o;n.invalidateAll&&U(),await Z({type:`goto`,url:ve(e),keepfocus:n.keepFocus,noscroll:n.noScroll,replace_state:n.replaceState,state:n.state,redirect_count:r,nav_token:i,accept:()=>{if(n.invalidateAll){$e=!0,a=new Set;for(let[e,t]of nt)for(let[n,r]of t)r.resource?.reset(),a.add(k(e,n));o=new Set;for(let[e,t]of rt)for(let n of t.keys())o.add(k(e,n))}n.invalidate&&n.invalidate.forEach(Nt)}}),n.invalidateAll&&t().then(t).then(()=>{for(let[e,t]of nt)for(let[n,{resource:r}]of t)a?.has(k(e,n))&&r.start();for(let[e,t]of rt)for(let[n,{resource:r}]of t)o?.has(k(e,n))&&r.reconnect()})}async function ut(e){if(e.id!==H?.id){U();let t={};tt.add(t),H={id:e.id,token:t,promise:bt({...e,preload:t}).then(e=>(tt.delete(t),e.type===`loaded`&&e.state.error&&U(),e)),fork:null}}return H.promise}async function dt(e){let t=(await wt(e,!1))?.route;t&&await Promise.all([...t.layouts,t.leaf].filter(Boolean).map(e=>e[1]()))}async function ft(e,t,n){let r={params:G.params,route:{id:G.route?.id??null},url:new URL(location.href)};if(G={...e.state,nav:r},Pe(e.props.page),et=new z.root({target:t,props:{...e.props,stores:F,components:V},hydrate:n,sync:!1,transformError:void 0}),await Promise.resolve(),n){let e={from:null,to:{...r,scroll:N[J]??T()},willUnload:!1,type:`enter`,complete:Promise.resolve()};W.forEach(t=>t(e))}st(Y),Xe=!0}async function pt({url:e,params:t,branch:n,errors:r,status:i,error:a,route:o,form:s}){let c=`never`;if(x&&(e.pathname===x||e.pathname===x+`/`))c=`always`;else for(let e of n)e?.slash!==void 0&&(c=e.slash);e.pathname=f(e.pathname,c),e.search=e.search;let l={type:`loaded`,state:{url:e,params:t,branch:n,error:a,route:o},props:{constructors:Oe(n).map(e=>e.node.component),page:Bt(A)}};s!==void 0&&(l.props.form=s);let u={},d=!A,p=0;for(let e=0;e<Math.max(n.length,G.branch.length);e+=1){let t=n[e],r=G.branch[e];t?.data!==r?.data&&(d=!0),t&&(u={...u,...t.data},d&&(l.props[`data_${p}`]=u),p+=1)}return(!G.url||e.href!==G.url.href||G.error!==a||s!==void 0&&s!==A.form||d)&&(l.props.page={error:a,params:t,route:{id:o?.id??null},state:{},status:i,url:new URL(e),form:s??null,data:d?u:A.data}),l}async function mt({loader:e,parent:t,url:n,params:r,route:i,server_data_node:a}){let o={dependencies:new Set,params:new Set,parent:!1,route:!1,url:!1,search_params:new Set},s=await e();return{node:s,loader:e,server:a,universal:s.universal?.load?{type:`data`,data:null,uses:o}:null,data:a?.data??null,slash:s.universal?.trailingSlash??a?.slash}}function ht(e,t,n){let r=e instanceof Request?e.url:e,i=new URL(r,n);return i.origin===n.origin&&(r=i.href.slice(n.origin.length)),{resolved:i,promise:Xe?ne(r,i.href,t):y(r,t)}}function gt(e,t,n,r,i,a){if($e)return!0;if(!i)return!1;if(i.parent&&e||i.route&&t||i.url&&n)return!0;for(let e of i.search_params)if(r.has(e))return!0;for(let e of i.params)if(a[e]!==G.params[e])return!0;for(let e of i.dependencies)if(B.some(t=>t(new URL(e))))return!0;return!1}function _t(e,t){return e?.type===`data`?e:e?.type===`skip`?t??null:null}function vt(e,t){if(!e)return new Set(t.searchParams.keys());let n=new Set([...e.searchParams.keys(),...t.searchParams.keys()]);for(let r of n){let i=e.searchParams.getAll(r),a=t.searchParams.getAll(r);i.every(e=>a.includes(e))&&a.every(e=>i.includes(e))&&n.delete(r)}return n}function yt({error:e,url:t,route:n,params:r}){return{type:`loaded`,state:{error:e,url:t,route:n,params:r,branch:[]},props:{page:Bt(A),constructors:[]}}}async function bt({id:e,invalidating:t,url:n,params:r,route:i,preload:a}){if(H?.id===e)return tt.delete(H.token),H.promise;let{errors:o,layouts:s,leaf:c}=i,d=[...s,c];o.forEach(e=>e?.().catch(h)),d.forEach(e=>e?.[1]().catch(h));let f=G.url?e!==Et(G.url):!1,p=G.route?i.id!==G.route.id:!1,ee=vt(G.url,n),m=!1,g=d.map(async(e,t)=>{if(!e)return;let a=G.branch[t];return e[1]===a?.loader&&!gt(m,p,f,ee,a.universal?.uses,r)?a:(m=!0,mt({loader:e[1],url:n,params:r,route:i,parent:async()=>{let e={};for(let n=0;n<t;n+=1)Object.assign(e,(await g[n])?.data);return e},server_data_node:_t(e[0]?{type:`skip`}:null,e[0]?a?.server:void 0)}))});for(let e of g)e.catch(h);let _=[];for(let e=0;e<d.length;e+=1)if(d[e])try{_.push(await g[e])}catch(t){if(t instanceof u)return{type:`redirect`,location:t.location};if(a&&tt.has(a))return yt({error:await $(t,{params:r,url:n,route:{id:i.id}}),url:n,params:r,route:i});let s=ke(t),c;if(t instanceof l)c=t.body;else{if(await F.updated.check())return await Be(),await I(n);c=await $(t,{params:r,url:n,route:{id:i.id}})}let d=await xt(e,_,o);return d?pt({url:n,params:r,branch:_.slice(0,d.idx).concat(d.node),errors:o,status:s,error:c,route:i}):await Ot(n,{id:i.id},c,s)}else _.push(void 0);return pt({url:n,params:r,branch:_,errors:o,status:200,error:null,route:i,form:t?void 0:null})}async function xt(e,t,n){for(;e--;)if(n[e]){let r=e;for(;!t[r];)--r;try{return{idx:r+1,node:{node:await n[e](),loader:n[e],data:{},server:null,universal:null}}}catch{continue}}}async function St({status:e,error:t,url:n,route:r}){let i={};try{return pt({url:n,params:i,branch:[await mt({loader:He,url:n,params:i,route:r,parent:()=>Promise.resolve({}),server_data_node:_t(null)}),{node:await L(),loader:L,universal:null,server:null,data:null}],status:e,error:t,errors:[],route:null})}catch(t){if(t instanceof u){await lt(new URL(t.location,location.href),{},0);return}let a=await z.get_error_template(),o=await $(t,{url:n,params:i,route:r}),s=a({status:e,message:String(o?.message??``).replace(/&/g,`&`).replace(/</g,`<`).replace(/>/g,`>`)}),c=new DOMParser().parseFromString(s,`text/html`);throw document.documentElement.replaceChild(document.adoptNode(c.head),document.head),document.documentElement.replaceChild(document.adoptNode(c.body),document.body),t}}async function Ct(e){let t=e.href;if(Ke.has(t))return Ke.get(t);let n;try{let r=(async()=>{let t=await z.hooks.reroute({url:new URL(e),fetch:async(t,n)=>ht(t,n,e).promise})??e;if(typeof t==`string`){let n=new URL(e);z.hash?n.hash=t:n.pathname=t,t=n}return t})();Ke.set(t,r),n=await r}catch{Ke.delete(t);return}return n}async function wt(e,t){if(e&&!O(e,x,z.hash)){let n=await Ct(e);if(!n)return;let r=Tt(n);for(let n of Ve){let i=n.exec(r);if(i)return{id:Et(e),invalidating:t,route:n,params:ee(i),url:e}}}}function Tt(e){return p(z.hash?e.hash.replace(/^#/,``).replace(/[?#].+/,``):e.pathname.slice(x.length))||`/`}function Et(e){return(z.hash?e.hash.replace(/^#/,``):e.pathname)+e.search}function Dt({url:e,type:t,intent:n,delta:r,event:i,scroll:a}){let o=!1,s=zt(G,n,e,t,a??null);r!==void 0&&(s.navigation.delta=r),i!==void 0&&(s.navigation.event=i);let c={...s.navigation,cancel:()=>{o=!0,s.reject(Error(`navigation cancelled`))}};return K||qe.forEach(e=>e(c)),o?null:s}async function Z({type:n,url:r,popped:i,keepfocus:a,noscroll:o,replace_state:s,state:c={},redirect_count:l=0,nav_token:u={},accept:f=h,block:p=h,event:ee}){let m=X;X=u;let g=await wt(r,!1),_=n===`enter`?zt(G,g,r,n):Dt({url:r,type:n,delta:i?.delta,intent:g,scroll:i?.scroll,event:ee});if(!_){p(),X===u&&(X=m);return}let te=J,v=Y;f(),K=!0,Xe&&_.navigation.type!==`enter`&&F.navigating.set(j.current=_.navigation);let y=g&&await bt(g);if(!y){if(O(r,x,z.hash))return await I(r,s);y=await Ot(r,{id:null},await $(new d(404,`Not Found`,`Not found: ${r.pathname}`),{url:r,params:{},route:{id:null}}),404,s)}if(r=g?.url||r,X!==u){_.reject(Error(`navigation aborted`));return}if(!y)return;if(y.type===`redirect`){if(l<20){await Z({type:n,url:new URL(y.location,r),popped:i,keepfocus:a,noscroll:o,replace_state:s,state:c,redirect_count:l+1,nav_token:u}),_.fulfil(void 0);return}if(y=await St({status:500,error:await $(Error(`Redirect loop`),{url:r,params:{},route:{id:null}}),url:r,route:{id:null}}),!y)return}else if(y.props.page.status>=400&&await F.updated.check())return await Be(),await I(r,s);if(at(),Re(te),ot(v),y.props.page.url.pathname!==r.pathname&&(r.pathname=y.props.page.url.pathname),c=i?i.state:c,!i){let e=+!s,t={[S]:J+=e,[C]:Y+=e,[ge]:c};(s?history.replaceState:history.pushState).call(history,t,``,r),s||ze(J,Y)}let ne=g&&H?.id===g.id?H.fork:null;H?.fork&&!ne?U():(H=null,Q={element:void 0,href:void 0}),y.props.page.state=c;let b;if(Xe){let t=(await Promise.all(Array.from(Je,e=>e(_.navigation)))).filter(e=>typeof e==`function`);if(t.length>0){function e(){t.forEach(e=>{W.delete(e)})}t.push(e),t.forEach(e=>{W.add(e)})}let n=_.navigation.to;G={...y.state,nav:{params:n.params,route:n.route,url:n.url}},y.props.page&&(y.props.page.url=r),!a&&document.activeElement instanceof HTMLElement&&document.activeElement!==document.body&&document.activeElement.blur();let i=ne&&await ne;i?b=i.commit():(M=null,et.$set(y.props),M&&Object.assign(y.props.page,M),Pe(y.props.page),b=e?.()),Qe=!0}else await ft(y,Ue,!1);let{activeElement:re}=document;if(await b,await t(),await t(),X!==u){_.reject(Error(`navigation aborted`));return}y.props.page&&M&&Object.assign(y.props.page,M);let ie=null;if(Ze){let e=i?i.scroll:o?T():null;e?scrollTo(e.x,e.y):(ie=r.hash&&document.getElementById(Ht(r)))?ie.scrollIntoView():scrollTo(0,0)}let ae=document.activeElement!==re&&document.activeElement!==document.body;!a&&!ae&&Rt(r,!ie),Ze=!0,K=!1,_.fulfil(void 0),_.navigation.to&&(_.navigation.to.scroll=T()),W.forEach(e=>e(_.navigation)),n===`popstate`&&st(Y),F.navigating.set(j.current=null)}async function Ot(e,t,n,r,i){return e.origin===_e&&e.pathname===location.pathname&&!Ye?await St({status:r,error:n,url:e,route:t}):await I(e,i)}var Q={element:void 0,href:void 0};function kt(){let e,t;R.addEventListener(`mousemove`,t=>{let n=t.target;clearTimeout(e),e=setTimeout(()=>{i(n,w.hover)},20)});function n(e){e.defaultPrevented||i(e.composedPath()[0],w.tap)}R.addEventListener(`mousedown`,n),R.addEventListener(`touchstart`,n,{passive:!0});let r=new IntersectionObserver(e=>{for(let t of e)t.isIntersecting&&(dt(new URL(t.target.href)),r.unobserve(t.target))},{threshold:0});async function i(e,n){let r=xe(e,R),i=r===Q.element&&r?.href===Q.href&&n>=t;if(!r||i)return;let{url:a,external:o,download:s}=Se(r,x,z.hash);if(o||s)return;let c=D(r),l=a&&Et(G.url)===Et(a);if(!(c.reload||l)){if(n<=c.preload_data){Q={element:r,href:r.href},t=w.tap;let e=await wt(a,!1);if(!e)return;ut(e)}else n<=c.preload_code&&(Q={element:r,href:r.href},t=n,dt(a))}}function a(){r.disconnect();for(let e of R.querySelectorAll(`a`)){let{url:t,external:n,download:i}=Se(e,x,z.hash);if(n||i)continue;let a=D(e);a.reload||(a.preload_code===w.viewport&&r.observe(e),a.preload_code===w.eager&&dt(t))}}W.add(a),a()}function $(e,t){if(e instanceof l)return e.body;let n=ke(e),r=Ae(e);return z.hooks.handleError({error:e,event:t,status:n,message:r})??{message:r}}function At(e,t){Fe(()=>(e.add(t),()=>{e.delete(t)}))}function jt(e){At(Je,e)}function Mt(e,t={}){return e=new URL(ve(e)),e.origin===_e?lt(e,t,0):Promise.reject(Error(`goto: invalid URL`))}function Nt(e){if(typeof e==`function`)B.push(e);else{let{href:t}=new URL(e,location.href);B.push(e=>e.href===t)}}function Pt(){history.scrollRestoration=`manual`,addEventListener(`beforeunload`,e=>{let t=!1;if(ct(),!K){let e=zt(G,void 0,null,`leave`),n={...e.navigation,cancel:()=>{t=!0,e.reject(Error(`navigation cancelled`))}};qe.forEach(e=>e(n))}t?(e.preventDefault(),e.returnValue=``):history.scrollRestoration=`auto`}),addEventListener(`visibilitychange`,()=>{document.visibilityState===`hidden`&&ct()}),navigator.connection?.saveData||kt(),R.addEventListener(`click`,async t=>{if(t.button||t.which!==1||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.defaultPrevented)return;let n=xe(t.composedPath()[0],R);if(!n)return;let{url:r,external:i,target:a,download:o}=Se(n,x,z.hash);if(!r)return;if(a===`_parent`||a===`_top`){if(window.parent!==window)return}else if(a&&a!==`_self`)return;let s=D(n);if(!(n instanceof SVGAElement)&&r.protocol!==location.protocol&&r.protocol!==`https:`&&r.protocol!==`http:`||o)return;let[c,l]=(z.hash?r.hash.replace(/^#/,``):r.href).split(`#`),u=c===m(location);if(i||s.reload&&(!u||!l)){Dt({url:r,type:`link`,event:t})?K=!0:t.preventDefault();return}if(l!==void 0&&u){let[,i]=G.url.href.split(`#`);if(i===l){if(t.preventDefault(),l===``||l===`top`&&n.ownerDocument.getElementById(`top`)===null)scrollTo({top:0});else{let e=n.ownerDocument.getElementById(decodeURIComponent(l));e&&(e.scrollIntoView(),e.focus())}return}if(q=!0,Re(J),e(r),!s.replace_state)return;q=!1}t.preventDefault(),await new Promise(e=>{requestAnimationFrame(()=>{setTimeout(e,0)}),setTimeout(e,100)}),await Z({type:`link`,url:r,keepfocus:s.keepfocus,noscroll:s.noscroll,replace_state:s.replace_state??r.href===location.href,event:t})}),R.addEventListener(`submit`,e=>{if(e.defaultPrevented)return;let t=HTMLFormElement.prototype.cloneNode.call(e.target),n=e.submitter;if((n?.formTarget||t.target)===`_blank`||(n?.formMethod||t.method)!==`get`)return;let r=new URL(n?.hasAttribute(`formaction`)&&n?.formAction||t.action);if(O(r,x,!1))return;let i=e.target,a=D(i);if(a.reload)return;e.preventDefault(),e.stopPropagation();let o=new FormData(i,n);r.search=new URLSearchParams(o).toString(),Z({type:`form`,url:r,keepfocus:a.keepfocus,noscroll:a.noscroll,replace_state:a.replace_state??r.href===location.href,event:e})}),addEventListener(`popstate`,async t=>{if(!Lt){if(t.state?.[`sveltekit:history`]){let n=t.state[S];if(X={},n===J)return;let r=N[n],i=t.state[`sveltekit:states`]??{},a=new URL(t.state[`sveltekit:pageurl`]??location.href),o=t.state[C],s=G.url?m(location)===m(G.url):!1;if(o===Y&&(Qe||s)){i!==A.state&&(A.state=i),e(a),N[J]=T(),r&&scrollTo(r.x,r.y),J=n;return}let c=n-J;await Z({type:`popstate`,url:a,popped:{state:i,scroll:r,delta:c},accept:()=>{J=n,Y=o},block:()=>{history.go(-c)},nav_token:X,event:t})}else q||(e(new URL(location.href)),z.hash&&location.reload())}}),addEventListener(`hashchange`,()=>{q&&(q=!1,history.replaceState({...history.state,[S]:++J,[C]:Y},``,location.href))});for(let e of document.querySelectorAll(`link`))Le.has(e.rel)&&(e.href=e.href);addEventListener(`pageshow`,e=>{e.persisted&&F.navigating.set(j.current=null)});function e(e){G.url=A.url=e,F.page.set(Bt(A)),F.page.notify()}}async function Ft(e,{status:t=200,error:n,node_ids:r,params:i,route:a,server_route:o,data:s,form:c}){Ye=!0;let l=new URL(location.href),d;({params:i={},route:a={id:null}}=await wt(l,!1)||{}),d=Ve.find(({id:e})=>e===a.id);let f,p=!0;try{let e=r.map(async(t,n)=>{let r=s[n];return r?.uses&&(r.uses=It(r.uses)),mt({loader:z.nodes[t],url:l,params:i,route:a,parent:async()=>{let t={};for(let r=0;r<n;r+=1)Object.assign(t,(await e[r]).data);return t},server_data_node:_t(r)})}),o=await Promise.all(e);if(d){let e=d.layouts;for(let t=0;t<e.length;t++)e[t]||o.splice(t,0,void 0)}f=await pt({url:l,params:i,branch:o,status:t,error:n,errors:d?.errors,form:c,route:d??null})}catch(t){if(t instanceof u)return await I(new URL(t.location,location.href));f=await St({status:ke(t),error:await $(t,{url:l,params:i,route:a}),url:l,route:a}),e.textContent=``,p=!1}f&&(f.props.page&&(f.props.page.state={}),await ft(f,e,p))}function It(e){return{dependencies:new Set(e?.dependencies??[]),params:new Set(e?.params??[]),parent:!!e?.parent,route:!!e?.route,url:!!e?.url,search_params:new Set(e?.search_params??[])}}var Lt=!1;function Rt(e,t=!0){let n=document.querySelector(`[autofocus]`);if(n)n.focus();else{let n=Ht(e);if(n&&document.getElementById(n)){let{x:r,y:i}=T();setTimeout(()=>{let a=history.state;Lt=!0,location.replace(new URL(`#${n}`,location.href)),history.replaceState(a,``,e),t&&scrollTo(r,i),Lt=!1})}else{let e=document.body,t=e.getAttribute(`tabindex`);e.tabIndex=-1,e.focus({preventScroll:!0,focusVisible:!1}),t===null?e.removeAttribute(`tabindex`):e.setAttribute(`tabindex`,t)}let r=getSelection();if(r&&r.type!==`None`){let e=[];for(let t=0;t<r.rangeCount;t+=1)e.push(r.getRangeAt(t));setTimeout(()=>{if(r.rangeCount===e.length){for(let t=0;t<r.rangeCount;t+=1){let n=e[t],i=r.getRangeAt(t);if(n.commonAncestorContainer!==i.commonAncestorContainer||n.startContainer!==i.startContainer||n.endContainer!==i.endContainer||n.startOffset!==i.startOffset||n.endOffset!==i.endOffset)return}r.removeAllRanges()}})}}}function zt(e,t,n,r,i=null){let a,o,s=new Promise((e,t)=>{a=e,o=t});return s.catch(h),{navigation:{from:{params:e.params,route:{id:e.route?.id??null},url:e.url,scroll:T()},to:n&&{params:t?.params??null,route:{id:t?.route?.id??null},url:n,scroll:i},willUnload:!t,type:r,complete:s},fulfil:a,reject:o}}function Bt(e){return{data:e.data,error:e.error,form:e.form,params:e.params,route:e.route,state:e.state,status:e.status,url:e.url}}function Vt(e){let t=new URL(e);return t.hash=decodeURIComponent(e.hash),t}function Ht(e){let t;if(z.hash){let[,,n]=e.hash.split(`#`,3);t=n??``}else t=e.hash.slice(1);return decodeURIComponent(t)}export{A as a,j as i,jt as n,Ee as o,it as r,x as s,Mt as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./C4dbyEfF.js";
|