@solid-design-system/components 5.9.0 → 5.10.0
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.45UEUNN5.js +3 -0
- package/cdn/components/switch/switch.d.ts +1 -0
- package/cdn/components/switch/switch.js +1 -1
- package/cdn/custom-elements.json +5 -1
- package/cdn/solid-components.bundle.js +10 -10
- package/cdn/solid-components.iife.js +10 -10
- package/cdn/solid-components.js +1 -1
- package/cdn/vscode.html-custom-data.json +1 -1
- package/cdn/web-types.json +9 -3
- package/cdn-versioned/chunks/chunk.2JZXQAEH.js +1 -1
- package/cdn-versioned/chunks/chunk.2S6PSHGR.js +1 -1
- package/cdn-versioned/chunks/chunk.2YPPKILR.js +1 -1
- package/cdn-versioned/chunks/chunk.3I7Z2ZGA.js +1 -1
- package/cdn-versioned/chunks/chunk.3VSEXUCN.js +1 -1
- package/cdn-versioned/chunks/chunk.45UEUNN5.js +3 -0
- package/cdn-versioned/chunks/chunk.4GU7BCCI.js +1 -1
- package/cdn-versioned/chunks/chunk.6HLS5XU2.js +1 -1
- package/cdn-versioned/chunks/chunk.6NART7VP.js +1 -1
- package/cdn-versioned/chunks/chunk.7F4BLDO5.js +1 -1
- package/cdn-versioned/chunks/chunk.AD3RLPIJ.js +1 -1
- package/cdn-versioned/chunks/chunk.AOLFDR44.js +1 -1
- package/cdn-versioned/chunks/chunk.AWLGV3BD.js +1 -1
- package/cdn-versioned/chunks/chunk.AXOCHBBU.js +1 -1
- package/cdn-versioned/chunks/chunk.BBD6RMZH.js +1 -1
- package/cdn-versioned/chunks/chunk.BGEMBVJV.js +1 -1
- package/cdn-versioned/chunks/chunk.CEVVDV52.js +1 -1
- package/cdn-versioned/chunks/chunk.CMIXQ7JH.js +1 -1
- package/cdn-versioned/chunks/chunk.CMMWC4RI.js +1 -1
- package/cdn-versioned/chunks/chunk.EADKGOFJ.js +1 -1
- package/cdn-versioned/chunks/chunk.ELCOIK5P.js +1 -1
- package/cdn-versioned/chunks/chunk.FA5R7CKW.js +1 -1
- package/cdn-versioned/chunks/chunk.FCFA3AM7.js +1 -1
- package/cdn-versioned/chunks/chunk.FCYUK5NR.js +2 -2
- package/cdn-versioned/chunks/chunk.GGXUEKTA.js +4 -4
- package/cdn-versioned/chunks/chunk.GYKZUJLA.js +1 -1
- package/cdn-versioned/chunks/chunk.H3RLFSFE.js +4 -4
- package/cdn-versioned/chunks/chunk.HAFUAYZZ.js +1 -1
- package/cdn-versioned/chunks/chunk.HDPQFCGV.js +1 -1
- package/cdn-versioned/chunks/chunk.IFNRX7KW.js +1 -1
- package/cdn-versioned/chunks/chunk.IHA7PGG2.js +1 -1
- package/cdn-versioned/chunks/chunk.IRWE4TYN.js +1 -1
- package/cdn-versioned/chunks/chunk.JUPXHQZ3.js +1 -1
- package/cdn-versioned/chunks/chunk.KWDCB5GN.js +1 -1
- package/cdn-versioned/chunks/chunk.LAFGNWFC.js +1 -1
- package/cdn-versioned/chunks/chunk.LDAMQCO2.js +1 -1
- package/cdn-versioned/chunks/chunk.LNX7ZKW3.js +1 -1
- package/cdn-versioned/chunks/chunk.MGVRJCCE.js +1 -1
- package/cdn-versioned/chunks/chunk.NFHVSI66.js +1 -1
- package/cdn-versioned/chunks/chunk.PQFPJ45Y.js +1 -1
- package/cdn-versioned/chunks/chunk.R2G6FMES.js +1 -1
- package/cdn-versioned/chunks/chunk.R4DOCTBU.js +1 -1
- package/cdn-versioned/chunks/chunk.RISDA2AI.js +1 -1
- package/cdn-versioned/chunks/chunk.S53XPYBW.js +1 -1
- package/cdn-versioned/chunks/chunk.SBIDVQ2E.js +1 -1
- package/cdn-versioned/chunks/chunk.SBU6FGLK.js +1 -1
- package/cdn-versioned/chunks/chunk.SHKBYZWU.js +1 -1
- package/cdn-versioned/chunks/chunk.U6FV3MPT.js +3 -3
- package/cdn-versioned/chunks/chunk.V4CRJJ5B.js +1 -1
- package/cdn-versioned/chunks/chunk.V7ZZFRHA.js +1 -1
- package/cdn-versioned/chunks/chunk.VPGQTCNG.js +1 -1
- package/cdn-versioned/chunks/chunk.W7A3TU2Z.js +1 -1
- package/cdn-versioned/chunks/chunk.WXLNA4GN.js +1 -1
- package/cdn-versioned/chunks/chunk.XMUDHBRG.js +1 -1
- package/cdn-versioned/chunks/chunk.XRBNH2NJ.js +1 -1
- package/cdn-versioned/chunks/chunk.YOYAMVUH.js +1 -1
- package/cdn-versioned/chunks/chunk.YVTCC5NZ.js +1 -1
- package/cdn-versioned/chunks/chunk.Z4UTG2XJ.js +1 -1
- 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/breadcrumb/breadcrumb.d.ts +1 -1
- package/cdn-versioned/components/breadcrumb-item/breadcrumb-item.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/menu/menu.d.ts +1 -1
- package/cdn-versioned/components/menu-item/menu-item.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 +1 -1
- 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 +1 -1
- 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 +2 -1
- package/cdn-versioned/components/switch/switch.js +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/video/video.d.ts +1 -1
- package/cdn-versioned/custom-elements.json +233 -229
- 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 +87 -87
- package/cdn-versioned/web-types.json +154 -148
- package/dist/chunks/{chunk.J5E5UTG2.js → chunk.FDQQDXKD.js} +6 -2
- package/dist/components/switch/switch.d.ts +1 -0
- package/dist/components/switch/switch.js +2 -1
- package/dist/custom-elements.json +5 -1
- package/dist/solid-components.js +4 -4
- package/dist/vscode.html-custom-data.json +1 -1
- package/dist/web-types.json +9 -3
- package/dist-versioned/chunks/chunk.2VDSJ75Q.js +2 -2
- package/dist-versioned/chunks/chunk.3JIBD4DC.js +4 -4
- package/dist-versioned/chunks/chunk.3PUMOBIO.js +1 -1
- package/dist-versioned/chunks/chunk.47VXT6XF.js +2 -2
- package/dist-versioned/chunks/chunk.4Z5MLLDU.js +2 -2
- package/dist-versioned/chunks/chunk.5UQ6EJAW.js +1 -1
- package/dist-versioned/chunks/chunk.5XKGAQGU.js +26 -26
- package/dist-versioned/chunks/chunk.6DKXZWRN.js +4 -4
- package/dist-versioned/chunks/chunk.6ID5BKH5.js +2 -2
- package/dist-versioned/chunks/chunk.6SZYSES2.js +1 -1
- package/dist-versioned/chunks/chunk.7EMNYFIP.js +1 -1
- package/dist-versioned/chunks/chunk.7VIYCZ4Z.js +14 -14
- package/dist-versioned/chunks/chunk.7ZISZOWN.js +2 -2
- package/dist-versioned/chunks/chunk.AQKWXHIC.js +2 -2
- package/dist-versioned/chunks/chunk.BK4CYVLA.js +2 -2
- package/dist-versioned/chunks/chunk.EIUEZZ5G.js +12 -12
- package/dist-versioned/chunks/chunk.EO5MCLIR.js +2 -2
- package/dist-versioned/chunks/{chunk.J5E5UTG2.js → chunk.FDQQDXKD.js} +7 -3
- package/dist-versioned/chunks/chunk.FDUVN4I6.js +6 -6
- package/dist-versioned/chunks/chunk.FFAUGMVF.js +3 -3
- package/dist-versioned/chunks/chunk.FUGGYSQF.js +6 -6
- package/dist-versioned/chunks/chunk.I6NQOQEO.js +3 -3
- package/dist-versioned/chunks/chunk.JJTGSFOV.js +3 -3
- package/dist-versioned/chunks/chunk.JUUDZ47Q.js +1 -1
- package/dist-versioned/chunks/chunk.KEJFWGZI.js +4 -4
- package/dist-versioned/chunks/chunk.KFVC6XFD.js +2 -2
- package/dist-versioned/chunks/chunk.KVKRZJS7.js +3 -3
- package/dist-versioned/chunks/chunk.MEDUZPGV.js +4 -4
- package/dist-versioned/chunks/chunk.MEHX7EVL.js +3 -3
- package/dist-versioned/chunks/chunk.MQ5VT5VP.js +2 -2
- package/dist-versioned/chunks/chunk.N3MU3643.js +1 -1
- package/dist-versioned/chunks/chunk.N7WBIQUG.js +5 -5
- package/dist-versioned/chunks/chunk.P4UKJXBL.js +3 -3
- package/dist-versioned/chunks/chunk.PP5IDYES.js +1 -1
- package/dist-versioned/chunks/chunk.QS7N47CI.js +6 -6
- package/dist-versioned/chunks/chunk.R2XG3O7O.js +1 -1
- package/dist-versioned/chunks/chunk.RGFFEJMJ.js +3 -3
- package/dist-versioned/chunks/chunk.SGJGJL45.js +5 -5
- package/dist-versioned/chunks/chunk.SW6AKO54.js +12 -12
- package/dist-versioned/chunks/chunk.TQMYNSM4.js +1 -1
- package/dist-versioned/chunks/chunk.TWDHTS5K.js +1 -1
- package/dist-versioned/chunks/chunk.TX6S5UVP.js +11 -11
- package/dist-versioned/chunks/chunk.UAADOLK5.js +1 -1
- package/dist-versioned/chunks/chunk.UIQBHPD3.js +2 -2
- package/dist-versioned/chunks/chunk.UJHYOR23.js +5 -5
- package/dist-versioned/chunks/chunk.UJHYUCHT.js +2 -2
- package/dist-versioned/chunks/chunk.UQ55GFI3.js +3 -3
- package/dist-versioned/chunks/chunk.VFG2SXVE.js +8 -8
- package/dist-versioned/chunks/chunk.WEUFN5UU.js +24 -24
- package/dist-versioned/chunks/chunk.WL7EGHGP.js +2 -2
- package/dist-versioned/chunks/chunk.WSEY3LJE.js +4 -4
- package/dist-versioned/chunks/chunk.XKFVXICF.js +3 -3
- package/dist-versioned/chunks/chunk.YGVCQCO4.js +2 -2
- package/dist-versioned/chunks/chunk.YRFRBXRK.js +1 -1
- package/dist-versioned/chunks/chunk.ZCI47J45.js +1 -1
- package/dist-versioned/chunks/chunk.ZF7CPAC2.js +5 -5
- package/dist-versioned/chunks/chunk.ZSZ2IB2L.js +2 -2
- package/dist-versioned/chunks/chunk.ZVLZ6XOK.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/breadcrumb/breadcrumb.d.ts +1 -1
- package/dist-versioned/components/breadcrumb-item/breadcrumb-item.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/menu/menu.d.ts +1 -1
- package/dist-versioned/components/menu-item/menu-item.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 +1 -1
- 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 +1 -1
- 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 +2 -1
- package/dist-versioned/components/switch/switch.js +2 -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/video/video.d.ts +1 -1
- package/dist-versioned/custom-elements.json +233 -229
- package/dist-versioned/internal/form.js +3 -3
- package/dist-versioned/solid-components.css +2 -2
- package/dist-versioned/solid-components.js +4 -4
- package/dist-versioned/vscode.html-custom-data.json +87 -87
- package/dist-versioned/web-types.json +154 -148
- package/package.json +1 -1
- package/cdn/chunks/chunk.ZOFXN52V.js +0 -3
- package/cdn-versioned/chunks/chunk.ZOFXN52V.js +0 -3
|
@@ -74,10 +74,10 @@ var SdRadioGroup = class extends SolidElement {
|
|
|
74
74
|
this.formControlController.updateValidity();
|
|
75
75
|
}
|
|
76
76
|
getAllRadios() {
|
|
77
|
-
return [...this.querySelectorAll("sd-5-
|
|
77
|
+
return [...this.querySelectorAll("sd-5-10-0-radio, sd-5-10-0-radio-button")];
|
|
78
78
|
}
|
|
79
79
|
handleRadioClick(event) {
|
|
80
|
-
const target = event.target.closest("sd-5-
|
|
80
|
+
const target = event.target.closest("sd-5-10-0-radio, sd-5-10-0-radio-button");
|
|
81
81
|
const radios = this.getAllRadios();
|
|
82
82
|
const oldValue = this.value;
|
|
83
83
|
if (target.disabled) {
|
|
@@ -154,7 +154,7 @@ var SdRadioGroup = class extends SolidElement {
|
|
|
154
154
|
}
|
|
155
155
|
})
|
|
156
156
|
);
|
|
157
|
-
this.hasButtonGroup = radios.some((radio) => radio.tagName.toLowerCase() === "sd-5-
|
|
157
|
+
this.hasButtonGroup = radios.some((radio) => radio.tagName.toLowerCase() === "sd-5-10-0-radio-button");
|
|
158
158
|
if (!radios.some((radio) => radio.checked)) {
|
|
159
159
|
if (this.hasButtonGroup) {
|
|
160
160
|
const buttonRadio = (_a = radios[0].shadowRoot) == null ? void 0 : _a.querySelector("button");
|
|
@@ -166,26 +166,26 @@ var SdRadioGroup = class extends SolidElement {
|
|
|
166
166
|
}
|
|
167
167
|
}
|
|
168
168
|
if (this.hasButtonGroup) {
|
|
169
|
-
const buttonGroup = (_b = this.shadowRoot) == null ? void 0 : _b.querySelector("sd-5-
|
|
169
|
+
const buttonGroup = (_b = this.shadowRoot) == null ? void 0 : _b.querySelector("sd-5-10-0-button-group");
|
|
170
170
|
if (buttonGroup) {
|
|
171
171
|
buttonGroup.disableRole = true;
|
|
172
172
|
}
|
|
173
173
|
}
|
|
174
174
|
}
|
|
175
175
|
syncRadios() {
|
|
176
|
-
if (customElements.get("sd-5-
|
|
176
|
+
if (customElements.get("sd-5-10-0-radio") && customElements.get("sd-5-10-0-radio-button")) {
|
|
177
177
|
this.syncRadioElements();
|
|
178
178
|
return;
|
|
179
179
|
}
|
|
180
|
-
if (customElements.get("sd-5-
|
|
180
|
+
if (customElements.get("sd-5-10-0-radio")) {
|
|
181
181
|
this.syncRadioElements();
|
|
182
182
|
} else {
|
|
183
|
-
customElements.whenDefined("sd-5-
|
|
183
|
+
customElements.whenDefined("sd-5-10-0-radio").then(() => this.syncRadios());
|
|
184
184
|
}
|
|
185
|
-
if (customElements.get("sd-5-
|
|
185
|
+
if (customElements.get("sd-5-10-0-radio-button")) {
|
|
186
186
|
this.syncRadioElements();
|
|
187
187
|
} else {
|
|
188
|
-
customElements.whenDefined("sd-5-
|
|
188
|
+
customElements.whenDefined("sd-5-10-0-radio-button").then(() => this.syncRadios());
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
191
|
updateCheckedRadio() {
|
|
@@ -264,7 +264,7 @@ var SdRadioGroup = class extends SolidElement {
|
|
|
264
264
|
vertical: "flex-col",
|
|
265
265
|
horizontal: "flex-row"
|
|
266
266
|
}[this.orientation]
|
|
267
|
-
)}"><div class="sr-only"><label><input id="validation-input" type="text" ?required="${this.required}" aria-labelledby="label" tabindex="-1" hidden @invalid="${this.handleInvalid}"></label></div>${this.hasButtonGroup ? html`<sd-5-
|
|
267
|
+
)}"><div class="sr-only"><label><input id="validation-input" type="text" ?required="${this.required}" aria-labelledby="label" tabindex="-1" hidden @invalid="${this.handleInvalid}"></label></div>${this.hasButtonGroup ? html`<sd-5-10-0-button-group part="button-group" exportparts="base:button-group__base" role="presentation">${defaultSlot}</sd-5-10-0-button-group>` : defaultSlot}</div></fieldset><slot name="help-text" part="form-control-help-text" id="help-text" class="${cx("text-sm text-neutral-700 mt-2", hasHelpText ? "block" : "hidden")}" aria-hidden="${!hasHelpText}">${this.helpText}</slot>${this.formControlController.renderInvalidMessage()}`;
|
|
268
268
|
}
|
|
269
269
|
};
|
|
270
270
|
/**
|
|
@@ -272,7 +272,7 @@ var SdRadioGroup = class extends SolidElement {
|
|
|
272
272
|
*/
|
|
273
273
|
SdRadioGroup.styles = [
|
|
274
274
|
...SolidElement.styles,
|
|
275
|
-
css`:host{display:block}:host([orientation=vertical]) ::slotted(sd-5-
|
|
275
|
+
css`:host{display:block}:host([orientation=vertical]) ::slotted(sd-5-10-0-radio){display:flex;margin-bottom:var(--sd-spacing-2,.5rem)}:host([orientation=vertical]) ::slotted(sd-5-10-0-radio:last-of-type){margin-bottom:var(--sd-spacing-0,0)}:host([orientation=horizontal]) ::slotted(sd-5-10-0-radio){margin-right:var(--sd-spacing-6,1.5rem)}:host([orientation=horizontal]) ::slotted(sd-5-10-0-radio:last-of-type){margin-right:var(--sd-spacing-0,0)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-5-10-0-radio){margin-right:var(--sd-spacing-4,1rem)}:host([orientation=horizontal]):host([size=sm]) ::slotted(sd-5-10-0-radio:last-of-type){margin-right:var(--sd-spacing-0,0)}:host([required]) #label:after{content:" *"}`
|
|
276
276
|
];
|
|
277
277
|
__decorateClass([
|
|
278
278
|
query("slot:not([name])")
|
|
@@ -329,7 +329,7 @@ __decorateClass([
|
|
|
329
329
|
watch("value")
|
|
330
330
|
], SdRadioGroup.prototype, "handleValueChange", 1);
|
|
331
331
|
SdRadioGroup = __decorateClass([
|
|
332
|
-
customElement("sd-5-
|
|
332
|
+
customElement("sd-5-10-0-radio-group")
|
|
333
333
|
], SdRadioGroup);
|
|
334
334
|
|
|
335
335
|
export {
|
|
@@ -208,7 +208,7 @@ __decorateClass([
|
|
|
208
208
|
watch("playbackRate")
|
|
209
209
|
], SdAnimation.prototype, "handlePlaybackRateChange", 1);
|
|
210
210
|
SdAnimation = __decorateClass([
|
|
211
|
-
customElement("sd-5-
|
|
211
|
+
customElement("sd-5-10-0-animation")
|
|
212
212
|
], SdAnimation);
|
|
213
213
|
|
|
214
214
|
export {
|
|
@@ -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-
|
|
28
|
+
customElement("sd-5-10-0-carousel-item")
|
|
29
29
|
], SdCarouselItem);
|
|
30
30
|
|
|
31
31
|
export {
|
|
@@ -17,19 +17,19 @@ var SdButtonGroup = class extends SolidElement {
|
|
|
17
17
|
}
|
|
18
18
|
handleFocus(event) {
|
|
19
19
|
const button = findButton(event.target);
|
|
20
|
-
button == null ? void 0 : button.classList.add("sd-5-
|
|
20
|
+
button == null ? void 0 : button.classList.add("sd-5-10-0-button-group__button--focus");
|
|
21
21
|
}
|
|
22
22
|
handleBlur(event) {
|
|
23
23
|
const button = findButton(event.target);
|
|
24
|
-
button == null ? void 0 : button.classList.remove("sd-5-
|
|
24
|
+
button == null ? void 0 : button.classList.remove("sd-5-10-0-button-group__button--focus");
|
|
25
25
|
}
|
|
26
26
|
handleMouseOver(event) {
|
|
27
27
|
const button = findButton(event.target);
|
|
28
|
-
button == null ? void 0 : button.classList.add("sd-5-
|
|
28
|
+
button == null ? void 0 : button.classList.add("sd-5-10-0-button-group__button--hover");
|
|
29
29
|
}
|
|
30
30
|
handleMouseOut(event) {
|
|
31
31
|
const button = findButton(event.target);
|
|
32
|
-
button == null ? void 0 : button.classList.remove("sd-5-
|
|
32
|
+
button == null ? void 0 : button.classList.remove("sd-5-10-0-button-group__button--hover");
|
|
33
33
|
}
|
|
34
34
|
handleSlotChange() {
|
|
35
35
|
const slottedElements = [...this.defaultSlot.assignedElements({ flatten: true })];
|
|
@@ -37,11 +37,11 @@ var SdButtonGroup = class extends SolidElement {
|
|
|
37
37
|
const index = slottedElements.indexOf(el);
|
|
38
38
|
const button = findButton(el);
|
|
39
39
|
if (button !== null) {
|
|
40
|
-
button.classList.add("sd-5-
|
|
41
|
-
button.classList.toggle("sd-5-
|
|
42
|
-
button.classList.toggle("sd-5-
|
|
43
|
-
button.classList.toggle("sd-5-
|
|
44
|
-
button.classList.toggle("sd-5-
|
|
40
|
+
button.classList.add("sd-5-10-0-button-group__button");
|
|
41
|
+
button.classList.toggle("sd-5-10-0-button-group__button--first", index === 0);
|
|
42
|
+
button.classList.toggle("sd-5-10-0-button-group__button--inner", index > 0 && index < slottedElements.length - 1);
|
|
43
|
+
button.classList.toggle("sd-5-10-0-button-group__button--last", index === slottedElements.length - 1);
|
|
44
|
+
button.classList.toggle("sd-5-10-0-button-group__button--radio", button.tagName.toLowerCase() === "sd-5-10-0-radio-button");
|
|
45
45
|
}
|
|
46
46
|
});
|
|
47
47
|
}
|
|
@@ -63,11 +63,11 @@ __decorateClass([
|
|
|
63
63
|
property({ type: String, reflect: true })
|
|
64
64
|
], SdButtonGroup.prototype, "label", 2);
|
|
65
65
|
SdButtonGroup = __decorateClass([
|
|
66
|
-
customElement("sd-5-
|
|
66
|
+
customElement("sd-5-10-0-button-group")
|
|
67
67
|
], SdButtonGroup);
|
|
68
68
|
function findButton(el) {
|
|
69
69
|
var _a;
|
|
70
|
-
const selector = "sd-5-
|
|
70
|
+
const selector = "sd-5-10-0-button, sd-5-10-0-radio-button";
|
|
71
71
|
return (_a = el.closest(selector)) != null ? _a : el.querySelector(selector);
|
|
72
72
|
}
|
|
73
73
|
|
|
@@ -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-
|
|
326
|
+
customElement("sd-5-10-0-popup")
|
|
327
327
|
], SdPopup);
|
|
328
328
|
|
|
329
329
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/components/combobox/utils.ts
|
|
2
2
|
var getAssignedElementsForSlot = (slot) => Array.from(slot.assignedElements({ flatten: true }));
|
|
3
|
-
var getOptionOrNestedOptions = (item) => item.tagName.toLocaleLowerCase() === "sd-5-
|
|
4
|
-
var isOptgroup = (item) => item.tagName.toLocaleLowerCase() === "sd-5-
|
|
3
|
+
var getOptionOrNestedOptions = (item) => item.tagName.toLocaleLowerCase() === "sd-5-10-0-option" ? item : Array.from(item.querySelectorAll(":scope > sd-5-10-0-option"));
|
|
4
|
+
var isOptgroup = (item) => item.tagName.toLocaleLowerCase() === "sd-5-10-0-optgroup";
|
|
5
5
|
var getAllOptions = (items) => items.map(getOptionOrNestedOptions);
|
|
6
6
|
var filterOnlyOptgroups = (items) => items.filter(isOptgroup);
|
|
7
7
|
var normalizeString = (str) => str.normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase();
|
|
@@ -117,16 +117,16 @@ var SdNavigationItem = class extends SolidElement {
|
|
|
117
117
|
slots["description"] && "pt-3",
|
|
118
118
|
slots["description"] || this.separated ? "pb-1" : horizontalPadding,
|
|
119
119
|
this.calculatePaddingX
|
|
120
|
-
)}">${this.divider && this.vertical ? html`<sd-5-
|
|
120
|
+
)}">${this.divider && this.vertical ? html`<sd-5-10-0-divider part="divider" class="${cx("w-full transition-all absolute -top-0.25 left-0", this.calculatePaddingX)}"></sd-5-10-0-divider>` : ""} <span part="content-container" class="inline-flex items-center flex-auto">${this.separated ? html`<a class="${cx(
|
|
121
121
|
"mr-4 w-full inline-flex items-center pl-4 cursor-pointer relative focus-visible:focus-outline hover:bg-neutral-200 group transition-colors duration-fast ease-in-out min-h-[48px]",
|
|
122
122
|
!slots["description"] && "py-4"
|
|
123
|
-
)}" href="${ifDefined(isLink ? this.href : void 0)}" target="${ifDefined(isLink ? this.target : void 0)}" download="${ifDefined(isLink ? this.download : void 0)}"><slot part="content" class="inline-flex"></slot></a>` : html`<slot part="content" class="inline-flex"></slot>`} </span>${(this.chevron || slots["children"]) && this.vertical ? this.separated ? html`<button type="button" title="${this.open ? this.localize.term("collapseNavigationItem") : this.localize.term("expandNavigationItem")}" class="sd-interactive sd-interactive--reset" @click="${this.handleClickSummary}"><sd-5-
|
|
123
|
+
)}" href="${ifDefined(isLink ? this.href : void 0)}" target="${ifDefined(isLink ? this.target : void 0)}" download="${ifDefined(isLink ? this.download : void 0)}"><slot part="content" class="inline-flex"></slot></a>` : html`<slot part="content" class="inline-flex"></slot>`} </span>${(this.chevron || slots["children"]) && this.vertical ? this.separated ? html`<button type="button" title="${this.open ? this.localize.term("collapseNavigationItem") : this.localize.term("expandNavigationItem")}" class="sd-interactive sd-interactive--reset" @click="${this.handleClickSummary}"><sd-5-10-0-icon name="chevron-down" part="chevron" library="_internal" color="currentColor" class="${cx(
|
|
124
124
|
"m-4 h-6 w-6 transition-all",
|
|
125
125
|
isAccordion || this.separated ? this.open ? "rotate-180" : "rotate-0" : "rotate-[270deg]"
|
|
126
|
-
)}"></sd-5-
|
|
126
|
+
)}"></sd-5-10-0-icon></button>` : html`<sd-5-10-0-icon name="chevron-down" part="chevron" library="_internal" color="currentColor" class="${cx(
|
|
127
127
|
"h-6 w-6 ml-2 transition-all",
|
|
128
128
|
isAccordion ? this.open ? "rotate-180" : "rotate-0" : "rotate-[270deg]"
|
|
129
|
-
)}"></sd-5-
|
|
129
|
+
)}"></sd-5-10-0-icon>` : ""} </span>${slots["description"] && this.vertical ? html`<slot name="description" part="description" class="${cx(
|
|
130
130
|
"inline-block text-sm text-left text-black pb-3",
|
|
131
131
|
isAccordion || this.separated ? "grow" : "w-full",
|
|
132
132
|
this.separated ? "px-4" : this.calculatePaddingX
|
|
@@ -190,7 +190,7 @@ __decorateClass([
|
|
|
190
190
|
property({ type: Boolean, reflect: true })
|
|
191
191
|
], SdNavigationItem.prototype, "separated", 2);
|
|
192
192
|
SdNavigationItem = __decorateClass([
|
|
193
|
-
customElement("sd-5-
|
|
193
|
+
customElement("sd-5-10-0-navigation-item")
|
|
194
194
|
], SdNavigationItem);
|
|
195
195
|
|
|
196
196
|
export {
|
|
@@ -176,7 +176,7 @@ var SdDialog = class extends SolidElement {
|
|
|
176
176
|
)}"><div part="overlay" class="fixed inset-0 bg-primary-800 opacity-90" @click="${() => this.requestClose("overlay")}" tabindex="-1"></div><div part="panel" class="${cx(
|
|
177
177
|
"flex flex-col z-20 bg-white py-4 sm:py-8 relative gap-6 focus-visible:focus-outline-inverted overflow-y-auto",
|
|
178
178
|
this.open && "flex opacity-100"
|
|
179
|
-
)}" role="dialog" aria-modal="true" aria-hidden="${this.open ? "false" : "true"}" aria-label="${ifDefined(this.headline ? this.headline : void 0)}" aria-labelledby="${ifDefined(!this.headline ? "title" : void 0)}" tabindex="0"><header part="header" class="flex flex-grow-0 flex-shrink-0 basis-auto px-6 sm:px-10"><h2 part="title" class="flex-auto m-0" id="title">${this.headline.length > 0 ? html`<span class="sd-headline sd-headline--size-3xl leading-tight">${this.headline}</span>` : html`<slot name="headline"></slot>`}</h2>${!this.noCloseButton ? html`<sd-5-
|
|
179
|
+
)}" role="dialog" aria-modal="true" aria-hidden="${this.open ? "false" : "true"}" aria-label="${ifDefined(this.headline ? this.headline : void 0)}" aria-labelledby="${ifDefined(!this.headline ? "title" : void 0)}" tabindex="0"><header part="header" class="flex flex-grow-0 flex-shrink-0 basis-auto px-6 sm:px-10"><h2 part="title" class="flex-auto m-0" id="title">${this.headline.length > 0 ? html`<span class="sd-headline sd-headline--size-3xl leading-tight">${this.headline}</span>` : html`<slot name="headline"></slot>`}</h2>${!this.noCloseButton ? html`<sd-5-10-0-button part="close-button" variant="tertiary" exportparts="base:close-button__base" class="${cx("absolute top-2 right-2")}" name="x-lg" @click="${() => this.requestClose("close-button")}" type="button"><sd-5-10-0-icon label="${this.localize.term("close")}" name="close" library="_internal" color="currentColor"></sd-5-10-0-icon></sd-5-10-0-button>` : ""}</header><main part="body" class="flex flex-auto overflow-auto w-full px-6 sm:px-10"><slot></slot></main><footer part="footer" class="flex flex-grow-0 flex-shrink-0 basis-auto ml-auto gap-4 px-6 sm:px-10"><slot name="footer"></slot></footer></div></div>`;
|
|
180
180
|
}
|
|
181
181
|
};
|
|
182
182
|
SdDialog.styles = [
|
|
@@ -205,7 +205,7 @@ __decorateClass([
|
|
|
205
205
|
watch("open", { waitUntilFirstUpdate: true })
|
|
206
206
|
], SdDialog.prototype, "handleOpenChange", 1);
|
|
207
207
|
SdDialog = __decorateClass([
|
|
208
|
-
customElement("sd-5-
|
|
208
|
+
customElement("sd-5-10-0-dialog")
|
|
209
209
|
], SdDialog);
|
|
210
210
|
setDefaultAnimation("dialog.show", {
|
|
211
211
|
keyframes: [
|
|
@@ -385,7 +385,7 @@ var SdInput = class extends SolidElement {
|
|
|
385
385
|
this.size === "sm" ? "h-6" : "h-8",
|
|
386
386
|
textSize
|
|
387
387
|
)}" type="${this.type === "password" && this.passwordVisible ? "text" : this.type}" title="${this.title}" name="${ifDefined(this.name)}" ?disabled="${this.disabled}" ?readonly="${this.readonly}" ?required="${this.required}" placeholder="${ifDefined(this.placeholder)}" minlength="${ifDefined(this.minlength)}" maxlength="${ifDefined(this.maxlength)}" min="${ifDefined(this.min)}" max="${ifDefined(this.max)}" step="${ifDefined(this.step)}" .value="${live(this.value)}" autocapitalize="${ifDefined(this.type === "password" ? "off" : this.autocapitalize)}" autocomplete="${// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
388
|
-
ifDefined(this.autocomplete)}" autocorrect="${ifDefined(this.type === "password" ? "off" : this.autocorrect)}" ?autofocus="${this.autofocus}" spellcheck="${this.spellcheck}" pattern="${ifDefined(this.pattern)}" enterkeyhint="${ifDefined(this.enterkeyhint)}" inputmode="${ifDefined(this.inputmode)}" aria-describedby="help-text invalid-message" aria-disabled="${this.visuallyDisabled || this.disabled ? "true" : "false"}" aria-invalid="${this.showInvalidStyle}" @change="${this.handleChange}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @keydown="${this.handleKeyDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"> ${hasClearIcon ? html`<button part="clear-button" class="${cx("flex justify-center", iconMarginLeft)}" type="button" aria-label="${this.localize.term("clearEntry")}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-5-
|
|
388
|
+
ifDefined(this.autocomplete)}" autocorrect="${ifDefined(this.type === "password" ? "off" : this.autocorrect)}" ?autofocus="${this.autofocus}" spellcheck="${this.spellcheck}" pattern="${ifDefined(this.pattern)}" enterkeyhint="${ifDefined(this.enterkeyhint)}" inputmode="${ifDefined(this.inputmode)}" aria-describedby="help-text invalid-message" aria-disabled="${this.visuallyDisabled || this.disabled ? "true" : "false"}" aria-invalid="${this.showInvalidStyle}" @change="${this.handleChange}" @input="${this.handleInput}" @invalid="${this.handleInvalid}" @keydown="${this.handleKeyDown}" @focus="${this.handleFocus}" @blur="${this.handleBlur}"> ${hasClearIcon ? html`<button part="clear-button" class="${cx("flex justify-center", iconMarginLeft)}" type="button" aria-label="${this.localize.term("clearEntry")}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-5-10-0-icon class="${cx("text-neutral-700", iconSize)}" library="_internal" name="closing-round"></sd-5-10-0-icon></slot></button>` : ""} ${this.passwordToggle && this.type === "password" ? html`<button aria-label="${this.localize.term(this.passwordVisible ? "hidePassword" : "showPassword")}" part="password-toggle-button" class="${cx("flex items-center sd-interactive", iconMarginLeft)}" type="button" @click="${this.handlePasswordToggle}">${this.passwordVisible ? html`<slot name="show-password-icon"><sd-5-10-0-icon class="${cx(iconColor, iconSize)}" library="_internal" name="eye"></sd-5-10-0-icon></slot>` : html`<slot name="hide-password-icon"><sd-5-10-0-icon class="${cx(iconColor, iconSize)}" library="_internal" name="eye-crossed-out"></sd-5-10-0-icon></slot>`}</button>` : ""} ${(this.type === "date" || this.type === "datetime-local") && !isFirefox ? html`<sd-5-10-0-icon class="${cx(iconColor, iconMarginLeft, iconSize)}" library="_internal" name="calendar"></sd-5-10-0-icon>` : ""} ${this.type === "time" ? html`<sd-5-10-0-icon class="${cx(iconColor, iconMarginLeft, iconSize)}" library="_internal" name="clock"></sd-5-10-0-icon>` : ""} ${this.type === "search" ? html`<button class="${cx("flex items-center sd-interactive", iconMarginLeft)}" type="button" @click="${this.handleSearchClick}"><sd-5-10-0-icon class="${cx(iconColor, iconSize)}" library="_internal" name="magnifying-glass" label="${this.localize.term("search")}"></sd-5-10-0-icon></button>` : ""} ${this.showInvalidStyle ? html`<sd-5-10-0-icon part="invalid-icon" class="${cx("text-error", iconMarginLeft, iconSize)}" library="_internal" name="risk"></sd-5-10-0-icon>` : ""} ${this.showValidStyle && this.styleOnValid ? html`<sd-5-10-0-icon class="${cx("text-success flex-shrink-0", iconMarginLeft, iconSize)}" library="_internal" name="status-check" part="valid-icon"></sd-5-10-0-icon>` : ""} ${slots["right"] ? html`<slot name="right" part="right" class="${cx("inline-flex", iconColor, iconMarginLeft, iconSize)}"></slot>` : ""} ${this.type === "number" && this.spinButtons ? html`<div part="stepper" class="flex items-center"><button part="decrement-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isDecrementDisabled()}" aria-hidden="true" ${longPress({ start: () => this.handleStepDown(), end: () => this.handleChange() })} tabindex="-1"><slot name="decrement-number-stepper"><sd-5-10-0-icon name="system/minus-circle" label="Decrease value" class="${cx(iconColor, iconMarginLeft, iconSize)}"></sd-5-10-0-icon></slot></button> <button part="increment-number-stepper" class="stepper-button flex" type="button" ?disabled="${this.isIncrementDisabled()}" aria-hidden="true" ${longPress({ start: () => this.handleStepUp(), end: () => this.handleChange() })} tabindex="-1"><slot name="increment-number-stepper"><sd-5-10-0-icon name="system/plus-circle" label="Decrease value" class="${cx(iconColor, iconMarginLeft, iconSize)}"></sd-5-10-0-icon></slot></button></div>` : ""}</div></div><slot name="help-text" part="form-control-help-text" id="help-text" class="${cx("text-sm text-neutral-700 mt-2", hasHelpText ? "block" : "hidden")}" aria-hidden="${!hasHelpText}">${this.helpText}</slot></div>${this.formControlController.renderInvalidMessage()}`;
|
|
389
389
|
}
|
|
390
390
|
};
|
|
391
391
|
/**
|
|
@@ -393,7 +393,7 @@ var SdInput = class extends SolidElement {
|
|
|
393
393
|
*/
|
|
394
394
|
SdInput.styles = [
|
|
395
395
|
...SolidElement.styles,
|
|
396
|
-
css`:host{box-sizing:border-box;display:inline-block;position:relative;text-align:left;width:100%}:host([vertical]){display:block}:host([required]) #label:after{content:" *"}:host([visually-disabled]) input{caret-color:transparent}details summary::-webkit-details-marker{display:none}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=time]::-webkit-calendar-picker-indicator{background:0 0}details summary::-webkit-details-marker,input[type=date]::-webkit-calendar-picker-indicator,input[type=datetime-local]::-webkit-calendar-picker-indicator,input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration,input[type=search]::-webkit-search-results-button,input[type=search]::-webkit-search-results-decoration{display:none}.stepper-button[disabled] sd-5-
|
|
396
|
+
css`:host{box-sizing:border-box;display:inline-block;position:relative;text-align:left;width:100%}:host([vertical]){display:block}:host([required]) #label:after{content:" *"}:host([visually-disabled]) input{caret-color:transparent}details summary::-webkit-details-marker{display:none}input::-webkit-inner-spin-button,input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=time]::-webkit-calendar-picker-indicator{background:0 0}details summary::-webkit-details-marker,input[type=date]::-webkit-calendar-picker-indicator,input[type=datetime-local]::-webkit-calendar-picker-indicator,input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration,input[type=search]::-webkit-search-results-button,input[type=search]::-webkit-search-results-decoration{display:none}.stepper-button[disabled] sd-5-10-0-icon{--tw-text-opacity:1;color:rgb(var(--sd-color-neutral-500,174 174 174)/var(--tw-text-opacity,1))}`
|
|
397
397
|
];
|
|
398
398
|
__decorateClass([
|
|
399
399
|
query("#input")
|
|
@@ -523,7 +523,7 @@ __decorateClass([
|
|
|
523
523
|
watch("value", { waitUntilFirstUpdate: true })
|
|
524
524
|
], SdInput.prototype, "handleValueChange", 1);
|
|
525
525
|
SdInput = __decorateClass([
|
|
526
|
-
customElement("sd-5-
|
|
526
|
+
customElement("sd-5-10-0-input")
|
|
527
527
|
], SdInput);
|
|
528
528
|
|
|
529
529
|
export {
|
|
@@ -129,7 +129,7 @@ var SdScrollable = class extends SolidElement {
|
|
|
129
129
|
down: this.upButton
|
|
130
130
|
}[direction];
|
|
131
131
|
const label = reachedStart ? `${this.localize.term("scrolled")}. ${this.localize.term("scrollToEnd")}` : `${this.localize.term("scrolled")}. ${this.localize.term("scrollToStart")}`;
|
|
132
|
-
(_c = oppositeButton == null ? void 0 : oppositeButton.querySelector("sd-5-
|
|
132
|
+
(_c = oppositeButton == null ? void 0 : oppositeButton.querySelector("sd-5-10-0-icon")) == null ? void 0 : _c.setAttribute("label", label);
|
|
133
133
|
if (isKeyboardTriggered) {
|
|
134
134
|
oppositeButton == null ? void 0 : oppositeButton.focus();
|
|
135
135
|
} else {
|
|
@@ -141,7 +141,7 @@ var SdScrollable = class extends SolidElement {
|
|
|
141
141
|
const scrollTo = ["left", "up"].includes(direction) ? "start" : "end";
|
|
142
142
|
const label = scrollTo === "start" ? this.localize.term("scrollToStart") : this.localize.term("scrollToEnd");
|
|
143
143
|
const button = e.target;
|
|
144
|
-
(_a = button.querySelector("sd-5-
|
|
144
|
+
(_a = button.querySelector("sd-5-10-0-icon")) == null ? void 0 : _a.setAttribute("label", label);
|
|
145
145
|
}
|
|
146
146
|
render() {
|
|
147
147
|
const scrollButtonClasses = "relative p-0 border-0 bg-transparent cursor-pointer w-5 h-5 flex items-center justify-center sd-interactive rounded-md flex text-lg";
|
|
@@ -158,16 +158,16 @@ var SdScrollable = class extends SolidElement {
|
|
|
158
158
|
)}" @scroll="${this.handleContainerScroll}" tabindex="0"><div id="announcement-container" role="status" class="sr-only"></div><div part="scroll-content" class="flex-1"><slot></slot></div></div>${this.buttons ? html`${this.isScrollHorizontalEnabled ? html`<div part="button-left" class="${cx(
|
|
159
159
|
"absolute z-10 flex items-center justify-center top-0 left-0 h-full w-8 transition-opacity duration-medium ease-in-out",
|
|
160
160
|
!this.canScroll.left && "opacity-0 pointer-events-none"
|
|
161
|
-
)}"><button part="button-start" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.left || void 0)}" tabindex="${ifDefined(!this.canScroll.left ? -1 : void 0)}" @click="${(e) => this.handleScroll("left", e)}" @blur="${(e) => this.handleButtonBlur("left", e)}"><slot name="icon-start"><sd-5-
|
|
161
|
+
)}"><button part="button-start" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.left || void 0)}" tabindex="${ifDefined(!this.canScroll.left ? -1 : void 0)}" @click="${(e) => this.handleScroll("left", e)}" @blur="${(e) => this.handleButtonBlur("left", e)}"><slot name="icon-start"><sd-5-10-0-icon library="_internal" name="chevron-up" class="rotate-[-90deg]" label="${this.localize.term("scrollToStart")}"></sd-5-10-0-icon></slot></button></div><div part="button-right" class="${cx(
|
|
162
162
|
"absolute z-10 flex items-center justify-center top-0 right-0 h-full w-8 transition-opacity duration-medium ease-in-out",
|
|
163
163
|
!this.canScroll.right && "opacity-0 pointer-events-none"
|
|
164
|
-
)}"><button part="button-end" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.right || void 0)}" tabindex="${ifDefined(!this.canScroll.right ? -1 : void 0)}" @click="${(e) => this.handleScroll("right", e)}" @blur="${(e) => this.handleButtonBlur("right", e)}"><slot name="icon-end"><sd-5-
|
|
164
|
+
)}"><button part="button-end" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.right || void 0)}" tabindex="${ifDefined(!this.canScroll.right ? -1 : void 0)}" @click="${(e) => this.handleScroll("right", e)}" @blur="${(e) => this.handleButtonBlur("right", e)}"><slot name="icon-end"><sd-5-10-0-icon library="_internal" name="chevron-down" class="rotate-[-90deg]" label="${this.localize.term("scrollToEnd")}"></sd-5-10-0-icon></slot></button></div>` : null} ${this.isScrollVerticalEnabled ? html`<div part="button-top" class="${cx(
|
|
165
165
|
"absolute z-10 flex items-center justify-center top-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",
|
|
166
166
|
!this.canScroll.up && "opacity-0 pointer-events-none"
|
|
167
|
-
)}"><button part="button-start" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.up || void 0)}" tabindex="${ifDefined(!this.canScroll.up ? -1 : void 0)}" @click="${(e) => this.handleScroll("up", e)}" @blur="${(e) => this.handleButtonBlur("up", e)}"><slot name="icon-start"><sd-5-
|
|
167
|
+
)}"><button part="button-start" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.up || void 0)}" tabindex="${ifDefined(!this.canScroll.up ? -1 : void 0)}" @click="${(e) => this.handleScroll("up", e)}" @blur="${(e) => this.handleButtonBlur("up", e)}"><slot name="icon-start"><sd-5-10-0-icon library="_internal" name="chevron-up" label="${this.localize.term("scrollToStart")}"></sd-5-10-0-icon></slot></button></div><div part="button-bottom" class="${cx(
|
|
168
168
|
"absolute z-10 flex items-center justify-center bottom-0 left-0 w-full h-8 transition-opacity duration-medium ease-in-out",
|
|
169
169
|
!this.canScroll.down && "opacity-0 pointer-events-none"
|
|
170
|
-
)}"><button part="button-end" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.down || void 0)}" tabindex="${ifDefined(!this.canScroll.down ? -1 : void 0)}" @click="${(e) => this.handleScroll("down", e)}" @blur="${(e) => this.handleButtonBlur("down", e)}"><slot name="icon-end"><sd-5-
|
|
170
|
+
)}"><button part="button-end" class="${cx(scrollButtonClasses)}" aria-hidden="${ifDefined(!this.canScroll.down || void 0)}" tabindex="${ifDefined(!this.canScroll.down ? -1 : void 0)}" @click="${(e) => this.handleScroll("down", e)}" @blur="${(e) => this.handleButtonBlur("down", e)}"><slot name="icon-end"><sd-5-10-0-icon library="_internal" name="chevron-down" label="${this.localize.term("scrollToEnd")}"></sd-5-10-0-icon></slot></button></div>` : null}` : null} ${this.shadows ? html`${this.isScrollHorizontalEnabled ? html`<div part="shadow-left" class="${cx(
|
|
171
171
|
"left top-0 left-0 w-[6px] h-full",
|
|
172
172
|
scrollShadowClasses,
|
|
173
173
|
this.canScroll.left ? "opacity-100" : "opacity-0"
|
|
@@ -188,7 +188,7 @@ var SdScrollable = class extends SolidElement {
|
|
|
188
188
|
};
|
|
189
189
|
SdScrollable.styles = [
|
|
190
190
|
...SolidElement.styles,
|
|
191
|
-
css`:host{--gradient-color:hsla(0,0%,100%,0);--gradient:var(--gradient-color) 0%,#fff 80%,#fff 100%;display:flex;overflow:hidden;position:relative}.hide-scrollbars{scrollbar-width:none;-ms-overflow-style:none}.hide-scrollbars::-webkit-scrollbar{display:none}.scroll-container::-webkit-scrollbar-thumb{background-color:transparent}.scroll-container:hover::-webkit-scrollbar-thumb{background:var(--background-neutral-400,#c3c3c3);border-radius:var(--sd-border-radius-sm,.125rem)}.scroll-container::-webkit-scrollbar{height:var(--sd-spacing-1,.25rem);width:var(--sd-spacing-1,.25rem)}.scroll-auto{overflow:auto}[part=button-left]{background:linear-gradient(270deg,var(--gradient))}[part=button-right]{background:linear-gradient(90deg,var(--gradient))}[part=button-top]{background:linear-gradient(0deg,var(--gradient))}[part=button-bottom]{background:linear-gradient(180deg,var(--gradient))}[part=shadow-left]{background:linear-gradient(270deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-right]{background:linear-gradient(90deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-top]{background:linear-gradient(0deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-bottom]{background:linear-gradient(180deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}.sd-5-
|
|
191
|
+
css`:host{--gradient-color:hsla(0,0%,100%,0);--gradient:var(--gradient-color) 0%,#fff 80%,#fff 100%;display:flex;overflow:hidden;position:relative}.hide-scrollbars{scrollbar-width:none;-ms-overflow-style:none}.hide-scrollbars::-webkit-scrollbar{display:none}.scroll-container::-webkit-scrollbar-thumb{background-color:transparent}.scroll-container:hover::-webkit-scrollbar-thumb{background:var(--background-neutral-400,#c3c3c3);border-radius:var(--sd-border-radius-sm,.125rem)}.scroll-container::-webkit-scrollbar{height:var(--sd-spacing-1,.25rem);width:var(--sd-spacing-1,.25rem)}.scroll-auto{overflow:auto}[part=button-left]{background:linear-gradient(270deg,var(--gradient))}[part=button-right]{background:linear-gradient(90deg,var(--gradient))}[part=button-top]{background:linear-gradient(0deg,var(--gradient))}[part=button-bottom]{background:linear-gradient(180deg,var(--gradient))}[part=shadow-left]{background:linear-gradient(270deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-right]{background:linear-gradient(90deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-top]{background:linear-gradient(0deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}[part=shadow-bottom]{background:linear-gradient(180deg,hsla(0,0%,9%,0) 50%,hsla(0,0%,9%,.4))}.sd-5-10-0-icon--top{align-self:flex-start}.sd-5-10-0-icon--down{align-self:flex-end}`
|
|
192
192
|
];
|
|
193
193
|
__decorateClass([
|
|
194
194
|
query('[part="button-right"] button')
|
|
@@ -236,7 +236,7 @@ __decorateClass([
|
|
|
236
236
|
state()
|
|
237
237
|
], SdScrollable.prototype, "isScrollVerticalEnabled", 2);
|
|
238
238
|
SdScrollable = __decorateClass([
|
|
239
|
-
customElement("sd-5-
|
|
239
|
+
customElement("sd-5-10-0-scrollable")
|
|
240
240
|
], SdScrollable);
|
|
241
241
|
|
|
242
242
|
export {
|
|
@@ -54,7 +54,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
54
54
|
constructor() {
|
|
55
55
|
super(...arguments);
|
|
56
56
|
this.formControlController = new FormControlController(this, {
|
|
57
|
-
assumeInteractionOn: ["sd-blur", "sd-5-
|
|
57
|
+
assumeInteractionOn: ["sd-blur", "sd-5-10-0-input"]
|
|
58
58
|
});
|
|
59
59
|
this.hasSlotController = new HasSlotController(this, "help-text", "label");
|
|
60
60
|
this.localize = new LocalizeController(this);
|
|
@@ -97,11 +97,11 @@ var SdCombobox = class extends SolidElement {
|
|
|
97
97
|
return normalizedOption.includes(normalizedQuery) || normalizedOptionLabel.includes(normalizedQuery);
|
|
98
98
|
};
|
|
99
99
|
this.getTag = (option) => {
|
|
100
|
-
return html`<sd-5-
|
|
100
|
+
return html`<sd-5-10-0-tag ?disabled="${this.disabled}" part="tag" exportparts="
|
|
101
101
|
base:tag__base,
|
|
102
102
|
content:tag__content,
|
|
103
103
|
removable-indicator:tag__removable-indicator,
|
|
104
|
-
" size="${this.size === "sm" ? "sm" : "lg"}" removable @keydown="${(event) => this.handleTagKeyDown(event, option)}" @sd-remove="${(event) => this.handleTagRemove(event, option)}">${option.getTextLabel()}</sd-5-
|
|
104
|
+
" size="${this.size === "sm" ? "sm" : "lg"}" removable @keydown="${(event) => this.handleTagKeyDown(event, option)}" @sd-remove="${(event) => this.handleTagRemove(event, option)}">${option.getTextLabel()}</sd-5-10-0-tag>`;
|
|
105
105
|
};
|
|
106
106
|
this.handleDocumentFocusIn = (event) => {
|
|
107
107
|
const path = event.composedPath();
|
|
@@ -236,9 +236,9 @@ var SdCombobox = class extends SolidElement {
|
|
|
236
236
|
return html`${typeof optionHtml === "string" ? unsafeHTML(optionHtml) : optionHtml}`;
|
|
237
237
|
};
|
|
238
238
|
return this.filteredOptions.map((item) => {
|
|
239
|
-
if (item.tagName.toLowerCase() === "sd-5-
|
|
239
|
+
if (item.tagName.toLowerCase() === "sd-5-10-0-optgroup") {
|
|
240
240
|
Array.from(item.children).forEach((option) => {
|
|
241
|
-
if (option.tagName.toLowerCase() === "sd-5-
|
|
241
|
+
if (option.tagName.toLowerCase() === "sd-5-10-0-option") {
|
|
242
242
|
renderOption(option);
|
|
243
243
|
}
|
|
244
244
|
});
|
|
@@ -258,11 +258,11 @@ var SdCombobox = class extends SolidElement {
|
|
|
258
258
|
});
|
|
259
259
|
} else {
|
|
260
260
|
return [
|
|
261
|
-
html`<sd-5-
|
|
261
|
+
html`<sd-5-10-0-tag ?disabled="${this.disabled}" part="tag" exportparts="
|
|
262
262
|
base:tag__base,
|
|
263
263
|
content:tag__content,
|
|
264
264
|
removable-indicator:tag__removable-indicator,
|
|
265
|
-
" size="${this.size === "sm" ? "sm" : "lg"}" removable @keydown="${(event) => this.handleTagMaxOptionsKeyDown(event)}" @sd-remove="${(event) => this.handleTagRemove(event)}">${this.selectedOptions.length} ${this.localize.term("tagsSelected")}</sd-5-
|
|
265
|
+
" size="${this.size === "sm" ? "sm" : "lg"}" removable @keydown="${(event) => this.handleTagMaxOptionsKeyDown(event)}" @sd-remove="${(event) => this.handleTagRemove(event)}">${this.selectedOptions.length} ${this.localize.term("tagsSelected")}</sd-5-10-0-tag>`
|
|
266
266
|
];
|
|
267
267
|
}
|
|
268
268
|
}
|
|
@@ -381,7 +381,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
381
381
|
}
|
|
382
382
|
handleOptionClick(event) {
|
|
383
383
|
const target = event.target;
|
|
384
|
-
const option = target.closest("sd-5-
|
|
384
|
+
const option = target.closest("sd-5-10-0-option");
|
|
385
385
|
const oldValue = this.value;
|
|
386
386
|
if (option && !option.disabled) {
|
|
387
387
|
if (this.multiple) {
|
|
@@ -433,7 +433,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
433
433
|
scrollIntoView(this.getCurrentOption(), this.listbox, "vertical", "auto");
|
|
434
434
|
}
|
|
435
435
|
getAllFilteredOptions() {
|
|
436
|
-
return [...this.filteredWrapper.querySelectorAll("sd-5-
|
|
436
|
+
return [...this.filteredWrapper.querySelectorAll("sd-5-10-0-option")];
|
|
437
437
|
}
|
|
438
438
|
getCurrentOption() {
|
|
439
439
|
return this.getAllFilteredOptions().find((option) => option.current);
|
|
@@ -563,7 +563,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
563
563
|
clonedOption.selected = option.selected;
|
|
564
564
|
clonedOption.checkbox = option.checkbox;
|
|
565
565
|
clonedOption.size = option.size;
|
|
566
|
-
const hasOptgroup = ((_b = option.parentElement) == null ? void 0 : _b.tagName.toLowerCase()) === "sd-5-
|
|
566
|
+
const hasOptgroup = ((_b = option.parentElement) == null ? void 0 : _b.tagName.toLowerCase()) === "sd-5-10-0-optgroup";
|
|
567
567
|
if (!hasOptgroup) {
|
|
568
568
|
return clonedOption;
|
|
569
569
|
}
|
|
@@ -587,7 +587,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
587
587
|
this.formControlController.emitInvalidEvent(event);
|
|
588
588
|
this.invalidMessage.textContent = event.target.validationMessage;
|
|
589
589
|
}
|
|
590
|
-
/** Receives incoming event detail from sd-5-
|
|
590
|
+
/** Receives incoming event detail from sd-5-10-0-popup and updates local state for conditional styling. */
|
|
591
591
|
handleCurrentPlacement(e) {
|
|
592
592
|
const incomingPlacement = e.detail;
|
|
593
593
|
if (incomingPlacement) {
|
|
@@ -599,7 +599,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
599
599
|
}
|
|
600
600
|
handleUseTagsChange() {
|
|
601
601
|
const allOptions = this.getAllFilteredOptions();
|
|
602
|
-
if (customElements.get("sd-5-
|
|
602
|
+
if (customElements.get("sd-5-10-0-option")) {
|
|
603
603
|
allOptions.forEach((option) => {
|
|
604
604
|
option.checkbox = this.multiple;
|
|
605
605
|
});
|
|
@@ -725,8 +725,8 @@ var SdCombobox = class extends SolidElement {
|
|
|
725
725
|
return filterOnlyOptgroups(getAssignedElementsForSlot(this.defaultSlot));
|
|
726
726
|
}
|
|
727
727
|
async handleDefaultSlotChange() {
|
|
728
|
-
if (!customElements.get("sd-5-
|
|
729
|
-
customElements.whenDefined("sd-5-
|
|
728
|
+
if (!customElements.get("sd-5-10-0-option")) {
|
|
729
|
+
customElements.whenDefined("sd-5-10-0-option").then(() => this.handleDefaultSlotChange());
|
|
730
730
|
return;
|
|
731
731
|
}
|
|
732
732
|
const slottedOptions = this.getSlottedOptions();
|
|
@@ -738,10 +738,10 @@ var SdCombobox = class extends SolidElement {
|
|
|
738
738
|
if (this.multiple) {
|
|
739
739
|
option.checkbox = true;
|
|
740
740
|
}
|
|
741
|
-
option.id = option.id || `sd-5-
|
|
741
|
+
option.id = option.id || `sd-5-10-0-combobox-option-${index}`;
|
|
742
742
|
});
|
|
743
743
|
slottedOptgroups.forEach((optgroup, index) => {
|
|
744
|
-
optgroup.id = optgroup.id || `sd-5-
|
|
744
|
+
optgroup.id = optgroup.id || `sd-5-10-0-combobox-optgroup-${index}`;
|
|
745
745
|
});
|
|
746
746
|
await this.syncSelectedOptionsAndValue();
|
|
747
747
|
if (this.multiple) {
|
|
@@ -789,7 +789,7 @@ var SdCombobox = class extends SolidElement {
|
|
|
789
789
|
default: "border-neutral-800"
|
|
790
790
|
}[selectState],
|
|
791
791
|
this.open && (this.currentPlacement === "bottom" ? "rounded-bl-none rounded-br-none" : "rounded-tl-none rounded-tr-none")
|
|
792
|
-
)}"></div><sd-5-
|
|
792
|
+
)}"></div><sd-5-10-0-popup @sd-current-placement="${this.handleCurrentPlacement}" class="${cx(
|
|
793
793
|
"inline-flex relative w-full",
|
|
794
794
|
this.currentPlacement === "bottom" ? "origin-top" : "origin-bottom"
|
|
795
795
|
)}" placement="${this.placement}" strategy="${this.hoist ? "fixed" : "absolute"}" flip shift sync="width" auto-size="vertical" auto-size-padding="10" exportparts="
|
|
@@ -811,26 +811,26 @@ var SdCombobox = class extends SolidElement {
|
|
|
811
811
|
"flex justify-center",
|
|
812
812
|
iconMarginLeft,
|
|
813
813
|
this.value.length > 0 ? "visible" : "invisible"
|
|
814
|
-
)}" type="button" aria-label="${this.localize.term("clearEntry")}" @mousedown="${this.preventLoosingFocus}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-5-
|
|
814
|
+
)}" type="button" aria-label="${this.localize.term("clearEntry")}" @mousedown="${this.preventLoosingFocus}" @click="${this.handleClearClick}" tabindex="-1"><slot name="clear-icon"><sd-5-10-0-icon class="${cx("text-neutral-700", iconSize)}" name="closing-round" library="_internal"></sd-5-10-0-icon></slot></button>` : ""} ${this.showInvalidStyle ? html`<sd-5-10-0-icon part="invalid-icon" class="${cx(iconMarginLeft, iconSize, "text-error")}" library="_internal" name="risk"></sd-5-10-0-icon>` : ""} ${this.styleOnValid && this.showValidStyle ? html`<sd-5-10-0-icon part="valid-icon" class="${cx("flex-shrink-0 text-success", iconMarginLeft, iconSize)}" library="_internal" name="status-check"></sd-5-10-0-icon>` : ""}<slot name="right" part="right" class="${cx(
|
|
815
815
|
"inline-flex ml-2 leading-[0]",
|
|
816
816
|
this.disabled || this.visuallyDisabled ? "text-neutral-500" : "text-primary",
|
|
817
817
|
iconSize
|
|
818
|
-
)}">${this.type !== "search" ? html`<sd-5-
|
|
818
|
+
)}">${this.type !== "search" ? html`<sd-5-10-0-icon class="${cx(
|
|
819
819
|
"transition-transform duration-medium ease-in-out",
|
|
820
820
|
this.open ? "rotate-180" : "rotate-0"
|
|
821
|
-
)}" name="chevron-down" part="chevron" library="_internal" color="currentColor" label="${this.localize.term("open")}"></sd-5-
|
|
821
|
+
)}" name="chevron-down" part="chevron" library="_internal" color="currentColor" label="${this.localize.term("open")}"></sd-5-10-0-icon>` : ""}</slot>${this.type === "search" ? html`<button class="${cx("flex items-center sd-interactive", iconMarginLeft)}" type="button"><sd-5-10-0-icon class="${cx(iconColor, iconSize)}" library="_internal" name="magnifying-glass" label="${this.localize.term("search")}"></sd-5-10-0-icon></button>` : html`<button class="sd-interactive combobox-button absolute top-2" @keydown="${this.handleComboboxMouseDown}" type="button"><span class="sr-only">${this.localize.term("open")}</span></button>`}</div><div id="listbox" role="${ifDefined(!this.multiple ? "listbox" : void 0)}" aria-expanded="${this.open}" aria-multiselectable="${this.multiple}" aria-labelledby="label" part="listbox" class="${cx(
|
|
822
822
|
"bg-white px-2 py-3 relative border-primary overflow-y-auto",
|
|
823
823
|
this.open && "shadow transition-shadow duration-medium ease-in-out",
|
|
824
824
|
this.currentPlacement === "bottom" ? "border-r-2 border-b-2 border-l-2 rounded-br-default rounded-bl-default" : "border-r-2 border-t-2 border-l-2 rounded-tr-default rounded-tl-default"
|
|
825
|
-
)}" tabindex="-1" @mousedown="${this.preventLoosingFocus}" @mouseup="${this.handleOptionClick}"><div part="filtered-listbox">${this.filteredOptions.length === 0 ? html`<span id="noResults" class="px-4 flex items-center w-full transition-all text-left text-base relative text-black py-3" aria-hidden="true" @click="${this.handleNoResultsClick}">${this.localize.term("noResults")}</span>` : this.options}</div><slot id="defaultOptionsSlot" class="hidden" @slotchange="${this.handleDefaultSlotChange}"></slot></div></sd-5-
|
|
825
|
+
)}" tabindex="-1" @mousedown="${this.preventLoosingFocus}" @mouseup="${this.handleOptionClick}"><div part="filtered-listbox">${this.filteredOptions.length === 0 ? html`<span id="noResults" class="px-4 flex items-center w-full transition-all text-left text-base relative text-black py-3" aria-hidden="true" @click="${this.handleNoResultsClick}">${this.localize.term("noResults")}</span>` : this.options}</div><slot id="defaultOptionsSlot" class="hidden" @slotchange="${this.handleDefaultSlotChange}"></slot></div></sd-5-10-0-popup></div><div part="form-control-help-text" id="help-text" class="text-sm text-neutral-700 mt-2" aria-hidden="${!hasHelpText}"><slot name="help-text">${this.helpText}</slot></div></div>${this.formControlController.renderInvalidMessage()}`;
|
|
826
826
|
}
|
|
827
827
|
};
|
|
828
828
|
SdCombobox.styles = [
|
|
829
829
|
...SolidElement.styles,
|
|
830
|
-
css`:host{display:block;position:relative;width:100%}:host([required]) #label:after{content:" *"}:host([disabled]) ::-moz-placeholder,:host([visually-disabled]) ::-moz-placeholder{--tw-text-opacity:1;color:rgb(var(--sd-color-neutral-500,174 174 174)/var(--tw-text-opacity,1))}:host([disabled]) ::placeholder,:host([visually-disabled]) ::placeholder{--tw-text-opacity:1;color:rgb(var(--sd-color-neutral-500,174 174 174)/var(--tw-text-opacity,1))}:host([visually-disabled]) input{caret-color:transparent}:host([size=sm]) .combobox-button{height:var(--sd-spacing-4,1rem);right:var(--sd-spacing-4,1rem);width:var(--sd-spacing-4,1rem)}:host([size=md]) .combobox-button{height:var(--sd-spacing-6,1.5rem);right:.85rem;width:var(--sd-spacing-6,1.5rem)}:host([size=lg]) .combobox-button{height:var(--sd-spacing-8,2rem);right:var(--sd-spacing-3,.75rem);width:var(--sd-spacing-8,2rem)}[part=listbox]{max-height:var(--auto-size-available-height,auto)}sd-5-
|
|
830
|
+
css`:host{display:block;position:relative;width:100%}:host([required]) #label:after{content:" *"}:host([disabled]) ::-moz-placeholder,:host([visually-disabled]) ::-moz-placeholder{--tw-text-opacity:1;color:rgb(var(--sd-color-neutral-500,174 174 174)/var(--tw-text-opacity,1))}:host([disabled]) ::placeholder,:host([visually-disabled]) ::placeholder{--tw-text-opacity:1;color:rgb(var(--sd-color-neutral-500,174 174 174)/var(--tw-text-opacity,1))}:host([visually-disabled]) input{caret-color:transparent}:host([size=sm]) .combobox-button{height:var(--sd-spacing-4,1rem);right:var(--sd-spacing-4,1rem);width:var(--sd-spacing-4,1rem)}:host([size=md]) .combobox-button{height:var(--sd-spacing-6,1.5rem);right:.85rem;width:var(--sd-spacing-6,1.5rem)}:host([size=lg]) .combobox-button{height:var(--sd-spacing-8,2rem);right:var(--sd-spacing-3,.75rem);width:var(--sd-spacing-8,2rem)}[part=listbox]{max-height:var(--auto-size-available-height,auto)}sd-5-10-0-popup::part(popup){z-index:var(--sd-z-index-dropdown,900)}sd-5-10-0-tag::part(base){border-radius:var(--sd-border-radius-default,.25rem);padding-left:var(--sd-spacing-1,.25rem);padding-right:var(--sd-spacing-1,.25rem)}sd-5-10-0-tag::part(content){display:inline-block;max-width:var(--tag-max-width,15ch);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}sd-5-10-0-tag[size=lg]::part(base){padding-left:var(--sd-spacing-2,.5rem);padding-right:var(--sd-spacing-2,.5rem)}sd-5-10-0-tag[disabled=false]::part(base):hover{--tw-bg-opacity:1;background-color:rgb(var(--sd-color-primary-100,236 240 249)/var(--tw-bg-opacity,1))}[part=filtered-listbox] sd-5-10-0-optgroup:first-of-type{--display-divider:none}mark{background-color:transparent;color:inherit;font-weight:700}`
|
|
831
831
|
];
|
|
832
832
|
__decorateClass([
|
|
833
|
-
query("sd-5-
|
|
833
|
+
query("sd-5-10-0-popup")
|
|
834
834
|
], SdCombobox.prototype, "popup", 2);
|
|
835
835
|
__decorateClass([
|
|
836
836
|
query('[part="combobox"]')
|
|
@@ -988,7 +988,7 @@ __decorateClass([
|
|
|
988
988
|
watch("open", { waitUntilFirstUpdate: true })
|
|
989
989
|
], SdCombobox.prototype, "handleOpenChange", 1);
|
|
990
990
|
SdCombobox = __decorateClass([
|
|
991
|
-
customElement("sd-5-
|
|
991
|
+
customElement("sd-5-10-0-combobox")
|
|
992
992
|
], SdCombobox);
|
|
993
993
|
setDefaultAnimation("combobox.show", {
|
|
994
994
|
keyframes: [{ opacity: 0 }, { opacity: 1 }],
|
|
@@ -142,7 +142,7 @@ var SdAccordion = class extends SolidElement {
|
|
|
142
142
|
)}"></div><slot name="summary" part="summary" class="flex flex-auto items-center text-left">${this.summary}</slot><span part="summary-icon" class="${cx(
|
|
143
143
|
"flex flex-grow-0 flex-shrink-0 flex-auto items-center transition-all ease-in-out duration-medium text-xl",
|
|
144
144
|
this.open && "rotate-180"
|
|
145
|
-
)}"><slot name="expand-icon" class="${cx(this.open && "hidden")}"><sd-5-
|
|
145
|
+
)}"><slot name="expand-icon" class="${cx(this.open && "hidden")}"><sd-5-10-0-icon library="_internal" name="chevron-down"></sd-5-10-0-icon></slot><slot name="collapse-icon" class="${cx(!this.open && "hidden")}"><sd-5-10-0-icon library="_internal" name="chevron-down"></sd-5-10-0-icon></slot></span></summary><div part="content" id="content" class="overflow-hidden"><slot part="content__slot" class="block px-4 py-6" role="region" aria-labelledby="header"></slot></div></details>`;
|
|
146
146
|
}
|
|
147
147
|
};
|
|
148
148
|
SdAccordion.styles = [
|
|
@@ -168,7 +168,7 @@ __decorateClass([
|
|
|
168
168
|
watch("open", { waitUntilFirstUpdate: true })
|
|
169
169
|
], SdAccordion.prototype, "handleOpenChange", 1);
|
|
170
170
|
SdAccordion = __decorateClass([
|
|
171
|
-
customElement("sd-5-
|
|
171
|
+
customElement("sd-5-10-0-accordion")
|
|
172
172
|
], SdAccordion);
|
|
173
173
|
setDefaultAnimation("accordion.show", {
|
|
174
174
|
keyframes: [
|
|
@@ -210,15 +210,15 @@ var SdNotification = class extends SolidElement {
|
|
|
210
210
|
warning: "bg-warning",
|
|
211
211
|
error: "bg-error"
|
|
212
212
|
}[this.variant]
|
|
213
|
-
)}"><sd-5-
|
|
213
|
+
)}"><sd-5-10-0-icon name="${{
|
|
214
214
|
info: "info-circle",
|
|
215
215
|
success: "confirm-circle",
|
|
216
216
|
warning: "exclamation-circle",
|
|
217
217
|
error: "warning"
|
|
218
|
-
}[this.variant] || ""}" library="_internal" class="h-6 w-6 text-white"></sd-5-
|
|
218
|
+
}[this.variant] || ""}" library="_internal" class="h-6 w-6 text-white"></sd-5-10-0-icon></slot><div part="content" class="${cx(
|
|
219
219
|
"h-full w-full p-1 gap-2 flex items-center justify-stretch bg-white",
|
|
220
220
|
"border-solid border-[1px] border-l-0 border-neutral-400"
|
|
221
|
-
)}"><slot id="message" part="message" class="block w-full pl-3 py-2"></slot>${this.closable ? html`<sd-5-
|
|
221
|
+
)}"><slot id="message" part="message" class="block w-full pl-3 py-2"></slot>${this.closable ? html`<sd-5-10-0-button size="md" variant="tertiary" part="close-button" class="ml-auto flex flex-[0_0_auto] items-stretch" @click="${this.handleCloseClick}"><sd-5-10-0-icon label="${this.localize.term("close")}" name="close" library="_internal" color="currentColor"></sd-5-10-0-icon></sd-5-10-0-button>` : ""}</div>${this.durationIndicator ? html`<div part="duration-indicator__elapsed" id="duration-indicator__elapsed" style="${`animation-duration: ${this.duration}ms`}" class="${cx(`absolute w-0 h-[2px] bottom-0 bg-primary z-10 animate-grow`)}"></div><div part="duration-indicator__total" class="w-full h-[2px] bottom-0 absolute border border-neutral-400"></div>` : ""}</div></div>`;
|
|
222
222
|
}
|
|
223
223
|
};
|
|
224
224
|
/**
|
|
@@ -262,7 +262,7 @@ __decorateClass([
|
|
|
262
262
|
watch("duration")
|
|
263
263
|
], SdNotification.prototype, "handleDurationChange", 1);
|
|
264
264
|
SdNotification = __decorateClass([
|
|
265
|
-
customElement("sd-5-
|
|
265
|
+
customElement("sd-5-10-0-notification")
|
|
266
266
|
], SdNotification);
|
|
267
267
|
setDefaultAnimation("notification.show", {
|
|
268
268
|
keyframes: [
|