@taiga-ui/kit 4.52.0-canary.ec0802b → 4.52.0-canary.efbd0d4
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/avatar/avatar-labeled.component.d.ts +3 -3
- package/components/avatar/avatar-stack.component.d.ts +2 -2
- package/components/badge-notification/badge-notification.component.d.ts +2 -3
- package/components/badged-content/badged-content.directive.d.ts +2 -2
- package/components/breadcrumbs/breadcrumbs.component.d.ts +6 -7
- package/components/button-loading/button-loading.component.d.ts +5 -5
- package/components/calendar-range/calendar-range.component.d.ts +0 -1
- package/components/calendar-range/day-range-period.d.ts +2 -1
- package/components/carousel/carousel.component.d.ts +15 -18
- package/components/carousel/carousel.directive.d.ts +5 -4
- package/components/combo-box/combo-box.d.ts +5 -0
- package/components/combo-box/combo-box.directive.d.ts +7 -9
- package/components/combo-box/index.d.ts +1 -0
- package/components/compass/compass.component.d.ts +2 -2
- package/components/confirm/confirm.component.d.ts +3 -2
- package/components/confirm/confirm.service.d.ts +1 -1
- package/components/copy/copy.component.d.ts +2 -3
- package/components/copy/copy.directive.d.ts +2 -4
- package/components/data-list-wrapper/data-list-group-wrapper.component.d.ts +2 -2
- package/components/data-list-wrapper/data-list-wrapper.component.d.ts +14 -22
- package/components/data-list-wrapper/{data-list-wrapper.module.d.ts → data-list-wrapper.d.ts} +1 -2
- package/components/data-list-wrapper/index.d.ts +1 -1
- package/components/drawer/drawer.component.d.ts +3 -4
- package/components/files/file/file.component.d.ts +16 -29
- package/components/files/files/files.component.d.ts +5 -8
- package/components/files/input-files/input-files.component.d.ts +2 -2
- package/components/files/input-files/input-files.content.d.ts +7 -8
- package/components/files/input-files/input-files.directive.d.ts +2 -2
- package/components/filter/filter.component.d.ts +9 -11
- package/components/fullscreen/fullscreen.component.d.ts +5 -8
- package/components/index.d.ts +0 -3
- package/components/input-chip/input-chip.component.d.ts +9 -8
- package/components/input-chip/input-chip.d.ts +5 -1
- package/components/input-chip/input-chip.directive.d.ts +7 -12
- package/components/input-color/index.d.ts +1 -0
- package/components/input-color/input-color.component.d.ts +4 -4
- package/components/input-color/input-color.d.ts +5 -0
- package/components/input-date/input-date.d.ts +4 -1
- package/components/input-date/input-date.directive.d.ts +12 -14
- package/components/input-date/input-date.options.d.ts +3 -3
- package/components/input-date-multi/input-date-multi.d.ts +1 -2
- package/components/input-date-multi/input-date-multi.directive.d.ts +10 -14
- package/components/input-date-range/input-date-range.d.ts +4 -1
- package/components/input-date-range/input-date-range.directive.d.ts +5 -8
- package/components/input-date-range/input-date-range.options.d.ts +2 -2
- package/components/input-date-time/input-date-time.d.ts +4 -1
- package/components/input-date-time/input-date-time.directive.d.ts +6 -6
- package/components/input-date-time/input-date-time.options.d.ts +2 -2
- package/components/input-month/input-month.d.ts +4 -1
- package/components/input-month/input-month.directive.d.ts +6 -5
- package/components/input-month-range/input-month-range.d.ts +4 -1
- package/components/input-month-range/input-month-range.directive.d.ts +6 -5
- package/components/input-number/input-number.d.ts +4 -1
- package/components/input-number/input-number.directive.d.ts +5 -7
- package/components/input-number/input-number.options.d.ts +2 -3
- package/components/input-number/step/input-number-step.component.d.ts +2 -1
- package/components/input-phone/index.d.ts +1 -0
- package/components/input-phone/input-phone.d.ts +5 -0
- package/components/input-phone/input-phone.directive.d.ts +7 -7
- package/components/input-phone-international/index.d.ts +1 -0
- package/components/input-phone-international/input-phone-international.component.d.ts +9 -8
- package/components/input-phone-international/input-phone-international.d.ts +5 -0
- package/components/input-pin/index.d.ts +1 -0
- package/components/input-pin/input-pin.component.d.ts +3 -3
- package/components/input-pin/input-pin.d.ts +5 -0
- package/components/input-range/index.d.ts +0 -1
- package/components/input-range/input-range.component.d.ts +4 -3
- package/components/input-slider/input-slider.d.ts +4 -1
- package/components/input-slider/input-slider.directive.d.ts +1 -1
- package/components/input-time/input-time.component.d.ts +1 -3
- package/components/input-time/input-time.d.ts +4 -1
- package/components/input-time/input-time.directive.d.ts +4 -4
- package/components/input-year/input-year.d.ts +4 -1
- package/components/input-year/input-year.directive.d.ts +5 -5
- package/components/input-year/input-year.options.d.ts +2 -2
- package/components/like/like.options.d.ts +1 -1
- package/components/line-clamp/line-clamp-box.component.d.ts +1 -1
- package/components/multi-select/multi-select-group/multi-select-group.component.d.ts +4 -6
- package/components/notification-middle/notification-middle.service.d.ts +1 -1
- package/components/pagination/pagination.component.d.ts +22 -52
- package/components/pagination/pagination.options.d.ts +3 -6
- package/components/preview/dialog/preview-dialog.service.d.ts +1 -1
- package/components/preview/index.d.ts +1 -0
- package/components/preview/pagination/preview-pagination.component.d.ts +2 -1
- package/components/preview/preview.component.d.ts +1 -1
- package/components/preview/zoom/preview-zoom.component.d.ts +3 -1
- package/components/progress/progress-bar/progress-bar.component.d.ts +3 -4
- package/components/pulse/pulse.component.d.ts +2 -2
- package/components/push/push-alert.component.d.ts +1 -1
- package/components/push/push.options.d.ts +4 -3
- package/components/push/push.service.d.ts +1 -1
- package/components/radio/radio.component.d.ts +1 -1
- package/components/radio-list/radio-list.component.d.ts +5 -3
- package/components/rating/rating.component.d.ts +1 -1
- package/components/routable-dialog/generate-dialogable-route.d.ts +1 -1
- package/components/segmented/segmented.component.d.ts +4 -6
- package/components/segmented/segmented.directive.d.ts +6 -7
- package/components/select/native-select/native-select.component.d.ts +4 -4
- package/components/select/select.d.ts +4 -1
- package/components/select/select.directive.d.ts +4 -3
- package/components/switch/switch.component.d.ts +1 -0
- package/components/textarea/index.d.ts +2 -1
- package/components/textarea/textarea.component.d.ts +4 -4
- package/components/textarea/textarea.d.ts +6 -0
- package/components/textarea/textarea.directive.d.ts +13 -0
- package/components/toast/toast.component.d.ts +1 -1
- package/components/toast/toast.options.d.ts +4 -3
- package/components/toast/toast.service.d.ts +1 -1
- package/directives/appearance-proxy/appearance-proxy.directive.d.ts +10 -0
- package/directives/appearance-proxy/index.d.ts +1 -0
- package/directives/button-select/button-select.directive.d.ts +1 -1
- package/directives/data-list-dropdown-manager/data-list-dropdown-manager.directive.d.ts +5 -5
- package/directives/fade/fade.directive.d.ts +5 -6
- package/directives/highlight/highlight.directive.d.ts +4 -4
- package/directives/index.d.ts +1 -1
- package/directives/password/password.directive.d.ts +1 -1
- package/directives/present/present.directive.d.ts +2 -4
- package/directives/tooltip/tooltip.directive.d.ts +1 -1
- package/directives/unfinished-validator/unfinished-validator.directive.d.ts +2 -2
- package/directives/unmask-handler/unmask-handler.directive.d.ts +3 -3
- package/fesm2022/taiga-ui-kit-components-accordion.mjs +8 -8
- package/fesm2022/taiga-ui-kit-components-accordion.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-action-bar.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-action-bar.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-avatar.mjs +33 -47
- package/fesm2022/taiga-ui-kit-components-avatar.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-badge-notification.mjs +8 -10
- package/fesm2022/taiga-ui-kit-components-badge-notification.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-badge.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-badged-content.mjs +9 -11
- package/fesm2022/taiga-ui-kit-components-badged-content.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-block.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-block.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs +16 -30
- package/fesm2022/taiga-ui-kit-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-button-loading.mjs +18 -26
- package/fesm2022/taiga-ui-kit-components-button-loading.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-calendar-month.mjs +5 -13
- package/fesm2022/taiga-ui-kit-components-calendar-month.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs +23 -23
- package/fesm2022/taiga-ui-kit-components-calendar-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-carousel.mjs +63 -107
- package/fesm2022/taiga-ui-kit-components-carousel.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-checkbox.mjs +4 -5
- package/fesm2022/taiga-ui-kit-components-checkbox.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-chip.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs +40 -44
- package/fesm2022/taiga-ui-kit-components-combo-box.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-comment.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-compass.mjs +7 -9
- package/fesm2022/taiga-ui-kit-components-compass.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-confirm.mjs +9 -10
- package/fesm2022/taiga-ui-kit-components-confirm.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-copy.mjs +19 -32
- package/fesm2022/taiga-ui-kit-components-copy.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs +24 -85
- package/fesm2022/taiga-ui-kit-components-data-list-wrapper.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-drawer.mjs +15 -32
- package/fesm2022/taiga-ui-kit-components-drawer.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-files.mjs +110 -230
- package/fesm2022/taiga-ui-kit-components-files.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-filter.mjs +20 -34
- package/fesm2022/taiga-ui-kit-components-filter.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-fullscreen.mjs +23 -42
- package/fesm2022/taiga-ui-kit-components-fullscreen.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-chip.mjs +63 -75
- package/fesm2022/taiga-ui-kit-components-input-chip.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-color.mjs +24 -13
- package/fesm2022/taiga-ui-kit-components-input-color.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs +34 -46
- package/fesm2022/taiga-ui-kit-components-input-date-multi.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date-range.mjs +30 -35
- package/fesm2022/taiga-ui-kit-components-input-date-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date-time.mjs +31 -27
- package/fesm2022/taiga-ui-kit-components-input-date-time.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-date.mjs +42 -38
- package/fesm2022/taiga-ui-kit-components-input-date.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-inline.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs +26 -22
- package/fesm2022/taiga-ui-kit-components-input-month-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-month.mjs +32 -22
- package/fesm2022/taiga-ui-kit-components-input-month.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-number.mjs +47 -40
- package/fesm2022/taiga-ui-kit-components-input-number.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs +48 -36
- package/fesm2022/taiga-ui-kit-components-input-phone-international.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs +29 -18
- package/fesm2022/taiga-ui-kit-components-input-phone.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-pin.mjs +18 -9
- package/fesm2022/taiga-ui-kit-components-input-pin.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-range.mjs +18 -16
- package/fesm2022/taiga-ui-kit-components-input-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs +15 -10
- package/fesm2022/taiga-ui-kit-components-input-slider.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-time.mjs +38 -39
- package/fesm2022/taiga-ui-kit-components-input-time.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-input-year.mjs +27 -18
- package/fesm2022/taiga-ui-kit-components-input-year.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-items-with-more.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-like.mjs +3 -3
- package/fesm2022/taiga-ui-kit-components-like.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-line-clamp.mjs +14 -14
- package/fesm2022/taiga-ui-kit-components-line-clamp.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-message.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-message.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-multi-select.mjs +29 -39
- package/fesm2022/taiga-ui-kit-components-multi-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-notification-middle.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-notification-middle.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pager.mjs +6 -8
- package/fesm2022/taiga-ui-kit-components-pager.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pagination.mjs +59 -140
- package/fesm2022/taiga-ui-kit-components-pagination.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pin.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-preview.mjs +48 -36
- package/fesm2022/taiga-ui-kit-components-preview.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-progress.mjs +31 -35
- package/fesm2022/taiga-ui-kit-components-progress.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-pulse.mjs +7 -11
- package/fesm2022/taiga-ui-kit-components-pulse.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-push.mjs +20 -21
- package/fesm2022/taiga-ui-kit-components-push.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-radio-list.mjs +8 -8
- package/fesm2022/taiga-ui-kit-components-radio-list.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-radio.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-radio.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-range.mjs +7 -7
- package/fesm2022/taiga-ui-kit-components-range.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-rating.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-rating.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs +4 -4
- package/fesm2022/taiga-ui-kit-components-routable-dialog.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-segmented.mjs +31 -57
- package/fesm2022/taiga-ui-kit-components-segmented.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-select.mjs +50 -26
- package/fesm2022/taiga-ui-kit-components-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-slider.mjs +18 -18
- package/fesm2022/taiga-ui-kit-components-slider.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-status.mjs +6 -6
- package/fesm2022/taiga-ui-kit-components-stepper.mjs +8 -8
- package/fesm2022/taiga-ui-kit-components-switch.mjs +10 -6
- package/fesm2022/taiga-ui-kit-components-switch.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-tabs.mjs +24 -22
- package/fesm2022/taiga-ui-kit-components-tabs.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-textarea.mjs +51 -50
- package/fesm2022/taiga-ui-kit-components-textarea.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-tiles.mjs +12 -12
- package/fesm2022/taiga-ui-kit-components-toast.mjs +23 -24
- package/fesm2022/taiga-ui-kit-components-toast.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components-tree.mjs +26 -25
- package/fesm2022/taiga-ui-kit-components-tree.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-components.mjs +0 -3
- package/fesm2022/taiga-ui-kit-components.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs +27 -0
- package/fesm2022/taiga-ui-kit-directives-appearance-proxy.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-directives-button-close.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-button-group.mjs +7 -7
- package/fesm2022/taiga-ui-kit-directives-button-group.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-button-select.mjs +6 -6
- package/fesm2022/taiga-ui-kit-directives-button-select.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-chevron.mjs +10 -9
- package/fesm2022/taiga-ui-kit-directives-chevron.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-connected.mjs +6 -6
- package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs +25 -52
- package/fesm2022/taiga-ui-kit-directives-data-list-dropdown-manager.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-fade.mjs +25 -34
- package/fesm2022/taiga-ui-kit-directives-fade.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-fluid-typography.mjs +3 -3
- package/fesm2022/taiga-ui-kit-directives-highlight.mjs +16 -20
- package/fesm2022/taiga-ui-kit-directives-highlight.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-password.mjs +10 -8
- package/fesm2022/taiga-ui-kit-directives-password.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-present.mjs +10 -17
- package/fesm2022/taiga-ui-kit-directives-present.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-sensitive.mjs +6 -6
- package/fesm2022/taiga-ui-kit-directives-shimmer.mjs +6 -6
- package/fesm2022/taiga-ui-kit-directives-skeleton.mjs +7 -6
- package/fesm2022/taiga-ui-kit-directives-skeleton.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-tooltip.mjs +8 -8
- package/fesm2022/taiga-ui-kit-directives-tooltip.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs +8 -10
- package/fesm2022/taiga-ui-kit-directives-unfinished-validator.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs +10 -14
- package/fesm2022/taiga-ui-kit-directives-unmask-handler.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-directives.mjs +1 -1
- package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs +43 -0
- package/fesm2022/taiga-ui-kit-pipes-auto-color.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-pipes-emails.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs +12 -24
- package/fesm2022/taiga-ui-kit-pipes-filter-by-input.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-flag.mjs +30 -0
- package/fesm2022/taiga-ui-kit-pipes-flag.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs +4 -4
- package/fesm2022/taiga-ui-kit-pipes-hide-selected.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-initials.mjs +28 -0
- package/fesm2022/taiga-ui-kit-pipes-initials.mjs.map +1 -0
- package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs +10 -8
- package/fesm2022/taiga-ui-kit-pipes-sort-countries.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes-stringify-content.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-pipes-stringify.mjs +3 -3
- package/fesm2022/taiga-ui-kit-pipes.mjs +3 -0
- package/fesm2022/taiga-ui-kit-pipes.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-tokens.mjs +4 -108
- package/fesm2022/taiga-ui-kit-tokens.mjs.map +1 -1
- package/fesm2022/taiga-ui-kit-utils.mjs +3 -15
- package/fesm2022/taiga-ui-kit-utils.mjs.map +1 -1
- package/package.json +62 -62
- package/pipes/auto-color/auto-color.pipe.d.ts +13 -0
- package/pipes/auto-color/index.d.ts +1 -0
- package/pipes/filter-by-input/filter-by-input.pipe.d.ts +2 -2
- package/pipes/flag/flag.pipe.d.ts +14 -0
- package/pipes/flag/index.d.ts +1 -0
- package/pipes/index.d.ts +3 -0
- package/pipes/initials/index.d.ts +1 -0
- package/pipes/initials/initials.pipe.d.ts +7 -0
- package/pipes/sort-countries/sort-countries.pipe.d.ts +4 -3
- package/pipes/stringify-content/stringify-content.pipe.d.ts +2 -3
- package/styles/components/avatar.less +14 -14
- package/styles/components/badge.less +3 -3
- package/styles/components/block.less +4 -4
- package/styles/components/chip.less +3 -3
- package/styles/components/comment.less +1 -1
- package/styles/components/message.less +1 -1
- package/styles/components/pin.less +3 -3
- package/styles/components/switch.less +2 -2
- package/styles/components/toast.less +1 -1
- package/tokens/i18n.d.ts +1 -0
- package/tokens/index.d.ts +0 -7
- package/utils/index.d.ts +0 -2
- package/components/elastic-container/elastic-container.component.d.ts +0 -8
- package/components/elastic-container/elastic-container.directive.d.ts +0 -7
- package/components/elastic-container/index.d.ts +0 -2
- package/components/floating-container/floating-container.directive.d.ts +0 -7
- package/components/floating-container/index.d.ts +0 -1
- package/components/input-range/input-range.d.ts +0 -3
- package/components/slides/index.d.ts +0 -1
- package/components/slides/slides.directive.d.ts +0 -11
- package/components/textarea/textarea-limit.directive.d.ts +0 -26
- package/directives/lazy-loading/index.d.ts +0 -2
- package/directives/lazy-loading/lazy-loading.directive.d.ts +0 -18
- package/directives/lazy-loading/lazy-loading.service.d.ts +0 -12
- package/fesm2022/taiga-ui-kit-components-elastic-container.mjs +0 -77
- package/fesm2022/taiga-ui-kit-components-elastic-container.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-components-floating-container.mjs +0 -37
- package/fesm2022/taiga-ui-kit-components-floating-container.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-components-slides.mjs +0 -49
- package/fesm2022/taiga-ui-kit-components-slides.mjs.map +0 -1
- package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs +0 -80
- package/fesm2022/taiga-ui-kit-directives-lazy-loading.mjs.map +0 -1
- package/tokens/calendar-date-stream.d.ts +0 -10
- package/tokens/date-inputs-value-transformers.d.ts +0 -19
- package/tokens/input-date-options.d.ts +0 -15
- package/tokens/items-handlers.d.ts +0 -20
- package/tokens/mobile-calendar.d.ts +0 -6
- package/tokens/month-formatter.d.ts +0 -5
- package/utils/phone.d.ts +0 -3
- package/utils/toggle-day.d.ts +0 -2
- /package/{tokens/preview-icons.d.ts → components/preview/preview.options.d.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-notification-middle.mjs","sources":["../../../projects/kit/components/notification-middle/notification-middle.component.ts","../../../projects/kit/components/notification-middle/notification-middle.service.ts","../../../projects/kit/components/notification-middle/notification-middle.directive.ts","../../../projects/kit/components/notification-middle/taiga-ui-kit-components-notification-middle.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, isSignal, type Signal} from '@angular/core';\nimport {WaResizeObserver} from '@ng-web-apis/resize-observer';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext} from '@taiga-ui/cdk/portals';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiLoader, tuiLoaderOptionsProvider} from '@taiga-ui/core/components/loader';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nexport interface TuiNotificationMiddleOptions {\n closable: Signal<boolean> | boolean;\n}\n\n@Component({\n selector: 'tui-notification-middle',\n imports: [PolymorpheusOutlet, TuiLoader],\n template: `\n <tui-loader class=\"t-loader\" />\n <ng-container *polymorpheusOutlet=\"context.content as text\">\n {{ text }}\n </ng-container>\n `,\n styleUrl: './notification-middle.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiLoaderOptionsProvider({size: 'l'})],\n hostDirectives: [\n TuiAnimated,\n {directive: WaResizeObserver, outputs: ['waResizeObserver']},\n ],\n host: {\n class: 'tui-backdrop-hidden',\n '(document:click.capture)': 'onClick($event.target)',\n '(document:keydown.esc)': 'onClick($event.currentTarget)',\n '(waResizeObserver)': 'el.style.setProperty(\"--t-width\", el.clientWidth + \"px\")',\n },\n})\nexport class TuiNotificationMiddleComponent {\n protected readonly el = tuiInjectElement();\n protected readonly context =\n injectContext<TuiPortalContext<TuiNotificationMiddleOptions>>();\n\n protected onClick(target: HTMLElement): void {\n if (this.closable && !this.el.contains(target)) {\n this.context.$implicit.complete();\n }\n }\n\n private get closable(): boolean {\n return isSignal(this.context.closable)\n ? this.context.closable()\n : this.context.closable;\n }\n}\n","import {Injectable} from '@angular/core';\nimport {TuiModalService} from '@taiga-ui/core/
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-notification-middle.mjs","sources":["../../../projects/kit/components/notification-middle/notification-middle.component.ts","../../../projects/kit/components/notification-middle/notification-middle.service.ts","../../../projects/kit/components/notification-middle/notification-middle.directive.ts","../../../projects/kit/components/notification-middle/taiga-ui-kit-components-notification-middle.ts"],"sourcesContent":["import {ChangeDetectionStrategy, Component, isSignal, type Signal} from '@angular/core';\nimport {WaResizeObserver} from '@ng-web-apis/resize-observer';\nimport {TuiAnimated} from '@taiga-ui/cdk/directives/animated';\nimport {type TuiPortalContext} from '@taiga-ui/cdk/portals';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {TuiLoader, tuiLoaderOptionsProvider} from '@taiga-ui/core/components/loader';\nimport {injectContext, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nexport interface TuiNotificationMiddleOptions {\n closable: Signal<boolean> | boolean;\n}\n\n@Component({\n selector: 'tui-notification-middle',\n imports: [PolymorpheusOutlet, TuiLoader],\n template: `\n <tui-loader class=\"t-loader\" />\n <ng-container *polymorpheusOutlet=\"context.content as text\">\n {{ text }}\n </ng-container>\n `,\n styleUrl: './notification-middle.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [tuiLoaderOptionsProvider({size: 'l'})],\n hostDirectives: [\n TuiAnimated,\n {directive: WaResizeObserver, outputs: ['waResizeObserver']},\n ],\n host: {\n class: 'tui-backdrop-hidden',\n '(document:click.capture)': 'onClick($event.target)',\n '(document:keydown.esc)': 'onClick($event.currentTarget)',\n '(waResizeObserver)': 'el.style.setProperty(\"--t-width\", el.clientWidth + \"px\")',\n },\n})\nexport class TuiNotificationMiddleComponent {\n protected readonly el = tuiInjectElement();\n protected readonly context =\n injectContext<TuiPortalContext<TuiNotificationMiddleOptions>>();\n\n protected onClick(target: HTMLElement): void {\n if (this.closable && !this.el.contains(target)) {\n this.context.$implicit.complete();\n }\n }\n\n private get closable(): boolean {\n return isSignal(this.context.closable)\n ? this.context.closable()\n : this.context.closable;\n }\n}\n","import {Injectable} from '@angular/core';\nimport {TuiModalService} from '@taiga-ui/core/portals/modal';\n\nimport {\n TuiNotificationMiddleComponent,\n type TuiNotificationMiddleOptions,\n} from './notification-middle.component';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class TuiNotificationMiddleService extends TuiModalService<TuiNotificationMiddleOptions> {\n protected readonly options = {closable: false};\n protected readonly content = TuiNotificationMiddleComponent;\n}\n","import {Directive, input} from '@angular/core';\nimport {tuiAsPortal, TuiPortalDirective} from '@taiga-ui/cdk/portals';\n\nimport {type TuiNotificationMiddleOptions} from './notification-middle.component';\nimport {TuiNotificationMiddleService} from './notification-middle.service';\n\n@Directive({\n selector: 'ng-template[tuiNotificationMiddle]',\n providers: [tuiAsPortal(TuiNotificationMiddleService)],\n hostDirectives: [\n {\n directive: TuiPortalDirective,\n inputs: [\n 'options: tuiNotificationMiddleOptions',\n 'open: tuiNotificationMiddle',\n ],\n outputs: ['openChange: tuiNotificationMiddleChange'],\n },\n ],\n})\nexport class TuiNotificationMiddle {\n public readonly tuiNotificationMiddleOptions = input<\n Partial<TuiNotificationMiddleOptions>\n >({});\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;MAmCa,8BAA8B,CAAA;AAvB3C,IAAA,WAAA,GAAA;QAwBuB,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;QACvB,IAAO,CAAA,OAAA,GACtB,aAAa,EAAkD;AAatE;AAXa,IAAA,OAAO,CAAC,MAAmB,EAAA;AACjC,QAAA,IAAI,IAAI,CAAC,QAAQ,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE;AAC5C,YAAA,IAAI,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AA;;;MCUY,qBAAqB,CAAA;AAdlC,IAAA,WAAA,GAAA;AAeoB,QAAA,IAAA,CAAA,4BAA4B,GAAG,KAAK,CAElD,EAAE,CAAC;AACR;+GAJY,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAArB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,qBAAqB,0RAZnB,CAAC,WAAW,CAAC,4BAA4B,CAAC,CAAC,EAAA,cAAA,EAAA,CAAA,EAAA,SAAA,EAAAA,IAAA,CAAA,kBAAA,EAAA,MAAA,EAAA,CAAA,SAAA,EAAA,8BAAA,EAAA,MAAA,EAAA,uBAAA,CAAA,EAAA,OAAA,EAAA,CAAA,YAAA,EAAA,6BAAA,CAAA,EAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAY7C,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAdjC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,oCAAoC;AAC9C,oBAAA,SAAS,EAAE,CAAC,WAAW,CAAC,4BAA4B,CAAC,CAAC;AACtD,oBAAA,cAAc,EAAE;AACZ,wBAAA;AACI,4BAAA,SAAS,EAAE,kBAAkB;AAC7B,4BAAA,MAAM,EAAE;gCACJ,uCAAuC;gCACvC,6BAA6B;AAChC,6BAAA;4BACD,OAAO,EAAE,CAAC,yCAAyC,CAAC;AACvD,yBAAA;AACJ,qBAAA;AACJ,iBAAA;;;ACnBD;;AAEG;;;;"}
|
|
@@ -2,9 +2,7 @@ import { NgTemplateOutlet } from '@angular/common';
|
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { signal, inject, Input, ViewChildren, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
4
4
|
import { toSignal, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
5
|
-
import { FormsModule } from '@angular/forms';
|
|
6
5
|
import { MutationObserverService, WA_MUTATION_OBSERVER_INIT } from '@ng-web-apis/mutation-observer';
|
|
7
|
-
import { TuiRepeatTimes } from '@taiga-ui/cdk/directives/repeat-times';
|
|
8
6
|
import { tuiWatch } from '@taiga-ui/cdk/observables';
|
|
9
7
|
import { delay, map } from 'rxjs';
|
|
10
8
|
|
|
@@ -48,8 +46,8 @@ class TuiPager {
|
|
|
48
46
|
}
|
|
49
47
|
this.left.set(-1 * left);
|
|
50
48
|
}
|
|
51
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
52
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
49
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiPager, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
50
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiPager, isStandalone: true, selector: "tui-pager", inputs: { max: "max", count: "count", size: "size", valueContent: "valueContent", index: "index" }, host: { properties: { "attr.data-size": "size", "style.--t-gap.px": "gap", "style.max-width.px": "maxWidth()" } }, providers: [
|
|
53
51
|
MutationObserverService,
|
|
54
52
|
{
|
|
55
53
|
provide: WA_MUTATION_OBSERVER_INIT,
|
|
@@ -60,11 +58,11 @@ class TuiPager {
|
|
|
60
58
|
subtree: true,
|
|
61
59
|
},
|
|
62
60
|
},
|
|
63
|
-
], viewQueries: [{ propertyName: "items", predicate: ["item"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"t-items\"\n [style.transform]=\"`translateX(calc(var(--tui-inline) * ${left()}px))`\"\n>\n
|
|
61
|
+
], viewQueries: [{ propertyName: "items", predicate: ["item"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"t-items\"\n [style.transform]=\"`translateX(calc(var(--tui-inline) * ${left()}px))`\"\n>\n @for (_ of '-'.repeat(count); track $index) {\n <div\n #item\n class=\"t-item\"\n [attr.data-index]=\"$index\"\n [class._active]=\"$index === index\"\n [class._last]=\"$index === count - 1\"\n [class._post-active]=\"$index === index + 1\"\n [class._pre-active]=\"$index === index - 1\"\n [class._pre-last]=\"$index === count - 2\"\n [class._visible]=\"$index >= start && $index <= end\"\n >\n <ng-container *ngTemplateOutlet=\"valueContent || null; context: {$implicit: $index}\" />\n </div>\n }\n</div>\n", styles: [":host{display:flex;align-items:center;overflow:hidden}:host[data-size=m]{--t-size: .5rem;--t-small-dot: scale(.75);--t-super-small-dot: scale(.5);--t-icon-size: 1rem;min-block-size:1.25rem}:host-context(tui-root._mobile) :host[data-size=m]{--t-icon-size: .875rem}:host[data-size=s]{--t-size: .375rem;--t-small-dot: scale(.666);--t-super-small-dot: scale(.333);--t-icon-size: .75rem;min-block-size:1rem}:host-context(tui-root._mobile) :host[data-size=s]{--t-icon-size: .6875rem}.t-items{display:flex;gap:var(--t-gap);transition:transform var(--tui-duration-fast, .15s) var(--tui-curve-productive-standard, cubic-bezier(.2, 0, .4, .9))}.t-item{display:flex;align-self:center;align-items:center;justify-content:center;color:var(--tui-background-neutral-2)}.t-item._active{color:var(--tui-background-accent-1)}.t-item:empty:before{content:\"\";display:flex;min-inline-size:var(--t-size);min-block-size:var(--t-size);border-radius:100%;background:currentColor;transition:inherit}.t-item:empty:not(._visible):before,.t-item:empty:not(._visible)+.t-item:not(._active):not(._pre-active):empty:before,.t-item:empty:not(._last):not(._post-active):not(._active):nth-last-child(1 of._visible):before{transform:var(--t-super-small-dot)!important}.t-item:empty:not(._last)._post-active:nth-last-child(1 of._visible):before,.t-item:empty:not(._visible)+.t-item._pre-active:empty:before,.t-item:empty:not(._visible)+.t-item:empty+.t-item:not(._active):empty:before,.t-item:empty:not(._pre-last):nth-last-child(2 of._visible):not(._active):before{transform:var(--t-small-dot)}.t-item:empty+.t-item:not(:empty)._pre-last{transform:scale(.64)}.t-item:empty+.t-item:not(:empty)._pre-last:nth-last-child(2 of._visible){transform:scale(1)}.t-item::ng-deep>tui-icon{inline-size:var(--t-icon-size);block-size:var(--t-icon-size)}.t-item,.t-item::ng-deep>tui-icon{transition:all var(--tui-duration-fast, .15s) var(--tui-curve-productive-standard, cubic-bezier(.2, 0, .4, .9))}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
64
62
|
}
|
|
65
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
63
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiPager, decorators: [{
|
|
66
64
|
type: Component,
|
|
67
|
-
args: [{ selector: 'tui-pager', imports: [
|
|
65
|
+
args: [{ selector: 'tui-pager', imports: [NgTemplateOutlet], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
68
66
|
MutationObserverService,
|
|
69
67
|
{
|
|
70
68
|
provide: WA_MUTATION_OBSERVER_INIT,
|
|
@@ -79,7 +77,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.15", ngImpo
|
|
|
79
77
|
'[attr.data-size]': 'size',
|
|
80
78
|
'[style.--t-gap.px]': 'gap',
|
|
81
79
|
'[style.max-width.px]': 'maxWidth()',
|
|
82
|
-
}, template: "<div\n class=\"t-items\"\n [style.transform]=\"`translateX(calc(var(--tui-inline) * ${left()}px))`\"\n>\n
|
|
80
|
+
}, template: "<div\n class=\"t-items\"\n [style.transform]=\"`translateX(calc(var(--tui-inline) * ${left()}px))`\"\n>\n @for (_ of '-'.repeat(count); track $index) {\n <div\n #item\n class=\"t-item\"\n [attr.data-index]=\"$index\"\n [class._active]=\"$index === index\"\n [class._last]=\"$index === count - 1\"\n [class._post-active]=\"$index === index + 1\"\n [class._pre-active]=\"$index === index - 1\"\n [class._pre-last]=\"$index === count - 2\"\n [class._visible]=\"$index >= start && $index <= end\"\n >\n <ng-container *ngTemplateOutlet=\"valueContent || null; context: {$implicit: $index}\" />\n </div>\n }\n</div>\n", styles: [":host{display:flex;align-items:center;overflow:hidden}:host[data-size=m]{--t-size: .5rem;--t-small-dot: scale(.75);--t-super-small-dot: scale(.5);--t-icon-size: 1rem;min-block-size:1.25rem}:host-context(tui-root._mobile) :host[data-size=m]{--t-icon-size: .875rem}:host[data-size=s]{--t-size: .375rem;--t-small-dot: scale(.666);--t-super-small-dot: scale(.333);--t-icon-size: .75rem;min-block-size:1rem}:host-context(tui-root._mobile) :host[data-size=s]{--t-icon-size: .6875rem}.t-items{display:flex;gap:var(--t-gap);transition:transform var(--tui-duration-fast, .15s) var(--tui-curve-productive-standard, cubic-bezier(.2, 0, .4, .9))}.t-item{display:flex;align-self:center;align-items:center;justify-content:center;color:var(--tui-background-neutral-2)}.t-item._active{color:var(--tui-background-accent-1)}.t-item:empty:before{content:\"\";display:flex;min-inline-size:var(--t-size);min-block-size:var(--t-size);border-radius:100%;background:currentColor;transition:inherit}.t-item:empty:not(._visible):before,.t-item:empty:not(._visible)+.t-item:not(._active):not(._pre-active):empty:before,.t-item:empty:not(._last):not(._post-active):not(._active):nth-last-child(1 of._visible):before{transform:var(--t-super-small-dot)!important}.t-item:empty:not(._last)._post-active:nth-last-child(1 of._visible):before,.t-item:empty:not(._visible)+.t-item._pre-active:empty:before,.t-item:empty:not(._visible)+.t-item:empty+.t-item:not(._active):empty:before,.t-item:empty:not(._pre-last):nth-last-child(2 of._visible):not(._active):before{transform:var(--t-small-dot)}.t-item:empty+.t-item:not(:empty)._pre-last{transform:scale(.64)}.t-item:empty+.t-item:not(:empty)._pre-last:nth-last-child(2 of._visible){transform:scale(1)}.t-item::ng-deep>tui-icon{inline-size:var(--t-icon-size);block-size:var(--t-icon-size)}.t-item,.t-item::ng-deep>tui-icon{transition:all var(--tui-duration-fast, .15s) var(--tui-curve-productive-standard, cubic-bezier(.2, 0, .4, .9))}\n"] }]
|
|
83
81
|
}], propDecorators: { items: [{
|
|
84
82
|
type: ViewChildren,
|
|
85
83
|
args: ['item']
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-pager.mjs","sources":["../../../projects/kit/components/pager/pager.component.ts","../../../projects/kit/components/pager/pager.component.html","../../../projects/kit/components/pager/taiga-ui-kit-components-pager.ts"],"sourcesContent":["import {NgTemplateOutlet} from '@angular/common';\nimport {\n type AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n type ElementRef,\n inject,\n Input,\n type OnChanges,\n type QueryList,\n signal,\n type TemplateRef,\n ViewChildren,\n} from '@angular/core';\nimport {takeUntilDestroyed, toSignal} from '@angular/core/rxjs-interop';\nimport {
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-pager.mjs","sources":["../../../projects/kit/components/pager/pager.component.ts","../../../projects/kit/components/pager/pager.component.html","../../../projects/kit/components/pager/taiga-ui-kit-components-pager.ts"],"sourcesContent":["import {NgTemplateOutlet} from '@angular/common';\nimport {\n type AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n type ElementRef,\n inject,\n Input,\n type OnChanges,\n type QueryList,\n signal,\n type TemplateRef,\n ViewChildren,\n} from '@angular/core';\nimport {takeUntilDestroyed, toSignal} from '@angular/core/rxjs-interop';\nimport {\n MutationObserverService,\n WA_MUTATION_OBSERVER_INIT,\n} from '@ng-web-apis/mutation-observer';\nimport {tuiWatch} from '@taiga-ui/cdk/observables';\nimport {type TuiSizeS} from '@taiga-ui/core/types';\nimport {delay, map} from 'rxjs';\n\n@Component({\n selector: 'tui-pager',\n imports: [NgTemplateOutlet],\n templateUrl: './pager.component.html',\n styleUrl: './pager.styles.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n MutationObserverService,\n {\n provide: WA_MUTATION_OBSERVER_INIT,\n useValue: {\n attributeOldValue: true,\n characterData: true,\n childList: true,\n subtree: true,\n },\n },\n ],\n host: {\n '[attr.data-size]': 'size',\n '[style.--t-gap.px]': 'gap',\n '[style.max-width.px]': 'maxWidth()',\n },\n})\nexport class TuiPager implements OnChanges, AfterViewInit {\n @ViewChildren('item')\n protected items?: QueryList<ElementRef<HTMLElement>>;\n\n protected start = 0;\n protected end = 0;\n protected left = signal(0);\n protected readonly maxWidth = toSignal(\n inject(MutationObserverService, {self: true}).pipe(\n delay(0),\n map(() => this.visibleWidth),\n tuiWatch(),\n takeUntilDestroyed(),\n ),\n {initialValue: 0},\n );\n\n @Input()\n public max = 6;\n\n @Input()\n public count = this.max;\n\n @Input()\n public size: TuiSizeS = 'm';\n\n @Input()\n public valueContent?: TemplateRef<unknown>;\n\n @Input()\n public index = 0;\n\n public ngOnChanges(): void {\n this.move();\n }\n\n public ngAfterViewInit(): void {\n this.move();\n }\n\n protected get gap(): number {\n return this.size === 'm' ? 9 : 7;\n }\n\n private get visibleRange(): [start: number, end: number] {\n const max = this.max > this.count ? this.count : this.max;\n\n const start = Math.min(\n Math.max(this.index - Math.floor(max / 2), 0),\n this.count - max,\n );\n\n return [start, start + (max - 1)];\n }\n\n private get visibleWidth(): number {\n return (\n (this.items?.map((item) => item.nativeElement.offsetWidth ?? 0) ?? [])\n .slice(this.start, this.end + 1)\n .reduce((sum, item) => sum + item + this.gap, 0) - this.gap\n );\n }\n\n private move(): void {\n const [start, end] = this.visibleRange;\n\n this.start = start;\n this.end = end;\n\n let left = this.start * this.gap;\n\n for (let i = 0; i < this.start; i++) {\n left += this.items?.get(i)?.nativeElement.offsetWidth ?? 0;\n }\n\n this.left.set(-1 * left);\n }\n}\n","<div\n class=\"t-items\"\n [style.transform]=\"`translateX(calc(var(--tui-inline) * ${left()}px))`\"\n>\n @for (_ of '-'.repeat(count); track $index) {\n <div\n #item\n class=\"t-item\"\n [attr.data-index]=\"$index\"\n [class._active]=\"$index === index\"\n [class._last]=\"$index === count - 1\"\n [class._post-active]=\"$index === index + 1\"\n [class._pre-active]=\"$index === index - 1\"\n [class._pre-last]=\"$index === count - 2\"\n [class._visible]=\"$index >= start && $index <= end\"\n >\n <ng-container *ngTemplateOutlet=\"valueContent || null; context: {$implicit: $index}\" />\n </div>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;MA+Ca,QAAQ,CAAA;AAxBrB,IAAA,WAAA,GAAA;QA4Bc,IAAK,CAAA,KAAA,GAAG,CAAC;QACT,IAAG,CAAA,GAAA,GAAG,CAAC;AACP,QAAA,IAAA,CAAA,IAAI,GAAG,MAAM,CAAC,CAAC,CAAC;QACP,IAAQ,CAAA,QAAA,GAAG,QAAQ,CAClC,MAAM,CAAC,uBAAuB,EAAE,EAAC,IAAI,EAAE,IAAI,EAAC,CAAC,CAAC,IAAI,CAC9C,KAAK,CAAC,CAAC,CAAC,EACR,GAAG,CAAC,MAAM,IAAI,CAAC,YAAY,CAAC,EAC5B,QAAQ,EAAE,EACV,kBAAkB,EAAE,CACvB,EACD,EAAC,YAAY,EAAE,CAAC,EAAC,CACpB;QAGM,IAAG,CAAA,GAAA,GAAG,CAAC;AAGP,QAAA,IAAA,CAAA,KAAK,GAAG,IAAI,CAAC,GAAG;QAGhB,IAAI,CAAA,IAAA,GAAa,GAAG;QAMpB,IAAK,CAAA,KAAA,GAAG,CAAC;AA+CnB;IA7CU,WAAW,GAAA;QACd,IAAI,CAAC,IAAI,EAAE;;IAGR,eAAe,GAAA;QAClB,IAAI,CAAC,IAAI,EAAE;;AAGf,IAAA,IAAc,GAAG,GAAA;AACb,QAAA,OAAO,IAAI,CAAC,IAAI,KAAK,GAAG,GAAG,CAAC,GAAG,CAAC;;AAGpC,IAAA,IAAY,YAAY,GAAA;QACpB,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,GAAG,IAAI,CAA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UAAA,EAAA,CAAA;kBAxBpB,SAAS;+BACI,WAAW,EAAA,OAAA,EACZ,CAAC,gBAAgB,CAAC,mBAGV,uBAAuB,CAAC,MAAM,EACpC,SAAA,EAAA;wBACP,uBAAuB;AACvB,wBAAA;AACI,4BAAA,OAAO,EAAE,yBAAyB;AAClC,4BAAA,QAAQ,EAAE;AACN,gCAAA,iBAAiB,EAAE,IAAI;AACvB,gCAAA,aAAa,EAAE,IAAI;AACnB,gCAAA,SAAS,EAAE,IAAI;AACf,gCAAA,OAAO,EAAE,IAAI;AAChB,6BAAA;AACJ,yBAAA;qBACJ,EACK,IAAA,EAAA;AACF,wBAAA,kBAAkB,EAAE,MAAM;AAC1B,wBAAA,oBAAoB,EAAE,KAAK;AAC3B,wBAAA,sBAAsB,EAAE,YAAY;AACvC,qBAAA,EAAA,QAAA,EAAA,ovBAAA,EAAA,MAAA,EAAA,CAAA,k6DAAA,CAAA,EAAA;8BAIS,KAAK,EAAA,CAAA;sBADd,YAAY;uBAAC,MAAM;gBAiBb,GAAG,EAAA,CAAA;sBADT;gBAIM,KAAK,EAAA,CAAA;sBADX;gBAIM,IAAI,EAAA,CAAA;sBADV;gBAIM,YAAY,EAAA,CAAA;sBADlB;gBAIM,KAAK,EAAA,CAAA;sBADX;;;AE5EL;;AAEG;;;;"}
|
|
@@ -1,89 +1,70 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { computed, inject, input, model, ElementRef, ViewChildren, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
3
|
import { EMPTY_QUERY } from '@taiga-ui/cdk/constants';
|
|
4
|
-
import { TuiRepeatTimes } from '@taiga-ui/cdk/directives/repeat-times';
|
|
5
4
|
import { tuiInjectElement } from '@taiga-ui/cdk/utils/dom';
|
|
6
5
|
import { tuiIsFocusedIn } from '@taiga-ui/cdk/utils/focus';
|
|
7
6
|
import { tuiClamp } from '@taiga-ui/cdk/utils/math';
|
|
8
7
|
import { TuiButton } from '@taiga-ui/core/components/button';
|
|
9
|
-
import {
|
|
8
|
+
import { TUI_COMMON_ICONS } from '@taiga-ui/core/tokens';
|
|
10
9
|
import { TUI_PAGINATION_TEXTS } from '@taiga-ui/kit/tokens';
|
|
11
10
|
import { PolymorpheusOutlet } from '@taiga-ui/polymorpheus';
|
|
12
11
|
import { tuiCreateOptions } from '@taiga-ui/cdk/utils/di';
|
|
13
12
|
|
|
14
13
|
const [TUI_PAGINATION_OPTIONS, tuiPaginationOptionsProvider] = tuiCreateOptions({
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
return isActive ? 'primary' : fallback;
|
|
18
|
-
},
|
|
19
|
-
defaultSize: 'l',
|
|
14
|
+
size: 'l',
|
|
15
|
+
appearance: (isActive) => (isActive ? 'primary' : 'flat'),
|
|
20
16
|
});
|
|
21
17
|
|
|
22
|
-
const
|
|
18
|
+
const ELLIPSIS_ITEM_LENGTH = 1;
|
|
23
19
|
const ACTIVE_ITEM_LENGTH = 1;
|
|
24
20
|
class TuiPagination {
|
|
25
21
|
constructor() {
|
|
26
22
|
this.els = EMPTY_QUERY;
|
|
27
23
|
this.el = tuiInjectElement();
|
|
24
|
+
this.maxHalfLength = computed(() => this.sidePadding() + ELLIPSIS_ITEM_LENGTH + this.activePadding());
|
|
25
|
+
this.maxElementsLength = computed(() => this.maxHalfLength() * 2 + ACTIVE_ITEM_LENGTH);
|
|
26
|
+
this.lastElementIndex = computed(() => this.elementsLength() - 1);
|
|
27
|
+
this.itemsFit = computed(() => this.length() <= this.maxElementsLength());
|
|
28
|
+
this.lastIndex = computed(() => this.length() - 1);
|
|
29
|
+
this.reverseIndex = computed(() => this.lastIndex() - this.index());
|
|
28
30
|
this.texts = inject(TUI_PAGINATION_TEXTS);
|
|
29
|
-
this.icons = inject(
|
|
31
|
+
this.icons = inject(TUI_COMMON_ICONS);
|
|
30
32
|
this.options = inject(TUI_PAGINATION_OPTIONS);
|
|
31
|
-
this.
|
|
32
|
-
this.
|
|
33
|
-
this.
|
|
34
|
-
this.
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
this.
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
this.
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
this.index = 0;
|
|
47
|
-
this.indexChange = new EventEmitter();
|
|
48
|
-
}
|
|
49
|
-
get nativeFocusableElement() {
|
|
50
|
-
if (this.disabled) {
|
|
51
|
-
return null;
|
|
52
|
-
}
|
|
53
|
-
let activeElementIndex = 0;
|
|
54
|
-
const { elementsLength } = this;
|
|
55
|
-
for (let i = 0; i < elementsLength; i++) {
|
|
56
|
-
const itemIndex = this.getItemIndexByElementIndex(i);
|
|
57
|
-
if (itemIndex) {
|
|
58
|
-
activeElementIndex++;
|
|
33
|
+
this.buttonSize = computed(() => (this.size() === 'm' ? 'xs' : 's'));
|
|
34
|
+
this.elementsLength = computed(() => this.itemsFit() ? this.length() : this.maxElementsLength());
|
|
35
|
+
this.length = input(1);
|
|
36
|
+
this.focusable = input(true);
|
|
37
|
+
this.size = input(this.options.size);
|
|
38
|
+
this.disabled = input(false);
|
|
39
|
+
this.activePadding = input(1);
|
|
40
|
+
this.sidePadding = input(1);
|
|
41
|
+
this.content = input();
|
|
42
|
+
this.index = model(0);
|
|
43
|
+
this.arrowIsDisabledRight = computed(() => this.reverseIndex() === 0);
|
|
44
|
+
this.arrowIsDisabledLeft = computed(() => this.index() === 0);
|
|
45
|
+
this.nativeFocusableElement = computed(() => {
|
|
46
|
+
if (this.disabled()) {
|
|
47
|
+
return null;
|
|
59
48
|
}
|
|
60
|
-
|
|
61
|
-
|
|
49
|
+
let activeElementIndex = 0;
|
|
50
|
+
for (let i = 0; i < this.elementsLength(); i++) {
|
|
51
|
+
const itemIndex = this.getItemIndexByElementIndex(i);
|
|
52
|
+
if (itemIndex) {
|
|
53
|
+
activeElementIndex++;
|
|
54
|
+
}
|
|
55
|
+
if (itemIndex === this.index()) {
|
|
56
|
+
break;
|
|
57
|
+
}
|
|
62
58
|
}
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
59
|
+
return (this.els.find((_, index) => index === activeElementIndex)?.nativeElement ??
|
|
60
|
+
null);
|
|
61
|
+
});
|
|
66
62
|
}
|
|
67
63
|
get focused() {
|
|
68
64
|
return tuiIsFocusedIn(this.el);
|
|
69
65
|
}
|
|
70
|
-
get arrowIsDisabledLeft() {
|
|
71
|
-
return this.index === 0;
|
|
72
|
-
}
|
|
73
|
-
get arrowIsDisabledRight() {
|
|
74
|
-
return this.reverseIndex === 0;
|
|
75
|
-
}
|
|
76
|
-
/**
|
|
77
|
-
* Number of items in a container.
|
|
78
|
-
*/
|
|
79
|
-
get elementsLength() {
|
|
80
|
-
return this.itemsFit ? this.length : this.maxElementsLength;
|
|
81
|
-
}
|
|
82
|
-
get buttonSize() {
|
|
83
|
-
return this.size === 'm' ? 'xs' : 's';
|
|
84
|
-
}
|
|
85
66
|
elementIsFocusable(index) {
|
|
86
|
-
return this.index === index && !this.focused;
|
|
67
|
+
return this.index() === index && !this.focused;
|
|
87
68
|
}
|
|
88
69
|
/**
|
|
89
70
|
* Get index by element index
|
|
@@ -91,31 +72,25 @@ class TuiPagination {
|
|
|
91
72
|
* @returns index or null (for '…')
|
|
92
73
|
*/
|
|
93
74
|
getItemIndexByElementIndex(elementIndex) {
|
|
94
|
-
|
|
75
|
+
const reverseElementIndex = this.lastElementIndex() - elementIndex;
|
|
76
|
+
if (elementIndex < this.sidePadding()) {
|
|
95
77
|
return elementIndex;
|
|
96
78
|
}
|
|
97
|
-
if (
|
|
98
|
-
return
|
|
79
|
+
if (reverseElementIndex < this.sidePadding()) {
|
|
80
|
+
return this.lastIndex() - reverseElementIndex;
|
|
99
81
|
}
|
|
100
|
-
if (elementIndex === this.sidePadding && this.hasCollapsedItems(this.index)) {
|
|
82
|
+
if (elementIndex === this.sidePadding() && this.hasCollapsedItems(this.index())) {
|
|
101
83
|
return null;
|
|
102
84
|
}
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
this.hasCollapsedItems(this.reverseIndex)) {
|
|
85
|
+
if (reverseElementIndex === this.sidePadding() &&
|
|
86
|
+
this.hasCollapsedItems(this.reverseIndex())) {
|
|
106
87
|
return null;
|
|
107
88
|
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
}
|
|
111
|
-
const computedIndex = this.index - this.maxHalfLength + elementIndex;
|
|
112
|
-
return tuiClamp(computedIndex, elementIndex, this.lastIndex - reverseElementIndex);
|
|
89
|
+
const computedIndex = this.index() - this.maxHalfLength() + elementIndex;
|
|
90
|
+
return tuiClamp(computedIndex, elementIndex, this.lastIndex() - reverseElementIndex);
|
|
113
91
|
}
|
|
114
92
|
getElementMode(index = -1) {
|
|
115
|
-
return this.options.appearance(
|
|
116
|
-
isActive: this.index === index,
|
|
117
|
-
size: this.size,
|
|
118
|
-
});
|
|
93
|
+
return this.options.appearance(this.index() === index);
|
|
119
94
|
}
|
|
120
95
|
onElementClick(index) {
|
|
121
96
|
this.updateIndex(index);
|
|
@@ -136,37 +111,7 @@ class TuiPagination {
|
|
|
136
111
|
}
|
|
137
112
|
onArrowClick(direction) {
|
|
138
113
|
this.tryChangeTo(direction);
|
|
139
|
-
this.
|
|
140
|
-
}
|
|
141
|
-
/**
|
|
142
|
-
* Active index from the end
|
|
143
|
-
*/
|
|
144
|
-
get reverseIndex() {
|
|
145
|
-
return this.lastIndex - this.index;
|
|
146
|
-
}
|
|
147
|
-
/**
|
|
148
|
-
* Max number of elements in half (not counting the middle one).
|
|
149
|
-
*/
|
|
150
|
-
get maxHalfLength() {
|
|
151
|
-
return this.sidePadding + DOTS_LENGTH + this.activePadding;
|
|
152
|
-
}
|
|
153
|
-
/**
|
|
154
|
-
* Is there '...' anywhere
|
|
155
|
-
*/
|
|
156
|
-
get itemsFit() {
|
|
157
|
-
return this.length <= this.maxElementsLength;
|
|
158
|
-
}
|
|
159
|
-
/**
|
|
160
|
-
* Max number of elements
|
|
161
|
-
*/
|
|
162
|
-
get maxElementsLength() {
|
|
163
|
-
return this.maxHalfLength * 2 + ACTIVE_ITEM_LENGTH;
|
|
164
|
-
}
|
|
165
|
-
get lastIndex() {
|
|
166
|
-
return this.length - 1;
|
|
167
|
-
}
|
|
168
|
-
get lastElementIndex() {
|
|
169
|
-
return this.elementsLength - 1;
|
|
114
|
+
this.nativeFocusableElement()?.focus();
|
|
170
115
|
}
|
|
171
116
|
/**
|
|
172
117
|
* Are there collapsed items at that index
|
|
@@ -174,51 +119,25 @@ class TuiPagination {
|
|
|
174
119
|
* @returns there are collapsed items
|
|
175
120
|
*/
|
|
176
121
|
hasCollapsedItems(index) {
|
|
177
|
-
return !this.itemsFit && index > this.maxHalfLength;
|
|
122
|
+
return !this.itemsFit() && index > this.maxHalfLength();
|
|
178
123
|
}
|
|
179
124
|
tryChangeTo(direction) {
|
|
180
|
-
this.updateIndex(tuiClamp(this.index + (direction === 'right' ? 1 : -1), 0, this.lastIndex));
|
|
181
|
-
}
|
|
182
|
-
focusActive() {
|
|
183
|
-
const { nativeFocusableElement } = this;
|
|
184
|
-
if (nativeFocusableElement) {
|
|
185
|
-
nativeFocusableElement.focus();
|
|
186
|
-
}
|
|
125
|
+
this.updateIndex(tuiClamp(this.index() + (direction === 'right' ? 1 : -1), 0, this.lastIndex()));
|
|
187
126
|
}
|
|
188
127
|
updateIndex(index) {
|
|
189
|
-
if (this.index
|
|
190
|
-
|
|
128
|
+
if (this.index() !== index) {
|
|
129
|
+
this.index.set(index);
|
|
191
130
|
}
|
|
192
|
-
this.index = index;
|
|
193
|
-
this.indexChange.emit(index);
|
|
194
131
|
}
|
|
195
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
196
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.
|
|
132
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiPagination, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
133
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.17", type: TuiPagination, isStandalone: true, selector: "tui-pagination", inputs: { length: { classPropertyName: "length", publicName: "length", isSignal: true, isRequired: false, transformFunction: null }, focusable: { classPropertyName: "focusable", publicName: "focusable", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, activePadding: { classPropertyName: "activePadding", publicName: "activePadding", isSignal: true, isRequired: false, transformFunction: null }, sidePadding: { classPropertyName: "sidePadding", publicName: "sidePadding", isSignal: true, isRequired: false, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null }, index: { classPropertyName: "index", publicName: "index", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { index: "indexChange" }, viewQueries: [{ propertyName: "els", predicate: ["element"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div class=\"t-content\">\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledLeft()\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[0] }}\n </button>\n @for (_ of '-'.repeat(elementsLength()); track $index) {\n @let index = getItemIndexByElementIndex($index);\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled()\"\n [size]=\"buttonSize()\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container *polymorpheusOutlet=\"content() || index + 1 as text; context: {$implicit: index}\">\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-ellipsis\"\n [class.t-ellipsis_small]=\"size() === 'm'\"\n ></div>\n }\n }\n\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledRight()\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[1] }}\n </button>\n</div>\n", styles: [":host{display:block;font:var(--tui-font-body-s);color:var(--tui-text-primary);text-align:center}.t-content{display:flex;justify-content:center}.t-button{margin:0 .125rem;flex-shrink:0}.t-button[tuiButton]:not(.t-button_small){min-inline-size:var(--tui-height-s);padding:0 .5rem}.t-button[tuiButton]:not(.t-button_small)[data-size=xs]{min-inline-size:var(--tui-height-xs);padding:0 .375rem}.t-button:first-child{transform:scaleX(var(--tui-inline));margin-inline-start:0}.t-button:last-child{transform:scaleX(var(--tui-inline));margin-inline-end:0}.t-ellipsis{inline-size:var(--tui-height-s);block-size:var(--tui-height-s);line-height:var(--tui-height-s);margin:0 .125rem;flex-shrink:0;color:var(--tui-text-action);text-align:center;cursor:default}.t-ellipsis_small{inline-size:var(--tui-height-xs);block-size:var(--tui-height-xs);line-height:var(--tui-height-xs)}.t-ellipsis:before{content:\"\\2026\"}\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"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
197
134
|
}
|
|
198
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
135
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.17", ngImport: i0, type: TuiPagination, decorators: [{
|
|
199
136
|
type: Component,
|
|
200
|
-
args: [{ selector: 'tui-pagination', imports: [PolymorpheusOutlet, TuiButton
|
|
137
|
+
args: [{ selector: 'tui-pagination', imports: [PolymorpheusOutlet, TuiButton], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"t-content\">\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledLeft()\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[0] }}\n </button>\n @for (_ of '-'.repeat(elementsLength()); track $index) {\n @let index = getItemIndexByElementIndex($index);\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled()\"\n [size]=\"buttonSize()\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container *polymorpheusOutlet=\"content() || index + 1 as text; context: {$implicit: index}\">\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-ellipsis\"\n [class.t-ellipsis_small]=\"size() === 'm'\"\n ></div>\n }\n }\n\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledRight()\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[1] }}\n </button>\n</div>\n", styles: [":host{display:block;font:var(--tui-font-body-s);color:var(--tui-text-primary);text-align:center}.t-content{display:flex;justify-content:center}.t-button{margin:0 .125rem;flex-shrink:0}.t-button[tuiButton]:not(.t-button_small){min-inline-size:var(--tui-height-s);padding:0 .5rem}.t-button[tuiButton]:not(.t-button_small)[data-size=xs]{min-inline-size:var(--tui-height-xs);padding:0 .375rem}.t-button:first-child{transform:scaleX(var(--tui-inline));margin-inline-start:0}.t-button:last-child{transform:scaleX(var(--tui-inline));margin-inline-end:0}.t-ellipsis{inline-size:var(--tui-height-s);block-size:var(--tui-height-s);line-height:var(--tui-height-s);margin:0 .125rem;flex-shrink:0;color:var(--tui-text-action);text-align:center;cursor:default}.t-ellipsis_small{inline-size:var(--tui-height-xs);block-size:var(--tui-height-xs);line-height:var(--tui-height-xs)}.t-ellipsis:before{content:\"\\2026\"}\n"] }]
|
|
201
138
|
}], propDecorators: { els: [{
|
|
202
139
|
type: ViewChildren,
|
|
203
140
|
args: ['element', { read: ElementRef }]
|
|
204
|
-
}], length: [{
|
|
205
|
-
type: Input
|
|
206
|
-
}], focusable: [{
|
|
207
|
-
type: Input
|
|
208
|
-
}], size: [{
|
|
209
|
-
type: Input
|
|
210
|
-
}], disabled: [{
|
|
211
|
-
type: Input
|
|
212
|
-
}], activePadding: [{
|
|
213
|
-
type: Input
|
|
214
|
-
}], sidePadding: [{
|
|
215
|
-
type: Input
|
|
216
|
-
}], content: [{
|
|
217
|
-
type: Input
|
|
218
|
-
}], index: [{
|
|
219
|
-
type: Input
|
|
220
|
-
}], indexChange: [{
|
|
221
|
-
type: Output
|
|
222
141
|
}] } });
|
|
223
142
|
|
|
224
143
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-kit-components-pagination.mjs","sources":["../../../projects/kit/components/pagination/pagination.options.ts","../../../projects/kit/components/pagination/pagination.component.ts","../../../projects/kit/components/pagination/pagination.template.html","../../../projects/kit/components/pagination/taiga-ui-kit-components-pagination.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeL, type TuiSizeS} from '@taiga-ui/core/types';\n\nexport interface TuiPaginationOptions {\n readonly appearance: TuiStringHandler<{\n isActive: boolean;\n size: TuiSizeL | TuiSizeS;\n }>;\n readonly defaultSize: TuiSizeL | TuiSizeS;\n}\n\nexport const [TUI_PAGINATION_OPTIONS, tuiPaginationOptionsProvider] =\n tuiCreateOptions<TuiPaginationOptions>({\n appearance: ({isActive, size}) => {\n const fallback = size === 's' ? 'secondary' : 'flat';\n\n return isActive ? 'primary' : fallback;\n },\n defaultSize: 'l',\n });\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n inject,\n Input,\n Output,\n type QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {EMPTY_QUERY} from '@taiga-ui/cdk/constants';\nimport {TuiRepeatTimes} from '@taiga-ui/cdk/directives/repeat-times';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TUI_SPIN_ICONS} from '@taiga-ui/core/tokens';\nimport {\n type TuiHorizontalDirection,\n type TuiSizeL,\n type TuiSizeS,\n type TuiSizeXS,\n} from '@taiga-ui/core/types';\nimport {TUI_PAGINATION_TEXTS} from '@taiga-ui/kit/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_PAGINATION_OPTIONS} from './pagination.options';\n\nconst DOTS_LENGTH = 1;\nconst ACTIVE_ITEM_LENGTH = 1;\n\n@Component({\n selector: 'tui-pagination',\n imports: [PolymorpheusOutlet, TuiButton, TuiRepeatTimes],\n templateUrl: './pagination.template.html',\n styleUrl: './pagination.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPagination {\n @ViewChildren('element', {read: ElementRef})\n private readonly els: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n private readonly el = tuiInjectElement();\n\n protected readonly texts = inject(TUI_PAGINATION_TEXTS);\n protected readonly icons = inject(TUI_SPIN_ICONS);\n protected readonly options = inject(TUI_PAGINATION_OPTIONS);\n\n @Input()\n public length = 1;\n\n @Input()\n public focusable = true;\n\n @Input()\n public size: TuiSizeL | TuiSizeS = this.options.defaultSize;\n\n @Input()\n public readonly disabled = false;\n\n /**\n * Amount of visible pages around active page\n */\n @Input()\n public activePadding = 1;\n\n /**\n * Amount of visible pages at the edges\n */\n @Input()\n public sidePadding = 1;\n\n /**\n * Customization for page number display.\n */\n @Input()\n public content: PolymorpheusContent<TuiContext<number>>;\n\n /**\n * Active page index\n */\n @Input()\n public index = 0;\n\n @Output()\n public readonly indexChange = new EventEmitter<number>();\n\n public get nativeFocusableElement(): HTMLElement | null {\n if (this.disabled) {\n return null;\n }\n\n let activeElementIndex = 0;\n const {elementsLength} = this;\n\n for (let i = 0; i < elementsLength; i++) {\n const itemIndex = this.getItemIndexByElementIndex(i);\n\n if (itemIndex) {\n activeElementIndex++;\n }\n\n if (itemIndex === this.index) {\n break;\n }\n }\n\n return (\n this.els.find((_, index) => index === activeElementIndex)?.nativeElement ??\n null\n );\n }\n\n public get focused(): boolean {\n return tuiIsFocusedIn(this.el);\n }\n\n public get arrowIsDisabledLeft(): boolean {\n return this.index === 0;\n }\n\n public get arrowIsDisabledRight(): boolean {\n return this.reverseIndex === 0;\n }\n\n /**\n * Number of items in a container.\n */\n protected get elementsLength(): number {\n return this.itemsFit ? this.length : this.maxElementsLength;\n }\n\n protected get buttonSize(): TuiSizeXS {\n return this.size === 'm' ? 'xs' : 's';\n }\n\n protected elementIsFocusable(index: number): boolean {\n return this.index === index && !this.focused;\n }\n\n /**\n * Get index by element index\n * @param elementIndex\n * @returns index or null (for '…')\n */\n protected getItemIndexByElementIndex(elementIndex: number): number | null {\n if (this.size === 's') {\n return elementIndex;\n }\n\n if (elementIndex < this.sidePadding) {\n return elementIndex;\n }\n\n if (elementIndex === this.sidePadding && this.hasCollapsedItems(this.index)) {\n return null;\n }\n\n const reverseElementIndex = this.lastElementIndex - elementIndex;\n\n if (\n reverseElementIndex === this.sidePadding &&\n this.hasCollapsedItems(this.reverseIndex)\n ) {\n return null;\n }\n\n if (reverseElementIndex < this.sidePadding) {\n return this.lastIndex - reverseElementIndex;\n }\n\n const computedIndex = this.index - this.maxHalfLength + elementIndex;\n\n return tuiClamp(\n computedIndex,\n elementIndex,\n this.lastIndex - reverseElementIndex,\n );\n }\n\n protected getElementMode(index = -1): string {\n return this.options.appearance({\n isActive: this.index === index,\n size: this.size,\n });\n }\n\n protected onElementClick(index: number): void {\n this.updateIndex(index);\n }\n\n protected onElementKeyDownArrowLeft(element: HTMLElement): void {\n if (element === this.els.first.nativeElement) {\n return;\n }\n\n const previous = this.els.find(\n (_, index, array) => array[index + 1]?.nativeElement === element,\n );\n\n previous?.nativeElement.focus();\n }\n\n protected onElementKeyDownArrowRight(element: HTMLElement): void {\n if (element === this.els.last.nativeElement) {\n return;\n }\n\n const next = this.els.find(\n (_, index, array) => array[index - 1]?.nativeElement === element,\n );\n\n next?.nativeElement.focus();\n }\n\n protected onArrowClick(direction: TuiHorizontalDirection): void {\n this.tryChangeTo(direction);\n this.focusActive();\n }\n\n /**\n * Active index from the end\n */\n private get reverseIndex(): number {\n return this.lastIndex - this.index;\n }\n\n /**\n * Max number of elements in half (not counting the middle one).\n */\n private get maxHalfLength(): number {\n return this.sidePadding + DOTS_LENGTH + this.activePadding;\n }\n\n /**\n * Is there '...' anywhere\n */\n private get itemsFit(): boolean {\n return this.length <= this.maxElementsLength;\n }\n\n /**\n * Max number of elements\n */\n private get maxElementsLength(): number {\n return this.maxHalfLength * 2 + ACTIVE_ITEM_LENGTH;\n }\n\n private get lastIndex(): number {\n return this.length - 1;\n }\n\n private get lastElementIndex(): number {\n return this.elementsLength - 1;\n }\n\n /**\n * Are there collapsed items at that index\n * @param index\n * @returns there are collapsed items\n */\n private hasCollapsedItems(index: number): boolean {\n return !this.itemsFit && index > this.maxHalfLength;\n }\n\n private tryChangeTo(direction: TuiHorizontalDirection): void {\n this.updateIndex(\n tuiClamp(this.index + (direction === 'right' ? 1 : -1), 0, this.lastIndex),\n );\n }\n\n private focusActive(): void {\n const {nativeFocusableElement} = this;\n\n if (nativeFocusableElement) {\n nativeFocusableElement.focus();\n }\n }\n\n private updateIndex(index: number): void {\n if (this.index === index) {\n return;\n }\n\n this.index = index;\n this.indexChange.emit(index);\n }\n}\n","<div class=\"t-content\">\n @if (size !== 's') {\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledLeft\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[0] }}\n </button>\n <ng-container *tuiRepeatTimes=\"let elementIndex of elementsLength\">\n @let index = getItemIndexByElementIndex(elementIndex);\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled\"\n [size]=\"buttonSize\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container *polymorpheusOutlet=\"content || index + 1 as text; context: {$implicit: index}\">\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-dots\"\n [class.t-dots_small]=\"size === 'm'\"\n ></div>\n }\n </ng-container>\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledRight\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[1] }}\n </button>\n } @else {\n <button\n *tuiRepeatTimes=\"let indexItem of length\"\n #element\n tuiButton\n type=\"button\"\n class=\"t-button t-button_small\"\n [appearance]=\"getElementMode(indexItem)\"\n [disabled]=\"disabled\"\n [tabIndex]=\"elementIsFocusable(indexItem) ? 0 : -1\"\n (click)=\"onElementClick(indexItem)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n {{ indexItem + 1 }}\n </button>\n }\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAYa,CAAC,sBAAsB,EAAE,4BAA4B,CAAC,GAC/D,gBAAgB,CAAuB;IACnC,UAAU,EAAE,CAAC,EAAC,QAAQ,EAAE,IAAI,EAAC,KAAI;AAC7B,QAAA,MAAM,QAAQ,GAAG,IAAI,KAAK,GAAG,GAAG,WAAW,GAAG,MAAM;QAEpD,OAAO,QAAQ,GAAG,SAAS,GAAG,QAAQ;KACzC;AACD,IAAA,WAAW,EAAE,GAAG;AACnB,CAAA;;ACUL,MAAM,WAAW,GAAG,CAAC;AACrB,MAAM,kBAAkB,GAAG,CAAC;MASf,aAAa,CAAA;AAP1B,IAAA,WAAA,GAAA;QASqB,IAAG,CAAA,GAAA,GAAuC,WAAW;QAErD,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAErB,QAAA,IA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S,EAAE,cAAc,CAAC,EAAA,eAAA,EAGvC,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,w8FAAA,EAAA,MAAA,EAAA,CAAA,6nCAAA,CAAA,EAAA;8BAI9B,GAAG,EAAA,CAAA;sBADnB,YAAY;AAAC,gBAAA,IAAA,EAAA,CAAA,SAAS,EAAE,EAAC,IAAI,EAAE,UAAU,EAAC;gBAUpC,MAAM,EAAA,CAAA;sBADZ;gBAIM,SAAS,EAAA,CAAA;sBADf;gBAIM,IAAI,EAAA,CAAA;sBADV;gBAIe,QAAQ,EAAA,CAAA;sBADvB;gBAOM,aAAa,EAAA,CAAA;sBADnB;gBAOM,WAAW,EAAA,CAAA;sBADjB;gBAOM,OAAO,EAAA,CAAA;sBADb;gBAOM,KAAK,EAAA,CAAA;sBADX;gBAIe,WAAW,EAAA,CAAA;sBAD1B;;;AEtFL;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-kit-components-pagination.mjs","sources":["../../../projects/kit/components/pagination/pagination.options.ts","../../../projects/kit/components/pagination/pagination.component.ts","../../../projects/kit/components/pagination/pagination.template.html","../../../projects/kit/components/pagination/taiga-ui-kit-components-pagination.ts"],"sourcesContent":["import {type TuiStringHandler} from '@taiga-ui/cdk/types';\nimport {tuiCreateOptions} from '@taiga-ui/cdk/utils/di';\nimport {type TuiSizeL} from '@taiga-ui/core/types';\n\nexport interface TuiPaginationOptions {\n readonly size: TuiSizeL;\n readonly appearance: TuiStringHandler<boolean>;\n}\n\nexport const [TUI_PAGINATION_OPTIONS, tuiPaginationOptionsProvider] =\n tuiCreateOptions<TuiPaginationOptions>({\n size: 'l',\n appearance: (isActive) => (isActive ? 'primary' : 'flat'),\n });\n","import {\n ChangeDetectionStrategy,\n Component,\n computed,\n ElementRef,\n inject,\n input,\n model,\n type QueryList,\n ViewChildren,\n} from '@angular/core';\nimport {EMPTY_QUERY} from '@taiga-ui/cdk/constants';\nimport {type TuiContext} from '@taiga-ui/cdk/types';\nimport {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';\nimport {tuiIsFocusedIn} from '@taiga-ui/cdk/utils/focus';\nimport {tuiClamp} from '@taiga-ui/cdk/utils/math';\nimport {TuiButton} from '@taiga-ui/core/components/button';\nimport {TUI_COMMON_ICONS} from '@taiga-ui/core/tokens';\nimport {type TuiHorizontalDirection} from '@taiga-ui/core/types';\nimport {TUI_PAGINATION_TEXTS} from '@taiga-ui/kit/tokens';\nimport {type PolymorpheusContent, PolymorpheusOutlet} from '@taiga-ui/polymorpheus';\n\nimport {TUI_PAGINATION_OPTIONS} from './pagination.options';\n\nconst ELLIPSIS_ITEM_LENGTH = 1;\nconst ACTIVE_ITEM_LENGTH = 1;\n\n@Component({\n selector: 'tui-pagination',\n imports: [PolymorpheusOutlet, TuiButton],\n templateUrl: './pagination.template.html',\n styleUrl: './pagination.style.less',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPagination {\n @ViewChildren('element', {read: ElementRef})\n private readonly els: QueryList<ElementRef<HTMLElement>> = EMPTY_QUERY;\n\n private readonly el = tuiInjectElement();\n\n private readonly maxHalfLength = computed(\n () => this.sidePadding() + ELLIPSIS_ITEM_LENGTH + this.activePadding(),\n );\n\n private readonly maxElementsLength = computed(\n () => this.maxHalfLength() * 2 + ACTIVE_ITEM_LENGTH,\n );\n\n private readonly lastElementIndex = computed(() => this.elementsLength() - 1);\n private readonly itemsFit = computed(() => this.length() <= this.maxElementsLength());\n private readonly lastIndex = computed(() => this.length() - 1);\n\n private readonly reverseIndex = computed(\n (): number => this.lastIndex() - this.index(),\n );\n\n protected readonly texts = inject(TUI_PAGINATION_TEXTS);\n protected readonly icons = inject(TUI_COMMON_ICONS);\n protected readonly options = inject(TUI_PAGINATION_OPTIONS);\n\n protected readonly buttonSize = computed(() => (this.size() === 'm' ? 'xs' : 's'));\n\n protected readonly elementsLength = computed(() =>\n this.itemsFit() ? this.length() : this.maxElementsLength(),\n );\n\n public readonly length = input(1);\n public readonly focusable = input(true);\n public readonly size = input(this.options.size);\n public readonly disabled = input(false);\n public readonly activePadding = input(1);\n public readonly sidePadding = input(1);\n public readonly content = input<PolymorpheusContent<TuiContext<number>>>();\n public readonly index = model(0);\n public readonly arrowIsDisabledRight = computed(() => this.reverseIndex() === 0);\n public readonly arrowIsDisabledLeft = computed(() => this.index() === 0);\n public readonly nativeFocusableElement = computed((): HTMLElement | null => {\n if (this.disabled()) {\n return null;\n }\n\n let activeElementIndex = 0;\n\n for (let i = 0; i < this.elementsLength(); i++) {\n const itemIndex = this.getItemIndexByElementIndex(i);\n\n if (itemIndex) {\n activeElementIndex++;\n }\n\n if (itemIndex === this.index()) {\n break;\n }\n }\n\n return (\n this.els.find((_, index) => index === activeElementIndex)?.nativeElement ??\n null\n );\n });\n\n public get focused(): boolean {\n return tuiIsFocusedIn(this.el);\n }\n\n protected elementIsFocusable(index: number): boolean {\n return this.index() === index && !this.focused;\n }\n\n /**\n * Get index by element index\n * @param elementIndex\n * @returns index or null (for '…')\n */\n protected getItemIndexByElementIndex(elementIndex: number): number | null {\n const reverseElementIndex = this.lastElementIndex() - elementIndex;\n\n if (elementIndex < this.sidePadding()) {\n return elementIndex;\n }\n\n if (reverseElementIndex < this.sidePadding()) {\n return this.lastIndex() - reverseElementIndex;\n }\n\n if (elementIndex === this.sidePadding() && this.hasCollapsedItems(this.index())) {\n return null;\n }\n\n if (\n reverseElementIndex === this.sidePadding() &&\n this.hasCollapsedItems(this.reverseIndex())\n ) {\n return null;\n }\n\n const computedIndex = this.index() - this.maxHalfLength() + elementIndex;\n\n return tuiClamp(\n computedIndex,\n elementIndex,\n this.lastIndex() - reverseElementIndex,\n );\n }\n\n protected getElementMode(index = -1): string {\n return this.options.appearance(this.index() === index);\n }\n\n protected onElementClick(index: number): void {\n this.updateIndex(index);\n }\n\n protected onElementKeyDownArrowLeft(element: HTMLElement): void {\n if (element === this.els.first.nativeElement) {\n return;\n }\n\n const previous = this.els.find(\n (_, index, array) => array[index + 1]?.nativeElement === element,\n );\n\n previous?.nativeElement.focus();\n }\n\n protected onElementKeyDownArrowRight(element: HTMLElement): void {\n if (element === this.els.last.nativeElement) {\n return;\n }\n\n const next = this.els.find(\n (_, index, array) => array[index - 1]?.nativeElement === element,\n );\n\n next?.nativeElement.focus();\n }\n\n protected onArrowClick(direction: TuiHorizontalDirection): void {\n this.tryChangeTo(direction);\n this.nativeFocusableElement()?.focus();\n }\n\n /**\n * Are there collapsed items at that index\n * @param index\n * @returns there are collapsed items\n */\n private hasCollapsedItems(index: number): boolean {\n return !this.itemsFit() && index > this.maxHalfLength();\n }\n\n private tryChangeTo(direction: TuiHorizontalDirection): void {\n this.updateIndex(\n tuiClamp(\n this.index() + (direction === 'right' ? 1 : -1),\n 0,\n this.lastIndex(),\n ),\n );\n }\n\n private updateIndex(index: number): void {\n if (this.index() !== index) {\n this.index.set(index);\n }\n }\n}\n","<div class=\"t-content\">\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledLeft()\"\n [iconStart]=\"icons.decrement\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('left')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[0] }}\n </button>\n @for (_ of '-'.repeat(elementsLength()); track $index) {\n @let index = getItemIndexByElementIndex($index);\n @if (index !== null) {\n <button\n #element\n automation-id=\"tui-pagination__element\"\n tuiButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode(index)\"\n [disabled]=\"disabled()\"\n [size]=\"buttonSize()\"\n [tabIndex]=\"elementIsFocusable(index) ? 0 : -1\"\n (click)=\"onElementClick(index)\"\n (keydown.arrowLeft.prevent)=\"onElementKeyDownArrowLeft(element)\"\n (keydown.arrowRight.prevent)=\"onElementKeyDownArrowRight(element)\"\n >\n <ng-container *polymorpheusOutlet=\"content() || index + 1 as text; context: {$implicit: index}\">\n {{ text }}\n </ng-container>\n </button>\n } @else {\n <div\n automation-id=\"tui-pagination__element\"\n class=\"t-ellipsis\"\n [class.t-ellipsis_small]=\"size() === 'm'\"\n ></div>\n }\n }\n\n <button\n tabIndex=\"-1\"\n tuiIconButton\n type=\"button\"\n class=\"t-button\"\n [appearance]=\"getElementMode()\"\n [disabled]=\"arrowIsDisabledRight()\"\n [iconStart]=\"icons.increment\"\n [size]=\"buttonSize()\"\n (click)=\"onArrowClick('right')\"\n (mousedown.zoneless.prevent)=\"(0)\"\n >\n {{ texts()[1] }}\n </button>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;MASa,CAAC,sBAAsB,EAAE,4BAA4B,CAAC,GAC/D,gBAAgB,CAAuB;AACnC,IAAA,IAAI,EAAE,GAAG;AACT,IAAA,UAAU,EAAE,CAAC,QAAQ,MAAM,QAAQ,GAAG,SAAS,GAAG,MAAM,CAAC;AAC5D,CAAA;;ACWL,MAAM,oBAAoB,GAAG,CAAC;AAC9B,MAAM,kBAAkB,GAAG,CAAC;MASf,aAAa,CAAA;AAP1B,IAAA,WAAA,GAAA;QASqB,IAAG,CAAA,GAAA,GAAuC,WAAW;QAErD,IAAE,CAAA,EAAA,GAAG,gBAAgB,EAAE;AAEvB,QAAA,IAAA,CAAA,aAAa,GAAG,QAAQ,CACrC,MAAM,IAAI,CAAC,WAAW,EAAE,GAAG,oBAAoB,GAAG,IAAI,CAAC,aAAa,EAAE,CACzE;AAEgB,QAAA,IAAA,CAAA,iBAAiB,GAAG,QAAQ,CACzC,MAAM,IAAI,CAAC,aAAa,EAAE,GAAG,CAAC,GAAG,kBAAkB,CACtD;AAEgB,QAAA,IAAA,CAAA,gBAAgB,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,cAAc,EAAE,GAAG,CAAC,CAAC;AAC5D,QAAA,IAAA,CAAA,QAAQ,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,MAAM,EAAE,IAAI,IAAI,CAAC,iBAA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