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