@taiga-ui/kit 4.52.0-canary.e444d19 → 4.52.0-canary.eb5ffe3
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/components/accordion/accordion.component.d.ts +13 -0
- package/components/accordion/accordion.d.ts +4 -4
- package/components/accordion/accordion.directive.d.ts +11 -10
- package/components/accordion/index.d.ts +1 -3
- package/components/action-bar/action-bar.component.d.ts +5 -7
- package/components/action-bar/index.d.ts +0 -2
- package/components/avatar/avatar-outline.directive.d.ts +3 -3
- package/components/avatar/avatar.directive.d.ts +15 -0
- package/components/avatar/avatar.options.d.ts +1 -4
- package/components/avatar/index.d.ts +1 -1
- package/components/badge/badge.directive.d.ts +2 -2
- package/components/block/block.directive.d.ts +4 -4
- package/components/block/block.options.d.ts +1 -1
- package/components/calendar-month/calendar-month.component.d.ts +1 -1
- package/components/calendar-month/calendar-month.options.d.ts +1 -1
- package/components/calendar-range/calendar-range.component.d.ts +1 -2
- package/components/checkbox/checkbox.component.d.ts +7 -18
- package/components/checkbox/checkbox.options.d.ts +5 -9
- package/components/chip/chip.directive.d.ts +2 -4
- package/components/comment/comment.directive.d.ts +2 -2
- package/components/confirm/confirm.component.d.ts +2 -1
- package/components/confirm/confirm.service.d.ts +2 -1
- package/{directives → components}/copy/copy.component.d.ts +1 -1
- package/{directives → components}/copy/copy.directive.d.ts +2 -2
- package/{directives → components}/copy/copy.options.d.ts +2 -2
- package/components/data-list-wrapper/data-list-group-wrapper.component.d.ts +2 -0
- package/components/files/file/file.options.d.ts +1 -1
- package/components/files/files/files.component.d.ts +2 -2
- package/components/floating-container/floating-container.directive.d.ts +2 -2
- package/components/fullscreen/fullscreen.component.d.ts +14 -0
- package/components/fullscreen/index.d.ts +1 -0
- package/components/index.d.ts +3 -2
- package/components/input-chip/input-chip.options.d.ts +1 -1
- package/components/input-color/input-color.component.d.ts +2 -2
- package/components/input-color/input-color.options.d.ts +1 -1
- package/components/input-date/input-date.options.d.ts +1 -1
- package/components/input-number/input-number.options.d.ts +1 -1
- package/components/input-number/quantum.directive.d.ts +1 -1
- package/components/input-number/step/input-number-step.component.d.ts +1 -1
- package/components/input-phone/input-phone.options.d.ts +1 -1
- package/components/input-phone-international/input-phone-international.component.d.ts +24 -30
- package/components/input-pin/input-pin.component.d.ts +1 -1
- package/components/input-range/input-range.component.d.ts +9 -12
- package/components/input-slider/input-slider.directive.d.ts +2 -4
- package/components/input-time/input-time.directive.d.ts +1 -0
- package/components/input-time/input-time.options.d.ts +1 -1
- package/components/like/like.component.d.ts +4 -11
- package/components/like/like.options.d.ts +3 -4
- package/components/line-clamp/line-clamp-box.component.d.ts +3 -4
- package/components/line-clamp/line-clamp.component.d.ts +8 -10
- package/components/multi-select/multi-select-group/multi-select-group.component.d.ts +3 -3
- package/components/multi-select/multi-select-option/multi-select-option.component.d.ts +1 -1
- package/components/pager/pager.component.d.ts +1 -1
- package/components/pagination/pagination.component.d.ts +1 -1
- package/components/pin/pin.directive.d.ts +2 -2
- package/components/preview/pagination/preview-pagination.component.d.ts +1 -1
- package/components/preview/preview.component.d.ts +1 -1
- package/components/preview/zoom/preview-zoom.component.d.ts +1 -1
- package/components/progress/progress-bar/fixed-gradient/progress-fixed-gradient.directive.d.ts +1 -2
- package/components/progress/progress-segmented/progress-segmented.directive.d.ts +2 -2
- package/components/push/push-alert.component.d.ts +4 -3
- package/components/push/push.component.d.ts +2 -2
- package/components/push/push.directive.d.ts +4 -6
- package/components/push/push.options.d.ts +4 -8
- package/components/push/push.service.d.ts +6 -2
- package/components/radio/radio.component.d.ts +7 -8
- package/components/radio/radio.directive.d.ts +2 -2
- package/components/radio/radio.options.d.ts +2 -5
- package/components/range/range-change.directive.d.ts +1 -1
- package/components/range/range.component.d.ts +0 -5
- package/components/rating/rating.component.d.ts +5 -5
- package/components/rating/rating.options.d.ts +5 -3
- package/components/segmented/segmented.component.d.ts +1 -3
- package/components/slider/helpers/key-steps.d.ts +1 -2
- package/components/slider/helpers/slider-key-steps.directive.d.ts +12 -21
- package/components/slides/slides.directive.d.ts +4 -4
- package/components/status/status.directive.d.ts +2 -2
- package/components/switch/switch.component.d.ts +7 -19
- package/components/switch/switch.options.d.ts +4 -8
- package/components/tabs/tabs-with-more.component.d.ts +1 -1
- package/components/textarea/textarea-limit.directive.d.ts +4 -5
- package/components/textarea/textarea.options.d.ts +1 -1
- package/components/toast/index.d.ts +5 -0
- package/components/toast/toast.component.d.ts +18 -0
- package/components/toast/toast.d.ts +3 -0
- package/components/toast/toast.directive.d.ts +7 -0
- package/components/toast/toast.options.d.ts +9 -0
- package/components/toast/toast.service.d.ts +17 -0
- package/components/tree/components/tree-item-content/tree-item-content.component.d.ts +1 -1
- package/directives/button-select/button-select.directive.d.ts +1 -2
- package/directives/chevron/chevron.directive.d.ts +2 -3
- package/directives/fade/fade.directive.d.ts +1 -0
- package/directives/highlight/highlight.directive.d.ts +1 -3
- package/directives/index.d.ts +0 -1
- package/directives/password/password.options.d.ts +1 -1
- package/directives/sensitive/sensitive.directive.d.ts +2 -2
- package/directives/shimmer/shimmer.directive.d.ts +3 -3
- package/directives/skeleton/skeleton.directive.d.ts +3 -3
- package/directives/tooltip/tooltip.directive.d.ts +2 -2
- package/directives/tooltip/tooltip.options.d.ts +1 -4
- package/fesm2022/taiga-ui-kit-components-accordion.mjs +69 -144
- package/fesm2022/taiga-ui-kit-components-accordion.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-action-bar.mjs +22 -38
- package/fesm2022/taiga-ui-kit-components-action-bar.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-avatar.mjs +52 -70
- package/fesm2022/taiga-ui-kit-components-avatar.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-badge-notification.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-badge.mjs +11 -18
- package/fesm2022/taiga-ui-kit-components-badge.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-badged-content.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-block.mjs +15 -22
- package/fesm2022/taiga-ui-kit-components-block.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +3 -4
- package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +3 -4
- package/fesm2022/taiga-ui-kit-components-calendar-month.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +4 -5
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-carousel.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-carousel.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-checkbox.mjs +18 -75
- package/fesm2022/taiga-ui-kit-components-checkbox.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-chip.mjs +20 -25
- package/fesm2022/taiga-ui-kit-components-chip.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs +5 -5
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-comment.mjs +11 -18
- package/fesm2022/taiga-ui-kit-components-comment.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-confirm.mjs +8 -9
- package/fesm2022/taiga-ui-kit-components-confirm.mjs.map +1 -1
- package/fesm2022/{taiga-ui-kit-directives-copy.mjs → taiga-ui-kit-components-copy.mjs} +11 -12
- package/fesm2022/taiga-ui-kit-components-copy.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +14 -6
- package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-drawer.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-drawer.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-elastic-container.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-files.mjs +12 -11
- package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-filter.mjs +1 -1
- package/fesm2022/taiga-ui-kit-components-filter.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-floating-container.mjs +11 -17
- package/fesm2022/taiga-ui-kit-components-floating-container.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-fullscreen.mjs +63 -0
- package/fesm2022/taiga-ui-kit-components-fullscreen.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-components-input-chip.mjs +10 -5
- package/fesm2022/taiga-ui-kit-components-input-chip.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-color.mjs +6 -8
- package/fesm2022/taiga-ui-kit-components-input-color.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +3 -4
- package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +1 -2
- package/fesm2022/taiga-ui-kit-components-input-date-time.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date.mjs +5 -6
- package/fesm2022/taiga-ui-kit-components-input-date.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-inline.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +5 -6
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-month.mjs +5 -6
- package/fesm2022/taiga-ui-kit-components-input-month.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-number.mjs +10 -9
- package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +103 -126
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs +2 -3
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-pin.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-input-pin.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-range.mjs +31 -27
- package/fesm2022/taiga-ui-kit-components-input-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs +25 -39
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-time.mjs +21 -5
- package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-year.mjs +4 -5
- package/fesm2022/taiga-ui-kit-components-input-year.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-items-with-more.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-like.mjs +38 -31
- package/fesm2022/taiga-ui-kit-components-like.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +25 -64
- package/fesm2022/taiga-ui-kit-components-line-clamp.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-message.mjs +6 -8
- package/fesm2022/taiga-ui-kit-components-message.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-multi-select.mjs +17 -18
- package/fesm2022/taiga-ui-kit-components-multi-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +2 -9
- package/fesm2022/taiga-ui-kit-components-notification-middle.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pager.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-pager.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pagination.mjs +5 -6
- package/fesm2022/taiga-ui-kit-components-pagination.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pin.mjs +13 -17
- package/fesm2022/taiga-ui-kit-components-pin.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-preview-dialog.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-preview.mjs +13 -13
- package/fesm2022/taiga-ui-kit-components-preview.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-progress.mjs +21 -34
- package/fesm2022/taiga-ui-kit-components-progress.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pulse.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-push.mjs +40 -47
- package/fesm2022/taiga-ui-kit-components-push.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-radio-list.mjs +2 -2
- package/fesm2022/taiga-ui-kit-components-radio-list.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-radio.mjs +30 -35
- package/fesm2022/taiga-ui-kit-components-radio.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-range.mjs +4 -13
- package/fesm2022/taiga-ui-kit-components-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-rating.mjs +15 -19
- package/fesm2022/taiga-ui-kit-components-rating.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-segmented.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-select.mjs +29 -22
- package/fesm2022/taiga-ui-kit-components-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-slider.mjs +57 -55
- package/fesm2022/taiga-ui-kit-components-slider.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-slides.mjs +12 -20
- package/fesm2022/taiga-ui-kit-components-slides.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-status.mjs +10 -14
- package/fesm2022/taiga-ui-kit-components-status.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-stepper.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-switch.mjs +18 -64
- package/fesm2022/taiga-ui-kit-components-switch.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-tabs.mjs +14 -17
- package/fesm2022/taiga-ui-kit-components-tabs.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-textarea.mjs +4 -11
- package/fesm2022/taiga-ui-kit-components-textarea.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-tiles.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-toast.mjs +165 -0
- package/fesm2022/taiga-ui-kit-components-toast.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-components-tree.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-tree.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components.mjs +3 -2
- package/fesm2022/taiga-ui-kit-components.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-button-group.mjs +6 -9
- package/fesm2022/taiga-ui-kit-directives-button-group.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-button-select.mjs +2 -9
- package/fesm2022/taiga-ui-kit-directives-button-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-chevron.mjs +11 -18
- package/fesm2022/taiga-ui-kit-directives-chevron.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-connected.mjs +7 -12
- package/fesm2022/taiga-ui-kit-directives-connected.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-fade.mjs +6 -9
- package/fesm2022/taiga-ui-kit-directives-fade.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-password.mjs +5 -8
- package/fesm2022/taiga-ui-kit-directives-password.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-sensitive.mjs +11 -16
- package/fesm2022/taiga-ui-kit-directives-sensitive.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-shimmer.mjs +22 -32
- package/fesm2022/taiga-ui-kit-directives-shimmer.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-skeleton.mjs +25 -36
- package/fesm2022/taiga-ui-kit-directives-skeleton.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +13 -18
- package/fesm2022/taiga-ui-kit-directives-tooltip.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +2 -3
- package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives.mjs +0 -1
- package/fesm2022/taiga-ui-kit-directives.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +2 -1
- package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes.mjs +0 -1
- package/fesm2022/taiga-ui-kit-pipes.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-tokens.mjs +4 -7
- package/fesm2022/taiga-ui-kit-tokens.mjs.map +1 -1
- package/package.json +34 -37
- package/pipes/index.d.ts +0 -1
- package/styles/components/avatar.less +188 -0
- package/styles/components/badge.less +1 -0
- package/styles/components/checkbox.less +14 -12
- package/styles/components/chip.less +12 -3
- package/styles/components/like.less +4 -9
- package/styles/components/pin.less +3 -7
- package/styles/components/radio.less +1 -1
- package/styles/components/switch.less +9 -9
- package/styles/components/toast.less +44 -0
- package/tokens/i18n.d.ts +25 -26
- package/tokens/index.d.ts +0 -1
- package/tokens/input-date-options.d.ts +1 -1
- package/components/accordion/accordion-item-content.directive.d.ts +0 -6
- package/components/accordion/accordion-item-eager-content.directive.d.ts +0 -5
- package/components/accordion/accordion-item.component.d.ts +0 -25
- package/components/action-bar/action-bar.d.ts +0 -3
- package/components/action-bar/action-bar.directive.d.ts +0 -6
- package/components/avatar/avatar.component.d.ts +0 -15
- package/components/input-password/index.d.ts +0 -2
- package/components/input-password/input-password.component.d.ts +0 -16
- package/components/input-password/input-password.options.d.ts +0 -24
- package/components/pdf-viewer/index.d.ts +0 -4
- package/components/pdf-viewer/pdf-viewer.component.d.ts +0 -12
- package/components/pdf-viewer/pdf-viewer.directive.d.ts +0 -7
- package/components/pdf-viewer/pdf-viewer.options.d.ts +0 -13
- package/components/pdf-viewer/pdf-viewer.service.d.ts +0 -13
- package/fesm2022/taiga-ui-kit-components-input-password.mjs +0 -95
- package/fesm2022/taiga-ui-kit-components-input-password.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-components-pdf-viewer.mjs +0 -83
- package/fesm2022/taiga-ui-kit-components-pdf-viewer.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-directives-copy.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-pipes-field-error.mjs +0 -147
- package/fesm2022/taiga-ui-kit-pipes-field-error.mjs.map +0 -1
- package/pipes/field-error/field-error-content-pipe.d.ts +0 -14
- package/pipes/field-error/field-error-pipe.d.ts +0 -29
- package/pipes/field-error/index.d.ts +0 -2
- package/tokens/validation-errors.d.ts +0 -5
- /package/{directives → components}/copy/copy.d.ts +0 -0
- /package/{directives → components}/copy/index.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-progress.mjs","sources":["../../../projects/kit/components/progress/progress-bar/fixed-gradient/progress-fixed-gradient.directive.ts","../../../projects/kit/components/progress/progress.options.ts","../../../projects/kit/components/progress/progress-bar/progress-bar.component.ts","../../../projects/kit/components/progress/progress-bar/progress-color-segments.directive.ts","../../../projects/kit/components/progress/progress-circle/progress-circle.component.ts","../../../projects/kit/components/progress/progress-circle/progress-circle.template.html","../../../projects/kit/components/progress/progress-label/progress-label.component.ts","../../../projects/kit/components/progress/progress-label/progress-label.template.html","../../../projects/kit/components/progress/progress-segmented/progress-segmented.directive.ts","../../../projects/kit/components/progress/progress.ts","../../../projects/kit/components/progress/taiga-ui-kit-components-progress.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n standalone: true,\n template: '',\n styleUrls: ['./progress-fixed-gradient.style.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n class: 'tui-fixed-gradient',\n },\n})\nclass TuiProgressFixedGradientStyles {}\n\n@Directive({\n standalone: true,\n selector: 'progress[tuiProgressBar][tuiProgressFixedGradient]',\n host: {\n '[style.--tui-progress-percent.%]': 'progressPercent',\n },\n})\nexport class TuiProgressFixedGradientDirective {\n private readonly nativeProgress = tuiInjectElement<HTMLProgressElement>();\n protected readonly nothing = tuiWithStyles(TuiProgressFixedGradientStyles);\n\n protected get progressPercent(): number {\n const {value} = this.nativeProgress;\n const max = this.nativeProgress.max ?? 1;\n\n return Math.min((value / max) * 100, 100);\n }\n}\n","import {InjectionToken, type Provider} from '@angular/core';\nimport {tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\n\nexport interface TuiProgressOptions {\n readonly color: string | null;\n readonly size: TuiSizeXXL | TuiSizeXXS;\n}\n\nexport const TUI_PROGRESS_DEFAULT_OPTIONS: TuiProgressOptions = {\n color: null,\n size: 'm',\n};\n\nexport const TUI_PROGRESS_OPTIONS = new InjectionToken(\n ngDevMode ? 'TUI_PROGRESS_OPTIONS' : '',\n {\n factory: () => TUI_PROGRESS_DEFAULT_OPTIONS,\n },\n);\n\nexport function tuiProgressOptionsProvider(\n options: Partial<TuiProgressOptions>,\n): Provider {\n return tuiProvideOptions(TUI_PROGRESS_OPTIONS, options, TUI_PROGRESS_DEFAULT_OPTIONS);\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n inject,\n Input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\n\nimport {TUI_PROGRESS_OPTIONS} from '../progress.options';\n\n@Component({\n standalone: true,\n selector: 'progress[tuiProgressBar]',\n template: '',\n styles: ['@import \"@taiga-ui/kit/styles/components/progress-bar.less\";'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[style.--tui-progress-color]': 'color',\n '[attr.data-size]': 'size',\n },\n})\nexport class TuiProgressBar {\n private readonly options = inject(TUI_PROGRESS_OPTIONS);\n\n @Input()\n public color: string | null = this.options.color;\n\n @Input()\n public size: TuiSizeXXL | TuiSizeXXS = this.options.size;\n}\n","import {Directive, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {ResizeObserverService} from '@ng-web-apis/resize-observer';\nimport {tuiWatch, tuiZonefull} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {BehaviorSubject, combineLatest, distinctUntilChanged, map} from 'rxjs';\n\n@Directive({\n standalone: true,\n selector: 'progress[tuiProgressBar][tuiProgressColorSegments]',\n providers: [ResizeObserverService],\n host: {'[style.--tui-progress-color]': 'color()'},\n})\nexport class TuiProgressColorSegments {\n private readonly colors$ = new BehaviorSubject<string[]>([]);\n private readonly el = tuiInjectElement<HTMLProgressElement>();\n\n protected readonly color = toSignal(\n combineLatest([\n this.colors$,\n inject(ResizeObserverService, {self: true}).pipe(\n map(() => this.el.offsetWidth),\n distinctUntilChanged(),\n ),\n ]).pipe(\n map(([colors, width]) => {\n const segmentWidth = Math.ceil(width / colors.length);\n const colorsString = colors.reduce(\n (acc, color, i) =>\n `${acc}, ${color} ${i * segmentWidth}px ${(i + 1) * segmentWidth}px`,\n '',\n );\n\n return `linear-gradient(to right ${colorsString})`;\n }),\n tuiZonefull(),\n tuiWatch(),\n ),\n );\n\n @Input('tuiProgressColorSegments')\n public set colors(colors: string[]) {\n this.colors$.next(colors);\n }\n}\n","import {type BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\nimport {delay, of} from 'rxjs';\n\nimport {TUI_PROGRESS_OPTIONS} from '../progress.options';\n\n@Component({\n standalone: true,\n selector: 'tui-progress-circle',\n templateUrl: './progress-circle.template.html',\n styleUrls: ['./progress-circle.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.data-size]': 'size',\n '[style.--tui-progress-color]': 'color',\n '[style.--t-progress-ratio]': 'progressRatio',\n '[class._arc]': 'arc',\n },\n})\nexport class TuiProgressCircle {\n private readonly options = inject(TUI_PROGRESS_OPTIONS);\n\n protected readonly animationDelay = toSignal(of(true).pipe(delay(0)));\n\n @Input()\n public value = 0;\n\n @Input()\n public max = 1;\n\n @Input()\n public color: string | null = this.options.color;\n\n @Input()\n public size: TuiSizeXXL | TuiSizeXXS = this.options.size;\n\n @Input({transform: coerceBooleanProperty})\n public arc: BooleanInput = false;\n\n protected get progressRatio(): number {\n const ratio = this.value / this.max;\n\n return Number.isFinite(ratio) ? ratio : 0;\n }\n}\n","<progress\n class=\"t-hidden-progress\"\n [max]=\"max\"\n [value]=\"value\"\n></progress>\n\n<svg\n aria-hidden=\"true\"\n height=\"100%\"\n width=\"100%\"\n class=\"t-svg\"\n>\n <circle\n cx=\"50%\"\n cy=\"50%\"\n class=\"t-track\"\n />\n\n <circle\n cx=\"50%\"\n cy=\"50%\"\n class=\"t-progress\"\n [class.t-progress_filled]=\"animationDelay()\"\n />\n</svg>\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\n\n@Component({\n standalone: true,\n selector: 'label[tuiProgressLabel]',\n templateUrl: './progress-label.template.html',\n styleUrls: ['./progress-label.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiProgressLabel {}\n","<ng-content select=\"progress\" />\n<ng-content select=\"tui-progress-circle\" />\n<span class=\"t-label\">\n <ng-content />\n</span>\n","import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n Input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n standalone: true,\n template: '',\n styleUrls: ['./progress-segmented.style.less'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-progress-segmented'},\n})\nclass TuiProgressSegmentedStyles {}\n\n@Directive({\n standalone: true,\n selector: '[tuiProgressBar][segments]',\n host: {\n class: '_segmented',\n '[style.--t-segment-width]': '1 / segments',\n },\n})\nexport class TuiProgressSegmented {\n protected readonly nothing = tuiWithStyles(TuiProgressSegmentedStyles);\n\n @Input()\n public segments = 1;\n}\n","import {TuiProgressFixedGradientDirective} from './progress-bar/fixed-gradient/progress-fixed-gradient.directive';\nimport {TuiProgressBar} from './progress-bar/progress-bar.component';\nimport {TuiProgressColorSegments} from './progress-bar/progress-color-segments.directive';\nimport {TuiProgressCircle} from './progress-circle/progress-circle.component';\nimport {TuiProgressLabel} from './progress-label/progress-label.component';\nimport {TuiProgressSegmented} from './progress-segmented/progress-segmented.directive';\n\nexport const TuiProgress = [\n TuiProgressBar,\n TuiProgressCircle,\n TuiProgressColorSegments,\n TuiProgressFixedGradientDirective,\n TuiProgressLabel,\n TuiProgressSegmented,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AASA,MAUM,8BAA8B,CAAA;+GAA9B,8BAA8B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAA9B,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,8BAA8B,wHARtB,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,2eAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAQV,8BAA8B,EAAA,UAAA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Q,MAAA,WAAW,GAAG;IACvB,cAAc;IACd,iBAAiB;IACjB,wBAAwB;IACxB,iCAAiC;IACjC,gBAAgB;IAChB,oBAAoB;;;ACbxB;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-progress.mjs","sources":["../../../projects/kit/components/progress/progress-bar/fixed-gradient/progress-fixed-gradient.directive.ts","../../../projects/kit/components/progress/progress.options.ts","../../../projects/kit/components/progress/progress-bar/progress-bar.component.ts","../../../projects/kit/components/progress/progress-bar/progress-color-segments.directive.ts","../../../projects/kit/components/progress/progress-circle/progress-circle.component.ts","../../../projects/kit/components/progress/progress-circle/progress-circle.template.html","../../../projects/kit/components/progress/progress-label/progress-label.component.ts","../../../projects/kit/components/progress/progress-label/progress-label.template.html","../../../projects/kit/components/progress/progress-segmented/progress-segmented.directive.ts","../../../projects/kit/components/progress/progress.ts","../../../projects/kit/components/progress/taiga-ui-kit-components-progress.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n template: '',\n styleUrl: './progress-fixed-gradient.style.less',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-fixed-gradient'},\n})\nclass Styles {}\n\n@Directive({\n selector: 'progress[tuiProgressBar][tuiProgressFixedGradient]',\n host: {'[style.--tui-progress-percent.%]': 'el.position * 100'},\n})\nexport class TuiProgressFixedGradientDirective {\n protected readonly nothing = tuiWithStyles(Styles);\n protected readonly el = tuiInjectElement<HTMLProgressElement>();\n}\n","import {InjectionToken, type Provider} from '@angular/core';\nimport {tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\n\nexport interface TuiProgressOptions {\n readonly color: string | null;\n readonly size: TuiSizeXXL | TuiSizeXXS;\n}\n\nexport const TUI_PROGRESS_DEFAULT_OPTIONS: TuiProgressOptions = {\n color: null,\n size: 'm',\n};\n\nexport const TUI_PROGRESS_OPTIONS = new InjectionToken(\n ngDevMode ? 'TUI_PROGRESS_OPTIONS' : '',\n {\n factory: () => TUI_PROGRESS_DEFAULT_OPTIONS,\n },\n);\n\nexport function tuiProgressOptionsProvider(\n options: Partial<TuiProgressOptions>,\n): Provider {\n return tuiProvideOptions(TUI_PROGRESS_OPTIONS, options, TUI_PROGRESS_DEFAULT_OPTIONS);\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n inject,\n Input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\n\nimport {TUI_PROGRESS_OPTIONS} from '../progress.options';\n\n@Component({\n standalone: true,\n selector: 'progress[tuiProgressBar]',\n template: '',\n styles: '@import \"@taiga-ui/kit/styles/components/progress-bar.less\";',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[style.--tui-progress-color]': 'color',\n '[attr.data-size]': 'size',\n },\n})\nexport class TuiProgressBar {\n private readonly options = inject(TUI_PROGRESS_OPTIONS);\n\n @Input()\n public color: string | null = this.options.color;\n\n @Input()\n public size: TuiSizeXXL | TuiSizeXXS = this.options.size;\n}\n","import {Directive, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {ResizeObserverService} from '@ng-web-apis/resize-observer';\nimport {tuiWatch, tuiZonefull} from '@taiga-ui/cdk/observables';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {BehaviorSubject, combineLatest, distinctUntilChanged, map} from 'rxjs';\n\n@Directive({\n standalone: true,\n selector: 'progress[tuiProgressBar][tuiProgressColorSegments]',\n providers: [ResizeObserverService],\n host: {'[style.--tui-progress-color]': 'color()'},\n})\nexport class TuiProgressColorSegments {\n private readonly colors$ = new BehaviorSubject<string[]>([]);\n private readonly el = tuiInjectElement<HTMLProgressElement>();\n\n protected readonly color = toSignal(\n combineLatest([\n this.colors$,\n inject(ResizeObserverService, {self: true}).pipe(\n map(() => this.el.offsetWidth),\n distinctUntilChanged(),\n ),\n ]).pipe(\n map(([colors, width]) => {\n const segmentWidth = Math.ceil(width / colors.length);\n const colorsString = colors.reduce(\n (acc, color, i) =>\n `${acc}, ${color} ${i * segmentWidth}px ${(i + 1) * segmentWidth}px`,\n '',\n );\n\n return `linear-gradient(to right ${colorsString})`;\n }),\n tuiZonefull(),\n tuiWatch(),\n ),\n );\n\n @Input('tuiProgressColorSegments')\n public set colors(colors: string[]) {\n this.colors$.next(colors);\n }\n}\n","import {type BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ChangeDetectionStrategy, Component, inject, Input} from '@angular/core';\nimport {toSignal} from '@angular/core/rxjs-interop';\nimport {type TuiSizeXXL, type TuiSizeXXS} from '@taiga-ui/core/types';\nimport {delay, of} from 'rxjs';\n\nimport {TUI_PROGRESS_OPTIONS} from '../progress.options';\n\n@Component({\n standalone: true,\n selector: 'tui-progress-circle',\n templateUrl: './progress-circle.template.html',\n styleUrl: './progress-circle.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.data-size]': 'size',\n '[style.--tui-progress-color]': 'color',\n '[style.--t-progress-ratio]': 'progressRatio',\n '[class._arc]': 'arc',\n },\n})\nexport class TuiProgressCircle {\n private readonly options = inject(TUI_PROGRESS_OPTIONS);\n\n protected readonly animationDelay = toSignal(of(true).pipe(delay(0)));\n\n @Input()\n public value = 0;\n\n @Input()\n public max = 1;\n\n @Input()\n public color: string | null = this.options.color;\n\n @Input()\n public size: TuiSizeXXL | TuiSizeXXS = this.options.size;\n\n @Input({transform: coerceBooleanProperty})\n public arc: BooleanInput = false;\n\n protected get progressRatio(): number {\n const ratio = this.value / this.max;\n\n return Number.isFinite(ratio) ? ratio : 0;\n }\n}\n","<progress\n class=\"t-hidden-progress\"\n [max]=\"max\"\n [value]=\"value\"\n></progress>\n\n<svg\n aria-hidden=\"true\"\n height=\"100%\"\n width=\"100%\"\n class=\"t-svg\"\n>\n <circle\n cx=\"50%\"\n cy=\"50%\"\n class=\"t-track\"\n />\n\n <circle\n cx=\"50%\"\n cy=\"50%\"\n class=\"t-progress\"\n [class.t-progress_filled]=\"animationDelay()\"\n />\n</svg>\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\n\n@Component({\n standalone: true,\n selector: 'label[tuiProgressLabel]',\n templateUrl: './progress-label.template.html',\n styleUrl: './progress-label.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiProgressLabel {}\n","<ng-content select=\"progress\" />\n<ng-content select=\"tui-progress-circle\" />\n<span class=\"t-label\">\n <ng-content />\n</span>\n","import {\n ChangeDetectionStrategy,\n Component,\n Directive,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport {tuiWithStyles} from '@taiga-ui/cdk/utils/miscellaneous';\n\n@Component({\n template: '',\n styleUrl: './progress-segmented.style.less',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {class: 'tui-progress-segmented'},\n})\nclass Styles {}\n\n@Directive({\n selector: '[tuiProgressBar][segments]',\n host: {\n class: '_segmented',\n '[style.--t-segment-width]': '1 / segments()',\n },\n})\nexport class TuiProgressSegmented {\n protected readonly nothing = tuiWithStyles(Styles);\n\n public readonly segments = input(1);\n}\n","import {TuiProgressFixedGradientDirective} from './progress-bar/fixed-gradient/progress-fixed-gradient.directive';\nimport {TuiProgressBar} from './progress-bar/progress-bar.component';\nimport {TuiProgressColorSegments} from './progress-bar/progress-color-segments.directive';\nimport {TuiProgressCircle} from './progress-circle/progress-circle.component';\nimport {TuiProgressLabel} from './progress-label/progress-label.component';\nimport {TuiProgressSegmented} from './progress-segmented/progress-segmented.directive';\n\nexport const TuiProgress = [\n TuiProgressBar,\n TuiProgressCircle,\n TuiProgressColorSegments,\n TuiProgressFixedGradientDirective,\n TuiProgressLabel,\n TuiProgressSegmented,\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["Styles"],"mappings":";;;;;;;;;;eASA,MAOM,MAAM,CAAA;+GAAN,MAAM,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAN,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,MAAM,wHANE,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,2eAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;;4FAMVA,QAAM,EAAA,UAAA,EAAA,CAAA;kBAPX,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAE,EAEG,aAAA,EAAA,iBAAiB,CAAC,IAAI,EACpB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EACzC,IAAA,EAAA,EAAC,KAAK,EAAE,oBAAoB,EAAC,EAAA,MAAA,EAAA,CAAA,2eAAA,CAAA,EAAA;;MAQ1B,iCAAiC,CAAA;AAJ9C,IAAA,WAAA,GAAA;AAKuB,QAAA,IAAA,CAAA,OAAO,GAAG,aAAa,CAACA,QAAM,CAAC;QAC/B,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAuB;AAClE;+GAHY,iCAAiC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAjC,iCAAiC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,oDAAA,EAAA,IAAA,EAAA,EAA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AAA,EAAA,EAAA,UAAA,EAAA,EAAA,yBAAA,EAAA,gBAAA,EAAA,EAAA,cAAA,EAAA,YAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAApB,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAPhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,4BAA4B;AACtC,oBAAA,IAAI,EAAE;AACF,wBAAA,KAAK,EAAE,YAAY;AACnB,wBAAA,2BAA2B,EAAE,gBAAgB;AAChD,qBAAA;AACJ,iBAAA;;;ACjBY,MAAA,WAAW,GAAG;IACvB,cAAc;IACd,iBAAiB;IACjB,wBAAwB;IACxB,iCAAiC;IACjC,gBAAgB;IAChB,oBAAoB;;;ACbxB;;AAEG;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-pulse.mjs","sources":["../../../projects/kit/components/pulse/pulse.component.ts","../../../projects/kit/components/pulse/taiga-ui-kit-components-pulse.ts"],"sourcesContent":["import {isPlatformBrowser} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n inject,\n Input,\n PLATFORM_ID,\n} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiAsRectAccessor, TuiRectAccessor} from '@taiga-ui/core/classes';\n\n@Component({\n standalone: true,\n selector: 'tui-pulse',\n template: '',\n
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-pulse.mjs","sources":["../../../projects/kit/components/pulse/pulse.component.ts","../../../projects/kit/components/pulse/taiga-ui-kit-components-pulse.ts"],"sourcesContent":["import {isPlatformBrowser} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n inject,\n Input,\n PLATFORM_ID,\n} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiAsRectAccessor, TuiRectAccessor} from '@taiga-ui/core/classes';\n\n@Component({\n standalone: true,\n selector: 'tui-pulse',\n template: '',\n styleUrl: './pulse.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiAsRectAccessor(TuiPulse)],\n hostDirectives: [TuiAnimated],\n host: {\n '[class._playing]': 'playing',\n },\n})\nexport class TuiPulse extends TuiRectAccessor {\n private readonly isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n private readonly el = tuiInjectElement();\n\n @Input()\n public playing = true;\n\n public readonly type = 'hint';\n\n public getClientRect(): DOMRect {\n const rect = this.el.getBoundingClientRect();\n\n return this.isBrowser\n ? new DOMRect(rect.x - 4, rect.y - 4, rect.width + 8, rect.height + 8)\n : rect;\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAwBM,MAAO,QAAS,SAAQ,eAAe,CAAA;AAZ7C,IAAA,WAAA,GAAA;;QAaqB,IAAS,CAAA,SAAA,GAAG,iBAAiB,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC;QAClD,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;QAGjC,IAAO,CAAA,OAAA,GAAG,IAAI;QAEL,IAAI,CAAA,IAAA,GAAG,MAAM;AAShC;IAPU,aAAa,GAAA;QAChB,MAAM,IAAI,GAAG,IAAI,CAAC,EAAE,CAAC,qBAAqB,EAAE;QAE5C,OAAO,IAAI,CAAC;cACN,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,EAAE,IAAI,CAAC,KAAK,GAAG,CAAC,EAAE,IAAI,CAAC,MAAM,GAAG,CAAC;cACnE,IAAI;;+GAdL,QAAQ,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAR,QAAQ,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,WAAA,EAAA,MAAA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,gBAAA,EAAA,SAAA,EAAA,EAAA,EAAA,SAAA,EANN,CAAC,iBAAiB,CAAC,QAAQ,CAAC,CAAC,kGAH9B,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,glBAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FASH,QAAQ,EAAA,UAAA,EAAA,CAAA;kBAZpB,SAAS;AACM,YAAA,IAAA,EAAA,CAAA,EAAA,UAAA,EAAA,IAAI,YACN,WAAW,EAAA,QAAA,EACX,EAAE,EAAA,eAAA,EAEK,uBAAuB,CAAC,MAAM,EACpC,SAAA,EAAA,CAAC,iBAAiB,CAAU,QAAA,CAAA,CAAC,kBACxB,CAAC,WAAW,CAAC,EACvB,IAAA,EAAA;AACF,wBAAA,kBAAkB,EAAE,SAAS;AAChC,qBAAA,EAAA,MAAA,EAAA,CAAA,glBAAA,CAAA,EAAA;8BAOM,OAAO,EAAA,CAAA;sBADb;;;AC5BL;;AAEG;;;;"}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { AsyncPipe } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { inject, EventEmitter, Output, Input, ChangeDetectionStrategy, Component,
|
|
4
|
-
import { tuiIsString,
|
|
3
|
+
import { inject, EventEmitter, Output, Input, ChangeDetectionStrategy, Component, Injectable, DestroyRef, Directive } from '@angular/core';
|
|
4
|
+
import { tuiIsString, tuiCreateToken } from '@taiga-ui/cdk/utils/miscellaneous';
|
|
5
5
|
import { TuiButton, tuiButtonOptionsProvider } from '@taiga-ui/core/components/button';
|
|
6
6
|
import { TuiFormatDatePipe } from '@taiga-ui/core/pipes/format-date';
|
|
7
7
|
import { TUI_CLOSE_WORD, TUI_COMMON_ICONS } from '@taiga-ui/core/tokens';
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { TUI_ALERTS } from '@taiga-ui/core/components/alert';
|
|
8
|
+
import * as i1$1 from '@taiga-ui/cdk/portals';
|
|
9
|
+
import { TuiPortalDirective, tuiAsPortal } from '@taiga-ui/cdk/portals';
|
|
10
|
+
import * as i2 from '@taiga-ui/core/directives/notification';
|
|
11
|
+
import { TuiNotificationDirective, TuiNotificationService } from '@taiga-ui/core/directives/notification';
|
|
12
|
+
import { tuiCreateOptions } from '@taiga-ui/cdk/utils/di';
|
|
14
13
|
import * as i1 from '@taiga-ui/cdk/directives/animated';
|
|
15
14
|
import { TuiAnimated } from '@taiga-ui/cdk/directives/animated';
|
|
16
15
|
import { TuiIcon } from '@taiga-ui/core/components/icon';
|
|
17
16
|
import { TuiLink } from '@taiga-ui/core/components/link';
|
|
17
|
+
import { injectContext, PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
|
|
18
18
|
|
|
19
19
|
class TuiPushComponent {
|
|
20
20
|
constructor() {
|
|
21
21
|
this.isString = tuiIsString;
|
|
22
|
-
this.closeWord
|
|
22
|
+
this.closeWord = inject(TUI_CLOSE_WORD);
|
|
23
23
|
this.icons = inject(TUI_COMMON_ICONS);
|
|
24
24
|
this.heading = '';
|
|
25
25
|
this.type = '';
|
|
@@ -28,13 +28,13 @@ class TuiPushComponent {
|
|
|
28
28
|
this.close = new EventEmitter();
|
|
29
29
|
}
|
|
30
30
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
31
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPushComponent, isStandalone: true, selector: "tui-push", inputs: { heading: "heading", type: "type", lines: "lines", timestamp: "timestamp" }, outputs: { close: "close" }, host: { properties: { "style.--t-lines": "lines" } }, providers: [tuiButtonOptionsProvider({ size: 's', appearance: 'secondary' })], ngImport: i0, template: "<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord
|
|
31
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPushComponent, isStandalone: true, selector: "tui-push", inputs: { heading: "heading", type: "type", lines: "lines", timestamp: "timestamp" }, outputs: { close: "close" }, host: { properties: { "style.--t-lines": "lines" } }, providers: [tuiButtonOptionsProvider({ size: 's', appearance: 'secondary' })], ngImport: i0, template: "<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord() }}\n </button>\n}\n<div class=\"t-top\">\n <span class=\"t-icon\">\n <ng-content select=\"tui-icon\" />\n </span>\n {{ type }}\n @if (timestamp) {\n <span\n class=\"t-time\"\n [textContent]=\"isString(timestamp) ? timestamp : (timestamp | tuiFormatDate | async)\"\n ></span>\n }\n</div>\n<h3\n automation-id=\"tui-push__heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h3>\n<div class=\"t-content\">\n <ng-content />\n</div>\n<div class=\"t-actions\">\n <span class=\"t-button\">\n <ng-content select=\"[tuiButton]\" />\n </span>\n <span class=\"t-link\">\n <ng-content select=\"[tuiLink]\" />\n </span>\n</div>\n", styles: [":host{position:relative;display:block;inline-size:22.5rem;max-inline-size:100%;box-sizing:border-box;padding:1.25rem 1.25rem .25rem;overflow:hidden;font:var(--tui-font-text-m);border-radius:var(--tui-radius-xl);background:var(--tui-background-elevation-2);box-shadow:var(--tui-shadow-small)}.t-image{display:flex;flex-direction:column;max-block-size:10.625rem;overflow:hidden;margin:-1.25rem -1.25rem 1.25rem}.t-close{position:absolute;top:.75rem;right:.75rem;color:#0000008a;background:#f2f2f252;-webkit-backdrop-filter:blur(1rem);backdrop-filter:blur(1rem)}@supports (inset-inline-end: 0){.t-close{right:unset;inset-inline-end:.75rem}}.t-top{display:flex;align-items:center;font:var(--tui-font-text-s);color:var(--tui-text-secondary)}.t-icon{block-size:1.25rem;margin-inline-end:.5rem;transform:scale(.833);transform-origin:top left;color:var(--tui-text-action)}.t-time:before{content:\"\\2022\";display:inline-block;inline-size:1rem;text-align:center}.t-heading{line-height:1.25rem;font-weight:700;margin:.75rem 0 .25rem}.t-heading,.t-content{display:-webkit-box;-webkit-box-orient:block-axis;-webkit-line-clamp:var(--t-lines);word-break:break-word;overflow:hidden}.t-actions{display:flex;align-items:center;font:var(--tui-font-text-s)}.t-button:not(:empty){margin:.75rem .75rem .75rem 0}.t-link{margin:.75rem 0}.t-link:empty{margin:.5rem}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "pipe", type: TuiFormatDatePipe, name: "tuiFormatDate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
32
32
|
}
|
|
33
33
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushComponent, decorators: [{
|
|
34
34
|
type: Component,
|
|
35
35
|
args: [{ selector: 'tui-push', imports: [AsyncPipe, TuiButton, TuiFormatDatePipe], changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiButtonOptionsProvider({ size: 's', appearance: 'secondary' })], host: {
|
|
36
36
|
'[style.--t-lines]': 'lines',
|
|
37
|
-
}, template: "<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord
|
|
37
|
+
}, template: "<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord() }}\n </button>\n}\n<div class=\"t-top\">\n <span class=\"t-icon\">\n <ng-content select=\"tui-icon\" />\n </span>\n {{ type }}\n @if (timestamp) {\n <span\n class=\"t-time\"\n [textContent]=\"isString(timestamp) ? timestamp : (timestamp | tuiFormatDate | async)\"\n ></span>\n }\n</div>\n<h3\n automation-id=\"tui-push__heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h3>\n<div class=\"t-content\">\n <ng-content />\n</div>\n<div class=\"t-actions\">\n <span class=\"t-button\">\n <ng-content select=\"[tuiButton]\" />\n </span>\n <span class=\"t-link\">\n <ng-content select=\"[tuiLink]\" />\n </span>\n</div>\n", styles: [":host{position:relative;display:block;inline-size:22.5rem;max-inline-size:100%;box-sizing:border-box;padding:1.25rem 1.25rem .25rem;overflow:hidden;font:var(--tui-font-text-m);border-radius:var(--tui-radius-xl);background:var(--tui-background-elevation-2);box-shadow:var(--tui-shadow-small)}.t-image{display:flex;flex-direction:column;max-block-size:10.625rem;overflow:hidden;margin:-1.25rem -1.25rem 1.25rem}.t-close{position:absolute;top:.75rem;right:.75rem;color:#0000008a;background:#f2f2f252;-webkit-backdrop-filter:blur(1rem);backdrop-filter:blur(1rem)}@supports (inset-inline-end: 0){.t-close{right:unset;inset-inline-end:.75rem}}.t-top{display:flex;align-items:center;font:var(--tui-font-text-s);color:var(--tui-text-secondary)}.t-icon{block-size:1.25rem;margin-inline-end:.5rem;transform:scale(.833);transform-origin:top left;color:var(--tui-text-action)}.t-time:before{content:\"\\2022\";display:inline-block;inline-size:1rem;text-align:center}.t-heading{line-height:1.25rem;font-weight:700;margin:.75rem 0 .25rem}.t-heading,.t-content{display:-webkit-box;-webkit-box-orient:block-axis;-webkit-line-clamp:var(--t-lines);word-break:break-word;overflow:hidden}.t-actions{display:flex;align-items:center;font:var(--tui-font-text-s)}.t-button:not(:empty){margin:.75rem .75rem .75rem 0}.t-link{margin:.75rem 0}.t-link:empty{margin:.5rem}\n"] }]
|
|
38
38
|
}], propDecorators: { heading: [{
|
|
39
39
|
type: Input
|
|
40
40
|
}], type: [{
|
|
@@ -47,7 +47,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
|
|
|
47
47
|
type: Output
|
|
48
48
|
}] } });
|
|
49
49
|
|
|
50
|
-
const
|
|
50
|
+
const TUI_PUSH_CONCURRENCY = tuiCreateToken(5);
|
|
51
|
+
const [TUI_PUSH_OPTIONS, tuiPushOptionsProvider] = tuiCreateOptions({
|
|
51
52
|
heading: '',
|
|
52
53
|
type: '',
|
|
53
54
|
timestamp: '',
|
|
@@ -55,70 +56,62 @@ const TUI_PUSH_DEFAULT_OPTIONS = {
|
|
|
55
56
|
icon: '',
|
|
56
57
|
iconColor: '',
|
|
57
58
|
buttons: [],
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
* Default parameters for Push component
|
|
61
|
-
*/
|
|
62
|
-
const TUI_PUSH_OPTIONS = new InjectionToken(ngDevMode ? 'TUI_PUSH_OPTIONS' : '', {
|
|
63
|
-
factory: () => TUI_PUSH_DEFAULT_OPTIONS,
|
|
59
|
+
block: 'end',
|
|
60
|
+
inline: 'end',
|
|
64
61
|
});
|
|
65
|
-
function tuiPushOptionsProvider(options) {
|
|
66
|
-
return tuiProvideOptions(TUI_PUSH_OPTIONS, options, TUI_PUSH_DEFAULT_OPTIONS);
|
|
67
|
-
}
|
|
68
62
|
|
|
69
63
|
class TuiPushAlert {
|
|
70
64
|
constructor() {
|
|
71
65
|
this.context = injectContext();
|
|
72
66
|
}
|
|
73
67
|
get isDirective() {
|
|
74
|
-
return this.context.content instanceof
|
|
68
|
+
return this.context.content instanceof TuiPortalDirective;
|
|
75
69
|
}
|
|
76
70
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushAlert, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
77
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPushAlert, isStandalone: true, selector: "
|
|
71
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiPushAlert, isStandalone: true, selector: "tui-push-alert", hostDirectives: [{ directive: i1.TuiAnimated }, { directive: i2.TuiNotificationDirective }], ngImport: i0, template: "<div class=\"t-wrapper\">\n @if (!isDirective) {\n <tui-push\n [heading]=\"context.heading\"\n [timestamp]=\"context.timestamp\"\n [type]=\"context.type\"\n (close)=\"context.$implicit.complete()\"\n >\n @if (context.image) {\n <img\n alt=\"\"\n [src]=\"context.image\"\n />\n }\n @if (context.icon) {\n <tui-icon\n [icon]=\"context.icon\"\n [style.color]=\"context.iconColor\"\n />\n }\n <div\n *polymorpheusOutlet=\"context.content as text; context: context\"\n [innerHTML]=\"text\"\n ></div>\n @if (context.buttons.length > 1) {\n <button\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[0] || '')\"\n >\n {{ context.buttons[0] }}\n </button>\n }\n @if (context.buttons.length) {\n <button\n tuiLink\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[context.buttons.length - 1] || '')\"\n >\n {{ context.buttons[context.buttons.length - 1] }}\n </button>\n }\n </tui-push>\n } @else {\n <ng-container *polymorpheusOutlet=\"context.content\" />\n }\n</div>\n", styles: [":host{max-inline-size:calc(100% - 2rem);margin:.625rem 1rem}\n"], dependencies: [{ kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "directive", type: TuiButton, selector: "a[tuiButton],button[tuiButton],a[tuiIconButton],button[tuiIconButton]", inputs: ["size"] }, { kind: "component", type: TuiIcon, selector: "tui-icon:not([tuiBadge])", inputs: ["background"] }, { kind: "directive", type: TuiLink, selector: "a[tuiLink], button[tuiLink]", inputs: ["pseudo"] }, { kind: "component", type: TuiPushComponent, selector: "tui-push", inputs: ["heading", "type", "lines", "timestamp"], outputs: ["close"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
78
72
|
}
|
|
79
73
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushAlert, decorators: [{
|
|
80
74
|
type: Component,
|
|
81
|
-
args: [{ imports: [PolymorpheusOutlet, TuiButton, TuiIcon, TuiLink, TuiPushComponent], changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiAnimated], host:
|
|
82
|
-
role: 'alert',
|
|
83
|
-
}, template: "<div class=\"t-wrapper\">\n @if (!isDirective) {\n <tui-push\n [heading]=\"context.heading\"\n [timestamp]=\"context.timestamp\"\n [type]=\"context.type\"\n (close)=\"context.$implicit.complete()\"\n >\n @if (context.image) {\n <img\n alt=\"\"\n [src]=\"context.image\"\n />\n }\n @if (context.icon) {\n <tui-icon\n [icon]=\"context.icon\"\n [style.color]=\"context.iconColor\"\n />\n }\n <div\n *polymorpheusOutlet=\"context.content as text; context: context\"\n [innerHTML]=\"text\"\n ></div>\n @if (context.buttons.length > 1) {\n <button\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[0] || '')\"\n >\n {{ context.buttons[0] }}\n </button>\n }\n @if (context.buttons.length) {\n <button\n tuiLink\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[context.buttons.length - 1] || '')\"\n >\n {{ context.buttons[context.buttons.length - 1] }}\n </button>\n }\n </tui-push>\n } @else {\n <ng-container *polymorpheusOutlet=\"context.content\" />\n }\n</div>\n", styles: [":host{position:relative;bottom:1rem;display:grid;flex-shrink:0;max-inline-size:calc(100% - 2rem);margin:0 1rem 0 auto;border-radius:var(--tui-radius-xl);box-shadow:var(--tui-shadow-small);overflow:hidden;--tui-from: translateX(100%)}:host.tui-enter,:host.tui-leave{animation-name:tuiFade,tuiSlide,tuiCollapse}:host.tui-leave:not(:first-child){transition-property:margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;margin-block-start:-1rem!important}:host:first-child{margin-block-start:auto}:host:not(:last-child){transition-property:margin;transition-duration:var(--tui-duration, .3s);transition-timing-function:ease-in-out;margin-block-end:1rem}.t-wrapper{grid-row:1 / span 2;overflow:hidden}\n"] }]
|
|
75
|
+
args: [{ selector: 'tui-push-alert', imports: [PolymorpheusOutlet, TuiButton, TuiIcon, TuiLink, TuiPushComponent], changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [TuiAnimated, TuiNotificationDirective], template: "<div class=\"t-wrapper\">\n @if (!isDirective) {\n <tui-push\n [heading]=\"context.heading\"\n [timestamp]=\"context.timestamp\"\n [type]=\"context.type\"\n (close)=\"context.$implicit.complete()\"\n >\n @if (context.image) {\n <img\n alt=\"\"\n [src]=\"context.image\"\n />\n }\n @if (context.icon) {\n <tui-icon\n [icon]=\"context.icon\"\n [style.color]=\"context.iconColor\"\n />\n }\n <div\n *polymorpheusOutlet=\"context.content as text; context: context\"\n [innerHTML]=\"text\"\n ></div>\n @if (context.buttons.length > 1) {\n <button\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[0] || '')\"\n >\n {{ context.buttons[0] }}\n </button>\n }\n @if (context.buttons.length) {\n <button\n tuiLink\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[context.buttons.length - 1] || '')\"\n >\n {{ context.buttons[context.buttons.length - 1] }}\n </button>\n }\n </tui-push>\n } @else {\n <ng-container *polymorpheusOutlet=\"context.content\" />\n }\n</div>\n", styles: [":host{max-inline-size:calc(100% - 2rem);margin:.625rem 1rem}\n"] }]
|
|
84
76
|
}] });
|
|
85
77
|
|
|
86
|
-
class TuiPushService extends
|
|
87
|
-
|
|
88
|
-
|
|
78
|
+
class TuiPushService extends TuiNotificationService {
|
|
79
|
+
constructor() {
|
|
80
|
+
super(inject(TUI_PUSH_CONCURRENCY));
|
|
81
|
+
this.options = inject(TUI_PUSH_OPTIONS);
|
|
82
|
+
this.component = TuiPushAlert;
|
|
83
|
+
}
|
|
84
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
85
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushService, providedIn: 'root' }); }
|
|
89
86
|
}
|
|
90
87
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushService, decorators: [{
|
|
91
88
|
type: Injectable,
|
|
92
89
|
args: [{
|
|
93
90
|
providedIn: 'root',
|
|
94
|
-
useFactory: () => new TuiPushService(TUI_ALERTS, TuiPushAlert, inject(TUI_PUSH_OPTIONS)),
|
|
95
91
|
}]
|
|
96
|
-
}] });
|
|
92
|
+
}], ctorParameters: () => [] });
|
|
97
93
|
|
|
98
|
-
class TuiPushDirective
|
|
94
|
+
class TuiPushDirective {
|
|
99
95
|
constructor() {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
this.show$ = new Subject();
|
|
103
|
-
this.show$
|
|
104
|
-
.pipe(tuiIfMap(() => this.push.open(this)), takeUntilDestroyed())
|
|
105
|
-
.subscribe();
|
|
106
|
-
}
|
|
107
|
-
set tuiPush(show) {
|
|
108
|
-
this.show$.next(show);
|
|
96
|
+
this.sub = inject(TuiPortalDirective).openChange.subscribe(() => { });
|
|
97
|
+
inject(DestroyRef).onDestroy(() => this.sub.unsubscribe());
|
|
109
98
|
}
|
|
110
99
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
111
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPushDirective, isStandalone: true, selector: "ng-template[tuiPush]",
|
|
100
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.15", type: TuiPushDirective, isStandalone: true, selector: "ng-template[tuiPush]", providers: [tuiAsPortal(TuiPushService)], hostDirectives: [{ directive: i1$1.TuiPortalDirective, inputs: ["open", "tuiPush"] }], ngImport: i0 }); }
|
|
112
101
|
}
|
|
113
102
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiPushDirective, decorators: [{
|
|
114
103
|
type: Directive,
|
|
115
104
|
args: [{
|
|
116
|
-
standalone: true,
|
|
117
105
|
selector: 'ng-template[tuiPush]',
|
|
106
|
+
providers: [tuiAsPortal(TuiPushService)],
|
|
107
|
+
hostDirectives: [
|
|
108
|
+
{
|
|
109
|
+
directive: TuiPortalDirective,
|
|
110
|
+
inputs: ['open: tuiPush'],
|
|
111
|
+
},
|
|
112
|
+
],
|
|
118
113
|
}]
|
|
119
|
-
}], ctorParameters: () => []
|
|
120
|
-
type: Input
|
|
121
|
-
}] } });
|
|
114
|
+
}], ctorParameters: () => [] });
|
|
122
115
|
|
|
123
116
|
const TuiPush = [TuiPushComponent, TuiPushAlert, TuiPushDirective];
|
|
124
117
|
|
|
@@ -126,5 +119,5 @@ const TuiPush = [TuiPushComponent, TuiPushAlert, TuiPushDirective];
|
|
|
126
119
|
* Generated bundle index. Do not edit.
|
|
127
120
|
*/
|
|
128
121
|
|
|
129
|
-
export {
|
|
122
|
+
export { TUI_PUSH_CONCURRENCY, TUI_PUSH_OPTIONS, TuiPush, TuiPushAlert, TuiPushComponent, TuiPushDirective, TuiPushService, tuiPushOptionsProvider };
|
|
130
123
|
//# sourceMappingURL=taiga-ui-kit-components-push.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-push.mjs","sources":["../../../projects/kit/components/push/push.component.ts","../../../projects/kit/components/push/push.template.html","../../../projects/kit/components/push/push.options.ts","../../../projects/kit/components/push/push-alert.component.ts","../../../projects/kit/components/push/push-alert.template.html","../../../projects/kit/components/push/push.service.ts","../../../projects/kit/components/push/push.directive.ts","../../../projects/kit/components/push/push.ts","../../../projects/kit/components/push/taiga-ui-kit-components-push.ts"],"sourcesContent":["import {AsyncPipe} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n inject,\n Input,\n Output,\n} from '@angular/core';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton, tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport {TuiFormatDatePipe} from '@taiga-ui/core/pipes/format-date';\nimport {TUI_CLOSE_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\n\n@Component({\n selector: 'tui-push',\n imports: [AsyncPipe, TuiButton, TuiFormatDatePipe],\n templateUrl: './push.template.html',\n styleUrls: ['./push.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiButtonOptionsProvider({size: 's', appearance: 'secondary'})],\n host: {\n '[style.--t-lines]': 'lines',\n },\n})\nexport class TuiPushComponent {\n protected readonly isString = tuiIsString;\n protected readonly closeWord$ = inject(TUI_CLOSE_WORD);\n protected readonly icons = inject(TUI_COMMON_ICONS);\n\n @Input()\n public heading = '';\n\n @Input()\n public type = '';\n\n @Input()\n public lines = 2;\n\n @Input()\n public timestamp: number | string = '';\n\n @Output()\n public readonly close = new EventEmitter<void>();\n}\n","<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord$ | async }}\n </button>\n}\n<div class=\"t-top\">\n <span class=\"t-icon\">\n <ng-content select=\"tui-svg,tui-icon\" />\n </span>\n {{ type }}\n @if (timestamp) {\n <span\n class=\"t-time\"\n [textContent]=\"isString(timestamp) ? timestamp : (timestamp | tuiFormatDate | async)\"\n ></span>\n }\n</div>\n<h3\n automation-id=\"tui-push__heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h3>\n<div class=\"t-content\">\n <ng-content />\n</div>\n<div class=\"t-actions\">\n <span class=\"t-button\">\n <ng-content select=\"[tuiButton]\" />\n </span>\n <span class=\"t-link\">\n <ng-content select=\"[tuiLink]\" />\n </span>\n</div>\n","import {InjectionToken, type Provider} from '@angular/core';\nimport {tuiProvideOptions} from '@taiga-ui/cdk/utils/miscellaneous';\n\nexport interface TuiPushOptions {\n readonly buttons: readonly string[];\n readonly heading: string;\n readonly icon: string;\n readonly iconColor: string;\n readonly image: string;\n readonly timestamp: number | string;\n readonly type: string;\n}\n\nexport const TUI_PUSH_DEFAULT_OPTIONS: TuiPushOptions = {\n heading: '',\n type: '',\n timestamp: '',\n image: '',\n icon: '',\n iconColor: '',\n buttons: [],\n};\n\n/**\n * Default parameters for Push component\n */\nexport const TUI_PUSH_OPTIONS = new InjectionToken(ngDevMode ? 'TUI_PUSH_OPTIONS' : '', {\n factory: () => TUI_PUSH_DEFAULT_OPTIONS,\n});\n\nexport function tuiPushOptionsProvider(options: Partial<TuiPushOptions>): Provider {\n return tuiProvideOptions(TUI_PUSH_OPTIONS, options, TUI_PUSH_DEFAULT_OPTIONS);\n}\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPopover} from '@taiga-ui/cdk/services';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiIcon} from '@taiga-ui/core/components/icon';\nimport {TuiLink} from '@taiga-ui/core/components/link';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TuiPushComponent} from './push.component';\nimport {TuiPushDirective} from './push.directive';\nimport {type TuiPushOptions} from './push.options';\n\n@Component({\n imports: [PolymorpheusOutlet, TuiButton, TuiIcon, TuiLink, TuiPushComponent],\n templateUrl: './push-alert.template.html',\n styleUrls: ['./push-alert.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated],\n host: {\n role: 'alert',\n },\n})\nexport class TuiPushAlert {\n protected readonly context = injectContext<TuiPopover<TuiPushOptions, string>>();\n\n protected get isDirective(): boolean {\n return this.context.content instanceof TuiPushDirective;\n }\n}\n","<div class=\"t-wrapper\">\n @if (!isDirective) {\n <tui-push\n [heading]=\"context.heading\"\n [timestamp]=\"context.timestamp\"\n [type]=\"context.type\"\n (close)=\"context.$implicit.complete()\"\n >\n @if (context.image) {\n <img\n alt=\"\"\n [src]=\"context.image\"\n />\n }\n @if (context.icon) {\n <tui-icon\n [icon]=\"context.icon\"\n [style.color]=\"context.iconColor\"\n />\n }\n <div\n *polymorpheusOutlet=\"context.content as text; context: context\"\n [innerHTML]=\"text\"\n ></div>\n @if (context.buttons.length > 1) {\n <button\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[0] || '')\"\n >\n {{ context.buttons[0] }}\n </button>\n }\n @if (context.buttons.length) {\n <button\n tuiLink\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[context.buttons.length - 1] || '')\"\n >\n {{ context.buttons[context.buttons.length - 1] }}\n </button>\n }\n </tui-push>\n } @else {\n <ng-container *polymorpheusOutlet=\"context.content\" />\n }\n</div>\n","import {inject, Injectable} from '@angular/core';\nimport {TuiPopoverService} from '@taiga-ui/cdk/services';\nimport {TUI_ALERTS} from '@taiga-ui/core/components/alert';\n\nimport {TUI_PUSH_OPTIONS, type TuiPushOptions} from './push.options';\nimport {TuiPushAlert} from './push-alert.component';\n\n@Injectable({\n providedIn: 'root',\n useFactory: () =>\n new TuiPushService(TUI_ALERTS, TuiPushAlert, inject(TUI_PUSH_OPTIONS)),\n})\nexport class TuiPushService extends TuiPopoverService<TuiPushOptions, string> {}\n","import {\n ChangeDetectorRef,\n Directive,\n forwardRef,\n inject,\n Input,\n TemplateRef,\n} from '@angular/core';\nimport {takeUntilDestroyed} from '@angular/core/rxjs-interop';\nimport {tuiIfMap} from '@taiga-ui/cdk/observables';\nimport {PolymorpheusTemplate} from '@taiga-ui/polymorpheus';\nimport {Subject} from 'rxjs';\n\nimport {TuiPushService} from './push.service';\n\n@Directive({\n standalone: true,\n selector: 'ng-template[tuiPush]',\n})\nexport class TuiPushDirective extends PolymorpheusTemplate {\n private readonly push: TuiPushService = inject(forwardRef(() => TuiPushService));\n private readonly show$ = new Subject<boolean>();\n\n constructor() {\n super(inject(TemplateRef), inject(ChangeDetectorRef));\n\n this.show$\n .pipe(\n tuiIfMap(() => this.push.open(this)),\n takeUntilDestroyed(),\n )\n .subscribe();\n }\n\n @Input()\n public set tuiPush(show: boolean) {\n this.show$.next(show);\n }\n}\n","import {TuiPushComponent} from './push.component';\nimport {TuiPushDirective} from './push.directive';\nimport {TuiPushAlert} from './push-alert.component';\n\nexport const TuiPush = [TuiPushComponent, TuiPushAlert, TuiPushDirective] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;MAyBa,gBAAgB,CAAA;AAX7B,IAAA,WAAA,GAAA;QAYuB,IAAQ,CAAA,QAAA,GAAG,WAAW;AACtB,QAAA,IAAA,CAAA,UAAU,GAAG,MAAM,CAAC,cAAc,CAAC;AACnC,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM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;AACA,aAAA,IAAI,CACD,QAAQ,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,EACpC,kBAAkB,EAAE;AAEvB,aAAA,SAAS,EAAE;;IAGpB,IACW,OAAO,CAAC,IAAa,EAAA;AAC5B,QAAA,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC;;+GAjBhB,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAhB,gBAAgB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,sBAAA,EAAA,MAAA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAAhB,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAJ5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,sBAAsB;AACnC,iBAAA;wDAiBc,OAAO,EAAA,CAAA;sBADjB;;;AC9BQ,MAAA,OAAO,GAAG,CAAC,gBAAgB,EAAE,YAAY,EAAE,gBAAgB;;ACJxE;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-push.mjs","sources":["../../../projects/kit/components/push/push.component.ts","../../../projects/kit/components/push/push.template.html","../../../projects/kit/components/push/push.options.ts","../../../projects/kit/components/push/push-alert.component.ts","../../../projects/kit/components/push/push-alert.template.html","../../../projects/kit/components/push/push.service.ts","../../../projects/kit/components/push/push.directive.ts","../../../projects/kit/components/push/push.ts","../../../projects/kit/components/push/taiga-ui-kit-components-push.ts"],"sourcesContent":["import {AsyncPipe} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n inject,\n Input,\n Output,\n} from '@angular/core';\nimport {tuiIsString} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {TuiButton, tuiButtonOptionsProvider} from '@taiga-ui/core/components/button';\nimport {TuiFormatDatePipe} from '@taiga-ui/core/pipes/format-date';\nimport {TUI_CLOSE_WORD, TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\n\n@Component({\n selector: 'tui-push',\n imports: [AsyncPipe, TuiButton, TuiFormatDatePipe],\n templateUrl: './push.template.html',\n styleUrl: './push.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiButtonOptionsProvider({size: 's', appearance: 'secondary'})],\n host: {\n '[style.--t-lines]': 'lines',\n },\n})\nexport class TuiPushComponent {\n protected readonly isString = tuiIsString;\n protected readonly closeWord = inject(TUI_CLOSE_WORD);\n protected readonly icons = inject(TUI_COMMON_ICONS);\n\n @Input()\n public heading = '';\n\n @Input()\n public type = '';\n\n @Input()\n public lines = 2;\n\n @Input()\n public timestamp: number | string = '';\n\n @Output()\n public readonly close = new EventEmitter<void>();\n}\n","<div class=\"t-image\">\n <ng-content select=\"img\" />\n</div>\n@if (close.observed) {\n <button\n appearance=\"\"\n size=\"xs\"\n tuiIconButton\n type=\"button\"\n class=\"t-close\"\n [iconStart]=\"icons.close\"\n [style.border-radius.%]=\"100\"\n (click)=\"close.emit()\"\n >\n {{ closeWord() }}\n </button>\n}\n<div class=\"t-top\">\n <span class=\"t-icon\">\n <ng-content select=\"tui-icon\" />\n </span>\n {{ type }}\n @if (timestamp) {\n <span\n class=\"t-time\"\n [textContent]=\"isString(timestamp) ? timestamp : (timestamp | tuiFormatDate | async)\"\n ></span>\n }\n</div>\n<h3\n automation-id=\"tui-push__heading\"\n class=\"t-heading\"\n>\n {{ heading }}\n</h3>\n<div class=\"t-content\">\n <ng-content />\n</div>\n<div class=\"t-actions\">\n <span class=\"t-button\">\n <ng-content select=\"[tuiButton]\" />\n </span>\n <span class=\"t-link\">\n <ng-content select=\"[tuiLink]\" />\n </span>\n</div>\n","import {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {tuiCreateToken} from '@taiga-ui/cdk/utils/miscellaneous';\nimport {type TuiPositionOptions} from '@taiga-ui/core/directives/notification';\n\nexport interface TuiPushOptions extends TuiPositionOptions {\n readonly buttons: readonly string[];\n readonly heading: string;\n readonly icon: string;\n readonly iconColor: string;\n readonly image: string;\n readonly timestamp: number | string;\n readonly type: string;\n}\n\nexport const TUI_PUSH_CONCURRENCY = tuiCreateToken<number>(5);\nexport const [TUI_PUSH_OPTIONS, tuiPushOptionsProvider] =\n tuiCreateOptions<TuiPushOptions>({\n heading: '',\n type: '',\n timestamp: '',\n image: '',\n icon: '',\n iconColor: '',\n buttons: [],\n block: 'end',\n inline: 'end',\n });\n","import {ChangeDetectionStrategy, Component} from '@angular/core';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext, TuiPortalDirective} from '@taiga-ui/cdk/portals';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TuiIcon} from '@taiga-ui/core/components/icon';\nimport {TuiLink} from '@taiga-ui/core/components/link';\nimport {TuiNotificationDirective} from '@taiga-ui/core/directives/notification';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TuiPushComponent} from './push.component';\nimport {type TuiPushOptions} from './push.options';\n\n@Component({\n selector: 'tui-push-alert',\n imports: [PolymorpheusOutlet, TuiButton, TuiIcon, TuiLink, TuiPushComponent],\n templateUrl: './push-alert.template.html',\n styleUrl: './push-alert.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [TuiAnimated, TuiNotificationDirective],\n})\nexport class TuiPushAlert {\n protected readonly context =\n injectContext<TuiPortalContext<TuiPushOptions, string>>();\n\n protected get isDirective(): boolean {\n return this.context.content instanceof TuiPortalDirective;\n }\n}\n","<div class=\"t-wrapper\">\n @if (!isDirective) {\n <tui-push\n [heading]=\"context.heading\"\n [timestamp]=\"context.timestamp\"\n [type]=\"context.type\"\n (close)=\"context.$implicit.complete()\"\n >\n @if (context.image) {\n <img\n alt=\"\"\n [src]=\"context.image\"\n />\n }\n @if (context.icon) {\n <tui-icon\n [icon]=\"context.icon\"\n [style.color]=\"context.iconColor\"\n />\n }\n <div\n *polymorpheusOutlet=\"context.content as text; context: context\"\n [innerHTML]=\"text\"\n ></div>\n @if (context.buttons.length > 1) {\n <button\n tuiButton\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[0] || '')\"\n >\n {{ context.buttons[0] }}\n </button>\n }\n @if (context.buttons.length) {\n <button\n tuiLink\n type=\"button\"\n (click)=\"context.$implicit.next(context.buttons[context.buttons.length - 1] || '')\"\n >\n {{ context.buttons[context.buttons.length - 1] }}\n </button>\n }\n </tui-push>\n } @else {\n <ng-container *polymorpheusOutlet=\"context.content\" />\n }\n</div>\n","import {inject, Injectable} from '@angular/core';\nimport {TuiNotificationService} from '@taiga-ui/core/directives/notification';\n\nimport {\n TUI_PUSH_CONCURRENCY,\n TUI_PUSH_OPTIONS,\n type TuiPushOptions,\n} from './push.options';\nimport {TuiPushAlert} from './push-alert.component';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class TuiPushService extends TuiNotificationService<TuiPushOptions, string> {\n protected override readonly options = inject(TUI_PUSH_OPTIONS);\n protected override readonly component = TuiPushAlert;\n\n constructor() {\n super(inject(TUI_PUSH_CONCURRENCY));\n }\n}\n","import {DestroyRef, Directive, inject} from '@angular/core';\nimport {tuiAsPortal, TuiPortalDirective} from '@taiga-ui/cdk/portals';\n\nimport {TuiPushService} from './push.service';\n\n@Directive({\n selector: 'ng-template[tuiPush]',\n providers: [tuiAsPortal(TuiPushService)],\n hostDirectives: [\n {\n directive: TuiPortalDirective,\n inputs: ['open: tuiPush'],\n },\n ],\n})\nexport class TuiPushDirective {\n private readonly sub = inject(TuiPortalDirective).openChange.subscribe(() => {});\n\n constructor() {\n inject(DestroyRef).onDestroy(() => this.sub.unsubscribe());\n }\n}\n","import {TuiPushComponent} from './push.component';\nimport {TuiPushDirective} from './push.directive';\nimport {TuiPushAlert} from './push-alert.component';\n\nexport const TuiPush = [TuiPushComponent, TuiPushAlert, TuiPushDirective] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;MAyBa,gBAAgB,CAAA;AAX7B,IAAA,WAAA,GAAA;QAYuB,IAAQ,CAAA,QAAA,GAAG,WAAW;AACtB,QAAA,IAAA,CAAA,SAAS,GAAG,MAAM,CAAC,cAAc,CAAC;AAClC,QAAA,IAAA,CAAA,KAAK,GAAG,MAAM,CAAC,gBAAgB,CAAC;QAG5C,IAAO,CAAA,OAAA,GAAG,EAAE;QAGZ,IAAI,CAAA,IAAA,GAAG,EAAE;QAGT,IAAK,CAAA,KAAA,GAAG,CAAC;QAGT,IAAS,CAAA,SAAA,GAAoB,EAAE;AAGtB,QAAA,IAAA,CAAA,KAAK,GAAG,IAAI,YAAY,EAAQ;AACnD;+GAnBY,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;mGAAhB,gBAAgB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,UAAA,EAAA,MAAA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,MAAA,EAAA,KAAA,EAAA,OAAA,EAAA,SAAA,EAAA,WAAA,EAAA,EAAA,OAAA,EAAA,EAAA,KAAA,EAAA,OAAA,EAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,iBAAA,EAAA,OAAA,EAAA,EAAA,EAAA,SAAA,EALd,CAAC,wBAAwB,CAAC,EAAC,IAAI,EAAE,GAAG,EAAE,UAAU,EAAE,WAAW,EAAC,CAAC,CAAC,ECpB/E,QAAA,EAAA,EAAA,EAAA,QAAA,EAAA,+jCA8CA,q3CD9Bc,SAAS,EAAA,IAAA,EAAA,OAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA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AC,UAAU,CAAC,CAAC,SAAS,CAAC,MAAM,IAAI,CAAC,GAAG,CAAC,WAAW,EAAE,CAAC;;+GAJrD,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAhB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,gBAAgB,mEARd,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC,EAAA,cAAA,EAAA,CAAA,EAAA,SAAA,EAAAA,IAAA,CAAA,kBAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,SAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAQ/B,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAV5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,sBAAsB;AAChC,oBAAA,SAAS,EAAE,CAAC,WAAW,CAAC,cAAc,CAAC,CAAC;AACxC,oBAAA,cAAc,EAAE;AACZ,wBAAA;AACI,4BAAA,SAAS,EAAE,kBAAkB;4BAC7B,MAAM,EAAE,CAAC,eAAe,CAAC;AAC5B,yBAAA;AACJ,qBAAA;AACJ,iBAAA;;;ACVY,MAAA,OAAO,GAAG,CAAC,gBAAgB,EAAE,YAAY,EAAE,gBAAgB;;ACJxE;;AAEG;;;;"}
|
|
@@ -38,14 +38,14 @@ class TuiRadioList extends TuiControl {
|
|
|
38
38
|
: this.identityMatcher(this.value(), item);
|
|
39
39
|
}
|
|
40
40
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiRadioList, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
41
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiRadioList, isStandalone: true, selector: "tui-radio-list", inputs: { items: "items", size: "size", identityMatcher: "identityMatcher", disabledItemHandler: "disabledItemHandler", itemContent: "itemContent" }, host: { listeners: { "focusout": "onFocusOut()" }, properties: { "attr.data-size": "size" } }, providers: [tuiAsControl(TuiRadioList)], viewQueries: [{ propertyName: "controls", predicate: NgControl, descendants: true }], usesInheritance: true, ngImport: i0, template: "@for (item of items; track item
|
|
41
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.15", type: TuiRadioList, isStandalone: true, selector: "tui-radio-list", inputs: { items: "items", size: "size", identityMatcher: "identityMatcher", disabledItemHandler: "disabledItemHandler", itemContent: "itemContent" }, host: { listeners: { "focusout": "onFocusOut()" }, properties: { "attr.data-size": "size" } }, providers: [tuiAsControl(TuiRadioList)], viewQueries: [{ propertyName: "controls", predicate: NgControl, descendants: true }], usesInheritance: true, ngImport: i0, template: "@for (item of items; track item) {\n <label\n class=\"t-item\"\n [class.t-item_disabled]=\"disabled() || disabledItemHandler(item)\"\n >\n <input\n tuiRadio\n type=\"radio\"\n [disabled]=\"disabled() || disabledItemHandler(item)\"\n [identityMatcher]=\"identityMatcher\"\n [name]=\"name\"\n [ngModel]=\"value()\"\n [ngModelOptions]=\"{standalone: true}\"\n [size]=\"size\"\n [tuiValidator]=\"validator()\"\n [value]=\"item\"\n (ngModelChange)=\"onChange($event)\"\n />\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: {$implicit: item, active: itemIsActive(item)}\">\n {{ text }}\n </ng-container>\n </label>\n}\n", styles: ["tui-radio-list{display:flex;flex-direction:column;align-items:flex-start;gap:.75rem 1.5rem;font:var(--tui-font-text-m)}tui-radio-list[data-size=s],tui-radio-list[data-size=s] [tuiTitle]{font:var(--tui-font-text-ui-s)}tui-radio-list[data-size=s] [tuiSubtitle],tui-radio-list[data-size=s] [tuiTitle] [tuiSubtitle]{font:var(--tui-font-text-xs)}tui-radio-list[data-size=s]>.t-item,tui-radio-list[data-size=s] [tuiTitle]>.t-item{gap:.5rem}tui-radio-list [tuiTitle]{font:var(--tui-font-text-m)}tui-radio-list [tuiSubtitle]{color:var(--tui-text-tertiary)}tui-radio-list>.t-item{display:flex;gap:.75rem}tui-radio-list>.t-item_disabled{opacity:var(--tui-disabled-opacity)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: PolymorpheusOutlet, selector: "[polymorpheusOutlet]", inputs: ["polymorpheusOutlet", "polymorpheusOutletContext"] }, { kind: "component", type: i2.TuiRadioComponent, selector: "input[type=\"radio\"][tuiRadio]", inputs: ["size"] }, { kind: "directive", type: i2.TuiRadioDirective, selector: "input[type=\"radio\"][tuiRadio][identityMatcher]", inputs: ["identityMatcher"] }, { kind: "directive", type: TuiValidator, selector: "[tuiValidator]", inputs: ["tuiValidator"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
42
42
|
}
|
|
43
43
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImport: i0, type: TuiRadioList, decorators: [{
|
|
44
44
|
type: Component,
|
|
45
45
|
args: [{ selector: 'tui-radio-list', imports: [FormsModule, PolymorpheusOutlet, TuiRadio, TuiValidator], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [tuiAsControl(TuiRadioList)], host: {
|
|
46
46
|
'[attr.data-size]': 'size',
|
|
47
47
|
'(focusout)': 'onFocusOut()',
|
|
48
|
-
}, template: "@for (item of items; track item
|
|
48
|
+
}, template: "@for (item of items; track item) {\n <label\n class=\"t-item\"\n [class.t-item_disabled]=\"disabled() || disabledItemHandler(item)\"\n >\n <input\n tuiRadio\n type=\"radio\"\n [disabled]=\"disabled() || disabledItemHandler(item)\"\n [identityMatcher]=\"identityMatcher\"\n [name]=\"name\"\n [ngModel]=\"value()\"\n [ngModelOptions]=\"{standalone: true}\"\n [size]=\"size\"\n [tuiValidator]=\"validator()\"\n [value]=\"item\"\n (ngModelChange)=\"onChange($event)\"\n />\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: {$implicit: item, active: itemIsActive(item)}\">\n {{ text }}\n </ng-container>\n </label>\n}\n", styles: ["tui-radio-list{display:flex;flex-direction:column;align-items:flex-start;gap:.75rem 1.5rem;font:var(--tui-font-text-m)}tui-radio-list[data-size=s],tui-radio-list[data-size=s] [tuiTitle]{font:var(--tui-font-text-ui-s)}tui-radio-list[data-size=s] [tuiSubtitle],tui-radio-list[data-size=s] [tuiTitle] [tuiSubtitle]{font:var(--tui-font-text-xs)}tui-radio-list[data-size=s]>.t-item,tui-radio-list[data-size=s] [tuiTitle]>.t-item{gap:.5rem}tui-radio-list [tuiTitle]{font:var(--tui-font-text-m)}tui-radio-list [tuiSubtitle]{color:var(--tui-text-tertiary)}tui-radio-list>.t-item{display:flex;gap:.75rem}tui-radio-list>.t-item_disabled{opacity:var(--tui-disabled-opacity)}\n"] }]
|
|
49
49
|
}], propDecorators: { controls: [{
|
|
50
50
|
type: ViewChildren,
|
|
51
51
|
args: [NgControl]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-radio-list.mjs","sources":["../../../projects/kit/components/radio-list/radio-list.component.ts","../../../projects/kit/components/radio-list/radio-list.template.html","../../../projects/kit/components/radio-list/taiga-ui-kit-components-radio-list.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n computed,\n inject,\n Input,\n type QueryList,\n ViewChildren,\n ViewEncapsulation,\n} from '@angular/core';\nimport {FormsModule, NgControl, type ValidatorFn, Validators} from '@angular/forms';\nimport {tuiAsControl, TuiControl} from '@taiga-ui/cdk/classes';\nimport {\n EMPTY_QUERY,\n TUI_DEFAULT_IDENTITY_MATCHER,\n TUI_FALSE_HANDLER,\n} from '@taiga-ui/cdk/constants';\nimport {TuiValidator} from '@taiga-ui/cdk/directives/validator';\nimport {TuiIdService} from '@taiga-ui/cdk/services';\nimport {type TuiBooleanHandler, type TuiIdentityMatcher} from '@taiga-ui/cdk/types';\nimport {type TuiSizeS, type TuiValueContentContext} from '@taiga-ui/core/types';\nimport {TuiRadio} from '@taiga-ui/kit/components/radio';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nconst ERROR: ValidatorFn = () => ({error: 'Invalid'});\n\n@Component({\n selector: 'tui-radio-list',\n imports: [FormsModule, PolymorpheusOutlet, TuiRadio, TuiValidator],\n templateUrl: './radio-list.template.html',\n
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-radio-list.mjs","sources":["../../../projects/kit/components/radio-list/radio-list.component.ts","../../../projects/kit/components/radio-list/radio-list.template.html","../../../projects/kit/components/radio-list/taiga-ui-kit-components-radio-list.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n computed,\n inject,\n Input,\n type QueryList,\n ViewChildren,\n ViewEncapsulation,\n} from '@angular/core';\nimport {FormsModule, NgControl, type ValidatorFn, Validators} from '@angular/forms';\nimport {tuiAsControl, TuiControl} from '@taiga-ui/cdk/classes';\nimport {\n EMPTY_QUERY,\n TUI_DEFAULT_IDENTITY_MATCHER,\n TUI_FALSE_HANDLER,\n} from '@taiga-ui/cdk/constants';\nimport {TuiValidator} from '@taiga-ui/cdk/directives/validator';\nimport {TuiIdService} from '@taiga-ui/cdk/services';\nimport {type TuiBooleanHandler, type TuiIdentityMatcher} from '@taiga-ui/cdk/types';\nimport {type TuiSizeS, type TuiValueContentContext} from '@taiga-ui/core/types';\nimport {TuiRadio} from '@taiga-ui/kit/components/radio';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nconst ERROR: ValidatorFn = () => ({error: 'Invalid'});\n\n@Component({\n selector: 'tui-radio-list',\n imports: [FormsModule, PolymorpheusOutlet, TuiRadio, TuiValidator],\n templateUrl: './radio-list.template.html',\n styleUrl: './radio-list.style.less',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiAsControl(TuiRadioList)],\n host: {\n '[attr.data-size]': 'size',\n '(focusout)': 'onFocusOut()',\n },\n})\nexport class TuiRadioList<T> extends TuiControl<T> {\n @ViewChildren(NgControl)\n private readonly controls: QueryList<NgControl> = EMPTY_QUERY;\n\n private readonly id = inject(TuiIdService).generate();\n\n protected validator = computed(() =>\n this.invalid() ? ERROR : Validators.nullValidator,\n );\n\n @Input()\n public items: readonly T[] = [];\n\n @Input()\n public size: TuiSizeS = 'm';\n\n @Input()\n public identityMatcher: TuiIdentityMatcher<T> = TUI_DEFAULT_IDENTITY_MATCHER;\n\n @Input()\n public disabledItemHandler: TuiBooleanHandler<T> = TUI_FALSE_HANDLER;\n\n @Input()\n public itemContent: PolymorpheusContent<TuiValueContentContext<T>> = ({$implicit}) =>\n String($implicit);\n\n protected get name(): string {\n return `${this.control.name}-${this.id}`;\n }\n\n protected onFocusOut(): void {\n this.controls.forEach((control) => control.control?.markAsTouched());\n\n if (!this.touched()) {\n this.onTouched();\n }\n }\n\n protected itemIsActive(item: T): boolean {\n return this.value() === null\n ? item === null\n : this.identityMatcher(this.value(), item);\n }\n}\n","@for (item of items; track item) {\n <label\n class=\"t-item\"\n [class.t-item_disabled]=\"disabled() || disabledItemHandler(item)\"\n >\n <input\n tuiRadio\n type=\"radio\"\n [disabled]=\"disabled() || disabledItemHandler(item)\"\n [identityMatcher]=\"identityMatcher\"\n [name]=\"name\"\n [ngModel]=\"value()\"\n [ngModelOptions]=\"{standalone: true}\"\n [size]=\"size\"\n [tuiValidator]=\"validator()\"\n [value]=\"item\"\n (ngModelChange)=\"onChange($event)\"\n />\n <ng-container *polymorpheusOutlet=\"itemContent as text; context: {$implicit: item, active: itemIsActive(item)}\">\n {{ text }}\n </ng-container>\n </label>\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAwBA,MAAM,KAAK,GAAgB,OAAO,EAAC,KAAK,EAAE,SAAS,EAAC,CAAC;AAe/C,MAAO,YAAgB,SAAQ,UAAa,CAAA;AAblD,IAAA,WAAA,GAAA;;QAeqB,IAAQ,CAAA,QAAA,GAAyB,WAAW;QAE5C,IAAE,CAAA,EAAA,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC,QAAQ,EAAE;QAE3C,IAAS,CAAA,SAAA,GAAG,QAAQ,CAAC,MAC3B,IAAI,CAAC,OAAO,EAAE,GAAG,KAAK,GAAG,UAAU,CAAC,aAAa,CACpD;QAGM,IAAK,CAAA,KAAA,GAAiB,EAAE;QAGxB,IAAI,CAAA,IAAA,GAAa,GAAG;QAGpB,IAAe,CAAA,eAAA,GAA0B,4BAA4B;QAGrE,IAAmB,CAAA,mBAAA,GAAyB,iBAAiB;AAG7D,QAAA,IAAA,CAAA,WAAW,GAAmD,CAAC,EAAC,SAAS,EAAC,KAC7E,MAAM,CAAC,SAAS,CAAC;AAmBxB;AAjBG,IAAA,IAAc,IAAI,GAAA;QACd,OAAO,CAAA,EAAG,IAAI,CAAC,OAAO,CAAC,IAAI,CAAA,CAAA,EAAI,IAAI,CAAC,EAAE,CAAA,CAAE;;IAGlC,UAAU,GAAA;AAChB,QAAA,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC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