@mgdis/stencil-helpers 1.1.5 → 1.1.6
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/components/index.d.ts.map +1 -1
- package/dist/index.es.js +169 -169
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/index.umd.js.map +1 -1
- package/dist/locale/index.d.ts +1 -1
- package/dist/locale/index.d.ts.map +1 -1
- package/dist/storybook/index.d.ts.map +1 -1
- package/dist/test/unit.d.ts.map +1 -1
- package/package.json +8 -8
package/dist/index.es.js
CHANGED
|
@@ -4,7 +4,7 @@ var v = (e, t, s) => ue(e, typeof t != "symbol" ? t + "" : t, s);
|
|
|
4
4
|
const Ce = (e = "", t = 10) => {
|
|
5
5
|
const s = new Uint8Array(t);
|
|
6
6
|
crypto.getRandomValues(s);
|
|
7
|
-
const r = Array.from(s).map((
|
|
7
|
+
const r = Array.from(s).map((o) => o.toString(16).padStart(2, "0")).join("").slice(0, t);
|
|
8
8
|
return e !== "" ? `${e}-${r}` : r;
|
|
9
9
|
};
|
|
10
10
|
class He {
|
|
@@ -71,29 +71,29 @@ const Pe = (e) => Array.isArray(e) && e.every((t) => typeof t == "string"), Be =
|
|
|
71
71
|
let t = e.overview ? `${e.overview}
|
|
72
72
|
|
|
73
73
|
` : "";
|
|
74
|
-
const s = e.props.filter(({ attr:
|
|
74
|
+
const s = e.props.filter(({ attr: o }) => o !== void 0);
|
|
75
75
|
s.length && (t += `Attributes:
|
|
76
|
-
`, t += s.map(({ attr:
|
|
76
|
+
`, t += s.map(({ attr: o, docs: l }) => `- \`${o}\`: ${l}
|
|
77
77
|
`).join(""), t += `
|
|
78
78
|
`);
|
|
79
|
-
const r = e.props.filter(({ attr:
|
|
79
|
+
const r = e.props.filter(({ attr: o }) => o === void 0);
|
|
80
80
|
return r.length && (t += `Properties:
|
|
81
|
-
`, t += r.map(({ name:
|
|
81
|
+
`, t += r.map(({ name: o, docs: l }) => `- \`${o}\`: ${l}
|
|
82
82
|
`).join(""), t += `
|
|
83
83
|
`), e.methods.length && (t += `Methods:
|
|
84
|
-
`, t += e.methods.map(({ name:
|
|
84
|
+
`, t += e.methods.map(({ name: o, docs: l }) => `- \`${o}\`: ${l}
|
|
85
85
|
`).join(""), t += `
|
|
86
86
|
`), e.events.length && (t += `Events:
|
|
87
|
-
`, t += e.events.map(({ event:
|
|
87
|
+
`, t += e.events.map(({ event: o, docs: l }) => `- \`${o}\`: ${l}
|
|
88
88
|
`).join(""), t += `
|
|
89
89
|
`), e.listeners.length && (t += `Listeners:
|
|
90
|
-
`, t += e.listeners.map(({ event:
|
|
90
|
+
`, t += e.listeners.map(({ event: o }) => `- \`${o}\`
|
|
91
91
|
`).join(""), t += `
|
|
92
92
|
`), e.slots.length && (t += `Slots:
|
|
93
|
-
`, t += e.slots.map(({ name:
|
|
93
|
+
`, t += e.slots.map(({ name: o, docs: l }) => `- \`${o}\`: ${l}
|
|
94
94
|
`).join(""), t += `
|
|
95
95
|
`), t;
|
|
96
|
-
},
|
|
96
|
+
}, _ = (e) => `${e.docs}
|
|
97
97
|
|
|
98
98
|
Type: \`${e.type}\``, Xe = (e, t, s, r) => ({
|
|
99
99
|
$schema: "https://json.schemastore.org/web-types",
|
|
@@ -102,16 +102,16 @@ Type: \`${e.type}\``, Xe = (e, t, s, r) => ({
|
|
|
102
102
|
"description-markup": "markdown",
|
|
103
103
|
contributions: {
|
|
104
104
|
html: {
|
|
105
|
-
elements: s.components.map((
|
|
106
|
-
const
|
|
105
|
+
elements: s.components.map((o) => {
|
|
106
|
+
const l = J(r, o.filePath);
|
|
107
107
|
return {
|
|
108
|
-
name:
|
|
109
|
-
description: Y(
|
|
110
|
-
"doc-url":
|
|
111
|
-
attributes:
|
|
108
|
+
name: o.tag,
|
|
109
|
+
description: Y(o),
|
|
110
|
+
"doc-url": l,
|
|
111
|
+
attributes: o.props.filter((n) => n.attr).map((n) => ({
|
|
112
112
|
name: n.attr,
|
|
113
|
-
description:
|
|
114
|
-
"doc-url":
|
|
113
|
+
description: _(n),
|
|
114
|
+
"doc-url": l,
|
|
115
115
|
value: {
|
|
116
116
|
type: n.type,
|
|
117
117
|
default: n.default,
|
|
@@ -119,17 +119,17 @@ Type: \`${e.type}\``, Xe = (e, t, s, r) => ({
|
|
|
119
119
|
}
|
|
120
120
|
})),
|
|
121
121
|
js: {
|
|
122
|
-
properties:
|
|
122
|
+
properties: o.props.map((n) => ({
|
|
123
123
|
name: n.name,
|
|
124
|
-
description:
|
|
125
|
-
"doc-url":
|
|
124
|
+
description: _(n),
|
|
125
|
+
"doc-url": l,
|
|
126
126
|
value: {
|
|
127
127
|
type: n.type,
|
|
128
128
|
default: n.default,
|
|
129
129
|
required: n.required
|
|
130
130
|
}
|
|
131
131
|
})),
|
|
132
|
-
events:
|
|
132
|
+
events: o.events.map((n) => ({
|
|
133
133
|
name: n.event,
|
|
134
134
|
description: n.docs
|
|
135
135
|
}))
|
|
@@ -146,18 +146,18 @@ Type: \`${e.type}\``, Xe = (e, t, s, r) => ({
|
|
|
146
146
|
return e.values.map(({ value: t }) => ({ name: t }));
|
|
147
147
|
}, Ke = (e, t, s, r) => ({
|
|
148
148
|
version: e,
|
|
149
|
-
tags: t.components.map((
|
|
150
|
-
const
|
|
149
|
+
tags: t.components.map((o) => {
|
|
150
|
+
const l = pe(s, r, o.filePath);
|
|
151
151
|
return {
|
|
152
|
-
name:
|
|
153
|
-
description: Y(
|
|
154
|
-
attributes:
|
|
152
|
+
name: o.tag,
|
|
153
|
+
description: Y(o),
|
|
154
|
+
attributes: o.props.map((n) => ({
|
|
155
155
|
name: n.attr || n.name,
|
|
156
|
-
description:
|
|
156
|
+
description: _(n),
|
|
157
157
|
values: ve(n),
|
|
158
|
-
references:
|
|
158
|
+
references: l
|
|
159
159
|
})),
|
|
160
|
-
references:
|
|
160
|
+
references: l
|
|
161
161
|
};
|
|
162
162
|
}),
|
|
163
163
|
globalAttributes: [],
|
|
@@ -166,13 +166,13 @@ Type: \`${e.type}\``, Xe = (e, t, s, r) => ({
|
|
|
166
166
|
const t = { value: "2023", pattern: "yyyy" }, s = { value: "12", pattern: "mm" }, r = { value: "24", pattern: "dd" };
|
|
167
167
|
return ye([t.value, s.value, r.value].join("-"), e, { timeZone: "UTC" }).replace(t.value, t.pattern).replace(s.value, s.pattern).replace(r.value, r.pattern);
|
|
168
168
|
}, Ze = (e) => e.toISOString().split("T")[0], ge = (e, t, s) => {
|
|
169
|
-
const r = e.closest("[lang]"),
|
|
169
|
+
const r = e.closest("[lang]"), o = Intl.NumberFormat.supportedLocalesOf(r == null ? void 0 : r.lang), l = o.length > 0 && typeof o[0] == "string" ? o[0] : navigator.language || s, n = l.split("-").shift();
|
|
170
170
|
return {
|
|
171
|
-
locale:
|
|
171
|
+
locale: l,
|
|
172
172
|
messages: t[n] || t[s]
|
|
173
173
|
};
|
|
174
174
|
}, Je = (e, t, s) => new Intl.NumberFormat(t, { style: "currency", currency: s }).format(e), Ye = (e, t, s = 0) => new Intl.NumberFormat(t, { minimumFractionDigits: s }).format(s > 0 ? Number(e == null ? void 0 : e.toFixed(s)) : e), he = /^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/, ye = (e, t, s) => typeof e != "string" || e === "" || !he.test(e) ? "" : new Intl.DateTimeFormat(t, s).format(new Date(e)), Ve = (e, t) => (s) => ge(s, e, t);
|
|
175
|
-
var
|
|
175
|
+
var N = {
|
|
176
176
|
allRenderFn: !1,
|
|
177
177
|
cmpDidLoad: !0,
|
|
178
178
|
cmpDidUnload: !1,
|
|
@@ -264,15 +264,25 @@ var U = {
|
|
|
264
264
|
}, be = Object.defineProperty, Se = (e, t) => {
|
|
265
265
|
for (var s in t)
|
|
266
266
|
be(e, s, { get: t[s], enumerable: !0 });
|
|
267
|
-
}, W =
|
|
267
|
+
}, W = (e, t) => t in e, z = "http://www.w3.org/1999/xlink", C = typeof window < "u" ? window : {}, j = C.document || { head: {} };
|
|
268
|
+
C.HTMLElement;
|
|
269
|
+
var x = {
|
|
270
|
+
$flags$: 0,
|
|
271
|
+
$resourcesUrl$: "",
|
|
272
|
+
jmp: (e) => e(),
|
|
273
|
+
raf: (e) => requestAnimationFrame(e),
|
|
274
|
+
ael: (e, t, s, r) => e.addEventListener(t, s, r),
|
|
275
|
+
rel: (e, t, s, r) => e.removeEventListener(t, s, r),
|
|
276
|
+
ce: (e, t) => new CustomEvent(e, t)
|
|
277
|
+
}, I = {}, me = "http://www.w3.org/2000/svg", Te = "http://www.w3.org/1999/xhtml", ke = (e) => e != null, V = (e) => (e = typeof e, e === "object" || e === "function"), xe = {};
|
|
268
278
|
Se(xe, {
|
|
269
279
|
err: () => ee,
|
|
270
280
|
map: () => Ee,
|
|
271
|
-
ok: () =>
|
|
281
|
+
ok: () => F,
|
|
272
282
|
unwrap: () => Ae,
|
|
273
283
|
unwrapErr: () => Le
|
|
274
284
|
});
|
|
275
|
-
var
|
|
285
|
+
var F = (e) => ({
|
|
276
286
|
isOk: !0,
|
|
277
287
|
isErr: !1,
|
|
278
288
|
value: e
|
|
@@ -284,7 +294,7 @@ var N = (e) => ({
|
|
|
284
294
|
function Ee(e, t) {
|
|
285
295
|
if (e.isOk) {
|
|
286
296
|
const s = t(e.value);
|
|
287
|
-
return s instanceof Promise ? s.then((r) =>
|
|
297
|
+
return s instanceof Promise ? s.then((r) => F(r)) : F(s);
|
|
288
298
|
}
|
|
289
299
|
if (e.isErr) {
|
|
290
300
|
const s = e.value;
|
|
@@ -300,16 +310,16 @@ var Ae = (e) => {
|
|
|
300
310
|
if (e.isErr)
|
|
301
311
|
return e.value;
|
|
302
312
|
throw e.value;
|
|
303
|
-
},
|
|
304
|
-
let r = null,
|
|
313
|
+
}, Re = (e, t, ...s) => {
|
|
314
|
+
let r = null, o = null, l = null, n = !1, i = !1;
|
|
305
315
|
const a = [], d = (f) => {
|
|
306
316
|
for (let $ = 0; $ < f.length; $++)
|
|
307
|
-
r = f[$], Array.isArray(r) ? d(r) : r != null && typeof r != "boolean" && ((n = !V(r)) && (r = String(r)), n && i ? a[a.length - 1].$text$ += r : a.push(n ?
|
|
317
|
+
r = f[$], Array.isArray(r) ? d(r) : r != null && typeof r != "boolean" && ((n = !V(r)) && (r = String(r)), n && i ? a[a.length - 1].$text$ += r : a.push(n ? U(null, r) : r), i = n);
|
|
308
318
|
};
|
|
309
319
|
d(s);
|
|
310
|
-
const u =
|
|
311
|
-
return u.$attrs$ = t, a.length > 0 && (u.$children$ = a), u.$key$ =
|
|
312
|
-
},
|
|
320
|
+
const u = U(e, null);
|
|
321
|
+
return u.$attrs$ = t, a.length > 0 && (u.$children$ = a), u.$key$ = o, u.$name$ = l, u;
|
|
322
|
+
}, U = (e, t) => {
|
|
313
323
|
const s = {
|
|
314
324
|
$flags$: 0,
|
|
315
325
|
$tag$: e,
|
|
@@ -318,11 +328,11 @@ var Ae = (e) => {
|
|
|
318
328
|
$children$: null
|
|
319
329
|
};
|
|
320
330
|
return s.$attrs$ = null, s.$key$ = null, s.$name$ = null, s;
|
|
321
|
-
}, je = {}, Oe = (e) => e && e.$tag$ === je,
|
|
331
|
+
}, je = {}, Oe = (e) => e && e.$tag$ === je, q = (e, t, s, r, o, l) => {
|
|
322
332
|
if (s !== r) {
|
|
323
|
-
let n =
|
|
333
|
+
let n = W(e, t), i = t.toLowerCase();
|
|
324
334
|
if (t === "class") {
|
|
325
|
-
const a = e.classList, d =
|
|
335
|
+
const a = e.classList, d = G(s), u = G(r);
|
|
326
336
|
a.remove(...d.filter((f) => f && !u.includes(f))), a.add(...u.filter((f) => f && !d.includes(f)));
|
|
327
337
|
} else if (t === "style") {
|
|
328
338
|
for (const a in s)
|
|
@@ -332,13 +342,13 @@ var Ae = (e) => {
|
|
|
332
342
|
} else if (t !== "key") if (t === "ref")
|
|
333
343
|
r && r(e);
|
|
334
344
|
else if (!e.__lookupSetter__(t) && t[0] === "o" && t[1] === "n") {
|
|
335
|
-
if (t[2] === "-" ? t = t.slice(3) :
|
|
345
|
+
if (t[2] === "-" ? t = t.slice(3) : W(C, i) ? t = i.slice(2) : t = i[2] + t.slice(3), s || r) {
|
|
336
346
|
const a = t.endsWith(te);
|
|
337
|
-
t = t.replace(De, ""), s &&
|
|
347
|
+
t = t.replace(De, ""), s && x.rel(e, t, s, a), r && x.ael(e, t, r, a);
|
|
338
348
|
}
|
|
339
349
|
} else {
|
|
340
350
|
const a = V(r);
|
|
341
|
-
if ((n || a && r !== null) && !
|
|
351
|
+
if ((n || a && r !== null) && !o)
|
|
342
352
|
try {
|
|
343
353
|
if (e.tagName.includes("-"))
|
|
344
354
|
e[t] = r;
|
|
@@ -349,17 +359,17 @@ var Ae = (e) => {
|
|
|
349
359
|
} catch {
|
|
350
360
|
}
|
|
351
361
|
let d = !1;
|
|
352
|
-
i !== (i = i.replace(/^xlink\:?/, "")) && (t = i, d = !0), r == null || r === !1 ? (r !== !1 || e.getAttribute(t) === "") && (d ? e.removeAttributeNS(z, t) : e.removeAttribute(t)) : (!n ||
|
|
362
|
+
i !== (i = i.replace(/^xlink\:?/, "")) && (t = i, d = !0), r == null || r === !1 ? (r !== !1 || e.getAttribute(t) === "") && (d ? e.removeAttributeNS(z, t) : e.removeAttribute(t)) : (!n || l & 4 || o) && !a && (r = r === !0 ? "" : r, d ? e.setAttributeNS(z, t, r) : e.setAttribute(t, r));
|
|
353
363
|
}
|
|
354
364
|
}
|
|
355
|
-
}, Me = /\s/,
|
|
356
|
-
const r = t.$elm$.nodeType === 11 && t.$elm$.host ? t.$elm$.host : t.$elm$,
|
|
357
|
-
for (const n of
|
|
358
|
-
n in
|
|
359
|
-
for (const n of
|
|
360
|
-
|
|
365
|
+
}, Me = /\s/, G = (e) => e ? e.split(Me) : [], te = "Capture", De = new RegExp(te + "$"), se = (e, t, s) => {
|
|
366
|
+
const r = t.$elm$.nodeType === 11 && t.$elm$.host ? t.$elm$.host : t.$elm$, o = e && e.$attrs$ || I, l = t.$attrs$ || I;
|
|
367
|
+
for (const n of X(Object.keys(o)))
|
|
368
|
+
n in l || q(r, n, o[n], void 0, s, t.$flags$);
|
|
369
|
+
for (const n of X(Object.keys(l)))
|
|
370
|
+
q(r, n, o[n], l[n], s, t.$flags$);
|
|
361
371
|
};
|
|
362
|
-
function
|
|
372
|
+
function X(e) {
|
|
363
373
|
return e.includes("ref") ? (
|
|
364
374
|
// we need to sort these to ensure that `'ref'` is the last attr
|
|
365
375
|
[...e.filter((t) => t !== "ref"), "ref"]
|
|
@@ -368,11 +378,11 @@ function G(e) {
|
|
|
368
378
|
e
|
|
369
379
|
);
|
|
370
380
|
}
|
|
371
|
-
var T,
|
|
372
|
-
var
|
|
373
|
-
const
|
|
381
|
+
var T, w, E, O = !1, M = !1, H = !1, h = !1, D = (e, t, s, r) => {
|
|
382
|
+
var o;
|
|
383
|
+
const l = t.$children$[s];
|
|
374
384
|
let n = 0, i, a, d;
|
|
375
|
-
if (
|
|
385
|
+
if (O || (H = !0, l.$tag$ === "slot" && (T && r.classList.add(T + "-s"), l.$flags$ |= l.$children$ ? (
|
|
376
386
|
// slot element has fallback content
|
|
377
387
|
// still create an element that "mocks" the slot element
|
|
378
388
|
2
|
|
@@ -381,84 +391,84 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
381
391
|
// create an html comment we'll use to always reference
|
|
382
392
|
// where actual slot content should sit next to
|
|
383
393
|
1
|
|
384
|
-
))),
|
|
385
|
-
i =
|
|
386
|
-
else if (
|
|
387
|
-
i =
|
|
394
|
+
))), l.$text$ !== null)
|
|
395
|
+
i = l.$elm$ = j.createTextNode(l.$text$);
|
|
396
|
+
else if (l.$flags$ & 1)
|
|
397
|
+
i = l.$elm$ = j.createTextNode("");
|
|
388
398
|
else {
|
|
389
|
-
if (h || (h =
|
|
399
|
+
if (h || (h = l.$tag$ === "svg"), i = l.$elm$ = j.createElementNS(
|
|
390
400
|
h ? me : Te,
|
|
391
|
-
|
|
392
|
-
), h &&
|
|
393
|
-
for (n = 0; n <
|
|
394
|
-
a =
|
|
395
|
-
|
|
401
|
+
!O && N.slotRelocation && l.$flags$ & 2 ? "slot-fb" : l.$tag$
|
|
402
|
+
), h && l.$tag$ === "foreignObject" && (h = !1), se(null, l, h), ke(T) && i["s-si"] !== T && i.classList.add(i["s-si"] = T), B(i, r), l.$children$)
|
|
403
|
+
for (n = 0; n < l.$children$.length; ++n)
|
|
404
|
+
a = D(e, l, n, i), a && i.appendChild(a);
|
|
405
|
+
l.$tag$ === "svg" ? h = !1 : i.tagName === "foreignObject" && (h = !0);
|
|
396
406
|
}
|
|
397
|
-
return i["s-hn"] =
|
|
407
|
+
return i["s-hn"] = E, l.$flags$ & 3 && (i["s-sr"] = !0, i["s-cr"] = w, i["s-sn"] = l.$name$ || "", i["s-rf"] = (o = l.$attrs$) == null ? void 0 : o.ref, d = e && e.$children$ && e.$children$[s], d && d.$tag$ === l.$tag$ && e.$elm$ && A(e.$elm$, !1)), i;
|
|
398
408
|
}, A = (e, t) => {
|
|
399
|
-
|
|
409
|
+
x.$flags$ |= 1;
|
|
400
410
|
const s = Array.from(e.childNodes);
|
|
401
|
-
if (e["s-sr"] &&
|
|
411
|
+
if (e["s-sr"] && N.experimentalSlotFixes) {
|
|
402
412
|
let r = e;
|
|
403
413
|
for (; r = r.nextSibling; )
|
|
404
|
-
r && r["s-sn"] === e["s-sn"] && r["s-sh"] ===
|
|
414
|
+
r && r["s-sn"] === e["s-sn"] && r["s-sh"] === E && s.push(r);
|
|
405
415
|
}
|
|
406
416
|
for (let r = s.length - 1; r >= 0; r--) {
|
|
407
|
-
const
|
|
408
|
-
|
|
417
|
+
const o = s[r];
|
|
418
|
+
o["s-hn"] !== E && o["s-ol"] && (m(le(o), o, P(o)), o["s-ol"].remove(), o["s-ol"] = void 0, o["s-sh"] = void 0, H = !0), t && A(o, t);
|
|
409
419
|
}
|
|
410
|
-
|
|
411
|
-
}, re = (e, t, s, r,
|
|
420
|
+
x.$flags$ &= -2;
|
|
421
|
+
}, re = (e, t, s, r, o, l) => {
|
|
412
422
|
let n = e["s-cr"] && e["s-cr"].parentNode || e, i;
|
|
413
|
-
for (n.shadowRoot && n.tagName ===
|
|
414
|
-
r[
|
|
415
|
-
},
|
|
423
|
+
for (n.shadowRoot && n.tagName === E && (n = n.shadowRoot); o <= l; ++o)
|
|
424
|
+
r[o] && (i = D(null, s, o, e), i && (r[o].$elm$ = i, m(n, i, P(t))));
|
|
425
|
+
}, oe = (e, t, s) => {
|
|
416
426
|
for (let r = t; r <= s; ++r) {
|
|
417
|
-
const
|
|
418
|
-
if (
|
|
419
|
-
const
|
|
420
|
-
ae(
|
|
427
|
+
const o = e[r];
|
|
428
|
+
if (o) {
|
|
429
|
+
const l = o.$elm$;
|
|
430
|
+
ae(o), l && (M = !0, l["s-ol"] ? l["s-ol"].remove() : A(l, !0), l.remove());
|
|
421
431
|
}
|
|
422
432
|
}
|
|
423
|
-
}, Ne = (e, t, s, r,
|
|
424
|
-
let
|
|
425
|
-
for (;
|
|
433
|
+
}, Ne = (e, t, s, r, o = !1) => {
|
|
434
|
+
let l = 0, n = 0, i = 0, a = 0, d = t.length - 1, u = t[0], f = t[d], $ = r.length - 1, c = r[0], p = r[$], b, y;
|
|
435
|
+
for (; l <= d && n <= $; )
|
|
426
436
|
if (u == null)
|
|
427
|
-
u = t[++
|
|
437
|
+
u = t[++l];
|
|
428
438
|
else if (f == null)
|
|
429
439
|
f = t[--d];
|
|
430
440
|
else if (c == null)
|
|
431
441
|
c = r[++n];
|
|
432
442
|
else if (p == null)
|
|
433
443
|
p = r[--$];
|
|
434
|
-
else if (R(u, c,
|
|
435
|
-
k(u, c,
|
|
436
|
-
else if (R(f, p,
|
|
437
|
-
k(f, p,
|
|
438
|
-
else if (R(u, p,
|
|
439
|
-
(u.$tag$ === "slot" || p.$tag$ === "slot") && A(u.$elm$.parentNode, !1), k(u, p,
|
|
440
|
-
else if (R(f, c,
|
|
441
|
-
(u.$tag$ === "slot" || p.$tag$ === "slot") && A(f.$elm$.parentNode, !1), k(f, c,
|
|
444
|
+
else if (R(u, c, o))
|
|
445
|
+
k(u, c, o), u = t[++l], c = r[++n];
|
|
446
|
+
else if (R(f, p, o))
|
|
447
|
+
k(f, p, o), f = t[--d], p = r[--$];
|
|
448
|
+
else if (R(u, p, o))
|
|
449
|
+
(u.$tag$ === "slot" || p.$tag$ === "slot") && A(u.$elm$.parentNode, !1), k(u, p, o), m(e, u.$elm$, f.$elm$.nextSibling), u = t[++l], p = r[--$];
|
|
450
|
+
else if (R(f, c, o))
|
|
451
|
+
(u.$tag$ === "slot" || p.$tag$ === "slot") && A(f.$elm$.parentNode, !1), k(f, c, o), m(e, f.$elm$, u.$elm$), f = t[--d], c = r[++n];
|
|
442
452
|
else {
|
|
443
|
-
for (i = -1, a =
|
|
453
|
+
for (i = -1, a = l; a <= d; ++a)
|
|
444
454
|
if (t[a] && t[a].$key$ !== null && t[a].$key$ === c.$key$) {
|
|
445
455
|
i = a;
|
|
446
456
|
break;
|
|
447
457
|
}
|
|
448
|
-
i >= 0 ? (y = t[i], y.$tag$ !== c.$tag$ ? b =
|
|
458
|
+
i >= 0 ? (y = t[i], y.$tag$ !== c.$tag$ ? b = D(t && t[n], s, i, e) : (k(y, c, o), t[i] = void 0, b = y.$elm$), c = r[++n]) : (b = D(t && t[n], s, n, e), c = r[++n]), b && m(le(u.$elm$), b, P(u.$elm$));
|
|
449
459
|
}
|
|
450
|
-
|
|
460
|
+
l > d ? re(
|
|
451
461
|
e,
|
|
452
462
|
r[$ + 1] == null ? null : r[$ + 1].$elm$,
|
|
453
463
|
s,
|
|
454
464
|
r,
|
|
455
465
|
n,
|
|
456
466
|
$
|
|
457
|
-
) : n > $ &&
|
|
458
|
-
}, R = (e, t, s = !1) => e.$tag$ === t.$tag$ ? e.$tag$ === "slot" ? e.$name$ === t.$name$ : s ? !0 : e.$key$ === t.$key$ : !1,
|
|
459
|
-
const r = t.$elm$ = e.$elm$,
|
|
467
|
+
) : n > $ && oe(t, l, d);
|
|
468
|
+
}, R = (e, t, s = !1) => e.$tag$ === t.$tag$ ? e.$tag$ === "slot" ? e.$name$ === t.$name$ : s ? !0 : e.$key$ === t.$key$ : !1, P = (e) => e && e["s-ol"] || e, le = (e) => (e["s-ol"] ? e["s-ol"] : e).parentNode, k = (e, t, s = !1) => {
|
|
469
|
+
const r = t.$elm$ = e.$elm$, o = e.$children$, l = t.$children$, n = t.$tag$, i = t.$text$;
|
|
460
470
|
let a;
|
|
461
|
-
i === null ? (h = n === "svg" ? !0 : n === "foreignObject" ? !1 : h, n === "slot" && !
|
|
471
|
+
i === null ? (h = n === "svg" ? !0 : n === "foreignObject" ? !1 : h, n === "slot" && !O || se(e, t, h), o !== null && l !== null ? Ne(r, o, t, l, s) : l !== null ? (e.$text$ !== null && (r.textContent = ""), re(r, null, t, l, 0, l.length - 1)) : o !== null && oe(o, 0, o.length - 1), h && n === "svg" && (h = !1)) : (a = r["s-cr"]) ? a.parentNode.textContent = i : e.$text$ !== i && (r.data = i);
|
|
462
472
|
}, ne = (e) => {
|
|
463
473
|
const t = e.childNodes;
|
|
464
474
|
for (const s of t)
|
|
@@ -466,14 +476,14 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
466
476
|
if (s["s-sr"]) {
|
|
467
477
|
const r = s["s-sn"];
|
|
468
478
|
s.hidden = !1;
|
|
469
|
-
for (const
|
|
470
|
-
if (
|
|
471
|
-
if (
|
|
472
|
-
if (
|
|
479
|
+
for (const o of t)
|
|
480
|
+
if (o !== s) {
|
|
481
|
+
if (o["s-hn"] !== s["s-hn"] || r !== "") {
|
|
482
|
+
if (o.nodeType === 1 && (r === o.getAttribute("slot") || r === o["s-sn"]) || o.nodeType === 3 && r === o["s-sn"]) {
|
|
473
483
|
s.hidden = !0;
|
|
474
484
|
break;
|
|
475
485
|
}
|
|
476
|
-
} else if (
|
|
486
|
+
} else if (o.nodeType === 1 || o.nodeType === 3 && o.textContent.trim() !== "") {
|
|
477
487
|
s.hidden = !0;
|
|
478
488
|
break;
|
|
479
489
|
}
|
|
@@ -483,31 +493,31 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
483
493
|
}
|
|
484
494
|
}, S = [], ie = (e) => {
|
|
485
495
|
let t, s, r;
|
|
486
|
-
for (const
|
|
487
|
-
if (
|
|
496
|
+
for (const o of e.childNodes) {
|
|
497
|
+
if (o["s-sr"] && (t = o["s-cr"]) && t.parentNode) {
|
|
488
498
|
s = t.parentNode.childNodes;
|
|
489
|
-
const
|
|
499
|
+
const l = o["s-sn"];
|
|
490
500
|
for (r = s.length - 1; r >= 0; r--)
|
|
491
|
-
if (t = s[r], !t["s-cn"] && !t["s-nr"] && t["s-hn"] !==
|
|
492
|
-
if (
|
|
501
|
+
if (t = s[r], !t["s-cn"] && !t["s-nr"] && t["s-hn"] !== o["s-hn"] && !N.experimentalSlotFixes)
|
|
502
|
+
if (K(t, l)) {
|
|
493
503
|
let n = S.find((i) => i.$nodeToRelocate$ === t);
|
|
494
|
-
|
|
495
|
-
$slotRefNode$:
|
|
504
|
+
M = !0, t["s-sn"] = t["s-sn"] || l, n ? (n.$nodeToRelocate$["s-sh"] = o["s-hn"], n.$slotRefNode$ = o) : (t["s-sh"] = o["s-hn"], S.push({
|
|
505
|
+
$slotRefNode$: o,
|
|
496
506
|
$nodeToRelocate$: t
|
|
497
507
|
})), t["s-sr"] && S.map((i) => {
|
|
498
|
-
|
|
508
|
+
K(i.$nodeToRelocate$, t["s-sn"]) && (n = S.find((a) => a.$nodeToRelocate$ === t), n && !i.$slotRefNode$ && (i.$slotRefNode$ = n.$slotRefNode$));
|
|
499
509
|
});
|
|
500
510
|
} else S.some((n) => n.$nodeToRelocate$ === t) || S.push({
|
|
501
511
|
$nodeToRelocate$: t
|
|
502
512
|
});
|
|
503
513
|
}
|
|
504
|
-
|
|
514
|
+
o.nodeType === 1 && ie(o);
|
|
505
515
|
}
|
|
506
|
-
},
|
|
516
|
+
}, K = (e, t) => e.nodeType === 1 ? e.getAttribute("slot") === null && t === "" || e.getAttribute("slot") === t : e["s-sn"] === t ? !0 : t === "", ae = (e) => {
|
|
507
517
|
e.$attrs$ && e.$attrs$.ref && e.$attrs$.ref(null), e.$children$ && e.$children$.map(ae);
|
|
508
518
|
}, m = (e, t, s) => {
|
|
509
519
|
const r = e == null ? void 0 : e.insertBefore(t, s);
|
|
510
|
-
return
|
|
520
|
+
return B(t, e), r;
|
|
511
521
|
}, ce = (e) => {
|
|
512
522
|
const t = [];
|
|
513
523
|
return e && t.push(
|
|
@@ -516,25 +526,25 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
516
526
|
e["s-sc"],
|
|
517
527
|
...ce(e.parentElement)
|
|
518
528
|
), t;
|
|
519
|
-
},
|
|
529
|
+
}, B = (e, t, s = !1) => {
|
|
520
530
|
var r;
|
|
521
531
|
if (e && t && e.nodeType === 1) {
|
|
522
|
-
const
|
|
523
|
-
if (
|
|
524
|
-
for (const
|
|
525
|
-
|
|
532
|
+
const o = new Set(ce(t).filter(Boolean));
|
|
533
|
+
if (o.size && ((r = e.classList) == null || r.add(...e["s-scs"] = [...o]), e["s-ol"] || s))
|
|
534
|
+
for (const l of Array.from(e.childNodes))
|
|
535
|
+
B(l, e, !0);
|
|
526
536
|
}
|
|
527
537
|
}, _e = (e, t, s = !1) => {
|
|
528
|
-
var r,
|
|
529
|
-
const a = e.$hostElement$, d = e.$cmpMeta$, u = e.$vnode$ ||
|
|
530
|
-
if (
|
|
538
|
+
var r, o, l, n, i;
|
|
539
|
+
const a = e.$hostElement$, d = e.$cmpMeta$, u = e.$vnode$ || U(null, null), f = Oe(t) ? t : Re(null, null, t);
|
|
540
|
+
if (E = a.tagName, d.$attrsToReflect$ && (f.$attrs$ = f.$attrs$ || {}, d.$attrsToReflect$.map(
|
|
531
541
|
([$, c]) => f.$attrs$[c] = a[$]
|
|
532
542
|
)), s && f.$attrs$)
|
|
533
543
|
for (const $ of Object.keys(f.$attrs$))
|
|
534
544
|
a.hasAttribute($) && !["key", "ref", "style", "class"].includes($) && (f.$attrs$[$] = a[$]);
|
|
535
|
-
f.$tag$ = null, f.$flags$ |= 4, e.$vnode$ = f, f.$elm$ = u.$elm$ = a.shadowRoot || a, T = a["s-sc"],
|
|
545
|
+
f.$tag$ = null, f.$flags$ |= 4, e.$vnode$ = f, f.$elm$ = u.$elm$ = a.shadowRoot || a, T = a["s-sc"], O = (d.$flags$ & 1) !== 0, w = a["s-cr"], M = !1, k(u, f, s);
|
|
536
546
|
{
|
|
537
|
-
if (
|
|
547
|
+
if (x.$flags$ |= 1, H) {
|
|
538
548
|
ie(f.$elm$);
|
|
539
549
|
for (const $ of S) {
|
|
540
550
|
const c = $.$nodeToRelocate$;
|
|
@@ -551,7 +561,7 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
551
561
|
{
|
|
552
562
|
let L = (r = c["s-ol"]) == null ? void 0 : r.previousSibling;
|
|
553
563
|
for (; L; ) {
|
|
554
|
-
let g = (
|
|
564
|
+
let g = (o = L["s-nr"]) != null ? o : null;
|
|
555
565
|
if (g && g["s-sn"] === c["s-sn"] && b === g.parentNode) {
|
|
556
566
|
for (g = g.nextSibling; g === c || g != null && g["s-sr"]; )
|
|
557
567
|
g = g == null ? void 0 : g.nextSibling;
|
|
@@ -563,55 +573,45 @@ var T, F, x, w = !1, O = !1, C = !1, h = !1, M = (e, t, s, r) => {
|
|
|
563
573
|
L = L.previousSibling;
|
|
564
574
|
}
|
|
565
575
|
}
|
|
566
|
-
(!y && b !== c.parentNode || c.nextSibling !== y) && c !== y && (!c["s-hn"] && c["s-ol"] && (c["s-hn"] = c["s-ol"].parentNode.nodeName), m(b, c, y), c.nodeType === 1 && (c.hidden = (
|
|
576
|
+
(!y && b !== c.parentNode || c.nextSibling !== y) && c !== y && (!c["s-hn"] && c["s-ol"] && (c["s-hn"] = c["s-ol"].parentNode.nodeName), m(b, c, y), c.nodeType === 1 && (c.hidden = (l = c["s-ih"]) != null ? l : !1)), c && typeof p["s-rf"] == "function" && p["s-rf"](c);
|
|
567
577
|
} else
|
|
568
578
|
c.nodeType === 1 && (s && (c["s-ih"] = (n = c.hidden) != null ? n : !1), c.hidden = !0);
|
|
569
579
|
}
|
|
570
580
|
}
|
|
571
|
-
|
|
581
|
+
M && ne(f.$elm$), x.$flags$ &= -2, S.length = 0;
|
|
572
582
|
}
|
|
573
|
-
if (
|
|
583
|
+
if (N.experimentalScopedSlotChanges && d.$flags$ & 2)
|
|
574
584
|
for (const $ of f.$elm$.childNodes)
|
|
575
|
-
$["s-hn"] !==
|
|
576
|
-
|
|
577
|
-
}, K = (e, t) => t in e, B = typeof window < "u" ? window : {}, j = B.document || { head: {} };
|
|
578
|
-
B.HTMLElement;
|
|
579
|
-
var E = {
|
|
580
|
-
$flags$: 0,
|
|
581
|
-
$resourcesUrl$: "",
|
|
582
|
-
jmp: (e) => e(),
|
|
583
|
-
raf: (e) => requestAnimationFrame(e),
|
|
584
|
-
ael: (e, t, s, r) => e.addEventListener(t, s, r),
|
|
585
|
-
rel: (e, t, s, r) => e.removeEventListener(t, s, r),
|
|
586
|
-
ce: (e, t) => new CustomEvent(e, t)
|
|
585
|
+
$["s-hn"] !== E && !$["s-sh"] && (s && $["s-ih"] == null && ($["s-ih"] = (i = $.hidden) != null ? i : !1), $.hidden = !0);
|
|
586
|
+
w = void 0;
|
|
587
587
|
};
|
|
588
588
|
const Fe = (e, t, s) => {
|
|
589
589
|
[null, void 0, "", !1].includes(s) || ["innerHTML", "style"].includes(t) || e.setAttribute(t, ["object", "function"].includes(typeof s) ? "/!\\ Object props are not rendered in the code example" : s);
|
|
590
|
-
}, fe = (e, t, s, r,
|
|
590
|
+
}, fe = (e, t, s, r, o) => {
|
|
591
591
|
if (t && typeof t == "string") {
|
|
592
|
-
const
|
|
592
|
+
const l = document.createElement(t);
|
|
593
593
|
Object.keys(s || {}).forEach((n) => {
|
|
594
|
-
Fe(
|
|
594
|
+
Fe(l, n, s[n]);
|
|
595
595
|
}), r == null || r.forEach((n) => {
|
|
596
|
-
fe(
|
|
597
|
-
}), s != null && s.innerHTML && (
|
|
596
|
+
fe(l, n.$tag$, n.$attrs$, n.$children$, n.$text$);
|
|
597
|
+
}), s != null && s.innerHTML && (l.innerHTML = s.innerHTML), e.appendChild(l);
|
|
598
598
|
}
|
|
599
|
-
|
|
599
|
+
o && (e.innerHTML = o);
|
|
600
600
|
}, et = (e, t) => {
|
|
601
601
|
const s = {};
|
|
602
602
|
if (typeof e != "object")
|
|
603
603
|
throw new Error("filterArgs - args isn't an object.");
|
|
604
604
|
for (const r in e)
|
|
605
605
|
if (!r.startsWith("slot")) {
|
|
606
|
-
const
|
|
607
|
-
(!t || !Object.keys(t).includes(r) || t[r] !==
|
|
606
|
+
const o = e[r], l = r.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
607
|
+
(!t || !Object.keys(t).includes(r) || t[r] !== o) && (s[l] = o);
|
|
608
608
|
}
|
|
609
609
|
return s;
|
|
610
610
|
}, tt = (e, t) => {
|
|
611
|
-
var r,
|
|
611
|
+
var r, o;
|
|
612
612
|
const s = document.getElementById("storybook-root");
|
|
613
613
|
if (s)
|
|
614
|
-
return (
|
|
614
|
+
return (o = document.querySelector("[lang]")) == null || o.setAttribute("lang", ((r = t.globals) == null ? void 0 : r.locale) || "en"), _e(
|
|
615
615
|
{
|
|
616
616
|
$ancestorComponent$: void 0,
|
|
617
617
|
$flags$: 0,
|
|
@@ -625,11 +625,11 @@ const Fe = (e, t, s) => {
|
|
|
625
625
|
e(t)
|
|
626
626
|
), s.children[s.children.length - 1];
|
|
627
627
|
}, st = ({ $tag$: e, $attrs$: t, $children$: s, $text$: r }) => {
|
|
628
|
-
const
|
|
629
|
-
return fe(
|
|
628
|
+
const o = document.createElement("div");
|
|
629
|
+
return fe(o, e, t, s, r), o.innerHTML;
|
|
630
630
|
}, rt = ({ disconnect: e, observe: t, takeRecords: s }) => {
|
|
631
631
|
class r {
|
|
632
|
-
constructor(
|
|
632
|
+
constructor(l) {
|
|
633
633
|
/**
|
|
634
634
|
*
|
|
635
635
|
*/
|
|
@@ -646,19 +646,19 @@ const Fe = (e, t, s) => {
|
|
|
646
646
|
*
|
|
647
647
|
*/
|
|
648
648
|
v(this, "cb");
|
|
649
|
-
this.cb =
|
|
649
|
+
this.cb = l;
|
|
650
650
|
}
|
|
651
651
|
}
|
|
652
|
-
return [window, global].forEach((
|
|
653
|
-
Object.defineProperty(
|
|
652
|
+
return [window, global].forEach((o) => {
|
|
653
|
+
Object.defineProperty(o, "MutationObserver", {
|
|
654
654
|
writable: !0,
|
|
655
655
|
configurable: !0,
|
|
656
656
|
value: r
|
|
657
657
|
});
|
|
658
658
|
}), r;
|
|
659
|
-
},
|
|
659
|
+
}, ot = ({ disconnect: e, observe: t }) => {
|
|
660
660
|
class s {
|
|
661
|
-
constructor(
|
|
661
|
+
constructor(o) {
|
|
662
662
|
/**
|
|
663
663
|
*
|
|
664
664
|
*/
|
|
@@ -675,7 +675,7 @@ const Fe = (e, t, s) => {
|
|
|
675
675
|
*
|
|
676
676
|
*/
|
|
677
677
|
v(this, "cb");
|
|
678
|
-
this.cb =
|
|
678
|
+
this.cb = o;
|
|
679
679
|
}
|
|
680
680
|
}
|
|
681
681
|
return [window, global].forEach((r) => {
|
|
@@ -696,7 +696,7 @@ class Ue extends Event {
|
|
|
696
696
|
v(this, "detail");
|
|
697
697
|
}
|
|
698
698
|
}
|
|
699
|
-
const
|
|
699
|
+
const lt = () => {
|
|
700
700
|
class e extends Ue {
|
|
701
701
|
}
|
|
702
702
|
return [window, global].forEach((t) => {
|
|
@@ -728,8 +728,8 @@ export {
|
|
|
728
728
|
Ye as localeNumber,
|
|
729
729
|
Ge as nextTick,
|
|
730
730
|
rt as setupMutationObserverMock,
|
|
731
|
-
|
|
732
|
-
|
|
731
|
+
ot as setupResizeObserverMock,
|
|
732
|
+
lt as setupSubmitEventMock,
|
|
733
733
|
tt as stencilWrapper,
|
|
734
734
|
Ke as vsCodeGenerator,
|
|
735
735
|
Xe as webTypesGenerator
|