@scania/tegel 1.27.0 → 1.28.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/dist/cjs/index-ca8040ad.js +4 -4
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/tds-dropdown_2.cjs.entry.js +8 -8
- package/dist/cjs/tds-footer-group.cjs.entry.js +27 -5
- package/dist/cjs/tds-footer-item.cjs.entry.js +2 -2
- package/dist/cjs/tds-footer.cjs.entry.js +1 -1
- package/dist/cjs/tds-header-brand-symbol.cjs.entry.js +6 -2
- package/dist/cjs/tds-header-dropdown.cjs.entry.js +26 -3
- package/dist/cjs/tds-header-hamburger.cjs.entry.js +7 -1
- package/dist/cjs/tds-header-launcher-button.cjs.entry.js +2 -1
- package/dist/cjs/tds-header-launcher.cjs.entry.js +23 -2
- package/dist/cjs/tds-icon.cjs.entry.js +3 -2
- package/dist/cjs/tds-inline-tabs.cjs.entry.js +1 -1
- package/dist/cjs/tds-modal.cjs.entry.js +75 -3
- package/dist/cjs/tds-navigation-tabs.cjs.entry.js +1 -1
- package/dist/cjs/tds-popover-canvas.cjs.entry.js +3 -2
- package/dist/cjs/tds-popover-core.cjs.entry.js +55 -11
- package/dist/cjs/tds-popover-menu-item.cjs.entry.js +2 -2
- package/dist/cjs/tds-popover-menu.cjs.entry.js +1 -1
- package/dist/cjs/tds-radio-button.cjs.entry.js +3 -1
- package/dist/cjs/tds-spinner.cjs.entry.js +1 -1
- package/dist/cjs/tds-step.cjs.entry.js +2 -1
- package/dist/cjs/tds-stepper.cjs.entry.js +2 -1
- package/dist/cjs/tds-text-field.cjs.entry.js +31 -16
- package/dist/cjs/tds-textarea.cjs.entry.js +27 -9
- package/dist/cjs/tds-toast.cjs.entry.js +10 -3
- package/dist/cjs/tds-toggle.cjs.entry.js +2 -2
- package/dist/cjs/tds-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/tegel.cjs.js +1 -1
- package/dist/collection/components/dropdown/dropdown.js +8 -8
- package/dist/collection/components/footer/footer-group/footer-group.css +23 -21
- package/dist/collection/components/footer/footer-group/footer-group.js +55 -5
- package/dist/collection/components/footer/footer-item/footer-item.css +17 -17
- package/dist/collection/components/footer/footer-item/footer-item.js +2 -2
- package/dist/collection/components/footer/footer.css +1 -1
- package/dist/collection/components/header/header-brand-symbol/header-brand-symbol.css +1 -1
- package/dist/collection/components/header/header-brand-symbol/header-brand-symbol.js +6 -2
- package/dist/collection/components/header/header-dropdown/header-dropdown.js +49 -3
- package/dist/collection/components/header/header-hamburger/header-hamburger.js +30 -1
- package/dist/collection/components/header/header-launcher/header-launcher.js +50 -2
- package/dist/collection/components/header/header-launcher-button/header-launcher-button.js +19 -1
- package/dist/collection/components/icon/icon.js +21 -2
- package/dist/collection/components/modal/modal.css +48 -43
- package/dist/collection/components/modal/modal.js +103 -3
- package/dist/collection/components/popover-canvas/popover-canvas.js +21 -2
- package/dist/collection/components/popover-core/popover-core.js +63 -10
- package/dist/collection/components/popover-core/tds-popover-core.css +123 -66
- package/dist/collection/components/popover-menu/popover-menu-item/popover-menu-item.js +2 -2
- package/dist/collection/components/popover-menu/popover-menu.js +1 -1
- package/dist/collection/components/radio-button/radio-button.js +37 -1
- package/dist/collection/components/spinner/spinner.css +62 -39
- package/dist/collection/components/stepper/step/step.js +19 -1
- package/dist/collection/components/stepper/stepper.js +20 -1
- package/dist/collection/components/tabs/inline-tabs/inline-tabs.css +0 -1
- package/dist/collection/components/tabs/navigation-tabs/navigation-tabs.css +2 -3
- package/dist/collection/components/text-field/text-field.css +21 -9
- package/dist/collection/components/text-field/text-field.js +48 -15
- package/dist/collection/components/textarea/textarea.css +11 -6
- package/dist/collection/components/textarea/textarea.js +61 -8
- package/dist/collection/components/toast/toast.js +45 -3
- package/dist/collection/components/toggle/toggle.js +2 -2
- package/dist/collection/components/tooltip/tooltip.js +2 -2
- package/dist/components/{p-2d93a742.js → p-1c606f82.js} +1 -1
- package/dist/components/p-252f3d4d.js +2098 -0
- package/dist/components/p-3dcfe1f4.js +115 -0
- package/dist/components/{p-53e4cdcf.js → p-789bb453.js} +5 -3
- package/dist/components/{p-4487c541.js → p-92fb75a7.js} +4 -2
- package/dist/components/{p-663b8e51.js → p-c0b84c59.js} +9 -9
- package/dist/components/{p-83db8b35.js → p-f8a36676.js} +5 -3
- package/dist/components/tds-accordion-item.js +1 -1
- package/dist/components/tds-banner.js +1 -1
- package/dist/components/tds-datetime.js +1 -1
- package/dist/components/tds-dropdown-option.js +1 -1
- package/dist/components/tds-dropdown.js +1 -1
- package/dist/components/tds-folder-tabs.js +1 -1
- package/dist/components/tds-footer-group.js +32 -8
- package/dist/components/tds-footer-item.js +3 -3
- package/dist/components/tds-footer.js +1 -1
- package/dist/components/tds-header-brand-symbol.js +6 -2
- package/dist/components/tds-header-cell.js +1 -1
- package/dist/components/tds-header-dropdown.js +31 -7
- package/dist/components/tds-header-hamburger.js +11 -3
- package/dist/components/tds-header-launcher-button.js +1 -1
- package/dist/components/tds-header-launcher.js +29 -7
- package/dist/components/tds-icon.js +1 -1
- package/dist/components/tds-inline-tabs.js +2 -2
- package/dist/components/tds-message.js +1 -1
- package/dist/components/tds-modal.js +79 -5
- package/dist/components/tds-navigation-tabs.js +2 -2
- package/dist/components/tds-popover-canvas.js +1 -1
- package/dist/components/tds-popover-core.js +1 -1
- package/dist/components/tds-popover-menu-item.js +2 -2
- package/dist/components/tds-popover-menu.js +2 -2
- package/dist/components/tds-radio-button.js +6 -2
- package/dist/components/tds-side-menu-close-button.js +1 -1
- package/dist/components/tds-side-menu-dropdown.js +1 -1
- package/dist/components/tds-slider.js +1 -1
- package/dist/components/tds-spinner.js +1 -1
- package/dist/components/tds-step.js +4 -2
- package/dist/components/tds-stepper.js +4 -2
- package/dist/components/tds-table-body-input-wrapper.js +1 -1
- package/dist/components/tds-table-footer.js +3 -3
- package/dist/components/tds-table-header-input-wrapper.js +1 -1
- package/dist/components/tds-table-toolbar.js +1 -1
- package/dist/components/tds-text-field.js +33 -17
- package/dist/components/tds-textarea.js +43 -11
- package/dist/components/tds-toast.js +13 -4
- package/dist/components/tds-toggle.js +2 -2
- package/dist/components/tds-tooltip.js +1 -113
- package/dist/esm/index-51d04e39.js +4 -4
- package/dist/esm/loader.js +1 -1
- package/dist/esm/tds-dropdown_2.entry.js +8 -8
- package/dist/esm/tds-footer-group.entry.js +27 -5
- package/dist/esm/tds-footer-item.entry.js +3 -3
- package/dist/esm/tds-footer.entry.js +1 -1
- package/dist/esm/tds-header-brand-symbol.entry.js +6 -2
- package/dist/esm/tds-header-dropdown.entry.js +26 -3
- package/dist/esm/tds-header-hamburger.entry.js +7 -1
- package/dist/esm/tds-header-launcher-button.entry.js +2 -1
- package/dist/esm/tds-header-launcher.entry.js +23 -2
- package/dist/esm/tds-icon.entry.js +3 -2
- package/dist/esm/tds-inline-tabs.entry.js +1 -1
- package/dist/esm/tds-modal.entry.js +75 -3
- package/dist/esm/tds-navigation-tabs.entry.js +1 -1
- package/dist/esm/tds-popover-canvas.entry.js +3 -2
- package/dist/esm/tds-popover-core.entry.js +55 -11
- package/dist/esm/tds-popover-menu-item.entry.js +2 -2
- package/dist/esm/tds-popover-menu.entry.js +1 -1
- package/dist/esm/tds-radio-button.entry.js +3 -1
- package/dist/esm/tds-spinner.entry.js +1 -1
- package/dist/esm/tds-step.entry.js +2 -1
- package/dist/esm/tds-stepper.entry.js +2 -1
- package/dist/esm/tds-text-field.entry.js +31 -16
- package/dist/esm/tds-textarea.entry.js +27 -9
- package/dist/esm/tds-toast.entry.js +10 -3
- package/dist/esm/tds-toggle.entry.js +2 -2
- package/dist/esm/tds-tooltip.entry.js +2 -2
- package/dist/esm/tegel.js +1 -1
- package/dist/tegel/p-033d991e.entry.js +1 -0
- package/dist/tegel/p-24db6b5b.entry.js +1 -0
- package/dist/tegel/p-27a4a7d0.entry.js +1 -0
- package/dist/tegel/p-28cf7204.entry.js +1 -0
- package/dist/tegel/p-302fea99.entry.js +1 -0
- package/dist/tegel/p-31bc440c.entry.js +1 -0
- package/dist/tegel/p-3e9ca19a.entry.js +1 -0
- package/dist/tegel/p-44ac6a20.entry.js +1 -0
- package/dist/tegel/{p-769d0503.entry.js → p-46205cfb.entry.js} +1 -1
- package/dist/tegel/p-54a20280.entry.js +1 -0
- package/dist/tegel/p-5a3ff0d3.entry.js +1 -0
- package/dist/tegel/p-660176d6.entry.js +1 -0
- package/dist/tegel/{p-eaa279dd.entry.js → p-81111221.entry.js} +1 -1
- package/dist/tegel/{p-668b7662.entry.js → p-8d7bf652.entry.js} +1 -1
- package/dist/tegel/p-b58f68f0.entry.js +1 -0
- package/dist/tegel/{p-5ba254ee.entry.js → p-c10be10e.entry.js} +1 -1
- package/dist/tegel/p-c71acb02.entry.js +1 -0
- package/dist/tegel/p-ceab8f75.entry.js +1 -0
- package/dist/tegel/p-e1abd593.entry.js +1 -0
- package/dist/tegel/p-e3c3bdac.entry.js +1 -0
- package/dist/tegel/p-e46744bc.entry.js +1 -0
- package/dist/tegel/p-ea9e7345.entry.js +1 -0
- package/dist/tegel/{p-97f10223.entry.js → p-eec22b6b.entry.js} +1 -1
- package/dist/tegel/p-f034fc0c.entry.js +1 -0
- package/dist/tegel/p-fa342278.entry.js +1 -0
- package/dist/tegel/{p-b9f81e53.entry.js → p-fc6196c4.entry.js} +1 -1
- package/dist/tegel/tegel.css +4 -4
- package/dist/tegel/tegel.esm.js +1 -1
- package/dist/types/components/footer/footer-group/footer-group.d.ts +7 -0
- package/dist/types/components/header/header-brand-symbol/header-brand-symbol.d.ts +1 -1
- package/dist/types/components/header/header-dropdown/header-dropdown.d.ts +4 -0
- package/dist/types/components/header/header-hamburger/header-hamburger.d.ts +3 -0
- package/dist/types/components/header/header-launcher/header-launcher.d.ts +4 -0
- package/dist/types/components/header/header-launcher-button/header-launcher-button.d.ts +2 -0
- package/dist/types/components/icon/icon.d.ts +2 -0
- package/dist/types/components/modal/modal.d.ts +6 -0
- package/dist/types/components/popover-canvas/popover-canvas.d.ts +2 -0
- package/dist/types/components/popover-core/popover-core.d.ts +4 -0
- package/dist/types/components/radio-button/radio-button.d.ts +4 -0
- package/dist/types/components/stepper/step/step.d.ts +1 -0
- package/dist/types/components/stepper/stepper.d.ts +2 -0
- package/dist/types/components/text-field/text-field.d.ts +6 -4
- package/dist/types/components/textarea/textarea.d.ts +10 -4
- package/dist/types/components/toast/toast.d.ts +5 -0
- package/dist/types/components.d.ts +130 -0
- package/package.json +1 -1
- package/dist/components/p-90dbeab3.js +0 -2052
- package/dist/tegel/p-035e58e6.entry.js +0 -1
- package/dist/tegel/p-22c592eb.entry.js +0 -1
- package/dist/tegel/p-288a09ef.entry.js +0 -1
- package/dist/tegel/p-4f5f152a.entry.js +0 -1
- package/dist/tegel/p-542d7b3e.entry.js +0 -1
- package/dist/tegel/p-5a7110b8.entry.js +0 -1
- package/dist/tegel/p-5db5c8f4.entry.js +0 -1
- package/dist/tegel/p-654785d2.entry.js +0 -1
- package/dist/tegel/p-66f394a2.entry.js +0 -1
- package/dist/tegel/p-727f873f.entry.js +0 -1
- package/dist/tegel/p-746e2927.entry.js +0 -1
- package/dist/tegel/p-754a4921.entry.js +0 -1
- package/dist/tegel/p-aef6b130.entry.js +0 -1
- package/dist/tegel/p-b114ec3d.entry.js +0 -1
- package/dist/tegel/p-b39ffad4.entry.js +0 -1
- package/dist/tegel/p-b686f1ad.entry.js +0 -1
- package/dist/tegel/p-c56be8d1.entry.js +0 -1
- package/dist/tegel/p-dfbbaefd.entry.js +0 -1
- package/dist/tegel/p-ea3e071f.entry.js +0 -1
- package/dist/tegel/p-ee7f07ae.entry.js +0 -1
|
@@ -15,6 +15,7 @@ const TdsStepper$1 = /*@__PURE__*/ proxyCustomElement(class TdsStepper extends H
|
|
|
15
15
|
this.size = 'lg';
|
|
16
16
|
this.hideLabels = false;
|
|
17
17
|
this.stepperId = generateUniqueId();
|
|
18
|
+
this.ariaLabel = 'Progress steps';
|
|
18
19
|
}
|
|
19
20
|
componentWillLoad() {
|
|
20
21
|
if (this.orientation === 'vertical') {
|
|
@@ -50,7 +51,7 @@ const TdsStepper$1 = /*@__PURE__*/ proxyCustomElement(class TdsStepper extends H
|
|
|
50
51
|
});
|
|
51
52
|
}
|
|
52
53
|
render() {
|
|
53
|
-
return (h(Host, { key: '
|
|
54
|
+
return (h(Host, { key: '25173326e603e33e1ecf1d3277a2eaae4a62b064' }, h("div", { key: 'ba9a309a916b8ae5ccfb3dfe51a6192eb4b86565', role: "list", "aria-label": this.ariaLabel, class: `${this.orientation} text-position-${this.labelPosition} ${this.size}` }, h("slot", { key: '3fdbd771ab23620fec9d062228aefd2d289358ed' }))));
|
|
54
55
|
}
|
|
55
56
|
get host() { return this; }
|
|
56
57
|
static get watchers() { return {
|
|
@@ -65,7 +66,8 @@ const TdsStepper$1 = /*@__PURE__*/ proxyCustomElement(class TdsStepper extends H
|
|
|
65
66
|
"labelPosition": [1, "label-position"],
|
|
66
67
|
"size": [1],
|
|
67
68
|
"hideLabels": [4, "hide-labels"],
|
|
68
|
-
"stepperId": [1, "stepper-id"]
|
|
69
|
+
"stepperId": [1, "stepper-id"],
|
|
70
|
+
"ariaLabel": [1, "aria-label"]
|
|
69
71
|
}, undefined, {
|
|
70
72
|
"orientation": ["handleDirectionChange"],
|
|
71
73
|
"labelPosition": ["handleLabelPositionChange"],
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, h, c as Host } from './p-28ef5186.js';
|
|
2
|
-
import { d as defineCustomElement$2 } from './p-
|
|
2
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
3
3
|
|
|
4
4
|
const tableBodyInputWrapperCss = ":host{position:relative}:host(.focused-input-wrapper) tds-icon{display:inline-block}:host(.show-icon) ::slotted(input){padding-right:var(--tds-spacing-element-24)}:host(:hover) tds-icon{display:inline-block}:host(:hover) ::slotted(input:not(:focus)){background-color:var(--tds-table-input-background-hover)}tds-icon.edit-icon{display:none;position:absolute;right:10px;top:1px;pointer-events:none;cursor:pointer}::slotted(input){box-sizing:border-box;font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding-left:var(--tds-spacing-element-16);padding-right:var(--tds-spacing-element-16);color:var(--tds-table-color);background-color:transparent;height:48px;border-radius:0;border:0;border-bottom:2px solid transparent;width:100%;cursor:pointer}::slotted(input)::placeholder{color:var(--tds-table-color)}::slotted(input:disabled){background-color:var(--tds-table-input-background-disabled)}::slotted(input:focus){outline:none;background-color:var(--tds-table-input-background-focus);border-bottom:2px solid var(--tds-text-field-bar)}:host(.tds-table__compact) ::slotted(input){height:32px;}";
|
|
5
5
|
const TdsTableBodyInputWrapperStyle0 = tableBodyInputWrapperCss;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, d as createEvent, h, c as Host } from './p-28ef5186.js';
|
|
2
2
|
import { d as defineCustomElement$5 } from './p-14ab9663.js';
|
|
3
|
-
import { d as defineCustomElement$4 } from './p-
|
|
4
|
-
import { d as defineCustomElement$3 } from './p-
|
|
5
|
-
import { d as defineCustomElement$2 } from './p-
|
|
3
|
+
import { d as defineCustomElement$4 } from './p-c0b84c59.js';
|
|
4
|
+
import { d as defineCustomElement$3 } from './p-1c606f82.js';
|
|
5
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
6
6
|
|
|
7
7
|
const tableFooterCss = ":host{box-sizing:border-box;display:table-footer-group;height:var(--tds-spacing-element-48)}:host *{box-sizing:border-box}:host .tds-table__footer-row{background-color:var(--tds-table-footer-background);color:var(--tds-table-color)}:host .tds-table__footer-cell{padding:0 var(--tds-spacing-element-16)}:host .tds-table__footer-cell .tds-table__pagination{height:var(--tds-spacing-element-48);display:flex;align-items:center;justify-content:space-between}:host .tds-table__footer-cell .tds-table__pagination .tds-table__row-selector,:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector{display:flex;align-items:center}:host .tds-table__footer-cell .tds-table__pagination .tds-table__row-selector .rows-per-page,:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector .rows-per-page{display:flex;align-items:center;margin-right:var(--tds-spacing-element-16)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__row-selector .rows-per-page p,:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector .rows-per-page p{margin-right:var(--tds-spacing-element-8)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector-input{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);background-color:var(--tds-table-footer-page-selector-input-background);color:var(--tds-table-color);width:74px;height:30px;border:none;border-radius:var(--tds-spacing-element-4);transition:background-color 250ms ease;margin-right:var(--tds-spacing-element-4);padding-left:var(--tds-spacing-element-16)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector-input:hover{background-color:var(--tds-table-footer-page-selector-input-background-hover)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector-input:disabled{color:var(--tds-table-footer-page-selector-input-color-disabled)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector-input--shake{animation:tds-shake-animation 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;transform:translate3d(0, 0, 0);backface-visibility:hidden;perspective:1000px}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-text{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:1px 8px 0 0}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn{display:flex;justify-content:center;align-items:center;border:none;background-color:transparent;cursor:pointer;height:var(--tds-spacing-element-32);width:var(--tds-spacing-element-32);border-radius:var(--tds-spacing-element-4);transition:background-color 250ms ease;color:var(--tds-table-footer-page-selector-icon)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn:hover{background-color:var(--tds-table-footer-btn-hover)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn:disabled{cursor:default;color:var(--tds-table-footer-page-selector-icon-disabled)}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn:disabled:hover{background-color:transparent}:host .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn-svg{height:var(--tds-spacing-element-20);width:var(--tds-spacing-element-20);fill:var(--tds-table-color)}:host(.tds-table--compact){height:var(--tds-spacing-element-32)}:host(.tds-table--compact) .tds-table__footer-cell .tds-table__pagination{height:var(--tds-spacing-element-32)}:host(.tds-table--compact) .tds-table__footer-cell .tds-table__pagination .tds-table__page-selector-input{height:var(--tds-spacing-element-24)}:host(.tds-table--compact) .tds-table__footer-cell .tds-table__pagination .tds-table__footer-btn{height:28px;width:28px}:host(.footer__horizontal-scroll){display:inline-table;position:absolute;margin-top:10px}@keyframes tds-shake-animation{10%,90%{transform:translate3d(-1px, 0, 0)}20%,80%{transform:translate3d(2px, 0, 0)}30%,50%,70%{transform:translate3d(-4px, 0, 0)}40%,60%{transform:translate3d(4px, 0, 0)}}tds-dropdown:focus-within::after{content:\"\";position:absolute;bottom:0;left:0;height:100%;width:100%;background-color:transparent;border-radius:var(--tds-spacing-element-4);pointer-events:none;outline:2px solid var(--tds-blue-400);outline-offset:-2px}";
|
|
8
8
|
const TdsTableFooterStyle0 = tableFooterCss;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, h, c as Host } from './p-28ef5186.js';
|
|
2
|
-
import { d as defineCustomElement$2 } from './p-
|
|
2
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
3
3
|
|
|
4
4
|
const tableHeaderInputWrapperCss = ":host{position:relative}:host(:hover) tds-icon{display:inline-block}:host(.focused-input-wrapper) tds-icon{display:inline-block}:host(.focused-input-wrapper) ::slotted(input:not(:focus)){background-color:var(--tds-table-input-background-hover)}:host(.show-icon) ::slotted(input){padding-left:35px}tds-icon.search-icon{color:var(--tds-table-input-header-icon);position:absolute;left:15px;top:1px}::slotted(input){box-sizing:border-box;font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);color:var(--tds-table-color);padding-left:var(--tds-spacing-element-16);padding-right:var(--tds-spacing-element-16);height:48px;border-radius:0;background-color:transparent;border:0;border-bottom:2px solid transparent}::slotted(input)::placeholder{color:var(--tds-table-input-header-placeholder)}::slotted(input:focus){outline:none;background-color:var(--tds-table-input-header-background-focus);border-bottom:2px solid var(--tds-text-field-bar)}:host(.tds-table__compact) ::slotted(input){height:32px;}";
|
|
5
5
|
const TdsTableHeaderInputWrapperStyle0 = tableHeaderInputWrapperCss;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, d as createEvent, h, c as Host } from './p-28ef5186.js';
|
|
2
|
-
import { d as defineCustomElement$2 } from './p-
|
|
2
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
3
3
|
|
|
4
4
|
const tableToolbarCss = ":host{box-sizing:border-box;display:table-caption;position:relative;background-color:var(--tds-table-toolbar-background);color:var(--tds-table-color);padding:0 var(--tds-spacing-element-16);height:64px;border-top-left-radius:4px;border-top-right-radius:4px}:host *{box-sizing:border-box}:host .tds-table__upper-bar-flex{width:100%;height:100%;display:flex;justify-content:space-between}:host .tds-table__title{font:var(--tds-headline-07);letter-spacing:var(--tds-headline-07-ls);padding-top:var(--tds-spacing-element-16);text-align:left}:host .tds-table__actionbar,:host slot[name=end]::slotted(*){display:flex;align-self:center}:host .tds-table__searchbar{display:flex;align-self:center;position:relative;height:40px;width:40px;border-radius:4px 4px 0 0;transition:background-color 250ms ease, width 250ms ease;overflow:hidden;background-color:transparent}:host .tds-table__searchbar::after{content:\"\";width:100%;height:2px;position:absolute;bottom:0;background-color:var(--tds-blue-400);transform:scaleX(0);transition:transform 150ms ease}:host .tds-table__searchbar:focus-within::after{transform:scaleX(100%)}:host .tds-table__searchbar:focus-within,:host .tds-table__searchbar.tds-table__searchbar--active{width:208px;background-color:var(--tds-table-toolbar-searchbar-background)}:host .tds-table__searchbar:focus-within:hover,:host .tds-table__searchbar.tds-table__searchbar--active:hover{background-color:var(--tds-table-toolbar-searchbar-background)}:host .tds-table__searchbar .tds-table__searchbar-input{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);color:var(--tds-table-color);z-index:1;width:100%;height:100%;border:none;padding:0 36px 0 16px;background-color:transparent;outline:none;cursor:pointer}:host .tds-table__searchbar .tds-table__searchbar-input :focus{background-color:var(--tds-table-toolbar-searchbar-background)}:host .tds-table__searchbar:hover{background-color:var(--tds-table-toolbar-searchbar-background-hover)}:host .tds-table__searchbar .tds-table__searchbar-icon{z-index:0;position:absolute;right:9px;top:9px;width:20px;height:20px}:host(.toolbar__horizontal-scroll){position:absolute;top:var(--tds-spacing-element-16)}:host(.tds-table--compact){height:56px}";
|
|
5
5
|
const TdsTableToolbarStyle0 = tableToolbarCss;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, d as createEvent, h } from './p-28ef5186.js';
|
|
2
2
|
import { h as hasSlot } from './p-ae110fc2.js';
|
|
3
|
-
import { d as defineCustomElement$2 } from './p-
|
|
3
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
4
4
|
|
|
5
|
-
const textFieldCss = ".text-field-input-lg.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-20) var(--tds-spacing-element-16)}.text-field-input-lg.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-lg.sc-tds-text-field:disabled{cursor:not-allowed;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-lg.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-lg.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-input-md.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-16)}.text-field-input-md.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-md.sc-tds-text-field:disabled{cursor:not-allowed;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-md.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-md.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-input-sm.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-16)}.text-field-input-sm.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-sm.sc-tds-text-field:disabled{cursor:not-allowed;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-sm.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-sm.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-container.sc-tds-text-field{border-radius:4px 4px 0 0;display:flex;position:relative;height:56px;box-sizing:border-box;background-color:var(--tds-text-field-background);border-bottom:1px solid var(--tds-text-field-border-bottom);transition:border-bottom-color 200ms ease}.text-field-container.sc-tds-text-field:hover{border-bottom-color:var(--tds-text-field-border-bottom-hover)}.form-text-field-md.sc-tds-text-field .text-field-container.sc-tds-text-field{height:48px}.form-text-field-sm.sc-tds-text-field .text-field-container.sc-tds-text-field{height:40px}.text-field-input-container.sc-tds-text-field{position:relative;width:100%}.text-field-data.sc-tds-text-field,.text-field-input.sc-tds-text-field{color:var(--tds-text-field-data-color)}.text-field-label-outside.sc-tds-text-field>*.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:block;margin-bottom:var(--tds-spacing-element-8);color:var(--tds-text-field-label-color)}.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);position:absolute;pointer-events:none;color:var(--tds-text-field-label-inside-color);left:16px}.form-text-field.sc-tds-text-field{display:block;min-width:208px}.form-text-field-nomin.sc-tds-text-field{min-width:auto}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field{padding-top:var(--tds-spacing-element-24);padding-bottom:15px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:20px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field{padding-top:var(--tds-spacing-element-20);padding-bottom:11px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:16px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field{padding-top:var(--tds-spacing-element-20);padding-bottom:11px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:16px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:8px}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:8px}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:12px}.text-field-bar.sc-tds-text-field{position:absolute;width:100%}.text-field-bar.sc-tds-text-field::before,.text-field-bar.sc-tds-text-field::after{content:\"\";height:2px;top:54px;width:0;position:absolute;background:var(--tds-text-field-bar);transition:0.35s ease all}.form-text-field-md.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.form-text-field-md.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{top:46px}.form-text-field-sm.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.form-text-field-sm.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{top:40px}.text-field-bar.sc-tds-text-field::before{left:50%}.text-field-bar.sc-tds-text-field::after{right:50%}.text-field-focus.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.text-field-focus.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{width:50%}.text-field-helper.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:flex;gap:8px;justify-content:space-between;flex-basis:100%;padding-top:var(--tds-spacing-element-4);color:var(--tds-text-field-helper)}.text-field-helper.sc-tds-text-field .text-field-textcounter.sc-tds-text-field{margin-left:auto}.form-text-field-disabled.sc-tds-text-field .text-field-container.sc-tds-text-field{border-bottom-color:transparent}.form-text-field-disabled.sc-tds-text-field .text-field-slot-wrap-prefix.sc-tds-text-field>*.sc-tds-text-field,.form-text-field-disabled.sc-tds-text-field .text-field-slot-wrap-suffix.sc-tds-text-field>*.sc-tds-text-field{color:var(--tds-text-field-ps-color-disabled)}.form-text-field-disabled.sc-tds-text-field .text-field-label-outside.sc-tds-text-field>*.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.form-text-field-disabled.sc-tds-text-field .text-field-helper.sc-tds-text-field{color:var(--tds-text-field-helper-disabled)}.text-field-icon__readonly.sc-tds-text-field{display:none;position:absolute;right:18px;top:50%;transform:translateY(-50%);color:var(--tds-text-field-icon-read-only-label-color)}.text-field-icon__readonly-label.sc-tds-text-field{display:none;position:absolute;right:18px;top:48px;font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);padding:8px;white-space:nowrap;border-radius:4px 0 4px 4px;background-color:var(--tds-text-field-icon-read-only-label-background)}.form-text-field-readonly.sc-tds-text-field{pointer-events:none}.form-text-field-readonly.sc-tds-text-field .text-field-icon__readonly.sc-tds-text-field{display:block}.form-text-field-readonly.sc-tds-text-field .text-field-icon__readonly.sc-tds-text-field:hover~.text-field-icon__readonly-label.sc-tds-text-field{display:block}.form-text-field-readonly.sc-tds-text-field .text-field-input.sc-tds-text-field{padding-right:54px;background-color:transparent}.form-text-field-success.sc-tds-text-field .text-field-container.sc-tds-text-field{border-bottom-color:var(--tds-text-field-border-bottom-success)}.form-text-field-error.sc-tds-text-field .text-field-helper.sc-tds-text-field{color:var(--tds-text-field-helper-error)}.form-text-field-error.sc-tds-text-field .text-field-container.sc-tds-text-field{border-bottom-color:var(--tds-text-field-border-bottom-error)}.form-text-field-error.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.form-text-field-error.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{background:var(--tds-text-field-bar-error)}.text-field-helper-error-state.sc-tds-text-field{display:flex;gap:8px;flex-wrap:nowrap}.text-field-textcounter-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-disabled)}.text-field-textcounter.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-text-field-textcounter);float:right}.text-field-textcounter.text-field-textcounter-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-disabled)}.text-field-textcounter.text-field-textcounter-divider.sc-tds-text-field{color:var(--tds-text-field-textcounter-divider)}.text-field-textcounter.text-field-textcounter-divider-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-divider-disabled)}.text-field-slot-wrap-prefix.sc-tds-text-field,.text-field-slot-wrap-suffix.sc-tds-text-field{align-self:center;font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);margin:0 0 0 14px;color:var(--tds-text-field-ps-color)}.text-field-slot-wrap-prefix.sc-tds-text-field-s>:not(tds-icon),.text-field-slot-wrap-suffix.sc-tds-text-field-s>:not(tds-icon){margin:0 0 0 2px}.text-field-slot-wrap-prefix.text-field-error.sc-tds-text-field,.text-field-slot-wrap-suffix.text-field-error.sc-tds-text-field{color:var(--tds-text-field-ps-color-error)}.text-field-slot-wrap-suffix.sc-tds-text-field{margin:0 14px 0 0}.text-field-slot-wrap-suffix.sc-tds-text-field-s>:not(tds-icon){margin:0 2px 0 0}";
|
|
5
|
+
const textFieldCss = ".text-field-input-lg.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-20) var(--tds-spacing-element-16)}.text-field-input-lg.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-lg.sc-tds-text-field:disabled{user-select:none;pointer-events:none;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-lg.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-lg.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-input-md.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-16)}.text-field-input-md.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-md.sc-tds-text-field:disabled{user-select:none;pointer-events:none;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-md.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-md.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-input-sm.sc-tds-text-field{all:unset;border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-text-field-color);background-color:var(--tds-text-field-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-16)}.text-field-input-sm.sc-tds-text-field::placeholder{color:var(--tds-text-field-placeholder)}.text-field-input-sm.sc-tds-text-field:disabled{user-select:none;pointer-events:none;background-color:var(--tds-text-field-background-disabled);color:var(--tds-text-field-color-disabled)}.text-field-input-sm.sc-tds-text-field:disabled::placeholder{color:var(--tds-text-field-placeholder-disabled)}.text-field-input-sm.sc-tds-text-field:disabled~.text-field-label-inside.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.text-field-container.sc-tds-text-field{border-radius:4px 4px 0 0;display:flex;position:relative;height:56px;box-sizing:border-box;background-color:var(--tds-text-field-background);border-bottom:1px solid var(--tds-text-field-border-bottom);transition:border-bottom-color 200ms ease}.text-field-container.sc-tds-text-field:hover{border-bottom-color:var(--tds-text-field-border-bottom-hover)}.form-text-field-md.sc-tds-text-field .text-field-container.sc-tds-text-field{height:48px}.form-text-field-sm.sc-tds-text-field .text-field-container.sc-tds-text-field{height:40px}.text-field-input-container.sc-tds-text-field{position:relative;width:100%}.text-field-data.sc-tds-text-field,.text-field-input.sc-tds-text-field{color:var(--tds-text-field-data-color)}.text-field-label-outside.sc-tds-text-field>*.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:block;margin-bottom:var(--tds-spacing-element-8);color:var(--tds-text-field-label-color)}.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);position:absolute;pointer-events:none;color:var(--tds-text-field-label-inside-color);left:16px}.form-text-field.sc-tds-text-field{display:block;min-width:208px}.form-text-field-nomin.sc-tds-text-field{min-width:auto}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field{padding-top:var(--tds-spacing-element-24);padding-bottom:15px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:20px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-lg.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field{padding-top:var(--tds-spacing-element-20);padding-bottom:11px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:16px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-md.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field{padding-top:var(--tds-spacing-element-20);padding-bottom:11px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{top:16px}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field .sc-tds-text-field::placeholder{color:transparent}.form-text-field.text-field-container-label-inside.sc-tds-text-field .text-field-input-sm.sc-tds-text-field:focus::placeholder{transition:color 0.35s ease;color:var(--tds-text-field-placeholder)}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-sm.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:8px}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-md.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:8px}.form-text-field.text-field-container-label-inside.text-field-focus.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field,.form-text-field.text-field-container-label-inside.text-field-data.sc-tds-text-field .text-field-input-lg.sc-tds-text-field~.text-field-label-inside.sc-tds-text-field{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);transition:0.1s ease all;top:12px}.text-field-bar.sc-tds-text-field{position:absolute;width:100%}.text-field-bar.sc-tds-text-field::before,.text-field-bar.sc-tds-text-field::after{content:\"\";height:2px;top:54px;width:0;position:absolute;background:var(--tds-text-field-bar);transition:0.35s ease all}.form-text-field-md.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.form-text-field-md.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{top:46px}.form-text-field-sm.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.form-text-field-sm.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{top:40px}.text-field-bar.sc-tds-text-field::before{left:50%}.text-field-bar.sc-tds-text-field::after{right:50%}.text-field-focus.sc-tds-text-field .text-field-bar.sc-tds-text-field::before,.text-field-focus.sc-tds-text-field .text-field-bar.sc-tds-text-field::after{width:50%}.text-field-helper.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:flex;gap:8px;justify-content:space-between;flex-basis:100%;padding-top:var(--tds-spacing-element-4);color:var(--tds-text-field-helper)}.text-field-helper.sc-tds-text-field .text-field-textcounter.sc-tds-text-field{margin-left:auto}.form-text-field-disabled.sc-tds-text-field .text-field-container.sc-tds-text-field{cursor:not-allowed;border-bottom-color:transparent}.form-text-field-disabled.sc-tds-text-field .text-field-slot-wrap-prefix.sc-tds-text-field>*.sc-tds-text-field,.form-text-field-disabled.sc-tds-text-field .text-field-slot-wrap-suffix.sc-tds-text-field>*.sc-tds-text-field{color:var(--tds-text-field-ps-color-disabled)}.form-text-field-disabled.sc-tds-text-field .text-field-label-outside.sc-tds-text-field>*.sc-tds-text-field{color:var(--tds-text-field-label-disabled)}.form-text-field-disabled.sc-tds-text-field .text-field-helper.sc-tds-text-field{color:var(--tds-text-field-helper-disabled)}.text-field-icon__readonly.sc-tds-text-field{display:none;position:absolute;right:18px;top:50%;transform:translateY(-50%);color:var(--tds-text-field-icon-read-only-label-color)}.text-field-icon__readonly-label.sc-tds-text-field{display:none;position:absolute;right:18px;top:48px;font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);padding:8px;white-space:nowrap;border-radius:4px 0 4px 4px;background-color:var(--tds-text-field-icon-read-only-label-background)}.form-text-field-readonly.sc-tds-text-field{user-select:auto;caret-color:transparent;cursor:default}.form-text-field-readonly.sc-tds-text-field .text-field-container.sc-tds-text-field{border-bottom-color:var(--tds-text-field-border-bottom-readonly)}.form-text-field-readonly.sc-tds-text-field .text-field-icon__readonly.sc-tds-text-field{display:block}.form-text-field-readonly.sc-tds-text-field .text-field-icon__readonly.sc-tds-text-field:hover~.text-field-icon__readonly-label.sc-tds-text-field{display:block}.form-text-field-readonly.sc-tds-text-field .text-field-input.sc-tds-text-field{background-color:transparent}.form-text-field-readonly.sc-tds-text-field:has(.text-field-icon__readonly) .text-field-input.sc-tds-text-field{padding-right:54px}.form-text-field-success.sc-tds-text-field:not(.form-text-field-readonly) .text-field-container.sc-tds-text-field{border-bottom-color:var(--tds-text-field-border-bottom-success)}.form-text-field-error.sc-tds-text-field:not(.form-text-field-readonly) .text-field-helper.sc-tds-text-field{color:var(--tds-text-field-helper-error)}.form-text-field-error.sc-tds-text-field:not(.form-text-field-readonly) .text-field-container.sc-tds-text-field{border-bottom-color:var(--tds-text-field-border-bottom-error)}.form-text-field-error.sc-tds-text-field:not(.form-text-field-readonly) .text-field-bar.sc-tds-text-field::before,.form-text-field-error.sc-tds-text-field:not(.form-text-field-readonly) .text-field-bar.sc-tds-text-field::after{background:var(--tds-text-field-bar-error)}.text-field-helper-error-state.sc-tds-text-field{display:flex;gap:8px;flex-wrap:nowrap}.text-field-textcounter-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-disabled)}.text-field-textcounter.sc-tds-text-field{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-text-field-textcounter);float:right}.text-field-textcounter.text-field-textcounter-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-disabled)}.text-field-textcounter.text-field-textcounter-divider.sc-tds-text-field{color:var(--tds-text-field-textcounter-divider)}.text-field-textcounter.text-field-textcounter-divider-disabled.sc-tds-text-field{color:var(--tds-text-field-textcounter-divider-disabled)}.text-field-slot-wrap-prefix.sc-tds-text-field,.text-field-slot-wrap-suffix.sc-tds-text-field{align-self:center;font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);margin:0 0 0 14px;color:var(--tds-text-field-ps-color)}.text-field-slot-wrap-prefix.sc-tds-text-field-s>:not(tds-icon),.text-field-slot-wrap-suffix.sc-tds-text-field-s>:not(tds-icon){margin:0 0 0 2px}.text-field-slot-wrap-prefix.text-field-error.sc-tds-text-field,.text-field-slot-wrap-suffix.text-field-error.sc-tds-text-field{color:var(--tds-text-field-ps-color-error)}.text-field-slot-wrap-suffix.sc-tds-text-field{margin:0 14px 0 0}.text-field-slot-wrap-suffix.sc-tds-text-field-s>:not(tds-icon){margin:0 2px 0 0}";
|
|
6
6
|
const TdsTextFieldStyle0 = textFieldCss;
|
|
7
7
|
|
|
8
8
|
const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField extends H {
|
|
@@ -23,6 +23,7 @@ const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField exten
|
|
|
23
23
|
this.value = '';
|
|
24
24
|
this.disabled = false;
|
|
25
25
|
this.readOnly = false;
|
|
26
|
+
this.hideReadOnlyIcon = false;
|
|
26
27
|
this.size = 'lg';
|
|
27
28
|
this.modeVariant = null;
|
|
28
29
|
this.noMinWidth = false;
|
|
@@ -31,14 +32,27 @@ const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField exten
|
|
|
31
32
|
this.maxLength = undefined;
|
|
32
33
|
this.autofocus = false;
|
|
33
34
|
this.tdsAriaLabel = undefined;
|
|
34
|
-
this.focusInput =
|
|
35
|
+
this.focusInput = false;
|
|
35
36
|
}
|
|
36
37
|
handleChange(event) {
|
|
37
38
|
this.tdsChange.emit(event);
|
|
38
39
|
}
|
|
39
40
|
// Data input event in value prop
|
|
40
41
|
handleInput(event) {
|
|
41
|
-
|
|
42
|
+
const inputEl = event.target;
|
|
43
|
+
let { value } = inputEl;
|
|
44
|
+
// Custom handling of number inputs when min/max are set
|
|
45
|
+
if (this.type === 'number') {
|
|
46
|
+
const numericValue = Number(value);
|
|
47
|
+
if (this.min !== undefined && numericValue < Number(this.min)) {
|
|
48
|
+
value = String(this.min);
|
|
49
|
+
}
|
|
50
|
+
if (this.max !== undefined && numericValue > Number(this.max)) {
|
|
51
|
+
value = String(this.max);
|
|
52
|
+
}
|
|
53
|
+
inputEl.value = value;
|
|
54
|
+
}
|
|
55
|
+
this.value = value;
|
|
42
56
|
this.tdsInput.emit(event);
|
|
43
57
|
}
|
|
44
58
|
/** Set the input as focus when clicking the whole Text Field with suffix/prefix */
|
|
@@ -67,33 +81,37 @@ const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField exten
|
|
|
67
81
|
var _a;
|
|
68
82
|
const usesPrefixSlot = hasSlot('prefix', this.host);
|
|
69
83
|
const usesSuffixSlot = hasSlot('suffix', this.host);
|
|
70
|
-
return (h("div", { key: '
|
|
84
|
+
return (h("div", { key: 'b15e2650ad5cb65cad16240834a569d89c787de6', class: {
|
|
71
85
|
'form-text-field': true,
|
|
72
86
|
'form-text-field-nomin': this.noMinWidth,
|
|
73
87
|
'text-field-focus': this.focusInput && !this.disabled,
|
|
74
88
|
'text-field-data': this.value !== '' && this.value !== null,
|
|
75
89
|
'text-field-container-label-inside': this.labelPosition === 'inside' && this.size !== 'sm',
|
|
76
90
|
'form-text-field-disabled': this.disabled,
|
|
77
|
-
'form-text-field-readonly': this.readOnly,
|
|
78
|
-
'tds-mode-variant-primary': this.
|
|
79
|
-
|
|
91
|
+
'form-text-field-readonly': this.disabled ? false : this.readOnly,
|
|
92
|
+
'tds-mode-variant-primary': this.readOnly
|
|
93
|
+
? this.modeVariant === 'secondary'
|
|
94
|
+
: this.modeVariant === 'primary',
|
|
95
|
+
'tds-mode-variant-secondary': this.readOnly
|
|
96
|
+
? this.modeVariant === 'primary'
|
|
97
|
+
: this.modeVariant === 'secondary',
|
|
80
98
|
'form-text-field-md': this.size === 'md',
|
|
81
99
|
'form-text-field-sm': this.size === 'sm',
|
|
82
100
|
'form-text-field-error': this.state === 'error',
|
|
83
101
|
'form-text-field-success': this.state === 'success',
|
|
84
|
-
} }, this.labelPosition === 'outside' && (h("div", { key: '
|
|
102
|
+
} }, this.labelPosition === 'outside' && (h("div", { key: 'a8d058d6e063cabf93cf859883b306bfeeb18319', class: "text-field-label-outside" }, h("label", { key: '6ee037a99fb88c38e1bbd967e74f609fcf4670dc', htmlFor: "text-field-input-element" }, this.label))), h("div", { key: 'e7e50a86f774f9d693a43690d75d381b3556124f', onClick: () => this.textInput.focus(), class: "text-field-container" }, usesPrefixSlot && (h("div", { key: '5f42f91a49235c9911f366920790942147eabefd', class: {
|
|
85
103
|
'text-field-slot-wrap-prefix': true,
|
|
86
104
|
'text-field-error': this.state === 'error',
|
|
87
105
|
'text-field-success': this.state === 'success',
|
|
88
106
|
'text-field-default': this.state === 'default',
|
|
89
|
-
} }, h("slot", { key: '
|
|
107
|
+
} }, h("slot", { key: 'a6093bd26cde5c76a1362b260aa44e6b4bf1aed5', name: "prefix" }))), h("div", { key: 'ae0ab4730cdede21de1accab8ed74440ec7084ae', class: "text-field-input-container" }, h("input", { key: '4a96bf3b95969d3a7c6e00487d36d3b0fbc720cc', ref: (inputEl) => {
|
|
90
108
|
this.textInput = inputEl;
|
|
91
109
|
}, class: {
|
|
92
110
|
'text-field-input': true,
|
|
93
111
|
'text-field-input-sm': this.size === 'sm',
|
|
94
112
|
'text-field-input-md': this.size === 'md',
|
|
95
113
|
'text-field-input-lg': this.size === 'lg',
|
|
96
|
-
}, type: this.type, disabled: this.disabled, readonly: this.readOnly, placeholder: this.placeholder, value: this.value, autofocus: this.autofocus, maxlength: this.maxLength, name: this.name, min: this.min, max: this.max, onInput: (event) => this.handleInput(event), onChange: (event) => this.handleChange(event), onFocus: (event) => {
|
|
114
|
+
}, type: this.type, disabled: this.disabled, readonly: this.disabled ? false : this.readOnly, placeholder: this.placeholder, value: this.value, autofocus: this.autofocus, maxlength: this.maxLength, name: this.name, min: this.min, max: this.max, onInput: (event) => this.handleInput(event), onChange: (event) => this.handleChange(event), onFocus: (event) => {
|
|
97
115
|
if (!this.readOnly) {
|
|
98
116
|
this.handleFocus(event);
|
|
99
117
|
}
|
|
@@ -101,19 +119,16 @@ const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField exten
|
|
|
101
119
|
if (!this.readOnly) {
|
|
102
120
|
this.handleBlur(event);
|
|
103
121
|
}
|
|
104
|
-
}, "aria-label": this.tdsAriaLabel ? this.tdsAriaLabel : this.label, "aria-describedby": "text-field-helper-element", "aria-readonly": this.readOnly, id: "text-field-input-element" }), this.labelPosition === 'inside' && this.size !== 'sm' && (h("label", { key: '
|
|
122
|
+
}, "aria-label": this.tdsAriaLabel ? this.tdsAriaLabel : this.label, "aria-describedby": "text-field-helper-element", "aria-readonly": this.readOnly, id: "text-field-input-element" }), this.labelPosition === 'inside' && this.size !== 'sm' && (h("label", { key: 'e9501e5e9af625a6efaca69b6d880a6063d9e1e3', class: "text-field-label-inside", htmlFor: "text-field-input-element" }, this.label))), h("div", { key: 'fed042784d9f96ffb658aaa7f83562fc4b696662', class: "text-field-bar" }), usesSuffixSlot && (h("div", { key: 'c66e08a4c15b09a3e340ffc1f249b49dae370a9f', class: {
|
|
105
123
|
'text-field-slot-wrap-suffix': true,
|
|
106
124
|
'text-field-error': this.state === 'error',
|
|
107
125
|
'text-field-success': this.state === 'success',
|
|
108
126
|
'text-field-default': this.state === 'default',
|
|
109
127
|
'tds-u-display-none': this.readOnly,
|
|
110
|
-
} }, h("slot", { key: '
|
|
111
|
-
'text-field-textcounter': true,
|
|
112
|
-
'text-field-textcounter-disabled': this.disabled,
|
|
113
|
-
} }, this.value === null ? 0 : (_a = this.value) === null || _a === void 0 ? void 0 : _a.length, h("span", { key: '744acd41ca6d968ee5dab7bd50ca52f5704b21dc', class: {
|
|
128
|
+
} }, h("slot", { key: '7caa1d97bcf8af6dc39976889a610027085421c9', name: "suffix" }))), this.readOnly && !this.hideReadOnlyIcon && (h("span", { key: '62bc9b373fb3e02b18041dde126e59354e727b2b', class: "text-field-icon__readonly" }, h("tds-icon", { key: '8064a973aae69b47661defa941de2e7fb6167b57', name: "edit_inactive", size: "20px" }))), h("span", { key: '71a2bd9077e2fa03458b41fd8ab5733998f33bbe', class: "text-field-icon__readonly-label" }, "This field is non-editable")), h("div", { key: 'f7110fc6ebff413d08feb61c8bf8bfd3aef3490c', "aria-live": "assertive" }, (this.helper || this.maxLength > 0) && (h("div", { key: '3776b5499bda3e3027ee537de571ded883e319af', class: "text-field-helper" }, this.state === 'error' && (h("div", { key: 'f887f43d1007b20d237217bf56813680ed671495', class: "text-field-helper-error-state" }, !this.readOnly && h("tds-icon", { key: 'ce50aeaa79974e0312307fab6a5b6d49bdfb501d', name: "error", size: "16px" }), this.helper)), this.state !== 'error' && this.helper, !this.readOnly && this.maxLength > 0 && (h("span", { key: '2bb64d74bee0003c2b68262852995573203703be', class: {
|
|
114
129
|
'text-field-textcounter-divider': true,
|
|
115
130
|
'text-field-textcounter-disabled': this.disabled,
|
|
116
|
-
} },
|
|
131
|
+
} }, this.value === null ? 0 : (_a = this.value) === null || _a === void 0 ? void 0 : _a.length, " / ", this.maxLength)))))));
|
|
117
132
|
}
|
|
118
133
|
get host() { return this; }
|
|
119
134
|
static get style() { return TdsTextFieldStyle0; }
|
|
@@ -128,6 +143,7 @@ const TdsTextField$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextField exten
|
|
|
128
143
|
"value": [513],
|
|
129
144
|
"disabled": [4],
|
|
130
145
|
"readOnly": [4, "read-only"],
|
|
146
|
+
"hideReadOnlyIcon": [4, "hide-read-only-icon"],
|
|
131
147
|
"size": [1],
|
|
132
148
|
"modeVariant": [1, "mode-variant"],
|
|
133
149
|
"noMinWidth": [4, "no-min-width"],
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, d as createEvent, h } from './p-28ef5186.js';
|
|
2
|
-
import { d as defineCustomElement$
|
|
2
|
+
import { d as defineCustomElement$4 } from './p-92fb75a7.js';
|
|
3
|
+
import { d as defineCustomElement$3 } from './p-252f3d4d.js';
|
|
4
|
+
import { d as defineCustomElement$2 } from './p-3dcfe1f4.js';
|
|
3
5
|
|
|
4
|
-
const textareaCss = ".textarea-container.sc-tds-textarea{border-radius:4px 4px 0 0;position:relative;box-sizing:border-box;height:auto;width:100%;min-width:208px;display:inline-flex;background-color:transparent;flex-flow:row wrap;border-bottom:0}.textarea-container.no-min-width.sc-tds-textarea{min-width:unset}.textarea-container.sc-tds-textarea .textarea-wrapper.sc-tds-textarea{position:relative;width:unset;min-width:100%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before,.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after{content:\"\";height:2px;width:0;position:absolute;background:var(--tds-textarea-bar);transition:0.35s ease all}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before{left:50%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after{right:50%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after,.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before{top:calc(100% - 2px)}.textarea-input.sc-tds-textarea{border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-textarea-color);background-color:var(--tds-textarea-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-20) var(--tds-spacing-element-16);display:block;resize:vertical;border-bottom:1px solid var(--tds-textarea-border-bottom);transition:border-bottom-color 200ms ease}.textarea-input.sc-tds-textarea::placeholder{opacity:1;color:var(--tds-textarea-placeholder)}.textarea-input.sc-tds-textarea:disabled{background-color:var(--tds-textarea-disabled-background);color:var(--tds-textarea-disabled-color);cursor:not-allowed}.textarea-input.sc-tds-textarea:disabled::placeholder{color:var(--tds-textarea-disabled-placeholder)}.textarea-input.sc-tds-textarea::-webkit-resizer{display:none}.textarea-input.sc-tds-textarea:hover{border-bottom-color:var(--tds-textarea-border-bottom-hover)}.textarea-resizer-icon.sc-tds-textarea{color:var(--tds-textarea-resize-icon);position:absolute;display:block;bottom:2px;right:1px;padding-bottom:2px;padding-right:2px;pointer-events:none;background-color:var(--tds-textarea-background)}.textarea-resizer-icon.sc-tds-textarea svg.sc-tds-textarea{display:block}.textarea-label.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:block;z-index:1;margin-bottom:var(--tds-spacing-element-8);color:var(--tds-textarea-label-color)}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);transition:0.1s ease all;color:var(--tds-textarea-label-inside-color);position:absolute;top:var(--tds-spacing-element-20);left:var(--tds-spacing-element-16)}.textarea-container.textarea-label-inside.textarea-disabled.sc-tds-textarea .textarea-label.sc-tds-textarea{color:var(--tds-textarea-disabled-label)}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea::placeholder{color:transparent}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea .sc-tds-textarea::placeholder{color:transparent}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea:focus::placeholder{transition:color 0.35s ease;color:var(--tds-textarea-placeholder)}.textarea-container.textarea-focus.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);top:var(--tds-spacing-element-8)}.textarea-container.textarea-focus.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::before,.textarea-container.textarea-focus.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::after{width:50%}.textarea-container.textarea-data.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);top:var(--tds-spacing-element-8)}.textarea-textcounter.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-textarea-textcounter);float:right;flex-basis:100%;text-align:right;padding-top:var(--tds-spacing-element-4)}.textarea-textcounter.sc-tds-textarea .textfield-textcounter-divider.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-textarea-textcounter-divider)}.textarea-helper.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:flex;gap:8px;align-items:center;padding-top:var(--tds-spacing-element-4);color:var(--tds-textarea-helper);flex-grow:2;flex-basis:auto}.textarea-helper.sc-tds-textarea~.textarea-textcounter.sc-tds-textarea{flex-basis:auto}.textarea-success.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:var(--tds-textarea-border-bottom-success)}.textarea-error.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:var(--tds-textarea-border-bottom-error)}.textarea-error.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::after,.textarea-error.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::before{background:var(--tds-textarea-bar-error)}.textarea-error.sc-tds-textarea .textarea-helper.sc-tds-textarea{color:var(--tds-textarea-helper-error)}.textarea-disabled.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:transparent}.textarea-disabled.sc-tds-textarea .textarea-label.sc-tds-textarea{color:var(--tds-textarea-disabled-label)}.textarea-disabled.sc-tds-textarea .textarea-helper.sc-tds-textarea{color:var(--tds-textarea-helper-disabled)}.textarea-disabled.sc-tds-textarea .textarea-textcounter.sc-tds-textarea{color:var(--tds-textarea-textcounter-disabled)}.textarea-disabled.sc-tds-textarea .textarea-textcounter.sc-tds-textarea .textfield-textcounter-divider.sc-tds-textarea{color:var(--tds-textarea-textcounter-disabled)}.textarea-icon__readonly.sc-tds-textarea{display:none;position:absolute;right:18px;top:18px;color:var(--tds-textarea-icon-read-only-color)}.textarea-icon__readonly-label.sc-tds-textarea{display:none;position:absolute;right:18px;top:48px;font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);padding:8px;color:var(--tds-textarea-icon-read-only-label-color);background-color:var(--tds-textarea-icon-read-only-label-background);white-space:nowrap;border-radius:4px 0 4px 4px}.textarea-readonly.sc-tds-textarea .textarea-icon__readonly.sc-tds-textarea{display:block}.textarea-readonly.sc-tds-textarea .textarea-
|
|
6
|
+
const textareaCss = ".textarea-container.sc-tds-textarea{border-radius:4px 4px 0 0;position:relative;box-sizing:border-box;height:auto;width:100%;min-width:208px;display:inline-flex;background-color:transparent;flex-flow:row wrap;border-bottom:0}.textarea-container.no-min-width.sc-tds-textarea{min-width:unset}.textarea-container.sc-tds-textarea .textarea-wrapper.sc-tds-textarea{position:relative;width:unset;min-width:100%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before,.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after{content:\"\";height:2px;width:0;position:absolute;background:var(--tds-textarea-bar);transition:0.35s ease all}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before{left:50%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after{right:50%}.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::after,.textarea-container.sc-tds-textarea:not(.textarea-disabled) .textarea-wrapper.sc-tds-textarea::before{top:calc(100% - 2px)}.textarea-input.sc-tds-textarea{border-radius:4px 4px 0 0;width:100%;box-sizing:border-box;margin:0;border:none;outline:none;height:100%;color:var(--tds-textarea-color);background-color:var(--tds-textarea-background);font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);padding:var(--tds-spacing-element-20) var(--tds-spacing-element-16);display:block;resize:vertical;border-bottom:1px solid var(--tds-textarea-border-bottom);transition:border-bottom-color 200ms ease}.textarea-input.sc-tds-textarea::placeholder{opacity:1;color:var(--tds-textarea-placeholder)}.textarea-input.sc-tds-textarea:disabled{background-color:var(--tds-textarea-disabled-background);color:var(--tds-textarea-disabled-color);cursor:not-allowed}.textarea-input.sc-tds-textarea:disabled::placeholder{color:var(--tds-textarea-disabled-placeholder)}.textarea-input.sc-tds-textarea::-webkit-resizer{display:none}.textarea-input.sc-tds-textarea:hover{border-bottom-color:var(--tds-textarea-border-bottom-hover)}.textarea-resizer-icon.sc-tds-textarea{color:var(--tds-textarea-resize-icon);position:absolute;display:block;bottom:2px;right:1px;padding-bottom:2px;padding-right:2px;pointer-events:none;background-color:var(--tds-textarea-background)}.textarea-resizer-icon.sc-tds-textarea svg.sc-tds-textarea{display:block}.textarea-label.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:block;z-index:1;margin-bottom:var(--tds-spacing-element-8);color:var(--tds-textarea-label-color)}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-02);letter-spacing:var(--tds-detail-02-ls);transition:0.1s ease all;color:var(--tds-textarea-label-inside-color);position:absolute;top:var(--tds-spacing-element-20);left:var(--tds-spacing-element-16)}.textarea-container.textarea-label-inside.textarea-disabled.sc-tds-textarea .textarea-label.sc-tds-textarea{color:var(--tds-textarea-disabled-label)}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea::placeholder{color:transparent}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea .sc-tds-textarea::placeholder{color:transparent}.textarea-container.textarea-label-inside.sc-tds-textarea .textarea-input.sc-tds-textarea:focus::placeholder{transition:color 0.35s ease;color:var(--tds-textarea-placeholder)}.textarea-container.textarea-focus.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);top:var(--tds-spacing-element-8)}.textarea-container.textarea-focus.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::before,.textarea-container.textarea-focus.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::after{width:50%}.textarea-container.textarea-data.textarea-label-inside.sc-tds-textarea .textarea-label.sc-tds-textarea{font:var(--tds-detail-07);letter-spacing:var(--tds-detail-07-ls);top:var(--tds-spacing-element-8)}.textarea-textcounter.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-textarea-textcounter);float:right;flex-basis:100%;text-align:right;padding-top:var(--tds-spacing-element-4)}.textarea-textcounter.sc-tds-textarea .textfield-textcounter-divider.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);color:var(--tds-textarea-textcounter-divider)}.textarea-helper.sc-tds-textarea{font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);display:flex;gap:8px;align-items:center;padding-top:var(--tds-spacing-element-4);color:var(--tds-textarea-helper);flex-grow:2;flex-basis:auto}.textarea-helper.sc-tds-textarea~.textarea-textcounter.sc-tds-textarea{flex-basis:auto}.textarea-success.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:var(--tds-textarea-border-bottom-success)}.textarea-error.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:var(--tds-textarea-border-bottom-error)}.textarea-error.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::after,.textarea-error.sc-tds-textarea .textarea-wrapper.sc-tds-textarea::before{background:var(--tds-textarea-bar-error)}.textarea-error.sc-tds-textarea .textarea-helper.sc-tds-textarea{color:var(--tds-textarea-helper-error)}.textarea-disabled.sc-tds-textarea{cursor:not-allowed}.textarea-disabled.sc-tds-textarea .textarea-input.sc-tds-textarea{border-bottom-color:transparent;pointer-events:none;user-select:none}.textarea-disabled.sc-tds-textarea .textarea-label.sc-tds-textarea{color:var(--tds-textarea-disabled-label)}.textarea-disabled.sc-tds-textarea .textarea-helper.sc-tds-textarea{color:var(--tds-textarea-helper-disabled)}.textarea-disabled.sc-tds-textarea .textarea-textcounter.sc-tds-textarea{color:var(--tds-textarea-textcounter-disabled)}.textarea-disabled.sc-tds-textarea .textarea-textcounter.sc-tds-textarea .textfield-textcounter-divider.sc-tds-textarea{color:var(--tds-textarea-textcounter-disabled)}.textarea-icon__readonly.sc-tds-textarea{display:none;position:absolute;right:18px;top:18px;color:var(--tds-textarea-icon-read-only-color)}.textarea-icon__readonly-label.sc-tds-textarea{display:none;position:absolute;right:18px;top:48px;font:var(--tds-detail-05);letter-spacing:var(--tds-detail-05-ls);padding:8px;color:var(--tds-textarea-icon-read-only-label-color);background-color:var(--tds-textarea-icon-read-only-label-background);white-space:nowrap;border-radius:4px 0 4px 4px}.textarea-readonly.sc-tds-textarea .textarea-icon__readonly.sc-tds-textarea{display:block}.textarea-readonly.sc-tds-textarea .textarea-input.sc-tds-textarea{border:1px solid var(--tds-textarea-border-bottom-read-only-color)}.textarea-readonly.sc-tds-textarea .textfield-container.sc-tds-textarea{background-color:transparent}.textarea-readonly.sc-tds-textarea:has(.textarea-icon__readonly) .textarea-input.sc-tds-textarea{padding-right:54px}";
|
|
5
7
|
const TdsTextareaStyle0 = textareaCss;
|
|
6
8
|
|
|
7
9
|
const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends H {
|
|
@@ -22,11 +24,13 @@ const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends
|
|
|
22
24
|
this.value = '';
|
|
23
25
|
this.disabled = false;
|
|
24
26
|
this.readOnly = false;
|
|
27
|
+
this.hideReadOnlyIcon = false;
|
|
25
28
|
this.state = 'default';
|
|
26
29
|
this.maxLength = undefined;
|
|
27
30
|
this.modeVariant = null;
|
|
28
31
|
this.autofocus = false;
|
|
29
32
|
this.noMinWidth = false;
|
|
33
|
+
this.tdsAriaLabel = undefined;
|
|
30
34
|
this.focusInput = undefined;
|
|
31
35
|
}
|
|
32
36
|
handleChange(event) {
|
|
@@ -38,8 +42,10 @@ const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends
|
|
|
38
42
|
}
|
|
39
43
|
// Data input event in value prop
|
|
40
44
|
handleInput(event) {
|
|
41
|
-
|
|
42
|
-
|
|
45
|
+
if (event.target instanceof HTMLInputElement) {
|
|
46
|
+
this.value = event.target.value;
|
|
47
|
+
this.tdsInput.emit(event);
|
|
48
|
+
}
|
|
43
49
|
}
|
|
44
50
|
/* Set the input as focus when clicking the whole textarea with suffix/prefix */
|
|
45
51
|
handleFocus(event) {
|
|
@@ -47,21 +53,35 @@ const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends
|
|
|
47
53
|
this.focusInput = true;
|
|
48
54
|
this.tdsFocus.emit(event);
|
|
49
55
|
}
|
|
56
|
+
setModeVariant(modeVariant) {
|
|
57
|
+
if (this.readOnly && modeVariant === 'primary') {
|
|
58
|
+
return 'secondary';
|
|
59
|
+
}
|
|
60
|
+
if (this.readOnly && modeVariant === 'secondary') {
|
|
61
|
+
return 'primary';
|
|
62
|
+
}
|
|
63
|
+
return modeVariant;
|
|
64
|
+
}
|
|
65
|
+
connectedCallback() {
|
|
66
|
+
if (!this.tdsAriaLabel && !this.label) {
|
|
67
|
+
console.warn('Tegel Textarea component: specify label or tdsAriaLabel prop for accessibility');
|
|
68
|
+
}
|
|
69
|
+
}
|
|
50
70
|
render() {
|
|
51
71
|
var _a;
|
|
52
|
-
return (h("div", { key: '
|
|
72
|
+
return (h("div", { key: 'b50538b818f0e82cca94db22f91a8ee73e009ca7', class: {
|
|
53
73
|
'textarea-container': true,
|
|
54
74
|
'textarea-label-inside': this.labelPosition === 'inside',
|
|
55
75
|
'textarea-focus': this.focusInput,
|
|
56
76
|
'textarea-disabled': this.disabled,
|
|
57
|
-
'textarea-readonly': this.readOnly,
|
|
58
|
-
[`tds-mode-variant-${this.modeVariant}`]:
|
|
77
|
+
'textarea-readonly': !this.disabled && this.readOnly,
|
|
78
|
+
[`tds-mode-variant-${this.setModeVariant(this.modeVariant)}`]: true,
|
|
59
79
|
'textarea-data': this.value !== '',
|
|
60
80
|
[`textarea-${this.state}`]: this.state === 'error' || this.state === 'success',
|
|
61
81
|
'no-min-width': this.noMinWidth,
|
|
62
|
-
} }, this.labelPosition !== 'no-label' && h("
|
|
82
|
+
} }, this.labelPosition !== 'no-label' && (h("label", { key: 'f96e68827795a3402d4261ffab997e5c9292fd20', htmlFor: "textarea-element", class: 'textarea-label' }, this.label)), h("div", { key: '0ed06e68cc15d78d4afead9404e89040229edb6e', class: "textarea-wrapper" }, h("textarea", { key: 'a15b5762cc8288e0b0e9631707055091062d0e95', id: "textarea-element", class: 'textarea-input', ref: (inputEl) => {
|
|
63
83
|
this.textEl = inputEl;
|
|
64
|
-
}, disabled: this.disabled, readonly: this.readOnly, placeholder: this.placeholder, value: this.value, name: this.name, autofocus: this.autofocus, maxlength: this.maxLength, cols: this.cols, rows: this.rows, onFocus: (event) => {
|
|
84
|
+
}, disabled: this.disabled, readonly: !this.disabled && this.readOnly, placeholder: this.placeholder, value: this.value, name: this.name, autofocus: this.autofocus, maxlength: this.maxLength, cols: this.cols, rows: this.rows, onFocus: (event) => {
|
|
65
85
|
if (!this.readOnly) {
|
|
66
86
|
this.handleFocus(event);
|
|
67
87
|
}
|
|
@@ -69,7 +89,7 @@ const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends
|
|
|
69
89
|
if (!this.readOnly) {
|
|
70
90
|
this.handleBlur(event);
|
|
71
91
|
}
|
|
72
|
-
}, onInput: (event) => this.handleInput(event), onChange: (event) => this.handleChange(event) }), h("span", { key: '
|
|
92
|
+
}, onInput: (event) => this.handleInput(event), onChange: (event) => this.handleChange(event), "aria-invalid": this.state === 'error' ? 'true' : 'false', "aria-readonly": this.readOnly ? 'true' : 'false', "aria-label": this.tdsAriaLabel ? this.tdsAriaLabel : this.label, "aria-describedby": "textarea-helper-element" }), h("span", { key: '904e38bce9b98c8ea06428c26083bc3d7476b845', class: "textarea-resizer-icon" }, h("svg", { key: '59e3404d79da1dfad42788e5f6e90e47752d603e', width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: '8e91b396a4337c0c56b0e8131d96aae5595506d9', "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M11.8536 0.853553C12.0488 0.658291 12.0488 0.341709 11.8536 0.146447C11.6583 -0.0488155 11.3417 -0.0488155 11.1464 0.146447L0.146447 11.1464C-0.0488155 11.3417 -0.0488155 11.6583 0.146447 11.8536C0.341709 12.0488 0.658291 12.0488 0.853553 11.8536L11.8536 0.853553ZM11.8536 4.64645C12.0488 4.84171 12.0488 5.15829 11.8536 5.35355L5.35355 11.8536C5.15829 12.0488 4.84171 12.0488 4.64645 11.8536C4.45118 11.6583 4.45118 11.3417 4.64645 11.1464L11.1464 4.64645C11.3417 4.45118 11.6583 4.45118 11.8536 4.64645ZM11.8536 8.64645C12.0488 8.84171 12.0488 9.15829 11.8536 9.35355L9.35355 11.8536C9.15829 12.0488 8.84171 12.0488 8.64645 11.8536C8.45118 11.6583 8.45118 11.3417 8.64645 11.1464L11.1464 8.64645C11.3417 8.45118 11.6583 8.45118 11.8536 8.64645Z", fill: "currentColor" }))), !this.disabled && !this.hideReadOnlyIcon && this.readOnly && (h("span", { key: '4c4629c89b4b2545a8482a0cd6c59b7c57888aa8', class: "textarea-icon__readonly" }, h("tds-tooltip", { key: 'cae2de2a71c2891067303188f54d7c1b186886ff', placement: "top-end", text: "This field is non-editable", selector: "#readonly-tooltip" }), h("tds-icon", { key: 'a09a265f4684d2356886a23cdef4a570d8323c04', id: "readonly-tooltip", name: "edit_inactive" })))), h("span", { key: '5862f0cb512faf37724629642c6560bdde90e47e', class: 'textarea-helper', "aria-live": "assertive", id: "textarea-helper-element" }, this.state === 'error' && !this.readOnly && h("tds-icon", { key: 'cc0202e6e28daf0664fb3446fd4118e453e89cff', name: "error", size: "16px" }), this.helper), this.maxLength > 0 && (h("div", { key: '6e1c683c4036b8aa9924ca69d4dda6b2b3a5fd8a', class: 'textarea-textcounter' }, this.value === null ? 0 : (_a = this.value) === null || _a === void 0 ? void 0 : _a.length, h("span", { key: '2eb15f11eb7b8abe3741bc9d4dde13ba2fa02d8a', class: "textfield-textcounter-divider" }, " / "), " ", this.maxLength))));
|
|
73
93
|
}
|
|
74
94
|
static get style() { return TdsTextareaStyle0; }
|
|
75
95
|
}, [2, "tds-textarea", {
|
|
@@ -83,18 +103,20 @@ const TdsTextarea$1 = /*@__PURE__*/ proxyCustomElement(class TdsTextarea extends
|
|
|
83
103
|
"value": [1],
|
|
84
104
|
"disabled": [4],
|
|
85
105
|
"readOnly": [4, "read-only"],
|
|
106
|
+
"hideReadOnlyIcon": [4, "hide-read-only-icon"],
|
|
86
107
|
"state": [1],
|
|
87
108
|
"maxLength": [2, "max-length"],
|
|
88
109
|
"modeVariant": [1, "mode-variant"],
|
|
89
110
|
"autofocus": [4],
|
|
90
111
|
"noMinWidth": [4, "no-min-width"],
|
|
112
|
+
"tdsAriaLabel": [1, "tds-aria-label"],
|
|
91
113
|
"focusInput": [32]
|
|
92
114
|
}]);
|
|
93
115
|
function defineCustomElement$1() {
|
|
94
116
|
if (typeof customElements === "undefined") {
|
|
95
117
|
return;
|
|
96
118
|
}
|
|
97
|
-
const components = ["tds-textarea", "tds-icon"];
|
|
119
|
+
const components = ["tds-textarea", "tds-icon", "tds-popover-core", "tds-tooltip"];
|
|
98
120
|
components.forEach(tagName => { switch (tagName) {
|
|
99
121
|
case "tds-textarea":
|
|
100
122
|
if (!customElements.get(tagName)) {
|
|
@@ -102,6 +124,16 @@ function defineCustomElement$1() {
|
|
|
102
124
|
}
|
|
103
125
|
break;
|
|
104
126
|
case "tds-icon":
|
|
127
|
+
if (!customElements.get(tagName)) {
|
|
128
|
+
defineCustomElement$4();
|
|
129
|
+
}
|
|
130
|
+
break;
|
|
131
|
+
case "tds-popover-core":
|
|
132
|
+
if (!customElements.get(tagName)) {
|
|
133
|
+
defineCustomElement$3();
|
|
134
|
+
}
|
|
135
|
+
break;
|
|
136
|
+
case "tds-tooltip":
|
|
105
137
|
if (!customElements.get(tagName)) {
|
|
106
138
|
defineCustomElement$2();
|
|
107
139
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, d as createEvent, h, c as Host } from './p-28ef5186.js';
|
|
2
2
|
import { g as generateUniqueId } from './p-11648030.js';
|
|
3
3
|
import { h as hasSlot } from './p-ae110fc2.js';
|
|
4
|
-
import { d as defineCustomElement$2 } from './p-
|
|
4
|
+
import { d as defineCustomElement$2 } from './p-92fb75a7.js';
|
|
5
5
|
|
|
6
6
|
const toastCss = ":host(.hide){display:none;visibility:hidden}:host{z-index:800}:host .wrapper{display:flex;width:348px;background-color:var(--tds-toast-background-color);border-radius:4px}:host .wrapper.information{border-left:4px solid var(--tds-information)}:host .wrapper.information tds-icon{color:var(--tds-information)}:host .wrapper.success{border-left:4px solid var(--tds-positive)}:host .wrapper.success tds-icon{color:var(--tds-positive)}:host .wrapper.error{border-left:4px solid var(--tds-negative)}:host .wrapper.error tds-icon{color:var(--tds-negative)}:host .wrapper.warning{border-left:4px solid var(--tds-warning)}:host .wrapper.warning tds-icon{color:var(--tds-warning)}:host .wrapper button.close{height:20px;width:20px;display:flex;align-items:center;justify-content:center;margin:14px 14px 0 22px;border:none;background:transparent}:host .wrapper button.close:hover{cursor:pointer}:host .wrapper button.close:focus{outline:2px solid var(--tds-blue-400);outline-offset:-2px}:host .wrapper button.close tds-icon{color:var(--tds-toast-dissmiss-color);padding:0}:host tds-icon{padding:14px 0 0 12px}:host .content{padding:16px 0 16px 10px;display:flex;flex-direction:column;flex:1;max-width:250px;word-break:break-word}:host .content .header-subheader{display:flex;flex-direction:column;gap:4px}:host .content .header,:host .content slot[name=header]::slotted(*){font:var(--tds-headline-07) !important;letter-spacing:var(--tds-headline-07-ls) !important;color:var(--tds-toast-headline-color)}:host .content .subheader,:host .content slot[name=subheader]::slotted(*){color:var(--tds-toast-subheadline-color);font:var(--tds-detail-02) !important;letter-spacing:var(--tds-detail-02-ls) !important}:host .content .subheader.no-link slot::slotted(*),:host .content slot[name=subheader]::slotted(*).no-link slot::slotted(*){padding-bottom:0}:host .content .toast-bottom{padding-top:12px}:host slot[name=actions]::slotted(*){color:var(--tds-toast-link-color)}:host .tds-mode-variant-primary{--tds-toast-background:var(--tds-toast-background-primary)}:host .tds-mode-variant-secondary{--tds-toast-background:var(--tds-toast-background-secondary)}";
|
|
7
7
|
const TdsToastStyle0 = toastCss;
|
|
@@ -49,6 +49,8 @@ const TdsToast$1 = /*@__PURE__*/ proxyCustomElement(class TdsToast extends H {
|
|
|
49
49
|
this.hidden = false;
|
|
50
50
|
this.closable = true;
|
|
51
51
|
this.toastRole = 'alert';
|
|
52
|
+
this.tdsCloseAriaLabel = undefined;
|
|
53
|
+
this.tdsAriaLive = 'polite';
|
|
52
54
|
}
|
|
53
55
|
/** Hides the Toast. */
|
|
54
56
|
async hideToast() {
|
|
@@ -58,16 +60,21 @@ const TdsToast$1 = /*@__PURE__*/ proxyCustomElement(class TdsToast extends H {
|
|
|
58
60
|
async showToast() {
|
|
59
61
|
this.hidden = false;
|
|
60
62
|
}
|
|
63
|
+
connectedCallback() {
|
|
64
|
+
if (!this.tdsCloseAriaLabel) {
|
|
65
|
+
console.warn('tds-toast: tdsCloseAriaLabel is required');
|
|
66
|
+
}
|
|
67
|
+
}
|
|
61
68
|
render() {
|
|
62
69
|
const usesHeaderSlot = hasSlot('header', this.host);
|
|
63
70
|
const usesSubheaderSlot = hasSlot('subheader', this.host);
|
|
64
71
|
const usesActionsSlot = hasSlot('actions', this.host);
|
|
65
|
-
return (h(Host, { key: '
|
|
72
|
+
return (h(Host, { key: '57126c13e4498e7862026978aab347dbe7e24d63', "aria-live": this.tdsAriaLive, toastRole: this.toastRole, "aria-describedby": this.host.getAttribute('aria-describedby'), class: {
|
|
66
73
|
hide: this.hidden,
|
|
67
74
|
show: !this.hidden,
|
|
68
|
-
} }, h("div", { key: '
|
|
75
|
+
} }, h("div", { key: '099c769d8f2e54b76eada969978e641b3f5c18ea', class: `
|
|
69
76
|
wrapper
|
|
70
|
-
${this.variant}` }, h("tds-icon", { key: '
|
|
77
|
+
${this.variant}` }, h("tds-icon", { key: '60fe4a91c42741be76f882fd82daa4ae3f5de545', name: this.getIconName(), size: "20px" }), h("div", { key: '5c5f4221726b14a38a6fb440a7f15570bb17b3cf', class: `content` }, h("div", { key: '2b53199e99ab3417160af38d81301a61e66eaef0', class: "header-subheader" }, this.header && h("div", { key: 'c98f680755ba45a8661ca46f6064c696ee61b6bb', class: "header" }, this.header), usesHeaderSlot && h("slot", { key: '5420edf38e156a811187eb6f5838bd8611818673', name: "header" }), this.subheader && h("div", { key: '9dc6d054f0f2ee3d179f25a8e75134d73ab426e2', class: "subheader" }, this.subheader), usesSubheaderSlot && h("slot", { key: '726eec99d5f05bea48b5a30bf7e91a71099960f8', name: "subheader" })), usesActionsSlot && (h("div", { key: '1cb83584cdb4cc8e3d383ebdf5d470135f7573ab', class: `toast-bottom ${usesSubheaderSlot || this.subheader ? 'subheader' : 'no-subheader'}` }, h("slot", { key: '0950f174a2e62ffbec229ef24e4a999a318798cd', name: "actions" })))), this.closable && (h("button", { key: 'ee90c96c48a11e38f17acd8cb66a1619bd770e83', id: "my-button", "aria-label": this.tdsCloseAriaLabel, onClick: this.handleClose, class: "close" }, h("tds-icon", { key: '632aefc906f17bd0993c832f9c4c5a1ec8db1ccc', name: "cross", size: "20px" }))))));
|
|
71
78
|
}
|
|
72
79
|
get host() { return this; }
|
|
73
80
|
static get style() { return TdsToastStyle0; }
|
|
@@ -79,6 +86,8 @@ const TdsToast$1 = /*@__PURE__*/ proxyCustomElement(class TdsToast extends H {
|
|
|
79
86
|
"hidden": [516],
|
|
80
87
|
"closable": [4],
|
|
81
88
|
"toastRole": [1, "toast-role"],
|
|
89
|
+
"tdsCloseAriaLabel": [1, "tds-close-aria-label"],
|
|
90
|
+
"tdsAriaLive": [1, "tds-aria-live"],
|
|
82
91
|
"hideToast": [64],
|
|
83
92
|
"showToast": [64]
|
|
84
93
|
}]);
|
|
@@ -42,10 +42,10 @@ const TdsToggle$1 = /*@__PURE__*/ proxyCustomElement(class TdsToggle extends H {
|
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
render() {
|
|
45
|
-
return (h("div", { key: '
|
|
45
|
+
return (h("div", { key: '8f8a77827f524c049aa004d15372a78e7fad41e2', class: "tds-toggle" }, this.headline && (h("div", { key: '8e254412e80362807046a893fc3f7c42a0c376ba', class: {
|
|
46
46
|
'toggle-headline': true,
|
|
47
47
|
'disabled': this.disabled,
|
|
48
|
-
} }, this.headline)), h("input", { key: '
|
|
48
|
+
} }, this.headline)), h("input", { key: '47ed1307b67b61b1594006449fb1b4ccf6d031b8', "aria-label": this.tdsAriaLabel, "aria-describedby": this.host.getAttribute('aria-describedby'), "aria-labelledby": this.host.getAttribute('aria-labelledby'), "aria-checked": this.checked, "aria-required": this.required, onChange: () => this.handleToggle(), class: `${this.size}`, checked: this.checked, disabled: this.disabled, required: this.required, type: "checkbox", name: this.name, id: this.toggleId, role: "switch" }), this.labelSlot && (h("label", { key: '75964d686710d6b4f8bbe365cc51c8aab3234d26', class: { disabled: this.disabled }, htmlFor: this.toggleId }, h("slot", { key: 'aeeaed1f37a160ce792df3f5115c75eaa0fd2c0a', name: "label" })))));
|
|
49
49
|
}
|
|
50
50
|
get host() { return this; }
|
|
51
51
|
static get style() { return TdsToggleStyle0; }
|