@taiga-ui/core 4.66.0 → 5.0.0-canary.8b64ec1
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/README.md +1 -1
- package/classes/accessors.d.ts +2 -2
- package/classes/driver.d.ts +1 -1
- package/components/button/button.directive.d.ts +2 -3
- package/components/button/button.options.d.ts +1 -1
- package/components/calendar/calendar-sheet.component.d.ts +2 -7
- package/components/calendar/calendar-sheet.options.d.ts +1 -3
- package/{pipes/calendar-sheet → components/calendar}/calendar-sheet.pipe.d.ts +2 -2
- package/components/calendar/calendar-spin.component.d.ts +1 -0
- package/components/calendar/calendar-year.component.d.ts +1 -1
- package/components/calendar/calendar.options.d.ts +9 -0
- package/components/calendar/index.d.ts +3 -0
- package/{pipes/order-week-days → components/calendar}/order-week-days.pipe.d.ts +1 -1
- package/components/cell/cell.directive.d.ts +9 -0
- package/components/cell/cell.options.d.ts +6 -0
- package/components/cell/index.d.ts +2 -0
- package/components/data-list/data-list.component.d.ts +8 -12
- package/components/data-list/data-list.d.ts +3 -4
- package/components/data-list/data-list.tokens.d.ts +1 -20
- package/components/data-list/index.d.ts +3 -4
- package/components/data-list/opt-group.directive.d.ts +2 -2
- package/components/data-list/option-content.directive.d.ts +14 -0
- package/components/data-list/option-with-value.directive.d.ts +9 -0
- package/components/data-list/option.directive.d.ts +19 -0
- package/components/error/error.component.d.ts +6 -8
- package/components/error/error.d.ts +4 -0
- package/components/error/error.directive.d.ts +19 -0
- package/components/error/error.pipe.d.ts +10 -0
- package/components/error/index.d.ts +3 -0
- package/components/expand/expand.component.d.ts +9 -28
- package/components/expand/index.d.ts +0 -2
- package/components/icon/icon.component.d.ts +6 -11
- package/components/index.d.ts +3 -3
- package/components/input/index.d.ts +2 -0
- package/components/input/input.d.ts +5 -0
- package/components/input/input.directive.d.ts +29 -0
- package/components/label/label.directive.d.ts +1 -1
- package/components/link/index.d.ts +0 -1
- package/components/link/link.directive.d.ts +8 -6
- package/components/loader/loader.component.d.ts +7 -7
- package/components/loader/loader.options.d.ts +1 -3
- package/components/notification/index.d.ts +3 -0
- package/components/notification/notification.component.d.ts +14 -0
- package/components/notification/notification.d.ts +3 -0
- package/components/notification/notification.directive.d.ts +7 -12
- package/components/notification/notification.options.d.ts +10 -7
- package/components/notification/notification.service.d.ts +17 -0
- package/components/root/root.component.d.ts +4 -7
- package/components/scrollbar/scroll-into-view.directive.d.ts +3 -2
- package/components/scrollbar/scroll-ref.directive.d.ts +2 -0
- package/components/scrollbar/scrollbar.component.d.ts +1 -5
- package/components/scrollbar/scrollbar.directive.d.ts +2 -2
- package/components/scrollbar/scrollbar.options.d.ts +1 -1
- package/components/spin-button/spin-button.component.d.ts +9 -10
- package/components/textfield/index.d.ts +1 -4
- package/components/textfield/textfield-content.directive.d.ts +3 -2
- package/components/textfield/textfield-icon.d.ts +3 -3
- package/components/textfield/textfield-multi/textfield-item.component.d.ts +3 -2
- package/components/textfield/textfield-multi/textfield-multi.component.d.ts +9 -15
- package/components/textfield/textfield.component.d.ts +20 -35
- package/components/textfield/textfield.d.ts +2 -4
- package/components/textfield/textfield.options.d.ts +8 -11
- package/{directives → components}/title/title.directive.d.ts +2 -3
- package/directives/appearance/appearance.directive.d.ts +5 -13
- package/directives/appearance/appearance.options.d.ts +1 -2
- package/directives/button-x/button-x.directive.d.ts +6 -0
- package/directives/button-x/index.d.ts +1 -0
- package/directives/date-format/date-format.directive.d.ts +3 -7
- package/directives/group/group.directive.d.ts +7 -7
- package/directives/group/group.options.d.ts +1 -3
- package/directives/icons/icons.bindings.d.ts +5 -0
- package/directives/icons/icons.directive.d.ts +8 -16
- package/directives/icons/index.d.ts +1 -0
- package/directives/index.d.ts +1 -5
- package/directives/items-handlers/items-handlers.directive.d.ts +5 -9
- package/directives/items-handlers/items-handlers.tokens.d.ts +4 -4
- package/directives/number-format/number-format.directive.d.ts +3 -7
- package/fesm2022/taiga-ui-core-classes.mjs +9 -11
- package/fesm2022/taiga-ui-core-classes.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-button.mjs +13 -21
- package/fesm2022/taiga-ui-core-components-button.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-calendar.mjs +144 -47
- package/fesm2022/taiga-ui-core-components-calendar.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-cell.mjs +45 -0
- package/fesm2022/taiga-ui-core-components-cell.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-components-data-list.mjs +113 -284
- package/fesm2022/taiga-ui-core-components-data-list.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-error.mjs +110 -26
- package/fesm2022/taiga-ui-core-components-error.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-expand.mjs +34 -132
- package/fesm2022/taiga-ui-core-components-expand.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-icon.mjs +22 -40
- package/fesm2022/taiga-ui-core-components-icon.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-input.mjs +100 -0
- package/fesm2022/taiga-ui-core-components-input.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-components-label.mjs +13 -18
- package/fesm2022/taiga-ui-core-components-label.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-link.mjs +16 -36
- package/fesm2022/taiga-ui-core-components-link.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-loader.mjs +20 -40
- package/fesm2022/taiga-ui-core-components-loader.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-notification.mjs +107 -66
- package/fesm2022/taiga-ui-core-components-notification.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-root.mjs +23 -60
- package/fesm2022/taiga-ui-core-components-root.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-scrollbar.mjs +73 -87
- package/fesm2022/taiga-ui-core-components-scrollbar.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-spin-button.mjs +18 -31
- package/fesm2022/taiga-ui-core-components-spin-button.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-textfield.mjs +136 -435
- package/fesm2022/taiga-ui-core-components-textfield.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-components-title.mjs +37 -0
- package/fesm2022/taiga-ui-core-components-title.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-components.mjs +3 -3
- package/fesm2022/taiga-ui-core-directives-appearance.mjs +32 -69
- package/fesm2022/taiga-ui-core-directives-appearance.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-button-x.mjs +51 -0
- package/fesm2022/taiga-ui-core-directives-button-x.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-directives-date-format.mjs +26 -20
- package/fesm2022/taiga-ui-core-directives-date-format.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-group.mjs +25 -40
- package/fesm2022/taiga-ui-core-directives-group.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-icons.mjs +35 -45
- package/fesm2022/taiga-ui-core-directives-icons.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-items-handlers.mjs +18 -42
- package/fesm2022/taiga-ui-core-directives-items-handlers.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives-number-format.mjs +32 -20
- package/fesm2022/taiga-ui-core-directives-number-format.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-directives.mjs +1 -5
- package/fesm2022/taiga-ui-core-directives.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-pipes-format-number.mjs +21 -15
- package/fesm2022/taiga-ui-core-pipes-format-number.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-pipes.mjs +0 -8
- package/fesm2022/taiga-ui-core-pipes.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-portals-alert.mjs +73 -0
- package/fesm2022/taiga-ui-core-portals-alert.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-portals-dialog.mjs +159 -0
- package/fesm2022/taiga-ui-core-portals-dialog.mjs.map +1 -0
- package/fesm2022/{taiga-ui-core-directives-dropdown.mjs → taiga-ui-core-portals-dropdown.mjs} +249 -414
- package/fesm2022/taiga-ui-core-portals-dropdown.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-portals-hint.mjs +552 -0
- package/fesm2022/taiga-ui-core-portals-hint.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-portals-modal.mjs +89 -0
- package/fesm2022/taiga-ui-core-portals-modal.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-portals-popup.mjs +56 -0
- package/fesm2022/taiga-ui-core-portals-popup.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-portals.mjs +11 -0
- package/fesm2022/taiga-ui-core-portals.mjs.map +1 -0
- package/fesm2022/taiga-ui-core-services.mjs +17 -81
- package/fesm2022/taiga-ui-core-services.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-tokens.mjs +62 -81
- package/fesm2022/taiga-ui-core-tokens.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-utils-dom.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-utils-format.mjs +1 -22
- package/fesm2022/taiga-ui-core-utils-format.mjs.map +1 -1
- package/fesm2022/taiga-ui-core-utils-miscellaneous.mjs +55 -19
- package/fesm2022/taiga-ui-core-utils-miscellaneous.mjs.map +1 -1
- package/fesm2022/taiga-ui-core.mjs +1 -1
- package/index.d.ts +1 -1
- package/package.json +61 -182
- package/pipes/format-number/format-number.pipe.d.ts +6 -4
- package/pipes/index.d.ts +0 -8
- package/portals/alert/alert.directive.d.ts +11 -0
- package/portals/alert/alert.service.d.ts +12 -0
- package/portals/alert/index.d.ts +2 -0
- package/portals/dialog/dialog.component.d.ts +14 -0
- package/portals/dialog/dialog.directive.d.ts +8 -0
- package/{components → portals}/dialog/dialog.factory.d.ts +1 -1
- package/portals/dialog/dialog.options.d.ts +25 -0
- package/{components/dialog/dialog-close.service.d.ts → portals/dialog/dialog.providers.d.ts} +2 -0
- package/portals/dialog/dialog.service.d.ts +10 -0
- package/portals/dialog/index.d.ts +6 -0
- package/portals/dropdown/dropdown-close.directive.d.ts +15 -0
- package/portals/dropdown/dropdown-content.directive.d.ts +9 -0
- package/{directives → portals}/dropdown/dropdown-context.directive.d.ts +0 -1
- package/{directives → portals}/dropdown/dropdown-hover.directive.d.ts +5 -10
- package/{directives → portals}/dropdown/dropdown-hover.options.d.ts +1 -3
- package/{directives → portals}/dropdown/dropdown-manual.directive.d.ts +2 -2
- package/portals/dropdown/dropdown-open.directive.d.ts +29 -0
- package/{directives → portals}/dropdown/dropdown-options.directive.d.ts +1 -5
- package/{directives → portals}/dropdown/dropdown-position-sided.directive.d.ts +3 -3
- package/{directives → portals}/dropdown/dropdown-position.directive.d.ts +6 -6
- package/{directives → portals}/dropdown/dropdown-selection.directive.d.ts +4 -5
- package/{directives → portals}/dropdown/dropdown.bindings.d.ts +0 -1
- package/{directives → portals}/dropdown/dropdown.d.ts +2 -3
- package/{directives → portals}/dropdown/dropdown.directive.d.ts +6 -8
- package/{directives → portals}/dropdown/index.d.ts +2 -4
- package/{directives → portals}/hint/hint-describe.directive.d.ts +4 -6
- package/{directives → portals}/hint/hint-host.directive.d.ts +2 -2
- package/{directives → portals}/hint/hint-hover.directive.d.ts +3 -4
- package/{directives → portals}/hint/hint-manual.directive.d.ts +2 -2
- package/portals/hint/hint-options.directive.d.ts +17 -0
- package/{directives → portals}/hint/hint-overflow.directive.d.ts +2 -2
- package/{directives → portals}/hint/hint-position.directive.d.ts +7 -8
- package/{directives → portals}/hint/hint-unstyled.component.d.ts +2 -7
- package/portals/hint/hint.component.d.ts +29 -0
- package/{directives → portals}/hint/hint.d.ts +1 -2
- package/portals/hint/hint.directive.d.ts +24 -0
- package/{directives → portals}/hint/index.d.ts +0 -2
- package/portals/index.d.ts +6 -0
- package/portals/modal/index.d.ts +2 -0
- package/portals/modal/modal.component.d.ts +17 -0
- package/portals/modal/modal.service.d.ts +13 -0
- package/portals/popup/popup.directive.d.ts +12 -0
- package/{directives → portals}/popup/popup.service.d.ts +1 -1
- package/{directives → portals}/popup/popups.component.d.ts +2 -2
- package/services/index.d.ts +0 -3
- package/styles/components/appearance.less +5 -0
- package/styles/components/button.less +10 -22
- package/styles/components/icon.less +42 -21
- package/styles/components/icons.less +18 -13
- package/styles/components/label.less +3 -12
- package/styles/components/link.less +8 -27
- package/styles/components/notification.less +31 -65
- package/styles/components/textfield.less +128 -213
- package/styles/components/title.less +8 -8
- package/styles/mixins/appearance.less +11 -26
- package/styles/mixins/appearance.scss +9 -24
- package/styles/mixins/date-picker.less +1 -1
- package/styles/mixins/mixins.less +1 -7
- package/styles/mixins/mixins.scss +1 -7
- package/styles/mixins/picker.less +1 -1
- package/styles/mixins/picker.scss +1 -1
- package/styles/mixins/slider.less +28 -24
- package/styles/mixins/slider.scss +23 -22
- package/styles/taiga-ui-local.less +0 -1
- package/styles/taiga-ui-local.scss +0 -1
- package/styles/taiga-ui-theme.less +0 -1
- package/styles/theme/appearance/outline.less +9 -18
- package/styles/theme/appearance/primary.less +2 -4
- package/styles/theme/appearance/secondary.less +6 -14
- package/styles/theme/appearance/status.less +0 -4
- package/styles/theme/appearance/table.less +36 -35
- package/styles/theme/appearance/textfield.less +27 -28
- package/styles/theme/appearance.less +0 -1
- package/styles/theme/variables.less +16 -19
- package/styles/variables/media.less +13 -18
- package/styles/variables/media.scss +13 -13
- package/tokens/breakpoint.d.ts +4 -0
- package/tokens/common-icons.d.ts +3 -3
- package/tokens/date-format.d.ts +2 -3
- package/tokens/i18n.d.ts +7 -7
- package/tokens/icon-resolver.d.ts +1 -5
- package/tokens/icons.d.ts +0 -4
- package/tokens/index.d.ts +2 -4
- package/tokens/number-format.d.ts +2 -3
- package/tokens/validation-errors.d.ts +4 -0
- package/types/direction.d.ts +1 -1
- package/types/index.d.ts +0 -3
- package/types/point.d.ts +1 -1
- package/types/size.d.ts +0 -11
- package/utils/format/index.d.ts +0 -1
- package/utils/miscellaneous/get-duration.d.ts +2 -0
- package/utils/miscellaneous/index.d.ts +2 -1
- package/utils/miscellaneous/provide-taiga.d.ts +13 -0
- package/animations/animations.d.ts +0 -109
- package/animations/index.d.ts +0 -1
- package/components/alert/alert.component.d.ts +0 -15
- package/components/alert/alert.directive.d.ts +0 -7
- package/components/alert/alert.interfaces.d.ts +0 -12
- package/components/alert/alert.service.d.ts +0 -7
- package/components/alert/alert.tokens.d.ts +0 -12
- package/components/alert/alerts.component.d.ts +0 -12
- package/components/alert/index.d.ts +0 -6
- package/components/data-list/data-list.directive.d.ts +0 -7
- package/components/data-list/option/option-content.d.ts +0 -16
- package/components/data-list/option/option-legacy.component.d.ts +0 -24
- package/components/data-list/option/option.directive.d.ts +0 -27
- package/components/dialog/active-zone-adapter.directive.d.ts +0 -11
- package/components/dialog/dialog.component.d.ts +0 -20
- package/components/dialog/dialog.directive.d.ts +0 -7
- package/components/dialog/dialog.interfaces.d.ts +0 -34
- package/components/dialog/dialog.service.d.ts +0 -7
- package/components/dialog/dialog.tokens.d.ts +0 -15
- package/components/dialog/dialogs.component.d.ts +0 -8
- package/components/dialog/index.d.ts +0 -8
- package/components/expand/expand-content.directive.d.ts +0 -8
- package/components/expand/expand.d.ts +0 -6
- package/components/fullscreen/fullscreen.component.d.ts +0 -14
- package/components/fullscreen/index.d.ts +0 -1
- package/components/link/link.options.d.ts +0 -12
- package/components/textfield/select.directive.d.ts +0 -19
- package/components/textfield/textfield-dropdown.directive.d.ts +0 -16
- package/components/textfield/textfield.directive.d.ts +0 -38
- package/directives/dropdown/dropdown-open-legacy.directive.d.ts +0 -12
- package/directives/dropdown/dropdown-open.directive.d.ts +0 -33
- package/directives/dropdown/dropdown-portal.directive.d.ts +0 -14
- package/directives/dropdown/dropdown.service.d.ts +0 -6
- package/directives/dropdown/dropdowns.component.d.ts +0 -9
- package/directives/hint/hint-options.directive.d.ts +0 -36
- package/directives/hint/hint.component.d.ts +0 -30
- package/directives/hint/hint.directive.d.ts +0 -26
- package/directives/hint/hint.service.d.ts +0 -13
- package/directives/hint/hints.component.d.ts +0 -12
- package/directives/popup/popup.directive.d.ts +0 -11
- package/directives/surface/index.d.ts +0 -1
- package/directives/surface/surface.directive.d.ts +0 -8
- package/esm2022/animations/animations.mjs +0 -363
- package/esm2022/animations/index.mjs +0 -2
- package/esm2022/animations/taiga-ui-core-animations.mjs +0 -5
- package/esm2022/classes/accessors.mjs +0 -31
- package/esm2022/classes/driver.mjs +0 -36
- package/esm2022/classes/index.mjs +0 -4
- package/esm2022/classes/taiga-ui-core-classes.mjs +0 -5
- package/esm2022/classes/vehicle.mjs +0 -7
- package/esm2022/components/alert/alert.component.mjs +0 -43
- package/esm2022/components/alert/alert.directive.mjs +0 -21
- package/esm2022/components/alert/alert.interfaces.mjs +0 -2
- package/esm2022/components/alert/alert.service.mjs +0 -18
- package/esm2022/components/alert/alert.tokens.mjs +0 -51
- package/esm2022/components/alert/alerts.component.mjs +0 -33
- package/esm2022/components/alert/index.mjs +0 -6
- package/esm2022/components/alert/taiga-ui-core-components-alert.mjs +0 -5
- package/esm2022/components/button/button.directive.mjs +0 -43
- package/esm2022/components/button/button.options.mjs +0 -7
- package/esm2022/components/button/index.mjs +0 -3
- package/esm2022/components/button/taiga-ui-core-components-button.mjs +0 -5
- package/esm2022/components/calendar/calendar-sheet.component.mjs +0 -168
- package/esm2022/components/calendar/calendar-sheet.options.mjs +0 -12
- package/esm2022/components/calendar/calendar-spin.component.mjs +0 -53
- package/esm2022/components/calendar/calendar-year.component.mjs +0 -128
- package/esm2022/components/calendar/calendar.component.mjs +0 -147
- package/esm2022/components/calendar/index.mjs +0 -6
- package/esm2022/components/calendar/taiga-ui-core-components-calendar.mjs +0 -5
- package/esm2022/components/data-list/data-list.component.mjs +0 -139
- package/esm2022/components/data-list/data-list.directive.mjs +0 -19
- package/esm2022/components/data-list/data-list.mjs +0 -14
- package/esm2022/components/data-list/data-list.tokens.mjs +0 -18
- package/esm2022/components/data-list/index.mjs +0 -9
- package/esm2022/components/data-list/opt-group.directive.mjs +0 -21
- package/esm2022/components/data-list/option/option-content.mjs +0 -36
- package/esm2022/components/data-list/option/option-legacy.component.mjs +0 -90
- package/esm2022/components/data-list/option/option.directive.mjs +0 -109
- package/esm2022/components/data-list/taiga-ui-core-components-data-list.mjs +0 -5
- package/esm2022/components/dialog/active-zone-adapter.directive.mjs +0 -37
- package/esm2022/components/dialog/dialog-close.service.mjs +0 -41
- package/esm2022/components/dialog/dialog.component.mjs +0 -63
- package/esm2022/components/dialog/dialog.directive.mjs +0 -21
- package/esm2022/components/dialog/dialog.factory.mjs +0 -15
- package/esm2022/components/dialog/dialog.interfaces.mjs +0 -2
- package/esm2022/components/dialog/dialog.service.mjs +0 -18
- package/esm2022/components/dialog/dialog.tokens.mjs +0 -33
- package/esm2022/components/dialog/dialogs.component.mjs +0 -31
- package/esm2022/components/dialog/index.mjs +0 -8
- package/esm2022/components/dialog/taiga-ui-core-components-dialog.mjs +0 -5
- package/esm2022/components/error/error.component.mjs +0 -34
- package/esm2022/components/error/index.mjs +0 -2
- package/esm2022/components/error/taiga-ui-core-components-error.mjs +0 -5
- package/esm2022/components/expand/expand-content.directive.mjs +0 -18
- package/esm2022/components/expand/expand.component.mjs +0 -124
- package/esm2022/components/expand/expand.mjs +0 -7
- package/esm2022/components/expand/index.mjs +0 -4
- package/esm2022/components/expand/taiga-ui-core-components-expand.mjs +0 -5
- package/esm2022/components/fullscreen/fullscreen.component.mjs +0 -71
- package/esm2022/components/fullscreen/index.mjs +0 -2
- package/esm2022/components/fullscreen/taiga-ui-core-components-fullscreen.mjs +0 -5
- package/esm2022/components/icon/icon.component.mjs +0 -44
- package/esm2022/components/icon/icon.pipe.mjs +0 -19
- package/esm2022/components/icon/index.mjs +0 -3
- package/esm2022/components/icon/taiga-ui-core-components-icon.mjs +0 -5
- package/esm2022/components/index.mjs +0 -18
- package/esm2022/components/label/index.mjs +0 -2
- package/esm2022/components/label/label.directive.mjs +0 -41
- package/esm2022/components/label/taiga-ui-core-components-label.mjs +0 -5
- package/esm2022/components/link/index.mjs +0 -3
- package/esm2022/components/link/link.directive.mjs +0 -47
- package/esm2022/components/link/link.options.mjs +0 -13
- package/esm2022/components/link/taiga-ui-core-components-link.mjs +0 -5
- package/esm2022/components/loader/index.mjs +0 -3
- package/esm2022/components/loader/loader.component.mjs +0 -46
- package/esm2022/components/loader/loader.options.mjs +0 -18
- package/esm2022/components/loader/taiga-ui-core-components-loader.mjs +0 -5
- package/esm2022/components/notification/index.mjs +0 -3
- package/esm2022/components/notification/notification.directive.mjs +0 -81
- package/esm2022/components/notification/notification.options.mjs +0 -23
- package/esm2022/components/notification/taiga-ui-core-components-notification.mjs +0 -5
- package/esm2022/components/root/index.mjs +0 -2
- package/esm2022/components/root/root.component.mjs +0 -87
- package/esm2022/components/root/taiga-ui-core-components-root.mjs +0 -5
- package/esm2022/components/scrollbar/index.mjs +0 -9
- package/esm2022/components/scrollbar/scroll-controls.component.mjs +0 -32
- package/esm2022/components/scrollbar/scroll-into-view.directive.mjs +0 -43
- package/esm2022/components/scrollbar/scroll-ref.directive.mjs +0 -19
- package/esm2022/components/scrollbar/scrollable.directive.mjs +0 -26
- package/esm2022/components/scrollbar/scrollbar.component.mjs +0 -72
- package/esm2022/components/scrollbar/scrollbar.directive.mjs +0 -93
- package/esm2022/components/scrollbar/scrollbar.options.mjs +0 -6
- package/esm2022/components/scrollbar/scrollbar.service.mjs +0 -46
- package/esm2022/components/scrollbar/taiga-ui-core-components-scrollbar.mjs +0 -5
- package/esm2022/components/spin-button/index.mjs +0 -2
- package/esm2022/components/spin-button/spin-button.component.mjs +0 -51
- package/esm2022/components/spin-button/taiga-ui-core-components-spin-button.mjs +0 -5
- package/esm2022/components/taiga-ui-core-components.mjs +0 -5
- package/esm2022/components/textfield/index.mjs +0 -16
- package/esm2022/components/textfield/select-like.directive.mjs +0 -44
- package/esm2022/components/textfield/select.directive.mjs +0 -64
- package/esm2022/components/textfield/taiga-ui-core-components-textfield.mjs +0 -5
- package/esm2022/components/textfield/textfield-accessor.mjs +0 -7
- package/esm2022/components/textfield/textfield-auxiliary.mjs +0 -7
- package/esm2022/components/textfield/textfield-content.directive.mjs +0 -22
- package/esm2022/components/textfield/textfield-dropdown.directive.mjs +0 -43
- package/esm2022/components/textfield/textfield-icon.mjs +0 -10
- package/esm2022/components/textfield/textfield-multi/textfield-item.component.mjs +0 -34
- package/esm2022/components/textfield/textfield-multi/textfield-multi.component.mjs +0 -137
- package/esm2022/components/textfield/textfield.component.mjs +0 -183
- package/esm2022/components/textfield/textfield.directive.mjs +0 -134
- package/esm2022/components/textfield/textfield.mjs +0 -19
- package/esm2022/components/textfield/textfield.options.mjs +0 -63
- package/esm2022/components/textfield/with-native-picker.directive.mjs +0 -24
- package/esm2022/directives/appearance/appearance.bindings.mjs +0 -15
- package/esm2022/directives/appearance/appearance.directive.mjs +0 -79
- package/esm2022/directives/appearance/appearance.options.mjs +0 -12
- package/esm2022/directives/appearance/index.mjs +0 -5
- package/esm2022/directives/appearance/taiga-ui-core-directives-appearance.mjs +0 -5
- package/esm2022/directives/appearance/with-appearance.mjs +0 -27
- package/esm2022/directives/date-format/date-format.directive.mjs +0 -31
- package/esm2022/directives/date-format/index.mjs +0 -2
- package/esm2022/directives/date-format/taiga-ui-core-directives-date-format.mjs +0 -5
- package/esm2022/directives/dropdown/dropdown-context.directive.mjs +0 -76
- package/esm2022/directives/dropdown/dropdown-hover.directive.mjs +0 -70
- package/esm2022/directives/dropdown/dropdown-hover.options.mjs +0 -17
- package/esm2022/directives/dropdown/dropdown-limit-width.mjs +0 -37
- package/esm2022/directives/dropdown/dropdown-manual.directive.mjs +0 -27
- package/esm2022/directives/dropdown/dropdown-open-legacy.directive.mjs +0 -33
- package/esm2022/directives/dropdown/dropdown-open.directive.mjs +0 -169
- package/esm2022/directives/dropdown/dropdown-options.directive.mjs +0 -73
- package/esm2022/directives/dropdown/dropdown-portal.directive.mjs +0 -34
- package/esm2022/directives/dropdown/dropdown-position-sided.directive.mjs +0 -69
- package/esm2022/directives/dropdown/dropdown-position.directive.mjs +0 -88
- package/esm2022/directives/dropdown/dropdown-selection.directive.mjs +0 -159
- package/esm2022/directives/dropdown/dropdown.bindings.mjs +0 -19
- package/esm2022/directives/dropdown/dropdown.component.mjs +0 -92
- package/esm2022/directives/dropdown/dropdown.directive.mjs +0 -110
- package/esm2022/directives/dropdown/dropdown.driver.mjs +0 -32
- package/esm2022/directives/dropdown/dropdown.mjs +0 -29
- package/esm2022/directives/dropdown/dropdown.providers.mjs +0 -10
- package/esm2022/directives/dropdown/dropdown.service.mjs +0 -15
- package/esm2022/directives/dropdown/dropdowns.component.mjs +0 -24
- package/esm2022/directives/dropdown/index.mjs +0 -22
- package/esm2022/directives/dropdown/taiga-ui-core-directives-dropdown.mjs +0 -5
- package/esm2022/directives/dropdown/with-dropdown-open.directive.mjs +0 -23
- package/esm2022/directives/group/group.directive.mjs +0 -53
- package/esm2022/directives/group/group.options.mjs +0 -15
- package/esm2022/directives/group/index.mjs +0 -3
- package/esm2022/directives/group/taiga-ui-core-directives-group.mjs +0 -5
- package/esm2022/directives/hint/hint-describe.directive.mjs +0 -50
- package/esm2022/directives/hint/hint-driver.directive.mjs +0 -19
- package/esm2022/directives/hint/hint-host.directive.mjs +0 -27
- package/esm2022/directives/hint/hint-hover.directive.mjs +0 -59
- package/esm2022/directives/hint/hint-manual.directive.mjs +0 -33
- package/esm2022/directives/hint/hint-options.directive.mjs +0 -86
- package/esm2022/directives/hint/hint-overflow.directive.mjs +0 -38
- package/esm2022/directives/hint/hint-pointer.directive.mjs +0 -33
- package/esm2022/directives/hint/hint-position.directive.mjs +0 -115
- package/esm2022/directives/hint/hint-unstyled.component.mjs +0 -39
- package/esm2022/directives/hint/hint.component.mjs +0 -127
- package/esm2022/directives/hint/hint.directive.mjs +0 -99
- package/esm2022/directives/hint/hint.mjs +0 -27
- package/esm2022/directives/hint/hint.providers.mjs +0 -9
- package/esm2022/directives/hint/hint.service.mjs +0 -29
- package/esm2022/directives/hint/hints.component.mjs +0 -34
- package/esm2022/directives/hint/index.mjs +0 -17
- package/esm2022/directives/hint/taiga-ui-core-directives-hint.mjs +0 -5
- package/esm2022/directives/icons/icons.directive.mjs +0 -66
- package/esm2022/directives/icons/index.mjs +0 -3
- package/esm2022/directives/icons/taiga-ui-core-directives-icons.mjs +0 -5
- package/esm2022/directives/icons/with-icons.mjs +0 -22
- package/esm2022/directives/index.mjs +0 -12
- package/esm2022/directives/items-handlers/index.mjs +0 -4
- package/esm2022/directives/items-handlers/items-handlers.directive.mjs +0 -63
- package/esm2022/directives/items-handlers/items-handlers.tokens.mjs +0 -27
- package/esm2022/directives/items-handlers/items-handlers.validator.mjs +0 -32
- package/esm2022/directives/items-handlers/taiga-ui-core-directives-items-handlers.mjs +0 -5
- package/esm2022/directives/number-format/index.mjs +0 -2
- package/esm2022/directives/number-format/number-format.directive.mjs +0 -31
- package/esm2022/directives/number-format/taiga-ui-core-directives-number-format.mjs +0 -5
- package/esm2022/directives/popup/index.mjs +0 -4
- package/esm2022/directives/popup/popup.directive.mjs +0 -31
- package/esm2022/directives/popup/popup.service.mjs +0 -15
- package/esm2022/directives/popup/popups.component.mjs +0 -20
- package/esm2022/directives/popup/taiga-ui-core-directives-popup.mjs +0 -5
- package/esm2022/directives/surface/index.mjs +0 -2
- package/esm2022/directives/surface/surface.directive.mjs +0 -44
- package/esm2022/directives/surface/taiga-ui-core-directives-surface.mjs +0 -5
- package/esm2022/directives/taiga-ui-core-directives.mjs +0 -5
- package/esm2022/directives/title/index.mjs +0 -2
- package/esm2022/directives/title/taiga-ui-core-directives-title.mjs +0 -5
- package/esm2022/directives/title/title.directive.mjs +0 -37
- package/esm2022/index.mjs +0 -9
- package/esm2022/pipes/auto-color/auto-color.pipe.mjs +0 -19
- package/esm2022/pipes/auto-color/index.mjs +0 -2
- package/esm2022/pipes/auto-color/taiga-ui-core-pipes-auto-color.mjs +0 -5
- package/esm2022/pipes/calendar-sheet/calendar-sheet.pipe.mjs +0 -54
- package/esm2022/pipes/calendar-sheet/index.mjs +0 -2
- package/esm2022/pipes/calendar-sheet/taiga-ui-core-pipes-calendar-sheet.mjs +0 -5
- package/esm2022/pipes/calendar-sheet/utils.mjs +0 -36
- package/esm2022/pipes/fallback-src/fallback-src.pipe.mjs +0 -23
- package/esm2022/pipes/fallback-src/index.mjs +0 -2
- package/esm2022/pipes/fallback-src/taiga-ui-core-pipes-fallback-src.mjs +0 -5
- package/esm2022/pipes/flag/flag.pipe.mjs +0 -26
- package/esm2022/pipes/flag/index.mjs +0 -2
- package/esm2022/pipes/flag/taiga-ui-core-pipes-flag.mjs +0 -5
- package/esm2022/pipes/format-date/format-date.pipe.mjs +0 -22
- package/esm2022/pipes/format-date/index.mjs +0 -2
- package/esm2022/pipes/format-date/taiga-ui-core-pipes-format-date.mjs +0 -5
- package/esm2022/pipes/format-number/format-number.pipe.mjs +0 -36
- package/esm2022/pipes/format-number/index.mjs +0 -2
- package/esm2022/pipes/format-number/taiga-ui-core-pipes-format-number.mjs +0 -5
- package/esm2022/pipes/index.mjs +0 -10
- package/esm2022/pipes/initials/index.mjs +0 -2
- package/esm2022/pipes/initials/initials.pipe.mjs +0 -23
- package/esm2022/pipes/initials/taiga-ui-core-pipes-initials.mjs +0 -5
- package/esm2022/pipes/month/index.mjs +0 -2
- package/esm2022/pipes/month/month.pipe.mjs +0 -23
- package/esm2022/pipes/month/taiga-ui-core-pipes-month.mjs +0 -5
- package/esm2022/pipes/order-week-days/index.mjs +0 -2
- package/esm2022/pipes/order-week-days/order-week-days.pipe.mjs +0 -30
- package/esm2022/pipes/order-week-days/taiga-ui-core-pipes-order-week-days.mjs +0 -5
- package/esm2022/pipes/taiga-ui-core-pipes.mjs +0 -5
- package/esm2022/services/breakpoint.service.mjs +0 -31
- package/esm2022/services/dark-theme.service.mjs +0 -24
- package/esm2022/services/format-date.service.mjs +0 -24
- package/esm2022/services/index.mjs +0 -6
- package/esm2022/services/position.service.mjs +0 -26
- package/esm2022/services/taiga-ui-core-services.mjs +0 -5
- package/esm2022/services/visual-viewport.service.mjs +0 -29
- package/esm2022/taiga-ui-core.mjs +0 -5
- package/esm2022/tokens/animations-speed.mjs +0 -9
- package/esm2022/tokens/assets-path.mjs +0 -11
- package/esm2022/tokens/auxiliary.mjs +0 -9
- package/esm2022/tokens/common-icons.mjs +0 -18
- package/esm2022/tokens/dark-mode.mjs +0 -43
- package/esm2022/tokens/date-format.mjs +0 -20
- package/esm2022/tokens/day-type-handler.mjs +0 -8
- package/esm2022/tokens/first-day-of-week.mjs +0 -9
- package/esm2022/tokens/i18n.mjs +0 -45
- package/esm2022/tokens/icon-resolver.mjs +0 -44
- package/esm2022/tokens/icon.mjs +0 -8
- package/esm2022/tokens/icons.mjs +0 -21
- package/esm2022/tokens/index.mjs +0 -21
- package/esm2022/tokens/media.mjs +0 -12
- package/esm2022/tokens/number-format.mjs +0 -24
- package/esm2022/tokens/reduced-motion.mjs +0 -7
- package/esm2022/tokens/scroll-ref.mjs +0 -6
- package/esm2022/tokens/selection-stream.mjs +0 -14
- package/esm2022/tokens/spin-icons.mjs +0 -8
- package/esm2022/tokens/taiga-ui-core-tokens.mjs +0 -5
- package/esm2022/tokens/theme.mjs +0 -5
- package/esm2022/tokens/viewport.mjs +0 -35
- package/esm2022/types/direction.mjs +0 -2
- package/esm2022/types/index.mjs +0 -2
- package/esm2022/types/interactive-state.mjs +0 -2
- package/esm2022/types/orientation.mjs +0 -2
- package/esm2022/types/point.mjs +0 -2
- package/esm2022/types/portal-item.mjs +0 -2
- package/esm2022/types/range-state.mjs +0 -2
- package/esm2022/types/size.mjs +0 -13
- package/esm2022/types/taiga-ui-core-types.mjs +0 -5
- package/esm2022/types/value-content-context.mjs +0 -2
- package/esm2022/utils/dom/check-fixed-position.mjs +0 -9
- package/esm2022/utils/dom/get-viewport.mjs +0 -24
- package/esm2022/utils/dom/get-word-range.mjs +0 -51
- package/esm2022/utils/dom/index.mjs +0 -4
- package/esm2022/utils/dom/taiga-ui-core-utils-dom.mjs +0 -5
- package/esm2022/utils/format/format-number.mjs +0 -47
- package/esm2022/utils/format/get-fractional-part-padded.mjs +0 -16
- package/esm2022/utils/format/index.mjs +0 -5
- package/esm2022/utils/format/number-to-string-without-exp.mjs +0 -18
- package/esm2022/utils/format/string-hash-to-hsl.mjs +0 -21
- package/esm2022/utils/format/taiga-ui-core-utils-format.mjs +0 -5
- package/esm2022/utils/index.mjs +0 -4
- package/esm2022/utils/miscellaneous/font-scaling.mjs +0 -21
- package/esm2022/utils/miscellaneous/index.mjs +0 -7
- package/esm2022/utils/miscellaneous/is-editing-key.mjs +0 -18
- package/esm2022/utils/miscellaneous/is-obscured.mjs +0 -8
- package/esm2022/utils/miscellaneous/override-options.mjs +0 -11
- package/esm2022/utils/miscellaneous/size-bigger.mjs +0 -19
- package/esm2022/utils/miscellaneous/taiga-ui-core-utils-miscellaneous.mjs +0 -5
- package/esm2022/utils/miscellaneous/to-animation-options.mjs +0 -16
- package/esm2022/utils/taiga-ui-core-utils.mjs +0 -5
- package/fesm2022/taiga-ui-core-animations.mjs +0 -370
- package/fesm2022/taiga-ui-core-animations.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-components-alert.mjs +0 -149
- package/fesm2022/taiga-ui-core-components-alert.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-components-dialog.mjs +0 -230
- package/fesm2022/taiga-ui-core-components-dialog.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-components-fullscreen.mjs +0 -77
- package/fesm2022/taiga-ui-core-components-fullscreen.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-directives-dropdown.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-directives-hint.mjs +0 -713
- package/fesm2022/taiga-ui-core-directives-hint.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-directives-popup.mjs +0 -63
- package/fesm2022/taiga-ui-core-directives-popup.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-directives-surface.mjs +0 -50
- package/fesm2022/taiga-ui-core-directives-surface.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-directives-title.mjs +0 -43
- package/fesm2022/taiga-ui-core-directives-title.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-auto-color.mjs +0 -25
- package/fesm2022/taiga-ui-core-pipes-auto-color.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-calendar-sheet.mjs +0 -94
- package/fesm2022/taiga-ui-core-pipes-calendar-sheet.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-fallback-src.mjs +0 -29
- package/fesm2022/taiga-ui-core-pipes-fallback-src.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-flag.mjs +0 -32
- package/fesm2022/taiga-ui-core-pipes-flag.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-format-date.mjs +0 -28
- package/fesm2022/taiga-ui-core-pipes-format-date.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-initials.mjs +0 -29
- package/fesm2022/taiga-ui-core-pipes-initials.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-month.mjs +0 -29
- package/fesm2022/taiga-ui-core-pipes-month.mjs.map +0 -1
- package/fesm2022/taiga-ui-core-pipes-order-week-days.mjs +0 -36
- package/fesm2022/taiga-ui-core-pipes-order-week-days.mjs.map +0 -1
- package/pipes/auto-color/auto-color.pipe.d.ts +0 -7
- package/pipes/auto-color/index.d.ts +0 -1
- package/pipes/calendar-sheet/index.d.ts +0 -1
- package/pipes/calendar-sheet/utils.d.ts +0 -20
- package/pipes/fallback-src/fallback-src.pipe.d.ts +0 -9
- package/pipes/fallback-src/index.d.ts +0 -1
- package/pipes/flag/flag.pipe.d.ts +0 -14
- package/pipes/flag/index.d.ts +0 -1
- package/pipes/format-date/format-date.pipe.d.ts +0 -9
- package/pipes/format-date/index.d.ts +0 -1
- package/pipes/initials/index.d.ts +0 -1
- package/pipes/initials/initials.pipe.d.ts +0 -7
- package/pipes/month/index.d.ts +0 -1
- package/pipes/month/month.pipe.d.ts +0 -10
- package/pipes/order-week-days/index.d.ts +0 -1
- package/services/breakpoint.service.d.ts +0 -16
- package/services/dark-theme.service.d.ts +0 -10
- package/services/format-date.service.d.ts +0 -8
- package/styles/mixins/wrapper.less +0 -64
- package/styles/mixins/wrapper.scss +0 -61
- package/styles/theme/appearance/opposite.less +0 -17
- package/styles/theme/wrapper.less +0 -211
- package/tokens/day-type-handler.d.ts +0 -7
- package/tokens/first-day-of-week.d.ts +0 -5
- package/tokens/scroll-ref.d.ts +0 -2
- package/tokens/spin-icons.d.ts +0 -6
- package/types/portal-item.d.ts +0 -9
- package/types/range-state.d.ts +0 -4
- package/types/value-content-context.d.ts +0 -4
- package/utils/format/string-hash-to-hsl.d.ts +0 -6
- package/utils/miscellaneous/to-animation-options.d.ts +0 -4
- /package/{directives → components}/title/index.d.ts +0 -0
- /package/{directives → portals}/dropdown/dropdown-limit-width.d.ts +0 -0
- /package/{directives → portals}/dropdown/dropdown.component.d.ts +0 -0
- /package/{directives → portals}/dropdown/dropdown.driver.d.ts +0 -0
- /package/{directives → portals}/dropdown/dropdown.providers.d.ts +0 -0
- /package/{directives → portals}/dropdown/with-dropdown-open.directive.d.ts +0 -0
- /package/{directives → portals}/hint/hint-driver.directive.d.ts +0 -0
- /package/{directives → portals}/hint/hint-pointer.directive.d.ts +0 -0
- /package/{directives → portals}/hint/hint.providers.d.ts +0 -0
- /package/{directives → portals}/popup/index.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-data-list.mjs","sources":["../../../projects/core/components/data-list/data-list.tokens.ts","../../../projects/core/components/data-list/option/option-content.ts","../../../projects/core/components/data-list/option/option.directive.ts","../../../projects/core/components/data-list/option/option-legacy.component.ts","../../../projects/core/components/data-list/data-list.component.ts","../../../projects/core/components/data-list/data-list.template.html","../../../projects/core/components/data-list/data-list.directive.ts","../../../projects/core/components/data-list/opt-group.directive.ts","../../../projects/core/components/data-list/data-list.ts","../../../projects/core/components/data-list/taiga-ui-core-components-data-list.ts"],"sourcesContent":["import {InjectionToken, type Provider, type Signal, type Type} from '@angular/core';\nimport {type TuiIdentityMatcher, type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {tuiAsAuxiliary} from '@taiga-ui/core/tokens';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiDataListAccessor<T = unknown> {\n // TODO(v5): delete\n getOptions(includeDisabled?: boolean): readonly T[];\n // TODO(v5): remove `undefined` for this property\n options?: Signal<readonly T[]>;\n}\n\n// TODO: Consider refactoring checkOption, it is only needed in ComboBox\nexport interface TuiDataListHost<T> {\n checkOption?(option: T): void;\n handleOption?(option: T): void;\n /**\n * @deprecated Use `inject(TuiItemsHandlersDirective<T>).identityMatcher` instead\n */\n readonly identityMatcher?: TuiIdentityMatcher<T>;\n /**\n * @deprecated Use `inject(TuiItemsHandlersDirective<T>).stringify` instead\n */\n readonly stringify?: TuiStringHandler<T>;\n readonly size?: TuiSizeL | TuiSizeS;\n}\n\n/**\n * Accessor for data-list options\n */\nexport const TUI_DATA_LIST_ACCESSOR = new InjectionToken<TuiDataListAccessor>(\n ngDevMode ? 'TUI_DATA_LIST_ACCESSOR' : '',\n);\n\nexport function tuiAsDataListAccessor(accessor: Type<TuiDataListAccessor>): Provider {\n return [tuiProvide(TUI_DATA_LIST_ACCESSOR, accessor), tuiAsAuxiliary(accessor)];\n}\n\n/**\n * DataList controller\n */\nexport const TUI_DATA_LIST_HOST = new InjectionToken<TuiDataListHost<unknown>>(\n ngDevMode ? 'TUI_DATA_LIST_HOST' : '',\n);\n\nexport function tuiAsDataListHost<T>(host: Type<TuiDataListHost<T>>): Provider {\n return tuiProvide(TUI_DATA_LIST_HOST, host);\n}\n","import {\n ContentChild,\n Directive,\n inject,\n InjectionToken,\n type Provider,\n type TemplateRef,\n type Type,\n} from '@angular/core';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {type PolymorpheusContent} from '@taiga-ui/polymorpheus';\n\n/**\n * Content for tuiOption component\n */\nexport const TUI_OPTION_CONTENT = new InjectionToken<\n | PolymorpheusContent<TuiContext<TemplateRef<Record<string, unknown>>>> // TODO(v5): delete\n | Type<any>\n>(ngDevMode ? 'TUI_OPTION_CONTENT' : '');\n\nexport function tuiAsOptionContent(\n useValue:\n | PolymorpheusContent<TuiContext<TemplateRef<Record<string, unknown>>>> // TODO(v5): delete\n | Type<any>,\n): Provider {\n return {\n provide: TUI_OPTION_CONTENT,\n useValue,\n };\n}\n\n@Directive({\n standalone: true,\n})\nexport class TuiWithOptionContent {\n @ContentChild(TUI_OPTION_CONTENT, {descendants: true})\n protected readonly localContent: Type<any> | null = null;\n\n protected readonly globalContent = inject<Type<any>>(TUI_OPTION_CONTENT, {\n optional: true,\n });\n\n public get content(): Type<any> | null {\n return this.globalContent ?? this.localContent;\n }\n}\n","import {\n createComponent,\n Directive,\n EnvironmentInjector,\n forwardRef,\n inject,\n INJECTOR,\n Input,\n type OnDestroy,\n signal,\n type Type,\n ViewContainerRef,\n} from '@angular/core';\nimport {TUI_IS_MOBILE} from '@taiga-ui/cdk/tokens';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsNativeFocused} from '@taiga-ui/cdk/utils/focus';\nimport {TuiDropdownDirective} from '@taiga-ui/core/directives/dropdown';\nimport {TuiWithIcons} from '@taiga-ui/core/directives/icons';\n\nimport {TuiDataListComponent} from '../data-list.component';\nimport {TUI_DATA_LIST_HOST, type TuiDataListHost} from '../data-list.tokens';\nimport {TUI_OPTION_CONTENT} from './option-content';\n\n// TODO(v5): rename `TuiOptionNew` => `TuiOption` & remove [new] from selector\n// TODO: Consider all use cases for aria roles\n@Directive({\n standalone: true,\n selector: 'button[tuiOption][new], a[tuiOption][new], label[tuiOption][new]',\n hostDirectives: [TuiWithIcons],\n host: {\n type: 'button',\n role: 'option',\n '[attr.disabled]': 'disabled || null',\n '[class._with-dropdown]': 'dropdown?.()',\n '(mousemove.zoneless)': 'onMouseMove()',\n },\n})\nexport class TuiOptionNew<T = unknown> implements OnDestroy {\n private readonly vcr = inject(ViewContainerRef);\n private readonly isMobile = inject(TUI_IS_MOBILE);\n private readonly el = tuiInjectElement();\n private readonly dataList = inject<TuiDataListComponent<T>>(\n forwardRef(() => TuiDataListComponent),\n {optional: true},\n );\n\n private readonly content = inject<Type<any> | null>(TUI_OPTION_CONTENT, {\n optional: true,\n });\n\n private readonly ref =\n this.content &&\n createComponent(this.content, {\n environmentInjector: inject(EnvironmentInjector),\n elementInjector: inject(INJECTOR),\n hostElement: tuiInjectElement(),\n });\n\n protected readonly dropdown = inject(TuiDropdownDirective, {\n self: true,\n optional: true,\n })?.ref;\n\n @Input()\n public disabled = false;\n\n constructor() {\n if (this.ref) {\n this.vcr.insert(this.ref.hostView);\n this.ref.changeDetectorRef.detectChanges();\n }\n }\n\n // Preventing focus loss upon focused option removal\n public ngOnDestroy(): void {\n this.dataList?.handleFocusLossIfNecessary(this.el);\n }\n\n protected onMouseMove(): void {\n if (\n !this.isMobile &&\n !tuiIsNativeFocused(this.el) &&\n this.dataList &&\n this.el.closest('[tuiDataListDropdownManager]')\n ) {\n this.el.focus({preventScroll: true});\n }\n }\n}\n\n// TODO(v5): remove [new] from selector\n@Directive({\n standalone: true,\n selector:\n 'button[tuiOption][value][new], a[tuiOption][value][new], label[tuiOption][value][new]',\n host: {\n '(click)': 'onClick()',\n },\n})\nexport class TuiOptionWithValue<T = unknown> {\n private readonly host = inject<TuiDataListHost<T>>(TUI_DATA_LIST_HOST, {\n optional: true,\n });\n\n @Input()\n public disabled = false;\n\n public readonly value = signal<T | undefined>(undefined);\n\n // TODO(v5): use `input.required<T>()` to remove `undefined` from `this.value()`\n @Input({alias: 'value', required: true})\n public set valueSetter(x: T) {\n this.value.set(x);\n }\n\n protected onClick(value = this.value()): void {\n if (this.host?.handleOption && value !== undefined) {\n this.host.handleOption(value);\n }\n }\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n forwardRef,\n inject,\n Input,\n type OnDestroy,\n type TemplateRef,\n} from '@angular/core';\nimport {TUI_IS_MOBILE} from '@taiga-ui/cdk/tokens';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsNativeFocused} from '@taiga-ui/cdk/utils/focus';\nimport {TuiDropdownDirective} from '@taiga-ui/core/directives/dropdown';\nimport {TuiWithIcons} from '@taiga-ui/core/directives/icons';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TuiDataListComponent} from '../data-list.component';\nimport {TUI_DATA_LIST_HOST, type TuiDataListHost} from '../data-list.tokens';\nimport {TUI_OPTION_CONTENT} from './option-content';\n\n/**\n * TODO(v5): delete\n * @deprecated use `<button tuiOption new />` / `<a tuiOption new /> / `<label tuiOption new /> instead\n */\n@Component({\n standalone: true,\n selector:\n 'button[tuiOption]:not([new]), a[tuiOption]:not([new]), label[tuiOption]:not([new])',\n imports: [PolymorpheusOutlet],\n template: `\n <ng-container *polymorpheusOutlet=\"content || t as text; context: {$implicit: t}\">\n {{ text }}\n </ng-container>\n <ng-template #t>\n <ng-content />\n </ng-template>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiWithIcons],\n host: {\n type: 'button',\n role: 'option',\n '[attr.disabled]': 'disabled || null',\n '[class._with-dropdown]': 'dropdown?.()',\n '(click)': 'onClick()',\n '(mousemove.zoneless)': 'onMouseMove()',\n },\n})\nexport class TuiOption<T = unknown> implements OnDestroy {\n private readonly isMobile = inject(TUI_IS_MOBILE);\n private readonly el = tuiInjectElement();\n private readonly dataList = inject<TuiDataListComponent<T>>(\n forwardRef(() => TuiDataListComponent),\n {optional: true},\n );\n\n private readonly host = inject<TuiDataListHost<T>>(TUI_DATA_LIST_HOST, {\n optional: true,\n });\n\n protected readonly content: PolymorpheusContent<\n TuiContext<TemplateRef<Record<string, unknown>>>\n > = inject(TUI_OPTION_CONTENT, {optional: true});\n\n protected readonly dropdown = inject(TuiDropdownDirective, {\n self: true,\n optional: true,\n })?.ref;\n\n @Input()\n public disabled = false;\n\n @Input()\n public value?: T;\n\n // Preventing focus loss upon focused option removal\n public ngOnDestroy(): void {\n this.dataList?.handleFocusLossIfNecessary(this.el);\n }\n\n protected onClick(): void {\n if (this.host?.handleOption && this.value !== undefined) {\n this.host.handleOption(this.value);\n }\n }\n\n protected onMouseMove(): void {\n if (\n !this.isMobile &&\n !tuiIsNativeFocused(this.el) &&\n this.dataList &&\n this.el.closest('[tuiDataListDropdownManager]')\n ) {\n this.el.focus({preventScroll: true});\n }\n }\n}\n","import {NgIf} from '@angular/common';\nimport {\n type AfterContentChecked,\n type AfterContentInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChildren,\n DestroyRef,\n forwardRef,\n inject,\n Input,\n isSignal,\n NgZone,\n type QueryList,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {EMPTY_QUERY} from '@taiga-ui/cdk/constants';\nimport {\n tuiQueryListChanges,\n tuiTakeUntilDestroyed,\n tuiZonefree,\n} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsNativeFocusedIn, tuiMoveFocus} from '@taiga-ui/cdk/utils/focus';\nimport {tuiIsPresent} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TUI_NOTHING_FOUND_MESSAGE} from '@taiga-ui/core/tokens';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport {combineLatest, map, ReplaySubject, startWith, switchMap, timer} from 'rxjs';\n\nimport {\n TUI_DATA_LIST_HOST,\n tuiAsDataListAccessor,\n type TuiDataListAccessor,\n} from './data-list.tokens';\nimport {TuiOptionWithValue} from './option/option.directive';\nimport {TUI_OPTION_CONTENT, TuiWithOptionContent} from './option/option-content';\nimport {TuiOption} from './option/option-legacy.component';\n\nexport function tuiInjectDataListSize(): TuiSizeL | TuiSizeS {\n const sizes = ['s', 'm', 'l'] as const;\n const size = inject(TUI_DATA_LIST_HOST, {optional: true})?.size;\n\n return size && sizes.includes(size) ? size : 'l';\n}\n\n// TODO: Consider aria-activedescendant for proper accessibility implementation\n@Component({\n standalone: true,\n selector: 'tui-data-list',\n imports: [NgIf, PolymorpheusOutlet],\n templateUrl: './data-list.template.html',\n styleUrls: ['./data-list.style.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiAsDataListAccessor(TuiDataListComponent),\n {\n provide: TUI_OPTION_CONTENT,\n useFactory: () =>\n inject(TuiWithOptionContent, {optional: true})?.content ??\n // TODO(v5): remove when all legacy controls are deleted\n inject(TUI_OPTION_CONTENT, {\n host: true,\n skipSelf: true,\n optional: true,\n }) ??\n inject(TUI_OPTION_CONTENT, {skipSelf: true, optional: true}),\n },\n ],\n host: {\n role: 'listbox',\n '[attr.data-size]': 'size',\n '(focusin)': 'onFocusIn($event.relatedTarget, $event.currentTarget)',\n '(mousedown.prevent)': '(0)',\n '(wheel.zoneless.passive)': 'handleFocusLossIfNecessary()',\n '(mouseleave)': 'handleFocusLossIfNecessary($event.target)',\n '(keydown.tab)': 'handleFocusLossIfNecessary()',\n '(keydown.shift.tab)': 'handleFocusLossIfNecessary()',\n '(keydown.arrowDown.prevent)': 'onKeyDownArrow($event.target, 1)',\n '(keydown.arrowUp.prevent)': 'onKeyDownArrow($event.target, -1)',\n },\n})\nexport class TuiDataListComponent<T>\n implements TuiDataListAccessor<T>, AfterContentChecked, AfterContentInit\n{\n // TODO(v5): delete\n @ContentChildren(forwardRef(() => TuiOption), {descendants: true})\n private readonly legacyOptionsQuery: QueryList<TuiOption<T>> = EMPTY_QUERY;\n\n @ContentChildren(forwardRef(() => TuiOptionWithValue), {descendants: true})\n private readonly optionsQuery: QueryList<TuiOptionWithValue<T>> = EMPTY_QUERY;\n\n private origin?: HTMLElement;\n private readonly ngZone = inject(NgZone);\n private readonly destroyRef = inject(DestroyRef);\n private readonly el = tuiInjectElement();\n private readonly cdr = inject(ChangeDetectorRef);\n private readonly contentReady$ = new ReplaySubject<boolean>(1);\n\n protected readonly fallback = toSignal(inject(TUI_NOTHING_FOUND_MESSAGE));\n protected readonly empty = signal(false);\n\n @Input()\n public emptyContent: PolymorpheusContent;\n\n @Input()\n public size = tuiInjectDataListSize();\n\n // TODO(v5): use signal `contentChildren`\n public readonly options = toSignal<readonly T[]>(\n this.contentReady$.pipe(\n switchMap(() =>\n combineLatest([\n tuiQueryListChanges(this.legacyOptionsQuery),\n tuiQueryListChanges(this.optionsQuery),\n ]),\n ),\n map(([legacyOptions, options]) =>\n [\n ...legacyOptions.map(({value}) => value),\n ...options.map(({value}) => value()),\n ].filter(tuiIsPresent),\n ),\n startWith([]),\n ),\n {requireSync: true},\n );\n\n public onKeyDownArrow(current: HTMLElement, step: number): void {\n const {elements} = this;\n\n tuiMoveFocus(elements.indexOf(current), elements, step);\n }\n\n public handleFocusLossIfNecessary(element: Element = this.el): void {\n if (tuiIsNativeFocusedIn(element)) {\n this.origin?.focus({preventScroll: true});\n }\n }\n\n public ngAfterContentInit(): void {\n this.contentReady$.next(true);\n }\n\n // TODO: Refactor to :has after Safari support bumped to 15\n public ngAfterContentChecked(): void {\n timer(0)\n .pipe(tuiZonefree(this.ngZone), tuiTakeUntilDestroyed(this.destroyRef))\n .subscribe(() => {\n this.empty.set(!this.elements.length);\n this.cdr.detectChanges();\n });\n }\n\n // TODO(v5): delete\n public getOptions(includeDisabled = false): readonly T[] {\n return [\n ...this.legacyOptionsQuery, // TODO(v5): delete\n ...this.optionsQuery,\n ]\n .filter(({disabled}) => includeDisabled || !disabled)\n .map(({value}) => (isSignal(value) ? value() : value))\n .filter(tuiIsPresent);\n }\n\n protected onFocusIn(relatedTarget: HTMLElement, currentTarget: HTMLElement): void {\n if (!currentTarget.contains(relatedTarget) && !this.origin) {\n this.origin = relatedTarget;\n }\n }\n\n private get elements(): readonly HTMLElement[] {\n return Array.from(this.el.querySelectorAll('[tuiOption]'));\n }\n}\n","<ng-content />\n<div\n *ngIf=\"empty()\"\n class=\"t-empty\"\n>\n <ng-container *polymorpheusOutlet=\"emptyContent || fallback() as text\">\n {{ text }}\n </ng-container>\n</div>\n","import {Directive, type Provider, type Type} from '@angular/core';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiDataList]',\n})\nexport class TuiDataListDirective {}\n\nexport function tuiAsDataList(list: Type<TuiDataListDirective>): Provider {\n return tuiProvide(TuiDataListDirective, list);\n}\n","import {Directive, Input} from '@angular/core';\n\n@Directive({\n standalone: true,\n selector: 'tui-opt-group',\n host: {\n role: 'group',\n '[attr.data-label]': 'label',\n },\n})\nexport class TuiOptGroup {\n @Input()\n public label?: string | null;\n}\n","import {TuiDataListComponent} from './data-list.component';\nimport {TuiDataListDirective} from './data-list.directive';\nimport {TuiOptGroup} from './opt-group.directive';\nimport {TuiOptionNew, TuiOptionWithValue} from './option/option.directive';\nimport {TuiOption} from './option/option-legacy.component';\n\nexport const TuiDataList = [\n TuiDataListComponent,\n TuiDataListDirective,\n TuiOption,\n TuiOptionNew,\n TuiOptionWithValue,\n TuiOptGroup,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AA4BA;;AAEG;AACU,MAAA,sBAAsB,GAAG,IAAI,cAAc,CACpD,SAAS,GAAG,wBAAwB,GAAG,EAAE,EAC3C;AAEI,SAAU,qBAAqB,CAAC,QAAmC,EAAA;AACrE,IAAA,OAAO,CAAC,UAAU,CAAC,sBAAsB,EAAE,QAAQ,CAAC,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAC,CAAC;AACpF,CAAC;AAED;;AAEG;AACU,MAAA,kBAAkB,GAAG,IAAI,cAAc,CAChD,SAAS,GAAG,oBAAoB,GAAG,EAAE,EACvC;AAEI,SAAU,iBAAiB,CAAI,IAA8B,EAA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;8BAGU,KAAK,EAAA,CAAA;sBADX,KAAK;;;ACLG,MAAA,WAAW,GAAG;IACvB,oBAAoB;IACpB,oBAAoB;IACpB,SAAS;IACT,YAAY;IACZ,kBAAkB;IAClB,WAAW;;;ACZf;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-data-list.mjs","sources":["../../../projects/core/components/data-list/data-list.tokens.ts","../../../projects/core/components/data-list/option-content.directive.ts","../../../projects/core/components/data-list/option-with-value.directive.ts","../../../projects/core/components/data-list/data-list.component.ts","../../../projects/core/components/data-list/data-list.template.html","../../../projects/core/components/data-list/opt-group.directive.ts","../../../projects/core/components/data-list/option.directive.ts","../../../projects/core/components/data-list/data-list.ts","../../../projects/core/components/data-list/taiga-ui-core-components-data-list.ts"],"sourcesContent":["import {InjectionToken, type Provider, type Signal, type Type} from '@angular/core';\nimport {tuiProvide} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiDataListAccessor<T = unknown> {\n options: Signal<readonly T[]>;\n}\n\nexport interface TuiDataListHost<T> {\n handleOption?(option: T): void;\n readonly size?: TuiSizeL | TuiSizeS;\n}\n\nexport const TUI_DATA_LIST_HOST = new InjectionToken<TuiDataListHost<unknown>>(\n ngDevMode ? 'TUI_DATA_LIST_HOST' : '',\n);\n\nexport function tuiAsDataListHost<T>(host: Type<TuiDataListHost<T>>): Provider {\n return tuiProvide(TUI_DATA_LIST_HOST, host);\n}\n","import {\n ContentChild,\n Directive,\n inject,\n InjectionToken,\n type Provider,\n type Type,\n} from '@angular/core';\n\n/**\n * Content for tuiOption component\n */\nexport const TUI_OPTION_CONTENT = new InjectionToken<Type<any>>(\n ngDevMode ? 'TUI_OPTION_CONTENT' : '',\n);\n\nexport function tuiAsOptionContent(useValue: Type<any>): Provider {\n return {provide: TUI_OPTION_CONTENT, useValue};\n}\n\n@Directive()\nexport class TuiWithOptionContent {\n @ContentChild(TUI_OPTION_CONTENT, {descendants: true})\n protected readonly local: Type<any> | null = null;\n\n protected readonly global = inject<Type<any>>(TUI_OPTION_CONTENT, {optional: true});\n\n public get content(): Type<any> | null {\n return this.global ?? this.local;\n }\n}\n","import {Directive, inject, input} from '@angular/core';\n\nimport {TUI_DATA_LIST_HOST} from './data-list.tokens';\n\n@Directive({\n selector: 'button[tuiOption][value], a[tuiOption][value], label[tuiOption][value]',\n host: {'(click)': 'onClick()'},\n})\nexport class TuiOptionWithValue<T = unknown> {\n private readonly host = inject(TUI_DATA_LIST_HOST, {optional: true});\n\n public readonly disabled = input(false);\n public readonly value = input<T>();\n\n protected onClick(value = this.value()): void {\n if (value !== undefined) {\n this.host?.handleOption?.(value);\n }\n }\n}\n","import {\n type AfterContentChecked,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n computed,\n contentChildren,\n DestroyRef,\n forwardRef,\n inject,\n input,\n NgZone,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiTakeUntilDestroyed, tuiZonefree} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocusedIn, tuiMoveFocus} from '@taiga-ui/cdk/utils/focus';\nimport {tuiIsPresent} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiCell, tuiCellOptionsProvider} from '@taiga-ui/core/components/cell';\nimport {TUI_NOTHING_FOUND_MESSAGE, tuiAsAuxiliary} from '@taiga-ui/core/tokens';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\nimport {timer} from 'rxjs';\n\nimport {TUI_DATA_LIST_HOST, type TuiDataListAccessor} from './data-list.tokens';\nimport {TUI_OPTION_CONTENT, TuiWithOptionContent} from './option-content.directive';\nimport {TuiOptionWithValue} from './option-with-value.directive';\n\nexport function tuiInjectDataListSize(): TuiSizeL | TuiSizeS {\n const sizes = ['s', 'm', 'l'] as const;\n const size = inject(TUI_DATA_LIST_HOST, {optional: true})?.size;\n\n return size && sizes.includes(size) ? size : 'l';\n}\n\n// TODO: Consider aria-activedescendant for proper accessibility implementation\n@Component({\n selector: 'tui-data-list',\n imports: [PolymorpheusOutlet, TuiCell],\n templateUrl: './data-list.template.html',\n styleUrl: './data-list.style.less',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiCellOptionsProvider(() => ({size: inject(TuiDataListComponent).size()})),\n tuiAsAuxiliary(TuiDataListComponent),\n {\n provide: TUI_OPTION_CONTENT,\n useFactory: () =>\n inject(TuiWithOptionContent, {optional: true})?.content ??\n inject(TUI_OPTION_CONTENT, {skipSelf: true, optional: true}),\n },\n ],\n host: {\n role: 'listbox',\n '[attr.data-size]': 'size()',\n '(focusin)': 'onFocusIn($event.relatedTarget, $event.currentTarget)',\n '(mousedown.prevent)': '(0)',\n '(wheel.zoneless.passive)': 'handleFocusLossIfNecessary()',\n '(mouseleave)': 'handleFocusLossIfNecessary($event.target)',\n '(keydown.tab)': 'handleFocusLossIfNecessary()',\n '(keydown.shift.tab)': 'handleFocusLossIfNecessary()',\n '(keydown.arrowDown.prevent)': 'onKeyDownArrow($event.target, 1)',\n '(keydown.arrowUp.prevent)': 'onKeyDownArrow($event.target, -1)',\n },\n})\nexport class TuiDataListComponent<T>\n implements TuiDataListAccessor<T>, AfterContentChecked\n{\n private origin?: HTMLElement;\n private readonly ngZone = inject(NgZone);\n private readonly destroyRef = inject(DestroyRef);\n private readonly el = tuiInjectElement();\n private readonly cdr = inject(ChangeDetectorRef);\n private readonly optionsQuery = contentChildren<TuiOptionWithValue<T>>(\n forwardRef(() => TuiOptionWithValue),\n {descendants: true},\n );\n\n protected readonly fallback = inject(TUI_NOTHING_FOUND_MESSAGE);\n protected readonly empty = signal(false);\n\n public readonly emptyContent = input<PolymorpheusContent>();\n public readonly size = input(tuiInjectDataListSize());\n\n public readonly options = computed(() =>\n this.optionsQuery()\n .map(({value}) => value())\n .filter(tuiIsPresent),\n );\n\n public onKeyDownArrow(current: HTMLElement, step: number): void {\n const {elements} = this;\n\n tuiMoveFocus(elements.indexOf(current), elements, step);\n }\n\n public handleFocusLossIfNecessary(element: Element = this.el): void {\n if (tuiIsFocusedIn(element)) {\n this.origin?.focus({preventScroll: true});\n }\n }\n\n // TODO: Refactor to :has after Safari support bumped to 15\n public ngAfterContentChecked(): void {\n timer(0)\n .pipe(tuiZonefree(this.ngZone), tuiTakeUntilDestroyed(this.destroyRef))\n .subscribe(() => {\n this.empty.set(!this.elements.length);\n this.cdr.detectChanges();\n });\n }\n\n protected onFocusIn(relatedTarget: HTMLElement, currentTarget: HTMLElement): void {\n if (!currentTarget.contains(relatedTarget) && !this.origin) {\n this.origin = relatedTarget;\n }\n }\n\n private get elements(): readonly HTMLElement[] {\n return Array.from(this.el.querySelectorAll('[tuiOption]:not(.t-empty)'));\n }\n}\n","<ng-content />\n@if (empty()) {\n <!-- tuiOption selector purely for cosmetics, do not import -->\n <span\n tuiCell\n tuiOption\n class=\"t-empty\"\n >\n <ng-container *polymorpheusOutlet=\"emptyContent() || fallback() as text\">\n {{ text }}\n </ng-container>\n </span>\n}\n","import {Directive, input} from '@angular/core';\n\n@Directive({\n selector: 'tui-opt-group',\n host: {\n role: 'group',\n '[attr.data-label]': 'label() || \"\"',\n },\n})\nexport class TuiOptGroup {\n public readonly label = input<string | null>();\n}\n","import {\n createComponent,\n Directive,\n EnvironmentInjector,\n forwardRef,\n inject,\n INJECTOR,\n input,\n type OnDestroy,\n type Type,\n ViewContainerRef,\n} from '@angular/core';\nimport {WA_IS_MOBILE} from '@ng-web-apis/platform';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocused} from '@taiga-ui/cdk/utils/focus';\nimport {TuiCell} from '@taiga-ui/core/components/cell';\nimport {TuiWithIcons} from '@taiga-ui/core/directives/icons';\nimport {TuiDropdownDirective} from '@taiga-ui/core/portals/dropdown';\n\nimport {TuiDataListComponent} from './data-list.component';\nimport {TUI_OPTION_CONTENT} from './option-content.directive';\n\n@Directive({\n selector: 'button[tuiOption], a[tuiOption], label[tuiOption]',\n hostDirectives: [TuiWithIcons, TuiCell],\n host: {\n type: 'button',\n role: 'option',\n '[attr.disabled]': 'disabled() || null',\n '[class._with-dropdown]': 'dropdown?.()',\n '(mousemove.zoneless)': 'onMouseMove()',\n },\n})\nexport class TuiOption<T = unknown> implements OnDestroy {\n private readonly vcr = inject(ViewContainerRef);\n private readonly isMobile = inject(WA_IS_MOBILE);\n private readonly el = tuiInjectElement();\n private readonly datalist = inject<TuiDataListComponent<T>>(\n forwardRef(() => TuiDataListComponent),\n {optional: true},\n );\n\n private readonly content = inject<Type<any> | null>(TUI_OPTION_CONTENT, {\n optional: true,\n });\n\n private readonly ref =\n this.content &&\n createComponent(this.content, {\n environmentInjector: inject(EnvironmentInjector),\n elementInjector: inject(INJECTOR),\n hostElement: tuiInjectElement(),\n });\n\n protected readonly dropdown = inject(TuiDropdownDirective, {\n self: true,\n optional: true,\n })?.ref;\n\n public readonly disabled = input(false);\n\n constructor() {\n if (this.ref) {\n this.vcr.insert(this.ref.hostView);\n this.ref.changeDetectorRef.detectChanges();\n }\n }\n\n // Preventing focus loss upon focused option removal\n public ngOnDestroy(): void {\n this.datalist?.handleFocusLossIfNecessary(this.el);\n }\n\n protected onMouseMove(): void {\n if (\n !this.isMobile &&\n !tuiIsFocused(this.el) &&\n this.datalist &&\n this.el.closest('[tuiDataListDropdownManager]')\n ) {\n this.el.focus({preventScroll: true});\n }\n }\n}\n","import {TuiDataListComponent} from './data-list.component';\nimport {TuiOptGroup} from './opt-group.directive';\nimport {TuiOption} from './option.directive';\nimport {TuiOptionWithValue} from './option-with-value.directive';\n\nexport const TuiDataList = [\n TuiDataListComponent,\n TuiOption,\n TuiOptionWithValue,\n TuiOptGroup,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;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AW,GAAG;IACvB,oBAAoB;IACpB,SAAS;IACT,kBAAkB;IAClB,WAAW;;;ACTf;;AAEG;;;;"}
|
|
@@ -1,40 +1,124 @@
|
|
|
1
|
-
import { NgIf } from '@angular/common';
|
|
2
1
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { inject,
|
|
4
|
-
import { toSignal } from '@angular/core/rxjs-interop';
|
|
2
|
+
import { inject, computed, input, ChangeDetectionStrategy, Component, isSignal, Directive, TemplateRef, untracked, Pipe } from '@angular/core';
|
|
5
3
|
import { TuiValidationError } from '@taiga-ui/cdk/classes';
|
|
6
4
|
import { TuiAnimated } from '@taiga-ui/cdk/directives/animated';
|
|
7
|
-
import { tuiIsString } from '@taiga-ui/cdk/utils/miscellaneous';
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
5
|
+
import { tuiIsString, tuiSetSignal } from '@taiga-ui/cdk/utils/miscellaneous';
|
|
6
|
+
import { TUI_DEFAULT_ERROR_MESSAGE, TUI_VALIDATION_ERRORS } from '@taiga-ui/core/tokens';
|
|
7
|
+
import { PolymorpheusOutlet, PolymorpheusTemplate, PolymorpheusComponent } from '@taiga-ui/polymorpheus';
|
|
8
|
+
import { toSignal } from '@angular/core/rxjs-interop';
|
|
9
|
+
import { NG_VALUE_ACCESSOR, NG_VALIDATORS, NgControl } from '@angular/forms';
|
|
10
|
+
import { tuiDirectiveBinding, tuiProvide } from '@taiga-ui/cdk/utils/di';
|
|
11
|
+
import { Subject, distinctUntilChanged, switchMap, startWith, map } from 'rxjs';
|
|
11
12
|
|
|
12
|
-
class
|
|
13
|
+
class TuiErrorComponent {
|
|
13
14
|
constructor() {
|
|
14
|
-
this.
|
|
15
|
-
this.error =
|
|
16
|
-
this.
|
|
17
|
-
this.default = toSignal(inject(TUI_DEFAULT_ERROR_MESSAGE));
|
|
18
|
-
}
|
|
19
|
-
set errorSetter(error) {
|
|
20
|
-
this.error = tuiIsString(error) ? new TuiValidationError(error) : error;
|
|
15
|
+
this.default = inject(TUI_DEFAULT_ERROR_MESSAGE);
|
|
16
|
+
this.content = computed((error = this.error()) => tuiIsString(error) ? new TuiValidationError(error) : error);
|
|
17
|
+
this.error = input(null);
|
|
21
18
|
}
|
|
22
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
23
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
19
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
20
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiErrorComponent, isStandalone: true, selector: "tui-error", inputs: { error: { classPropertyName: "error", publicName: "error", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class._error": "content()" } }, ngImport: i0, template: "@if (content(); as error) {\n <span\n tuiAnimated\n class=\"t-message-text\"\n >\n <span\n *polymorpheusOutlet=\"error.message || default() as text; context: error.context || {}\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n}\n", styles: [":host{transition-property:grid-template-rows;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:grid;font:var(--tui-font-body-s);color:var(--tui-text-negative);overflow-wrap:break-word;grid-template-rows:0fr}:host._error{grid-template-rows:1fr}.t-message-text{white-space:pre-line;grid-area:1 / 1 / span 2;overflow:hidden}.t-message-text.tui-enter,.t-message-text.tui-leave{animation-name:tuiFade}.t-message-text:before{content:\"\";line-height:1.5rem;vertical-align:bottom}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiAnimated, selector: "[tuiAnimated]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
24
21
|
}
|
|
25
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
22
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorComponent, decorators: [{
|
|
26
23
|
type: Component,
|
|
27
|
-
args: [{
|
|
28
|
-
'[class._error]': '
|
|
29
|
-
}, template: "
|
|
30
|
-
}]
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
args: [{ selector: 'tui-error', imports: [PolymorpheusOutlet, TuiAnimated], changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
25
|
+
'[class._error]': 'content()',
|
|
26
|
+
}, template: "@if (content(); as error) {\n <span\n tuiAnimated\n class=\"t-message-text\"\n >\n <span\n *polymorpheusOutlet=\"error.message || default() as text; context: error.context || {}\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n}\n", styles: [":host{transition-property:grid-template-rows;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:grid;font:var(--tui-font-body-s);color:var(--tui-text-negative);overflow-wrap:break-word;grid-template-rows:0fr}:host._error{grid-template-rows:1fr}.t-message-text{white-space:pre-line;grid-area:1 / 1 / span 2;overflow:hidden}.t-message-text.tui-enter,.t-message-text.tui-leave{animation-name:tuiFade}.t-message-text:before{content:\"\";line-height:1.5rem;vertical-align:bottom}\n"] }]
|
|
27
|
+
}] });
|
|
28
|
+
|
|
29
|
+
class TuiErrorDirective {
|
|
30
|
+
constructor() {
|
|
31
|
+
this.content = inject(TUI_VALIDATION_ERRORS);
|
|
32
|
+
this.control = new Subject();
|
|
33
|
+
this.errors = toSignal(this.control.pipe(distinctUntilChanged(), switchMap((control) => control.events.pipe(startWith(null), map(() => control.invalid && control.touched && control.errors)))));
|
|
34
|
+
this.key = computed((errors = this.errors() || {}) => this.order().find((id) => errors[id]) || Object.keys(errors)[0] || '');
|
|
35
|
+
this.order = input([]);
|
|
36
|
+
this.error = tuiDirectiveBinding(TuiErrorComponent, 'error', computed((errors = this.errors() || null) => errors && this.getError(errors[this.key()], this.content[this.key()])), { self: true, optional: true });
|
|
37
|
+
}
|
|
38
|
+
registerOnChange() { }
|
|
39
|
+
registerOnTouched() { }
|
|
40
|
+
writeValue() { }
|
|
41
|
+
validate(control) {
|
|
42
|
+
this.control.next(control);
|
|
43
|
+
return null;
|
|
44
|
+
}
|
|
45
|
+
getError(context, content) {
|
|
46
|
+
context = isSignal(context) ? context() : context;
|
|
47
|
+
if (context instanceof TuiValidationError) {
|
|
48
|
+
return context;
|
|
49
|
+
}
|
|
50
|
+
if (content === undefined && isContent(context)) {
|
|
51
|
+
return getError(context);
|
|
52
|
+
}
|
|
53
|
+
if (isSignal(content)) {
|
|
54
|
+
return getError(content(), context);
|
|
55
|
+
}
|
|
56
|
+
if (content instanceof Function) {
|
|
57
|
+
const message = content(context);
|
|
58
|
+
return getError(isSignal(message) ? message() : message, context);
|
|
59
|
+
}
|
|
60
|
+
return getError(content, context);
|
|
61
|
+
}
|
|
62
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
63
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.2.17", type: TuiErrorDirective, isStandalone: true, selector: "tui-error[ngModel], tui-error[formControlName], tui-error[formControl], tui-error[formGroup], tui-error[formGroupName], tui-error[formArrayName]", inputs: { order: { classPropertyName: "order", publicName: "order", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
|
|
64
|
+
tuiProvide(NG_VALUE_ACCESSOR, TuiErrorDirective, true),
|
|
65
|
+
tuiProvide(NG_VALIDATORS, TuiErrorDirective, true),
|
|
66
|
+
], ngImport: i0 }); }
|
|
67
|
+
}
|
|
68
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorDirective, decorators: [{
|
|
69
|
+
type: Directive,
|
|
70
|
+
args: [{
|
|
71
|
+
selector: 'tui-error[ngModel], tui-error[formControlName], tui-error[formControl], tui-error[formGroup], tui-error[formGroupName], tui-error[formArrayName]',
|
|
72
|
+
providers: [
|
|
73
|
+
tuiProvide(NG_VALUE_ACCESSOR, TuiErrorDirective, true),
|
|
74
|
+
tuiProvide(NG_VALIDATORS, TuiErrorDirective, true),
|
|
75
|
+
],
|
|
76
|
+
}]
|
|
77
|
+
}] });
|
|
78
|
+
function getError(content = '', context) {
|
|
79
|
+
return new TuiValidationError(content, context);
|
|
80
|
+
}
|
|
81
|
+
function isContent(value) {
|
|
82
|
+
return (tuiIsString(value) ||
|
|
83
|
+
value instanceof TemplateRef ||
|
|
84
|
+
value instanceof PolymorpheusTemplate ||
|
|
85
|
+
value instanceof PolymorpheusComponent);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
class TuiErrorPipe {
|
|
89
|
+
constructor() {
|
|
90
|
+
this.control = inject(NgControl);
|
|
91
|
+
this.directive = new TuiErrorDirective();
|
|
92
|
+
}
|
|
93
|
+
transform(order) {
|
|
94
|
+
untracked(() => {
|
|
95
|
+
this.directive.validate(this.control.control);
|
|
96
|
+
tuiSetSignal(this.directive.order, order);
|
|
97
|
+
});
|
|
98
|
+
const error = this.directive.error();
|
|
99
|
+
if (!error) {
|
|
100
|
+
return '';
|
|
101
|
+
}
|
|
102
|
+
return typeof error.message === 'function'
|
|
103
|
+
? error.message(error.context)
|
|
104
|
+
: error.message;
|
|
105
|
+
}
|
|
106
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
107
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorPipe, isStandalone: true, name: "tuiError", pure: false }); }
|
|
108
|
+
}
|
|
109
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiErrorPipe, decorators: [{
|
|
110
|
+
type: Pipe,
|
|
111
|
+
args: [{
|
|
112
|
+
name: 'tuiError',
|
|
113
|
+
pure: false,
|
|
114
|
+
}]
|
|
115
|
+
}] });
|
|
116
|
+
|
|
117
|
+
const TuiError = [TuiErrorComponent, TuiErrorDirective, TuiErrorPipe];
|
|
34
118
|
|
|
35
119
|
/**
|
|
36
120
|
* Generated bundle index. Do not edit.
|
|
37
121
|
*/
|
|
38
122
|
|
|
39
|
-
export { TuiError };
|
|
123
|
+
export { TuiError, TuiErrorComponent, TuiErrorDirective, TuiErrorPipe };
|
|
40
124
|
//# sourceMappingURL=taiga-ui-core-components-error.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-error.mjs","sources":["../../../projects/core/components/error/error.component.ts","../../../projects/core/components/error/error.template.html","../../../projects/core/components/error/taiga-ui-core-components-error.ts"],"sourcesContent":["import {NgIf} from '@angular/common';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {TuiValidationError} from '@taiga-ui/cdk/classes';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TUI_ANIMATIONS_SPEED, TUI_DEFAULT_ERROR_MESSAGE} from '@taiga-ui/core/tokens';\nimport {tuiToAnimationOptions} from '@taiga-ui/core/utils';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n standalone: true,\n selector: 'tui-error',\n imports: [NgIf, PolymorpheusOutlet, TuiAnimated],\n templateUrl: './error.template.html',\n styleUrls: ['./error.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class._error]': 'error',\n },\n})\nexport class TuiError {\n protected readonly options = tuiToAnimationOptions(inject(TUI_ANIMATIONS_SPEED));\n protected error: TuiValidationError | null = null;\n protected visible = true;\n protected readonly default = toSignal(inject(TUI_DEFAULT_ERROR_MESSAGE));\n\n @Input('error')\n public set errorSetter(error: TuiValidationError | string | null) {\n this.error = tuiIsString(error) ? new TuiValidationError(error) : error;\n }\n}\n","<div\n *ngIf=\"error\"\n automation-id=\"tui-error__text\"\n tuiAnimated\n class=\"t-message-text\"\n>\n <ng-container *polymorpheusOutlet=\"error.message || default() as text; context: error.context || {}\">\n {{ text }}\n </ng-container>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAUA,MAWa,QAAQ,CAAA;AAXrB,IAAA,WAAA,GAAA;QAYuB,IAAO,CAAA,OAAA,GAAG,qBAAqB,CAAC,MAAM,CAAC,oBAAoB,CAAC,CAAC,CAAC;QACvE,IAAK,CAAA,KAAA,GAA8B,IAAI,CAAC;QACxC,IAAO,CAAA,OAAA,GAAG,IAAI,CAAC;QACN,IAAO,CAAA,OAAA,GAAG,QAAQ,CAAC,MAAM,CAAC,yBAAyB,CAAC,CAAC,CAAC;AAM5E,KAAA;IAJG,IACW,WAAW,CAAC,KAAyC,EAAA;AAC5D,QAAA,IAAI,CAAC,KAAK,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,IAAI,kBAAkB,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC;KAC3E;+GATQ,QAAQ,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;AAAR,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,QAAQ,2KCrBrB,oRAUA,EAAA,MAAA,EAAA,CAAA,kgBAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EDGc,IAAI,EAAE,QAAA,EAAA,QAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,UAAA,EAAA,UAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,kBAAkB,8HAAE,WAAW,EAAA,QAAA,EAAA,eAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA,EAAA;;4FAQtC,QAAQ,EAAA,UAAA,EAAA,CAAA;kBAXpB,SAAS;AACM,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA,IAAI,EACN,QAAA,EAAA,WAAW,EACZ,OAAA,EAAA,CAAC,IAAI,EAAE,kBAAkB,EAAE,WAAW,CAAC,EAAA,eAAA,EAG/B,uBAAuB,CAAC,MAAM,EACzC,IAAA,EAAA;AACF,wBAAA,gBAAgB,EAAE,OAAO;AAC5B,qBAAA,EAAA,QAAA,EAAA,oRAAA,EAAA,MAAA,EAAA,CAAA,kgBAAA,CAAA,EAAA,CAAA;8BASU,WAAW,EAAA,CAAA;sBADrB,KAAK;uBAAC,OAAO,CAAA;;;AE3BlB;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-error.mjs","sources":["../../../projects/core/components/error/error.component.ts","../../../projects/core/components/error/error.template.html","../../../projects/core/components/error/error.directive.ts","../../../projects/core/components/error/error.pipe.ts","../../../projects/core/components/error/error.ts","../../../projects/core/components/error/taiga-ui-core-components-error.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, computed, inject, input} from '@angular/core';\nimport {TuiValidationError} from '@taiga-ui/cdk/classes';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TUI_DEFAULT_ERROR_MESSAGE} from '@taiga-ui/core/tokens';\nimport {PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\n@Component({\n selector: 'tui-error',\n imports: [PolymorpheusOutlet, TuiAnimated],\n templateUrl: './error.template.html',\n styleUrl: './error.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class._error]': 'content()',\n },\n})\nexport class TuiErrorComponent {\n protected readonly default = inject(TUI_DEFAULT_ERROR_MESSAGE);\n protected readonly content = computed((error = this.error()) =>\n tuiIsString(error) ? new TuiValidationError(error) : error,\n );\n\n public readonly error = input<TuiValidationError | string | null>(null);\n}\n","@if (content(); as error) {\n <span\n tuiAnimated\n class=\"t-message-text\"\n >\n <span\n *polymorpheusOutlet=\"error.message || default() as text; context: error.context || {}\"\n [innerHTML]=\"text\"\n ></span>\n </span>\n}\n","import {\n computed,\n Directive,\n inject,\n input,\n isSignal,\n type Signal,\n TemplateRef,\n} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {\n type AbstractControl,\n type ControlValueAccessor,\n NG_VALIDATORS,\n NG_VALUE_ACCESSOR,\n type ValidationErrors,\n type Validator,\n} from '@angular/forms';\nimport {TuiValidationError} from '@taiga-ui/cdk/classes';\nimport {tuiDirectiveBinding, tuiProvide} from '@taiga-ui/cdk/utils/di';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TUI_VALIDATION_ERRORS} from '@taiga-ui/core/tokens';\nimport {\n PolymorpheusComponent,\n type PolymorpheusContent,\n PolymorpheusTemplate,\n} from '@taiga-ui/polymorpheus';\nimport {distinctUntilChanged, map, startWith, Subject, switchMap} from 'rxjs';\n\nimport {TuiErrorComponent} from './error.component';\n\n@Directive({\n selector:\n 'tui-error[ngModel], tui-error[formControlName], tui-error[formControl], tui-error[formGroup], tui-error[formGroupName], tui-error[formArrayName]',\n providers: [\n tuiProvide(NG_VALUE_ACCESSOR, TuiErrorDirective, true),\n tuiProvide(NG_VALIDATORS, TuiErrorDirective, true),\n ],\n})\nexport class TuiErrorDirective implements ControlValueAccessor, Validator {\n private readonly content = inject(TUI_VALIDATION_ERRORS);\n private readonly control = new Subject<AbstractControl>();\n\n private readonly errors = toSignal(\n this.control.pipe(\n distinctUntilChanged(),\n switchMap((control) =>\n control.events.pipe(\n startWith(null),\n map(() => control.invalid && control.touched && control.errors),\n ),\n ),\n ),\n );\n\n private readonly key = computed(\n (errors = this.errors() || {}) =>\n this.order().find((id) => errors[id]) || Object.keys(errors)[0] || '',\n );\n\n public readonly order = input<readonly string[]>([]);\n public readonly error = tuiDirectiveBinding(\n TuiErrorComponent,\n 'error',\n computed(\n (errors = this.errors() || null) =>\n errors && this.getError(errors[this.key()], this.content[this.key()]),\n ),\n {self: true, optional: true},\n );\n\n public registerOnChange(): void {}\n public registerOnTouched(): void {}\n public writeValue(): void {}\n public validate(control: AbstractControl): ValidationErrors | null {\n this.control.next(control);\n\n return null;\n }\n\n private getError(\n context: unknown,\n content?: PolymorpheusContent | Signal<PolymorpheusContent>,\n ): TuiValidationError {\n context = isSignal(context) ? context() : context;\n\n if (context instanceof TuiValidationError) {\n return context;\n }\n\n if (content === undefined && isContent(context)) {\n return getError(context);\n }\n\n if (isSignal(content)) {\n return getError(content(), context);\n }\n\n if (content instanceof Function) {\n const message = content(context);\n\n return getError(isSignal(message) ? message() : message, context);\n }\n\n return getError(content, context);\n }\n}\n\nfunction getError(content: unknown = '', context?: any): TuiValidationError {\n return new TuiValidationError(content as PolymorpheusContent, context);\n}\n\nfunction isContent(value: unknown): value is PolymorpheusContent {\n return (\n tuiIsString(value) ||\n value instanceof TemplateRef ||\n value instanceof PolymorpheusTemplate ||\n value instanceof PolymorpheusComponent\n );\n}\n","import {inject, Pipe, type PipeTransform, untracked} from '@angular/core';\nimport {NgControl} from '@angular/forms';\nimport {tuiSetSignal} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {type PolymorpheusContent} from '@taiga-ui/polymorpheus';\n\nimport {TuiErrorDirective} from './error.directive';\n\n@Pipe({\n name: 'tuiError',\n pure: false,\n})\nexport class TuiErrorPipe implements PipeTransform {\n private readonly control = inject(NgControl);\n private readonly directive = new TuiErrorDirective();\n\n public transform(order: readonly string[]): PolymorpheusContent {\n untracked(() => {\n this.directive.validate(this.control.control!);\n tuiSetSignal(this.directive.order, order);\n });\n\n const error = this.directive.error();\n\n if (!error) {\n return '';\n }\n\n return typeof error.message === 'function'\n ? error.message(error.context)\n : error.message;\n }\n}\n","import {TuiErrorComponent} from './error.component';\nimport {TuiErrorDirective} from './error.directive';\nimport {TuiErrorPipe} from './error.pipe';\n\nexport const TuiError = [TuiErrorComponent, TuiErrorDirective, TuiErrorPipe] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;MAiBa,iBAAiB,CAAA;AAV9B,IAAA,WAAA,GAAA;AAWuB,QAAA,IAAA,CAAA,OAAO,GAAG,MAAM,CAAC,yBAAyB,CAAC;AAC3C,QAAA,IAAA,CAAA,OAAO,GAAG,QAAQ,CAAC,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,EAAE,KACvD,WAAW,CAAC,KAAK,CAAC,GAAG,IAAI,kBAAkB,CAAC,KAAK,CAAC,GAAG,KAAK,CAC7D;AAEe,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK,CAAqC,IAAI,CAAC;AAC1E;+GAPY,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAjB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,iBAAiB,ECjB9B,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,WAAA,EAAA,MAAA,EAAA,EAAA,KAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,UAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EA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,oBAAA,IAAI,EAAE,KAAK;AACd,iBAAA;;;ACNY,MAAA,QAAQ,GAAG,CAAC,iBAAiB,EAAE,iBAAiB,EAAE,YAAY;;ACJ3E;;AAEG;;;;"}
|
|
@@ -1,149 +1,51 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { NgTemplateOutlet } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { tuiParentAnimation } from '@taiga-ui/core/animations';
|
|
6
|
-
import { TuiLoader } from '@taiga-ui/core/components/loader';
|
|
7
|
-
import { timer } from 'rxjs';
|
|
3
|
+
import { contentChild, TemplateRef, signal, input, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
4
|
+
import { TuiItem } from '@taiga-ui/cdk/directives/item';
|
|
8
5
|
|
|
9
|
-
|
|
10
|
-
* @deprecated use {@link TuiExpand} from @taiga-ui/experimental
|
|
11
|
-
*/
|
|
12
|
-
class TuiExpandContent {
|
|
13
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiExpandContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
14
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: TuiExpandContent, isStandalone: true, selector: "[tuiExpandContent]", ngImport: i0 }); }
|
|
15
|
-
}
|
|
16
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiExpandContent, decorators: [{
|
|
17
|
-
type: Directive,
|
|
18
|
-
args: [{
|
|
19
|
-
standalone: true,
|
|
20
|
-
selector: '[tuiExpandContent]',
|
|
21
|
-
}]
|
|
22
|
-
}] });
|
|
23
|
-
|
|
24
|
-
const State = {
|
|
25
|
-
Idle: 0,
|
|
26
|
-
Loading: 1,
|
|
27
|
-
Prepared: 2,
|
|
28
|
-
Animated: 3,
|
|
29
|
-
};
|
|
30
|
-
const LOADER_HEIGHT = 48;
|
|
31
|
-
/**
|
|
32
|
-
* An event indicating that async data for expand has finished loading.
|
|
33
|
-
* Dispatch to finish loading states for {@link TuiExpandComponent}.
|
|
34
|
-
*/
|
|
35
|
-
const TUI_EXPAND_LOADED = 'tui-expand-loaded';
|
|
36
|
-
/**
|
|
37
|
-
* @deprecated use {@link TuiExpand} from @taiga-ui/experimental
|
|
38
|
-
*/
|
|
39
|
-
class TuiExpandComponent {
|
|
6
|
+
class TuiExpand {
|
|
40
7
|
constructor() {
|
|
41
|
-
this.
|
|
42
|
-
this.
|
|
43
|
-
this.
|
|
44
|
-
this.content = null;
|
|
45
|
-
this.expanded = null;
|
|
46
|
-
this.async = false;
|
|
47
|
-
}
|
|
48
|
-
set expandedSetter(expanded) {
|
|
49
|
-
if (this.expanded === null) {
|
|
50
|
-
this.expanded = expanded;
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
if (this.state !== State.Idle) {
|
|
54
|
-
this.expanded = expanded;
|
|
55
|
-
this.state = State.Animated;
|
|
56
|
-
return;
|
|
57
|
-
}
|
|
58
|
-
this.expanded = expanded;
|
|
59
|
-
this.retrigger(this.async && expanded ? State.Loading : State.Animated);
|
|
60
|
-
}
|
|
61
|
-
get contentVisible() {
|
|
62
|
-
return this.expanded || this.state !== State.Idle;
|
|
8
|
+
this.content = contentChild(TuiItem, { read: TemplateRef });
|
|
9
|
+
this.open = signal(false);
|
|
10
|
+
this.expanded = input(false);
|
|
63
11
|
}
|
|
64
|
-
|
|
65
|
-
|
|
12
|
+
ngOnInit() {
|
|
13
|
+
this.open.set(this.expanded());
|
|
66
14
|
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
get height() {
|
|
71
|
-
const { expanded, state, contentWrapper } = this;
|
|
72
|
-
if ((expanded && state === State.Prepared) ||
|
|
73
|
-
(!expanded && state === State.Animated)) {
|
|
74
|
-
return 0;
|
|
75
|
-
}
|
|
76
|
-
if (contentWrapper &&
|
|
77
|
-
((!expanded && state === State.Prepared) ||
|
|
78
|
-
(expanded && state === State.Animated))) {
|
|
79
|
-
return contentWrapper.nativeElement.offsetHeight;
|
|
80
|
-
}
|
|
81
|
-
if (contentWrapper && expanded && state === State.Loading) {
|
|
82
|
-
return Math.max(contentWrapper.nativeElement.offsetHeight, LOADER_HEIGHT);
|
|
83
|
-
}
|
|
84
|
-
return null;
|
|
85
|
-
}
|
|
86
|
-
onTransitionEnd({ propertyName, pseudoElement }) {
|
|
87
|
-
if (propertyName === 'opacity' &&
|
|
88
|
-
!pseudoElement &&
|
|
89
|
-
this.state === State.Animated) {
|
|
90
|
-
this.state = State.Idle;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
onExpandLoaded(event) {
|
|
94
|
-
event.stopPropagation();
|
|
95
|
-
if (this.state === State.Loading) {
|
|
96
|
-
this.retrigger(State.Animated);
|
|
15
|
+
onTransitionEnd({ propertyName }) {
|
|
16
|
+
if (propertyName === 'grid-template-rows') {
|
|
17
|
+
this.open.set(this.expanded());
|
|
97
18
|
}
|
|
98
19
|
}
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
// We need delay to re-trigger CSS height transition from the correct number
|
|
105
|
-
if (this.state !== State.Prepared) {
|
|
106
|
-
return;
|
|
20
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiExpand, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
21
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiExpand, isStandalone: true, selector: "tui-expand", inputs: { expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "transitionend.self": "onTransitionEnd($event)" }, properties: { "class._expanded": "expanded()", "class._open": "open()" } }, queries: [{ propertyName: "content", first: true, predicate: TuiItem, descendants: true, read: TemplateRef, isSignal: true }], ngImport: i0, template: `
|
|
22
|
+
<div class="t-wrapper">
|
|
23
|
+
@if (expanded() || open()) {
|
|
24
|
+
<ng-container [ngTemplateOutlet]="content() || null" />
|
|
107
25
|
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
}
|
|
112
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: TuiExpandComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
113
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: TuiExpandComponent, isStandalone: true, selector: "tui-expand", inputs: { async: "async", expandedSetter: ["expanded", "expandedSetter"] }, host: { listeners: { "transitionend.self": "onTransitionEnd($event)", "tui-expand-loaded": "onExpandLoaded($event)" }, properties: { "style.height.px": "height", "class._loading": "loading", "class._overflow": "overflow", "class._expanded": "expanded", "attr.aria-expanded": "expanded" } }, queries: [{ propertyName: "content", first: true, predicate: TuiExpandContent, descendants: true, read: TemplateRef }], viewQueries: [{ propertyName: "contentWrapper", first: true, predicate: ["wrapper"], descendants: true }], ngImport: i0, template: "<div\n #wrapper\n class=\"t-wrapper\"\n @tuiParentAnimation\n [@.disabled]=\"overflow\"\n>\n <ng-container *ngIf=\"contentVisible\">\n <ng-content />\n <tui-loader\n *ngIf=\"async; else content\"\n size=\"l\"\n [overlay]=\"true\"\n [showLoader]=\"loading\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </tui-loader>\n </ng-container>\n</div>\n", styles: [":host{transition-property:opacity,height,visibility;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;display:block;opacity:0;transition-delay:1ms}:host._overflow{overflow:hidden}:host._expanded{opacity:1}:host._loading{opacity:.99}.t-wrapper:before,.t-wrapper:after{content:\"\";display:table}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: TuiLoader, selector: "tui-loader", inputs: ["size", "inheritColor", "overlay", "textContent", "showLoader"] }], animations: [tuiParentAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
26
|
+
<ng-content />
|
|
27
|
+
</div>
|
|
28
|
+
`, isInline: true, styles: [":host{transition-property:grid-template-rows,padding;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;display:grid;grid-template-rows:0fr;transition-delay:1ms}:host:not(._expanded){padding-block:0}:host._expanded{grid-template-rows:1fr}:host._expanded>.t-wrapper{opacity:1;visibility:visible}:host._expanded._open>.t-wrapper{overflow:visible}.t-wrapper{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;grid-row:1 / span 2;overflow:hidden;opacity:0;visibility:hidden}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
114
29
|
}
|
|
115
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiExpand, decorators: [{
|
|
116
31
|
type: Component,
|
|
117
|
-
args: [{
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
32
|
+
args: [{ selector: 'tui-expand', imports: [NgTemplateOutlet], template: `
|
|
33
|
+
<div class="t-wrapper">
|
|
34
|
+
@if (expanded() || open()) {
|
|
35
|
+
<ng-container [ngTemplateOutlet]="content() || null" />
|
|
36
|
+
}
|
|
37
|
+
<ng-content />
|
|
38
|
+
</div>
|
|
39
|
+
`, changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
40
|
+
'[class._expanded]': 'expanded()',
|
|
41
|
+
'[class._open]': 'open()',
|
|
123
42
|
'(transitionend.self)': 'onTransitionEnd($event)',
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
}], propDecorators: { contentWrapper: [{
|
|
127
|
-
type: ViewChild,
|
|
128
|
-
args: ['wrapper']
|
|
129
|
-
}], content: [{
|
|
130
|
-
type: ContentChild,
|
|
131
|
-
args: [TuiExpandContent, { read: TemplateRef }]
|
|
132
|
-
}], async: [{
|
|
133
|
-
type: Input
|
|
134
|
-
}], expandedSetter: [{
|
|
135
|
-
type: Input,
|
|
136
|
-
args: ['expanded']
|
|
137
|
-
}] } });
|
|
138
|
-
|
|
139
|
-
/**
|
|
140
|
-
* @deprecated use {@link TuiExpand} from @taiga-ui/experimental
|
|
141
|
-
*/
|
|
142
|
-
const TuiExpand = [TuiExpandComponent, TuiExpandContent];
|
|
43
|
+
}, styles: [":host{transition-property:grid-template-rows,padding;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;position:relative;display:grid;grid-template-rows:0fr;transition-delay:1ms}:host:not(._expanded){padding-block:0}:host._expanded{grid-template-rows:1fr}:host._expanded>.t-wrapper{opacity:1;visibility:visible}:host._expanded._open>.t-wrapper{overflow:visible}.t-wrapper{transition-property:all;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;grid-row:1 / span 2;overflow:hidden;opacity:0;visibility:hidden}\n"] }]
|
|
44
|
+
}] });
|
|
143
45
|
|
|
144
46
|
/**
|
|
145
47
|
* Generated bundle index. Do not edit.
|
|
146
48
|
*/
|
|
147
49
|
|
|
148
|
-
export {
|
|
50
|
+
export { TuiExpand };
|
|
149
51
|
//# sourceMappingURL=taiga-ui-core-components-expand.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-expand.mjs","sources":["../../../projects/core/components/expand/expand-content.directive.ts","../../../projects/core/components/expand/expand.component.ts","../../../projects/core/components/expand/expand.template.html","../../../projects/core/components/expand/expand.ts","../../../projects/core/components/expand/taiga-ui-core-components-expand.ts"],"sourcesContent":["import {Directive} from '@angular/core';\n\n/**\n * @deprecated use {@link TuiExpand} from @taiga-ui/experimental\n */\n@Directive({\n standalone: true,\n selector: '[tuiExpandContent]',\n})\nexport class TuiExpandContent {}\n","import {NgIf, type NgIfContext, NgTemplateOutlet} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n DestroyRef,\n type ElementRef,\n inject,\n Input,\n TemplateRef,\n ViewChild,\n} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {type TuiValuesOf} from '@taiga-ui/cdk/types';\nimport {tuiParentAnimation} from '@taiga-ui/core/animations';\nimport {TuiLoader} from '@taiga-ui/core/components/loader';\nimport {timer} from 'rxjs';\n\nimport {TuiExpandContent} from './expand-content.directive';\n\nconst State = {\n Idle: 0,\n Loading: 1,\n Prepared: 2,\n Animated: 3,\n} as const;\n\nconst LOADER_HEIGHT = 48;\n\n/**\n * An event indicating that async data for expand has finished loading.\n * Dispatch to finish loading states for {@link TuiExpandComponent}.\n */\nexport const TUI_EXPAND_LOADED = 'tui-expand-loaded';\n\n/**\n * @deprecated use {@link TuiExpand} from @taiga-ui/experimental\n */\n@Component({\n standalone: true,\n selector: 'tui-expand',\n imports: [NgIf, NgTemplateOutlet, TuiLoader],\n templateUrl: './expand.template.html',\n styleUrls: ['./expand.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n animations: [tuiParentAnimation],\n host: {\n '[style.height.px]': 'height',\n '[class._loading]': 'loading',\n '[class._overflow]': 'overflow',\n '[class._expanded]': 'expanded',\n '[attr.aria-expanded]': 'expanded',\n '(transitionend.self)': 'onTransitionEnd($event)',\n [`(${TUI_EXPAND_LOADED})`]: 'onExpandLoaded($event)',\n },\n})\nexport class TuiExpandComponent {\n @ViewChild('wrapper')\n private readonly contentWrapper?: ElementRef<HTMLDivElement>;\n\n private readonly cdr = inject(ChangeDetectorRef);\n private readonly destroyRef = inject(DestroyRef);\n private state: TuiValuesOf<typeof State> = State.Idle;\n\n @ContentChild(TuiExpandContent, {read: TemplateRef})\n protected content: TemplateRef<NgIfContext<boolean>> | null = null;\n\n protected expanded: boolean | null = null;\n\n @Input()\n public async = false;\n\n @Input('expanded')\n public set expandedSetter(expanded: boolean | null) {\n if (this.expanded === null) {\n this.expanded = expanded;\n\n return;\n }\n\n if (this.state !== State.Idle) {\n this.expanded = expanded;\n this.state = State.Animated;\n\n return;\n }\n\n this.expanded = expanded;\n this.retrigger(this.async && expanded ? State.Loading : State.Animated);\n }\n\n public get contentVisible(): boolean {\n return this.expanded || this.state !== State.Idle;\n }\n\n protected get overflow(): boolean {\n return this.state !== State.Idle;\n }\n\n protected get loading(): boolean {\n return !!this.expanded && this.async && this.state === State.Loading;\n }\n\n protected get height(): number | null {\n const {expanded, state, contentWrapper} = this;\n\n if (\n (expanded && state === State.Prepared) ||\n (!expanded && state === State.Animated)\n ) {\n return 0;\n }\n\n if (\n contentWrapper &&\n ((!expanded && state === State.Prepared) ||\n (expanded && state === State.Animated))\n ) {\n return contentWrapper.nativeElement.offsetHeight;\n }\n\n if (contentWrapper && expanded && state === State.Loading) {\n return Math.max(contentWrapper.nativeElement.offsetHeight, LOADER_HEIGHT);\n }\n\n return null;\n }\n\n protected onTransitionEnd({propertyName, pseudoElement}: TransitionEvent): void {\n if (\n propertyName === 'opacity' &&\n !pseudoElement &&\n this.state === State.Animated\n ) {\n this.state = State.Idle;\n }\n }\n\n protected onExpandLoaded(event: Event): void {\n event.stopPropagation();\n\n if (this.state === State.Loading) {\n this.retrigger(State.Animated);\n }\n }\n\n private retrigger(state: TuiValuesOf<typeof State>): void {\n this.state = State.Prepared;\n\n timer(0)\n .pipe(takeUntilDestroyed(this.destroyRef))\n .subscribe(() => {\n // We need delay to re-trigger CSS height transition from the correct number\n if (this.state !== State.Prepared) {\n return;\n }\n\n this.state = state;\n this.cdr.markForCheck();\n });\n }\n}\n","<div\n #wrapper\n class=\"t-wrapper\"\n @tuiParentAnimation\n [@.disabled]=\"overflow\"\n>\n <ng-container *ngIf=\"contentVisible\">\n <ng-content />\n <tui-loader\n *ngIf=\"async; else content\"\n size=\"l\"\n [overlay]=\"true\"\n [showLoader]=\"loading\"\n >\n <ng-container [ngTemplateOutlet]=\"content\" />\n </tui-loader>\n </ng-container>\n</div>\n","import {TuiExpandComponent} from './expand.component';\nimport {TuiExpandContent} from './expand-content.directive';\n\n/**\n * @deprecated use {@link TuiExpand} from @taiga-ui/experimental\n */\nexport const TuiExpand = [TuiExpandComponent, TuiExpandContent] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAEA;;AAEG;AACH,MAIa,gBAAgB,CAAA;+GAAhB,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;mGAAhB,gBAAgB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,oBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA,EAAA;;4FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,oBAAoB;AACjC,iBAAA,CAAA;;;ACaD,MAAM,KAAK,GAAG;AACV,IAAA,IAAI,EAAE,CAAC;AACP,IAAA,OAAO,EAAE,CAAC;AACV,IAAA,QAAQ,EAAE,CAAC;AACX,IAAA,QAAQ,EAAE,CAAC;CACL,CAAC;AAEX,MAAM,aAAa,GAAG,EAAE,CAAC;AAEzB;;;AAGG;AACI,MAAM,iBAAiB,GAAG,oBAAoB;AAErD;;AAEG;AACH,MAkBa,k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,iBAAiB,CAAG,CAAA,CAAA,GAAG,wBAAwB;AACvD,qBAAA,EAAA,QAAA,EAAA,ycAAA,EAAA,MAAA,EAAA,CAAA,4UAAA,CAAA,EAAA,CAAA;8BAIgB,cAAc,EAAA,CAAA;sBAD9B,SAAS;uBAAC,SAAS,CAAA;gBAQV,OAAO,EAAA,CAAA;sBADhB,YAAY;AAAC,gBAAA,IAAA,EAAA,CAAA,gBAAgB,EAAE,EAAC,IAAI,EAAE,WAAW,EAAC,CAAA;gBAM5C,KAAK,EAAA,CAAA;sBADX,KAAK;gBAIK,cAAc,EAAA,CAAA;sBADxB,KAAK;uBAAC,UAAU,CAAA;;;AEtErB;;AAEG;MACU,SAAS,GAAG,CAAC,kBAAkB,EAAE,gBAAgB;;ACN9D;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-expand.mjs","sources":["../../../projects/core/components/expand/expand.component.ts","../../../projects/core/components/expand/taiga-ui-core-components-expand.ts"],"sourcesContent":["import {NgTemplateOutlet} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n contentChild,\n input,\n type OnInit,\n signal,\n TemplateRef,\n} from '@angular/core';\nimport {TuiItem} from '@taiga-ui/cdk/directives/item';\n\n@Component({\n selector: 'tui-expand',\n imports: [NgTemplateOutlet],\n template: `\n <div class=\"t-wrapper\">\n @if (expanded() || open()) {\n <ng-container [ngTemplateOutlet]=\"content() || null\" />\n }\n <ng-content />\n </div>\n `,\n styleUrl: './expand.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[class._expanded]': 'expanded()',\n '[class._open]': 'open()',\n '(transitionend.self)': 'onTransitionEnd($event)',\n },\n})\nexport class TuiExpand implements OnInit {\n protected readonly content = contentChild(TuiItem, {read: TemplateRef});\n protected readonly open = signal(false);\n\n public readonly expanded = input(false);\n\n public ngOnInit(): void {\n this.open.set(this.expanded());\n }\n\n protected onTransitionEnd({propertyName}: TransitionEvent): void {\n if (propertyName === 'grid-template-rows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