@taiga-ui/core 2.75.0 → 2.76.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/abstract/abstract-dropdown.d.ts +2 -2
- package/abstract/taiga-ui-core-abstract.metadata.json +1 -1
- package/bundles/taiga-ui-core-abstract.umd.js +49 -2
- package/bundles/taiga-ui-core-abstract.umd.js.map +1 -1
- package/bundles/taiga-ui-core-abstract.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-alert.umd.js +55 -10
- package/bundles/taiga-ui-core-components-alert.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-alert.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-button.umd.js +60 -15
- package/bundles/taiga-ui-core-components-button.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-button.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-calendar.umd.js +47 -2
- package/bundles/taiga-ui-core-components-calendar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-calendar.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-data-list.umd.js +83 -39
- package/bundles/taiga-ui-core-components-data-list.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-data-list.umd.min.js +1 -1
- package/bundles/taiga-ui-core-components-data-list.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-dialog.umd.js +60 -15
- package/bundles/taiga-ui-core-components-dialog.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-dialog.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-dropdown-box.umd.js +84 -39
- package/bundles/taiga-ui-core-components-dropdown-box.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-dropdown-box.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-error.umd.js +50 -5
- package/bundles/taiga-ui-core-components-error.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-error.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-expand.umd.js +58 -13
- package/bundles/taiga-ui-core-components-expand.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-expand.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-group.umd.js +64 -19
- package/bundles/taiga-ui-core-components-group.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-group.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-hints-host.umd.js +93 -48
- package/bundles/taiga-ui-core-components-hints-host.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-hints-host.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js +56 -11
- package/bundles/taiga-ui-core-components-hosted-dropdown.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-hosted-dropdown.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-label.umd.js +51 -6
- package/bundles/taiga-ui-core-components-label.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-label.umd.min.js +1 -1
- package/bundles/taiga-ui-core-components-label.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-link.umd.js +57 -12
- package/bundles/taiga-ui-core-components-link.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-link.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-loader.umd.js +48 -3
- package/bundles/taiga-ui-core-components-loader.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-loader.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-notification.umd.js +54 -9
- package/bundles/taiga-ui-core-components-notification.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-notification.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-calendar.umd.js +48 -3
- package/bundles/taiga-ui-core-components-primitive-calendar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-calendar.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-checkbox.umd.js +49 -4
- package/bundles/taiga-ui-core-components-primitive-checkbox.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-checkbox.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-spin-button.umd.js +48 -3
- package/bundles/taiga-ui-core-components-primitive-spin-button.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-spin-button.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-textfield.umd.js +97 -52
- package/bundles/taiga-ui-core-components-primitive-textfield.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-textfield.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js +48 -3
- package/bundles/taiga-ui-core-components-primitive-year-picker.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-primitive-year-picker.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-root.umd.js +50 -5
- package/bundles/taiga-ui-core-components-root.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-root.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-scroll-controls.umd.js +72 -27
- package/bundles/taiga-ui-core-components-scroll-controls.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-scroll-controls.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-scrollbar.umd.js +54 -9
- package/bundles/taiga-ui-core-components-scrollbar.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-scrollbar.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-svg.umd.js +61 -16
- package/bundles/taiga-ui-core-components-svg.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-svg.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-theme-night.umd.js +48 -3
- package/bundles/taiga-ui-core-components-theme-night.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-theme-night.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-components-tooltip.umd.js +53 -8
- package/bundles/taiga-ui-core-components-tooltip.umd.js.map +1 -1
- package/bundles/taiga-ui-core-components-tooltip.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-color.umd.js +52 -7
- package/bundles/taiga-ui-core-directives-color.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-color.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-described-by.umd.js +50 -5
- package/bundles/taiga-ui-core-directives-described-by.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-described-by.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-dropdown-controller.umd.js +55 -10
- package/bundles/taiga-ui-core-directives-dropdown-controller.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-dropdown-controller.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-dropdown.umd.js +48 -3
- package/bundles/taiga-ui-core-directives-dropdown.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-dropdown.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-hint-controller.umd.js +52 -7
- package/bundles/taiga-ui-core-directives-hint-controller.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-hint-controller.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-hint.umd.js +51 -6
- package/bundles/taiga-ui-core-directives-hint.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-hint.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-manual-hint.umd.js +49 -4
- package/bundles/taiga-ui-core-directives-manual-hint.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-manual-hint.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mask-accessor.umd.js +47 -2
- package/bundles/taiga-ui-core-directives-mask-accessor.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mask-accessor.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mode.umd.js +48 -3
- package/bundles/taiga-ui-core-directives-mode.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-mode.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-pointer-hint.umd.js +50 -5
- package/bundles/taiga-ui-core-directives-pointer-hint.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-pointer-hint.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-scroll-into-view.umd.js +47 -2
- package/bundles/taiga-ui-core-directives-scroll-into-view.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-scroll-into-view.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-table-mode.umd.js +48 -3
- package/bundles/taiga-ui-core-directives-table-mode.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-table-mode.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-textfield-controller.umd.js +79 -34
- package/bundles/taiga-ui-core-directives-textfield-controller.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-textfield-controller.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-directives-wrapper.umd.js +55 -10
- package/bundles/taiga-ui-core-directives-wrapper.umd.js.map +1 -1
- package/bundles/taiga-ui-core-directives-wrapper.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js +47 -2
- package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.js.map +1 -1
- package/bundles/taiga-ui-core-internal-primitive-year-month-pagination.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-internal-svg-defs-host.umd.js +47 -2
- package/bundles/taiga-ui-core-internal-svg-defs-host.umd.js.map +1 -1
- package/bundles/taiga-ui-core-internal-svg-defs-host.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-calendar-sheet.umd.js +47 -2
- package/bundles/taiga-ui-core-pipes-calendar-sheet.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-calendar-sheet.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-date.umd.js +46 -1
- package/bundles/taiga-ui-core-pipes-format-date.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-date.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-number.umd.js +46 -1
- package/bundles/taiga-ui-core-pipes-format-number.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-number.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-phone.umd.js +46 -1
- package/bundles/taiga-ui-core-pipes-format-phone.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-format-phone.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-month.umd.js +46 -1
- package/bundles/taiga-ui-core-pipes-month.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-month.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-pluralize.umd.js +46 -1
- package/bundles/taiga-ui-core-pipes-pluralize.umd.js.map +1 -1
- package/bundles/taiga-ui-core-pipes-pluralize.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-services.umd.js +46 -1
- package/bundles/taiga-ui-core-services.umd.js.map +1 -1
- package/bundles/taiga-ui-core-services.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-tokens.umd.js +46 -1
- package/bundles/taiga-ui-core-tokens.umd.js.map +1 -1
- package/bundles/taiga-ui-core-tokens.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-utils-dom.umd.js +1 -3
- package/bundles/taiga-ui-core-utils-dom.umd.js.map +1 -1
- package/bundles/taiga-ui-core-utils-dom.umd.min.js +1 -1
- package/bundles/taiga-ui-core-utils-dom.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-utils-format.umd.js +46 -1
- package/bundles/taiga-ui-core-utils-format.umd.js.map +1 -1
- package/bundles/taiga-ui-core-utils-format.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-utils-mask.umd.js +47 -2
- package/bundles/taiga-ui-core-utils-mask.umd.js.map +1 -1
- package/bundles/taiga-ui-core-utils-mask.umd.min.js.map +1 -1
- package/bundles/taiga-ui-core-utils-polyfills.umd.js.map +1 -1
- package/bundles/taiga-ui-core-utils-polyfills.umd.min.js.map +1 -1
- package/components/button/button-options.d.ts +3 -3
- package/components/button/button.component.d.ts +2 -2
- package/components/calendar/calendar.component.d.ts +1 -1
- package/components/data-list/option/option.component.d.ts +1 -1
- package/components/dropdown-box/dropdown-box.component.d.ts +3 -3
- package/components/label/taiga-ui-core-components-label.metadata.json +1 -1
- package/components/link/link.component.d.ts +1 -1
- package/components/loader/loader.component.d.ts +1 -1
- package/components/notification/notification.component.d.ts +1 -1
- package/components/primitive-calendar/primitive-calendar.component.d.ts +2 -2
- package/components/primitive-textfield/primitive-textfield.component.d.ts +2 -2
- package/components/primitive-year-picker/primitive-year-picker.component.d.ts +1 -1
- package/components/svg/svg.component.d.ts +1 -1
- package/components/svg/taiga-ui-core-components-svg.metadata.json +1 -1
- package/constants/version.d.ts +1 -1
- package/directives/dropdown-controller/taiga-ui-core-directives-dropdown-controller.metadata.json +1 -1
- package/directives/textfield-controller/textfield-size.directive.d.ts +1 -1
- package/directives/textfield-controller/textfield.controller.d.ts +1 -1
- package/esm2015/abstract/abstract-dropdown.js +1 -1
- package/esm2015/abstract/abstract-textfield-host.js +7 -3
- package/esm2015/components/alert/alert.component.js +10 -10
- package/esm2015/components/button/button-options.js +1 -1
- package/esm2015/components/button/button.component.js +15 -15
- package/esm2015/components/calendar/calendar.component.js +2 -2
- package/esm2015/components/data-list/data-list-dropdown-manager.directive.js +9 -10
- package/esm2015/components/data-list/data-list.component.js +12 -12
- package/esm2015/components/data-list/data-list.directive.js +2 -2
- package/esm2015/components/data-list/opt-group.directive.js +5 -5
- package/esm2015/components/data-list/option/option.component.js +13 -13
- package/esm2015/components/dialog/dialog.component.js +12 -12
- package/esm2015/components/dialog/dialog.directive.js +4 -4
- package/esm2015/components/dropdown-box/dropdown-box.component.js +39 -39
- package/esm2015/components/error/error.component.js +5 -5
- package/esm2015/components/expand/expand-content.directive.js +2 -2
- package/esm2015/components/expand/expand.component.js +12 -12
- package/esm2015/components/group/group-styles.component.js +2 -2
- package/esm2015/components/group/group.component.js +4 -4
- package/esm2015/components/group/group.directive.js +15 -15
- package/esm2015/components/hints-host/hint-box/hint-box.component.js +46 -46
- package/esm2015/components/hints-host/hints-host.component.js +3 -3
- package/esm2015/components/hosted-dropdown/hosted-dropdown-connector.directive.js +2 -2
- package/esm2015/components/hosted-dropdown/hosted-dropdown.component.js +10 -10
- package/esm2015/components/label/label.component.js +6 -6
- package/esm2015/components/link/link.component.js +12 -12
- package/esm2015/components/loader/loader.component.js +3 -3
- package/esm2015/components/notification/notification.component.js +9 -9
- package/esm2015/components/primitive-calendar/primitive-calendar.component.js +3 -3
- package/esm2015/components/primitive-checkbox/primitive-checkbox.component.js +4 -4
- package/esm2015/components/primitive-spin-button/primitive-spin-button.component.js +3 -3
- package/esm2015/components/primitive-textfield/primitive-textfield.component.js +28 -28
- package/esm2015/components/primitive-textfield/primitive-textfield.directive.js +2 -2
- package/esm2015/components/primitive-textfield/textfield/textfield.component.js +13 -13
- package/esm2015/components/primitive-textfield/value-decoration/value-decoration.component.js +12 -12
- package/esm2015/components/primitive-year-picker/primitive-year-picker.component.js +3 -3
- package/esm2015/components/root/root.component.js +5 -5
- package/esm2015/components/scroll-controls/scroll-controls.component.js +4 -4
- package/esm2015/components/scroll-controls/scrollbar-wrapper.directive.js +2 -2
- package/esm2015/components/scroll-controls/scrollbar.directive.js +23 -23
- package/esm2015/components/scrollbar/scroll-ref.directive.js +2 -2
- package/esm2015/components/scrollbar/scrollable.directive.js +2 -2
- package/esm2015/components/scrollbar/scrollbar.component.js +7 -7
- package/esm2015/components/svg/svg.component.js +16 -16
- package/esm2015/components/theme-night/theme-night.component.js +3 -3
- package/esm2015/components/tooltip/tooltip.component.js +8 -8
- package/esm2015/directives/color/color.directive.js +7 -7
- package/esm2015/directives/described-by/described-by.directive.js +5 -5
- package/esm2015/directives/dropdown/dropdown.directive.js +3 -3
- package/esm2015/directives/dropdown-controller/dropdown-controller.directive.js +10 -10
- package/esm2015/directives/hint/hint.directive.js +6 -6
- package/esm2015/directives/hint-controller/hint-controller.directive.js +7 -7
- package/esm2015/directives/manual-hint/manual-hint.directive.js +4 -4
- package/esm2015/directives/mask-accessor/mask-accessor.directive.js +2 -2
- package/esm2015/directives/mode/mode.directive.js +3 -3
- package/esm2015/directives/pointer-hint/pointer-hint.directive.js +5 -5
- package/esm2015/directives/scroll-into-view/scroll-into-view.directive.js +2 -2
- package/esm2015/directives/table-mode/table-mode.directive.js +3 -3
- package/esm2015/directives/textfield-controller/textfield-autocomplete.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-cleaner.directive.js +4 -4
- package/esm2015/directives/textfield-controller/textfield-custom-content.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-example-text.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-input-mode.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-label-outside.directive.js +4 -4
- package/esm2015/directives/textfield-controller/textfield-max-length.directive.js +4 -4
- package/esm2015/directives/textfield-controller/textfield-size.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield-type.directive.js +5 -5
- package/esm2015/directives/textfield-controller/textfield.controller.js +1 -1
- package/esm2015/directives/wrapper/wrapper.directive.js +10 -10
- package/esm2015/interfaces/alert-options.js +1 -1
- package/esm2015/interfaces/dropdown-directive.js +1 -1
- package/esm2015/interfaces/hint.js +1 -1
- package/esm2015/interfaces/notification-options.js +1 -1
- package/esm2015/interfaces/number-format-settings.js +1 -1
- package/esm2015/internal/primitive-year-month-pagination/primitive-year-month-pagination.component.js +2 -2
- package/esm2015/internal/svg-defs-host/svg-defs-host.component.js +2 -2
- package/esm2015/mask/text-mask-list.js +1 -1
- package/esm2015/mask/text-mask-pipe-handler.js +1 -1
- package/esm2015/pipes/calendar-sheet/utils.js +2 -2
- package/esm2015/pipes/format-date/format-date.pipe.js +1 -1
- package/esm2015/types/brightness.js +1 -1
- package/esm2015/types/decimal-symbol.js +1 -1
- package/esm2015/types/decimal.js +1 -1
- package/esm2015/types/dialog-size.js +1 -1
- package/esm2015/types/direction.js +1 -1
- package/esm2015/types/dropdown-width.js +1 -1
- package/esm2015/types/marker-handler.js +1 -1
- package/esm2015/types/option-role.js +1 -1
- package/esm2015/types/orientation.js +1 -1
- package/esm2015/types/size.js +1 -1
- package/esm2015/utils/dom/get-safe-area-size.js +1 -1
- package/esm2015/utils/dom/process-icon.js +2 -4
- package/esm2015/utils/mask/create-number-mask.js +2 -2
- package/esm2015/utils/polyfills/inner-html.js +3 -3
- package/esm5/abstract/abstract-dropdown.js +1 -1
- package/esm5/abstract/abstract-textfield-host.js +4 -2
- package/esm5/components/alert/alert.component.js +10 -10
- package/esm5/components/button/button-options.js +1 -1
- package/esm5/components/button/button.component.js +15 -15
- package/esm5/components/calendar/calendar.component.js +2 -2
- package/esm5/components/data-list/data-list-dropdown-manager.directive.js +10 -11
- package/esm5/components/data-list/data-list.component.js +12 -12
- package/esm5/components/data-list/data-list.directive.js +2 -2
- package/esm5/components/data-list/opt-group.directive.js +5 -5
- package/esm5/components/data-list/option/option.component.js +13 -13
- package/esm5/components/dialog/dialog.component.js +12 -12
- package/esm5/components/dialog/dialog.directive.js +4 -4
- package/esm5/components/dropdown-box/dropdown-box.component.js +39 -39
- package/esm5/components/error/error.component.js +5 -5
- package/esm5/components/expand/expand-content.directive.js +2 -2
- package/esm5/components/expand/expand.component.js +12 -12
- package/esm5/components/group/group-styles.component.js +2 -2
- package/esm5/components/group/group.component.js +4 -4
- package/esm5/components/group/group.directive.js +15 -15
- package/esm5/components/hints-host/hint-box/hint-box.component.js +46 -46
- package/esm5/components/hints-host/hints-host.component.js +3 -3
- package/esm5/components/hosted-dropdown/hosted-dropdown-connector.directive.js +2 -2
- package/esm5/components/hosted-dropdown/hosted-dropdown.component.js +10 -10
- package/esm5/components/label/label.component.js +6 -6
- package/esm5/components/link/link.component.js +12 -12
- package/esm5/components/loader/loader.component.js +3 -3
- package/esm5/components/notification/notification.component.js +9 -9
- package/esm5/components/primitive-calendar/primitive-calendar.component.js +3 -3
- package/esm5/components/primitive-checkbox/primitive-checkbox.component.js +4 -4
- package/esm5/components/primitive-spin-button/primitive-spin-button.component.js +3 -3
- package/esm5/components/primitive-textfield/primitive-textfield.component.js +28 -28
- package/esm5/components/primitive-textfield/primitive-textfield.directive.js +2 -2
- package/esm5/components/primitive-textfield/textfield/textfield.component.js +13 -13
- package/esm5/components/primitive-textfield/value-decoration/value-decoration.component.js +12 -12
- package/esm5/components/primitive-year-picker/primitive-year-picker.component.js +3 -3
- package/esm5/components/root/root.component.js +5 -5
- package/esm5/components/scroll-controls/scroll-controls.component.js +4 -4
- package/esm5/components/scroll-controls/scrollbar-wrapper.directive.js +2 -2
- package/esm5/components/scroll-controls/scrollbar.directive.js +23 -23
- package/esm5/components/scrollbar/scroll-ref.directive.js +2 -2
- package/esm5/components/scrollbar/scrollable.directive.js +2 -2
- package/esm5/components/scrollbar/scrollbar.component.js +7 -7
- package/esm5/components/svg/svg.component.js +16 -16
- package/esm5/components/theme-night/theme-night.component.js +3 -3
- package/esm5/components/tooltip/tooltip.component.js +8 -8
- package/esm5/directives/color/color.directive.js +7 -7
- package/esm5/directives/described-by/described-by.directive.js +5 -5
- package/esm5/directives/dropdown/dropdown.directive.js +3 -3
- package/esm5/directives/dropdown-controller/dropdown-controller.directive.js +10 -10
- package/esm5/directives/hint/hint.directive.js +6 -6
- package/esm5/directives/hint-controller/hint-controller.directive.js +7 -7
- package/esm5/directives/manual-hint/manual-hint.directive.js +4 -4
- package/esm5/directives/mask-accessor/mask-accessor.directive.js +2 -2
- package/esm5/directives/mode/mode.directive.js +3 -3
- package/esm5/directives/pointer-hint/pointer-hint.directive.js +5 -5
- package/esm5/directives/scroll-into-view/scroll-into-view.directive.js +2 -2
- package/esm5/directives/table-mode/table-mode.directive.js +3 -3
- package/esm5/directives/textfield-controller/textfield-autocomplete.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield-cleaner.directive.js +4 -4
- package/esm5/directives/textfield-controller/textfield-custom-content.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield-example-text.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield-input-mode.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield-label-outside.directive.js +4 -4
- package/esm5/directives/textfield-controller/textfield-max-length.directive.js +4 -4
- package/esm5/directives/textfield-controller/textfield-size.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield-type.directive.js +5 -5
- package/esm5/directives/textfield-controller/textfield.controller.js +1 -1
- package/esm5/directives/wrapper/wrapper.directive.js +10 -10
- package/esm5/interfaces/alert-options.js +1 -1
- package/esm5/interfaces/dropdown-directive.js +1 -1
- package/esm5/interfaces/hint.js +1 -1
- package/esm5/interfaces/notification-options.js +1 -1
- package/esm5/interfaces/number-format-settings.js +1 -1
- package/esm5/internal/primitive-year-month-pagination/primitive-year-month-pagination.component.js +2 -2
- package/esm5/internal/svg-defs-host/svg-defs-host.component.js +2 -2
- package/esm5/mask/text-mask-list.js +1 -1
- package/esm5/mask/text-mask-pipe-handler.js +1 -1
- package/esm5/pipes/calendar-sheet/utils.js +2 -2
- package/esm5/pipes/format-date/format-date.pipe.js +1 -1
- package/esm5/types/brightness.js +1 -1
- package/esm5/types/decimal-symbol.js +1 -1
- package/esm5/types/decimal.js +1 -1
- package/esm5/types/dialog-size.js +1 -1
- package/esm5/types/direction.js +1 -1
- package/esm5/types/dropdown-width.js +1 -1
- package/esm5/types/marker-handler.js +1 -1
- package/esm5/types/option-role.js +1 -1
- package/esm5/types/orientation.js +1 -1
- package/esm5/types/size.js +1 -1
- package/esm5/utils/dom/get-safe-area-size.js +1 -1
- package/esm5/utils/dom/process-icon.js +2 -4
- package/esm5/utils/mask/create-number-mask.js +2 -2
- package/esm5/utils/polyfills/inner-html.js +1 -1
- package/fesm2015/taiga-ui-core-abstract.js +6 -2
- package/fesm2015/taiga-ui-core-abstract.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-alert.js +9 -9
- package/fesm2015/taiga-ui-core-components-alert.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-button.js +14 -14
- package/fesm2015/taiga-ui-core-components-button.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-calendar.js +1 -1
- package/fesm2015/taiga-ui-core-components-calendar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-data-list.js +36 -37
- package/fesm2015/taiga-ui-core-components-data-list.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-dialog.js +14 -14
- package/fesm2015/taiga-ui-core-components-dialog.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-dropdown-box.js +38 -38
- package/fesm2015/taiga-ui-core-components-dropdown-box.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-error.js +4 -4
- package/fesm2015/taiga-ui-core-components-error.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-expand.js +12 -12
- package/fesm2015/taiga-ui-core-components-expand.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-group.js +18 -18
- package/fesm2015/taiga-ui-core-components-group.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-hints-host.js +47 -47
- package/fesm2015/taiga-ui-core-components-hints-host.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-hosted-dropdown.js +10 -10
- package/fesm2015/taiga-ui-core-components-hosted-dropdown.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-label.js +5 -5
- package/fesm2015/taiga-ui-core-components-label.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-link.js +11 -11
- package/fesm2015/taiga-ui-core-components-link.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-loader.js +2 -2
- package/fesm2015/taiga-ui-core-components-loader.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-notification.js +8 -8
- package/fesm2015/taiga-ui-core-components-notification.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-calendar.js +2 -2
- package/fesm2015/taiga-ui-core-components-primitive-calendar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-checkbox.js +3 -3
- package/fesm2015/taiga-ui-core-components-primitive-checkbox.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-spin-button.js +2 -2
- package/fesm2015/taiga-ui-core-components-primitive-spin-button.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-textfield.js +51 -51
- package/fesm2015/taiga-ui-core-components-primitive-textfield.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-primitive-year-picker.js +2 -2
- package/fesm2015/taiga-ui-core-components-primitive-year-picker.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-root.js +4 -4
- package/fesm2015/taiga-ui-core-components-root.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-scroll-controls.js +26 -26
- package/fesm2015/taiga-ui-core-components-scroll-controls.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-scrollbar.js +8 -8
- package/fesm2015/taiga-ui-core-components-scrollbar.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-svg.js +15 -15
- package/fesm2015/taiga-ui-core-components-svg.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-theme-night.js +2 -2
- package/fesm2015/taiga-ui-core-components-theme-night.js.map +1 -1
- package/fesm2015/taiga-ui-core-components-tooltip.js +7 -7
- package/fesm2015/taiga-ui-core-components-tooltip.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-color.js +6 -6
- package/fesm2015/taiga-ui-core-directives-color.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-described-by.js +4 -4
- package/fesm2015/taiga-ui-core-directives-described-by.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-dropdown-controller.js +9 -9
- package/fesm2015/taiga-ui-core-directives-dropdown-controller.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-dropdown.js +2 -2
- package/fesm2015/taiga-ui-core-directives-dropdown.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-hint-controller.js +6 -6
- package/fesm2015/taiga-ui-core-directives-hint-controller.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-hint.js +5 -5
- package/fesm2015/taiga-ui-core-directives-hint.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-manual-hint.js +3 -3
- package/fesm2015/taiga-ui-core-directives-manual-hint.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-mask-accessor.js +1 -1
- package/fesm2015/taiga-ui-core-directives-mask-accessor.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-mode.js +2 -2
- package/fesm2015/taiga-ui-core-directives-mode.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-pointer-hint.js +4 -4
- package/fesm2015/taiga-ui-core-directives-pointer-hint.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-scroll-into-view.js +1 -1
- package/fesm2015/taiga-ui-core-directives-scroll-into-view.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-table-mode.js +2 -2
- package/fesm2015/taiga-ui-core-directives-table-mode.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-textfield-controller.js +33 -33
- package/fesm2015/taiga-ui-core-directives-textfield-controller.js.map +1 -1
- package/fesm2015/taiga-ui-core-directives-wrapper.js +9 -9
- package/fesm2015/taiga-ui-core-directives-wrapper.js.map +1 -1
- package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js +1 -1
- package/fesm2015/taiga-ui-core-internal-primitive-year-month-pagination.js.map +1 -1
- package/fesm2015/taiga-ui-core-internal-svg-defs-host.js +1 -1
- package/fesm2015/taiga-ui-core-internal-svg-defs-host.js.map +1 -1
- package/fesm2015/taiga-ui-core-pipes-calendar-sheet.js +1 -1
- package/fesm2015/taiga-ui-core-pipes-calendar-sheet.js.map +1 -1
- package/fesm2015/taiga-ui-core-pipes-format-date.js.map +1 -1
- package/fesm2015/taiga-ui-core-utils-dom.js +1 -3
- package/fesm2015/taiga-ui-core-utils-dom.js.map +1 -1
- package/fesm2015/taiga-ui-core-utils-mask.js +1 -1
- package/fesm2015/taiga-ui-core-utils-mask.js.map +1 -1
- package/fesm2015/taiga-ui-core-utils-polyfills.js +2 -2
- package/fesm2015/taiga-ui-core-utils-polyfills.js.map +1 -1
- package/fesm5/taiga-ui-core-abstract.js +3 -1
- package/fesm5/taiga-ui-core-abstract.js.map +1 -1
- package/fesm5/taiga-ui-core-components-alert.js +9 -9
- package/fesm5/taiga-ui-core-components-alert.js.map +1 -1
- package/fesm5/taiga-ui-core-components-button.js +14 -14
- package/fesm5/taiga-ui-core-components-button.js.map +1 -1
- package/fesm5/taiga-ui-core-components-calendar.js +1 -1
- package/fesm5/taiga-ui-core-components-calendar.js.map +1 -1
- package/fesm5/taiga-ui-core-components-data-list.js +37 -38
- package/fesm5/taiga-ui-core-components-data-list.js.map +1 -1
- package/fesm5/taiga-ui-core-components-dialog.js +14 -14
- package/fesm5/taiga-ui-core-components-dialog.js.map +1 -1
- package/fesm5/taiga-ui-core-components-dropdown-box.js +38 -38
- package/fesm5/taiga-ui-core-components-dropdown-box.js.map +1 -1
- package/fesm5/taiga-ui-core-components-error.js +4 -4
- package/fesm5/taiga-ui-core-components-error.js.map +1 -1
- package/fesm5/taiga-ui-core-components-expand.js +12 -12
- package/fesm5/taiga-ui-core-components-expand.js.map +1 -1
- package/fesm5/taiga-ui-core-components-group.js +18 -18
- package/fesm5/taiga-ui-core-components-group.js.map +1 -1
- package/fesm5/taiga-ui-core-components-hints-host.js +47 -47
- package/fesm5/taiga-ui-core-components-hints-host.js.map +1 -1
- package/fesm5/taiga-ui-core-components-hosted-dropdown.js +10 -10
- package/fesm5/taiga-ui-core-components-hosted-dropdown.js.map +1 -1
- package/fesm5/taiga-ui-core-components-label.js +5 -5
- package/fesm5/taiga-ui-core-components-label.js.map +1 -1
- package/fesm5/taiga-ui-core-components-link.js +11 -11
- package/fesm5/taiga-ui-core-components-link.js.map +1 -1
- package/fesm5/taiga-ui-core-components-loader.js +2 -2
- package/fesm5/taiga-ui-core-components-loader.js.map +1 -1
- package/fesm5/taiga-ui-core-components-notification.js +8 -8
- package/fesm5/taiga-ui-core-components-notification.js.map +1 -1
- package/fesm5/taiga-ui-core-components-primitive-calendar.js +2 -2
- package/fesm5/taiga-ui-core-components-primitive-calendar.js.map +1 -1
- package/fesm5/taiga-ui-core-components-primitive-checkbox.js +3 -3
- package/fesm5/taiga-ui-core-components-primitive-checkbox.js.map +1 -1
- package/fesm5/taiga-ui-core-components-primitive-spin-button.js +2 -2
- package/fesm5/taiga-ui-core-components-primitive-spin-button.js.map +1 -1
- package/fesm5/taiga-ui-core-components-primitive-textfield.js +51 -51
- package/fesm5/taiga-ui-core-components-primitive-textfield.js.map +1 -1
- package/fesm5/taiga-ui-core-components-primitive-year-picker.js +2 -2
- package/fesm5/taiga-ui-core-components-primitive-year-picker.js.map +1 -1
- package/fesm5/taiga-ui-core-components-root.js +4 -4
- package/fesm5/taiga-ui-core-components-root.js.map +1 -1
- package/fesm5/taiga-ui-core-components-scroll-controls.js +26 -26
- package/fesm5/taiga-ui-core-components-scroll-controls.js.map +1 -1
- package/fesm5/taiga-ui-core-components-scrollbar.js +8 -8
- package/fesm5/taiga-ui-core-components-scrollbar.js.map +1 -1
- package/fesm5/taiga-ui-core-components-svg.js +15 -15
- package/fesm5/taiga-ui-core-components-svg.js.map +1 -1
- package/fesm5/taiga-ui-core-components-theme-night.js +2 -2
- package/fesm5/taiga-ui-core-components-theme-night.js.map +1 -1
- package/fesm5/taiga-ui-core-components-tooltip.js +7 -7
- package/fesm5/taiga-ui-core-components-tooltip.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-color.js +6 -6
- package/fesm5/taiga-ui-core-directives-color.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-described-by.js +4 -4
- package/fesm5/taiga-ui-core-directives-described-by.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-dropdown-controller.js +9 -9
- package/fesm5/taiga-ui-core-directives-dropdown-controller.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-dropdown.js +2 -2
- package/fesm5/taiga-ui-core-directives-dropdown.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-hint-controller.js +6 -6
- package/fesm5/taiga-ui-core-directives-hint-controller.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-hint.js +5 -5
- package/fesm5/taiga-ui-core-directives-hint.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-manual-hint.js +3 -3
- package/fesm5/taiga-ui-core-directives-manual-hint.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-mask-accessor.js +1 -1
- package/fesm5/taiga-ui-core-directives-mask-accessor.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-mode.js +2 -2
- package/fesm5/taiga-ui-core-directives-mode.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-pointer-hint.js +4 -4
- package/fesm5/taiga-ui-core-directives-pointer-hint.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-scroll-into-view.js +1 -1
- package/fesm5/taiga-ui-core-directives-scroll-into-view.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-table-mode.js +2 -2
- package/fesm5/taiga-ui-core-directives-table-mode.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-textfield-controller.js +33 -33
- package/fesm5/taiga-ui-core-directives-textfield-controller.js.map +1 -1
- package/fesm5/taiga-ui-core-directives-wrapper.js +9 -9
- package/fesm5/taiga-ui-core-directives-wrapper.js.map +1 -1
- package/fesm5/taiga-ui-core-internal-primitive-year-month-pagination.js +1 -1
- package/fesm5/taiga-ui-core-internal-primitive-year-month-pagination.js.map +1 -1
- package/fesm5/taiga-ui-core-internal-svg-defs-host.js +1 -1
- package/fesm5/taiga-ui-core-internal-svg-defs-host.js.map +1 -1
- package/fesm5/taiga-ui-core-pipes-calendar-sheet.js +1 -1
- package/fesm5/taiga-ui-core-pipes-calendar-sheet.js.map +1 -1
- package/fesm5/taiga-ui-core-pipes-format-date.js.map +1 -1
- package/fesm5/taiga-ui-core-utils-dom.js +1 -3
- package/fesm5/taiga-ui-core-utils-dom.js.map +1 -1
- package/fesm5/taiga-ui-core-utils-mask.js +1 -1
- package/fesm5/taiga-ui-core-utils-mask.js.map +1 -1
- package/fesm5/taiga-ui-core-utils-polyfills.js.map +1 -1
- package/interfaces/alert-options.d.ts +1 -1
- package/interfaces/dropdown-directive.d.ts +2 -2
- package/interfaces/hint.d.ts +1 -1
- package/interfaces/notification-options.d.ts +1 -1
- package/interfaces/number-format-settings.d.ts +1 -2
- package/mask/text-mask-list.d.ts +1 -1
- package/mask/text-mask-pipe-handler.d.ts +1 -1
- package/package.json +4 -4
- package/pipes/format-date/format-date.pipe.d.ts +1 -1
- package/tokens/dropdown-directive.d.ts +1 -1
- package/types/brightness.d.ts +1 -1
- package/types/decimal-symbol.d.ts +1 -1
- package/types/decimal.d.ts +1 -1
- package/types/dialog-size.d.ts +1 -1
- package/types/direction.d.ts +2 -2
- package/types/dropdown-width.d.ts +1 -1
- package/types/marker-handler.d.ts +1 -1
- package/types/option-role.d.ts +1 -1
- package/types/orientation.d.ts +1 -1
- package/types/size.d.ts +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-primitive-calendar.js","sources":["ng://@taiga-ui/core/components/primitive-calendar/primitive-calendar.component.ts","ng://@taiga-ui/core/components/primitive-calendar/primitive-calendar.module.ts","ng://@taiga-ui/core/components/primitive-calendar/taiga-ui-core-components-primitive-calendar.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n HostBinding,\n Inject,\n Input,\n Output,\n} from '@angular/core';\nimport {\n ALWAYS_FALSE_HANDLER,\n nullableSame,\n TuiBooleanHandler,\n TuiDay,\n TuiDayRange,\n tuiDefaultProp,\n TuiMonth,\n} from '@taiga-ui/cdk';\nimport {TUI_DEFAULT_MARKER_HANDLER} from '@taiga-ui/core/constants';\nimport {TuiInteractiveState, TuiRangeState} from '@taiga-ui/core/enums';\nimport {TUI_ORDERED_SHORT_WEEK_DAYS, WEEK_DAYS_NAMES} from '@taiga-ui/core/tokens';\nimport {TuiColor, TuiMarkerHandler} from '@taiga-ui/core/types';\nimport {Observable} from 'rxjs';\n\n// @dynamic\n@Component({\n selector: `tui-primitive-calendar`,\n templateUrl: `./primitive-calendar.template.html`,\n styleUrls: [`./primitive-calendar.style.less`],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPrimitiveCalendarComponent {\n private pressedItem: TuiDay | null = null;\n private readonly today = TuiDay.currentLocal();\n\n @Input()\n @tuiDefaultProp()\n month: TuiMonth = TuiMonth.currentLocal();\n\n @Input()\n @tuiDefaultProp()\n disabledItemHandler: TuiBooleanHandler<TuiDay> = ALWAYS_FALSE_HANDLER;\n\n @Input()\n @tuiDefaultProp()\n markerHandler: TuiMarkerHandler = TUI_DEFAULT_MARKER_HANDLER;\n\n @Input()\n @tuiDefaultProp()\n value: TuiDayRange | TuiDay | null = null;\n\n @Input()\n @tuiDefaultProp()\n hoveredItem: TuiDay | null = null;\n\n @Input()\n @tuiDefaultProp()\n showAdjacent = true;\n\n @Output()\n readonly hoveredItemChange = new EventEmitter<TuiDay | null>();\n\n @Output()\n readonly dayClick = new EventEmitter<TuiDay>();\n\n constructor(\n @Inject(TUI_ORDERED_SHORT_WEEK_DAYS)\n readonly weekDays$: Observable<WEEK_DAYS_NAMES>,\n ) {}\n\n @HostBinding(`class._single`)\n get isSingle(): boolean {\n return (\n this.value !== null &&\n (this.value instanceof TuiDay || this.value.isSingleDay)\n );\n }\n\n readonly toMarkers = (\n day: TuiDay,\n today: boolean,\n inRange: boolean,\n ): null | [TuiColor | string] | [TuiColor | string, TuiColor | string] => {\n if (today || inRange) {\n return null;\n }\n\n const markers = this.markerHandler(day);\n\n return markers.length === 0 ? null : markers;\n };\n\n getItemState(item: TuiDay): TuiInteractiveState | null {\n const {disabledItemHandler, pressedItem, hoveredItem} = this;\n\n if (disabledItemHandler(item)) {\n return TuiInteractiveState.Disabled;\n }\n\n if (pressedItem?.daySame(item)) {\n return TuiInteractiveState.Pressed;\n }\n\n if (hoveredItem?.daySame(item)) {\n return TuiInteractiveState.Hovered;\n }\n\n return null;\n }\n\n getItemRange(item: TuiDay): TuiRangeState | null {\n const {value, hoveredItem} = this;\n\n if (!value) {\n return null;\n }\n\n if (value instanceof TuiDay) {\n return value.daySame(item) ? TuiRangeState.Single : null;\n }\n\n if (\n (value.from.daySame(item) && !value.isSingleDay) ||\n (hoveredItem?.dayAfter(value.from) &&\n value.from.daySame(item) &&\n value.isSingleDay) ||\n (hoveredItem?.daySame(item) &&\n hoveredItem.dayBefore(value.from) &&\n value.isSingleDay)\n ) {\n return TuiRangeState.Start;\n }\n\n if (\n (value.to.daySame(item) && !value.isSingleDay) ||\n (hoveredItem?.dayBefore(value.from) &&\n value.from.daySame(item) &&\n value.isSingleDay) ||\n (hoveredItem?.daySame(item) &&\n hoveredItem.dayAfter(value.from) &&\n value.isSingleDay)\n ) {\n return TuiRangeState.End;\n }\n\n return value.isSingleDay && value.from.daySame(item)\n ? TuiRangeState.Single\n : null;\n }\n\n itemIsToday(item: TuiDay): boolean {\n return this.today.daySame(item);\n }\n\n itemIsUnavailable(item: TuiDay): boolean {\n return !this.month.monthSame(item);\n }\n\n itemIsInterval(day: TuiDay): boolean {\n const {value, hoveredItem} = this;\n\n if (value === null || value instanceof TuiDay) {\n return false;\n }\n\n if (!value.isSingleDay) {\n return value.from.daySameOrBefore(day) && value.to.dayAfter(day);\n }\n\n if (hoveredItem === null) {\n return false;\n }\n\n const range = TuiDayRange.sort(value.from, hoveredItem);\n\n return range.from.daySameOrBefore(day) && range.to.dayAfter(day);\n }\n\n onItemHovered(item: TuiDay | false): void {\n this.updateHoveredItem(item || null);\n }\n\n onItemPressed(item: TuiDay | false): void {\n this.pressedItem = item || null;\n }\n\n onItemClick(item: TuiDay): void {\n this.dayClick.emit(item);\n }\n\n private updateHoveredItem(day: TuiDay | null): void {\n if (nullableSame(this.hoveredItem, day, (a, b) => a.daySame(b))) {\n return;\n }\n\n this.hoveredItem = day;\n this.hoveredItemChange.emit(day);\n }\n}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {\n TuiHoveredModule,\n TuiLetModule,\n TuiMapperPipeModule,\n TuiPressedModule,\n TuiRepeatTimesModule,\n} from '@taiga-ui/cdk';\nimport {TuiColorModule} from '@taiga-ui/core/directives/color';\nimport {TuiCalendarSheetPipeModule} from '@taiga-ui/core/pipes';\n\nimport {TuiPrimitiveCalendarComponent} from './primitive-calendar.component';\n\n@NgModule({\n imports: [\n CommonModule,\n TuiLetModule,\n TuiMapperPipeModule,\n TuiRepeatTimesModule,\n TuiHoveredModule,\n TuiPressedModule,\n TuiColorModule,\n TuiCalendarSheetPipeModule,\n ],\n declarations: [TuiPrimitiveCalendarComponent],\n exports: [TuiPrimitiveCalendarComponent],\n})\nexport class TuiPrimitiveCalendarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAwBA;IAOa,6BAA6B,GAA1C,MAAa,6BAA6B;IAkCtC,YAEa,SAAsC;QAAtC,cAAS,GAAT,SAAS,CAA6B;QAnC3C,gBAAW,GAAkB,IAAI,CAAC;QACzB,UAAK,GAAG,MAAM,CAAC,YAAY,EAAE,CAAC;QAI/C,UAAK,GAAa,QAAQ,CAAC,YAAY,EAAE,CAAC;QAI1C,wBAAmB,GAA8B,oBAAoB,CAAC;QAItE,kBAAa,GAAqB,0BAA0B,CAAC;QAI7D,UAAK,GAAgC,IAAI,CAAC;QAI1C,gBAAW,GAAkB,IAAI,CAAC;QAIlC,iBAAY,GAAG,IAAI,CAAC;QAGX,sBAAiB,GAAG,IAAI,YAAY,EAAiB,CAAC;QAGtD,aAAQ,GAAG,IAAI,YAAY,EAAU,CAAC;QAetC,cAAS,GAAG,CACjB,GAAW,EACX,KAAc,EACd,OAAgB;YAEhB,IAAI,KAAK,IAAI,OAAO,EAAE;gBAClB,OAAO,IAAI,CAAC;aACf;YAED,MAAM,OAAO,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;YAExC,OAAO,OAAO,CAAC,MAAM,KAAK,CAAC,GAAG,IAAI,GAAG,OAAO,CAAC;SAChD,CAAC;KAtBE;IAGJ,IAAI,QAAQ;QACR,QACI,IAAI,CAAC,KAAK,KAAK,IAAI;aAClB,IAAI,CAAC,KAAK,YAAY,MAAM,IAAI,IAAI,CAAC,KAAK,CAAC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KzC;;IC1KY,0BAA0B,GAAvC,MAAa,0BAA0B;EAAG;AAA7B,0BAA0B;IAdtC,QAAQ,CAAC;QACN,OAAO,EAAE;YACL,YAAY;YACZ,YAAY;YACZ,mBAAmB;YACnB,oBAAoB;YACpB,gBAAgB;YAChB,gBAAgB;YAChB,cAAc;YACd,0BAA0B;SAC7B;QACD,YAAY,EAAE,CAAC,6BAA6B,CAAC;QAC7C,OAAO,EAAE,CAAC,6BAA6B,CAAC;KAC3C,CAAC;GACW,0BAA0B,CAAG;;AC5B1C;;;;;;"}
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-primitive-calendar.js","sources":["ng://@taiga-ui/core/components/primitive-calendar/primitive-calendar.component.ts","ng://@taiga-ui/core/components/primitive-calendar/primitive-calendar.module.ts","ng://@taiga-ui/core/components/primitive-calendar/taiga-ui-core-components-primitive-calendar.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n HostBinding,\n Inject,\n Input,\n Output,\n} from '@angular/core';\nimport {\n ALWAYS_FALSE_HANDLER,\n nullableSame,\n TuiBooleanHandler,\n TuiDay,\n TuiDayRange,\n tuiDefaultProp,\n TuiMonth,\n} from '@taiga-ui/cdk';\nimport {TUI_DEFAULT_MARKER_HANDLER} from '@taiga-ui/core/constants';\nimport {TuiInteractiveState, TuiRangeState} from '@taiga-ui/core/enums';\nimport {TUI_ORDERED_SHORT_WEEK_DAYS, WEEK_DAYS_NAMES} from '@taiga-ui/core/tokens';\nimport {TuiColor, TuiMarkerHandler} from '@taiga-ui/core/types';\nimport {Observable} from 'rxjs';\n\n// @dynamic\n@Component({\n selector: 'tui-primitive-calendar',\n templateUrl: './primitive-calendar.template.html',\n styleUrls: ['./primitive-calendar.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPrimitiveCalendarComponent {\n private pressedItem: TuiDay | null = null;\n private readonly today = TuiDay.currentLocal();\n\n @Input()\n @tuiDefaultProp()\n month: TuiMonth = TuiMonth.currentLocal();\n\n @Input()\n @tuiDefaultProp()\n disabledItemHandler: TuiBooleanHandler<TuiDay> = ALWAYS_FALSE_HANDLER;\n\n @Input()\n @tuiDefaultProp()\n markerHandler: TuiMarkerHandler = TUI_DEFAULT_MARKER_HANDLER;\n\n @Input()\n @tuiDefaultProp()\n value: TuiDay | TuiDayRange | null = null;\n\n @Input()\n @tuiDefaultProp()\n hoveredItem: TuiDay | null = null;\n\n @Input()\n @tuiDefaultProp()\n showAdjacent = true;\n\n @Output()\n readonly hoveredItemChange = new EventEmitter<TuiDay | null>();\n\n @Output()\n readonly dayClick = new EventEmitter<TuiDay>();\n\n constructor(\n @Inject(TUI_ORDERED_SHORT_WEEK_DAYS)\n readonly weekDays$: Observable<WEEK_DAYS_NAMES>,\n ) {}\n\n @HostBinding('class._single')\n get isSingle(): boolean {\n return (\n this.value !== null &&\n (this.value instanceof TuiDay || this.value.isSingleDay)\n );\n }\n\n readonly toMarkers = (\n day: TuiDay,\n today: boolean,\n inRange: boolean,\n ): [TuiColor | string, TuiColor | string] | [TuiColor | string] | null => {\n if (today || inRange) {\n return null;\n }\n\n const markers = this.markerHandler(day);\n\n return markers.length === 0 ? null : markers;\n };\n\n getItemState(item: TuiDay): TuiInteractiveState | null {\n const {disabledItemHandler, pressedItem, hoveredItem} = this;\n\n if (disabledItemHandler(item)) {\n return TuiInteractiveState.Disabled;\n }\n\n if (pressedItem?.daySame(item)) {\n return TuiInteractiveState.Pressed;\n }\n\n if (hoveredItem?.daySame(item)) {\n return TuiInteractiveState.Hovered;\n }\n\n return null;\n }\n\n getItemRange(item: TuiDay): TuiRangeState | null {\n const {value, hoveredItem} = this;\n\n if (!value) {\n return null;\n }\n\n if (value instanceof TuiDay) {\n return value.daySame(item) ? TuiRangeState.Single : null;\n }\n\n if (\n (value.from.daySame(item) && !value.isSingleDay) ||\n (hoveredItem?.dayAfter(value.from) &&\n value.from.daySame(item) &&\n value.isSingleDay) ||\n (hoveredItem?.daySame(item) &&\n hoveredItem.dayBefore(value.from) &&\n value.isSingleDay)\n ) {\n return TuiRangeState.Start;\n }\n\n if (\n (value.to.daySame(item) && !value.isSingleDay) ||\n (hoveredItem?.dayBefore(value.from) &&\n value.from.daySame(item) &&\n value.isSingleDay) ||\n (hoveredItem?.daySame(item) &&\n hoveredItem.dayAfter(value.from) &&\n value.isSingleDay)\n ) {\n return TuiRangeState.End;\n }\n\n return value.isSingleDay && value.from.daySame(item)\n ? TuiRangeState.Single\n : null;\n }\n\n itemIsToday(item: TuiDay): boolean {\n return this.today.daySame(item);\n }\n\n itemIsUnavailable(item: TuiDay): boolean {\n return !this.month.monthSame(item);\n }\n\n itemIsInterval(day: TuiDay): boolean {\n const {value, hoveredItem} = this;\n\n if (value === null || value instanceof TuiDay) {\n return false;\n }\n\n if (!value.isSingleDay) {\n return value.from.daySameOrBefore(day) && value.to.dayAfter(day);\n }\n\n if (hoveredItem === null) {\n return false;\n }\n\n const range = TuiDayRange.sort(value.from, hoveredItem);\n\n return range.from.daySameOrBefore(day) && range.to.dayAfter(day);\n }\n\n onItemHovered(item: TuiDay | false): void {\n this.updateHoveredItem(item || null);\n }\n\n onItemPressed(item: TuiDay | false): void {\n this.pressedItem = item || null;\n }\n\n onItemClick(item: TuiDay): void {\n this.dayClick.emit(item);\n }\n\n private updateHoveredItem(day: TuiDay | null): void {\n if (nullableSame(this.hoveredItem, day, (a, b) => a.daySame(b))) {\n return;\n }\n\n this.hoveredItem = day;\n this.hoveredItemChange.emit(day);\n }\n}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {\n TuiHoveredModule,\n TuiLetModule,\n TuiMapperPipeModule,\n TuiPressedModule,\n TuiRepeatTimesModule,\n} from '@taiga-ui/cdk';\nimport {TuiColorModule} from '@taiga-ui/core/directives/color';\nimport {TuiCalendarSheetPipeModule} from '@taiga-ui/core/pipes';\n\nimport {TuiPrimitiveCalendarComponent} from './primitive-calendar.component';\n\n@NgModule({\n imports: [\n CommonModule,\n TuiLetModule,\n TuiMapperPipeModule,\n TuiRepeatTimesModule,\n TuiHoveredModule,\n TuiPressedModule,\n TuiColorModule,\n TuiCalendarSheetPipeModule,\n ],\n declarations: [TuiPrimitiveCalendarComponent],\n exports: [TuiPrimitiveCalendarComponent],\n})\nexport class TuiPrimitiveCalendarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAwBA;IAOa,6BAA6B,GAA1C,MAAa,6BAA6B;IAkCtC,YAEa,SAAsC;QAAtC,cAAS,GAAT,SAAS,CAA6B;QAnC3C,gBAAW,GAAkB,IAAI,CAAC;QACzB,UAAK,GAAG,MAAM,CAAC,YAAY,EAAE,CAAC;QAI/C,UAAK,GAAa,QAAQ,CAAC,YAAY,EAAE,CAAC;QAI1C,wBAAmB,GAA8B,oBAAoB,CAAC;QAItE,kBAAa,GAAqB,0BAA0B,CAAC;QAI7D,UAAK,GAAgC,IAAI,CAAC;QAI1C,gBAAW,GAAkB,IAAI,CAAC;QAIlC,iBAAY,GAAG,IAAI,CAAC;QAGX,sBAAiB,GAAG,IAAI,YAAY,EAAiB,CAAC;QAGtD,aAAQ,GAAG,IAAI,YAAY,EAAU,CAAC;QAetC,cAAS,GAAG,CACjB,GAAW,EACX,KAAc,EACd,OAAgB;YAEhB,IAAI,KAAK,IAAI,OAAO,EAAE;gBAClB,OAAO,IAAI,CAAC;aACf;YAED,MAAM,OAAO,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;YAExC,OAAO,OAAO,CAAC,MAAM,KAAK,CAAC,GAAG,IAAI,GAAG,OAAO,CAAC;SAChD,CAAC;KAtBE;IAGJ,IAAI,QAAQ;QACR,QACI,IAAI,CAAC,KAAK,KAAK,IAAI;aAClB,IAAI,CAAC,KAAK,YAAY,MAAM,IAAI,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,EAC1D;KACL;IAgBD,YAAY,CAAC,IAAY;QACrB,MAAM,EAAC,mBA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QAAQ,CAAC;QACN,OAAO,EAAE;YACL,YAAY;YACZ,YAAY;YACZ,mBAAmB;YACnB,oBAAoB;YACpB,gBAAgB;YAChB,gBAAgB;YAChB,cAAc;YACd,0BAA0B;SAC7B;QACD,YAAY,EAAE,CAAC,6BAA6B,CAAC;QAC7C,OAAO,EAAE,CAAC,6BAA6B,CAAC;KAC3C,CAAC;GACW,0BAA0B,CAAG;;AC5B1C;;;;;;"}
|
|
@@ -74,7 +74,7 @@ TuiPrimitiveCheckboxComponent.ctorParameters = () => [
|
|
|
74
74
|
];
|
|
75
75
|
__decorate([
|
|
76
76
|
Input(),
|
|
77
|
-
HostBinding(
|
|
77
|
+
HostBinding('attr.data-size'),
|
|
78
78
|
tuiDefaultProp()
|
|
79
79
|
], TuiPrimitiveCheckboxComponent.prototype, "size", void 0);
|
|
80
80
|
__decorate([
|
|
@@ -98,12 +98,12 @@ __decorate([
|
|
|
98
98
|
tuiDefaultProp()
|
|
99
99
|
], TuiPrimitiveCheckboxComponent.prototype, "invalid", void 0);
|
|
100
100
|
__decorate([
|
|
101
|
-
Input(
|
|
101
|
+
Input('value'),
|
|
102
102
|
tuiDefaultProp()
|
|
103
103
|
], TuiPrimitiveCheckboxComponent.prototype, "valueSetter", null);
|
|
104
104
|
TuiPrimitiveCheckboxComponent = __decorate([
|
|
105
105
|
Component({
|
|
106
|
-
selector:
|
|
106
|
+
selector: 'tui-primitive-checkbox',
|
|
107
107
|
template: "<tui-wrapper\n [appearance]=\"appearance\"\n [disabled]=\"disabled\"\n [focused]=\"focused\"\n [hovered]=\"hovered\"\n [pressed]=\"pressed\"\n [invalid]=\"invalid\"\n>\n <span\n polymorpheus-outlet\n [content]=\"icon\"\n [context]=\"{$implicit: size}\"\n >\n <ng-template let-icon>\n <tui-svg\n class=\"t-mark\"\n [class.t-mark_on]=\"!empty\"\n [src]=\"icon\"\n ></tui-svg>\n </ng-template>\n </span>\n <ng-content></ng-content>\n</tui-wrapper>\n",
|
|
108
108
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
109
109
|
styles: [":host{display:block;font-size:0;flex-shrink:0}:host[data-size='m']{width:1rem;height:1rem;border-radius:var(--tui-radius-xs)}:host[data-size='l']{width:1.5rem;height:1.5rem;border-radius:var(--tui-radius-s)}.t-mark{transition-property:transform;transition-duration:var(--tui-duration,300ms);transition-timing-function:ease-in-out;display:block;width:100%;height:100%;transform:scale(0)}.t-mark_on{transform:scale(1)}"]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-primitive-checkbox.js","sources":["ng://@taiga-ui/core/components/primitive-checkbox/checkbox-options.ts","ng://@taiga-ui/core/components/primitive-checkbox/primitive-checkbox.component.ts","ng://@taiga-ui/core/components/primitive-checkbox/primitive-checkbox.module.ts","ng://@taiga-ui/core/components/primitive-checkbox/taiga-ui-core-components-primitive-checkbox.ts"],"sourcesContent":["import {InjectionToken, ValueProvider} from '@angular/core';\nimport {TuiContextWithImplicit} from '@taiga-ui/cdk';\nimport {TuiAppearance} from '@taiga-ui/core/enums';\nimport {TuiSizeL} from '@taiga-ui/core/types';\nimport {PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\n\nexport interface TuiCheckboxOptions {\n readonly size: TuiSizeL;\n readonly appearances: Readonly<{\n unchecked: string;\n checked: string;\n indeterminate: string;\n }>;\n readonly icons: Readonly<{\n checked: PolymorpheusContent<TuiContextWithImplicit<TuiSizeL>>;\n indeterminate: PolymorpheusContent<TuiContextWithImplicit<TuiSizeL>>;\n }>;\n}\n\n/**\n * @deprecated: use TuiCheckboxOptions instead\n * todo: remove in 3.0\n */\nexport type CheckboxOptions = TuiCheckboxOptions;\n\n/** Default values for the checkbox options. */\nexport const TUI_CHECKBOX_DEFAULT_OPTIONS: TuiCheckboxOptions = {\n size: `m`,\n appearances: {\n unchecked: TuiAppearance.Outline,\n checked: TuiAppearance.Primary,\n indeterminate: TuiAppearance.Primary,\n },\n icons: {\n checked({$implicit}: TuiContextWithImplicit<TuiSizeL>): string {\n return $implicit === `m` ? `tuiIconCheck` : `tuiIconCheckLarge`;\n },\n indeterminate({$implicit}: TuiContextWithImplicit<TuiSizeL>): string {\n return $implicit === `m` ? `tuiIconMinus` : `tuiIconMinusLarge`;\n },\n },\n};\n\nexport const TUI_CHECKBOX_OPTIONS = new InjectionToken<TuiCheckboxOptions>(\n `Default parameters for checkbox component`,\n {\n factory: () => TUI_CHECKBOX_DEFAULT_OPTIONS,\n },\n);\n\nexport const tuiCheckboxOptionsProvider: (\n options: Partial<TuiCheckboxOptions>,\n) => ValueProvider = (options: Partial<TuiCheckboxOptions>) => ({\n provide: TUI_CHECKBOX_OPTIONS,\n useValue: {...TUI_CHECKBOX_DEFAULT_OPTIONS, ...options},\n});\n","import {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n Inject,\n Input,\n} from '@angular/core';\nimport {TuiContextWithImplicit, tuiDefaultProp} from '@taiga-ui/cdk';\nimport {TuiSizeL} from '@taiga-ui/core/types';\nimport {PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\n\nimport {TUI_CHECKBOX_OPTIONS, TuiCheckboxOptions} from './checkbox-options';\n\n// @dynamic\n@Component({\n selector:
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-primitive-checkbox.js","sources":["ng://@taiga-ui/core/components/primitive-checkbox/checkbox-options.ts","ng://@taiga-ui/core/components/primitive-checkbox/primitive-checkbox.component.ts","ng://@taiga-ui/core/components/primitive-checkbox/primitive-checkbox.module.ts","ng://@taiga-ui/core/components/primitive-checkbox/taiga-ui-core-components-primitive-checkbox.ts"],"sourcesContent":["import {InjectionToken, ValueProvider} from '@angular/core';\nimport {TuiContextWithImplicit} from '@taiga-ui/cdk';\nimport {TuiAppearance} from '@taiga-ui/core/enums';\nimport {TuiSizeL} from '@taiga-ui/core/types';\nimport {PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\n\nexport interface TuiCheckboxOptions {\n readonly size: TuiSizeL;\n readonly appearances: Readonly<{\n unchecked: string;\n checked: string;\n indeterminate: string;\n }>;\n readonly icons: Readonly<{\n checked: PolymorpheusContent<TuiContextWithImplicit<TuiSizeL>>;\n indeterminate: PolymorpheusContent<TuiContextWithImplicit<TuiSizeL>>;\n }>;\n}\n\n/**\n * @deprecated: use TuiCheckboxOptions instead\n * todo: remove in 3.0\n */\nexport type CheckboxOptions = TuiCheckboxOptions;\n\n/** Default values for the checkbox options. */\nexport const TUI_CHECKBOX_DEFAULT_OPTIONS: TuiCheckboxOptions = {\n size: `m`,\n appearances: {\n unchecked: TuiAppearance.Outline,\n checked: TuiAppearance.Primary,\n indeterminate: TuiAppearance.Primary,\n },\n icons: {\n checked({$implicit}: TuiContextWithImplicit<TuiSizeL>): string {\n return $implicit === `m` ? `tuiIconCheck` : `tuiIconCheckLarge`;\n },\n indeterminate({$implicit}: TuiContextWithImplicit<TuiSizeL>): string {\n return $implicit === `m` ? `tuiIconMinus` : `tuiIconMinusLarge`;\n },\n },\n};\n\nexport const TUI_CHECKBOX_OPTIONS = new InjectionToken<TuiCheckboxOptions>(\n `Default parameters for checkbox component`,\n {\n factory: () => TUI_CHECKBOX_DEFAULT_OPTIONS,\n },\n);\n\nexport const tuiCheckboxOptionsProvider: (\n options: Partial<TuiCheckboxOptions>,\n) => ValueProvider = (options: Partial<TuiCheckboxOptions>) => ({\n provide: TUI_CHECKBOX_OPTIONS,\n useValue: {...TUI_CHECKBOX_DEFAULT_OPTIONS, ...options},\n});\n","import {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n Inject,\n Input,\n} from '@angular/core';\nimport {TuiContextWithImplicit, tuiDefaultProp} from '@taiga-ui/cdk';\nimport {TuiSizeL} from '@taiga-ui/core/types';\nimport {PolymorpheusContent} from '@tinkoff/ng-polymorpheus';\n\nimport {TUI_CHECKBOX_OPTIONS, TuiCheckboxOptions} from './checkbox-options';\n\n// @dynamic\n@Component({\n selector: 'tui-primitive-checkbox',\n templateUrl: './primitive-checkbox.template.html',\n styleUrls: ['./primitive-checkbox.style.less'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class TuiPrimitiveCheckboxComponent {\n @Input()\n @HostBinding('attr.data-size')\n @tuiDefaultProp()\n size: TuiSizeL = this.options.size;\n\n @Input()\n @tuiDefaultProp()\n disabled = false;\n\n @Input()\n @tuiDefaultProp()\n focused = false;\n\n @Input()\n @tuiDefaultProp()\n hovered = false;\n\n @Input()\n @tuiDefaultProp()\n pressed = false;\n\n @Input()\n @tuiDefaultProp()\n invalid = false;\n\n @Input('value')\n @tuiDefaultProp()\n set valueSetter(value: boolean | null) {\n if (value !== false) {\n this.setCurrentIcon(value);\n }\n\n this.value = value;\n }\n\n icon: PolymorpheusContent<TuiContextWithImplicit<TuiSizeL>> =\n this.options.icons.checked;\n\n value: boolean | null = false;\n\n constructor(\n @Inject(TUI_CHECKBOX_OPTIONS) private readonly options: TuiCheckboxOptions,\n ) {}\n\n get appearance(): string {\n switch (this.value) {\n case false:\n return this.options.appearances.unchecked;\n case true:\n return this.options.appearances.checked;\n default:\n return this.options.appearances.indeterminate;\n }\n }\n\n get empty(): boolean {\n return this.value === false;\n }\n\n private setCurrentIcon(value: boolean | null): void {\n this.icon =\n value === null\n ? this.options.icons.indeterminate\n : this.options.icons.checked;\n }\n}\n","import {NgModule} from '@angular/core';\nimport {TuiSvgModule} from '@taiga-ui/core/components/svg';\nimport {TuiWrapperModule} from '@taiga-ui/core/directives/wrapper';\nimport {PolymorpheusModule} from '@tinkoff/ng-polymorpheus';\n\nimport {TuiPrimitiveCheckboxComponent} from './primitive-checkbox.component';\n\n@NgModule({\n imports: [TuiSvgModule, TuiWrapperModule, PolymorpheusModule],\n declarations: [TuiPrimitiveCheckboxComponent],\n exports: [TuiPrimitiveCheckboxComponent],\n})\nexport class TuiPrimitiveCheckboxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAyBA;MACa,4BAA4B,GAAuB;IAC5D,IAAI,EAAE,GAAG;IACT,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,6BAA6B,CAAC;KAC3C,CAAC;GACW,0BAA0B,CAAG;;ACZ1C;;;;;;"}
|
|
@@ -48,7 +48,7 @@ TuiPrimitiveSpinButtonComponent.ctorParameters = () => [
|
|
|
48
48
|
{ type: Observable, decorators: [{ type: Inject, args: [TUI_SPIN_TEXTS,] }] }
|
|
49
49
|
];
|
|
50
50
|
__decorate([
|
|
51
|
-
ViewChild(
|
|
51
|
+
ViewChild('wrapper')
|
|
52
52
|
], TuiPrimitiveSpinButtonComponent.prototype, "wrapper", void 0);
|
|
53
53
|
__decorate([
|
|
54
54
|
Input(),
|
|
@@ -74,7 +74,7 @@ __decorate([
|
|
|
74
74
|
], TuiPrimitiveSpinButtonComponent.prototype, "rightClick", void 0);
|
|
75
75
|
TuiPrimitiveSpinButtonComponent = __decorate([
|
|
76
76
|
Component({
|
|
77
|
-
selector:
|
|
77
|
+
selector: 'tui-primitive-spin-button',
|
|
78
78
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
79
79
|
template: "<div\n *ngIf=\"spinTexts$ | async as texts\"\n #wrapper\n tuiPreventDefault=\"mousedown\"\n class=\"t-wrapper\"\n [tuiFocusable]=\"computedFocusable\"\n (tuiFocusedChange)=\"onFocused($event)\"\n (tuiFocusVisibleChange)=\"onFocusVisible($event)\"\n (keydown.arrowLeft)=\"onLeftClick()\"\n (keydown.arrowRight)=\"onRightClick()\"\n>\n <button\n tuiIconButton\n type=\"button\"\n size=\"xs\"\n appearance=\"\"\n automation-id=\"tui-primitive-spin-button__left\"\n icon=\"tuiIconChevronLeftLarge\"\n class=\"t-arrow\"\n [class.t-arrow_hidden]=\"leftComputedDisabled\"\n [title]=\"texts[0]\"\n [focusable]=\"false\"\n (click)=\"onLeftClick()\"\n ></button>\n <span class=\"t-content\">\n <ng-content></ng-content>\n </span>\n <button\n tuiIconButton\n type=\"button\"\n size=\"xs\"\n appearance=\"\"\n automation-id=\"tui-primitive-spin-button__right\"\n icon=\"tuiIconChevronRightLarge\"\n class=\"t-arrow\"\n [class.t-arrow_hidden]=\"rightComputedDisabled\"\n [title]=\"texts[1]\"\n [focusable]=\"false\"\n (click)=\"onRightClick()\"\n ></button>\n</div>\n",
|
|
80
80
|
styles: [":host{display:block;font:var(--tui-font-text-l);text-align:center;font-weight:700}.t-wrapper{display:flex;align-items:center;justify-content:space-between;outline:0}.t-arrow{margin:0 .25rem}.t-arrow_hidden{visibility:hidden}.t-content{padding:0 .5rem}:host._focus-visible .t-content{box-shadow:0 0 0 1px var(--tui-focus)}"]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-core-components-primitive-spin-button.js","sources":["ng://@taiga-ui/core/components/primitive-spin-button/primitive-spin-button.component.ts","ng://@taiga-ui/core/components/primitive-spin-button/primitive-spin-button.module.ts","ng://@taiga-ui/core/components/primitive-spin-button/taiga-ui-core-components-primitive-spin-button.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n Inject,\n Input,\n Output,\n ViewChild,\n} from '@angular/core';\nimport {AbstractTuiInteractive, isNativeFocused, tuiDefaultProp} from '@taiga-ui/cdk';\nimport {TuiAppearance} from '@taiga-ui/core/enums';\nimport {TUI_SPIN_TEXTS} from '@taiga-ui/core/tokens';\nimport {Observable} from 'rxjs';\n\n// @dynamic\n@Component({\n selector:
|
|
1
|
+
{"version":3,"file":"taiga-ui-core-components-primitive-spin-button.js","sources":["ng://@taiga-ui/core/components/primitive-spin-button/primitive-spin-button.component.ts","ng://@taiga-ui/core/components/primitive-spin-button/primitive-spin-button.module.ts","ng://@taiga-ui/core/components/primitive-spin-button/taiga-ui-core-components-primitive-spin-button.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n Inject,\n Input,\n Output,\n ViewChild,\n} from '@angular/core';\nimport {AbstractTuiInteractive, isNativeFocused, tuiDefaultProp} from '@taiga-ui/cdk';\nimport {TuiAppearance} from '@taiga-ui/core/enums';\nimport {TUI_SPIN_TEXTS} from '@taiga-ui/core/tokens';\nimport {Observable} from 'rxjs';\n\n// @dynamic\n@Component({\n selector: 'tui-primitive-spin-button',\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './primitive-spin-button.template.html',\n styleUrls: ['./primitive-spin-button.style.less'],\n})\nexport class TuiPrimitiveSpinButtonComponent extends AbstractTuiInteractive {\n @ViewChild('wrapper')\n private readonly wrapper?: ElementRef<HTMLElement>;\n\n @Input()\n @tuiDefaultProp()\n disabled = false;\n\n @Input()\n @tuiDefaultProp()\n mode: TuiAppearance = TuiAppearance.Flat;\n\n @Input()\n @tuiDefaultProp()\n leftDisabled = false;\n\n @Input()\n @tuiDefaultProp()\n rightDisabled = false;\n\n @Output()\n readonly leftClick = new EventEmitter<void>();\n\n @Output()\n readonly rightClick = new EventEmitter<void>();\n\n constructor(\n @Inject(TUI_SPIN_TEXTS) readonly spinTexts$: Observable<[string, string]>,\n ) {\n super();\n }\n\n get focused(): boolean {\n return !!this.wrapper && isNativeFocused(this.wrapper.nativeElement);\n }\n\n get leftComputedDisabled(): boolean {\n return this.computedDisabled || this.leftDisabled;\n }\n\n get rightComputedDisabled(): boolean {\n return this.computedDisabled || this.rightDisabled;\n }\n\n onLeftClick(): void {\n if (!this.leftComputedDisabled) {\n this.leftClick.emit();\n }\n }\n\n onRightClick(): void {\n if (!this.rightComputedDisabled) {\n this.rightClick.emit();\n }\n }\n\n onFocused(focused: boolean): void {\n this.updateFocused(focused);\n }\n\n onFocusVisible(focusVisible: boolean): void {\n this.updateFocusVisible(focusVisible);\n }\n}\n","import {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {\n TuiFocusableModule,\n TuiFocusedModule,\n TuiFocusVisibleModule,\n TuiPreventDefaultModule,\n} from '@taiga-ui/cdk';\nimport {TuiButtonModule} from '@taiga-ui/core/components/button';\n\nimport {TuiPrimitiveSpinButtonComponent} from './primitive-spin-button.component';\n\n@NgModule({\n imports: [\n CommonModule,\n TuiFocusVisibleModule,\n TuiFocusedModule,\n TuiFocusableModule,\n TuiPreventDefaultModule,\n TuiButtonModule,\n ],\n declarations: [TuiPrimitiveSpinButtonComponent],\n exports: [TuiPrimitiveSpinButtonComponent],\n})\nexport class TuiPrimitiveSpinButtonModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAeA;IAOa,+BAA+B,GAA5C,MAAa,+BAAgC,SAAQ,sBAAsB;IA0BvE,YACqC,UAAwC;QAEzE,KAAK,EAAE,CAAC;QAFyB,eAAU,GAAV,UAAU,CAA8B;QArB7E,aAAQ,GAAG,KAAK,CAAC;QAIjB,SAAI,qBAAqC;QAIzC,iBAAY,GAAG,KAAK,CAAC;QAIrB,kBAAa,GAAG,KAAK,CAAC;QAGb,cAAS,GAAG,IAAI,YAAY,EAAQ,CAAC;QAGrC,eAAU,GAAG,IAAI,YAAY,EAAQ,CAAC;KAM9C;IAED,IAAI,OAAO;QACP,OAAO,CAAC,CAAC,IAAI,CAAC,OAAO,IAAI,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;KACxE;IAED,IAAI,oBAAoB;QACpB,OAAO,IAAI,CAAC,gBAAgB,IAAI,IAAI,CAAC,YAAY,CAAC;KACrD;IAED,IAAI,qBAAqB;QACrB,OAAO,IAAI,CAAC,gBAAgB,IAAI,IAAI,CAAC,aAAa,CAAC;KACtD;IAED,WAAW;QACP,IAAI,CAAC,IAAI,CAAC,oBAAoB,EAAE;YAC5B,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,CAAC;SACzB;KACJ;IAED,YAAY;QACR,IAAI,CAAC,IAAI,CAAC,qBAAqB,EAAE;YAC7B,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE,CAAC;SAC1B;KACJ;IAED,SAAS,CAAC,OAAgB;QACtB,IAAI,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;KAC/B;IAED,cAAc,CAAC,YAAqB;QAChC,IAAI,CAAC,kBAAkB,CAAC,YAAY,CAAC,CAAC;KACzC;EACJ;;YApCoD,UAAU,uBAAtD,MAAM,SAAC,cAAc;;AAzB1B;IADC,SAAS,CAAC,SAAS,CAAC;gEAC8B;AAInD;IAFC,KAAK,EAAE;IACP,cAAc,EAAE;iEACA;AAIjB;IAFC,KAAK,EAAE;IACP,cAAc,EAAE;6DACwB;AAIzC;IAFC,KAAK,EAAE;IACP,cAAc,EAAE;qEACI;AAIrB;IAFC,KAAK,EAAE;IACP,cAAc,EAAE;sEACK;AAGtB;IADC,MAAM,EAAE;kEACqC;AAG9C;IADC,MAAM,EAAE;mEACsC;AAxBtC,+BAA+B;IAN3C,SAAS,CAAC;QACP,QAAQ,EAAE,2BAA2B;QACrC,eAAe,EAAE,uBAAuB,CAAC,MAAM;QAC/C,wvCAAoD;;KAEvD,CAAC;IA4BO,WAAA,MAAM,CAAC,cAAc,CAAC,CAAA;GA3BlB,+BAA+B,CA+D3C;;IC7DY,4BAA4B,GAAzC,MAAa,4BAA4B;EAAG;AAA/B,4BAA4B;IAZxC,QAAQ,CAAC;QACN,OAAO,EAAE;YACL,YAAY;YACZ,qBAAqB;YACrB,gBAAgB;YAChB,kBAAkB;YAClB,uBAAuB;YACvB,eAAe;SAClB;QACD,YAAY,EAAE,CAAC,+BAA+B,CAAC;QAC/C,OAAO,EAAE,CAAC,+BAA+B,CAAC;KAC7C,CAAC;GACW,4BAA4B,CAAG;;ACxB5C;;;;;;"}
|
|
@@ -56,7 +56,7 @@ let TuiPrimitiveTextfieldComponent = class TuiPrimitiveTextfieldComponent extend
|
|
|
56
56
|
this.options = options;
|
|
57
57
|
this.elementRef = elementRef;
|
|
58
58
|
this.editable = true;
|
|
59
|
-
this.filler =
|
|
59
|
+
this.filler = '';
|
|
60
60
|
this.iconAlign = this.options.iconAlign;
|
|
61
61
|
// TODO: 3.0 Remove null
|
|
62
62
|
this.iconContent = null;
|
|
@@ -64,9 +64,9 @@ let TuiPrimitiveTextfieldComponent = class TuiPrimitiveTextfieldComponent extend
|
|
|
64
64
|
this.readOnly = false;
|
|
65
65
|
this.invalid = false;
|
|
66
66
|
this.disabled = false;
|
|
67
|
-
this.prefix =
|
|
68
|
-
this.postfix =
|
|
69
|
-
this.value =
|
|
67
|
+
this.prefix = '';
|
|
68
|
+
this.postfix = '';
|
|
69
|
+
this.value = '';
|
|
70
70
|
this.valueChange = new EventEmitter();
|
|
71
71
|
/**
|
|
72
72
|
* @deprecated TODO: 3.0 remove
|
|
@@ -112,7 +112,7 @@ let TuiPrimitiveTextfieldComponent = class TuiPrimitiveTextfieldComponent extend
|
|
|
112
112
|
get showOnlyPlaceholder() {
|
|
113
113
|
return (this.focused &&
|
|
114
114
|
this.placeholderVisible &&
|
|
115
|
-
(this.size ===
|
|
115
|
+
(this.size === 's' || (this.size === 'm' && !this.placeholderRaisable)));
|
|
116
116
|
}
|
|
117
117
|
get placeholderVisible() {
|
|
118
118
|
var _a;
|
|
@@ -137,32 +137,32 @@ let TuiPrimitiveTextfieldComponent = class TuiPrimitiveTextfieldComponent extend
|
|
|
137
137
|
return getBorder(this.iconAlignRight, this.hasCleaner, this.hasTooltip, this.hasCustomContent);
|
|
138
138
|
}
|
|
139
139
|
get iconAlignLeft() {
|
|
140
|
-
return this.hasIcon && this.iconAlign ===
|
|
140
|
+
return this.hasIcon && this.iconAlign === 'left';
|
|
141
141
|
}
|
|
142
142
|
get iconAlignRight() {
|
|
143
|
-
return this.hasIcon && this.iconAlign ===
|
|
143
|
+
return this.hasIcon && this.iconAlign === 'right';
|
|
144
144
|
}
|
|
145
145
|
// Safari expiration date autofill workaround
|
|
146
146
|
get name() {
|
|
147
147
|
return this.controller.autocomplete === "cc-exp" /* CcExp */
|
|
148
|
-
?
|
|
148
|
+
? 'ccexpiryyear'
|
|
149
149
|
: null;
|
|
150
150
|
}
|
|
151
151
|
get computedId() {
|
|
152
152
|
var _a;
|
|
153
|
-
return ((_a = this.nativeFocusableElement) === null || _a === void 0 ? void 0 : _a.id) ||
|
|
153
|
+
return ((_a = this.nativeFocusableElement) === null || _a === void 0 ? void 0 : _a.id) || '';
|
|
154
154
|
}
|
|
155
155
|
onFocused(focused) {
|
|
156
156
|
this.updateFocused(focused);
|
|
157
157
|
}
|
|
158
158
|
getIndent$(element) {
|
|
159
|
-
return fromEvent(element,
|
|
159
|
+
return fromEvent(element, 'scroll').pipe(map(() => -1 * element.scrollLeft));
|
|
160
160
|
}
|
|
161
161
|
clear() {
|
|
162
162
|
if (this.nativeFocusableElement) {
|
|
163
|
-
this.nativeFocusableElement.value =
|
|
163
|
+
this.nativeFocusableElement.value = '';
|
|
164
164
|
}
|
|
165
|
-
this.updateValue(
|
|
165
|
+
this.updateValue('');
|
|
166
166
|
}
|
|
167
167
|
onMouseDown(event) {
|
|
168
168
|
const { nativeFocusableElement } = this;
|
|
@@ -182,10 +182,10 @@ let TuiPrimitiveTextfieldComponent = class TuiPrimitiveTextfieldComponent extend
|
|
|
182
182
|
this.updateAutofilled(autofilled);
|
|
183
183
|
}
|
|
184
184
|
get iconPaddingLeft() {
|
|
185
|
-
return this.size ===
|
|
185
|
+
return this.size === 's' ? ICON_PADDING_S : ICON_PADDING;
|
|
186
186
|
}
|
|
187
187
|
get placeholderRaisable() {
|
|
188
|
-
return this.size !==
|
|
188
|
+
return this.size !== 's' && !this.controller.labelOutside;
|
|
189
189
|
}
|
|
190
190
|
get hasIcon() {
|
|
191
191
|
return !!this.iconContent;
|
|
@@ -211,7 +211,7 @@ TuiPrimitiveTextfieldComponent.ctorParameters = () => [
|
|
|
211
211
|
{ type: ElementRef, decorators: [{ type: Inject, args: [ElementRef,] }] }
|
|
212
212
|
];
|
|
213
213
|
__decorate([
|
|
214
|
-
ViewChild(
|
|
214
|
+
ViewChild('focusableElement')
|
|
215
215
|
], TuiPrimitiveTextfieldComponent.prototype, "focusableElement", void 0);
|
|
216
216
|
__decorate([
|
|
217
217
|
Input(),
|
|
@@ -235,7 +235,7 @@ __decorate([
|
|
|
235
235
|
], TuiPrimitiveTextfieldComponent.prototype, "iconCleaner", void 0);
|
|
236
236
|
__decorate([
|
|
237
237
|
Input(),
|
|
238
|
-
HostBinding(
|
|
238
|
+
HostBinding('class._readonly'),
|
|
239
239
|
tuiDefaultProp()
|
|
240
240
|
], TuiPrimitiveTextfieldComponent.prototype, "readOnly", void 0);
|
|
241
241
|
__decorate([
|
|
@@ -268,37 +268,37 @@ __decorate([
|
|
|
268
268
|
ContentChildren(PolymorpheusOutletComponent)
|
|
269
269
|
], TuiPrimitiveTextfieldComponent.prototype, "content", void 0);
|
|
270
270
|
__decorate([
|
|
271
|
-
HostBinding(
|
|
271
|
+
HostBinding('attr.data-size')
|
|
272
272
|
], TuiPrimitiveTextfieldComponent.prototype, "size", null);
|
|
273
273
|
__decorate([
|
|
274
|
-
HostBinding(
|
|
274
|
+
HostBinding('class._invalid')
|
|
275
275
|
], TuiPrimitiveTextfieldComponent.prototype, "computedInvalid", null);
|
|
276
276
|
__decorate([
|
|
277
|
-
HostBinding(
|
|
277
|
+
HostBinding('class._hidden')
|
|
278
278
|
], TuiPrimitiveTextfieldComponent.prototype, "inputHidden", null);
|
|
279
279
|
__decorate([
|
|
280
|
-
HostBinding(
|
|
280
|
+
HostBinding('style.--border-start.rem')
|
|
281
281
|
], TuiPrimitiveTextfieldComponent.prototype, "borderStart", null);
|
|
282
282
|
__decorate([
|
|
283
|
-
HostBinding(
|
|
283
|
+
HostBinding('style.--border-end.rem')
|
|
284
284
|
], TuiPrimitiveTextfieldComponent.prototype, "borderEnd", null);
|
|
285
285
|
__decorate([
|
|
286
|
-
HostListener(
|
|
287
|
-
HostListener(
|
|
286
|
+
HostListener('focusin', ['true']),
|
|
287
|
+
HostListener('focusout', ['false'])
|
|
288
288
|
], TuiPrimitiveTextfieldComponent.prototype, "onFocused", null);
|
|
289
289
|
__decorate([
|
|
290
290
|
tuiPure
|
|
291
291
|
], TuiPrimitiveTextfieldComponent.prototype, "getIndent$", null);
|
|
292
292
|
TuiPrimitiveTextfieldComponent = __decorate([
|
|
293
293
|
Component({
|
|
294
|
-
selector:
|
|
294
|
+
selector: 'tui-primitive-textfield',
|
|
295
295
|
template: "<ng-container *ngIf=\"content?.changes | async\"></ng-container>\n<tui-wrapper\n automation-id=\"tui-primitive-textfield__wrapper\"\n [appearance]=\"appearance\"\n [readOnly]=\"readOnly\"\n [disabled]=\"disabled\"\n [focused]=\"computedFocused\"\n [hovered]=\"computedHovered\"\n [pressed]=\"computedPressed\"\n [invalid]=\"computedInvalid\"\n [style.--text-indent.px]=\"decor.pre$ | async\"\n (mousedown)=\"onMouseDown($event)\"\n (click.prevent.silent)=\"(0)\"\n (tuiHoveredChange)=\"onHovered($event)\"\n (tuiAutofilledChange)=\"onAutofilled($event)\"\n>\n <ng-content select=\"input\"></ng-content>\n <input\n #focusableElement\n tuiMaskAccessor\n automation-id=\"tui-primitive-textfield__native-input\"\n class=\"t-input\"\n [attr.disabled]=\"computedDisabled || null\"\n [attr.maxLength]=\"controller.maxLength\"\n [attr.name]=\"name\"\n [attr.aria-placeholder]=\"controller.exampleText\"\n [attr.aria-invalid]=\"computedInvalid\"\n [autocomplete]=\"controller.autocomplete\"\n [type]=\"controller.type\"\n [id]=\"id\"\n [readOnly]=\"readOnly || !editable\"\n [tuiInputMode]=\"controller.inputMode\"\n [tuiFocusable]=\"computedFocusable\"\n [tuiDescribedBy]=\"id\"\n [ngModel]=\"value\"\n (ngModelChange)=\"onModelChange($event)\"\n />\n <div\n *ngIf=\"inputHidden\"\n automation-id=\"tui-primitive-textfield__value\"\n class=\"t-input t-input_template\"\n >\n <ng-content select=\"[polymorpheus-outlet]\"></ng-content>\n </div>\n <div class=\"t-content\">\n <div\n *ngIf=\"iconAlignLeft\"\n polymorpheus-outlet\n class=\"t-icon t-icon_left\"\n [content]=\"iconContent\"\n [context]=\"{$implicit: size}\"\n >\n <ng-template let-iconSrc>\n <tui-svg [src]=\"iconSrc\"></tui-svg>\n </ng-template>\n </div>\n <div class=\"t-wrapper\">\n <label\n *ngIf=\"hasPlaceholder\"\n automation-id=\"tui-primitive-textfield__placeholder\"\n class=\"t-placeholder\"\n [class.t-placeholder_raised]=\"placeholderRaised\"\n [for]=\"computedId\"\n >\n <ng-content></ng-content>\n </label>\n <div class=\"t-wrapper-value-decoration\">\n <tui-value-decoration\n #decor\n automation-id=\"tui-primitive-textfield__value-decoration\"\n aria-hidden=\"true\"\n class=\"t-value-decoration\"\n [class.t-has-value]=\"value\"\n [style.textIndent.px]=\"getIndent$(focusableElement) | async\"\n ></tui-value-decoration>\n </div>\n </div>\n <div\n *ngIf=\"hasCustomContent\"\n polymorpheus-outlet\n automation-id=\"tui-primitive-textfield__custom-content\"\n class=\"t-custom-content\"\n [content]=\"controller.customContent\"\n >\n <ng-template let-iconSrc>\n <tui-svg\n class=\"t-custom-icon\"\n [src]=\"iconSrc\"\n ></tui-svg>\n </ng-template>\n </div>\n <span\n *ngIf=\"hasCleaner\"\n polymorpheus-outlet\n automation-id=\"tui-primitive-textfield__cleaner\"\n class=\"t-cleaner\"\n [content]=\"iconCleaner\"\n (click.stop)=\"clear()\"\n >\n <ng-template let-icon>\n <tui-svg [src]=\"icon\"></tui-svg>\n </ng-template>\n </span>\n <tui-tooltip\n *ngIf=\"hasTooltip\"\n automation-id=\"tui-primitive-textfield__tooltip\"\n [describeId]=\"computedId\"\n [content]=\"hintController.content || ''\"\n [direction]=\"hintController.direction\"\n [mode]=\"hintController.mode\"\n [showDelay]=\"hintController.showDelay\"\n [hideDelay]=\"hintController.hideDelay\"\n ></tui-tooltip>\n <div\n *ngIf=\"iconAlignRight\"\n polymorpheus-outlet\n class=\"t-icon\"\n [content]=\"iconContent\"\n [context]=\"{$implicit: size}\"\n >\n <ng-template let-iconSrc>\n <tui-svg [src]=\"iconSrc\"></tui-svg>\n </ng-template>\n </div>\n </div>\n</tui-wrapper>\n",
|
|
296
296
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
297
297
|
providers: TUI_PRIMITIVE_TEXTFIELD_PROVIDERS,
|
|
298
298
|
host: {
|
|
299
|
-
'($.data-mode.attr)':
|
|
300
|
-
'[class._autofilled]':
|
|
301
|
-
'[class._label-outside]':
|
|
299
|
+
'($.data-mode.attr)': 'mode$',
|
|
300
|
+
'[class._autofilled]': 'autofilled',
|
|
301
|
+
'[class._label-outside]': 'controller.labelOutside',
|
|
302
302
|
},
|
|
303
303
|
styles: [":host{font:var(--tui-font-text-s);color:var(--tui-text-01);position:relative;display:block;border-radius:var(--tui-radius-m);text-align:left}:host[data-size='s']{height:var(--tui-height-s);min-height:var(--tui-height-s);max-height:var(--tui-height-s)}:host[data-size='m']{height:var(--tui-height-m);min-height:var(--tui-height-m);max-height:var(--tui-height-m)}:host[data-size='l']{height:var(--tui-height-l);min-height:var(--tui-height-l);max-height:var(--tui-height-l);font:var(--tui-font-text-m);line-height:1.25rem}.t-input{font:var(--tui-font-text-s);color:var(--tui-text-01);padding:0;margin:0;border:0;border-radius:inherit;background:0 0;font-size:inherit;line-height:inherit;font-weight:inherit;color:inherit;caret-color:currentColor;outline:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;word-break:keep-all;-webkit-text-fill-color:currentColor;position:absolute;top:0;left:0;width:100%;height:100%;padding:0 var(--tui-padding-m);border:solid transparent;border-width:0 var(--border-end,0) 0 var(--border-start,0);border-inline-start-width:var(--border-start,0);border-inline-end-width:var(--border-end,0);text-indent:var(--text-indent);text-align:inherit;box-sizing:border-box;white-space:nowrap;overflow:hidden;text-transform:inherit;resize:none}.t-input:-webkit-autofill,.t-input:-webkit-autofill:focus,.t-input:-webkit-autofill:hover{caret-color:var(--tui-base-09);border-radius:inherit;color:inherit!important;background-color:transparent!important;-webkit-text-fill-color:var(--tui-text-01)!important;border-color:var(--tui-autofill);-webkit-box-shadow:0 0 0 100rem var(--tui-autofill) inset!important}.t-input :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill,.t-input :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill:focus,.t-input :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill:hover,.t-input :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill,.t-input :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill:focus,.t-input :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill:hover,:host[data-mode=onDark] .t-input:-webkit-autofill,:host[data-mode=onDark] .t-input:-webkit-autofill:focus,:host[data-mode=onDark] .t-input:-webkit-autofill:hover{caret-color:var(--tui-base-09);border-radius:inherit;color:inherit!important;background-color:transparent!important;-webkit-text-fill-color:var(--tui-text-01-night)!important;border-color:var(--tui-autofill-night);-webkit-box-shadow:0 0 0 100rem var(--tui-autofill-night) inset!important}.t-input :host-context(tui-primitive-textfield[data-size='s']):not(tui-primitive-textfield),.t-input :host-context(tui-text-area[data-size='s']):not(tui-text-area),:host[data-size='s'] .t-input{padding:0 var(--tui-padding-s)}.t-input :host-context(tui-primitive-textfield[data-size='l']):not(tui-primitive-textfield),.t-input :host-context(tui-text-area[data-size='l']):not(tui-text-area),:host[data-size='l'] .t-input{padding:0 var(--tui-padding-l)}.t-input :host-context(tui-primitive-textfield._disabled),.t-input :host-context(tui-text-area._disabled),:host._disabled .t-input{pointer-events:none}.t-input :host-context(tui-primitive-textfield[data-size='l']:not(._label-outside)):not(tui-primitive-textfield),:host[data-size='l']:not(._label-outside) .t-input{padding-top:1.25rem}.t-input :host-context(tui-primitive-textfield[data-size='l']:not(._label-outside)):not(tui-primitive-textfield):-webkit-autofill+.t-content .t-placeholder,:host[data-size='l']:not(._label-outside) .t-input:-webkit-autofill+.t-content .t-placeholder{font-size:.8156rem;transform:translateY(-.625rem)}.t-input :host-context(tui-primitive-textfield[data-size='m']:not(._label-outside)):not(tui-primitive-textfield),:host[data-size='m']:not(._label-outside) .t-input{padding-top:1.125rem}.t-input :host-context(tui-primitive-textfield[data-size='m']:not(._label-outside)):not(tui-primitive-textfield):-webkit-autofill+.t-content .t-placeholder,:host[data-size='m']:not(._label-outside) .t-input:-webkit-autofill+.t-content .t-placeholder{font-size:.69rem;transform:translateY(-.5rem)}.t-input :host-context(tui-primitive-textfield._hidden),:host._hidden input.t-input{opacity:0;text-indent:-10em;-webkit-user-select:none}.t-content{display:flex;height:100%;width:100%;padding:0 var(--tui-padding-m);box-sizing:border-box;align-items:center;overflow:hidden}:host[data-size='s'] .t-content{padding:0 var(--tui-padding-s)}:host[data-size='l'] .t-content{padding:0 var(--tui-padding-l)}.t-content:after{content:'';margin-right:-.25rem}:host[data-size='m'] .t-content:after{display:none}.t-wrapper{flex:1;min-width:0;padding-right:.25rem;-webkit-padding-end:.25rem;padding-inline-end:.25rem;-webkit-padding-start:0;padding-inline-start:0}.t-placeholder{transition-property:transform,font-size,color,letter-spacing;transition-duration:var(--tui-duration,300ms);transition-timing-function:ease-in-out;font:var(--tui-font-text-s);color:var(--tui-text-01);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;color:var(--tui-text-02);pointer-events:none;will-change:transform;transform:translateY(0)}.t-placeholder_raised{transform:translateY(-.625rem)}:host[data-size='m'] .t-placeholder_raised{font:var(--tui-font-text-xs);transform:translateY(-.5rem);letter-spacing:.025rem}:host._invalid:not(._focused) .t-placeholder_raised,:host._invalid:not(._focused):hover .t-placeholder_raised{color:var(--tui-error-fill)}:host[data-mode=onDark]._invalid:not(._focused) .t-placeholder_raised,:host[data-mode=onDark]._invalid:not(._focused):hover .t-placeholder_raised{color:var(--tui-error-fill-night)}:host._focused .t-placeholder,:host[data-size='l']._focused._label-outside .t-placeholder,:host[data-size='m']._focused._label-outside .t-placeholder{color:var(--tui-text-03)}:host[data-size='l'] .t-placeholder{font-size:.9375rem}:host[data-size='l'] .t-placeholder_raised{font-size:.8156rem}:host[data-size='l']._focused:not(._label-outside) .t-placeholder,:host[data-size='m']._focused:not(._label-outside) .t-placeholder{color:var(--tui-text-01)}:host[data-mode=onDark] .t-placeholder{color:var(--tui-text-02-night)}:host[data-size='l'][data-mode=onDark]._focused:not(._label-outside) .t-placeholder,:host[data-size='m'][data-mode=onDark]._focused:not(._label-outside) .t-placeholder{color:var(--tui-text-01-night)}:host[data-mode=onDark]._focused .t-placeholder,:host[data-size='l'][data-mode=onDark]._focused._label-outside .t-placeholder,:host[data-size='m'][data-mode=onDark]._focused._label-outside .t-placeholder{color:var(--tui-text-02-night)}@supports (-webkit-hyphens:none){.t-placeholder{will-change:unset;transition-property:transform,color,letter-spacing}}.t-cleaner{transition-duration:var(--tui-duration,300ms);transition-timing-function:ease-in-out;display:flex;width:1.5rem;height:1.5rem;align-items:center;justify-content:center;color:var(--tui-text-03);position:relative;box-sizing:border-box;cursor:pointer;transition-property:color,transform}.t-cleaner:hover{color:var(--tui-text-02)}:host._disabled .t-cleaner,:host._readonly .t-cleaner{pointer-events:none}:host[data-mode=onDark] .t-cleaner{color:var(--tui-text-03-night)}:host[data-mode=onDark] .t-cleaner:hover{color:var(--tui-text-01-night)}.t-icon{display:flex;align-items:center;justify-content:center;color:var(--tui-text-03)}.t-icon_left{margin:0 .5rem 0 -.25rem;-webkit-margin-start:-.25rem;margin-inline-start:-.25rem;-webkit-margin-end:.5rem;margin-inline-end:.5rem}:host[data-size='s'] .t-icon_left{margin-right:.25rem;-webkit-margin-end:.25rem;margin-inline-end:.25rem}:host._autofilled .t-value-decoration:not(.t-has-value){visibility:hidden}:host._autofilled[data-size='m']:not(._focused) .t-placeholder,:host._autofilled[data-size='s']:not(._focused) .t-placeholder{visibility:hidden}.t-custom-content{position:relative;display:flex;align-items:center;justify-content:center;min-width:2rem;height:2rem;margin-right:.25rem;pointer-events:none}.t-custom-icon{width:2rem;height:100%}.t-icon{transition-duration:var(--tui-duration,300ms);transition-timing-function:ease-in-out;display:flex;width:1.5rem;height:1.5rem;align-items:center;justify-content:center;color:var(--tui-text-03);box-sizing:border-box;cursor:pointer;transition-property:color,transform;position:relative;pointer-events:none}.t-icon:hover{color:var(--tui-text-02)}:host._disabled .t-icon,:host._readonly .t-icon{pointer-events:none}:host[data-mode=onDark] .t-icon{color:var(--tui-text-03-night)}:host[data-mode=onDark] .t-icon:hover{color:var(--tui-text-01-night)}:host:hover:not(._readonly) .t-icon{color:var(--tui-text-02)}:host[data-mode=onDark]:hover:not(._readonly) .t-icon{color:var(--tui-text-01-night)}:host[data-mode=onLight]:hover:not(._readonly) .t-icon{color:var(--tui-text-01)}.t-input:not(:first-child){display:none}:host[data-size] .t-input_template{display:flex;width:calc(100% - 1rem);max-width:calc(100% - 1rem);align-items:center;pointer-events:none;-webkit-padding-end:0;padding-inline-end:0}.t-input:-webkit-autofill,.t-input:-webkit-autofill::first-line{font-size:inherit;line-height:inherit}.t-input::-webkit-caps-lock-indicator,.t-input::-webkit-contacts-auto-fill-button,.t-input::-webkit-credentials-auto-fill-button,.t-input::-webkit-credit-card-auto-fill-button,.t-input::-webkit-strong-password-auto-fill-button{content:none!important;position:absolute;left:-62.4375rem;top:-62.4375rem;z-index:-999;display:none!important;background:0 0!important;pointer-events:none!important}.t-text-template{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.t-wrapper-value-decoration{position:relative;pointer-events:none}"]
|
|
304
304
|
}),
|
|
@@ -333,7 +333,7 @@ TuiPrimitiveTextfieldDirective.ctorParameters = () => [
|
|
|
333
333
|
];
|
|
334
334
|
TuiPrimitiveTextfieldDirective = TuiPrimitiveTextfieldDirective_1 = __decorate([
|
|
335
335
|
Directive({
|
|
336
|
-
selector:
|
|
336
|
+
selector: 'tui-primitive-textfield',
|
|
337
337
|
providers: [
|
|
338
338
|
{
|
|
339
339
|
provide: TUI_TEXTFIELD_HOST,
|
|
@@ -372,29 +372,29 @@ TuiTextfieldComponent.ctorParameters = () => [
|
|
|
372
372
|
{ type: TuiIdService, decorators: [{ type: Inject, args: [TuiIdService,] }] }
|
|
373
373
|
];
|
|
374
374
|
__decorate([
|
|
375
|
-
HostBinding(
|
|
375
|
+
HostBinding('attr.aria-describedby')
|
|
376
376
|
], TuiTextfieldComponent.prototype, "computedDescribedBy", null);
|
|
377
377
|
__decorate([
|
|
378
|
-
HostBinding(
|
|
378
|
+
HostBinding('id')
|
|
379
379
|
], TuiTextfieldComponent.prototype, "id", null);
|
|
380
380
|
TuiTextfieldComponent = __decorate([
|
|
381
381
|
Component({
|
|
382
|
-
selector:
|
|
383
|
-
template:
|
|
382
|
+
selector: 'input[tuiTextfield], textarea[tuiTextfield]',
|
|
383
|
+
template: '',
|
|
384
384
|
providers: [
|
|
385
385
|
TuiDescribedByDirective,
|
|
386
386
|
TUI_DESCRIBED_BY_PROVIDERS,
|
|
387
387
|
TEXTFIELD_CONTROLLER_PROVIDER$1,
|
|
388
388
|
],
|
|
389
389
|
host: {
|
|
390
|
-
type:
|
|
391
|
-
'[attr.aria-placeholder]':
|
|
392
|
-
'[attr.aria-invalid]':
|
|
393
|
-
'[attr.disabled]':
|
|
394
|
-
'[tabIndex]':
|
|
395
|
-
'[readOnly]':
|
|
396
|
-
'[value]':
|
|
397
|
-
'(input)':
|
|
390
|
+
type: 'text',
|
|
391
|
+
'[attr.aria-placeholder]': 'controller.exampleText',
|
|
392
|
+
'[attr.aria-invalid]': 'host.invalid',
|
|
393
|
+
'[attr.disabled]': 'host.disabled || null',
|
|
394
|
+
'[tabIndex]': 'host.focusable ? 0 : -1',
|
|
395
|
+
'[readOnly]': 'host.readOnly',
|
|
396
|
+
'[value]': 'host.value',
|
|
397
|
+
'(input)': 'host.onValueChange($event.target.value)',
|
|
398
398
|
},
|
|
399
399
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
400
400
|
styles: [":host{font:var(--tui-font-text-s);color:var(--tui-text-01);padding:0;margin:0;border:0;border-radius:inherit;background:0 0;font-size:inherit;line-height:inherit;font-weight:inherit;color:inherit;caret-color:currentColor;outline:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;word-break:keep-all;-webkit-text-fill-color:currentColor;position:absolute;top:0;left:0;width:100%;height:100%;padding:0 var(--tui-padding-m);border:solid transparent;border-width:0 var(--border-end,0) 0 var(--border-start,0);border-inline-start-width:var(--border-start,0);border-inline-end-width:var(--border-end,0);text-indent:var(--text-indent);text-align:inherit;box-sizing:border-box;white-space:nowrap;overflow:hidden;text-transform:inherit;resize:none}:host:-webkit-autofill,:host:-webkit-autofill:focus,:host:-webkit-autofill:hover{caret-color:var(--tui-base-09);border-radius:inherit;color:inherit!important;background-color:transparent!important;-webkit-text-fill-color:var(--tui-text-01)!important;border-color:var(--tui-autofill);-webkit-box-shadow:0 0 0 100rem var(--tui-autofill) inset!important}:host :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill,:host :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill:focus,:host :host-context(tui-primitive-textfield[data-mode=onDark]):-webkit-autofill:hover,:host :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill,:host :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill:focus,:host :host-context(tui-text-area[data-mode=onDark]):-webkit-autofill:hover,:host[data-mode=onDark] :host:-webkit-autofill,:host[data-mode=onDark] :host:-webkit-autofill:focus,:host[data-mode=onDark] :host:-webkit-autofill:hover{caret-color:var(--tui-base-09);border-radius:inherit;color:inherit!important;background-color:transparent!important;-webkit-text-fill-color:var(--tui-text-01-night)!important;border-color:var(--tui-autofill-night);-webkit-box-shadow:0 0 0 100rem var(--tui-autofill-night) inset!important}:host :host-context(tui-primitive-textfield[data-size='s']):not(tui-primitive-textfield),:host :host-context(tui-text-area[data-size='s']):not(tui-text-area),:host[data-size='s'] :host{padding:0 var(--tui-padding-s)}:host :host-context(tui-primitive-textfield[data-size='l']):not(tui-primitive-textfield),:host :host-context(tui-text-area[data-size='l']):not(tui-text-area),:host[data-size='l'] :host{padding:0 var(--tui-padding-l)}:host :host-context(tui-primitive-textfield._disabled),:host :host-context(tui-text-area._disabled),:host._disabled :host{pointer-events:none}:host :host-context(tui-primitive-textfield[data-size='l']:not(._label-outside)):not(tui-primitive-textfield),:host[data-size='l']:not(._label-outside) :host{padding-top:1.25rem}:host :host-context(tui-primitive-textfield[data-size='l']:not(._label-outside)):not(tui-primitive-textfield):-webkit-autofill+.t-content .t-placeholder,:host[data-size='l']:not(._label-outside) :host:-webkit-autofill+.t-content .t-placeholder{font-size:.8156rem;transform:translateY(-.625rem)}:host :host-context(tui-primitive-textfield[data-size='m']:not(._label-outside)):not(tui-primitive-textfield),:host[data-size='m']:not(._label-outside) :host{padding-top:1.125rem}:host :host-context(tui-primitive-textfield[data-size='m']:not(._label-outside)):not(tui-primitive-textfield):-webkit-autofill+.t-content .t-placeholder,:host[data-size='m']:not(._label-outside) :host:-webkit-autofill+.t-content .t-placeholder{font-size:.69rem;transform:translateY(-.5rem)}:host :host-context(tui-primitive-textfield._hidden),:host._hidden input:host{opacity:0;text-indent:-10em;-webkit-user-select:none}:host::-ms-input-placeholder{color:var(--tui-text-03);opacity:0}:host::placeholder{color:var(--tui-text-03);opacity:0}:host :host-context(tui-primitive-textfield[data-mode=onDark])::-ms-input-placeholder,:host :host-context(tui-text-area[data-mode=onDark])::-ms-input-placeholder{color:var(--tui-text-03-night)}:host :host-context(tui-primitive-textfield[data-mode=onDark])::placeholder,:host :host-context(tui-text-area[data-mode=onDark])::placeholder{color:var(--tui-text-03-night)}:host :host-context(tui-primitive-textfield._focused:not(._readonly))::-ms-input-placeholder,:host :host-context(tui-text-area._focused:not(._readonly))::-ms-input-placeholder{opacity:1}:host :host-context(tui-primitive-textfield._focused:not(._readonly))::placeholder,:host :host-context(tui-text-area._focused:not(._readonly))::placeholder{opacity:1}:host::-webkit-caps-lock-indicator,:host::-webkit-contacts-auto-fill-button,:host::-webkit-credentials-auto-fill-button,:host::-webkit-credit-card-auto-fill-button,:host::-webkit-strong-password-auto-fill-button{content:none!important;position:absolute;left:-62.4375rem;top:-62.4375rem;z-index:-999;display:none!important;background:0 0!important;pointer-events:none!important}textarea:host{white-space:normal}textarea:host :host-context(tui-text-area._ios){padding-left:.8125rem}"]
|
|
@@ -410,7 +410,7 @@ let TuiValueDecorationComponent = class TuiValueDecorationComponent {
|
|
|
410
410
|
constructor(textfield, controller) {
|
|
411
411
|
this.textfield = textfield;
|
|
412
412
|
this.controller = controller;
|
|
413
|
-
this.prefix$ = new BehaviorSubject(
|
|
413
|
+
this.prefix$ = new BehaviorSubject('');
|
|
414
414
|
this.pre$ = this.prefix$.pipe(delay(0), filter(() => { var _a; return !!((_a = this.pre) === null || _a === void 0 ? void 0 : _a.nativeElement.isConnected); }), distinctUntilChanged(), map(() => { var _a; return ((_a = this.pre) === null || _a === void 0 ? void 0 : _a.nativeElement.offsetWidth) || 0; }));
|
|
415
415
|
}
|
|
416
416
|
get isContextTable() {
|
|
@@ -422,26 +422,26 @@ let TuiValueDecorationComponent = class TuiValueDecorationComponent {
|
|
|
422
422
|
get filler() {
|
|
423
423
|
const { focused, placeholder, exampleText, value, textfield } = this;
|
|
424
424
|
if (placeholder && exampleText) {
|
|
425
|
-
return
|
|
425
|
+
return '';
|
|
426
426
|
}
|
|
427
|
-
return focused ? exampleText || textfield.filler.slice(value.length) :
|
|
427
|
+
return focused ? exampleText || textfield.filler.slice(value.length) : '';
|
|
428
428
|
}
|
|
429
429
|
get prefix() {
|
|
430
|
-
return this.decorationsVisible ? this.textfield.prefix :
|
|
430
|
+
return this.decorationsVisible ? this.textfield.prefix : '';
|
|
431
431
|
}
|
|
432
432
|
get postfix() {
|
|
433
|
-
return this.decorationsVisible ? this.computedPostfix :
|
|
433
|
+
return this.decorationsVisible ? this.computedPostfix : '';
|
|
434
434
|
}
|
|
435
435
|
ngDoCheck() {
|
|
436
436
|
this.prefix$.next(this.prefix);
|
|
437
437
|
}
|
|
438
438
|
get placeholder() {
|
|
439
439
|
var _a;
|
|
440
|
-
return ((_a = this.textfield.nativeFocusableElement) === null || _a === void 0 ? void 0 : _a.placeholder) ||
|
|
440
|
+
return ((_a = this.textfield.nativeFocusableElement) === null || _a === void 0 ? void 0 : _a.placeholder) || '';
|
|
441
441
|
}
|
|
442
442
|
get exampleText() {
|
|
443
443
|
const exampleText = this.controller.exampleText || this.placeholder;
|
|
444
|
-
return !this.value && this.focused ? exampleText :
|
|
444
|
+
return !this.value && this.focused ? exampleText : '';
|
|
445
445
|
}
|
|
446
446
|
get decorationsVisible() {
|
|
447
447
|
return !!this.value || this.focused;
|
|
@@ -460,17 +460,17 @@ TuiValueDecorationComponent.ctorParameters = () => [
|
|
|
460
460
|
{ type: TuiTextfieldController$1, decorators: [{ type: Inject, args: [TUI_TEXTFIELD_WATCHED_CONTROLLER$1,] }] }
|
|
461
461
|
];
|
|
462
462
|
__decorate([
|
|
463
|
-
ViewChild(
|
|
463
|
+
ViewChild('pre', { read: ElementRef, static: true })
|
|
464
464
|
], TuiValueDecorationComponent.prototype, "pre", void 0);
|
|
465
465
|
__decorate([
|
|
466
|
-
HostBinding(
|
|
466
|
+
HostBinding('class._table')
|
|
467
467
|
], TuiValueDecorationComponent.prototype, "isContextTable", null);
|
|
468
468
|
__decorate([
|
|
469
|
-
HostListener(
|
|
469
|
+
HostListener('animationstart')
|
|
470
470
|
], TuiValueDecorationComponent.prototype, "ngDoCheck", null);
|
|
471
471
|
TuiValueDecorationComponent = __decorate([
|
|
472
472
|
Component({
|
|
473
|
-
selector:
|
|
473
|
+
selector: 'tui-value-decoration',
|
|
474
474
|
template: "<span\n #pre\n class=\"t-prefix t-inline\"\n [textContent]=\"prefix\"\n></span>\n<span\n class=\"t-ghost t-inline\"\n [textContent]=\"value\"\n></span>\n<span\n class=\"t-filler t-inline\"\n [textContent]=\"filler\"\n></span>\n<span\n class=\"t-postfix t-inline\"\n [textContent]=\"postfix\"\n></span>\n",
|
|
475
475
|
// It follows Change Detection of PrimitiveTextfield
|
|
476
476
|
changeDetection: ChangeDetectionStrategy.Default,
|