@ids-group-ltd/ids-design-system 0.14.2 → 0.14.3
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/CHANGELOG.md +93 -0
- package/components.md +15 -15
- package/docs/agent/forms/ds-color-picker.md +1 -1
- package/docs/agent/forms/ds-date-picker.md +1 -1
- package/docs/agent/forms/ds-select.md +1 -1
- package/docs/agent/forms/ds-textarea.md +1 -1
- package/docs/agent/forms/ds-time-picker.md +1 -1
- package/docs/agent/forms/the-picker-family-ds-select-ds-multi-select-ds-autocomplete.md +1 -1
- package/docs/agent/foundations/tokens.md +1 -1
- package/docs/agent/navigation/ds-tabs.md +1 -1
- package/docs/agent/overlays/ds-bottom-sheet.md +1 -1
- package/docs/agent/overlays/ds-drawer.md +1 -1
- package/docs/agent/overlays/ds-modal.md +1 -1
- package/docs/agent/overlays/ds-popover.md +1 -1
- package/docs/agent/overlays/ds-tooltip.md +3 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-autocomplete.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-bottom-sheet.mjs +16 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-bottom-sheet.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs +25 -10
- package/fesm2022/ids-group-ltd-ids-design-system-components-color-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs +28 -11
- package/fesm2022/ids-group-ltd-ids-design-system-components-date-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs +13 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-drawer.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs +3 -3
- package/fesm2022/ids-group-ltd-ids-design-system-components-multi-select.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs +3 -4
- package/fesm2022/ids-group-ltd-ids-design-system-components-select.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-sidenav.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-stat.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-table.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components-tabs.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs +31 -9
- package/fesm2022/ids-group-ltd-ids-design-system-components-textarea.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs +16 -5
- package/fesm2022/ids-group-ltd-ids-design-system-components-time-picker.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs +74 -18
- package/fesm2022/ids-group-ltd-ids-design-system-components-tooltip.mjs.map +1 -1
- package/fesm2022/ids-group-ltd-ids-design-system-components.mjs +2 -2
- package/fesm2022/ids-group-ltd-ids-design-system-components.mjs.map +1 -1
- package/migrations/0.14.3.json +71 -0
- package/package.json +1 -1
- package/schematics/check-overrides/surface.json +6 -1
- package/themes/_semantic.scss +1 -0
- package/themes/dark/_theme.scss +1 -0
- package/types/ids-group-ltd-ids-design-system-components-bottom-sheet.d.ts +4 -1
- package/types/ids-group-ltd-ids-design-system-components-color-picker.d.ts +4 -2
- package/types/ids-group-ltd-ids-design-system-components-date-picker.d.ts +4 -2
- package/types/ids-group-ltd-ids-design-system-components-drawer.d.ts +4 -1
- package/types/ids-group-ltd-ids-design-system-components-textarea.d.ts +11 -3
- package/types/ids-group-ltd-ids-design-system-components-time-picker.d.ts +3 -2
- package/types/ids-group-ltd-ids-design-system-components-tooltip.d.ts +10 -1
|
@@ -425,14 +425,14 @@ class TabsComponent {
|
|
|
425
425
|
});
|
|
426
426
|
}
|
|
427
427
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: TabsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
428
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.22", type: TabsComponent, isStandalone: true, selector: "ds-tabs", inputs: { selectedIndex: { classPropertyName: "selectedIndex", publicName: "selectedIndex", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, lazy: { classPropertyName: "lazy", publicName: "lazy", isSignal: true, isRequired: false, transformFunction: null }, scrollable: { classPropertyName: "scrollable", publicName: "scrollable", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, urlParam: { classPropertyName: "urlParam", publicName: "urlParam", isSignal: true, isRequired: false, transformFunction: null }, rememberLastTab: { classPropertyName: "rememberLastTab", publicName: "rememberLastTab", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectedIndex: "selectedIndexChange", tabClosed: "tabClosed" }, host: { properties: { "class.vertical-host": "orientation() === 'vertical'", "class.scrolling-host": "scrollsHorizontally()" } }, queries: [{ propertyName: "tabs", predicate: TabComponent, isSignal: true }], viewQueries: [{ propertyName: "tablist", first: true, predicate: ["tablist"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_tabs-divider: var(--ds-tabs-divider, var(--border-divider));--_tab-padding-x: var(--ds-tab-padding-x, var(--space-4));--_tab-padding-y: var(--ds-tab-padding-y, var(--space-3));--_tab-padding-top: var(--ds-tab-padding-top, var(--_tab-padding-y));--_tab-padding-bottom: var(--ds-tab-padding-bottom, var(--_tab-padding-y));--_tab-label-font-weight: var(--ds-tab-label-font-weight, var(--font-weight-semibold));--_tab-label-font-size: var(--ds-tab-label-font-size, var(--font-size-s));--_tabs-gap: var(--ds-tabs-gap, var(--space-2));--_tabs-panel-padding-top: var(--ds-tabs-panel-padding-top, var(--space-3));--_tab-label-color: var(--ds-tab-label-color, var(--text-secondary));--_tab-label-color-hover: var(--ds-tab-label-color-hover, var(--text-primary));--_tab-label-color-active: var(--ds-tab-label-color-active, var(--accent));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--accent));--_tab-indicator-width: var(--ds-tab-indicator-width, var(--border-width-strong));--_tabs-pills-bg-color: var(--ds-tabs-pills-bg-color, var(--surface-secondary));--_tab-pill-bg-color-hover: var(--ds-tab-pill-bg-color-hover, var(--accent-subtitle));--_tab-pill-bg-color-active: var(--ds-tab-pill-bg-color-active, var(--surface-default));--_tab-pill-bg-color-active-hover: var(--ds-tab-pill-bg-color-active-hover, var(--accent-subtitle));--_tab-pill-label-color-active: var(--ds-tab-pill-label-color-active, var(--accent-strong));--_tab-pill-radius: var(--ds-tab-pill-radius, var(--ds-radius-control));--_tab-badge-bg-color: var(--ds-tab-badge-bg-color, var(--surface-secondary));--_tab-badge-label-color: var(--ds-tab-badge-label-color, var(--text-secondary));--_tab-close-icon-color: var(--ds-tab-close-icon-color, var(--text-tertiary));--_tab-close-bg-color-hover: var(--ds-tab-close-bg-color-hover, var(--surface-secondary));display:block}:host(.scrolling-host){display:grid;grid-template-columns:auto minmax(0,1fr) auto}:host(.scrolling-host)>.tabs{grid-column:2}:host(.scrolling-host)>.panel{grid-column:1/-1;min-width:0}.scroll-arrow{display:inline-flex;flex:none;align-items:center;justify-content:center;width:var(--hit-sm);padding:0;border:0;border-bottom:var(--border-width-default) solid var(--_tabs-divider);border-radius:var(--ds-radius-control) var(--ds-radius-control) 0 0;background:transparent;color:var(--_tab-label-color);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.scroll-arrow:hover{background-color:var(--surface-muted);color:var(--_tab-label-color-hover)}.scroll-arrow:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.scroll-arrow.at-edge{visibility:hidden}.scroll-arrow:dir(rtl) ds-icon{transform:scaleX(-1)}:host(.scrolling-host:has(> .pills)) .scroll-arrow{border-bottom:0;border-radius:var(--ds-radius-control)}.tabs{display:flex;gap:var(--_tabs-gap);border-bottom:var(--border-width-default) solid var(--_tabs-divider)}.tabs.scrollable{overflow-x:auto;scroll-behavior:smooth}@media(prefers-reduced-motion:reduce){.tabs.scrollable{scroll-behavior:auto}}.tabs.scrollable{--focus-ring-offset: calc(-1 * var(--focus-ring-width));flex-wrap:nowrap;scrollbar-width:none}.tabs.scrollable::-webkit-scrollbar{display:none}.tabs .tab{display:inline-flex;align-items:center;gap:var(--space-2);padding:var(--_tab-padding-top) var(--_tab-padding-x) var(--_tab-padding-bottom);border:0;background:transparent;font:var(--_tab-label-font-weight) var(--_tab-label-font-size)/var(--line-height-flat) var(--font-sans);color:var(--_tab-label-color);cursor:pointer;border-bottom:var(--_tab-indicator-width) solid transparent;margin-bottom:calc(-1 * var(--border-width-default));white-space:nowrap;flex-shrink:0;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard),border-color var(--duration-fast) var(--ease-standard)}.tabs .tab:hover{color:var(--_tab-label-color-hover)}.tabs .tab.active{color:var(--_tab-label-color-active);border-bottom-color:var(--_tab-indicator-color)}.tabs .tab .badge{min-width:var(--badge-count-size);height:var(--badge-count-size);padding:0 var(--space-1-5);display:inline-grid;place-items:center;border-radius:var(--radius-pill);font:var(--font-weight-bold) var(--font-size-2xs)/var(--line-height-base) var(--font-sans);letter-spacing:var(--letter-spacing-wide);white-space:nowrap;background:var(--_tab-badge-bg-color);color:var(--_tab-badge-label-color);margin-left:var(--space-1)}.tabs .tab .tab-close{display:inline-flex;align-items:center;justify-content:center;width:var(--icon-md);height:var(--icon-md);border-radius:var(--ds-radius-inner);color:var(--_tab-close-icon-color);margin-left:var(--space-1);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.tabs .tab .tab-close:hover{background-color:var(--_tab-close-bg-color-hover);color:var(--text-primary)}.tabs .tab .tab-close:active{background-color:var(--surface-muted)}.tabs .tab:focus-visible{outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard);border-radius:var(--radius-sm)}.tabs .tab:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.tabs .tab[disabled],.tabs .tab.disabled{color:var(--text-disabled);cursor:not-allowed}:host(.secondary) .tab.active{--_tab-label-color-active: var(--ds-tab-label-color-active, var(--secondary-strong));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--secondary))}.tabs.pills{border-bottom:0;gap:var(--space-1);padding:var(--space-1);background-color:var(--_tabs-pills-bg-color);border-radius:var(--_tab-pill-radius);display:inline-flex}.tabs.pills .tab{padding:var(--space-2) var(--space-3);border-bottom:0;margin-bottom:0;border-radius:var(--_tab-pill-radius);color:var(--_tab-label-color)}.tabs.pills .tab:hover{background-color:var(--_tab-pill-bg-color-hover);color:var(--_tab-label-color-hover)}.tabs.pills .tab.active{background-color:var(--_tab-pill-bg-color-active);color:var(--_tab-pill-label-color-active);border-bottom:0}.tabs.pills .tab.active:not(:focus-visible){box-shadow:var(--shadow-1)}.tabs.pills .tab.active:hover{background-color:var(--_tab-pill-bg-color-active-hover)}.tabs.pills.scrollable{display:flex;width:100%}.tabs.vertical{flex-direction:column;border-bottom:0;border-right:var(--border-width-default) solid var(--_tabs-divider);gap:var(--space-1)}.tabs.vertical .tab{border-bottom:0;margin-bottom:0;border-right:var(--_tab-indicator-width) solid transparent;margin-right:calc(-1 * var(--border-width-default));text-align:left;justify-content:flex-start}.tabs.vertical .tab.active{color:var(--_tab-label-color-active);border-bottom-color:transparent;border-right-color:var(--_tab-indicator-color)}:host(.vertical-host){display:flex;flex-direction:row;align-items:flex-start;gap:var(--space-4)}.panel{padding-top:var(--_tabs-panel-padding-top)}.panel:empty{display:none}.panel[hidden]{display:none}:host(.vertical-host) .panel{padding-top:0;padding-left:var(--space-4);flex:1;min-width:0}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: IconComponent, selector: "ds-icon", inputs: ["name", "size", "stroke", "ariaLabel"] }] });
|
|
428
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.22", type: TabsComponent, isStandalone: true, selector: "ds-tabs", inputs: { selectedIndex: { classPropertyName: "selectedIndex", publicName: "selectedIndex", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, lazy: { classPropertyName: "lazy", publicName: "lazy", isSignal: true, isRequired: false, transformFunction: null }, scrollable: { classPropertyName: "scrollable", publicName: "scrollable", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, urlParam: { classPropertyName: "urlParam", publicName: "urlParam", isSignal: true, isRequired: false, transformFunction: null }, rememberLastTab: { classPropertyName: "rememberLastTab", publicName: "rememberLastTab", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectedIndex: "selectedIndexChange", tabClosed: "tabClosed" }, host: { properties: { "class.vertical-host": "orientation() === 'vertical'", "class.scrolling-host": "scrollsHorizontally()" } }, queries: [{ propertyName: "tabs", predicate: TabComponent, isSignal: true }], viewQueries: [{ propertyName: "tablist", first: true, predicate: ["tablist"], descendants: true, isSignal: true }], ngImport: i0, template: "@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_tabs-divider: var(--ds-tabs-divider, var(--border-divider));--_tab-padding-x: var(--ds-tab-padding-x, var(--space-4));--_tab-padding-y: var(--ds-tab-padding-y, var(--space-3));--_tab-padding-top: var(--ds-tab-padding-top, var(--_tab-padding-y));--_tab-padding-bottom: var(--ds-tab-padding-bottom, var(--_tab-padding-y));--_tab-label-font-weight: var(--ds-tab-label-font-weight, var(--font-weight-semibold));--_tab-label-font-size: var(--ds-tab-label-font-size, var(--font-size-s));--_tabs-gap: var(--ds-tabs-gap, var(--space-2));--_tabs-panel-padding-top: var(--ds-tabs-panel-padding-top, var(--space-3));--_tab-label-color: var(--ds-tab-label-color, var(--text-secondary));--_tab-label-color-hover: var(--ds-tab-label-color-hover, var(--text-primary));--_tab-label-color-active: var(--ds-tab-label-color-active, var(--accent));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--accent));--_tab-indicator-width: var(--ds-tab-indicator-width, var(--border-width-strong));--_tabs-pills-bg-color: var(--ds-tabs-pills-bg-color, var(--surface-secondary));--_tab-pill-bg-color-hover: var(--ds-tab-pill-bg-color-hover, var(--accent-subtitle));--_tab-pill-bg-color-active: var(--ds-tab-pill-bg-color-active, var(--surface-default));--_tab-pill-bg-color-active-hover: var(--ds-tab-pill-bg-color-active-hover, var(--accent-subtitle));--_tab-pill-label-color-active: var(--ds-tab-pill-label-color-active, var(--accent-strong));--_tab-pill-radius: var(--ds-tab-pill-radius, var(--ds-radius-control));--_tab-badge-bg-color: var(--ds-tab-badge-bg-color, var(--surface-secondary));--_tab-badge-label-color: var(--ds-tab-badge-label-color, var(--text-secondary));--_tab-close-icon-color: var(--ds-tab-close-icon-color, var(--text-tertiary));--_tab-close-bg-color-hover: var(--ds-tab-close-bg-color-hover, var(--surface-secondary));--_tabs-scroll-arrow-bg-color-hover: var(--ds-tabs-scroll-arrow-bg-color-hover, var(--surface-secondary));display:block}:host(.scrolling-host){display:grid;grid-template-columns:auto minmax(0,1fr) auto}:host(.scrolling-host)>.tabs{grid-column:2}:host(.scrolling-host)>.panel{grid-column:1/-1;min-width:0}.scroll-arrow{--_scroll-arrow-padding-bottom: calc(var(--_tab-padding-bottom) + var(--_tab-indicator-width) - var(--border-width-default));--_scroll-arrow-surface-shift: calc(var(--_scroll-arrow-padding-bottom) - var(--_tab-padding-top));--_tabs-scroll-arrow-icon-color-hover: var(--ds-tabs-scroll-arrow-icon-color-hover, var(--_tab-label-color-active));position:relative;isolation:isolate;contain:size;display:inline-flex;flex:none;align-items:center;justify-content:center;width:var(--hit-sm);padding:var(--_tab-padding-top) 0 var(--_scroll-arrow-padding-bottom);border:0;border-bottom:var(--border-width-default) solid var(--_tabs-divider);background:transparent;color:var(--_tab-label-color);cursor:pointer;transition:color var(--duration-fast) var(--ease-standard)}.scroll-arrow:before{content:\"\";position:absolute;inset:max(0px,-1 * var(--_scroll-arrow-surface-shift)) 0 max(0px,var(--_scroll-arrow-surface-shift));z-index:-1;border-radius:var(--ds-radius-control) var(--ds-radius-control) 0 0;transition:background-color var(--duration-fast) var(--ease-standard)}.scroll-arrow:hover{color:var(--_tabs-scroll-arrow-icon-color-hover)}.scroll-arrow:hover:before{background-color:var(--_tabs-scroll-arrow-bg-color-hover)}.scroll-arrow:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.scroll-arrow.at-edge{visibility:hidden}.scroll-arrow:dir(rtl) ds-icon{transform:scaleX(-1)}:host(.scrolling-host:has(> .pills)) .scroll-arrow{--_tabs-scroll-arrow-icon-color-hover: var(--ds-tabs-scroll-arrow-icon-color-hover, var(--_tab-pill-label-color-active));padding:0;border-bottom:0}:host(.scrolling-host:has(> .pills)) .scroll-arrow:before{inset:var(--space-1) 0;border-radius:var(--_tab-pill-radius)}.tabs{display:flex;gap:var(--_tabs-gap);border-bottom:var(--border-width-default) solid var(--_tabs-divider)}.tabs.scrollable{overflow-x:auto;scroll-behavior:smooth}@media(prefers-reduced-motion:reduce){.tabs.scrollable{scroll-behavior:auto}}.tabs.scrollable{--focus-ring-offset: calc(-1 * var(--focus-ring-width));flex-wrap:nowrap;scrollbar-width:none}.tabs.scrollable::-webkit-scrollbar{display:none}.tabs .tab{display:inline-flex;align-items:center;gap:var(--space-2);padding:var(--_tab-padding-top) var(--_tab-padding-x) var(--_tab-padding-bottom);border:0;background:transparent;font:var(--_tab-label-font-weight) var(--_tab-label-font-size)/var(--line-height-flat) var(--font-sans);color:var(--_tab-label-color);cursor:pointer;border-bottom:var(--_tab-indicator-width) solid transparent;margin-bottom:calc(-1 * var(--border-width-default));white-space:nowrap;flex-shrink:0;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard),border-color var(--duration-fast) var(--ease-standard)}.tabs .tab:hover{color:var(--_tab-label-color-hover)}.tabs .tab.active{color:var(--_tab-label-color-active);border-bottom-color:var(--_tab-indicator-color)}.tabs .tab .badge{min-width:var(--badge-count-size);height:var(--badge-count-size);padding:0 var(--space-1-5);display:inline-grid;place-items:center;border-radius:var(--radius-pill);font:var(--font-weight-bold) var(--font-size-2xs)/var(--line-height-base) var(--font-sans);letter-spacing:var(--letter-spacing-wide);white-space:nowrap;background:var(--_tab-badge-bg-color);color:var(--_tab-badge-label-color);margin-left:var(--space-1)}.tabs .tab .tab-close{display:inline-flex;align-items:center;justify-content:center;width:var(--icon-md);height:var(--icon-md);border-radius:var(--ds-radius-inner);color:var(--_tab-close-icon-color);margin-left:var(--space-1);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.tabs .tab .tab-close:hover{background-color:var(--_tab-close-bg-color-hover);color:var(--text-primary)}.tabs .tab .tab-close:active{background-color:var(--surface-muted)}.tabs .tab:focus-visible{outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard);border-radius:var(--radius-sm)}.tabs .tab:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.tabs .tab[disabled],.tabs .tab.disabled{color:var(--text-disabled);cursor:not-allowed}:host(.secondary){--_tab-label-color-active: var(--ds-tab-label-color-active, var(--secondary-strong));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--secondary))}.tabs.pills{border-bottom:0;gap:var(--space-1);padding:var(--space-1);background-color:var(--_tabs-pills-bg-color);border-radius:var(--_tab-pill-radius);display:inline-flex}.tabs.pills .tab{padding:var(--space-2) var(--space-3);border-bottom:0;margin-bottom:0;border-radius:var(--_tab-pill-radius);color:var(--_tab-label-color)}.tabs.pills .tab:hover{background-color:var(--_tab-pill-bg-color-hover);color:var(--_tab-label-color-hover)}.tabs.pills .tab.active{background-color:var(--_tab-pill-bg-color-active);color:var(--_tab-pill-label-color-active);border-bottom:0}.tabs.pills .tab.active:not(:focus-visible){box-shadow:var(--shadow-1)}.tabs.pills .tab.active:hover{background-color:var(--_tab-pill-bg-color-active-hover)}.tabs.pills.scrollable{display:flex;width:100%}.tabs.vertical{flex-direction:column;border-bottom:0;border-right:var(--border-width-default) solid var(--_tabs-divider);gap:var(--space-1)}.tabs.vertical .tab{border-bottom:0;margin-bottom:0;border-right:var(--_tab-indicator-width) solid transparent;margin-right:calc(-1 * var(--border-width-default));text-align:left;justify-content:flex-start}.tabs.vertical .tab.active{color:var(--_tab-label-color-active);border-bottom-color:transparent;border-right-color:var(--_tab-indicator-color)}:host(.vertical-host){display:flex;flex-direction:row;align-items:flex-start;gap:var(--space-4)}.panel{padding-top:var(--_tabs-panel-padding-top)}.panel:empty{display:none}.panel[hidden]{display:none}:host(.vertical-host) .panel{padding-top:0;padding-left:var(--space-4);flex:1;min-width:0}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: IconComponent, selector: "ds-icon", inputs: ["name", "size", "stroke", "ariaLabel"] }] });
|
|
429
429
|
}
|
|
430
430
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: TabsComponent, decorators: [{
|
|
431
431
|
type: Component,
|
|
432
432
|
args: [{ selector: 'ds-tabs', standalone: true, imports: [NgTemplateOutlet, IconComponent], encapsulation: ViewEncapsulation.Emulated, host: {
|
|
433
433
|
'[class.vertical-host]': "orientation() === 'vertical'",
|
|
434
434
|
'[class.scrolling-host]': 'scrollsHorizontally()',
|
|
435
|
-
}, template: "@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_tabs-divider: var(--ds-tabs-divider, var(--border-divider));--_tab-padding-x: var(--ds-tab-padding-x, var(--space-4));--_tab-padding-y: var(--ds-tab-padding-y, var(--space-3));--_tab-padding-top: var(--ds-tab-padding-top, var(--_tab-padding-y));--_tab-padding-bottom: var(--ds-tab-padding-bottom, var(--_tab-padding-y));--_tab-label-font-weight: var(--ds-tab-label-font-weight, var(--font-weight-semibold));--_tab-label-font-size: var(--ds-tab-label-font-size, var(--font-size-s));--_tabs-gap: var(--ds-tabs-gap, var(--space-2));--_tabs-panel-padding-top: var(--ds-tabs-panel-padding-top, var(--space-3));--_tab-label-color: var(--ds-tab-label-color, var(--text-secondary));--_tab-label-color-hover: var(--ds-tab-label-color-hover, var(--text-primary));--_tab-label-color-active: var(--ds-tab-label-color-active, var(--accent));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--accent));--_tab-indicator-width: var(--ds-tab-indicator-width, var(--border-width-strong));--_tabs-pills-bg-color: var(--ds-tabs-pills-bg-color, var(--surface-secondary));--_tab-pill-bg-color-hover: var(--ds-tab-pill-bg-color-hover, var(--accent-subtitle));--_tab-pill-bg-color-active: var(--ds-tab-pill-bg-color-active, var(--surface-default));--_tab-pill-bg-color-active-hover: var(--ds-tab-pill-bg-color-active-hover, var(--accent-subtitle));--_tab-pill-label-color-active: var(--ds-tab-pill-label-color-active, var(--accent-strong));--_tab-pill-radius: var(--ds-tab-pill-radius, var(--ds-radius-control));--_tab-badge-bg-color: var(--ds-tab-badge-bg-color, var(--surface-secondary));--_tab-badge-label-color: var(--ds-tab-badge-label-color, var(--text-secondary));--_tab-close-icon-color: var(--ds-tab-close-icon-color, var(--text-tertiary));--_tab-close-bg-color-hover: var(--ds-tab-close-bg-color-hover, var(--surface-secondary));display:block}:host(.scrolling-host){display:grid;grid-template-columns:auto minmax(0,1fr) auto}:host(.scrolling-host)>.tabs{grid-column:2}:host(.scrolling-host)>.panel{grid-column:1/-1;min-width:0}.scroll-arrow{display:inline-flex;flex:none;align-items:center;justify-content:center;width:var(--hit-sm);padding:0;border:0;border-bottom:var(--border-width-default) solid var(--_tabs-divider);border-radius:var(--ds-radius-control) var(--ds-radius-control) 0 0;background:transparent;color:var(--_tab-label-color);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.scroll-arrow:hover{background-color:var(--surface-muted);color:var(--_tab-label-color-hover)}.scroll-arrow:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.scroll-arrow.at-edge{visibility:hidden}.scroll-arrow:dir(rtl) ds-icon{transform:scaleX(-1)}:host(.scrolling-host:has(> .pills)) .scroll-arrow{border-bottom:0;border-radius:var(--ds-radius-control)}.tabs{display:flex;gap:var(--_tabs-gap);border-bottom:var(--border-width-default) solid var(--_tabs-divider)}.tabs.scrollable{overflow-x:auto;scroll-behavior:smooth}@media(prefers-reduced-motion:reduce){.tabs.scrollable{scroll-behavior:auto}}.tabs.scrollable{--focus-ring-offset: calc(-1 * var(--focus-ring-width));flex-wrap:nowrap;scrollbar-width:none}.tabs.scrollable::-webkit-scrollbar{display:none}.tabs .tab{display:inline-flex;align-items:center;gap:var(--space-2);padding:var(--_tab-padding-top) var(--_tab-padding-x) var(--_tab-padding-bottom);border:0;background:transparent;font:var(--_tab-label-font-weight) var(--_tab-label-font-size)/var(--line-height-flat) var(--font-sans);color:var(--_tab-label-color);cursor:pointer;border-bottom:var(--_tab-indicator-width) solid transparent;margin-bottom:calc(-1 * var(--border-width-default));white-space:nowrap;flex-shrink:0;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard),border-color var(--duration-fast) var(--ease-standard)}.tabs .tab:hover{color:var(--_tab-label-color-hover)}.tabs .tab.active{color:var(--_tab-label-color-active);border-bottom-color:var(--_tab-indicator-color)}.tabs .tab .badge{min-width:var(--badge-count-size);height:var(--badge-count-size);padding:0 var(--space-1-5);display:inline-grid;place-items:center;border-radius:var(--radius-pill);font:var(--font-weight-bold) var(--font-size-2xs)/var(--line-height-base) var(--font-sans);letter-spacing:var(--letter-spacing-wide);white-space:nowrap;background:var(--_tab-badge-bg-color);color:var(--_tab-badge-label-color);margin-left:var(--space-1)}.tabs .tab .tab-close{display:inline-flex;align-items:center;justify-content:center;width:var(--icon-md);height:var(--icon-md);border-radius:var(--ds-radius-inner);color:var(--_tab-close-icon-color);margin-left:var(--space-1);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.tabs .tab .tab-close:hover{background-color:var(--_tab-close-bg-color-hover);color:var(--text-primary)}.tabs .tab .tab-close:active{background-color:var(--surface-muted)}.tabs .tab:focus-visible{outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard);border-radius:var(--radius-sm)}.tabs .tab:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.tabs .tab[disabled],.tabs .tab.disabled{color:var(--text-disabled);cursor:not-allowed}:host(.secondary) .tab.active{--_tab-label-color-active: var(--ds-tab-label-color-active, var(--secondary-strong));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--secondary))}.tabs.pills{border-bottom:0;gap:var(--space-1);padding:var(--space-1);background-color:var(--_tabs-pills-bg-color);border-radius:var(--_tab-pill-radius);display:inline-flex}.tabs.pills .tab{padding:var(--space-2) var(--space-3);border-bottom:0;margin-bottom:0;border-radius:var(--_tab-pill-radius);color:var(--_tab-label-color)}.tabs.pills .tab:hover{background-color:var(--_tab-pill-bg-color-hover);color:var(--_tab-label-color-hover)}.tabs.pills .tab.active{background-color:var(--_tab-pill-bg-color-active);color:var(--_tab-pill-label-color-active);border-bottom:0}.tabs.pills .tab.active:not(:focus-visible){box-shadow:var(--shadow-1)}.tabs.pills .tab.active:hover{background-color:var(--_tab-pill-bg-color-active-hover)}.tabs.pills.scrollable{display:flex;width:100%}.tabs.vertical{flex-direction:column;border-bottom:0;border-right:var(--border-width-default) solid var(--_tabs-divider);gap:var(--space-1)}.tabs.vertical .tab{border-bottom:0;margin-bottom:0;border-right:var(--_tab-indicator-width) solid transparent;margin-right:calc(-1 * var(--border-width-default));text-align:left;justify-content:flex-start}.tabs.vertical .tab.active{color:var(--_tab-label-color-active);border-bottom-color:transparent;border-right-color:var(--_tab-indicator-color)}:host(.vertical-host){display:flex;flex-direction:row;align-items:flex-start;gap:var(--space-4)}.panel{padding-top:var(--_tabs-panel-padding-top)}.panel:empty{display:none}.panel[hidden]{display:none}:host(.vertical-host) .panel{padding-top:0;padding-left:var(--space-4);flex:1;min-width:0}\n"] }]
|
|
435
|
+
}, template: "@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_tabs-divider: var(--ds-tabs-divider, var(--border-divider));--_tab-padding-x: var(--ds-tab-padding-x, var(--space-4));--_tab-padding-y: var(--ds-tab-padding-y, var(--space-3));--_tab-padding-top: var(--ds-tab-padding-top, var(--_tab-padding-y));--_tab-padding-bottom: var(--ds-tab-padding-bottom, var(--_tab-padding-y));--_tab-label-font-weight: var(--ds-tab-label-font-weight, var(--font-weight-semibold));--_tab-label-font-size: var(--ds-tab-label-font-size, var(--font-size-s));--_tabs-gap: var(--ds-tabs-gap, var(--space-2));--_tabs-panel-padding-top: var(--ds-tabs-panel-padding-top, var(--space-3));--_tab-label-color: var(--ds-tab-label-color, var(--text-secondary));--_tab-label-color-hover: var(--ds-tab-label-color-hover, var(--text-primary));--_tab-label-color-active: var(--ds-tab-label-color-active, var(--accent));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--accent));--_tab-indicator-width: var(--ds-tab-indicator-width, var(--border-width-strong));--_tabs-pills-bg-color: var(--ds-tabs-pills-bg-color, var(--surface-secondary));--_tab-pill-bg-color-hover: var(--ds-tab-pill-bg-color-hover, var(--accent-subtitle));--_tab-pill-bg-color-active: var(--ds-tab-pill-bg-color-active, var(--surface-default));--_tab-pill-bg-color-active-hover: var(--ds-tab-pill-bg-color-active-hover, var(--accent-subtitle));--_tab-pill-label-color-active: var(--ds-tab-pill-label-color-active, var(--accent-strong));--_tab-pill-radius: var(--ds-tab-pill-radius, var(--ds-radius-control));--_tab-badge-bg-color: var(--ds-tab-badge-bg-color, var(--surface-secondary));--_tab-badge-label-color: var(--ds-tab-badge-label-color, var(--text-secondary));--_tab-close-icon-color: var(--ds-tab-close-icon-color, var(--text-tertiary));--_tab-close-bg-color-hover: var(--ds-tab-close-bg-color-hover, var(--surface-secondary));--_tabs-scroll-arrow-bg-color-hover: var(--ds-tabs-scroll-arrow-bg-color-hover, var(--surface-secondary));display:block}:host(.scrolling-host){display:grid;grid-template-columns:auto minmax(0,1fr) auto}:host(.scrolling-host)>.tabs{grid-column:2}:host(.scrolling-host)>.panel{grid-column:1/-1;min-width:0}.scroll-arrow{--_scroll-arrow-padding-bottom: calc(var(--_tab-padding-bottom) + var(--_tab-indicator-width) - var(--border-width-default));--_scroll-arrow-surface-shift: calc(var(--_scroll-arrow-padding-bottom) - var(--_tab-padding-top));--_tabs-scroll-arrow-icon-color-hover: var(--ds-tabs-scroll-arrow-icon-color-hover, var(--_tab-label-color-active));position:relative;isolation:isolate;contain:size;display:inline-flex;flex:none;align-items:center;justify-content:center;width:var(--hit-sm);padding:var(--_tab-padding-top) 0 var(--_scroll-arrow-padding-bottom);border:0;border-bottom:var(--border-width-default) solid var(--_tabs-divider);background:transparent;color:var(--_tab-label-color);cursor:pointer;transition:color var(--duration-fast) var(--ease-standard)}.scroll-arrow:before{content:\"\";position:absolute;inset:max(0px,-1 * var(--_scroll-arrow-surface-shift)) 0 max(0px,var(--_scroll-arrow-surface-shift));z-index:-1;border-radius:var(--ds-radius-control) var(--ds-radius-control) 0 0;transition:background-color var(--duration-fast) var(--ease-standard)}.scroll-arrow:hover{color:var(--_tabs-scroll-arrow-icon-color-hover)}.scroll-arrow:hover:before{background-color:var(--_tabs-scroll-arrow-bg-color-hover)}.scroll-arrow:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.scroll-arrow.at-edge{visibility:hidden}.scroll-arrow:dir(rtl) ds-icon{transform:scaleX(-1)}:host(.scrolling-host:has(> .pills)) .scroll-arrow{--_tabs-scroll-arrow-icon-color-hover: var(--ds-tabs-scroll-arrow-icon-color-hover, var(--_tab-pill-label-color-active));padding:0;border-bottom:0}:host(.scrolling-host:has(> .pills)) .scroll-arrow:before{inset:var(--space-1) 0;border-radius:var(--_tab-pill-radius)}.tabs{display:flex;gap:var(--_tabs-gap);border-bottom:var(--border-width-default) solid var(--_tabs-divider)}.tabs.scrollable{overflow-x:auto;scroll-behavior:smooth}@media(prefers-reduced-motion:reduce){.tabs.scrollable{scroll-behavior:auto}}.tabs.scrollable{--focus-ring-offset: calc(-1 * var(--focus-ring-width));flex-wrap:nowrap;scrollbar-width:none}.tabs.scrollable::-webkit-scrollbar{display:none}.tabs .tab{display:inline-flex;align-items:center;gap:var(--space-2);padding:var(--_tab-padding-top) var(--_tab-padding-x) var(--_tab-padding-bottom);border:0;background:transparent;font:var(--_tab-label-font-weight) var(--_tab-label-font-size)/var(--line-height-flat) var(--font-sans);color:var(--_tab-label-color);cursor:pointer;border-bottom:var(--_tab-indicator-width) solid transparent;margin-bottom:calc(-1 * var(--border-width-default));white-space:nowrap;flex-shrink:0;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard),border-color var(--duration-fast) var(--ease-standard)}.tabs .tab:hover{color:var(--_tab-label-color-hover)}.tabs .tab.active{color:var(--_tab-label-color-active);border-bottom-color:var(--_tab-indicator-color)}.tabs .tab .badge{min-width:var(--badge-count-size);height:var(--badge-count-size);padding:0 var(--space-1-5);display:inline-grid;place-items:center;border-radius:var(--radius-pill);font:var(--font-weight-bold) var(--font-size-2xs)/var(--line-height-base) var(--font-sans);letter-spacing:var(--letter-spacing-wide);white-space:nowrap;background:var(--_tab-badge-bg-color);color:var(--_tab-badge-label-color);margin-left:var(--space-1)}.tabs .tab .tab-close{display:inline-flex;align-items:center;justify-content:center;width:var(--icon-md);height:var(--icon-md);border-radius:var(--ds-radius-inner);color:var(--_tab-close-icon-color);margin-left:var(--space-1);cursor:pointer;transition:background-color var(--duration-fast) var(--ease-standard),color var(--duration-fast) var(--ease-standard)}.tabs .tab .tab-close:hover{background-color:var(--_tab-close-bg-color-hover);color:var(--text-primary)}.tabs .tab .tab-close:active{background-color:var(--surface-muted)}.tabs .tab:focus-visible{outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard);border-radius:var(--radius-sm)}.tabs .tab:active:not(:disabled,[disabled],.is-disabled){filter:brightness(var(--ds-press-brightness, .9));transform:scale(var(--ds-press-scale, .97))}.tabs .tab[disabled],.tabs .tab.disabled{color:var(--text-disabled);cursor:not-allowed}:host(.secondary){--_tab-label-color-active: var(--ds-tab-label-color-active, var(--secondary-strong));--_tab-indicator-color: var(--ds-tab-indicator-color, var(--secondary))}.tabs.pills{border-bottom:0;gap:var(--space-1);padding:var(--space-1);background-color:var(--_tabs-pills-bg-color);border-radius:var(--_tab-pill-radius);display:inline-flex}.tabs.pills .tab{padding:var(--space-2) var(--space-3);border-bottom:0;margin-bottom:0;border-radius:var(--_tab-pill-radius);color:var(--_tab-label-color)}.tabs.pills .tab:hover{background-color:var(--_tab-pill-bg-color-hover);color:var(--_tab-label-color-hover)}.tabs.pills .tab.active{background-color:var(--_tab-pill-bg-color-active);color:var(--_tab-pill-label-color-active);border-bottom:0}.tabs.pills .tab.active:not(:focus-visible){box-shadow:var(--shadow-1)}.tabs.pills .tab.active:hover{background-color:var(--_tab-pill-bg-color-active-hover)}.tabs.pills.scrollable{display:flex;width:100%}.tabs.vertical{flex-direction:column;border-bottom:0;border-right:var(--border-width-default) solid var(--_tabs-divider);gap:var(--space-1)}.tabs.vertical .tab{border-bottom:0;margin-bottom:0;border-right:var(--_tab-indicator-width) solid transparent;margin-right:calc(-1 * var(--border-width-default));text-align:left;justify-content:flex-start}.tabs.vertical .tab.active{color:var(--_tab-label-color-active);border-bottom-color:transparent;border-right-color:var(--_tab-indicator-color)}:host(.vertical-host){display:flex;flex-direction:row;align-items:flex-start;gap:var(--space-4)}.panel{padding-top:var(--_tabs-panel-padding-top)}.panel:empty{display:none}.panel[hidden]{display:none}:host(.vertical-host) .panel{padding-top:0;padding-left:var(--space-4);flex:1;min-width:0}\n"] }]
|
|
436
436
|
}], ctorParameters: () => [], propDecorators: { selectedIndex: [{ type: i0.Input, args: [{ isSignal: true, alias: "selectedIndex", required: false }] }, { type: i0.Output, args: ["selectedIndexChange"] }], variant: [{ type: i0.Input, args: [{ isSignal: true, alias: "variant", required: false }] }], lazy: [{ type: i0.Input, args: [{ isSignal: true, alias: "lazy", required: false }] }], scrollable: [{ type: i0.Input, args: [{ isSignal: true, alias: "scrollable", required: false }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], urlParam: [{ type: i0.Input, args: [{ isSignal: true, alias: "urlParam", required: false }] }], rememberLastTab: [{ type: i0.Input, args: [{ isSignal: true, alias: "rememberLastTab", required: false }] }], tabClosed: [{ type: i0.Output, args: ["tabClosed"] }], tablist: [{ type: i0.ViewChild, args: ['tablist', { isSignal: true }] }], tabs: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => TabComponent), { isSignal: true }] }] } });
|
|
437
437
|
|
|
438
438
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ids-group-ltd-ids-design-system-components-tabs.mjs","sources":["../../../src/lib/components/tabs/tab.component.ts","../../../src/lib/components/tabs/tabs.component.ts","../../../src/lib/components/tabs/tabs.component.html","../../../src/lib/components/tabs/ids-group-ltd-ids-design-system-components-tabs.ts"],"sourcesContent":["import {\n Component,\n TemplateRef,\n ViewEncapsulation,\n booleanAttribute,\n input,\n viewChild,\n} from '@angular/core';\nimport type { IconName } from '@ids-group-ltd/ids-design-system/core';\n\n@Component({\n selector: 'ds-tab',\n standalone: true,\n template: `<ng-template #content>\n <ng-content></ng-content>\n </ng-template>`,\n styles: [':host { display: none; }'],\n encapsulation: ViewEncapsulation.Emulated,\n})\nexport class TabComponent {\n /** Text shown in the tab button. */\n readonly label = input.required<string>();\n /** Icon shown before the label. */\n readonly icon = input<IconName | null>(null);\n /** Numeric badge shown after the label. */\n readonly count = input<number | null>(null);\n /** Excludes the tab from selection and keyboard navigation. */\n readonly disabled = input(false, { transform: booleanAttribute });\n /** Identifier emitted by tabClosed. Falls back to label when omitted. */\n readonly value = input<string | null>(null);\n readonly content = viewChild.required<TemplateRef<unknown>>('content');\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n Component,\n ElementRef,\n afterRenderEffect,\n ViewEncapsulation,\n booleanAttribute,\n computed,\n contentChildren,\n effect,\n inject,\n Injector,\n input,\n isDevMode,\n model,\n output,\n signal,\n viewChild,\n} from '@angular/core';\nimport { ActivatedRoute, Router, type ParamMap } from '@angular/router';\nimport { IconComponent } from '@ids-group-ltd/ids-design-system/icons';\nimport { DS_INTL } from '@ids-group-ltd/ids-design-system/core';\nimport { TabComponent } from './tab.component';\nimport type { TabsOrientation, TabsVariant } from './tabs.types';\n\nlet nextId = 0;\n\n// Which query parameters are already claimed, so two strips on one screen cannot\n// quietly fight over the same one. Dev-only bookkeeping; nothing reads it in\n// production.\nconst claimedUrlParams = new Map<string, number>();\n\n/** Label → URL name. Diacritics are decomposed and dropped so \"Zusätze\" gives\n * `zusatze` rather than a percent-encoded umlaut. A label with nothing sluggable\n * in it — CJK, or bare punctuation — keeps its raw text rather than becoming an\n * empty parameter. */\nfunction slugify(label: string): string {\n const slug = label\n .normalize('NFKD')\n .replace(/\\p{M}/gu, '')\n .toLowerCase()\n .replace(/[^a-z0-9]+/g, '-')\n .replace(/^-+|-+$/g, '');\n\n return slug || label;\n}\n\n@Component({\n selector: 'ds-tabs',\n standalone: true,\n imports: [NgTemplateOutlet, IconComponent],\n templateUrl: './tabs.component.html',\n styleUrl: './tabs.component.scss',\n encapsulation: ViewEncapsulation.Emulated,\n host: {\n '[class.vertical-host]': \"orientation() === 'vertical'\",\n '[class.scrolling-host]': 'scrollsHorizontally()',\n },\n})\nexport class TabsComponent {\n protected readonly intl = inject(DS_INTL);\n\n /** Index of the active tab, two-way bound. */\n readonly selectedIndex = model<number>(0);\n /** Visual style of the tab strip. */\n readonly variant = input<TabsVariant>('line');\n\n /** When true, a tab's content is instantiated only on first activation and\n kept alive thereafter. When false (default), all panels render eagerly. */\n readonly lazy = input(false, { transform: booleanAttribute });\n\n /** When true, a horizontal strip scrolls inside its own box and shows\n previous/next arrows while tabs lie beyond its edges, each arrow hidden at\n its own edge. The active tab is scrolled into view on selection. When\n false, tabs keep their width and a strip too long for its container\n overflows it. */\n readonly scrollable = input(false, { transform: booleanAttribute });\n\n /** When true, each tab shows a close button. Clicking it emits tabClosed with\n the tab's value (or label as fallback) and does not switch to that tab. */\n readonly closable = input(false, { transform: booleanAttribute });\n\n /** Controls whether the tab list and panel are stacked horizontally (default)\n or the tab list runs vertically beside the panel. */\n readonly orientation = input<TabsOrientation>('horizontal');\n\n /**\n * Keep the active tab in a query parameter, so it survives F5, a shared link\n * and the Back button: `urlParam=\"tab\"` gives `?tab=activity`. Empty (the\n * default) leaves the URL alone, and the strip works exactly as before.\n *\n * The names come from each `ds-tab`'s `value` (falling back to its `label`),\n * so there is no second list to keep in step. **Names, not indices** — writing\n * `?tab=1` would silently repoint every old link the moment a tab is inserted.\n * The FIRST tab writes no parameter and every write REPLACES the history\n * entry, so a pristine screen keeps a clean address and flipping tabs does not\n * fill the Back button.\n *\n * An unknown or missing name lands on the first tab rather than throwing: a\n * URL is user input, and a stale bookmark should still open the screen.\n *\n * Outside a routed context the input is inert. Nothing router-shaped is even\n * resolved until you set it — no DI lookup and, more to the point, no\n * subscription — so a strip that never uses this costs exactly what it did\n * before the input existed.\n */\n readonly urlParam = input<string>('');\n\n /** Reopen the tab this screen was last left on, per path, from `sessionStorage`.\n * Off by default, and needs `urlParam` for the names — a remembered INDEX would\n * repoint the moment a tab is inserted. A link always wins: the parameter is read\n * first, memory only fills the gap the first tab leaves in the URL. Session, not\n * local, so tomorrow is a fresh visit. */\n readonly rememberLastTab = input(false, { transform: booleanAttribute });\n\n /** Emitted when a close button is clicked. Carries the tab's value input, or\n its label when value is not set. The host is responsible for removing the\n tab from its list. */\n readonly tabClosed = output<string>();\n\n private readonly host = inject(ElementRef<HTMLElement>);\n private readonly uid = `ds-tabs-${++nextId}`;\n private readonly tablist =\n viewChild.required<ElementRef<HTMLElement>>('tablist');\n\n protected readonly scrollsHorizontally = computed(\n () => this.scrollable() && this.orientation() === 'horizontal',\n );\n private readonly overflowing = signal(false);\n protected readonly showScrollArrows = computed(\n () => this.scrollsHorizontally() && this.overflowing(),\n );\n protected readonly canScrollPrevious = signal(false);\n protected readonly canScrollNext = signal(false);\n\n protected readonly tabs = contentChildren(TabComponent);\n\n // Nothing router-shaped is touched until `urlParam` is set: no DI lookup, and\n // above all no subscription. A tab strip is perfectly valid outside a routed\n // context — in a dialog, on a static page — and most are, so the default must\n // cost nothing. Resolved through the component's own Injector rather than\n // `inject(Router)` at construction, which would run for every instance.\n private readonly injector = inject(Injector);\n private router: Router | null = null;\n private route: ActivatedRoute | null = null;\n private readonly urlParams = signal<ParamMap | null>(null);\n\n constructor() {\n afterRenderEffect((onCleanup) => {\n this.tabs();\n if (!this.scrollsHorizontally()) {\n this.overflowing.set(false);\n\n return;\n }\n const strip = this.tablist().nativeElement;\n const observer = new ResizeObserver(() => this.updateScrollArrows());\n observer.observe(strip);\n observer.observe(strip.parentElement!);\n for (const tab of Array.from(strip.children)) {\n observer.observe(tab);\n }\n onCleanup(() => observer.disconnect());\n });\n\n /**\n * Two strips sharing a parameter is the failure mode of going round a screen\n * turning this on: `tab` is the obvious name, so the second strip takes it\n * too, and from then on each write erases the other's tab. Nothing throws and\n * the URL looks plausible — it just restores the wrong tab on reload.\n */\n if (isDevMode()) {\n effect((onCleanup) => {\n const param = this.urlParam();\n if (!param) {\n return;\n }\n const held = claimedUrlParams.get(param) ?? 0;\n if (held > 0) {\n console.warn(\n `[ds-tabs] urlParam=\"${param}\" is already used by another ds-tabs on this screen. Both strips write the same query parameter, so each one erases the other's tab and a reload restores whichever wrote last. Give each strip its own name.`,\n );\n }\n claimedUrlParams.set(param, held + 1);\n // onCleanup alone: it runs before every re-run AND on destroy, so\n // releasing again from a DestroyRef would double-count the way out.\n onCleanup(() => {\n const now = (claimedUrlParams.get(param) ?? 1) - 1;\n if (now > 0) {\n claimedUrlParams.set(param, now);\n } else {\n claimedUrlParams.delete(param);\n }\n });\n });\n }\n\n // Subscribe only while the feature is on, and drop the subscription again if\n // `urlParam` is cleared.\n effect((onCleanup) => {\n if (!this.urlParam() || !this.resolveRouting()) {\n this.urlParams.set(null);\n\n return;\n }\n const subscription = this.route!.queryParamMap.subscribe((map) =>\n this.urlParams.set(map),\n );\n onCleanup(() => subscription.unsubscribe());\n });\n\n // URL -> tab. Runs again when the tabs arrive (content children resolve\n // after the first pass) and on every Back/Forward, which is what makes the\n // history walk the tabs. Writing back is guarded by the equality check\n // below, so this cannot loop with `writeUrl`.\n effect(() => {\n const param = this.urlParam();\n const params = this.urlParams();\n const tabs = this.tabs();\n if (!param || !params || tabs.length === 0) {\n return;\n }\n const target = params.get(param) ?? this.rememberedName();\n const found = target\n ? tabs.findIndex((tab) => this.tabName(tab) === target)\n : 0;\n const index = found < 0 ? 0 : found;\n if (index !== this.selectedIndex()) {\n this.selectedIndex.set(index);\n }\n });\n }\n\n /** Resolves the router pair on first use. Null outside a routed context, which\n * makes `urlParam` inert there rather than an error. */\n private resolveRouting(): boolean {\n this.router ??= this.injector.get(Router, null);\n this.route ??= this.injector.get(ActivatedRoute, null);\n\n return !!this.router && !!this.route;\n }\n\n /** The tab's name AS IT APPEARS IN THE URL, and deliberately NOT what\n * `tabClosed` emits — that stays the label, because a host matches it against\n * its own list. A slug is still derived from display copy, so renaming a tab\n * still breaks saved links; `value` is the only fix for that. */\n private tabName(tab: TabComponent): string {\n return tab.value() ?? slugify(tab.label());\n }\n\n /** Storage key for `rememberLastTab`: the path plus the parameter name. Per\n * path because that is the screen a reader returns to, and the parameter is\n * what keeps two strips on one path apart — which the dev warning above\n * already insists is unique. */\n private memoryKey(): string | null {\n const param = this.urlParam();\n if (!this.rememberLastTab() || !param || !this.resolveRouting()) {\n return null;\n }\n\n return `ds-tabs:${this.router!.url.split('?')[0]}:${param}`;\n }\n\n /** Every access is wrapped: Safari in private mode throws on write, and a\n * quota error must not take a tab strip down with it. Same guard as\n * `ds-table`'s persisted layout. */\n private rememberedName(): string | null {\n const key = this.memoryKey();\n if (!key) {\n return null;\n }\n try {\n return sessionStorage.getItem(key);\n } catch {\n return null;\n }\n }\n\n private remember(index: number): void {\n const key = this.memoryKey();\n const tab = this.tabs()[index];\n if (!key || !tab) {\n return;\n }\n try {\n // Stored for the first tab too, which writes no parameter: without that,\n // deliberately going back to tab one would be forgotten and the next visit\n // would reopen the tab before it.\n sessionStorage.setItem(key, this.tabName(tab));\n } catch {\n // Storage unavailable — the strip simply stops remembering.\n }\n }\n\n private writeUrl(index: number): void {\n this.remember(index);\n const param = this.urlParam();\n if (!param || !this.resolveRouting()) {\n return;\n }\n const tab = this.tabs()[index];\n void this.router!.navigate([], {\n relativeTo: this.route,\n queryParams: { [param]: index === 0 || !tab ? null : this.tabName(tab) },\n queryParamsHandling: 'merge',\n replaceUrl: true,\n });\n }\n\n /** Tracks which tab indices have ever been activated (for lazy rendering). */\n private readonly activatedIndices = signal<ReadonlySet<number>>(new Set([0]));\n\n protected tabId(index: number): string {\n return `${this.uid}-tab-${index}`;\n }\n\n protected panelId(index: number): string {\n return `${this.uid}-panel-${index}`;\n }\n\n protected readonly tablistClasses = computed(() => {\n const parts = ['tabs'];\n if (this.variant() === 'pills') {\n parts.push('pills');\n }\n if (this.scrollable()) {\n parts.push('scrollable');\n }\n if (this.orientation() === 'vertical') {\n parts.push('vertical');\n }\n\n return parts.join(' ');\n });\n\n /** Whether the panel for a given index should be rendered (lazy gate). */\n protected isPanelVisible(index: number): boolean {\n if (!this.lazy()) {\n return index === this.selectedIndex();\n }\n\n return this.activatedIndices().has(index);\n }\n\n protected tabClasses(index: number, disabled: boolean): string {\n const parts = ['tab'];\n if (index === this.selectedIndex()) {\n parts.push('active');\n }\n if (disabled) {\n parts.push('disabled');\n }\n\n return parts.join(' ');\n }\n\n protected select(index: number, disabled: boolean): void {\n if (disabled) {\n return;\n }\n this.selectedIndex.set(index);\n this.writeUrl(index);\n if (this.lazy()) {\n this.activatedIndices.update((previous) => {\n if (previous.has(index)) {\n return previous;\n }\n\n return new Set([...previous, index]);\n });\n }\n if (this.scrollable()) {\n setTimeout(() => {\n const button = this.host.nativeElement.querySelector(\n `#${this.tabId(index)}`,\n ) as HTMLElement | null;\n button?.scrollIntoView({ block: 'nearest', inline: 'nearest' });\n });\n }\n }\n\n protected updateScrollArrows(): void {\n const strip = this.tablist().nativeElement;\n const scrolled = Math.abs(strip.scrollLeft);\n const hidden = strip.scrollWidth - strip.clientWidth;\n // Against the row, not the strip: the arrows narrow the strip, and a strip\n // measured against its own width would keep them for tabs that fit without them.\n this.overflowing.set(\n strip.scrollWidth > strip.parentElement!.clientWidth + 1,\n );\n this.canScrollPrevious.set(scrolled > 1);\n this.canScrollNext.set(scrolled < hidden - 1);\n }\n\n protected scrollPage(towardEnd: boolean): void {\n const strip = this.tablist().nativeElement;\n const mirror = getComputedStyle(strip).direction === 'rtl' ? -1 : 1;\n const inlineStart = (rect: DOMRect): number =>\n mirror === 1 ? rect.left : -rect.right;\n const inlineEnd = (rect: DOMRect): number =>\n mirror === 1 ? rect.right : -rect.left;\n const view = strip.getBoundingClientRect();\n const tabRects = Array.from(strip.children, (tab) =>\n tab.getBoundingClientRect(),\n );\n const step = towardEnd ? 1 : -1;\n let distance = 0;\n if (towardEnd) {\n const next = tabRects.find(\n (rect) => inlineEnd(rect) > inlineEnd(view) + 1,\n );\n distance = next ? inlineStart(next) - inlineStart(view) : 0;\n } else {\n const previous = tabRects\n .reverse()\n .find((rect) => inlineStart(rect) < inlineStart(view) - 1);\n distance = previous ? inlineEnd(previous) - inlineEnd(view) : 0;\n }\n // A tab wider than the strip is already aligned, so move a full width.\n if (distance * step < 1) {\n distance = step * strip.clientWidth;\n }\n strip.scrollBy({ left: mirror * distance });\n }\n\n protected onCloseClick(event: MouseEvent, index: number): void {\n event.stopPropagation();\n this.closeTab(index);\n }\n\n private closeTab(index: number): void {\n const tab = this.tabs()[index];\n if (!tab) {\n return;\n }\n this.tabClosed.emit(tab.value() ?? tab.label());\n }\n\n /** Roving keyboard navigation across the tablist (APG automatic activation).\n Arrow axis follows orientation: Left/Right for horizontal, Up/Down for vertical. */\n protected onKeydown(event: KeyboardEvent, index: number): void {\n const count = this.tabs().length;\n if (!count) {\n return;\n }\n // APG: Delete removes the focused tab when the tablist is closable.\n if (this.closable() && event.key === 'Delete') {\n event.preventDefault();\n this.closeTab(index);\n\n return;\n }\n const isVertical = this.orientation() === 'vertical';\n const forwardKey = isVertical ? 'ArrowDown' : 'ArrowRight';\n const backwardKey = isVertical ? 'ArrowUp' : 'ArrowLeft';\n // Keep both axes active so vertical also responds to Left/Right and\n // horizontal also responds to Up/Down for cross-axis discoverability,\n // matching the ARIA APG recommendation for roving tabindex.\n const forward =\n event.key === forwardKey ||\n (!isVertical && event.key === 'ArrowDown') ||\n (isVertical && event.key === 'ArrowRight');\n const backward =\n event.key === backwardKey ||\n (!isVertical && event.key === 'ArrowUp') ||\n (isVertical && event.key === 'ArrowLeft');\n\n let next: number;\n if (forward) {\n next = (index + 1) % count;\n } else if (backward) {\n next = (index - 1 + count) % count;\n } else if (event.key === 'Home') {\n next = 0;\n } else if (event.key === 'End') {\n next = count - 1;\n } else {\n return;\n }\n event.preventDefault();\n // Skip disabled tabs in the travel direction.\n const step = backward || event.key === 'End' ? -1 : 1;\n let guard = 0;\n while (this.tabs()[next]?.disabled() && guard < count) {\n next = (next + step + count) % count;\n guard++;\n }\n this.select(next, this.tabs()[next]?.disabled() ?? false);\n setTimeout(() => {\n const element = this.host.nativeElement.querySelector(\n `#${this.tabId(next)}`,\n ) as HTMLElement | null;\n element?.focus();\n });\n }\n}\n","@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;MAmBa,YAAY,CAAA;;AAEd,IAAA,KAAK,GAAG,KAAK,CAAC,QAAQ,2EAAU;;AAEhC,IAAA,IAAI,GAAG,KAAK,CAAkB,IAAI,2EAAC;;AAEnC,IAAA,KAAK,GAAG,KAAK,CAAgB,IAAI,4EAAC;;IAElC,QAAQ,GAAG,KAAK,CAAC,KAAK,gFAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;;AAExD,IAAA,KAAK,GAAG,KAAK,CAAgB,IAAI,4EAAC;AAClC,IAAA,OAAO,GAAG,SAAS,CAAC,QAAQ,CAAuB,SAAS,CAAC;wGAX3D,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAZ,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,YAAY,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,QAAA,EAAA,MAAA,EAAA,EAAA,KAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,IAAA,EAAA,EAAA,iBAAA,EAAA,MAAA,EAAA,UAAA,EAAA,MAAA,EAAA,QAAA,EAAA,IAAA,EAA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AAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,WAAA,CAAA,EAAA,CAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,SAAS,wFAYb,YAAY,CAAA,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AEvIxD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ids-group-ltd-ids-design-system-components-tabs.mjs","sources":["../../../src/lib/components/tabs/tab.component.ts","../../../src/lib/components/tabs/tabs.component.ts","../../../src/lib/components/tabs/tabs.component.html","../../../src/lib/components/tabs/ids-group-ltd-ids-design-system-components-tabs.ts"],"sourcesContent":["import {\n Component,\n TemplateRef,\n ViewEncapsulation,\n booleanAttribute,\n input,\n viewChild,\n} from '@angular/core';\nimport type { IconName } from '@ids-group-ltd/ids-design-system/core';\n\n@Component({\n selector: 'ds-tab',\n standalone: true,\n template: `<ng-template #content>\n <ng-content></ng-content>\n </ng-template>`,\n styles: [':host { display: none; }'],\n encapsulation: ViewEncapsulation.Emulated,\n})\nexport class TabComponent {\n /** Text shown in the tab button. */\n readonly label = input.required<string>();\n /** Icon shown before the label. */\n readonly icon = input<IconName | null>(null);\n /** Numeric badge shown after the label. */\n readonly count = input<number | null>(null);\n /** Excludes the tab from selection and keyboard navigation. */\n readonly disabled = input(false, { transform: booleanAttribute });\n /** Identifier emitted by tabClosed. Falls back to label when omitted. */\n readonly value = input<string | null>(null);\n readonly content = viewChild.required<TemplateRef<unknown>>('content');\n}\n","import { NgTemplateOutlet } from '@angular/common';\nimport {\n Component,\n ElementRef,\n afterRenderEffect,\n ViewEncapsulation,\n booleanAttribute,\n computed,\n contentChildren,\n effect,\n inject,\n Injector,\n input,\n isDevMode,\n model,\n output,\n signal,\n viewChild,\n} from '@angular/core';\nimport { ActivatedRoute, Router, type ParamMap } from '@angular/router';\nimport { IconComponent } from '@ids-group-ltd/ids-design-system/icons';\nimport { DS_INTL } from '@ids-group-ltd/ids-design-system/core';\nimport { TabComponent } from './tab.component';\nimport type { TabsOrientation, TabsVariant } from './tabs.types';\n\nlet nextId = 0;\n\n// Which query parameters are already claimed, so two strips on one screen cannot\n// quietly fight over the same one. Dev-only bookkeeping; nothing reads it in\n// production.\nconst claimedUrlParams = new Map<string, number>();\n\n/** Label → URL name. Diacritics are decomposed and dropped so \"Zusätze\" gives\n * `zusatze` rather than a percent-encoded umlaut. A label with nothing sluggable\n * in it — CJK, or bare punctuation — keeps its raw text rather than becoming an\n * empty parameter. */\nfunction slugify(label: string): string {\n const slug = label\n .normalize('NFKD')\n .replace(/\\p{M}/gu, '')\n .toLowerCase()\n .replace(/[^a-z0-9]+/g, '-')\n .replace(/^-+|-+$/g, '');\n\n return slug || label;\n}\n\n@Component({\n selector: 'ds-tabs',\n standalone: true,\n imports: [NgTemplateOutlet, IconComponent],\n templateUrl: './tabs.component.html',\n styleUrl: './tabs.component.scss',\n encapsulation: ViewEncapsulation.Emulated,\n host: {\n '[class.vertical-host]': \"orientation() === 'vertical'\",\n '[class.scrolling-host]': 'scrollsHorizontally()',\n },\n})\nexport class TabsComponent {\n protected readonly intl = inject(DS_INTL);\n\n /** Index of the active tab, two-way bound. */\n readonly selectedIndex = model<number>(0);\n /** Visual style of the tab strip. */\n readonly variant = input<TabsVariant>('line');\n\n /** When true, a tab's content is instantiated only on first activation and\n kept alive thereafter. When false (default), all panels render eagerly. */\n readonly lazy = input(false, { transform: booleanAttribute });\n\n /** When true, a horizontal strip scrolls inside its own box and shows\n previous/next arrows while tabs lie beyond its edges, each arrow hidden at\n its own edge. The active tab is scrolled into view on selection. When\n false, tabs keep their width and a strip too long for its container\n overflows it. */\n readonly scrollable = input(false, { transform: booleanAttribute });\n\n /** When true, each tab shows a close button. Clicking it emits tabClosed with\n the tab's value (or label as fallback) and does not switch to that tab. */\n readonly closable = input(false, { transform: booleanAttribute });\n\n /** Controls whether the tab list and panel are stacked horizontally (default)\n or the tab list runs vertically beside the panel. */\n readonly orientation = input<TabsOrientation>('horizontal');\n\n /**\n * Keep the active tab in a query parameter, so it survives F5, a shared link\n * and the Back button: `urlParam=\"tab\"` gives `?tab=activity`. Empty (the\n * default) leaves the URL alone, and the strip works exactly as before.\n *\n * The names come from each `ds-tab`'s `value` (falling back to its `label`),\n * so there is no second list to keep in step. **Names, not indices** — writing\n * `?tab=1` would silently repoint every old link the moment a tab is inserted.\n * The FIRST tab writes no parameter and every write REPLACES the history\n * entry, so a pristine screen keeps a clean address and flipping tabs does not\n * fill the Back button.\n *\n * An unknown or missing name lands on the first tab rather than throwing: a\n * URL is user input, and a stale bookmark should still open the screen.\n *\n * Outside a routed context the input is inert. Nothing router-shaped is even\n * resolved until you set it — no DI lookup and, more to the point, no\n * subscription — so a strip that never uses this costs exactly what it did\n * before the input existed.\n */\n readonly urlParam = input<string>('');\n\n /** Reopen the tab this screen was last left on, per path, from `sessionStorage`.\n * Off by default, and needs `urlParam` for the names — a remembered INDEX would\n * repoint the moment a tab is inserted. A link always wins: the parameter is read\n * first, memory only fills the gap the first tab leaves in the URL. Session, not\n * local, so tomorrow is a fresh visit. */\n readonly rememberLastTab = input(false, { transform: booleanAttribute });\n\n /** Emitted when a close button is clicked. Carries the tab's value input, or\n its label when value is not set. The host is responsible for removing the\n tab from its list. */\n readonly tabClosed = output<string>();\n\n private readonly host = inject(ElementRef<HTMLElement>);\n private readonly uid = `ds-tabs-${++nextId}`;\n private readonly tablist =\n viewChild.required<ElementRef<HTMLElement>>('tablist');\n\n protected readonly scrollsHorizontally = computed(\n () => this.scrollable() && this.orientation() === 'horizontal',\n );\n private readonly overflowing = signal(false);\n protected readonly showScrollArrows = computed(\n () => this.scrollsHorizontally() && this.overflowing(),\n );\n protected readonly canScrollPrevious = signal(false);\n protected readonly canScrollNext = signal(false);\n\n protected readonly tabs = contentChildren(TabComponent);\n\n // Nothing router-shaped is touched until `urlParam` is set: no DI lookup, and\n // above all no subscription. A tab strip is perfectly valid outside a routed\n // context — in a dialog, on a static page — and most are, so the default must\n // cost nothing. Resolved through the component's own Injector rather than\n // `inject(Router)` at construction, which would run for every instance.\n private readonly injector = inject(Injector);\n private router: Router | null = null;\n private route: ActivatedRoute | null = null;\n private readonly urlParams = signal<ParamMap | null>(null);\n\n constructor() {\n afterRenderEffect((onCleanup) => {\n this.tabs();\n if (!this.scrollsHorizontally()) {\n this.overflowing.set(false);\n\n return;\n }\n const strip = this.tablist().nativeElement;\n const observer = new ResizeObserver(() => this.updateScrollArrows());\n observer.observe(strip);\n observer.observe(strip.parentElement!);\n for (const tab of Array.from(strip.children)) {\n observer.observe(tab);\n }\n onCleanup(() => observer.disconnect());\n });\n\n /**\n * Two strips sharing a parameter is the failure mode of going round a screen\n * turning this on: `tab` is the obvious name, so the second strip takes it\n * too, and from then on each write erases the other's tab. Nothing throws and\n * the URL looks plausible — it just restores the wrong tab on reload.\n */\n if (isDevMode()) {\n effect((onCleanup) => {\n const param = this.urlParam();\n if (!param) {\n return;\n }\n const held = claimedUrlParams.get(param) ?? 0;\n if (held > 0) {\n console.warn(\n `[ds-tabs] urlParam=\"${param}\" is already used by another ds-tabs on this screen. Both strips write the same query parameter, so each one erases the other's tab and a reload restores whichever wrote last. Give each strip its own name.`,\n );\n }\n claimedUrlParams.set(param, held + 1);\n // onCleanup alone: it runs before every re-run AND on destroy, so\n // releasing again from a DestroyRef would double-count the way out.\n onCleanup(() => {\n const now = (claimedUrlParams.get(param) ?? 1) - 1;\n if (now > 0) {\n claimedUrlParams.set(param, now);\n } else {\n claimedUrlParams.delete(param);\n }\n });\n });\n }\n\n // Subscribe only while the feature is on, and drop the subscription again if\n // `urlParam` is cleared.\n effect((onCleanup) => {\n if (!this.urlParam() || !this.resolveRouting()) {\n this.urlParams.set(null);\n\n return;\n }\n const subscription = this.route!.queryParamMap.subscribe((map) =>\n this.urlParams.set(map),\n );\n onCleanup(() => subscription.unsubscribe());\n });\n\n // URL -> tab. Runs again when the tabs arrive (content children resolve\n // after the first pass) and on every Back/Forward, which is what makes the\n // history walk the tabs. Writing back is guarded by the equality check\n // below, so this cannot loop with `writeUrl`.\n effect(() => {\n const param = this.urlParam();\n const params = this.urlParams();\n const tabs = this.tabs();\n if (!param || !params || tabs.length === 0) {\n return;\n }\n const target = params.get(param) ?? this.rememberedName();\n const found = target\n ? tabs.findIndex((tab) => this.tabName(tab) === target)\n : 0;\n const index = found < 0 ? 0 : found;\n if (index !== this.selectedIndex()) {\n this.selectedIndex.set(index);\n }\n });\n }\n\n /** Resolves the router pair on first use. Null outside a routed context, which\n * makes `urlParam` inert there rather than an error. */\n private resolveRouting(): boolean {\n this.router ??= this.injector.get(Router, null);\n this.route ??= this.injector.get(ActivatedRoute, null);\n\n return !!this.router && !!this.route;\n }\n\n /** The tab's name AS IT APPEARS IN THE URL, and deliberately NOT what\n * `tabClosed` emits — that stays the label, because a host matches it against\n * its own list. A slug is still derived from display copy, so renaming a tab\n * still breaks saved links; `value` is the only fix for that. */\n private tabName(tab: TabComponent): string {\n return tab.value() ?? slugify(tab.label());\n }\n\n /** Storage key for `rememberLastTab`: the path plus the parameter name. Per\n * path because that is the screen a reader returns to, and the parameter is\n * what keeps two strips on one path apart — which the dev warning above\n * already insists is unique. */\n private memoryKey(): string | null {\n const param = this.urlParam();\n if (!this.rememberLastTab() || !param || !this.resolveRouting()) {\n return null;\n }\n\n return `ds-tabs:${this.router!.url.split('?')[0]}:${param}`;\n }\n\n /** Every access is wrapped: Safari in private mode throws on write, and a\n * quota error must not take a tab strip down with it. Same guard as\n * `ds-table`'s persisted layout. */\n private rememberedName(): string | null {\n const key = this.memoryKey();\n if (!key) {\n return null;\n }\n try {\n return sessionStorage.getItem(key);\n } catch {\n return null;\n }\n }\n\n private remember(index: number): void {\n const key = this.memoryKey();\n const tab = this.tabs()[index];\n if (!key || !tab) {\n return;\n }\n try {\n // Stored for the first tab too, which writes no parameter: without that,\n // deliberately going back to tab one would be forgotten and the next visit\n // would reopen the tab before it.\n sessionStorage.setItem(key, this.tabName(tab));\n } catch {\n // Storage unavailable — the strip simply stops remembering.\n }\n }\n\n private writeUrl(index: number): void {\n this.remember(index);\n const param = this.urlParam();\n if (!param || !this.resolveRouting()) {\n return;\n }\n const tab = this.tabs()[index];\n void this.router!.navigate([], {\n relativeTo: this.route,\n queryParams: { [param]: index === 0 || !tab ? null : this.tabName(tab) },\n queryParamsHandling: 'merge',\n replaceUrl: true,\n });\n }\n\n /** Tracks which tab indices have ever been activated (for lazy rendering). */\n private readonly activatedIndices = signal<ReadonlySet<number>>(new Set([0]));\n\n protected tabId(index: number): string {\n return `${this.uid}-tab-${index}`;\n }\n\n protected panelId(index: number): string {\n return `${this.uid}-panel-${index}`;\n }\n\n protected readonly tablistClasses = computed(() => {\n const parts = ['tabs'];\n if (this.variant() === 'pills') {\n parts.push('pills');\n }\n if (this.scrollable()) {\n parts.push('scrollable');\n }\n if (this.orientation() === 'vertical') {\n parts.push('vertical');\n }\n\n return parts.join(' ');\n });\n\n /** Whether the panel for a given index should be rendered (lazy gate). */\n protected isPanelVisible(index: number): boolean {\n if (!this.lazy()) {\n return index === this.selectedIndex();\n }\n\n return this.activatedIndices().has(index);\n }\n\n protected tabClasses(index: number, disabled: boolean): string {\n const parts = ['tab'];\n if (index === this.selectedIndex()) {\n parts.push('active');\n }\n if (disabled) {\n parts.push('disabled');\n }\n\n return parts.join(' ');\n }\n\n protected select(index: number, disabled: boolean): void {\n if (disabled) {\n return;\n }\n this.selectedIndex.set(index);\n this.writeUrl(index);\n if (this.lazy()) {\n this.activatedIndices.update((previous) => {\n if (previous.has(index)) {\n return previous;\n }\n\n return new Set([...previous, index]);\n });\n }\n if (this.scrollable()) {\n setTimeout(() => {\n const button = this.host.nativeElement.querySelector(\n `#${this.tabId(index)}`,\n ) as HTMLElement | null;\n button?.scrollIntoView({ block: 'nearest', inline: 'nearest' });\n });\n }\n }\n\n protected updateScrollArrows(): void {\n const strip = this.tablist().nativeElement;\n const scrolled = Math.abs(strip.scrollLeft);\n const hidden = strip.scrollWidth - strip.clientWidth;\n // Against the row, not the strip: the arrows narrow the strip, and a strip\n // measured against its own width would keep them for tabs that fit without them.\n this.overflowing.set(\n strip.scrollWidth > strip.parentElement!.clientWidth + 1,\n );\n this.canScrollPrevious.set(scrolled > 1);\n this.canScrollNext.set(scrolled < hidden - 1);\n }\n\n protected scrollPage(towardEnd: boolean): void {\n const strip = this.tablist().nativeElement;\n const mirror = getComputedStyle(strip).direction === 'rtl' ? -1 : 1;\n const inlineStart = (rect: DOMRect): number =>\n mirror === 1 ? rect.left : -rect.right;\n const inlineEnd = (rect: DOMRect): number =>\n mirror === 1 ? rect.right : -rect.left;\n const view = strip.getBoundingClientRect();\n const tabRects = Array.from(strip.children, (tab) =>\n tab.getBoundingClientRect(),\n );\n const step = towardEnd ? 1 : -1;\n let distance = 0;\n if (towardEnd) {\n const next = tabRects.find(\n (rect) => inlineEnd(rect) > inlineEnd(view) + 1,\n );\n distance = next ? inlineStart(next) - inlineStart(view) : 0;\n } else {\n const previous = tabRects\n .reverse()\n .find((rect) => inlineStart(rect) < inlineStart(view) - 1);\n distance = previous ? inlineEnd(previous) - inlineEnd(view) : 0;\n }\n // A tab wider than the strip is already aligned, so move a full width.\n if (distance * step < 1) {\n distance = step * strip.clientWidth;\n }\n strip.scrollBy({ left: mirror * distance });\n }\n\n protected onCloseClick(event: MouseEvent, index: number): void {\n event.stopPropagation();\n this.closeTab(index);\n }\n\n private closeTab(index: number): void {\n const tab = this.tabs()[index];\n if (!tab) {\n return;\n }\n this.tabClosed.emit(tab.value() ?? tab.label());\n }\n\n /** Roving keyboard navigation across the tablist (APG automatic activation).\n Arrow axis follows orientation: Left/Right for horizontal, Up/Down for vertical. */\n protected onKeydown(event: KeyboardEvent, index: number): void {\n const count = this.tabs().length;\n if (!count) {\n return;\n }\n // APG: Delete removes the focused tab when the tablist is closable.\n if (this.closable() && event.key === 'Delete') {\n event.preventDefault();\n this.closeTab(index);\n\n return;\n }\n const isVertical = this.orientation() === 'vertical';\n const forwardKey = isVertical ? 'ArrowDown' : 'ArrowRight';\n const backwardKey = isVertical ? 'ArrowUp' : 'ArrowLeft';\n // Keep both axes active so vertical also responds to Left/Right and\n // horizontal also responds to Up/Down for cross-axis discoverability,\n // matching the ARIA APG recommendation for roving tabindex.\n const forward =\n event.key === forwardKey ||\n (!isVertical && event.key === 'ArrowDown') ||\n (isVertical && event.key === 'ArrowRight');\n const backward =\n event.key === backwardKey ||\n (!isVertical && event.key === 'ArrowUp') ||\n (isVertical && event.key === 'ArrowLeft');\n\n let next: number;\n if (forward) {\n next = (index + 1) % count;\n } else if (backward) {\n next = (index - 1 + count) % count;\n } else if (event.key === 'Home') {\n next = 0;\n } else if (event.key === 'End') {\n next = count - 1;\n } else {\n return;\n }\n event.preventDefault();\n // Skip disabled tabs in the travel direction.\n const step = backward || event.key === 'End' ? -1 : 1;\n let guard = 0;\n while (this.tabs()[next]?.disabled() && guard < count) {\n next = (next + step + count) % count;\n guard++;\n }\n this.select(next, this.tabs()[next]?.disabled() ?? false);\n setTimeout(() => {\n const element = this.host.nativeElement.querySelector(\n `#${this.tabId(next)}`,\n ) as HTMLElement | null;\n element?.focus();\n });\n }\n}\n","@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollPrevious()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(false)\">\n <ds-icon\n name=\"chevronLeft\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n<div\n #tablist\n role=\"tablist\"\n [class]=\"tablistClasses()\"\n [attr.aria-orientation]=\"orientation()\"\n (scroll)=\"updateScrollArrows()\">\n @for (tab of tabs(); track $index) {\n <button\n type=\"button\"\n role=\"tab\"\n [id]=\"tabId($index)\"\n [class]=\"tabClasses($index, tab.disabled())\"\n [attr.aria-selected]=\"$index === selectedIndex()\"\n [attr.aria-controls]=\"panelId($index)\"\n [attr.tabindex]=\"$index === selectedIndex() ? 0 : -1\"\n [disabled]=\"tab.disabled()\"\n (click)=\"select($index, tab.disabled())\"\n (keydown)=\"onKeydown($event, $index)\">\n @if (tab.icon()) {\n <ds-icon\n [name]=\"tab.icon()!\"\n [size]=\"14\">\n </ds-icon>\n }\n\n <span>\n {{ tab.label() }}\n </span>\n\n @if (tab.count() !== null) {\n <span class=\"badge\">\n {{ tab.count() }}\n </span>\n }\n\n @if (closable()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -- mouse affordance; keyboard closes the focused tab via Delete (see onKeydown) -->\n <span\n class=\"tab-close\"\n [attr.aria-label]=\"intl().tabs.close(tab.label())\"\n (click)=\"onCloseClick($event, $index)\">\n <ds-icon\n name=\"x\"\n [size]=\"12\">\n </ds-icon>\n </span>\n }\n </button>\n }\n</div>\n\n@if (showScrollArrows()) {\n <button\n type=\"button\"\n class=\"scroll-arrow\"\n tabindex=\"-1\"\n aria-hidden=\"true\"\n [class.at-edge]=\"!canScrollNext()\"\n (mousedown)=\"$event.preventDefault()\"\n (click)=\"scrollPage(true)\">\n <ds-icon\n name=\"chevronRight\"\n [size]=\"16\">\n </ds-icon>\n </button>\n}\n\n@for (tab of tabs(); track $index) {\n @if (isPanelVisible($index)) {\n <div\n class=\"panel\"\n role=\"tabpanel\"\n tabindex=\"0\"\n [id]=\"panelId($index)\"\n [attr.aria-labelledby]=\"tabId($index)\"\n [hidden]=\"$index !== selectedIndex()\">\n <ng-container *ngTemplateOutlet=\"tab.content()\"></ng-container>\n </div>\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;MAmBa,YAAY,CAAA;;AAEd,IAAA,KAAK,GAAG,KAAK,CAAC,QAAQ,2EAAU;;AAEhC,IAAA,IAAI,GAAG,KAAK,CAAkB,IAAI,2EAAC;;AAEnC,IAAA,KAAK,G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,EAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,UAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,WAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,aAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,UAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,SAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,MAAA,EAAA,IAAA,EAAA,CAAA,WAAA,CAAA,EAAA,CAAA,EAAA,OAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,SAAS,wFAYb,YAAY,CAAA,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AEvIxD;;AAEG;;;;"}
|
|
@@ -58,7 +58,8 @@ class TextareaComponent extends DsControlValueAccessor {
|
|
|
58
58
|
ariaLabel = input(null, ...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
59
59
|
/** Character limit - shows a live "{current}/{max}" counter below the field.
|
|
60
60
|
* `maxLengthMode` decides what happens at the limit. Counts `value.length`, the
|
|
61
|
-
* UTF-16 units the native `maxlength` counts, whitespace included
|
|
61
|
+
* UTF-16 units the native `maxlength` counts, whitespace included, unless
|
|
62
|
+
* `countTrimmed` is set. */
|
|
62
63
|
maxLength = input(null, { ...(ngDevMode ? { debugName: "maxLength" } : /* istanbul ignore next */ {}), transform: optionalBound });
|
|
63
64
|
/** `'hard'` applies the native maxlength attribute, so typing and paste stop at
|
|
64
65
|
* `maxLength`. `'soft'` lets the text run past it: the counter turns red, the
|
|
@@ -66,15 +67,33 @@ class TextareaComponent extends DsControlValueAccessor {
|
|
|
66
67
|
* (`aria-invalid`, with the counter as its description). Blocking a save on
|
|
67
68
|
* it is the form's job. */
|
|
68
69
|
maxLengthMode = input('hard', ...(ngDevMode ? [{ debugName: "maxLengthMode" }] : /* istanbul ignore next */ []));
|
|
70
|
+
/** Leaves whitespace at either end of the text out of the counter, the soft-limit
|
|
71
|
+
* state and the highlight, for a value the server stores trimmed. Whitespace
|
|
72
|
+
* between words still counts. The native `maxlength` of `maxLengthMode="hard"`
|
|
73
|
+
* counts every character regardless. */
|
|
74
|
+
countTrimmed = input(false, { ...(ngDevMode ? { debugName: "countTrimmed" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
75
|
+
countedRange = computed(() => {
|
|
76
|
+
const value = this.value();
|
|
77
|
+
if (!this.countTrimmed()) {
|
|
78
|
+
return { start: 0, end: value.length };
|
|
79
|
+
}
|
|
80
|
+
const start = value.length - value.trimStart().length;
|
|
81
|
+
return { start, end: Math.max(start, value.trimEnd().length) };
|
|
82
|
+
}, ...(ngDevMode ? [{ debugName: "countedRange" }] : /* istanbul ignore next */ []));
|
|
83
|
+
currentLength = computed(() => {
|
|
84
|
+
const { start, end } = this.countedRange();
|
|
85
|
+
return end - start;
|
|
86
|
+
}, ...(ngDevMode ? [{ debugName: "currentLength" }] : /* istanbul ignore next */ []));
|
|
69
87
|
overLimitBy = computed(() => {
|
|
70
88
|
const limit = this.maxLength();
|
|
71
89
|
return this.maxLengthMode() === 'soft' && limit !== null
|
|
72
|
-
? Math.max(0, this.
|
|
90
|
+
? Math.max(0, this.currentLength() - limit)
|
|
73
91
|
: 0;
|
|
74
92
|
}, ...(ngDevMode ? [{ debugName: "overLimitBy" }] : /* istanbul ignore next */ []));
|
|
75
93
|
overflowParts = computed(() => {
|
|
76
94
|
const value = this.value();
|
|
77
|
-
|
|
95
|
+
const { end } = this.countedRange();
|
|
96
|
+
let splitAt = end - this.overLimitBy();
|
|
78
97
|
// A limit inside a surrogate pair marks the whole pair: half a pair renders
|
|
79
98
|
// at another width and shifts every mirrored line after it.
|
|
80
99
|
// A limit inside an emoji ZWJ sequence still shifts them; splitting on
|
|
@@ -83,7 +102,11 @@ class TextareaComponent extends DsControlValueAccessor {
|
|
|
83
102
|
if (previous >= 0xd800 && previous <= 0xdbff) {
|
|
84
103
|
splitAt -= 1;
|
|
85
104
|
}
|
|
86
|
-
return {
|
|
105
|
+
return {
|
|
106
|
+
within: value.slice(0, splitAt),
|
|
107
|
+
over: value.slice(splitAt, end),
|
|
108
|
+
after: value.slice(end),
|
|
109
|
+
};
|
|
87
110
|
}, ...(ngDevMode ? [{ debugName: "overflowParts" }] : /* istanbul ignore next */ []));
|
|
88
111
|
// Signal forms binds these by name; without them a `pattern()` or `minLength()`
|
|
89
112
|
// rule validated in the form model while the native element advertised nothing.
|
|
@@ -124,7 +147,6 @@ class TextareaComponent extends DsControlValueAccessor {
|
|
|
124
147
|
resolvedAriaLabel = computed(() => this.label() ? null : this.ariaLabel() || this.placeholder() || null, ...(ngDevMode ? [{ debugName: "resolvedAriaLabel" }] : /* istanbul ignore next */ []));
|
|
125
148
|
/** Effective disabled — own `disabled` input OR the reactive-forms state. */
|
|
126
149
|
isDisabled = computed(() => this.disabled() || this.formDisabled(), ...(ngDevMode ? [{ debugName: "isDisabled" }] : /* istanbul ignore next */ []));
|
|
127
|
-
currentLength = computed(() => this.value().length, ...(ngDevMode ? [{ debugName: "currentLength" }] : /* istanbul ignore next */ []));
|
|
128
150
|
counterId = computed(() => this.maxLength() !== null ? `${this.uid}-counter` : null, ...(ngDevMode ? [{ debugName: "counterId" }] : /* istanbul ignore next */ []));
|
|
129
151
|
describedBy = computed(() => [this.hintId(), this.overLimitBy() > 0 ? this.counterId() : null]
|
|
130
152
|
.filter(Boolean)
|
|
@@ -204,13 +226,13 @@ class TextareaComponent extends DsControlValueAccessor {
|
|
|
204
226
|
this.control()?.nativeElement.select();
|
|
205
227
|
}
|
|
206
228
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: TextareaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
207
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.22", type: TextareaComponent, isStandalone: true, selector: "ds-textarea", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readOnly: { classPropertyName: "readOnly", publicName: "readOnly", isSignal: true, isRequired: false, transformFunction: null }, readonlyBinding: { classPropertyName: "readonlyBinding", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, success: { classPropertyName: "success", publicName: "success", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, optional: { classPropertyName: "optional", publicName: "optional", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, autosize: { classPropertyName: "autosize", publicName: "autosize", isSignal: true, isRequired: false, transformFunction: null }, minRows: { classPropertyName: "minRows", publicName: "minRows", isSignal: true, isRequired: false, transformFunction: null }, maxRows: { classPropertyName: "maxRows", publicName: "maxRows", isSignal: true, isRequired: false, transformFunction: null }, resize: { classPropertyName: "resize", publicName: "resize", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, maxLength: { classPropertyName: "maxLength", publicName: "maxLength", isSignal: true, isRequired: false, transformFunction: null }, maxLengthMode: { classPropertyName: "maxLengthMode", publicName: "maxLengthMode", isSignal: true, isRequired: false, transformFunction: null }, minLength: { classPropertyName: "minLength", publicName: "minLength", isSignal: true, isRequired: false, transformFunction: null }, pattern: { classPropertyName: "pattern", publicName: "pattern", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, host: { properties: { "attr.data-field-state": "controlState()" } }, providers: [
|
|
229
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.22", type: TextareaComponent, isStandalone: true, selector: "ds-textarea", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readOnly: { classPropertyName: "readOnly", publicName: "readOnly", isSignal: true, isRequired: false, transformFunction: null }, readonlyBinding: { classPropertyName: "readonlyBinding", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, success: { classPropertyName: "success", publicName: "success", isSignal: true, isRequired: false, transformFunction: null }, required: { classPropertyName: "required", publicName: "required", isSignal: true, isRequired: false, transformFunction: null }, optional: { classPropertyName: "optional", publicName: "optional", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, autosize: { classPropertyName: "autosize", publicName: "autosize", isSignal: true, isRequired: false, transformFunction: null }, minRows: { classPropertyName: "minRows", publicName: "minRows", isSignal: true, isRequired: false, transformFunction: null }, maxRows: { classPropertyName: "maxRows", publicName: "maxRows", isSignal: true, isRequired: false, transformFunction: null }, resize: { classPropertyName: "resize", publicName: "resize", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, maxLength: { classPropertyName: "maxLength", publicName: "maxLength", isSignal: true, isRequired: false, transformFunction: null }, maxLengthMode: { classPropertyName: "maxLengthMode", publicName: "maxLengthMode", isSignal: true, isRequired: false, transformFunction: null }, countTrimmed: { classPropertyName: "countTrimmed", publicName: "countTrimmed", isSignal: true, isRequired: false, transformFunction: null }, minLength: { classPropertyName: "minLength", publicName: "minLength", isSignal: true, isRequired: false, transformFunction: null }, pattern: { classPropertyName: "pattern", publicName: "pattern", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, host: { properties: { "attr.data-field-state": "controlState()" } }, providers: [
|
|
208
230
|
{
|
|
209
231
|
provide: NG_VALUE_ACCESSOR,
|
|
210
232
|
useExisting: forwardRef(() => TextareaComponent),
|
|
211
233
|
multi: true,
|
|
212
234
|
},
|
|
213
|
-
], viewQueries: [{ propertyName: "control", first: true, predicate: ["control"], descendants: true, isSignal: true }, { propertyName: "overflowMirror", first: true, predicate: ["overflowMirror"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div [class]=\"wrapperClasses()\">\n @if (label()) {\n <label\n class=\"label\"\n [attr.for]=\"uid\">\n {{ label() }}\n @if (required()) {\n <span\n class=\"req\"\n aria-hidden=\"true\">\n *\n </span>\n } @else if (optional()) {\n <span\n class=\"optional-marker\"\n aria-hidden=\"true\">\n {{ intl().field.optional }}\n </span>\n }\n </label>\n }\n\n <div\n class=\"control\"\n dsFieldClickFocus>\n @if (overLimitBy() > 0) {\n <div\n #overflowMirror\n class=\"overflow-mirror\"\n aria-hidden=\"true\">\n <span [textContent]=\"overflowParts().within\"></span>\n\n <mark [textContent]=\"overflowParts().over\"></mark>\n </div>\n }\n\n <textarea\n #control\n [id]=\"uid\"\n [rows]=\"rows()\"\n [attr.name]=\"name()\"\n [attr.placeholder]=\"placeholder() || null\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [attr.aria-invalid]=\"invalidResolved() ? 'true' : null\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-required]=\"required() ? 'true' : null\"\n [attr.maxlength]=\"nativeMaxLength()\"\n [attr.minlength]=\"minLength()\"\n [attr.pattern]=\"patternAttribute()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"isReadOnly()\"\n [required]=\"required()\"\n [style.resize]=\"effectiveResize()\"\n [style.min-height]=\"autosizeMinHeight()\"\n [style.max-height]=\"autosizeMaxHeight()\"\n [style.overflow-y]=\"autosize() && maxRows() ? 'auto' : null\"\n [(ngModel)]=\"value\"\n (blur)=\"markTouched()\"\n (scroll)=\"syncOverflowScroll()\">\n </textarea>\n </div>\n\n @if (\n reserveMessageResolved() ||\n message().text ||\n maxLength() !== null\n ) {\n <div class=\"field-footer\">\n <ds-field-message\n [icon]=\"messageIcon()\"\n [text]=\"message().text\"\n [state]=\"message().state\"\n [messageId]=\"hintId()\"\n [reserve]=\"reserveMessageResolved()\" />\n\n @if (maxLength() !== null) {\n <span\n class=\"char-counter\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n [class.over-limit]=\"overLimitBy() > 0\"\n [id]=\"counterId()\">\n {{ currentLength() }}/{{ maxLength() }}\n @if (overLimitBy() > 0) {\n <span class=\"visually-hidden\">\n {{ intl().field.overLimit(overLimitBy()) }}\n </span>\n }\n </span>\n }\n </div>\n }\n</div>\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_field-border-color: var(--ds-field-border-color, var(--border-default));--_field-border-color-hover: var(--ds-field-border-color-hover, var(--border-strong));--_field-border-color-focus: var(--ds-field-border-color-focus, var(--accent));--_field-text-color: var(--ds-field-text-color, var(--text-primary));--_field-placeholder-color: var(--ds-field-placeholder-color, var(--text-tertiary));--_field-font-size: var(--ds-field-font-size, var(--font-size-s));--_input-bg-color: var(--ds-input-bg-color, var(--surface-default));--_input-border: var(--ds-input-border, var(--_field-border-color));--_input-radius: var(--ds-input-radius, var(--ds-radius-control));--_input-padding-y: var(--ds-input-padding-y, var(--space-3));--_input-padding-x: var(--ds-input-padding-x, var(--field-pad-x));--_input-text-color: var(--ds-input-text-color, var(--_field-text-color));--_input-placeholder: var(--ds-input-placeholder, var(--_field-placeholder-color));--_input-border-hover: var(--ds-input-border-hover, var(--_field-border-color-hover));--_input-border-focus: var(--ds-input-border-focus, var(--_field-border-color-focus));--_input-focus-shadow: var(--ds-input-focus-shadow, var(--ds-field-focus-shadow));--_input-focus-shadow-error: var(--ds-input-focus-shadow-error, var(--ds-field-focus-shadow-error));--_input-bg-color-disabled: var(--ds-input-bg-color-disabled, var(--surface-disabled));--_input-bg-color-error: var(--ds-input-bg-color-error, var(--error-subtitle));--_input-border-error: var(--ds-input-border-error, var(--error));--_input-border-success: var(--ds-input-border-success, var(--success));--_input-font-size: var(--ds-input-font-size, var(--_field-font-size));--_textarea-font: var(--font-weight-regular) var(--_input-font-size) / var(--line-height-base) var(--font-sans);display:block}.field{display:flex;flex-direction:column;gap:var(--field-label-gap);width:100%}.field .label{--_field-label-font-size: var(--ds-field-label-font-size, var(--font-size-xs));--_field-label-font-weight: var(--ds-field-label-font-weight, var(--font-weight-bold));--_field-label-color: var(--ds-field-label-color, var(--text-secondary));--_field-label-text-transform: var(--ds-field-label-text-transform, none);--_field-label-letter-spacing: var(--ds-field-label-letter-spacing, normal);display:flex;align-items:center;gap:var(--field-gap-req);font:var(--_field-label-font-weight) var(--_field-label-font-size)/var(--line-height-base) var(--font-sans);color:var(--_field-label-color);text-transform:var(--_field-label-text-transform);letter-spacing:var(--_field-label-letter-spacing)}.field .label .req{color:var(--error);font-weight:var(--font-weight-semibold)}.field .label .optional-marker{color:var(--text-tertiary);font-weight:var(--font-weight-regular)}.field .control{display:flex;align-items:stretch;gap:var(--space-2);background-color:var(--_input-bg-color);border:var(--border-width-default) solid var(--_input-border);border-radius:var(--_input-radius);padding:0 var(--_input-padding-x);height:auto;transition:border-color var(--duration-fast) var(--ease-standard),box-shadow var(--duration-fast) var(--ease-standard),background var(--duration-fast) var(--ease-standard)}.field .control textarea{flex:1;min-width:0;appearance:none;border:0}@media not (forced-colors:active){.field .control textarea{outline:none}}.field .control textarea{background:transparent;font:var(--_textarea-font);color:var(--_input-text-color);min-height:var(--field-textarea-rows-min, 60px);padding:var(--_input-padding-y) 0}.field .control textarea::placeholder{color:var(--_input-placeholder)}.field .control:hover{border-color:var(--_input-border-hover)}.field .control:focus-within{border-color:var(--_input-border-focus);box-shadow:var(--_input-focus-shadow)}@media not (forced-colors:active){.field .control textarea:where(:focus-visible){outline:none}}.field.disabled .control{background-color:var(--_input-bg-color-disabled);border-color:var(--border-disabled)}.field.disabled textarea{color:var(--text-disabled)}.field.read-only .control{background:var(--surface-secondary)}.field.read-only .control textarea{cursor:default}.field.sm .control{padding:0 var(--space-2)}.field.lg .control{padding:0 var(--space-3)}.field.autosize .control textarea{field-sizing:content;overflow:hidden}.field .field-footer{display:flex;align-items:baseline;justify-content:space-between;gap:var(--space-2)}.field .char-counter{font-size:var(--font-size-xs);color:var(--text-tertiary);font-variant-numeric:tabular-nums;white-space:nowrap;flex-shrink:0;margin-left:auto}.field .char-counter.over-limit{position:relative;color:var(--error-text)}.field .char-counter .visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}.field.soft-limit .control{position:relative}.field.soft-limit .control textarea{position:relative;scrollbar-gutter:stable}.field .overflow-mirror{position:absolute;inset:0;box-sizing:border-box;padding-inline:inherit;overflow:hidden;scrollbar-gutter:stable;font:var(--_textarea-font);letter-spacing:normal;word-spacing:normal;text-transform:none;text-indent:0;text-align:start;white-space:pre-wrap;overflow-wrap:break-word;color:transparent;pointer-events:none;-webkit-user-select:none;user-select:none}.field .overflow-mirror:after{content:\" \"}.field .overflow-mirror mark{color:transparent;background-color:var(--error-muted-strong);border-radius:var(--ds-radius-inner)}@media(forced-colors:active){.field .overflow-mirror mark{forced-color-adjust:none;background-color:transparent;text-decoration:underline wavy CanvasText;text-decoration-skip-ink:none}}.field .control :is(textarea,.overflow-mirror){padding-block:var(--_input-padding-y)}.field.sm .control :is(textarea,.overflow-mirror){padding-block:var(--space-2)}.field.lg .control :is(textarea,.overflow-mirror){padding-block:var(--space-4)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-error);background-color:var(--_input-bg-color-error)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-within,:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-visible{box-shadow:var(--_input-focus-shadow-error)}:host([data-field-state=warning]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--warning-text)}:host([data-field-state=success]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-success)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: FieldMessageComponent, selector: "ds-field-message", inputs: ["text", "state", "messageId", "icon", "reserve"] }, { kind: "directive", type: FieldClickFocusDirective, selector: "[dsFieldClickFocus]" }] });
|
|
235
|
+
], viewQueries: [{ propertyName: "control", first: true, predicate: ["control"], descendants: true, isSignal: true }, { propertyName: "overflowMirror", first: true, predicate: ["overflowMirror"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div [class]=\"wrapperClasses()\">\n @if (label()) {\n <label\n class=\"label\"\n [attr.for]=\"uid\">\n {{ label() }}\n @if (required()) {\n <span\n class=\"req\"\n aria-hidden=\"true\">\n *\n </span>\n } @else if (optional()) {\n <span\n class=\"optional-marker\"\n aria-hidden=\"true\">\n {{ intl().field.optional }}\n </span>\n }\n </label>\n }\n\n <div\n class=\"control\"\n dsFieldClickFocus>\n @if (overLimitBy() > 0) {\n <div\n #overflowMirror\n class=\"overflow-mirror\"\n aria-hidden=\"true\">\n <span [textContent]=\"overflowParts().within\"></span>\n\n <mark [textContent]=\"overflowParts().over\"></mark>\n\n <span [textContent]=\"overflowParts().after\"></span>\n </div>\n }\n\n <textarea\n #control\n [id]=\"uid\"\n [rows]=\"rows()\"\n [attr.name]=\"name()\"\n [attr.placeholder]=\"placeholder() || null\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [attr.aria-invalid]=\"invalidResolved() ? 'true' : null\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-required]=\"required() ? 'true' : null\"\n [attr.maxlength]=\"nativeMaxLength()\"\n [attr.minlength]=\"minLength()\"\n [attr.pattern]=\"patternAttribute()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"isReadOnly()\"\n [required]=\"required()\"\n [style.resize]=\"effectiveResize()\"\n [style.min-height]=\"autosizeMinHeight()\"\n [style.max-height]=\"autosizeMaxHeight()\"\n [style.overflow-y]=\"autosize() && maxRows() ? 'auto' : null\"\n [(ngModel)]=\"value\"\n (blur)=\"markTouched()\"\n (scroll)=\"syncOverflowScroll()\">\n </textarea>\n </div>\n\n @if (\n reserveMessageResolved() ||\n message().text ||\n maxLength() !== null\n ) {\n <div class=\"field-footer\">\n <ds-field-message\n [icon]=\"messageIcon()\"\n [text]=\"message().text\"\n [state]=\"message().state\"\n [messageId]=\"hintId()\"\n [reserve]=\"reserveMessageResolved()\" />\n\n @if (maxLength() !== null) {\n <span\n class=\"char-counter\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n [class.over-limit]=\"overLimitBy() > 0\"\n [id]=\"counterId()\">\n {{ currentLength() }}/{{ maxLength() }}\n @if (overLimitBy() > 0) {\n <span class=\"visually-hidden\">\n {{ intl().field.overLimit(overLimitBy()) }}\n </span>\n }\n </span>\n }\n </div>\n }\n</div>\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_field-border-color: var(--ds-field-border-color, var(--border-default));--_field-border-color-hover: var(--ds-field-border-color-hover, var(--border-strong));--_field-border-color-focus: var(--ds-field-border-color-focus, var(--accent));--_field-text-color: var(--ds-field-text-color, var(--text-primary));--_field-placeholder-color: var(--ds-field-placeholder-color, var(--text-tertiary));--_field-font-size: var(--ds-field-font-size, var(--font-size-s));--_input-bg-color: var(--ds-input-bg-color, var(--surface-default));--_input-border: var(--ds-input-border, var(--_field-border-color));--_input-radius: var(--ds-input-radius, var(--ds-radius-control));--_input-padding-y: var(--ds-input-padding-y, var(--space-3));--_input-padding-x: var(--ds-input-padding-x, var(--field-pad-x));--_input-text-color: var(--ds-input-text-color, var(--_field-text-color));--_input-placeholder: var(--ds-input-placeholder, var(--_field-placeholder-color));--_input-border-hover: var(--ds-input-border-hover, var(--_field-border-color-hover));--_input-border-focus: var(--ds-input-border-focus, var(--_field-border-color-focus));--_input-focus-shadow: var(--ds-input-focus-shadow, var(--ds-field-focus-shadow));--_input-focus-shadow-error: var(--ds-input-focus-shadow-error, var(--ds-field-focus-shadow-error));--_input-bg-color-disabled: var(--ds-input-bg-color-disabled, var(--surface-disabled));--_input-bg-color-error: var(--ds-input-bg-color-error, var(--error-subtitle));--_input-border-error: var(--ds-input-border-error, var(--error));--_input-border-success: var(--ds-input-border-success, var(--success));--_input-font-size: var(--ds-input-font-size, var(--_field-font-size));--_textarea-font: var(--font-weight-regular) var(--_input-font-size) / var(--line-height-base) var(--font-sans);display:block}.field{display:flex;flex-direction:column;gap:var(--field-label-gap);width:100%}.field .label{--_field-label-font-size: var(--ds-field-label-font-size, var(--font-size-xs));--_field-label-font-weight: var(--ds-field-label-font-weight, var(--font-weight-bold));--_field-label-color: var(--ds-field-label-color, var(--text-secondary));--_field-label-text-transform: var(--ds-field-label-text-transform, none);--_field-label-letter-spacing: var(--ds-field-label-letter-spacing, normal);display:flex;align-items:center;gap:var(--field-gap-req);font:var(--_field-label-font-weight) var(--_field-label-font-size)/var(--line-height-base) var(--font-sans);color:var(--_field-label-color);text-transform:var(--_field-label-text-transform);letter-spacing:var(--_field-label-letter-spacing)}.field .label .req{color:var(--error);font-weight:var(--font-weight-semibold)}.field .label .optional-marker{color:var(--text-tertiary);font-weight:var(--font-weight-regular)}.field .control{display:flex;align-items:stretch;gap:var(--space-2);background-color:var(--_input-bg-color);border:var(--border-width-default) solid var(--_input-border);border-radius:var(--_input-radius);padding:0 var(--_input-padding-x);height:auto;transition:border-color var(--duration-fast) var(--ease-standard),box-shadow var(--duration-fast) var(--ease-standard),background var(--duration-fast) var(--ease-standard)}.field .control textarea{flex:1;min-width:0;appearance:none;border:0}@media not (forced-colors:active){.field .control textarea{outline:none}}.field .control textarea{background:transparent;font:var(--_textarea-font);color:var(--_input-text-color);min-height:var(--field-textarea-rows-min, 60px);padding:var(--_input-padding-y) 0}.field .control textarea::placeholder{color:var(--_input-placeholder)}.field .control:hover{border-color:var(--_input-border-hover)}.field .control:focus-within{border-color:var(--_input-border-focus);box-shadow:var(--_input-focus-shadow)}@media not (forced-colors:active){.field .control textarea:where(:focus-visible){outline:none}}.field.disabled .control{background-color:var(--_input-bg-color-disabled);border-color:var(--border-disabled)}.field.disabled textarea{color:var(--text-disabled)}.field.read-only .control{background:var(--surface-secondary)}.field.read-only .control textarea{cursor:default}.field.sm .control{padding:0 var(--space-2)}.field.lg .control{padding:0 var(--space-3)}.field.autosize .control textarea{field-sizing:content;overflow:hidden}.field .field-footer{display:flex;align-items:baseline;justify-content:space-between;gap:var(--space-2)}.field .char-counter{font-size:var(--font-size-xs);color:var(--text-tertiary);font-variant-numeric:tabular-nums;white-space:nowrap;flex-shrink:0;margin-left:auto}.field .char-counter.over-limit{position:relative;color:var(--error-text)}.field .char-counter .visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}.field.soft-limit .control{position:relative}.field.soft-limit .control textarea{position:relative;scrollbar-gutter:stable}.field .overflow-mirror{position:absolute;inset:0;box-sizing:border-box;padding-inline:inherit;overflow:hidden;scrollbar-gutter:stable;font:var(--_textarea-font);letter-spacing:normal;word-spacing:normal;text-transform:none;text-indent:0;text-align:start;white-space:pre-wrap;overflow-wrap:break-word;color:transparent;pointer-events:none;-webkit-user-select:none;user-select:none}.field .overflow-mirror:after{content:\" \"}.field .overflow-mirror mark{color:transparent;background-color:var(--error-highlight);border-radius:var(--ds-radius-inner)}@media(forced-colors:active){.field .overflow-mirror mark{forced-color-adjust:none;background-color:transparent;text-decoration:underline wavy CanvasText;text-decoration-skip-ink:none}}.field .control :is(textarea,.overflow-mirror){padding-block:var(--_input-padding-y)}.field.sm .control :is(textarea,.overflow-mirror){padding-block:var(--space-2)}.field.lg .control :is(textarea,.overflow-mirror){padding-block:var(--space-4)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-error);background-color:var(--_input-bg-color-error)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-within,:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-visible{box-shadow:var(--_input-focus-shadow-error)}:host([data-field-state=warning]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--warning-text)}:host([data-field-state=success]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-success)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: FieldMessageComponent, selector: "ds-field-message", inputs: ["text", "state", "messageId", "icon", "reserve"] }, { kind: "directive", type: FieldClickFocusDirective, selector: "[dsFieldClickFocus]" }] });
|
|
214
236
|
}
|
|
215
237
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImport: i0, type: TextareaComponent, decorators: [{
|
|
216
238
|
type: Component,
|
|
@@ -222,8 +244,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.22", ngImpo
|
|
|
222
244
|
useExisting: forwardRef(() => TextareaComponent),
|
|
223
245
|
multi: true,
|
|
224
246
|
},
|
|
225
|
-
], template: "<div [class]=\"wrapperClasses()\">\n @if (label()) {\n <label\n class=\"label\"\n [attr.for]=\"uid\">\n {{ label() }}\n @if (required()) {\n <span\n class=\"req\"\n aria-hidden=\"true\">\n *\n </span>\n } @else if (optional()) {\n <span\n class=\"optional-marker\"\n aria-hidden=\"true\">\n {{ intl().field.optional }}\n </span>\n }\n </label>\n }\n\n <div\n class=\"control\"\n dsFieldClickFocus>\n @if (overLimitBy() > 0) {\n <div\n #overflowMirror\n class=\"overflow-mirror\"\n aria-hidden=\"true\">\n <span [textContent]=\"overflowParts().within\"></span>\n\n <mark [textContent]=\"overflowParts().over\"></mark>\n </div>\n }\n\n <textarea\n #control\n [id]=\"uid\"\n [rows]=\"rows()\"\n [attr.name]=\"name()\"\n [attr.placeholder]=\"placeholder() || null\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [attr.aria-invalid]=\"invalidResolved() ? 'true' : null\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-required]=\"required() ? 'true' : null\"\n [attr.maxlength]=\"nativeMaxLength()\"\n [attr.minlength]=\"minLength()\"\n [attr.pattern]=\"patternAttribute()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"isReadOnly()\"\n [required]=\"required()\"\n [style.resize]=\"effectiveResize()\"\n [style.min-height]=\"autosizeMinHeight()\"\n [style.max-height]=\"autosizeMaxHeight()\"\n [style.overflow-y]=\"autosize() && maxRows() ? 'auto' : null\"\n [(ngModel)]=\"value\"\n (blur)=\"markTouched()\"\n (scroll)=\"syncOverflowScroll()\">\n </textarea>\n </div>\n\n @if (\n reserveMessageResolved() ||\n message().text ||\n maxLength() !== null\n ) {\n <div class=\"field-footer\">\n <ds-field-message\n [icon]=\"messageIcon()\"\n [text]=\"message().text\"\n [state]=\"message().state\"\n [messageId]=\"hintId()\"\n [reserve]=\"reserveMessageResolved()\" />\n\n @if (maxLength() !== null) {\n <span\n class=\"char-counter\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n [class.over-limit]=\"overLimitBy() > 0\"\n [id]=\"counterId()\">\n {{ currentLength() }}/{{ maxLength() }}\n @if (overLimitBy() > 0) {\n <span class=\"visually-hidden\">\n {{ intl().field.overLimit(overLimitBy()) }}\n </span>\n }\n </span>\n }\n </div>\n }\n</div>\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_field-border-color: var(--ds-field-border-color, var(--border-default));--_field-border-color-hover: var(--ds-field-border-color-hover, var(--border-strong));--_field-border-color-focus: var(--ds-field-border-color-focus, var(--accent));--_field-text-color: var(--ds-field-text-color, var(--text-primary));--_field-placeholder-color: var(--ds-field-placeholder-color, var(--text-tertiary));--_field-font-size: var(--ds-field-font-size, var(--font-size-s));--_input-bg-color: var(--ds-input-bg-color, var(--surface-default));--_input-border: var(--ds-input-border, var(--_field-border-color));--_input-radius: var(--ds-input-radius, var(--ds-radius-control));--_input-padding-y: var(--ds-input-padding-y, var(--space-3));--_input-padding-x: var(--ds-input-padding-x, var(--field-pad-x));--_input-text-color: var(--ds-input-text-color, var(--_field-text-color));--_input-placeholder: var(--ds-input-placeholder, var(--_field-placeholder-color));--_input-border-hover: var(--ds-input-border-hover, var(--_field-border-color-hover));--_input-border-focus: var(--ds-input-border-focus, var(--_field-border-color-focus));--_input-focus-shadow: var(--ds-input-focus-shadow, var(--ds-field-focus-shadow));--_input-focus-shadow-error: var(--ds-input-focus-shadow-error, var(--ds-field-focus-shadow-error));--_input-bg-color-disabled: var(--ds-input-bg-color-disabled, var(--surface-disabled));--_input-bg-color-error: var(--ds-input-bg-color-error, var(--error-subtitle));--_input-border-error: var(--ds-input-border-error, var(--error));--_input-border-success: var(--ds-input-border-success, var(--success));--_input-font-size: var(--ds-input-font-size, var(--_field-font-size));--_textarea-font: var(--font-weight-regular) var(--_input-font-size) / var(--line-height-base) var(--font-sans);display:block}.field{display:flex;flex-direction:column;gap:var(--field-label-gap);width:100%}.field .label{--_field-label-font-size: var(--ds-field-label-font-size, var(--font-size-xs));--_field-label-font-weight: var(--ds-field-label-font-weight, var(--font-weight-bold));--_field-label-color: var(--ds-field-label-color, var(--text-secondary));--_field-label-text-transform: var(--ds-field-label-text-transform, none);--_field-label-letter-spacing: var(--ds-field-label-letter-spacing, normal);display:flex;align-items:center;gap:var(--field-gap-req);font:var(--_field-label-font-weight) var(--_field-label-font-size)/var(--line-height-base) var(--font-sans);color:var(--_field-label-color);text-transform:var(--_field-label-text-transform);letter-spacing:var(--_field-label-letter-spacing)}.field .label .req{color:var(--error);font-weight:var(--font-weight-semibold)}.field .label .optional-marker{color:var(--text-tertiary);font-weight:var(--font-weight-regular)}.field .control{display:flex;align-items:stretch;gap:var(--space-2);background-color:var(--_input-bg-color);border:var(--border-width-default) solid var(--_input-border);border-radius:var(--_input-radius);padding:0 var(--_input-padding-x);height:auto;transition:border-color var(--duration-fast) var(--ease-standard),box-shadow var(--duration-fast) var(--ease-standard),background var(--duration-fast) var(--ease-standard)}.field .control textarea{flex:1;min-width:0;appearance:none;border:0}@media not (forced-colors:active){.field .control textarea{outline:none}}.field .control textarea{background:transparent;font:var(--_textarea-font);color:var(--_input-text-color);min-height:var(--field-textarea-rows-min, 60px);padding:var(--_input-padding-y) 0}.field .control textarea::placeholder{color:var(--_input-placeholder)}.field .control:hover{border-color:var(--_input-border-hover)}.field .control:focus-within{border-color:var(--_input-border-focus);box-shadow:var(--_input-focus-shadow)}@media not (forced-colors:active){.field .control textarea:where(:focus-visible){outline:none}}.field.disabled .control{background-color:var(--_input-bg-color-disabled);border-color:var(--border-disabled)}.field.disabled textarea{color:var(--text-disabled)}.field.read-only .control{background:var(--surface-secondary)}.field.read-only .control textarea{cursor:default}.field.sm .control{padding:0 var(--space-2)}.field.lg .control{padding:0 var(--space-3)}.field.autosize .control textarea{field-sizing:content;overflow:hidden}.field .field-footer{display:flex;align-items:baseline;justify-content:space-between;gap:var(--space-2)}.field .char-counter{font-size:var(--font-size-xs);color:var(--text-tertiary);font-variant-numeric:tabular-nums;white-space:nowrap;flex-shrink:0;margin-left:auto}.field .char-counter.over-limit{position:relative;color:var(--error-text)}.field .char-counter .visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}.field.soft-limit .control{position:relative}.field.soft-limit .control textarea{position:relative;scrollbar-gutter:stable}.field .overflow-mirror{position:absolute;inset:0;box-sizing:border-box;padding-inline:inherit;overflow:hidden;scrollbar-gutter:stable;font:var(--_textarea-font);letter-spacing:normal;word-spacing:normal;text-transform:none;text-indent:0;text-align:start;white-space:pre-wrap;overflow-wrap:break-word;color:transparent;pointer-events:none;-webkit-user-select:none;user-select:none}.field .overflow-mirror:after{content:\" \"}.field .overflow-mirror mark{color:transparent;background-color:var(--error-muted-strong);border-radius:var(--ds-radius-inner)}@media(forced-colors:active){.field .overflow-mirror mark{forced-color-adjust:none;background-color:transparent;text-decoration:underline wavy CanvasText;text-decoration-skip-ink:none}}.field .control :is(textarea,.overflow-mirror){padding-block:var(--_input-padding-y)}.field.sm .control :is(textarea,.overflow-mirror){padding-block:var(--space-2)}.field.lg .control :is(textarea,.overflow-mirror){padding-block:var(--space-4)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-error);background-color:var(--_input-bg-color-error)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-within,:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-visible{box-shadow:var(--_input-focus-shadow-error)}:host([data-field-state=warning]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--warning-text)}:host([data-field-state=success]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-success)}\n"] }]
|
|
226
|
-
}], ctorParameters: () => [], propDecorators: { control: [{ type: i0.ViewChild, args: ['control', { isSignal: true }] }], overflowMirror: [{ type: i0.ViewChild, args: ['overflowMirror', { isSignal: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readOnly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readOnly", required: false }] }], readonlyBinding: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], success: [{ type: i0.Input, args: [{ isSignal: true, alias: "success", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], optional: [{ type: i0.Input, args: [{ isSignal: true, alias: "optional", required: false }] }], rows: [{ type: i0.Input, args: [{ isSignal: true, alias: "rows", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], autosize: [{ type: i0.Input, args: [{ isSignal: true, alias: "autosize", required: false }] }], minRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "minRows", required: false }] }], maxRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxRows", required: false }] }], resize: [{ type: i0.Input, args: [{ isSignal: true, alias: "resize", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], maxLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLength", required: false }] }], maxLengthMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLengthMode", required: false }] }], minLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "minLength", required: false }] }], pattern: [{ type: i0.Input, args: [{ isSignal: true, alias: "pattern", required: false }] }] } });
|
|
247
|
+
], template: "<div [class]=\"wrapperClasses()\">\n @if (label()) {\n <label\n class=\"label\"\n [attr.for]=\"uid\">\n {{ label() }}\n @if (required()) {\n <span\n class=\"req\"\n aria-hidden=\"true\">\n *\n </span>\n } @else if (optional()) {\n <span\n class=\"optional-marker\"\n aria-hidden=\"true\">\n {{ intl().field.optional }}\n </span>\n }\n </label>\n }\n\n <div\n class=\"control\"\n dsFieldClickFocus>\n @if (overLimitBy() > 0) {\n <div\n #overflowMirror\n class=\"overflow-mirror\"\n aria-hidden=\"true\">\n <span [textContent]=\"overflowParts().within\"></span>\n\n <mark [textContent]=\"overflowParts().over\"></mark>\n\n <span [textContent]=\"overflowParts().after\"></span>\n </div>\n }\n\n <textarea\n #control\n [id]=\"uid\"\n [rows]=\"rows()\"\n [attr.name]=\"name()\"\n [attr.placeholder]=\"placeholder() || null\"\n [attr.aria-label]=\"resolvedAriaLabel()\"\n [attr.aria-invalid]=\"invalidResolved() ? 'true' : null\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-required]=\"required() ? 'true' : null\"\n [attr.maxlength]=\"nativeMaxLength()\"\n [attr.minlength]=\"minLength()\"\n [attr.pattern]=\"patternAttribute()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"isReadOnly()\"\n [required]=\"required()\"\n [style.resize]=\"effectiveResize()\"\n [style.min-height]=\"autosizeMinHeight()\"\n [style.max-height]=\"autosizeMaxHeight()\"\n [style.overflow-y]=\"autosize() && maxRows() ? 'auto' : null\"\n [(ngModel)]=\"value\"\n (blur)=\"markTouched()\"\n (scroll)=\"syncOverflowScroll()\">\n </textarea>\n </div>\n\n @if (\n reserveMessageResolved() ||\n message().text ||\n maxLength() !== null\n ) {\n <div class=\"field-footer\">\n <ds-field-message\n [icon]=\"messageIcon()\"\n [text]=\"message().text\"\n [state]=\"message().state\"\n [messageId]=\"hintId()\"\n [reserve]=\"reserveMessageResolved()\" />\n\n @if (maxLength() !== null) {\n <span\n class=\"char-counter\"\n aria-live=\"polite\"\n aria-atomic=\"true\"\n [class.over-limit]=\"overLimitBy() > 0\"\n [id]=\"counterId()\">\n {{ currentLength() }}/{{ maxLength() }}\n @if (overLimitBy() > 0) {\n <span class=\"visually-hidden\">\n {{ intl().field.overLimit(overLimitBy()) }}\n </span>\n }\n </span>\n }\n </div>\n }\n</div>\n", styles: ["@charset \"UTF-8\";:where(:focus-visible){outline:var(--focus-ring-width) solid var(--focus-ring-color);outline-offset:var(--focus-ring-offset);animation:ds-focus-ring-in var(--duration-fast) var(--ease-standard)}@keyframes ds-focus-ring-in{0%{outline-color:transparent}}:root[data-focus=ring]{--ds-field-focus-shadow: var(--focus-ring);--ds-field-focus-shadow-error: var(--focus-ring-error)}:root[data-focus=edge]{--focus-ring-offset: 0px;--ds-field-focus-shadow: 0 0 0 var(--border-width-default) var(--primary);--ds-field-focus-shadow-error: 0 0 0 var(--border-width-default) var(--error)}[data-focus=inset]{--focus-ring-offset: calc(-1 * var(--focus-ring-width));--ds-field-focus-shadow: var(--focus-ring-inset);--ds-field-focus-shadow-error: var(--focus-ring-inset-error)}@media(forced-colors:active){:where(:focus-visible){outline:var(--focus-ring-width) solid CanvasText;outline-offset:var(--focus-ring-offset)}}:host{--_field-border-color: var(--ds-field-border-color, var(--border-default));--_field-border-color-hover: var(--ds-field-border-color-hover, var(--border-strong));--_field-border-color-focus: var(--ds-field-border-color-focus, var(--accent));--_field-text-color: var(--ds-field-text-color, var(--text-primary));--_field-placeholder-color: var(--ds-field-placeholder-color, var(--text-tertiary));--_field-font-size: var(--ds-field-font-size, var(--font-size-s));--_input-bg-color: var(--ds-input-bg-color, var(--surface-default));--_input-border: var(--ds-input-border, var(--_field-border-color));--_input-radius: var(--ds-input-radius, var(--ds-radius-control));--_input-padding-y: var(--ds-input-padding-y, var(--space-3));--_input-padding-x: var(--ds-input-padding-x, var(--field-pad-x));--_input-text-color: var(--ds-input-text-color, var(--_field-text-color));--_input-placeholder: var(--ds-input-placeholder, var(--_field-placeholder-color));--_input-border-hover: var(--ds-input-border-hover, var(--_field-border-color-hover));--_input-border-focus: var(--ds-input-border-focus, var(--_field-border-color-focus));--_input-focus-shadow: var(--ds-input-focus-shadow, var(--ds-field-focus-shadow));--_input-focus-shadow-error: var(--ds-input-focus-shadow-error, var(--ds-field-focus-shadow-error));--_input-bg-color-disabled: var(--ds-input-bg-color-disabled, var(--surface-disabled));--_input-bg-color-error: var(--ds-input-bg-color-error, var(--error-subtitle));--_input-border-error: var(--ds-input-border-error, var(--error));--_input-border-success: var(--ds-input-border-success, var(--success));--_input-font-size: var(--ds-input-font-size, var(--_field-font-size));--_textarea-font: var(--font-weight-regular) var(--_input-font-size) / var(--line-height-base) var(--font-sans);display:block}.field{display:flex;flex-direction:column;gap:var(--field-label-gap);width:100%}.field .label{--_field-label-font-size: var(--ds-field-label-font-size, var(--font-size-xs));--_field-label-font-weight: var(--ds-field-label-font-weight, var(--font-weight-bold));--_field-label-color: var(--ds-field-label-color, var(--text-secondary));--_field-label-text-transform: var(--ds-field-label-text-transform, none);--_field-label-letter-spacing: var(--ds-field-label-letter-spacing, normal);display:flex;align-items:center;gap:var(--field-gap-req);font:var(--_field-label-font-weight) var(--_field-label-font-size)/var(--line-height-base) var(--font-sans);color:var(--_field-label-color);text-transform:var(--_field-label-text-transform);letter-spacing:var(--_field-label-letter-spacing)}.field .label .req{color:var(--error);font-weight:var(--font-weight-semibold)}.field .label .optional-marker{color:var(--text-tertiary);font-weight:var(--font-weight-regular)}.field .control{display:flex;align-items:stretch;gap:var(--space-2);background-color:var(--_input-bg-color);border:var(--border-width-default) solid var(--_input-border);border-radius:var(--_input-radius);padding:0 var(--_input-padding-x);height:auto;transition:border-color var(--duration-fast) var(--ease-standard),box-shadow var(--duration-fast) var(--ease-standard),background var(--duration-fast) var(--ease-standard)}.field .control textarea{flex:1;min-width:0;appearance:none;border:0}@media not (forced-colors:active){.field .control textarea{outline:none}}.field .control textarea{background:transparent;font:var(--_textarea-font);color:var(--_input-text-color);min-height:var(--field-textarea-rows-min, 60px);padding:var(--_input-padding-y) 0}.field .control textarea::placeholder{color:var(--_input-placeholder)}.field .control:hover{border-color:var(--_input-border-hover)}.field .control:focus-within{border-color:var(--_input-border-focus);box-shadow:var(--_input-focus-shadow)}@media not (forced-colors:active){.field .control textarea:where(:focus-visible){outline:none}}.field.disabled .control{background-color:var(--_input-bg-color-disabled);border-color:var(--border-disabled)}.field.disabled textarea{color:var(--text-disabled)}.field.read-only .control{background:var(--surface-secondary)}.field.read-only .control textarea{cursor:default}.field.sm .control{padding:0 var(--space-2)}.field.lg .control{padding:0 var(--space-3)}.field.autosize .control textarea{field-sizing:content;overflow:hidden}.field .field-footer{display:flex;align-items:baseline;justify-content:space-between;gap:var(--space-2)}.field .char-counter{font-size:var(--font-size-xs);color:var(--text-tertiary);font-variant-numeric:tabular-nums;white-space:nowrap;flex-shrink:0;margin-left:auto}.field .char-counter.over-limit{position:relative;color:var(--error-text)}.field .char-counter .visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}.field.soft-limit .control{position:relative}.field.soft-limit .control textarea{position:relative;scrollbar-gutter:stable}.field .overflow-mirror{position:absolute;inset:0;box-sizing:border-box;padding-inline:inherit;overflow:hidden;scrollbar-gutter:stable;font:var(--_textarea-font);letter-spacing:normal;word-spacing:normal;text-transform:none;text-indent:0;text-align:start;white-space:pre-wrap;overflow-wrap:break-word;color:transparent;pointer-events:none;-webkit-user-select:none;user-select:none}.field .overflow-mirror:after{content:\" \"}.field .overflow-mirror mark{color:transparent;background-color:var(--error-highlight);border-radius:var(--ds-radius-inner)}@media(forced-colors:active){.field .overflow-mirror mark{forced-color-adjust:none;background-color:transparent;text-decoration:underline wavy CanvasText;text-decoration-skip-ink:none}}.field .control :is(textarea,.overflow-mirror){padding-block:var(--_input-padding-y)}.field.sm .control :is(textarea,.overflow-mirror){padding-block:var(--space-2)}.field.lg .control :is(textarea,.overflow-mirror){padding-block:var(--space-4)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-error);background-color:var(--_input-bg-color-error)}:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-within,:host([data-field-state=error]:not(.in-group)) .control:not(.disabled):not(:disabled):focus-visible{box-shadow:var(--_input-focus-shadow-error)}:host([data-field-state=warning]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--warning-text)}:host([data-field-state=success]:not(.in-group)) .control:not(.disabled):not(:disabled){border-color:var(--_input-border-success)}\n"] }]
|
|
248
|
+
}], ctorParameters: () => [], propDecorators: { control: [{ type: i0.ViewChild, args: ['control', { isSignal: true }] }], overflowMirror: [{ type: i0.ViewChild, args: ['overflowMirror', { isSignal: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readOnly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readOnly", required: false }] }], readonlyBinding: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], success: [{ type: i0.Input, args: [{ isSignal: true, alias: "success", required: false }] }], required: [{ type: i0.Input, args: [{ isSignal: true, alias: "required", required: false }] }], optional: [{ type: i0.Input, args: [{ isSignal: true, alias: "optional", required: false }] }], rows: [{ type: i0.Input, args: [{ isSignal: true, alias: "rows", required: false }] }], name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], autosize: [{ type: i0.Input, args: [{ isSignal: true, alias: "autosize", required: false }] }], minRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "minRows", required: false }] }], maxRows: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxRows", required: false }] }], resize: [{ type: i0.Input, args: [{ isSignal: true, alias: "resize", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], maxLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLength", required: false }] }], maxLengthMode: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLengthMode", required: false }] }], countTrimmed: [{ type: i0.Input, args: [{ isSignal: true, alias: "countTrimmed", required: false }] }], minLength: [{ type: i0.Input, args: [{ isSignal: true, alias: "minLength", required: false }] }], pattern: [{ type: i0.Input, args: [{ isSignal: true, alias: "pattern", required: false }] }] } });
|
|
227
249
|
|
|
228
250
|
/**
|
|
229
251
|
* Generated bundle index. Do not edit.
|