@solid-design-system/components 7.0.3 → 7.1.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.PEHSUZ2L.js +2 -0
- package/cdn/components/datepicker/datepicker.d.ts +4 -0
- package/cdn/components/datepicker/datepicker.js +1 -1
- package/cdn/custom-elements.json +33 -1
- package/cdn/solid-components.bundle.js +2 -2
- package/cdn/solid-components.iife.js +2 -2
- package/cdn/solid-components.js +1 -1
- package/cdn/vscode.html-custom-data.json +6 -1
- package/cdn/web-types.json +24 -2
- package/cdn-versioned/chunks/chunk.2C3UQTSS.js +2 -2
- package/cdn-versioned/chunks/chunk.2O3FM7UB.js +2 -2
- package/cdn-versioned/chunks/chunk.35XPUMS2.js +1 -1
- package/cdn-versioned/chunks/chunk.37JCS2XH.js +5 -5
- package/cdn-versioned/chunks/chunk.3IZUMERL.js +2 -2
- package/cdn-versioned/chunks/chunk.3RIAU3TH.js +3 -3
- package/cdn-versioned/chunks/chunk.4GA43M6X.js +2 -2
- package/cdn-versioned/chunks/chunk.4QTJXGRR.js +2 -2
- package/cdn-versioned/chunks/chunk.ADVB3FPU.js +2 -2
- package/cdn-versioned/chunks/chunk.AJGTKHU5.js +2 -2
- package/cdn-versioned/chunks/chunk.C37LGAL3.js +2 -2
- package/cdn-versioned/chunks/chunk.CGMKBGJU.js +2 -2
- package/cdn-versioned/chunks/chunk.CQNFI34K.js +2 -2
- package/cdn-versioned/chunks/chunk.DCAJAXUP.js +2 -2
- package/cdn-versioned/chunks/chunk.DS2MKMMN.js +3 -3
- package/cdn-versioned/chunks/chunk.DSKB3SEU.js +1 -1
- package/cdn-versioned/chunks/chunk.GA3PWYR4.js +2 -2
- package/cdn-versioned/chunks/chunk.HNBY226D.js +1 -1
- package/cdn-versioned/chunks/chunk.HY624TPC.js +2 -2
- package/cdn-versioned/chunks/chunk.I7OVY27Y.js +10 -10
- package/cdn-versioned/chunks/chunk.IFLRUJCI.js +2 -2
- package/cdn-versioned/chunks/chunk.IQBZ7GRB.js +2 -2
- package/cdn-versioned/chunks/chunk.J45556RK.js +1 -1
- package/cdn-versioned/chunks/chunk.JMX6KLDZ.js +2 -2
- package/cdn-versioned/chunks/chunk.JQV2BZ2E.js +2 -2
- package/cdn-versioned/chunks/chunk.KE2YEQDL.js +2 -2
- package/cdn-versioned/chunks/chunk.LZRL7OLU.js +1 -1
- package/cdn-versioned/chunks/chunk.MR54F6CV.js +2 -2
- package/cdn-versioned/chunks/chunk.MYPRMCUO.js +1 -1
- package/cdn-versioned/chunks/chunk.N4L76IWF.js +1 -1
- package/cdn-versioned/chunks/chunk.NGU7NO3O.js +5 -5
- package/cdn-versioned/chunks/chunk.NJKSWXOS.js +2 -2
- package/cdn-versioned/chunks/chunk.NOP4DTP2.js +2 -2
- package/cdn-versioned/chunks/chunk.OOIX4OAP.js +2 -2
- package/cdn-versioned/chunks/chunk.P7GMFHO5.js +1 -1
- package/cdn-versioned/chunks/chunk.PCXVXYU2.js +2 -2
- package/cdn-versioned/chunks/chunk.PEHSUZ2L.js +2 -0
- package/cdn-versioned/chunks/chunk.PFPUD5HR.js +2 -2
- package/cdn-versioned/chunks/chunk.PKCNX4R2.js +2 -2
- package/cdn-versioned/chunks/chunk.PQW77KHE.js +2 -2
- package/cdn-versioned/chunks/chunk.PURR56D5.js +2 -2
- package/cdn-versioned/chunks/chunk.Q63S2Z2M.js +2 -2
- package/cdn-versioned/chunks/chunk.QK3WCIP5.js +2 -2
- package/cdn-versioned/chunks/chunk.RHC6WZ6V.js +2 -2
- package/cdn-versioned/chunks/chunk.RRJCCIDH.js +1 -1
- package/cdn-versioned/chunks/chunk.SPL6VR5S.js +2 -2
- package/cdn-versioned/chunks/chunk.SSE7T5OF.js +2 -2
- package/cdn-versioned/chunks/chunk.SZNU4NHI.js +1 -1
- package/cdn-versioned/chunks/chunk.T7I5MFNS.js +2 -2
- package/cdn-versioned/chunks/chunk.TIMZJKMF.js +2 -2
- package/cdn-versioned/chunks/chunk.TX5WPWH2.js +2 -2
- package/cdn-versioned/chunks/chunk.UI3ZVKSU.js +2 -2
- package/cdn-versioned/chunks/chunk.V6IM4GAA.js +2 -2
- package/cdn-versioned/chunks/chunk.VPBXFCBA.js +2 -2
- package/cdn-versioned/chunks/chunk.VSX5LY2D.js +2 -2
- package/cdn-versioned/chunks/chunk.W7A3TU2Z.js +1 -1
- package/cdn-versioned/chunks/chunk.WL6NNNG5.js +2 -2
- package/cdn-versioned/chunks/chunk.WQZWYMH3.js +1 -1
- package/cdn-versioned/chunks/chunk.WUXX2P2S.js +2 -2
- package/cdn-versioned/chunks/chunk.XGVG7F7T.js +2 -2
- package/cdn-versioned/chunks/chunk.XHYIXZF4.js +2 -2
- package/cdn-versioned/chunks/chunk.XZ5JTM6K.js +2 -2
- package/cdn-versioned/chunks/chunk.Y4ZS3BWH.js +2 -2
- package/cdn-versioned/chunks/chunk.YUDSN6HJ.js +3 -3
- package/cdn-versioned/chunks/chunk.Z2M7BQV5.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/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/datepicker/datepicker.d.ts +5 -1
- package/cdn-versioned/components/datepicker/datepicker.js +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/file-selector/file-selector.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/loader/loader.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/progress-bar/progress-bar.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/range/range.d.ts +1 -1
- package/cdn-versioned/components/range-tick/range-tick.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/skeleton/skeleton.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/theme-listener/theme-listener.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 +298 -266
- package/cdn-versioned/internal/form.js +2 -2
- package/cdn-versioned/solid-components.bundle.js +81 -81
- package/cdn-versioned/solid-components.css +3 -3
- package/cdn-versioned/solid-components.iife.js +81 -81
- package/cdn-versioned/solid-components.js +1 -1
- package/cdn-versioned/vscode.html-custom-data.json +120 -115
- package/cdn-versioned/web-types.json +195 -173
- package/dist/chunks/{chunk.UDTZN5OG.js → chunk.RRSERGVO.js} +37 -2
- package/dist/components/datepicker/datepicker.d.ts +4 -0
- package/dist/components/datepicker/datepicker.js +1 -1
- package/dist/custom-elements.json +33 -1
- package/dist/solid-components.js +4 -4
- package/dist/vscode.html-custom-data.json +6 -1
- package/dist/web-types.json +24 -2
- package/dist-versioned/chunks/chunk.2EXNVXP2.js +2 -2
- package/dist-versioned/chunks/chunk.2M6Y3YHU.js +4 -4
- package/dist-versioned/chunks/chunk.2NXJZVSN.js +11 -11
- package/dist-versioned/chunks/chunk.2OT7JZJP.js +10 -10
- package/dist-versioned/chunks/chunk.2Y2MTVGF.js +3 -3
- package/dist-versioned/chunks/chunk.3PHACHZ2.js +7 -7
- package/dist-versioned/chunks/chunk.42XKKRQ2.js +6 -6
- package/dist-versioned/chunks/chunk.4FXMBMSY.js +3 -3
- package/dist-versioned/chunks/chunk.4JC6XNQW.js +4 -4
- package/dist-versioned/chunks/chunk.4VWOZ477.js +4 -4
- package/dist-versioned/chunks/chunk.5JPFIM5W.js +3 -3
- package/dist-versioned/chunks/chunk.5TU4CAN7.js +6 -6
- package/dist-versioned/chunks/chunk.65FELEDA.js +3 -3
- package/dist-versioned/chunks/chunk.67LY7Y75.js +4 -4
- package/dist-versioned/chunks/chunk.6F52A4JB.js +3 -3
- package/dist-versioned/chunks/chunk.72LCNWVE.js +3 -3
- package/dist-versioned/chunks/chunk.7DQB3MN6.js +7 -7
- package/dist-versioned/chunks/chunk.7EXDALNL.js +5 -5
- package/dist-versioned/chunks/chunk.AHIYNPL4.js +1 -1
- package/dist-versioned/chunks/chunk.ALJ34SPY.js +4 -4
- package/dist-versioned/chunks/chunk.B5BWUIZC.js +2 -2
- package/dist-versioned/chunks/chunk.BW5BXFWA.js +5 -5
- package/dist-versioned/chunks/chunk.C3L34J75.js +1 -1
- package/dist-versioned/chunks/chunk.C3WIBDGG.js +2 -2
- package/dist-versioned/chunks/chunk.C4HDZU75.js +2 -2
- package/dist-versioned/chunks/chunk.CB7PF3MZ.js +6 -6
- package/dist-versioned/chunks/chunk.CXFXIMXV.js +13 -13
- package/dist-versioned/chunks/chunk.DF2LZ65H.js +2 -2
- package/dist-versioned/chunks/chunk.DGLSKBZE.js +3 -3
- package/dist-versioned/chunks/chunk.DZED227Y.js +1 -1
- package/dist-versioned/chunks/chunk.EQIZ7J5Z.js +25 -25
- package/dist-versioned/chunks/chunk.ES5DW7MC.js +2 -2
- package/dist-versioned/chunks/chunk.HFRDUE6W.js +11 -11
- package/dist-versioned/chunks/chunk.I3DVEGNB.js +11 -11
- package/dist-versioned/chunks/chunk.JKJXDDJU.js +3 -3
- package/dist-versioned/chunks/chunk.JPGYEMXS.js +2 -2
- package/dist-versioned/chunks/chunk.JXDY64LH.js +10 -10
- package/dist-versioned/chunks/chunk.KEJFWGZI.js +4 -4
- package/dist-versioned/chunks/chunk.KSU44YSO.js +7 -7
- package/dist-versioned/chunks/chunk.KXUT6UJL.js +2 -2
- package/dist-versioned/chunks/chunk.MPHRXV2B.js +1 -1
- package/dist-versioned/chunks/chunk.N5RQE7OC.js +1 -1
- package/dist-versioned/chunks/chunk.PAXRRXRW.js +4 -4
- package/dist-versioned/chunks/chunk.PGECK7YI.js +1 -1
- package/dist-versioned/chunks/chunk.QGCJ4WUV.js +5 -5
- package/dist-versioned/chunks/chunk.QIYLIH7P.js +5 -5
- package/dist-versioned/chunks/chunk.QNHUD2SQ.js +42 -42
- package/dist-versioned/chunks/{chunk.UDTZN5OG.js → chunk.RRSERGVO.js} +46 -11
- package/dist-versioned/chunks/chunk.S2ZVBJYN.js +5 -5
- package/dist-versioned/chunks/chunk.SEWHXNAY.js +5 -5
- package/dist-versioned/chunks/chunk.SG7H3CVK.js +12 -12
- package/dist-versioned/chunks/chunk.SMRP2JEM.js +1 -1
- package/dist-versioned/chunks/chunk.TFAIMBF7.js +11 -11
- package/dist-versioned/chunks/chunk.TLAI6IVF.js +2 -2
- package/dist-versioned/chunks/chunk.UIQBHPD3.js +2 -2
- package/dist-versioned/chunks/chunk.UORTR6WB.js +5 -5
- package/dist-versioned/chunks/chunk.VX7JXCCH.js +2 -2
- package/dist-versioned/chunks/chunk.XAU2YS2A.js +5 -5
- package/dist-versioned/chunks/chunk.XQMBT64Z.js +8 -8
- package/dist-versioned/chunks/chunk.YJ46MX3X.js +6 -6
- package/dist-versioned/chunks/chunk.YKGIJFJM.js +23 -23
- package/dist-versioned/chunks/chunk.YRKHHYV5.js +2 -2
- package/dist-versioned/chunks/chunk.Z4IULIBO.js +10 -10
- package/dist-versioned/chunks/chunk.ZLPWCNY6.js +14 -14
- package/dist-versioned/chunks/chunk.ZQ6CXL6H.js +5 -5
- 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/datepicker/datepicker.d.ts +5 -1
- package/dist-versioned/components/datepicker/datepicker.js +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/file-selector/file-selector.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/loader/loader.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/progress-bar/progress-bar.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/range/range.d.ts +1 -1
- package/dist-versioned/components/range-tick/range-tick.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/skeleton/skeleton.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/theme-listener/theme-listener.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 +298 -266
- package/dist-versioned/internal/form.js +2 -2
- package/dist-versioned/solid-components.css +3 -3
- package/dist-versioned/solid-components.js +4 -4
- package/dist-versioned/vscode.html-custom-data.json +120 -115
- package/dist-versioned/web-types.json +195 -173
- package/package.json +3 -3
- package/cdn/chunks/chunk.7OG7ICBB.js +0 -2
- package/cdn-versioned/chunks/chunk.7OG7ICBB.js +0 -2
|
@@ -48,7 +48,7 @@ var SubmenuController = class {
|
|
|
48
48
|
if (event.target === this.host) {
|
|
49
49
|
event.preventDefault();
|
|
50
50
|
event.stopPropagation();
|
|
51
|
-
} else if (event.target instanceof Element && (event.target.tagName === "sd-7-0-
|
|
51
|
+
} else if (event.target instanceof Element && (event.target.tagName === "sd-7-1-0-menu-item" || ((_a = event.target.role) == null ? void 0 : _a.startsWith("menuitem")))) {
|
|
52
52
|
const type = event.target.getAttribute("type");
|
|
53
53
|
if (type !== "checkbox") {
|
|
54
54
|
this.disableSubmenu();
|
|
@@ -69,7 +69,7 @@ var SubmenuController = class {
|
|
|
69
69
|
// Set the safe triangle values for the submenu when the position changes
|
|
70
70
|
this.handlePopupReposition = () => {
|
|
71
71
|
const submenuSlot = this.host.renderRoot.querySelector("slot[name='submenu']");
|
|
72
|
-
const menu = submenuSlot == null ? void 0 : submenuSlot.assignedElements({ flatten: true }).filter((el) => el.localName === "sd-7-0-
|
|
72
|
+
const menu = submenuSlot == null ? void 0 : submenuSlot.assignedElements({ flatten: true }).filter((el) => el.localName === "sd-7-1-0-menu")[0];
|
|
73
73
|
const isRtl = getComputedStyle(this.host).direction === "rtl";
|
|
74
74
|
if (!menu) {
|
|
75
75
|
return;
|
|
@@ -141,7 +141,7 @@ var SubmenuController = class {
|
|
|
141
141
|
}
|
|
142
142
|
let menuItems = null;
|
|
143
143
|
for (const elt of submenuSlot.assignedElements()) {
|
|
144
|
-
menuItems = elt.querySelectorAll("sd-7-0-
|
|
144
|
+
menuItems = elt.querySelectorAll("sd-7-1-0-menu-item, [role^='menuitem']");
|
|
145
145
|
if (menuItems.length !== 0) {
|
|
146
146
|
break;
|
|
147
147
|
}
|
|
@@ -220,7 +220,7 @@ var SubmenuController = class {
|
|
|
220
220
|
if (!this.isConnected) {
|
|
221
221
|
return html`<slot name="submenu" hidden></slot>`;
|
|
222
222
|
}
|
|
223
|
-
return html`<sd-7-0-
|
|
223
|
+
return html`<sd-7-1-0-popup ${ref(this.popupRef)} placement="${isRtl ? "left-start" : "right-start"}" anchor="anchor" flip flip-fallback-strategy="best-fit" skidding="${this.skidding}" strategy="fixed" auto-size="vertical" auto-size-padding="10"><slot name="submenu"></slot></sd-7-1-0-popup>`;
|
|
224
224
|
}
|
|
225
225
|
};
|
|
226
226
|
|
|
@@ -24,7 +24,7 @@ var SdTab = class extends SolidElement {
|
|
|
24
24
|
constructor() {
|
|
25
25
|
super(...arguments);
|
|
26
26
|
this.attrId = ++id;
|
|
27
|
-
this.componentId = `sd-7-0-
|
|
27
|
+
this.componentId = `sd-7-1-0-tab-${this.attrId}`;
|
|
28
28
|
this.hasSlotController = new HasSlotController(this, "left");
|
|
29
29
|
this.localize = new LocalizeController(this);
|
|
30
30
|
this.variant = "default";
|
|
@@ -62,17 +62,17 @@ var SdTab = class extends SolidElement {
|
|
|
62
62
|
"outline-hidden focus-visible:focus-outline outline-2 !-outline-offset-2 transition-all duration-fast ease-in-out",
|
|
63
63
|
this.variant === "container" ? "tab-container-border bg-white rounded-[4px_4px_0_0]" : "navigable-border-radius",
|
|
64
64
|
this.variant === "container" && this.active && "tab--active-container-border bg-white",
|
|
65
|
-
this.disabled || this.visuallyDisabled ? "!cursor-not-allowed" : "hover:sd-7-0-
|
|
66
|
-
this.active && "z-20 sd-7-0-
|
|
65
|
+
this.disabled || this.visuallyDisabled ? "!cursor-not-allowed" : "hover:sd-7-1-0-tab--hover-color-background",
|
|
66
|
+
this.active && "z-20 sd-7-1-0-tab--active-color-text"
|
|
67
67
|
)}" tabindex="${!this.active || this.disabled ? "-1" : "0"}"><div class="${cx("flex h-full items-center justify-center whitespace-nowrap")}"><slot name="left" class="${cx(
|
|
68
68
|
slots.left && "block pr-2",
|
|
69
|
-
this.disabled || this.visuallyDisabled ? "sd-7-0-
|
|
69
|
+
this.disabled || this.visuallyDisabled ? "sd-7-1-0-tab--disabled-color-text" : this.active ? "sd-7-1-0-tab--active-color-text" : "sd-7-1-0-tab-color-text"
|
|
70
70
|
)}"></slot><slot class="${cx(
|
|
71
|
-
this.disabled || this.visuallyDisabled ? "sd-7-0-
|
|
71
|
+
this.disabled || this.visuallyDisabled ? "sd-7-1-0-tab--disabled-color-text" : this.active ? "sd-7-1-0-tab--active-color-text" : "sd-7-1-0-tab-color-text"
|
|
72
72
|
)}"></slot>${this.variant === "container" ? html`<div part="active-tab-indicator" class="${cx(
|
|
73
73
|
"absolute bottom-0 h-1 bg-accent w-3/4 bottom-0 group-hover:w-[calc(100%-2px)] navigable__current-indicator-height navigable__current-indicator-border-radius"
|
|
74
74
|
)}"></div>` : ""}<div part="hover-bottom-border" class="${cx(
|
|
75
|
-
!this.active && !this.disabled && "absolute bottom-0 left-0 w-full h-0.25 border-b sd-7-0-
|
|
75
|
+
!this.active && !this.disabled && "absolute bottom-0 left-0 w-full h-0.25 border-b sd-7-1-0-tab-color-border"
|
|
76
76
|
)}"></div></div></div>`;
|
|
77
77
|
}
|
|
78
78
|
};
|
|
@@ -109,7 +109,7 @@ __decorateClass([
|
|
|
109
109
|
watch(["disabled", "visually-disabled"])
|
|
110
110
|
], SdTab.prototype, "handleDisabledChange", 1);
|
|
111
111
|
SdTab = __decorateClass([
|
|
112
|
-
customElement("sd-7-0-
|
|
112
|
+
customElement("sd-7-1-0-tab")
|
|
113
113
|
], SdTab);
|
|
114
114
|
|
|
115
115
|
export {
|
|
@@ -138,7 +138,7 @@ var SdDrawer = class extends SolidElement {
|
|
|
138
138
|
end: "top-0 end-0 bottom-auto start-auto w-[var(--width)] h-full",
|
|
139
139
|
start: "top-0 end-auto bottom-auto start-0 w-[var(--width)] h-full"
|
|
140
140
|
}[this.placement]
|
|
141
|
-
)}" 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:64px"><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 ms-4 absolute top-2 end-2"><sd-7-0-
|
|
141
|
+
)}" 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:64px"><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 ms-4 absolute top-2 end-2"><sd-7-1-0-button variant="tertiary" size="lg" part="close-button" @click="${() => this.requestClose("close-button")}"><sd-7-1-0-icon label="${this.localize.term("close")}" name="close" library="_internal"></sd-7-1-0-icon></sd-7-1-0-button></div></header>` : html`<sd-7-1-0-button variant="tertiary" size="lg" part="close-button" @click="${() => this.requestClose("close-button")}" class="absolute top-2 end-2 z-10"><sd-7-1-0-icon label="${this.localize.term("close")}" name="close" library="_internal"></sd-7-1-0-icon></sd-7-1-0-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></dialog>`;
|
|
142
142
|
}
|
|
143
143
|
};
|
|
144
144
|
SdDrawer.styles = [
|
|
@@ -174,7 +174,7 @@ __decorateClass([
|
|
|
174
174
|
watch("open", { waitUntilFirstUpdate: true })
|
|
175
175
|
], SdDrawer.prototype, "handleOpenChange", 1);
|
|
176
176
|
SdDrawer = __decorateClass([
|
|
177
|
-
customElement("sd-7-0-
|
|
177
|
+
customElement("sd-7-1-0-drawer")
|
|
178
178
|
], SdDrawer);
|
|
179
179
|
setDefaultAnimation("drawer.showStart", {
|
|
180
180
|
keyframes: [
|
|
@@ -209,7 +209,7 @@ __decorateClass([
|
|
|
209
209
|
watch("playbackRate")
|
|
210
210
|
], SdAnimation.prototype, "handlePlaybackRateChange", 1);
|
|
211
211
|
SdAnimation = __decorateClass([
|
|
212
|
-
customElement("sd-7-0-
|
|
212
|
+
customElement("sd-7-1-0-animation")
|
|
213
213
|
], SdAnimation);
|
|
214
214
|
|
|
215
215
|
export {
|
|
@@ -324,7 +324,7 @@ __decorateClass([
|
|
|
324
324
|
property({ attribute: "auto-size-padding", type: Number })
|
|
325
325
|
], SdPopup.prototype, "autoSizePadding", 2);
|
|
326
326
|
SdPopup = __decorateClass([
|
|
327
|
-
customElement("sd-7-0-
|
|
327
|
+
customElement("sd-7-1-0-popup")
|
|
328
328
|
], SdPopup);
|
|
329
329
|
|
|
330
330
|
export {
|
|
@@ -25,11 +25,11 @@ var SdOptgroup = class extends SolidElement {
|
|
|
25
25
|
this.label = "";
|
|
26
26
|
}
|
|
27
27
|
/**
|
|
28
|
-
* Syncs the disabled prop for all slotted sd-7-0-
|
|
28
|
+
* Syncs the disabled prop for all slotted sd-7-1-0-options when it is triggered
|
|
29
29
|
*/
|
|
30
30
|
handleDisableOptions() {
|
|
31
31
|
const { disabled } = this;
|
|
32
|
-
this.defaultSlot.assignedElements().filter((opt) => opt.tagName.toLowerCase() === "sd-7-0-
|
|
32
|
+
this.defaultSlot.assignedElements().filter((opt) => opt.tagName.toLowerCase() === "sd-7-1-0-option").forEach((opt) => {
|
|
33
33
|
opt.disabled = disabled;
|
|
34
34
|
});
|
|
35
35
|
}
|
|
@@ -38,7 +38,7 @@ var SdOptgroup = class extends SolidElement {
|
|
|
38
38
|
}
|
|
39
39
|
render() {
|
|
40
40
|
const { disabled } = this;
|
|
41
|
-
return html`<div role="${disabled ? "presentation" : "group"}" class="${cx(this.disabled ? "text-neutral-500" : "")}" part="base" aria-labelledby="group-label"><sd-7-0-
|
|
41
|
+
return html`<div role="${disabled ? "presentation" : "group"}" class="${cx(this.disabled ? "text-neutral-500" : "")}" part="base" aria-labelledby="group-label"><sd-7-1-0-divider id="divider" class="pt-2 pb-4" part="divider"></sd-7-1-0-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>`;
|
|
42
42
|
}
|
|
43
43
|
};
|
|
44
44
|
SdOptgroup.styles = [
|
|
@@ -59,7 +59,7 @@ __decorateClass([
|
|
|
59
59
|
watch("disabled", { waitUntilFirstUpdate: true })
|
|
60
60
|
], SdOptgroup.prototype, "handleDisabledChange", 1);
|
|
61
61
|
SdOptgroup = __decorateClass([
|
|
62
|
-
customElement("sd-7-0-
|
|
62
|
+
customElement("sd-7-1-0-optgroup")
|
|
63
63
|
], SdOptgroup);
|
|
64
64
|
|
|
65
65
|
export {
|
|
@@ -26,7 +26,7 @@ SdCarouselItem.styles = [
|
|
|
26
26
|
:host{aspect-ratio:var(--aspect-ratio);scroll-snap-align:start;scroll-snap-stop:always;display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center}::slotted(img){height:100%;width:100%;-o-object-fit:cover;object-fit:cover}`
|
|
27
27
|
];
|
|
28
28
|
SdCarouselItem = __decorateClass([
|
|
29
|
-
customElement("sd-7-0-
|
|
29
|
+
customElement("sd-7-1-0-carousel-item")
|
|
30
30
|
], SdCarouselItem);
|
|
31
31
|
|
|
32
32
|
export {
|
|
@@ -87,7 +87,7 @@ var SdFlipcard = class extends SolidElement {
|
|
|
87
87
|
"gradient-light": this.placement === "top" ? "bg-gradient-to-b from-white/60 to-white/0 mb-auto" : "bg-gradient-to-t from-white/60 to-white/0 mt-auto",
|
|
88
88
|
"gradient-dark": this.placement === "bottom" ? "bg-gradient-to-t from-primary-800/60 to-primary-800/0 mt-auto" : "bg-gradient-to-b from-primary-800/60 to-primary-800/0 mb-auto"
|
|
89
89
|
}[this.frontVariant]
|
|
90
|
-
)}"></div><sd-7-0-
|
|
90
|
+
)}"></div><sd-7-1-0-button part="front-button" size="md" variant="${{
|
|
91
91
|
primary: "tertiary",
|
|
92
92
|
"primary-100": "tertiary",
|
|
93
93
|
"gradient-light": "primary",
|
|
@@ -97,7 +97,7 @@ var SdFlipcard = class extends SolidElement {
|
|
|
97
97
|
"primary-100": false,
|
|
98
98
|
"gradient-light": true,
|
|
99
99
|
"gradient-dark": true
|
|
100
|
-
}[this.frontVariant]}" class="${cx("absolute right-0 p-2 flex-shrink-0", this.placement === "top" ? "bottom-0" : "top-0")}" @click="${this.flipFront}" @keydown="${this.handleFrontKeydown}"><sd-7-0-
|
|
100
|
+
}[this.frontVariant]}" class="${cx("absolute right-0 p-2 flex-shrink-0", this.placement === "top" ? "bottom-0" : "top-0")}" @click="${this.flipFront}" @keydown="${this.handleFrontKeydown}"><sd-7-1-0-icon library="_internal" name="reload" label="Flip to Back"></sd-7-1-0-icon></sd-7-1-0-button></div><div part="back" tabindex="0" aria-hidden="${this.activeSide === "front"}" inert="${ifDefined(this.activeSide === "front" || void 0)}" class="${cx(
|
|
101
101
|
"flip-card__side flip-card__side--back overflow-hidden transition-transform duration-1000 ease-in-out",
|
|
102
102
|
"flex focus-visible:focus-outline",
|
|
103
103
|
"absolute top-0 left-0 w-full h-full justify-end text-left",
|
|
@@ -130,7 +130,7 @@ var SdFlipcard = class extends SolidElement {
|
|
|
130
130
|
"gradient-light": this.placement === "top" ? "bg-gradient-to-b from-white/60 to-white/0 mb-auto" : "bg-gradient-to-t from-white/60 to-white/0 mt-auto",
|
|
131
131
|
"gradient-dark": this.placement === "bottom" ? "bg-gradient-to-t from-primary-800/60 to-primary-800/0 mt-auto" : "bg-gradient-to-b from-primary-800/60 to-primary-800/0 mb-auto"
|
|
132
132
|
}[this.backVariant]
|
|
133
|
-
)}"></div><sd-7-0-
|
|
133
|
+
)}"></div><sd-7-1-0-button size="md" part="back-button" variant="${{
|
|
134
134
|
primary: "tertiary",
|
|
135
135
|
"primary-100": "tertiary",
|
|
136
136
|
"gradient-light": "primary",
|
|
@@ -140,7 +140,7 @@ var SdFlipcard = class extends SolidElement {
|
|
|
140
140
|
"primary-100": false,
|
|
141
141
|
"gradient-light": true,
|
|
142
142
|
"gradient-dark": true
|
|
143
|
-
}[this.backVariant]}" class="${cx("absolute right-0 p-2 flex-shrink-0", this.placement === "top" ? "bottom-0" : "top-0")}" @click="${this.flipBack}" @keydown="${this.handleBackKeydown}"><sd-7-0-
|
|
143
|
+
}[this.backVariant]}" class="${cx("absolute right-0 p-2 flex-shrink-0", this.placement === "top" ? "bottom-0" : "top-0")}" @click="${this.flipBack}" @keydown="${this.handleBackKeydown}"><sd-7-1-0-icon library="_internal" name="reload" label="Flip to Front"></sd-7-1-0-icon></sd-7-1-0-button></div></div>`;
|
|
144
144
|
}
|
|
145
145
|
};
|
|
146
146
|
/**
|
|
@@ -176,7 +176,7 @@ __decorateClass([
|
|
|
176
176
|
state()
|
|
177
177
|
], SdFlipcard.prototype, "activeSide", 2);
|
|
178
178
|
SdFlipcard = __decorateClass([
|
|
179
|
-
customElement("sd-7-0-
|
|
179
|
+
customElement("sd-7-1-0-flipcard")
|
|
180
180
|
], SdFlipcard);
|
|
181
181
|
|
|
182
182
|
export {
|
|
@@ -300,19 +300,19 @@ var SdAudio = class extends SolidElement {
|
|
|
300
300
|
)}" part="audio-controls"><button class="${cx(
|
|
301
301
|
"playback-speed justify-self-start text-base font-bold hover:cursor-pointer sd-interactive",
|
|
302
302
|
this.inverted && "sd-interactive--inverted"
|
|
303
|
-
)}" aria-label="${this.localize.term("playbackSpeed")} (${this.speed}x)" @click="${this.togglePlaybackSpeed}" @keydown="${this.togglePlaybackSpeedKeydown}" part="playback-speed">${this.speed}x</button><sd-7-0-
|
|
303
|
+
)}" aria-label="${this.localize.term("playbackSpeed")} (${this.speed}x)" @click="${this.togglePlaybackSpeed}" @keydown="${this.togglePlaybackSpeedKeydown}" part="playback-speed">${this.speed}x</button><sd-7-1-0-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="mb-4">${this.isPlaying ? html`<slot name="pause-icon"><sd-7-1-0-icon class="text-xl" name="pause" library="_internal"></sd-7-1-0-icon></slot>` : html`<slot name="play-icon"><sd-7-1-0-icon class="text-xl" name="play" library="_internal"></sd-7-1-0-icon></slot>`}</sd-7-1-0-button><div class="flex items-center gap-6 justify-self-end">${this.hasSlotController.test("transcript") ? html`<button class="${cx("w-6 h-6 hover:cursor-pointer sd-interactive", this.inverted && "sd-interactive--inverted")}" aria-label="${this.isTranscriptOpen ? this.localize.term("transcriptIsOpen") : this.localize.term("openTranscript")}" @click="${this.showTranscript}" @keydown="${this.showTranscriptKeydown}" part="transcript"><sd-7-1-0-icon class="w-6 h-6" name="transcript" library="_internal"></sd-7-1-0-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-7-1-0-icon class="w-6 h-6" name="${this.isMuted ? "mute" : "volume"}" library="_internal"></sd-7-1-0-icon></button></div></div>`;
|
|
304
304
|
const renderTimestamps = html`<div class="${cx(
|
|
305
305
|
"w-full flex justify-between",
|
|
306
306
|
this.reversedLayout ? "mb-0.5" : "mt-0.5",
|
|
307
307
|
this.animated && this.reversedLayout && "absolute bottom-0 left-0 !mb-4"
|
|
308
308
|
)}" part="timestamps"><div class="${cx("current-time text-sm", this.inverted ? "text-primary-400" : "text-neutral-700")}">${this.currentTime}</div><div class="${cx("current-time text-sm", this.inverted ? "text-primary-400" : "text-neutral-700")}">${this.duration}</div></div>`;
|
|
309
|
-
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 -mb-2"></canvas>` : null} ${!this.hideTimestamps && this.animated && this.reversedLayout ? renderTimestamps : null}<sd-7-0-
|
|
309
|
+
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 -mb-2"></canvas>` : null} ${!this.hideTimestamps && this.animated && this.reversedLayout ? renderTimestamps : null}<sd-7-1-0-range part="progress-slider" tooltip="hidden" min="0" max="100" step="0.001" label="${this.localize.term("seekBar")}" @mousedown="${this.handleThumbGrab}" @touchstart="${this.handleThumbGrab}" @mouseup="${this.handleThumbRelease}" @touchend="${this.handleThumbRelease}" @sd-7-1-0-input="${this.handleAudioProgress}" @keydown="${this.handleAudioProgressKeydown}"></sd-7-1-0-range></div>${this.hasSlotController.test("transcript") ? html`<sd-7-1-0-drawer><slot name="transcript"></slot></sd-7-1-0-drawer>` : null} ${!this.hideTimestamps && (!this.animated || !this.reversedLayout) ? renderTimestamps : null}</div><sd-7-1-0-theme-listener></sd-7-1-0-theme-listener>`;
|
|
310
310
|
}
|
|
311
311
|
};
|
|
312
312
|
SdAudio.styles = [
|
|
313
313
|
...SolidElement.styles,
|
|
314
314
|
css`/*! tailwindcss v4.3.2 | MIT License | https://tailwindcss.com */@layer theme,base,components,utilities;
|
|
315
|
-
sd-7-0-
|
|
315
|
+
sd-7-1-0-button::part(base){display:flex;height:var(--sd-spacing-12,3rem);width:var(--sd-spacing-12,3rem);align-items:center;justify-content:center;border-radius:var(--sd-radius-full,624.9375rem)}sd-7-1-0-button::part(motion-wrapper){border-radius:var(--sd-radius-full,624.9375rem)}sd-7-1-0-button::part(label){display:flex;flex-grow:0;align-items:center}sd-7-1-0-range::part(form-control-label){display:none}:host([inverted]) sd-7-1-0-range::part(thumb){outline-color:rgba(var(--sd-color-border-white,var(--sd-color-white,255 255 255)));background-color:rgba(var(--sd-color-icon-fill-white,rgba(var(--sd-color-white))))}:host([animated]) sd-7-1-0-range::part(track){background-color:transparent}:host([inverted]:not([animated])) sd-7-1-0-range::part(track){background-color:rgba(var(--sd-audio__slide-bar--inverted-color-background,rgba(var(--sd-color-primary-400))))}:host([inverted]:not([animated])) sd-7-1-0-range::part(active-track){background-color:rgba(var(--sd-audio__track-bar--inverted-color-background,rgba(var(--sd-color-white))))}`
|
|
316
316
|
];
|
|
317
317
|
__decorateClass([
|
|
318
318
|
property({ type: Boolean, reflect: true, attribute: "reversed-layout" })
|
|
@@ -354,13 +354,13 @@ __decorateClass([
|
|
|
354
354
|
query('[part="audio-player"]')
|
|
355
355
|
], SdAudio.prototype, "audioPlayerContainer", 2);
|
|
356
356
|
__decorateClass([
|
|
357
|
-
query("sd-7-0-
|
|
357
|
+
query("sd-7-1-0-drawer")
|
|
358
358
|
], SdAudio.prototype, "drawer", 2);
|
|
359
359
|
__decorateClass([
|
|
360
360
|
query("canvas")
|
|
361
361
|
], SdAudio.prototype, "canvas", 2);
|
|
362
362
|
SdAudio = __decorateClass([
|
|
363
|
-
customElement("sd-7-0-
|
|
363
|
+
customElement("sd-7-1-0-audio")
|
|
364
364
|
], SdAudio);
|
|
365
365
|
|
|
366
366
|
export {
|
|
@@ -163,76 +163,76 @@ var SdButton = class extends SolidElement {
|
|
|
163
163
|
const hasBorder = this.variant === "secondary";
|
|
164
164
|
const variantBackgroundColors = {
|
|
165
165
|
primary: this.inverted ? {
|
|
166
|
-
motionBackground: "sd-7-0-
|
|
167
|
-
baseBackground: "hover:sd-7-0-
|
|
166
|
+
motionBackground: "sd-7-1-0-button--primary--inverted--hover-color-background group-active:sd-7-1-0-button--primary--inverted--active-color-background",
|
|
167
|
+
baseBackground: "hover:sd-7-1-0-button--primary--inverted--hover-color-background active:sd-7-1-0-button--primary--inverted--active-color-background"
|
|
168
168
|
} : {
|
|
169
|
-
motionBackground: "sd-7-0-
|
|
170
|
-
baseBackground: "hover:sd-7-0-
|
|
169
|
+
motionBackground: "sd-7-1-0-button--primary--hover-color-background group-active:sd-7-1-0-button--primary--active-color-background",
|
|
170
|
+
baseBackground: "hover:sd-7-1-0-button--primary--hover-color-background active:sd-7-1-0-button--primary--active-color-background"
|
|
171
171
|
},
|
|
172
172
|
secondary: this.inverted ? {
|
|
173
|
-
motionBackground: "sd-7-0-
|
|
174
|
-
baseBackground: "hover:sd-7-0-
|
|
173
|
+
motionBackground: "sd-7-1-0-button--secondary--inverted--hover-color-background group-active:sd-7-1-0-button--secondary--inverted--active-color-background group-active:sd-7-1-0-button--secondary--inverted--active-color-text",
|
|
174
|
+
baseBackground: "hover:sd-7-1-0-button--secondary--inverted--hover-color-background active:sd-7-1-0-button--secondary--inverted--active-color-background"
|
|
175
175
|
} : {
|
|
176
|
-
motionBackground: "sd-7-0-
|
|
177
|
-
baseBackground: "hover:sd-7-0-
|
|
176
|
+
motionBackground: "sd-7-1-0-button--secondary--hover-color-background group-active:sd-7-1-0-button--secondary--active-color-background",
|
|
177
|
+
baseBackground: "hover:sd-7-1-0-button--secondary--hover-color-background active:sd-7-1-0-button--secondary--active-color-background"
|
|
178
178
|
},
|
|
179
179
|
tertiary: this.inverted ? {
|
|
180
|
-
motionBackground: "sd-7-0-
|
|
181
|
-
baseBackground: "hover:sd-7-0-
|
|
180
|
+
motionBackground: "sd-7-1-0-button--tertiary--inverted--hover-color-background group-active:sd-7-1-0-button--tertiary--inverted--active-color-background group-active:sd-7-1-0-button--tertiary--inverted--active-color-text",
|
|
181
|
+
baseBackground: "hover:sd-7-1-0-button--tertiary--inverted--hover-color-background active:sd-7-1-0-button--tertiary--inverted--active-color-background"
|
|
182
182
|
} : {
|
|
183
|
-
motionBackground: "sd-7-0-
|
|
184
|
-
baseBackground: "hover:sd-7-0-
|
|
183
|
+
motionBackground: "sd-7-1-0-button--tertiary--hover-color-background group-active:sd-7-1-0-button--tertiary--active-color-background",
|
|
184
|
+
baseBackground: "hover:sd-7-1-0-button--tertiary--hover-color-background active:sd-7-1-0-button--tertiary--active-color-background"
|
|
185
185
|
},
|
|
186
186
|
cta: this.inverted ? {
|
|
187
|
-
motionBackground: "sd-7-0-
|
|
188
|
-
baseBackground: "hover:sd-7-0-
|
|
187
|
+
motionBackground: "sd-7-1-0-button--cta--inverted--hover-color-background group-active:sd-7-1-0-button--cta--inverted--active-color-background",
|
|
188
|
+
baseBackground: "hover:sd-7-1-0-button--cta--inverted--hover-color-background active:sd-7-1-0-button--cta--inverted--active-color-background"
|
|
189
189
|
} : {
|
|
190
190
|
motionBackground: "bg-accent-500 group-active:bg-accent-700",
|
|
191
191
|
baseBackground: "hover:bg-accent-500 active:bg-accent-700"
|
|
192
192
|
}
|
|
193
193
|
}[this.variant];
|
|
194
|
-
return html`<sd-7-0-
|
|
194
|
+
return html`<sd-7-1-0-theme-listener></sd-7-1-0-theme-listener><${tag} part="base" class="${cx(
|
|
195
195
|
`group relative z-10 font-md no-underline
|
|
196
196
|
w-full align-middle inline-flex items-stretch justify-center
|
|
197
197
|
transition-colors duration-fast ease-in-out
|
|
198
198
|
select-none cursor-[inherit]`,
|
|
199
|
-
!this.hasUiMotion && "sd-7-0-
|
|
199
|
+
!this.hasUiMotion && "sd-7-1-0-button--simple-motion",
|
|
200
200
|
!this.inverted ? "focus-visible:focus-outline" : "focus-visible:focus-outline-inverted",
|
|
201
201
|
this.loading && "relative cursor-wait",
|
|
202
202
|
(this.disabled || this.visuallyDisabled) && "cursor-not-allowed",
|
|
203
203
|
{
|
|
204
204
|
/* sizes, fonts */
|
|
205
|
-
sm: `varspacing-8 min-h-8 sd-7-0-
|
|
206
|
-
md: `varspacing-10 sd-7-0-
|
|
207
|
-
lg: `varspacing-12 sd-7-0-
|
|
205
|
+
sm: `varspacing-8 min-h-8 sd-7-1-0-button--size-sm-font-size sd-7-1-0-button-font-weight sd-7-1-0-button--secondary--size-sm-padding-block sd-7-1-0-button-border-radius`,
|
|
206
|
+
md: `varspacing-10 sd-7-1-0-button--size-md-height sd-7-1-0-button--size-md-font-size sd-7-1-0-button--secondary--size-md-padding-block sd-7-1-0-button-font-weight sd-7-1-0-button-border-radius`,
|
|
207
|
+
lg: `varspacing-12 sd-7-1-0-button--size-lg-height sd-7-1-0-button--size-lg-font-size sd-7-1-0-button--secondary--size-lg-padding-block sd-7-1-0-button-font-weight sd-7-1-0-button-border-radius`
|
|
208
208
|
}[this.size],
|
|
209
209
|
!slots["icon-only"] && {
|
|
210
210
|
/* sizes, fonts */
|
|
211
|
-
sm: `${hasBorder ? "sd-7-0-
|
|
212
|
-
md: `${hasBorder ? "sd-7-0-
|
|
213
|
-
lg: `${hasBorder ? "sd-7-0-
|
|
211
|
+
sm: `${hasBorder ? "sd-7-1-0-button--secondary-padding-inline" : "sd-7-1-0-button--size-sm-padding-block sd-7-1-0-button-padding-inline"}`,
|
|
212
|
+
md: `${hasBorder ? "sd-7-1-0-button--secondary-padding-inline" : "sd-7-1-0-button--size-md-padding-block sd-7-1-0-button-padding-inline"}`,
|
|
213
|
+
lg: `${hasBorder ? "sd-7-1-0-button--secondary-padding-inline" : "sd-7-1-0-button--size-lg-padding-block sd-7-1-0-button-padding-inline"}`
|
|
214
214
|
}[this.size],
|
|
215
215
|
/**
|
|
216
216
|
* Anatomy
|
|
217
217
|
* */
|
|
218
218
|
slots["icon-only"] && {
|
|
219
219
|
sm: "px-1 aspect-square",
|
|
220
|
-
md: "sd-7-0-
|
|
220
|
+
md: "sd-7-1-0-button--size-md--icon-only-padding-inline aspect-square",
|
|
221
221
|
lg: "px-[12px] aspect-square"
|
|
222
222
|
}[this.size],
|
|
223
223
|
{
|
|
224
224
|
/* variants */
|
|
225
|
-
primary: !this.inverted ? `${this.visuallyDisabled ? "sd-7-0-
|
|
226
|
-
disabled:sd-7-0-
|
|
227
|
-
disabled:sd-7-0-
|
|
228
|
-
secondary: !this.inverted ? `border sd-7-0-
|
|
229
|
-
disabled:sd-7-0-
|
|
230
|
-
disabled:sd-7-0-
|
|
231
|
-
tertiary: !this.inverted ? `border-transparent ${this.visuallyDisabled ? "sd-7-0-
|
|
232
|
-
disabled:sd-7-0-
|
|
233
|
-
disabled:sd-7-0-
|
|
234
|
-
cta: `${this.visuallyDisabled ? "sd-7-0-
|
|
235
|
-
${!this.inverted ? "text-white bg-accent disabled:sd-7-0-
|
|
225
|
+
primary: !this.inverted ? `${this.visuallyDisabled ? "sd-7-1-0-button--primary--disabled-color-background border-neutral-500 text-white" : "sd-7-1-0-button--primary--default-color-background border-transparent sd-7-1-0-button--primary--default-color-text hover:sd-7-1-0-button--primary--hover-color-text active:sd-7-1-0-button--primary--active-color-text"}
|
|
226
|
+
disabled:sd-7-1-0-button--primary--disabled-color-background disabled:text-white` : `${this.visuallyDisabled ? "sd-7-1-0-button--inverted--disabled-color-background text-white border-neutral-500" : "sd-7-1-0-button--primary--inverted--default-color-text sd-7-1-0-button--primary--inverted--default-color-background border-white hover:sd-7-1-0-button--primary--inverted--hover-color-text active:sd-7-1-0-button--primary--inverted--active-color-text"}
|
|
227
|
+
disabled:sd-7-1-0-button--inverted--disabled-color-background disabled:text-white`,
|
|
228
|
+
secondary: !this.inverted ? `border sd-7-1-0-button-border-width ${this.visuallyDisabled ? "sd-7-1-0-button--secondary--disabled-color-text sd-7-1-0-button--secondary--disabled-color-border" : "sd-7-1-0-button--secondary--default-color-text sd-7-1-0-button--secondary--default-color-border hover:sd-7-1-0-button--secondary--hover-color-text hover:sd-7-1-0-button--secondary--hover-color-border active:sd-7-1-0-button--secondary--active-color-text active:sd-7-1-0-button--secondary--active-color-border"}
|
|
229
|
+
disabled:sd-7-1-0-button--secondary--disabled-color-text disabled:sd-7-1-0-button--secondary--disabled-color-border` : `border sd-7-1-0-button-border-width ${this.visuallyDisabled ? "text-neutral-600 border-neutral-600" : "sd-7-1-0-button--secondary--inverted-color-text sd-7-1-0-button--secondary--inverted-color-border hover:sd-7-1-0-button--secondary--inverted-color-border hover:sd-7-1-0-button--secondary--inverted--hover-color-text active:sd-7-1-0-button--secondary--inverted--active-color-text active:border-primary-200"}
|
|
230
|
+
disabled:sd-7-1-0-button--inverted--disabled-color-border disabled:sd-7-1-0-button--inverted--disabled-color-text`,
|
|
231
|
+
tertiary: !this.inverted ? `border-transparent ${this.visuallyDisabled ? "sd-7-1-0-button--tertiary--disabled-color-text" : "sd-7-1-0-button--tertiary--default-color-text hover:sd-7-1-0-button--tertiary--hover-color-text active:sd-7-1-0-button--tertiary--active-color-text"}
|
|
232
|
+
disabled:sd-7-1-0-button--tertiary--disabled-color-text` : `border-transparent ${this.visuallyDisabled ? "text-neutral-600" : "sd-7-1-0-button--tertiary--inverted-color-text hover:sd-7-1-0-button--tertiary--inverted--hover-color-text active:sd-7-1-0-button--tertiary--inverted--active-color-text"}
|
|
233
|
+
disabled:sd-7-1-0-button--inverted--disabled-color-text`,
|
|
234
|
+
cta: `${this.visuallyDisabled ? "sd-7-1-0-button--primary--disabled-color-background border-neutral-500" : "border-transparent"}
|
|
235
|
+
${!this.inverted ? "text-white bg-accent disabled:sd-7-1-0-button--primary--disabled-color-background disabled:border-neutral-500 disabled:text-white" : "sd-7-1-0-button--cta--inverted--default-color-background sd-7-1-0-button--cta--inverted--default-color-text hover:sd-7-1-0-button--cta--inverted--hover-color-text active:sd-7-1-0-button--cta--inverted--active-color-text disabled:sd-7-1-0-button--inverted--disabled-color-background disabled:text-white"}`
|
|
236
236
|
}[this.variant],
|
|
237
237
|
!this.hasUiMotion && !this.disabled && !this.visuallyDisabled && variantBackgroundColors.baseBackground
|
|
238
238
|
)}" ?disabled="${ifDefined(isLink ? void 0 : this.disabled)}" type="${ifDefined(isLink ? void 0 : this.type)}" title="${this.title}" name="${ifDefined(isLink ? void 0 : this.name)}" value="${ifDefined(isLink ? void 0 : this.value)}" href="${ifDefined(isLink ? this.href : void 0)}" target="${ifDefined(isLink ? this.target : void 0)}" download="${ifDefined(isLink ? this.download : void 0)}" rel="${ifDefined(isLink && this.target ? "noreferrer noopener" : void 0)}" role="${ifDefined(isLink ? void 0 : "button")}" aria-disabled="${this.disabled || this.visuallyDisabled ? "true" : "false"}" aria-labelledby="content" tabindex="${this.disabled ? "-1" : "0"}" @blur="${this.handleBlur}" @focus="${this.handleFocus}" @invalid="${this.isButton() ? this.handleInvalid : null}" @click="${this.handleClick}"><div part="motion-wrapper" class="${cx(
|
|
@@ -240,9 +240,9 @@ var SdButton = class extends SolidElement {
|
|
|
240
240
|
(!this.hasUiMotion || this.disabled || this.visuallyDisabled) && "hidden",
|
|
241
241
|
{
|
|
242
242
|
/* sizes, fonts */
|
|
243
|
-
sm: `sd-7-0-
|
|
244
|
-
md: `sd-7-0-
|
|
245
|
-
lg: `sd-7-0-
|
|
243
|
+
sm: `sd-7-1-0-button-border-radius`,
|
|
244
|
+
md: `sd-7-1-0-button-border-radius`,
|
|
245
|
+
lg: `sd-7-1-0-button-border-radius`
|
|
246
246
|
}[this.size]
|
|
247
247
|
)}"><div class="absolute inset-0 w-full h-full transition-all duration-fast translate-y-full group-hover:translate-y-0 group-hover:mt-[-22%] mt-[11%]"><div class="${cx(
|
|
248
248
|
"absolute right-0 min-w-full min-h-full aspect-square skew-y-[-11deg] mt-[11%]",
|
|
@@ -250,7 +250,7 @@ var SdButton = class extends SolidElement {
|
|
|
250
250
|
)}"></div><div class="${cx(
|
|
251
251
|
"absolute w-full h-full mt-[22%]",
|
|
252
252
|
variantBackgroundColors.motionBackground,
|
|
253
|
-
this.variant === "secondary" && this.inverted && "group-active:sd-7-0-
|
|
253
|
+
this.variant === "secondary" && this.inverted && "group-active:sd-7-1-0-button--secondary--active-color-border"
|
|
254
254
|
)}"></div></div></div><slot name="icon-left" part="icon-left" class="${cx(
|
|
255
255
|
"flex flex-auto items-center justify-end pointer-events-none",
|
|
256
256
|
slots["icon-only"] && "hidden",
|
|
@@ -278,7 +278,7 @@ var SdButton = class extends SolidElement {
|
|
|
278
278
|
md: "ml-2",
|
|
279
279
|
lg: "ml-2"
|
|
280
280
|
}[this.size]
|
|
281
|
-
)}"></slot>${this.loading ? html`<sd-7-0-
|
|
281
|
+
)}"></slot>${this.loading ? html`<sd-7-1-0-loader class="${cx("absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2")}"></sd-7-1-0-loader>` : ""}</${tag}>`;
|
|
282
282
|
}
|
|
283
283
|
};
|
|
284
284
|
/**
|
|
@@ -287,13 +287,13 @@ var SdButton = class extends SolidElement {
|
|
|
287
287
|
SdButton.styles = [
|
|
288
288
|
...SolidElement.styles,
|
|
289
289
|
css`/*! tailwindcss v4.3.2 | MIT License | https://tailwindcss.com */@layer properties;@layer theme,base,components,utilities;
|
|
290
|
-
:host{position:relative;z-index:0;display:inline-block;width:auto;cursor:pointer}.sd-7-0-
|
|
290
|
+
:host{position:relative;z-index:0;display:inline-block;width:auto;cursor:pointer}.sd-7-1-0-button--simple-motion{transition:background-color 150ms ease,color 150ms ease,border-color 150ms ease,box-shadow 150ms ease}::slotted(sd-7-1-0-badge){pointer-events:none;position:absolute;top:0;right:0;--tw-translate-x:calc(1 / 2 * 100%)!important;--tw-translate-y:calc(calc(1 / 2 * 100%) * -1)!important;translate:var(--tw-translate-x) var(--tw-translate-y)!important}::slotted(sd-7-1-0-icon),sd-7-1-0-loader{font-size:calc(var(--tw-varspacing)/ 2)}:host([size=lg]) ::slotted(sd-7-1-0-icon){font-size:var(--sd-button--size-lg-icon-height,var(--sd-spacing-6))}.sd-7-1-0-button-border-radius{border-radius:var(--sd-button-border-radius)}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}`
|
|
291
291
|
];
|
|
292
292
|
__decorateClass([
|
|
293
293
|
query("a, button")
|
|
294
294
|
], SdButton.prototype, "button", 2);
|
|
295
295
|
__decorateClass([
|
|
296
|
-
queryAssignedElements({ selector: "sd-7-0-
|
|
296
|
+
queryAssignedElements({ selector: "sd-7-1-0-icon" })
|
|
297
297
|
], SdButton.prototype, "_iconsInDefaultSlot", 2);
|
|
298
298
|
__decorateClass([
|
|
299
299
|
state()
|
|
@@ -362,7 +362,7 @@ __decorateClass([
|
|
|
362
362
|
watch("disabled", { waitUntilFirstUpdate: true })
|
|
363
363
|
], SdButton.prototype, "handleDisabledChange", 1);
|
|
364
364
|
SdButton = __decorateClass([
|
|
365
|
-
customElement("sd-7-0-
|
|
365
|
+
customElement("sd-7-1-0-button")
|
|
366
366
|
], SdButton);
|
|
367
367
|
|
|
368
368
|
export {
|