@eodash/eodash 5.0.0-alpha.1.9 → 5.0.0-alpha.2.1
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/LICENSE +21 -0
- package/README.md +1 -1
- package/bin/cli.js +15 -8
- package/bin/main.js +9 -0
- package/bin/serverConfig.js +58 -29
- package/bin/types.d.ts +52 -0
- package/bin/utils.js +70 -20
- package/core/App.vue +10 -12
- package/core/SuspensedDashboard.ce.vue +65 -0
- package/core/asWebComponent.d.ts +18 -0
- package/core/asWebComponent.js +12 -0
- package/core/components/DashboardLayout.vue +11 -25
- package/core/components/DynamicWebComponent.vue +6 -6
- package/core/components/Footer.vue +11 -12
- package/core/components/Header.vue +5 -29
- package/core/components/Loading.vue +27 -0
- package/core/components/MobileLayout.vue +34 -63
- package/core/composables/DefineEodash.js +57 -0
- package/core/composables/DefineWidgets.js +26 -15
- package/core/composables/index.js +139 -67
- package/core/eodash.js +100 -0
- package/core/main.js +2 -4
- package/core/plugins/index.js +3 -12
- package/core/plugins/vuetify.js +5 -2
- package/core/store/Actions.js +0 -28
- package/core/store/States.js +12 -3
- package/core/store/stac.js +7 -5
- package/core/types.d.ts +149 -124
- package/core/utils/eodashSTAC.js +164 -0
- package/core/utils/helpers.js +40 -0
- package/core/utils/index.js +28 -0
- package/core/utils/keys.js +6 -0
- package/core/views/Dashboard.vue +33 -23
- package/core/vite-env.d.ts +16 -2
- package/dist/.gitkeep +0 -0
- package/dist/DashboardLayout-Dp8AnYD9.js +141 -0
- package/dist/DynamicWebComponent-BrHVTesn.js +57 -0
- package/dist/EodashDatePicker-D_udZ26j.js +1645 -0
- package/dist/EodashItemFilter-BLAGx2UD.js +51 -0
- package/dist/EodashMap-Bxl_aqY2.js +53405 -0
- package/dist/Footer-AohCH8U7.js +118 -0
- package/dist/Header-DC50S6GR.js +609 -0
- package/dist/IframeWrapper-Dd9zrX9s.js +19 -0
- package/dist/MobileLayout-CgToA7Gp.js +523 -0
- package/dist/VBtn-Bz7ruRUg.js +1106 -0
- package/dist/VMain-BHfWJU2j.js +35 -0
- package/dist/WidgetsContainer-DxfCu0I3.js +122 -0
- package/dist/_commonjsHelpers-DaMA6jEr.js +8 -0
- package/dist/asWebComponent-C8rb3b1D.js +11323 -0
- package/dist/basedecoder-Qm25PwVp-CHo5Pomv.js +89 -0
- package/dist/color-DpYEub1f.js +115 -0
- package/dist/decoder-kAoyGIq9-BBR5CgzS.js +10 -0
- package/dist/deflate-Be2Arps5-hDqMz3RA.js +10 -0
- package/dist/dimensions-CJaGeSrj.js +53 -0
- package/dist/eo-dash.js +6 -0
- package/dist/eox-itemfilter-DcQkRD2l.js +7537 -0
- package/dist/eox-map-BJ9SIixs.js +36205 -0
- package/dist/eox-stacinfo-B-YrT7Ug.js +13698 -0
- package/dist/forwardRefs-Bxeu9Obx.js +142 -0
- package/dist/index-DTkOfh2g.js +152 -0
- package/dist/index-Sa2Vg_gx.js +65 -0
- package/dist/jpeg-DNfUpLwy-Fjan-04T.js +515 -0
- package/dist/lerc-C9VL9kri-cIdbW0sg.js +1029 -0
- package/dist/lzw-BOMhmEDy-Dboc93VO.js +84 -0
- package/dist/packbits-DaUD6MLm-Bu1PoTGa.js +24 -0
- package/dist/pako.esm-C3kYPGGQ-BMki8cQY.js +1087 -0
- package/dist/raw-CcGKjn8q-DFOt-i8n.js +9 -0
- package/dist/ssrBoot-D-b4-M19.js +17 -0
- package/dist/style.css +5 -0
- package/dist/webfontloader-CyOFAuFB.js +471 -0
- package/dist/webimage-D2c098k3-DLj1LQxB.js +19 -0
- package/package.json +40 -12
- package/widgets/EodashDatePicker.vue +56 -0
- package/widgets/EodashItemFilter.vue +60 -0
- package/widgets/EodashMap.vue +82 -0
- package/widgets/WidgetsContainer.vue +1 -1
- package/core/composables/DefineConfig.js +0 -45
- package/core/eodashConfig.js +0 -136
- package/core/plugins/router.js +0 -20
- package/core/store/Keys.js +0 -6
|
@@ -0,0 +1,1106 @@
|
|
|
1
|
+
import { an as j, p as w, af as z, c as r, a as d, F as Ge, J, b as N, e as O, _ as A, g as E, $ as D, q as Fe, t as L, u as P, U as ee, ag as Xe, ao as he, y as qe, Y as te, w as ne, ap as He, n as ye, C as Ue, aq as be, ab as Ye, ar as We, a0 as je, m as Je, as as Ke, v as _, I as K, r as ae, at as Ze, au as Qe, av as et, s as tt, W as nt, i as at, a3 as st, f as pe, aw as lt, H as it, ax as re, X as ot, x as rt, ay as ue, M as ut, Z as ct } from "./asWebComponent-C8rb3b1D.js";
|
|
2
|
+
import { g as dt, c as Ce, d as ke, m as se, e as _e, f as we, b as le, u as F, a as ce } from "./color-DpYEub1f.js";
|
|
3
|
+
import { m as vt, u as ft, V as Y } from "./dimensions-CJaGeSrj.js";
|
|
4
|
+
const mt = ["top", "bottom"], gt = ["start", "end", "left", "right"];
|
|
5
|
+
function ht(e, t) {
|
|
6
|
+
let [n, a] = e.split(" ");
|
|
7
|
+
return a || (a = j(mt, n) ? "start" : j(gt, n) ? "top" : "center"), {
|
|
8
|
+
side: de(n, t),
|
|
9
|
+
align: de(a, t)
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
function de(e, t) {
|
|
13
|
+
return e === "start" ? t ? "right" : "left" : e === "end" ? t ? "left" : "right" : e;
|
|
14
|
+
}
|
|
15
|
+
const yt = [null, "default", "comfortable", "compact"], Se = w({
|
|
16
|
+
density: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: "default",
|
|
19
|
+
validator: (e) => yt.includes(e)
|
|
20
|
+
}
|
|
21
|
+
}, "density");
|
|
22
|
+
function xe(e) {
|
|
23
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : z();
|
|
24
|
+
return {
|
|
25
|
+
densityClasses: r(() => `${t}--density-${e.density}`)
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
const bt = ["elevated", "flat", "tonal", "outlined", "text", "plain"];
|
|
29
|
+
function pt(e, t) {
|
|
30
|
+
return d(Ge, null, [e && d("span", {
|
|
31
|
+
key: "overlay",
|
|
32
|
+
class: `${t}__overlay`
|
|
33
|
+
}, null), d("span", {
|
|
34
|
+
key: "underlay",
|
|
35
|
+
class: `${t}__underlay`
|
|
36
|
+
}, null)]);
|
|
37
|
+
}
|
|
38
|
+
const Ie = w({
|
|
39
|
+
color: String,
|
|
40
|
+
variant: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: "elevated",
|
|
43
|
+
validator: (e) => bt.includes(e)
|
|
44
|
+
}
|
|
45
|
+
}, "variant");
|
|
46
|
+
function Ct(e) {
|
|
47
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : z();
|
|
48
|
+
const n = r(() => {
|
|
49
|
+
const {
|
|
50
|
+
variant: l
|
|
51
|
+
} = J(e);
|
|
52
|
+
return `${t}--variant-${l}`;
|
|
53
|
+
}), {
|
|
54
|
+
colorClasses: a,
|
|
55
|
+
colorStyles: s
|
|
56
|
+
} = dt(r(() => {
|
|
57
|
+
const {
|
|
58
|
+
variant: l,
|
|
59
|
+
color: i
|
|
60
|
+
} = J(e);
|
|
61
|
+
return {
|
|
62
|
+
[["elevated", "flat"].includes(l) ? "background" : "text"]: i
|
|
63
|
+
};
|
|
64
|
+
}));
|
|
65
|
+
return {
|
|
66
|
+
colorClasses: a,
|
|
67
|
+
colorStyles: s,
|
|
68
|
+
variantClasses: n
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
const Le = w({
|
|
72
|
+
divided: Boolean,
|
|
73
|
+
...Ce(),
|
|
74
|
+
...N(),
|
|
75
|
+
...Se(),
|
|
76
|
+
...ke(),
|
|
77
|
+
...se(),
|
|
78
|
+
...O(),
|
|
79
|
+
...A(),
|
|
80
|
+
...Ie()
|
|
81
|
+
}, "VBtnGroup"), ve = E()({
|
|
82
|
+
name: "VBtnGroup",
|
|
83
|
+
props: Le(),
|
|
84
|
+
setup(e, t) {
|
|
85
|
+
let {
|
|
86
|
+
slots: n
|
|
87
|
+
} = t;
|
|
88
|
+
const {
|
|
89
|
+
themeClasses: a
|
|
90
|
+
} = D(e), {
|
|
91
|
+
densityClasses: s
|
|
92
|
+
} = xe(e), {
|
|
93
|
+
borderClasses: l
|
|
94
|
+
} = _e(e), {
|
|
95
|
+
elevationClasses: i
|
|
96
|
+
} = we(e), {
|
|
97
|
+
roundedClasses: c
|
|
98
|
+
} = le(e);
|
|
99
|
+
Fe({
|
|
100
|
+
VBtn: {
|
|
101
|
+
height: "auto",
|
|
102
|
+
color: L(e, "color"),
|
|
103
|
+
density: L(e, "density"),
|
|
104
|
+
flat: !0,
|
|
105
|
+
variant: L(e, "variant")
|
|
106
|
+
}
|
|
107
|
+
}), P(() => d(e.tag, {
|
|
108
|
+
class: ["v-btn-group", {
|
|
109
|
+
"v-btn-group--divided": e.divided
|
|
110
|
+
}, a.value, l.value, s.value, i.value, c.value, e.class],
|
|
111
|
+
style: e.style
|
|
112
|
+
}, n));
|
|
113
|
+
}
|
|
114
|
+
}), kt = w({
|
|
115
|
+
modelValue: {
|
|
116
|
+
type: null,
|
|
117
|
+
default: void 0
|
|
118
|
+
},
|
|
119
|
+
multiple: Boolean,
|
|
120
|
+
mandatory: [Boolean, String],
|
|
121
|
+
max: Number,
|
|
122
|
+
selectedClass: String,
|
|
123
|
+
disabled: Boolean
|
|
124
|
+
}, "group"), _t = w({
|
|
125
|
+
value: null,
|
|
126
|
+
disabled: Boolean,
|
|
127
|
+
selectedClass: String
|
|
128
|
+
}, "group-item");
|
|
129
|
+
function wt(e, t) {
|
|
130
|
+
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !0;
|
|
131
|
+
const a = ee("useGroupItem");
|
|
132
|
+
if (!a)
|
|
133
|
+
throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");
|
|
134
|
+
const s = Xe();
|
|
135
|
+
he(Symbol.for(`${t.description}:id`), s);
|
|
136
|
+
const l = qe(t, null);
|
|
137
|
+
if (!l) {
|
|
138
|
+
if (!n)
|
|
139
|
+
return l;
|
|
140
|
+
throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`);
|
|
141
|
+
}
|
|
142
|
+
const i = L(e, "value"), c = r(() => !!(l.disabled.value || e.disabled));
|
|
143
|
+
l.register({
|
|
144
|
+
id: s,
|
|
145
|
+
value: i,
|
|
146
|
+
disabled: c
|
|
147
|
+
}, a), te(() => {
|
|
148
|
+
l.unregister(s);
|
|
149
|
+
});
|
|
150
|
+
const u = r(() => l.isSelected(s)), p = r(() => u.value && [l.selectedClass.value, e.selectedClass]);
|
|
151
|
+
return ne(u, (g) => {
|
|
152
|
+
a.emit("group:selected", {
|
|
153
|
+
value: g
|
|
154
|
+
});
|
|
155
|
+
}, {
|
|
156
|
+
flush: "sync"
|
|
157
|
+
}), {
|
|
158
|
+
id: s,
|
|
159
|
+
isSelected: u,
|
|
160
|
+
toggle: () => l.select(s, !u.value),
|
|
161
|
+
select: (g) => l.select(s, g),
|
|
162
|
+
selectedClass: p,
|
|
163
|
+
value: i,
|
|
164
|
+
disabled: c,
|
|
165
|
+
group: l
|
|
166
|
+
};
|
|
167
|
+
}
|
|
168
|
+
function St(e, t) {
|
|
169
|
+
let n = !1;
|
|
170
|
+
const a = He([]), s = ye(e, "modelValue", [], (o) => o == null ? [] : Ve(a, Ye(o)), (o) => {
|
|
171
|
+
const f = It(a, o);
|
|
172
|
+
return e.multiple ? f : f[0];
|
|
173
|
+
}), l = ee("useGroup");
|
|
174
|
+
function i(o, f) {
|
|
175
|
+
const y = o, v = Symbol.for(`${t.description}:id`), b = We(v, l?.vnode).indexOf(f);
|
|
176
|
+
J(y.value) == null && (y.value = b), b > -1 ? a.splice(b, 0, y) : a.push(y);
|
|
177
|
+
}
|
|
178
|
+
function c(o) {
|
|
179
|
+
if (n)
|
|
180
|
+
return;
|
|
181
|
+
u();
|
|
182
|
+
const f = a.findIndex((y) => y.id === o);
|
|
183
|
+
a.splice(f, 1);
|
|
184
|
+
}
|
|
185
|
+
function u() {
|
|
186
|
+
const o = a.find((f) => !f.disabled);
|
|
187
|
+
o && e.mandatory === "force" && !s.value.length && (s.value = [o.id]);
|
|
188
|
+
}
|
|
189
|
+
Ue(() => {
|
|
190
|
+
u();
|
|
191
|
+
}), te(() => {
|
|
192
|
+
n = !0;
|
|
193
|
+
});
|
|
194
|
+
function p(o, f) {
|
|
195
|
+
const y = a.find((v) => v.id === o);
|
|
196
|
+
if (!(f && y?.disabled))
|
|
197
|
+
if (e.multiple) {
|
|
198
|
+
const v = s.value.slice(), k = v.findIndex((m) => m === o), b = ~k;
|
|
199
|
+
if (f = f ?? !b, b && e.mandatory && v.length <= 1 || !b && e.max != null && v.length + 1 > e.max)
|
|
200
|
+
return;
|
|
201
|
+
k < 0 && f ? v.push(o) : k >= 0 && !f && v.splice(k, 1), s.value = v;
|
|
202
|
+
} else {
|
|
203
|
+
const v = s.value.includes(o);
|
|
204
|
+
if (e.mandatory && v)
|
|
205
|
+
return;
|
|
206
|
+
s.value = f ?? !v ? [o] : [];
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
function g(o) {
|
|
210
|
+
if (e.multiple && je('This method is not supported when using "multiple" prop'), s.value.length) {
|
|
211
|
+
const f = s.value[0], y = a.findIndex((b) => b.id === f);
|
|
212
|
+
let v = (y + o) % a.length, k = a[v];
|
|
213
|
+
for (; k.disabled && v !== y; )
|
|
214
|
+
v = (v + o) % a.length, k = a[v];
|
|
215
|
+
if (k.disabled)
|
|
216
|
+
return;
|
|
217
|
+
s.value = [a[v].id];
|
|
218
|
+
} else {
|
|
219
|
+
const f = a.find((y) => !y.disabled);
|
|
220
|
+
f && (s.value = [f.id]);
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
const h = {
|
|
224
|
+
register: i,
|
|
225
|
+
unregister: c,
|
|
226
|
+
selected: s,
|
|
227
|
+
select: p,
|
|
228
|
+
disabled: L(e, "disabled"),
|
|
229
|
+
prev: () => g(a.length - 1),
|
|
230
|
+
next: () => g(1),
|
|
231
|
+
isSelected: (o) => s.value.includes(o),
|
|
232
|
+
selectedClass: r(() => e.selectedClass),
|
|
233
|
+
items: r(() => a),
|
|
234
|
+
getItemIndex: (o) => xt(a, o)
|
|
235
|
+
};
|
|
236
|
+
return he(t, h), h;
|
|
237
|
+
}
|
|
238
|
+
function xt(e, t) {
|
|
239
|
+
const n = Ve(e, [t]);
|
|
240
|
+
return n.length ? e.findIndex((a) => a.id === n[0]) : -1;
|
|
241
|
+
}
|
|
242
|
+
function Ve(e, t) {
|
|
243
|
+
const n = [];
|
|
244
|
+
return t.forEach((a) => {
|
|
245
|
+
const s = e.find((i) => be(a, i.value)), l = e[a];
|
|
246
|
+
s?.value != null ? n.push(s.id) : l != null && n.push(l.id);
|
|
247
|
+
}), n;
|
|
248
|
+
}
|
|
249
|
+
function It(e, t) {
|
|
250
|
+
const n = [];
|
|
251
|
+
return t.forEach((a) => {
|
|
252
|
+
const s = e.findIndex((l) => l.id === a);
|
|
253
|
+
if (~s) {
|
|
254
|
+
const l = e[s];
|
|
255
|
+
n.push(l.value != null ? l.value : s);
|
|
256
|
+
}
|
|
257
|
+
}), n;
|
|
258
|
+
}
|
|
259
|
+
const Be = Symbol.for("vuetify:v-btn-toggle"), Lt = w({
|
|
260
|
+
...Le(),
|
|
261
|
+
...kt()
|
|
262
|
+
}, "VBtnToggle");
|
|
263
|
+
E()({
|
|
264
|
+
name: "VBtnToggle",
|
|
265
|
+
props: Lt(),
|
|
266
|
+
emits: {
|
|
267
|
+
"update:modelValue": (e) => !0
|
|
268
|
+
},
|
|
269
|
+
setup(e, t) {
|
|
270
|
+
let {
|
|
271
|
+
slots: n
|
|
272
|
+
} = t;
|
|
273
|
+
const {
|
|
274
|
+
isSelected: a,
|
|
275
|
+
next: s,
|
|
276
|
+
prev: l,
|
|
277
|
+
select: i,
|
|
278
|
+
selected: c
|
|
279
|
+
} = St(e, Be);
|
|
280
|
+
return P(() => {
|
|
281
|
+
const u = ve.filterProps(e);
|
|
282
|
+
return d(ve, Je({
|
|
283
|
+
class: ["v-btn-toggle", e.class]
|
|
284
|
+
}, u, {
|
|
285
|
+
style: e.style
|
|
286
|
+
}), {
|
|
287
|
+
default: () => [n.default?.({
|
|
288
|
+
isSelected: a,
|
|
289
|
+
next: s,
|
|
290
|
+
prev: l,
|
|
291
|
+
select: i,
|
|
292
|
+
selected: c
|
|
293
|
+
})]
|
|
294
|
+
});
|
|
295
|
+
}), {
|
|
296
|
+
next: s,
|
|
297
|
+
prev: l,
|
|
298
|
+
select: i
|
|
299
|
+
};
|
|
300
|
+
}
|
|
301
|
+
});
|
|
302
|
+
const Vt = ["x-small", "small", "default", "large", "x-large"], ie = w({
|
|
303
|
+
size: {
|
|
304
|
+
type: [String, Number],
|
|
305
|
+
default: "default"
|
|
306
|
+
}
|
|
307
|
+
}, "size");
|
|
308
|
+
function oe(e) {
|
|
309
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : z();
|
|
310
|
+
return Ke(() => {
|
|
311
|
+
let n, a;
|
|
312
|
+
return j(Vt, e.size) ? n = `${t}--size-${e.size}` : e.size && (a = {
|
|
313
|
+
width: _(e.size),
|
|
314
|
+
height: _(e.size)
|
|
315
|
+
}), {
|
|
316
|
+
sizeClasses: n,
|
|
317
|
+
sizeStyles: a
|
|
318
|
+
};
|
|
319
|
+
});
|
|
320
|
+
}
|
|
321
|
+
const Bt = w({
|
|
322
|
+
color: String,
|
|
323
|
+
disabled: Boolean,
|
|
324
|
+
start: Boolean,
|
|
325
|
+
end: Boolean,
|
|
326
|
+
icon: K,
|
|
327
|
+
...N(),
|
|
328
|
+
...ie(),
|
|
329
|
+
...O({
|
|
330
|
+
tag: "i"
|
|
331
|
+
}),
|
|
332
|
+
...A()
|
|
333
|
+
}, "VIcon"), W = E()({
|
|
334
|
+
name: "VIcon",
|
|
335
|
+
props: Bt(),
|
|
336
|
+
setup(e, t) {
|
|
337
|
+
let {
|
|
338
|
+
attrs: n,
|
|
339
|
+
slots: a
|
|
340
|
+
} = t;
|
|
341
|
+
const s = ae(), {
|
|
342
|
+
themeClasses: l
|
|
343
|
+
} = D(e), {
|
|
344
|
+
iconData: i
|
|
345
|
+
} = Ze(r(() => s.value || e.icon)), {
|
|
346
|
+
sizeClasses: c
|
|
347
|
+
} = oe(e), {
|
|
348
|
+
textColorClasses: u,
|
|
349
|
+
textColorStyles: p
|
|
350
|
+
} = F(L(e, "color"));
|
|
351
|
+
return P(() => {
|
|
352
|
+
const g = a.default?.();
|
|
353
|
+
g && (s.value = Qe(g).filter((o) => o.type === et && o.children && typeof o.children == "string")[0]?.children);
|
|
354
|
+
const h = !!(n.onClick || n.onClickOnce);
|
|
355
|
+
return d(i.value.component, {
|
|
356
|
+
tag: e.tag,
|
|
357
|
+
icon: i.value.icon,
|
|
358
|
+
class: ["v-icon", "notranslate", l.value, c.value, u.value, {
|
|
359
|
+
"v-icon--clickable": h,
|
|
360
|
+
"v-icon--disabled": e.disabled,
|
|
361
|
+
"v-icon--start": e.start,
|
|
362
|
+
"v-icon--end": e.end
|
|
363
|
+
}, e.class],
|
|
364
|
+
style: [c.value ? void 0 : {
|
|
365
|
+
fontSize: _(e.size),
|
|
366
|
+
height: _(e.size),
|
|
367
|
+
width: _(e.size)
|
|
368
|
+
}, p.value, e.style],
|
|
369
|
+
role: h ? "button" : void 0,
|
|
370
|
+
"aria-hidden": !h,
|
|
371
|
+
tabindex: h ? e.disabled ? -1 : 0 : void 0
|
|
372
|
+
}, {
|
|
373
|
+
default: () => [g]
|
|
374
|
+
});
|
|
375
|
+
}), {};
|
|
376
|
+
}
|
|
377
|
+
});
|
|
378
|
+
function Ee(e, t) {
|
|
379
|
+
const n = ae(), a = tt(!1);
|
|
380
|
+
if (nt) {
|
|
381
|
+
const s = new IntersectionObserver((l) => {
|
|
382
|
+
e?.(l, s), a.value = !!l.find((i) => i.isIntersecting);
|
|
383
|
+
}, t);
|
|
384
|
+
te(() => {
|
|
385
|
+
s.disconnect();
|
|
386
|
+
}), ne(n, (l, i) => {
|
|
387
|
+
i && (s.unobserve(i), a.value = !1), l && s.observe(l);
|
|
388
|
+
}, {
|
|
389
|
+
flush: "post"
|
|
390
|
+
});
|
|
391
|
+
}
|
|
392
|
+
return {
|
|
393
|
+
intersectionRef: n,
|
|
394
|
+
isIntersecting: a
|
|
395
|
+
};
|
|
396
|
+
}
|
|
397
|
+
const Et = w({
|
|
398
|
+
bgColor: String,
|
|
399
|
+
color: String,
|
|
400
|
+
indeterminate: [Boolean, String],
|
|
401
|
+
modelValue: {
|
|
402
|
+
type: [Number, String],
|
|
403
|
+
default: 0
|
|
404
|
+
},
|
|
405
|
+
rotate: {
|
|
406
|
+
type: [Number, String],
|
|
407
|
+
default: 0
|
|
408
|
+
},
|
|
409
|
+
width: {
|
|
410
|
+
type: [Number, String],
|
|
411
|
+
default: 4
|
|
412
|
+
},
|
|
413
|
+
...N(),
|
|
414
|
+
...ie(),
|
|
415
|
+
...O({
|
|
416
|
+
tag: "div"
|
|
417
|
+
}),
|
|
418
|
+
...A()
|
|
419
|
+
}, "VProgressCircular"), Pt = E()({
|
|
420
|
+
name: "VProgressCircular",
|
|
421
|
+
props: Et(),
|
|
422
|
+
setup(e, t) {
|
|
423
|
+
let {
|
|
424
|
+
slots: n
|
|
425
|
+
} = t;
|
|
426
|
+
const a = 20, s = 2 * Math.PI * a, l = ae(), {
|
|
427
|
+
themeClasses: i
|
|
428
|
+
} = D(e), {
|
|
429
|
+
sizeClasses: c,
|
|
430
|
+
sizeStyles: u
|
|
431
|
+
} = oe(e), {
|
|
432
|
+
textColorClasses: p,
|
|
433
|
+
textColorStyles: g
|
|
434
|
+
} = F(L(e, "color")), {
|
|
435
|
+
textColorClasses: h,
|
|
436
|
+
textColorStyles: o
|
|
437
|
+
} = F(L(e, "bgColor")), {
|
|
438
|
+
intersectionRef: f,
|
|
439
|
+
isIntersecting: y
|
|
440
|
+
} = Ee(), {
|
|
441
|
+
resizeRef: v,
|
|
442
|
+
contentRect: k
|
|
443
|
+
} = at(), b = r(() => Math.max(0, Math.min(100, parseFloat(e.modelValue)))), m = r(() => Number(e.width)), C = r(() => u.value ? Number(e.size) : k.value ? k.value.width : Math.max(m.value, 32)), V = r(() => a / (1 - m.value / C.value) * 2), I = r(() => m.value / C.value * V.value), T = r(() => _((100 - b.value) / 100 * s));
|
|
444
|
+
return st(() => {
|
|
445
|
+
f.value = l.value, v.value = l.value;
|
|
446
|
+
}), P(() => d(e.tag, {
|
|
447
|
+
ref: l,
|
|
448
|
+
class: ["v-progress-circular", {
|
|
449
|
+
"v-progress-circular--indeterminate": !!e.indeterminate,
|
|
450
|
+
"v-progress-circular--visible": y.value,
|
|
451
|
+
"v-progress-circular--disable-shrink": e.indeterminate === "disable-shrink"
|
|
452
|
+
}, i.value, c.value, p.value, e.class],
|
|
453
|
+
style: [u.value, g.value, e.style],
|
|
454
|
+
role: "progressbar",
|
|
455
|
+
"aria-valuemin": "0",
|
|
456
|
+
"aria-valuemax": "100",
|
|
457
|
+
"aria-valuenow": e.indeterminate ? void 0 : b.value
|
|
458
|
+
}, {
|
|
459
|
+
default: () => [d("svg", {
|
|
460
|
+
style: {
|
|
461
|
+
transform: `rotate(calc(-90deg + ${Number(e.rotate)}deg))`
|
|
462
|
+
},
|
|
463
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
464
|
+
viewBox: `0 0 ${V.value} ${V.value}`
|
|
465
|
+
}, [d("circle", {
|
|
466
|
+
class: ["v-progress-circular__underlay", h.value],
|
|
467
|
+
style: o.value,
|
|
468
|
+
fill: "transparent",
|
|
469
|
+
cx: "50%",
|
|
470
|
+
cy: "50%",
|
|
471
|
+
r: a,
|
|
472
|
+
"stroke-width": I.value,
|
|
473
|
+
"stroke-dasharray": s,
|
|
474
|
+
"stroke-dashoffset": 0
|
|
475
|
+
}, null), d("circle", {
|
|
476
|
+
class: "v-progress-circular__overlay",
|
|
477
|
+
fill: "transparent",
|
|
478
|
+
cx: "50%",
|
|
479
|
+
cy: "50%",
|
|
480
|
+
r: a,
|
|
481
|
+
"stroke-width": I.value,
|
|
482
|
+
"stroke-dasharray": s,
|
|
483
|
+
"stroke-dashoffset": T.value
|
|
484
|
+
}, null)]), n.default && d("div", {
|
|
485
|
+
class: "v-progress-circular__content"
|
|
486
|
+
}, [n.default({
|
|
487
|
+
value: b.value
|
|
488
|
+
})])]
|
|
489
|
+
})), {};
|
|
490
|
+
}
|
|
491
|
+
}), fe = {
|
|
492
|
+
center: "center",
|
|
493
|
+
top: "bottom",
|
|
494
|
+
bottom: "top",
|
|
495
|
+
left: "right",
|
|
496
|
+
right: "left"
|
|
497
|
+
}, Pe = w({
|
|
498
|
+
location: String
|
|
499
|
+
}, "location");
|
|
500
|
+
function Te(e) {
|
|
501
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, n = arguments.length > 2 ? arguments[2] : void 0;
|
|
502
|
+
const {
|
|
503
|
+
isRtl: a
|
|
504
|
+
} = pe();
|
|
505
|
+
return {
|
|
506
|
+
locationStyles: r(() => {
|
|
507
|
+
if (!e.location)
|
|
508
|
+
return {};
|
|
509
|
+
const {
|
|
510
|
+
side: l,
|
|
511
|
+
align: i
|
|
512
|
+
} = ht(e.location.split(" ").length > 1 ? e.location : `${e.location} center`, a.value);
|
|
513
|
+
function c(p) {
|
|
514
|
+
return n ? n(p) : 0;
|
|
515
|
+
}
|
|
516
|
+
const u = {};
|
|
517
|
+
return l !== "center" && (t ? u[fe[l]] = `calc(100% - ${c(l)}px)` : u[l] = 0), i !== "center" ? t ? u[fe[i]] = `calc(100% - ${c(i)}px)` : u[i] = 0 : (l === "center" ? u.top = u.left = "50%" : u[{
|
|
518
|
+
top: "left",
|
|
519
|
+
bottom: "left",
|
|
520
|
+
left: "top",
|
|
521
|
+
right: "top"
|
|
522
|
+
}[l]] = "50%", u.transform = {
|
|
523
|
+
top: "translateX(-50%)",
|
|
524
|
+
bottom: "translateX(-50%)",
|
|
525
|
+
left: "translateY(-50%)",
|
|
526
|
+
right: "translateY(-50%)",
|
|
527
|
+
center: "translate(-50%, -50%)"
|
|
528
|
+
}[l]), u;
|
|
529
|
+
})
|
|
530
|
+
};
|
|
531
|
+
}
|
|
532
|
+
const Tt = w({
|
|
533
|
+
absolute: Boolean,
|
|
534
|
+
active: {
|
|
535
|
+
type: Boolean,
|
|
536
|
+
default: !0
|
|
537
|
+
},
|
|
538
|
+
bgColor: String,
|
|
539
|
+
bgOpacity: [Number, String],
|
|
540
|
+
bufferValue: {
|
|
541
|
+
type: [Number, String],
|
|
542
|
+
default: 0
|
|
543
|
+
},
|
|
544
|
+
clickable: Boolean,
|
|
545
|
+
color: String,
|
|
546
|
+
height: {
|
|
547
|
+
type: [Number, String],
|
|
548
|
+
default: 4
|
|
549
|
+
},
|
|
550
|
+
indeterminate: Boolean,
|
|
551
|
+
max: {
|
|
552
|
+
type: [Number, String],
|
|
553
|
+
default: 100
|
|
554
|
+
},
|
|
555
|
+
modelValue: {
|
|
556
|
+
type: [Number, String],
|
|
557
|
+
default: 0
|
|
558
|
+
},
|
|
559
|
+
reverse: Boolean,
|
|
560
|
+
stream: Boolean,
|
|
561
|
+
striped: Boolean,
|
|
562
|
+
roundedBar: Boolean,
|
|
563
|
+
...N(),
|
|
564
|
+
...Pe({
|
|
565
|
+
location: "top"
|
|
566
|
+
}),
|
|
567
|
+
...se(),
|
|
568
|
+
...O(),
|
|
569
|
+
...A()
|
|
570
|
+
}, "VProgressLinear"), $t = E()({
|
|
571
|
+
name: "VProgressLinear",
|
|
572
|
+
props: Tt(),
|
|
573
|
+
emits: {
|
|
574
|
+
"update:modelValue": (e) => !0
|
|
575
|
+
},
|
|
576
|
+
setup(e, t) {
|
|
577
|
+
let {
|
|
578
|
+
slots: n
|
|
579
|
+
} = t;
|
|
580
|
+
const a = ye(e, "modelValue"), {
|
|
581
|
+
isRtl: s,
|
|
582
|
+
rtlClasses: l
|
|
583
|
+
} = pe(), {
|
|
584
|
+
themeClasses: i
|
|
585
|
+
} = D(e), {
|
|
586
|
+
locationStyles: c
|
|
587
|
+
} = Te(e), {
|
|
588
|
+
textColorClasses: u,
|
|
589
|
+
textColorStyles: p
|
|
590
|
+
} = F(e, "color"), {
|
|
591
|
+
backgroundColorClasses: g,
|
|
592
|
+
backgroundColorStyles: h
|
|
593
|
+
} = ce(r(() => e.bgColor || e.color)), {
|
|
594
|
+
backgroundColorClasses: o,
|
|
595
|
+
backgroundColorStyles: f
|
|
596
|
+
} = ce(e, "color"), {
|
|
597
|
+
roundedClasses: y
|
|
598
|
+
} = le(e), {
|
|
599
|
+
intersectionRef: v,
|
|
600
|
+
isIntersecting: k
|
|
601
|
+
} = Ee(), b = r(() => parseInt(e.max, 10)), m = r(() => parseInt(e.height, 10)), C = r(() => parseFloat(e.bufferValue) / b.value * 100), V = r(() => parseFloat(a.value) / b.value * 100), I = r(() => s.value !== e.reverse), T = r(() => e.indeterminate ? "fade-transition" : "slide-x-transition"), M = r(() => e.bgOpacity == null ? e.bgOpacity : parseFloat(e.bgOpacity));
|
|
602
|
+
function q(S) {
|
|
603
|
+
if (!v.value)
|
|
604
|
+
return;
|
|
605
|
+
const {
|
|
606
|
+
left: H,
|
|
607
|
+
right: U,
|
|
608
|
+
width: B
|
|
609
|
+
} = v.value.getBoundingClientRect(), G = I.value ? B - S.clientX + (U - B) : S.clientX - H;
|
|
610
|
+
a.value = Math.round(G / B * b.value);
|
|
611
|
+
}
|
|
612
|
+
return P(() => d(e.tag, {
|
|
613
|
+
ref: v,
|
|
614
|
+
class: ["v-progress-linear", {
|
|
615
|
+
"v-progress-linear--absolute": e.absolute,
|
|
616
|
+
"v-progress-linear--active": e.active && k.value,
|
|
617
|
+
"v-progress-linear--reverse": I.value,
|
|
618
|
+
"v-progress-linear--rounded": e.rounded,
|
|
619
|
+
"v-progress-linear--rounded-bar": e.roundedBar,
|
|
620
|
+
"v-progress-linear--striped": e.striped
|
|
621
|
+
}, y.value, i.value, l.value, e.class],
|
|
622
|
+
style: [{
|
|
623
|
+
bottom: e.location === "bottom" ? 0 : void 0,
|
|
624
|
+
top: e.location === "top" ? 0 : void 0,
|
|
625
|
+
height: e.active ? _(m.value) : 0,
|
|
626
|
+
"--v-progress-linear-height": _(m.value),
|
|
627
|
+
...c.value
|
|
628
|
+
}, e.style],
|
|
629
|
+
role: "progressbar",
|
|
630
|
+
"aria-hidden": e.active ? "false" : "true",
|
|
631
|
+
"aria-valuemin": "0",
|
|
632
|
+
"aria-valuemax": e.max,
|
|
633
|
+
"aria-valuenow": e.indeterminate ? void 0 : V.value,
|
|
634
|
+
onClick: e.clickable && q
|
|
635
|
+
}, {
|
|
636
|
+
default: () => [e.stream && d("div", {
|
|
637
|
+
key: "stream",
|
|
638
|
+
class: ["v-progress-linear__stream", u.value],
|
|
639
|
+
style: {
|
|
640
|
+
...p.value,
|
|
641
|
+
[I.value ? "left" : "right"]: _(-m.value),
|
|
642
|
+
borderTop: `${_(m.value / 2)} dotted`,
|
|
643
|
+
opacity: M.value,
|
|
644
|
+
top: `calc(50% - ${_(m.value / 4)})`,
|
|
645
|
+
width: _(100 - C.value, "%"),
|
|
646
|
+
"--v-progress-linear-stream-to": _(m.value * (I.value ? 1 : -1))
|
|
647
|
+
}
|
|
648
|
+
}, null), d("div", {
|
|
649
|
+
class: ["v-progress-linear__background", g.value],
|
|
650
|
+
style: [h.value, {
|
|
651
|
+
opacity: M.value,
|
|
652
|
+
width: _(e.stream ? C.value : 100, "%")
|
|
653
|
+
}]
|
|
654
|
+
}, null), d(lt, {
|
|
655
|
+
name: T.value
|
|
656
|
+
}, {
|
|
657
|
+
default: () => [e.indeterminate ? d("div", {
|
|
658
|
+
class: "v-progress-linear__indeterminate"
|
|
659
|
+
}, [["long", "short"].map((S) => d("div", {
|
|
660
|
+
key: S,
|
|
661
|
+
class: ["v-progress-linear__indeterminate", S, o.value],
|
|
662
|
+
style: f.value
|
|
663
|
+
}, null))]) : d("div", {
|
|
664
|
+
class: ["v-progress-linear__determinate", o.value],
|
|
665
|
+
style: [f.value, {
|
|
666
|
+
width: _(V.value, "%")
|
|
667
|
+
}]
|
|
668
|
+
}, null)]
|
|
669
|
+
}), n.default && d("div", {
|
|
670
|
+
class: "v-progress-linear__content"
|
|
671
|
+
}, [n.default({
|
|
672
|
+
value: V.value,
|
|
673
|
+
buffer: C.value
|
|
674
|
+
})])]
|
|
675
|
+
})), {};
|
|
676
|
+
}
|
|
677
|
+
}), Rt = w({
|
|
678
|
+
loading: [Boolean, String]
|
|
679
|
+
}, "loader");
|
|
680
|
+
function zt(e) {
|
|
681
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : z();
|
|
682
|
+
return {
|
|
683
|
+
loaderClasses: r(() => ({
|
|
684
|
+
[`${t}--loading`]: e.loading
|
|
685
|
+
}))
|
|
686
|
+
};
|
|
687
|
+
}
|
|
688
|
+
function Qt(e, t) {
|
|
689
|
+
let {
|
|
690
|
+
slots: n
|
|
691
|
+
} = t;
|
|
692
|
+
return d("div", {
|
|
693
|
+
class: `${e.name}__loader`
|
|
694
|
+
}, [n.default?.({
|
|
695
|
+
color: e.color,
|
|
696
|
+
isActive: e.active
|
|
697
|
+
}) || d($t, {
|
|
698
|
+
absolute: e.absolute,
|
|
699
|
+
active: e.active,
|
|
700
|
+
color: e.color,
|
|
701
|
+
height: "2",
|
|
702
|
+
indeterminate: !0
|
|
703
|
+
}, null)]);
|
|
704
|
+
}
|
|
705
|
+
const Nt = ["static", "relative", "fixed", "absolute", "sticky"], Ot = w({
|
|
706
|
+
position: {
|
|
707
|
+
type: String,
|
|
708
|
+
validator: (
|
|
709
|
+
/* istanbul ignore next */
|
|
710
|
+
(e) => Nt.includes(e)
|
|
711
|
+
)
|
|
712
|
+
}
|
|
713
|
+
}, "position");
|
|
714
|
+
function At(e) {
|
|
715
|
+
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : z();
|
|
716
|
+
return {
|
|
717
|
+
positionClasses: r(() => e.position ? `${t}--${e.position}` : void 0)
|
|
718
|
+
};
|
|
719
|
+
}
|
|
720
|
+
function Dt() {
|
|
721
|
+
const e = ee("useRoute");
|
|
722
|
+
return r(() => e?.proxy?.$route);
|
|
723
|
+
}
|
|
724
|
+
function Mt(e, t) {
|
|
725
|
+
const n = it("RouterLink"), a = r(() => !!(e.href || e.to)), s = r(() => a?.value || re(t, "click") || re(e, "click"));
|
|
726
|
+
if (typeof n == "string" || !("useLink" in n))
|
|
727
|
+
return {
|
|
728
|
+
isLink: a,
|
|
729
|
+
isClickable: s,
|
|
730
|
+
href: L(e, "href")
|
|
731
|
+
};
|
|
732
|
+
const l = r(() => ({
|
|
733
|
+
...e,
|
|
734
|
+
to: L(() => e.to || {})
|
|
735
|
+
})), i = n.useLink(l.value), c = r(() => e.to ? i : void 0), u = Dt();
|
|
736
|
+
return {
|
|
737
|
+
isLink: a,
|
|
738
|
+
isClickable: s,
|
|
739
|
+
route: c.value?.route,
|
|
740
|
+
navigate: c.value?.navigate,
|
|
741
|
+
isActive: r(() => c.value ? e.exact ? u.value ? c.value.isExactActive?.value && be(c.value.route.value.query, u.value.query) : c.value.isExactActive?.value ?? !1 : c.value.isActive?.value ?? !1 : !1),
|
|
742
|
+
href: r(() => e.to ? c.value?.route.value.href : e.href)
|
|
743
|
+
};
|
|
744
|
+
}
|
|
745
|
+
const Gt = w({
|
|
746
|
+
href: String,
|
|
747
|
+
replace: Boolean,
|
|
748
|
+
to: [String, Object],
|
|
749
|
+
exact: Boolean
|
|
750
|
+
}, "router");
|
|
751
|
+
function Ft(e, t) {
|
|
752
|
+
ne(() => e.isActive?.value, (n) => {
|
|
753
|
+
e.isLink.value && n && t && ot(() => {
|
|
754
|
+
t(!0);
|
|
755
|
+
});
|
|
756
|
+
}, {
|
|
757
|
+
immediate: !0
|
|
758
|
+
});
|
|
759
|
+
}
|
|
760
|
+
const Z = Symbol("rippleStop"), Xt = 80;
|
|
761
|
+
function me(e, t) {
|
|
762
|
+
e.style.transform = t, e.style.webkitTransform = t;
|
|
763
|
+
}
|
|
764
|
+
function Q(e) {
|
|
765
|
+
return e.constructor.name === "TouchEvent";
|
|
766
|
+
}
|
|
767
|
+
function $e(e) {
|
|
768
|
+
return e.constructor.name === "KeyboardEvent";
|
|
769
|
+
}
|
|
770
|
+
const qt = function(e, t) {
|
|
771
|
+
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, a = 0, s = 0;
|
|
772
|
+
if (!$e(e)) {
|
|
773
|
+
const h = t.getBoundingClientRect(), o = Q(e) ? e.touches[e.touches.length - 1] : e;
|
|
774
|
+
a = o.clientX - h.left, s = o.clientY - h.top;
|
|
775
|
+
}
|
|
776
|
+
let l = 0, i = 0.3;
|
|
777
|
+
t._ripple?.circle ? (i = 0.15, l = t.clientWidth / 2, l = n.center ? l : l + Math.sqrt((a - l) ** 2 + (s - l) ** 2) / 4) : l = Math.sqrt(t.clientWidth ** 2 + t.clientHeight ** 2) / 2;
|
|
778
|
+
const c = `${(t.clientWidth - l * 2) / 2}px`, u = `${(t.clientHeight - l * 2) / 2}px`, p = n.center ? c : `${a - l}px`, g = n.center ? u : `${s - l}px`;
|
|
779
|
+
return {
|
|
780
|
+
radius: l,
|
|
781
|
+
scale: i,
|
|
782
|
+
x: p,
|
|
783
|
+
y: g,
|
|
784
|
+
centerX: c,
|
|
785
|
+
centerY: u
|
|
786
|
+
};
|
|
787
|
+
}, X = {
|
|
788
|
+
/* eslint-disable max-statements */
|
|
789
|
+
show(e, t) {
|
|
790
|
+
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
791
|
+
if (!t?._ripple?.enabled)
|
|
792
|
+
return;
|
|
793
|
+
const a = document.createElement("span"), s = document.createElement("span");
|
|
794
|
+
a.appendChild(s), a.className = "v-ripple__container", n.class && (a.className += ` ${n.class}`);
|
|
795
|
+
const {
|
|
796
|
+
radius: l,
|
|
797
|
+
scale: i,
|
|
798
|
+
x: c,
|
|
799
|
+
y: u,
|
|
800
|
+
centerX: p,
|
|
801
|
+
centerY: g
|
|
802
|
+
} = qt(e, t, n), h = `${l * 2}px`;
|
|
803
|
+
s.className = "v-ripple__animation", s.style.width = h, s.style.height = h, t.appendChild(a);
|
|
804
|
+
const o = window.getComputedStyle(t);
|
|
805
|
+
o && o.position === "static" && (t.style.position = "relative", t.dataset.previousPosition = "static"), s.classList.add("v-ripple__animation--enter"), s.classList.add("v-ripple__animation--visible"), me(s, `translate(${c}, ${u}) scale3d(${i},${i},${i})`), s.dataset.activated = String(performance.now()), setTimeout(() => {
|
|
806
|
+
s.classList.remove("v-ripple__animation--enter"), s.classList.add("v-ripple__animation--in"), me(s, `translate(${p}, ${g}) scale3d(1,1,1)`);
|
|
807
|
+
}, 0);
|
|
808
|
+
},
|
|
809
|
+
hide(e) {
|
|
810
|
+
if (!e?._ripple?.enabled)
|
|
811
|
+
return;
|
|
812
|
+
const t = e.getElementsByClassName("v-ripple__animation");
|
|
813
|
+
if (t.length === 0)
|
|
814
|
+
return;
|
|
815
|
+
const n = t[t.length - 1];
|
|
816
|
+
if (n.dataset.isHiding)
|
|
817
|
+
return;
|
|
818
|
+
n.dataset.isHiding = "true";
|
|
819
|
+
const a = performance.now() - Number(n.dataset.activated), s = Math.max(250 - a, 0);
|
|
820
|
+
setTimeout(() => {
|
|
821
|
+
n.classList.remove("v-ripple__animation--in"), n.classList.add("v-ripple__animation--out"), setTimeout(() => {
|
|
822
|
+
e.getElementsByClassName("v-ripple__animation").length === 1 && e.dataset.previousPosition && (e.style.position = e.dataset.previousPosition, delete e.dataset.previousPosition), n.parentNode?.parentNode === e && e.removeChild(n.parentNode);
|
|
823
|
+
}, 300);
|
|
824
|
+
}, s);
|
|
825
|
+
}
|
|
826
|
+
};
|
|
827
|
+
function Re(e) {
|
|
828
|
+
return typeof e > "u" || !!e;
|
|
829
|
+
}
|
|
830
|
+
function $(e) {
|
|
831
|
+
const t = {}, n = e.currentTarget;
|
|
832
|
+
if (!(!n?._ripple || n._ripple.touched || e[Z])) {
|
|
833
|
+
if (e[Z] = !0, Q(e))
|
|
834
|
+
n._ripple.touched = !0, n._ripple.isTouch = !0;
|
|
835
|
+
else if (n._ripple.isTouch)
|
|
836
|
+
return;
|
|
837
|
+
if (t.center = n._ripple.centered || $e(e), n._ripple.class && (t.class = n._ripple.class), Q(e)) {
|
|
838
|
+
if (n._ripple.showTimerCommit)
|
|
839
|
+
return;
|
|
840
|
+
n._ripple.showTimerCommit = () => {
|
|
841
|
+
X.show(e, n, t);
|
|
842
|
+
}, n._ripple.showTimer = window.setTimeout(() => {
|
|
843
|
+
n?._ripple?.showTimerCommit && (n._ripple.showTimerCommit(), n._ripple.showTimerCommit = null);
|
|
844
|
+
}, Xt);
|
|
845
|
+
} else
|
|
846
|
+
X.show(e, n, t);
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
function ge(e) {
|
|
850
|
+
e[Z] = !0;
|
|
851
|
+
}
|
|
852
|
+
function x(e) {
|
|
853
|
+
const t = e.currentTarget;
|
|
854
|
+
if (t?._ripple) {
|
|
855
|
+
if (window.clearTimeout(t._ripple.showTimer), e.type === "touchend" && t._ripple.showTimerCommit) {
|
|
856
|
+
t._ripple.showTimerCommit(), t._ripple.showTimerCommit = null, t._ripple.showTimer = window.setTimeout(() => {
|
|
857
|
+
x(e);
|
|
858
|
+
});
|
|
859
|
+
return;
|
|
860
|
+
}
|
|
861
|
+
window.setTimeout(() => {
|
|
862
|
+
t._ripple && (t._ripple.touched = !1);
|
|
863
|
+
}), X.hide(t);
|
|
864
|
+
}
|
|
865
|
+
}
|
|
866
|
+
function ze(e) {
|
|
867
|
+
const t = e.currentTarget;
|
|
868
|
+
t?._ripple && (t._ripple.showTimerCommit && (t._ripple.showTimerCommit = null), window.clearTimeout(t._ripple.showTimer));
|
|
869
|
+
}
|
|
870
|
+
let R = !1;
|
|
871
|
+
function Ne(e) {
|
|
872
|
+
!R && (e.keyCode === ue.enter || e.keyCode === ue.space) && (R = !0, $(e));
|
|
873
|
+
}
|
|
874
|
+
function Oe(e) {
|
|
875
|
+
R = !1, x(e);
|
|
876
|
+
}
|
|
877
|
+
function Ae(e) {
|
|
878
|
+
R && (R = !1, x(e));
|
|
879
|
+
}
|
|
880
|
+
function De(e, t, n) {
|
|
881
|
+
const {
|
|
882
|
+
value: a,
|
|
883
|
+
modifiers: s
|
|
884
|
+
} = t, l = Re(a);
|
|
885
|
+
if (l || X.hide(e), e._ripple = e._ripple ?? {}, e._ripple.enabled = l, e._ripple.centered = s.center, e._ripple.circle = s.circle, rt(a) && a.class && (e._ripple.class = a.class), l && !n) {
|
|
886
|
+
if (s.stop) {
|
|
887
|
+
e.addEventListener("touchstart", ge, {
|
|
888
|
+
passive: !0
|
|
889
|
+
}), e.addEventListener("mousedown", ge);
|
|
890
|
+
return;
|
|
891
|
+
}
|
|
892
|
+
e.addEventListener("touchstart", $, {
|
|
893
|
+
passive: !0
|
|
894
|
+
}), e.addEventListener("touchend", x, {
|
|
895
|
+
passive: !0
|
|
896
|
+
}), e.addEventListener("touchmove", ze, {
|
|
897
|
+
passive: !0
|
|
898
|
+
}), e.addEventListener("touchcancel", x), e.addEventListener("mousedown", $), e.addEventListener("mouseup", x), e.addEventListener("mouseleave", x), e.addEventListener("keydown", Ne), e.addEventListener("keyup", Oe), e.addEventListener("blur", Ae), e.addEventListener("dragstart", x, {
|
|
899
|
+
passive: !0
|
|
900
|
+
});
|
|
901
|
+
} else
|
|
902
|
+
!l && n && Me(e);
|
|
903
|
+
}
|
|
904
|
+
function Me(e) {
|
|
905
|
+
e.removeEventListener("mousedown", $), e.removeEventListener("touchstart", $), e.removeEventListener("touchend", x), e.removeEventListener("touchmove", ze), e.removeEventListener("touchcancel", x), e.removeEventListener("mouseup", x), e.removeEventListener("mouseleave", x), e.removeEventListener("keydown", Ne), e.removeEventListener("keyup", Oe), e.removeEventListener("dragstart", x), e.removeEventListener("blur", Ae);
|
|
906
|
+
}
|
|
907
|
+
function Ht(e, t) {
|
|
908
|
+
De(e, t, !1);
|
|
909
|
+
}
|
|
910
|
+
function Ut(e) {
|
|
911
|
+
delete e._ripple, Me(e);
|
|
912
|
+
}
|
|
913
|
+
function Yt(e, t) {
|
|
914
|
+
if (t.value === t.oldValue)
|
|
915
|
+
return;
|
|
916
|
+
const n = Re(t.oldValue);
|
|
917
|
+
De(e, t, n);
|
|
918
|
+
}
|
|
919
|
+
const Wt = {
|
|
920
|
+
mounted: Ht,
|
|
921
|
+
unmounted: Ut,
|
|
922
|
+
updated: Yt
|
|
923
|
+
}, jt = w({
|
|
924
|
+
active: {
|
|
925
|
+
type: Boolean,
|
|
926
|
+
default: void 0
|
|
927
|
+
},
|
|
928
|
+
symbol: {
|
|
929
|
+
type: null,
|
|
930
|
+
default: Be
|
|
931
|
+
},
|
|
932
|
+
flat: Boolean,
|
|
933
|
+
icon: [Boolean, String, Function, Object],
|
|
934
|
+
prependIcon: K,
|
|
935
|
+
appendIcon: K,
|
|
936
|
+
block: Boolean,
|
|
937
|
+
slim: Boolean,
|
|
938
|
+
stacked: Boolean,
|
|
939
|
+
ripple: {
|
|
940
|
+
type: [Boolean, Object],
|
|
941
|
+
default: !0
|
|
942
|
+
},
|
|
943
|
+
text: String,
|
|
944
|
+
...Ce(),
|
|
945
|
+
...N(),
|
|
946
|
+
...Se(),
|
|
947
|
+
...vt(),
|
|
948
|
+
...ke(),
|
|
949
|
+
..._t(),
|
|
950
|
+
...Rt(),
|
|
951
|
+
...Pe(),
|
|
952
|
+
...Ot(),
|
|
953
|
+
...se(),
|
|
954
|
+
...Gt(),
|
|
955
|
+
...ie(),
|
|
956
|
+
...O({
|
|
957
|
+
tag: "button"
|
|
958
|
+
}),
|
|
959
|
+
...A(),
|
|
960
|
+
...Ie({
|
|
961
|
+
variant: "elevated"
|
|
962
|
+
})
|
|
963
|
+
}, "VBtn"), en = E()({
|
|
964
|
+
name: "VBtn",
|
|
965
|
+
directives: {
|
|
966
|
+
Ripple: Wt
|
|
967
|
+
},
|
|
968
|
+
props: jt(),
|
|
969
|
+
emits: {
|
|
970
|
+
"group:selected": (e) => !0
|
|
971
|
+
},
|
|
972
|
+
setup(e, t) {
|
|
973
|
+
let {
|
|
974
|
+
attrs: n,
|
|
975
|
+
slots: a
|
|
976
|
+
} = t;
|
|
977
|
+
const {
|
|
978
|
+
themeClasses: s
|
|
979
|
+
} = D(e), {
|
|
980
|
+
borderClasses: l
|
|
981
|
+
} = _e(e), {
|
|
982
|
+
colorClasses: i,
|
|
983
|
+
colorStyles: c,
|
|
984
|
+
variantClasses: u
|
|
985
|
+
} = Ct(e), {
|
|
986
|
+
densityClasses: p
|
|
987
|
+
} = xe(e), {
|
|
988
|
+
dimensionStyles: g
|
|
989
|
+
} = ft(e), {
|
|
990
|
+
elevationClasses: h
|
|
991
|
+
} = we(e), {
|
|
992
|
+
loaderClasses: o
|
|
993
|
+
} = zt(e), {
|
|
994
|
+
locationStyles: f
|
|
995
|
+
} = Te(e), {
|
|
996
|
+
positionClasses: y
|
|
997
|
+
} = At(e), {
|
|
998
|
+
roundedClasses: v
|
|
999
|
+
} = le(e), {
|
|
1000
|
+
sizeClasses: k,
|
|
1001
|
+
sizeStyles: b
|
|
1002
|
+
} = oe(e), m = wt(e, e.symbol, !1), C = Mt(e, n), V = r(() => e.active !== void 0 ? e.active : C.isLink.value ? C.isActive?.value : m?.isSelected.value), I = r(() => m?.disabled.value || e.disabled), T = r(() => e.variant === "elevated" && !(e.disabled || e.flat || e.border)), M = r(() => {
|
|
1003
|
+
if (!(e.value === void 0 || typeof e.value == "symbol"))
|
|
1004
|
+
return Object(e.value) === e.value ? JSON.stringify(e.value, null, 0) : e.value;
|
|
1005
|
+
});
|
|
1006
|
+
function q(S) {
|
|
1007
|
+
I.value || C.isLink.value && (S.metaKey || S.ctrlKey || S.shiftKey || S.button !== 0 || n.target === "_blank") || (C.navigate?.(S), m?.toggle());
|
|
1008
|
+
}
|
|
1009
|
+
return Ft(C, m?.select), P(() => {
|
|
1010
|
+
const S = C.isLink.value ? "a" : e.tag, H = !!(e.prependIcon || a.prepend), U = !!(e.appendIcon || a.append), B = !!(e.icon && e.icon !== !0), G = m?.isSelected.value && (!C.isLink.value || C.isActive?.value) || !m || C.isActive?.value;
|
|
1011
|
+
return ut(d(S, {
|
|
1012
|
+
type: S === "a" ? void 0 : "button",
|
|
1013
|
+
class: ["v-btn", m?.selectedClass.value, {
|
|
1014
|
+
"v-btn--active": V.value,
|
|
1015
|
+
"v-btn--block": e.block,
|
|
1016
|
+
"v-btn--disabled": I.value,
|
|
1017
|
+
"v-btn--elevated": T.value,
|
|
1018
|
+
"v-btn--flat": e.flat,
|
|
1019
|
+
"v-btn--icon": !!e.icon,
|
|
1020
|
+
"v-btn--loading": e.loading,
|
|
1021
|
+
"v-btn--slim": e.slim,
|
|
1022
|
+
"v-btn--stacked": e.stacked
|
|
1023
|
+
}, s.value, l.value, G ? i.value : void 0, p.value, h.value, o.value, y.value, v.value, k.value, u.value, e.class],
|
|
1024
|
+
style: [G ? c.value : void 0, g.value, f.value, b.value, e.style],
|
|
1025
|
+
"aria-busy": e.loading ? !0 : void 0,
|
|
1026
|
+
disabled: I.value || void 0,
|
|
1027
|
+
href: C.href.value,
|
|
1028
|
+
tabindex: e.loading ? -1 : void 0,
|
|
1029
|
+
onClick: q,
|
|
1030
|
+
value: M.value
|
|
1031
|
+
}, {
|
|
1032
|
+
default: () => [pt(!0, "v-btn"), !e.icon && H && d("span", {
|
|
1033
|
+
key: "prepend",
|
|
1034
|
+
class: "v-btn__prepend"
|
|
1035
|
+
}, [a.prepend ? d(Y, {
|
|
1036
|
+
key: "prepend-defaults",
|
|
1037
|
+
disabled: !e.prependIcon,
|
|
1038
|
+
defaults: {
|
|
1039
|
+
VIcon: {
|
|
1040
|
+
icon: e.prependIcon
|
|
1041
|
+
}
|
|
1042
|
+
}
|
|
1043
|
+
}, a.prepend) : d(W, {
|
|
1044
|
+
key: "prepend-icon",
|
|
1045
|
+
icon: e.prependIcon
|
|
1046
|
+
}, null)]), d("span", {
|
|
1047
|
+
class: "v-btn__content",
|
|
1048
|
+
"data-no-activator": ""
|
|
1049
|
+
}, [!a.default && B ? d(W, {
|
|
1050
|
+
key: "content-icon",
|
|
1051
|
+
icon: e.icon
|
|
1052
|
+
}, null) : d(Y, {
|
|
1053
|
+
key: "content-defaults",
|
|
1054
|
+
disabled: !B,
|
|
1055
|
+
defaults: {
|
|
1056
|
+
VIcon: {
|
|
1057
|
+
icon: e.icon
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
}, {
|
|
1061
|
+
default: () => [a.default?.() ?? e.text]
|
|
1062
|
+
})]), !e.icon && U && d("span", {
|
|
1063
|
+
key: "append",
|
|
1064
|
+
class: "v-btn__append"
|
|
1065
|
+
}, [a.append ? d(Y, {
|
|
1066
|
+
key: "append-defaults",
|
|
1067
|
+
disabled: !e.appendIcon,
|
|
1068
|
+
defaults: {
|
|
1069
|
+
VIcon: {
|
|
1070
|
+
icon: e.appendIcon
|
|
1071
|
+
}
|
|
1072
|
+
}
|
|
1073
|
+
}, a.append) : d(W, {
|
|
1074
|
+
key: "append-icon",
|
|
1075
|
+
icon: e.appendIcon
|
|
1076
|
+
}, null)]), !!e.loading && d("span", {
|
|
1077
|
+
key: "loader",
|
|
1078
|
+
class: "v-btn__loader"
|
|
1079
|
+
}, [a.loader?.() ?? d(Pt, {
|
|
1080
|
+
color: typeof e.loading == "boolean" ? void 0 : e.loading,
|
|
1081
|
+
indeterminate: !0,
|
|
1082
|
+
size: "23",
|
|
1083
|
+
width: "2"
|
|
1084
|
+
}, null)])]
|
|
1085
|
+
}), [[ct("ripple"), !I.value && e.ripple, null]]);
|
|
1086
|
+
}), {
|
|
1087
|
+
group: m
|
|
1088
|
+
};
|
|
1089
|
+
}
|
|
1090
|
+
});
|
|
1091
|
+
export {
|
|
1092
|
+
Qt as L,
|
|
1093
|
+
en as V,
|
|
1094
|
+
kt as a,
|
|
1095
|
+
W as b,
|
|
1096
|
+
Se as c,
|
|
1097
|
+
xe as d,
|
|
1098
|
+
Pe as e,
|
|
1099
|
+
Ot as f,
|
|
1100
|
+
Te as g,
|
|
1101
|
+
At as h,
|
|
1102
|
+
Rt as i,
|
|
1103
|
+
zt as j,
|
|
1104
|
+
jt as m,
|
|
1105
|
+
St as u
|
|
1106
|
+
};
|