@solid-design-system/components 5.0.0 → 5.0.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/cdn/chunks/{chunk.BRBTXWYJ.js → chunk.YB2NTPL2.js} +2 -2
- package/cdn/components/tooltip/tooltip.js +1 -1
- package/cdn/custom-elements.json +1 -1
- package/cdn/solid-components.bundle.js +1 -1
- package/cdn/solid-components.iife.js +1 -1
- package/cdn/solid-components.js +1 -1
- package/cdn/web-types.json +1 -1
- package/cdn-versioned/_components/menu/menu.js +1 -1
- package/cdn-versioned/_components/menu/menu.styles.js +1 -1
- package/cdn-versioned/_components/menu-item/menu-item.js +2 -2
- package/cdn-versioned/chunks/chunk.24NAQP34.js +4 -4
- package/cdn-versioned/chunks/chunk.2NKZVN6T.js +1 -1
- package/cdn-versioned/chunks/chunk.2OZUXFC2.js +1 -1
- package/cdn-versioned/chunks/chunk.3FDVJBSF.js +1 -1
- package/cdn-versioned/chunks/chunk.3X2DDJ4U.js +1 -1
- package/cdn-versioned/chunks/chunk.4FWO2JFZ.js +1 -1
- package/cdn-versioned/chunks/chunk.4VSK5ST5.js +1 -1
- package/cdn-versioned/chunks/chunk.4VT5Z2HL.js +1 -1
- package/cdn-versioned/chunks/chunk.5QKKX7BL.js +2 -2
- package/cdn-versioned/chunks/chunk.5QNLI2ZJ.js +3 -3
- package/cdn-versioned/chunks/chunk.5RKART7T.js +4 -4
- package/cdn-versioned/chunks/chunk.63MF7F4O.js +1 -1
- package/cdn-versioned/chunks/chunk.65USTXPJ.js +1 -1
- package/cdn-versioned/chunks/chunk.6HETYMOP.js +1 -1
- package/cdn-versioned/chunks/chunk.6HLS5XU2.js +1 -1
- package/cdn-versioned/chunks/chunk.7GCBGKAC.js +1 -1
- package/cdn-versioned/chunks/chunk.AB7XNCA6.js +1 -1
- package/cdn-versioned/chunks/chunk.ACQENQRU.js +1 -1
- package/cdn-versioned/chunks/chunk.ALYMVLUP.js +1 -1
- package/cdn-versioned/chunks/chunk.CEVVDV52.js +1 -1
- package/cdn-versioned/chunks/chunk.DCKEYTYR.js +1 -1
- package/cdn-versioned/chunks/chunk.DDYOZMUK.js +1 -1
- package/cdn-versioned/chunks/chunk.DZQ3ELX5.js +1 -1
- package/cdn-versioned/chunks/chunk.EQD3QFY2.js +1 -1
- package/cdn-versioned/chunks/chunk.GJMMISZZ.js +1 -1
- package/cdn-versioned/chunks/chunk.GUQYIKUH.js +1 -1
- package/cdn-versioned/chunks/chunk.H7MIOI36.js +1 -1
- package/cdn-versioned/chunks/chunk.I4ZKBGAB.js +1 -1
- package/cdn-versioned/chunks/chunk.IXF4WTNA.js +1 -1
- package/cdn-versioned/chunks/chunk.JGSQEZKI.js +1 -1
- package/cdn-versioned/chunks/chunk.JPHZN55N.js +1 -1
- package/cdn-versioned/chunks/chunk.KFZTALU6.js +1 -1
- package/cdn-versioned/chunks/chunk.KV2JBQ2O.js +1 -1
- package/cdn-versioned/chunks/chunk.LL5NC5IC.js +1 -1
- package/cdn-versioned/chunks/chunk.LLMJPBPU.js +1 -1
- package/cdn-versioned/chunks/chunk.NODVJPTE.js +1 -1
- package/cdn-versioned/chunks/chunk.OLLYYRFO.js +1 -1
- package/cdn-versioned/chunks/chunk.OQM23IJ6.js +1 -1
- package/cdn-versioned/chunks/chunk.OYZELC4M.js +1 -1
- package/cdn-versioned/chunks/chunk.SUL3XIWG.js +1 -1
- package/cdn-versioned/chunks/chunk.T57D67S5.js +1 -1
- package/cdn-versioned/chunks/chunk.U47LULNM.js +1 -1
- package/cdn-versioned/chunks/chunk.UCP62LZF.js +1 -1
- package/cdn-versioned/chunks/chunk.UHTFJWWX.js +1 -1
- package/cdn-versioned/chunks/chunk.UO5T3YYC.js +1 -1
- package/cdn-versioned/chunks/chunk.VEAL7L4X.js +1 -1
- package/cdn-versioned/chunks/chunk.VH5VPRX2.js +1 -1
- package/cdn-versioned/chunks/chunk.VKFY3OQC.js +1 -1
- package/cdn-versioned/chunks/chunk.W7A3TU2Z.js +1 -1
- package/cdn-versioned/chunks/chunk.XMYHQ3RJ.js +1 -1
- package/cdn-versioned/chunks/chunk.XVOWJXRK.js +1 -1
- package/cdn-versioned/chunks/chunk.XYJWLDWC.js +1 -1
- package/cdn-versioned/chunks/{chunk.BRBTXWYJ.js → chunk.YB2NTPL2.js} +2 -2
- package/cdn-versioned/components/accordion/accordion.d.ts +1 -1
- package/cdn-versioned/components/accordion-group/accordion-group.d.ts +1 -1
- package/cdn-versioned/components/animation/animation.d.ts +1 -1
- package/cdn-versioned/components/audio/audio.d.ts +1 -1
- package/cdn-versioned/components/badge/badge.d.ts +1 -1
- package/cdn-versioned/components/brandshape/brandshape.d.ts +1 -1
- package/cdn-versioned/components/button/button.d.ts +1 -1
- package/cdn-versioned/components/button-group/button-group.d.ts +1 -1
- package/cdn-versioned/components/carousel/carousel.d.ts +1 -1
- package/cdn-versioned/components/carousel-item/carousel-item.d.ts +1 -1
- package/cdn-versioned/components/checkbox/checkbox.d.ts +1 -1
- package/cdn-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
- package/cdn-versioned/components/combobox/combobox.d.ts +1 -1
- package/cdn-versioned/components/dialog/dialog.d.ts +1 -1
- package/cdn-versioned/components/divider/divider.d.ts +1 -1
- package/cdn-versioned/components/drawer/drawer.d.ts +1 -1
- package/cdn-versioned/components/dropdown/dropdown.d.ts +1 -1
- package/cdn-versioned/components/expandable/expandable.d.ts +1 -1
- package/cdn-versioned/components/flipcard/flipcard.d.ts +1 -1
- package/cdn-versioned/components/header/header.d.ts +1 -1
- package/cdn-versioned/components/icon/icon.d.ts +1 -1
- package/cdn-versioned/components/include/include.d.ts +1 -1
- package/cdn-versioned/components/input/input.d.ts +1 -1
- package/cdn-versioned/components/link/link.d.ts +1 -1
- package/cdn-versioned/components/map-marker/map-marker.d.ts +1 -1
- package/cdn-versioned/components/navigation-item/navigation-item.d.ts +1 -1
- package/cdn-versioned/components/notification/notification.d.ts +1 -1
- package/cdn-versioned/components/optgroup/optgroup.d.ts +2 -2
- package/cdn-versioned/components/option/option.d.ts +1 -1
- package/cdn-versioned/components/popup/popup.d.ts +1 -1
- package/cdn-versioned/components/quickfact/quickfact.d.ts +1 -1
- package/cdn-versioned/components/radio/radio.d.ts +1 -1
- package/cdn-versioned/components/radio-button/radio-button.d.ts +1 -1
- package/cdn-versioned/components/radio-group/radio-group.d.ts +2 -2
- package/cdn-versioned/components/scrollable/scrollable.d.ts +1 -1
- package/cdn-versioned/components/select/select.d.ts +1 -1
- package/cdn-versioned/components/spinner/spinner.d.ts +1 -1
- package/cdn-versioned/components/step/step.d.ts +1 -1
- package/cdn-versioned/components/step-group/step-group.d.ts +1 -1
- package/cdn-versioned/components/switch/switch.d.ts +1 -1
- package/cdn-versioned/components/tab/tab.d.ts +1 -1
- package/cdn-versioned/components/tab-group/tab-group.d.ts +1 -1
- package/cdn-versioned/components/tab-panel/tab-panel.d.ts +1 -1
- package/cdn-versioned/components/tag/tag.d.ts +1 -1
- package/cdn-versioned/components/textarea/textarea.d.ts +1 -1
- package/cdn-versioned/components/tooltip/tooltip.d.ts +1 -1
- package/cdn-versioned/components/tooltip/tooltip.js +1 -1
- package/cdn-versioned/components/video/video.d.ts +1 -1
- package/cdn-versioned/custom-elements.json +211 -211
- package/cdn-versioned/internal/form.js +3 -3
- package/cdn-versioned/solid-components.bundle.js +16 -16
- package/cdn-versioned/solid-components.css +2 -2
- package/cdn-versioned/solid-components.iife.js +16 -16
- package/cdn-versioned/solid-components.js +1 -1
- package/cdn-versioned/vscode.html-custom-data.json +80 -80
- package/cdn-versioned/web-types.json +137 -137
- package/dist/chunks/{chunk.Q7ULKBP6.js → chunk.34LQ4H4Y.js} +4 -10
- package/dist/components/tooltip/tooltip.js +1 -1
- package/dist/custom-elements.json +1 -1
- package/dist/solid-components.js +1 -1
- package/dist/web-types.json +1 -1
- package/dist-versioned/_components/menu/menu.js +1 -1
- package/dist-versioned/_components/menu/menu.styles.js +1 -1
- package/dist-versioned/_components/menu-item/menu-item.js +2 -2
- package/dist-versioned/chunks/chunk.2BVPWR2S.js +4 -4
- package/dist-versioned/chunks/chunk.2FRKOJLK.js +1 -1
- package/dist-versioned/chunks/{chunk.Q7ULKBP6.js → chunk.34LQ4H4Y.js} +9 -15
- package/dist-versioned/chunks/chunk.357PR2IB.js +1 -1
- package/dist-versioned/chunks/chunk.3AQM6FKF.js +2 -2
- package/dist-versioned/chunks/chunk.3MARQHUW.js +8 -8
- package/dist-versioned/chunks/chunk.4J3ZCSIH.js +2 -2
- package/dist-versioned/chunks/chunk.4JPDAEAZ.js +26 -26
- package/dist-versioned/chunks/chunk.4PVTBZ45.js +2 -2
- package/dist-versioned/chunks/chunk.5TXDZ6OQ.js +2 -2
- package/dist-versioned/chunks/chunk.6DKXZWRN.js +4 -4
- package/dist-versioned/chunks/chunk.73ZM47SZ.js +1 -1
- package/dist-versioned/chunks/chunk.75VFJ3VZ.js +4 -4
- package/dist-versioned/chunks/chunk.7GKULTU7.js +5 -5
- package/dist-versioned/chunks/chunk.AH4MJVKG.js +2 -2
- package/dist-versioned/chunks/chunk.AUFB3CF2.js +1 -1
- package/dist-versioned/chunks/chunk.BLQFQXCU.js +2 -2
- package/dist-versioned/chunks/chunk.DXLUBAVX.js +1 -1
- package/dist-versioned/chunks/chunk.ENBSTUKA.js +13 -13
- package/dist-versioned/chunks/chunk.EYYHIJ7Q.js +1 -1
- package/dist-versioned/chunks/chunk.F4LWSCE7.js +6 -6
- package/dist-versioned/chunks/chunk.F5WZXOGP.js +3 -3
- package/dist-versioned/chunks/chunk.G3LCJLER.js +5 -5
- package/dist-versioned/chunks/chunk.GCNQNIVQ.js +2 -2
- package/dist-versioned/chunks/chunk.K3HF3JA4.js +2 -2
- package/dist-versioned/chunks/chunk.KVKRZJS7.js +3 -3
- package/dist-versioned/chunks/chunk.M2VTLBRP.js +6 -6
- package/dist-versioned/chunks/chunk.M7TUM74F.js +2 -2
- package/dist-versioned/chunks/chunk.MBOP4XDK.js +1 -1
- package/dist-versioned/chunks/chunk.MGUEJDPC.js +1 -1
- package/dist-versioned/chunks/chunk.MJ3MZ7IA.js +2 -2
- package/dist-versioned/chunks/chunk.NMI37BFS.js +1 -1
- package/dist-versioned/chunks/chunk.O6YESZHA.js +1 -1
- package/dist-versioned/chunks/chunk.OGWBQ3DK.js +3 -3
- package/dist-versioned/chunks/chunk.P3M4RPHM.js +1 -1
- package/dist-versioned/chunks/chunk.P4BL4RSV.js +3 -3
- package/dist-versioned/chunks/chunk.P775L6OS.js +1 -1
- package/dist-versioned/chunks/chunk.PK3XZW2G.js +14 -14
- package/dist-versioned/chunks/chunk.QDFEG22S.js +2 -2
- package/dist-versioned/chunks/chunk.QF3WLERT.js +9 -9
- package/dist-versioned/chunks/chunk.QHQBGFCN.js +2 -2
- package/dist-versioned/chunks/chunk.QQHF7ENZ.js +1 -1
- package/dist-versioned/chunks/chunk.QZCGIMWI.js +1 -1
- package/dist-versioned/chunks/chunk.RHQ6U3DB.js +5 -5
- package/dist-versioned/chunks/chunk.SOAF3TY4.js +2 -2
- package/dist-versioned/chunks/chunk.UIQBHPD3.js +2 -2
- package/dist-versioned/chunks/chunk.V5HD2RQH.js +24 -24
- package/dist-versioned/chunks/chunk.WM4AGOIZ.js +3 -3
- package/dist-versioned/chunks/chunk.X7HYCD3E.js +3 -3
- package/dist-versioned/chunks/chunk.XI3IZCLB.js +2 -2
- package/dist-versioned/chunks/chunk.YTDKF4U7.js +11 -11
- package/dist-versioned/chunks/chunk.YTDXH4KI.js +5 -5
- package/dist-versioned/chunks/chunk.ZAWI6TGO.js +2 -2
- package/dist-versioned/components/accordion/accordion.d.ts +1 -1
- package/dist-versioned/components/accordion-group/accordion-group.d.ts +1 -1
- package/dist-versioned/components/animation/animation.d.ts +1 -1
- package/dist-versioned/components/audio/audio.d.ts +1 -1
- package/dist-versioned/components/badge/badge.d.ts +1 -1
- package/dist-versioned/components/brandshape/brandshape.d.ts +1 -1
- package/dist-versioned/components/button/button.d.ts +1 -1
- package/dist-versioned/components/button-group/button-group.d.ts +1 -1
- package/dist-versioned/components/carousel/carousel.d.ts +1 -1
- package/dist-versioned/components/carousel-item/carousel-item.d.ts +1 -1
- package/dist-versioned/components/checkbox/checkbox.d.ts +1 -1
- package/dist-versioned/components/checkbox-group/checkbox-group.d.ts +1 -1
- package/dist-versioned/components/combobox/combobox.d.ts +1 -1
- package/dist-versioned/components/dialog/dialog.d.ts +1 -1
- package/dist-versioned/components/divider/divider.d.ts +1 -1
- package/dist-versioned/components/drawer/drawer.d.ts +1 -1
- package/dist-versioned/components/dropdown/dropdown.d.ts +1 -1
- package/dist-versioned/components/expandable/expandable.d.ts +1 -1
- package/dist-versioned/components/flipcard/flipcard.d.ts +1 -1
- package/dist-versioned/components/header/header.d.ts +1 -1
- package/dist-versioned/components/icon/icon.d.ts +1 -1
- package/dist-versioned/components/include/include.d.ts +1 -1
- package/dist-versioned/components/input/input.d.ts +1 -1
- package/dist-versioned/components/link/link.d.ts +1 -1
- package/dist-versioned/components/map-marker/map-marker.d.ts +1 -1
- package/dist-versioned/components/navigation-item/navigation-item.d.ts +1 -1
- package/dist-versioned/components/notification/notification.d.ts +1 -1
- package/dist-versioned/components/optgroup/optgroup.d.ts +2 -2
- package/dist-versioned/components/option/option.d.ts +1 -1
- package/dist-versioned/components/popup/popup.d.ts +1 -1
- package/dist-versioned/components/quickfact/quickfact.d.ts +1 -1
- package/dist-versioned/components/radio/radio.d.ts +1 -1
- package/dist-versioned/components/radio-button/radio-button.d.ts +1 -1
- package/dist-versioned/components/radio-group/radio-group.d.ts +2 -2
- package/dist-versioned/components/scrollable/scrollable.d.ts +1 -1
- package/dist-versioned/components/select/select.d.ts +1 -1
- package/dist-versioned/components/spinner/spinner.d.ts +1 -1
- package/dist-versioned/components/step/step.d.ts +1 -1
- package/dist-versioned/components/step-group/step-group.d.ts +1 -1
- package/dist-versioned/components/switch/switch.d.ts +1 -1
- package/dist-versioned/components/tab/tab.d.ts +1 -1
- package/dist-versioned/components/tab-group/tab-group.d.ts +1 -1
- package/dist-versioned/components/tab-panel/tab-panel.d.ts +1 -1
- package/dist-versioned/components/tag/tag.d.ts +1 -1
- package/dist-versioned/components/textarea/textarea.d.ts +1 -1
- package/dist-versioned/components/tooltip/tooltip.d.ts +1 -1
- package/dist-versioned/components/tooltip/tooltip.js +1 -1
- package/dist-versioned/components/video/video.d.ts +1 -1
- package/dist-versioned/custom-elements.json +211 -211
- package/dist-versioned/internal/form.js +3 -3
- package/dist-versioned/solid-components.css +2 -2
- package/dist-versioned/solid-components.js +1 -1
- package/dist-versioned/vscode.html-custom-data.json +80 -80
- package/dist-versioned/web-types.json +137 -137
- package/package.json +1 -1
|
@@ -26,7 +26,7 @@ var SdCheckboxGroup = class extends SolidElement {
|
|
|
26
26
|
this.helpText = "";
|
|
27
27
|
}
|
|
28
28
|
getAllCheckboxes() {
|
|
29
|
-
return [...this.querySelectorAll("sd-5-0-
|
|
29
|
+
return [...this.querySelectorAll("sd-5-0-1-checkbox")];
|
|
30
30
|
}
|
|
31
31
|
async syncCheckboxElements() {
|
|
32
32
|
const checkboxes = this.getAllCheckboxes();
|
|
@@ -39,10 +39,10 @@ var SdCheckboxGroup = class extends SolidElement {
|
|
|
39
39
|
);
|
|
40
40
|
}
|
|
41
41
|
syncCheckboxes() {
|
|
42
|
-
if (customElements.get("sd-5-0-
|
|
42
|
+
if (customElements.get("sd-5-0-1-checkbox")) {
|
|
43
43
|
this.syncCheckboxElements();
|
|
44
44
|
} else {
|
|
45
|
-
customElements.whenDefined("sd-5-0-
|
|
45
|
+
customElements.whenDefined("sd-5-0-1-checkbox").then(() => this.syncCheckboxes());
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
handleSizeChange() {
|
|
@@ -79,7 +79,7 @@ var SdCheckboxGroup = class extends SolidElement {
|
|
|
79
79
|
*/
|
|
80
80
|
SdCheckboxGroup.styles = [
|
|
81
81
|
...SolidElement.styles,
|
|
82
|
-
css`:host{display:block}:host([orientation=vertical]) ::slotted(sd-5-0-
|
|
82
|
+
css`:host{display:block}:host([orientation=vertical]) ::slotted(sd-5-0-1-checkbox){display:flex;margin-bottom:var(--sd-spacing-2,.5rem)}:host([orientation=vertical]) ::slotted(sd-5-0-1-checkbox:last-of-type){margin-bottom:var(--sd-spacing-0,0)}:host([orientation=horizontal]) ::slotted(sd-5-0-1-checkbox){margin-right:var(--sd-spacing-6,1.5rem)}:host([orientation=horizontal]) ::slotted(sd-5-0-1-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-5-0-1-checkbox){margin-right:var(--sd-spacing-4,1rem)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-5-0-1-checkbox:last-of-type){margin-right:var(--sd-spacing-0,0)}`
|
|
83
83
|
];
|
|
84
84
|
__decorateClass([
|
|
85
85
|
property({ type: String, reflect: true })
|
|
@@ -100,7 +100,7 @@ __decorateClass([
|
|
|
100
100
|
watch("invalid", { waitUntilFirstUpdate: true })
|
|
101
101
|
], SdCheckboxGroup.prototype, "handleInvalid", 1);
|
|
102
102
|
SdCheckboxGroup = __decorateClass([
|
|
103
|
-
customElement("sd-5-0-
|
|
103
|
+
customElement("sd-5-0-1-checkbox-group")
|
|
104
104
|
], SdCheckboxGroup);
|
|
105
105
|
|
|
106
106
|
export {
|
|
@@ -55,7 +55,7 @@ var SdStepGroup = class extends SolidElement {
|
|
|
55
55
|
});
|
|
56
56
|
}
|
|
57
57
|
getAllSteps() {
|
|
58
|
-
return [...this.body.assignedElements()].filter((el) => el.tagName.toLowerCase() === "sd-5-0-
|
|
58
|
+
return [...this.body.assignedElements()].filter((el) => el.tagName.toLowerCase() === "sd-5-0-1-step");
|
|
59
59
|
}
|
|
60
60
|
/**
|
|
61
61
|
* Sets the active step.
|
|
@@ -120,7 +120,7 @@ __decorateClass([
|
|
|
120
120
|
watch("notInteractive")
|
|
121
121
|
], SdStepGroup.prototype, "handleInteractivityChange", 1);
|
|
122
122
|
SdStepGroup = __decorateClass([
|
|
123
|
-
customElement("sd-5-0-
|
|
123
|
+
customElement("sd-5-0-1-step-group")
|
|
124
124
|
], SdStepGroup);
|
|
125
125
|
|
|
126
126
|
export {
|
|
@@ -71,7 +71,7 @@ var SdRadio = class extends SolidElement {
|
|
|
71
71
|
}
|
|
72
72
|
render() {
|
|
73
73
|
return html`<span part="base" class="${cx(
|
|
74
|
-
"sd-5-0-
|
|
74
|
+
"sd-5-0-1-radio group inline-flex items-start items-center text-base leading-normal text-black cursor-pointer align-middle",
|
|
75
75
|
(this.disabled || this.visuallyDisabled) && "hover:cursor-not-allowed",
|
|
76
76
|
{
|
|
77
77
|
/* sizes, fonts */
|
|
@@ -126,7 +126,7 @@ __decorateClass([
|
|
|
126
126
|
watch(["disabled", "visually-disabled"], { waitUntilFirstUpdate: true })
|
|
127
127
|
], SdRadio.prototype, "handleDisabledChange", 1);
|
|
128
128
|
SdRadio = __decorateClass([
|
|
129
|
-
customElement("sd-5-0-
|
|
129
|
+
customElement("sd-5-0-1-radio")
|
|
130
130
|
], SdRadio);
|
|
131
131
|
|
|
132
132
|
export {
|
|
@@ -15,7 +15,7 @@ var FormControlController = class {
|
|
|
15
15
|
const disabled = this.options.disabled(this.host);
|
|
16
16
|
const name = this.options.name(this.host);
|
|
17
17
|
const value = this.options.value(this.host);
|
|
18
|
-
const isButton = this.host.tagName.toLowerCase() === "sd-5-0-
|
|
18
|
+
const isButton = this.host.tagName.toLowerCase() === "sd-5-0-1-button";
|
|
19
19
|
if (!disabled && !isButton && typeof name === "string" && name.length > 0 && typeof value !== "undefined") {
|
|
20
20
|
if (Array.isArray(value)) {
|
|
21
21
|
value.forEach((val) => {
|
|
@@ -40,7 +40,7 @@ var FormControlController = class {
|
|
|
40
40
|
event.stopImmediatePropagation();
|
|
41
41
|
const invalidElements = (_b = this.form) == null ? void 0 : _b.querySelectorAll("[data-invalid]");
|
|
42
42
|
const sdRadioGroups = Array.from(invalidElements).filter(
|
|
43
|
-
(element) => element.tagName.toLowerCase() === "sd-5-0-
|
|
43
|
+
(element) => element.tagName.toLowerCase() === "sd-5-0-1-radio-group"
|
|
44
44
|
);
|
|
45
45
|
sdRadioGroups.forEach((radioGroup) => {
|
|
46
46
|
var _a2, _b2;
|
|
@@ -88,7 +88,7 @@ var FormControlController = class {
|
|
|
88
88
|
},
|
|
89
89
|
reportValidity: (input) => typeof input.reportValidity === "function" ? input.reportValidity() : true,
|
|
90
90
|
setValue: (input, value) => input.value = value,
|
|
91
|
-
assumeInteractionOn: ["sd-5-0-
|
|
91
|
+
assumeInteractionOn: ["sd-5-0-1-input"]
|
|
92
92
|
}, options);
|
|
93
93
|
}
|
|
94
94
|
hostConnected() {
|
|
@@ -288,10 +288,10 @@ var SdAudio = class extends SolidElement {
|
|
|
288
288
|
)}" part="audio-controls"><button class="${cx(
|
|
289
289
|
"playback-speed justify-self-start text-base font-bold hover:cursor-pointer sd-interactive",
|
|
290
290
|
this.inverted && "sd-interactive--inverted"
|
|
291
|
-
)}" aria-label="${this.localize.term("playbackSpeed")} (${this.speed}x)" @click="${this.togglePlaybackSpeed}" @keydown="${this.togglePlaybackSpeedKeydown}" part="playback-speed">${this.speed}x</button><sd-5-0-
|
|
291
|
+
)}" aria-label="${this.localize.term("playbackSpeed")} (${this.speed}x)" @click="${this.togglePlaybackSpeed}" @keydown="${this.togglePlaybackSpeedKeydown}" part="playback-speed">${this.speed}x</button><sd-5-0-1-button ?inverted="${this.inverted ? true : false}" part="play-button" size="lg" @click="${!this.isPlaying ? this.playAudio : this.pauseAudio}" aria-label="${this.isPlaying ? this.localize.term("pauseAudio") : this.localize.term("playAudio")}" title="${this.isPlaying ? this.localize.term("pauseAudio") : this.localize.term("playAudio")}" class="text-3xl">${this.isPlaying ? html`<slot name="pause-icon"><sd-5-0-1-icon class="text-3xl" name="pause" library="_internal"></sd-5-0-1-icon></slot>` : html`<slot name="play-icon"><sd-5-0-1-icon class="text-3xl" name="start" library="_internal"></sd-5-0-1-icon></slot>`}</sd-5-0-1-button><div class="flex items-center justify-self-end">${this.hasSlotController.test("transcript") ? html`<button class="${cx(
|
|
292
292
|
"mr-6 w-6 h-6 hover:cursor-pointer sd-interactive",
|
|
293
293
|
this.inverted && "sd-interactive--inverted"
|
|
294
|
-
)}" aria-label="${this.isTranscriptOpen ? this.localize.term("transcriptIsOpen") : this.localize.term("openTranscript")}" @click="${this.showTranscript}" @keydown="${this.showTranscriptKeydown}" part="transcript"><sd-5-0-
|
|
294
|
+
)}" aria-label="${this.isTranscriptOpen ? this.localize.term("transcriptIsOpen") : this.localize.term("openTranscript")}" @click="${this.showTranscript}" @keydown="${this.showTranscriptKeydown}" part="transcript"><sd-5-0-1-icon class="w-6 h-6" name="transcript" library="_internal"></sd-5-0-1-icon></button>` : null} <button class="${cx("w-6 h-6 hover:cursor-pointer sd-interactive", this.inverted && "sd-interactive--inverted")}" part="volume" aria-label="${!this.isMuted ? this.localize.term("mute") : this.localize.term("unmute")}" @click="${this.toggleMute}" @keydown="${this.toggleMuteKeydown}"><sd-5-0-1-icon class="w-6 h-6" name="${this.isMuted ? "mute" : "volume"}" library="_internal"></sd-5-0-1-icon></button></div></div>`;
|
|
295
295
|
const renderTimestamps = html`<div class="${cx(
|
|
296
296
|
"w-full flex justify-between",
|
|
297
297
|
this.reversedLayout ? "mb-2" : "mt-2",
|
|
@@ -301,12 +301,12 @@ var SdAudio = class extends SolidElement {
|
|
|
301
301
|
return html`<div class="${cx("w-full flex relative", this.reversedLayout ? "flex-col-reverse" : "flex-col")}" aria-label="${this.localize.term("audioPlayer")}" part="audio-player"><slot @slotchange="${this.updateAudioDuration}"></slot>${!this.animated || this.animated && this.reversedLayout ? renderAudioControls : null}<div class="relative">${this.animated && !this.reversedLayout ? html`${renderAudioControls}` : null} ${this.animated ? html`<canvas class="w-full h-16"></canvas>` : null} ${!this.hideTimestamps && this.animated && this.reversedLayout ? renderTimestamps : null} <input class="${cx(
|
|
302
302
|
"progress-slider bg-primary appearance-none w-full cursor-pointer outline-none h-1 flex items-center sd-interactive",
|
|
303
303
|
this.inverted && "sd-interactive--inverted"
|
|
304
|
-
)}" type="range" max="100" step="0.001" value="${this.progress}" @input="${this.handleAudioProgress}" @keydown="${this.handleAudioProgressKeydown}" aria-label="${this.localize.term("seekBar")}" part="progress-slider" style="background:linear-gradient(to right,${this.inverted ? "rgb(var(--sd-color-white, 255 255 255) / 1)" : "rgb(var(--sd-color-primary, 0 53 142) / 1)"} ${progressPercentage}%,${this.animated ? "transparent" : this.inverted ? "rgb(var(--sd-color-primary-400, 153 171 208) / 1)" : "rgb(var(--sd-color-grey-400, 195 195 195) / 1)"} ${progressPercentage}%)"></div>${this.hasSlotController.test("transcript") ? html`<sd-5-0-
|
|
304
|
+
)}" type="range" max="100" step="0.001" value="${this.progress}" @input="${this.handleAudioProgress}" @keydown="${this.handleAudioProgressKeydown}" aria-label="${this.localize.term("seekBar")}" part="progress-slider" style="background:linear-gradient(to right,${this.inverted ? "rgb(var(--sd-color-white, 255 255 255) / 1)" : "rgb(var(--sd-color-primary, 0 53 142) / 1)"} ${progressPercentage}%,${this.animated ? "transparent" : this.inverted ? "rgb(var(--sd-color-primary-400, 153 171 208) / 1)" : "rgb(var(--sd-color-grey-400, 195 195 195) / 1)"} ${progressPercentage}%)"></div>${this.hasSlotController.test("transcript") ? html`<sd-5-0-1-drawer><slot name="transcript"></slot></sd-5-0-1-drawer>` : null} ${!this.hideTimestamps && (!this.animated || !this.reversedLayout) ? renderTimestamps : null}</div>`;
|
|
305
305
|
}
|
|
306
306
|
};
|
|
307
307
|
SdAudio.styles = [
|
|
308
308
|
...SolidElement.styles,
|
|
309
|
-
css`.progress-slider:focus-visible{outline:2px solid transparent;outline-offset:2px}.progress-slider::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;background-color:currentColor;border-radius:var(--sd-border-radius-full,9999px);border-style:none;height:var(--sd-spacing-4,1rem);transition-duration:.2s;-webkit-transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:var(--sd-spacing-4,1rem)}.progress-slider:focus-visible::-webkit-slider-thumb{outline-offset:2px;outline-style:solid}.progress-slider::-moz-range-thumb{-moz-appearance:none;appearance:none;background-color:currentColor;border-radius:var(--sd-border-radius-full,9999px);border-style:none;height:var(--sd-spacing-4,1rem);transition-duration:.2s;-moz-transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:var(--sd-spacing-4,1rem)}.progress-slider:focus-visible::-moz-range-thumb{outline-offset:2px;outline-style:solid}sd-5-0-
|
|
309
|
+
css`.progress-slider:focus-visible{outline:2px solid transparent;outline-offset:2px}.progress-slider::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;background-color:currentColor;border-radius:var(--sd-border-radius-full,9999px);border-style:none;height:var(--sd-spacing-4,1rem);transition-duration:.2s;-webkit-transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:var(--sd-spacing-4,1rem)}.progress-slider:focus-visible::-webkit-slider-thumb{outline-offset:2px;outline-style:solid}.progress-slider::-moz-range-thumb{-moz-appearance:none;appearance:none;background-color:currentColor;border-radius:var(--sd-border-radius-full,9999px);border-style:none;height:var(--sd-spacing-4,1rem);transition-duration:.2s;-moz-transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:var(--sd-spacing-4,1rem)}.progress-slider:focus-visible::-moz-range-thumb{outline-offset:2px;outline-style:solid}sd-5-0-1-button::part(base){align-items:center;border-radius:var(--sd-border-radius-full,9999px);display:flex;height:var(--sd-spacing-16,4rem);justify-content:center;width:var(--sd-spacing-16,4rem)}sd-5-0-1-button::part(motion-wrapper){border-radius:var(--sd-border-radius-full,9999px)}sd-5-0-1-button::part(label){align-items:center;display:flex;flex-grow:0}`
|
|
310
310
|
];
|
|
311
311
|
__decorateClass([
|
|
312
312
|
property({ type: Boolean, reflect: true, attribute: "reversed-layout" })
|
|
@@ -348,13 +348,13 @@ __decorateClass([
|
|
|
348
348
|
query('[part="audio-player"]')
|
|
349
349
|
], SdAudio.prototype, "audioPlayerContainer", 2);
|
|
350
350
|
__decorateClass([
|
|
351
|
-
query("sd-5-0-
|
|
351
|
+
query("sd-5-0-1-drawer")
|
|
352
352
|
], SdAudio.prototype, "drawer", 2);
|
|
353
353
|
__decorateClass([
|
|
354
354
|
query("canvas")
|
|
355
355
|
], SdAudio.prototype, "canvas", 2);
|
|
356
356
|
SdAudio = __decorateClass([
|
|
357
|
-
customElement("sd-5-0-
|
|
357
|
+
customElement("sd-5-0-1-audio")
|
|
358
358
|
], SdAudio);
|
|
359
359
|
|
|
360
360
|
export {
|
|
@@ -98,7 +98,7 @@ var SdVideo = class extends SolidElement {
|
|
|
98
98
|
this.playing ? "opacity-0" : "opacity-100",
|
|
99
99
|
this.isBelowBreakpoint ? "w-[48px] h-[48px]" : "w-[96px] h-[96px]",
|
|
100
100
|
"absolute left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 p-4 bg-white bg-opacity-75 rounded-full play-pause-transition outline-2 outline-offset-2 group-focus-visible:outline"
|
|
101
|
-
)}"><slot name="play-icon" part="play-icon" class="${cx(this.isBelowBreakpoint ? "text-[2rem]" : "text-[4rem]")}"><sd-5-0-
|
|
101
|
+
)}"><slot name="play-icon" part="play-icon" class="${cx(this.isBelowBreakpoint ? "text-[2rem]" : "text-[4rem]")}"><sd-5-0-1-icon id="default-play-icon" library="_internal" name="start"></sd-5-0-1-icon></slot></div></button> ${this.hasSlotController.test("poster") ? html`<div part="poster-wrapper" class="absolute left-0 top-0 w-full z-10 overflow-hidden"><slot name="poster" role="presentation"></slot></div>` : null}<slot></slot></div>`;
|
|
102
102
|
}
|
|
103
103
|
};
|
|
104
104
|
SdVideo.styles = [
|
|
@@ -115,7 +115,7 @@ __decorateClass([
|
|
|
115
115
|
property({ type: Boolean })
|
|
116
116
|
], SdVideo.prototype, "isBelowBreakpoint", 2);
|
|
117
117
|
SdVideo = __decorateClass([
|
|
118
|
-
customElement("sd-5-0-
|
|
118
|
+
customElement("sd-5-0-1-video")
|
|
119
119
|
], SdVideo);
|
|
120
120
|
|
|
121
121
|
export {
|
|
@@ -323,7 +323,7 @@ __decorateClass([
|
|
|
323
323
|
property({ attribute: "auto-size-padding", type: Number })
|
|
324
324
|
], SdPopup.prototype, "autoSizePadding", 2);
|
|
325
325
|
SdPopup = __decorateClass([
|
|
326
|
-
customElement("sd-5-0-
|
|
326
|
+
customElement("sd-5-0-1-popup")
|
|
327
327
|
], SdPopup);
|
|
328
328
|
|
|
329
329
|
export {
|
|
@@ -94,7 +94,7 @@ var SdExpandable = class extends SolidElement {
|
|
|
94
94
|
)}" @click="${this.onToggleClick}" aria-expanded="${this.open}"><div class="${cx("h-full justify-center w-full text-base flex items-center toggle")}"><span part="toggle-icon" class="${cx(
|
|
95
95
|
"flex items-center mr-2 transition-transform duration-medium ease-in-out",
|
|
96
96
|
this.open && "rotate-180"
|
|
97
|
-
)}"><slot name="expand-icon" class="${cx(this.open && "hidden")}"><sd-5-0-
|
|
97
|
+
)}"><slot name="expand-icon" class="${cx(this.open && "hidden")}"><sd-5-0-1-icon library="_internal" name="chevron-down" class="text-xl"></sd-5-0-1-icon></slot><slot name="collapse-icon" class="${cx(!this.open && "hidden")}"><sd-5-0-1-icon library="_internal" name="chevron-down" class="text-xl"></sd-5-0-1-icon></slot></span><slot name="toggle-closed" class="${cx(this.open && "hidden")}">${this.localize.term("showMore")}</slot><slot name="toggle-open" class="${cx(!this.open && "hidden")}">${this.localize.term("showLess")}</slot></div></button><details part="details" ?inert="${ifDefined(!this.open)}"><summary part="summary" aria-hidden="true" class="cursor-pointer overflow-hidden list-none"><slot name="clone"></slot></summary><div part="content" class="content content-preview overflow-hidden relative"><slot></slot></div></details></div>`;
|
|
98
98
|
}
|
|
99
99
|
firstUpdated() {
|
|
100
100
|
this.cloneContentToLightDOM();
|
|
@@ -134,7 +134,7 @@ __decorateClass([
|
|
|
134
134
|
watch("open", { waitUntilFirstUpdate: true })
|
|
135
135
|
], SdExpandable.prototype, "onOpenChange", 1);
|
|
136
136
|
SdExpandable = __decorateClass([
|
|
137
|
-
customElement("sd-5-0-
|
|
137
|
+
customElement("sd-5-0-1-expandable")
|
|
138
138
|
], SdExpandable);
|
|
139
139
|
setDefaultAnimation("expandable.show", {
|
|
140
140
|
keyframes: [{ height: "var(--component-expandable-max-block-size, 90px)" }, { height: "auto" }],
|
|
@@ -168,7 +168,7 @@ __decorateClass([
|
|
|
168
168
|
watch(["checked"], { waitUntilFirstUpdate: true })
|
|
169
169
|
], SdSwitch.prototype, "handleStateChange", 1);
|
|
170
170
|
SdSwitch = __decorateClass([
|
|
171
|
-
customElement("sd-5-0-
|
|
171
|
+
customElement("sd-5-0-1-switch")
|
|
172
172
|
], SdSwitch);
|
|
173
173
|
|
|
174
174
|
export {
|
|
@@ -208,7 +208,7 @@ __decorateClass([
|
|
|
208
208
|
watch("playbackRate")
|
|
209
209
|
], SdAnimation.prototype, "handlePlaybackRateChange", 1);
|
|
210
210
|
SdAnimation = __decorateClass([
|
|
211
|
-
customElement("sd-5-0-
|
|
211
|
+
customElement("sd-5-0-1-animation")
|
|
212
212
|
], SdAnimation);
|
|
213
213
|
|
|
214
214
|
export {
|
|
@@ -64,10 +64,10 @@ var SdQuickfact = class extends SdAccordion {
|
|
|
64
64
|
!this.expandable && "hidden"
|
|
65
65
|
)}
|
|
66
66
|
><slot name="expand-icon" class=${cx(this.open && "hidden")}>
|
|
67
|
-
<sd-5-0-
|
|
67
|
+
<sd-5-0-1-icon library="_internal" name="chevron-down"></sd-5-0-1-icon>
|
|
68
68
|
</slot>
|
|
69
69
|
<slot name="collapse-icon" class=${cx(!this.open && "hidden")}>
|
|
70
|
-
<sd-5-0-
|
|
70
|
+
<sd-5-0-1-icon library="_internal" name="chevron-down"></sd-5-0-1-icon> </slot
|
|
71
71
|
></span>
|
|
72
72
|
</${header}>
|
|
73
73
|
<div part="content" id="content" class=${cx("overflow-hidden", !this.expandable && "hidden")}>
|
|
@@ -85,7 +85,7 @@ __decorateClass([
|
|
|
85
85
|
property({ type: Boolean, reflect: true })
|
|
86
86
|
], SdQuickfact.prototype, "expandable", 2);
|
|
87
87
|
SdQuickfact = __decorateClass([
|
|
88
|
-
customElement("sd-5-0-
|
|
88
|
+
customElement("sd-5-0-1-quickfact")
|
|
89
89
|
], SdQuickfact);
|
|
90
90
|
setDefaultAnimation("quickfact.show", {
|
|
91
91
|
keyframes: [
|
|
@@ -25,7 +25,7 @@ SdCarouselItem.styles = [
|
|
|
25
25
|
css`:host{align-items:center;aspect-ratio:var(--aspect-ratio);display:flex;flex-direction:column;height:100%;justify-content:center;scroll-snap-align:start;scroll-snap-stop:always;width:100%}::slotted(img){height:100%;-o-object-fit:cover;object-fit:cover;width:100%}`
|
|
26
26
|
];
|
|
27
27
|
SdCarouselItem = __decorateClass([
|
|
28
|
-
customElement("sd-5-0-
|
|
28
|
+
customElement("sd-5-0-1-carousel-item")
|
|
29
29
|
], SdCarouselItem);
|
|
30
30
|
|
|
31
31
|
export {
|
|
@@ -118,7 +118,7 @@ var SdCheckbox = class extends SolidElement {
|
|
|
118
118
|
render() {
|
|
119
119
|
const checkboxState = this.disabled && this.indeterminate ? "disabledIndeterminate" : this.disabled && this.checked ? "disabledChecked" : this.disabled ? "disabled" : this.visuallyDisabled ? "visuallyDisabled" : this.showInvalidStyle && this.indeterminate ? "invalidIndeterminate" : this.showInvalidStyle ? "invalid" : this.checked || this.indeterminate ? "filled" : "default";
|
|
120
120
|
return html`<label part="base" class="${cx(
|
|
121
|
-
"sd-5-0-
|
|
121
|
+
"sd-5-0-1-checkbox group flex items-start text-base leading-normal text-black cursor-pointer",
|
|
122
122
|
(this.disabled || this.visuallyDisabled) && "hover:cursor-not-allowed",
|
|
123
123
|
{
|
|
124
124
|
/* sizes, fonts */
|
|
@@ -144,7 +144,7 @@ var SdCheckbox = class extends SolidElement {
|
|
|
144
144
|
filled: "border-accent hover:border-accent-550 group-hover:border-accent-550 bg-accent group-hover:bg-accent-550",
|
|
145
145
|
default: "border-neutral-800 hover:bg-neutral-200 group-hover:bg-neutral-200 bg-white"
|
|
146
146
|
}[checkboxState]
|
|
147
|
-
)}">${this.checked ? html`<sd-5-0-
|
|
147
|
+
)}">${this.checked ? html`<sd-5-0-1-icon part="checked-icon" class="text-white w-3 h-3" library="_internal" name="status-check"></sd-5-0-1-icon>` : ""} ${!this.checked && this.indeterminate ? html`<sd-5-0-1-icon part="indeterminate-icon" class="text-white w-3 h-3" library="_internal" name="status-minus"></sd-5-0-1-icon>` : ""} </span><span part="label" id="label" class="${cx(
|
|
148
148
|
"select-none inline-block ml-2",
|
|
149
149
|
this.disabled || this.visuallyDisabled ? "text-neutral-500" : this.showInvalidStyle ? "text-error" : "text-black"
|
|
150
150
|
)}"><slot></slot></span></label> ${this.formControlController.renderInvalidMessage()}`;
|
|
@@ -206,7 +206,7 @@ __decorateClass([
|
|
|
206
206
|
watch(["checked", "indeterminate"], { waitUntilFirstUpdate: true })
|
|
207
207
|
], SdCheckbox.prototype, "handleStateChange", 1);
|
|
208
208
|
SdCheckbox = __decorateClass([
|
|
209
|
-
customElement("sd-5-0-
|
|
209
|
+
customElement("sd-5-0-1-checkbox")
|
|
210
210
|
], SdCheckbox);
|
|
211
211
|
|
|
212
212
|
export {
|
|
@@ -29,8 +29,8 @@ var SdTabGroup = class extends SolidElement {
|
|
|
29
29
|
}
|
|
30
30
|
connectedCallback() {
|
|
31
31
|
const whenAllDefined = Promise.all([
|
|
32
|
-
customElements.whenDefined("sd-5-0-
|
|
33
|
-
customElements.whenDefined("sd-5-0-
|
|
32
|
+
customElements.whenDefined("sd-5-0-1-tab"),
|
|
33
|
+
customElements.whenDefined("sd-5-0-1-tab-panel")
|
|
34
34
|
]);
|
|
35
35
|
super.connectedCallback();
|
|
36
36
|
this.resizeObserver = new ResizeObserver(() => {
|
|
@@ -70,20 +70,20 @@ var SdTabGroup = class extends SolidElement {
|
|
|
70
70
|
}
|
|
71
71
|
getAllTabs(options = { includeDisabled: true }) {
|
|
72
72
|
const slot = this.shadowRoot.querySelector('slot[name="nav"]');
|
|
73
|
-
return Array.from(slot.assignedElements()).map((el) => el.tagName.toLocaleLowerCase() === "sd-5-0-
|
|
74
|
-
return el && options.includeDisabled ? el.tagName.toLowerCase() === "sd-5-0-
|
|
73
|
+
return Array.from(slot.assignedElements()).map((el) => el.tagName.toLocaleLowerCase() === "sd-5-0-1-tab" ? el : el.querySelector("sd-5-0-1-tab")).filter((el) => {
|
|
74
|
+
return el && options.includeDisabled ? el.tagName.toLowerCase() === "sd-5-0-1-tab" : el.tagName.toLowerCase() === "sd-5-0-1-tab" && !el.disabled;
|
|
75
75
|
});
|
|
76
76
|
}
|
|
77
77
|
getAllPanels() {
|
|
78
|
-
return [...this.body.assignedElements()].filter((el) => el.tagName.toLowerCase() === "sd-5-0-
|
|
78
|
+
return [...this.body.assignedElements()].filter((el) => el.tagName.toLowerCase() === "sd-5-0-1-tab-panel");
|
|
79
79
|
}
|
|
80
80
|
getActiveTab() {
|
|
81
81
|
return this.tabs.find((t) => t.matches(":focus"));
|
|
82
82
|
}
|
|
83
83
|
handleClick(event) {
|
|
84
84
|
const target = event.target;
|
|
85
|
-
const tab = target.closest("sd-5-0-
|
|
86
|
-
const tabGroup = tab == null ? void 0 : tab.closest("sd-5-0-
|
|
85
|
+
const tab = target.closest("sd-5-0-1-tab");
|
|
86
|
+
const tabGroup = tab == null ? void 0 : tab.closest("sd-5-0-1-tab-group");
|
|
87
87
|
if (tabGroup !== this) {
|
|
88
88
|
return;
|
|
89
89
|
}
|
|
@@ -93,8 +93,8 @@ var SdTabGroup = class extends SolidElement {
|
|
|
93
93
|
}
|
|
94
94
|
handleKeyDown(event) {
|
|
95
95
|
const target = event.target;
|
|
96
|
-
const tab = target.closest("sd-5-0-
|
|
97
|
-
const tabGroup = tab == null ? void 0 : tab.closest("sd-5-0-
|
|
96
|
+
const tab = target.closest("sd-5-0-1-tab");
|
|
97
|
+
const tabGroup = tab == null ? void 0 : tab.closest("sd-5-0-1-tab-group");
|
|
98
98
|
if (tabGroup !== this) {
|
|
99
99
|
return;
|
|
100
100
|
}
|
|
@@ -119,7 +119,7 @@ var SdTabGroup = class extends SolidElement {
|
|
|
119
119
|
if (["ArrowLeft", "ArrowRight", "ArrowUp", "ArrowDown", "Home", "End"].includes(event.key)) {
|
|
120
120
|
const activeEl = this.tabs.find((t) => t.matches(":focus"));
|
|
121
121
|
const isRtl = this.localize.dir() === "rtl";
|
|
122
|
-
if ((activeEl == null ? void 0 : activeEl.tagName.toLowerCase()) === "sd-5-0-
|
|
122
|
+
if ((activeEl == null ? void 0 : activeEl.tagName.toLowerCase()) === "sd-5-0-1-tab") {
|
|
123
123
|
let index = this.tabs.indexOf(activeEl);
|
|
124
124
|
if (event.key === "Home") {
|
|
125
125
|
index = 0;
|
|
@@ -215,15 +215,15 @@ var SdTabGroup = class extends SolidElement {
|
|
|
215
215
|
return html`<div part="base" class="${cx("flex flex-col rounded-none")}" @click="${this.handleClick}" @keydown="${this.handleKeyDown}"><div part="nav" class="${cx(this.hasScrollControls && "relative py-0 px-12")}">${this.hasScrollControls ? html`<button part="scroll-button--start" exportparts="base:scroll-button__base" tabindex="-1" aria-hidden="true" class="${cx(
|
|
216
216
|
"sd-interactive flex items-center justify-center absolute top-0 bottom-0 left-0 !outline-offset-0 border-b border-neutral-400 z-10",
|
|
217
217
|
this.localize.dir() === "rtl" && "left-auto right-0"
|
|
218
|
-
)}" @click="${this.handleScrollToStart}"><sd-5-0-
|
|
218
|
+
)}" @click="${this.handleScrollToStart}"><sd-5-0-1-icon library="_internal" name="${isRtl ? "chevron-up" : "chevron-down"}" label="previous" class="${cx("h-6 w-12 rotate-90 grid place-items-center")}"></sd-5-0-1-icon></button>` : ""}<div part="scroll-container" class="flex overflow-x-auto focus-visible:focus-outline !outline-offset-0"><div part="tabs" class="${cx("flex flex-auto relative flex-row")}" role="tablist"><div part="separation" class="w-full border-[0.25px] border-neutral-400 absolute bottom-0"></div><slot name="nav" @slotchange="${this.syncTabsAndPanels}"></slot></div></div>${this.hasScrollControls ? html`<button part="scroll-button--end" exportparts="base:scroll-button__base" tabindex="-1" aria-hidden="true" class="${cx(
|
|
219
219
|
"sd-interactive flex items-center justify-center absolute top-0 bottom-0 right-0 !outline-offset-0 border-b border-neutral-400 z-10",
|
|
220
220
|
this.localize.dir() === "rtl" && "right-auto left-0"
|
|
221
|
-
)}" @click="${this.handleScrollToEnd}"><sd-5-0-
|
|
221
|
+
)}" @click="${this.handleScrollToEnd}"><sd-5-0-1-icon library="_internal" name="${isRtl ? "chevron-down" : "chevron-up"}" label="next" class="${cx("h-6 w-12 rotate-90 grid place-items-center")}"></sd-5-0-1-icon></button>` : ""}</div><slot part="body" class="${cx("block auto py-8 px-6", this.variant === "container" && "border border-neutral-400 border-t-0")}" @slotchange="${this.syncTabsAndPanels}"></slot></div>`;
|
|
222
222
|
}
|
|
223
223
|
};
|
|
224
224
|
SdTabGroup.styles = [
|
|
225
225
|
...SolidElement.styles,
|
|
226
|
-
css`:host{box-sizing:border-box;display:block}[part=scroll-container]{scrollbar-width:none}[part=scroll-container]::-webkit-scrollbar{height:var(--sd-spacing-0,0);width:var(--sd-spacing-0,0)}:focus-within::slotted(sd-5-0-
|
|
226
|
+
css`:host{box-sizing:border-box;display:block}[part=scroll-container]{scrollbar-width:none}[part=scroll-container]::-webkit-scrollbar{height:var(--sd-spacing-0,0);width:var(--sd-spacing-0,0)}:focus-within::slotted(sd-5-0-1-tab-panel){outline-color:rgb(var(--sd-color-primary,0 53 142)/1);outline-offset:2px;outline-style:solid;outline-width:2px}::slotted(sd-5-0-1-tab-panel){--padding:1rem 0}`
|
|
227
227
|
];
|
|
228
228
|
__decorateClass([
|
|
229
229
|
query("[part=base]")
|
|
@@ -244,7 +244,7 @@ __decorateClass([
|
|
|
244
244
|
property({ type: String, reflect: true })
|
|
245
245
|
], SdTabGroup.prototype, "activation", 2);
|
|
246
246
|
SdTabGroup = __decorateClass([
|
|
247
|
-
customElement("sd-5-0-
|
|
247
|
+
customElement("sd-5-0-1-tab-group")
|
|
248
248
|
], SdTabGroup);
|
|
249
249
|
|
|
250
250
|
export {
|
|
@@ -18,7 +18,7 @@ var SdTabPanel = class extends SolidElement {
|
|
|
18
18
|
constructor() {
|
|
19
19
|
super(...arguments);
|
|
20
20
|
this.attrId = ++id;
|
|
21
|
-
this.componentId = `sd-5-0-
|
|
21
|
+
this.componentId = `sd-5-0-1-tab-panel-${this.attrId}`;
|
|
22
22
|
this.name = "";
|
|
23
23
|
this.active = false;
|
|
24
24
|
}
|
|
@@ -48,7 +48,7 @@ __decorateClass([
|
|
|
48
48
|
watch("active")
|
|
49
49
|
], SdTabPanel.prototype, "handleActiveChange", 1);
|
|
50
50
|
SdTabPanel = __decorateClass([
|
|
51
|
-
customElement("sd-5-0-
|
|
51
|
+
customElement("sd-5-0-1-tab-panel")
|
|
52
52
|
], SdTabPanel);
|
|
53
53
|
|
|
54
54
|
export {
|
|
@@ -76,7 +76,7 @@ var SdDropdown = class extends SolidElement {
|
|
|
76
76
|
* within the slotted trigger. This could be the slotted element itself, a child of the slotted element,
|
|
77
77
|
* or an element within the slotted elements shadow root.
|
|
78
78
|
*
|
|
79
|
-
* e.g. the accessible trigger of an <sd-5-0-
|
|
79
|
+
* e.g. the accessible trigger of an <sd-5-0-1-button> is a <button> located inside its shadow root.
|
|
80
80
|
*
|
|
81
81
|
* To determine this, we assume the first tabbable element in the trigger slot is the "accessible trigger."
|
|
82
82
|
* */
|
|
@@ -87,11 +87,11 @@ var SdDropdown = class extends SolidElement {
|
|
|
87
87
|
if (accessibleTrigger) {
|
|
88
88
|
switch (accessibleTrigger.tagName.toLowerCase()) {
|
|
89
89
|
// Solid buttons have to update the internal button so it's announced correctly by screen readers
|
|
90
|
-
case "sd-5-0-
|
|
91
|
-
case "sd-5-0-
|
|
90
|
+
case "sd-5-0-1-button":
|
|
91
|
+
case "sd-5-0-1-icon-button":
|
|
92
92
|
target = accessibleTrigger.button;
|
|
93
93
|
break;
|
|
94
|
-
case "sd-5-0-
|
|
94
|
+
case "sd-5-0-1-navigation-item":
|
|
95
95
|
target = accessibleTrigger.button;
|
|
96
96
|
break;
|
|
97
97
|
default:
|
|
@@ -236,7 +236,7 @@ var SdDropdown = class extends SolidElement {
|
|
|
236
236
|
}
|
|
237
237
|
addOpenListeners() {
|
|
238
238
|
this.panel.addEventListener("sd-activate", this.handleMenuItemActivate);
|
|
239
|
-
this.panel.addEventListener("sd-5-0-
|
|
239
|
+
this.panel.addEventListener("sd-5-0-1-select", this.handlePanelSelect);
|
|
240
240
|
this.panel.addEventListener("keydown", this.handleKeyDown);
|
|
241
241
|
document.addEventListener("keydown", this.handleDocumentKeyDown);
|
|
242
242
|
document.addEventListener("mousedown", this.handleDocumentMouseDown);
|
|
@@ -244,7 +244,7 @@ var SdDropdown = class extends SolidElement {
|
|
|
244
244
|
removeOpenListeners() {
|
|
245
245
|
if (this.panel) {
|
|
246
246
|
this.panel.removeEventListener("sd-activate", this.handleMenuItemActivate);
|
|
247
|
-
this.panel.removeEventListener("sd-5-0-
|
|
247
|
+
this.panel.removeEventListener("sd-5-0-1-select", this.handlePanelSelect);
|
|
248
248
|
this.panel.removeEventListener("keydown", this.handleKeyDown);
|
|
249
249
|
}
|
|
250
250
|
document.removeEventListener("keydown", this.handleDocumentKeyDown);
|
|
@@ -277,11 +277,11 @@ var SdDropdown = class extends SolidElement {
|
|
|
277
277
|
}
|
|
278
278
|
}
|
|
279
279
|
render() {
|
|
280
|
-
return html`<sd-5-0-
|
|
280
|
+
return html`<sd-5-0-1-popup part="base" id="dropdown" placement="${this.placement}" distance="${this.rounded && this.distance < 1 ? 1 : this.distance}" skidding="${this.skidding}" strategy="${this.hoist ? "fixed" : "absolute"}" ?flip="${!this.noFlip}" shift auto-size="vertical" auto-size-padding="10"><slot name="trigger" slot="anchor" part="trigger" class="block" @click="${this.handleTriggerClick}" @keydown="${this.handleTriggerKeyDown}" @keyup="${this.handleTriggerKeyUp}" @slotchange="${this.handleTriggerSlotChange}"></slot><slot part="panel" class="${cx(
|
|
281
281
|
"shadow bg-white block",
|
|
282
282
|
this.open ? "pointer-events-auto" : "pointer-events-none",
|
|
283
283
|
this.rounded && "rounded-md"
|
|
284
|
-
)}" aria-hidden="${this.open ? "false" : "true"}" aria-labelledby="dropdown"></slot></sd-5-0-
|
|
284
|
+
)}" aria-hidden="${this.open ? "false" : "true"}" aria-labelledby="dropdown"></slot></sd-5-0-1-popup>`;
|
|
285
285
|
}
|
|
286
286
|
};
|
|
287
287
|
SdDropdown.styles = [
|
|
@@ -334,7 +334,7 @@ __decorateClass([
|
|
|
334
334
|
watch("open", { waitUntilFirstUpdate: true })
|
|
335
335
|
], SdDropdown.prototype, "handleOpenChange", 1);
|
|
336
336
|
SdDropdown = __decorateClass([
|
|
337
|
-
customElement("sd-5-0-
|
|
337
|
+
customElement("sd-5-0-1-dropdown")
|
|
338
338
|
], SdDropdown);
|
|
339
339
|
setDefaultAnimation("dropdown.show", {
|
|
340
340
|
keyframes: [{ opacity: 0 }, { opacity: 1 }],
|
|
@@ -210,7 +210,7 @@ var SdDrawer = class extends SolidElement {
|
|
|
210
210
|
end: "top-0 end-0 bottom-auto start-auto w-[--width] h-full",
|
|
211
211
|
start: "top-0 end-auto bottom-auto start-0 w-[--width] h-full"
|
|
212
212
|
}[this.placement]
|
|
213
|
-
)}" role="dialog" aria-modal="true" aria-label="${this.label}" tabindex="0">${!this.noHeader ? html`<header part="header" class="flex justify-between py-2 px-4 items-center flex-shrink-0" style="min-height:56px"><div part="title"><slot name="header" part="title" class="flex-auto text-xl m-0" id="title"></slot></div><div class="shrink-0 flex flex-wrap justify-end gap-1 ml-4 absolute top-2 right-2"><sd-5-0-
|
|
213
|
+
)}" role="dialog" aria-modal="true" aria-label="${this.label}" tabindex="0">${!this.noHeader ? html`<header part="header" class="flex justify-between py-2 px-4 items-center flex-shrink-0" style="min-height:56px"><div part="title"><slot name="header" part="title" class="flex-auto text-xl m-0" id="title"></slot></div><div class="shrink-0 flex flex-wrap justify-end gap-1 ml-4 absolute top-2 right-2"><sd-5-0-1-button variant="tertiary" size="lg" part="close-button" @click="${() => this.requestClose("close-button")}"><sd-5-0-1-icon label="${this.localize.term("close")}" name="close" library="_internal"></sd-5-0-1-icon></sd-5-0-1-button></div></header>` : html`<sd-5-0-1-button variant="tertiary" size="lg" part="close-button" @click="${() => this.requestClose("close-button")}" class="absolute top-2 right-2"><sd-5-0-1-icon label="${this.localize.term("close")}" name="close" library="_internal"></sd-5-0-1-icon></sd-5-0-1-button>`}<div part="body" class="flex-auto block px-4 focus-visible:focus-outline !-outline-offset-2" tabindex="0"><slot></slot></div><footer part="footer" class="${cx(this.hasSlotController.test("footer") ? "text-left p-4" : "hidden")}"><slot name="footer"></slot></footer></div></section>`;
|
|
214
214
|
}
|
|
215
215
|
};
|
|
216
216
|
SdDrawer.styles = [
|
|
@@ -251,7 +251,7 @@ __decorateClass([
|
|
|
251
251
|
watch("contained", { waitUntilFirstUpdate: true })
|
|
252
252
|
], SdDrawer.prototype, "handleNoModalChange", 1);
|
|
253
253
|
SdDrawer = __decorateClass([
|
|
254
|
-
customElement("sd-5-0-
|
|
254
|
+
customElement("sd-5-0-1-drawer")
|
|
255
255
|
], SdDrawer);
|
|
256
256
|
setDefaultAnimation("drawer.showStart", {
|
|
257
257
|
keyframes: [
|
|
@@ -28,11 +28,11 @@ var SdOptgroup = class extends SolidElement {
|
|
|
28
28
|
this.label = "";
|
|
29
29
|
}
|
|
30
30
|
/**
|
|
31
|
-
* Syncs the disabled prop for all slotted sd-5-0-
|
|
31
|
+
* Syncs the disabled prop for all slotted sd-5-0-1-options when it is triggered
|
|
32
32
|
*/
|
|
33
33
|
handleDisableOptions() {
|
|
34
34
|
const { disabled } = this;
|
|
35
|
-
this.defaultSlot.assignedElements().filter((opt) => opt.tagName.toLowerCase() === "sd-5-0-
|
|
35
|
+
this.defaultSlot.assignedElements().filter((opt) => opt.tagName.toLowerCase() === "sd-5-0-1-option").forEach((opt) => {
|
|
36
36
|
opt.disabled = disabled;
|
|
37
37
|
});
|
|
38
38
|
}
|
|
@@ -41,11 +41,11 @@ var SdOptgroup = class extends SolidElement {
|
|
|
41
41
|
}
|
|
42
42
|
render() {
|
|
43
43
|
const { disabled } = this;
|
|
44
|
-
return html`<div role="${disabled ? "presentation" : "group"}" class="${cx(this.disabled ? "text-neutral-500" : "")}" part="base" aria-labelledby="group-label"><sd-5-0-
|
|
44
|
+
return html`<div role="${disabled ? "presentation" : "group"}" class="${cx(this.disabled ? "text-neutral-500" : "")}" part="base" aria-labelledby="group-label"><sd-5-0-1-divider id="divider" class="pt-2 pb-4" part="divider"></sd-5-0-1-divider><div part="label-container" class="${cx(this.disabled ? "text-neutral-500" : "text-black")} px-4 font-bold text-left" role="presentation" id="group-label"><slot name="label"><span>${this.label}</span></slot></div><div role="listbox" part="options" aria-label="${this.localize.term("optionGroup")}"><slot @slotchange="${this.handleDisableOptions}"></slot></div></div>`;
|
|
45
45
|
}
|
|
46
46
|
};
|
|
47
47
|
SdOptgroup.dependencies = {
|
|
48
|
-
"sd-5-0-
|
|
48
|
+
"sd-5-0-1-divider": SdDivider
|
|
49
49
|
};
|
|
50
50
|
SdOptgroup.styles = [
|
|
51
51
|
...SolidElement.styles,
|
|
@@ -64,7 +64,7 @@ __decorateClass([
|
|
|
64
64
|
watch("disabled", { waitUntilFirstUpdate: true })
|
|
65
65
|
], SdOptgroup.prototype, "handleDisabledChange", 1);
|
|
66
66
|
SdOptgroup = __decorateClass([
|
|
67
|
-
customElement("sd-5-0-
|
|
67
|
+
customElement("sd-5-0-1-optgroup")
|
|
68
68
|
], SdOptgroup);
|
|
69
69
|
|
|
70
70
|
export {
|
|
@@ -89,7 +89,7 @@ var SdStep = class extends SolidElement {
|
|
|
89
89
|
!this.disabled && !this.current && !this.notInteractive && "text-primary group-hover:text-primary-500 group-hover:fill-primary-500",
|
|
90
90
|
this.notInteractive && "text-primary",
|
|
91
91
|
this.size === "lg" ? "text-lg" : "text-sm"
|
|
92
|
-
)}">${!this.disabled && !this.current && !this.notInteractive ? html`<sd-5-0-
|
|
92
|
+
)}">${!this.disabled && !this.current && !this.notInteractive ? html`<sd-5-0-1-icon name="status-check" library="_internal"></sd-5-0-1-icon>` : html`${this.index}`}</slot></${tag}>${this.noTail ? "" : html`<div part="tail" class="${cx(
|
|
93
93
|
this.orientation === "horizontal" ? "border-t w-full my-auto mr-2" : "border-l flex-grow flex-shrink-0 basis-auto h-full w-[1px] mx-auto",
|
|
94
94
|
!this.disabled && !this.current && !this.notInteractive ? " border-primary group-hover:border-primary-500" : "border-neutral-400"
|
|
95
95
|
)}"></div>`}</div><div part="text-container" class="${cx("mt-4 break-words flex flex-col gap-2", this.orientation === "horizontal" ? "text-center w-40" : "w-max text-left", this.disabled && "!text-neutral-700", this.notInteractive ? "ml-3" : "mr-4")}"><div part="label" id="label" class="${cx("!font-bold sd-paragraph", this.disabled && "!text-neutral-700", !this.disabled && !this.current && !this.notInteractive ? "!text-primary group-hover:!text-primary-500 group-hover:cursor-pointer" : "text-black")}"><slot name="label">${this.label}</slot></div><div part="description" id="description" class="${cx("sd-paragraph sd-paragraph--size-sm", this.disabled && "!text-neutral-700")}">${this.description || html`<slot></slot>`}</div></div></div>`;
|
|
@@ -139,7 +139,7 @@ __decorateClass([
|
|
|
139
139
|
watch("notInteractive")
|
|
140
140
|
], SdStep.prototype, "handleInteractivityChange", 1);
|
|
141
141
|
SdStep = __decorateClass([
|
|
142
|
-
customElement("sd-5-0-
|
|
142
|
+
customElement("sd-5-0-1-step")
|
|
143
143
|
], SdStep);
|
|
144
144
|
|
|
145
145
|
export {
|