@hiai-gg/docsmint 0.3.5 → 0.3.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -18
- package/backend/src/lib/lifecycle-service.ts +334 -219
- package/dist/backend/index.js +232 -18
- package/dist/backend-launcher.d.ts +15 -0
- package/dist/backend-launcher.js +22 -0
- package/dist/frontend/CategoryDialog--rIE7FrH.js +580 -0
- package/dist/frontend/ConfirmDialog-Cpzyb55f.js +212 -0
- package/dist/frontend/CreateSnapshotDialog-CmkV-n2A.js +216 -0
- package/dist/frontend/DatePicker-Byynca7V.js +257 -0
- package/dist/frontend/DeleteDialog-ap6nOywZ.js +174 -0
- package/dist/frontend/FolderDialog-DmN_trV0.js +247 -0
- package/dist/frontend/FolderNode-C4B8a2fd.js +317 -0
- package/dist/frontend/FolderTreeSelector-D6ijiZTA.js +100 -0
- package/dist/frontend/Icon-DtNo0N1U.js +64 -0
- package/dist/frontend/SettingsDialog-2kTaTXAs.js +992 -0
- package/dist/frontend/ShareDialog-BBDGNF5n.js +165 -0
- package/dist/frontend/TagCreateDialog-DiLZnJo4.js +258 -0
- package/dist/frontend/api/attachments.d.ts +6 -0
- package/dist/frontend/api/attachments.js +2 -0
- package/dist/frontend/api/categories.js +1 -1
- package/dist/frontend/api/documents.js +1 -1
- package/dist/frontend/api/folders.js +1 -1
- package/dist/frontend/api/settings.js +1 -1
- package/dist/frontend/api/share.d.ts +5 -0
- package/dist/frontend/api/share.js +2 -0
- package/dist/frontend/api/tags.js +1 -1
- package/dist/frontend/api-keys-CpkrA8rD.js +35 -0
- package/dist/frontend/attachments-BuILSs56.js +50 -0
- package/dist/frontend/{settings-PCrOtied.js → auth-client-Cygmp1I2.js} +205 -265
- package/dist/frontend/awareness-snQ3RD9f.js +3714 -0
- package/dist/frontend/bundle-mjs-CP6Owz-8.js +1723 -0
- package/dist/frontend/camera-B7dAOd4s.js +28 -0
- package/dist/frontend/{categories-BE6ZpZl8.js → categories-izQovv2w.js} +1 -1
- package/dist/frontend/check-CDwRlG9T.js +24 -0
- package/dist/frontend/chevron-down-B7ZrjUmT.js +24 -0
- package/dist/frontend/circle-check-CDqeMB2d.js +28 -0
- package/dist/frontend/{client-C6QQGb0e.js → client-Bc5Fzx40.js} +833 -814
- package/dist/frontend/{client-B9hzI0W8.js → client-GbtOH90i.js} +1 -1
- package/dist/frontend/clipboard-Cgzxc0_R.js +16 -0
- package/dist/frontend/clock-Ck5Sn-Zl.js +28 -0
- package/dist/frontend/clsx-nmtDPO_P.js +16 -0
- package/dist/frontend/collaboration.d.ts +6 -0
- package/dist/frontend/collaboration.js +182 -0
- package/dist/frontend/components/category-dialog.d.ts +2 -0
- package/dist/frontend/components/category-dialog.js +2 -0
- package/dist/frontend/components/create-snapshot-dialog.d.ts +2 -0
- package/dist/frontend/components/create-snapshot-dialog.js +2 -0
- package/dist/frontend/components/delete-dialog.d.ts +2 -0
- package/dist/frontend/components/delete-dialog.js +2 -0
- package/dist/frontend/components/editor/document-editor.d.ts +3 -0
- package/dist/frontend/components/editor/document-editor.js +3021 -0
- package/dist/frontend/components/editor/document-title.d.ts +2 -0
- package/dist/frontend/components/editor/document-title.js +31 -0
- package/dist/frontend/components/editor/docx-serializer.d.ts +2 -0
- package/dist/frontend/components/editor/docx-serializer.js +14600 -0
- package/dist/frontend/components/editor/extensions.d.ts +2 -0
- package/dist/frontend/components/editor/extensions.js +2 -0
- package/dist/frontend/components/editor/markdown-toggle.d.ts +2 -0
- package/dist/frontend/components/editor/markdown-toggle.js +72 -0
- package/dist/frontend/components/editor/markdown.d.ts +1 -0
- package/dist/frontend/components/editor/markdown.js +2 -0
- package/dist/frontend/components/folder-node.d.ts +3 -0
- package/dist/frontend/components/folder-node.js +2 -0
- package/dist/frontend/components/folder-tree-selector.d.ts +2 -0
- package/dist/frontend/components/folder-tree-selector.js +2 -0
- package/dist/frontend/components/save-as-dialog.d.ts +2 -0
- package/dist/frontend/components/save-as-dialog.js +254 -0
- package/dist/frontend/components/settings.js +1 -1
- package/dist/frontend/components/share-dialog.d.ts +2 -0
- package/dist/frontend/components/share-dialog.js +2 -0
- package/dist/frontend/components/sidebar.js +1206 -3762
- package/dist/frontend/components/tag-create-dialog.d.ts +2 -0
- package/dist/frontend/components/tag-create-dialog.js +2 -0
- package/dist/frontend/components/version-history.d.ts +2 -0
- package/dist/frontend/components/version-history.js +293 -0
- package/dist/frontend/{context-DbnW5yib.js → context-BMD6XTPe.js} +0 -3
- package/dist/frontend/copy-CMAA6GP0.js +31 -0
- package/dist/frontend/dashboard.js +1148 -1224
- package/dist/frontend/{SettingsDialog-D4pgFD0D.js → db-ByrlYfaI.js} +923 -2002
- package/dist/frontend/dialog-BDkiG42a.js +213 -0
- package/dist/frontend/disclose-version-5I57E3LD.js +3 -0
- package/dist/frontend/dndzone-BzsOINtP.js +1199 -0
- package/dist/frontend/doc-tabs.d.ts +7 -0
- package/dist/frontend/doc-tabs.js +14 -0
- package/dist/frontend/document-drop-coordinator-C4xHMjwC.js +68 -0
- package/dist/frontend/document-drop-coordinator.d.ts +2 -0
- package/dist/frontend/document-drop-coordinator.js +2 -0
- package/dist/frontend/{documents-DFVS9SsL.js → documents-BsDkvzCm.js} +1 -1
- package/dist/frontend/editorExtensions-BMHvUbdk.js +27021 -0
- package/dist/frontend/ellipsis-vertical-BBuPldbW.js +519 -0
- package/dist/frontend/extension.d.ts +2 -1
- package/dist/frontend/extension.js +6 -5
- package/dist/frontend/floating-layer-anchor-C51M4l6v.js +4513 -0
- package/dist/frontend/folder-TQjKY4yn.js +44 -0
- package/dist/frontend/folder-refresh.d.ts +8 -0
- package/dist/frontend/folder-refresh.js +2 -0
- package/dist/frontend/{folders-CGe9diAG.js → folders-CTuV_JtU.js} +1 -1
- package/dist/frontend/frontend.css +1 -1
- package/dist/frontend/i18n.js +1 -1
- package/dist/frontend/identity-DyWeNzu_.js +69 -0
- package/dist/frontend/index-client-jobkrWVL.js +86 -0
- package/dist/frontend/input-CBI6p4Xl.js +23 -0
- package/dist/frontend/keyboard.d.ts +14 -0
- package/dist/frontend/keyboard.js +2 -0
- package/dist/frontend/keyboard.svelte-D7H8DihC.js +133 -0
- package/dist/frontend/label-C-GkhEp4.js +30 -0
- package/dist/frontend/loader-circle-Bk-WFz9g.js +267 -0
- package/dist/frontend/markdown-BwnyjITU.js +11 -0
- package/dist/frontend/messages-BpYaLbzE.js +1091 -0
- package/dist/frontend/offline/identity.d.ts +6 -0
- package/dist/frontend/offline/identity.js +2 -0
- package/dist/frontend/resolve-BG4HgzpN.js +19 -0
- package/dist/frontend/rolldown-runtime-CWhphoD1.js +23 -0
- package/dist/frontend/rotate-ccw-CleZtJ5D.js +24 -0
- package/dist/frontend/search.js +637 -628
- package/dist/frontend/select-value-CvrWRkXW.js +1436 -0
- package/dist/frontend/settings-blyobazp.js +62 -0
- package/dist/frontend/share-Cu7SSJuJ.js +28 -0
- package/dist/frontend/shared-document.js +105 -69
- package/dist/frontend/subfolders-refresh-store.svelte-BsheoQma.js +65 -0
- package/dist/frontend/{tag-C5xrg-bb.js → tag-Dx3SmucJ.js} +7 -7
- package/dist/frontend/tag-store.svelte-CIaF4sdZ.js +29 -0
- package/dist/frontend/{tags-DVXTut0p.js → tags-CtCV0Djo.js} +1 -1
- package/dist/frontend/textarea-Dfp78XlL.js +23 -0
- package/dist/frontend/theme.js +1 -1
- package/dist/frontend/{theme.svelte-ei0QxXa8.js → theme.svelte-CROg1Hi5.js} +7 -7
- package/dist/frontend/types.d.ts +6 -0
- package/dist/frontend/types.js +0 -0
- package/dist/frontend/utils/clipboard.d.ts +1 -0
- package/dist/frontend/utils/clipboard.js +2 -0
- package/dist/frontend/utils/dndzone.d.ts +4 -0
- package/dist/frontend/utils/dndzone.js +2 -0
- package/dist/frontend/utils-C0OW2678.js +20 -0
- package/dist/frontend/utils-D8kmM3ub.js +8 -0
- package/dist/frontend/utils.d.ts +4 -0
- package/dist/frontend/utils.js +2 -0
- package/dist/frontend/x-DaTdeDXv.js +24 -0
- package/dist/lifecycle-persistent.d.ts +31 -0
- package/dist/lifecycle-persistent.js +33 -0
- package/dist/server-only-browser-entry.d.ts +0 -0
- package/dist/server-only-browser-entry.js +3 -0
- package/dist/storage-quota.d.ts +36 -0
- package/dist/storage-quota.js +14 -1
- package/dist/types.d.ts +7 -0
- package/dist/workspace.d.ts +4 -1
- package/dist/workspace.js +29 -8
- package/package.json +110 -3
- package/packages/cli/src/index.ts +1 -1
- package/packages/db/src/index.ts +11 -2
- package/packages/db/src/schema.ts +30 -2
- package/packages/db/src/with-tenant.ts +38 -1
- package/packages/mcp-server/src/index.ts +1 -1
- package/dist/frontend/DatePicker-BcMD49PV.js +0 -275
- package/dist/frontend/ShareDialog-Dzh7rV7J.js +0 -1317
- package/dist/frontend/input-ieWIt8I7.js +0 -257
- package/dist/frontend/messages-CTGAsqFu.js +0 -1106
- package/dist/frontend/resolve-Bl6xmJl_.js +0 -2068
- package/dist/frontend/tag-store.svelte-B3839FYq.js +0 -6152
|
@@ -0,0 +1,4513 @@
|
|
|
1
|
+
import "./disclose-version-5I57E3LD.js";
|
|
2
|
+
import { $ as e, A as t, D as n, E as r, G as i, J as a, M as o, O as s, V as c, at as l, ct as u, dt as d, et as f, ft as p, i as m, j as h, lt as g, n as _, q as v, r as y, rt as b, tt as x, vt as S, z as C } from "./client-Bc5Fzx40.js";
|
|
3
|
+
import { t as w } from "./clsx-nmtDPO_P.js";
|
|
4
|
+
import { t as T } from "./index-client-jobkrWVL.js";
|
|
5
|
+
import { getContext as E, hasContext as D, onMount as O, setContext as ee, tick as k, untrack as A } from "svelte";
|
|
6
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/is.js
|
|
7
|
+
function te(e) {
|
|
8
|
+
return typeof e == "function";
|
|
9
|
+
}
|
|
10
|
+
function j(e) {
|
|
11
|
+
return typeof e == "object" && !!e;
|
|
12
|
+
}
|
|
13
|
+
var ne = [
|
|
14
|
+
"string",
|
|
15
|
+
"number",
|
|
16
|
+
"bigint",
|
|
17
|
+
"boolean"
|
|
18
|
+
];
|
|
19
|
+
function re(e) {
|
|
20
|
+
return e == null || ne.includes(typeof e) ? !0 : Array.isArray(e) ? e.every((e) => re(e)) : typeof e == "object" ? Object.getPrototypeOf(e) === Object.prototype : !1;
|
|
21
|
+
}
|
|
22
|
+
//#endregion
|
|
23
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/box/box-extras.svelte.js
|
|
24
|
+
var ie = Symbol("box"), ae = Symbol("is-writable");
|
|
25
|
+
function M(e, t) {
|
|
26
|
+
let n = u(e);
|
|
27
|
+
return t ? {
|
|
28
|
+
[ie]: !0,
|
|
29
|
+
[ae]: !0,
|
|
30
|
+
get current() {
|
|
31
|
+
return c(n);
|
|
32
|
+
},
|
|
33
|
+
set current(e) {
|
|
34
|
+
t(e);
|
|
35
|
+
}
|
|
36
|
+
} : {
|
|
37
|
+
[ie]: !0,
|
|
38
|
+
get current() {
|
|
39
|
+
return e();
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function oe(e) {
|
|
44
|
+
return j(e) && ie in e;
|
|
45
|
+
}
|
|
46
|
+
function se(e) {
|
|
47
|
+
return oe(e) && ae in e;
|
|
48
|
+
}
|
|
49
|
+
function ce(e) {
|
|
50
|
+
return oe(e) ? e : te(e) ? M(e) : N(e);
|
|
51
|
+
}
|
|
52
|
+
function le(e) {
|
|
53
|
+
return Object.entries(e).reduce((e, [t, n]) => oe(n) ? (se(n) ? Object.defineProperty(e, t, {
|
|
54
|
+
get() {
|
|
55
|
+
return n.current;
|
|
56
|
+
},
|
|
57
|
+
set(e) {
|
|
58
|
+
n.current = e;
|
|
59
|
+
}
|
|
60
|
+
}) : Object.defineProperty(e, t, { get() {
|
|
61
|
+
return n.current;
|
|
62
|
+
} }), e) : Object.assign(e, { [t]: n }), {});
|
|
63
|
+
}
|
|
64
|
+
function ue(e) {
|
|
65
|
+
return se(e) ? {
|
|
66
|
+
[ie]: !0,
|
|
67
|
+
get current() {
|
|
68
|
+
return e.current;
|
|
69
|
+
}
|
|
70
|
+
} : e;
|
|
71
|
+
}
|
|
72
|
+
function N(e) {
|
|
73
|
+
let t = l(x(e));
|
|
74
|
+
return {
|
|
75
|
+
[ie]: !0,
|
|
76
|
+
[ae]: !0,
|
|
77
|
+
get current() {
|
|
78
|
+
return c(t);
|
|
79
|
+
},
|
|
80
|
+
set current(e) {
|
|
81
|
+
b(t, e, !0);
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
//#endregion
|
|
86
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/box/box.svelte.js
|
|
87
|
+
function de(e) {
|
|
88
|
+
let t = l(x(e));
|
|
89
|
+
return {
|
|
90
|
+
[ie]: !0,
|
|
91
|
+
[ae]: !0,
|
|
92
|
+
get current() {
|
|
93
|
+
return c(t);
|
|
94
|
+
},
|
|
95
|
+
set current(e) {
|
|
96
|
+
b(t, e, !0);
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
de.from = ce, de.with = M, de.flatten = le, de.readonly = ue, de.isBox = oe, de.isWritableBox = se;
|
|
101
|
+
//#endregion
|
|
102
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/compose-handlers.js
|
|
103
|
+
function fe(...e) {
|
|
104
|
+
return function(t) {
|
|
105
|
+
for (let n of e) if (n) {
|
|
106
|
+
if (t.defaultPrevented) return;
|
|
107
|
+
typeof n == "function" ? n.call(this, t) : n.current?.call(this, t);
|
|
108
|
+
}
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
//#endregion
|
|
112
|
+
//#region ../node_modules/.bun/inline-style-parser@0.2.7/node_modules/inline-style-parser/esm/index.mjs
|
|
113
|
+
var pe = /\/\*[^*]*\*+([^/*][^*]*\*+)*\//g, me = /\n/g, he = /^\s*/, ge = /^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/, _e = /^:\s*/, ve = /^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/, ye = /^[;\s]*/, be = /^\s+|\s+$/g, xe = "\n", Se = "/", Ce = "*", we = "", Te = "comment", Ee = "declaration";
|
|
114
|
+
function De(e, t) {
|
|
115
|
+
if (typeof e != "string") throw TypeError("First argument must be a string");
|
|
116
|
+
if (!e) return [];
|
|
117
|
+
t ||= {};
|
|
118
|
+
var n = 1, r = 1;
|
|
119
|
+
function i(e) {
|
|
120
|
+
var t = e.match(me);
|
|
121
|
+
t && (n += t.length);
|
|
122
|
+
var i = e.lastIndexOf(xe);
|
|
123
|
+
r = ~i ? e.length - i : r + e.length;
|
|
124
|
+
}
|
|
125
|
+
function a() {
|
|
126
|
+
var e = {
|
|
127
|
+
line: n,
|
|
128
|
+
column: r
|
|
129
|
+
};
|
|
130
|
+
return function(t) {
|
|
131
|
+
return t.position = new o(e), l(), t;
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
function o(e) {
|
|
135
|
+
this.start = e, this.end = {
|
|
136
|
+
line: n,
|
|
137
|
+
column: r
|
|
138
|
+
}, this.source = t.source;
|
|
139
|
+
}
|
|
140
|
+
o.prototype.content = e;
|
|
141
|
+
function s(i) {
|
|
142
|
+
var a = /* @__PURE__ */ Error(t.source + ":" + n + ":" + r + ": " + i);
|
|
143
|
+
if (a.reason = i, a.filename = t.source, a.line = n, a.column = r, a.source = e, !t.silent) throw a;
|
|
144
|
+
}
|
|
145
|
+
function c(t) {
|
|
146
|
+
var n = t.exec(e);
|
|
147
|
+
if (n) {
|
|
148
|
+
var r = n[0];
|
|
149
|
+
return i(r), e = e.slice(r.length), n;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
function l() {
|
|
153
|
+
c(he);
|
|
154
|
+
}
|
|
155
|
+
function u(e) {
|
|
156
|
+
var t;
|
|
157
|
+
for (e ||= []; t = d();) t !== !1 && e.push(t);
|
|
158
|
+
return e;
|
|
159
|
+
}
|
|
160
|
+
function d() {
|
|
161
|
+
var t = a();
|
|
162
|
+
if (!(Se != e.charAt(0) || Ce != e.charAt(1))) {
|
|
163
|
+
for (var n = 2; we != e.charAt(n) && (Ce != e.charAt(n) || Se != e.charAt(n + 1));) ++n;
|
|
164
|
+
if (n += 2, we === e.charAt(n - 1)) return s("End of comment missing");
|
|
165
|
+
var o = e.slice(2, n - 2);
|
|
166
|
+
return r += 2, i(o), e = e.slice(n), r += 2, t({
|
|
167
|
+
type: Te,
|
|
168
|
+
comment: o
|
|
169
|
+
});
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
function f() {
|
|
173
|
+
var e = a(), t = c(ge);
|
|
174
|
+
if (t) {
|
|
175
|
+
if (d(), !c(_e)) return s("property missing ':'");
|
|
176
|
+
var n = c(ve), r = e({
|
|
177
|
+
type: Ee,
|
|
178
|
+
property: Oe(t[0].replace(pe, we)),
|
|
179
|
+
value: n ? Oe(n[0].replace(pe, we)) : we
|
|
180
|
+
});
|
|
181
|
+
return c(ye), r;
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
function p() {
|
|
185
|
+
var e = [];
|
|
186
|
+
u(e);
|
|
187
|
+
for (var t; t = f();) t !== !1 && (e.push(t), u(e));
|
|
188
|
+
return e;
|
|
189
|
+
}
|
|
190
|
+
return l(), p();
|
|
191
|
+
}
|
|
192
|
+
function Oe(e) {
|
|
193
|
+
return e ? e.replace(be, we) : we;
|
|
194
|
+
}
|
|
195
|
+
//#endregion
|
|
196
|
+
//#region ../node_modules/.bun/style-to-object@1.0.14/node_modules/style-to-object/esm/index.mjs
|
|
197
|
+
function ke(e, t) {
|
|
198
|
+
let n = null;
|
|
199
|
+
if (!e || typeof e != "string") return n;
|
|
200
|
+
let r = De(e), i = typeof t == "function";
|
|
201
|
+
return r.forEach((e) => {
|
|
202
|
+
if (e.type !== "declaration") return;
|
|
203
|
+
let { property: r, value: a } = e;
|
|
204
|
+
i ? t(r, a, e) : a && (n ||= {}, n[r] = a);
|
|
205
|
+
}), n;
|
|
206
|
+
}
|
|
207
|
+
//#endregion
|
|
208
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/strings.js
|
|
209
|
+
var Ae = /\d/, je = [
|
|
210
|
+
"-",
|
|
211
|
+
"_",
|
|
212
|
+
"/",
|
|
213
|
+
"."
|
|
214
|
+
];
|
|
215
|
+
function Me(e = "") {
|
|
216
|
+
if (!Ae.test(e)) return e !== e.toLowerCase();
|
|
217
|
+
}
|
|
218
|
+
function Ne(e) {
|
|
219
|
+
let t = [], n = "", r, i;
|
|
220
|
+
for (let a of e) {
|
|
221
|
+
let e = je.includes(a);
|
|
222
|
+
if (e === !0) {
|
|
223
|
+
t.push(n), n = "", r = void 0;
|
|
224
|
+
continue;
|
|
225
|
+
}
|
|
226
|
+
let o = Me(a);
|
|
227
|
+
if (i === !1) {
|
|
228
|
+
if (r === !1 && o === !0) {
|
|
229
|
+
t.push(n), n = a, r = o;
|
|
230
|
+
continue;
|
|
231
|
+
}
|
|
232
|
+
if (r === !0 && o === !1 && n.length > 1) {
|
|
233
|
+
let e = n.at(-1);
|
|
234
|
+
t.push(n.slice(0, Math.max(0, n.length - 1))), n = e + a, r = o;
|
|
235
|
+
continue;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
n += a, r = o, i = e;
|
|
239
|
+
}
|
|
240
|
+
return t.push(n), t;
|
|
241
|
+
}
|
|
242
|
+
function Pe(e) {
|
|
243
|
+
return e ? Ne(e).map((e) => Ie(e)).join("") : "";
|
|
244
|
+
}
|
|
245
|
+
function Fe(e) {
|
|
246
|
+
return Le(Pe(e || ""));
|
|
247
|
+
}
|
|
248
|
+
function Ie(e) {
|
|
249
|
+
return e ? e[0].toUpperCase() + e.slice(1) : "";
|
|
250
|
+
}
|
|
251
|
+
function Le(e) {
|
|
252
|
+
return e ? e[0].toLowerCase() + e.slice(1) : "";
|
|
253
|
+
}
|
|
254
|
+
//#endregion
|
|
255
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/css-to-style-obj.js
|
|
256
|
+
function Re(e) {
|
|
257
|
+
if (!e) return {};
|
|
258
|
+
let t = {};
|
|
259
|
+
function n(e, n) {
|
|
260
|
+
if (e.startsWith("-moz-") || e.startsWith("-webkit-") || e.startsWith("-ms-") || e.startsWith("-o-")) {
|
|
261
|
+
t[Pe(e)] = n;
|
|
262
|
+
return;
|
|
263
|
+
}
|
|
264
|
+
if (e.startsWith("--")) {
|
|
265
|
+
t[e] = n;
|
|
266
|
+
return;
|
|
267
|
+
}
|
|
268
|
+
t[Fe(e)] = n;
|
|
269
|
+
}
|
|
270
|
+
return ke(e, n), t;
|
|
271
|
+
}
|
|
272
|
+
//#endregion
|
|
273
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/execute-callbacks.js
|
|
274
|
+
function ze(...e) {
|
|
275
|
+
return (...t) => {
|
|
276
|
+
for (let n of e) typeof n == "function" && n(...t);
|
|
277
|
+
};
|
|
278
|
+
}
|
|
279
|
+
//#endregion
|
|
280
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/style-to-css.js
|
|
281
|
+
function Be(e, t) {
|
|
282
|
+
let n = RegExp(e, "g");
|
|
283
|
+
return (e) => {
|
|
284
|
+
if (typeof e != "string") throw TypeError(`expected an argument of type string, but got ${typeof e}`);
|
|
285
|
+
return e.match(n) ? e.replace(n, t) : e;
|
|
286
|
+
};
|
|
287
|
+
}
|
|
288
|
+
var Ve = Be(/[A-Z]/, (e) => `-${e.toLowerCase()}`);
|
|
289
|
+
function He(e) {
|
|
290
|
+
if (!e || typeof e != "object" || Array.isArray(e)) throw TypeError(`expected an argument of type object, but got ${typeof e}`);
|
|
291
|
+
return Object.keys(e).map((t) => `${Ve(t)}: ${e[t]};`).join("\n");
|
|
292
|
+
}
|
|
293
|
+
//#endregion
|
|
294
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/style.js
|
|
295
|
+
function Ue(e = {}) {
|
|
296
|
+
return He(e).replace("\n", " ");
|
|
297
|
+
}
|
|
298
|
+
var We = new Set(/* @__PURE__ */ "onabort.onanimationcancel.onanimationend.onanimationiteration.onanimationstart.onauxclick.onbeforeinput.onbeforetoggle.onblur.oncancel.oncanplay.oncanplaythrough.onchange.onclick.onclose.oncompositionend.oncompositionstart.oncompositionupdate.oncontextlost.oncontextmenu.oncontextrestored.oncopy.oncuechange.oncut.ondblclick.ondrag.ondragend.ondragenter.ondragleave.ondragover.ondragstart.ondrop.ondurationchange.onemptied.onended.onerror.onfocus.onfocusin.onfocusout.onformdata.ongotpointercapture.oninput.oninvalid.onkeydown.onkeypress.onkeyup.onload.onloadeddata.onloadedmetadata.onloadstart.onlostpointercapture.onmousedown.onmouseenter.onmouseleave.onmousemove.onmouseout.onmouseover.onmouseup.onpaste.onpause.onplay.onplaying.onpointercancel.onpointerdown.onpointerenter.onpointerleave.onpointermove.onpointerout.onpointerover.onpointerup.onprogress.onratechange.onreset.onresize.onscroll.onscrollend.onsecuritypolicyviolation.onseeked.onseeking.onselect.onselectionchange.onselectstart.onslotchange.onstalled.onsubmit.onsuspend.ontimeupdate.ontoggle.ontouchcancel.ontouchend.ontouchmove.ontouchstart.ontransitioncancel.ontransitionend.ontransitionrun.ontransitionstart.onvolumechange.onwaiting.onwebkitanimationend.onwebkitanimationiteration.onwebkitanimationstart.onwebkittransitionend.onwheel".split("."));
|
|
299
|
+
//#endregion
|
|
300
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/merge-props.js
|
|
301
|
+
function Ge(e) {
|
|
302
|
+
return We.has(e);
|
|
303
|
+
}
|
|
304
|
+
function Ke(...e) {
|
|
305
|
+
let t = { ...e[0] };
|
|
306
|
+
for (let n = 1; n < e.length; n++) {
|
|
307
|
+
let r = e[n];
|
|
308
|
+
if (r) {
|
|
309
|
+
for (let e of Object.keys(r)) {
|
|
310
|
+
let n = t[e], i = r[e], a = typeof n == "function", o = typeof i == "function";
|
|
311
|
+
if (a && typeof o && Ge(e)) t[e] = fe(n, i);
|
|
312
|
+
else if (a && o) t[e] = ze(n, i);
|
|
313
|
+
else if (e === "class") {
|
|
314
|
+
let r = re(n), a = re(i);
|
|
315
|
+
r && a ? t[e] = w(n, i) : r ? t[e] = w(n) : a && (t[e] = w(i));
|
|
316
|
+
} else if (e === "style") {
|
|
317
|
+
let r = typeof n == "object", a = typeof i == "object", o = typeof n == "string", s = typeof i == "string";
|
|
318
|
+
if (r && a) t[e] = {
|
|
319
|
+
...n,
|
|
320
|
+
...i
|
|
321
|
+
};
|
|
322
|
+
else if (r && s) {
|
|
323
|
+
let r = Re(i);
|
|
324
|
+
t[e] = {
|
|
325
|
+
...n,
|
|
326
|
+
...r
|
|
327
|
+
};
|
|
328
|
+
} else if (o && a) t[e] = {
|
|
329
|
+
...Re(n),
|
|
330
|
+
...i
|
|
331
|
+
};
|
|
332
|
+
else if (o && s) {
|
|
333
|
+
let r = Re(n), a = Re(i);
|
|
334
|
+
t[e] = {
|
|
335
|
+
...r,
|
|
336
|
+
...a
|
|
337
|
+
};
|
|
338
|
+
} else r ? t[e] = n : a ? t[e] = i : o ? t[e] = n : s && (t[e] = i);
|
|
339
|
+
} else t[e] = i === void 0 ? n : i;
|
|
340
|
+
}
|
|
341
|
+
for (let e of Object.getOwnPropertySymbols(r)) {
|
|
342
|
+
let n = t[e], i = r[e];
|
|
343
|
+
t[e] = i === void 0 ? n : i;
|
|
344
|
+
}
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
return typeof t.style == "object" && (t.style = Ue(t.style).replaceAll("\n", " ")), t.hidden === !1 && (t.hidden = void 0, delete t.hidden), t.disabled === !1 && (t.disabled = void 0, delete t.disabled), t;
|
|
348
|
+
}
|
|
349
|
+
//#endregion
|
|
350
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/on-destroy-effect.svelte.js
|
|
351
|
+
function P(e) {
|
|
352
|
+
v(() => () => {
|
|
353
|
+
e();
|
|
354
|
+
});
|
|
355
|
+
}
|
|
356
|
+
//#endregion
|
|
357
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/after-sleep.js
|
|
358
|
+
function qe(e, t) {
|
|
359
|
+
return setTimeout(t, e);
|
|
360
|
+
}
|
|
361
|
+
//#endregion
|
|
362
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/after-tick.js
|
|
363
|
+
function F(e) {
|
|
364
|
+
k().then(e);
|
|
365
|
+
}
|
|
366
|
+
//#endregion
|
|
367
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/dom.js
|
|
368
|
+
var Je = 1, Ye = 9, Xe = 11;
|
|
369
|
+
function Ze(e) {
|
|
370
|
+
return j(e) && e.nodeType === Je && typeof e.nodeName == "string";
|
|
371
|
+
}
|
|
372
|
+
function Qe(e) {
|
|
373
|
+
return j(e) && e.nodeType === Ye;
|
|
374
|
+
}
|
|
375
|
+
function $e(e) {
|
|
376
|
+
return j(e) && e.constructor?.name === "VisualViewport";
|
|
377
|
+
}
|
|
378
|
+
function et(e) {
|
|
379
|
+
return j(e) && e.nodeType !== void 0;
|
|
380
|
+
}
|
|
381
|
+
function tt(e) {
|
|
382
|
+
return et(e) && e.nodeType === Xe && "host" in e;
|
|
383
|
+
}
|
|
384
|
+
function nt(e, t) {
|
|
385
|
+
if (!e || !t || !Ze(e) || !Ze(t)) return !1;
|
|
386
|
+
let n = t.getRootNode?.();
|
|
387
|
+
if (e === t || e.contains(t)) return !0;
|
|
388
|
+
if (n && tt(n)) {
|
|
389
|
+
let n = t;
|
|
390
|
+
for (; n;) {
|
|
391
|
+
if (e === n) return !0;
|
|
392
|
+
n = n.parentNode || n.host;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
return !1;
|
|
396
|
+
}
|
|
397
|
+
function rt(e) {
|
|
398
|
+
return Qe(e) ? e : $e(e) ? e.document : e?.ownerDocument ?? document;
|
|
399
|
+
}
|
|
400
|
+
function it(e) {
|
|
401
|
+
return tt(e) ? it(e.host) : Qe(e) ? e.defaultView ?? window : Ze(e) ? e.ownerDocument?.defaultView ?? window : window;
|
|
402
|
+
}
|
|
403
|
+
function at(e) {
|
|
404
|
+
let t = e.activeElement;
|
|
405
|
+
for (; t?.shadowRoot;) {
|
|
406
|
+
let e = t.shadowRoot.activeElement;
|
|
407
|
+
if (e === t) break;
|
|
408
|
+
t = e;
|
|
409
|
+
}
|
|
410
|
+
return t;
|
|
411
|
+
}
|
|
412
|
+
//#endregion
|
|
413
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/dom-context.svelte.js
|
|
414
|
+
var ot = class {
|
|
415
|
+
element;
|
|
416
|
+
#e = u(() => this.element.current ? this.element.current.getRootNode() ?? document : document);
|
|
417
|
+
get root() {
|
|
418
|
+
return c(this.#e);
|
|
419
|
+
}
|
|
420
|
+
set root(e) {
|
|
421
|
+
b(this.#e, e);
|
|
422
|
+
}
|
|
423
|
+
constructor(e) {
|
|
424
|
+
typeof e == "function" ? this.element = M(e) : this.element = e;
|
|
425
|
+
}
|
|
426
|
+
getDocument = () => rt(this.root);
|
|
427
|
+
getWindow = () => this.getDocument().defaultView ?? window;
|
|
428
|
+
getActiveElement = () => at(this.root);
|
|
429
|
+
isActiveElement = (e) => e === this.getActiveElement();
|
|
430
|
+
getElementById(e) {
|
|
431
|
+
return this.root.getElementById(e);
|
|
432
|
+
}
|
|
433
|
+
querySelector = (e) => this.root ? this.root.querySelector(e) : null;
|
|
434
|
+
querySelectorAll = (e) => this.root ? this.root.querySelectorAll(e) : [];
|
|
435
|
+
setTimeout = (e, t) => this.getWindow().setTimeout(e, t);
|
|
436
|
+
clearTimeout = (e) => this.getWindow().clearTimeout(e);
|
|
437
|
+
};
|
|
438
|
+
//#endregion
|
|
439
|
+
//#region ../node_modules/.bun/svelte-toolbelt@0.10.6+68f06e2e1fdd21f8/node_modules/svelte-toolbelt/dist/utils/attach-ref.js
|
|
440
|
+
function I(e, t) {
|
|
441
|
+
return { [n()]: (n) => oe(e) ? (e.current = n, A(() => t?.(n)), () => {
|
|
442
|
+
"isConnected" in n && n.isConnected || (e.current = null, t?.(null));
|
|
443
|
+
}) : (e(n), A(() => t?.(n)), () => {
|
|
444
|
+
"isConnected" in n && n.isConnected || (e(null), t?.(null));
|
|
445
|
+
}) };
|
|
446
|
+
}
|
|
447
|
+
//#endregion
|
|
448
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/internal/configurable-globals.js
|
|
449
|
+
var st = typeof window < "u" ? window : void 0;
|
|
450
|
+
typeof window < "u" && window.document, typeof window < "u" && window.navigator, typeof window < "u" && window.location;
|
|
451
|
+
//#endregion
|
|
452
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/internal/utils/dom.js
|
|
453
|
+
function ct(e) {
|
|
454
|
+
let t = e.activeElement;
|
|
455
|
+
for (; t?.shadowRoot;) {
|
|
456
|
+
let e = t.shadowRoot.activeElement;
|
|
457
|
+
if (e === t) break;
|
|
458
|
+
t = e;
|
|
459
|
+
}
|
|
460
|
+
return t;
|
|
461
|
+
}
|
|
462
|
+
new class {
|
|
463
|
+
#e;
|
|
464
|
+
#t;
|
|
465
|
+
constructor(e = {}) {
|
|
466
|
+
let { window: t = st, document: n = t?.document } = e;
|
|
467
|
+
t !== void 0 && (this.#e = n, this.#t = g((e) => {
|
|
468
|
+
let n = C(t, "focusin", e), r = C(t, "focusout", e);
|
|
469
|
+
return () => {
|
|
470
|
+
n(), r();
|
|
471
|
+
};
|
|
472
|
+
}));
|
|
473
|
+
}
|
|
474
|
+
get current() {
|
|
475
|
+
return this.#t?.(), this.#e ? ct(this.#e) : null;
|
|
476
|
+
}
|
|
477
|
+
}();
|
|
478
|
+
//#endregion
|
|
479
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/internal/utils/is.js
|
|
480
|
+
function lt(e) {
|
|
481
|
+
return typeof e == "function";
|
|
482
|
+
}
|
|
483
|
+
//#endregion
|
|
484
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/utilities/context/context.js
|
|
485
|
+
var L = class {
|
|
486
|
+
#e;
|
|
487
|
+
#t;
|
|
488
|
+
constructor(e) {
|
|
489
|
+
this.#e = e, this.#t = Symbol(e);
|
|
490
|
+
}
|
|
491
|
+
get key() {
|
|
492
|
+
return this.#t;
|
|
493
|
+
}
|
|
494
|
+
exists() {
|
|
495
|
+
return D(this.#t);
|
|
496
|
+
}
|
|
497
|
+
get() {
|
|
498
|
+
let e = E(this.#t);
|
|
499
|
+
if (e === void 0) throw Error(`Context "${this.#e}" not found`);
|
|
500
|
+
return e;
|
|
501
|
+
}
|
|
502
|
+
getOr(e) {
|
|
503
|
+
let t = E(this.#t);
|
|
504
|
+
return t === void 0 ? e : t;
|
|
505
|
+
}
|
|
506
|
+
set(e) {
|
|
507
|
+
return ee(this.#t, e);
|
|
508
|
+
}
|
|
509
|
+
};
|
|
510
|
+
//#endregion
|
|
511
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/utilities/watch/watch.svelte.js
|
|
512
|
+
function ut(e, t) {
|
|
513
|
+
switch (e) {
|
|
514
|
+
case "post":
|
|
515
|
+
v(t);
|
|
516
|
+
break;
|
|
517
|
+
case "pre":
|
|
518
|
+
a(t);
|
|
519
|
+
break;
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
function dt(e, t, n, r = {}) {
|
|
523
|
+
let { lazy: i = !1 } = r, a = !i, o = Array.isArray(e) ? [] : void 0;
|
|
524
|
+
ut(t, () => {
|
|
525
|
+
let t = Array.isArray(e) ? e.map((e) => e()) : e();
|
|
526
|
+
if (!a) {
|
|
527
|
+
a = !0, o = t;
|
|
528
|
+
return;
|
|
529
|
+
}
|
|
530
|
+
let r = A(() => n(t, o));
|
|
531
|
+
return o = t, r;
|
|
532
|
+
});
|
|
533
|
+
}
|
|
534
|
+
function ft(e, t, n) {
|
|
535
|
+
let r = i(() => {
|
|
536
|
+
let i = !1;
|
|
537
|
+
dt(e, t, (e, t) => {
|
|
538
|
+
if (i) {
|
|
539
|
+
r();
|
|
540
|
+
return;
|
|
541
|
+
}
|
|
542
|
+
let a = n(e, t);
|
|
543
|
+
return i = !0, a;
|
|
544
|
+
}, { lazy: !0 });
|
|
545
|
+
});
|
|
546
|
+
v(() => r);
|
|
547
|
+
}
|
|
548
|
+
function R(e, t, n) {
|
|
549
|
+
dt(e, "post", t, n);
|
|
550
|
+
}
|
|
551
|
+
function pt(e, t, n) {
|
|
552
|
+
dt(e, "pre", t, n);
|
|
553
|
+
}
|
|
554
|
+
R.pre = pt;
|
|
555
|
+
function mt(e, t) {
|
|
556
|
+
ft(e, "post", t);
|
|
557
|
+
}
|
|
558
|
+
function ht(e, t) {
|
|
559
|
+
ft(e, "pre", t);
|
|
560
|
+
}
|
|
561
|
+
mt.pre = ht;
|
|
562
|
+
//#endregion
|
|
563
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/internal/utils/get.js
|
|
564
|
+
function gt(e) {
|
|
565
|
+
return lt(e) ? e() : e;
|
|
566
|
+
}
|
|
567
|
+
//#endregion
|
|
568
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/utilities/element-size/element-size.svelte.js
|
|
569
|
+
var _t = class {
|
|
570
|
+
#e = {
|
|
571
|
+
width: 0,
|
|
572
|
+
height: 0
|
|
573
|
+
};
|
|
574
|
+
#t = !1;
|
|
575
|
+
#n;
|
|
576
|
+
#r;
|
|
577
|
+
#i;
|
|
578
|
+
#a = u(() => (c(this.#s)?.(), this.getSize().width));
|
|
579
|
+
#o = u(() => (c(this.#s)?.(), this.getSize().height));
|
|
580
|
+
#s = u(() => {
|
|
581
|
+
let e = gt(this.#r);
|
|
582
|
+
if (e) return g((t) => {
|
|
583
|
+
if (!this.#i) return;
|
|
584
|
+
let n = new this.#i.ResizeObserver((e) => {
|
|
585
|
+
this.#t = !0;
|
|
586
|
+
for (let t of e) {
|
|
587
|
+
let e = this.#n.box === "content-box" ? t.contentBoxSize : t.borderBoxSize, n = Array.isArray(e) ? e : [e];
|
|
588
|
+
this.#e.width = n.reduce((e, t) => Math.max(e, t.inlineSize), 0), this.#e.height = n.reduce((e, t) => Math.max(e, t.blockSize), 0);
|
|
589
|
+
}
|
|
590
|
+
t();
|
|
591
|
+
});
|
|
592
|
+
return n.observe(e), () => {
|
|
593
|
+
this.#t = !1, n.disconnect();
|
|
594
|
+
};
|
|
595
|
+
});
|
|
596
|
+
});
|
|
597
|
+
constructor(e, t = { box: "border-box" }) {
|
|
598
|
+
this.#i = t.window ?? st, this.#n = t, this.#r = e, this.#e = {
|
|
599
|
+
width: 0,
|
|
600
|
+
height: 0
|
|
601
|
+
};
|
|
602
|
+
}
|
|
603
|
+
calculateSize() {
|
|
604
|
+
let e = gt(this.#r);
|
|
605
|
+
if (!e || !this.#i) return;
|
|
606
|
+
let t = e.offsetWidth, n = e.offsetHeight;
|
|
607
|
+
if (this.#n.box === "border-box") return {
|
|
608
|
+
width: t,
|
|
609
|
+
height: n
|
|
610
|
+
};
|
|
611
|
+
let r = this.#i.getComputedStyle(e), i = parseFloat(r.paddingLeft) + parseFloat(r.paddingRight), a = parseFloat(r.paddingTop) + parseFloat(r.paddingBottom), o = parseFloat(r.borderLeftWidth) + parseFloat(r.borderRightWidth), s = parseFloat(r.borderTopWidth) + parseFloat(r.borderBottomWidth);
|
|
612
|
+
return {
|
|
613
|
+
width: t - i - o,
|
|
614
|
+
height: n - a - s
|
|
615
|
+
};
|
|
616
|
+
}
|
|
617
|
+
getSize() {
|
|
618
|
+
return this.#t ? this.#e : this.calculateSize() ?? this.#e;
|
|
619
|
+
}
|
|
620
|
+
get current() {
|
|
621
|
+
return c(this.#s)?.(), this.getSize();
|
|
622
|
+
}
|
|
623
|
+
get width() {
|
|
624
|
+
return c(this.#a);
|
|
625
|
+
}
|
|
626
|
+
get height() {
|
|
627
|
+
return c(this.#o);
|
|
628
|
+
}
|
|
629
|
+
}, vt = class {
|
|
630
|
+
#e = () => void 0;
|
|
631
|
+
#t = u(() => this.#e());
|
|
632
|
+
constructor(e, t) {
|
|
633
|
+
let n;
|
|
634
|
+
t !== void 0 && (n = t), this.#e = () => {
|
|
635
|
+
try {
|
|
636
|
+
return n;
|
|
637
|
+
} finally {
|
|
638
|
+
n = e();
|
|
639
|
+
}
|
|
640
|
+
};
|
|
641
|
+
}
|
|
642
|
+
get current() {
|
|
643
|
+
return c(this.#t);
|
|
644
|
+
}
|
|
645
|
+
};
|
|
646
|
+
//#endregion
|
|
647
|
+
//#region ../node_modules/.bun/runed@0.35.1+68f06e2e1fdd21f8/node_modules/runed/dist/utilities/resource/resource.svelte.js
|
|
648
|
+
function yt(e, t) {
|
|
649
|
+
let n, r = null;
|
|
650
|
+
return (...i) => new Promise((a) => {
|
|
651
|
+
r && r(void 0), r = a, clearTimeout(n), n = setTimeout(async () => {
|
|
652
|
+
let t = await e(...i);
|
|
653
|
+
r &&= (r(t), null);
|
|
654
|
+
}, t);
|
|
655
|
+
});
|
|
656
|
+
}
|
|
657
|
+
function bt(e, t) {
|
|
658
|
+
let n = 0, r = null;
|
|
659
|
+
return (...i) => {
|
|
660
|
+
let a = Date.now();
|
|
661
|
+
return n && a - n < t ? r ?? Promise.resolve(void 0) : (n = a, r = e(...i), r);
|
|
662
|
+
};
|
|
663
|
+
}
|
|
664
|
+
function xt(e, t, n = {}, r) {
|
|
665
|
+
let { lazy: i = !1, once: a = !1, initialValue: o, debounce: s, throttle: u } = n, d = l(x(o)), f = l(!1), p = l(void 0), m = l(x([])), h = () => {
|
|
666
|
+
c(m).forEach((e) => e()), b(m, [], !0);
|
|
667
|
+
}, g = (e) => {
|
|
668
|
+
b(m, [...c(m), e], !0);
|
|
669
|
+
}, _ = async (e, n, r = !1) => {
|
|
670
|
+
try {
|
|
671
|
+
b(f, !0), b(p, void 0), h();
|
|
672
|
+
let i = new AbortController();
|
|
673
|
+
g(() => i.abort());
|
|
674
|
+
let a = await t(e, n, {
|
|
675
|
+
data: c(d),
|
|
676
|
+
refetching: r,
|
|
677
|
+
onCleanup: g,
|
|
678
|
+
signal: i.signal
|
|
679
|
+
});
|
|
680
|
+
return b(d, a, !0), a;
|
|
681
|
+
} catch (e) {
|
|
682
|
+
e instanceof DOMException && e.name === "AbortError" || b(p, e, !0);
|
|
683
|
+
return;
|
|
684
|
+
} finally {
|
|
685
|
+
b(f, !1);
|
|
686
|
+
}
|
|
687
|
+
}, v = s ? yt(_, s) : u ? bt(_, u) : _, y = Array.isArray(e) ? e : [e], S;
|
|
688
|
+
return r((t, n) => {
|
|
689
|
+
a && S || (S = t, v(Array.isArray(e) ? t : t[0], Array.isArray(e) ? n : n?.[0]));
|
|
690
|
+
}, { lazy: i }), {
|
|
691
|
+
get current() {
|
|
692
|
+
return c(d);
|
|
693
|
+
},
|
|
694
|
+
get loading() {
|
|
695
|
+
return c(f);
|
|
696
|
+
},
|
|
697
|
+
get error() {
|
|
698
|
+
return c(p);
|
|
699
|
+
},
|
|
700
|
+
mutate: (e) => {
|
|
701
|
+
b(d, e, !0);
|
|
702
|
+
},
|
|
703
|
+
refetch: (t) => {
|
|
704
|
+
let n = y.map((e) => e());
|
|
705
|
+
return v(Array.isArray(e) ? n : n[0], Array.isArray(e) ? n : n[0], t ?? !0);
|
|
706
|
+
}
|
|
707
|
+
};
|
|
708
|
+
}
|
|
709
|
+
function St(e, t, n) {
|
|
710
|
+
return xt(e, t, n, (t, n) => {
|
|
711
|
+
let r = Array.isArray(e) ? e : [e];
|
|
712
|
+
R(() => r.map((e) => e()), (e, n) => {
|
|
713
|
+
t(e, n ?? []);
|
|
714
|
+
}, n);
|
|
715
|
+
});
|
|
716
|
+
}
|
|
717
|
+
function Ct(e, t, n) {
|
|
718
|
+
return xt(e, t, n, (t, n) => {
|
|
719
|
+
let r = Array.isArray(e) ? e : [e];
|
|
720
|
+
R.pre(() => r.map((e) => e()), (e, n) => {
|
|
721
|
+
t(e, n ?? []);
|
|
722
|
+
}, n);
|
|
723
|
+
});
|
|
724
|
+
}
|
|
725
|
+
St.pre = Ct;
|
|
726
|
+
var wt = "ArrowDown", Tt = "ArrowLeft", Et = "ArrowRight", Dt = "ArrowUp", Ot = "CapsLock", kt = "Control", At = "Enter", jt = "Escape", Mt = "Home", Nt = "Meta", Pt = "PageDown", Ft = "PageUp", It = "Shift", Lt = [At, " "], Rt = [
|
|
727
|
+
wt,
|
|
728
|
+
Ft,
|
|
729
|
+
Mt
|
|
730
|
+
], zt = [
|
|
731
|
+
Dt,
|
|
732
|
+
Pt,
|
|
733
|
+
"End"
|
|
734
|
+
], Bt = [...Rt, ...zt];
|
|
735
|
+
[...Lt], [...Lt];
|
|
736
|
+
function z(e) {
|
|
737
|
+
return e.pointerType === "mouse";
|
|
738
|
+
}
|
|
739
|
+
//#endregion
|
|
740
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/is.js
|
|
741
|
+
var Vt = typeof document < "u", Ht = Ut();
|
|
742
|
+
function Ut() {
|
|
743
|
+
return Vt && window?.navigator?.userAgent && (/iP(ad|hone|od)/.test(window.navigator.userAgent) || window?.navigator?.maxTouchPoints > 2 && /iPad|Macintosh/.test(window?.navigator.userAgent));
|
|
744
|
+
}
|
|
745
|
+
function B(e) {
|
|
746
|
+
return e instanceof HTMLElement;
|
|
747
|
+
}
|
|
748
|
+
function Wt(e) {
|
|
749
|
+
return e instanceof Element;
|
|
750
|
+
}
|
|
751
|
+
function Gt(e) {
|
|
752
|
+
return e instanceof Element || e instanceof SVGElement;
|
|
753
|
+
}
|
|
754
|
+
function Kt(e) {
|
|
755
|
+
return e !== null;
|
|
756
|
+
}
|
|
757
|
+
function qt(e) {
|
|
758
|
+
return e instanceof HTMLInputElement && "select" in e;
|
|
759
|
+
}
|
|
760
|
+
//#endregion
|
|
761
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/focus.js
|
|
762
|
+
function Jt(e, { select: t = !1 } = {}) {
|
|
763
|
+
if (!e || !e.focus) return;
|
|
764
|
+
let n = rt(e);
|
|
765
|
+
if (n.activeElement === e) return;
|
|
766
|
+
let r = n.activeElement;
|
|
767
|
+
e.focus({ preventScroll: !0 }), e !== r && qt(e) && t && e.select();
|
|
768
|
+
}
|
|
769
|
+
function Yt(e, { select: t = !1 } = {}, n) {
|
|
770
|
+
let r = n();
|
|
771
|
+
for (let i of e) if (Jt(i, { select: t }), n() !== r) return !0;
|
|
772
|
+
}
|
|
773
|
+
//#endregion
|
|
774
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/events.js
|
|
775
|
+
var Xt = class {
|
|
776
|
+
eventName;
|
|
777
|
+
options;
|
|
778
|
+
constructor(e, t = {
|
|
779
|
+
bubbles: !0,
|
|
780
|
+
cancelable: !0
|
|
781
|
+
}) {
|
|
782
|
+
this.eventName = e, this.options = t;
|
|
783
|
+
}
|
|
784
|
+
createEvent(e) {
|
|
785
|
+
return new CustomEvent(this.eventName, {
|
|
786
|
+
...this.options,
|
|
787
|
+
detail: e
|
|
788
|
+
});
|
|
789
|
+
}
|
|
790
|
+
dispatch(e, t) {
|
|
791
|
+
let n = this.createEvent(t);
|
|
792
|
+
return e.dispatchEvent(n), n;
|
|
793
|
+
}
|
|
794
|
+
listen(e, t, n) {
|
|
795
|
+
return C(e, this.eventName, (e) => {
|
|
796
|
+
t(e);
|
|
797
|
+
}, n);
|
|
798
|
+
}
|
|
799
|
+
};
|
|
800
|
+
//#endregion
|
|
801
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/attrs.js
|
|
802
|
+
function Zt(e) {
|
|
803
|
+
return e ? "true" : "false";
|
|
804
|
+
}
|
|
805
|
+
function Qt(e) {
|
|
806
|
+
return e ? "" : void 0;
|
|
807
|
+
}
|
|
808
|
+
function $t(e) {
|
|
809
|
+
return e ? !0 : void 0;
|
|
810
|
+
}
|
|
811
|
+
function en(e) {
|
|
812
|
+
return e ? "open" : "closed";
|
|
813
|
+
}
|
|
814
|
+
function tn(e) {
|
|
815
|
+
return e === "starting" ? { "data-starting-style": "" } : e === "ending" ? { "data-ending-style": "" } : {};
|
|
816
|
+
}
|
|
817
|
+
var nn = class {
|
|
818
|
+
#e;
|
|
819
|
+
#t;
|
|
820
|
+
attrs;
|
|
821
|
+
constructor(e) {
|
|
822
|
+
this.#e = e.getVariant ? e.getVariant() : null, this.#t = this.#e ? `data-${this.#e}-` : `data-${e.component}-`, this.getAttr = this.getAttr.bind(this), this.selector = this.selector.bind(this), this.attrs = Object.fromEntries(e.parts.map((e) => [e, this.getAttr(e)]));
|
|
823
|
+
}
|
|
824
|
+
getAttr(e, t) {
|
|
825
|
+
return t ? `data-${t}-${e}` : `${this.#t}${e}`;
|
|
826
|
+
}
|
|
827
|
+
selector(e, t) {
|
|
828
|
+
return `[${this.getAttr(e, t)}]`;
|
|
829
|
+
}
|
|
830
|
+
};
|
|
831
|
+
function rn(e) {
|
|
832
|
+
let t = new nn(e);
|
|
833
|
+
return {
|
|
834
|
+
...t.attrs,
|
|
835
|
+
selector: t.selector,
|
|
836
|
+
getAttr: t.getAttr
|
|
837
|
+
};
|
|
838
|
+
}
|
|
839
|
+
//#endregion
|
|
840
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/is-using-keyboard/is-using-keyboard.svelte.js
|
|
841
|
+
var an = l(!1), on = class e {
|
|
842
|
+
static _refs = 0;
|
|
843
|
+
static _cleanup;
|
|
844
|
+
constructor() {
|
|
845
|
+
v(() => (e._refs === 0 && (e._cleanup = i(() => {
|
|
846
|
+
let e = [], t = (e) => {
|
|
847
|
+
b(an, !1);
|
|
848
|
+
};
|
|
849
|
+
return e.push(C(document, "pointerdown", t, { capture: !0 }), C(document, "pointermove", t, { capture: !0 }), C(document, "keydown", (e) => {
|
|
850
|
+
b(an, !0);
|
|
851
|
+
}, { capture: !0 })), ze(...e);
|
|
852
|
+
})), e._refs++, () => {
|
|
853
|
+
e._refs--, e._refs === 0 && (b(an, !1), e._cleanup?.());
|
|
854
|
+
}));
|
|
855
|
+
}
|
|
856
|
+
get current() {
|
|
857
|
+
return c(an);
|
|
858
|
+
}
|
|
859
|
+
set current(e) {
|
|
860
|
+
b(an, e, !0);
|
|
861
|
+
}
|
|
862
|
+
}, sn = [
|
|
863
|
+
"input:not([inert]):not([inert] *)",
|
|
864
|
+
"select:not([inert]):not([inert] *)",
|
|
865
|
+
"textarea:not([inert]):not([inert] *)",
|
|
866
|
+
"a[href]:not([inert]):not([inert] *)",
|
|
867
|
+
"button:not([inert]):not([inert] *)",
|
|
868
|
+
"[tabindex]:not(slot):not([inert]):not([inert] *)",
|
|
869
|
+
"audio[controls]:not([inert]):not([inert] *)",
|
|
870
|
+
"video[controls]:not([inert]):not([inert] *)",
|
|
871
|
+
"[contenteditable]:not([contenteditable=\"false\"]):not([inert]):not([inert] *)",
|
|
872
|
+
"details>summary:first-of-type:not([inert]):not([inert] *)",
|
|
873
|
+
"details:not([inert]):not([inert] *)"
|
|
874
|
+
], cn = /* #__PURE__ */ sn.join(","), ln = typeof Element > "u", un = ln ? function() {} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector, dn = !ln && Element.prototype.getRootNode ? function(e) {
|
|
875
|
+
return e?.getRootNode?.call(e);
|
|
876
|
+
} : function(e) {
|
|
877
|
+
return e?.ownerDocument;
|
|
878
|
+
}, fn = function(e, t) {
|
|
879
|
+
t === void 0 && (t = !0);
|
|
880
|
+
var n = e?.getAttribute?.call(e, "inert");
|
|
881
|
+
return n === "" || n === "true" || t && e && (typeof e.closest == "function" ? e.closest("[inert]") : fn(e.parentNode));
|
|
882
|
+
}, pn = function(e) {
|
|
883
|
+
var t = e?.getAttribute?.call(e, "contenteditable");
|
|
884
|
+
return t === "" || t === "true";
|
|
885
|
+
}, mn = function(e, t, n) {
|
|
886
|
+
if (fn(e)) return [];
|
|
887
|
+
var r = Array.prototype.slice.apply(e.querySelectorAll(cn));
|
|
888
|
+
return t && un.call(e, cn) && r.unshift(e), r = r.filter(n), r;
|
|
889
|
+
}, hn = function(e, t, n) {
|
|
890
|
+
for (var r = [], i = Array.from(e); i.length;) {
|
|
891
|
+
var a = i.shift();
|
|
892
|
+
if (!fn(a, !1)) if (a.tagName === "SLOT") {
|
|
893
|
+
var o = a.assignedElements(), s = hn(o.length ? o : a.children, !0, n);
|
|
894
|
+
n.flatten ? r.push.apply(r, s) : r.push({
|
|
895
|
+
scopeParent: a,
|
|
896
|
+
candidates: s
|
|
897
|
+
});
|
|
898
|
+
} else {
|
|
899
|
+
un.call(a, cn) && n.filter(a) && (t || !e.includes(a)) && r.push(a);
|
|
900
|
+
var c = a.shadowRoot || typeof n.getShadowRoot == "function" && n.getShadowRoot(a), l = !fn(c, !1) && (!n.shadowRootFilter || n.shadowRootFilter(a));
|
|
901
|
+
if (c && l) {
|
|
902
|
+
var u = hn(c === !0 ? a.children : c.children, !0, n);
|
|
903
|
+
n.flatten ? r.push.apply(r, u) : r.push({
|
|
904
|
+
scopeParent: a,
|
|
905
|
+
candidates: u
|
|
906
|
+
});
|
|
907
|
+
} else i.unshift.apply(i, a.children);
|
|
908
|
+
}
|
|
909
|
+
}
|
|
910
|
+
return r;
|
|
911
|
+
}, gn = function(e) {
|
|
912
|
+
return !isNaN(parseInt(e.getAttribute("tabindex"), 10));
|
|
913
|
+
}, _n = function(e) {
|
|
914
|
+
if (!e) throw Error("No node provided");
|
|
915
|
+
return e.tabIndex < 0 && (/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName) || pn(e)) && !gn(e) ? 0 : e.tabIndex;
|
|
916
|
+
}, vn = function(e, t) {
|
|
917
|
+
var n = _n(e);
|
|
918
|
+
return n < 0 && t && !gn(e) ? 0 : n;
|
|
919
|
+
}, yn = function(e, t) {
|
|
920
|
+
return e.tabIndex === t.tabIndex ? e.documentOrder - t.documentOrder : e.tabIndex - t.tabIndex;
|
|
921
|
+
}, bn = function(e) {
|
|
922
|
+
return e.tagName === "INPUT";
|
|
923
|
+
}, xn = function(e) {
|
|
924
|
+
return bn(e) && e.type === "hidden";
|
|
925
|
+
}, Sn = function(e) {
|
|
926
|
+
return e.tagName === "DETAILS" && Array.prototype.slice.apply(e.children).some(function(e) {
|
|
927
|
+
return e.tagName === "SUMMARY";
|
|
928
|
+
});
|
|
929
|
+
}, Cn = function(e, t) {
|
|
930
|
+
for (var n = 0; n < e.length; n++) if (e[n].checked && e[n].form === t) return e[n];
|
|
931
|
+
}, wn = function(e) {
|
|
932
|
+
if (!e.name) return !0;
|
|
933
|
+
var t = e.form || dn(e), n = function(e) {
|
|
934
|
+
return t.querySelectorAll("input[type=\"radio\"][name=\"" + e + "\"]");
|
|
935
|
+
}, r;
|
|
936
|
+
if (typeof window < "u" && window.CSS !== void 0 && typeof window.CSS.escape == "function") r = n(window.CSS.escape(e.name));
|
|
937
|
+
else try {
|
|
938
|
+
r = n(e.name);
|
|
939
|
+
} catch (e) {
|
|
940
|
+
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;
|
|
941
|
+
}
|
|
942
|
+
var i = Cn(r, e.form);
|
|
943
|
+
return !i || i === e;
|
|
944
|
+
}, Tn = function(e) {
|
|
945
|
+
return bn(e) && e.type === "radio";
|
|
946
|
+
}, En = function(e) {
|
|
947
|
+
return Tn(e) && !wn(e);
|
|
948
|
+
}, Dn = function(e) {
|
|
949
|
+
var t = e && dn(e), n = t?.host, r = !1;
|
|
950
|
+
if (t && t !== e) {
|
|
951
|
+
var i, a, o;
|
|
952
|
+
for (r = !!((i = n) != null && (a = i.ownerDocument) != null && a.contains(n) || e != null && (o = e.ownerDocument) != null && o.contains(e)); !r && n;) {
|
|
953
|
+
var s, c;
|
|
954
|
+
t = dn(n), n = t?.host, r = !!((s = n) != null && (c = s.ownerDocument) != null && c.contains(n));
|
|
955
|
+
}
|
|
956
|
+
}
|
|
957
|
+
return r;
|
|
958
|
+
}, On = function(e) {
|
|
959
|
+
var t = e.getBoundingClientRect(), n = t.width, r = t.height;
|
|
960
|
+
return n === 0 && r === 0;
|
|
961
|
+
}, kn = function(e, t) {
|
|
962
|
+
var n = t.displayCheck, r = t.getShadowRoot;
|
|
963
|
+
if (n === "full-native" && "checkVisibility" in e) return !e.checkVisibility({
|
|
964
|
+
checkOpacity: !1,
|
|
965
|
+
opacityProperty: !1,
|
|
966
|
+
contentVisibilityAuto: !0,
|
|
967
|
+
visibilityProperty: !0,
|
|
968
|
+
checkVisibilityCSS: !0
|
|
969
|
+
});
|
|
970
|
+
if (getComputedStyle(e).visibility === "hidden") return !0;
|
|
971
|
+
var i = un.call(e, "details>summary:first-of-type") ? e.parentElement : e;
|
|
972
|
+
if (un.call(i, "details:not([open]) *")) return !0;
|
|
973
|
+
if (!n || n === "full" || n === "full-native" || n === "legacy-full") {
|
|
974
|
+
if (typeof r == "function") {
|
|
975
|
+
for (var a = e; e;) {
|
|
976
|
+
var o = e.parentElement, s = dn(e);
|
|
977
|
+
if (o && !o.shadowRoot && r(o) === !0) return On(e);
|
|
978
|
+
e = e.assignedSlot ? e.assignedSlot : !o && s !== e.ownerDocument ? s.host : o;
|
|
979
|
+
}
|
|
980
|
+
e = a;
|
|
981
|
+
}
|
|
982
|
+
if (Dn(e)) return !e.getClientRects().length;
|
|
983
|
+
if (n !== "legacy-full") return !0;
|
|
984
|
+
} else if (n === "non-zero-area") return On(e);
|
|
985
|
+
return !1;
|
|
986
|
+
}, An = function(e) {
|
|
987
|
+
if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName)) for (var t = e.parentElement; t;) {
|
|
988
|
+
if (t.tagName === "FIELDSET" && t.disabled) {
|
|
989
|
+
for (var n = 0; n < t.children.length; n++) {
|
|
990
|
+
var r = t.children.item(n);
|
|
991
|
+
if (r.tagName === "LEGEND") return un.call(t, "fieldset[disabled] *") ? !0 : !r.contains(e);
|
|
992
|
+
}
|
|
993
|
+
return !0;
|
|
994
|
+
}
|
|
995
|
+
t = t.parentElement;
|
|
996
|
+
}
|
|
997
|
+
return !1;
|
|
998
|
+
}, jn = function(e, t) {
|
|
999
|
+
return !(t.disabled || xn(t) || kn(t, e) || Sn(t) || An(t));
|
|
1000
|
+
}, Mn = function(e, t) {
|
|
1001
|
+
return !(En(t) || _n(t) < 0 || !jn(e, t));
|
|
1002
|
+
}, Nn = function(e) {
|
|
1003
|
+
var t = parseInt(e.getAttribute("tabindex"), 10);
|
|
1004
|
+
return !!(isNaN(t) || t >= 0);
|
|
1005
|
+
}, Pn = function(e) {
|
|
1006
|
+
var t = [], n = [];
|
|
1007
|
+
return e.forEach(function(e, r) {
|
|
1008
|
+
var i = !!e.scopeParent, a = i ? e.scopeParent : e, o = vn(a, i), s = i ? Pn(e.candidates) : a;
|
|
1009
|
+
o === 0 ? i ? t.push.apply(t, s) : t.push(a) : n.push({
|
|
1010
|
+
documentOrder: r,
|
|
1011
|
+
tabIndex: o,
|
|
1012
|
+
item: e,
|
|
1013
|
+
isScope: i,
|
|
1014
|
+
content: s
|
|
1015
|
+
});
|
|
1016
|
+
}), n.sort(yn).reduce(function(e, t) {
|
|
1017
|
+
return t.isScope ? e.push.apply(e, t.content) : e.push(t.content), e;
|
|
1018
|
+
}, []).concat(t);
|
|
1019
|
+
}, Fn = function(e, t) {
|
|
1020
|
+
return t ||= {}, Pn(t.getShadowRoot ? hn([e], t.includeContainer, {
|
|
1021
|
+
filter: Mn.bind(null, t),
|
|
1022
|
+
flatten: !1,
|
|
1023
|
+
getShadowRoot: t.getShadowRoot,
|
|
1024
|
+
shadowRootFilter: Nn
|
|
1025
|
+
}) : mn(e, t.includeContainer, Mn.bind(null, t)));
|
|
1026
|
+
}, In = function(e, t) {
|
|
1027
|
+
return t ||= {}, t.getShadowRoot ? hn([e], t.includeContainer, {
|
|
1028
|
+
filter: jn.bind(null, t),
|
|
1029
|
+
flatten: !0,
|
|
1030
|
+
getShadowRoot: t.getShadowRoot
|
|
1031
|
+
}) : mn(e, t.includeContainer, jn.bind(null, t));
|
|
1032
|
+
}, Ln = function(e, t) {
|
|
1033
|
+
if (t ||= {}, !e) throw Error("No node provided");
|
|
1034
|
+
return un.call(e, cn) === !1 ? !1 : Mn(t, e);
|
|
1035
|
+
}, Rn = /* #__PURE__ */ sn.concat("iframe:not([inert]):not([inert] *)").join(","), zn = function(e, t) {
|
|
1036
|
+
if (t ||= {}, !e) throw Error("No node provided");
|
|
1037
|
+
return un.call(e, Rn) === !1 ? !1 : jn(t, e);
|
|
1038
|
+
};
|
|
1039
|
+
//#endregion
|
|
1040
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/tabbable.js
|
|
1041
|
+
function Bn() {
|
|
1042
|
+
return {
|
|
1043
|
+
getShadowRoot: !0,
|
|
1044
|
+
displayCheck: typeof ResizeObserver == "function" && ResizeObserver.toString().includes("[native code]") ? "full" : "none"
|
|
1045
|
+
};
|
|
1046
|
+
}
|
|
1047
|
+
function Vn(e, t) {
|
|
1048
|
+
if (!Ln(e, Bn())) return Hn(e, t);
|
|
1049
|
+
let n = rt(e), r = Fn(n.body, Bn());
|
|
1050
|
+
t === "prev" && r.reverse();
|
|
1051
|
+
let i = r.indexOf(e);
|
|
1052
|
+
return i === -1 ? n.body : r.slice(i + 1)[0];
|
|
1053
|
+
}
|
|
1054
|
+
function Hn(e, t) {
|
|
1055
|
+
let n = rt(e);
|
|
1056
|
+
if (!zn(e, Bn())) return n.body;
|
|
1057
|
+
let r = In(n.body, Bn());
|
|
1058
|
+
t === "prev" && r.reverse();
|
|
1059
|
+
let i = r.indexOf(e);
|
|
1060
|
+
return i === -1 ? n.body : r.slice(i + 1).find((e) => Ln(e, Bn())) ?? n.body;
|
|
1061
|
+
}
|
|
1062
|
+
//#endregion
|
|
1063
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/arrays.js
|
|
1064
|
+
function Un(e, t, n = !0) {
|
|
1065
|
+
if (!(e.length === 0 || t < 0 || t >= e.length)) return e.length === 1 && t === 0 ? e[0] : t === e.length - 1 ? n ? e[0] : void 0 : e[t + 1];
|
|
1066
|
+
}
|
|
1067
|
+
function Wn(e, t, n = !0) {
|
|
1068
|
+
if (!(e.length === 0 || t < 0 || t >= e.length)) return e.length === 1 && t === 0 ? e[0] : t === 0 ? n ? e[e.length - 1] : void 0 : e[t - 1];
|
|
1069
|
+
}
|
|
1070
|
+
function Gn(e, t, n, r = !0) {
|
|
1071
|
+
if (e.length === 0 || t < 0 || t >= e.length) return;
|
|
1072
|
+
let i = t + n;
|
|
1073
|
+
return i = r ? (i % e.length + e.length) % e.length : Math.max(0, Math.min(i, e.length - 1)), e[i];
|
|
1074
|
+
}
|
|
1075
|
+
function Kn(e, t, n, r = !0) {
|
|
1076
|
+
if (e.length === 0 || t < 0 || t >= e.length) return;
|
|
1077
|
+
let i = t - n;
|
|
1078
|
+
return i = r ? (i % e.length + e.length) % e.length : Math.max(0, Math.min(i, e.length - 1)), e[i];
|
|
1079
|
+
}
|
|
1080
|
+
function qn(e, t, n) {
|
|
1081
|
+
let r = t.toLowerCase();
|
|
1082
|
+
if (r.endsWith(" ")) {
|
|
1083
|
+
let i = r.slice(0, -1);
|
|
1084
|
+
if (e.filter((e) => e.toLowerCase().startsWith(i)).length <= 1) return qn(e, i, n);
|
|
1085
|
+
let a = n?.toLowerCase();
|
|
1086
|
+
if (a && a.startsWith(i) && a.charAt(i.length) === " " && t.trim() === i) return n;
|
|
1087
|
+
let o = e.filter((e) => e.toLowerCase().startsWith(r));
|
|
1088
|
+
if (o.length > 0) {
|
|
1089
|
+
let t = n ? e.indexOf(n) : -1;
|
|
1090
|
+
return Jn(o, Math.max(t, 0)).find((e) => e !== n) || n;
|
|
1091
|
+
}
|
|
1092
|
+
}
|
|
1093
|
+
let i = t.length > 1 && Array.from(t).every((e) => e === t[0]) ? t[0] : t, a = i.toLowerCase(), o = n ? e.indexOf(n) : -1, s = Jn(e, Math.max(o, 0));
|
|
1094
|
+
i.length === 1 && (s = s.filter((e) => e !== n));
|
|
1095
|
+
let c = s.find((e) => e?.toLowerCase().startsWith(a));
|
|
1096
|
+
return c === n ? void 0 : c;
|
|
1097
|
+
}
|
|
1098
|
+
function Jn(e, t) {
|
|
1099
|
+
return e.map((n, r) => e[(t + r) % e.length]);
|
|
1100
|
+
}
|
|
1101
|
+
//#endregion
|
|
1102
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/noop.js
|
|
1103
|
+
function V() {}
|
|
1104
|
+
//#endregion
|
|
1105
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/box-auto-reset.svelte.js
|
|
1106
|
+
var Yn = {
|
|
1107
|
+
afterMs: 1e4,
|
|
1108
|
+
onChange: V
|
|
1109
|
+
};
|
|
1110
|
+
function Xn(e, t) {
|
|
1111
|
+
let { afterMs: n, onChange: r, getWindow: i } = {
|
|
1112
|
+
...Yn,
|
|
1113
|
+
...t
|
|
1114
|
+
}, a = null, o = l(x(e));
|
|
1115
|
+
function s() {
|
|
1116
|
+
return i().setTimeout(() => {
|
|
1117
|
+
b(o, e, !0), r?.(e);
|
|
1118
|
+
}, n);
|
|
1119
|
+
}
|
|
1120
|
+
return v(() => () => {
|
|
1121
|
+
a && i().clearTimeout(a);
|
|
1122
|
+
}), M(() => c(o), (e) => {
|
|
1123
|
+
b(o, e, !0), r?.(e), a && i().clearTimeout(a), a = s();
|
|
1124
|
+
});
|
|
1125
|
+
}
|
|
1126
|
+
//#endregion
|
|
1127
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/dom-typeahead.svelte.js
|
|
1128
|
+
var Zn = class {
|
|
1129
|
+
#e;
|
|
1130
|
+
#t;
|
|
1131
|
+
#n = u(() => this.#e.onMatch ? this.#e.onMatch : (e) => e.focus());
|
|
1132
|
+
#r = u(() => this.#e.getCurrentItem ? this.#e.getCurrentItem : this.#e.getActiveElement);
|
|
1133
|
+
constructor(e) {
|
|
1134
|
+
this.#e = e, this.#t = Xn("", {
|
|
1135
|
+
afterMs: 1e3,
|
|
1136
|
+
getWindow: e.getWindow
|
|
1137
|
+
}), this.handleTypeaheadSearch = this.handleTypeaheadSearch.bind(this), this.resetTypeahead = this.resetTypeahead.bind(this);
|
|
1138
|
+
}
|
|
1139
|
+
handleTypeaheadSearch(e, t) {
|
|
1140
|
+
if (!t.length) return;
|
|
1141
|
+
this.#t.current = this.#t.current + e;
|
|
1142
|
+
let n = c(this.#r)(), r = t.find((e) => e === n)?.textContent?.trim() ?? "", i = qn(t.map((e) => e.textContent?.trim() ?? ""), this.#t.current, r), a = t.find((e) => e.textContent?.trim() === i);
|
|
1143
|
+
return a && c(this.#n)(a), a;
|
|
1144
|
+
}
|
|
1145
|
+
resetTypeahead() {
|
|
1146
|
+
this.#t.current = "";
|
|
1147
|
+
}
|
|
1148
|
+
get search() {
|
|
1149
|
+
return this.#t.current;
|
|
1150
|
+
}
|
|
1151
|
+
};
|
|
1152
|
+
//#endregion
|
|
1153
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/locale.js
|
|
1154
|
+
function Qn(e) {
|
|
1155
|
+
return window.getComputedStyle(e).getPropertyValue("direction");
|
|
1156
|
+
}
|
|
1157
|
+
//#endregion
|
|
1158
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/get-directional-keys.js
|
|
1159
|
+
var $n = [
|
|
1160
|
+
wt,
|
|
1161
|
+
Ft,
|
|
1162
|
+
Mt
|
|
1163
|
+
], er = [
|
|
1164
|
+
Dt,
|
|
1165
|
+
Pt,
|
|
1166
|
+
"End"
|
|
1167
|
+
];
|
|
1168
|
+
[...$n, ...er];
|
|
1169
|
+
function tr(e = "ltr", t = "horizontal") {
|
|
1170
|
+
return {
|
|
1171
|
+
horizontal: e === "rtl" ? Tt : Et,
|
|
1172
|
+
vertical: wt
|
|
1173
|
+
}[t];
|
|
1174
|
+
}
|
|
1175
|
+
function nr(e = "ltr", t = "horizontal") {
|
|
1176
|
+
return {
|
|
1177
|
+
horizontal: e === "rtl" ? Et : Tt,
|
|
1178
|
+
vertical: Dt
|
|
1179
|
+
}[t];
|
|
1180
|
+
}
|
|
1181
|
+
function rr(e = "ltr", t = "horizontal") {
|
|
1182
|
+
return ["ltr", "rtl"].includes(e) || (e = "ltr"), ["horizontal", "vertical"].includes(t) || (t = "horizontal"), {
|
|
1183
|
+
nextKey: tr(e, t),
|
|
1184
|
+
prevKey: nr(e, t)
|
|
1185
|
+
};
|
|
1186
|
+
}
|
|
1187
|
+
//#endregion
|
|
1188
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/roving-focus-group.js
|
|
1189
|
+
var ir = class {
|
|
1190
|
+
#e;
|
|
1191
|
+
#t = de(null);
|
|
1192
|
+
constructor(e) {
|
|
1193
|
+
this.#e = e;
|
|
1194
|
+
}
|
|
1195
|
+
getCandidateNodes() {
|
|
1196
|
+
return this.#e.rootNode.current ? this.#e.candidateSelector ? Array.from(this.#e.rootNode.current.querySelectorAll(this.#e.candidateSelector)) : this.#e.candidateAttr ? Array.from(this.#e.rootNode.current.querySelectorAll(`[${this.#e.candidateAttr}]:not([data-disabled])`)) : [] : [];
|
|
1197
|
+
}
|
|
1198
|
+
focusFirstCandidate() {
|
|
1199
|
+
let e = this.getCandidateNodes();
|
|
1200
|
+
e.length && e[0]?.focus();
|
|
1201
|
+
}
|
|
1202
|
+
handleKeydown(e, t, n = !1) {
|
|
1203
|
+
let r = this.#e.rootNode.current;
|
|
1204
|
+
if (!r || !e) return;
|
|
1205
|
+
let i = this.getCandidateNodes();
|
|
1206
|
+
if (!i.length) return;
|
|
1207
|
+
let a = i.indexOf(e), { nextKey: o, prevKey: s } = rr(Qn(r), this.#e.orientation.current), c = this.#e.loop.current, l = {
|
|
1208
|
+
[o]: a + 1,
|
|
1209
|
+
[s]: a - 1,
|
|
1210
|
+
[Mt]: 0,
|
|
1211
|
+
End: i.length - 1
|
|
1212
|
+
};
|
|
1213
|
+
if (n) {
|
|
1214
|
+
let e = o === "ArrowDown" ? Et : wt, t = s === "ArrowUp" ? Tt : Dt;
|
|
1215
|
+
l[e] = a + 1, l[t] = a - 1;
|
|
1216
|
+
}
|
|
1217
|
+
let u = l[t.key];
|
|
1218
|
+
if (u === void 0) return;
|
|
1219
|
+
t.preventDefault(), u < 0 && c ? u = i.length - 1 : u === i.length && c && (u = 0);
|
|
1220
|
+
let d = i[u];
|
|
1221
|
+
if (d) return d.focus(), this.#t.current = d.id, this.#e.onCandidateFocus?.(d), d;
|
|
1222
|
+
}
|
|
1223
|
+
getTabIndex(e) {
|
|
1224
|
+
let t = this.getCandidateNodes(), n = this.#t.current !== null;
|
|
1225
|
+
return e && !n && t[0] === e ? (this.#t.current = e.id, 0) : e?.id === this.#t.current ? 0 : -1;
|
|
1226
|
+
}
|
|
1227
|
+
setCurrentTabStopId(e) {
|
|
1228
|
+
this.#t.current = e;
|
|
1229
|
+
}
|
|
1230
|
+
focusCurrentTabStop() {
|
|
1231
|
+
let e = this.#t.current;
|
|
1232
|
+
if (!e) return;
|
|
1233
|
+
let t = this.#e.rootNode.current?.querySelector(`#${e}`);
|
|
1234
|
+
!t || !B(t) || t.focus();
|
|
1235
|
+
}
|
|
1236
|
+
}, ar = class {
|
|
1237
|
+
#e;
|
|
1238
|
+
#t = null;
|
|
1239
|
+
#n = null;
|
|
1240
|
+
#r = 0;
|
|
1241
|
+
constructor(e) {
|
|
1242
|
+
this.#e = e, P(() => this.#i());
|
|
1243
|
+
}
|
|
1244
|
+
#i() {
|
|
1245
|
+
this.#t !== null && (window.cancelAnimationFrame(this.#t), this.#t = null), this.#n?.disconnect(), this.#n = null, this.#r++;
|
|
1246
|
+
}
|
|
1247
|
+
run(e) {
|
|
1248
|
+
this.#i();
|
|
1249
|
+
let t = this.#e.ref.current;
|
|
1250
|
+
if (!t) return;
|
|
1251
|
+
if (typeof t.getAnimations != "function") {
|
|
1252
|
+
this.#a(e);
|
|
1253
|
+
return;
|
|
1254
|
+
}
|
|
1255
|
+
let n = this.#r, r = () => {
|
|
1256
|
+
n === this.#r && this.#a(e);
|
|
1257
|
+
}, i = () => {
|
|
1258
|
+
if (n !== this.#r) return;
|
|
1259
|
+
let e = t.getAnimations();
|
|
1260
|
+
if (e.length === 0) {
|
|
1261
|
+
r();
|
|
1262
|
+
return;
|
|
1263
|
+
}
|
|
1264
|
+
Promise.all(e.map((e) => e.finished)).then(() => {
|
|
1265
|
+
r();
|
|
1266
|
+
}).catch(() => {
|
|
1267
|
+
if (n === this.#r) {
|
|
1268
|
+
if (t.getAnimations().some((e) => e.pending || e.playState !== "finished")) {
|
|
1269
|
+
i();
|
|
1270
|
+
return;
|
|
1271
|
+
}
|
|
1272
|
+
r();
|
|
1273
|
+
}
|
|
1274
|
+
});
|
|
1275
|
+
}, a = () => {
|
|
1276
|
+
this.#t = window.requestAnimationFrame(() => {
|
|
1277
|
+
this.#t = null, i();
|
|
1278
|
+
});
|
|
1279
|
+
};
|
|
1280
|
+
if (!this.#e.afterTick.current) {
|
|
1281
|
+
a();
|
|
1282
|
+
return;
|
|
1283
|
+
}
|
|
1284
|
+
this.#t = window.requestAnimationFrame(() => {
|
|
1285
|
+
this.#t = null;
|
|
1286
|
+
let e = "data-starting-style";
|
|
1287
|
+
if (!t.hasAttribute(e)) {
|
|
1288
|
+
a();
|
|
1289
|
+
return;
|
|
1290
|
+
}
|
|
1291
|
+
this.#n = new MutationObserver(() => {
|
|
1292
|
+
n === this.#r && (t.hasAttribute(e) || (this.#n?.disconnect(), this.#n = null, a()));
|
|
1293
|
+
}), this.#n.observe(t, {
|
|
1294
|
+
attributes: !0,
|
|
1295
|
+
attributeFilter: [e]
|
|
1296
|
+
});
|
|
1297
|
+
});
|
|
1298
|
+
}
|
|
1299
|
+
#a(e) {
|
|
1300
|
+
let t = () => {
|
|
1301
|
+
e();
|
|
1302
|
+
};
|
|
1303
|
+
this.#e.afterTick ? F(t) : t();
|
|
1304
|
+
}
|
|
1305
|
+
}, or = class {
|
|
1306
|
+
#e;
|
|
1307
|
+
#t;
|
|
1308
|
+
#n;
|
|
1309
|
+
#r = l(!1);
|
|
1310
|
+
#i = l(void 0);
|
|
1311
|
+
#a = !1;
|
|
1312
|
+
#o = null;
|
|
1313
|
+
constructor(e) {
|
|
1314
|
+
this.#e = e, b(this.#r, e.open.current, !0), this.#t = e.enabled ?? !0, this.#n = new ar({
|
|
1315
|
+
ref: this.#e.ref,
|
|
1316
|
+
afterTick: this.#e.open
|
|
1317
|
+
}), P(() => this.#s()), R(() => this.#e.open.current, (e) => {
|
|
1318
|
+
if (!this.#a) {
|
|
1319
|
+
this.#a = !0;
|
|
1320
|
+
return;
|
|
1321
|
+
}
|
|
1322
|
+
if (this.#s(), !e && this.#e.shouldSkipExitAnimation?.()) {
|
|
1323
|
+
b(this.#r, !1), b(this.#i, void 0), this.#e.onComplete?.();
|
|
1324
|
+
return;
|
|
1325
|
+
}
|
|
1326
|
+
if (e && b(this.#r, !0), b(this.#i, e ? "starting" : "ending", !0), e && (this.#o = window.requestAnimationFrame(() => {
|
|
1327
|
+
this.#o = null, this.#e.open.current && b(this.#i, void 0);
|
|
1328
|
+
})), !this.#t) {
|
|
1329
|
+
e || b(this.#r, !1), b(this.#i, void 0), this.#e.onComplete?.();
|
|
1330
|
+
return;
|
|
1331
|
+
}
|
|
1332
|
+
this.#n.run(() => {
|
|
1333
|
+
e === this.#e.open.current && (this.#e.open.current || b(this.#r, !1), b(this.#i, void 0), this.#e.onComplete?.());
|
|
1334
|
+
});
|
|
1335
|
+
});
|
|
1336
|
+
}
|
|
1337
|
+
get shouldRender() {
|
|
1338
|
+
return c(this.#r);
|
|
1339
|
+
}
|
|
1340
|
+
get transitionStatus() {
|
|
1341
|
+
return c(this.#i);
|
|
1342
|
+
}
|
|
1343
|
+
#s() {
|
|
1344
|
+
this.#o !== null && (window.cancelAnimationFrame(this.#o), this.#o = null);
|
|
1345
|
+
}
|
|
1346
|
+
}, sr = "data-context-menu-trigger", cr = "data-context-menu-content", lr = new L("Menu.Root"), ur = new L("Menu.Root | Menu.Sub"), dr = new L("Menu.Content"), fr = new L("Menu.Group | Menu.RadioGroup");
|
|
1347
|
+
new L("Menu.RadioGroup"), new L("Menu.CheckboxGroup");
|
|
1348
|
+
var pr = new Xt("bitsmenuopen", {
|
|
1349
|
+
bubbles: !1,
|
|
1350
|
+
cancelable: !0
|
|
1351
|
+
}), mr = rn({
|
|
1352
|
+
component: "menu",
|
|
1353
|
+
parts: [
|
|
1354
|
+
"trigger",
|
|
1355
|
+
"content",
|
|
1356
|
+
"sub-trigger",
|
|
1357
|
+
"item",
|
|
1358
|
+
"group",
|
|
1359
|
+
"group-heading",
|
|
1360
|
+
"checkbox-group",
|
|
1361
|
+
"checkbox-item",
|
|
1362
|
+
"radio-group",
|
|
1363
|
+
"radio-item",
|
|
1364
|
+
"separator",
|
|
1365
|
+
"sub-content",
|
|
1366
|
+
"arrow"
|
|
1367
|
+
]
|
|
1368
|
+
}), hr = class {
|
|
1369
|
+
#e;
|
|
1370
|
+
#t = null;
|
|
1371
|
+
#n = null;
|
|
1372
|
+
#r = !1;
|
|
1373
|
+
#i = null;
|
|
1374
|
+
#a = null;
|
|
1375
|
+
#o = null;
|
|
1376
|
+
#s = null;
|
|
1377
|
+
constructor(e) {
|
|
1378
|
+
this.#e = e, R([
|
|
1379
|
+
e.triggerNode,
|
|
1380
|
+
e.contentNode,
|
|
1381
|
+
e.enabled
|
|
1382
|
+
], ([e, t, n]) => {
|
|
1383
|
+
if (this.#_(), !e || !t || !n) return;
|
|
1384
|
+
let r = (e) => {
|
|
1385
|
+
z(e) && (this.#s = {
|
|
1386
|
+
x: e.clientX,
|
|
1387
|
+
y: e.clientY
|
|
1388
|
+
}, this.#r || this.#d(e, "content"));
|
|
1389
|
+
}, i = (e) => {
|
|
1390
|
+
z(e) && this.#f(e, "content");
|
|
1391
|
+
}, a = (e) => {
|
|
1392
|
+
z(e) && (this.#r || this.#d(e, "trigger"));
|
|
1393
|
+
}, o = (e) => {
|
|
1394
|
+
if (z(e)) {
|
|
1395
|
+
if (Wt(e.relatedTarget)) {
|
|
1396
|
+
let n = this.#e.subContentSelector(), r = e.relatedTarget.closest(n);
|
|
1397
|
+
if (r && r !== t && r.id && t.querySelector(`[aria-controls="${r.id}"]`)) return;
|
|
1398
|
+
}
|
|
1399
|
+
this.#f(e, "trigger");
|
|
1400
|
+
}
|
|
1401
|
+
}, s = (e) => {
|
|
1402
|
+
z(e) && this.#m();
|
|
1403
|
+
}, c = (e) => {
|
|
1404
|
+
z(e) && this.#m();
|
|
1405
|
+
};
|
|
1406
|
+
return e.addEventListener("pointermove", r), e.addEventListener("pointerleave", i), e.addEventListener("pointerenter", s), t.addEventListener("pointermove", a), t.addEventListener("pointerleave", o), t.addEventListener("pointerenter", c), () => {
|
|
1407
|
+
e.removeEventListener("pointermove", r), e.removeEventListener("pointerleave", i), e.removeEventListener("pointerenter", s), t.removeEventListener("pointermove", a), t.removeEventListener("pointerleave", o), t.removeEventListener("pointerenter", c), this.#_();
|
|
1408
|
+
};
|
|
1409
|
+
}), P(() => {
|
|
1410
|
+
this.#_();
|
|
1411
|
+
});
|
|
1412
|
+
}
|
|
1413
|
+
#c() {
|
|
1414
|
+
let e = this.#e.parentContentNode();
|
|
1415
|
+
return e ? e.getBoundingClientRect() : this.#e.triggerNode()?.getBoundingClientRect() ?? null;
|
|
1416
|
+
}
|
|
1417
|
+
#l(e, t) {
|
|
1418
|
+
let n = this.#e.triggerNode(), r = this.#e.contentNode();
|
|
1419
|
+
if (!n || !r) return null;
|
|
1420
|
+
let i = n.getBoundingClientRect(), a = r.getBoundingClientRect(), o = yr(i, a), s, c, l;
|
|
1421
|
+
return t === "content" ? (s = this.#r ? this.#a ?? e : e, c = a) : (s = this.#s ?? e, c = this.#c() ?? i, l = a), this.#a = s, {
|
|
1422
|
+
corridor: br(i, a, o),
|
|
1423
|
+
intent: xr(s, c, o, t, l),
|
|
1424
|
+
targetRect: c,
|
|
1425
|
+
side: o
|
|
1426
|
+
};
|
|
1427
|
+
}
|
|
1428
|
+
#u(e, t, n) {
|
|
1429
|
+
return gr(e, t) || gr(e, n);
|
|
1430
|
+
}
|
|
1431
|
+
#d(e, t) {
|
|
1432
|
+
let n = {
|
|
1433
|
+
x: e.clientX,
|
|
1434
|
+
y: e.clientY
|
|
1435
|
+
};
|
|
1436
|
+
this.#l(n, t) && (this.#i = t, this.#o = n);
|
|
1437
|
+
}
|
|
1438
|
+
#f(e, t) {
|
|
1439
|
+
if (!this.#e.enabled()) return;
|
|
1440
|
+
let n = this.#e.triggerNode(), r = this.#e.contentNode();
|
|
1441
|
+
if (!n || !r) return;
|
|
1442
|
+
let i = e.relatedTarget;
|
|
1443
|
+
if (Wt(i) && (t === "content" && r.contains(i) || t === "trigger" && n.contains(i))) return;
|
|
1444
|
+
let a = {
|
|
1445
|
+
x: e.clientX,
|
|
1446
|
+
y: e.clientY
|
|
1447
|
+
}, o = this.#l(a, t);
|
|
1448
|
+
if (o) {
|
|
1449
|
+
if (!_r(a, o.targetRect) && !this.#u(a, o.corridor, o.intent)) {
|
|
1450
|
+
this.#w();
|
|
1451
|
+
return;
|
|
1452
|
+
}
|
|
1453
|
+
this.#r = !0, this.#i = t, this.#o = a, this.#e.setIsPointerInTransit(!0), this.#b(), this.#S();
|
|
1454
|
+
}
|
|
1455
|
+
}
|
|
1456
|
+
#p = null;
|
|
1457
|
+
#m() {
|
|
1458
|
+
if (!this.#r) return;
|
|
1459
|
+
let e = this.#i === "trigger";
|
|
1460
|
+
this.#x(), this.#C(), this.#r = !1, this.#w(), e ? (this.#h(), this.#p = setTimeout(() => {
|
|
1461
|
+
this.#p = null, this.#e.setIsPointerInTransit(!1);
|
|
1462
|
+
}, 100)) : this.#e.setIsPointerInTransit(!1);
|
|
1463
|
+
}
|
|
1464
|
+
#h() {
|
|
1465
|
+
this.#p !== null && (clearTimeout(this.#p), this.#p = null);
|
|
1466
|
+
}
|
|
1467
|
+
#g() {
|
|
1468
|
+
let e = this.#o;
|
|
1469
|
+
this.#x(), this.#C(), this.#h(), this.#r = !1, this.#e.setIsPointerInTransit(!1), this.#w(), this.#e.onIntentExit(e);
|
|
1470
|
+
}
|
|
1471
|
+
#_() {
|
|
1472
|
+
this.#x(), this.#C(), this.#h(), this.#r && this.#e.setIsPointerInTransit(!1), this.#r = !1, this.#i = null, this.#a = null, this.#o = null, this.#s = null;
|
|
1473
|
+
}
|
|
1474
|
+
#v(e) {
|
|
1475
|
+
let t = this.#e.contentNode();
|
|
1476
|
+
if (!t) return !1;
|
|
1477
|
+
let n = t.ownerDocument.elementFromPoint(e.x, e.y);
|
|
1478
|
+
if (!n) return !1;
|
|
1479
|
+
let r = this.#e.subContentSelector(), i = n.closest(r);
|
|
1480
|
+
return !i || i === t ? !1 : i.id ? !!t.querySelector(`[aria-controls="${i.id}"]`) : !1;
|
|
1481
|
+
}
|
|
1482
|
+
#y = (e) => {
|
|
1483
|
+
if (!this.#r || !this.#i || !z(e)) return;
|
|
1484
|
+
let t = this.#e.triggerNode(), n = this.#e.contentNode();
|
|
1485
|
+
if (!t || !n) {
|
|
1486
|
+
this.#g();
|
|
1487
|
+
return;
|
|
1488
|
+
}
|
|
1489
|
+
this.#C();
|
|
1490
|
+
let r = {
|
|
1491
|
+
x: e.clientX,
|
|
1492
|
+
y: e.clientY
|
|
1493
|
+
};
|
|
1494
|
+
this.#o = r;
|
|
1495
|
+
let i = t.getBoundingClientRect(), a = n.getBoundingClientRect();
|
|
1496
|
+
if (this.#i === "content" && _r(r, a)) {
|
|
1497
|
+
this.#m();
|
|
1498
|
+
return;
|
|
1499
|
+
}
|
|
1500
|
+
if (this.#i === "trigger" && vr(r, i, 4)) {
|
|
1501
|
+
this.#m();
|
|
1502
|
+
return;
|
|
1503
|
+
}
|
|
1504
|
+
if (this.#v(r)) {
|
|
1505
|
+
this.#S();
|
|
1506
|
+
return;
|
|
1507
|
+
}
|
|
1508
|
+
let o = this.#l(r, this.#i);
|
|
1509
|
+
if (!o) {
|
|
1510
|
+
this.#g();
|
|
1511
|
+
return;
|
|
1512
|
+
}
|
|
1513
|
+
if (this.#u(r, o.corridor, o.intent)) {
|
|
1514
|
+
this.#S();
|
|
1515
|
+
return;
|
|
1516
|
+
}
|
|
1517
|
+
this.#g();
|
|
1518
|
+
};
|
|
1519
|
+
#b() {
|
|
1520
|
+
if (this.#t) return;
|
|
1521
|
+
let e = rt(this.#e.triggerNode() ?? this.#e.contentNode());
|
|
1522
|
+
e && (e.addEventListener("pointermove", this.#y, !0), this.#t = () => {
|
|
1523
|
+
e.removeEventListener("pointermove", this.#y, !0), this.#t = null;
|
|
1524
|
+
});
|
|
1525
|
+
}
|
|
1526
|
+
#x() {
|
|
1527
|
+
this.#t?.();
|
|
1528
|
+
}
|
|
1529
|
+
#S() {
|
|
1530
|
+
this.#C(), this.#n = setTimeout(() => {
|
|
1531
|
+
this.#n = null, this.#r && this.#g();
|
|
1532
|
+
}, 500);
|
|
1533
|
+
}
|
|
1534
|
+
#C() {
|
|
1535
|
+
this.#n !== null && (clearTimeout(this.#n), this.#n = null);
|
|
1536
|
+
}
|
|
1537
|
+
#w() {
|
|
1538
|
+
this.#i = null, this.#a = null, this.#o = null;
|
|
1539
|
+
}
|
|
1540
|
+
};
|
|
1541
|
+
function gr(e, t) {
|
|
1542
|
+
let { x: n, y: r } = e, i = !1;
|
|
1543
|
+
for (let e = 0, a = t.length - 1; e < t.length; a = e++) {
|
|
1544
|
+
let o = t[e].x, s = t[e].y, c = t[a].x, l = t[a].y;
|
|
1545
|
+
s > r != l > r && n < (c - o) * (r - s) / (l - s) + o && (i = !i);
|
|
1546
|
+
}
|
|
1547
|
+
return i;
|
|
1548
|
+
}
|
|
1549
|
+
function _r(e, t) {
|
|
1550
|
+
return e.x >= t.left && e.x <= t.right && e.y >= t.top && e.y <= t.bottom;
|
|
1551
|
+
}
|
|
1552
|
+
function vr(e, t, n) {
|
|
1553
|
+
return e.x >= t.left + n && e.x <= t.right - n && e.y >= t.top + n && e.y <= t.bottom - n;
|
|
1554
|
+
}
|
|
1555
|
+
function yr(e, t) {
|
|
1556
|
+
let n = e.left + e.width / 2, r = e.top + e.height / 2, i = t.left + t.width / 2, a = t.top + t.height / 2, o = i - n, s = a - r;
|
|
1557
|
+
return Math.abs(o) > Math.abs(s) ? o > 0 ? "right" : "left" : s > 0 ? "bottom" : "top";
|
|
1558
|
+
}
|
|
1559
|
+
function br(e, t, n) {
|
|
1560
|
+
switch (n) {
|
|
1561
|
+
case "top": return [
|
|
1562
|
+
{
|
|
1563
|
+
x: Math.min(e.left, t.left) - 2,
|
|
1564
|
+
y: e.top
|
|
1565
|
+
},
|
|
1566
|
+
{
|
|
1567
|
+
x: Math.min(e.left, t.left) - 2,
|
|
1568
|
+
y: t.bottom
|
|
1569
|
+
},
|
|
1570
|
+
{
|
|
1571
|
+
x: Math.max(e.right, t.right) + 2,
|
|
1572
|
+
y: t.bottom
|
|
1573
|
+
},
|
|
1574
|
+
{
|
|
1575
|
+
x: Math.max(e.right, t.right) + 2,
|
|
1576
|
+
y: e.top
|
|
1577
|
+
}
|
|
1578
|
+
];
|
|
1579
|
+
case "bottom": return [
|
|
1580
|
+
{
|
|
1581
|
+
x: Math.min(e.left, t.left) - 2,
|
|
1582
|
+
y: e.bottom
|
|
1583
|
+
},
|
|
1584
|
+
{
|
|
1585
|
+
x: Math.min(e.left, t.left) - 2,
|
|
1586
|
+
y: t.top
|
|
1587
|
+
},
|
|
1588
|
+
{
|
|
1589
|
+
x: Math.max(e.right, t.right) + 2,
|
|
1590
|
+
y: t.top
|
|
1591
|
+
},
|
|
1592
|
+
{
|
|
1593
|
+
x: Math.max(e.right, t.right) + 2,
|
|
1594
|
+
y: e.bottom
|
|
1595
|
+
}
|
|
1596
|
+
];
|
|
1597
|
+
case "left": return [
|
|
1598
|
+
{
|
|
1599
|
+
x: e.left,
|
|
1600
|
+
y: Math.min(e.top, t.top) - 2
|
|
1601
|
+
},
|
|
1602
|
+
{
|
|
1603
|
+
x: t.right,
|
|
1604
|
+
y: Math.min(e.top, t.top) - 2
|
|
1605
|
+
},
|
|
1606
|
+
{
|
|
1607
|
+
x: t.right,
|
|
1608
|
+
y: Math.max(e.bottom, t.bottom) + 2
|
|
1609
|
+
},
|
|
1610
|
+
{
|
|
1611
|
+
x: e.left,
|
|
1612
|
+
y: Math.max(e.bottom, t.bottom) + 2
|
|
1613
|
+
}
|
|
1614
|
+
];
|
|
1615
|
+
case "right": return [
|
|
1616
|
+
{
|
|
1617
|
+
x: e.right,
|
|
1618
|
+
y: Math.min(e.top, t.top) - 2
|
|
1619
|
+
},
|
|
1620
|
+
{
|
|
1621
|
+
x: t.left,
|
|
1622
|
+
y: Math.min(e.top, t.top) - 2
|
|
1623
|
+
},
|
|
1624
|
+
{
|
|
1625
|
+
x: t.left,
|
|
1626
|
+
y: Math.max(e.bottom, t.bottom) + 2
|
|
1627
|
+
},
|
|
1628
|
+
{
|
|
1629
|
+
x: e.right,
|
|
1630
|
+
y: Math.max(e.bottom, t.bottom) + 2
|
|
1631
|
+
}
|
|
1632
|
+
];
|
|
1633
|
+
}
|
|
1634
|
+
}
|
|
1635
|
+
function xr(e, t, n, r, i) {
|
|
1636
|
+
let a = r === "trigger" ? Sr(n) : n, o = i ? Math.min(t.top, i.top) - 8 : t.top - 8, s = i ? Math.max(t.bottom, i.bottom) + 8 : t.bottom + 8, c = i ? Math.min(t.left, i.left) - 8 : t.left - 8, l = i ? Math.max(t.right, i.right) + 8 : t.right + 8;
|
|
1637
|
+
switch (a) {
|
|
1638
|
+
case "right": return [
|
|
1639
|
+
e,
|
|
1640
|
+
{
|
|
1641
|
+
x: t.left,
|
|
1642
|
+
y: o
|
|
1643
|
+
},
|
|
1644
|
+
{
|
|
1645
|
+
x: t.left,
|
|
1646
|
+
y: s
|
|
1647
|
+
}
|
|
1648
|
+
];
|
|
1649
|
+
case "left": return [
|
|
1650
|
+
e,
|
|
1651
|
+
{
|
|
1652
|
+
x: t.right,
|
|
1653
|
+
y: o
|
|
1654
|
+
},
|
|
1655
|
+
{
|
|
1656
|
+
x: t.right,
|
|
1657
|
+
y: s
|
|
1658
|
+
}
|
|
1659
|
+
];
|
|
1660
|
+
case "bottom": return [
|
|
1661
|
+
e,
|
|
1662
|
+
{
|
|
1663
|
+
x: c,
|
|
1664
|
+
y: t.top
|
|
1665
|
+
},
|
|
1666
|
+
{
|
|
1667
|
+
x: l,
|
|
1668
|
+
y: t.top
|
|
1669
|
+
}
|
|
1670
|
+
];
|
|
1671
|
+
case "top": return [
|
|
1672
|
+
e,
|
|
1673
|
+
{
|
|
1674
|
+
x: c,
|
|
1675
|
+
y: t.bottom
|
|
1676
|
+
},
|
|
1677
|
+
{
|
|
1678
|
+
x: l,
|
|
1679
|
+
y: t.bottom
|
|
1680
|
+
}
|
|
1681
|
+
];
|
|
1682
|
+
}
|
|
1683
|
+
}
|
|
1684
|
+
function Sr(e) {
|
|
1685
|
+
switch (e) {
|
|
1686
|
+
case "top": return "bottom";
|
|
1687
|
+
case "bottom": return "top";
|
|
1688
|
+
case "left": return "right";
|
|
1689
|
+
case "right": return "left";
|
|
1690
|
+
}
|
|
1691
|
+
}
|
|
1692
|
+
var Cr = class e {
|
|
1693
|
+
static create(t) {
|
|
1694
|
+
let n = new e(t);
|
|
1695
|
+
return lr.set(n);
|
|
1696
|
+
}
|
|
1697
|
+
opts;
|
|
1698
|
+
isUsingKeyboard = new on();
|
|
1699
|
+
#e = l(!1);
|
|
1700
|
+
get ignoreCloseAutoFocus() {
|
|
1701
|
+
return c(this.#e);
|
|
1702
|
+
}
|
|
1703
|
+
set ignoreCloseAutoFocus(e) {
|
|
1704
|
+
b(this.#e, e, !0);
|
|
1705
|
+
}
|
|
1706
|
+
#t = l(!1);
|
|
1707
|
+
get isPointerInTransit() {
|
|
1708
|
+
return c(this.#t);
|
|
1709
|
+
}
|
|
1710
|
+
set isPointerInTransit(e) {
|
|
1711
|
+
b(this.#t, e, !0);
|
|
1712
|
+
}
|
|
1713
|
+
constructor(e) {
|
|
1714
|
+
this.opts = e;
|
|
1715
|
+
}
|
|
1716
|
+
getBitsAttr = (e) => mr.getAttr(e, this.opts.variant.current);
|
|
1717
|
+
}, wr = class e {
|
|
1718
|
+
static create(t, n) {
|
|
1719
|
+
return ur.set(new e(t, n, null));
|
|
1720
|
+
}
|
|
1721
|
+
opts;
|
|
1722
|
+
root;
|
|
1723
|
+
parentMenu;
|
|
1724
|
+
contentId = M(() => "");
|
|
1725
|
+
#e = l(null);
|
|
1726
|
+
get contentNode() {
|
|
1727
|
+
return c(this.#e);
|
|
1728
|
+
}
|
|
1729
|
+
set contentNode(e) {
|
|
1730
|
+
b(this.#e, e, !0);
|
|
1731
|
+
}
|
|
1732
|
+
contentPresence;
|
|
1733
|
+
#t = l(null);
|
|
1734
|
+
get triggerNode() {
|
|
1735
|
+
return c(this.#t);
|
|
1736
|
+
}
|
|
1737
|
+
set triggerNode(e) {
|
|
1738
|
+
b(this.#t, e, !0);
|
|
1739
|
+
}
|
|
1740
|
+
constructor(e, t, n) {
|
|
1741
|
+
this.opts = e, this.root = t, this.parentMenu = n, this.contentPresence = new or({
|
|
1742
|
+
ref: M(() => this.contentNode),
|
|
1743
|
+
open: this.opts.open,
|
|
1744
|
+
onComplete: () => {
|
|
1745
|
+
this.opts.onOpenChangeComplete.current(this.opts.open.current);
|
|
1746
|
+
},
|
|
1747
|
+
shouldSkipExitAnimation: () => this.root.opts.variant.current !== "menubar" || this.parentMenu !== null ? !1 : this.root.opts.shouldSkipExitAnimation?.() ?? !1
|
|
1748
|
+
}), n && R(() => n.opts.open.current, () => {
|
|
1749
|
+
n.opts.open.current || (this.opts.open.current = !1);
|
|
1750
|
+
});
|
|
1751
|
+
}
|
|
1752
|
+
toggleOpen() {
|
|
1753
|
+
this.opts.open.current = !this.opts.open.current;
|
|
1754
|
+
}
|
|
1755
|
+
onOpen() {
|
|
1756
|
+
this.opts.open.current = !0;
|
|
1757
|
+
}
|
|
1758
|
+
onClose() {
|
|
1759
|
+
this.opts.open.current = !1;
|
|
1760
|
+
}
|
|
1761
|
+
}, Tr = class e {
|
|
1762
|
+
static create(t) {
|
|
1763
|
+
return dr.set(new e(t, ur.get()));
|
|
1764
|
+
}
|
|
1765
|
+
opts;
|
|
1766
|
+
parentMenu;
|
|
1767
|
+
rovingFocusGroup;
|
|
1768
|
+
domContext;
|
|
1769
|
+
attachment;
|
|
1770
|
+
#e = l("");
|
|
1771
|
+
get search() {
|
|
1772
|
+
return c(this.#e);
|
|
1773
|
+
}
|
|
1774
|
+
set search(e) {
|
|
1775
|
+
b(this.#e, e, !0);
|
|
1776
|
+
}
|
|
1777
|
+
#t = 0;
|
|
1778
|
+
#n;
|
|
1779
|
+
#r = l(!1);
|
|
1780
|
+
get mounted() {
|
|
1781
|
+
return c(this.#r);
|
|
1782
|
+
}
|
|
1783
|
+
set mounted(e) {
|
|
1784
|
+
b(this.#r, e, !0);
|
|
1785
|
+
}
|
|
1786
|
+
#i;
|
|
1787
|
+
constructor(e, t) {
|
|
1788
|
+
this.opts = e, this.parentMenu = t, this.domContext = new ot(e.ref), this.attachment = I(this.opts.ref, (e) => {
|
|
1789
|
+
this.parentMenu.contentNode !== e && (this.parentMenu.contentNode = e);
|
|
1790
|
+
}), t.contentId = e.id, this.#i = e.isSub ?? !1, this.onkeydown = this.onkeydown.bind(this), this.onblur = this.onblur.bind(this), this.onfocus = this.onfocus.bind(this), this.handleInteractOutside = this.handleInteractOutside.bind(this), new hr({
|
|
1791
|
+
contentNode: () => this.parentMenu.contentNode,
|
|
1792
|
+
triggerNode: () => this.parentMenu.triggerNode,
|
|
1793
|
+
parentContentNode: () => this.parentMenu.parentMenu?.contentNode ?? null,
|
|
1794
|
+
subContentSelector: () => `[${this.parentMenu.root.getBitsAttr("sub-content")}]`,
|
|
1795
|
+
enabled: () => this.parentMenu.opts.open.current && !!this.parentMenu.triggerNode?.hasAttribute(this.parentMenu.root.getBitsAttr("sub-trigger")),
|
|
1796
|
+
onIntentExit: (e) => {
|
|
1797
|
+
this.parentMenu.opts.open.current = !1, this.#s(e);
|
|
1798
|
+
},
|
|
1799
|
+
setIsPointerInTransit: (e) => {
|
|
1800
|
+
this.parentMenu.root.isPointerInTransit = e;
|
|
1801
|
+
}
|
|
1802
|
+
}), this.#n = new Zn({
|
|
1803
|
+
getActiveElement: () => this.domContext.getActiveElement(),
|
|
1804
|
+
getWindow: () => this.domContext.getWindow()
|
|
1805
|
+
}).handleTypeaheadSearch, this.rovingFocusGroup = new ir({
|
|
1806
|
+
rootNode: M(() => this.parentMenu.contentNode),
|
|
1807
|
+
candidateAttr: this.parentMenu.root.getBitsAttr("item"),
|
|
1808
|
+
loop: this.opts.loop,
|
|
1809
|
+
orientation: M(() => "vertical")
|
|
1810
|
+
}), R(() => this.parentMenu.contentNode, (e) => e ? pr.listen(e, () => {
|
|
1811
|
+
F(() => {
|
|
1812
|
+
this.parentMenu.root.isUsingKeyboard.current && this.rovingFocusGroup.focusFirstCandidate();
|
|
1813
|
+
});
|
|
1814
|
+
}) : void 0), v(() => {
|
|
1815
|
+
this.parentMenu.opts.open.current || this.domContext.getWindow().clearTimeout(this.#t);
|
|
1816
|
+
});
|
|
1817
|
+
}
|
|
1818
|
+
#a() {
|
|
1819
|
+
let e = this.parentMenu.contentNode;
|
|
1820
|
+
return e ? Array.from(e.querySelectorAll(`[${this.parentMenu.root.getBitsAttr("item")}]:not([data-disabled])`)) : [];
|
|
1821
|
+
}
|
|
1822
|
+
#o() {
|
|
1823
|
+
return this.parentMenu.root.isPointerInTransit;
|
|
1824
|
+
}
|
|
1825
|
+
#s(e) {
|
|
1826
|
+
if (!e) return;
|
|
1827
|
+
let t = this.parentMenu.parentMenu?.contentNode;
|
|
1828
|
+
if (!t) return;
|
|
1829
|
+
let n = this.domContext.getDocument().elementFromPoint(e.x, e.y);
|
|
1830
|
+
if (!Wt(n)) return;
|
|
1831
|
+
let r = n.closest(`[${this.parentMenu.root.getBitsAttr("sub-trigger")}]`);
|
|
1832
|
+
!r || !t.contains(r) || r !== this.parentMenu.triggerNode && r.dispatchEvent(new PointerEvent("pointermove", {
|
|
1833
|
+
bubbles: !0,
|
|
1834
|
+
cancelable: !0,
|
|
1835
|
+
pointerType: "mouse",
|
|
1836
|
+
clientX: e.x,
|
|
1837
|
+
clientY: e.y
|
|
1838
|
+
}));
|
|
1839
|
+
}
|
|
1840
|
+
onCloseAutoFocus = (e) => {
|
|
1841
|
+
if (this.opts.onCloseAutoFocus.current?.(e), !(e.defaultPrevented || this.#i)) {
|
|
1842
|
+
if (this.parentMenu.root.ignoreCloseAutoFocus) {
|
|
1843
|
+
e.preventDefault();
|
|
1844
|
+
return;
|
|
1845
|
+
}
|
|
1846
|
+
this.parentMenu.triggerNode && Ln(this.parentMenu.triggerNode) && (e.preventDefault(), this.parentMenu.triggerNode.focus());
|
|
1847
|
+
}
|
|
1848
|
+
};
|
|
1849
|
+
handleTabKeyDown(e) {
|
|
1850
|
+
let t = this.parentMenu;
|
|
1851
|
+
for (; t.parentMenu !== null;) t = t.parentMenu;
|
|
1852
|
+
if (!t.triggerNode) return;
|
|
1853
|
+
e.preventDefault();
|
|
1854
|
+
let n = Vn(t.triggerNode, e.shiftKey ? "prev" : "next");
|
|
1855
|
+
n ? (this.parentMenu.root.ignoreCloseAutoFocus = !0, t.onClose(), F(() => {
|
|
1856
|
+
n.focus(), F(() => {
|
|
1857
|
+
this.parentMenu.root.ignoreCloseAutoFocus = !1;
|
|
1858
|
+
});
|
|
1859
|
+
})) : this.domContext.getDocument().body.focus();
|
|
1860
|
+
}
|
|
1861
|
+
onkeydown(e) {
|
|
1862
|
+
if (e.defaultPrevented) return;
|
|
1863
|
+
if (e.key === "Tab") {
|
|
1864
|
+
this.handleTabKeyDown(e);
|
|
1865
|
+
return;
|
|
1866
|
+
}
|
|
1867
|
+
let t = e.target, n = e.currentTarget;
|
|
1868
|
+
if (!B(t) || !B(n)) return;
|
|
1869
|
+
let r = t.closest(`[${this.parentMenu.root.getBitsAttr("content")}]`)?.id === this.parentMenu.contentId.current, i = e.ctrlKey || e.altKey || e.metaKey, a = e.key.length === 1;
|
|
1870
|
+
if (this.rovingFocusGroup.handleKeydown(t, e) || e.code === "Space") return;
|
|
1871
|
+
let o = this.#a();
|
|
1872
|
+
r && !i && a && this.#n(e.key, o), e.target?.id === this.parentMenu.contentId.current && Bt.includes(e.key) && (e.preventDefault(), zt.includes(e.key) && o.reverse(), Yt(o, { select: !1 }, () => this.domContext.getActiveElement()));
|
|
1873
|
+
}
|
|
1874
|
+
onblur(e) {
|
|
1875
|
+
Wt(e.currentTarget) && Wt(e.target) && (e.currentTarget.contains?.(e.target) || (this.domContext.getWindow().clearTimeout(this.#t), this.search = ""));
|
|
1876
|
+
}
|
|
1877
|
+
onfocus(e) {
|
|
1878
|
+
this.parentMenu.root.isUsingKeyboard.current && F(() => this.rovingFocusGroup.focusFirstCandidate());
|
|
1879
|
+
}
|
|
1880
|
+
onItemEnter() {
|
|
1881
|
+
return this.#o();
|
|
1882
|
+
}
|
|
1883
|
+
onItemLeave(e) {
|
|
1884
|
+
e.currentTarget.hasAttribute(this.parentMenu.root.getBitsAttr("sub-trigger")) || this.#o() || this.parentMenu.root.isUsingKeyboard.current || (this.parentMenu.contentNode?.focus({ preventScroll: !0 }), this.rovingFocusGroup.setCurrentTabStopId(""));
|
|
1885
|
+
}
|
|
1886
|
+
onTriggerLeave() {
|
|
1887
|
+
return !!this.#o();
|
|
1888
|
+
}
|
|
1889
|
+
handleInteractOutside(e) {
|
|
1890
|
+
if (!Gt(e.target)) return;
|
|
1891
|
+
let t = this.parentMenu.triggerNode?.id;
|
|
1892
|
+
if (e.target.id === t) {
|
|
1893
|
+
e.preventDefault();
|
|
1894
|
+
return;
|
|
1895
|
+
}
|
|
1896
|
+
if (e.target.closest(`#${t}`)) {
|
|
1897
|
+
e.preventDefault();
|
|
1898
|
+
return;
|
|
1899
|
+
}
|
|
1900
|
+
this.parentMenu.root.ignoreCloseAutoFocus = !0, F(() => {
|
|
1901
|
+
this.parentMenu.root.ignoreCloseAutoFocus = !1;
|
|
1902
|
+
});
|
|
1903
|
+
}
|
|
1904
|
+
get shouldRender() {
|
|
1905
|
+
return this.parentMenu.contentPresence.shouldRender;
|
|
1906
|
+
}
|
|
1907
|
+
#c = u(() => ({ open: this.parentMenu.opts.open.current }));
|
|
1908
|
+
get snippetProps() {
|
|
1909
|
+
return c(this.#c);
|
|
1910
|
+
}
|
|
1911
|
+
set snippetProps(e) {
|
|
1912
|
+
b(this.#c, e);
|
|
1913
|
+
}
|
|
1914
|
+
#l = u(() => ({
|
|
1915
|
+
id: this.opts.id.current,
|
|
1916
|
+
role: "menu",
|
|
1917
|
+
"aria-orientation": "vertical",
|
|
1918
|
+
[this.parentMenu.root.getBitsAttr("content")]: "",
|
|
1919
|
+
"data-state": en(this.parentMenu.opts.open.current),
|
|
1920
|
+
...tn(this.parentMenu.contentPresence.transitionStatus),
|
|
1921
|
+
onkeydown: this.onkeydown,
|
|
1922
|
+
onblur: this.onblur,
|
|
1923
|
+
onfocus: this.onfocus,
|
|
1924
|
+
dir: this.parentMenu.root.opts.dir.current,
|
|
1925
|
+
style: {
|
|
1926
|
+
pointerEvents: "auto",
|
|
1927
|
+
contain: "layout style"
|
|
1928
|
+
},
|
|
1929
|
+
...this.attachment
|
|
1930
|
+
}));
|
|
1931
|
+
get props() {
|
|
1932
|
+
return c(this.#l);
|
|
1933
|
+
}
|
|
1934
|
+
set props(e) {
|
|
1935
|
+
b(this.#l, e);
|
|
1936
|
+
}
|
|
1937
|
+
popperProps = { onCloseAutoFocus: (e) => this.onCloseAutoFocus(e) };
|
|
1938
|
+
}, Er = class {
|
|
1939
|
+
opts;
|
|
1940
|
+
content;
|
|
1941
|
+
attachment;
|
|
1942
|
+
#e = l(!1);
|
|
1943
|
+
constructor(e, t) {
|
|
1944
|
+
this.opts = e, this.content = t, this.attachment = I(this.opts.ref), this.onpointermove = this.onpointermove.bind(this), this.onpointerleave = this.onpointerleave.bind(this), this.onfocus = this.onfocus.bind(this), this.onblur = this.onblur.bind(this);
|
|
1945
|
+
}
|
|
1946
|
+
onpointermove(e) {
|
|
1947
|
+
if (!e.defaultPrevented && z(e)) if (this.opts.disabled.current) this.content.onItemLeave(e);
|
|
1948
|
+
else {
|
|
1949
|
+
if (this.content.onItemEnter()) return;
|
|
1950
|
+
let t = e.currentTarget;
|
|
1951
|
+
if (!B(t)) return;
|
|
1952
|
+
t.focus({ preventScroll: !0 });
|
|
1953
|
+
}
|
|
1954
|
+
}
|
|
1955
|
+
onpointerleave(e) {
|
|
1956
|
+
e.defaultPrevented || z(e) && this.content.onItemLeave(e);
|
|
1957
|
+
}
|
|
1958
|
+
onfocus(e) {
|
|
1959
|
+
F(() => {
|
|
1960
|
+
e.defaultPrevented || this.opts.disabled.current || b(this.#e, !0);
|
|
1961
|
+
});
|
|
1962
|
+
}
|
|
1963
|
+
onblur(e) {
|
|
1964
|
+
F(() => {
|
|
1965
|
+
e.defaultPrevented || b(this.#e, !1);
|
|
1966
|
+
});
|
|
1967
|
+
}
|
|
1968
|
+
#t = u(() => ({
|
|
1969
|
+
id: this.opts.id.current,
|
|
1970
|
+
tabindex: -1,
|
|
1971
|
+
role: "menuitem",
|
|
1972
|
+
"aria-disabled": Zt(this.opts.disabled.current),
|
|
1973
|
+
"data-disabled": Qt(this.opts.disabled.current),
|
|
1974
|
+
"data-highlighted": c(this.#e) ? "" : void 0,
|
|
1975
|
+
[this.content.parentMenu.root.getBitsAttr("item")]: "",
|
|
1976
|
+
onpointermove: this.onpointermove,
|
|
1977
|
+
onpointerleave: this.onpointerleave,
|
|
1978
|
+
onfocus: this.onfocus,
|
|
1979
|
+
onblur: this.onblur,
|
|
1980
|
+
...this.attachment
|
|
1981
|
+
}));
|
|
1982
|
+
get props() {
|
|
1983
|
+
return c(this.#t);
|
|
1984
|
+
}
|
|
1985
|
+
set props(e) {
|
|
1986
|
+
b(this.#t, e);
|
|
1987
|
+
}
|
|
1988
|
+
}, Dr = class e {
|
|
1989
|
+
static create(t) {
|
|
1990
|
+
return new e(t, new Er(t, dr.get()));
|
|
1991
|
+
}
|
|
1992
|
+
opts;
|
|
1993
|
+
item;
|
|
1994
|
+
root;
|
|
1995
|
+
#e = !1;
|
|
1996
|
+
constructor(e, t) {
|
|
1997
|
+
this.opts = e, this.item = t, this.root = t.content.parentMenu.root, this.onkeydown = this.onkeydown.bind(this), this.onclick = this.onclick.bind(this), this.onpointerdown = this.onpointerdown.bind(this), this.onpointerup = this.onpointerup.bind(this);
|
|
1998
|
+
}
|
|
1999
|
+
#t() {
|
|
2000
|
+
if (this.item.opts.disabled.current) return;
|
|
2001
|
+
let e = new CustomEvent("menuitemselect", {
|
|
2002
|
+
bubbles: !0,
|
|
2003
|
+
cancelable: !0
|
|
2004
|
+
});
|
|
2005
|
+
if (this.opts.onSelect.current(e), e.defaultPrevented) {
|
|
2006
|
+
this.item.content.parentMenu.root.isUsingKeyboard.current = !1;
|
|
2007
|
+
return;
|
|
2008
|
+
}
|
|
2009
|
+
this.opts.closeOnSelect.current && this.item.content.parentMenu.root.opts.onClose();
|
|
2010
|
+
}
|
|
2011
|
+
onkeydown(e) {
|
|
2012
|
+
let t = this.item.content.search !== "";
|
|
2013
|
+
if (!(this.item.opts.disabled.current || t && e.key === " ") && Lt.includes(e.key)) {
|
|
2014
|
+
if (!B(e.currentTarget)) return;
|
|
2015
|
+
e.currentTarget.click(), e.preventDefault();
|
|
2016
|
+
}
|
|
2017
|
+
}
|
|
2018
|
+
onclick(e) {
|
|
2019
|
+
this.item.opts.disabled.current || this.#t();
|
|
2020
|
+
}
|
|
2021
|
+
onpointerup(e) {
|
|
2022
|
+
if (!e.defaultPrevented && !this.#e) {
|
|
2023
|
+
if (!B(e.currentTarget)) return;
|
|
2024
|
+
e.currentTarget?.click();
|
|
2025
|
+
}
|
|
2026
|
+
}
|
|
2027
|
+
onpointerdown(e) {
|
|
2028
|
+
this.#e = !0;
|
|
2029
|
+
}
|
|
2030
|
+
#n = u(() => Ke(this.item.props, {
|
|
2031
|
+
onclick: this.onclick,
|
|
2032
|
+
onpointerdown: this.onpointerdown,
|
|
2033
|
+
onpointerup: this.onpointerup,
|
|
2034
|
+
onkeydown: this.onkeydown
|
|
2035
|
+
}));
|
|
2036
|
+
get props() {
|
|
2037
|
+
return c(this.#n);
|
|
2038
|
+
}
|
|
2039
|
+
set props(e) {
|
|
2040
|
+
b(this.#n, e);
|
|
2041
|
+
}
|
|
2042
|
+
}, Or = class e {
|
|
2043
|
+
static create(t) {
|
|
2044
|
+
return fr.set(new e(t, lr.get()));
|
|
2045
|
+
}
|
|
2046
|
+
opts;
|
|
2047
|
+
root;
|
|
2048
|
+
attachment;
|
|
2049
|
+
#e = l(void 0);
|
|
2050
|
+
get groupHeadingId() {
|
|
2051
|
+
return c(this.#e);
|
|
2052
|
+
}
|
|
2053
|
+
set groupHeadingId(e) {
|
|
2054
|
+
b(this.#e, e, !0);
|
|
2055
|
+
}
|
|
2056
|
+
constructor(e, t) {
|
|
2057
|
+
this.opts = e, this.root = t, this.attachment = I(this.opts.ref);
|
|
2058
|
+
}
|
|
2059
|
+
#t = u(() => ({
|
|
2060
|
+
id: this.opts.id.current,
|
|
2061
|
+
role: "group",
|
|
2062
|
+
"aria-labelledby": this.groupHeadingId,
|
|
2063
|
+
[this.root.getBitsAttr("group")]: "",
|
|
2064
|
+
...this.attachment
|
|
2065
|
+
}));
|
|
2066
|
+
get props() {
|
|
2067
|
+
return c(this.#t);
|
|
2068
|
+
}
|
|
2069
|
+
set props(e) {
|
|
2070
|
+
b(this.#t, e);
|
|
2071
|
+
}
|
|
2072
|
+
}, kr = class e {
|
|
2073
|
+
static create(t) {
|
|
2074
|
+
return new e(t, lr.get());
|
|
2075
|
+
}
|
|
2076
|
+
opts;
|
|
2077
|
+
root;
|
|
2078
|
+
attachment;
|
|
2079
|
+
constructor(e, t) {
|
|
2080
|
+
this.opts = e, this.root = t, this.attachment = I(this.opts.ref);
|
|
2081
|
+
}
|
|
2082
|
+
#e = u(() => ({
|
|
2083
|
+
id: this.opts.id.current,
|
|
2084
|
+
role: "group",
|
|
2085
|
+
[this.root.getBitsAttr("separator")]: "",
|
|
2086
|
+
...this.attachment
|
|
2087
|
+
}));
|
|
2088
|
+
get props() {
|
|
2089
|
+
return c(this.#e);
|
|
2090
|
+
}
|
|
2091
|
+
set props(e) {
|
|
2092
|
+
b(this.#e, e);
|
|
2093
|
+
}
|
|
2094
|
+
}, Ar = class e {
|
|
2095
|
+
static create(t) {
|
|
2096
|
+
return new e(t, ur.get());
|
|
2097
|
+
}
|
|
2098
|
+
opts;
|
|
2099
|
+
parentMenu;
|
|
2100
|
+
attachment;
|
|
2101
|
+
constructor(e, t) {
|
|
2102
|
+
this.opts = e, this.parentMenu = t, this.attachment = I(this.opts.ref, (e) => this.parentMenu.triggerNode = e);
|
|
2103
|
+
}
|
|
2104
|
+
onclick = (e) => {
|
|
2105
|
+
this.opts.disabled.current || e.detail !== 0 || (this.parentMenu.toggleOpen(), e.preventDefault());
|
|
2106
|
+
};
|
|
2107
|
+
onpointerdown = (e) => {
|
|
2108
|
+
if (!this.opts.disabled.current) {
|
|
2109
|
+
if (e.pointerType === "touch") return e.preventDefault();
|
|
2110
|
+
e.button === 0 && e.ctrlKey === !1 && (this.parentMenu.toggleOpen(), this.parentMenu.opts.open.current || e.preventDefault());
|
|
2111
|
+
}
|
|
2112
|
+
};
|
|
2113
|
+
onpointerup = (e) => {
|
|
2114
|
+
this.opts.disabled.current || e.pointerType === "touch" && (e.preventDefault(), this.parentMenu.toggleOpen());
|
|
2115
|
+
};
|
|
2116
|
+
onkeydown = (e) => {
|
|
2117
|
+
if (!this.opts.disabled.current) {
|
|
2118
|
+
if (e.key === " " || e.key === "Enter") {
|
|
2119
|
+
this.parentMenu.toggleOpen(), e.preventDefault();
|
|
2120
|
+
return;
|
|
2121
|
+
}
|
|
2122
|
+
e.key === "ArrowDown" && (this.parentMenu.onOpen(), e.preventDefault());
|
|
2123
|
+
}
|
|
2124
|
+
};
|
|
2125
|
+
#e = u(() => {
|
|
2126
|
+
if (this.parentMenu.opts.open.current && this.parentMenu.contentId.current) return this.parentMenu.contentId.current;
|
|
2127
|
+
});
|
|
2128
|
+
#t = u(() => ({
|
|
2129
|
+
id: this.opts.id.current,
|
|
2130
|
+
disabled: this.opts.disabled.current,
|
|
2131
|
+
"aria-haspopup": "menu",
|
|
2132
|
+
"aria-expanded": Zt(this.parentMenu.opts.open.current),
|
|
2133
|
+
"aria-controls": c(this.#e),
|
|
2134
|
+
"data-disabled": Qt(this.opts.disabled.current),
|
|
2135
|
+
"data-state": en(this.parentMenu.opts.open.current),
|
|
2136
|
+
[this.parentMenu.root.getBitsAttr("trigger")]: "",
|
|
2137
|
+
onclick: this.onclick,
|
|
2138
|
+
onpointerdown: this.onpointerdown,
|
|
2139
|
+
onpointerup: this.onpointerup,
|
|
2140
|
+
onkeydown: this.onkeydown,
|
|
2141
|
+
...this.attachment
|
|
2142
|
+
}));
|
|
2143
|
+
get props() {
|
|
2144
|
+
return c(this.#t);
|
|
2145
|
+
}
|
|
2146
|
+
set props(e) {
|
|
2147
|
+
b(this.#t, e);
|
|
2148
|
+
}
|
|
2149
|
+
}, jr = class {
|
|
2150
|
+
static create(e) {
|
|
2151
|
+
let t = ur.get();
|
|
2152
|
+
return ur.set(new wr(e, t.root, t));
|
|
2153
|
+
}
|
|
2154
|
+
}, Mr = [
|
|
2155
|
+
"top",
|
|
2156
|
+
"right",
|
|
2157
|
+
"bottom",
|
|
2158
|
+
"left"
|
|
2159
|
+
], H = Math.min, U = Math.max, Nr = Math.round, Pr = Math.floor, W = (e) => ({
|
|
2160
|
+
x: e,
|
|
2161
|
+
y: e
|
|
2162
|
+
}), Fr = {
|
|
2163
|
+
left: "right",
|
|
2164
|
+
right: "left",
|
|
2165
|
+
bottom: "top",
|
|
2166
|
+
top: "bottom"
|
|
2167
|
+
};
|
|
2168
|
+
function Ir(e, t, n) {
|
|
2169
|
+
return U(e, H(t, n));
|
|
2170
|
+
}
|
|
2171
|
+
function G(e, t) {
|
|
2172
|
+
return typeof e == "function" ? e(t) : e;
|
|
2173
|
+
}
|
|
2174
|
+
function K(e) {
|
|
2175
|
+
return e.split("-")[0];
|
|
2176
|
+
}
|
|
2177
|
+
function Lr(e) {
|
|
2178
|
+
return e.split("-")[1];
|
|
2179
|
+
}
|
|
2180
|
+
function Rr(e) {
|
|
2181
|
+
return e === "x" ? "y" : "x";
|
|
2182
|
+
}
|
|
2183
|
+
function zr(e) {
|
|
2184
|
+
return e === "y" ? "height" : "width";
|
|
2185
|
+
}
|
|
2186
|
+
function q(e) {
|
|
2187
|
+
let t = e[0];
|
|
2188
|
+
return t === "t" || t === "b" ? "y" : "x";
|
|
2189
|
+
}
|
|
2190
|
+
function Br(e) {
|
|
2191
|
+
return Rr(q(e));
|
|
2192
|
+
}
|
|
2193
|
+
function Vr(e, t, n) {
|
|
2194
|
+
n === void 0 && (n = !1);
|
|
2195
|
+
let r = Lr(e), i = Br(e), a = zr(i), o = i === "x" ? r === (n ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
|
|
2196
|
+
return t.reference[a] > t.floating[a] && (o = Xr(o)), [o, Xr(o)];
|
|
2197
|
+
}
|
|
2198
|
+
function Hr(e) {
|
|
2199
|
+
let t = Xr(e);
|
|
2200
|
+
return [
|
|
2201
|
+
Ur(e),
|
|
2202
|
+
t,
|
|
2203
|
+
Ur(t)
|
|
2204
|
+
];
|
|
2205
|
+
}
|
|
2206
|
+
function Ur(e) {
|
|
2207
|
+
return e.includes("start") ? e.replace("start", "end") : e.replace("end", "start");
|
|
2208
|
+
}
|
|
2209
|
+
var Wr = ["left", "right"], Gr = ["right", "left"], Kr = ["top", "bottom"], qr = ["bottom", "top"];
|
|
2210
|
+
function Jr(e, t, n) {
|
|
2211
|
+
switch (e) {
|
|
2212
|
+
case "top":
|
|
2213
|
+
case "bottom": return n ? t ? Gr : Wr : t ? Wr : Gr;
|
|
2214
|
+
case "left":
|
|
2215
|
+
case "right": return t ? Kr : qr;
|
|
2216
|
+
default: return [];
|
|
2217
|
+
}
|
|
2218
|
+
}
|
|
2219
|
+
function Yr(e, t, n, r) {
|
|
2220
|
+
let i = Lr(e), a = Jr(K(e), n === "start", r);
|
|
2221
|
+
return i && (a = a.map((e) => e + "-" + i), t && (a = a.concat(a.map(Ur)))), a;
|
|
2222
|
+
}
|
|
2223
|
+
function Xr(e) {
|
|
2224
|
+
let t = K(e);
|
|
2225
|
+
return Fr[t] + e.slice(t.length);
|
|
2226
|
+
}
|
|
2227
|
+
function Zr(e) {
|
|
2228
|
+
return {
|
|
2229
|
+
top: 0,
|
|
2230
|
+
right: 0,
|
|
2231
|
+
bottom: 0,
|
|
2232
|
+
left: 0,
|
|
2233
|
+
...e
|
|
2234
|
+
};
|
|
2235
|
+
}
|
|
2236
|
+
function Qr(e) {
|
|
2237
|
+
return typeof e == "number" ? {
|
|
2238
|
+
top: e,
|
|
2239
|
+
right: e,
|
|
2240
|
+
bottom: e,
|
|
2241
|
+
left: e
|
|
2242
|
+
} : Zr(e);
|
|
2243
|
+
}
|
|
2244
|
+
function $r(e) {
|
|
2245
|
+
let { x: t, y: n, width: r, height: i } = e;
|
|
2246
|
+
return {
|
|
2247
|
+
width: r,
|
|
2248
|
+
height: i,
|
|
2249
|
+
top: n,
|
|
2250
|
+
left: t,
|
|
2251
|
+
right: t + r,
|
|
2252
|
+
bottom: n + i,
|
|
2253
|
+
x: t,
|
|
2254
|
+
y: n
|
|
2255
|
+
};
|
|
2256
|
+
}
|
|
2257
|
+
//#endregion
|
|
2258
|
+
//#region ../node_modules/.bun/@floating-ui+core@1.7.5/node_modules/@floating-ui/core/dist/floating-ui.core.mjs
|
|
2259
|
+
function ei(e, t, n) {
|
|
2260
|
+
let { reference: r, floating: i } = e, a = q(t), o = Br(t), s = zr(o), c = K(t), l = a === "y", u = r.x + r.width / 2 - i.width / 2, d = r.y + r.height / 2 - i.height / 2, f = r[s] / 2 - i[s] / 2, p;
|
|
2261
|
+
switch (c) {
|
|
2262
|
+
case "top":
|
|
2263
|
+
p = {
|
|
2264
|
+
x: u,
|
|
2265
|
+
y: r.y - i.height
|
|
2266
|
+
};
|
|
2267
|
+
break;
|
|
2268
|
+
case "bottom":
|
|
2269
|
+
p = {
|
|
2270
|
+
x: u,
|
|
2271
|
+
y: r.y + r.height
|
|
2272
|
+
};
|
|
2273
|
+
break;
|
|
2274
|
+
case "right":
|
|
2275
|
+
p = {
|
|
2276
|
+
x: r.x + r.width,
|
|
2277
|
+
y: d
|
|
2278
|
+
};
|
|
2279
|
+
break;
|
|
2280
|
+
case "left":
|
|
2281
|
+
p = {
|
|
2282
|
+
x: r.x - i.width,
|
|
2283
|
+
y: d
|
|
2284
|
+
};
|
|
2285
|
+
break;
|
|
2286
|
+
default: p = {
|
|
2287
|
+
x: r.x,
|
|
2288
|
+
y: r.y
|
|
2289
|
+
};
|
|
2290
|
+
}
|
|
2291
|
+
switch (Lr(t)) {
|
|
2292
|
+
case "start":
|
|
2293
|
+
p[o] -= f * (n && l ? -1 : 1);
|
|
2294
|
+
break;
|
|
2295
|
+
case "end":
|
|
2296
|
+
p[o] += f * (n && l ? -1 : 1);
|
|
2297
|
+
break;
|
|
2298
|
+
}
|
|
2299
|
+
return p;
|
|
2300
|
+
}
|
|
2301
|
+
async function ti(e, t) {
|
|
2302
|
+
t === void 0 && (t = {});
|
|
2303
|
+
let { x: n, y: r, platform: i, rects: a, elements: o, strategy: s } = e, { boundary: c = "clippingAncestors", rootBoundary: l = "viewport", elementContext: u = "floating", altBoundary: d = !1, padding: f = 0 } = G(t, e), p = Qr(f), m = o[d ? u === "floating" ? "reference" : "floating" : u], h = $r(await i.getClippingRect({
|
|
2304
|
+
element: await (i.isElement == null ? void 0 : i.isElement(m)) ?? !0 ? m : m.contextElement || await (i.getDocumentElement == null ? void 0 : i.getDocumentElement(o.floating)),
|
|
2305
|
+
boundary: c,
|
|
2306
|
+
rootBoundary: l,
|
|
2307
|
+
strategy: s
|
|
2308
|
+
})), g = u === "floating" ? {
|
|
2309
|
+
x: n,
|
|
2310
|
+
y: r,
|
|
2311
|
+
width: a.floating.width,
|
|
2312
|
+
height: a.floating.height
|
|
2313
|
+
} : a.reference, _ = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(o.floating)), v = await (i.isElement == null ? void 0 : i.isElement(_)) && await (i.getScale == null ? void 0 : i.getScale(_)) || {
|
|
2314
|
+
x: 1,
|
|
2315
|
+
y: 1
|
|
2316
|
+
}, y = $r(i.convertOffsetParentRelativeRectToViewportRelativeRect ? await i.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
2317
|
+
elements: o,
|
|
2318
|
+
rect: g,
|
|
2319
|
+
offsetParent: _,
|
|
2320
|
+
strategy: s
|
|
2321
|
+
}) : g);
|
|
2322
|
+
return {
|
|
2323
|
+
top: (h.top - y.top + p.top) / v.y,
|
|
2324
|
+
bottom: (y.bottom - h.bottom + p.bottom) / v.y,
|
|
2325
|
+
left: (h.left - y.left + p.left) / v.x,
|
|
2326
|
+
right: (y.right - h.right + p.right) / v.x
|
|
2327
|
+
};
|
|
2328
|
+
}
|
|
2329
|
+
var ni = 50, ri = async (e, t, n) => {
|
|
2330
|
+
let { placement: r = "bottom", strategy: i = "absolute", middleware: a = [], platform: o } = n, s = o.detectOverflow ? o : {
|
|
2331
|
+
...o,
|
|
2332
|
+
detectOverflow: ti
|
|
2333
|
+
}, c = await (o.isRTL == null ? void 0 : o.isRTL(t)), l = await o.getElementRects({
|
|
2334
|
+
reference: e,
|
|
2335
|
+
floating: t,
|
|
2336
|
+
strategy: i
|
|
2337
|
+
}), { x: u, y: d } = ei(l, r, c), f = r, p = 0, m = {};
|
|
2338
|
+
for (let n = 0; n < a.length; n++) {
|
|
2339
|
+
let h = a[n];
|
|
2340
|
+
if (!h) continue;
|
|
2341
|
+
let { name: g, fn: _ } = h, { x: v, y, data: b, reset: x } = await _({
|
|
2342
|
+
x: u,
|
|
2343
|
+
y: d,
|
|
2344
|
+
initialPlacement: r,
|
|
2345
|
+
placement: f,
|
|
2346
|
+
strategy: i,
|
|
2347
|
+
middlewareData: m,
|
|
2348
|
+
rects: l,
|
|
2349
|
+
platform: s,
|
|
2350
|
+
elements: {
|
|
2351
|
+
reference: e,
|
|
2352
|
+
floating: t
|
|
2353
|
+
}
|
|
2354
|
+
});
|
|
2355
|
+
u = v ?? u, d = y ?? d, m[g] = {
|
|
2356
|
+
...m[g],
|
|
2357
|
+
...b
|
|
2358
|
+
}, x && p < ni && (p++, typeof x == "object" && (x.placement && (f = x.placement), x.rects && (l = x.rects === !0 ? await o.getElementRects({
|
|
2359
|
+
reference: e,
|
|
2360
|
+
floating: t,
|
|
2361
|
+
strategy: i
|
|
2362
|
+
}) : x.rects), {x: u, y: d} = ei(l, f, c)), n = -1);
|
|
2363
|
+
}
|
|
2364
|
+
return {
|
|
2365
|
+
x: u,
|
|
2366
|
+
y: d,
|
|
2367
|
+
placement: f,
|
|
2368
|
+
strategy: i,
|
|
2369
|
+
middlewareData: m
|
|
2370
|
+
};
|
|
2371
|
+
}, ii = (e) => ({
|
|
2372
|
+
name: "arrow",
|
|
2373
|
+
options: e,
|
|
2374
|
+
async fn(t) {
|
|
2375
|
+
let { x: n, y: r, placement: i, rects: a, platform: o, elements: s, middlewareData: c } = t, { element: l, padding: u = 0 } = G(e, t) || {};
|
|
2376
|
+
if (l == null) return {};
|
|
2377
|
+
let d = Qr(u), f = {
|
|
2378
|
+
x: n,
|
|
2379
|
+
y: r
|
|
2380
|
+
}, p = Br(i), m = zr(p), h = await o.getDimensions(l), g = p === "y", _ = g ? "top" : "left", v = g ? "bottom" : "right", y = g ? "clientHeight" : "clientWidth", b = a.reference[m] + a.reference[p] - f[p] - a.floating[m], x = f[p] - a.reference[p], S = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(l)), C = S ? S[y] : 0;
|
|
2381
|
+
(!C || !await (o.isElement == null ? void 0 : o.isElement(S))) && (C = s.floating[y] || a.floating[m]);
|
|
2382
|
+
let w = b / 2 - x / 2, T = C / 2 - h[m] / 2 - 1, E = H(d[_], T), D = H(d[v], T), O = E, ee = C - h[m] - D, k = C / 2 - h[m] / 2 + w, A = Ir(O, k, ee), te = !c.arrow && Lr(i) != null && k !== A && a.reference[m] / 2 - (k < O ? E : D) - h[m] / 2 < 0, j = te ? k < O ? k - O : k - ee : 0;
|
|
2383
|
+
return {
|
|
2384
|
+
[p]: f[p] + j,
|
|
2385
|
+
data: {
|
|
2386
|
+
[p]: A,
|
|
2387
|
+
centerOffset: k - A - j,
|
|
2388
|
+
...te && { alignmentOffset: j }
|
|
2389
|
+
},
|
|
2390
|
+
reset: te
|
|
2391
|
+
};
|
|
2392
|
+
}
|
|
2393
|
+
}), ai = function(e) {
|
|
2394
|
+
return e === void 0 && (e = {}), {
|
|
2395
|
+
name: "flip",
|
|
2396
|
+
options: e,
|
|
2397
|
+
async fn(t) {
|
|
2398
|
+
var n;
|
|
2399
|
+
let { placement: r, middlewareData: i, rects: a, initialPlacement: o, platform: s, elements: c } = t, { mainAxis: l = !0, crossAxis: u = !0, fallbackPlacements: d, fallbackStrategy: f = "bestFit", fallbackAxisSideDirection: p = "none", flipAlignment: m = !0, ...h } = G(e, t);
|
|
2400
|
+
if ((n = i.arrow) != null && n.alignmentOffset) return {};
|
|
2401
|
+
let g = K(r), _ = q(o), v = K(o) === o, y = await (s.isRTL == null ? void 0 : s.isRTL(c.floating)), b = d || (v || !m ? [Xr(o)] : Hr(o)), x = p !== "none";
|
|
2402
|
+
!d && x && b.push(...Yr(o, m, p, y));
|
|
2403
|
+
let S = [o, ...b], C = await s.detectOverflow(t, h), w = [], T = i.flip?.overflows || [];
|
|
2404
|
+
if (l && w.push(C[g]), u) {
|
|
2405
|
+
let e = Vr(r, a, y);
|
|
2406
|
+
w.push(C[e[0]], C[e[1]]);
|
|
2407
|
+
}
|
|
2408
|
+
if (T = [...T, {
|
|
2409
|
+
placement: r,
|
|
2410
|
+
overflows: w
|
|
2411
|
+
}], !w.every((e) => e <= 0)) {
|
|
2412
|
+
let e = (i.flip?.index || 0) + 1, t = S[e];
|
|
2413
|
+
if (t && (!(u === "alignment" && _ !== q(t)) || T.every((e) => q(e.placement) === _ ? e.overflows[0] > 0 : !0))) return {
|
|
2414
|
+
data: {
|
|
2415
|
+
index: e,
|
|
2416
|
+
overflows: T
|
|
2417
|
+
},
|
|
2418
|
+
reset: { placement: t }
|
|
2419
|
+
};
|
|
2420
|
+
let n = T.filter((e) => e.overflows[0] <= 0).sort((e, t) => e.overflows[1] - t.overflows[1])[0]?.placement;
|
|
2421
|
+
if (!n) switch (f) {
|
|
2422
|
+
case "bestFit": {
|
|
2423
|
+
let e = T.filter((e) => {
|
|
2424
|
+
if (x) {
|
|
2425
|
+
let t = q(e.placement);
|
|
2426
|
+
return t === _ || t === "y";
|
|
2427
|
+
}
|
|
2428
|
+
return !0;
|
|
2429
|
+
}).map((e) => [e.placement, e.overflows.filter((e) => e > 0).reduce((e, t) => e + t, 0)]).sort((e, t) => e[1] - t[1])[0]?.[0];
|
|
2430
|
+
e && (n = e);
|
|
2431
|
+
break;
|
|
2432
|
+
}
|
|
2433
|
+
case "initialPlacement":
|
|
2434
|
+
n = o;
|
|
2435
|
+
break;
|
|
2436
|
+
}
|
|
2437
|
+
if (r !== n) return { reset: { placement: n } };
|
|
2438
|
+
}
|
|
2439
|
+
return {};
|
|
2440
|
+
}
|
|
2441
|
+
};
|
|
2442
|
+
};
|
|
2443
|
+
function oi(e, t) {
|
|
2444
|
+
return {
|
|
2445
|
+
top: e.top - t.height,
|
|
2446
|
+
right: e.right - t.width,
|
|
2447
|
+
bottom: e.bottom - t.height,
|
|
2448
|
+
left: e.left - t.width
|
|
2449
|
+
};
|
|
2450
|
+
}
|
|
2451
|
+
function si(e) {
|
|
2452
|
+
return Mr.some((t) => e[t] >= 0);
|
|
2453
|
+
}
|
|
2454
|
+
var ci = function(e) {
|
|
2455
|
+
return e === void 0 && (e = {}), {
|
|
2456
|
+
name: "hide",
|
|
2457
|
+
options: e,
|
|
2458
|
+
async fn(t) {
|
|
2459
|
+
let { rects: n, platform: r } = t, { strategy: i = "referenceHidden", ...a } = G(e, t);
|
|
2460
|
+
switch (i) {
|
|
2461
|
+
case "referenceHidden": {
|
|
2462
|
+
let e = oi(await r.detectOverflow(t, {
|
|
2463
|
+
...a,
|
|
2464
|
+
elementContext: "reference"
|
|
2465
|
+
}), n.reference);
|
|
2466
|
+
return { data: {
|
|
2467
|
+
referenceHiddenOffsets: e,
|
|
2468
|
+
referenceHidden: si(e)
|
|
2469
|
+
} };
|
|
2470
|
+
}
|
|
2471
|
+
case "escaped": {
|
|
2472
|
+
let e = oi(await r.detectOverflow(t, {
|
|
2473
|
+
...a,
|
|
2474
|
+
altBoundary: !0
|
|
2475
|
+
}), n.floating);
|
|
2476
|
+
return { data: {
|
|
2477
|
+
escapedOffsets: e,
|
|
2478
|
+
escaped: si(e)
|
|
2479
|
+
} };
|
|
2480
|
+
}
|
|
2481
|
+
default: return {};
|
|
2482
|
+
}
|
|
2483
|
+
}
|
|
2484
|
+
};
|
|
2485
|
+
}, li = /*#__PURE__*/ new Set(["left", "top"]);
|
|
2486
|
+
async function ui(e, t) {
|
|
2487
|
+
let { placement: n, platform: r, elements: i } = e, a = await (r.isRTL == null ? void 0 : r.isRTL(i.floating)), o = K(n), s = Lr(n), c = q(n) === "y", l = li.has(o) ? -1 : 1, u = a && c ? -1 : 1, d = G(t, e), { mainAxis: f, crossAxis: p, alignmentAxis: m } = typeof d == "number" ? {
|
|
2488
|
+
mainAxis: d,
|
|
2489
|
+
crossAxis: 0,
|
|
2490
|
+
alignmentAxis: null
|
|
2491
|
+
} : {
|
|
2492
|
+
mainAxis: d.mainAxis || 0,
|
|
2493
|
+
crossAxis: d.crossAxis || 0,
|
|
2494
|
+
alignmentAxis: d.alignmentAxis
|
|
2495
|
+
};
|
|
2496
|
+
return s && typeof m == "number" && (p = s === "end" ? m * -1 : m), c ? {
|
|
2497
|
+
x: p * u,
|
|
2498
|
+
y: f * l
|
|
2499
|
+
} : {
|
|
2500
|
+
x: f * l,
|
|
2501
|
+
y: p * u
|
|
2502
|
+
};
|
|
2503
|
+
}
|
|
2504
|
+
var di = function(e) {
|
|
2505
|
+
return e === void 0 && (e = 0), {
|
|
2506
|
+
name: "offset",
|
|
2507
|
+
options: e,
|
|
2508
|
+
async fn(t) {
|
|
2509
|
+
var n;
|
|
2510
|
+
let { x: r, y: i, placement: a, middlewareData: o } = t, s = await ui(t, e);
|
|
2511
|
+
return a === o.offset?.placement && (n = o.arrow) != null && n.alignmentOffset ? {} : {
|
|
2512
|
+
x: r + s.x,
|
|
2513
|
+
y: i + s.y,
|
|
2514
|
+
data: {
|
|
2515
|
+
...s,
|
|
2516
|
+
placement: a
|
|
2517
|
+
}
|
|
2518
|
+
};
|
|
2519
|
+
}
|
|
2520
|
+
};
|
|
2521
|
+
}, fi = function(e) {
|
|
2522
|
+
return e === void 0 && (e = {}), {
|
|
2523
|
+
name: "shift",
|
|
2524
|
+
options: e,
|
|
2525
|
+
async fn(t) {
|
|
2526
|
+
let { x: n, y: r, placement: i, platform: a } = t, { mainAxis: o = !0, crossAxis: s = !1, limiter: c = { fn: (e) => {
|
|
2527
|
+
let { x: t, y: n } = e;
|
|
2528
|
+
return {
|
|
2529
|
+
x: t,
|
|
2530
|
+
y: n
|
|
2531
|
+
};
|
|
2532
|
+
} }, ...l } = G(e, t), u = {
|
|
2533
|
+
x: n,
|
|
2534
|
+
y: r
|
|
2535
|
+
}, d = await a.detectOverflow(t, l), f = q(K(i)), p = Rr(f), m = u[p], h = u[f];
|
|
2536
|
+
if (o) {
|
|
2537
|
+
let e = p === "y" ? "top" : "left", t = p === "y" ? "bottom" : "right", n = m + d[e], r = m - d[t];
|
|
2538
|
+
m = Ir(n, m, r);
|
|
2539
|
+
}
|
|
2540
|
+
if (s) {
|
|
2541
|
+
let e = f === "y" ? "top" : "left", t = f === "y" ? "bottom" : "right", n = h + d[e], r = h - d[t];
|
|
2542
|
+
h = Ir(n, h, r);
|
|
2543
|
+
}
|
|
2544
|
+
let g = c.fn({
|
|
2545
|
+
...t,
|
|
2546
|
+
[p]: m,
|
|
2547
|
+
[f]: h
|
|
2548
|
+
});
|
|
2549
|
+
return {
|
|
2550
|
+
...g,
|
|
2551
|
+
data: {
|
|
2552
|
+
x: g.x - n,
|
|
2553
|
+
y: g.y - r,
|
|
2554
|
+
enabled: {
|
|
2555
|
+
[p]: o,
|
|
2556
|
+
[f]: s
|
|
2557
|
+
}
|
|
2558
|
+
}
|
|
2559
|
+
};
|
|
2560
|
+
}
|
|
2561
|
+
};
|
|
2562
|
+
}, pi = function(e) {
|
|
2563
|
+
return e === void 0 && (e = {}), {
|
|
2564
|
+
options: e,
|
|
2565
|
+
fn(t) {
|
|
2566
|
+
let { x: n, y: r, placement: i, rects: a, middlewareData: o } = t, { offset: s = 0, mainAxis: c = !0, crossAxis: l = !0 } = G(e, t), u = {
|
|
2567
|
+
x: n,
|
|
2568
|
+
y: r
|
|
2569
|
+
}, d = q(i), f = Rr(d), p = u[f], m = u[d], h = G(s, t), g = typeof h == "number" ? {
|
|
2570
|
+
mainAxis: h,
|
|
2571
|
+
crossAxis: 0
|
|
2572
|
+
} : {
|
|
2573
|
+
mainAxis: 0,
|
|
2574
|
+
crossAxis: 0,
|
|
2575
|
+
...h
|
|
2576
|
+
};
|
|
2577
|
+
if (c) {
|
|
2578
|
+
let e = f === "y" ? "height" : "width", t = a.reference[f] - a.floating[e] + g.mainAxis, n = a.reference[f] + a.reference[e] - g.mainAxis;
|
|
2579
|
+
p < t ? p = t : p > n && (p = n);
|
|
2580
|
+
}
|
|
2581
|
+
if (l) {
|
|
2582
|
+
let e = f === "y" ? "width" : "height", t = li.has(K(i)), n = a.reference[d] - a.floating[e] + (t && o.offset?.[d] || 0) + (t ? 0 : g.crossAxis), r = a.reference[d] + a.reference[e] + (t ? 0 : o.offset?.[d] || 0) - (t ? g.crossAxis : 0);
|
|
2583
|
+
m < n ? m = n : m > r && (m = r);
|
|
2584
|
+
}
|
|
2585
|
+
return {
|
|
2586
|
+
[f]: p,
|
|
2587
|
+
[d]: m
|
|
2588
|
+
};
|
|
2589
|
+
}
|
|
2590
|
+
};
|
|
2591
|
+
}, mi = function(e) {
|
|
2592
|
+
return e === void 0 && (e = {}), {
|
|
2593
|
+
name: "size",
|
|
2594
|
+
options: e,
|
|
2595
|
+
async fn(t) {
|
|
2596
|
+
var n, r;
|
|
2597
|
+
let { placement: i, rects: a, platform: o, elements: s } = t, { apply: c = () => {}, ...l } = G(e, t), u = await o.detectOverflow(t, l), d = K(i), f = Lr(i), p = q(i) === "y", { width: m, height: h } = a.floating, g, _;
|
|
2598
|
+
d === "top" || d === "bottom" ? (g = d, _ = f === (await (o.isRTL == null ? void 0 : o.isRTL(s.floating)) ? "start" : "end") ? "left" : "right") : (_ = d, g = f === "end" ? "top" : "bottom");
|
|
2599
|
+
let v = h - u.top - u.bottom, y = m - u.left - u.right, b = H(h - u[g], v), x = H(m - u[_], y), S = !t.middlewareData.shift, C = b, w = x;
|
|
2600
|
+
if ((n = t.middlewareData.shift) != null && n.enabled.x && (w = y), (r = t.middlewareData.shift) != null && r.enabled.y && (C = v), S && !f) {
|
|
2601
|
+
let e = U(u.left, 0), t = U(u.right, 0), n = U(u.top, 0), r = U(u.bottom, 0);
|
|
2602
|
+
p ? w = m - 2 * (e !== 0 || t !== 0 ? e + t : U(u.left, u.right)) : C = h - 2 * (n !== 0 || r !== 0 ? n + r : U(u.top, u.bottom));
|
|
2603
|
+
}
|
|
2604
|
+
await c({
|
|
2605
|
+
...t,
|
|
2606
|
+
availableWidth: w,
|
|
2607
|
+
availableHeight: C
|
|
2608
|
+
});
|
|
2609
|
+
let T = await o.getDimensions(s.floating);
|
|
2610
|
+
return m !== T.width || h !== T.height ? { reset: { rects: !0 } } : {};
|
|
2611
|
+
}
|
|
2612
|
+
};
|
|
2613
|
+
};
|
|
2614
|
+
//#endregion
|
|
2615
|
+
//#region ../node_modules/.bun/@floating-ui+utils@0.2.11/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs
|
|
2616
|
+
function hi() {
|
|
2617
|
+
return typeof window < "u";
|
|
2618
|
+
}
|
|
2619
|
+
function gi(e) {
|
|
2620
|
+
return _i(e) ? (e.nodeName || "").toLowerCase() : "#document";
|
|
2621
|
+
}
|
|
2622
|
+
function J(e) {
|
|
2623
|
+
var t;
|
|
2624
|
+
return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
|
|
2625
|
+
}
|
|
2626
|
+
function Y(e) {
|
|
2627
|
+
return ((_i(e) ? e.ownerDocument : e.document) || window.document)?.documentElement;
|
|
2628
|
+
}
|
|
2629
|
+
function _i(e) {
|
|
2630
|
+
return hi() ? e instanceof Node || e instanceof J(e).Node : !1;
|
|
2631
|
+
}
|
|
2632
|
+
function X(e) {
|
|
2633
|
+
return hi() ? e instanceof Element || e instanceof J(e).Element : !1;
|
|
2634
|
+
}
|
|
2635
|
+
function Z(e) {
|
|
2636
|
+
return hi() ? e instanceof HTMLElement || e instanceof J(e).HTMLElement : !1;
|
|
2637
|
+
}
|
|
2638
|
+
function vi(e) {
|
|
2639
|
+
return !hi() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof J(e).ShadowRoot;
|
|
2640
|
+
}
|
|
2641
|
+
function yi(e) {
|
|
2642
|
+
let { overflow: t, overflowX: n, overflowY: r, display: i } = Q(e);
|
|
2643
|
+
return /auto|scroll|overlay|hidden|clip/.test(t + r + n) && i !== "inline" && i !== "contents";
|
|
2644
|
+
}
|
|
2645
|
+
function bi(e) {
|
|
2646
|
+
return /^(table|td|th)$/.test(gi(e));
|
|
2647
|
+
}
|
|
2648
|
+
function xi(e) {
|
|
2649
|
+
try {
|
|
2650
|
+
if (e.matches(":popover-open")) return !0;
|
|
2651
|
+
} catch {}
|
|
2652
|
+
try {
|
|
2653
|
+
return e.matches(":modal");
|
|
2654
|
+
} catch {
|
|
2655
|
+
return !1;
|
|
2656
|
+
}
|
|
2657
|
+
}
|
|
2658
|
+
var Si = /transform|translate|scale|rotate|perspective|filter/, Ci = /paint|layout|strict|content/, wi = (e) => !!e && e !== "none", Ti;
|
|
2659
|
+
function Ei(e) {
|
|
2660
|
+
let t = X(e) ? Q(e) : e;
|
|
2661
|
+
return wi(t.transform) || wi(t.translate) || wi(t.scale) || wi(t.rotate) || wi(t.perspective) || !Oi() && (wi(t.backdropFilter) || wi(t.filter)) || Si.test(t.willChange || "") || Ci.test(t.contain || "");
|
|
2662
|
+
}
|
|
2663
|
+
function Di(e) {
|
|
2664
|
+
let t = $(e);
|
|
2665
|
+
for (; Z(t) && !ki(t);) {
|
|
2666
|
+
if (Ei(t)) return t;
|
|
2667
|
+
if (xi(t)) return null;
|
|
2668
|
+
t = $(t);
|
|
2669
|
+
}
|
|
2670
|
+
return null;
|
|
2671
|
+
}
|
|
2672
|
+
function Oi() {
|
|
2673
|
+
return Ti ??= typeof CSS < "u" && CSS.supports && CSS.supports("-webkit-backdrop-filter", "none"), Ti;
|
|
2674
|
+
}
|
|
2675
|
+
function ki(e) {
|
|
2676
|
+
return /^(html|body|#document)$/.test(gi(e));
|
|
2677
|
+
}
|
|
2678
|
+
function Q(e) {
|
|
2679
|
+
return J(e).getComputedStyle(e);
|
|
2680
|
+
}
|
|
2681
|
+
function Ai(e) {
|
|
2682
|
+
return X(e) ? {
|
|
2683
|
+
scrollLeft: e.scrollLeft,
|
|
2684
|
+
scrollTop: e.scrollTop
|
|
2685
|
+
} : {
|
|
2686
|
+
scrollLeft: e.scrollX,
|
|
2687
|
+
scrollTop: e.scrollY
|
|
2688
|
+
};
|
|
2689
|
+
}
|
|
2690
|
+
function $(e) {
|
|
2691
|
+
if (gi(e) === "html") return e;
|
|
2692
|
+
let t = e.assignedSlot || e.parentNode || vi(e) && e.host || Y(e);
|
|
2693
|
+
return vi(t) ? t.host : t;
|
|
2694
|
+
}
|
|
2695
|
+
function ji(e) {
|
|
2696
|
+
let t = $(e);
|
|
2697
|
+
return ki(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : Z(t) && yi(t) ? t : ji(t);
|
|
2698
|
+
}
|
|
2699
|
+
function Mi(e, t, n) {
|
|
2700
|
+
t === void 0 && (t = []), n === void 0 && (n = !0);
|
|
2701
|
+
let r = ji(e), i = r === e.ownerDocument?.body, a = J(r);
|
|
2702
|
+
if (i) {
|
|
2703
|
+
let e = Ni(a);
|
|
2704
|
+
return t.concat(a, a.visualViewport || [], yi(r) ? r : [], e && n ? Mi(e) : []);
|
|
2705
|
+
} else return t.concat(r, Mi(r, [], n));
|
|
2706
|
+
}
|
|
2707
|
+
function Ni(e) {
|
|
2708
|
+
return e.parent && Object.getPrototypeOf(e.parent) ? e.frameElement : null;
|
|
2709
|
+
}
|
|
2710
|
+
//#endregion
|
|
2711
|
+
//#region ../node_modules/.bun/@floating-ui+dom@1.7.6/node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
|
|
2712
|
+
function Pi(e) {
|
|
2713
|
+
let t = Q(e), n = parseFloat(t.width) || 0, r = parseFloat(t.height) || 0, i = Z(e), a = i ? e.offsetWidth : n, o = i ? e.offsetHeight : r, s = Nr(n) !== a || Nr(r) !== o;
|
|
2714
|
+
return s && (n = a, r = o), {
|
|
2715
|
+
width: n,
|
|
2716
|
+
height: r,
|
|
2717
|
+
$: s
|
|
2718
|
+
};
|
|
2719
|
+
}
|
|
2720
|
+
function Fi(e) {
|
|
2721
|
+
return X(e) ? e : e.contextElement;
|
|
2722
|
+
}
|
|
2723
|
+
function Ii(e) {
|
|
2724
|
+
let t = Fi(e);
|
|
2725
|
+
if (!Z(t)) return W(1);
|
|
2726
|
+
let n = t.getBoundingClientRect(), { width: r, height: i, $: a } = Pi(t), o = (a ? Nr(n.width) : n.width) / r, s = (a ? Nr(n.height) : n.height) / i;
|
|
2727
|
+
return (!o || !Number.isFinite(o)) && (o = 1), (!s || !Number.isFinite(s)) && (s = 1), {
|
|
2728
|
+
x: o,
|
|
2729
|
+
y: s
|
|
2730
|
+
};
|
|
2731
|
+
}
|
|
2732
|
+
var Li = /*#__PURE__*/ W(0);
|
|
2733
|
+
function Ri(e) {
|
|
2734
|
+
let t = J(e);
|
|
2735
|
+
return !Oi() || !t.visualViewport ? Li : {
|
|
2736
|
+
x: t.visualViewport.offsetLeft,
|
|
2737
|
+
y: t.visualViewport.offsetTop
|
|
2738
|
+
};
|
|
2739
|
+
}
|
|
2740
|
+
function zi(e, t, n) {
|
|
2741
|
+
return t === void 0 && (t = !1), !n || t && n !== J(e) ? !1 : t;
|
|
2742
|
+
}
|
|
2743
|
+
function Bi(e, t, n, r) {
|
|
2744
|
+
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
2745
|
+
let i = e.getBoundingClientRect(), a = Fi(e), o = W(1);
|
|
2746
|
+
t && (r ? X(r) && (o = Ii(r)) : o = Ii(e));
|
|
2747
|
+
let s = zi(a, n, r) ? Ri(a) : W(0), c = (i.left + s.x) / o.x, l = (i.top + s.y) / o.y, u = i.width / o.x, d = i.height / o.y;
|
|
2748
|
+
if (a) {
|
|
2749
|
+
let e = J(a), t = r && X(r) ? J(r) : r, n = e, i = Ni(n);
|
|
2750
|
+
for (; i && r && t !== n;) {
|
|
2751
|
+
let e = Ii(i), t = i.getBoundingClientRect(), r = Q(i), a = t.left + (i.clientLeft + parseFloat(r.paddingLeft)) * e.x, o = t.top + (i.clientTop + parseFloat(r.paddingTop)) * e.y;
|
|
2752
|
+
c *= e.x, l *= e.y, u *= e.x, d *= e.y, c += a, l += o, n = J(i), i = Ni(n);
|
|
2753
|
+
}
|
|
2754
|
+
}
|
|
2755
|
+
return $r({
|
|
2756
|
+
width: u,
|
|
2757
|
+
height: d,
|
|
2758
|
+
x: c,
|
|
2759
|
+
y: l
|
|
2760
|
+
});
|
|
2761
|
+
}
|
|
2762
|
+
function Vi(e, t) {
|
|
2763
|
+
let n = Ai(e).scrollLeft;
|
|
2764
|
+
return t ? t.left + n : Bi(Y(e)).left + n;
|
|
2765
|
+
}
|
|
2766
|
+
function Hi(e, t) {
|
|
2767
|
+
let n = e.getBoundingClientRect();
|
|
2768
|
+
return {
|
|
2769
|
+
x: n.left + t.scrollLeft - Vi(e, n),
|
|
2770
|
+
y: n.top + t.scrollTop
|
|
2771
|
+
};
|
|
2772
|
+
}
|
|
2773
|
+
function Ui(e) {
|
|
2774
|
+
let { elements: t, rect: n, offsetParent: r, strategy: i } = e, a = i === "fixed", o = Y(r), s = t ? xi(t.floating) : !1;
|
|
2775
|
+
if (r === o || s && a) return n;
|
|
2776
|
+
let c = {
|
|
2777
|
+
scrollLeft: 0,
|
|
2778
|
+
scrollTop: 0
|
|
2779
|
+
}, l = W(1), u = W(0), d = Z(r);
|
|
2780
|
+
if ((d || !d && !a) && ((gi(r) !== "body" || yi(o)) && (c = Ai(r)), d)) {
|
|
2781
|
+
let e = Bi(r);
|
|
2782
|
+
l = Ii(r), u.x = e.x + r.clientLeft, u.y = e.y + r.clientTop;
|
|
2783
|
+
}
|
|
2784
|
+
let f = o && !d && !a ? Hi(o, c) : W(0);
|
|
2785
|
+
return {
|
|
2786
|
+
width: n.width * l.x,
|
|
2787
|
+
height: n.height * l.y,
|
|
2788
|
+
x: n.x * l.x - c.scrollLeft * l.x + u.x + f.x,
|
|
2789
|
+
y: n.y * l.y - c.scrollTop * l.y + u.y + f.y
|
|
2790
|
+
};
|
|
2791
|
+
}
|
|
2792
|
+
function Wi(e) {
|
|
2793
|
+
return Array.from(e.getClientRects());
|
|
2794
|
+
}
|
|
2795
|
+
function Gi(e) {
|
|
2796
|
+
let t = Y(e), n = Ai(e), r = e.ownerDocument.body, i = U(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), a = U(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight), o = -n.scrollLeft + Vi(e), s = -n.scrollTop;
|
|
2797
|
+
return Q(r).direction === "rtl" && (o += U(t.clientWidth, r.clientWidth) - i), {
|
|
2798
|
+
width: i,
|
|
2799
|
+
height: a,
|
|
2800
|
+
x: o,
|
|
2801
|
+
y: s
|
|
2802
|
+
};
|
|
2803
|
+
}
|
|
2804
|
+
var Ki = 25;
|
|
2805
|
+
function qi(e, t) {
|
|
2806
|
+
let n = J(e), r = Y(e), i = n.visualViewport, a = r.clientWidth, o = r.clientHeight, s = 0, c = 0;
|
|
2807
|
+
if (i) {
|
|
2808
|
+
a = i.width, o = i.height;
|
|
2809
|
+
let e = Oi();
|
|
2810
|
+
(!e || e && t === "fixed") && (s = i.offsetLeft, c = i.offsetTop);
|
|
2811
|
+
}
|
|
2812
|
+
let l = Vi(r);
|
|
2813
|
+
if (l <= 0) {
|
|
2814
|
+
let e = r.ownerDocument, t = e.body, n = getComputedStyle(t), i = e.compatMode === "CSS1Compat" && parseFloat(n.marginLeft) + parseFloat(n.marginRight) || 0, o = Math.abs(r.clientWidth - t.clientWidth - i);
|
|
2815
|
+
o <= Ki && (a -= o);
|
|
2816
|
+
} else l <= Ki && (a += l);
|
|
2817
|
+
return {
|
|
2818
|
+
width: a,
|
|
2819
|
+
height: o,
|
|
2820
|
+
x: s,
|
|
2821
|
+
y: c
|
|
2822
|
+
};
|
|
2823
|
+
}
|
|
2824
|
+
function Ji(e, t) {
|
|
2825
|
+
let n = Bi(e, !0, t === "fixed"), r = n.top + e.clientTop, i = n.left + e.clientLeft, a = Z(e) ? Ii(e) : W(1);
|
|
2826
|
+
return {
|
|
2827
|
+
width: e.clientWidth * a.x,
|
|
2828
|
+
height: e.clientHeight * a.y,
|
|
2829
|
+
x: i * a.x,
|
|
2830
|
+
y: r * a.y
|
|
2831
|
+
};
|
|
2832
|
+
}
|
|
2833
|
+
function Yi(e, t, n) {
|
|
2834
|
+
let r;
|
|
2835
|
+
if (t === "viewport") r = qi(e, n);
|
|
2836
|
+
else if (t === "document") r = Gi(Y(e));
|
|
2837
|
+
else if (X(t)) r = Ji(t, n);
|
|
2838
|
+
else {
|
|
2839
|
+
let n = Ri(e);
|
|
2840
|
+
r = {
|
|
2841
|
+
x: t.x - n.x,
|
|
2842
|
+
y: t.y - n.y,
|
|
2843
|
+
width: t.width,
|
|
2844
|
+
height: t.height
|
|
2845
|
+
};
|
|
2846
|
+
}
|
|
2847
|
+
return $r(r);
|
|
2848
|
+
}
|
|
2849
|
+
function Xi(e, t) {
|
|
2850
|
+
let n = $(e);
|
|
2851
|
+
return n === t || !X(n) || ki(n) ? !1 : Q(n).position === "fixed" || Xi(n, t);
|
|
2852
|
+
}
|
|
2853
|
+
function Zi(e, t) {
|
|
2854
|
+
let n = t.get(e);
|
|
2855
|
+
if (n) return n;
|
|
2856
|
+
let r = Mi(e, [], !1).filter((e) => X(e) && gi(e) !== "body"), i = null, a = Q(e).position === "fixed", o = a ? $(e) : e;
|
|
2857
|
+
for (; X(o) && !ki(o);) {
|
|
2858
|
+
let t = Q(o), n = Ei(o);
|
|
2859
|
+
!n && t.position === "fixed" && (i = null), (a ? !n && !i : !n && t.position === "static" && i && (i.position === "absolute" || i.position === "fixed") || yi(o) && !n && Xi(e, o)) ? r = r.filter((e) => e !== o) : i = t, o = $(o);
|
|
2860
|
+
}
|
|
2861
|
+
return t.set(e, r), r;
|
|
2862
|
+
}
|
|
2863
|
+
function Qi(e) {
|
|
2864
|
+
let { element: t, boundary: n, rootBoundary: r, strategy: i } = e, a = [...n === "clippingAncestors" ? xi(t) ? [] : Zi(t, this._c) : [].concat(n), r], o = Yi(t, a[0], i), s = o.top, c = o.right, l = o.bottom, u = o.left;
|
|
2865
|
+
for (let e = 1; e < a.length; e++) {
|
|
2866
|
+
let n = Yi(t, a[e], i);
|
|
2867
|
+
s = U(n.top, s), c = H(n.right, c), l = H(n.bottom, l), u = U(n.left, u);
|
|
2868
|
+
}
|
|
2869
|
+
return {
|
|
2870
|
+
width: c - u,
|
|
2871
|
+
height: l - s,
|
|
2872
|
+
x: u,
|
|
2873
|
+
y: s
|
|
2874
|
+
};
|
|
2875
|
+
}
|
|
2876
|
+
function $i(e) {
|
|
2877
|
+
let { width: t, height: n } = Pi(e);
|
|
2878
|
+
return {
|
|
2879
|
+
width: t,
|
|
2880
|
+
height: n
|
|
2881
|
+
};
|
|
2882
|
+
}
|
|
2883
|
+
function ea(e, t, n) {
|
|
2884
|
+
let r = Z(t), i = Y(t), a = n === "fixed", o = Bi(e, !0, a, t), s = {
|
|
2885
|
+
scrollLeft: 0,
|
|
2886
|
+
scrollTop: 0
|
|
2887
|
+
}, c = W(0);
|
|
2888
|
+
function l() {
|
|
2889
|
+
c.x = Vi(i);
|
|
2890
|
+
}
|
|
2891
|
+
if (r || !r && !a) if ((gi(t) !== "body" || yi(i)) && (s = Ai(t)), r) {
|
|
2892
|
+
let e = Bi(t, !0, a, t);
|
|
2893
|
+
c.x = e.x + t.clientLeft, c.y = e.y + t.clientTop;
|
|
2894
|
+
} else i && l();
|
|
2895
|
+
a && !r && i && l();
|
|
2896
|
+
let u = i && !r && !a ? Hi(i, s) : W(0);
|
|
2897
|
+
return {
|
|
2898
|
+
x: o.left + s.scrollLeft - c.x - u.x,
|
|
2899
|
+
y: o.top + s.scrollTop - c.y - u.y,
|
|
2900
|
+
width: o.width,
|
|
2901
|
+
height: o.height
|
|
2902
|
+
};
|
|
2903
|
+
}
|
|
2904
|
+
function ta(e) {
|
|
2905
|
+
return Q(e).position === "static";
|
|
2906
|
+
}
|
|
2907
|
+
function na(e, t) {
|
|
2908
|
+
if (!Z(e) || Q(e).position === "fixed") return null;
|
|
2909
|
+
if (t) return t(e);
|
|
2910
|
+
let n = e.offsetParent;
|
|
2911
|
+
return Y(e) === n && (n = n.ownerDocument.body), n;
|
|
2912
|
+
}
|
|
2913
|
+
function ra(e, t) {
|
|
2914
|
+
let n = J(e);
|
|
2915
|
+
if (xi(e)) return n;
|
|
2916
|
+
if (!Z(e)) {
|
|
2917
|
+
let t = $(e);
|
|
2918
|
+
for (; t && !ki(t);) {
|
|
2919
|
+
if (X(t) && !ta(t)) return t;
|
|
2920
|
+
t = $(t);
|
|
2921
|
+
}
|
|
2922
|
+
return n;
|
|
2923
|
+
}
|
|
2924
|
+
let r = na(e, t);
|
|
2925
|
+
for (; r && bi(r) && ta(r);) r = na(r, t);
|
|
2926
|
+
return r && ki(r) && ta(r) && !Ei(r) ? n : r || Di(e) || n;
|
|
2927
|
+
}
|
|
2928
|
+
var ia = async function(e) {
|
|
2929
|
+
let t = this.getOffsetParent || ra, n = this.getDimensions, r = await n(e.floating);
|
|
2930
|
+
return {
|
|
2931
|
+
reference: ea(e.reference, await t(e.floating), e.strategy),
|
|
2932
|
+
floating: {
|
|
2933
|
+
x: 0,
|
|
2934
|
+
y: 0,
|
|
2935
|
+
width: r.width,
|
|
2936
|
+
height: r.height
|
|
2937
|
+
}
|
|
2938
|
+
};
|
|
2939
|
+
};
|
|
2940
|
+
function aa(e) {
|
|
2941
|
+
return Q(e).direction === "rtl";
|
|
2942
|
+
}
|
|
2943
|
+
var oa = {
|
|
2944
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: Ui,
|
|
2945
|
+
getDocumentElement: Y,
|
|
2946
|
+
getClippingRect: Qi,
|
|
2947
|
+
getOffsetParent: ra,
|
|
2948
|
+
getElementRects: ia,
|
|
2949
|
+
getClientRects: Wi,
|
|
2950
|
+
getDimensions: $i,
|
|
2951
|
+
getScale: Ii,
|
|
2952
|
+
isElement: X,
|
|
2953
|
+
isRTL: aa
|
|
2954
|
+
};
|
|
2955
|
+
function sa(e, t) {
|
|
2956
|
+
return e.x === t.x && e.y === t.y && e.width === t.width && e.height === t.height;
|
|
2957
|
+
}
|
|
2958
|
+
function ca(e, t) {
|
|
2959
|
+
let n = null, r, i = Y(e);
|
|
2960
|
+
function a() {
|
|
2961
|
+
var e;
|
|
2962
|
+
clearTimeout(r), (e = n) == null || e.disconnect(), n = null;
|
|
2963
|
+
}
|
|
2964
|
+
function o(s, c) {
|
|
2965
|
+
s === void 0 && (s = !1), c === void 0 && (c = 1), a();
|
|
2966
|
+
let l = e.getBoundingClientRect(), { left: u, top: d, width: f, height: p } = l;
|
|
2967
|
+
if (s || t(), !f || !p) return;
|
|
2968
|
+
let m = Pr(d), h = Pr(i.clientWidth - (u + f)), g = Pr(i.clientHeight - (d + p)), _ = Pr(u), v = {
|
|
2969
|
+
rootMargin: -m + "px " + -h + "px " + -g + "px " + -_ + "px",
|
|
2970
|
+
threshold: U(0, H(1, c)) || 1
|
|
2971
|
+
}, y = !0;
|
|
2972
|
+
function b(t) {
|
|
2973
|
+
let n = t[0].intersectionRatio;
|
|
2974
|
+
if (n !== c) {
|
|
2975
|
+
if (!y) return o();
|
|
2976
|
+
n ? o(!1, n) : r = setTimeout(() => {
|
|
2977
|
+
o(!1, 1e-7);
|
|
2978
|
+
}, 1e3);
|
|
2979
|
+
}
|
|
2980
|
+
n === 1 && !sa(l, e.getBoundingClientRect()) && o(), y = !1;
|
|
2981
|
+
}
|
|
2982
|
+
try {
|
|
2983
|
+
n = new IntersectionObserver(b, {
|
|
2984
|
+
...v,
|
|
2985
|
+
root: i.ownerDocument
|
|
2986
|
+
});
|
|
2987
|
+
} catch {
|
|
2988
|
+
n = new IntersectionObserver(b, v);
|
|
2989
|
+
}
|
|
2990
|
+
n.observe(e);
|
|
2991
|
+
}
|
|
2992
|
+
return o(!0), a;
|
|
2993
|
+
}
|
|
2994
|
+
function la(e, t, n, r) {
|
|
2995
|
+
r === void 0 && (r = {});
|
|
2996
|
+
let { ancestorScroll: i = !0, ancestorResize: a = !0, elementResize: o = typeof ResizeObserver == "function", layoutShift: s = typeof IntersectionObserver == "function", animationFrame: c = !1 } = r, l = Fi(e), u = i || a ? [...l ? Mi(l) : [], ...t ? Mi(t) : []] : [];
|
|
2997
|
+
u.forEach((e) => {
|
|
2998
|
+
i && e.addEventListener("scroll", n, { passive: !0 }), a && e.addEventListener("resize", n);
|
|
2999
|
+
});
|
|
3000
|
+
let d = l && s ? ca(l, n) : null, f = -1, p = null;
|
|
3001
|
+
o && (p = new ResizeObserver((e) => {
|
|
3002
|
+
let [r] = e;
|
|
3003
|
+
r && r.target === l && p && t && (p.unobserve(t), cancelAnimationFrame(f), f = requestAnimationFrame(() => {
|
|
3004
|
+
var e;
|
|
3005
|
+
(e = p) == null || e.observe(t);
|
|
3006
|
+
})), n();
|
|
3007
|
+
}), l && !c && p.observe(l), t && p.observe(t));
|
|
3008
|
+
let m, h = c ? Bi(e) : null;
|
|
3009
|
+
c && g();
|
|
3010
|
+
function g() {
|
|
3011
|
+
let t = Bi(e);
|
|
3012
|
+
h && !sa(h, t) && n(), h = t, m = requestAnimationFrame(g);
|
|
3013
|
+
}
|
|
3014
|
+
return n(), () => {
|
|
3015
|
+
var e;
|
|
3016
|
+
u.forEach((e) => {
|
|
3017
|
+
i && e.removeEventListener("scroll", n), a && e.removeEventListener("resize", n);
|
|
3018
|
+
}), d?.(), (e = p) == null || e.disconnect(), p = null, c && cancelAnimationFrame(m);
|
|
3019
|
+
};
|
|
3020
|
+
}
|
|
3021
|
+
var ua = di, da = fi, fa = ai, pa = mi, ma = ci, ha = ii, ga = pi, _a = (e, t, n) => {
|
|
3022
|
+
let r = /* @__PURE__ */ new Map(), i = {
|
|
3023
|
+
platform: oa,
|
|
3024
|
+
...n
|
|
3025
|
+
}, a = {
|
|
3026
|
+
...i.platform,
|
|
3027
|
+
_c: r
|
|
3028
|
+
};
|
|
3029
|
+
return ri(e, t, {
|
|
3030
|
+
...i,
|
|
3031
|
+
platform: a
|
|
3032
|
+
});
|
|
3033
|
+
};
|
|
3034
|
+
//#endregion
|
|
3035
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/use-id.js
|
|
3036
|
+
globalThis.bitsIdCounter ??= { current: 0 };
|
|
3037
|
+
function va(e = "bits") {
|
|
3038
|
+
return globalThis.bitsIdCounter.current++, `${e}-${globalThis.bitsIdCounter.current}`;
|
|
3039
|
+
}
|
|
3040
|
+
//#endregion
|
|
3041
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/floating-svelte/floating-utils.svelte.js
|
|
3042
|
+
function ya(e) {
|
|
3043
|
+
return typeof e == "function" ? e() : e;
|
|
3044
|
+
}
|
|
3045
|
+
function ba(e) {
|
|
3046
|
+
return typeof window > "u" ? 1 : (e.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
3047
|
+
}
|
|
3048
|
+
function xa(e, t) {
|
|
3049
|
+
let n = ba(e);
|
|
3050
|
+
return Math.round(t * n) / n;
|
|
3051
|
+
}
|
|
3052
|
+
function Sa(e) {
|
|
3053
|
+
return {
|
|
3054
|
+
[`--bits-${e}-content-transform-origin`]: "var(--bits-floating-transform-origin)",
|
|
3055
|
+
[`--bits-${e}-content-available-width`]: "var(--bits-floating-available-width)",
|
|
3056
|
+
[`--bits-${e}-content-available-height`]: "var(--bits-floating-available-height)",
|
|
3057
|
+
[`--bits-${e}-anchor-width`]: "var(--bits-floating-anchor-width)",
|
|
3058
|
+
[`--bits-${e}-anchor-height`]: "var(--bits-floating-anchor-height)"
|
|
3059
|
+
};
|
|
3060
|
+
}
|
|
3061
|
+
//#endregion
|
|
3062
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/floating-svelte/use-floating.svelte.js
|
|
3063
|
+
function Ca(e) {
|
|
3064
|
+
let t = e.whileElementsMounted, n = u(() => ya(e.open) ?? !0), r = u(() => ya(e.middleware)), i = u(() => ya(e.transform) ?? !0), a = u(() => ya(e.placement) ?? "bottom"), o = u(() => ya(e.strategy) ?? "absolute"), s = u(() => ya(e.sideOffset) ?? 0), d = u(() => ya(e.alignOffset) ?? 0), f = e.reference, p = l(0), m = l(0), h = N(null), g = l(x(c(o))), _ = l(x(c(a))), y = l(x({})), S = l(!1), C = !1, w = 0, T = u(() => {
|
|
3065
|
+
let e = h.current ? xa(h.current, c(p)) : c(p), t = h.current ? xa(h.current, c(m)) : c(m);
|
|
3066
|
+
return c(i) ? {
|
|
3067
|
+
position: c(g),
|
|
3068
|
+
left: "0",
|
|
3069
|
+
top: "0",
|
|
3070
|
+
transform: `translate(${e}px, ${t}px)`,
|
|
3071
|
+
...h.current && ba(h.current) >= 1.5 && { willChange: "transform" }
|
|
3072
|
+
} : {
|
|
3073
|
+
position: c(g),
|
|
3074
|
+
left: `${e}px`,
|
|
3075
|
+
top: `${t}px`
|
|
3076
|
+
};
|
|
3077
|
+
}), E;
|
|
3078
|
+
function D() {
|
|
3079
|
+
if (f.current === null || h.current === null) return;
|
|
3080
|
+
let e = f.current, t = h.current, i = ++w;
|
|
3081
|
+
_a(e, t, {
|
|
3082
|
+
middleware: c(r),
|
|
3083
|
+
placement: c(a),
|
|
3084
|
+
strategy: c(o)
|
|
3085
|
+
}).then((r) => {
|
|
3086
|
+
if (i === w && !(f.current !== e || h.current !== t)) {
|
|
3087
|
+
if (wa(e)) {
|
|
3088
|
+
b(y, {
|
|
3089
|
+
...c(y),
|
|
3090
|
+
hide: {
|
|
3091
|
+
...c(y).hide,
|
|
3092
|
+
referenceHidden: !0
|
|
3093
|
+
}
|
|
3094
|
+
}, !0);
|
|
3095
|
+
return;
|
|
3096
|
+
}
|
|
3097
|
+
if (!c(n) && c(p) !== 0 && c(m) !== 0) {
|
|
3098
|
+
let e = Math.max(Math.abs(c(s)), Math.abs(c(d)), 15);
|
|
3099
|
+
if (r.x <= e && r.y <= e) return;
|
|
3100
|
+
}
|
|
3101
|
+
b(p, r.x, !0), b(m, r.y, !0), b(g, r.strategy, !0), b(_, r.placement, !0), b(y, r.middlewareData, !0), b(S, !0);
|
|
3102
|
+
}
|
|
3103
|
+
});
|
|
3104
|
+
}
|
|
3105
|
+
function O() {
|
|
3106
|
+
typeof E == "function" && (E(), E = void 0), w++;
|
|
3107
|
+
}
|
|
3108
|
+
function ee() {
|
|
3109
|
+
if (O(), t === void 0) {
|
|
3110
|
+
D();
|
|
3111
|
+
return;
|
|
3112
|
+
}
|
|
3113
|
+
c(n) && (f.current === null || h.current === null || (E = t(f.current, h.current, D)));
|
|
3114
|
+
}
|
|
3115
|
+
function k() {
|
|
3116
|
+
!c(n) && h.current === null && b(S, !1);
|
|
3117
|
+
}
|
|
3118
|
+
function A() {
|
|
3119
|
+
return [
|
|
3120
|
+
c(r),
|
|
3121
|
+
c(a),
|
|
3122
|
+
c(o),
|
|
3123
|
+
c(s),
|
|
3124
|
+
c(d),
|
|
3125
|
+
c(n)
|
|
3126
|
+
];
|
|
3127
|
+
}
|
|
3128
|
+
return v(() => {
|
|
3129
|
+
t === void 0 && c(n) && D();
|
|
3130
|
+
}), v(ee), v(() => {
|
|
3131
|
+
if (t !== void 0) {
|
|
3132
|
+
if (A(), !c(n)) {
|
|
3133
|
+
C = !1;
|
|
3134
|
+
return;
|
|
3135
|
+
}
|
|
3136
|
+
if (!c(S)) {
|
|
3137
|
+
C = !1;
|
|
3138
|
+
return;
|
|
3139
|
+
}
|
|
3140
|
+
if (!C) {
|
|
3141
|
+
C = !0;
|
|
3142
|
+
return;
|
|
3143
|
+
}
|
|
3144
|
+
D();
|
|
3145
|
+
}
|
|
3146
|
+
}), v(k), v(() => O), {
|
|
3147
|
+
floating: h,
|
|
3148
|
+
reference: f,
|
|
3149
|
+
get strategy() {
|
|
3150
|
+
return c(g);
|
|
3151
|
+
},
|
|
3152
|
+
get placement() {
|
|
3153
|
+
return c(_);
|
|
3154
|
+
},
|
|
3155
|
+
get middlewareData() {
|
|
3156
|
+
return c(y);
|
|
3157
|
+
},
|
|
3158
|
+
get isPositioned() {
|
|
3159
|
+
return c(S);
|
|
3160
|
+
},
|
|
3161
|
+
get floatingStyles() {
|
|
3162
|
+
return c(T);
|
|
3163
|
+
},
|
|
3164
|
+
get update() {
|
|
3165
|
+
return D;
|
|
3166
|
+
}
|
|
3167
|
+
};
|
|
3168
|
+
}
|
|
3169
|
+
function wa(e) {
|
|
3170
|
+
return e instanceof Element ? !e.isConnected || e instanceof HTMLElement && e.hidden ? !0 : e.getClientRects().length === 0 : !1;
|
|
3171
|
+
}
|
|
3172
|
+
//#endregion
|
|
3173
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/floating-layer/use-floating-layer.svelte.js
|
|
3174
|
+
var Ta = {
|
|
3175
|
+
top: "bottom",
|
|
3176
|
+
right: "left",
|
|
3177
|
+
bottom: "top",
|
|
3178
|
+
left: "right"
|
|
3179
|
+
}, Ea = new L("Floating.Root"), Da = new L("Floating.Content"), Oa = new L("Floating.Root"), ka = class e {
|
|
3180
|
+
static create(t = !1) {
|
|
3181
|
+
return t ? Oa.set(new e()) : Ea.set(new e());
|
|
3182
|
+
}
|
|
3183
|
+
anchorNode = N(null);
|
|
3184
|
+
customAnchorNode = N(null);
|
|
3185
|
+
triggerNode = N(null);
|
|
3186
|
+
constructor() {
|
|
3187
|
+
v(() => {
|
|
3188
|
+
this.customAnchorNode.current ? typeof this.customAnchorNode.current == "string" ? this.anchorNode.current = document.querySelector(this.customAnchorNode.current) : this.anchorNode.current = this.customAnchorNode.current : this.anchorNode.current = this.triggerNode.current;
|
|
3189
|
+
});
|
|
3190
|
+
}
|
|
3191
|
+
}, Aa = class e {
|
|
3192
|
+
static create(t, n = !1) {
|
|
3193
|
+
return n ? Da.set(new e(t, Oa.get())) : Da.set(new e(t, Ea.get()));
|
|
3194
|
+
}
|
|
3195
|
+
opts;
|
|
3196
|
+
root;
|
|
3197
|
+
contentRef = N(null);
|
|
3198
|
+
wrapperRef = N(null);
|
|
3199
|
+
arrowRef = N(null);
|
|
3200
|
+
contentAttachment = I(this.contentRef);
|
|
3201
|
+
wrapperAttachment = I(this.wrapperRef);
|
|
3202
|
+
arrowAttachment = I(this.arrowRef);
|
|
3203
|
+
arrowId = N(va());
|
|
3204
|
+
#e = u(() => {
|
|
3205
|
+
if (typeof this.opts.style == "string") return Re(this.opts.style);
|
|
3206
|
+
if (!this.opts.style) return {};
|
|
3207
|
+
});
|
|
3208
|
+
#t = void 0;
|
|
3209
|
+
#n = new _t(() => this.arrowRef.current ?? void 0);
|
|
3210
|
+
#r = u(() => this.#n?.width ?? 0);
|
|
3211
|
+
#i = u(() => this.#n?.height ?? 0);
|
|
3212
|
+
#a = u(() => this.opts.side?.current + (this.opts.align.current === "center" ? "" : `-${this.opts.align.current}`));
|
|
3213
|
+
#o = u(() => Array.isArray(this.opts.collisionBoundary.current) ? this.opts.collisionBoundary.current : [this.opts.collisionBoundary.current]);
|
|
3214
|
+
#s = u(() => c(this.#o).length > 0);
|
|
3215
|
+
get hasExplicitBoundaries() {
|
|
3216
|
+
return c(this.#s);
|
|
3217
|
+
}
|
|
3218
|
+
set hasExplicitBoundaries(e) {
|
|
3219
|
+
b(this.#s, e);
|
|
3220
|
+
}
|
|
3221
|
+
#c = u(() => ({
|
|
3222
|
+
padding: this.opts.collisionPadding.current,
|
|
3223
|
+
boundary: c(this.#o).filter(Kt),
|
|
3224
|
+
altBoundary: this.hasExplicitBoundaries
|
|
3225
|
+
}));
|
|
3226
|
+
get detectOverflowOptions() {
|
|
3227
|
+
return c(this.#c);
|
|
3228
|
+
}
|
|
3229
|
+
set detectOverflowOptions(e) {
|
|
3230
|
+
b(this.#c, e);
|
|
3231
|
+
}
|
|
3232
|
+
#l = l(void 0);
|
|
3233
|
+
#u = l(void 0);
|
|
3234
|
+
#d = l(void 0);
|
|
3235
|
+
#f = l(void 0);
|
|
3236
|
+
#p = u(() => [
|
|
3237
|
+
ua({
|
|
3238
|
+
mainAxis: this.opts.sideOffset.current + c(this.#i),
|
|
3239
|
+
alignmentAxis: this.opts.alignOffset.current
|
|
3240
|
+
}),
|
|
3241
|
+
this.opts.avoidCollisions.current && da({
|
|
3242
|
+
mainAxis: !0,
|
|
3243
|
+
crossAxis: !1,
|
|
3244
|
+
limiter: this.opts.sticky.current === "partial" ? ga() : void 0,
|
|
3245
|
+
...this.detectOverflowOptions
|
|
3246
|
+
}),
|
|
3247
|
+
this.opts.avoidCollisions.current && fa({ ...this.detectOverflowOptions }),
|
|
3248
|
+
pa({
|
|
3249
|
+
...this.detectOverflowOptions,
|
|
3250
|
+
apply: ({ rects: e, availableWidth: t, availableHeight: n }) => {
|
|
3251
|
+
let { width: r, height: i } = e.reference;
|
|
3252
|
+
b(this.#l, t, !0), b(this.#u, n, !0), b(this.#d, r, !0), b(this.#f, i, !0);
|
|
3253
|
+
}
|
|
3254
|
+
}),
|
|
3255
|
+
this.arrowRef.current && ha({
|
|
3256
|
+
element: this.arrowRef.current,
|
|
3257
|
+
padding: this.opts.arrowPadding.current
|
|
3258
|
+
}),
|
|
3259
|
+
Ma({
|
|
3260
|
+
arrowWidth: c(this.#r),
|
|
3261
|
+
arrowHeight: c(this.#i)
|
|
3262
|
+
}),
|
|
3263
|
+
this.opts.hideWhenDetached.current && ma({
|
|
3264
|
+
strategy: "referenceHidden",
|
|
3265
|
+
...this.detectOverflowOptions
|
|
3266
|
+
})
|
|
3267
|
+
].filter(Boolean));
|
|
3268
|
+
get middleware() {
|
|
3269
|
+
return c(this.#p);
|
|
3270
|
+
}
|
|
3271
|
+
set middleware(e) {
|
|
3272
|
+
b(this.#p, e);
|
|
3273
|
+
}
|
|
3274
|
+
floating;
|
|
3275
|
+
#m = u(() => Pa(this.floating.placement));
|
|
3276
|
+
get placedSide() {
|
|
3277
|
+
return c(this.#m);
|
|
3278
|
+
}
|
|
3279
|
+
set placedSide(e) {
|
|
3280
|
+
b(this.#m, e);
|
|
3281
|
+
}
|
|
3282
|
+
#h = u(() => Fa(this.floating.placement));
|
|
3283
|
+
get placedAlign() {
|
|
3284
|
+
return c(this.#h);
|
|
3285
|
+
}
|
|
3286
|
+
set placedAlign(e) {
|
|
3287
|
+
b(this.#h, e);
|
|
3288
|
+
}
|
|
3289
|
+
#g = u(() => this.floating.middlewareData.arrow?.x ?? 0);
|
|
3290
|
+
get arrowX() {
|
|
3291
|
+
return c(this.#g);
|
|
3292
|
+
}
|
|
3293
|
+
set arrowX(e) {
|
|
3294
|
+
b(this.#g, e);
|
|
3295
|
+
}
|
|
3296
|
+
#_ = u(() => this.floating.middlewareData.arrow?.y ?? 0);
|
|
3297
|
+
get arrowY() {
|
|
3298
|
+
return c(this.#_);
|
|
3299
|
+
}
|
|
3300
|
+
set arrowY(e) {
|
|
3301
|
+
b(this.#_, e);
|
|
3302
|
+
}
|
|
3303
|
+
#v = u(() => this.floating.middlewareData.arrow?.centerOffset !== 0);
|
|
3304
|
+
get cannotCenterArrow() {
|
|
3305
|
+
return c(this.#v);
|
|
3306
|
+
}
|
|
3307
|
+
set cannotCenterArrow(e) {
|
|
3308
|
+
b(this.#v, e);
|
|
3309
|
+
}
|
|
3310
|
+
#y = l();
|
|
3311
|
+
get contentZIndex() {
|
|
3312
|
+
return c(this.#y);
|
|
3313
|
+
}
|
|
3314
|
+
set contentZIndex(e) {
|
|
3315
|
+
b(this.#y, e, !0);
|
|
3316
|
+
}
|
|
3317
|
+
#b = u(() => Ta[this.placedSide]);
|
|
3318
|
+
get arrowBaseSide() {
|
|
3319
|
+
return c(this.#b);
|
|
3320
|
+
}
|
|
3321
|
+
set arrowBaseSide(e) {
|
|
3322
|
+
b(this.#b, e);
|
|
3323
|
+
}
|
|
3324
|
+
#x = u(() => ({
|
|
3325
|
+
id: this.opts.wrapperId.current,
|
|
3326
|
+
"data-bits-floating-content-wrapper": "",
|
|
3327
|
+
style: {
|
|
3328
|
+
...this.floating.floatingStyles,
|
|
3329
|
+
transform: this.floating.isPositioned ? this.floating.floatingStyles.transform : "translate(0, -200%)",
|
|
3330
|
+
minWidth: "max-content",
|
|
3331
|
+
zIndex: this.contentZIndex,
|
|
3332
|
+
"--bits-floating-transform-origin": `${this.floating.middlewareData.transformOrigin?.x} ${this.floating.middlewareData.transformOrigin?.y}`,
|
|
3333
|
+
"--bits-floating-available-width": `${c(this.#l)}px`,
|
|
3334
|
+
"--bits-floating-available-height": `${c(this.#u)}px`,
|
|
3335
|
+
"--bits-floating-anchor-width": `${c(this.#d)}px`,
|
|
3336
|
+
"--bits-floating-anchor-height": `${c(this.#f)}px`,
|
|
3337
|
+
...this.floating.middlewareData.hide?.referenceHidden && {
|
|
3338
|
+
visibility: "hidden",
|
|
3339
|
+
"pointer-events": "none"
|
|
3340
|
+
},
|
|
3341
|
+
...c(this.#e)
|
|
3342
|
+
},
|
|
3343
|
+
dir: this.opts.dir.current,
|
|
3344
|
+
...this.wrapperAttachment
|
|
3345
|
+
}));
|
|
3346
|
+
get wrapperProps() {
|
|
3347
|
+
return c(this.#x);
|
|
3348
|
+
}
|
|
3349
|
+
set wrapperProps(e) {
|
|
3350
|
+
b(this.#x, e);
|
|
3351
|
+
}
|
|
3352
|
+
#S = u(() => ({
|
|
3353
|
+
"data-side": this.placedSide,
|
|
3354
|
+
"data-align": this.placedAlign,
|
|
3355
|
+
style: Ue({ ...c(this.#e) }),
|
|
3356
|
+
...this.contentAttachment
|
|
3357
|
+
}));
|
|
3358
|
+
get props() {
|
|
3359
|
+
return c(this.#S);
|
|
3360
|
+
}
|
|
3361
|
+
set props(e) {
|
|
3362
|
+
b(this.#S, e);
|
|
3363
|
+
}
|
|
3364
|
+
#C = u(() => ({
|
|
3365
|
+
position: "absolute",
|
|
3366
|
+
left: this.arrowX ? `${this.arrowX}px` : void 0,
|
|
3367
|
+
top: this.arrowY ? `${this.arrowY}px` : void 0,
|
|
3368
|
+
[this.arrowBaseSide]: 0,
|
|
3369
|
+
"transform-origin": {
|
|
3370
|
+
top: "",
|
|
3371
|
+
right: "0 0",
|
|
3372
|
+
bottom: "center 0",
|
|
3373
|
+
left: "100% 0"
|
|
3374
|
+
}[this.placedSide],
|
|
3375
|
+
transform: {
|
|
3376
|
+
top: "translateY(100%)",
|
|
3377
|
+
right: "translateY(50%) rotate(90deg) translateX(-50%)",
|
|
3378
|
+
bottom: "rotate(180deg)",
|
|
3379
|
+
left: "translateY(50%) rotate(-90deg) translateX(50%)"
|
|
3380
|
+
}[this.placedSide],
|
|
3381
|
+
visibility: this.cannotCenterArrow ? "hidden" : void 0
|
|
3382
|
+
}));
|
|
3383
|
+
get arrowStyle() {
|
|
3384
|
+
return c(this.#C);
|
|
3385
|
+
}
|
|
3386
|
+
set arrowStyle(e) {
|
|
3387
|
+
b(this.#C, e);
|
|
3388
|
+
}
|
|
3389
|
+
constructor(e, t) {
|
|
3390
|
+
this.opts = e, this.root = t, this.#t = e.updatePositionStrategy, e.customAnchor && (this.root.customAnchorNode.current = e.customAnchor.current), R(() => e.customAnchor.current, (e) => {
|
|
3391
|
+
this.root.customAnchorNode.current = e;
|
|
3392
|
+
}), this.floating = Ca({
|
|
3393
|
+
strategy: () => this.opts.strategy.current,
|
|
3394
|
+
placement: () => c(this.#a),
|
|
3395
|
+
middleware: () => this.middleware,
|
|
3396
|
+
reference: this.root.anchorNode,
|
|
3397
|
+
whileElementsMounted: (...e) => la(...e, { animationFrame: this.#t?.current === "always" }),
|
|
3398
|
+
open: () => this.opts.enabled.current,
|
|
3399
|
+
sideOffset: () => this.opts.sideOffset.current,
|
|
3400
|
+
alignOffset: () => this.opts.alignOffset.current
|
|
3401
|
+
}), v(() => {
|
|
3402
|
+
this.floating.isPositioned && this.opts.onPlaced?.current();
|
|
3403
|
+
}), R(() => this.contentRef.current, (e) => {
|
|
3404
|
+
if (!e || !this.opts.enabled.current) return;
|
|
3405
|
+
let t = it(e), n = t.requestAnimationFrame(() => {
|
|
3406
|
+
if (this.contentRef.current !== e || !this.opts.enabled.current) return;
|
|
3407
|
+
let n = t.getComputedStyle(e).zIndex;
|
|
3408
|
+
n !== this.contentZIndex && (this.contentZIndex = n);
|
|
3409
|
+
});
|
|
3410
|
+
return () => {
|
|
3411
|
+
t.cancelAnimationFrame(n);
|
|
3412
|
+
};
|
|
3413
|
+
}), v(() => {
|
|
3414
|
+
this.floating.floating.current = this.wrapperRef.current;
|
|
3415
|
+
});
|
|
3416
|
+
}
|
|
3417
|
+
}, ja = class e {
|
|
3418
|
+
static create(t, n = !1) {
|
|
3419
|
+
return n ? new e(t, Oa.get()) : new e(t, Ea.get());
|
|
3420
|
+
}
|
|
3421
|
+
opts;
|
|
3422
|
+
root;
|
|
3423
|
+
constructor(e, t) {
|
|
3424
|
+
this.opts = e, this.root = t, e.virtualEl && e.virtualEl.current ? t.triggerNode = ce(e.virtualEl.current) : t.triggerNode = e.ref;
|
|
3425
|
+
}
|
|
3426
|
+
};
|
|
3427
|
+
function Ma(e) {
|
|
3428
|
+
return {
|
|
3429
|
+
name: "transformOrigin",
|
|
3430
|
+
options: e,
|
|
3431
|
+
fn(t) {
|
|
3432
|
+
let { placement: n, rects: r, middlewareData: i } = t, a = i.arrow?.centerOffset !== 0, o = a ? 0 : e.arrowWidth, s = a ? 0 : e.arrowHeight, [c, l] = Na(n), u = {
|
|
3433
|
+
start: "0%",
|
|
3434
|
+
center: "50%",
|
|
3435
|
+
end: "100%"
|
|
3436
|
+
}[l], d = (i.arrow?.x ?? 0) + o / 2, f = (i.arrow?.y ?? 0) + s / 2, p = "", m = "";
|
|
3437
|
+
return c === "bottom" ? (p = a ? u : `${d}px`, m = `${-s}px`) : c === "top" ? (p = a ? u : `${d}px`, m = `${r.floating.height + s}px`) : c === "right" ? (p = `${-s}px`, m = a ? u : `${f}px`) : c === "left" && (p = `${r.floating.width + s}px`, m = a ? u : `${f}px`), { data: {
|
|
3438
|
+
x: p,
|
|
3439
|
+
y: m
|
|
3440
|
+
} };
|
|
3441
|
+
}
|
|
3442
|
+
};
|
|
3443
|
+
}
|
|
3444
|
+
function Na(e) {
|
|
3445
|
+
let [t, n = "center"] = e.split("-");
|
|
3446
|
+
return [t, n];
|
|
3447
|
+
}
|
|
3448
|
+
function Pa(e) {
|
|
3449
|
+
return Na(e)[0];
|
|
3450
|
+
}
|
|
3451
|
+
function Fa(e) {
|
|
3452
|
+
return Na(e)[1];
|
|
3453
|
+
}
|
|
3454
|
+
//#endregion
|
|
3455
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/floating-layer/components/floating-layer.svelte
|
|
3456
|
+
function Ia(n, r) {
|
|
3457
|
+
p(r, !0);
|
|
3458
|
+
let i = _(r, "tooltip", 3, !1);
|
|
3459
|
+
ka.create(i());
|
|
3460
|
+
var a = h();
|
|
3461
|
+
s(e(a), () => r.children ?? S), t(n, a), d();
|
|
3462
|
+
}
|
|
3463
|
+
//#endregion
|
|
3464
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/create-id.js
|
|
3465
|
+
function La(e, t) {
|
|
3466
|
+
return t === void 0 ? `bits-${e}` : `bits-${e}-${t}`;
|
|
3467
|
+
}
|
|
3468
|
+
//#endregion
|
|
3469
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/shared-state.svelte.js
|
|
3470
|
+
var Ra = class {
|
|
3471
|
+
#e;
|
|
3472
|
+
#t = 0;
|
|
3473
|
+
#n = l();
|
|
3474
|
+
#r;
|
|
3475
|
+
constructor(e) {
|
|
3476
|
+
this.#e = e;
|
|
3477
|
+
}
|
|
3478
|
+
#i() {
|
|
3479
|
+
--this.#t, this.#r && this.#t <= 0 && (this.#r(), b(this.#n, void 0), this.#r = void 0);
|
|
3480
|
+
}
|
|
3481
|
+
get(...e) {
|
|
3482
|
+
return this.#t += 1, c(this.#n) === void 0 && (this.#r = i(() => {
|
|
3483
|
+
b(this.#n, this.#e(...e), !0);
|
|
3484
|
+
})), v(() => () => {
|
|
3485
|
+
this.#i();
|
|
3486
|
+
}), c(this.#n);
|
|
3487
|
+
}
|
|
3488
|
+
}, za = new T(), Ba = l(null), Va = null, Ha = null, Ua = !1, Wa = M(() => {
|
|
3489
|
+
for (let e of za.values()) if (e) return !0;
|
|
3490
|
+
return !1;
|
|
3491
|
+
}), Ga = null, Ka = new Ra(() => {
|
|
3492
|
+
function e() {
|
|
3493
|
+
document.body.setAttribute("style", c(Ba) ?? ""), document.body.style.removeProperty("--scrollbar-width"), Ht && Va?.(), b(Ba, null);
|
|
3494
|
+
}
|
|
3495
|
+
function t() {
|
|
3496
|
+
Ha !== null && (window.clearTimeout(Ha), Ha = null);
|
|
3497
|
+
}
|
|
3498
|
+
function n(e, n) {
|
|
3499
|
+
t(), Ua = !0, Ga = Date.now();
|
|
3500
|
+
let r = Ga, i = () => {
|
|
3501
|
+
Ha = null, Ga === r && (Ja(za) ? Ua = !1 : (Ua = !1, n()));
|
|
3502
|
+
}, a = e === null ? 24 : e;
|
|
3503
|
+
Ha = window.setTimeout(i, a);
|
|
3504
|
+
}
|
|
3505
|
+
function r() {
|
|
3506
|
+
c(Ba) === null && za.size === 0 && !Ua && b(Ba, document.body.getAttribute("style"), !0);
|
|
3507
|
+
}
|
|
3508
|
+
return R(() => Wa.current, () => {
|
|
3509
|
+
if (!Wa.current) return;
|
|
3510
|
+
r(), Ua = !1;
|
|
3511
|
+
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 = {
|
|
3512
|
+
padding: Number.parseInt(t.paddingRight ?? "0", 10) + i,
|
|
3513
|
+
margin: Number.parseInt(t.marginRight ?? "0", 10)
|
|
3514
|
+
};
|
|
3515
|
+
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", Ht && (Va = C(document, "touchmove", (e) => {
|
|
3516
|
+
e.target === document.documentElement && (e.touches.length > 1 || e.preventDefault());
|
|
3517
|
+
}, { passive: !1 })), F(() => {
|
|
3518
|
+
document.body.style.pointerEvents = "none", document.body.style.overflow = "hidden";
|
|
3519
|
+
});
|
|
3520
|
+
}), P(() => () => {
|
|
3521
|
+
Va?.();
|
|
3522
|
+
}), {
|
|
3523
|
+
get lockMap() {
|
|
3524
|
+
return za;
|
|
3525
|
+
},
|
|
3526
|
+
resetBodyStyle: e,
|
|
3527
|
+
scheduleCleanupIfNoNewLocks: n,
|
|
3528
|
+
cancelPendingCleanup: t,
|
|
3529
|
+
ensureInitialStyleCaptured: r
|
|
3530
|
+
};
|
|
3531
|
+
}), qa = class {
|
|
3532
|
+
#e = va();
|
|
3533
|
+
#t;
|
|
3534
|
+
#n = () => null;
|
|
3535
|
+
#r;
|
|
3536
|
+
locked;
|
|
3537
|
+
constructor(e, t = () => null) {
|
|
3538
|
+
this.#t = e, this.#n = t, this.#r = Ka.get(), this.#r && (this.#r.cancelPendingCleanup(), this.#r.ensureInitialStyleCaptured(), this.#r.lockMap.set(this.#e, this.#t ?? !1), this.locked = M(() => this.#r.lockMap.get(this.#e) ?? !1, (e) => this.#r.lockMap.set(this.#e, e)), P(() => {
|
|
3539
|
+
if (this.#r.lockMap.delete(this.#e), Ja(this.#r.lockMap)) return;
|
|
3540
|
+
let e = this.#n();
|
|
3541
|
+
this.#r.scheduleCleanupIfNoNewLocks(e, () => {
|
|
3542
|
+
this.#r.resetBodyStyle();
|
|
3543
|
+
});
|
|
3544
|
+
}));
|
|
3545
|
+
}
|
|
3546
|
+
};
|
|
3547
|
+
function Ja(e) {
|
|
3548
|
+
for (let [t, n] of e) if (n) return !0;
|
|
3549
|
+
return !1;
|
|
3550
|
+
}
|
|
3551
|
+
//#endregion
|
|
3552
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/scroll-lock/scroll-lock.svelte
|
|
3553
|
+
function Ya(e, t) {
|
|
3554
|
+
p(t, !0);
|
|
3555
|
+
let n = _(t, "preventScroll", 3, !0), r = _(t, "restoreScrollDelay", 3, null);
|
|
3556
|
+
n() && new qa(n(), () => r()), d();
|
|
3557
|
+
}
|
|
3558
|
+
//#endregion
|
|
3559
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/floating-layer/components/floating-layer-content-static.svelte
|
|
3560
|
+
function Xa(n, r) {
|
|
3561
|
+
p(r, !0), O(() => {
|
|
3562
|
+
r.onPlaced?.();
|
|
3563
|
+
});
|
|
3564
|
+
var i = h();
|
|
3565
|
+
s(e(i), () => r.content ?? S, () => ({
|
|
3566
|
+
props: {},
|
|
3567
|
+
wrapperProps: {}
|
|
3568
|
+
})), t(n, i), d();
|
|
3569
|
+
}
|
|
3570
|
+
//#endregion
|
|
3571
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/floating-layer/components/floating-layer-content.svelte
|
|
3572
|
+
function Za(n, r) {
|
|
3573
|
+
p(r, !0);
|
|
3574
|
+
let i = _(r, "side", 3, "bottom"), a = _(r, "sideOffset", 3, 0), o = _(r, "align", 3, "center"), l = _(r, "alignOffset", 3, 0), f = _(r, "arrowPadding", 3, 0), m = _(r, "avoidCollisions", 3, !0), g = _(r, "collisionBoundary", 19, () => []), v = _(r, "collisionPadding", 3, 0), y = _(r, "hideWhenDetached", 3, !1), b = _(r, "onPlaced", 3, () => {}), x = _(r, "sticky", 3, "partial"), C = _(r, "updatePositionStrategy", 3, "optimized"), w = _(r, "strategy", 3, "fixed"), T = _(r, "dir", 3, "ltr"), E = _(r, "style", 19, () => ({})), D = _(r, "wrapperId", 19, va), O = _(r, "customAnchor", 3, null), ee = _(r, "tooltip", 3, !1), k = Aa.create({
|
|
3575
|
+
side: M(() => i()),
|
|
3576
|
+
sideOffset: M(() => a()),
|
|
3577
|
+
align: M(() => o()),
|
|
3578
|
+
alignOffset: M(() => l()),
|
|
3579
|
+
id: M(() => r.id),
|
|
3580
|
+
arrowPadding: M(() => f()),
|
|
3581
|
+
avoidCollisions: M(() => m()),
|
|
3582
|
+
collisionBoundary: M(() => g()),
|
|
3583
|
+
collisionPadding: M(() => v()),
|
|
3584
|
+
hideWhenDetached: M(() => y()),
|
|
3585
|
+
onPlaced: M(() => b()),
|
|
3586
|
+
sticky: M(() => x()),
|
|
3587
|
+
updatePositionStrategy: M(() => C()),
|
|
3588
|
+
strategy: M(() => w()),
|
|
3589
|
+
dir: M(() => T()),
|
|
3590
|
+
style: M(() => E()),
|
|
3591
|
+
enabled: M(() => r.enabled),
|
|
3592
|
+
wrapperId: M(() => D()),
|
|
3593
|
+
customAnchor: M(() => O())
|
|
3594
|
+
}, ee()), A = u(() => Ke(k.wrapperProps, { style: { pointerEvents: "auto" } }));
|
|
3595
|
+
var te = h();
|
|
3596
|
+
s(e(te), () => r.content ?? S, () => ({
|
|
3597
|
+
props: k.props,
|
|
3598
|
+
wrapperProps: c(A)
|
|
3599
|
+
})), t(n, te), d();
|
|
3600
|
+
}
|
|
3601
|
+
//#endregion
|
|
3602
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/popper-layer/popper-content.svelte
|
|
3603
|
+
var Qa = /* @__PURE__ */ new Set([
|
|
3604
|
+
"$$slots",
|
|
3605
|
+
"$$events",
|
|
3606
|
+
"$$legacy",
|
|
3607
|
+
"content",
|
|
3608
|
+
"isStatic",
|
|
3609
|
+
"onPlaced"
|
|
3610
|
+
]);
|
|
3611
|
+
function $a(n, i) {
|
|
3612
|
+
let a = _(i, "isStatic", 3, !1), o = y(i, Qa);
|
|
3613
|
+
var s = h(), c = e(s), l = (e) => {
|
|
3614
|
+
Xa(e, {
|
|
3615
|
+
get content() {
|
|
3616
|
+
return i.content;
|
|
3617
|
+
},
|
|
3618
|
+
get onPlaced() {
|
|
3619
|
+
return i.onPlaced;
|
|
3620
|
+
}
|
|
3621
|
+
});
|
|
3622
|
+
}, u = (e) => {
|
|
3623
|
+
Za(e, m({
|
|
3624
|
+
get content() {
|
|
3625
|
+
return i.content;
|
|
3626
|
+
},
|
|
3627
|
+
get onPlaced() {
|
|
3628
|
+
return i.onPlaced;
|
|
3629
|
+
}
|
|
3630
|
+
}, () => o));
|
|
3631
|
+
};
|
|
3632
|
+
r(c, (e) => {
|
|
3633
|
+
a() ? e(l) : e(u, -1);
|
|
3634
|
+
}), t(n, s);
|
|
3635
|
+
}
|
|
3636
|
+
//#endregion
|
|
3637
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/escape-layer/use-escape-layer.svelte.js
|
|
3638
|
+
globalThis.bitsEscapeLayers ??= /* @__PURE__ */ new Map();
|
|
3639
|
+
var eo = class e {
|
|
3640
|
+
static create(t) {
|
|
3641
|
+
return new e(t);
|
|
3642
|
+
}
|
|
3643
|
+
opts;
|
|
3644
|
+
domContext;
|
|
3645
|
+
constructor(e) {
|
|
3646
|
+
this.opts = e, this.domContext = new ot(this.opts.ref);
|
|
3647
|
+
let t = V;
|
|
3648
|
+
R(() => e.enabled.current, (n) => (n && (globalThis.bitsEscapeLayers.set(this, e.escapeKeydownBehavior), t = this.#e()), () => {
|
|
3649
|
+
t(), globalThis.bitsEscapeLayers.delete(this);
|
|
3650
|
+
}));
|
|
3651
|
+
}
|
|
3652
|
+
#e = () => C(this.domContext.getDocument(), "keydown", this.#t, { passive: !1 });
|
|
3653
|
+
#t = (e) => {
|
|
3654
|
+
if (e.key !== "Escape" || !to(this)) return;
|
|
3655
|
+
let t = new KeyboardEvent(e.type, e);
|
|
3656
|
+
e.preventDefault();
|
|
3657
|
+
let n = this.opts.escapeKeydownBehavior.current;
|
|
3658
|
+
n !== "close" && n !== "defer-otherwise-close" || this.opts.onEscapeKeydown.current(t);
|
|
3659
|
+
};
|
|
3660
|
+
};
|
|
3661
|
+
function to(e) {
|
|
3662
|
+
let t = [...globalThis.bitsEscapeLayers], n = t.findLast(([e, { current: t }]) => t === "close" || t === "ignore");
|
|
3663
|
+
if (n) return n[0] === e;
|
|
3664
|
+
let [r] = t[0];
|
|
3665
|
+
return r === e;
|
|
3666
|
+
}
|
|
3667
|
+
//#endregion
|
|
3668
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/escape-layer/escape-layer.svelte
|
|
3669
|
+
function no(n, r) {
|
|
3670
|
+
p(r, !0);
|
|
3671
|
+
let i = _(r, "escapeKeydownBehavior", 3, "close"), a = _(r, "onEscapeKeydown", 3, V);
|
|
3672
|
+
eo.create({
|
|
3673
|
+
escapeKeydownBehavior: M(() => i()),
|
|
3674
|
+
onEscapeKeydown: M(() => a()),
|
|
3675
|
+
enabled: M(() => r.enabled),
|
|
3676
|
+
ref: r.ref
|
|
3677
|
+
});
|
|
3678
|
+
var o = h();
|
|
3679
|
+
s(e(o), () => r.children ?? S), t(n, o), d();
|
|
3680
|
+
}
|
|
3681
|
+
//#endregion
|
|
3682
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/debounce.js
|
|
3683
|
+
function ro(e, t = 500) {
|
|
3684
|
+
let n = null, r = (...r) => {
|
|
3685
|
+
n !== null && clearTimeout(n), n = setTimeout(() => {
|
|
3686
|
+
e(...r);
|
|
3687
|
+
}, t);
|
|
3688
|
+
};
|
|
3689
|
+
return r.destroy = () => {
|
|
3690
|
+
n !== null && (clearTimeout(n), n = null);
|
|
3691
|
+
}, r;
|
|
3692
|
+
}
|
|
3693
|
+
//#endregion
|
|
3694
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/elements.js
|
|
3695
|
+
function io(e, t) {
|
|
3696
|
+
return e === t || e.contains(t);
|
|
3697
|
+
}
|
|
3698
|
+
function ao(e) {
|
|
3699
|
+
return e?.ownerDocument ?? document;
|
|
3700
|
+
}
|
|
3701
|
+
//#endregion
|
|
3702
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/internal/dom.js
|
|
3703
|
+
function oo(e, t) {
|
|
3704
|
+
let { clientX: n, clientY: r } = e, i = t.getBoundingClientRect();
|
|
3705
|
+
return n < i.left || n > i.right || r < i.top || r > i.bottom;
|
|
3706
|
+
}
|
|
3707
|
+
//#endregion
|
|
3708
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/dismissible-layer/use-dismissable-layer.svelte.js
|
|
3709
|
+
globalThis.bitsDismissableLayers ??= /* @__PURE__ */ new Map();
|
|
3710
|
+
var so = class e {
|
|
3711
|
+
static create(t) {
|
|
3712
|
+
return new e(t);
|
|
3713
|
+
}
|
|
3714
|
+
opts;
|
|
3715
|
+
#e;
|
|
3716
|
+
#t;
|
|
3717
|
+
#n = { pointerdown: !1 };
|
|
3718
|
+
#r = !1;
|
|
3719
|
+
#i = !1;
|
|
3720
|
+
#a = void 0;
|
|
3721
|
+
#o;
|
|
3722
|
+
#s = V;
|
|
3723
|
+
constructor(e) {
|
|
3724
|
+
this.opts = e, this.#t = e.interactOutsideBehavior, this.#e = e.onInteractOutside, this.#o = e.onFocusOutside, v(() => {
|
|
3725
|
+
this.#a = ao(this.opts.ref.current);
|
|
3726
|
+
});
|
|
3727
|
+
let t = V, n = () => {
|
|
3728
|
+
this.#g(), globalThis.bitsDismissableLayers.delete(this), this.#d.destroy(), t();
|
|
3729
|
+
};
|
|
3730
|
+
R([() => this.opts.enabled.current, () => this.opts.ref.current], () => {
|
|
3731
|
+
if (!(!this.opts.enabled.current || !this.opts.ref.current)) return qe(1, () => {
|
|
3732
|
+
this.opts.ref.current && (globalThis.bitsDismissableLayers.set(this, this.#t), t(), t = this.#l());
|
|
3733
|
+
}), n;
|
|
3734
|
+
}), P(() => {
|
|
3735
|
+
this.#g.destroy(), globalThis.bitsDismissableLayers.delete(this), this.#d.destroy(), this.#s(), t();
|
|
3736
|
+
});
|
|
3737
|
+
}
|
|
3738
|
+
#c = (e) => {
|
|
3739
|
+
e.defaultPrevented || this.opts.ref.current && F(() => {
|
|
3740
|
+
!this.opts.ref.current || this.#h(e.target) || e.target && !this.#i && this.#o.current?.(e);
|
|
3741
|
+
});
|
|
3742
|
+
};
|
|
3743
|
+
#l() {
|
|
3744
|
+
return ze(C(this.#a, "pointerdown", ze(this.#f, this.#m), { capture: !0 }), C(this.#a, "pointerdown", ze(this.#p, this.#d)), C(this.#a, "focusin", this.#c));
|
|
3745
|
+
}
|
|
3746
|
+
#u = (e) => {
|
|
3747
|
+
let t = e;
|
|
3748
|
+
t.defaultPrevented && (t = fo(e)), this.#e.current(e);
|
|
3749
|
+
};
|
|
3750
|
+
#d = ro((e) => {
|
|
3751
|
+
if (!this.opts.ref.current) {
|
|
3752
|
+
this.#s();
|
|
3753
|
+
return;
|
|
3754
|
+
}
|
|
3755
|
+
let t = this.opts.isValidEvent.current(e, this.opts.ref.current) || uo(e, this.opts.ref.current);
|
|
3756
|
+
if (!this.#r || this.#_() || !t) {
|
|
3757
|
+
this.#s();
|
|
3758
|
+
return;
|
|
3759
|
+
}
|
|
3760
|
+
let n = e;
|
|
3761
|
+
if (n.defaultPrevented && (n = fo(n)), this.#t.current !== "close" && this.#t.current !== "defer-otherwise-close") {
|
|
3762
|
+
this.#s();
|
|
3763
|
+
return;
|
|
3764
|
+
}
|
|
3765
|
+
e.pointerType === "touch" ? (this.#s(), this.#s = C(this.#a, "click", this.#u, { once: !0 })) : this.#e.current(n);
|
|
3766
|
+
}, 10);
|
|
3767
|
+
#f = (e) => {
|
|
3768
|
+
this.#n[e.type] = !0;
|
|
3769
|
+
};
|
|
3770
|
+
#p = (e) => {
|
|
3771
|
+
this.#n[e.type] = !1;
|
|
3772
|
+
};
|
|
3773
|
+
#m = () => {
|
|
3774
|
+
this.opts.ref.current && (this.#r = lo(this.opts.ref.current));
|
|
3775
|
+
};
|
|
3776
|
+
#h = (e) => this.opts.ref.current ? io(this.opts.ref.current, e) : !1;
|
|
3777
|
+
#g = ro(() => {
|
|
3778
|
+
for (let e in this.#n) this.#n[e] = !1;
|
|
3779
|
+
this.#r = !1;
|
|
3780
|
+
}, 20);
|
|
3781
|
+
#_() {
|
|
3782
|
+
return Object.values(this.#n).some(Boolean);
|
|
3783
|
+
}
|
|
3784
|
+
#v = () => {
|
|
3785
|
+
this.#i = !0;
|
|
3786
|
+
};
|
|
3787
|
+
#y = () => {
|
|
3788
|
+
this.#i = !1;
|
|
3789
|
+
};
|
|
3790
|
+
props = {
|
|
3791
|
+
onfocuscapture: this.#v,
|
|
3792
|
+
onblurcapture: this.#y
|
|
3793
|
+
};
|
|
3794
|
+
};
|
|
3795
|
+
function co(e = [...globalThis.bitsDismissableLayers]) {
|
|
3796
|
+
return e.findLast(([e, { current: t }]) => t === "close" || t === "ignore");
|
|
3797
|
+
}
|
|
3798
|
+
function lo(e) {
|
|
3799
|
+
let t = [...globalThis.bitsDismissableLayers], n = co(t);
|
|
3800
|
+
if (n) return n[0].opts.ref.current === e;
|
|
3801
|
+
let [r] = t[0];
|
|
3802
|
+
return r.opts.ref.current === e;
|
|
3803
|
+
}
|
|
3804
|
+
function uo(e, t) {
|
|
3805
|
+
let n = e.target;
|
|
3806
|
+
if (!Gt(n)) return !1;
|
|
3807
|
+
let r = !!n.closest(`[${sr}]`), i = !!t.closest(`[${cr}]`);
|
|
3808
|
+
return "button" in e && e.button > 0 && !r ? !1 : "button" in e && e.button === 0 && r && i ? !0 : r && i ? !1 : ao(n).documentElement.contains(n) && !io(t, n) && oo(e, t);
|
|
3809
|
+
}
|
|
3810
|
+
function fo(e) {
|
|
3811
|
+
let t = e.currentTarget, n = e.target, r;
|
|
3812
|
+
r = e instanceof PointerEvent ? new PointerEvent(e.type, e) : new PointerEvent("pointerdown", e);
|
|
3813
|
+
let i = !1;
|
|
3814
|
+
return new Proxy(r, { get: (r, a) => a === "currentTarget" ? t : a === "target" ? n : a === "preventDefault" ? () => {
|
|
3815
|
+
i = !0, typeof r.preventDefault == "function" && r.preventDefault();
|
|
3816
|
+
} : a === "defaultPrevented" ? i : a in r ? r[a] : e[a] });
|
|
3817
|
+
}
|
|
3818
|
+
//#endregion
|
|
3819
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/dismissible-layer/dismissible-layer.svelte
|
|
3820
|
+
function po(n, r) {
|
|
3821
|
+
p(r, !0);
|
|
3822
|
+
let i = _(r, "interactOutsideBehavior", 3, "close"), a = _(r, "onInteractOutside", 3, V), o = _(r, "onFocusOutside", 3, V), c = _(r, "isValidEvent", 3, () => !1), l = so.create({
|
|
3823
|
+
id: M(() => r.id),
|
|
3824
|
+
interactOutsideBehavior: M(() => i()),
|
|
3825
|
+
onInteractOutside: M(() => a()),
|
|
3826
|
+
enabled: M(() => r.enabled),
|
|
3827
|
+
onFocusOutside: M(() => o()),
|
|
3828
|
+
isValidEvent: M(() => c()),
|
|
3829
|
+
ref: r.ref
|
|
3830
|
+
});
|
|
3831
|
+
var u = h();
|
|
3832
|
+
s(e(u), () => r.children ?? S, () => ({ props: l.props })), t(n, u), d();
|
|
3833
|
+
}
|
|
3834
|
+
//#endregion
|
|
3835
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/text-selection-layer/use-text-selection-layer.svelte.js
|
|
3836
|
+
var mo = () => {};
|
|
3837
|
+
globalThis.bitsTextSelectionLayers ??= /* @__PURE__ */ new Map();
|
|
3838
|
+
var ho = class e {
|
|
3839
|
+
static create(t) {
|
|
3840
|
+
return new e(t);
|
|
3841
|
+
}
|
|
3842
|
+
opts;
|
|
3843
|
+
domContext;
|
|
3844
|
+
#e = V;
|
|
3845
|
+
#t = !1;
|
|
3846
|
+
#n = mo;
|
|
3847
|
+
#r = mo;
|
|
3848
|
+
constructor(e) {
|
|
3849
|
+
this.opts = e, this.domContext = new ot(e.ref);
|
|
3850
|
+
let t = V;
|
|
3851
|
+
R(() => [
|
|
3852
|
+
this.opts.enabled.current,
|
|
3853
|
+
this.opts.onPointerDown.current,
|
|
3854
|
+
this.opts.onPointerUp.current
|
|
3855
|
+
], ([e, n, r]) => (this.#t = e, this.#n = n, this.#r = r, e && (globalThis.bitsTextSelectionLayers.set(this, this.opts.enabled), t(), t = this.#i()), () => {
|
|
3856
|
+
this.#t = !1, t(), this.#s(), globalThis.bitsTextSelectionLayers.delete(this);
|
|
3857
|
+
}));
|
|
3858
|
+
}
|
|
3859
|
+
#i() {
|
|
3860
|
+
return ze(C(this.domContext.getDocument(), "pointerdown", this.#o), C(this.domContext.getDocument(), "pointerup", fe(this.#s, this.#a)));
|
|
3861
|
+
}
|
|
3862
|
+
#a = (e) => {
|
|
3863
|
+
this.#r(e);
|
|
3864
|
+
};
|
|
3865
|
+
#o = (e) => {
|
|
3866
|
+
let t = this.opts.ref.current, n = e.target;
|
|
3867
|
+
!B(t) || !B(n) || !this.#t || !yo(this) || !nt(t, n) || (this.#n(e), !e.defaultPrevented && (this.#e = _o(t, this.domContext.getDocument().body)));
|
|
3868
|
+
};
|
|
3869
|
+
#s = () => {
|
|
3870
|
+
this.#e(), this.#e = V;
|
|
3871
|
+
};
|
|
3872
|
+
}, go = (e) => e.style.userSelect || e.style.webkitUserSelect;
|
|
3873
|
+
function _o(e, t) {
|
|
3874
|
+
let n = go(t), r = go(e);
|
|
3875
|
+
return vo(t, "none"), vo(e, "text"), () => {
|
|
3876
|
+
vo(t, n), vo(e, r);
|
|
3877
|
+
};
|
|
3878
|
+
}
|
|
3879
|
+
function vo(e, t) {
|
|
3880
|
+
e.style.userSelect = t, e.style.webkitUserSelect = t;
|
|
3881
|
+
}
|
|
3882
|
+
function yo(e) {
|
|
3883
|
+
let t = [...globalThis.bitsTextSelectionLayers];
|
|
3884
|
+
if (!t.length) return !1;
|
|
3885
|
+
let n = t.at(-1);
|
|
3886
|
+
return n ? n[0] === e : !1;
|
|
3887
|
+
}
|
|
3888
|
+
//#endregion
|
|
3889
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/text-selection-layer/text-selection-layer.svelte
|
|
3890
|
+
function bo(n, r) {
|
|
3891
|
+
p(r, !0);
|
|
3892
|
+
let i = _(r, "preventOverflowTextSelection", 3, !0), a = _(r, "onPointerDown", 3, V), o = _(r, "onPointerUp", 3, V);
|
|
3893
|
+
ho.create({
|
|
3894
|
+
id: M(() => r.id),
|
|
3895
|
+
onPointerDown: M(() => a()),
|
|
3896
|
+
onPointerUp: M(() => o()),
|
|
3897
|
+
enabled: M(() => r.enabled && i()),
|
|
3898
|
+
ref: r.ref
|
|
3899
|
+
});
|
|
3900
|
+
var c = h();
|
|
3901
|
+
s(e(c), () => r.children ?? S), t(n, c), d();
|
|
3902
|
+
}
|
|
3903
|
+
//#endregion
|
|
3904
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/focus-scope/focus-scope-manager.js
|
|
3905
|
+
var xo = class e {
|
|
3906
|
+
static instance;
|
|
3907
|
+
#e = N([]);
|
|
3908
|
+
#t = /* @__PURE__ */ new WeakMap();
|
|
3909
|
+
#n = /* @__PURE__ */ new WeakMap();
|
|
3910
|
+
static getInstance() {
|
|
3911
|
+
return this.instance ||= new e(), this.instance;
|
|
3912
|
+
}
|
|
3913
|
+
register(e) {
|
|
3914
|
+
let t = this.getActive();
|
|
3915
|
+
t && t !== e && t.pause();
|
|
3916
|
+
let n = document.activeElement;
|
|
3917
|
+
n && n !== document.body && this.#n.set(e, n), this.#e.current = this.#e.current.filter((t) => t !== e), this.#e.current.unshift(e);
|
|
3918
|
+
}
|
|
3919
|
+
unregister(e) {
|
|
3920
|
+
this.#e.current = this.#e.current.filter((t) => t !== e);
|
|
3921
|
+
let t = this.getActive();
|
|
3922
|
+
t && t.resume();
|
|
3923
|
+
}
|
|
3924
|
+
getActive() {
|
|
3925
|
+
return this.#e.current[0];
|
|
3926
|
+
}
|
|
3927
|
+
setFocusMemory(e, t) {
|
|
3928
|
+
this.#t.set(e, t);
|
|
3929
|
+
}
|
|
3930
|
+
getFocusMemory(e) {
|
|
3931
|
+
return this.#t.get(e);
|
|
3932
|
+
}
|
|
3933
|
+
isActiveScope(e) {
|
|
3934
|
+
return this.getActive() === e;
|
|
3935
|
+
}
|
|
3936
|
+
setPreFocusMemory(e, t) {
|
|
3937
|
+
this.#n.set(e, t);
|
|
3938
|
+
}
|
|
3939
|
+
getPreFocusMemory(e) {
|
|
3940
|
+
return this.#n.get(e);
|
|
3941
|
+
}
|
|
3942
|
+
clearPreFocusMemory(e) {
|
|
3943
|
+
this.#n.delete(e);
|
|
3944
|
+
}
|
|
3945
|
+
}, So = class e {
|
|
3946
|
+
#e = !1;
|
|
3947
|
+
#t = null;
|
|
3948
|
+
#n = xo.getInstance();
|
|
3949
|
+
#r = [];
|
|
3950
|
+
#i;
|
|
3951
|
+
constructor(e) {
|
|
3952
|
+
this.#i = e;
|
|
3953
|
+
}
|
|
3954
|
+
get paused() {
|
|
3955
|
+
return this.#e;
|
|
3956
|
+
}
|
|
3957
|
+
pause() {
|
|
3958
|
+
this.#e = !0;
|
|
3959
|
+
}
|
|
3960
|
+
resume() {
|
|
3961
|
+
this.#e = !1;
|
|
3962
|
+
}
|
|
3963
|
+
#a() {
|
|
3964
|
+
for (let e of this.#r) e();
|
|
3965
|
+
this.#r = [];
|
|
3966
|
+
}
|
|
3967
|
+
mount(e) {
|
|
3968
|
+
this.#t && this.unmount(), this.#t = e, this.#n.register(this), this.#c(), this.#o();
|
|
3969
|
+
}
|
|
3970
|
+
unmount() {
|
|
3971
|
+
this.#t &&= (this.#a(), this.#s(), this.#n.unregister(this), this.#n.clearPreFocusMemory(this), null);
|
|
3972
|
+
}
|
|
3973
|
+
#o() {
|
|
3974
|
+
if (!this.#t) return;
|
|
3975
|
+
let e = new CustomEvent("focusScope.onOpenAutoFocus", {
|
|
3976
|
+
bubbles: !1,
|
|
3977
|
+
cancelable: !0
|
|
3978
|
+
});
|
|
3979
|
+
this.#i.onOpenAutoFocus.current(e), e.defaultPrevented || requestAnimationFrame(() => {
|
|
3980
|
+
if (!this.#t) return;
|
|
3981
|
+
let e = this.#u();
|
|
3982
|
+
e ? (e.focus(), this.#n.setFocusMemory(this, e)) : this.#t.focus();
|
|
3983
|
+
});
|
|
3984
|
+
}
|
|
3985
|
+
#s() {
|
|
3986
|
+
let e = new CustomEvent("focusScope.onCloseAutoFocus", {
|
|
3987
|
+
bubbles: !1,
|
|
3988
|
+
cancelable: !0
|
|
3989
|
+
});
|
|
3990
|
+
if (this.#i.onCloseAutoFocus.current?.(e), !e.defaultPrevented) {
|
|
3991
|
+
let e = this.#n.getPreFocusMemory(this);
|
|
3992
|
+
if (e && document.contains(e)) try {
|
|
3993
|
+
e.focus();
|
|
3994
|
+
} catch {
|
|
3995
|
+
document.body.focus();
|
|
3996
|
+
}
|
|
3997
|
+
}
|
|
3998
|
+
}
|
|
3999
|
+
#c() {
|
|
4000
|
+
if (!this.#t || !this.#i.trap.current) return;
|
|
4001
|
+
let e = this.#t, t = e.ownerDocument;
|
|
4002
|
+
this.#r.push(C(t, "focusin", (t) => {
|
|
4003
|
+
if (this.#e || !this.#n.isActiveScope(this)) return;
|
|
4004
|
+
let n = t.target;
|
|
4005
|
+
if (n) if (e.contains(n)) this.#n.setFocusMemory(this, n);
|
|
4006
|
+
else {
|
|
4007
|
+
let n = this.#n.getFocusMemory(this);
|
|
4008
|
+
if (n && e.contains(n) && zn(n)) t.preventDefault(), n.focus();
|
|
4009
|
+
else {
|
|
4010
|
+
let t = this.#u(), n = this.#d()[0];
|
|
4011
|
+
(t || n || e).focus();
|
|
4012
|
+
}
|
|
4013
|
+
}
|
|
4014
|
+
}, { capture: !0 }), C(e, "keydown", (e) => {
|
|
4015
|
+
if (!this.#i.loop || this.#e || e.key !== "Tab" || !this.#n.isActiveScope(this)) return;
|
|
4016
|
+
let n = this.#l();
|
|
4017
|
+
if (n.length === 0) return;
|
|
4018
|
+
let r = n[0], i = n[n.length - 1];
|
|
4019
|
+
!e.shiftKey && t.activeElement === i ? (e.preventDefault(), r.focus()) : e.shiftKey && t.activeElement === r && (e.preventDefault(), i.focus());
|
|
4020
|
+
}));
|
|
4021
|
+
let n = new MutationObserver(() => {
|
|
4022
|
+
let t = this.#n.getFocusMemory(this);
|
|
4023
|
+
if (t && !e.contains(t)) {
|
|
4024
|
+
let t = this.#u(), n = this.#d()[0], r = t || n;
|
|
4025
|
+
r ? (r.focus(), this.#n.setFocusMemory(this, r)) : e.focus();
|
|
4026
|
+
}
|
|
4027
|
+
});
|
|
4028
|
+
n.observe(e, {
|
|
4029
|
+
childList: !0,
|
|
4030
|
+
subtree: !0
|
|
4031
|
+
}), this.#r.push(() => n.disconnect());
|
|
4032
|
+
}
|
|
4033
|
+
#l() {
|
|
4034
|
+
return this.#t ? Fn(this.#t, {
|
|
4035
|
+
includeContainer: !1,
|
|
4036
|
+
getShadowRoot: !0
|
|
4037
|
+
}) : [];
|
|
4038
|
+
}
|
|
4039
|
+
#u() {
|
|
4040
|
+
return this.#l()[0] || null;
|
|
4041
|
+
}
|
|
4042
|
+
#d() {
|
|
4043
|
+
return this.#t ? In(this.#t, {
|
|
4044
|
+
includeContainer: !1,
|
|
4045
|
+
getShadowRoot: !0
|
|
4046
|
+
}) : [];
|
|
4047
|
+
}
|
|
4048
|
+
static use(t) {
|
|
4049
|
+
let n = null;
|
|
4050
|
+
return R([() => t.ref.current, () => t.enabled.current], ([r, i]) => {
|
|
4051
|
+
r && i ? (n ||= new e(t), n.mount(r)) : n &&= (n.unmount(), null);
|
|
4052
|
+
}), P(() => {
|
|
4053
|
+
n?.unmount();
|
|
4054
|
+
}), { get props() {
|
|
4055
|
+
return { tabindex: -1 };
|
|
4056
|
+
} };
|
|
4057
|
+
}
|
|
4058
|
+
};
|
|
4059
|
+
//#endregion
|
|
4060
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/focus-scope/focus-scope.svelte
|
|
4061
|
+
function Co(n, r) {
|
|
4062
|
+
p(r, !0);
|
|
4063
|
+
let i = _(r, "enabled", 3, !1), a = _(r, "trapFocus", 3, !1), o = _(r, "loop", 3, !1), c = _(r, "onCloseAutoFocus", 3, V), l = _(r, "onOpenAutoFocus", 3, V), u = So.use({
|
|
4064
|
+
enabled: M(() => i()),
|
|
4065
|
+
trap: M(() => a()),
|
|
4066
|
+
loop: o(),
|
|
4067
|
+
onCloseAutoFocus: M(() => c()),
|
|
4068
|
+
onOpenAutoFocus: M(() => l()),
|
|
4069
|
+
ref: r.ref
|
|
4070
|
+
});
|
|
4071
|
+
var f = h();
|
|
4072
|
+
s(e(f), () => r.focusScope ?? S, () => ({ props: u.props })), t(n, f), d();
|
|
4073
|
+
}
|
|
4074
|
+
//#endregion
|
|
4075
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/popper-layer/popper-layer-inner.svelte
|
|
4076
|
+
var wo = /* @__PURE__ */ new Set(/* @__PURE__ */ "$$slots.$$events.$$legacy.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled.ref.tooltip.contentPointerEvents".split(".")), To = o("<!> <!>", 1);
|
|
4077
|
+
function Eo(n, i) {
|
|
4078
|
+
p(i, !0);
|
|
4079
|
+
let a = _(i, "interactOutsideBehavior", 3, "close"), o = _(i, "trapFocus", 3, !0), l = _(i, "isValidEvent", 3, () => !1), m = _(i, "customAnchor", 3, null), g = _(i, "isStatic", 3, !1), v = _(i, "tooltip", 3, !1), b = _(i, "contentPointerEvents", 3, "auto"), x = y(i, wo), C = u(() => i.preventScroll ?? !0), w = u(() => i.strategy ?? (c(C) ? "fixed" : "absolute"));
|
|
4080
|
+
$a(n, {
|
|
4081
|
+
get isStatic() {
|
|
4082
|
+
return g();
|
|
4083
|
+
},
|
|
4084
|
+
get id() {
|
|
4085
|
+
return i.id;
|
|
4086
|
+
},
|
|
4087
|
+
get side() {
|
|
4088
|
+
return i.side;
|
|
4089
|
+
},
|
|
4090
|
+
get sideOffset() {
|
|
4091
|
+
return i.sideOffset;
|
|
4092
|
+
},
|
|
4093
|
+
get align() {
|
|
4094
|
+
return i.align;
|
|
4095
|
+
},
|
|
4096
|
+
get alignOffset() {
|
|
4097
|
+
return i.alignOffset;
|
|
4098
|
+
},
|
|
4099
|
+
get arrowPadding() {
|
|
4100
|
+
return i.arrowPadding;
|
|
4101
|
+
},
|
|
4102
|
+
get avoidCollisions() {
|
|
4103
|
+
return i.avoidCollisions;
|
|
4104
|
+
},
|
|
4105
|
+
get collisionBoundary() {
|
|
4106
|
+
return i.collisionBoundary;
|
|
4107
|
+
},
|
|
4108
|
+
get collisionPadding() {
|
|
4109
|
+
return i.collisionPadding;
|
|
4110
|
+
},
|
|
4111
|
+
get sticky() {
|
|
4112
|
+
return i.sticky;
|
|
4113
|
+
},
|
|
4114
|
+
get hideWhenDetached() {
|
|
4115
|
+
return i.hideWhenDetached;
|
|
4116
|
+
},
|
|
4117
|
+
get updatePositionStrategy() {
|
|
4118
|
+
return i.updatePositionStrategy;
|
|
4119
|
+
},
|
|
4120
|
+
get strategy() {
|
|
4121
|
+
return c(w);
|
|
4122
|
+
},
|
|
4123
|
+
get dir() {
|
|
4124
|
+
return i.dir;
|
|
4125
|
+
},
|
|
4126
|
+
get wrapperId() {
|
|
4127
|
+
return i.wrapperId;
|
|
4128
|
+
},
|
|
4129
|
+
get style() {
|
|
4130
|
+
return i.style;
|
|
4131
|
+
},
|
|
4132
|
+
get onPlaced() {
|
|
4133
|
+
return i.onPlaced;
|
|
4134
|
+
},
|
|
4135
|
+
get customAnchor() {
|
|
4136
|
+
return m();
|
|
4137
|
+
},
|
|
4138
|
+
get enabled() {
|
|
4139
|
+
return i.enabled;
|
|
4140
|
+
},
|
|
4141
|
+
get tooltip() {
|
|
4142
|
+
return v();
|
|
4143
|
+
},
|
|
4144
|
+
content: (n, d) => {
|
|
4145
|
+
let p = () => (d?.()).props, m = () => (d?.()).wrapperProps;
|
|
4146
|
+
var g = To(), _ = e(g), v = (e) => {
|
|
4147
|
+
Ya(e, { get preventScroll() {
|
|
4148
|
+
return c(C);
|
|
4149
|
+
} });
|
|
4150
|
+
}, y = (e) => {
|
|
4151
|
+
Ya(e, { get preventScroll() {
|
|
4152
|
+
return c(C);
|
|
4153
|
+
} });
|
|
4154
|
+
};
|
|
4155
|
+
r(_, (e) => {
|
|
4156
|
+
i.forceMount && i.enabled ? e(v) : i.forceMount || e(y, 1);
|
|
4157
|
+
}), Co(f(_, 2), {
|
|
4158
|
+
get onOpenAutoFocus() {
|
|
4159
|
+
return i.onOpenAutoFocus;
|
|
4160
|
+
},
|
|
4161
|
+
get onCloseAutoFocus() {
|
|
4162
|
+
return i.onCloseAutoFocus;
|
|
4163
|
+
},
|
|
4164
|
+
get loop() {
|
|
4165
|
+
return i.loop;
|
|
4166
|
+
},
|
|
4167
|
+
get enabled() {
|
|
4168
|
+
return i.enabled;
|
|
4169
|
+
},
|
|
4170
|
+
get trapFocus() {
|
|
4171
|
+
return o();
|
|
4172
|
+
},
|
|
4173
|
+
get forceMount() {
|
|
4174
|
+
return i.forceMount;
|
|
4175
|
+
},
|
|
4176
|
+
get ref() {
|
|
4177
|
+
return i.ref;
|
|
4178
|
+
},
|
|
4179
|
+
focusScope: (n, r) => {
|
|
4180
|
+
let o = () => (r?.()).props;
|
|
4181
|
+
no(n, {
|
|
4182
|
+
get onEscapeKeydown() {
|
|
4183
|
+
return i.onEscapeKeydown;
|
|
4184
|
+
},
|
|
4185
|
+
get escapeKeydownBehavior() {
|
|
4186
|
+
return i.escapeKeydownBehavior;
|
|
4187
|
+
},
|
|
4188
|
+
get enabled() {
|
|
4189
|
+
return i.enabled;
|
|
4190
|
+
},
|
|
4191
|
+
get ref() {
|
|
4192
|
+
return i.ref;
|
|
4193
|
+
},
|
|
4194
|
+
children: (n, r) => {
|
|
4195
|
+
po(n, {
|
|
4196
|
+
get id() {
|
|
4197
|
+
return i.id;
|
|
4198
|
+
},
|
|
4199
|
+
get onInteractOutside() {
|
|
4200
|
+
return i.onInteractOutside;
|
|
4201
|
+
},
|
|
4202
|
+
get onFocusOutside() {
|
|
4203
|
+
return i.onFocusOutside;
|
|
4204
|
+
},
|
|
4205
|
+
get interactOutsideBehavior() {
|
|
4206
|
+
return a();
|
|
4207
|
+
},
|
|
4208
|
+
get isValidEvent() {
|
|
4209
|
+
return l();
|
|
4210
|
+
},
|
|
4211
|
+
get enabled() {
|
|
4212
|
+
return i.enabled;
|
|
4213
|
+
},
|
|
4214
|
+
get ref() {
|
|
4215
|
+
return i.ref;
|
|
4216
|
+
},
|
|
4217
|
+
children: (n, r) => {
|
|
4218
|
+
let a = () => (r?.()).props;
|
|
4219
|
+
bo(n, {
|
|
4220
|
+
get id() {
|
|
4221
|
+
return i.id;
|
|
4222
|
+
},
|
|
4223
|
+
get preventOverflowTextSelection() {
|
|
4224
|
+
return i.preventOverflowTextSelection;
|
|
4225
|
+
},
|
|
4226
|
+
get onPointerDown() {
|
|
4227
|
+
return i.onPointerDown;
|
|
4228
|
+
},
|
|
4229
|
+
get onPointerUp() {
|
|
4230
|
+
return i.onPointerUp;
|
|
4231
|
+
},
|
|
4232
|
+
get enabled() {
|
|
4233
|
+
return i.enabled;
|
|
4234
|
+
},
|
|
4235
|
+
get ref() {
|
|
4236
|
+
return i.ref;
|
|
4237
|
+
},
|
|
4238
|
+
children: (n, r) => {
|
|
4239
|
+
var l = h(), d = e(l);
|
|
4240
|
+
{
|
|
4241
|
+
let e = u(() => ({
|
|
4242
|
+
props: Ke(x, p(), a(), o(), { style: { pointerEvents: b() } }),
|
|
4243
|
+
wrapperProps: m()
|
|
4244
|
+
}));
|
|
4245
|
+
s(d, () => i.popper ?? S, () => c(e));
|
|
4246
|
+
}
|
|
4247
|
+
t(n, l);
|
|
4248
|
+
},
|
|
4249
|
+
$$slots: { default: !0 }
|
|
4250
|
+
});
|
|
4251
|
+
},
|
|
4252
|
+
$$slots: { default: !0 }
|
|
4253
|
+
});
|
|
4254
|
+
},
|
|
4255
|
+
$$slots: { default: !0 }
|
|
4256
|
+
});
|
|
4257
|
+
},
|
|
4258
|
+
$$slots: { focusScope: !0 }
|
|
4259
|
+
}), t(n, g);
|
|
4260
|
+
},
|
|
4261
|
+
$$slots: { content: !0 }
|
|
4262
|
+
}), d();
|
|
4263
|
+
}
|
|
4264
|
+
//#endregion
|
|
4265
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/popper-layer/popper-layer.svelte
|
|
4266
|
+
var Do = /* @__PURE__ */ new Set(/* @__PURE__ */ "$$slots.$$events.$$legacy.popper.open.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.ref.shouldRender".split("."));
|
|
4267
|
+
function Oo(n, i) {
|
|
4268
|
+
let a = _(i, "interactOutsideBehavior", 3, "close"), o = _(i, "trapFocus", 3, !0), s = _(i, "isValidEvent", 3, () => !1), c = _(i, "customAnchor", 3, null), l = _(i, "isStatic", 3, !1), u = y(i, Do);
|
|
4269
|
+
var d = h(), f = e(d), p = (e) => {
|
|
4270
|
+
Eo(e, m({
|
|
4271
|
+
get popper() {
|
|
4272
|
+
return i.popper;
|
|
4273
|
+
},
|
|
4274
|
+
get onEscapeKeydown() {
|
|
4275
|
+
return i.onEscapeKeydown;
|
|
4276
|
+
},
|
|
4277
|
+
get escapeKeydownBehavior() {
|
|
4278
|
+
return i.escapeKeydownBehavior;
|
|
4279
|
+
},
|
|
4280
|
+
get preventOverflowTextSelection() {
|
|
4281
|
+
return i.preventOverflowTextSelection;
|
|
4282
|
+
},
|
|
4283
|
+
get id() {
|
|
4284
|
+
return i.id;
|
|
4285
|
+
},
|
|
4286
|
+
get onPointerDown() {
|
|
4287
|
+
return i.onPointerDown;
|
|
4288
|
+
},
|
|
4289
|
+
get onPointerUp() {
|
|
4290
|
+
return i.onPointerUp;
|
|
4291
|
+
},
|
|
4292
|
+
get side() {
|
|
4293
|
+
return i.side;
|
|
4294
|
+
},
|
|
4295
|
+
get sideOffset() {
|
|
4296
|
+
return i.sideOffset;
|
|
4297
|
+
},
|
|
4298
|
+
get align() {
|
|
4299
|
+
return i.align;
|
|
4300
|
+
},
|
|
4301
|
+
get alignOffset() {
|
|
4302
|
+
return i.alignOffset;
|
|
4303
|
+
},
|
|
4304
|
+
get arrowPadding() {
|
|
4305
|
+
return i.arrowPadding;
|
|
4306
|
+
},
|
|
4307
|
+
get avoidCollisions() {
|
|
4308
|
+
return i.avoidCollisions;
|
|
4309
|
+
},
|
|
4310
|
+
get collisionBoundary() {
|
|
4311
|
+
return i.collisionBoundary;
|
|
4312
|
+
},
|
|
4313
|
+
get collisionPadding() {
|
|
4314
|
+
return i.collisionPadding;
|
|
4315
|
+
},
|
|
4316
|
+
get sticky() {
|
|
4317
|
+
return i.sticky;
|
|
4318
|
+
},
|
|
4319
|
+
get hideWhenDetached() {
|
|
4320
|
+
return i.hideWhenDetached;
|
|
4321
|
+
},
|
|
4322
|
+
get updatePositionStrategy() {
|
|
4323
|
+
return i.updatePositionStrategy;
|
|
4324
|
+
},
|
|
4325
|
+
get strategy() {
|
|
4326
|
+
return i.strategy;
|
|
4327
|
+
},
|
|
4328
|
+
get dir() {
|
|
4329
|
+
return i.dir;
|
|
4330
|
+
},
|
|
4331
|
+
get preventScroll() {
|
|
4332
|
+
return i.preventScroll;
|
|
4333
|
+
},
|
|
4334
|
+
get wrapperId() {
|
|
4335
|
+
return i.wrapperId;
|
|
4336
|
+
},
|
|
4337
|
+
get style() {
|
|
4338
|
+
return i.style;
|
|
4339
|
+
},
|
|
4340
|
+
get onPlaced() {
|
|
4341
|
+
return i.onPlaced;
|
|
4342
|
+
},
|
|
4343
|
+
get customAnchor() {
|
|
4344
|
+
return c();
|
|
4345
|
+
},
|
|
4346
|
+
get isStatic() {
|
|
4347
|
+
return l();
|
|
4348
|
+
},
|
|
4349
|
+
get enabled() {
|
|
4350
|
+
return i.open;
|
|
4351
|
+
},
|
|
4352
|
+
get onInteractOutside() {
|
|
4353
|
+
return i.onInteractOutside;
|
|
4354
|
+
},
|
|
4355
|
+
get onCloseAutoFocus() {
|
|
4356
|
+
return i.onCloseAutoFocus;
|
|
4357
|
+
},
|
|
4358
|
+
get onOpenAutoFocus() {
|
|
4359
|
+
return i.onOpenAutoFocus;
|
|
4360
|
+
},
|
|
4361
|
+
get interactOutsideBehavior() {
|
|
4362
|
+
return a();
|
|
4363
|
+
},
|
|
4364
|
+
get loop() {
|
|
4365
|
+
return i.loop;
|
|
4366
|
+
},
|
|
4367
|
+
get trapFocus() {
|
|
4368
|
+
return o();
|
|
4369
|
+
},
|
|
4370
|
+
get isValidEvent() {
|
|
4371
|
+
return s();
|
|
4372
|
+
},
|
|
4373
|
+
get onFocusOutside() {
|
|
4374
|
+
return i.onFocusOutside;
|
|
4375
|
+
},
|
|
4376
|
+
forceMount: !1,
|
|
4377
|
+
get ref() {
|
|
4378
|
+
return i.ref;
|
|
4379
|
+
}
|
|
4380
|
+
}, () => u));
|
|
4381
|
+
};
|
|
4382
|
+
r(f, (e) => {
|
|
4383
|
+
i.shouldRender && e(p);
|
|
4384
|
+
}), t(n, d);
|
|
4385
|
+
}
|
|
4386
|
+
//#endregion
|
|
4387
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/popper-layer/popper-layer-force-mount.svelte
|
|
4388
|
+
var ko = /* @__PURE__ */ new Set(/* @__PURE__ */ "$$slots.$$events.$$legacy.popper.onEscapeKeydown.escapeKeydownBehavior.preventOverflowTextSelection.id.onPointerDown.onPointerUp.side.sideOffset.align.alignOffset.arrowPadding.avoidCollisions.collisionBoundary.collisionPadding.sticky.hideWhenDetached.updatePositionStrategy.strategy.dir.preventScroll.wrapperId.style.onPlaced.onInteractOutside.onCloseAutoFocus.onOpenAutoFocus.onFocusOutside.interactOutsideBehavior.loop.trapFocus.isValidEvent.customAnchor.isStatic.enabled".split("."));
|
|
4389
|
+
function Ao(e, t) {
|
|
4390
|
+
let n = _(t, "interactOutsideBehavior", 3, "close"), r = _(t, "trapFocus", 3, !0), i = _(t, "isValidEvent", 3, () => !1), a = _(t, "customAnchor", 3, null), o = _(t, "isStatic", 3, !1), s = y(t, ko);
|
|
4391
|
+
Eo(e, m({
|
|
4392
|
+
get popper() {
|
|
4393
|
+
return t.popper;
|
|
4394
|
+
},
|
|
4395
|
+
get onEscapeKeydown() {
|
|
4396
|
+
return t.onEscapeKeydown;
|
|
4397
|
+
},
|
|
4398
|
+
get escapeKeydownBehavior() {
|
|
4399
|
+
return t.escapeKeydownBehavior;
|
|
4400
|
+
},
|
|
4401
|
+
get preventOverflowTextSelection() {
|
|
4402
|
+
return t.preventOverflowTextSelection;
|
|
4403
|
+
},
|
|
4404
|
+
get id() {
|
|
4405
|
+
return t.id;
|
|
4406
|
+
},
|
|
4407
|
+
get onPointerDown() {
|
|
4408
|
+
return t.onPointerDown;
|
|
4409
|
+
},
|
|
4410
|
+
get onPointerUp() {
|
|
4411
|
+
return t.onPointerUp;
|
|
4412
|
+
},
|
|
4413
|
+
get side() {
|
|
4414
|
+
return t.side;
|
|
4415
|
+
},
|
|
4416
|
+
get sideOffset() {
|
|
4417
|
+
return t.sideOffset;
|
|
4418
|
+
},
|
|
4419
|
+
get align() {
|
|
4420
|
+
return t.align;
|
|
4421
|
+
},
|
|
4422
|
+
get alignOffset() {
|
|
4423
|
+
return t.alignOffset;
|
|
4424
|
+
},
|
|
4425
|
+
get arrowPadding() {
|
|
4426
|
+
return t.arrowPadding;
|
|
4427
|
+
},
|
|
4428
|
+
get avoidCollisions() {
|
|
4429
|
+
return t.avoidCollisions;
|
|
4430
|
+
},
|
|
4431
|
+
get collisionBoundary() {
|
|
4432
|
+
return t.collisionBoundary;
|
|
4433
|
+
},
|
|
4434
|
+
get collisionPadding() {
|
|
4435
|
+
return t.collisionPadding;
|
|
4436
|
+
},
|
|
4437
|
+
get sticky() {
|
|
4438
|
+
return t.sticky;
|
|
4439
|
+
},
|
|
4440
|
+
get hideWhenDetached() {
|
|
4441
|
+
return t.hideWhenDetached;
|
|
4442
|
+
},
|
|
4443
|
+
get updatePositionStrategy() {
|
|
4444
|
+
return t.updatePositionStrategy;
|
|
4445
|
+
},
|
|
4446
|
+
get strategy() {
|
|
4447
|
+
return t.strategy;
|
|
4448
|
+
},
|
|
4449
|
+
get dir() {
|
|
4450
|
+
return t.dir;
|
|
4451
|
+
},
|
|
4452
|
+
get preventScroll() {
|
|
4453
|
+
return t.preventScroll;
|
|
4454
|
+
},
|
|
4455
|
+
get wrapperId() {
|
|
4456
|
+
return t.wrapperId;
|
|
4457
|
+
},
|
|
4458
|
+
get style() {
|
|
4459
|
+
return t.style;
|
|
4460
|
+
},
|
|
4461
|
+
get onPlaced() {
|
|
4462
|
+
return t.onPlaced;
|
|
4463
|
+
},
|
|
4464
|
+
get customAnchor() {
|
|
4465
|
+
return a();
|
|
4466
|
+
},
|
|
4467
|
+
get isStatic() {
|
|
4468
|
+
return o();
|
|
4469
|
+
},
|
|
4470
|
+
get enabled() {
|
|
4471
|
+
return t.enabled;
|
|
4472
|
+
},
|
|
4473
|
+
get onInteractOutside() {
|
|
4474
|
+
return t.onInteractOutside;
|
|
4475
|
+
},
|
|
4476
|
+
get onCloseAutoFocus() {
|
|
4477
|
+
return t.onCloseAutoFocus;
|
|
4478
|
+
},
|
|
4479
|
+
get onOpenAutoFocus() {
|
|
4480
|
+
return t.onOpenAutoFocus;
|
|
4481
|
+
},
|
|
4482
|
+
get interactOutsideBehavior() {
|
|
4483
|
+
return n();
|
|
4484
|
+
},
|
|
4485
|
+
get loop() {
|
|
4486
|
+
return t.loop;
|
|
4487
|
+
},
|
|
4488
|
+
get trapFocus() {
|
|
4489
|
+
return r();
|
|
4490
|
+
},
|
|
4491
|
+
get isValidEvent() {
|
|
4492
|
+
return i();
|
|
4493
|
+
},
|
|
4494
|
+
get onFocusOutside() {
|
|
4495
|
+
return t.onFocusOutside;
|
|
4496
|
+
}
|
|
4497
|
+
}, () => s, { forceMount: !0 }));
|
|
4498
|
+
}
|
|
4499
|
+
//#endregion
|
|
4500
|
+
//#region ../node_modules/.bun/bits-ui@2.18.1+203cd734255b50e4/node_modules/bits-ui/dist/bits/utilities/floating-layer/components/floating-layer-anchor.svelte
|
|
4501
|
+
function jo(n, r) {
|
|
4502
|
+
p(r, !0);
|
|
4503
|
+
let i = _(r, "tooltip", 3, !1);
|
|
4504
|
+
ja.create({
|
|
4505
|
+
id: M(() => r.id),
|
|
4506
|
+
virtualEl: M(() => r.virtualEl),
|
|
4507
|
+
ref: r.ref
|
|
4508
|
+
}, i());
|
|
4509
|
+
var a = h();
|
|
4510
|
+
s(e(a), () => r.children ?? S), t(n, a), d();
|
|
4511
|
+
}
|
|
4512
|
+
//#endregion
|
|
4513
|
+
export { M as $, Ht as A, Nt as B, Wn as C, rn as D, $t as E, Ot as F, R as G, Ft as H, kt as I, ot as J, L as K, At as L, Tt as M, Et as N, en as O, Dt as P, Ue as Q, jt as R, Un as S, Zt as T, It as U, Pt as V, vt as W, P as X, F as Y, Ke as Z, Xn as _, Ia as a, Gn as b, Tr as c, wr as d, Cr as f, Zn as g, or as h, La as i, wt as j, tn as k, Or as l, jr as m, Ao as n, Sa as o, kr as p, I as q, Oo as r, Ar as s, jo as t, Dr as u, V as v, Qt as w, qn as x, Kn as y, Mt as z };
|