@mgdis/mg-components 5.27.1 → 5.27.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{index-4b43c17b.js → index-00072168.js} +43 -43
- package/dist/cjs/index-00072168.js.map +1 -0
- package/dist/cjs/{index-83102ab3.js → index-7e27c7ae.js} +26 -3
- package/dist/cjs/index-7e27c7ae.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mg-action-more_36.cjs.entry.js +138 -138
- package/dist/cjs/mg-action-more_36.cjs.entry.js.map +1 -1
- package/dist/cjs/mg-components.cjs.js +2 -2
- package/dist/cjs/mg-components.cjs.js.map +1 -1
- package/dist/cjs/mg-loader.cjs.entry.js +4 -4
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/atoms/mg-button/mg-button.js +1 -1
- package/dist/collection/components/atoms/mg-button/mg-button.js.map +1 -1
- package/dist/collection/components/atoms/mg-card/mg-card.js +1 -1
- package/dist/collection/components/atoms/mg-card/mg-card.js.map +1 -1
- package/dist/collection/components/atoms/mg-character-left/mg-character-left.js +1 -1
- package/dist/collection/components/atoms/mg-divider/mg-divider.js +1 -1
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js +1 -1
- package/dist/collection/components/atoms/mg-input-title/mg-input-title.js.map +1 -1
- package/dist/collection/components/atoms/mg-tag/mg-tag.js +1 -1
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip-content/mg-tooltip-content.js +1 -1
- package/dist/collection/components/atoms/mg-tooltip/mg-tooltip.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input/mg-input.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox-paginated/mg-input-checkbox-paginated.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-checkbox/mg-input-checkbox.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-date/mg-input-date.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-numeric/mg-input-numeric.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-password/mg-input-password.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-radio/mg-input-radio.js +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-select/mg-input-select.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js +3 -3
- package/dist/collection/components/molecules/inputs/mg-input-text/mg-input-text.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js +2 -2
- package/dist/collection/components/molecules/inputs/mg-input-textarea/mg-input-textarea.js.map +1 -1
- package/dist/collection/components/molecules/inputs/mg-input-toggle/mg-input-toggle.js +1 -1
- package/dist/collection/components/molecules/menu/mg-menu/mg-menu.js +1 -1
- package/dist/collection/components/molecules/menu/mg-menu-item/mg-menu-item.js +1 -1
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js +3 -3
- package/dist/collection/components/molecules/mg-action-more/mg-action-more.js.map +1 -1
- package/dist/collection/components/molecules/mg-details/mg-details.js +1 -1
- package/dist/collection/components/molecules/mg-form/mg-form.js +1 -1
- package/dist/collection/components/molecules/mg-form/mg-form.js.map +1 -1
- package/dist/collection/components/molecules/mg-illustrated-message/mg-illustrated-message.js +3 -3
- package/dist/collection/components/molecules/mg-item-more/mg-item-more.js +2 -2
- package/dist/collection/components/molecules/mg-item-more/mg-item-more.js.map +1 -1
- package/dist/collection/components/molecules/mg-loader/mg-loader.js +1 -1
- package/dist/collection/components/molecules/mg-message/mg-message.js +1 -1
- package/dist/collection/components/molecules/mg-message/mg-message.js.map +1 -1
- package/dist/collection/components/molecules/mg-modal/mg-modal.js +2 -2
- package/dist/collection/components/molecules/mg-modal/mg-modal.js.map +1 -1
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js +3 -3
- package/dist/collection/components/molecules/mg-pagination/mg-pagination.js.map +1 -1
- package/dist/collection/components/molecules/mg-panel/mg-panel.js +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover-content/mg-popover-content.js +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover-content/mg-popover-content.js.map +1 -1
- package/dist/collection/components/molecules/mg-popover/mg-popover.js +1 -1
- package/dist/collection/components/molecules/mg-skip-links/mg-skip-links.js +1 -1
- package/dist/collection/components/molecules/mg-tabs/mg-tabs.js +1 -1
- package/dist/components/index.es.js +39 -39
- package/dist/components/index.es.js.map +1 -1
- package/dist/components/index2.js +2 -2
- package/dist/components/mg-action-more.js +5 -5
- package/dist/components/mg-action-more.js.map +1 -1
- package/dist/components/mg-badge2.js +3 -3
- package/dist/components/mg-button2.js +5 -5
- package/dist/components/mg-button2.js.map +1 -1
- package/dist/components/mg-card2.js +3 -3
- package/dist/components/mg-card2.js.map +1 -1
- package/dist/components/mg-character-left2.js +1 -1
- package/dist/components/mg-details.js +3 -3
- package/dist/components/mg-divider.js +1 -1
- package/dist/components/mg-form.js +4 -4
- package/dist/components/mg-form.js.map +1 -1
- package/dist/components/mg-icon2.js +2 -2
- package/dist/components/mg-illustrated-message.js +5 -5
- package/dist/components/mg-input-checkbox-paginated2.js +2 -2
- package/dist/components/mg-input-checkbox-paginated2.js.map +1 -1
- package/dist/components/mg-input-checkbox.js +5 -5
- package/dist/components/mg-input-date.js +11 -11
- package/dist/components/mg-input-numeric.js +7 -7
- package/dist/components/mg-input-password.js +5 -5
- package/dist/components/mg-input-radio.js +5 -5
- package/dist/components/mg-input-select2.js +8 -8
- package/dist/components/mg-input-select2.js.map +1 -1
- package/dist/components/mg-input-text2.js +9 -9
- package/dist/components/mg-input-text2.js.map +1 -1
- package/dist/components/mg-input-textarea.js +8 -8
- package/dist/components/mg-input-textarea.js.map +1 -1
- package/dist/components/mg-input-title2.js +3 -3
- package/dist/components/mg-input-title2.js.map +1 -1
- package/dist/components/mg-input-toggle.js +5 -5
- package/dist/components/mg-input2.js +4 -4
- package/dist/components/mg-item-more2.js +5 -5
- package/dist/components/mg-item-more2.js.map +1 -1
- package/dist/components/mg-loader.js +3 -3
- package/dist/components/mg-menu-item2.js +6 -6
- package/dist/components/mg-message.js +4 -4
- package/dist/components/mg-message.js.map +1 -1
- package/dist/components/mg-modal.js +8 -8
- package/dist/components/mg-modal.js.map +1 -1
- package/dist/components/mg-pagination2.js +5 -5
- package/dist/components/mg-pagination2.js.map +1 -1
- package/dist/components/mg-panel.js +5 -5
- package/dist/components/mg-popover-content2.js +4 -4
- package/dist/components/mg-popover-content2.js.map +1 -1
- package/dist/components/mg-popover2.js +4 -4
- package/dist/components/mg-skip-links.js +3 -3
- package/dist/components/mg-tabs.js +7 -7
- package/dist/components/mg-tag.js +4 -4
- package/dist/components/mg-tooltip-content2.js +1 -1
- package/dist/components/mg-tooltip2.js +7 -7
- package/dist/esm/{index-c4ed16b2.js → index-8d5d1bfd.js} +41 -41
- package/dist/esm/index-8d5d1bfd.js.map +1 -0
- package/dist/esm/{index-d43d1c5d.js → index-e479d5ae.js} +26 -3
- package/dist/esm/index-e479d5ae.js.map +1 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mg-action-more_36.entry.js +138 -138
- package/dist/esm/mg-action-more_36.entry.js.map +1 -1
- package/dist/esm/mg-components.js +3 -3
- package/dist/esm/mg-components.js.map +1 -1
- package/dist/esm/mg-loader.entry.js +4 -4
- package/dist/mg-components/mg-components.esm.js +1 -1
- package/dist/mg-components/mg-components.esm.js.map +1 -1
- package/dist/mg-components/p-7315d4a6.js +3 -0
- package/dist/mg-components/p-7315d4a6.js.map +1 -0
- package/dist/mg-components/{p-350454b9.js → p-8800813b.js} +2 -2
- package/dist/mg-components/p-8800813b.js.map +1 -0
- package/dist/mg-components/{p-d4084a15.entry.js → p-99e2f42a.entry.js} +2 -2
- package/dist/mg-components/p-f9ac8927.entry.js +2 -0
- package/dist/mg-components/{p-9cdd1bc9.entry.js.map → p-f9ac8927.entry.js.map} +1 -1
- package/ide/intellij/web-types.json +1 -1
- package/ide/vscode/html-custom-data.json +1 -1
- package/package.json +10 -10
- package/dist/cjs/index-4b43c17b.js.map +0 -1
- package/dist/cjs/index-83102ab3.js.map +0 -1
- package/dist/esm/index-c4ed16b2.js.map +0 -1
- package/dist/esm/index-d43d1c5d.js.map +0 -1
- package/dist/mg-components/p-350454b9.js.map +0 -1
- package/dist/mg-components/p-9cdd1bc9.entry.js +0 -2
- package/dist/mg-components/p-cf0b0988.js +0 -3
- package/dist/mg-components/p-cf0b0988.js.map +0 -1
- /package/dist/mg-components/{p-d4084a15.entry.js.map → p-99e2f42a.entry.js.map} +0 -0
|
@@ -1,33 +1,33 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
const
|
|
7
|
-
const s = new Uint8Array(
|
|
3
|
+
var ce = Object.defineProperty;
|
|
4
|
+
var ae = (e, t, s) => t in e ? ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: s }) : e[t] = s;
|
|
5
|
+
var h = (e, t, s) => (ae(e, typeof t != "symbol" ? t + "" : t, s), s);
|
|
6
|
+
const Me = (e = "", t = 10) => {
|
|
7
|
+
const s = new Uint8Array(t);
|
|
8
8
|
crypto.getRandomValues(s);
|
|
9
|
-
const r = Array.from(s).map((n) => n.toString(16).padStart(2, "0")).join("").slice(0,
|
|
10
|
-
return
|
|
9
|
+
const r = Array.from(s).map((n) => n.toString(16).padStart(2, "0")).join("").slice(0, t);
|
|
10
|
+
return e !== "" ? `${e}-${r}` : r;
|
|
11
11
|
};
|
|
12
|
-
class
|
|
13
|
-
constructor(
|
|
12
|
+
class Oe {
|
|
13
|
+
constructor(t = []) {
|
|
14
14
|
/**
|
|
15
15
|
* Available classes
|
|
16
16
|
*/
|
|
17
|
-
|
|
17
|
+
h(this, "classes");
|
|
18
18
|
/**
|
|
19
19
|
* Add class
|
|
20
20
|
* @param className - class name to add
|
|
21
21
|
*/
|
|
22
|
-
|
|
23
|
-
this.has(
|
|
22
|
+
h(this, "add", (t) => {
|
|
23
|
+
this.has(t) || this.classes.push(t);
|
|
24
24
|
});
|
|
25
25
|
/**
|
|
26
26
|
* Delete class
|
|
27
27
|
* @param className - class name to delete
|
|
28
28
|
*/
|
|
29
|
-
|
|
30
|
-
const s = this.classes.indexOf(
|
|
29
|
+
h(this, "delete", (t) => {
|
|
30
|
+
const s = this.classes.indexOf(t);
|
|
31
31
|
s > -1 && this.classes.splice(s, 1);
|
|
32
32
|
});
|
|
33
33
|
/**
|
|
@@ -35,42 +35,42 @@ class Me {
|
|
|
35
35
|
* @param className - class name to check
|
|
36
36
|
* @returns class name is in the list
|
|
37
37
|
*/
|
|
38
|
-
|
|
38
|
+
h(this, "has", (t) => this.classes.includes(t));
|
|
39
39
|
/**
|
|
40
40
|
* Join classes seperated by spaces
|
|
41
41
|
* @returns joined values
|
|
42
42
|
*/
|
|
43
|
-
|
|
44
|
-
this.classes =
|
|
43
|
+
h(this, "join", () => this.classes.join(" "));
|
|
44
|
+
this.classes = t;
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
|
-
const
|
|
48
|
-
const
|
|
49
|
-
return [
|
|
50
|
-
},
|
|
51
|
-
if (
|
|
47
|
+
const Fe = (e) => Array.isArray(e) && e.every((t) => typeof t == "string"), De = (e, t) => t.includes(e == null ? void 0 : e.tagName.toLowerCase()), _e = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]), [identifier], mg-button', Be = (e) => {
|
|
48
|
+
const t = X(e), s = K(e);
|
|
49
|
+
return [e, ...t, ...s];
|
|
50
|
+
}, X = (e, t = []) => {
|
|
51
|
+
if (e.self !== e.top)
|
|
52
52
|
try {
|
|
53
|
-
const s =
|
|
54
|
-
return s ? (
|
|
53
|
+
const s = e.parent;
|
|
54
|
+
return s ? (t.push(s), X(s, t)) : t;
|
|
55
55
|
} catch (s) {
|
|
56
|
-
return console.error("Different hosts between iframes:", s),
|
|
56
|
+
return console.error("Different hosts between iframes:", s), t;
|
|
57
57
|
}
|
|
58
|
-
return
|
|
59
|
-
},
|
|
60
|
-
if (
|
|
61
|
-
for (const s of Array.from(
|
|
62
|
-
|
|
63
|
-
return
|
|
64
|
-
},
|
|
65
|
-
const
|
|
66
|
-
return
|
|
67
|
-
},
|
|
68
|
-
const r =
|
|
58
|
+
return t;
|
|
59
|
+
}, K = (e, t = []) => {
|
|
60
|
+
if (e.frames.length > 0)
|
|
61
|
+
for (const s of Array.from(e.frames))
|
|
62
|
+
t.push(s), K(s, t);
|
|
63
|
+
return t;
|
|
64
|
+
}, Ne = (e) => typeof e == "string" && e.trim() !== "", Ue = (e) => typeof e == "string" ? e.toLocaleLowerCase().normalize("NFD").replaceAll(/[\u0300-\u036f]/g, "") : e, Ce = async (e) => e(), We = (e) => {
|
|
65
|
+
const t = { value: "2023", pattern: "yyyy" }, s = { value: "12", pattern: "mm" }, r = { value: "24", pattern: "dd" };
|
|
66
|
+
return pe([t.value, s.value, r.value].join("-"), e).replace(t.value, t.pattern).replace(s.value, s.pattern).replace(r.value, r.pattern);
|
|
67
|
+
}, ze = (e) => e.toISOString().split("T")[0], de = (e, t, s) => {
|
|
68
|
+
const r = e.closest("[lang]"), n = Intl.NumberFormat.supportedLocalesOf(r == null ? void 0 : r.lang), l = n.length > 0 && typeof n[0] == "string" ? n[0] : navigator.language || s, o = l.split("-").shift();
|
|
69
69
|
return {
|
|
70
70
|
locale: l,
|
|
71
|
-
messages:
|
|
71
|
+
messages: t[o] || t[s]
|
|
72
72
|
};
|
|
73
|
-
},
|
|
73
|
+
}, qe = (e, t, s) => new Intl.NumberFormat(t, { style: "currency", currency: s }).format(e), we = (e, t, s = 0) => new Intl.NumberFormat(t, { minimumFractionDigits: s }).format(s > 0 ? Number(e == null ? void 0 : e.toFixed(s)) : e), ge = /^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/, pe = (e, t) => typeof e != "string" || e === "" || !ge.test(e) ? "" : new Intl.DateTimeFormat(t).format(new Date(e)), Ge = (e, t) => (s) => de(s, e, t);
|
|
74
74
|
|
|
75
75
|
const errors$1 = {
|
|
76
76
|
required: "This field is required.",
|
|
@@ -321,23 +321,23 @@ const messages = { en, fr };
|
|
|
321
321
|
* @param element - element we need to get the language
|
|
322
322
|
* @returns messages object
|
|
323
323
|
*/
|
|
324
|
-
const initLocales =
|
|
324
|
+
const initLocales = Ge(messages, defaultLocale);
|
|
325
325
|
|
|
326
326
|
exports.Be = Be;
|
|
327
|
+
exports.Ce = Ce;
|
|
327
328
|
exports.De = De;
|
|
328
329
|
exports.Fe = Fe;
|
|
329
330
|
exports.Me = Me;
|
|
330
331
|
exports.Ne = Ne;
|
|
331
332
|
exports.Oe = Oe;
|
|
332
|
-
exports.Pe = Pe;
|
|
333
|
-
exports.Re = Re;
|
|
334
333
|
exports.Ue = Ue;
|
|
335
334
|
exports.We = We;
|
|
336
335
|
exports._e = _e;
|
|
337
|
-
exports.de = de;
|
|
338
336
|
exports.ge = ge;
|
|
339
337
|
exports.initLocales = initLocales;
|
|
338
|
+
exports.pe = pe;
|
|
340
339
|
exports.qe = qe;
|
|
340
|
+
exports.we = we;
|
|
341
341
|
exports.ze = ze;
|
|
342
342
|
|
|
343
|
-
//# sourceMappingURL=index-
|
|
343
|
+
//# sourceMappingURL=index-00072168.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"file":"index-00072168.js","mappings":";;AAAA,IAAI,EAAE,GAAG,MAAM,CAAC,cAAc,CAAC;AAC/B,IAAI,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,UAAU,EAAE,CAAC,CAAC,EAAE,YAAY,EAAE,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC5Ktb,MAAM,aAAa,GAAG,IAAI,CAAC;AAC3B,MAAM,QAAQ,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC;AAE5B;;;;;MAKa,WAAW,GAAGA,EAAa,CAAC,QAAQ,EAAE,aAAa;;;;;;;;;;;;;;;;;;;","names":["defineLocales"],"sources":["../stencil-helpers/dist/index.es.js","src/locales/index.ts"],"sourcesContent":["var ce = Object.defineProperty;\nvar ae = (e, t, s) => t in e ? ce(e, t, { enumerable: !0, configurable: !0, writable: !0, value: s }) : e[t] = s;\nvar h = (e, t, s) => (ae(e, typeof t != \"symbol\" ? t + \"\" : t, s), s);\nconst Me = (e = \"\", t = 10) => {\n const s = new Uint8Array(t);\n crypto.getRandomValues(s);\n const r = Array.from(s).map((n) => n.toString(16).padStart(2, \"0\")).join(\"\").slice(0, t);\n return e !== \"\" ? `${e}-${r}` : r;\n};\nclass Oe {\n constructor(t = []) {\n /**\n * Available classes\n */\n h(this, \"classes\");\n /**\n * Add class\n * @param className - class name to add\n */\n h(this, \"add\", (t) => {\n this.has(t) || this.classes.push(t);\n });\n /**\n * Delete class\n * @param className - class name to delete\n */\n h(this, \"delete\", (t) => {\n const s = this.classes.indexOf(t);\n s > -1 && this.classes.splice(s, 1);\n });\n /**\n * Check if class exist in list\n * @param className - class name to check\n * @returns class name is in the list\n */\n h(this, \"has\", (t) => this.classes.includes(t));\n /**\n * Join classes seperated by spaces\n * @returns joined values\n */\n h(this, \"join\", () => this.classes.join(\" \"));\n this.classes = t;\n }\n}\nconst Fe = (e) => Array.isArray(e) && e.every((t) => typeof t == \"string\"), De = (e, t) => t.includes(e == null ? void 0 : e.tagName.toLowerCase()), _e = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]), [identifier], mg-button', Be = (e) => {\n const t = X(e), s = K(e);\n return [e, ...t, ...s];\n}, X = (e, t = []) => {\n if (e.self !== e.top)\n try {\n const s = e.parent;\n return s ? (t.push(s), X(s, t)) : t;\n } catch (s) {\n return console.error(\"Different hosts between iframes:\", s), t;\n }\n return t;\n}, K = (e, t = []) => {\n if (e.frames.length > 0)\n for (const s of Array.from(e.frames))\n t.push(s), K(s, t);\n return t;\n}, Ne = (e) => typeof e == \"string\" && e.trim() !== \"\", Ue = (e) => typeof e == \"string\" ? e.toLocaleLowerCase().normalize(\"NFD\").replaceAll(/[\\u0300-\\u036f]/g, \"\") : e, Ce = async (e) => e(), Q = (e, t) => {\n if (!t)\n return;\n const s = t.split(\"/\");\n return `${e}${s.slice(2, s.length - 1).join(\"-\")}--docs`;\n}, fe = (e, t) => {\n if (t)\n return `${e}${t}`;\n}, J = (e) => {\n let t = e.overview ? `${e.overview}\n\n` : \"\";\n const s = e.props.filter(({ attr: n }) => n !== void 0);\n s.length && (t += `Attributes:\n`, t += s.map(({ attr: n, docs: l }) => `- \\`${n}\\`: ${l}\n`).join(\"\"), t += `\n`);\n const r = e.props.filter(({ attr: n }) => n === void 0);\n return r.length && (t += `Properties:\n`, t += r.map(({ name: n, docs: l }) => `- \\`${n}\\`: ${l}\n`).join(\"\"), t += `\n`), e.methods.length && (t += `Methods:\n`, t += e.methods.map(({ name: n, docs: l }) => `- \\`${n}\\`: ${l}\n`).join(\"\"), t += `\n`), e.events.length && (t += `Events:\n`, t += e.events.map(({ event: n, docs: l }) => `- \\`${n}\\`: ${l}\n`).join(\"\"), t += `\n`), e.listeners.length && (t += `Listeners:\n`, t += e.listeners.map(({ event: n }) => `- \\`${n}\\`\n`).join(\"\"), t += `\n`), e.slots.length && (t += `Slots:\n`, t += e.slots.map(({ name: n, docs: l }) => `- \\`${n}\\`: ${l}\n`).join(\"\"), t += `\n`), t;\n}, F = (e) => `${e.docs}\n\nType: \\`${e.type}\\``, He = (e, t, s, r) => ({\n $schema: \"https://json.schemastore.org/web-types\",\n name: e,\n version: t,\n \"description-markup\": \"markdown\",\n contributions: {\n html: {\n elements: s.components.map((n) => {\n const l = Q(r, n.filePath);\n return {\n name: n.tag,\n description: J(n),\n \"doc-url\": l,\n attributes: n.props.filter((o) => o.attr).map((o) => ({\n name: o.attr,\n description: F(o),\n \"doc-url\": l,\n value: {\n type: o.type,\n default: o.default,\n required: o.required\n }\n })),\n js: {\n properties: n.props.map((o) => ({\n name: o.name,\n description: F(o),\n \"doc-url\": l,\n value: {\n type: o.type,\n default: o.default,\n required: o.required\n }\n })),\n events: n.events.map((o) => ({\n name: o.event,\n description: o.docs\n }))\n }\n };\n })\n }\n }\n}), $e = (e, t, s) => {\n if (s)\n return [\n { name: \"Storybook\", url: Q(e, s) },\n { name: \"Sources\", url: fe(t, s) }\n ];\n}, ue = (e) => {\n if (!e.values.some(({ value: t }) => t === void 0))\n return e.values.map(({ value: t }) => ({ name: t }));\n}, Pe = (e, t, s, r) => ({\n version: e,\n tags: t.components.map((n) => {\n const l = $e(s, r, n.filePath);\n return {\n name: n.tag,\n description: J(n),\n attributes: n.props.map((o) => ({\n name: o.attr || o.name,\n description: F(o),\n values: ue(o),\n references: l\n })),\n references: l\n };\n }),\n globalAttributes: [],\n valueSets: []\n}), We = (e) => {\n const t = { value: \"2023\", pattern: \"yyyy\" }, s = { value: \"12\", pattern: \"mm\" }, r = { value: \"24\", pattern: \"dd\" };\n return pe([t.value, s.value, r.value].join(\"-\"), e).replace(t.value, t.pattern).replace(s.value, s.pattern).replace(r.value, r.pattern);\n}, ze = (e) => e.toISOString().split(\"T\")[0], de = (e, t, s) => {\n const r = e.closest(\"[lang]\"), n = Intl.NumberFormat.supportedLocalesOf(r == null ? void 0 : r.lang), l = n.length > 0 && typeof n[0] == \"string\" ? n[0] : navigator.language || s, o = l.split(\"-\").shift();\n return {\n locale: l,\n messages: t[o] || t[s]\n };\n}, qe = (e, t, s) => new Intl.NumberFormat(t, { style: \"currency\", currency: s }).format(e), we = (e, t, s = 0) => new Intl.NumberFormat(t, { minimumFractionDigits: s }).format(s > 0 ? Number(e == null ? void 0 : e.toFixed(s)) : e), ge = /^\\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$/, pe = (e, t) => typeof e != \"string\" || e === \"\" || !ge.test(e) ? \"\" : new Intl.DateTimeFormat(t).format(new Date(e)), Ge = (e, t) => (s) => de(s, e, t), _ = {\n allRenderFn: !1,\n cmpDidLoad: !0,\n cmpDidUnload: !1,\n cmpDidUpdate: !0,\n cmpDidRender: !0,\n cmpWillLoad: !0,\n cmpWillUpdate: !0,\n cmpWillRender: !0,\n connectedCallback: !0,\n disconnectedCallback: !0,\n element: !0,\n event: !0,\n hasRenderFn: !0,\n lifecycle: !0,\n hostListener: !0,\n hostListenerTargetWindow: !0,\n hostListenerTargetDocument: !0,\n hostListenerTargetBody: !0,\n hostListenerTargetParent: !1,\n hostListenerTarget: !0,\n member: !0,\n method: !0,\n mode: !0,\n observeAttribute: !0,\n prop: !0,\n propMutable: !0,\n reflect: !0,\n scoped: !0,\n shadowDom: !0,\n slot: !0,\n cssAnnotations: !0,\n state: !0,\n style: !0,\n formAssociated: !1,\n svg: !0,\n updatable: !0,\n vdomAttribute: !0,\n vdomXlink: !0,\n vdomClass: !0,\n vdomFunctional: !0,\n vdomKey: !0,\n vdomListener: !0,\n vdomRef: !0,\n vdomPropOrAttr: !0,\n vdomRender: !0,\n vdomStyle: !0,\n vdomText: !0,\n watchCallback: !0,\n taskQueue: !0,\n hotModuleReplacement: !1,\n isDebug: !1,\n isDev: !1,\n isTesting: !1,\n hydrateServerSide: !1,\n hydrateClientSide: !1,\n lifecycleDOMEvents: !1,\n lazyLoad: !1,\n profile: !1,\n slotRelocation: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n appendChildSlotFix: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n cloneNodeFix: !1,\n hydratedAttribute: !1,\n hydratedClass: !0,\n scriptDataOpts: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n scopedSlotTextContentFix: !1,\n // TODO(STENCIL-854): Remove code related to legacy shadowDomShim field\n shadowDomShim: !1,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n slotChildNodesFix: !1,\n invisiblePrehydration: !0,\n propBoolean: !0,\n propNumber: !0,\n propString: !0,\n constructableCSS: !0,\n cmpShouldUpdate: !0,\n devTools: !1,\n shadowDelegatesFocus: !0,\n initializeNextTick: !1,\n asyncLoading: !1,\n asyncQueue: !1,\n transformTagName: !1,\n attachStyles: !0,\n // TODO(STENCIL-914): remove this option when `experimentalSlotFixes` is the default behavior\n experimentalSlotFixes: !1\n};\nlet k, D, x, B = !1, R = !1, N = !1, y = !1;\nconst H = \"http://www.w3.org/1999/xlink\", P = {}, he = \"http://www.w3.org/2000/svg\", ye = \"http://www.w3.org/1999/xhtml\", ve = (e) => e != null, Y = (e) => (e = typeof e, e === \"object\" || e === \"function\"), Z = (e, t, ...s) => {\n let r = null, n = null, l = null, o = !1, c = !1;\n const i = [], d = (f) => {\n for (let $ = 0; $ < f.length; $++)\n r = f[$], Array.isArray(r) ? d(r) : r != null && typeof r != \"boolean\" && ((o = typeof e != \"function\" && !Y(r)) && (r = String(r)), o && c ? i[i.length - 1].$text$ += r : i.push(o ? M(null, r) : r), c = o);\n };\n if (d(s), t) {\n t.key && (n = t.key), t.name && (l = t.name);\n {\n const f = t.className || t.class;\n f && (t.class = typeof f != \"object\" ? f : Object.keys(f).filter(($) => f[$]).join(\" \"));\n }\n }\n if (typeof e == \"function\")\n return e(t === null ? {} : t, i, ke);\n const u = M(e, null);\n return u.$attrs$ = t, i.length > 0 && (u.$children$ = i), u.$key$ = n, u.$name$ = l, u;\n}, M = (e, t) => {\n const s = {\n $flags$: 0,\n $tag$: e,\n $text$: t,\n $elm$: null,\n $children$: null\n };\n return s.$attrs$ = null, s.$key$ = null, s.$name$ = null, s;\n}, be = {}, Se = (e) => e && e.$tag$ === be, ke = {\n forEach: (e, t) => e.map(W).forEach(t),\n map: (e, t) => e.map(W).map(t).map(Te)\n}, W = (e) => ({\n vattrs: e.$attrs$,\n vchildren: e.$children$,\n vkey: e.$key$,\n vname: e.$name$,\n vtag: e.$tag$,\n vtext: e.$text$\n}), Te = (e) => {\n if (typeof e.vtag == \"function\") {\n const s = Object.assign({}, e.vattrs);\n return e.vkey && (s.key = e.vkey), e.vname && (s.name = e.vname), Z(e.vtag, s, ...e.vchildren || []);\n }\n const t = M(e.vtag, e.vtext);\n return t.$attrs$ = e.vattrs, t.$children$ = e.vchildren, t.$key$ = e.vkey, t.$name$ = e.vname, t;\n}, z = (e, t, s, r, n, l) => {\n if (s !== r) {\n let o = I(e, t), c = t.toLowerCase();\n if (t === \"class\") {\n const i = e.classList, d = q(s), u = q(r);\n i.remove(...d.filter((f) => f && !u.includes(f))), i.add(...u.filter((f) => f && !d.includes(f)));\n } else if (t === \"style\") {\n for (const i in s)\n (!r || r[i] == null) && (i.includes(\"-\") ? e.style.removeProperty(i) : e.style[i] = \"\");\n for (const i in r)\n (!s || r[i] !== s[i]) && (i.includes(\"-\") ? e.style.setProperty(i, r[i]) : e.style[i] = r[i]);\n } else if (t !== \"key\")\n if (t === \"ref\")\n r && r(e);\n else if (!e.__lookupSetter__(t) && t[0] === \"o\" && t[1] === \"n\") {\n if (t[2] === \"-\" ? t = t.slice(3) : I(C, c) ? t = c.slice(2) : t = c[2] + t.slice(3), s || r) {\n const i = t.endsWith(V);\n t = t.replace(me, \"\"), s && m.rel(e, t, s, i), r && m.ael(e, t, r, i);\n }\n } else {\n const i = Y(r);\n if ((o || i && r !== null) && !n)\n try {\n if (e.tagName.includes(\"-\"))\n e[t] = r;\n else {\n const u = r ?? \"\";\n t === \"list\" ? o = !1 : (s == null || e[t] != u) && (e[t] = u);\n }\n } catch {\n }\n let d = !1;\n c !== (c = c.replace(/^xlink\\:?/, \"\")) && (t = c, d = !0), r == null || r === !1 ? (r !== !1 || e.getAttribute(t) === \"\") && (d ? e.removeAttributeNS(H, t) : e.removeAttribute(t)) : (!o || l & 4 || n) && !i && (r = r === !0 ? \"\" : r, d ? e.setAttributeNS(H, t, r) : e.setAttribute(t, r));\n }\n }\n}, xe = /\\s/, q = (e) => e ? e.split(xe) : [], V = \"Capture\", me = new RegExp(V + \"$\"), ee = (e, t, s, r) => {\n const n = t.$elm$.nodeType === 11 && t.$elm$.host ? t.$elm$.host : t.$elm$, l = e && e.$attrs$ || P, o = t.$attrs$ || P;\n for (r of w(Object.keys(l)))\n r in o || z(n, r, l[r], void 0, s, t.$flags$);\n for (r of w(Object.keys(o)))\n z(n, r, l[r], o[r], s, t.$flags$);\n};\nfunction w(e) {\n return e.includes(\"ref\") ? (\n // we need to sort these to ensure that `'ref'` is the last attr\n [...e.filter((t) => t !== \"ref\"), \"ref\"]\n ) : (\n // no need to sort, return the original array\n e\n );\n}\nconst O = (e, t, s, r) => {\n var n;\n const l = t.$children$[s];\n let o = 0, c, i, d;\n if (B || (N = !0, l.$tag$ === \"slot\" && (k && r.classList.add(k + \"-s\"), l.$flags$ |= l.$children$ ? (\n // slot element has fallback content\n 2\n ) : (\n // slot element does not have fallback content\n 1\n ))), l.$text$ !== null)\n c = l.$elm$ = j.createTextNode(l.$text$);\n else if (l.$flags$ & 1)\n c = l.$elm$ = j.createTextNode(\"\");\n else {\n if (y || (y = l.$tag$ === \"svg\"), c = l.$elm$ = j.createElementNS(y ? he : ye, l.$flags$ & 2 ? \"slot-fb\" : l.$tag$), y && l.$tag$ === \"foreignObject\" && (y = !1), ee(null, l, y), ve(k) && c[\"s-si\"] !== k && c.classList.add(c[\"s-si\"] = k), l.$children$)\n for (o = 0; o < l.$children$.length; ++o)\n i = O(e, l, o, c), i && c.appendChild(i);\n l.$tag$ === \"svg\" ? y = !1 : c.tagName === \"foreignObject\" && (y = !0);\n }\n return c[\"s-hn\"] = x, l.$flags$ & 3 && (c[\"s-sr\"] = !0, c[\"s-cr\"] = D, c[\"s-sn\"] = l.$name$ || \"\", c[\"s-rf\"] = (n = l.$attrs$) === null || n === void 0 ? void 0 : n.ref, d = e && e.$children$ && e.$children$[s], d && d.$tag$ === l.$tag$ && e.$elm$ && A(e.$elm$, !1)), c;\n}, A = (e, t) => {\n m.$flags$ |= 1;\n const s = Array.from(e.childNodes);\n if (e[\"s-sr\"] && _.experimentalSlotFixes) {\n let r = e;\n for (; r = r.nextSibling; )\n r && r[\"s-sn\"] === e[\"s-sn\"] && r[\"s-sh\"] === x && s.push(r);\n }\n for (let r = s.length - 1; r >= 0; r--) {\n const n = s[r];\n n[\"s-hn\"] !== x && n[\"s-ol\"] && (re(n).insertBefore(n, U(n)), n[\"s-ol\"].remove(), n[\"s-ol\"] = void 0, n[\"s-sh\"] = void 0, N = !0), t && A(n, t);\n }\n m.$flags$ &= -2;\n}, te = (e, t, s, r, n, l) => {\n let o = e[\"s-cr\"] && e[\"s-cr\"].parentNode || e, c;\n for (o.shadowRoot && o.tagName === x && (o = o.shadowRoot); n <= l; ++n)\n r[n] && (c = O(null, s, n, e), c && (r[n].$elm$ = c, o.insertBefore(c, U(t))));\n}, se = (e, t, s) => {\n for (let r = t; r <= s; ++r) {\n const n = e[r];\n if (n) {\n const l = n.$elm$;\n oe(n), l && (R = !0, l[\"s-ol\"] ? l[\"s-ol\"].remove() : A(l, !0), l.remove());\n }\n }\n}, Ae = (e, t, s, r, n = !1) => {\n let l = 0, o = 0, c = 0, i = 0, d = t.length - 1, u = t[0], f = t[d], $ = r.length - 1, a = r[0], g = r[$], b, v;\n for (; l <= d && o <= $; )\n if (u == null)\n u = t[++l];\n else if (f == null)\n f = t[--d];\n else if (a == null)\n a = r[++o];\n else if (g == null)\n g = r[--$];\n else if (E(u, a, n))\n T(u, a, n), u = t[++l], a = r[++o];\n else if (E(f, g, n))\n T(f, g, n), f = t[--d], g = r[--$];\n else if (E(u, g, n))\n (u.$tag$ === \"slot\" || g.$tag$ === \"slot\") && A(u.$elm$.parentNode, !1), T(u, g, n), e.insertBefore(u.$elm$, f.$elm$.nextSibling), u = t[++l], g = r[--$];\n else if (E(f, a, n))\n (u.$tag$ === \"slot\" || g.$tag$ === \"slot\") && A(f.$elm$.parentNode, !1), T(f, a, n), e.insertBefore(f.$elm$, u.$elm$), f = t[--d], a = r[++o];\n else {\n for (c = -1, i = l; i <= d; ++i)\n if (t[i] && t[i].$key$ !== null && t[i].$key$ === a.$key$) {\n c = i;\n break;\n }\n c >= 0 ? (v = t[c], v.$tag$ !== a.$tag$ ? b = O(t && t[o], s, c, e) : (T(v, a, n), t[c] = void 0, b = v.$elm$), a = r[++o]) : (b = O(t && t[o], s, o, e), a = r[++o]), b && re(u.$elm$).insertBefore(b, U(u.$elm$));\n }\n l > d ? te(e, r[$ + 1] == null ? null : r[$ + 1].$elm$, s, r, o, $) : o > $ && se(t, l, d);\n}, E = (e, t, s = !1) => e.$tag$ === t.$tag$ ? e.$tag$ === \"slot\" ? e.$name$ === t.$name$ : s ? !0 : e.$key$ === t.$key$ : !1, U = (e) => e && e[\"s-ol\"] || e, re = (e) => (e[\"s-ol\"] ? e[\"s-ol\"] : e).parentNode, T = (e, t, s = !1) => {\n const r = t.$elm$ = e.$elm$, n = e.$children$, l = t.$children$, o = t.$tag$, c = t.$text$;\n let i;\n c === null ? (y = o === \"svg\" ? !0 : o === \"foreignObject\" ? !1 : y, o === \"slot\" && !B || ee(e, t, y), n !== null && l !== null ? Ae(r, n, t, l, s) : l !== null ? (e.$text$ !== null && (r.textContent = \"\"), te(r, null, t, l, 0, l.length - 1)) : n !== null && se(n, 0, n.length - 1), y && o === \"svg\" && (y = !1)) : (i = r[\"s-cr\"]) ? i.parentNode.textContent = c : e.$text$ !== c && (r.data = c);\n}, ne = (e) => {\n const t = e.childNodes;\n for (const s of t)\n if (s.nodeType === 1) {\n if (s[\"s-sr\"]) {\n const r = s[\"s-sn\"];\n s.hidden = !1;\n for (const n of t)\n if (n !== s) {\n if (n[\"s-hn\"] !== s[\"s-hn\"] || r !== \"\") {\n if (n.nodeType === 1 && (r === n.getAttribute(\"slot\") || r === n[\"s-sn\"])) {\n s.hidden = !0;\n break;\n }\n } else if (n.nodeType === 1 || n.nodeType === 3 && n.textContent.trim() !== \"\") {\n s.hidden = !0;\n break;\n }\n }\n }\n ne(s);\n }\n}, S = [], le = (e) => {\n let t, s, r;\n for (const n of e.childNodes) {\n if (n[\"s-sr\"] && (t = n[\"s-cr\"]) && t.parentNode) {\n s = t.parentNode.childNodes;\n const l = n[\"s-sn\"];\n for (r = s.length - 1; r >= 0; r--)\n if (t = s[r], !t[\"s-cn\"] && !t[\"s-nr\"] && t[\"s-hn\"] !== n[\"s-hn\"] && !_.experimentalSlotFixes)\n if (G(t, l)) {\n let o = S.find((c) => c.$nodeToRelocate$ === t);\n R = !0, t[\"s-sn\"] = t[\"s-sn\"] || l, o ? (o.$nodeToRelocate$[\"s-sh\"] = n[\"s-hn\"], o.$slotRefNode$ = n) : (t[\"s-sh\"] = n[\"s-hn\"], S.push({\n $slotRefNode$: n,\n $nodeToRelocate$: t\n })), t[\"s-sr\"] && S.map((c) => {\n G(c.$nodeToRelocate$, t[\"s-sn\"]) && (o = S.find((i) => i.$nodeToRelocate$ === t), o && !c.$slotRefNode$ && (c.$slotRefNode$ = o.$slotRefNode$));\n });\n } else\n S.some((o) => o.$nodeToRelocate$ === t) || S.push({\n $nodeToRelocate$: t\n });\n }\n n.nodeType === 1 && le(n);\n }\n}, G = (e, t) => e.nodeType === 1 ? e.getAttribute(\"slot\") === null && t === \"\" || e.getAttribute(\"slot\") === t : e[\"s-sn\"] === t ? !0 : t === \"\", oe = (e) => {\n e.$attrs$ && e.$attrs$.ref && e.$attrs$.ref(null), e.$children$ && e.$children$.map(oe);\n}, Le = (e, t, s = !1) => {\n var r, n, l, o, c;\n const i = e.$hostElement$, d = e.$cmpMeta$, u = e.$vnode$ || M(null, null), f = Se(t) ? t : Z(null, null, t);\n if (x = i.tagName, d.$attrsToReflect$ && (f.$attrs$ = f.$attrs$ || {}, d.$attrsToReflect$.map(([$, a]) => f.$attrs$[a] = i[$])), s && f.$attrs$)\n for (const $ of Object.keys(f.$attrs$))\n i.hasAttribute($) && ![\"key\", \"ref\", \"style\", \"class\"].includes($) && (f.$attrs$[$] = i[$]);\n f.$tag$ = null, f.$flags$ |= 4, e.$vnode$ = f, f.$elm$ = u.$elm$ = i.shadowRoot || i, k = i[\"s-sc\"], B = (d.$flags$ & 1) !== 0, D = i[\"s-cr\"], R = !1, T(u, f, s);\n {\n if (m.$flags$ |= 1, N) {\n le(f.$elm$);\n for (const $ of S) {\n const a = $.$nodeToRelocate$;\n if (!a[\"s-ol\"]) {\n const g = j.createTextNode(\"\");\n g[\"s-nr\"] = a, a.parentNode.insertBefore(a[\"s-ol\"] = g, a);\n }\n }\n for (const $ of S) {\n const a = $.$nodeToRelocate$, g = $.$slotRefNode$;\n if (g) {\n const b = g.parentNode;\n let v = g.nextSibling;\n {\n let L = (r = a[\"s-ol\"]) === null || r === void 0 ? void 0 : r.previousSibling;\n for (; L; ) {\n let p = (n = L[\"s-nr\"]) !== null && n !== void 0 ? n : null;\n if (p && p[\"s-sn\"] === a[\"s-sn\"] && b === p.parentNode) {\n for (p = p.nextSibling; p === a || p != null && p[\"s-sr\"]; )\n p = p == null ? void 0 : p.nextSibling;\n if (!p || !p[\"s-nr\"]) {\n v = p;\n break;\n }\n }\n L = L.previousSibling;\n }\n }\n (!v && b !== a.parentNode || a.nextSibling !== v) && a !== v && (!a[\"s-hn\"] && a[\"s-ol\"] && (a[\"s-hn\"] = a[\"s-ol\"].parentNode.nodeName), b.insertBefore(a, v), a.nodeType === 1 && (a.hidden = (l = a[\"s-ih\"]) !== null && l !== void 0 ? l : !1)), a && typeof g[\"s-rf\"] == \"function\" && g[\"s-rf\"](a);\n } else\n a.nodeType === 1 && (s && (a[\"s-ih\"] = (o = a.hidden) !== null && o !== void 0 ? o : !1), a.hidden = !0);\n }\n }\n R && ne(f.$elm$), m.$flags$ &= -2, S.length = 0;\n }\n if (_.experimentalScopedSlotChanges && d.$flags$ & 2)\n for (const $ of f.$elm$.childNodes)\n $[\"s-hn\"] !== x && !$[\"s-sh\"] && (s && $[\"s-ih\"] == null && ($[\"s-ih\"] = (c = $.hidden) !== null && c !== void 0 ? c : !1), $.hidden = !0);\n D = void 0;\n}, I = (e, t) => t in e, C = typeof window < \"u\" ? window : {}, j = C.document || { head: {} };\nC.HTMLElement;\nconst m = {\n $flags$: 0,\n $resourcesUrl$: \"\",\n jmp: (e) => e(),\n raf: (e) => requestAnimationFrame(e),\n ael: (e, t, s, r) => e.addEventListener(t, s, r),\n rel: (e, t, s, r) => e.removeEventListener(t, s, r),\n ce: (e, t) => new CustomEvent(e, t)\n}, Ee = (e, t, s) => {\n [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);\n}, ie = (e, t, s, r, n) => {\n if (t && typeof t == \"string\") {\n const l = document.createElement(t);\n Object.keys(s || {}).forEach((o) => {\n Ee(l, o, s[o]);\n }), r == null || r.forEach((o) => {\n ie(l, o.$tag$, o.$attrs$, o.$children$, o.$text$);\n }), s != null && s.innerHTML && (l.innerHTML = s.innerHTML), e.appendChild(l);\n }\n n && (e.innerHTML = n);\n}, Ie = (e, t) => {\n const s = {};\n if (typeof e != \"object\")\n throw new Error(\"filterArgs - args isn't an object.\");\n for (const r in e)\n if (!r.startsWith(\"slot\")) {\n const n = e[r], l = r.replace(/([a-z])([A-Z])/g, \"$1-$2\").toLowerCase();\n (!t || !Object.keys(t).includes(r) || t[r] !== n) && (s[l] = n);\n }\n return s;\n}, Xe = (e, t) => {\n var r, n;\n const s = document.getElementById(\"storybook-root\");\n if (s)\n return (n = document.querySelector(\"[lang]\")) == null || n.setAttribute(\"lang\", ((r = t.globals) == null ? void 0 : r.locale) || \"en\"), Le(\n {\n $ancestorComponent$: void 0,\n $flags$: 0,\n $modeName$: void 0,\n $cmpMeta$: {\n $flags$: 0,\n $tagName$: s.tagName\n },\n $hostElement$: s\n },\n e(t)\n ), s.children[s.children.length - 1];\n}, Ke = ({ $tag$: e, $attrs$: t, $children$: s, $text$: r }) => {\n const n = document.createElement(\"div\");\n return ie(n, e, t, s, r), n.innerHTML;\n}, Qe = ({ disconnect: e, observe: t, takeRecords: s }) => {\n class r {\n constructor(l) {\n /**\n *\n */\n h(this, \"disconnect\", e);\n /**\n *\n */\n h(this, \"observe\", t);\n /**\n *\n */\n h(this, \"takeRecords\", s);\n /**\n *\n */\n h(this, \"cb\");\n this.cb = l;\n }\n }\n return [window, global].forEach((n) => {\n Object.defineProperty(n, \"MutationObserver\", {\n writable: !0,\n configurable: !0,\n value: r\n });\n }), r;\n}, Je = ({ disconnect: e, observe: t }) => {\n class s {\n constructor(n) {\n /**\n *\n */\n h(this, \"disconnect\", e);\n /**\n *\n */\n h(this, \"observe\", t);\n /**\n *\n */\n h(this, \"unobserve\");\n /**\n *\n */\n h(this, \"cb\");\n this.cb = n;\n }\n }\n return [window, global].forEach((r) => {\n Object.defineProperty(r, \"ResizeObserver\", {\n writable: !0,\n configurable: !0,\n value: s\n });\n }), s;\n};\nclass je extends Event {\n constructor() {\n super(...arguments);\n /**\n *\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n h(this, \"detail\");\n }\n}\nconst Ye = () => {\n class e extends je {\n }\n return [window, global].forEach((t) => {\n Object.defineProperty(t, \"SubmitEvent\", {\n writable: !0,\n configurable: !0,\n value: e\n });\n }), e;\n};\nexport {\n Oe as ClassList,\n Fe as allItemsAreString,\n Ue as cleanString,\n Me as createID,\n ge as dateRegExp,\n ze as dateToString,\n Ge as defineLocales,\n Ie as filterArgs,\n _e as focusableElements,\n We as getLocaleDatePattern,\n X as getParentWindows,\n Ke as getStoryHTML,\n Be as getWindows,\n De as isTagName,\n Ne as isValidString,\n qe as localeCurrency,\n pe as localeDate,\n we as localeNumber,\n Ce as nextTick,\n Qe as setupMutationObserverMock,\n Je as setupResizeObserverMock,\n Ye as setupSubmitEventMock,\n Xe as stencilWrapper,\n Pe as vsCodeGenerator,\n He as webTypesGenerator\n};\n//# sourceMappingURL=index.es.js.map\n","import en from './en/messages.json';\nimport fr from './fr/messages.json';\nimport { defineLocales } from '@mgdis/stencil-helpers';\n\nconst defaultLocale = 'en';\nconst messages = { en, fr };\n\n/**\n * Get Intl object\n * @param element - element we need to get the language\n * @returns messages object\n */\nexport const initLocales = defineLocales(messages, defaultLocale);\n"],"version":3}
|
|
@@ -609,17 +609,35 @@ const updateElement = (oldVnode, newVnode, isSvgMode, memberName) => {
|
|
|
609
609
|
const newVnodeAttrs = newVnode.$attrs$ || EMPTY_OBJ;
|
|
610
610
|
{
|
|
611
611
|
// remove attributes no longer present on the vnode by setting them to undefined
|
|
612
|
-
for (memberName
|
|
612
|
+
for (memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
613
613
|
if (!(memberName in newVnodeAttrs)) {
|
|
614
614
|
setAccessor(elm, memberName, oldVnodeAttrs[memberName], undefined, isSvgMode, newVnode.$flags$);
|
|
615
615
|
}
|
|
616
616
|
}
|
|
617
617
|
}
|
|
618
618
|
// add new & update changed attributes
|
|
619
|
-
for (memberName
|
|
619
|
+
for (memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
620
620
|
setAccessor(elm, memberName, oldVnodeAttrs[memberName], newVnodeAttrs[memberName], isSvgMode, newVnode.$flags$);
|
|
621
621
|
}
|
|
622
622
|
};
|
|
623
|
+
/**
|
|
624
|
+
* Sort a list of attribute names to ensure that all the attribute names which
|
|
625
|
+
* are _not_ `"ref"` come before `"ref"`. Preserve the order of the non-ref
|
|
626
|
+
* attributes.
|
|
627
|
+
*
|
|
628
|
+
* **Note**: if the supplied attributes do not include `'ref'` then the same
|
|
629
|
+
* (by reference) array will be returned without modification.
|
|
630
|
+
*
|
|
631
|
+
* @param attrNames attribute names to sort
|
|
632
|
+
* @returns a list of attribute names, sorted if they include `"ref"`
|
|
633
|
+
*/
|
|
634
|
+
function sortedAttrNames(attrNames) {
|
|
635
|
+
return attrNames.includes('ref')
|
|
636
|
+
? // we need to sort these to ensure that `'ref'` is the last attr
|
|
637
|
+
[...attrNames.filter((attr) => attr !== 'ref'), 'ref']
|
|
638
|
+
: // no need to sort, return the original array
|
|
639
|
+
attrNames;
|
|
640
|
+
}
|
|
623
641
|
/**
|
|
624
642
|
* Create a DOM Node corresponding to one of the children of a given VNode.
|
|
625
643
|
*
|
|
@@ -1455,6 +1473,11 @@ const renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1455
1473
|
let refNode = (_b = orgLocationNode['s-nr']) !== null && _b !== void 0 ? _b : null;
|
|
1456
1474
|
if (refNode && refNode['s-sn'] === nodeToRelocate['s-sn'] && parentNodeRef === refNode.parentNode) {
|
|
1457
1475
|
refNode = refNode.nextSibling;
|
|
1476
|
+
// If the refNode is the same node to be relocated or another element's slot reference, keep searching to find the
|
|
1477
|
+
// correct relocation target
|
|
1478
|
+
while (refNode === nodeToRelocate || (refNode === null || refNode === void 0 ? void 0 : refNode['s-sr'])) {
|
|
1479
|
+
refNode = refNode === null || refNode === void 0 ? void 0 : refNode.nextSibling;
|
|
1480
|
+
}
|
|
1458
1481
|
if (!refNode || !refNode['s-nr']) {
|
|
1459
1482
|
insertBeforeNode = refNode;
|
|
1460
1483
|
break;
|
|
@@ -2535,4 +2558,4 @@ exports.promiseResolve = promiseResolve;
|
|
|
2535
2558
|
exports.registerInstance = registerInstance;
|
|
2536
2559
|
exports.setNonce = setNonce;
|
|
2537
2560
|
|
|
2538
|
-
//# sourceMappingURL=index-
|
|
2561
|
+
//# sourceMappingURL=index-7e27c7ae.js.map
|