@cregis/ui 0.2.0 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/cregis-ui.js +871 -836
- package/dist/index.css +1 -1
- package/dist/types/index.d.ts +9 -1
- package/dist/umd/cregis-ui.umd.cjs +1 -1
- package/dist/umd/index.css +1 -1
- package/package.json +1 -1
package/dist/es/cregis-ui.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { EdsLoad as
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as G, useSlots as ur, computed as m, createElementBlock as x, openBlock as b, createElementVNode as V, createCommentVNode as I, mergeProps as xe, createBlock as Le, resolveDynamicComponent as Ft, normalizeStyle as ie, renderSlot as q, normalizeClass as j, toDisplayString as M, unref as ne, ref as _, watch as J, withDirectives as je, vModelDynamic as dr, withModifiers as fr, vModelText as pr, createVNode as U, withCtx as Z, createTextVNode as $e, nextTick as Ke, reactive as Me, provide as Ht, toRef as vr, Fragment as lt, renderList as ct, inject as qt, onMounted as et, onUnmounted as Ee, onBeforeUnmount as Ut, Transition as vt, render as Qe, h as Yt, toHandlers as Et, vShow as mt } from "vue";
|
|
2
|
+
import { EdsLoad as mr, EdsCloseCircleFill as gr, EdsWarningFill as hr, EdsSearch as Xt, EdsArrowDownMiniIos as Kt, EdsArrowRightMiniIos as br } from "@cregis/icon";
|
|
3
|
+
const yr = {
|
|
4
4
|
key: 0,
|
|
5
5
|
class: "cregis-button__icon-wrapper"
|
|
6
|
-
},
|
|
6
|
+
}, wr = ["disabled"], xr = ["disabled"], Or = ["disabled"], Ye = /* @__PURE__ */ G({
|
|
7
7
|
name: "Button",
|
|
8
8
|
inheritAttrs: !1,
|
|
9
9
|
__name: "Button",
|
|
@@ -24,7 +24,10 @@ const br = {
|
|
|
24
24
|
isActive: { type: Boolean }
|
|
25
25
|
},
|
|
26
26
|
setup(e) {
|
|
27
|
-
const t = e, r =
|
|
27
|
+
const t = e, r = ur(), n = m(() => {
|
|
28
|
+
const s = t, d = r.icon;
|
|
29
|
+
return !s.icon && typeof d == "function";
|
|
30
|
+
}), a = m(() => t.size === "large" ? "20px" : t.size === "medium" ? "16px" : "12px"), i = m(() => t.size === "large" || t.size === "medium" ? "16px" : "12px"), l = m(() => t.width ? { width: t.width } : void 0), o = m(() => {
|
|
28
31
|
if (t.plain || t.text)
|
|
29
32
|
switch (t.type) {
|
|
30
33
|
case "primary":
|
|
@@ -41,26 +44,33 @@ const br = {
|
|
|
41
44
|
else
|
|
42
45
|
return t.type === "secondary" ? "var(--material-foreground-base-secondary)" : t.type === "foreground" ? "var(--text-face-primary)" : t.type === "sameWhite" ? "var(--text-same-black)" : "var(--material-same-white)";
|
|
43
46
|
});
|
|
44
|
-
return (s,
|
|
45
|
-
|
|
47
|
+
return (s, d) => e.icon || s.$slots.icon ? (b(), x("div", yr, [
|
|
48
|
+
V("button", xe(s.$attrs, {
|
|
46
49
|
class: ["cregis-button__icon", {
|
|
47
50
|
[`cregis-button__icon--${e.iconType}`]: e.iconType,
|
|
48
51
|
[`cregis-button__icon--${e.size}`]: e.size,
|
|
52
|
+
"cregis-button__icon--slot": n.value,
|
|
49
53
|
"is-disabled": e.disabled,
|
|
50
54
|
"is-active": e.isActive
|
|
51
55
|
}],
|
|
52
56
|
disabled: e.disabled || e.loading
|
|
53
57
|
}), [
|
|
54
|
-
e.icon ? (
|
|
58
|
+
e.icon ? (b(), Le(Ft(e.icon), {
|
|
55
59
|
key: 0,
|
|
56
|
-
size:
|
|
57
|
-
}, null, 8, ["size"])) :
|
|
58
|
-
|
|
59
|
-
|
|
60
|
+
size: a.value
|
|
61
|
+
}, null, 8, ["size"])) : (b(), x("span", {
|
|
62
|
+
key: 1,
|
|
63
|
+
class: "cregis-button__icon-slot-inner",
|
|
64
|
+
style: ie({ "--cregis-btn-icon-slot-size": a.value })
|
|
65
|
+
}, [
|
|
66
|
+
q(s.$slots, "icon")
|
|
67
|
+
], 4))
|
|
68
|
+
], 16, wr),
|
|
69
|
+
e.iconText ? (b(), x("span", {
|
|
60
70
|
key: 0,
|
|
61
71
|
class: j(["cregis-button__icon-text", { "is-disabled": e.disabled }])
|
|
62
|
-
},
|
|
63
|
-
])) : e.link ? (
|
|
72
|
+
}, M(e.iconText), 3)) : I("", !0)
|
|
73
|
+
])) : e.link ? (b(), x("button", xe({ key: 1 }, s.$attrs, {
|
|
64
74
|
class: ["cregis-button__link", {
|
|
65
75
|
[`cregis-button__link--${e.type}`]: e.type,
|
|
66
76
|
[`cregis-button__link--${e.size}`]: e.size,
|
|
@@ -70,11 +80,11 @@ const br = {
|
|
|
70
80
|
disabled: e.disabled || e.loading
|
|
71
81
|
}), [
|
|
72
82
|
q(s.$slots, "default")
|
|
73
|
-
], 16,
|
|
83
|
+
], 16, xr)) : (b(), x("button", xe({
|
|
74
84
|
key: 2,
|
|
75
85
|
ref: "buttonRef"
|
|
76
86
|
}, s.$attrs, {
|
|
77
|
-
style:
|
|
87
|
+
style: l.value,
|
|
78
88
|
class: ["cregis-button", {
|
|
79
89
|
[`cregis-button--${e.type}`]: e.type,
|
|
80
90
|
[`cregis-button--${e.size}`]: e.size,
|
|
@@ -88,24 +98,24 @@ const br = {
|
|
|
88
98
|
}],
|
|
89
99
|
disabled: e.disabled || e.loading
|
|
90
100
|
}), [
|
|
91
|
-
e.loading ? (
|
|
101
|
+
e.loading ? (b(), Le(ne(mr), {
|
|
92
102
|
key: 0,
|
|
93
103
|
class: "loading",
|
|
94
|
-
size:
|
|
95
|
-
color:
|
|
104
|
+
size: i.value,
|
|
105
|
+
color: o.value
|
|
96
106
|
}, null, 8, ["size", "color"])) : q(s.$slots, "default", { key: 1 })
|
|
97
|
-
], 16,
|
|
107
|
+
], 16, Or));
|
|
98
108
|
}
|
|
99
109
|
}), $r = {
|
|
100
110
|
key: 0,
|
|
101
111
|
class: "cregis-input__prefix"
|
|
102
|
-
},
|
|
112
|
+
}, kr = ["type", "placeholder", "disabled"], Tr = {
|
|
103
113
|
key: 2,
|
|
104
114
|
class: "cregis-input__suffix"
|
|
105
|
-
},
|
|
115
|
+
}, Sr = ["disabled", "placeholder", "rows"], Cr = {
|
|
106
116
|
key: 0,
|
|
107
117
|
class: "cregis-textarea__buttons"
|
|
108
|
-
},
|
|
118
|
+
}, Qt = /* @__PURE__ */ G({
|
|
109
119
|
name: "Input",
|
|
110
120
|
inheritAttrs: !1,
|
|
111
121
|
__name: "Input",
|
|
@@ -123,37 +133,37 @@ const br = {
|
|
|
123
133
|
},
|
|
124
134
|
emits: ["update:modelValue", "input", "change", "focus", "blur", "clear"],
|
|
125
135
|
setup(e, { expose: t, emit: r }) {
|
|
126
|
-
const n = e, a = r, i =
|
|
136
|
+
const n = e, a = r, i = _(n.modelValue);
|
|
127
137
|
J(
|
|
128
138
|
() => n.modelValue,
|
|
129
139
|
(f) => {
|
|
130
140
|
i.value = f;
|
|
131
141
|
}
|
|
132
142
|
);
|
|
133
|
-
const
|
|
143
|
+
const l = _(), o = _(0), s = _(!1);
|
|
134
144
|
let d = null;
|
|
135
145
|
const c = async () => {
|
|
136
|
-
await
|
|
146
|
+
await Ke(), l.value?.focus();
|
|
137
147
|
}, w = async () => {
|
|
138
|
-
a("update:modelValue", i.value), a("input", i.value), await
|
|
148
|
+
a("update:modelValue", i.value), a("input", i.value), await Ke(), C();
|
|
139
149
|
}, k = () => {
|
|
140
150
|
a("change", i.value);
|
|
141
151
|
}, v = (f) => {
|
|
142
|
-
|
|
143
|
-
},
|
|
144
|
-
|
|
145
|
-
},
|
|
152
|
+
s.value = !0, a("focus", f);
|
|
153
|
+
}, S = (f) => {
|
|
154
|
+
s.value = !1, a("blur", f);
|
|
155
|
+
}, O = m(() => n.clearable && !n.disabled && !!i.value && s.value), $ = () => {
|
|
146
156
|
i.value = "", a("update:modelValue", ""), a("clear"), a("input", ""), a("change", "");
|
|
147
|
-
},
|
|
157
|
+
}, C = () => {
|
|
148
158
|
d && cancelAnimationFrame(d), d = requestAnimationFrame(() => {
|
|
149
|
-
if (!
|
|
150
|
-
const f =
|
|
151
|
-
u.style.position = "absolute", u.style.visibility = "hidden", u.style.whiteSpace = "pre", u.style.font = window.getComputedStyle(f).font, u.style.letterSpacing = window.getComputedStyle(f).letterSpacing, u.textContent =
|
|
159
|
+
if (!l.value || l.value.tagName !== "INPUT") return;
|
|
160
|
+
const f = l.value, g = f.value, u = document.createElement("span");
|
|
161
|
+
u.style.position = "absolute", u.style.visibility = "hidden", u.style.whiteSpace = "pre", u.style.font = window.getComputedStyle(f).font, u.style.letterSpacing = window.getComputedStyle(f).letterSpacing, u.textContent = g || " ", document.body.appendChild(u), o.value = u.getBoundingClientRect().width, document.body.removeChild(u);
|
|
152
162
|
});
|
|
153
|
-
},
|
|
163
|
+
}, E = m(() => {
|
|
154
164
|
const f = {};
|
|
155
165
|
return o.value > 0 && (f.position = "absolute", f.left = `${o.value + 16}px`), f;
|
|
156
|
-
}),
|
|
166
|
+
}), R = async () => {
|
|
157
167
|
try {
|
|
158
168
|
i.value = await navigator.clipboard.readText();
|
|
159
169
|
} catch (f) {
|
|
@@ -162,8 +172,8 @@ const br = {
|
|
|
162
172
|
};
|
|
163
173
|
return t({
|
|
164
174
|
focus: c,
|
|
165
|
-
updateTextWidth:
|
|
166
|
-
}), (f,
|
|
175
|
+
updateTextWidth: C
|
|
176
|
+
}), (f, g) => e.type !== "textarea" ? (b(), x("div", {
|
|
167
177
|
key: 0,
|
|
168
178
|
class: j(["cregis-input", {
|
|
169
179
|
[`cregis-input--${e.size}`]: e.size,
|
|
@@ -171,19 +181,19 @@ const br = {
|
|
|
171
181
|
"is-prefix": f.$slots.prefix,
|
|
172
182
|
"is-suffix": f.$slots.suffix
|
|
173
183
|
}]),
|
|
174
|
-
style:
|
|
184
|
+
style: ie([{ width: e.width }, e.inputStyle])
|
|
175
185
|
}, [
|
|
176
|
-
|
|
177
|
-
class: j(["cregis-input__wrapper", { "is-focus":
|
|
186
|
+
V("div", {
|
|
187
|
+
class: j(["cregis-input__wrapper", { "is-focus": s.value }])
|
|
178
188
|
}, [
|
|
179
|
-
f.$slots.prefix ? (
|
|
189
|
+
f.$slots.prefix ? (b(), x("span", $r, [
|
|
180
190
|
q(f.$slots, "prefix")
|
|
181
191
|
])) : I("", !0),
|
|
182
|
-
|
|
192
|
+
je(V("input", xe({
|
|
183
193
|
class: "cregis-input__inner",
|
|
184
|
-
"onUpdate:modelValue":
|
|
194
|
+
"onUpdate:modelValue": g[0] || (g[0] = (u) => i.value = u),
|
|
185
195
|
ref_key: "inputRef",
|
|
186
|
-
ref:
|
|
196
|
+
ref: l,
|
|
187
197
|
type: e.type,
|
|
188
198
|
placeholder: e.placeholder
|
|
189
199
|
}, f.$attrs, {
|
|
@@ -191,85 +201,85 @@ const br = {
|
|
|
191
201
|
onInput: w,
|
|
192
202
|
onChange: k,
|
|
193
203
|
onFocus: v,
|
|
194
|
-
onBlur:
|
|
195
|
-
}), null, 16,
|
|
196
|
-
[
|
|
204
|
+
onBlur: S
|
|
205
|
+
}), null, 16, kr), [
|
|
206
|
+
[dr, i.value]
|
|
197
207
|
]),
|
|
198
|
-
e.unit && i.value ? (
|
|
208
|
+
e.unit && i.value ? (b(), x("span", {
|
|
199
209
|
key: 1,
|
|
200
|
-
style:
|
|
210
|
+
style: ie(E.value),
|
|
201
211
|
class: "cregis-input__unit"
|
|
202
|
-
},
|
|
203
|
-
f.$slots.suffix ||
|
|
212
|
+
}, M(e.unit), 5)) : I("", !0),
|
|
213
|
+
f.$slots.suffix || O.value ? (b(), x("span", Tr, [
|
|
204
214
|
q(f.$slots, "suffix"),
|
|
205
|
-
|
|
215
|
+
O.value ? (b(), Le(Ye, {
|
|
206
216
|
key: 0,
|
|
207
|
-
icon:
|
|
217
|
+
icon: ne(gr),
|
|
208
218
|
"icon-type": "square",
|
|
209
219
|
onClick: $,
|
|
210
|
-
onMousedown:
|
|
220
|
+
onMousedown: g[1] || (g[1] = fr(() => {
|
|
211
221
|
}, ["prevent"]))
|
|
212
222
|
}, null, 8, ["icon"])) : I("", !0)
|
|
213
223
|
])) : I("", !0)
|
|
214
224
|
], 2)
|
|
215
|
-
], 6)) : (
|
|
225
|
+
], 6)) : (b(), x("div", {
|
|
216
226
|
key: 1,
|
|
217
227
|
class: j(["cregis-textarea", { "is-disabled": e.disabled }]),
|
|
218
|
-
style:
|
|
228
|
+
style: ie([{ width: e.width }, e.inputStyle])
|
|
219
229
|
}, [
|
|
220
|
-
|
|
230
|
+
je(V("textarea", xe({ class: "cregis-textarea__wrapper" }, f.$attrs, {
|
|
221
231
|
ref_key: "inputRef",
|
|
222
|
-
ref:
|
|
232
|
+
ref: l,
|
|
223
233
|
disabled: e.disabled,
|
|
224
234
|
placeholder: e.placeholder,
|
|
225
235
|
rows: e.rows,
|
|
226
|
-
"onUpdate:modelValue":
|
|
236
|
+
"onUpdate:modelValue": g[2] || (g[2] = (u) => i.value = u),
|
|
227
237
|
onInput: w,
|
|
228
238
|
onChange: k,
|
|
229
239
|
onFocus: v,
|
|
230
|
-
onBlur:
|
|
231
|
-
}), null, 16,
|
|
232
|
-
[
|
|
240
|
+
onBlur: S
|
|
241
|
+
}), null, 16, Sr), [
|
|
242
|
+
[pr, i.value]
|
|
233
243
|
]),
|
|
234
|
-
e.disabled ? I("", !0) : (
|
|
235
|
-
U(
|
|
244
|
+
e.disabled ? I("", !0) : (b(), x("div", Cr, [
|
|
245
|
+
U(Ye, {
|
|
236
246
|
class: "cregis-textarea__button",
|
|
237
247
|
link: "",
|
|
238
248
|
size: "small",
|
|
239
|
-
onClick:
|
|
249
|
+
onClick: R
|
|
240
250
|
}, {
|
|
241
|
-
default: Z(() => [...
|
|
242
|
-
|
|
251
|
+
default: Z(() => [...g[3] || (g[3] = [
|
|
252
|
+
$e(" Paste ", -1)
|
|
243
253
|
])]),
|
|
244
254
|
_: 1
|
|
245
255
|
}),
|
|
246
|
-
U(
|
|
256
|
+
U(Ye, {
|
|
247
257
|
class: "cregis-textarea__button",
|
|
248
258
|
link: "",
|
|
249
259
|
size: "small",
|
|
250
260
|
disabled: !i.value,
|
|
251
261
|
onClick: $
|
|
252
262
|
}, {
|
|
253
|
-
default: Z(() => [...
|
|
254
|
-
|
|
263
|
+
default: Z(() => [...g[4] || (g[4] = [
|
|
264
|
+
$e(" Clear ", -1)
|
|
255
265
|
])]),
|
|
256
266
|
_: 1
|
|
257
267
|
}, 8, ["disabled"])
|
|
258
268
|
]))
|
|
259
269
|
], 6));
|
|
260
270
|
}
|
|
261
|
-
}),
|
|
271
|
+
}), Pr = ["width", "height"], Vr = {
|
|
262
272
|
stroke: "none",
|
|
263
273
|
"stroke-width": "1",
|
|
264
274
|
fill: "none",
|
|
265
275
|
"fill-rule": "evenodd"
|
|
266
|
-
}, Er = { transform: "translate(-394.000000, -457.000000)" },
|
|
276
|
+
}, Er = { transform: "translate(-394.000000, -457.000000)" }, Br = { transform: "translate(394.000000, 457.000000)" }, Ar = ["width", "height"], Rr = /* @__PURE__ */ G({
|
|
267
277
|
__name: "checked-basis",
|
|
268
278
|
props: {
|
|
269
279
|
size: { default: "16px" }
|
|
270
280
|
},
|
|
271
281
|
setup(e) {
|
|
272
|
-
return (t, r) => (
|
|
282
|
+
return (t, r) => (b(), x("svg", {
|
|
273
283
|
width: e.size,
|
|
274
284
|
height: e.size,
|
|
275
285
|
viewBox: "0 0 16 16",
|
|
@@ -277,16 +287,16 @@ const br = {
|
|
|
277
287
|
xmlns: "http://www.w3.org/2000/svg",
|
|
278
288
|
"xmlns:xlink": "http://www.w3.org/1999/xlink"
|
|
279
289
|
}, [
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
290
|
+
V("g", Vr, [
|
|
291
|
+
V("g", Er, [
|
|
292
|
+
V("g", Br, [
|
|
293
|
+
V("rect", {
|
|
284
294
|
x: "0",
|
|
285
295
|
y: "0",
|
|
286
296
|
width: e.size,
|
|
287
297
|
height: e.size
|
|
288
|
-
}, null, 8,
|
|
289
|
-
r[0] || (r[0] =
|
|
298
|
+
}, null, 8, Ar),
|
|
299
|
+
r[0] || (r[0] = V("path", {
|
|
290
300
|
d: "M6.67713976,13.5709642 C7.12567714,13.5709642 7.468039,13.3943662 7.70422535,13.0411701 L13.7562297,3.77789816 C13.8407367,3.65005417 13.9024919,3.52546046 13.9414951,3.40411701 C13.9804984,3.28277356 14,3.16468039 14,3.04983749 C14,2.74647887 13.8976165,2.49566631 13.6928494,2.29739978 C13.4880823,2.09913326 13.2307692,2 12.9209101,2 C12.7063922,2 12.5265439,2.04225352 12.3813651,2.12676056 C12.2361863,2.21126761 12.0975081,2.35536295 11.9653304,2.55904659 L6.65113759,10.9512459 L3.95016251,7.60346696 C3.71830986,7.32177681 3.43011918,7.18093174 3.08559047,7.18093174 C2.77139762,7.18093174 2.51191766,7.28169014 2.3071506,7.48320693 C2.10238353,7.68472373 2,7.93824485 2,8.24377031 C2,8.38028169 2.02329361,8.51083424 2.06988082,8.63542795 C2.11646804,8.76002167 2.19826652,8.88949079 2.31527627,9.02383532 L5.67280607,13.0899242 C5.94149512,13.4106176 6.27627302,13.5709642 6.67713976,13.5709642 Z",
|
|
291
301
|
fill: "currentColor",
|
|
292
302
|
"fill-rule": "nonzero"
|
|
@@ -294,12 +304,12 @@ const br = {
|
|
|
294
304
|
])
|
|
295
305
|
])
|
|
296
306
|
])
|
|
297
|
-
], 8,
|
|
307
|
+
], 8, Pr));
|
|
298
308
|
}
|
|
299
|
-
}),
|
|
309
|
+
}), Dr = {
|
|
300
310
|
key: 0,
|
|
301
311
|
class: "cregis-checkbox--indeterminate"
|
|
302
|
-
},
|
|
312
|
+
}, ei = /* @__PURE__ */ G({
|
|
303
313
|
name: "Checkbox",
|
|
304
314
|
__name: "Checkbox",
|
|
305
315
|
props: {
|
|
@@ -311,7 +321,7 @@ const br = {
|
|
|
311
321
|
},
|
|
312
322
|
emits: ["update:modelValue", "change"],
|
|
313
323
|
setup(e, { emit: t }) {
|
|
314
|
-
const r = e, n = t, a =
|
|
324
|
+
const r = e, n = t, a = m(() => r.modelValue), i = () => {
|
|
315
325
|
r.disabled || n("update:modelValue", !a.value);
|
|
316
326
|
};
|
|
317
327
|
return J(
|
|
@@ -319,11 +329,11 @@ const br = {
|
|
|
319
329
|
() => {
|
|
320
330
|
n("change", a.value);
|
|
321
331
|
}
|
|
322
|
-
), (
|
|
332
|
+
), (l, o) => (b(), x("div", {
|
|
323
333
|
class: "cregis-checkbox__wrapper",
|
|
324
334
|
onClick: i
|
|
325
335
|
}, [
|
|
326
|
-
|
|
336
|
+
V("div", {
|
|
327
337
|
class: j(["cregis-checkbox", {
|
|
328
338
|
"is-disabled": e.disabled,
|
|
329
339
|
"is-checked": a.value,
|
|
@@ -331,22 +341,22 @@ const br = {
|
|
|
331
341
|
"is-indeterminate": e.indeterminate
|
|
332
342
|
}])
|
|
333
343
|
}, [
|
|
334
|
-
e.indeterminate ? (
|
|
344
|
+
e.indeterminate ? (b(), x("div", Dr)) : (b(), Le(Rr, {
|
|
335
345
|
key: 1,
|
|
336
346
|
size: "10px"
|
|
337
347
|
}))
|
|
338
348
|
], 2),
|
|
339
|
-
|
|
349
|
+
l.$slots.default || e.label ? (b(), x("span", {
|
|
340
350
|
key: 0,
|
|
341
351
|
class: j(["cregis-checkbox__label", { "is-disabled": e.disabled }])
|
|
342
352
|
}, [
|
|
343
|
-
q(
|
|
344
|
-
|
|
353
|
+
q(l.$slots, "default", {}, () => [
|
|
354
|
+
$e(M(e.label), 1)
|
|
345
355
|
])
|
|
346
356
|
], 2)) : I("", !0)
|
|
347
357
|
]));
|
|
348
358
|
}
|
|
349
|
-
}),
|
|
359
|
+
}), ti = /* @__PURE__ */ G({
|
|
350
360
|
name: "Radio",
|
|
351
361
|
__name: "Radio",
|
|
352
362
|
props: {
|
|
@@ -357,32 +367,32 @@ const br = {
|
|
|
357
367
|
},
|
|
358
368
|
emits: ["update:modelValue", "change"],
|
|
359
369
|
setup(e, { emit: t }) {
|
|
360
|
-
const r = e, n = t, a =
|
|
370
|
+
const r = e, n = t, a = m(() => r.modelValue === r.value), i = () => {
|
|
361
371
|
r.disabled || (n("update:modelValue", r.value), n("change", r.value));
|
|
362
372
|
};
|
|
363
|
-
return (
|
|
373
|
+
return (l, o) => (b(), x("div", {
|
|
364
374
|
class: "cregis-radio__wrapper",
|
|
365
375
|
onClick: i
|
|
366
376
|
}, [
|
|
367
|
-
|
|
377
|
+
V("div", {
|
|
368
378
|
class: j(["cregis-radio", {
|
|
369
379
|
"is-disabled": e.disabled,
|
|
370
380
|
"is-checked": a.value
|
|
371
381
|
}])
|
|
372
382
|
}, [...o[0] || (o[0] = [
|
|
373
|
-
|
|
383
|
+
V("div", { class: "cregis-radio__inner" }, null, -1)
|
|
374
384
|
])], 2),
|
|
375
|
-
|
|
385
|
+
l.$slots.default || e.label ? (b(), x("span", {
|
|
376
386
|
key: 0,
|
|
377
387
|
class: j(["cregis-radio__label", { "is-disabled": e.disabled }])
|
|
378
388
|
}, [
|
|
379
|
-
q(
|
|
380
|
-
|
|
389
|
+
q(l.$slots, "default", {}, () => [
|
|
390
|
+
$e(M(e.label), 1)
|
|
381
391
|
])
|
|
382
392
|
], 2)) : I("", !0)
|
|
383
393
|
]));
|
|
384
394
|
}
|
|
385
|
-
}),
|
|
395
|
+
}), ri = /* @__PURE__ */ G({
|
|
386
396
|
name: "Divider",
|
|
387
397
|
__name: "Divider",
|
|
388
398
|
props: {
|
|
@@ -394,13 +404,13 @@ const br = {
|
|
|
394
404
|
length: {}
|
|
395
405
|
},
|
|
396
406
|
setup(e) {
|
|
397
|
-
const t = e, r =
|
|
407
|
+
const t = e, r = m(() => {
|
|
398
408
|
if (Array.isArray(t.margin)) {
|
|
399
409
|
const [a, i] = t.margin;
|
|
400
410
|
return t.direction === "horizontal" ? `${a} 0 ${i} 0` : `0 ${i} 0 ${a}`;
|
|
401
411
|
} else
|
|
402
412
|
return t.direction === "horizontal" ? `${t.margin} 0` : `0 ${t.margin}`;
|
|
403
|
-
}), n =
|
|
413
|
+
}), n = m(() => t.direction === "horizontal" ? {
|
|
404
414
|
width: t.length || "100%",
|
|
405
415
|
borderTopWidth: t.lineThickness,
|
|
406
416
|
borderTopStyle: t.borderStyle,
|
|
@@ -413,14 +423,14 @@ const br = {
|
|
|
413
423
|
borderLeftColor: t.color,
|
|
414
424
|
margin: r.value
|
|
415
425
|
});
|
|
416
|
-
return (a, i) => (
|
|
426
|
+
return (a, i) => (b(), x("div", {
|
|
417
427
|
class: j(["cregis-divider", {
|
|
418
428
|
[`cregis-divider--${e.direction}`]: e.direction
|
|
419
429
|
}]),
|
|
420
|
-
style:
|
|
430
|
+
style: ie(n.value)
|
|
421
431
|
}, null, 6));
|
|
422
432
|
}
|
|
423
|
-
}),
|
|
433
|
+
}), Gt = Symbol("TABS_KEY"), zr = ["onClick"], Wr = { style: { display: "none" } }, ai = /* @__PURE__ */ G({
|
|
424
434
|
name: "Tabs",
|
|
425
435
|
__name: "Tabs",
|
|
426
436
|
props: {
|
|
@@ -430,12 +440,12 @@ const br = {
|
|
|
430
440
|
},
|
|
431
441
|
emits: ["update:modelValue"],
|
|
432
442
|
setup(e) {
|
|
433
|
-
const t = e, r =
|
|
434
|
-
r.some((o) => o.name ===
|
|
435
|
-
}, a = (
|
|
436
|
-
const o = r.findIndex((
|
|
443
|
+
const t = e, r = Me([]), n = (l) => {
|
|
444
|
+
r.some((o) => o.name === l.name) || r.push(l);
|
|
445
|
+
}, a = (l) => {
|
|
446
|
+
const o = r.findIndex((s) => s.name === l);
|
|
437
447
|
o !== -1 && r.splice(o, 1);
|
|
438
|
-
}, i =
|
|
448
|
+
}, i = m(() => t.type === "card" ? t.size === "large" ? {
|
|
439
449
|
borderRadius: "13px"
|
|
440
450
|
} : t.size === "medium" ? {
|
|
441
451
|
borderRadius: "11px"
|
|
@@ -444,30 +454,30 @@ const br = {
|
|
|
444
454
|
} : {
|
|
445
455
|
borderRadius: 0
|
|
446
456
|
});
|
|
447
|
-
return
|
|
448
|
-
activeName:
|
|
457
|
+
return Ht(Gt, {
|
|
458
|
+
activeName: vr(t, "modelValue"),
|
|
449
459
|
registerTab: n,
|
|
450
460
|
unregisterTab: a
|
|
451
|
-
}), (
|
|
461
|
+
}), (l, o) => (b(), x("div", {
|
|
452
462
|
class: j(["cregis-tabs", {
|
|
453
463
|
[`cregis-tabs--${e.type}`]: e.type,
|
|
454
464
|
[`cregis-tabs--${e.size}`]: e.size
|
|
455
465
|
}])
|
|
456
466
|
}, [
|
|
457
|
-
(
|
|
458
|
-
key:
|
|
459
|
-
class: j(["cregis-tabs__item", { "is-active": e.modelValue ===
|
|
460
|
-
style:
|
|
461
|
-
onClick: (d) =>
|
|
467
|
+
(b(!0), x(lt, null, ct(r, (s) => (b(), x("div", {
|
|
468
|
+
key: s.name,
|
|
469
|
+
class: j(["cregis-tabs__item", { "is-active": e.modelValue === s.name }]),
|
|
470
|
+
style: ie(i.value),
|
|
471
|
+
onClick: (d) => l.$emit("update:modelValue", s.name)
|
|
462
472
|
}, [
|
|
463
|
-
|
|
464
|
-
], 14,
|
|
465
|
-
|
|
466
|
-
q(
|
|
473
|
+
V("span", null, M(s.label), 1)
|
|
474
|
+
], 14, zr))), 128)),
|
|
475
|
+
V("div", Wr, [
|
|
476
|
+
q(l.$slots, "default")
|
|
467
477
|
])
|
|
468
478
|
], 2));
|
|
469
479
|
}
|
|
470
|
-
}),
|
|
480
|
+
}), ni = /* @__PURE__ */ G({
|
|
471
481
|
name: "TabPane",
|
|
472
482
|
__name: "TabPane",
|
|
473
483
|
props: {
|
|
@@ -475,25 +485,25 @@ const br = {
|
|
|
475
485
|
name: {}
|
|
476
486
|
},
|
|
477
487
|
setup(e) {
|
|
478
|
-
const t = e, r =
|
|
488
|
+
const t = e, r = qt(Gt);
|
|
479
489
|
if (!r) throw new Error("TabPane must be used within Tabs");
|
|
480
|
-
return
|
|
490
|
+
return et(() => {
|
|
481
491
|
r.registerTab({ label: t.label, name: t.name });
|
|
482
492
|
}), J(
|
|
483
493
|
() => t.label,
|
|
484
494
|
(n) => {
|
|
485
495
|
r.unregisterTab(t.name), r.registerTab({ label: n, name: t.name });
|
|
486
496
|
}
|
|
487
|
-
),
|
|
497
|
+
), Ee(() => {
|
|
488
498
|
r.unregisterTab(t.name);
|
|
489
499
|
}), (n, a) => null;
|
|
490
500
|
}
|
|
491
|
-
}),
|
|
501
|
+
}), Lr = { class: "cregis-message__wrapper" }, jr = {
|
|
492
502
|
key: 0,
|
|
493
503
|
class: "cregis-message",
|
|
494
504
|
role: "status",
|
|
495
505
|
"aria-live": "polite"
|
|
496
|
-
},
|
|
506
|
+
}, Mr = /* @__PURE__ */ G({
|
|
497
507
|
name: "Message",
|
|
498
508
|
__name: "Message",
|
|
499
509
|
props: {
|
|
@@ -502,7 +512,7 @@ const br = {
|
|
|
502
512
|
onVanish: {}
|
|
503
513
|
},
|
|
504
514
|
setup(e) {
|
|
505
|
-
const t = e, r =
|
|
515
|
+
const t = e, r = _(!1);
|
|
506
516
|
let n;
|
|
507
517
|
const a = () => {
|
|
508
518
|
n = window.setTimeout(() => {
|
|
@@ -511,53 +521,53 @@ const br = {
|
|
|
511
521
|
}, i = () => {
|
|
512
522
|
t.onVanish?.();
|
|
513
523
|
};
|
|
514
|
-
return
|
|
524
|
+
return Ut(() => {
|
|
515
525
|
n !== void 0 && clearTimeout(n);
|
|
516
|
-
}),
|
|
526
|
+
}), Ke(() => {
|
|
517
527
|
r.value = !0;
|
|
518
|
-
}), (
|
|
519
|
-
U(
|
|
528
|
+
}), (l, o) => (b(), x("div", Lr, [
|
|
529
|
+
U(vt, {
|
|
520
530
|
name: "cregis-message",
|
|
521
531
|
onAfterEnter: a,
|
|
522
532
|
onAfterLeave: i
|
|
523
533
|
}, {
|
|
524
534
|
default: Z(() => [
|
|
525
|
-
r.value ? (
|
|
535
|
+
r.value ? (b(), x("div", jr, M(e.message), 1)) : I("", !0)
|
|
526
536
|
]),
|
|
527
537
|
_: 1
|
|
528
538
|
})
|
|
529
539
|
]));
|
|
530
540
|
}
|
|
531
541
|
});
|
|
532
|
-
let
|
|
533
|
-
function
|
|
542
|
+
let it = !1;
|
|
543
|
+
function _r(e) {
|
|
534
544
|
return typeof e == "string" ? { message: e, duration: 1e3 } : {
|
|
535
545
|
message: e.message,
|
|
536
546
|
duration: e.duration ?? 1e3
|
|
537
547
|
};
|
|
538
548
|
}
|
|
539
|
-
function
|
|
540
|
-
if (
|
|
541
|
-
const { message: t, duration: r } =
|
|
542
|
-
|
|
549
|
+
function ii(e) {
|
|
550
|
+
if (it) return;
|
|
551
|
+
const { message: t, duration: r } = _r(e);
|
|
552
|
+
it = !0;
|
|
543
553
|
const n = document.createElement("div");
|
|
544
|
-
document.body.appendChild(n),
|
|
545
|
-
|
|
554
|
+
document.body.appendChild(n), Qe(
|
|
555
|
+
Yt(Mr, {
|
|
546
556
|
message: t,
|
|
547
557
|
duration: r,
|
|
548
558
|
onVanish: () => {
|
|
549
|
-
|
|
559
|
+
it = !1, Qe(null, n), n.remove();
|
|
550
560
|
}
|
|
551
561
|
}),
|
|
552
562
|
n
|
|
553
563
|
);
|
|
554
564
|
}
|
|
555
|
-
const
|
|
565
|
+
const Ir = { class: "cregis-notification__wrapper" }, Nr = {
|
|
556
566
|
key: 0,
|
|
557
567
|
class: "cregis-notification",
|
|
558
568
|
role: "status",
|
|
559
569
|
"aria-live": "polite"
|
|
560
|
-
},
|
|
570
|
+
}, Fr = { class: "cregis-notification__content" }, Hr = { class: "cregis-notification__title" }, qr = { class: "cregis-notification__message" }, Ur = /* @__PURE__ */ G({
|
|
561
571
|
name: "Notification",
|
|
562
572
|
__name: "Notification",
|
|
563
573
|
props: {
|
|
@@ -568,35 +578,35 @@ const _r = { class: "cregis-notification__wrapper" }, Ir = {
|
|
|
568
578
|
onVanish: {}
|
|
569
579
|
},
|
|
570
580
|
setup(e) {
|
|
571
|
-
const t = e, r =
|
|
581
|
+
const t = e, r = _(!1), n = () => {
|
|
572
582
|
r.value = !1;
|
|
573
583
|
}, a = () => {
|
|
574
584
|
t.onVanish?.();
|
|
575
585
|
};
|
|
576
|
-
return
|
|
577
|
-
}),
|
|
586
|
+
return Ut(() => {
|
|
587
|
+
}), Ke(() => {
|
|
578
588
|
r.value = !0;
|
|
579
|
-
}), (i,
|
|
580
|
-
U(
|
|
589
|
+
}), (i, l) => (b(), x("div", Ir, [
|
|
590
|
+
U(vt, {
|
|
581
591
|
name: "cregis-notification",
|
|
582
592
|
onAfterLeave: a
|
|
583
593
|
}, {
|
|
584
594
|
default: Z(() => [
|
|
585
|
-
r.value ? (
|
|
586
|
-
(
|
|
595
|
+
r.value ? (b(), x("div", Nr, [
|
|
596
|
+
(b(), Le(Ft(ne(hr)), {
|
|
587
597
|
size: "18px",
|
|
588
598
|
color: "var(--material-vibrant-error-primary)"
|
|
589
599
|
})),
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
600
|
+
V("div", Fr, [
|
|
601
|
+
V("div", Hr, M(e.title), 1),
|
|
602
|
+
V("div", qr, M(e.message), 1)
|
|
593
603
|
]),
|
|
594
|
-
U(
|
|
604
|
+
U(Ye, {
|
|
595
605
|
type: "sameWhite",
|
|
596
606
|
onClick: n
|
|
597
607
|
}, {
|
|
598
608
|
default: Z(() => [
|
|
599
|
-
|
|
609
|
+
$e(M(e.btnText), 1)
|
|
600
610
|
]),
|
|
601
611
|
_: 1
|
|
602
612
|
})
|
|
@@ -607,29 +617,29 @@ const _r = { class: "cregis-notification__wrapper" }, Ir = {
|
|
|
607
617
|
]));
|
|
608
618
|
}
|
|
609
619
|
});
|
|
610
|
-
let
|
|
611
|
-
function
|
|
612
|
-
if (
|
|
620
|
+
let ot = !1;
|
|
621
|
+
function oi(e) {
|
|
622
|
+
if (ot) return;
|
|
613
623
|
const { title: t, message: r, type: n, btnText: a } = e;
|
|
614
|
-
|
|
624
|
+
ot = !0;
|
|
615
625
|
const i = document.createElement("div");
|
|
616
|
-
document.body.appendChild(i),
|
|
617
|
-
|
|
626
|
+
document.body.appendChild(i), Qe(
|
|
627
|
+
Yt(Ur, {
|
|
618
628
|
title: t,
|
|
619
629
|
message: r,
|
|
620
630
|
type: n,
|
|
621
631
|
btnText: a,
|
|
622
632
|
onVanish: () => {
|
|
623
|
-
|
|
633
|
+
ot = !1, Qe(null, i), i.remove();
|
|
624
634
|
}
|
|
625
635
|
}),
|
|
626
636
|
i
|
|
627
637
|
);
|
|
628
638
|
}
|
|
629
|
-
const
|
|
639
|
+
const Yr = { class: "cregis-progress__wrapper" }, Xr = { class: "cregis-progress__track-wrap" }, Kr = { class: "cregis-progress cregis-progress--striped active" }, Qr = {
|
|
630
640
|
key: 0,
|
|
631
641
|
class: "cregis-progress__sliding-block"
|
|
632
|
-
},
|
|
642
|
+
}, si = /* @__PURE__ */ G({
|
|
633
643
|
name: "Progress",
|
|
634
644
|
__name: "Progress",
|
|
635
645
|
props: {
|
|
@@ -638,37 +648,37 @@ const Ur = { class: "cregis-progress__wrapper" }, Xr = { class: "cregis-progress
|
|
|
638
648
|
showPercentage: { type: Boolean, default: !0 }
|
|
639
649
|
},
|
|
640
650
|
setup(e) {
|
|
641
|
-
const t = e, r =
|
|
651
|
+
const t = e, r = m(() => Math.min(100, Math.max(0, t.percentage - 1))), n = m(() => ({
|
|
642
652
|
width: `${t.percentage}%`,
|
|
643
653
|
height: `${t.strokeWidth}px`
|
|
644
|
-
})), a =
|
|
654
|
+
})), a = m(() => ({
|
|
645
655
|
"--cregis-progress-tip-left": `${r.value}%`
|
|
646
|
-
})), i =
|
|
647
|
-
return (
|
|
648
|
-
|
|
649
|
-
e.showPercentage && t.percentage > 0 ? (
|
|
656
|
+
})), i = m(() => `${Math.round(t.percentage)}%`);
|
|
657
|
+
return (l, o) => (b(), x("div", Yr, [
|
|
658
|
+
V("div", Xr, [
|
|
659
|
+
e.showPercentage && t.percentage > 0 ? (b(), x("div", {
|
|
650
660
|
key: 0,
|
|
651
661
|
class: "cregis-progress__tip",
|
|
652
|
-
style:
|
|
662
|
+
style: ie(a.value),
|
|
653
663
|
"aria-live": "polite"
|
|
654
|
-
},
|
|
655
|
-
|
|
656
|
-
|
|
664
|
+
}, M(i.value), 5)) : I("", !0),
|
|
665
|
+
V("div", Kr, [
|
|
666
|
+
V("div", {
|
|
657
667
|
class: "cregis-progress__bar",
|
|
658
|
-
style:
|
|
668
|
+
style: ie(n.value)
|
|
659
669
|
}, null, 4),
|
|
660
|
-
t.percentage === 0 ? (
|
|
670
|
+
t.percentage === 0 ? (b(), x("div", Qr)) : I("", !0)
|
|
661
671
|
])
|
|
662
672
|
])
|
|
663
673
|
]));
|
|
664
674
|
}
|
|
665
675
|
});
|
|
666
|
-
var ee = "top",
|
|
667
|
-
return e.concat([t + "-" +
|
|
668
|
-
}, []),
|
|
669
|
-
return e.concat([t, t + "-" +
|
|
670
|
-
}, []),
|
|
671
|
-
function
|
|
676
|
+
var ee = "top", se = "bottom", le = "right", te = "left", gt = "auto", Ne = [ee, se, le, te], Se = "start", _e = "end", Gr = "clippingParents", Zt = "viewport", Re = "popper", Zr = "reference", Bt = /* @__PURE__ */ Ne.reduce(function(e, t) {
|
|
677
|
+
return e.concat([t + "-" + Se, t + "-" + _e]);
|
|
678
|
+
}, []), Jt = /* @__PURE__ */ [].concat(Ne, [gt]).reduce(function(e, t) {
|
|
679
|
+
return e.concat([t, t + "-" + Se, t + "-" + _e]);
|
|
680
|
+
}, []), Jr = "beforeRead", ea = "read", ta = "afterRead", ra = "beforeMain", aa = "main", na = "afterMain", ia = "beforeWrite", oa = "write", sa = "afterWrite", la = [Jr, ea, ta, ra, aa, na, ia, oa, sa];
|
|
681
|
+
function ve(e) {
|
|
672
682
|
return e ? (e.nodeName || "").toLowerCase() : null;
|
|
673
683
|
}
|
|
674
684
|
function re(e) {
|
|
@@ -684,27 +694,27 @@ function ke(e) {
|
|
|
684
694
|
var t = re(e).Element;
|
|
685
695
|
return e instanceof t || e instanceof Element;
|
|
686
696
|
}
|
|
687
|
-
function
|
|
697
|
+
function oe(e) {
|
|
688
698
|
var t = re(e).HTMLElement;
|
|
689
699
|
return e instanceof t || e instanceof HTMLElement;
|
|
690
700
|
}
|
|
691
|
-
function
|
|
701
|
+
function ht(e) {
|
|
692
702
|
if (typeof ShadowRoot > "u")
|
|
693
703
|
return !1;
|
|
694
704
|
var t = re(e).ShadowRoot;
|
|
695
705
|
return e instanceof t || e instanceof ShadowRoot;
|
|
696
706
|
}
|
|
697
|
-
function
|
|
707
|
+
function ca(e) {
|
|
698
708
|
var t = e.state;
|
|
699
709
|
Object.keys(t.elements).forEach(function(r) {
|
|
700
710
|
var n = t.styles[r] || {}, a = t.attributes[r] || {}, i = t.elements[r];
|
|
701
|
-
!
|
|
702
|
-
var o = a[
|
|
703
|
-
o === !1 ? i.removeAttribute(
|
|
711
|
+
!oe(i) || !ve(i) || (Object.assign(i.style, n), Object.keys(a).forEach(function(l) {
|
|
712
|
+
var o = a[l];
|
|
713
|
+
o === !1 ? i.removeAttribute(l) : i.setAttribute(l, o === !0 ? "" : o);
|
|
704
714
|
}));
|
|
705
715
|
});
|
|
706
716
|
}
|
|
707
|
-
function
|
|
717
|
+
function ua(e) {
|
|
708
718
|
var t = e.state, r = {
|
|
709
719
|
popper: {
|
|
710
720
|
position: t.options.strategy,
|
|
@@ -719,41 +729,41 @@ function ca(e) {
|
|
|
719
729
|
};
|
|
720
730
|
return Object.assign(t.elements.popper.style, r.popper), t.styles = r, t.elements.arrow && Object.assign(t.elements.arrow.style, r.arrow), function() {
|
|
721
731
|
Object.keys(t.elements).forEach(function(n) {
|
|
722
|
-
var a = t.elements[n], i = t.attributes[n] || {},
|
|
723
|
-
return
|
|
732
|
+
var a = t.elements[n], i = t.attributes[n] || {}, l = Object.keys(t.styles.hasOwnProperty(n) ? t.styles[n] : r[n]), o = l.reduce(function(s, d) {
|
|
733
|
+
return s[d] = "", s;
|
|
724
734
|
}, {});
|
|
725
|
-
!
|
|
726
|
-
a.removeAttribute(
|
|
735
|
+
!oe(a) || !ve(a) || (Object.assign(a.style, o), Object.keys(i).forEach(function(s) {
|
|
736
|
+
a.removeAttribute(s);
|
|
727
737
|
}));
|
|
728
738
|
});
|
|
729
739
|
};
|
|
730
740
|
}
|
|
731
|
-
const
|
|
741
|
+
const da = {
|
|
732
742
|
name: "applyStyles",
|
|
733
743
|
enabled: !0,
|
|
734
744
|
phase: "write",
|
|
735
|
-
fn:
|
|
736
|
-
effect:
|
|
745
|
+
fn: ca,
|
|
746
|
+
effect: ua,
|
|
737
747
|
requires: ["computeStyles"]
|
|
738
748
|
};
|
|
739
|
-
function
|
|
749
|
+
function pe(e) {
|
|
740
750
|
return e.split("-")[0];
|
|
741
751
|
}
|
|
742
|
-
var
|
|
743
|
-
function
|
|
752
|
+
var Oe = Math.max, Ge = Math.min, Ce = Math.round;
|
|
753
|
+
function ut() {
|
|
744
754
|
var e = navigator.userAgentData;
|
|
745
755
|
return e != null && e.brands && Array.isArray(e.brands) ? e.brands.map(function(t) {
|
|
746
756
|
return t.brand + "/" + t.version;
|
|
747
757
|
}).join(" ") : navigator.userAgent;
|
|
748
758
|
}
|
|
749
|
-
function
|
|
750
|
-
return !/^((?!chrome|android).)*safari/i.test(
|
|
759
|
+
function er() {
|
|
760
|
+
return !/^((?!chrome|android).)*safari/i.test(ut());
|
|
751
761
|
}
|
|
752
762
|
function Pe(e, t, r) {
|
|
753
763
|
t === void 0 && (t = !1), r === void 0 && (r = !1);
|
|
754
764
|
var n = e.getBoundingClientRect(), a = 1, i = 1;
|
|
755
|
-
t &&
|
|
756
|
-
var
|
|
765
|
+
t && oe(e) && (a = e.offsetWidth > 0 && Ce(n.width) / e.offsetWidth || 1, i = e.offsetHeight > 0 && Ce(n.height) / e.offsetHeight || 1);
|
|
766
|
+
var l = ke(e) ? re(e) : window, o = l.visualViewport, s = !er() && r, d = (n.left + (s && o ? o.offsetLeft : 0)) / a, c = (n.top + (s && o ? o.offsetTop : 0)) / i, w = n.width / a, k = n.height / i;
|
|
757
767
|
return {
|
|
758
768
|
width: w,
|
|
759
769
|
height: k,
|
|
@@ -765,7 +775,7 @@ function Pe(e, t, r) {
|
|
|
765
775
|
y: c
|
|
766
776
|
};
|
|
767
777
|
}
|
|
768
|
-
function
|
|
778
|
+
function bt(e) {
|
|
769
779
|
var t = Pe(e), r = e.offsetWidth, n = e.offsetHeight;
|
|
770
780
|
return Math.abs(t.width - r) <= 1 && (r = t.width), Math.abs(t.height - n) <= 1 && (n = t.height), {
|
|
771
781
|
x: e.offsetLeft,
|
|
@@ -774,11 +784,11 @@ function ht(e) {
|
|
|
774
784
|
height: n
|
|
775
785
|
};
|
|
776
786
|
}
|
|
777
|
-
function
|
|
787
|
+
function tr(e, t) {
|
|
778
788
|
var r = t.getRootNode && t.getRootNode();
|
|
779
789
|
if (e.contains(t))
|
|
780
790
|
return !0;
|
|
781
|
-
if (r &&
|
|
791
|
+
if (r && ht(r)) {
|
|
782
792
|
var n = t;
|
|
783
793
|
do {
|
|
784
794
|
if (n && e.isSameNode(n))
|
|
@@ -791,8 +801,8 @@ function Jt(e, t) {
|
|
|
791
801
|
function ge(e) {
|
|
792
802
|
return re(e).getComputedStyle(e);
|
|
793
803
|
}
|
|
794
|
-
function
|
|
795
|
-
return ["table", "td", "th"].indexOf(
|
|
804
|
+
function fa(e) {
|
|
805
|
+
return ["table", "td", "th"].indexOf(ve(e)) >= 0;
|
|
796
806
|
}
|
|
797
807
|
function be(e) {
|
|
798
808
|
return ((ke(e) ? e.ownerDocument : (
|
|
@@ -800,31 +810,31 @@ function be(e) {
|
|
|
800
810
|
e.document
|
|
801
811
|
)) || window.document).documentElement;
|
|
802
812
|
}
|
|
803
|
-
function
|
|
804
|
-
return
|
|
813
|
+
function tt(e) {
|
|
814
|
+
return ve(e) === "html" ? e : (
|
|
805
815
|
// this is a quicker (but less type safe) way to save quite some bytes from the bundle
|
|
806
816
|
// $FlowFixMe[incompatible-return]
|
|
807
817
|
// $FlowFixMe[prop-missing]
|
|
808
818
|
e.assignedSlot || // step into the shadow DOM of the parent of a slotted node
|
|
809
819
|
e.parentNode || // DOM Element detected
|
|
810
|
-
(
|
|
820
|
+
(ht(e) ? e.host : null) || // ShadowRoot detected
|
|
811
821
|
// $FlowFixMe[incompatible-call]: HTMLElement is a Node
|
|
812
822
|
be(e)
|
|
813
823
|
);
|
|
814
824
|
}
|
|
815
|
-
function
|
|
816
|
-
return !
|
|
825
|
+
function At(e) {
|
|
826
|
+
return !oe(e) || // https://github.com/popperjs/popper-core/issues/837
|
|
817
827
|
ge(e).position === "fixed" ? null : e.offsetParent;
|
|
818
828
|
}
|
|
819
|
-
function
|
|
820
|
-
var t = /firefox/i.test(
|
|
821
|
-
if (r &&
|
|
829
|
+
function pa(e) {
|
|
830
|
+
var t = /firefox/i.test(ut()), r = /Trident/i.test(ut());
|
|
831
|
+
if (r && oe(e)) {
|
|
822
832
|
var n = ge(e);
|
|
823
833
|
if (n.position === "fixed")
|
|
824
834
|
return null;
|
|
825
835
|
}
|
|
826
|
-
var a =
|
|
827
|
-
for (
|
|
836
|
+
var a = tt(e);
|
|
837
|
+
for (ht(a) && (a = a.host); oe(a) && ["html", "body"].indexOf(ve(a)) < 0; ) {
|
|
828
838
|
var i = ge(a);
|
|
829
839
|
if (i.transform !== "none" || i.perspective !== "none" || i.contain === "paint" || ["transform", "perspective"].indexOf(i.willChange) !== -1 || t && i.willChange === "filter" || t && i.filter && i.filter !== "none")
|
|
830
840
|
return a;
|
|
@@ -832,22 +842,22 @@ function fa(e) {
|
|
|
832
842
|
}
|
|
833
843
|
return null;
|
|
834
844
|
}
|
|
835
|
-
function
|
|
836
|
-
for (var t = re(e), r =
|
|
837
|
-
r =
|
|
838
|
-
return r && (
|
|
845
|
+
function Fe(e) {
|
|
846
|
+
for (var t = re(e), r = At(e); r && fa(r) && ge(r).position === "static"; )
|
|
847
|
+
r = At(r);
|
|
848
|
+
return r && (ve(r) === "html" || ve(r) === "body" && ge(r).position === "static") ? t : r || pa(e) || t;
|
|
839
849
|
}
|
|
840
|
-
function
|
|
850
|
+
function yt(e) {
|
|
841
851
|
return ["top", "bottom"].indexOf(e) >= 0 ? "x" : "y";
|
|
842
852
|
}
|
|
843
|
-
function
|
|
844
|
-
return
|
|
853
|
+
function ze(e, t, r) {
|
|
854
|
+
return Oe(e, Ge(t, r));
|
|
845
855
|
}
|
|
846
|
-
function
|
|
847
|
-
var n =
|
|
856
|
+
function va(e, t, r) {
|
|
857
|
+
var n = ze(e, t, r);
|
|
848
858
|
return n > r ? r : n;
|
|
849
859
|
}
|
|
850
|
-
function
|
|
860
|
+
function rr() {
|
|
851
861
|
return {
|
|
852
862
|
top: 0,
|
|
853
863
|
right: 0,
|
|
@@ -855,143 +865,143 @@ function er() {
|
|
|
855
865
|
left: 0
|
|
856
866
|
};
|
|
857
867
|
}
|
|
858
|
-
function
|
|
859
|
-
return Object.assign({},
|
|
868
|
+
function ar(e) {
|
|
869
|
+
return Object.assign({}, rr(), e);
|
|
860
870
|
}
|
|
861
|
-
function
|
|
871
|
+
function nr(e, t) {
|
|
862
872
|
return t.reduce(function(r, n) {
|
|
863
873
|
return r[n] = e, r;
|
|
864
874
|
}, {});
|
|
865
875
|
}
|
|
866
|
-
var
|
|
876
|
+
var ma = function(t, r) {
|
|
867
877
|
return t = typeof t == "function" ? t(Object.assign({}, r.rects, {
|
|
868
878
|
placement: r.placement
|
|
869
|
-
})) : t,
|
|
879
|
+
})) : t, ar(typeof t != "number" ? t : nr(t, Ne));
|
|
870
880
|
};
|
|
871
|
-
function
|
|
872
|
-
var t, r = e.state, n = e.name, a = e.options, i = r.elements.arrow,
|
|
873
|
-
if (!(!i || !
|
|
874
|
-
var w =
|
|
881
|
+
function ga(e) {
|
|
882
|
+
var t, r = e.state, n = e.name, a = e.options, i = r.elements.arrow, l = r.modifiersData.popperOffsets, o = pe(r.placement), s = yt(o), d = [te, le].indexOf(o) >= 0, c = d ? "height" : "width";
|
|
883
|
+
if (!(!i || !l)) {
|
|
884
|
+
var w = ma(a.padding, r), k = bt(i), v = s === "y" ? ee : te, S = s === "y" ? se : le, O = r.rects.reference[c] + r.rects.reference[s] - l[s] - r.rects.popper[c], $ = l[s] - r.rects.reference[s], C = Fe(i), E = C ? s === "y" ? C.clientHeight || 0 : C.clientWidth || 0 : 0, R = O / 2 - $ / 2, f = w[v], g = E - k[c] - w[S], u = E / 2 - k[c] / 2 + R, T = ze(f, u, g), B = s;
|
|
875
885
|
r.modifiersData[n] = (t = {}, t[B] = T, t.centerOffset = T - u, t);
|
|
876
886
|
}
|
|
877
887
|
}
|
|
878
|
-
function
|
|
888
|
+
function ha(e) {
|
|
879
889
|
var t = e.state, r = e.options, n = r.element, a = n === void 0 ? "[data-popper-arrow]" : n;
|
|
880
|
-
a != null && (typeof a == "string" && (a = t.elements.popper.querySelector(a), !a) ||
|
|
890
|
+
a != null && (typeof a == "string" && (a = t.elements.popper.querySelector(a), !a) || tr(t.elements.popper, a) && (t.elements.arrow = a));
|
|
881
891
|
}
|
|
882
|
-
const
|
|
892
|
+
const ba = {
|
|
883
893
|
name: "arrow",
|
|
884
894
|
enabled: !0,
|
|
885
895
|
phase: "main",
|
|
886
|
-
fn:
|
|
887
|
-
effect:
|
|
896
|
+
fn: ga,
|
|
897
|
+
effect: ha,
|
|
888
898
|
requires: ["popperOffsets"],
|
|
889
899
|
requiresIfExists: ["preventOverflow"]
|
|
890
900
|
};
|
|
891
|
-
function
|
|
901
|
+
function Ve(e) {
|
|
892
902
|
return e.split("-")[1];
|
|
893
903
|
}
|
|
894
|
-
var
|
|
904
|
+
var ya = {
|
|
895
905
|
top: "auto",
|
|
896
906
|
right: "auto",
|
|
897
907
|
bottom: "auto",
|
|
898
908
|
left: "auto"
|
|
899
909
|
};
|
|
900
|
-
function
|
|
910
|
+
function wa(e, t) {
|
|
901
911
|
var r = e.x, n = e.y, a = t.devicePixelRatio || 1;
|
|
902
912
|
return {
|
|
903
|
-
x:
|
|
904
|
-
y:
|
|
913
|
+
x: Ce(r * a) / a || 0,
|
|
914
|
+
y: Ce(n * a) / a || 0
|
|
905
915
|
};
|
|
906
916
|
}
|
|
907
|
-
function
|
|
908
|
-
var t, r = e.popper, n = e.popperRect, a = e.placement, i = e.variation,
|
|
917
|
+
function Rt(e) {
|
|
918
|
+
var t, r = e.popper, n = e.popperRect, a = e.placement, i = e.variation, l = e.offsets, o = e.position, s = e.gpuAcceleration, d = e.adaptive, c = e.roundOffsets, w = e.isFixed, k = l.x, v = k === void 0 ? 0 : k, S = l.y, O = S === void 0 ? 0 : S, $ = typeof c == "function" ? c({
|
|
909
919
|
x: v,
|
|
910
|
-
y:
|
|
920
|
+
y: O
|
|
911
921
|
}) : {
|
|
912
922
|
x: v,
|
|
913
|
-
y:
|
|
923
|
+
y: O
|
|
914
924
|
};
|
|
915
|
-
v = $.x,
|
|
916
|
-
var
|
|
925
|
+
v = $.x, O = $.y;
|
|
926
|
+
var C = l.hasOwnProperty("x"), E = l.hasOwnProperty("y"), R = te, f = ee, g = window;
|
|
917
927
|
if (d) {
|
|
918
|
-
var u =
|
|
919
|
-
if (u === re(r) && (u = be(r), ge(u).position !== "static" && o === "absolute" && (T = "scrollHeight", B = "scrollWidth")), u = u, a === ee || (a === te || a ===
|
|
920
|
-
f =
|
|
921
|
-
var D = w && u ===
|
|
928
|
+
var u = Fe(r), T = "clientHeight", B = "clientWidth";
|
|
929
|
+
if (u === re(r) && (u = be(r), ge(u).position !== "static" && o === "absolute" && (T = "scrollHeight", B = "scrollWidth")), u = u, a === ee || (a === te || a === le) && i === _e) {
|
|
930
|
+
f = se;
|
|
931
|
+
var D = w && u === g && g.visualViewport ? g.visualViewport.height : (
|
|
922
932
|
// $FlowFixMe[prop-missing]
|
|
923
933
|
u[T]
|
|
924
934
|
);
|
|
925
|
-
|
|
935
|
+
O -= D - n.height, O *= s ? 1 : -1;
|
|
926
936
|
}
|
|
927
|
-
if (a === te || (a === ee || a ===
|
|
928
|
-
|
|
929
|
-
var W = w && u ===
|
|
937
|
+
if (a === te || (a === ee || a === se) && i === _e) {
|
|
938
|
+
R = le;
|
|
939
|
+
var W = w && u === g && g.visualViewport ? g.visualViewport.width : (
|
|
930
940
|
// $FlowFixMe[prop-missing]
|
|
931
941
|
u[B]
|
|
932
942
|
);
|
|
933
|
-
v -= W - n.width, v *=
|
|
943
|
+
v -= W - n.width, v *= s ? 1 : -1;
|
|
934
944
|
}
|
|
935
945
|
}
|
|
936
|
-
var
|
|
946
|
+
var y = Object.assign({
|
|
937
947
|
position: o
|
|
938
|
-
}, d &&
|
|
948
|
+
}, d && ya), A = c === !0 ? wa({
|
|
939
949
|
x: v,
|
|
940
|
-
y:
|
|
950
|
+
y: O
|
|
941
951
|
}, re(r)) : {
|
|
942
952
|
x: v,
|
|
943
|
-
y:
|
|
953
|
+
y: O
|
|
944
954
|
};
|
|
945
|
-
if (v =
|
|
955
|
+
if (v = A.x, O = A.y, s) {
|
|
946
956
|
var z;
|
|
947
|
-
return Object.assign({},
|
|
957
|
+
return Object.assign({}, y, (z = {}, z[f] = E ? "0" : "", z[R] = C ? "0" : "", z.transform = (g.devicePixelRatio || 1) <= 1 ? "translate(" + v + "px, " + O + "px)" : "translate3d(" + v + "px, " + O + "px, 0)", z));
|
|
948
958
|
}
|
|
949
|
-
return Object.assign({},
|
|
959
|
+
return Object.assign({}, y, (t = {}, t[f] = E ? O + "px" : "", t[R] = C ? v + "px" : "", t.transform = "", t));
|
|
950
960
|
}
|
|
951
|
-
function
|
|
952
|
-
var t = e.state, r = e.options, n = r.gpuAcceleration, a = n === void 0 ? !0 : n, i = r.adaptive,
|
|
953
|
-
placement:
|
|
954
|
-
variation:
|
|
961
|
+
function xa(e) {
|
|
962
|
+
var t = e.state, r = e.options, n = r.gpuAcceleration, a = n === void 0 ? !0 : n, i = r.adaptive, l = i === void 0 ? !0 : i, o = r.roundOffsets, s = o === void 0 ? !0 : o, d = {
|
|
963
|
+
placement: pe(t.placement),
|
|
964
|
+
variation: Ve(t.placement),
|
|
955
965
|
popper: t.elements.popper,
|
|
956
966
|
popperRect: t.rects.popper,
|
|
957
967
|
gpuAcceleration: a,
|
|
958
968
|
isFixed: t.options.strategy === "fixed"
|
|
959
969
|
};
|
|
960
|
-
t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper,
|
|
970
|
+
t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper, Rt(Object.assign({}, d, {
|
|
961
971
|
offsets: t.modifiersData.popperOffsets,
|
|
962
972
|
position: t.options.strategy,
|
|
963
|
-
adaptive:
|
|
964
|
-
roundOffsets:
|
|
965
|
-
})))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow,
|
|
973
|
+
adaptive: l,
|
|
974
|
+
roundOffsets: s
|
|
975
|
+
})))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow, Rt(Object.assign({}, d, {
|
|
966
976
|
offsets: t.modifiersData.arrow,
|
|
967
977
|
position: "absolute",
|
|
968
978
|
adaptive: !1,
|
|
969
|
-
roundOffsets:
|
|
979
|
+
roundOffsets: s
|
|
970
980
|
})))), t.attributes.popper = Object.assign({}, t.attributes.popper, {
|
|
971
981
|
"data-popper-placement": t.placement
|
|
972
982
|
});
|
|
973
983
|
}
|
|
974
|
-
const
|
|
984
|
+
const Oa = {
|
|
975
985
|
name: "computeStyles",
|
|
976
986
|
enabled: !0,
|
|
977
987
|
phase: "beforeWrite",
|
|
978
|
-
fn:
|
|
988
|
+
fn: xa,
|
|
979
989
|
data: {}
|
|
980
990
|
};
|
|
981
|
-
var
|
|
991
|
+
var Ue = {
|
|
982
992
|
passive: !0
|
|
983
993
|
};
|
|
984
994
|
function $a(e) {
|
|
985
|
-
var t = e.state, r = e.instance, n = e.options, a = n.scroll, i = a === void 0 ? !0 : a,
|
|
995
|
+
var t = e.state, r = e.instance, n = e.options, a = n.scroll, i = a === void 0 ? !0 : a, l = n.resize, o = l === void 0 ? !0 : l, s = re(t.elements.popper), d = [].concat(t.scrollParents.reference, t.scrollParents.popper);
|
|
986
996
|
return i && d.forEach(function(c) {
|
|
987
|
-
c.addEventListener("scroll", r.update,
|
|
988
|
-
}), o &&
|
|
997
|
+
c.addEventListener("scroll", r.update, Ue);
|
|
998
|
+
}), o && s.addEventListener("resize", r.update, Ue), function() {
|
|
989
999
|
i && d.forEach(function(c) {
|
|
990
|
-
c.removeEventListener("scroll", r.update,
|
|
991
|
-
}), o &&
|
|
1000
|
+
c.removeEventListener("scroll", r.update, Ue);
|
|
1001
|
+
}), o && s.removeEventListener("resize", r.update, Ue);
|
|
992
1002
|
};
|
|
993
1003
|
}
|
|
994
|
-
const
|
|
1004
|
+
const ka = {
|
|
995
1005
|
name: "eventListeners",
|
|
996
1006
|
enabled: !0,
|
|
997
1007
|
phase: "write",
|
|
@@ -1000,7 +1010,7 @@ const Oa = {
|
|
|
1000
1010
|
effect: $a,
|
|
1001
1011
|
data: {}
|
|
1002
1012
|
};
|
|
1003
|
-
var
|
|
1013
|
+
var Ta = {
|
|
1004
1014
|
left: "right",
|
|
1005
1015
|
right: "left",
|
|
1006
1016
|
bottom: "top",
|
|
@@ -1008,68 +1018,68 @@ var ka = {
|
|
|
1008
1018
|
};
|
|
1009
1019
|
function Xe(e) {
|
|
1010
1020
|
return e.replace(/left|right|bottom|top/g, function(t) {
|
|
1011
|
-
return
|
|
1021
|
+
return Ta[t];
|
|
1012
1022
|
});
|
|
1013
1023
|
}
|
|
1014
|
-
var
|
|
1024
|
+
var Sa = {
|
|
1015
1025
|
start: "end",
|
|
1016
1026
|
end: "start"
|
|
1017
1027
|
};
|
|
1018
|
-
function
|
|
1028
|
+
function Dt(e) {
|
|
1019
1029
|
return e.replace(/start|end/g, function(t) {
|
|
1020
|
-
return
|
|
1030
|
+
return Sa[t];
|
|
1021
1031
|
});
|
|
1022
1032
|
}
|
|
1023
|
-
function
|
|
1033
|
+
function wt(e) {
|
|
1024
1034
|
var t = re(e), r = t.pageXOffset, n = t.pageYOffset;
|
|
1025
1035
|
return {
|
|
1026
1036
|
scrollLeft: r,
|
|
1027
1037
|
scrollTop: n
|
|
1028
1038
|
};
|
|
1029
1039
|
}
|
|
1030
|
-
function
|
|
1031
|
-
return Pe(be(e)).left +
|
|
1040
|
+
function xt(e) {
|
|
1041
|
+
return Pe(be(e)).left + wt(e).scrollLeft;
|
|
1032
1042
|
}
|
|
1033
1043
|
function Ca(e, t) {
|
|
1034
|
-
var r = re(e), n = be(e), a = r.visualViewport, i = n.clientWidth,
|
|
1044
|
+
var r = re(e), n = be(e), a = r.visualViewport, i = n.clientWidth, l = n.clientHeight, o = 0, s = 0;
|
|
1035
1045
|
if (a) {
|
|
1036
|
-
i = a.width,
|
|
1037
|
-
var d =
|
|
1038
|
-
(d || !d && t === "fixed") && (o = a.offsetLeft,
|
|
1046
|
+
i = a.width, l = a.height;
|
|
1047
|
+
var d = er();
|
|
1048
|
+
(d || !d && t === "fixed") && (o = a.offsetLeft, s = a.offsetTop);
|
|
1039
1049
|
}
|
|
1040
1050
|
return {
|
|
1041
1051
|
width: i,
|
|
1042
|
-
height:
|
|
1043
|
-
x: o +
|
|
1044
|
-
y:
|
|
1052
|
+
height: l,
|
|
1053
|
+
x: o + xt(e),
|
|
1054
|
+
y: s
|
|
1045
1055
|
};
|
|
1046
1056
|
}
|
|
1047
|
-
function
|
|
1048
|
-
var t, r = be(e), n =
|
|
1049
|
-
return ge(a || r).direction === "rtl" && (o +=
|
|
1057
|
+
function Pa(e) {
|
|
1058
|
+
var t, r = be(e), n = wt(e), a = (t = e.ownerDocument) == null ? void 0 : t.body, i = Oe(r.scrollWidth, r.clientWidth, a ? a.scrollWidth : 0, a ? a.clientWidth : 0), l = Oe(r.scrollHeight, r.clientHeight, a ? a.scrollHeight : 0, a ? a.clientHeight : 0), o = -n.scrollLeft + xt(e), s = -n.scrollTop;
|
|
1059
|
+
return ge(a || r).direction === "rtl" && (o += Oe(r.clientWidth, a ? a.clientWidth : 0) - i), {
|
|
1050
1060
|
width: i,
|
|
1051
|
-
height:
|
|
1061
|
+
height: l,
|
|
1052
1062
|
x: o,
|
|
1053
|
-
y:
|
|
1063
|
+
y: s
|
|
1054
1064
|
};
|
|
1055
1065
|
}
|
|
1056
|
-
function
|
|
1066
|
+
function Ot(e) {
|
|
1057
1067
|
var t = ge(e), r = t.overflow, n = t.overflowX, a = t.overflowY;
|
|
1058
1068
|
return /auto|scroll|overlay|hidden/.test(r + a + n);
|
|
1059
1069
|
}
|
|
1060
|
-
function
|
|
1061
|
-
return ["html", "body", "#document"].indexOf(
|
|
1070
|
+
function ir(e) {
|
|
1071
|
+
return ["html", "body", "#document"].indexOf(ve(e)) >= 0 ? e.ownerDocument.body : oe(e) && Ot(e) ? e : ir(tt(e));
|
|
1062
1072
|
}
|
|
1063
|
-
function
|
|
1073
|
+
function We(e, t) {
|
|
1064
1074
|
var r;
|
|
1065
1075
|
t === void 0 && (t = []);
|
|
1066
|
-
var n =
|
|
1076
|
+
var n = ir(e), a = n === ((r = e.ownerDocument) == null ? void 0 : r.body), i = re(n), l = a ? [i].concat(i.visualViewport || [], Ot(n) ? n : []) : n, o = t.concat(l);
|
|
1067
1077
|
return a ? o : (
|
|
1068
1078
|
// $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
|
|
1069
|
-
o.concat(
|
|
1079
|
+
o.concat(We(tt(l)))
|
|
1070
1080
|
);
|
|
1071
1081
|
}
|
|
1072
|
-
function
|
|
1082
|
+
function dt(e) {
|
|
1073
1083
|
return Object.assign({}, e, {
|
|
1074
1084
|
left: e.x,
|
|
1075
1085
|
top: e.y,
|
|
@@ -1077,179 +1087,179 @@ function ut(e) {
|
|
|
1077
1087
|
bottom: e.y + e.height
|
|
1078
1088
|
});
|
|
1079
1089
|
}
|
|
1080
|
-
function
|
|
1090
|
+
function Va(e, t) {
|
|
1081
1091
|
var r = Pe(e, !1, t === "fixed");
|
|
1082
1092
|
return r.top = r.top + e.clientTop, r.left = r.left + e.clientLeft, r.bottom = r.top + e.clientHeight, r.right = r.left + e.clientWidth, r.width = e.clientWidth, r.height = e.clientHeight, r.x = r.left, r.y = r.top, r;
|
|
1083
1093
|
}
|
|
1084
|
-
function
|
|
1085
|
-
return t ===
|
|
1094
|
+
function zt(e, t, r) {
|
|
1095
|
+
return t === Zt ? dt(Ca(e, r)) : ke(t) ? Va(t, r) : dt(Pa(be(e)));
|
|
1086
1096
|
}
|
|
1087
1097
|
function Ea(e) {
|
|
1088
|
-
var t =
|
|
1098
|
+
var t = We(tt(e)), r = ["absolute", "fixed"].indexOf(ge(e).position) >= 0, n = r && oe(e) ? Fe(e) : e;
|
|
1089
1099
|
return ke(n) ? t.filter(function(a) {
|
|
1090
|
-
return ke(a) &&
|
|
1100
|
+
return ke(a) && tr(a, n) && ve(a) !== "body";
|
|
1091
1101
|
}) : [];
|
|
1092
1102
|
}
|
|
1093
|
-
function
|
|
1094
|
-
var a = t === "clippingParents" ? Ea(e) : [].concat(t), i = [].concat(a, [r]),
|
|
1095
|
-
var c =
|
|
1096
|
-
return
|
|
1097
|
-
},
|
|
1103
|
+
function Ba(e, t, r, n) {
|
|
1104
|
+
var a = t === "clippingParents" ? Ea(e) : [].concat(t), i = [].concat(a, [r]), l = i[0], o = i.reduce(function(s, d) {
|
|
1105
|
+
var c = zt(e, d, n);
|
|
1106
|
+
return s.top = Oe(c.top, s.top), s.right = Ge(c.right, s.right), s.bottom = Ge(c.bottom, s.bottom), s.left = Oe(c.left, s.left), s;
|
|
1107
|
+
}, zt(e, l, n));
|
|
1098
1108
|
return o.width = o.right - o.left, o.height = o.bottom - o.top, o.x = o.left, o.y = o.top, o;
|
|
1099
1109
|
}
|
|
1100
|
-
function
|
|
1101
|
-
var t = e.reference, r = e.element, n = e.placement, a = n ?
|
|
1110
|
+
function or(e) {
|
|
1111
|
+
var t = e.reference, r = e.element, n = e.placement, a = n ? pe(n) : null, i = n ? Ve(n) : null, l = t.x + t.width / 2 - r.width / 2, o = t.y + t.height / 2 - r.height / 2, s;
|
|
1102
1112
|
switch (a) {
|
|
1103
1113
|
case ee:
|
|
1104
|
-
|
|
1105
|
-
x:
|
|
1114
|
+
s = {
|
|
1115
|
+
x: l,
|
|
1106
1116
|
y: t.y - r.height
|
|
1107
1117
|
};
|
|
1108
1118
|
break;
|
|
1109
|
-
case
|
|
1110
|
-
|
|
1111
|
-
x:
|
|
1119
|
+
case se:
|
|
1120
|
+
s = {
|
|
1121
|
+
x: l,
|
|
1112
1122
|
y: t.y + t.height
|
|
1113
1123
|
};
|
|
1114
1124
|
break;
|
|
1115
|
-
case
|
|
1116
|
-
|
|
1125
|
+
case le:
|
|
1126
|
+
s = {
|
|
1117
1127
|
x: t.x + t.width,
|
|
1118
1128
|
y: o
|
|
1119
1129
|
};
|
|
1120
1130
|
break;
|
|
1121
1131
|
case te:
|
|
1122
|
-
|
|
1132
|
+
s = {
|
|
1123
1133
|
x: t.x - r.width,
|
|
1124
1134
|
y: o
|
|
1125
1135
|
};
|
|
1126
1136
|
break;
|
|
1127
1137
|
default:
|
|
1128
|
-
|
|
1138
|
+
s = {
|
|
1129
1139
|
x: t.x,
|
|
1130
1140
|
y: t.y
|
|
1131
1141
|
};
|
|
1132
1142
|
}
|
|
1133
|
-
var d = a ?
|
|
1143
|
+
var d = a ? yt(a) : null;
|
|
1134
1144
|
if (d != null) {
|
|
1135
1145
|
var c = d === "y" ? "height" : "width";
|
|
1136
1146
|
switch (i) {
|
|
1137
|
-
case
|
|
1138
|
-
|
|
1147
|
+
case Se:
|
|
1148
|
+
s[d] = s[d] - (t[c] / 2 - r[c] / 2);
|
|
1139
1149
|
break;
|
|
1140
|
-
case
|
|
1141
|
-
|
|
1150
|
+
case _e:
|
|
1151
|
+
s[d] = s[d] + (t[c] / 2 - r[c] / 2);
|
|
1142
1152
|
break;
|
|
1143
1153
|
}
|
|
1144
1154
|
}
|
|
1145
|
-
return
|
|
1155
|
+
return s;
|
|
1146
1156
|
}
|
|
1147
|
-
function
|
|
1157
|
+
function Ie(e, t) {
|
|
1148
1158
|
t === void 0 && (t = {});
|
|
1149
|
-
var r = t, n = r.placement, a = n === void 0 ? e.placement : n, i = r.strategy,
|
|
1159
|
+
var r = t, n = r.placement, a = n === void 0 ? e.placement : n, i = r.strategy, l = i === void 0 ? e.strategy : i, o = r.boundary, s = o === void 0 ? Gr : o, d = r.rootBoundary, c = d === void 0 ? Zt : d, w = r.elementContext, k = w === void 0 ? Re : w, v = r.altBoundary, S = v === void 0 ? !1 : v, O = r.padding, $ = O === void 0 ? 0 : O, C = ar(typeof $ != "number" ? $ : nr($, Ne)), E = k === Re ? Zr : Re, R = e.rects.popper, f = e.elements[S ? E : k], g = Ba(ke(f) ? f : f.contextElement || be(e.elements.popper), s, c, l), u = Pe(e.elements.reference), T = or({
|
|
1150
1160
|
reference: u,
|
|
1151
|
-
element:
|
|
1161
|
+
element: R,
|
|
1152
1162
|
placement: a
|
|
1153
|
-
}), B =
|
|
1154
|
-
top:
|
|
1155
|
-
bottom: D.bottom -
|
|
1156
|
-
left:
|
|
1157
|
-
right: D.right -
|
|
1158
|
-
},
|
|
1159
|
-
if (k === Re &&
|
|
1160
|
-
var
|
|
1163
|
+
}), B = dt(Object.assign({}, R, T)), D = k === Re ? B : u, W = {
|
|
1164
|
+
top: g.top - D.top + C.top,
|
|
1165
|
+
bottom: D.bottom - g.bottom + C.bottom,
|
|
1166
|
+
left: g.left - D.left + C.left,
|
|
1167
|
+
right: D.right - g.right + C.right
|
|
1168
|
+
}, y = e.modifiersData.offset;
|
|
1169
|
+
if (k === Re && y) {
|
|
1170
|
+
var A = y[a];
|
|
1161
1171
|
Object.keys(W).forEach(function(z) {
|
|
1162
|
-
var
|
|
1163
|
-
W[z] +=
|
|
1172
|
+
var Y = [le, se].indexOf(z) >= 0 ? 1 : -1, X = [ee, se].indexOf(z) >= 0 ? "y" : "x";
|
|
1173
|
+
W[z] += A[X] * Y;
|
|
1164
1174
|
});
|
|
1165
1175
|
}
|
|
1166
1176
|
return W;
|
|
1167
1177
|
}
|
|
1168
|
-
function
|
|
1178
|
+
function Aa(e, t) {
|
|
1169
1179
|
t === void 0 && (t = {});
|
|
1170
|
-
var r = t, n = r.placement, a = r.boundary, i = r.rootBoundary,
|
|
1171
|
-
return
|
|
1172
|
-
}) :
|
|
1173
|
-
return d.indexOf(
|
|
1180
|
+
var r = t, n = r.placement, a = r.boundary, i = r.rootBoundary, l = r.padding, o = r.flipVariations, s = r.allowedAutoPlacements, d = s === void 0 ? Jt : s, c = Ve(n), w = c ? o ? Bt : Bt.filter(function(S) {
|
|
1181
|
+
return Ve(S) === c;
|
|
1182
|
+
}) : Ne, k = w.filter(function(S) {
|
|
1183
|
+
return d.indexOf(S) >= 0;
|
|
1174
1184
|
});
|
|
1175
1185
|
k.length === 0 && (k = w);
|
|
1176
|
-
var v = k.reduce(function(
|
|
1177
|
-
return
|
|
1178
|
-
placement:
|
|
1186
|
+
var v = k.reduce(function(S, O) {
|
|
1187
|
+
return S[O] = Ie(e, {
|
|
1188
|
+
placement: O,
|
|
1179
1189
|
boundary: a,
|
|
1180
1190
|
rootBoundary: i,
|
|
1181
|
-
padding:
|
|
1182
|
-
})[
|
|
1191
|
+
padding: l
|
|
1192
|
+
})[pe(O)], S;
|
|
1183
1193
|
}, {});
|
|
1184
|
-
return Object.keys(v).sort(function(
|
|
1185
|
-
return v[
|
|
1194
|
+
return Object.keys(v).sort(function(S, O) {
|
|
1195
|
+
return v[S] - v[O];
|
|
1186
1196
|
});
|
|
1187
1197
|
}
|
|
1188
1198
|
function Ra(e) {
|
|
1189
|
-
if (
|
|
1199
|
+
if (pe(e) === gt)
|
|
1190
1200
|
return [];
|
|
1191
1201
|
var t = Xe(e);
|
|
1192
|
-
return [
|
|
1202
|
+
return [Dt(e), t, Dt(t)];
|
|
1193
1203
|
}
|
|
1194
|
-
function
|
|
1204
|
+
function Da(e) {
|
|
1195
1205
|
var t = e.state, r = e.options, n = e.name;
|
|
1196
1206
|
if (!t.modifiersData[n]._skip) {
|
|
1197
|
-
for (var a = r.mainAxis, i = a === void 0 ? !0 : a,
|
|
1198
|
-
return he.concat(
|
|
1199
|
-
placement:
|
|
1207
|
+
for (var a = r.mainAxis, i = a === void 0 ? !0 : a, l = r.altAxis, o = l === void 0 ? !0 : l, s = r.fallbackPlacements, d = r.padding, c = r.boundary, w = r.rootBoundary, k = r.altBoundary, v = r.flipVariations, S = v === void 0 ? !0 : v, O = r.allowedAutoPlacements, $ = t.options.placement, C = pe($), E = C === $, R = s || (E || !S ? [Xe($)] : Ra($)), f = [$].concat(R).reduce(function(he, fe) {
|
|
1208
|
+
return he.concat(pe(fe) === gt ? Aa(t, {
|
|
1209
|
+
placement: fe,
|
|
1200
1210
|
boundary: c,
|
|
1201
1211
|
rootBoundary: w,
|
|
1202
1212
|
padding: d,
|
|
1203
|
-
flipVariations:
|
|
1204
|
-
allowedAutoPlacements:
|
|
1205
|
-
}) :
|
|
1206
|
-
}, []),
|
|
1207
|
-
var
|
|
1208
|
-
placement:
|
|
1213
|
+
flipVariations: S,
|
|
1214
|
+
allowedAutoPlacements: O
|
|
1215
|
+
}) : fe);
|
|
1216
|
+
}, []), g = t.rects.reference, u = t.rects.popper, T = /* @__PURE__ */ new Map(), B = !0, D = f[0], W = 0; W < f.length; W++) {
|
|
1217
|
+
var y = f[W], A = pe(y), z = Ve(y) === Se, Y = [ee, se].indexOf(A) >= 0, X = Y ? "width" : "height", F = Ie(t, {
|
|
1218
|
+
placement: y,
|
|
1209
1219
|
boundary: c,
|
|
1210
1220
|
rootBoundary: w,
|
|
1211
1221
|
altBoundary: k,
|
|
1212
1222
|
padding: d
|
|
1213
|
-
}),
|
|
1214
|
-
|
|
1215
|
-
var
|
|
1216
|
-
if (i &&
|
|
1223
|
+
}), H = Y ? z ? le : te : z ? se : ee;
|
|
1224
|
+
g[X] > u[X] && (H = Xe(H));
|
|
1225
|
+
var de = Xe(H), ce = [];
|
|
1226
|
+
if (i && ce.push(F[A] <= 0), o && ce.push(F[H] <= 0, F[de] <= 0), ce.every(function(he) {
|
|
1217
1227
|
return he;
|
|
1218
1228
|
})) {
|
|
1219
|
-
D =
|
|
1229
|
+
D = y, B = !1;
|
|
1220
1230
|
break;
|
|
1221
1231
|
}
|
|
1222
|
-
T.set(
|
|
1232
|
+
T.set(y, ce);
|
|
1223
1233
|
}
|
|
1224
1234
|
if (B)
|
|
1225
|
-
for (var
|
|
1235
|
+
for (var h = S ? 3 : 1, N = function(fe) {
|
|
1226
1236
|
var ye = f.find(function(Te) {
|
|
1227
|
-
var
|
|
1228
|
-
if (
|
|
1229
|
-
return
|
|
1237
|
+
var me = T.get(Te);
|
|
1238
|
+
if (me)
|
|
1239
|
+
return me.slice(0, fe).every(function(Be) {
|
|
1230
1240
|
return Be;
|
|
1231
1241
|
});
|
|
1232
1242
|
});
|
|
1233
1243
|
if (ye)
|
|
1234
1244
|
return D = ye, "break";
|
|
1235
|
-
},
|
|
1236
|
-
var
|
|
1237
|
-
if (
|
|
1245
|
+
}, K = h; K > 0; K--) {
|
|
1246
|
+
var ue = N(K);
|
|
1247
|
+
if (ue === "break") break;
|
|
1238
1248
|
}
|
|
1239
1249
|
t.placement !== D && (t.modifiersData[n]._skip = !0, t.placement = D, t.reset = !0);
|
|
1240
1250
|
}
|
|
1241
1251
|
}
|
|
1242
|
-
const
|
|
1252
|
+
const za = {
|
|
1243
1253
|
name: "flip",
|
|
1244
1254
|
enabled: !0,
|
|
1245
1255
|
phase: "main",
|
|
1246
|
-
fn:
|
|
1256
|
+
fn: Da,
|
|
1247
1257
|
requiresIfExists: ["offset"],
|
|
1248
1258
|
data: {
|
|
1249
1259
|
_skip: !1
|
|
1250
1260
|
}
|
|
1251
1261
|
};
|
|
1252
|
-
function
|
|
1262
|
+
function Wt(e, t, r) {
|
|
1253
1263
|
return r === void 0 && (r = {
|
|
1254
1264
|
x: 0,
|
|
1255
1265
|
y: 0
|
|
@@ -1260,19 +1270,19 @@ function Dt(e, t, r) {
|
|
|
1260
1270
|
left: e.left - t.width - r.x
|
|
1261
1271
|
};
|
|
1262
1272
|
}
|
|
1263
|
-
function
|
|
1264
|
-
return [ee,
|
|
1273
|
+
function Lt(e) {
|
|
1274
|
+
return [ee, le, se, te].some(function(t) {
|
|
1265
1275
|
return e[t] >= 0;
|
|
1266
1276
|
});
|
|
1267
1277
|
}
|
|
1268
|
-
function
|
|
1269
|
-
var t = e.state, r = e.name, n = t.rects.reference, a = t.rects.popper, i = t.modifiersData.preventOverflow,
|
|
1278
|
+
function Wa(e) {
|
|
1279
|
+
var t = e.state, r = e.name, n = t.rects.reference, a = t.rects.popper, i = t.modifiersData.preventOverflow, l = Ie(t, {
|
|
1270
1280
|
elementContext: "reference"
|
|
1271
|
-
}), o =
|
|
1281
|
+
}), o = Ie(t, {
|
|
1272
1282
|
altBoundary: !0
|
|
1273
|
-
}),
|
|
1283
|
+
}), s = Wt(l, n), d = Wt(o, a, i), c = Lt(s), w = Lt(d);
|
|
1274
1284
|
t.modifiersData[r] = {
|
|
1275
|
-
referenceClippingOffsets:
|
|
1285
|
+
referenceClippingOffsets: s,
|
|
1276
1286
|
popperEscapeOffsets: d,
|
|
1277
1287
|
isReferenceHidden: c,
|
|
1278
1288
|
hasPopperEscaped: w
|
|
@@ -1281,138 +1291,138 @@ function za(e) {
|
|
|
1281
1291
|
"data-popper-escaped": w
|
|
1282
1292
|
});
|
|
1283
1293
|
}
|
|
1284
|
-
const
|
|
1294
|
+
const La = {
|
|
1285
1295
|
name: "hide",
|
|
1286
1296
|
enabled: !0,
|
|
1287
1297
|
phase: "main",
|
|
1288
1298
|
requiresIfExists: ["preventOverflow"],
|
|
1289
|
-
fn:
|
|
1299
|
+
fn: Wa
|
|
1290
1300
|
};
|
|
1291
|
-
function
|
|
1292
|
-
var n =
|
|
1301
|
+
function ja(e, t, r) {
|
|
1302
|
+
var n = pe(e), a = [te, ee].indexOf(n) >= 0 ? -1 : 1, i = typeof r == "function" ? r(Object.assign({}, t, {
|
|
1293
1303
|
placement: e
|
|
1294
|
-
})) : r,
|
|
1295
|
-
return
|
|
1304
|
+
})) : r, l = i[0], o = i[1];
|
|
1305
|
+
return l = l || 0, o = (o || 0) * a, [te, le].indexOf(n) >= 0 ? {
|
|
1296
1306
|
x: o,
|
|
1297
|
-
y:
|
|
1307
|
+
y: l
|
|
1298
1308
|
} : {
|
|
1299
|
-
x:
|
|
1309
|
+
x: l,
|
|
1300
1310
|
y: o
|
|
1301
1311
|
};
|
|
1302
1312
|
}
|
|
1303
|
-
function
|
|
1304
|
-
var t = e.state, r = e.options, n = e.name, a = r.offset, i = a === void 0 ? [0, 0] : a,
|
|
1305
|
-
return c[w] =
|
|
1306
|
-
}, {}), o =
|
|
1307
|
-
t.modifiersData.popperOffsets != null && (t.modifiersData.popperOffsets.x +=
|
|
1313
|
+
function Ma(e) {
|
|
1314
|
+
var t = e.state, r = e.options, n = e.name, a = r.offset, i = a === void 0 ? [0, 0] : a, l = Jt.reduce(function(c, w) {
|
|
1315
|
+
return c[w] = ja(w, t.rects, i), c;
|
|
1316
|
+
}, {}), o = l[t.placement], s = o.x, d = o.y;
|
|
1317
|
+
t.modifiersData.popperOffsets != null && (t.modifiersData.popperOffsets.x += s, t.modifiersData.popperOffsets.y += d), t.modifiersData[n] = l;
|
|
1308
1318
|
}
|
|
1309
|
-
const
|
|
1319
|
+
const _a = {
|
|
1310
1320
|
name: "offset",
|
|
1311
1321
|
enabled: !0,
|
|
1312
1322
|
phase: "main",
|
|
1313
1323
|
requires: ["popperOffsets"],
|
|
1314
|
-
fn:
|
|
1324
|
+
fn: Ma
|
|
1315
1325
|
};
|
|
1316
|
-
function
|
|
1326
|
+
function Ia(e) {
|
|
1317
1327
|
var t = e.state, r = e.name;
|
|
1318
|
-
t.modifiersData[r] =
|
|
1328
|
+
t.modifiersData[r] = or({
|
|
1319
1329
|
reference: t.rects.reference,
|
|
1320
1330
|
element: t.rects.popper,
|
|
1321
1331
|
placement: t.placement
|
|
1322
1332
|
});
|
|
1323
1333
|
}
|
|
1324
|
-
const
|
|
1334
|
+
const Na = {
|
|
1325
1335
|
name: "popperOffsets",
|
|
1326
1336
|
enabled: !0,
|
|
1327
1337
|
phase: "read",
|
|
1328
|
-
fn:
|
|
1338
|
+
fn: Ia,
|
|
1329
1339
|
data: {}
|
|
1330
1340
|
};
|
|
1331
|
-
function
|
|
1341
|
+
function Fa(e) {
|
|
1332
1342
|
return e === "x" ? "y" : "x";
|
|
1333
1343
|
}
|
|
1334
|
-
function
|
|
1335
|
-
var t = e.state, r = e.options, n = e.name, a = r.mainAxis, i = a === void 0 ? !0 : a,
|
|
1336
|
-
boundary:
|
|
1344
|
+
function Ha(e) {
|
|
1345
|
+
var t = e.state, r = e.options, n = e.name, a = r.mainAxis, i = a === void 0 ? !0 : a, l = r.altAxis, o = l === void 0 ? !1 : l, s = r.boundary, d = r.rootBoundary, c = r.altBoundary, w = r.padding, k = r.tether, v = k === void 0 ? !0 : k, S = r.tetherOffset, O = S === void 0 ? 0 : S, $ = Ie(t, {
|
|
1346
|
+
boundary: s,
|
|
1337
1347
|
rootBoundary: d,
|
|
1338
1348
|
padding: w,
|
|
1339
1349
|
altBoundary: c
|
|
1340
|
-
}),
|
|
1350
|
+
}), C = pe(t.placement), E = Ve(t.placement), R = !E, f = yt(C), g = Fa(f), u = t.modifiersData.popperOffsets, T = t.rects.reference, B = t.rects.popper, D = typeof O == "function" ? O(Object.assign({}, t.rects, {
|
|
1341
1351
|
placement: t.placement
|
|
1342
|
-
})) :
|
|
1352
|
+
})) : O, W = typeof D == "number" ? {
|
|
1343
1353
|
mainAxis: D,
|
|
1344
1354
|
altAxis: D
|
|
1345
1355
|
} : Object.assign({
|
|
1346
1356
|
mainAxis: 0,
|
|
1347
1357
|
altAxis: 0
|
|
1348
|
-
}, D),
|
|
1358
|
+
}, D), y = t.modifiersData.offset ? t.modifiersData.offset[t.placement] : null, A = {
|
|
1349
1359
|
x: 0,
|
|
1350
1360
|
y: 0
|
|
1351
1361
|
};
|
|
1352
1362
|
if (u) {
|
|
1353
1363
|
if (i) {
|
|
1354
|
-
var z,
|
|
1364
|
+
var z, Y = f === "y" ? ee : te, X = f === "y" ? se : le, F = f === "y" ? "height" : "width", H = u[f], de = H + $[Y], ce = H - $[X], h = v ? -B[F] / 2 : 0, N = E === Se ? T[F] : B[F], K = E === Se ? -B[F] : -T[F], ue = t.elements.arrow, he = v && ue ? bt(ue) : {
|
|
1355
1365
|
width: 0,
|
|
1356
1366
|
height: 0
|
|
1357
|
-
},
|
|
1358
|
-
u[f] =
|
|
1367
|
+
}, fe = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : rr(), ye = fe[Y], Te = fe[X], me = ze(0, T[F], he[F]), Be = R ? T[F] / 2 - h - me - ye - W.mainAxis : N - me - ye - W.mainAxis, He = R ? -T[F] / 2 + h + me + Te + W.mainAxis : K + me + Te + W.mainAxis, Ae = t.elements.arrow && Fe(t.elements.arrow), rt = Ae ? f === "y" ? Ae.clientTop || 0 : Ae.clientLeft || 0 : 0, p = (z = y?.[f]) != null ? z : 0, L = H + Be - p - rt, P = H + He - p, ae = ze(v ? Ge(de, L) : de, H, v ? Oe(ce, P) : ce);
|
|
1368
|
+
u[f] = ae, A[f] = ae - H;
|
|
1359
1369
|
}
|
|
1360
1370
|
if (o) {
|
|
1361
|
-
var
|
|
1362
|
-
u[
|
|
1371
|
+
var Q, at = f === "x" ? ee : te, $t = f === "x" ? se : le, we = u[g], qe = g === "y" ? "height" : "width", kt = we + $[at], Tt = we - $[$t], nt = [ee, te].indexOf(C) !== -1, St = (Q = y?.[g]) != null ? Q : 0, Ct = nt ? kt : we - T[qe] - B[qe] - St + W.altAxis, Pt = nt ? we + T[qe] + B[qe] - St - W.altAxis : Tt, Vt = v && nt ? va(Ct, we, Pt) : ze(v ? Ct : kt, we, v ? Pt : Tt);
|
|
1372
|
+
u[g] = Vt, A[g] = Vt - we;
|
|
1363
1373
|
}
|
|
1364
|
-
t.modifiersData[n] =
|
|
1374
|
+
t.modifiersData[n] = A;
|
|
1365
1375
|
}
|
|
1366
1376
|
}
|
|
1367
|
-
const
|
|
1377
|
+
const qa = {
|
|
1368
1378
|
name: "preventOverflow",
|
|
1369
1379
|
enabled: !0,
|
|
1370
1380
|
phase: "main",
|
|
1371
|
-
fn:
|
|
1381
|
+
fn: Ha,
|
|
1372
1382
|
requiresIfExists: ["offset"]
|
|
1373
1383
|
};
|
|
1374
|
-
function
|
|
1384
|
+
function Ua(e) {
|
|
1375
1385
|
return {
|
|
1376
1386
|
scrollLeft: e.scrollLeft,
|
|
1377
1387
|
scrollTop: e.scrollTop
|
|
1378
1388
|
};
|
|
1379
1389
|
}
|
|
1380
|
-
function
|
|
1381
|
-
return e === re(e) || !
|
|
1390
|
+
function Ya(e) {
|
|
1391
|
+
return e === re(e) || !oe(e) ? wt(e) : Ua(e);
|
|
1382
1392
|
}
|
|
1383
1393
|
function Xa(e) {
|
|
1384
|
-
var t = e.getBoundingClientRect(), r =
|
|
1394
|
+
var t = e.getBoundingClientRect(), r = Ce(t.width) / e.offsetWidth || 1, n = Ce(t.height) / e.offsetHeight || 1;
|
|
1385
1395
|
return r !== 1 || n !== 1;
|
|
1386
1396
|
}
|
|
1387
|
-
function
|
|
1397
|
+
function Ka(e, t, r) {
|
|
1388
1398
|
r === void 0 && (r = !1);
|
|
1389
|
-
var n =
|
|
1399
|
+
var n = oe(t), a = oe(t) && Xa(t), i = be(t), l = Pe(e, a, r), o = {
|
|
1390
1400
|
scrollLeft: 0,
|
|
1391
1401
|
scrollTop: 0
|
|
1392
|
-
},
|
|
1402
|
+
}, s = {
|
|
1393
1403
|
x: 0,
|
|
1394
1404
|
y: 0
|
|
1395
1405
|
};
|
|
1396
|
-
return (n || !n && !r) && ((
|
|
1397
|
-
|
|
1398
|
-
x:
|
|
1399
|
-
y:
|
|
1400
|
-
width:
|
|
1401
|
-
height:
|
|
1406
|
+
return (n || !n && !r) && ((ve(t) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
|
|
1407
|
+
Ot(i)) && (o = Ya(t)), oe(t) ? (s = Pe(t, !0), s.x += t.clientLeft, s.y += t.clientTop) : i && (s.x = xt(i))), {
|
|
1408
|
+
x: l.left + o.scrollLeft - s.x,
|
|
1409
|
+
y: l.top + o.scrollTop - s.y,
|
|
1410
|
+
width: l.width,
|
|
1411
|
+
height: l.height
|
|
1402
1412
|
};
|
|
1403
1413
|
}
|
|
1404
|
-
function
|
|
1414
|
+
function Qa(e) {
|
|
1405
1415
|
var t = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Set(), n = [];
|
|
1406
1416
|
e.forEach(function(i) {
|
|
1407
1417
|
t.set(i.name, i);
|
|
1408
1418
|
});
|
|
1409
1419
|
function a(i) {
|
|
1410
1420
|
r.add(i.name);
|
|
1411
|
-
var
|
|
1412
|
-
|
|
1421
|
+
var l = [].concat(i.requires || [], i.requiresIfExists || []);
|
|
1422
|
+
l.forEach(function(o) {
|
|
1413
1423
|
if (!r.has(o)) {
|
|
1414
|
-
var
|
|
1415
|
-
|
|
1424
|
+
var s = t.get(o);
|
|
1425
|
+
s && a(s);
|
|
1416
1426
|
}
|
|
1417
1427
|
}), n.push(i);
|
|
1418
1428
|
}
|
|
@@ -1420,15 +1430,15 @@ function Ka(e) {
|
|
|
1420
1430
|
r.has(i.name) || a(i);
|
|
1421
1431
|
}), n;
|
|
1422
1432
|
}
|
|
1423
|
-
function
|
|
1424
|
-
var t =
|
|
1425
|
-
return
|
|
1433
|
+
function Ga(e) {
|
|
1434
|
+
var t = Qa(e);
|
|
1435
|
+
return la.reduce(function(r, n) {
|
|
1426
1436
|
return r.concat(t.filter(function(a) {
|
|
1427
1437
|
return a.phase === n;
|
|
1428
1438
|
}));
|
|
1429
1439
|
}, []);
|
|
1430
1440
|
}
|
|
1431
|
-
function
|
|
1441
|
+
function Za(e) {
|
|
1432
1442
|
var t;
|
|
1433
1443
|
return function() {
|
|
1434
1444
|
return t || (t = new Promise(function(r) {
|
|
@@ -1438,7 +1448,7 @@ function Ga(e) {
|
|
|
1438
1448
|
})), t;
|
|
1439
1449
|
};
|
|
1440
1450
|
}
|
|
1441
|
-
function
|
|
1451
|
+
function Ja(e) {
|
|
1442
1452
|
var t = e.reduce(function(r, n) {
|
|
1443
1453
|
var a = r[n.name];
|
|
1444
1454
|
return r[n.name] = a ? Object.assign({}, a, n, {
|
|
@@ -1450,46 +1460,46 @@ function Za(e) {
|
|
|
1450
1460
|
return t[r];
|
|
1451
1461
|
});
|
|
1452
1462
|
}
|
|
1453
|
-
var
|
|
1463
|
+
var jt = {
|
|
1454
1464
|
placement: "bottom",
|
|
1455
1465
|
modifiers: [],
|
|
1456
1466
|
strategy: "absolute"
|
|
1457
1467
|
};
|
|
1458
|
-
function
|
|
1468
|
+
function Mt() {
|
|
1459
1469
|
for (var e = arguments.length, t = new Array(e), r = 0; r < e; r++)
|
|
1460
1470
|
t[r] = arguments[r];
|
|
1461
1471
|
return !t.some(function(n) {
|
|
1462
1472
|
return !(n && typeof n.getBoundingClientRect == "function");
|
|
1463
1473
|
});
|
|
1464
1474
|
}
|
|
1465
|
-
function
|
|
1475
|
+
function en(e) {
|
|
1466
1476
|
e === void 0 && (e = {});
|
|
1467
|
-
var t = e, r = t.defaultModifiers, n = r === void 0 ? [] : r, a = t.defaultOptions, i = a === void 0 ?
|
|
1468
|
-
return function(o,
|
|
1477
|
+
var t = e, r = t.defaultModifiers, n = r === void 0 ? [] : r, a = t.defaultOptions, i = a === void 0 ? jt : a;
|
|
1478
|
+
return function(o, s, d) {
|
|
1469
1479
|
d === void 0 && (d = i);
|
|
1470
1480
|
var c = {
|
|
1471
1481
|
placement: "bottom",
|
|
1472
1482
|
orderedModifiers: [],
|
|
1473
|
-
options: Object.assign({},
|
|
1483
|
+
options: Object.assign({}, jt, i),
|
|
1474
1484
|
modifiersData: {},
|
|
1475
1485
|
elements: {
|
|
1476
1486
|
reference: o,
|
|
1477
|
-
popper:
|
|
1487
|
+
popper: s
|
|
1478
1488
|
},
|
|
1479
1489
|
attributes: {},
|
|
1480
1490
|
styles: {}
|
|
1481
1491
|
}, w = [], k = !1, v = {
|
|
1482
1492
|
state: c,
|
|
1483
|
-
setOptions: function(
|
|
1484
|
-
var
|
|
1485
|
-
|
|
1486
|
-
reference: ke(o) ?
|
|
1487
|
-
popper:
|
|
1493
|
+
setOptions: function(C) {
|
|
1494
|
+
var E = typeof C == "function" ? C(c.options) : C;
|
|
1495
|
+
O(), c.options = Object.assign({}, i, c.options, E), c.scrollParents = {
|
|
1496
|
+
reference: ke(o) ? We(o) : o.contextElement ? We(o.contextElement) : [],
|
|
1497
|
+
popper: We(s)
|
|
1488
1498
|
};
|
|
1489
|
-
var
|
|
1490
|
-
return c.orderedModifiers =
|
|
1499
|
+
var R = Ga(Ja([].concat(n, c.options.modifiers)));
|
|
1500
|
+
return c.orderedModifiers = R.filter(function(f) {
|
|
1491
1501
|
return f.enabled;
|
|
1492
|
-
}),
|
|
1502
|
+
}), S(), v.update();
|
|
1493
1503
|
},
|
|
1494
1504
|
// Sync update – it will always be executed, even if not necessary. This
|
|
1495
1505
|
// is useful for low frequency updates where sync behavior simplifies the
|
|
@@ -1498,11 +1508,11 @@ function Ja(e) {
|
|
|
1498
1508
|
// prefer the async Popper#update method
|
|
1499
1509
|
forceUpdate: function() {
|
|
1500
1510
|
if (!k) {
|
|
1501
|
-
var
|
|
1502
|
-
if (
|
|
1511
|
+
var C = c.elements, E = C.reference, R = C.popper;
|
|
1512
|
+
if (Mt(E, R)) {
|
|
1503
1513
|
c.rects = {
|
|
1504
|
-
reference:
|
|
1505
|
-
popper:
|
|
1514
|
+
reference: Ka(E, Fe(R), c.options.strategy === "fixed"),
|
|
1515
|
+
popper: bt(R)
|
|
1506
1516
|
}, c.reset = !1, c.placement = c.options.placement, c.orderedModifiers.forEach(function(W) {
|
|
1507
1517
|
return c.modifiersData[W.name] = Object.assign({}, W.data);
|
|
1508
1518
|
});
|
|
@@ -1511,7 +1521,7 @@ function Ja(e) {
|
|
|
1511
1521
|
c.reset = !1, f = -1;
|
|
1512
1522
|
continue;
|
|
1513
1523
|
}
|
|
1514
|
-
var
|
|
1524
|
+
var g = c.orderedModifiers[f], u = g.fn, T = g.options, B = T === void 0 ? {} : T, D = g.name;
|
|
1515
1525
|
typeof u == "function" && (c = u({
|
|
1516
1526
|
state: c,
|
|
1517
1527
|
options: B,
|
|
@@ -1524,36 +1534,36 @@ function Ja(e) {
|
|
|
1524
1534
|
},
|
|
1525
1535
|
// Async and optimistically optimized update – it will not be executed if
|
|
1526
1536
|
// not necessary (debounced to run at most once-per-tick)
|
|
1527
|
-
update:
|
|
1537
|
+
update: Za(function() {
|
|
1528
1538
|
return new Promise(function($) {
|
|
1529
1539
|
v.forceUpdate(), $(c);
|
|
1530
1540
|
});
|
|
1531
1541
|
}),
|
|
1532
1542
|
destroy: function() {
|
|
1533
|
-
|
|
1543
|
+
O(), k = !0;
|
|
1534
1544
|
}
|
|
1535
1545
|
};
|
|
1536
|
-
if (!
|
|
1546
|
+
if (!Mt(o, s))
|
|
1537
1547
|
return v;
|
|
1538
1548
|
v.setOptions(d).then(function($) {
|
|
1539
1549
|
!k && d.onFirstUpdate && d.onFirstUpdate($);
|
|
1540
1550
|
});
|
|
1541
|
-
function
|
|
1551
|
+
function S() {
|
|
1542
1552
|
c.orderedModifiers.forEach(function($) {
|
|
1543
|
-
var
|
|
1553
|
+
var C = $.name, E = $.options, R = E === void 0 ? {} : E, f = $.effect;
|
|
1544
1554
|
if (typeof f == "function") {
|
|
1545
|
-
var
|
|
1555
|
+
var g = f({
|
|
1546
1556
|
state: c,
|
|
1547
|
-
name:
|
|
1557
|
+
name: C,
|
|
1548
1558
|
instance: v,
|
|
1549
|
-
options:
|
|
1559
|
+
options: R
|
|
1550
1560
|
}), u = function() {
|
|
1551
1561
|
};
|
|
1552
|
-
w.push(
|
|
1562
|
+
w.push(g || u);
|
|
1553
1563
|
}
|
|
1554
1564
|
});
|
|
1555
1565
|
}
|
|
1556
|
-
function
|
|
1566
|
+
function O() {
|
|
1557
1567
|
w.forEach(function($) {
|
|
1558
1568
|
return $();
|
|
1559
1569
|
}), w = [];
|
|
@@ -1561,136 +1571,136 @@ function Ja(e) {
|
|
|
1561
1571
|
return v;
|
|
1562
1572
|
};
|
|
1563
1573
|
}
|
|
1564
|
-
var
|
|
1565
|
-
defaultModifiers:
|
|
1566
|
-
}),
|
|
1567
|
-
function
|
|
1568
|
-
var t =
|
|
1574
|
+
var tn = [ka, Na, Oa, da, _a, za, qa, ba, La], rn = /* @__PURE__ */ en({
|
|
1575
|
+
defaultModifiers: tn
|
|
1576
|
+
}), an = typeof global == "object" && global && global.Object === Object && global, nn = typeof self == "object" && self && self.Object === Object && self, sr = an || nn || Function("return this")(), Ze = sr.Symbol, lr = Object.prototype, on = lr.hasOwnProperty, sn = lr.toString, De = Ze ? Ze.toStringTag : void 0;
|
|
1577
|
+
function ln(e) {
|
|
1578
|
+
var t = on.call(e, De), r = e[De];
|
|
1569
1579
|
try {
|
|
1570
|
-
e[
|
|
1580
|
+
e[De] = void 0;
|
|
1571
1581
|
var n = !0;
|
|
1572
1582
|
} catch {
|
|
1573
1583
|
}
|
|
1574
|
-
var a =
|
|
1575
|
-
return n && (t ? e[
|
|
1576
|
-
}
|
|
1577
|
-
var ln = Object.prototype, cn = ln.toString;
|
|
1578
|
-
function un(e) {
|
|
1579
|
-
return cn.call(e);
|
|
1584
|
+
var a = sn.call(e);
|
|
1585
|
+
return n && (t ? e[De] = r : delete e[De]), a;
|
|
1580
1586
|
}
|
|
1581
|
-
var
|
|
1582
|
-
function
|
|
1583
|
-
return
|
|
1587
|
+
var cn = Object.prototype, un = cn.toString;
|
|
1588
|
+
function dn(e) {
|
|
1589
|
+
return un.call(e);
|
|
1584
1590
|
}
|
|
1591
|
+
var fn = "[object Null]", pn = "[object Undefined]", _t = Ze ? Ze.toStringTag : void 0;
|
|
1585
1592
|
function vn(e) {
|
|
1593
|
+
return e == null ? e === void 0 ? pn : fn : _t && _t in Object(e) ? ln(e) : dn(e);
|
|
1594
|
+
}
|
|
1595
|
+
function mn(e) {
|
|
1586
1596
|
return e != null && typeof e == "object";
|
|
1587
1597
|
}
|
|
1588
|
-
var
|
|
1589
|
-
function
|
|
1590
|
-
return typeof e == "symbol" ||
|
|
1598
|
+
var gn = "[object Symbol]";
|
|
1599
|
+
function hn(e) {
|
|
1600
|
+
return typeof e == "symbol" || mn(e) && vn(e) == gn;
|
|
1591
1601
|
}
|
|
1592
|
-
var
|
|
1593
|
-
function
|
|
1594
|
-
for (var t = e.length; t-- &&
|
|
1602
|
+
var bn = /\s/;
|
|
1603
|
+
function yn(e) {
|
|
1604
|
+
for (var t = e.length; t-- && bn.test(e.charAt(t)); )
|
|
1595
1605
|
;
|
|
1596
1606
|
return t;
|
|
1597
1607
|
}
|
|
1598
|
-
var
|
|
1599
|
-
function
|
|
1600
|
-
return e && e.slice(0,
|
|
1608
|
+
var wn = /^\s+/;
|
|
1609
|
+
function xn(e) {
|
|
1610
|
+
return e && e.slice(0, yn(e) + 1).replace(wn, "");
|
|
1601
1611
|
}
|
|
1602
|
-
function
|
|
1612
|
+
function Je(e) {
|
|
1603
1613
|
var t = typeof e;
|
|
1604
1614
|
return e != null && (t == "object" || t == "function");
|
|
1605
1615
|
}
|
|
1606
|
-
var
|
|
1607
|
-
function
|
|
1616
|
+
var It = NaN, On = /^[-+]0x[0-9a-f]+$/i, $n = /^0b[01]+$/i, kn = /^0o[0-7]+$/i, Tn = parseInt;
|
|
1617
|
+
function Nt(e) {
|
|
1608
1618
|
if (typeof e == "number")
|
|
1609
1619
|
return e;
|
|
1610
|
-
if (
|
|
1611
|
-
return
|
|
1612
|
-
if (
|
|
1620
|
+
if (hn(e))
|
|
1621
|
+
return It;
|
|
1622
|
+
if (Je(e)) {
|
|
1613
1623
|
var t = typeof e.valueOf == "function" ? e.valueOf() : e;
|
|
1614
|
-
e =
|
|
1624
|
+
e = Je(t) ? t + "" : t;
|
|
1615
1625
|
}
|
|
1616
1626
|
if (typeof e != "string")
|
|
1617
1627
|
return e === 0 ? e : +e;
|
|
1618
|
-
e =
|
|
1628
|
+
e = xn(e);
|
|
1619
1629
|
var r = $n.test(e);
|
|
1620
|
-
return r ||
|
|
1630
|
+
return r || kn.test(e) ? Tn(e.slice(2), r ? 2 : 8) : On.test(e) ? It : +e;
|
|
1621
1631
|
}
|
|
1622
|
-
var
|
|
1623
|
-
return
|
|
1624
|
-
},
|
|
1625
|
-
function
|
|
1626
|
-
var n, a, i,
|
|
1632
|
+
var st = function() {
|
|
1633
|
+
return sr.Date.now();
|
|
1634
|
+
}, Sn = "Expected a function", Cn = Math.max, Pn = Math.min;
|
|
1635
|
+
function ft(e, t, r) {
|
|
1636
|
+
var n, a, i, l, o, s, d = 0, c = !1, w = !1, k = !0;
|
|
1627
1637
|
if (typeof e != "function")
|
|
1628
|
-
throw new TypeError(
|
|
1629
|
-
t =
|
|
1638
|
+
throw new TypeError(Sn);
|
|
1639
|
+
t = Nt(t) || 0, Je(r) && (c = !!r.leading, w = "maxWait" in r, i = w ? Cn(Nt(r.maxWait) || 0, t) : i, k = "trailing" in r ? !!r.trailing : k);
|
|
1630
1640
|
function v(u) {
|
|
1631
1641
|
var T = n, B = a;
|
|
1632
|
-
return n = a = void 0, d = u,
|
|
1642
|
+
return n = a = void 0, d = u, l = e.apply(B, T), l;
|
|
1633
1643
|
}
|
|
1634
|
-
function
|
|
1635
|
-
return d = u, o = setTimeout(
|
|
1644
|
+
function S(u) {
|
|
1645
|
+
return d = u, o = setTimeout(C, t), c ? v(u) : l;
|
|
1636
1646
|
}
|
|
1637
|
-
function
|
|
1638
|
-
var T = u -
|
|
1639
|
-
return w ?
|
|
1647
|
+
function O(u) {
|
|
1648
|
+
var T = u - s, B = u - d, D = t - T;
|
|
1649
|
+
return w ? Pn(D, i - B) : D;
|
|
1640
1650
|
}
|
|
1641
1651
|
function $(u) {
|
|
1642
|
-
var T = u -
|
|
1643
|
-
return
|
|
1652
|
+
var T = u - s, B = u - d;
|
|
1653
|
+
return s === void 0 || T >= t || T < 0 || w && B >= i;
|
|
1644
1654
|
}
|
|
1645
|
-
function
|
|
1646
|
-
var u =
|
|
1655
|
+
function C() {
|
|
1656
|
+
var u = st();
|
|
1647
1657
|
if ($(u))
|
|
1648
|
-
return
|
|
1649
|
-
o = setTimeout(
|
|
1658
|
+
return E(u);
|
|
1659
|
+
o = setTimeout(C, O(u));
|
|
1650
1660
|
}
|
|
1651
|
-
function
|
|
1652
|
-
return o = void 0, k && n ? v(u) : (n = a = void 0,
|
|
1661
|
+
function E(u) {
|
|
1662
|
+
return o = void 0, k && n ? v(u) : (n = a = void 0, l);
|
|
1653
1663
|
}
|
|
1654
|
-
function
|
|
1655
|
-
o !== void 0 && clearTimeout(o), d = 0, n =
|
|
1664
|
+
function R() {
|
|
1665
|
+
o !== void 0 && clearTimeout(o), d = 0, n = s = a = o = void 0;
|
|
1656
1666
|
}
|
|
1657
1667
|
function f() {
|
|
1658
|
-
return o === void 0 ?
|
|
1668
|
+
return o === void 0 ? l : E(st());
|
|
1659
1669
|
}
|
|
1660
|
-
function
|
|
1661
|
-
var u =
|
|
1662
|
-
if (n = arguments, a = this,
|
|
1670
|
+
function g() {
|
|
1671
|
+
var u = st(), T = $(u);
|
|
1672
|
+
if (n = arguments, a = this, s = u, T) {
|
|
1663
1673
|
if (o === void 0)
|
|
1664
|
-
return
|
|
1674
|
+
return S(s);
|
|
1665
1675
|
if (w)
|
|
1666
|
-
return clearTimeout(o), o = setTimeout(
|
|
1676
|
+
return clearTimeout(o), o = setTimeout(C, t), v(s);
|
|
1667
1677
|
}
|
|
1668
|
-
return o === void 0 && (o = setTimeout(
|
|
1678
|
+
return o === void 0 && (o = setTimeout(C, t)), l;
|
|
1669
1679
|
}
|
|
1670
|
-
return
|
|
1680
|
+
return g.cancel = R, g.flush = f, g;
|
|
1671
1681
|
}
|
|
1672
|
-
var
|
|
1682
|
+
var Vn = "Expected a function";
|
|
1673
1683
|
function En(e, t, r) {
|
|
1674
1684
|
var n = !0, a = !0;
|
|
1675
1685
|
if (typeof e != "function")
|
|
1676
|
-
throw new TypeError(
|
|
1677
|
-
return
|
|
1686
|
+
throw new TypeError(Vn);
|
|
1687
|
+
return Je(r) && (n = "leading" in r ? !!r.leading : n, a = "trailing" in r ? !!r.trailing : a), ft(e, t, {
|
|
1678
1688
|
leading: n,
|
|
1679
1689
|
maxWait: t,
|
|
1680
1690
|
trailing: a
|
|
1681
1691
|
});
|
|
1682
1692
|
}
|
|
1683
|
-
const
|
|
1693
|
+
const Bn = (e, t) => {
|
|
1684
1694
|
const r = (n) => {
|
|
1685
1695
|
const a = e.value, i = n.target;
|
|
1686
1696
|
!a || !i || !(i instanceof Node) || a.contains(i) || t(n);
|
|
1687
1697
|
};
|
|
1688
|
-
|
|
1698
|
+
et(() => {
|
|
1689
1699
|
document.addEventListener("click", r, !0);
|
|
1690
|
-
}),
|
|
1700
|
+
}), Ee(() => {
|
|
1691
1701
|
document.removeEventListener("click", r, !0);
|
|
1692
1702
|
});
|
|
1693
|
-
},
|
|
1703
|
+
}, An = 80, pt = /* @__PURE__ */ G({
|
|
1694
1704
|
name: "Popover",
|
|
1695
1705
|
__name: "Popover",
|
|
1696
1706
|
props: {
|
|
@@ -1709,19 +1719,19 @@ const Vn = (e, t) => {
|
|
|
1709
1719
|
},
|
|
1710
1720
|
emits: ["visible-change", "click-outside", "scroll"],
|
|
1711
1721
|
setup(e, { expose: t, emit: r }) {
|
|
1712
|
-
const n =
|
|
1713
|
-
let w = null, k =
|
|
1714
|
-
const
|
|
1715
|
-
const
|
|
1716
|
-
return
|
|
1717
|
-
}), $ =
|
|
1718
|
-
const
|
|
1719
|
-
if (
|
|
1722
|
+
const n = _(!1), a = e, i = m(() => a.preserveContentMount || n.value), l = m(() => !a.preserveContentMount || n.value), o = r, s = _(), d = _(), c = _();
|
|
1723
|
+
let w = null, k = Me({}), v = Me({});
|
|
1724
|
+
const S = (y) => typeof y == "number" ? `${y}px` : y, O = m(() => {
|
|
1725
|
+
const y = a.maxPopperHeight;
|
|
1726
|
+
return y != null && y !== "";
|
|
1727
|
+
}), $ = m(() => {
|
|
1728
|
+
const y = {}, A = a.popperWidth;
|
|
1729
|
+
if (A != null && A !== "" && (y.width = S(A)), O.value) {
|
|
1720
1730
|
const z = a.maxPopperHeight;
|
|
1721
|
-
|
|
1731
|
+
y.maxHeight = S(z), y.overflowY = "auto", y.scrollbarWidth = "none", y.msOverflowStyle = "none";
|
|
1722
1732
|
}
|
|
1723
|
-
return
|
|
1724
|
-
}),
|
|
1733
|
+
return y.padding = S(a.padding), y;
|
|
1734
|
+
}), C = m(() => ({
|
|
1725
1735
|
placement: a.placement,
|
|
1726
1736
|
modifiers: [
|
|
1727
1737
|
{
|
|
@@ -1732,16 +1742,16 @@ const Vn = (e, t) => {
|
|
|
1732
1742
|
}
|
|
1733
1743
|
],
|
|
1734
1744
|
...a.popoverOptions
|
|
1735
|
-
})),
|
|
1745
|
+
})), E = () => {
|
|
1736
1746
|
a.disabled || (n.value = !0, o("visible-change", !0));
|
|
1737
|
-
},
|
|
1747
|
+
}, R = () => {
|
|
1738
1748
|
n.value = !1, o("visible-change", !1);
|
|
1739
|
-
}, f =
|
|
1740
|
-
a.disabled || (
|
|
1749
|
+
}, f = ft(E, a.openDelay), g = ft(R, a.closeDelay), u = () => {
|
|
1750
|
+
a.disabled || (g.cancel(), f());
|
|
1741
1751
|
}, T = () => {
|
|
1742
|
-
f.cancel(),
|
|
1752
|
+
f.cancel(), g();
|
|
1743
1753
|
};
|
|
1744
|
-
|
|
1754
|
+
Bn(s, () => {
|
|
1745
1755
|
a.trigger === "click" && n.value && !a.manual && T(), n.value && o("click-outside", !0);
|
|
1746
1756
|
});
|
|
1747
1757
|
const B = () => {
|
|
@@ -1751,80 +1761,80 @@ const Vn = (e, t) => {
|
|
|
1751
1761
|
};
|
|
1752
1762
|
J(
|
|
1753
1763
|
() => n.value,
|
|
1754
|
-
(
|
|
1755
|
-
|
|
1764
|
+
(y) => {
|
|
1765
|
+
y && (d.value && c.value ? w = rn(d.value, c.value, C.value) : w?.destroy());
|
|
1756
1766
|
},
|
|
1757
1767
|
{ flush: "post" }
|
|
1758
1768
|
), J(
|
|
1759
1769
|
() => a.manual,
|
|
1760
|
-
(
|
|
1761
|
-
|
|
1770
|
+
(y) => {
|
|
1771
|
+
y ? (v = {}, k = {}) : D();
|
|
1762
1772
|
}
|
|
1763
1773
|
), J(
|
|
1764
1774
|
() => a.trigger,
|
|
1765
|
-
(
|
|
1766
|
-
|
|
1775
|
+
(y, A) => {
|
|
1776
|
+
y !== A && (v = {}, k = {}, D());
|
|
1767
1777
|
}
|
|
1768
1778
|
), J(
|
|
1769
1779
|
() => a.disabled,
|
|
1770
|
-
(
|
|
1771
|
-
|
|
1780
|
+
(y) => {
|
|
1781
|
+
y && T();
|
|
1772
1782
|
}
|
|
1773
|
-
),
|
|
1783
|
+
), et(() => {
|
|
1774
1784
|
a.manual || D();
|
|
1775
1785
|
});
|
|
1776
|
-
const W = En((
|
|
1777
|
-
const
|
|
1778
|
-
o("scroll", { scrollTop:
|
|
1779
|
-
},
|
|
1780
|
-
return
|
|
1786
|
+
const W = En((y) => {
|
|
1787
|
+
const A = y.target;
|
|
1788
|
+
o("scroll", { scrollTop: A.scrollTop, scrollLeft: A.scrollLeft });
|
|
1789
|
+
}, An);
|
|
1790
|
+
return Ee(() => {
|
|
1781
1791
|
W.cancel(), w?.destroy();
|
|
1782
1792
|
}), t({
|
|
1783
1793
|
isOpen: n,
|
|
1784
1794
|
open: u,
|
|
1785
1795
|
close: T
|
|
1786
|
-
}), (
|
|
1796
|
+
}), (y, A) => (b(), x("div", xe({
|
|
1787
1797
|
class: "cregis-popover",
|
|
1788
1798
|
ref_key: "popoverRef",
|
|
1789
|
-
ref:
|
|
1790
|
-
},
|
|
1791
|
-
|
|
1799
|
+
ref: s
|
|
1800
|
+
}, Et(ne(k), !0)), [
|
|
1801
|
+
V("div", xe({
|
|
1792
1802
|
class: ["cregis-popover__trigger", { "cregis-popover__trigger--disabled": e.disabled }],
|
|
1793
1803
|
ref_key: "popoverTriggerRef",
|
|
1794
1804
|
ref: d
|
|
1795
|
-
},
|
|
1796
|
-
q(
|
|
1805
|
+
}, Et(ne(v), !0)), [
|
|
1806
|
+
q(y.$slots, "reference")
|
|
1797
1807
|
], 16),
|
|
1798
|
-
U(
|
|
1808
|
+
U(vt, { name: "fade" }, {
|
|
1799
1809
|
default: Z(() => [
|
|
1800
|
-
i.value ?
|
|
1810
|
+
i.value ? je((b(), x("div", {
|
|
1801
1811
|
key: 0,
|
|
1802
|
-
class: j(["cregis-popover__content", { "cregis-popover__content--hide-scrollbar":
|
|
1812
|
+
class: j(["cregis-popover__content", { "cregis-popover__content--hide-scrollbar": O.value }]),
|
|
1803
1813
|
ref_key: "popoverContentRef",
|
|
1804
1814
|
ref: c,
|
|
1805
|
-
style:
|
|
1806
|
-
onScroll:
|
|
1807
|
-
(...z) =>
|
|
1815
|
+
style: ie($.value),
|
|
1816
|
+
onScroll: A[0] || (A[0] = //@ts-ignore
|
|
1817
|
+
(...z) => ne(W) && ne(W)(...z))
|
|
1808
1818
|
}, [
|
|
1809
|
-
q(
|
|
1819
|
+
q(y.$slots, "default")
|
|
1810
1820
|
], 38)), [
|
|
1811
|
-
[
|
|
1821
|
+
[mt, l.value]
|
|
1812
1822
|
]) : I("", !0)
|
|
1813
1823
|
]),
|
|
1814
1824
|
_: 3
|
|
1815
1825
|
})
|
|
1816
1826
|
], 16));
|
|
1817
1827
|
}
|
|
1818
|
-
}),
|
|
1828
|
+
}), cr = Symbol("CregisSelect"), Rn = { class: "cregis-select__trigger-label" }, Dn = { class: "cregis-select__selected" }, zn = {
|
|
1819
1829
|
key: 1,
|
|
1820
1830
|
class: "cregis-select__placeholder"
|
|
1821
|
-
},
|
|
1831
|
+
}, Wn = {
|
|
1822
1832
|
key: 0,
|
|
1823
1833
|
class: "cregis-select__dropdown-empty"
|
|
1824
|
-
},
|
|
1834
|
+
}, Ln = {
|
|
1825
1835
|
key: 2,
|
|
1826
1836
|
class: "cregis-select__dropdown-filter-empty"
|
|
1827
|
-
},
|
|
1837
|
+
}, jn = { class: "cregis-select__dropdown-content" }, li = /* @__PURE__ */ G({
|
|
1828
1838
|
name: "Select",
|
|
1829
1839
|
__name: "Select",
|
|
1830
1840
|
props: {
|
|
@@ -1844,146 +1854,146 @@ const Vn = (e, t) => {
|
|
|
1844
1854
|
},
|
|
1845
1855
|
emits: ["update:modelValue", "change", "visible-change", "filter-input", "filter-clear"],
|
|
1846
1856
|
setup(e, { emit: t }) {
|
|
1847
|
-
const r = e, n = t, a =
|
|
1848
|
-
let
|
|
1857
|
+
const r = e, n = t, a = _(null), i = _(!1);
|
|
1858
|
+
let l = null;
|
|
1849
1859
|
const o = () => {
|
|
1850
|
-
|
|
1851
|
-
},
|
|
1852
|
-
i.value =
|
|
1853
|
-
}, d = (
|
|
1854
|
-
const
|
|
1855
|
-
return k.value++, c[
|
|
1856
|
-
k.value--, delete c[
|
|
1860
|
+
l !== null && (clearTimeout(l), l = null);
|
|
1861
|
+
}, s = (h) => {
|
|
1862
|
+
i.value = h, n("visible-change", h), !h && r.filterable && (f.value = "", g.value = "", o());
|
|
1863
|
+
}, d = (h) => typeof h == "number" ? `n:${h}` : `s:${h}`, c = Me({}), w = Me({}), k = _(0), v = _(null), S = (h, N, K) => {
|
|
1864
|
+
const ue = d(h);
|
|
1865
|
+
return k.value++, c[ue] = N, w[ue] = K ?? N, () => {
|
|
1866
|
+
k.value--, delete c[ue], delete w[ue];
|
|
1857
1867
|
};
|
|
1858
|
-
},
|
|
1868
|
+
}, O = m(() => k.value === 0);
|
|
1859
1869
|
J(
|
|
1860
1870
|
() => r.modelValue,
|
|
1861
|
-
(
|
|
1862
|
-
if (
|
|
1871
|
+
(h) => {
|
|
1872
|
+
if (h == null || h === "") {
|
|
1863
1873
|
v.value = null;
|
|
1864
1874
|
return;
|
|
1865
1875
|
}
|
|
1866
|
-
v.value && v.value.value !==
|
|
1876
|
+
v.value && v.value.value !== h && (v.value = null);
|
|
1867
1877
|
}
|
|
1868
1878
|
);
|
|
1869
|
-
const $ =
|
|
1870
|
-
const
|
|
1871
|
-
return
|
|
1872
|
-
}),
|
|
1879
|
+
const $ = m(() => {
|
|
1880
|
+
const h = r.modelValue;
|
|
1881
|
+
return h != null && h !== "";
|
|
1882
|
+
}), C = m(() => {
|
|
1873
1883
|
if (!$.value) return "";
|
|
1874
|
-
const
|
|
1875
|
-
return v.value?.value ===
|
|
1876
|
-
}),
|
|
1877
|
-
r.disabled || (v.value = { value:
|
|
1878
|
-
}, f =
|
|
1879
|
-
const
|
|
1880
|
-
return !r.filterable || !
|
|
1881
|
-
}), B =
|
|
1882
|
-
() => r.filterable && !!u.value && !T.value && !
|
|
1884
|
+
const h = r.modelValue;
|
|
1885
|
+
return v.value?.value === h ? v.value.label : c[d(h)] ?? String(h);
|
|
1886
|
+
}), E = (h) => r.modelValue === h, R = (h, N) => {
|
|
1887
|
+
r.disabled || (v.value = { value: h, label: N }, n("update:modelValue", h), n("change", h), a.value?.close());
|
|
1888
|
+
}, f = _(""), g = _(""), u = m(() => g.value.trim().toLowerCase()), T = m(() => {
|
|
1889
|
+
const h = u.value;
|
|
1890
|
+
return !r.filterable || !h ? !0 : Object.keys(c).some((N) => (w[N] ?? c[N]).toLowerCase().includes(h));
|
|
1891
|
+
}), B = m(
|
|
1892
|
+
() => r.filterable && !!u.value && !T.value && !O.value
|
|
1883
1893
|
), D = () => {
|
|
1884
|
-
r.filterable && (o(),
|
|
1885
|
-
|
|
1894
|
+
r.filterable && (o(), l = setTimeout(() => {
|
|
1895
|
+
g.value = f.value.trim(), l = null;
|
|
1886
1896
|
}, r.filterDebounceMs));
|
|
1887
1897
|
};
|
|
1888
1898
|
J(f, () => {
|
|
1889
1899
|
r.filterable && D();
|
|
1890
1900
|
}), J(
|
|
1891
1901
|
() => r.filterable,
|
|
1892
|
-
(
|
|
1893
|
-
|
|
1902
|
+
(h) => {
|
|
1903
|
+
h || (f.value = "", g.value = "", o());
|
|
1894
1904
|
}
|
|
1895
|
-
),
|
|
1896
|
-
const W = (
|
|
1897
|
-
n("filter-input", String(
|
|
1898
|
-
},
|
|
1899
|
-
|
|
1905
|
+
), Ee(() => o());
|
|
1906
|
+
const W = (h) => {
|
|
1907
|
+
n("filter-input", String(h ?? ""));
|
|
1908
|
+
}, y = () => {
|
|
1909
|
+
g.value = "", o(), n("filter-clear");
|
|
1900
1910
|
};
|
|
1901
|
-
|
|
1902
|
-
modelValue:
|
|
1903
|
-
disabled:
|
|
1904
|
-
selectOption:
|
|
1905
|
-
isOptionSelected:
|
|
1906
|
-
registerOption:
|
|
1911
|
+
Ht(cr, {
|
|
1912
|
+
modelValue: m(() => r.modelValue),
|
|
1913
|
+
disabled: m(() => !!r.disabled),
|
|
1914
|
+
selectOption: R,
|
|
1915
|
+
isOptionSelected: E,
|
|
1916
|
+
registerOption: S,
|
|
1907
1917
|
filterQuery: u
|
|
1908
1918
|
});
|
|
1909
|
-
const
|
|
1910
|
-
if (r.popperWidth) return
|
|
1911
|
-
const
|
|
1912
|
-
return typeof
|
|
1913
|
-
}),
|
|
1914
|
-
width:
|
|
1915
|
-
})),
|
|
1916
|
-
|
|
1919
|
+
const A = (h) => typeof h == "number" ? `${h}px` : h, z = m(() => {
|
|
1920
|
+
if (r.popperWidth) return A(r.popperWidth);
|
|
1921
|
+
const h = r.triggerWidth;
|
|
1922
|
+
return typeof h == "number" ? h + 8 : `calc(${h} + 8px)`;
|
|
1923
|
+
}), Y = m(() => typeof z.value == "number" ? `${z.value - 12}px` : `calc(${z.value} - 12px)`), X = m(() => r.align === "center" ? "bottom" : r.align === "left" ? "bottom-start" : "bottom-end"), F = m(() => ({
|
|
1924
|
+
width: A(r.triggerWidth)
|
|
1925
|
+
})), H = m(() => r.size === "large" ? "20px" : r.size === "medium" ? "14px" : "12px"), de = _(0), ce = (h) => {
|
|
1926
|
+
de.value = h.scrollTop;
|
|
1917
1927
|
};
|
|
1918
|
-
return (
|
|
1928
|
+
return (h, N) => (b(), x("div", {
|
|
1919
1929
|
class: j(["cregis-select", { "is-disabled": e.disabled }])
|
|
1920
1930
|
}, [
|
|
1921
|
-
U(
|
|
1931
|
+
U(pt, {
|
|
1922
1932
|
ref_key: "popoverRef",
|
|
1923
1933
|
ref: a,
|
|
1924
1934
|
"preserve-content-mount": "",
|
|
1925
1935
|
"popper-width": z.value,
|
|
1926
|
-
placement:
|
|
1936
|
+
placement: X.value,
|
|
1927
1937
|
disabled: !!e.disabled,
|
|
1928
1938
|
padding: 0,
|
|
1929
1939
|
"max-popper-height": e.maxPopperHeight,
|
|
1930
|
-
onVisibleChange:
|
|
1931
|
-
onScroll:
|
|
1940
|
+
onVisibleChange: s,
|
|
1941
|
+
onScroll: ce
|
|
1932
1942
|
}, {
|
|
1933
1943
|
reference: Z(() => [
|
|
1934
|
-
|
|
1944
|
+
V("div", {
|
|
1935
1945
|
class: j(["cregis-select__trigger", { [`cregis-select__trigger--${e.size}`]: e.size, [`cregis-select__trigger--${e.type}`]: e.type }]),
|
|
1936
|
-
style:
|
|
1946
|
+
style: ie(F.value)
|
|
1937
1947
|
}, [
|
|
1938
|
-
|
|
1939
|
-
$.value ? q(
|
|
1948
|
+
V("div", Rn, [
|
|
1949
|
+
$.value ? q(h.$slots, "label", {
|
|
1940
1950
|
key: 0,
|
|
1941
1951
|
modelValue: e.modelValue,
|
|
1942
|
-
displayText:
|
|
1952
|
+
displayText: C.value,
|
|
1943
1953
|
placeholder: e.placeholder,
|
|
1944
1954
|
hasSelection: $.value
|
|
1945
1955
|
}, () => [
|
|
1946
|
-
|
|
1947
|
-
]) : (
|
|
1956
|
+
V("p", Dn, M(C.value), 1)
|
|
1957
|
+
]) : (b(), x("p", zn, M(e.placeholder), 1))
|
|
1948
1958
|
]),
|
|
1949
|
-
|
|
1959
|
+
V("span", {
|
|
1950
1960
|
class: j(["cregis-select__icon", { "is-open": i.value }])
|
|
1951
1961
|
}, [
|
|
1952
|
-
U(
|
|
1953
|
-
size:
|
|
1962
|
+
U(ne(Kt), {
|
|
1963
|
+
size: H.value,
|
|
1954
1964
|
color: e.disabled ? "var(--text-base-quaternary)" : "var(--material-foreground-base-secondary)"
|
|
1955
1965
|
}, null, 8, ["size", "color"])
|
|
1956
1966
|
], 2)
|
|
1957
1967
|
], 6)
|
|
1958
1968
|
]),
|
|
1959
1969
|
default: Z(() => [
|
|
1960
|
-
|
|
1961
|
-
class: j(["cregis-select__dropdown", { "is-empty":
|
|
1970
|
+
V("div", {
|
|
1971
|
+
class: j(["cregis-select__dropdown", { "is-empty": O.value }])
|
|
1962
1972
|
}, [
|
|
1963
|
-
|
|
1964
|
-
e.filterable ? (
|
|
1973
|
+
O.value ? (b(), x("p", Wn, M(e.noDataText), 1)) : I("", !0),
|
|
1974
|
+
e.filterable ? (b(), x("div", {
|
|
1965
1975
|
key: 1,
|
|
1966
|
-
class: j(["cregis-select__dropdown-filter", { "backdrop-fixed-header":
|
|
1976
|
+
class: j(["cregis-select__dropdown-filter", { "backdrop-fixed-header": de.value > 10 }])
|
|
1967
1977
|
}, [
|
|
1968
|
-
U(
|
|
1978
|
+
U(Qt, {
|
|
1969
1979
|
modelValue: f.value,
|
|
1970
|
-
"onUpdate:modelValue":
|
|
1980
|
+
"onUpdate:modelValue": N[0] || (N[0] = (K) => f.value = K),
|
|
1971
1981
|
placeholder: "search",
|
|
1972
|
-
width:
|
|
1982
|
+
width: Y.value,
|
|
1973
1983
|
size: "small",
|
|
1974
1984
|
clearable: "",
|
|
1975
1985
|
onInput: W,
|
|
1976
|
-
onClear:
|
|
1986
|
+
onClear: y
|
|
1977
1987
|
}, {
|
|
1978
1988
|
prefix: Z(() => [
|
|
1979
|
-
U(
|
|
1989
|
+
U(ne(Xt), { size: "14px" })
|
|
1980
1990
|
]),
|
|
1981
1991
|
_: 1
|
|
1982
1992
|
}, 8, ["modelValue", "width"])
|
|
1983
1993
|
], 2)) : I("", !0),
|
|
1984
|
-
B.value ? (
|
|
1985
|
-
|
|
1986
|
-
q(
|
|
1994
|
+
B.value ? (b(), x("p", Ln, M(e.noMatchText), 1)) : I("", !0),
|
|
1995
|
+
V("div", jn, [
|
|
1996
|
+
q(h.$slots, "default")
|
|
1987
1997
|
])
|
|
1988
1998
|
], 2)
|
|
1989
1999
|
]),
|
|
@@ -1991,7 +2001,7 @@ const Vn = (e, t) => {
|
|
|
1991
2001
|
}, 8, ["popper-width", "placement", "disabled", "max-popper-height"])
|
|
1992
2002
|
], 2));
|
|
1993
2003
|
}
|
|
1994
|
-
}),
|
|
2004
|
+
}), Mn = ["aria-selected"], ci = /* @__PURE__ */ G({
|
|
1995
2005
|
name: "Option",
|
|
1996
2006
|
__name: "Option",
|
|
1997
2007
|
props: {
|
|
@@ -2001,49 +2011,52 @@ const Vn = (e, t) => {
|
|
|
2001
2011
|
filterText: {}
|
|
2002
2012
|
},
|
|
2003
2013
|
setup(e) {
|
|
2004
|
-
const t = e, r =
|
|
2014
|
+
const t = e, r = qt(cr, null);
|
|
2005
2015
|
let n;
|
|
2006
2016
|
const a = () => t.filterText ?? t.label, i = () => {
|
|
2007
2017
|
n?.(), r && (n = r.registerOption(t.value, t.label, a()));
|
|
2008
2018
|
};
|
|
2009
|
-
|
|
2010
|
-
const
|
|
2019
|
+
et(i), Ee(() => n?.()), J(() => [t.value, t.label, t.filterText], i);
|
|
2020
|
+
const l = m(() => r?.isOptionSelected(t.value) ?? !1), o = () => {
|
|
2011
2021
|
t.disabled || r?.disabled.value || r?.selectOption(t.value, t.label);
|
|
2012
|
-
},
|
|
2013
|
-
const c =
|
|
2022
|
+
}, s = m(() => r?.filterQuery?.value ?? ""), d = m(() => {
|
|
2023
|
+
const c = s.value;
|
|
2014
2024
|
return c ? a().toLowerCase().includes(c) : !0;
|
|
2015
2025
|
});
|
|
2016
|
-
return (c, w) =>
|
|
2017
|
-
class: j(["cregis-select__option", { "is-selected":
|
|
2026
|
+
return (c, w) => je((b(), x("div", {
|
|
2027
|
+
class: j(["cregis-select__option", { "is-selected": l.value, "is-disabled": e.disabled }]),
|
|
2018
2028
|
role: "option",
|
|
2019
|
-
"aria-selected":
|
|
2029
|
+
"aria-selected": l.value,
|
|
2020
2030
|
onClick: o
|
|
2021
2031
|
}, [
|
|
2022
2032
|
q(c.$slots, "default", {
|
|
2023
2033
|
label: e.label,
|
|
2024
2034
|
value: e.value,
|
|
2025
2035
|
disabled: !!e.disabled,
|
|
2026
|
-
selected:
|
|
2036
|
+
selected: l.value
|
|
2027
2037
|
}, () => [
|
|
2028
|
-
|
|
2038
|
+
$e(M(e.label), 1)
|
|
2029
2039
|
])
|
|
2030
|
-
], 10,
|
|
2031
|
-
[
|
|
2040
|
+
], 10, Mn)), [
|
|
2041
|
+
[mt, d.value]
|
|
2032
2042
|
]);
|
|
2033
2043
|
}
|
|
2034
|
-
}),
|
|
2044
|
+
}), _n = { class: "cregis-cascader__trigger-label" }, In = { class: "cregis-cascader__selected" }, Nn = {
|
|
2035
2045
|
key: 1,
|
|
2036
2046
|
class: "cregis-cascader__placeholder"
|
|
2037
|
-
},
|
|
2047
|
+
}, Fn = {
|
|
2038
2048
|
key: 0,
|
|
2039
2049
|
class: "cregis-cascader__dropdown-empty"
|
|
2040
|
-
},
|
|
2050
|
+
}, Hn = {
|
|
2041
2051
|
key: 2,
|
|
2042
2052
|
class: "cregis-cascader__dropdown-filter-empty"
|
|
2043
|
-
},
|
|
2053
|
+
}, qn = { class: "cregis-cascader__dropdown-content" }, Un = {
|
|
2044
2054
|
key: 0,
|
|
2045
2055
|
class: "cregis-cascader__dropdown-item-popover"
|
|
2046
|
-
},
|
|
2056
|
+
}, Yn = { class: "cregis-cascader__suboption-amount-container" }, Xn = {
|
|
2057
|
+
key: 0,
|
|
2058
|
+
class: "cregis-cascader__suboption-amount"
|
|
2059
|
+
}, Kn = { class: "cregis-cascader__suboption-panel" }, Qn = ["onClick"], Gn = ["onClick"], ui = /* @__PURE__ */ G({
|
|
2047
2060
|
name: "Cascader",
|
|
2048
2061
|
__name: "Cascader",
|
|
2049
2062
|
props: {
|
|
@@ -2061,42 +2074,44 @@ const Vn = (e, t) => {
|
|
|
2061
2074
|
triggerWidth: { default: "296px" },
|
|
2062
2075
|
popperWidth: {},
|
|
2063
2076
|
subPopperWidth: { default: "200px" },
|
|
2064
|
-
maxPopperHeight: {}
|
|
2077
|
+
maxPopperHeight: { default: 300 },
|
|
2078
|
+
offset: { default: () => [0, 0] },
|
|
2079
|
+
showSubOptionAmount: { type: Boolean, default: !0 }
|
|
2065
2080
|
},
|
|
2066
2081
|
emits: ["update:modelValue", "change", "visible-change", "filter-input", "filter-clear"],
|
|
2067
2082
|
setup(e, { emit: t }) {
|
|
2068
|
-
const r = e, n = t, a =
|
|
2069
|
-
let
|
|
2083
|
+
const r = e, n = t, a = _(null), i = _(!1);
|
|
2084
|
+
let l = null;
|
|
2070
2085
|
const o = () => {
|
|
2071
|
-
|
|
2072
|
-
},
|
|
2073
|
-
r.filterable && (o(),
|
|
2074
|
-
d.value =
|
|
2086
|
+
l !== null && (clearTimeout(l), l = null);
|
|
2087
|
+
}, s = _(""), d = _(""), c = m(() => d.value.trim().toLowerCase()), w = () => {
|
|
2088
|
+
r.filterable && (o(), l = setTimeout(() => {
|
|
2089
|
+
d.value = s.value.trim(), l = null;
|
|
2075
2090
|
}, r.filterDebounceMs));
|
|
2076
2091
|
};
|
|
2077
|
-
J(
|
|
2092
|
+
J(s, () => {
|
|
2078
2093
|
r.filterable && w();
|
|
2079
2094
|
}), J(
|
|
2080
2095
|
() => r.filterable,
|
|
2081
2096
|
(p) => {
|
|
2082
|
-
p || (
|
|
2097
|
+
p || (s.value = "", d.value = "", o());
|
|
2083
2098
|
}
|
|
2084
|
-
),
|
|
2099
|
+
), Ee(() => o());
|
|
2085
2100
|
const k = (p) => {
|
|
2086
2101
|
n("filter-input", String(p ?? ""));
|
|
2087
2102
|
}, v = () => {
|
|
2088
2103
|
d.value = "", o(), n("filter-clear");
|
|
2089
|
-
},
|
|
2104
|
+
}, S = (p) => (p.filterText ?? p.label).toLowerCase(), O = (p) => {
|
|
2090
2105
|
const L = c.value;
|
|
2091
|
-
return !L ||
|
|
2106
|
+
return !L || S(p).includes(L) ? !0 : (p.children ?? []).some((ae) => S(ae).includes(L));
|
|
2092
2107
|
}, $ = (p, L) => {
|
|
2093
2108
|
const P = c.value;
|
|
2094
|
-
return !P ||
|
|
2095
|
-
},
|
|
2096
|
-
() => r.filterable && !!d.value.trim() && !
|
|
2097
|
-
),
|
|
2098
|
-
i.value = p, n("visible-change", p), !p && r.filterable && (
|
|
2099
|
-
}, u =
|
|
2109
|
+
return !P || S(p).includes(P) ? !0 : S(L).includes(P);
|
|
2110
|
+
}, C = m(() => r.options.filter((p) => O(p))), E = m(() => r.options.length === 0), R = m(() => (c.value, r.options.some((p) => O(p)))), f = m(
|
|
2111
|
+
() => r.filterable && !!d.value.trim() && !R.value && !E.value
|
|
2112
|
+
), g = (p) => {
|
|
2113
|
+
i.value = p, n("visible-change", p), !p && r.filterable && (s.value = "", d.value = "", o());
|
|
2114
|
+
}, u = _(null), T = (p) => {
|
|
2100
2115
|
const L = r.options.find((P) => P.value === p);
|
|
2101
2116
|
if (L)
|
|
2102
2117
|
return {
|
|
@@ -2106,13 +2121,13 @@ const Vn = (e, t) => {
|
|
|
2106
2121
|
sub: void 0
|
|
2107
2122
|
};
|
|
2108
2123
|
for (const P of r.options) {
|
|
2109
|
-
const
|
|
2110
|
-
if (
|
|
2124
|
+
const ae = P.children?.find((Q) => Q.value === p);
|
|
2125
|
+
if (ae)
|
|
2111
2126
|
return {
|
|
2112
2127
|
level: 2,
|
|
2113
|
-
label:
|
|
2128
|
+
label: ae.label,
|
|
2114
2129
|
primary: P,
|
|
2115
|
-
sub:
|
|
2130
|
+
sub: ae
|
|
2116
2131
|
};
|
|
2117
2132
|
}
|
|
2118
2133
|
return {
|
|
@@ -2121,7 +2136,7 @@ const Vn = (e, t) => {
|
|
|
2121
2136
|
primary: void 0,
|
|
2122
2137
|
sub: void 0
|
|
2123
2138
|
};
|
|
2124
|
-
}, B =
|
|
2139
|
+
}, B = m(() => {
|
|
2125
2140
|
const p = r.modelValue;
|
|
2126
2141
|
return p == null || p === "" ? {
|
|
2127
2142
|
level: 0,
|
|
@@ -2145,79 +2160,96 @@ const Vn = (e, t) => {
|
|
|
2145
2160
|
u.value !== null && u.value.value !== p && (u.value = null);
|
|
2146
2161
|
}
|
|
2147
2162
|
);
|
|
2148
|
-
const D =
|
|
2163
|
+
const D = m(() => B.value.level > 0), W = m(() => B.value.label), y = m(() => r.modelValue), A = m(() => W.value), z = m(() => B.value.level), Y = m(() => B.value.primary), X = m(() => B.value.sub), F = (p) => (p.children?.length ?? 0) > 0, H = (p) => r.modelValue === p, de = (p) => {
|
|
2149
2164
|
const L = r.modelValue;
|
|
2150
2165
|
return L == null || L === "" ? !1 : (p.children ?? []).some((P) => P.value === L);
|
|
2151
|
-
},
|
|
2166
|
+
}, ce = (p, L) => {
|
|
2152
2167
|
r.disabled || p.disabled || L.disabled || (u.value = { value: L.value, label: L.label, level: 2, primary: p, sub: L }, n("update:modelValue", L.value), n("change", L.value), a.value?.close());
|
|
2153
|
-
},
|
|
2154
|
-
r.disabled || p.disabled ||
|
|
2155
|
-
},
|
|
2168
|
+
}, h = (p) => {
|
|
2169
|
+
r.disabled || p.disabled || F(p) || (u.value = { value: p.value, label: p.label, level: 1, primary: p }, n("update:modelValue", p.value), n("change", p.value), a.value?.close());
|
|
2170
|
+
}, N = (p) => typeof p == "number" ? `${p}px` : p, K = m(() => {
|
|
2156
2171
|
if (r.popperWidth !== void 0 && r.popperWidth !== null && r.popperWidth !== "")
|
|
2157
|
-
return
|
|
2172
|
+
return N(r.popperWidth);
|
|
2158
2173
|
const p = r.triggerWidth;
|
|
2159
2174
|
return typeof p == "number" ? `${p + 8}px` : `calc(${p} + 8px)`;
|
|
2160
|
-
}),
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2175
|
+
}), ue = m(() => N(r.subPopperWidth)), he = m(() => typeof K.value == "number" ? `${K.value - 12}px` : `calc(${K.value} - 12px)`), fe = m(() => ({
|
|
2176
|
+
maxHeight: N(r.maxPopperHeight),
|
|
2177
|
+
overflowY: "auto"
|
|
2178
|
+
})), ye = { strategy: "fixed" }, Te = m(() => r.align === "center" ? "bottom" : r.align === "left" ? "bottom-start" : "bottom-end"), me = m(() => ({
|
|
2179
|
+
width: N(r.triggerWidth)
|
|
2180
|
+
})), Be = m(() => r.size === "large" ? "20px" : r.size === "medium" ? "14px" : "12px"), He = _(0), Ae = (p) => {
|
|
2181
|
+
const L = p.target;
|
|
2182
|
+
He.value = L.scrollTop;
|
|
2183
|
+
}, rt = [-16, -8];
|
|
2184
|
+
return (p, L) => (b(), x("div", {
|
|
2166
2185
|
class: j(["cregis-cascader", { "is-disabled": e.disabled }])
|
|
2167
2186
|
}, [
|
|
2168
|
-
U(
|
|
2187
|
+
U(pt, {
|
|
2169
2188
|
ref_key: "popoverRef",
|
|
2170
2189
|
ref: a,
|
|
2171
2190
|
"preserve-content-mount": "",
|
|
2172
|
-
"popper-width":
|
|
2173
|
-
placement:
|
|
2191
|
+
"popper-width": K.value,
|
|
2192
|
+
placement: Te.value,
|
|
2193
|
+
offset: e.offset,
|
|
2174
2194
|
disabled: !!e.disabled,
|
|
2175
2195
|
padding: 0,
|
|
2176
|
-
|
|
2177
|
-
onVisibleChange: m,
|
|
2178
|
-
onScroll: Be
|
|
2196
|
+
onVisibleChange: g
|
|
2179
2197
|
}, {
|
|
2180
2198
|
reference: Z(() => [
|
|
2181
|
-
|
|
2199
|
+
p.$slots.trigger ? q(p.$slots, "trigger", {
|
|
2200
|
+
key: 0,
|
|
2201
|
+
modelValue: y.value,
|
|
2202
|
+
selectedLabel: A.value,
|
|
2203
|
+
level: z.value,
|
|
2204
|
+
primaryOption: Y.value,
|
|
2205
|
+
subOption: X.value,
|
|
2206
|
+
placeholder: e.placeholder,
|
|
2207
|
+
hasSelection: D.value,
|
|
2208
|
+
open: i.value,
|
|
2209
|
+
disabled: !!e.disabled
|
|
2210
|
+
}) : (b(), x("div", {
|
|
2211
|
+
key: 1,
|
|
2182
2212
|
class: j(["cregis-cascader__trigger", { [`cregis-cascader__trigger--${e.size}`]: e.size, [`cregis-cascader__trigger--${e.type}`]: e.type }]),
|
|
2183
|
-
style:
|
|
2213
|
+
style: ie(me.value)
|
|
2184
2214
|
}, [
|
|
2185
|
-
|
|
2215
|
+
V("div", _n, [
|
|
2186
2216
|
D.value ? q(p.$slots, "label", {
|
|
2187
2217
|
key: 0,
|
|
2188
|
-
modelValue:
|
|
2189
|
-
selectedLabel:
|
|
2218
|
+
modelValue: y.value,
|
|
2219
|
+
selectedLabel: A.value,
|
|
2190
2220
|
level: z.value,
|
|
2191
|
-
primaryOption:
|
|
2192
|
-
subOption:
|
|
2221
|
+
primaryOption: Y.value,
|
|
2222
|
+
subOption: X.value,
|
|
2193
2223
|
placeholder: e.placeholder,
|
|
2194
2224
|
hasSelection: D.value
|
|
2195
2225
|
}, () => [
|
|
2196
|
-
|
|
2197
|
-
]) : (
|
|
2226
|
+
V("p", In, M(W.value), 1)
|
|
2227
|
+
]) : (b(), x("p", Nn, M(e.placeholder), 1))
|
|
2198
2228
|
]),
|
|
2199
|
-
|
|
2229
|
+
V("span", {
|
|
2200
2230
|
class: j(["cregis-cascader__icon", { "is-open": i.value }])
|
|
2201
2231
|
}, [
|
|
2202
|
-
U(
|
|
2203
|
-
size:
|
|
2232
|
+
U(ne(Kt), {
|
|
2233
|
+
size: Be.value,
|
|
2204
2234
|
color: e.disabled ? "var(--text-base-quaternary)" : "var(--material-foreground-base-secondary)"
|
|
2205
2235
|
}, null, 8, ["size", "color"])
|
|
2206
2236
|
], 2)
|
|
2207
|
-
], 6)
|
|
2237
|
+
], 6))
|
|
2208
2238
|
]),
|
|
2209
2239
|
default: Z(() => [
|
|
2210
|
-
|
|
2211
|
-
class: j(["cregis-cascader__dropdown", { "is-empty":
|
|
2240
|
+
V("div", {
|
|
2241
|
+
class: j(["cregis-cascader__dropdown", { "is-empty": E.value }]),
|
|
2242
|
+
style: ie(fe.value),
|
|
2243
|
+
onScroll: Ae
|
|
2212
2244
|
}, [
|
|
2213
|
-
|
|
2214
|
-
e.filterable ? (
|
|
2245
|
+
E.value ? (b(), x("p", Fn, M(e.noDataText), 1)) : I("", !0),
|
|
2246
|
+
e.filterable ? (b(), x("div", {
|
|
2215
2247
|
key: 1,
|
|
2216
|
-
class: j(["cregis-cascader__dropdown-filter", { "backdrop-fixed-header":
|
|
2248
|
+
class: j(["cregis-cascader__dropdown-filter", { "backdrop-fixed-header": He.value > 10 }])
|
|
2217
2249
|
}, [
|
|
2218
|
-
U(
|
|
2219
|
-
modelValue:
|
|
2220
|
-
"onUpdate:modelValue": L[0] || (L[0] = (P) =>
|
|
2250
|
+
U(Qt, {
|
|
2251
|
+
modelValue: s.value,
|
|
2252
|
+
"onUpdate:modelValue": L[0] || (L[0] = (P) => s.value = P),
|
|
2221
2253
|
placeholder: "search",
|
|
2222
2254
|
width: he.value,
|
|
2223
2255
|
size: "small",
|
|
@@ -2226,131 +2258,134 @@ const Vn = (e, t) => {
|
|
|
2226
2258
|
onClear: v
|
|
2227
2259
|
}, {
|
|
2228
2260
|
prefix: Z(() => [
|
|
2229
|
-
U(
|
|
2261
|
+
U(ne(Xt), { size: "14px" })
|
|
2230
2262
|
]),
|
|
2231
2263
|
_: 1
|
|
2232
2264
|
}, 8, ["modelValue", "width"])
|
|
2233
2265
|
], 2)) : I("", !0),
|
|
2234
|
-
f.value ? (
|
|
2235
|
-
|
|
2236
|
-
(
|
|
2266
|
+
f.value ? (b(), x("p", Hn, M(e.noMatchText), 1)) : I("", !0),
|
|
2267
|
+
V("ul", qn, [
|
|
2268
|
+
(b(!0), x(lt, null, ct(C.value, (P, ae) => (b(), x("li", {
|
|
2237
2269
|
key: P.value,
|
|
2238
2270
|
class: j(["cregis-cascader__dropdown-item", { "is-disabled": P.disabled }])
|
|
2239
2271
|
}, [
|
|
2240
|
-
|
|
2241
|
-
U(
|
|
2272
|
+
F(P) ? (b(), x("div", Un, [
|
|
2273
|
+
U(pt, {
|
|
2242
2274
|
trigger: "hover",
|
|
2243
2275
|
placement: "right-start",
|
|
2244
|
-
offset:
|
|
2245
|
-
"
|
|
2276
|
+
offset: rt,
|
|
2277
|
+
"popover-options": ye,
|
|
2278
|
+
"popper-width": ue.value,
|
|
2246
2279
|
padding: 4,
|
|
2247
2280
|
disabled: !!P.disabled || !!e.disabled
|
|
2248
2281
|
}, {
|
|
2249
2282
|
reference: Z(() => [
|
|
2250
|
-
|
|
2283
|
+
V("div", {
|
|
2251
2284
|
class: j(["cregis-cascader__suboption-trigger", {
|
|
2252
2285
|
"is-disabled": P.disabled,
|
|
2253
|
-
"is-parent-active":
|
|
2286
|
+
"is-parent-active": de(P)
|
|
2254
2287
|
}])
|
|
2255
2288
|
}, [
|
|
2256
2289
|
q(p.$slots, "option", {
|
|
2257
|
-
modelValue:
|
|
2258
|
-
selectedLabel:
|
|
2290
|
+
modelValue: y.value,
|
|
2291
|
+
selectedLabel: A.value,
|
|
2259
2292
|
level: z.value,
|
|
2260
|
-
primaryOption:
|
|
2261
|
-
subOption:
|
|
2293
|
+
primaryOption: Y.value,
|
|
2294
|
+
subOption: X.value,
|
|
2262
2295
|
option: P,
|
|
2263
|
-
index:
|
|
2296
|
+
index: ae,
|
|
2264
2297
|
disabled: !!P.disabled,
|
|
2265
|
-
selected:
|
|
2266
|
-
isParentOfSelected:
|
|
2298
|
+
selected: H(P.value),
|
|
2299
|
+
isParentOfSelected: de(P)
|
|
2267
2300
|
}, () => [
|
|
2268
|
-
|
|
2301
|
+
V("p", null, M(P.label), 1)
|
|
2269
2302
|
]),
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2303
|
+
V("div", Yn, [
|
|
2304
|
+
e.showSubOptionAmount ? (b(), x("div", Xn, M(P.children.length), 1)) : I("", !0),
|
|
2305
|
+
U(ne(br), {
|
|
2306
|
+
size: "14px",
|
|
2307
|
+
color: "currentColor"
|
|
2308
|
+
})
|
|
2309
|
+
])
|
|
2275
2310
|
], 2)
|
|
2276
2311
|
]),
|
|
2277
2312
|
default: Z(() => [
|
|
2278
|
-
|
|
2279
|
-
(
|
|
2280
|
-
key:
|
|
2313
|
+
V("div", Kn, [
|
|
2314
|
+
(b(!0), x(lt, null, ct(P.children, (Q, at) => je((b(), x("div", {
|
|
2315
|
+
key: Q.value,
|
|
2281
2316
|
class: j(["cregis-cascader__suboption-row", {
|
|
2282
|
-
"is-active":
|
|
2283
|
-
"is-disabled":
|
|
2317
|
+
"is-active": H(Q.value),
|
|
2318
|
+
"is-disabled": Q.disabled
|
|
2284
2319
|
}]),
|
|
2285
2320
|
role: "menuitem",
|
|
2286
|
-
onClick: (
|
|
2321
|
+
onClick: ($t) => ce(P, Q)
|
|
2287
2322
|
}, [
|
|
2288
2323
|
q(p.$slots, "subOption", {
|
|
2289
|
-
modelValue:
|
|
2290
|
-
selectedLabel:
|
|
2324
|
+
modelValue: y.value,
|
|
2325
|
+
selectedLabel: A.value,
|
|
2291
2326
|
level: z.value,
|
|
2292
|
-
primaryOption:
|
|
2293
|
-
subOption:
|
|
2294
|
-
option:
|
|
2295
|
-
index:
|
|
2327
|
+
primaryOption: Y.value,
|
|
2328
|
+
subOption: X.value,
|
|
2329
|
+
option: Q,
|
|
2330
|
+
index: at,
|
|
2296
2331
|
parent: P,
|
|
2297
|
-
parentIndex:
|
|
2298
|
-
selected:
|
|
2299
|
-
disabled: !!
|
|
2332
|
+
parentIndex: ae,
|
|
2333
|
+
selected: H(Q.value),
|
|
2334
|
+
disabled: !!Q.disabled
|
|
2300
2335
|
}, () => [
|
|
2301
|
-
|
|
2336
|
+
$e(M(Q.label), 1)
|
|
2302
2337
|
])
|
|
2303
|
-
], 10,
|
|
2304
|
-
[
|
|
2338
|
+
], 10, Qn)), [
|
|
2339
|
+
[mt, $(P, Q)]
|
|
2305
2340
|
])), 128))
|
|
2306
2341
|
])
|
|
2307
2342
|
]),
|
|
2308
2343
|
_: 2
|
|
2309
2344
|
}, 1032, ["popper-width", "disabled"])
|
|
2310
|
-
])) : (
|
|
2345
|
+
])) : (b(), x("div", {
|
|
2311
2346
|
key: 1,
|
|
2312
2347
|
class: "cregis-cascader__leaf-only",
|
|
2313
|
-
onClick: (
|
|
2348
|
+
onClick: (Q) => h(P)
|
|
2314
2349
|
}, [
|
|
2315
2350
|
q(p.$slots, "option", {
|
|
2316
|
-
modelValue:
|
|
2317
|
-
selectedLabel:
|
|
2351
|
+
modelValue: y.value,
|
|
2352
|
+
selectedLabel: A.value,
|
|
2318
2353
|
level: z.value,
|
|
2319
|
-
primaryOption:
|
|
2320
|
-
subOption:
|
|
2354
|
+
primaryOption: Y.value,
|
|
2355
|
+
subOption: X.value,
|
|
2321
2356
|
option: P,
|
|
2322
|
-
index:
|
|
2357
|
+
index: ae,
|
|
2323
2358
|
disabled: !!P.disabled,
|
|
2324
|
-
selected:
|
|
2359
|
+
selected: H(P.value),
|
|
2325
2360
|
isParentOfSelected: !1
|
|
2326
2361
|
}, () => [
|
|
2327
|
-
|
|
2362
|
+
V("p", null, M(P.label), 1)
|
|
2328
2363
|
])
|
|
2329
|
-
], 8,
|
|
2364
|
+
], 8, Gn))
|
|
2330
2365
|
], 2))), 128))
|
|
2331
2366
|
])
|
|
2332
|
-
],
|
|
2367
|
+
], 38)
|
|
2333
2368
|
]),
|
|
2334
2369
|
_: 3
|
|
2335
|
-
}, 8, ["popper-width", "placement", "
|
|
2370
|
+
}, 8, ["popper-width", "placement", "offset", "disabled"])
|
|
2336
2371
|
], 2));
|
|
2337
2372
|
}
|
|
2338
2373
|
});
|
|
2339
2374
|
export {
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2375
|
+
Ye as Button,
|
|
2376
|
+
ui as Cascader,
|
|
2377
|
+
ei as Checkbox,
|
|
2378
|
+
ri as Divider,
|
|
2379
|
+
Qt as Input,
|
|
2380
|
+
ii as Message,
|
|
2381
|
+
oi as Notification,
|
|
2382
|
+
ci as Option,
|
|
2383
|
+
pt as Popover,
|
|
2384
|
+
si as Progress,
|
|
2385
|
+
ti as Radio,
|
|
2386
|
+
li as Select,
|
|
2387
|
+
Gt as TABS_KEY,
|
|
2388
|
+
ni as TabPane,
|
|
2389
|
+
ai as Tabs,
|
|
2390
|
+
cr as selectInjectKey
|
|
2356
2391
|
};
|