@sixbell-telco/sdk 4.2.0 → 4.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +108 -1
- package/README.md +98 -66
- package/_index.css +2 -1586
- package/components/accordion/accordion-item/accordion-item.component.d.ts +1 -1
- package/components/alert/README.md +27 -0
- package/components/alert/index.d.ts +5 -0
- package/components/alert/public-api.d.ts +1 -0
- package/components/alert/src/alert.component.d.ts +85 -0
- package/components/audio-player/audio-timeline/audio-timeline.component.d.ts +1 -1
- package/components/audio-player/button-play/button-play.component.d.ts +7 -7
- package/components/audio-player/src/audio-player.component.d.ts +2 -2
- package/components/audio-player/volume-control/volume-control.component.d.ts +1 -1
- package/components/avatar/README.md +1 -0
- package/components/avatar/src/avatar.component.d.ts +2 -2
- package/components/badge/src/badge.component.d.ts +4 -4
- package/components/button/README.md +5 -4
- package/components/button/src/button.component.d.ts +38 -16
- package/components/card/README.md +2 -0
- package/components/card/card-footer/card-footer.component.d.ts +37 -2
- package/components/card/card-section-group/card-section-group.component.d.ts +1 -1
- package/components/card/src/card.component.d.ts +6 -6
- package/components/countdown/src/countdown.component.d.ts +4 -4
- package/components/data-table/README.md +26 -0
- package/components/data-table/expandable/expandable.component.d.ts +4 -4
- package/components/data-table/sortable-header/sortable-header.component.d.ts +1 -1
- package/components/data-table/src/data-table.component.d.ts +15 -8
- package/components/data-table/sub-component-toggle/sub-component-toggle.component.d.ts +1 -1
- package/components/description-list/README.md +27 -0
- package/components/description-list/index.d.ts +5 -0
- package/components/description-list/public-api.d.ts +1 -0
- package/components/description-list/src/description-list.component.d.ts +90 -0
- package/components/dialog/README.md +10 -6
- package/components/dialog/dialog-actions/dialog-actions.component.d.ts +4 -0
- package/components/dialog/src/dialog.component.d.ts +27 -6
- package/components/dialog/src/fullscreen-block-scroll-strategy.d.ts +31 -0
- package/components/divider/src/divider.component.d.ts +1 -1
- package/components/dropdown/README.md +2 -2
- package/components/dropdown/dropdown-chevron/dropdown-chevron.component.d.ts +1 -1
- package/components/dropdown/dropdown-content/dropdown-content.component.d.ts +1 -1
- package/components/dropdown/dropdown-item/dropdown-item.component.d.ts +4 -4
- package/components/dropdown/dropdown-item-checkbox/dropdown-item-checkbox.component.d.ts +5 -5
- package/components/dropdown/dropdown-item-radio/dropdown-item-radio.component.d.ts +5 -5
- package/components/dropdown/dropdown-trigger/dropdown-trigger.component.d.ts +11 -14
- package/components/dropdown-menu/README.md +2 -2
- package/components/dropdown-menu/bar/dropdown-menu-bar/dropdown-menu-bar.component.d.ts +1 -1
- package/components/dropdown-menu/bar/dropdown-menu-bar-content/dropdown-menu-bar-content.component.d.ts +6 -2
- package/components/dropdown-menu/bar/dropdown-menu-bar-item/dropdown-menu-bar-item.component.d.ts +3 -3
- package/components/dropdown-menu/bar/dropdown-menu-bar-item-checkbox/dropdown-menu-bar-item-checkbox.component.d.ts +4 -4
- package/components/dropdown-menu/bar/dropdown-menu-bar-item-radio/dropdown-menu-bar-item-radio.component.d.ts +4 -4
- package/components/dropdown-menu/bar/dropdown-menu-bar-sub-trigger/dropdown-menu-bar-sub-trigger.component.d.ts +3 -1
- package/components/dropdown-menu/bar/dropdown-menu-bar-trigger/dropdown-menu-bar-trigger.component.d.ts +3 -1
- package/components/dropdown-menu/context/dropdown-context-menu-trigger/dropdown-context-menu-trigger.component.d.ts +2 -1
- package/components/dropdown-menu/dropdown-menu-chevron/dropdown-menu-chevron.component.d.ts +1 -1
- package/components/dropdown-menu/src/dropdown-menu-content/dropdown-menu-content.component.d.ts +2 -0
- package/components/dropdown-menu/src/dropdown-menu-item/dropdown-menu-item.component.d.ts +3 -3
- package/components/dropdown-menu/src/dropdown-menu-sub-content/dropdown-menu-sub-content.component.d.ts +2 -0
- package/components/dropdown-menu/src/dropdown-menu-sub-trigger/dropdown-menu-sub-trigger.component.d.ts +2 -1
- package/components/dropdown-menu/src/dropdown-menu-trigger/dropdown-menu-trigger.component.d.ts +1 -0
- package/components/empty-state/README.md +40 -0
- package/components/empty-state/index.d.ts +5 -0
- package/components/empty-state/public-api.d.ts +1 -0
- package/components/empty-state/src/empty-state.component.d.ts +73 -0
- package/components/file-upload/file-dropzone/file-dropzone.component.d.ts +4 -4
- package/components/file-upload/file-uploader/file-uploader.component.d.ts +2 -2
- package/components/forms/checkbox/src/checkbox.component.d.ts +1 -1
- package/components/forms/combobox/README.md +2 -1
- package/components/forms/combobox/src/combobox.component.d.ts +31 -18
- package/components/forms/date-picker/src/date-picker.component.d.ts +16 -9
- package/components/forms/form-hint/README.md +29 -0
- package/components/forms/form-hint/index.d.ts +5 -0
- package/components/forms/form-hint/public-api.d.ts +1 -0
- package/components/forms/form-hint/src/form-hint.component.d.ts +38 -0
- package/components/forms/form-item/src/form-item.component.d.ts +45 -1
- package/components/forms/input/src/input.component.d.ts +15 -8
- package/components/forms/radio/src/radio.component.d.ts +1 -1
- package/components/forms/range/src/range.component.d.ts +18 -4
- package/components/forms/select/README.md +2 -1
- package/components/forms/select/src/select.component.d.ts +30 -16
- package/components/forms/switch/src/switch.component.d.ts +1 -1
- package/components/forms/textarea/src/textarea.component.d.ts +12 -5
- package/components/forms/toggle/src/toggle.component.d.ts +1 -1
- package/components/notification/src/notification.component.d.ts +1 -1
- package/components/overlay/README.md +7 -2
- package/components/overlay/overlay-trigger/overlay-trigger.component.d.ts +1 -1
- package/components/overlay/src/overlay.component.d.ts +10 -9
- package/components/paginator/components/pagination-item/pagination-item.component.d.ts +3 -3
- package/components/progress/src/progress.component.d.ts +1 -1
- package/components/segmented-button/README.md +57 -0
- package/components/segmented-button/index.d.ts +5 -0
- package/components/segmented-button/public-api.d.ts +1 -0
- package/components/segmented-button/src/segmented-button.component.d.ts +110 -0
- package/components/sonner/toaster/src/toaster.component.d.ts +3 -3
- package/components/tab/src/tab.component.d.ts +2 -2
- package/components/table/README.md +51 -3
- package/components/table/public-api.d.ts +1 -0
- package/components/table/src/table.component.d.ts +20 -13
- package/components/table/table-action/table-action.component.d.ts +14 -3
- package/components/table/table-actions/table-actions.component.d.ts +12 -1
- package/components/table/tokens/README.md +7 -0
- package/components/table/tokens/index.d.ts +5 -0
- package/components/table/tokens/public-api.d.ts +1 -0
- package/components/table/tokens/table-empty-state.d.ts +6 -0
- package/components/tooltip/README.md +25 -7
- package/components/tooltip/src/tooltip.component.d.ts +44 -12
- package/components/tree/README.md +73 -0
- package/components/tree/index.d.ts +5 -0
- package/components/tree/public-api.d.ts +1 -0
- package/components/tree/src/tree.component.d.ts +180 -0
- package/components/wizard/README.md +9 -0
- package/components/wizard/wizard-content/wizard-content.component.d.ts +1 -1
- package/components/wizard/wizard-wrapper/wizard-wrapper.component.d.ts +15 -6
- package/directives/auto-focus/src/auto-focus.directive.d.ts +1 -1
- package/directives/only-numbers/src/only-numbers.directive.d.ts +1 -1
- package/directives/truncate/README.md +49 -0
- package/directives/truncate/index.d.ts +5 -0
- package/directives/truncate/public-api.d.ts +1 -0
- package/directives/truncate/src/truncate-popover.component.d.ts +11 -0
- package/directives/truncate/src/truncate.directive.d.ts +96 -0
- package/fesm2022/sixbell-telco-sdk-components-accordion.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-accordion.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-alert.mjs +152 -0
- package/fesm2022/sixbell-telco-sdk-components-alert.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-audio-player.mjs +15 -15
- package/fesm2022/sixbell-telco-sdk-components-audio-player.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-avatar.mjs +4 -4
- package/fesm2022/sixbell-telco-sdk-components-avatar.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-badge.mjs +5 -5
- package/fesm2022/sixbell-telco-sdk-components-badge.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-button.mjs +53 -19
- package/fesm2022/sixbell-telco-sdk-components-button.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-card.mjs +61 -14
- package/fesm2022/sixbell-telco-sdk-components-card.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-countdown.mjs +5 -5
- package/fesm2022/sixbell-telco-sdk-components-countdown.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs +3 -3
- package/fesm2022/sixbell-telco-sdk-components-data-table-sub-component-toggle.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-data-table.mjs +34 -33
- package/fesm2022/sixbell-telco-sdk-components-data-table.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-description-list.mjs +200 -0
- package/fesm2022/sixbell-telco-sdk-components-description-list.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-dialog.mjs +128 -17
- package/fesm2022/sixbell-telco-sdk-components-dialog.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-divider.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-divider.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs +33 -24
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-bar.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-context.mjs +7 -3
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu-context.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu.mjs +25 -14
- package/fesm2022/sixbell-telco-sdk-components-dropdown-menu.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs +43 -72
- package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs +1 -1
- package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-empty-state.mjs +131 -0
- package/fesm2022/sixbell-telco-sdk-components-empty-state.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-file-upload.mjs +9 -9
- package/fesm2022/sixbell-telco-sdk-components-file-upload.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs +104 -72
- package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs +23 -12
- package/fesm2022/sixbell-telco-sdk-components-forms-date-picker.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-form-hint.mjs +81 -0
- package/fesm2022/sixbell-telco-sdk-components-forms-form-hint.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-forms-form-item.mjs +45 -3
- package/fesm2022/sixbell-telco-sdk-components-forms-form-item.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs +27 -13
- package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs +29 -7
- package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs +84 -56
- package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs +27 -22
- package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-notification.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-notification.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-overlay.mjs +41 -79
- package/fesm2022/sixbell-telco-sdk-components-overlay.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-paginator.mjs +4 -4
- package/fesm2022/sixbell-telco-sdk-components-paginator.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-progress.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-components-progress.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-segmented-button.mjs +329 -0
- package/fesm2022/sixbell-telco-sdk-components-segmented-button.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs +4 -4
- package/fesm2022/sixbell-telco-sdk-components-sonner-toaster.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-sonner.mjs +4 -4
- package/fesm2022/sixbell-telco-sdk-components-sonner.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-tab.mjs +3 -3
- package/fesm2022/sixbell-telco-sdk-components-tab.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-table-tokens.mjs +14 -0
- package/fesm2022/sixbell-telco-sdk-components-table-tokens.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-table.mjs +63 -32
- package/fesm2022/sixbell-telco-sdk-components-table.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-tooltip.mjs +187 -75
- package/fesm2022/sixbell-telco-sdk-components-tooltip.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-components-tree.mjs +478 -0
- package/fesm2022/sixbell-telco-sdk-components-tree.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-components-wizard.mjs +18 -9
- package/fesm2022/sixbell-telco-sdk-components-wizard.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-directives-auto-focus.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-directives-auto-focus.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-directives-only-numbers.mjs +2 -2
- package/fesm2022/sixbell-telco-sdk-directives-only-numbers.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-directives-truncate.mjs +339 -0
- package/fesm2022/sixbell-telco-sdk-directives-truncate.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-layouts.mjs +69 -41
- package/fesm2022/sixbell-telco-sdk-layouts.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-date.mjs +15 -2
- package/fesm2022/sixbell-telco-sdk-utils-date.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-mfe.mjs +87 -2
- package/fesm2022/sixbell-telco-sdk-utils-mfe.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-popover-motion.mjs +186 -0
- package/fesm2022/sixbell-telco-sdk-utils-popover-motion.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-utils-theme.mjs +234 -4
- package/fesm2022/sixbell-telco-sdk-utils-theme.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-translation-testing.mjs +203 -0
- package/fesm2022/sixbell-telco-sdk-utils-translation-testing.mjs.map +1 -0
- package/fesm2022/sixbell-telco-sdk-utils-translation.mjs +129 -14
- package/fesm2022/sixbell-telco-sdk-utils-translation.mjs.map +1 -1
- package/fesm2022/sixbell-telco-sdk-utils-unsaved-changes.mjs +150 -0
- package/fesm2022/sixbell-telco-sdk-utils-unsaved-changes.mjs.map +1 -0
- package/i18n/sdk/en.json +224 -0
- package/i18n/sdk/es.json +224 -0
- package/i18n/sdk/pt.json +224 -0
- package/layouts/README.md +18 -11
- package/layouts/public-api.d.ts +1 -1
- package/layouts/src/app-layout/app-layout.component.d.ts +11 -8
- package/layouts/src/layout.config.d.ts +1 -1
- package/layouts/src/menu/menu-active.d.ts +2 -1
- package/layouts/src/menu/menu-url.d.ts +2 -0
- package/layouts/src/navbar/navbar.component.d.ts +5 -5
- package/layouts/src/page-banner/page-banner.component.d.ts +19 -2
- package/layouts/src/side-menu/side-menu.component.d.ts +2 -2
- package/layouts/src/user-menu/user-menu.component.d.ts +5 -5
- package/package.json +64 -20
- package/src/_index.css +1701 -0
- package/utils/mfe/README.md +1 -0
- package/utils/mfe/src/hoist-property-rules.d.ts +13 -0
- package/utils/mfe/src/mfe-shadow-shell.component.d.ts +3 -0
- package/utils/popover-motion/README.md +38 -0
- package/utils/popover-motion/index.d.ts +5 -0
- package/utils/popover-motion/public-api.d.ts +2 -0
- package/utils/popover-motion/src/popover-menu-motion.d.ts +37 -0
- package/utils/popover-motion/src/popover-motion.d.ts +31 -0
- package/utils/theme/README.md +94 -1
- package/utils/theme/public-api.d.ts +2 -1
- package/utils/theme/src/models/theme.d.ts +32 -0
- package/utils/theme/src/overlay/theme-overlay.d.ts +33 -0
- package/utils/theme/src/providers/theme.provider.types.d.ts +7 -0
- package/utils/translation/README.md +63 -0
- package/utils/translation/src/translation.service.d.ts +24 -0
- package/utils/translation/testing/index.d.ts +5 -0
- package/utils/translation/testing/public-api.d.ts +2 -0
- package/utils/translation/testing/src/translation-testing.d.ts +96 -0
- package/utils/unsaved-changes/README.md +33 -0
- package/utils/unsaved-changes/index.d.ts +5 -0
- package/utils/unsaved-changes/public-api.d.ts +1 -0
- package/utils/unsaved-changes/src/unsaved-changes-dialog.component.d.ts +24 -0
- package/utils/unsaved-changes/src/unsaved-changes.d.ts +50 -0
|
@@ -3,6 +3,7 @@ import { ControlValueAccessor, FormGroup } from '@angular/forms';
|
|
|
3
3
|
import { TranslateService } from '@ngx-translate/core';
|
|
4
4
|
import { CdkListbox } from '@angular/cdk/listbox';
|
|
5
5
|
import { ConnectedOverlayPositionChange, ConnectedPosition } from '@angular/cdk/overlay';
|
|
6
|
+
import { PopoverPlacement, PopoverSide } from '@sixbell-telco/sdk/utils/popover-motion';
|
|
6
7
|
import { ThemeDomService } from '@sixbell-telco/sdk/utils/theme';
|
|
7
8
|
import * as i0 from "@angular/core";
|
|
8
9
|
/** Possible select dropdown style variants */
|
|
@@ -64,17 +65,24 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
64
65
|
* Whether to show optional indicator
|
|
65
66
|
* @defaultValue false
|
|
66
67
|
*/
|
|
67
|
-
showOptional: import("@angular/core").
|
|
68
|
+
showOptional: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
68
69
|
/**
|
|
69
70
|
* Optional indicator text (translation key or literal)
|
|
70
71
|
* @defaultValue 'sdk.formFields.optional'
|
|
71
72
|
*/
|
|
72
73
|
optionalText: import("@angular/core").InputSignal<string>;
|
|
74
|
+
/**
|
|
75
|
+
* Mark the field as required: shows the `*` marker and announces the field as required.
|
|
76
|
+
* When not set, the enclosing `st-form-item` `required`, then `Validators.required` on the bound control decide.
|
|
77
|
+
*/
|
|
78
|
+
required: import("@angular/core").InputSignalWithTransform<boolean | undefined, unknown>;
|
|
79
|
+
/** @internal Required state and hint ids from the enclosing `st-form-item`. */
|
|
80
|
+
protected readonly fieldA11y: import("@sixbell-telco/sdk/components/forms/form-item").FormFieldA11y;
|
|
73
81
|
/**
|
|
74
82
|
* Whether to use ghost (transparent) styling
|
|
75
83
|
* @defaultValue false
|
|
76
84
|
*/
|
|
77
|
-
ghost: import("@angular/core").
|
|
85
|
+
ghost: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
78
86
|
/**
|
|
79
87
|
* HTML name attribute for the select
|
|
80
88
|
*/
|
|
@@ -117,7 +125,7 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
117
125
|
* Whether to show a clear button next to the selected value
|
|
118
126
|
* @default true
|
|
119
127
|
*/
|
|
120
|
-
allowClear: import("@angular/core").
|
|
128
|
+
allowClear: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
121
129
|
/**
|
|
122
130
|
* Parent form group for reactive forms
|
|
123
131
|
*/
|
|
@@ -143,7 +151,7 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
143
151
|
* Stop event propagation for activation events
|
|
144
152
|
* @defaultValue false
|
|
145
153
|
*/
|
|
146
|
-
stopPropagation: import("@angular/core").
|
|
154
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
147
155
|
/**
|
|
148
156
|
* Event emitted on click
|
|
149
157
|
*/
|
|
@@ -171,6 +179,8 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
171
179
|
protected readonly clearSelectionLabel: import("@angular/core").Signal<string>;
|
|
172
180
|
/** Current animation state of the overlay */
|
|
173
181
|
private readonly animationState;
|
|
182
|
+
/** Set when the exit animation already ran the close cleanup, so the detach that follows does not repeat it */
|
|
183
|
+
private exitSettled;
|
|
174
184
|
/** Trigger for blur events in form validation */
|
|
175
185
|
private readonly blurTrigger;
|
|
176
186
|
/** Active option index for keyboard navigation */
|
|
@@ -189,20 +199,16 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
189
199
|
private readonly currentPosition;
|
|
190
200
|
/** Overlay positions with a symmetric 4px trigger gap (below first, flip above) */
|
|
191
201
|
readonly overlayPositions: ConnectedPosition[];
|
|
202
|
+
/** Real placement of the open panel, bound to `data-side` / `data-align`; null until the CDK places it */
|
|
203
|
+
readonly placement: import("@angular/core").Signal<PopoverPlacement | null>;
|
|
192
204
|
/**
|
|
193
|
-
*
|
|
194
|
-
*
|
|
195
|
-
* All class names are static and detectable by Tailwind at build time
|
|
196
|
-
*/
|
|
197
|
-
private readonly animationClassMap;
|
|
198
|
-
/**
|
|
199
|
-
* Computed animation direction based on overlay positioning
|
|
200
|
-
* Detects actual position from CDK overlay and returns appropriate direction
|
|
205
|
+
* Side of the field the panel opened on (`'bottom'` until the CDK places it)
|
|
206
|
+
* @deprecated Read `data-side` on the panel instead; kept for compatibility
|
|
201
207
|
*/
|
|
202
|
-
animationDirection: import("@angular/core").Signal<
|
|
208
|
+
animationDirection: import("@angular/core").Signal<PopoverSide>;
|
|
203
209
|
/**
|
|
204
|
-
*
|
|
205
|
-
*
|
|
210
|
+
* Class of the panel: the shared `popover-motion` utility driven by `data-state` and `data-side`
|
|
211
|
+
* @deprecated Kept for compatibility; the motion lives in the `popover-motion` utility
|
|
206
212
|
*/
|
|
207
213
|
animationClasses: import("@angular/core").Signal<string>;
|
|
208
214
|
/** Form control reference for reactive forms */
|
|
@@ -221,6 +227,8 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
221
227
|
private onChange;
|
|
222
228
|
/** Callback function for touch events */
|
|
223
229
|
private onTouched;
|
|
230
|
+
/** Value written through the accessor while no options were bound yet */
|
|
231
|
+
private pendingValue;
|
|
224
232
|
/**
|
|
225
233
|
* Whether the overlay is currently open or in the process of opening/closing
|
|
226
234
|
* @returns True if overlay is visible or animating
|
|
@@ -285,6 +293,12 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
285
293
|
* @param value - The new value to set
|
|
286
294
|
*/
|
|
287
295
|
writeValue(value: any): void;
|
|
296
|
+
/**
|
|
297
|
+
* Resolves a value written before its option existed once the options arrive.
|
|
298
|
+
* Never calls onChange: the form already holds the value.
|
|
299
|
+
*/
|
|
300
|
+
private readonly pendingValueEffect;
|
|
301
|
+
private hasOption;
|
|
288
302
|
/**
|
|
289
303
|
* Registers a callback function to be called when the value changes
|
|
290
304
|
* @param fn - The callback function
|
|
@@ -410,6 +424,6 @@ export declare class SelectComponent implements ControlValueAccessor {
|
|
|
410
424
|
*/
|
|
411
425
|
private updateActiveOptionVisually;
|
|
412
426
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent, never>;
|
|
413
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "st-select", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "showOptional": { "alias": "showOptional"; "required": false; "isSignal": true; }; "optionalText": { "alias": "optionalText"; "required": false; "isSignal": true; }; "ghost": { "alias": "ghost"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": false; "isSignal": true; }; "displayKey": { "alias": "displayKey"; "required": false; "isSignal": true; }; "valueKey": { "alias": "valueKey"; "required": false; "isSignal": true; }; "allowClear": { "alias": "allowClear"; "required": false; "isSignal": true; }; "parentForm": { "alias": "parentForm"; "required": false; "isSignal": true; }; "formControlName": { "alias": "formControlName"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "stopPropagation": { "alias": "stopPropagation"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "disabled": "disabledChange"; "blurred": "blurred"; "valueUpdated": "valueUpdated"; "clicked": "clicked"; "keyDownEnter": "keyDownEnter"; "keyDownSpace": "keyDownSpace"; "triggered": "triggered"; }, never, ["*"], true, never>;
|
|
427
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "st-select", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "showOptional": { "alias": "showOptional"; "required": false; "isSignal": true; }; "optionalText": { "alias": "optionalText"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "ghost": { "alias": "ghost"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "options": { "alias": "options"; "required": false; "isSignal": true; }; "displayKey": { "alias": "displayKey"; "required": false; "isSignal": true; }; "valueKey": { "alias": "valueKey"; "required": false; "isSignal": true; }; "allowClear": { "alias": "allowClear"; "required": false; "isSignal": true; }; "parentForm": { "alias": "parentForm"; "required": false; "isSignal": true; }; "formControlName": { "alias": "formControlName"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "stopPropagation": { "alias": "stopPropagation"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "disabled": "disabledChange"; "blurred": "blurred"; "valueUpdated": "valueUpdated"; "clicked": "clicked"; "keyDownEnter": "keyDownEnter"; "keyDownSpace": "keyDownSpace"; "triggered": "triggered"; }, never, ["*"], true, never>;
|
|
414
428
|
}
|
|
415
429
|
export {};
|
|
@@ -71,7 +71,7 @@ export declare class SwitchComponent implements ControlValueAccessor {
|
|
|
71
71
|
* Stop event propagation for activation events
|
|
72
72
|
* @defaultValue false
|
|
73
73
|
*/
|
|
74
|
-
stopPropagation: import("@angular/core").
|
|
74
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
75
75
|
/**
|
|
76
76
|
* Event emitted on click
|
|
77
77
|
*/
|
|
@@ -52,7 +52,7 @@ export declare class TextareaComponent {
|
|
|
52
52
|
* Whether to use ghost (transparent) styling
|
|
53
53
|
* @defaultValue false
|
|
54
54
|
*/
|
|
55
|
-
ghost: import("@angular/core").
|
|
55
|
+
ghost: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
56
56
|
/**
|
|
57
57
|
* Label displayed above the textarea
|
|
58
58
|
*/
|
|
@@ -61,12 +61,19 @@ export declare class TextareaComponent {
|
|
|
61
61
|
* Whether to show optional indicator
|
|
62
62
|
* @defaultValue false
|
|
63
63
|
*/
|
|
64
|
-
showOptional: import("@angular/core").
|
|
64
|
+
showOptional: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
65
65
|
/**
|
|
66
66
|
* Optional indicator text (translation key or literal)
|
|
67
67
|
* @defaultValue 'sdk.formFields.optional'
|
|
68
68
|
*/
|
|
69
69
|
optionalText: import("@angular/core").InputSignal<string>;
|
|
70
|
+
/**
|
|
71
|
+
* Mark the field as required: shows the `*` marker and announces the field as required.
|
|
72
|
+
* When not set, the enclosing `st-form-item` `required`, then `Validators.required` on the bound control decide.
|
|
73
|
+
*/
|
|
74
|
+
required: import("@angular/core").InputSignalWithTransform<boolean | undefined, unknown>;
|
|
75
|
+
/** @internal Required state and hint ids from the enclosing `st-form-item`. */
|
|
76
|
+
protected readonly fieldA11y: import("@sixbell-telco/sdk/components/forms/form-item").FormFieldA11y;
|
|
70
77
|
/**
|
|
71
78
|
* HTML name attribute for the textarea
|
|
72
79
|
*/
|
|
@@ -92,7 +99,7 @@ export declare class TextareaComponent {
|
|
|
92
99
|
* Whether the textarea is readonly
|
|
93
100
|
* @defaultValue false
|
|
94
101
|
*/
|
|
95
|
-
readonly: import("@angular/core").
|
|
102
|
+
readonly: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
96
103
|
/**
|
|
97
104
|
* Whether the textarea is disabled
|
|
98
105
|
* @defaultValue false
|
|
@@ -139,7 +146,7 @@ export declare class TextareaComponent {
|
|
|
139
146
|
* Stop event propagation for activation events
|
|
140
147
|
* @defaultValue false
|
|
141
148
|
*/
|
|
142
|
-
stopPropagation: import("@angular/core").
|
|
149
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
143
150
|
/**
|
|
144
151
|
* Event emitted on Enter keydown
|
|
145
152
|
*/
|
|
@@ -252,5 +259,5 @@ export declare class TextareaComponent {
|
|
|
252
259
|
*/
|
|
253
260
|
private setupDebounce;
|
|
254
261
|
static ɵfac: i0.ɵɵFactoryDeclaration<TextareaComponent, never>;
|
|
255
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<TextareaComponent, "st-textarea", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "ghost": { "alias": "ghost"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "showOptional": { "alias": "showOptional"; "required": false; "isSignal": true; }; "optionalText": { "alias": "optionalText"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "maxCharacters": { "alias": "maxCharacters"; "required": false; "isSignal": true; }; "parentForm": { "alias": "parentForm"; "required": false; "isSignal": true; }; "formControlName": { "alias": "formControlName"; "required": false; "isSignal": true; }; "stopPropagation": { "alias": "stopPropagation"; "required": false; "isSignal": true; }; "debounceTime": { "alias": "debounceTime"; "required": false; "isSignal": true; }; }, { "disabled": "disabledChange"; "blurred": "blurred"; "value": "valueChange"; "keyDownEnter": "keyDownEnter"; "triggered": "triggered"; "valueDebounced": "valueDebounced"; }, never, ["*"], true, never>;
|
|
262
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TextareaComponent, "st-textarea", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "ghost": { "alias": "ghost"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "showOptional": { "alias": "showOptional"; "required": false; "isSignal": true; }; "optionalText": { "alias": "optionalText"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "readonly": { "alias": "readonly"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "maxCharacters": { "alias": "maxCharacters"; "required": false; "isSignal": true; }; "parentForm": { "alias": "parentForm"; "required": false; "isSignal": true; }; "formControlName": { "alias": "formControlName"; "required": false; "isSignal": true; }; "stopPropagation": { "alias": "stopPropagation"; "required": false; "isSignal": true; }; "debounceTime": { "alias": "debounceTime"; "required": false; "isSignal": true; }; }, { "disabled": "disabledChange"; "blurred": "blurred"; "value": "valueChange"; "keyDownEnter": "keyDownEnter"; "triggered": "triggered"; "valueDebounced": "valueDebounced"; }, never, ["*"], true, never>;
|
|
256
263
|
}
|
|
@@ -29,7 +29,7 @@ export declare class ToggleComponent {
|
|
|
29
29
|
setDisabledState(isDisabled: boolean): void;
|
|
30
30
|
handleToggle(): void;
|
|
31
31
|
valueUpdated: import("@angular/core").OutputEmitterRef<boolean>;
|
|
32
|
-
stopPropagation: import("@angular/core").
|
|
32
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
33
33
|
clicked: import("@angular/core").OutputEmitterRef<MouseEvent>;
|
|
34
34
|
keyDownEnter: import("@angular/core").OutputEmitterRef<KeyboardEvent>;
|
|
35
35
|
keyDownSpace: import("@angular/core").OutputEmitterRef<KeyboardEvent>;
|
|
@@ -19,7 +19,7 @@ export declare class NotificationComponent {
|
|
|
19
19
|
size: import("@angular/core").InputSignal<"auto" | undefined>;
|
|
20
20
|
icon: import("@angular/core").InputSignal<string>;
|
|
21
21
|
status: import("@angular/core").InputSignal<NotificationStatus>;
|
|
22
|
-
disabled: import("@angular/core").
|
|
22
|
+
disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
23
23
|
/**
|
|
24
24
|
* Accessible name of the button. Defaults to `sdk.notification.label`, or `sdk.notification.unseen` while `status` is `'unseen'`.
|
|
25
25
|
*/
|
|
@@ -13,7 +13,7 @@ match the trigger.
|
|
|
13
13
|
```html
|
|
14
14
|
<st-overlay>
|
|
15
15
|
<st-overlay-trigger>
|
|
16
|
-
<st-button>
|
|
16
|
+
<st-button variant="tertiary" [outline]="true">Show details</st-button>
|
|
17
17
|
</st-overlay-trigger>
|
|
18
18
|
<st-overlay-content>Overlay content</st-overlay-content>
|
|
19
19
|
</st-overlay>
|
|
@@ -22,10 +22,15 @@ match the trigger.
|
|
|
22
22
|
## Notes
|
|
23
23
|
|
|
24
24
|
- Position via `originX` / `originY` / `overlayX` / `overlayY` and `fallbacks`.
|
|
25
|
+
- `offsetY` defaults to a 4px gap, like `st-dropdown`, `st-select` and
|
|
26
|
+
`st-combobox`; generated fallbacks that flip to the opposite edge mirror it.
|
|
27
|
+
Pass `[offsetY]="0"` for a flush panel.
|
|
25
28
|
- The primary connection is attempted first, followed by configured fallback
|
|
26
29
|
positions or the built-in Y flip, X flip, both-axis flip, and standard
|
|
27
30
|
placements. CDK push keeps the selected pane inside the viewport.
|
|
28
|
-
-
|
|
31
|
+
- Motion is the shared `popover-motion`: the entrance starts once the CDK
|
|
32
|
+
placed the pane (`data-side`), so a flip never restarts it.
|
|
33
|
+
- Opening and closing remain mounted until the animation settles;
|
|
29
34
|
`opened` and `closed` reflect the settled lifecycle. Escape and outside clicks
|
|
30
35
|
dismiss the overlay, while programmatic and Escape closes restore the captured
|
|
31
36
|
trigger focus.
|
|
@@ -36,7 +36,7 @@ export declare class OverlayTriggerComponent {
|
|
|
36
36
|
* Stop event propagation for activation events
|
|
37
37
|
* @defaultValue false
|
|
38
38
|
*/
|
|
39
|
-
stopPropagation: import("@angular/core").
|
|
39
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
40
40
|
/**
|
|
41
41
|
* Tab index for the trigger wrapper
|
|
42
42
|
* @defaultValue -1
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ConnectedOverlayPositionChange, ConnectedPosition } from '@angular/cdk/overlay';
|
|
2
|
+
import { PopoverMotionState, PopoverPlacement } from '@sixbell-telco/sdk/utils/popover-motion';
|
|
2
3
|
import { ThemeDomService } from '@sixbell-telco/sdk/utils/theme';
|
|
3
4
|
import { OverlayContentComponent } from '../overlay-content/overlay-content.component';
|
|
4
5
|
import { OverlayTriggerComponent } from '../overlay-trigger/overlay-trigger.component';
|
|
@@ -14,7 +15,6 @@ export interface OverlayFallbackPositions {
|
|
|
14
15
|
/** Custom fallback positions - if not provided, default fallbacks will be used */
|
|
15
16
|
positions?: ConnectedPosition[];
|
|
16
17
|
}
|
|
17
|
-
type OverlayPhase = 'closed' | 'opening' | 'open' | 'closing';
|
|
18
18
|
/**
|
|
19
19
|
* Overlay - Shell component for creating custom overlays with positioning
|
|
20
20
|
*
|
|
@@ -71,7 +71,7 @@ export declare class OverlayComponent {
|
|
|
71
71
|
private readonly animatedRoot;
|
|
72
72
|
/** Offset X in pixels */
|
|
73
73
|
offsetX: import("@angular/core").InputSignal<number>;
|
|
74
|
-
/**
|
|
74
|
+
/** Gap in pixels between the trigger and the panel; flipped fallbacks mirror it */
|
|
75
75
|
offsetY: import("@angular/core").InputSignal<number>;
|
|
76
76
|
/** Origin X position */
|
|
77
77
|
originX: import("@angular/core").InputSignal<OverlayXPosition>;
|
|
@@ -84,13 +84,13 @@ export declare class OverlayComponent {
|
|
|
84
84
|
/** Fallback positions configuration */
|
|
85
85
|
fallbacks: import("@angular/core").InputSignal<OverlayFallbackPositions>;
|
|
86
86
|
/** Whether to sync the overlay content width with the trigger width */
|
|
87
|
-
syncWidth: import("@angular/core").
|
|
87
|
+
syncWidth: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
88
88
|
/** Internal signal to track overlay state */
|
|
89
89
|
readonly _isOpen: import("@angular/core").WritableSignal<boolean>;
|
|
90
90
|
/** Internal signal to keep the portal rendered during exit animation */
|
|
91
91
|
readonly renderedOpen: import("@angular/core").WritableSignal<boolean>;
|
|
92
92
|
/** Current animation lifecycle phase */
|
|
93
|
-
readonly phase: import("@angular/core").WritableSignal<
|
|
93
|
+
readonly phase: import("@angular/core").WritableSignal<PopoverMotionState>;
|
|
94
94
|
private transitionToken;
|
|
95
95
|
private closeReason;
|
|
96
96
|
private restoreTarget;
|
|
@@ -99,8 +99,10 @@ export declare class OverlayComponent {
|
|
|
99
99
|
private animationFallbackHandle;
|
|
100
100
|
/** Internal signal to track the synced width */
|
|
101
101
|
readonly _syncedWidth: import("@angular/core").WritableSignal<string | null>;
|
|
102
|
-
/**
|
|
102
|
+
/** Position the CDK applied for the current open cycle; null until the first `positionChange` */
|
|
103
103
|
currentPosition: import("@angular/core").WritableSignal<ConnectedPosition | null>;
|
|
104
|
+
/** Real placement of the open panel, bound to `data-side` / `data-align`; null until the CDK places it */
|
|
105
|
+
readonly placement: import("@angular/core").Signal<PopoverPlacement | null>;
|
|
104
106
|
/** Event emitted when overlay is opened */
|
|
105
107
|
opened: import("@angular/core").OutputEmitterRef<void>;
|
|
106
108
|
/** Event emitted when overlay is closed */
|
|
@@ -152,6 +154,8 @@ export declare class OverlayComponent {
|
|
|
152
154
|
*/
|
|
153
155
|
toggle(): void;
|
|
154
156
|
private requestState;
|
|
157
|
+
/** Measure the fallback once the next render applied the phase, so the computed animation is the real one */
|
|
158
|
+
private deferAnimationFallback;
|
|
155
159
|
private settleOpening;
|
|
156
160
|
private settleClosing;
|
|
157
161
|
private scheduleAnimationFallback;
|
|
@@ -159,9 +163,6 @@ export declare class OverlayComponent {
|
|
|
159
163
|
private captureFocusTarget;
|
|
160
164
|
private restoreFocus;
|
|
161
165
|
private isFocusable;
|
|
162
|
-
private expectedAnimationName;
|
|
163
|
-
private sideFromPair;
|
|
164
|
-
protected animationClass(): string;
|
|
165
166
|
/**
|
|
166
167
|
* Update the synced width based on trigger element width
|
|
167
168
|
*/
|
|
@@ -170,6 +171,7 @@ export declare class OverlayComponent {
|
|
|
170
171
|
* Handle position changes from CDK overlay
|
|
171
172
|
*/
|
|
172
173
|
onAttach(): void;
|
|
174
|
+
/** The first position of an open cycle starts the entrance (`data-side`), so its fallback is measured then */
|
|
173
175
|
onPositionChange(position: ConnectedOverlayPositionChange): void;
|
|
174
176
|
onAnimationEnd(event: AnimationEvent): void;
|
|
175
177
|
onAnimationCancel(event: AnimationEvent): void;
|
|
@@ -188,4 +190,3 @@ export declare class OverlayComponent {
|
|
|
188
190
|
static ɵfac: i0.ɵɵFactoryDeclaration<OverlayComponent, never>;
|
|
189
191
|
static ɵcmp: i0.ɵɵComponentDeclaration<OverlayComponent, "st-overlay", ["stOverlay"], { "offsetX": { "alias": "offsetX"; "required": false; "isSignal": true; }; "offsetY": { "alias": "offsetY"; "required": false; "isSignal": true; }; "originX": { "alias": "originX"; "required": false; "isSignal": true; }; "originY": { "alias": "originY"; "required": false; "isSignal": true; }; "overlayX": { "alias": "overlayX"; "required": false; "isSignal": true; }; "overlayY": { "alias": "overlayY"; "required": false; "isSignal": true; }; "fallbacks": { "alias": "fallbacks"; "required": false; "isSignal": true; }; "syncWidth": { "alias": "syncWidth"; "required": false; "isSignal": true; }; }, { "opened": "opened"; "closed": "closed"; }, ["trigger", "content"], ["st-overlay-trigger"], true, never>;
|
|
190
192
|
}
|
|
191
|
-
export {};
|
|
@@ -70,17 +70,17 @@ export declare class PaginationItemComponent {
|
|
|
70
70
|
* Active state styling
|
|
71
71
|
* @defaultValue false
|
|
72
72
|
*/
|
|
73
|
-
active: import("@angular/core").
|
|
73
|
+
active: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
74
74
|
/**
|
|
75
75
|
* Disabled state styling
|
|
76
76
|
* @defaultValue false
|
|
77
77
|
*/
|
|
78
|
-
disabled: import("@angular/core").
|
|
78
|
+
disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
79
79
|
/**
|
|
80
80
|
* Stop event propagation for activation events
|
|
81
81
|
* @defaultValue false
|
|
82
82
|
*/
|
|
83
|
-
stopPropagation: import("@angular/core").
|
|
83
|
+
stopPropagation: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
84
84
|
/**
|
|
85
85
|
* Accessible name forwarded to the inner `<button>` as `aria-label`.
|
|
86
86
|
* Required for the `icon` and `dots` variants, which have no visible text.
|
|
@@ -58,7 +58,7 @@ export declare class ProgressComponent {
|
|
|
58
58
|
* Enable indeterminate animation
|
|
59
59
|
* @defaultValue false
|
|
60
60
|
*/
|
|
61
|
-
indeterminate: import("@angular/core").
|
|
61
|
+
indeterminate: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
62
62
|
/**
|
|
63
63
|
* Position of progress value label
|
|
64
64
|
* @defaultValue 'none'
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Segmented Button
|
|
2
|
+
|
|
3
|
+
Import: `@sixbell-telco/sdk/components/segmented-button`
|
|
4
|
+
|
|
5
|
+
Selector: `st-segmented-button`
|
|
6
|
+
|
|
7
|
+
Single-choice control styled as a compact button bar, for picking a value such
|
|
8
|
+
as a period, an export format or a view mode.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
```html
|
|
13
|
+
<st-segmented-button ariaLabel="Period" [options]="periods" [(value)]="period" />
|
|
14
|
+
|
|
15
|
+
<st-segmented-button ariaLabel="Format" variant="primary" fullWidth [options]="formats" formControlName="format" />
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
```ts
|
|
19
|
+
periods: SegmentedButtonOption[] = [
|
|
20
|
+
{ value: 'day', label: 'Day' },
|
|
21
|
+
{ value: 'month', label: 'Month' },
|
|
22
|
+
{ value: 'list', icon: heroListBullet, ariaLabel: 'List' },
|
|
23
|
+
];
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
| Input | Default | Purpose |
|
|
27
|
+
| ---------------- | ------- | ------------------------------------------------------------- |
|
|
28
|
+
| `options` | `[]` | `{ value, label?, icon?, ariaLabel?, disabled? }` per segment |
|
|
29
|
+
| `value` (model) | `null` | Selected value, two-way with `[(value)]` |
|
|
30
|
+
| `variant` | `base` | Selected segment color (`primary`, `secondary`, …) |
|
|
31
|
+
| `size` | `md` | `xs`–`xl`, same scale as `st-button` |
|
|
32
|
+
| `fullWidth` | `false` | Stretch to the parent; segments share the width |
|
|
33
|
+
| `disabled` | `false` | Disable every segment |
|
|
34
|
+
| `ariaLabel` | `''` | Accessible name of the group |
|
|
35
|
+
| `ariaLabelledby` | `''` | Id of a visible label naming the group |
|
|
36
|
+
| `class` | `''` | Extra classes merged onto the track |
|
|
37
|
+
|
|
38
|
+
Implements `ControlValueAccessor` (`formControlName`, `formControl`, `ngModel`),
|
|
39
|
+
including `disable()`; the control is marked touched when focus leaves the group.
|
|
40
|
+
|
|
41
|
+
## Accessibility
|
|
42
|
+
|
|
43
|
+
- WAI-ARIA APG radio group: the host is `role="radiogroup"`, each segment is a
|
|
44
|
+
native `button` with `role="radio"` and `aria-checked`.
|
|
45
|
+
- One tab stop (roving tabindex): the checked segment, or the first enabled one.
|
|
46
|
+
- Arrow Right/Down and Left/Up move focus and select, wrapping and skipping
|
|
47
|
+
disabled segments (Left/Right flip in RTL). Home/End go to the first/last
|
|
48
|
+
segment. Space and Enter select the focused segment.
|
|
49
|
+
- Always name the group (`ariaLabel` or `ariaLabelledby`). Icon-only segments
|
|
50
|
+
need their own `ariaLabel`; icons are `aria-hidden`.
|
|
51
|
+
|
|
52
|
+
## When to use something else
|
|
53
|
+
|
|
54
|
+
- `st-tab`: switches between content panels (tablist semantics), not a form value.
|
|
55
|
+
- `st-radio`: long or descriptive choices, or more than about five options.
|
|
56
|
+
- `st-toggle` / `st-switch`: a single on/off value.
|
|
57
|
+
- DaisyUI `join` only groups buttons visually; it has no selection or keyboard model.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src/segmented-button.component';
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/** Value carried by a segment */
|
|
4
|
+
export type SegmentedButtonValue = string | number | boolean;
|
|
5
|
+
/** One segment of `st-segmented-button` */
|
|
6
|
+
export type SegmentedButtonOption = {
|
|
7
|
+
value: SegmentedButtonValue;
|
|
8
|
+
/** Visible text. Optional when `icon` is set, but then `ariaLabel` is required. */
|
|
9
|
+
label?: string;
|
|
10
|
+
/** Icon SVG (same format as `st-icon` `icon`) rendered before the label. */
|
|
11
|
+
icon?: string;
|
|
12
|
+
/** Accessible name for icon-only segments. */
|
|
13
|
+
ariaLabel?: string;
|
|
14
|
+
disabled?: boolean;
|
|
15
|
+
};
|
|
16
|
+
/** Possible segmented button color variants (selected segment) */
|
|
17
|
+
export type SegmentedButtonVariantProps = 'base' | 'primary' | 'secondary' | 'tertiary' | 'accent' | 'info' | 'success' | 'warning' | 'error' | null | undefined;
|
|
18
|
+
/** Possible segmented button sizes (same scale as `st-button`) */
|
|
19
|
+
export type SegmentedButtonSizeProps = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | null | undefined;
|
|
20
|
+
/**
|
|
21
|
+
* @internal
|
|
22
|
+
* Track (radiogroup) classes
|
|
23
|
+
*/
|
|
24
|
+
export declare const segmentedButtonTrack: (props?: ({
|
|
25
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | null | undefined;
|
|
26
|
+
fullWidth?: boolean | null | undefined;
|
|
27
|
+
disabled?: boolean | null | undefined;
|
|
28
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
29
|
+
/**
|
|
30
|
+
* @internal
|
|
31
|
+
* Segment (radio) classes
|
|
32
|
+
*/
|
|
33
|
+
export declare const segmentedButtonSegment: (props?: ({
|
|
34
|
+
variant?: "base" | "primary" | "secondary" | "tertiary" | "accent" | "info" | "success" | "warning" | "error" | null | undefined;
|
|
35
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | null | undefined;
|
|
36
|
+
selected?: boolean | null | undefined;
|
|
37
|
+
fullWidth?: boolean | null | undefined;
|
|
38
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
39
|
+
/**
|
|
40
|
+
* A single-choice segmented control: a compact, keyboard-accessible radio group styled like a button bar.
|
|
41
|
+
*
|
|
42
|
+
* @remarks
|
|
43
|
+
* - WAI-ARIA radio group pattern: `role="radiogroup"` with `role="radio"` segments, a single tab stop
|
|
44
|
+
* (roving tabindex), arrow keys move focus and select (wrapping, disabled segments skipped), Home/End
|
|
45
|
+
* jump to the first/last segment.
|
|
46
|
+
* - Two-way binding through `[(value)]`, and a `ControlValueAccessor` for reactive and template forms
|
|
47
|
+
* (`formControlName`, `ngModel`), including the disabled state.
|
|
48
|
+
* - Name the group with `ariaLabel` or `ariaLabelledby`; icon-only segments need their own `ariaLabel`.
|
|
49
|
+
* - Use it to pick a value. To switch between content panels, use `st-tab`.
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
* ```html
|
|
53
|
+
* <st-segmented-button ariaLabel="Period" [options]="periods" [(value)]="period" />
|
|
54
|
+
* <st-segmented-button ariaLabel="Format" variant="primary" fullWidth [options]="formats" formControlName="format" />
|
|
55
|
+
* ```
|
|
56
|
+
*/
|
|
57
|
+
export declare class SegmentedButtonComponent implements ControlValueAccessor {
|
|
58
|
+
/** Segments to render, in order. */
|
|
59
|
+
readonly options: import("@angular/core").InputSignal<SegmentedButtonOption[]>;
|
|
60
|
+
/** Selected value (two-way: `[(value)]`). `null` selects nothing. */
|
|
61
|
+
readonly value: import("@angular/core").ModelSignal<SegmentedButtonValue | null>;
|
|
62
|
+
/**
|
|
63
|
+
* Color of the selected segment.
|
|
64
|
+
* @defaultValue 'base'
|
|
65
|
+
*/
|
|
66
|
+
readonly variant: import("@angular/core").InputSignal<SegmentedButtonVariantProps>;
|
|
67
|
+
/**
|
|
68
|
+
* Size, on the same scale as `st-button`.
|
|
69
|
+
* @defaultValue 'md'
|
|
70
|
+
*/
|
|
71
|
+
readonly size: import("@angular/core").InputSignal<SegmentedButtonSizeProps>;
|
|
72
|
+
/** Stretch to the parent width; segments share the space equally. */
|
|
73
|
+
readonly fullWidth: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
74
|
+
/** Disables every segment. */
|
|
75
|
+
readonly disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
76
|
+
/** Accessible name of the group. */
|
|
77
|
+
readonly ariaLabel: import("@angular/core").InputSignal<string>;
|
|
78
|
+
/** Id(s) of the element(s) naming the group, such as a visible label. */
|
|
79
|
+
readonly ariaLabelledby: import("@angular/core").InputSignal<string>;
|
|
80
|
+
/** Extra classes merged onto the track. */
|
|
81
|
+
readonly class: import("@angular/core").InputSignal<string>;
|
|
82
|
+
private readonly formDisabled;
|
|
83
|
+
private readonly segments;
|
|
84
|
+
private readonly host;
|
|
85
|
+
private onChange;
|
|
86
|
+
private onTouched;
|
|
87
|
+
/** @internal */
|
|
88
|
+
readonly isDisabled: import("@angular/core").Signal<boolean>;
|
|
89
|
+
/** @internal Index of the segment that holds the single tab stop. */
|
|
90
|
+
readonly tabStopIndex: import("@angular/core").Signal<number>;
|
|
91
|
+
/** @internal */
|
|
92
|
+
readonly trackClass: import("@angular/core").Signal<string>;
|
|
93
|
+
/** @internal */
|
|
94
|
+
isSelected(option: SegmentedButtonOption): boolean;
|
|
95
|
+
/** @internal */
|
|
96
|
+
segmentClass(option: SegmentedButtonOption): string;
|
|
97
|
+
/** Selects a segment, as a click or arrow key does. Ignored for disabled segments. */
|
|
98
|
+
select(option: SegmentedButtonOption): void;
|
|
99
|
+
/** @internal */
|
|
100
|
+
onKeydown(event: KeyboardEvent, index: number): void;
|
|
101
|
+
/** @internal */
|
|
102
|
+
onFocusOut(event: FocusEvent): void;
|
|
103
|
+
writeValue(value: SegmentedButtonValue | null): void;
|
|
104
|
+
registerOnChange(fn: (value: SegmentedButtonValue | null) => void): void;
|
|
105
|
+
registerOnTouched(fn: () => void): void;
|
|
106
|
+
setDisabledState(isDisabled: boolean): void;
|
|
107
|
+
private findEnabled;
|
|
108
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SegmentedButtonComponent, never>;
|
|
109
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SegmentedButtonComponent, "st-segmented-button", never, { "options": { "alias": "options"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "fullWidth": { "alias": "fullWidth"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "ariaLabelledby": { "alias": "ariaLabelledby"; "required": false; "isSignal": true; }; "class": { "alias": "class"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
|
|
110
|
+
}
|
|
@@ -25,12 +25,12 @@ export declare class SonnerToasterComponent {
|
|
|
25
25
|
* (semantic border and text color on the base-200 surface, applied through the SDK classes).
|
|
26
26
|
* @defaultValue false
|
|
27
27
|
*/
|
|
28
|
-
richColors: import("@angular/core").
|
|
28
|
+
richColors: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
29
29
|
/**
|
|
30
30
|
* Whether to expand the toast on hover
|
|
31
31
|
* @defaultValue false
|
|
32
32
|
*/
|
|
33
|
-
expand: import("@angular/core").
|
|
33
|
+
expand: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
34
34
|
/**
|
|
35
35
|
* Maximum number of visible toasts
|
|
36
36
|
* @defaultValue 3
|
|
@@ -50,7 +50,7 @@ export declare class SonnerToasterComponent {
|
|
|
50
50
|
* Whether to show close button
|
|
51
51
|
* @defaultValue false
|
|
52
52
|
*/
|
|
53
|
-
closeButton: import("@angular/core").
|
|
53
|
+
closeButton: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
54
54
|
/**
|
|
55
55
|
* Duration for the toast in milliseconds
|
|
56
56
|
* @defaultValue 4000
|
|
@@ -18,8 +18,8 @@ export type TabProps = {
|
|
|
18
18
|
export declare class TabComponent {
|
|
19
19
|
variant: import("@angular/core").InputSignal<TabVariantProps>;
|
|
20
20
|
size: import("@angular/core").InputSignal<TabSizeProps>;
|
|
21
|
-
disabled: import("@angular/core").
|
|
22
|
-
active: import("@angular/core").
|
|
21
|
+
disabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
22
|
+
active: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
23
23
|
componentClass: import("@angular/core").Signal<string>;
|
|
24
24
|
static ɵfac: i0.ɵɵFactoryDeclaration<TabComponent, never>;
|
|
25
25
|
static ɵcmp: i0.ɵɵComponentDeclaration<TabComponent, "st-tab", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "active": { "alias": "active"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|