@koobiq/components 17.0.0-rc.10 → 17.0.0-rc.12
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/alert/public-api.d.ts +1 -1
- package/autocomplete/public-api.d.ts +2 -2
- package/badge/public-api.d.ts +1 -1
- package/button/button.component.d.ts +2 -2
- package/button/public-api.d.ts +1 -1
- package/button-toggle/public-api.d.ts +1 -1
- package/card/card.component.d.ts +1 -1
- package/card/public-api.d.ts +1 -1
- package/code-block/code-block.component.d.ts +2 -2
- package/code-block/public-api.d.ts +1 -1
- package/core/animation/index.d.ts +1 -1
- package/core/common-behaviors/index.d.ts +3 -3
- package/core/datetime/index.d.ts +1 -1
- package/core/formatters/index.d.ts +1 -1
- package/core/forms/index.d.ts +1 -1
- package/core/locales/index.d.ts +1 -1
- package/core/option/index.d.ts +2 -2
- package/core/option/optgroup.scss +2 -2
- package/core/pop-up/pop-up-trigger.d.ts +1 -1
- package/core/public-api.d.ts +3 -3
- package/core/select/constants.d.ts +1 -1
- package/core/select/index.d.ts +3 -3
- package/core/styles/common/_animation.scss +8 -8
- package/core/styles/common/_list.scss +23 -62
- package/core/styles/theming/_components-theming.scss +331 -331
- package/core/styles/theming/_theming.scss +3 -3
- package/core/styles/typography/_typography-utils.scss +8 -1
- package/core/styles/typography/_typography.scss +7 -7
- package/core/styles/visual/_layout.scss +1 -1
- package/core/utils/data-size/index.d.ts +1 -1
- package/core/utils/public-api.d.ts +1 -1
- package/datepicker/datepicker-input.directive.d.ts +1 -0
- package/datepicker/public-api.d.ts +4 -4
- package/dl/public-api.d.ts +1 -1
- package/dropdown/_dropdown-theme.scss +4 -1
- package/dropdown/dropdown-content.directive.d.ts +1 -1
- package/dropdown/dropdown-item.component.d.ts +1 -1
- package/dropdown/dropdown-item.scss +9 -6
- package/dropdown/dropdown.component.d.ts +1 -1
- package/dropdown/public-api.d.ts +5 -5
- package/ellipsis-center/ellipsis-center.directive.d.ts +1 -1
- package/empty-state/public-api.d.ts +1 -1
- package/esm2022/alert/alert.component.mjs +3 -3
- package/esm2022/alert/alert.module.mjs +1 -1
- package/esm2022/alert/public-api.mjs +2 -2
- package/esm2022/autocomplete/autocomplete-origin.directive.mjs +1 -1
- package/esm2022/autocomplete/autocomplete-trigger.directive.mjs +23 -31
- package/esm2022/autocomplete/autocomplete.component.mjs +14 -9
- package/esm2022/autocomplete/autocomplete.module.mjs +3 -3
- package/esm2022/autocomplete/public-api.mjs +3 -3
- package/esm2022/badge/badge.component.mjs +6 -4
- package/esm2022/badge/badge.module.mjs +1 -1
- package/esm2022/badge/public-api.mjs +2 -2
- package/esm2022/button/button.component.mjs +12 -9
- package/esm2022/button/button.module.mjs +1 -1
- package/esm2022/button/public-api.mjs +2 -2
- package/esm2022/button-toggle/button-toggle.component.mjs +24 -16
- package/esm2022/button-toggle/button-toggle.module.mjs +1 -1
- package/esm2022/button-toggle/public-api.mjs +2 -2
- package/esm2022/card/card.component.mjs +2 -2
- package/esm2022/card/card.module.mjs +1 -1
- package/esm2022/card/public-api.mjs +2 -2
- package/esm2022/checkbox/checkbox-config.mjs +1 -1
- package/esm2022/checkbox/checkbox-module.mjs +1 -1
- package/esm2022/checkbox/checkbox-required-validator.mjs +1 -1
- package/esm2022/checkbox/checkbox.mjs +6 -6
- package/esm2022/checkbox/public-api.mjs +1 -1
- package/esm2022/code-block/actionbar.component.mjs +4 -6
- package/esm2022/code-block/code-block.component.mjs +16 -13
- package/esm2022/code-block/code-block.module.mjs +9 -5
- package/esm2022/code-block/public-api.mjs +2 -2
- package/esm2022/core/animation/fade-animations.mjs +1 -1
- package/esm2022/core/animation/index.mjs +2 -2
- package/esm2022/core/animation/select-animations.mjs +2 -2
- package/esm2022/core/common-behaviors/color.mjs +4 -2
- package/esm2022/core/common-behaviors/common-module.mjs +2 -2
- package/esm2022/core/common-behaviors/constructor.mjs +1 -1
- package/esm2022/core/common-behaviors/disabled.mjs +1 -1
- package/esm2022/core/common-behaviors/error-state.mjs +1 -1
- package/esm2022/core/common-behaviors/index.mjs +4 -4
- package/esm2022/core/common-behaviors/tabindex.mjs +1 -1
- package/esm2022/core/datetime/date-adapter.mjs +1 -1
- package/esm2022/core/datetime/date-formats.mjs +1 -1
- package/esm2022/core/datetime/index.mjs +2 -2
- package/esm2022/core/error/error-options.mjs +1 -1
- package/esm2022/core/form-field/form-field-ref.mjs +1 -1
- package/esm2022/core/formatters/date/formatter.mjs +1 -1
- package/esm2022/core/formatters/date/formatter.pipe.mjs +1 -1
- package/esm2022/core/formatters/index.mjs +2 -2
- package/esm2022/core/formatters/number/formatter.mjs +19 -20
- package/esm2022/core/forms/forms-module.mjs +1 -1
- package/esm2022/core/forms/forms.directive.mjs +1 -1
- package/esm2022/core/forms/index.mjs +2 -2
- package/esm2022/core/highlight/highlight.pipe.mjs +1 -1
- package/esm2022/core/highlight/index.mjs +1 -1
- package/esm2022/core/label/label-options.mjs +1 -1
- package/esm2022/core/line/line.mjs +2 -2
- package/esm2022/core/locales/en-US.mjs +1 -1
- package/esm2022/core/locales/es-LA.mjs +1 -1
- package/esm2022/core/locales/fa-IR.mjs +1 -1
- package/esm2022/core/locales/index.mjs +2 -2
- package/esm2022/core/locales/locale-service.mjs +8 -5
- package/esm2022/core/locales/locale-service.module.mjs +1 -1
- package/esm2022/core/locales/pt-BR.mjs +1 -1
- package/esm2022/core/locales/ru-RU.mjs +3 -3
- package/esm2022/core/locales/zh-CN.mjs +1 -1
- package/esm2022/core/option/action.mjs +20 -12
- package/esm2022/core/option/index.mjs +3 -3
- package/esm2022/core/option/optgroup.mjs +4 -4
- package/esm2022/core/option/option-module.mjs +1 -1
- package/esm2022/core/option/option.mjs +13 -7
- package/esm2022/core/overlay/overlay-position-map.mjs +1 -1
- package/esm2022/core/pop-up/pop-up-trigger.mjs +15 -23
- package/esm2022/core/pop-up/pop-up.mjs +1 -1
- package/esm2022/core/public-api.mjs +4 -4
- package/esm2022/core/select/common.mjs +2 -2
- package/esm2022/core/select/constants.mjs +1 -1
- package/esm2022/core/select/index.mjs +4 -4
- package/esm2022/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +3 -3
- package/esm2022/core/selection/pseudo-checkbox/pseudo-checkbox.module.mjs +1 -1
- package/esm2022/core/services/measure-scrollbar.service.mjs +1 -1
- package/esm2022/core/services/theme.service.mjs +2 -4
- package/esm2022/core/title/title-text-ref.mjs +1 -1
- package/esm2022/core/utils/data-size/config.mjs +1 -1
- package/esm2022/core/utils/data-size/data-size.pipe.mjs +2 -3
- package/esm2022/core/utils/data-size/index.mjs +2 -2
- package/esm2022/core/utils/data-size/size.mjs +3 -6
- package/esm2022/core/utils/public-api.mjs +2 -2
- package/esm2022/core/utils/utils.mjs +4 -2
- package/esm2022/core/validation/validation.mjs +4 -2
- package/esm2022/core/version.mjs +2 -2
- package/esm2022/datepicker/calendar-body.component.mjs +3 -3
- package/esm2022/datepicker/calendar-header.component.mjs +8 -7
- package/esm2022/datepicker/calendar.component.mjs +6 -6
- package/esm2022/datepicker/datepicker-animations.mjs +1 -1
- package/esm2022/datepicker/datepicker-errors.mjs +1 -1
- package/esm2022/datepicker/datepicker-input.directive.mjs +42 -34
- package/esm2022/datepicker/datepicker-intl.mjs +1 -1
- package/esm2022/datepicker/datepicker-module.mjs +2 -2
- package/esm2022/datepicker/datepicker-toggle.component.mjs +11 -10
- package/esm2022/datepicker/datepicker.component.mjs +15 -15
- package/esm2022/datepicker/month-view.component.mjs +14 -13
- package/esm2022/datepicker/public-api.mjs +5 -5
- package/esm2022/divider/divider.component.mjs +1 -1
- package/esm2022/divider/divider.module.mjs +1 -1
- package/esm2022/dl/dl.component.mjs +1 -1
- package/esm2022/dl/dl.module.mjs +2 -2
- package/esm2022/dl/public-api.mjs +2 -2
- package/esm2022/dropdown/dropdown-animations.mjs +2 -2
- package/esm2022/dropdown/dropdown-content.directive.mjs +3 -3
- package/esm2022/dropdown/dropdown-item.component.mjs +5 -5
- package/esm2022/dropdown/dropdown-trigger.directive.mjs +22 -28
- package/esm2022/dropdown/dropdown.component.mjs +10 -18
- package/esm2022/dropdown/dropdown.module.mjs +1 -1
- package/esm2022/dropdown/dropdown.types.mjs +1 -1
- package/esm2022/dropdown/public-api.mjs +6 -6
- package/esm2022/ellipsis-center/ellipsis-center.directive.mjs +3 -3
- package/esm2022/empty-state/empty-state.component.mjs +1 -1
- package/esm2022/empty-state/empty-state.module.mjs +2 -2
- package/esm2022/empty-state/public-api.mjs +2 -2
- package/esm2022/file-upload/file-drop.mjs +2 -2
- package/esm2022/file-upload/file-upload.mjs +1 -1
- package/esm2022/file-upload/file-upload.module.mjs +2 -2
- package/esm2022/file-upload/index.mjs +1 -1
- package/esm2022/file-upload/multiple-file-upload.component.mjs +16 -12
- package/esm2022/file-upload/public-api.mjs +2 -2
- package/esm2022/file-upload/single-file-upload.component.mjs +14 -10
- package/esm2022/form-field/cleaner.mjs +13 -3
- package/esm2022/form-field/form-field-control.mjs +1 -1
- package/esm2022/form-field/form-field-errors.mjs +1 -1
- package/esm2022/form-field/form-field.mjs +8 -13
- package/esm2022/form-field/form-field.module.mjs +1 -1
- package/esm2022/form-field/hint.mjs +2 -2
- package/esm2022/form-field/password-hint.mjs +13 -13
- package/esm2022/form-field/password-toggle.mjs +4 -7
- package/esm2022/form-field/prefix.mjs +1 -1
- package/esm2022/form-field/public-api.mjs +4 -4
- package/esm2022/form-field/stepper.mjs +33 -29
- package/esm2022/form-field/suffix.mjs +1 -1
- package/esm2022/form-field/validate.directive.mjs +6 -5
- package/esm2022/icon/icon-button.component.mjs +2 -2
- package/esm2022/icon/icon-item.component.mjs +1 -1
- package/esm2022/icon/icon.component.mjs +3 -4
- package/esm2022/icon/icon.module.mjs +1 -1
- package/esm2022/icon/public-api.mjs +3 -3
- package/esm2022/input/input-number-validators.mjs +1 -1
- package/esm2022/input/input-number.mjs +34 -35
- package/esm2022/input/input-password.mjs +13 -7
- package/esm2022/input/input-value-accessor.mjs +1 -1
- package/esm2022/input/input.mjs +13 -7
- package/esm2022/input/input.module.mjs +1 -1
- package/esm2022/input/public-api.mjs +3 -3
- package/esm2022/link/link.component.mjs +2 -2
- package/esm2022/link/link.module.mjs +1 -1
- package/esm2022/link/public-api.mjs +2 -2
- package/esm2022/list/list-selection.component.mjs +34 -36
- package/esm2022/list/list.component.mjs +3 -3
- package/esm2022/list/list.module.mjs +2 -2
- package/esm2022/list/public-api.mjs +3 -3
- package/esm2022/loader-overlay/loader-overlay.component.mjs +3 -3
- package/esm2022/loader-overlay/loader-overlay.module.mjs +1 -1
- package/esm2022/loader-overlay/public-api.mjs +2 -2
- package/esm2022/markdown/markdown.component.mjs +20 -6
- package/esm2022/markdown/markdown.module.mjs +1 -1
- package/esm2022/markdown/markdown.service.mjs +1 -1
- package/esm2022/modal/css-unit.pipe.mjs +1 -1
- package/esm2022/modal/modal-control.service.mjs +3 -2
- package/esm2022/modal/modal-ref.class.mjs +1 -1
- package/esm2022/modal/modal-util.mjs +1 -1
- package/esm2022/modal/modal.component.mjs +50 -27
- package/esm2022/modal/modal.directive.mjs +27 -11
- package/esm2022/modal/modal.module.mjs +2 -2
- package/esm2022/modal/modal.service.mjs +3 -2
- package/esm2022/modal/modal.type.mjs +1 -1
- package/esm2022/modal/public-api.mjs +3 -3
- package/esm2022/navbar/index.mjs +1 -1
- package/esm2022/navbar/navbar-item.component.mjs +37 -28
- package/esm2022/navbar/navbar.component.mjs +19 -28
- package/esm2022/navbar/navbar.module.mjs +2 -2
- package/esm2022/navbar/public-api.mjs +3 -3
- package/esm2022/navbar/vertical-navbar.component.mjs +17 -18
- package/esm2022/popover/popover-animations.mjs +1 -1
- package/esm2022/popover/popover-confirm.component.mjs +3 -3
- package/esm2022/popover/popover.component.mjs +5 -5
- package/esm2022/popover/popover.module.mjs +1 -1
- package/esm2022/popover/public-api.mjs +3 -3
- package/esm2022/progress-bar/progress-bar.component.mjs +4 -4
- package/esm2022/progress-bar/progress-bar.module.mjs +2 -2
- package/esm2022/progress-bar/public-api.mjs +2 -2
- package/esm2022/progress-spinner/progress-spinner.component.mjs +4 -4
- package/esm2022/progress-spinner/progress-spinner.module.mjs +1 -1
- package/esm2022/progress-spinner/public-api.mjs +2 -2
- package/esm2022/radio/public-api.mjs +2 -2
- package/esm2022/radio/radio.component.mjs +9 -10
- package/esm2022/radio/radio.module.mjs +1 -1
- package/esm2022/risk-level/public-api.mjs +2 -2
- package/esm2022/risk-level/risk-level.component.mjs +1 -1
- package/esm2022/risk-level/risk-level.module.mjs +1 -1
- package/esm2022/scrollbar/public-api.mjs +2 -2
- package/esm2022/scrollbar/scrollbar.component.mjs +13 -11
- package/esm2022/scrollbar/scrollbar.directive.mjs +3 -3
- package/esm2022/scrollbar/scrollbar.module.mjs +2 -2
- package/esm2022/scrollbar/scrollbar.types.mjs +3 -2
- package/esm2022/select/public-api.mjs +3 -3
- package/esm2022/select/select-option.directive.mjs +8 -5
- package/esm2022/select/select.component.mjs +41 -64
- package/esm2022/select/select.module.mjs +1 -1
- package/esm2022/sidebar/public-api.mjs +2 -2
- package/esm2022/sidebar/sidebar-animations.mjs +1 -1
- package/esm2022/sidebar/sidebar.component.mjs +3 -3
- package/esm2022/sidebar/sidebar.module.mjs +1 -1
- package/esm2022/sidepanel/public-api.mjs +4 -4
- package/esm2022/sidepanel/sidepanel-animations.mjs +7 -3
- package/esm2022/sidepanel/sidepanel-config.mjs +1 -1
- package/esm2022/sidepanel/sidepanel-container.component.mjs +4 -4
- package/esm2022/sidepanel/sidepanel-directives.mjs +30 -16
- package/esm2022/sidepanel/sidepanel-ref.mjs +10 -4
- package/esm2022/sidepanel/sidepanel.module.mjs +1 -1
- package/esm2022/sidepanel/sidepanel.service.mjs +11 -14
- package/esm2022/splitter/public-api.mjs +2 -2
- package/esm2022/splitter/splitter.component.mjs +13 -23
- package/esm2022/splitter/splitter.module.mjs +1 -1
- package/esm2022/table/public-api.mjs +2 -2
- package/esm2022/table/table.component.mjs +1 -1
- package/esm2022/table/table.module.mjs +1 -1
- package/esm2022/tabs/paginated-tab-header.mjs +8 -11
- package/esm2022/tabs/public-api.mjs +6 -6
- package/esm2022/tabs/tab-body.component.mjs +9 -9
- package/esm2022/tabs/tab-content.directive.mjs +1 -1
- package/esm2022/tabs/tab-group.component.mjs +11 -13
- package/esm2022/tabs/tab-header.component.mjs +4 -4
- package/esm2022/tabs/tab-label-wrapper.directive.mjs +1 -1
- package/esm2022/tabs/tab-label.directive.mjs +1 -1
- package/esm2022/tabs/tab-nav-bar/index.mjs +1 -1
- package/esm2022/tabs/tab-nav-bar/tab-nav-bar.mjs +2 -2
- package/esm2022/tabs/tab.component.mjs +4 -6
- package/esm2022/tabs/tabs-animations.mjs +1 -1
- package/esm2022/tabs/tabs.module.mjs +2 -2
- package/esm2022/tags/public-api.mjs +5 -5
- package/esm2022/tags/tag-default-options.mjs +1 -1
- package/esm2022/tags/tag-input.mjs +12 -14
- package/esm2022/tags/tag-list.component.mjs +14 -20
- package/esm2022/tags/tag-text-control.mjs +1 -1
- package/esm2022/tags/tag.component.mjs +5 -7
- package/esm2022/tags/tag.module.mjs +9 -5
- package/esm2022/textarea/index.mjs +1 -1
- package/esm2022/textarea/textarea.component.mjs +4 -6
- package/esm2022/textarea/textarea.module.mjs +1 -1
- package/esm2022/timepicker/public-api.mjs +2 -2
- package/esm2022/timepicker/timepicker.constants.mjs +6 -1
- package/esm2022/timepicker/timepicker.directive.mjs +62 -26
- package/esm2022/timepicker/timepicker.module.mjs +1 -1
- package/esm2022/timezone/cities-by-filter.pipe.mjs +1 -1
- package/esm2022/timezone/timezone-option.component.mjs +12 -11
- package/esm2022/timezone/timezone-option.directive.mjs +3 -3
- package/esm2022/timezone/timezone-select.component.mjs +5 -5
- package/esm2022/timezone/timezone.module.mjs +1 -1
- package/esm2022/timezone/timezone.utils.mjs +5 -9
- package/esm2022/timezone/utc-offset.pipe.mjs +1 -1
- package/esm2022/title/public-api.mjs +2 -2
- package/esm2022/title/title.directive.mjs +9 -5
- package/esm2022/title/title.module.mjs +1 -1
- package/esm2022/toast/public-api.mjs +4 -4
- package/esm2022/toast/toast-animations.mjs +2 -2
- package/esm2022/toast/toast-container.component.mjs +3 -4
- package/esm2022/toast/toast.component.mjs +5 -5
- package/esm2022/toast/toast.module.mjs +1 -1
- package/esm2022/toast/toast.service.mjs +14 -30
- package/esm2022/toast/toast.type.mjs +1 -1
- package/esm2022/toggle/public-api.mjs +2 -2
- package/esm2022/toggle/toggle.component.mjs +17 -9
- package/esm2022/toggle/toggle.module.mjs +1 -1
- package/esm2022/tooltip/public-api.mjs +2 -2
- package/esm2022/tooltip/tooltip.animations.mjs +1 -1
- package/esm2022/tooltip/tooltip.component.mjs +7 -5
- package/esm2022/tooltip/tooltip.module.mjs +2 -2
- package/esm2022/tree/control/base-tree-control.mjs +1 -1
- package/esm2022/tree/control/flat-tree-control.filters.mjs +4 -7
- package/esm2022/tree/control/flat-tree-control.mjs +4 -7
- package/esm2022/tree/control/nested-tree-control.mjs +1 -1
- package/esm2022/tree/control/tree-control.mjs +1 -1
- package/esm2022/tree/data-source/flat-data-source.mjs +3 -8
- package/esm2022/tree/data-source/nested-data-source.mjs +2 -3
- package/esm2022/tree/node.mjs +1 -1
- package/esm2022/tree/outlet.mjs +1 -1
- package/esm2022/tree/padding.directive.mjs +4 -5
- package/esm2022/tree/public-api.mjs +11 -11
- package/esm2022/tree/toggle.mjs +8 -5
- package/esm2022/tree/tree-base.mjs +3 -3
- package/esm2022/tree/tree-errors.mjs +1 -1
- package/esm2022/tree/tree-option.component.mjs +9 -13
- package/esm2022/tree/tree-selection.component.mjs +17 -36
- package/esm2022/tree/tree.mjs +7 -3
- package/esm2022/tree/tree.module.mjs +4 -4
- package/esm2022/tree-select/public-api.mjs +2 -2
- package/esm2022/tree-select/tree-select.component.mjs +54 -64
- package/esm2022/tree-select/tree-select.module.mjs +1 -1
- package/fesm2022/koobiq-components-alert.mjs +6 -6
- package/fesm2022/koobiq-components-alert.mjs.map +1 -1
- package/fesm2022/koobiq-components-autocomplete.mjs +58 -61
- package/fesm2022/koobiq-components-autocomplete.mjs.map +1 -1
- package/fesm2022/koobiq-components-badge.mjs +8 -6
- package/fesm2022/koobiq-components-badge.mjs.map +1 -1
- package/fesm2022/koobiq-components-button-toggle.mjs +28 -20
- package/fesm2022/koobiq-components-button-toggle.mjs.map +1 -1
- package/fesm2022/koobiq-components-button.mjs +14 -11
- package/fesm2022/koobiq-components-button.mjs.map +1 -1
- package/fesm2022/koobiq-components-card.mjs +2 -2
- package/fesm2022/koobiq-components-card.mjs.map +1 -1
- package/fesm2022/koobiq-components-checkbox.mjs +3 -3
- package/fesm2022/koobiq-components-checkbox.mjs.map +1 -1
- package/fesm2022/koobiq-components-code-block.mjs +33 -28
- package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
- package/fesm2022/koobiq-components-core.mjs +323 -315
- package/fesm2022/koobiq-components-core.mjs.map +1 -1
- package/fesm2022/koobiq-components-datepicker.mjs +100 -89
- package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-divider.mjs.map +1 -1
- package/fesm2022/koobiq-components-dl.mjs +3 -3
- package/fesm2022/koobiq-components-dl.mjs.map +1 -1
- package/fesm2022/koobiq-components-dropdown.mjs +124 -138
- package/fesm2022/koobiq-components-dropdown.mjs.map +1 -1
- package/fesm2022/koobiq-components-ellipsis-center.mjs.map +1 -1
- package/fesm2022/koobiq-components-empty-state.mjs +3 -3
- package/fesm2022/koobiq-components-empty-state.mjs.map +1 -1
- package/fesm2022/koobiq-components-file-upload.mjs +45 -37
- package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
- package/fesm2022/koobiq-components-form-field.mjs +69 -62
- package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
- package/fesm2022/koobiq-components-icon.mjs +3 -4
- package/fesm2022/koobiq-components-icon.mjs.map +1 -1
- package/fesm2022/koobiq-components-input.mjs +61 -50
- package/fesm2022/koobiq-components-input.mjs.map +1 -1
- package/fesm2022/koobiq-components-link.mjs +1 -1
- package/fesm2022/koobiq-components-link.mjs.map +1 -1
- package/fesm2022/koobiq-components-list.mjs +39 -41
- package/fesm2022/koobiq-components-list.mjs.map +1 -1
- package/fesm2022/koobiq-components-loader-overlay.mjs +6 -6
- package/fesm2022/koobiq-components-loader-overlay.mjs.map +1 -1
- package/fesm2022/koobiq-components-markdown.mjs +18 -4
- package/fesm2022/koobiq-components-markdown.mjs.map +1 -1
- package/fesm2022/koobiq-components-modal.mjs +84 -44
- package/fesm2022/koobiq-components-modal.mjs.map +1 -1
- package/fesm2022/koobiq-components-navbar.mjs +74 -75
- package/fesm2022/koobiq-components-navbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-popover.mjs +12 -12
- package/fesm2022/koobiq-components-popover.mjs.map +1 -1
- package/fesm2022/koobiq-components-progress-bar.mjs +5 -5
- package/fesm2022/koobiq-components-progress-bar.mjs.map +1 -1
- package/fesm2022/koobiq-components-progress-spinner.mjs +5 -5
- package/fesm2022/koobiq-components-progress-spinner.mjs.map +1 -1
- package/fesm2022/koobiq-components-radio.mjs +11 -12
- package/fesm2022/koobiq-components-radio.mjs.map +1 -1
- package/fesm2022/koobiq-components-risk-level.mjs +2 -2
- package/fesm2022/koobiq-components-risk-level.mjs.map +1 -1
- package/fesm2022/koobiq-components-scrollbar.mjs +15 -12
- package/fesm2022/koobiq-components-scrollbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-select.mjs +52 -72
- package/fesm2022/koobiq-components-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidebar.mjs +3 -3
- package/fesm2022/koobiq-components-sidebar.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidepanel.mjs +108 -87
- package/fesm2022/koobiq-components-sidepanel.mjs.map +1 -1
- package/fesm2022/koobiq-components-splitter.mjs +15 -25
- package/fesm2022/koobiq-components-splitter.mjs.map +1 -1
- package/fesm2022/koobiq-components-table.mjs +3 -3
- package/fesm2022/koobiq-components-table.mjs.map +1 -1
- package/fesm2022/koobiq-components-tabs.mjs +36 -43
- package/fesm2022/koobiq-components-tabs.mjs.map +1 -1
- package/fesm2022/koobiq-components-tags.mjs +38 -44
- package/fesm2022/koobiq-components-tags.mjs.map +1 -1
- package/fesm2022/koobiq-components-textarea.mjs +2 -4
- package/fesm2022/koobiq-components-textarea.mjs.map +1 -1
- package/fesm2022/koobiq-components-timepicker.mjs +69 -28
- package/fesm2022/koobiq-components-timepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-timezone.mjs +16 -19
- package/fesm2022/koobiq-components-timezone.mjs.map +1 -1
- package/fesm2022/koobiq-components-title.mjs +11 -7
- package/fesm2022/koobiq-components-title.mjs.map +1 -1
- package/fesm2022/koobiq-components-toast.mjs +69 -86
- package/fesm2022/koobiq-components-toast.mjs.map +1 -1
- package/fesm2022/koobiq-components-toggle.mjs +17 -9
- package/fesm2022/koobiq-components-toggle.mjs.map +1 -1
- package/fesm2022/koobiq-components-tooltip.mjs +10 -8
- package/fesm2022/koobiq-components-tooltip.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree-select.mjs +63 -73
- package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree.mjs +506 -535
- package/fesm2022/koobiq-components-tree.mjs.map +1 -1
- package/file-upload/multiple-file-upload.component.d.ts +2 -2
- package/file-upload/public-api.d.ts +1 -1
- package/file-upload/single-file-upload.component.d.ts +2 -2
- package/form-field/public-api.d.ts +3 -3
- package/icon/public-api.d.ts +2 -2
- package/input/public-api.d.ts +2 -2
- package/link/_link-theme.scss +1 -1
- package/link/link.component.d.ts +1 -1
- package/link/public-api.d.ts +1 -1
- package/list/list-selection.component.d.ts +2 -2
- package/list/list.scss +1 -1
- package/list/public-api.d.ts +2 -2
- package/loader-overlay/public-api.d.ts +1 -1
- package/modal/README.md +1 -1
- package/modal/modal.directive.d.ts +3 -3
- package/modal/modal.type.d.ts +2 -2
- package/modal/public-api.d.ts +2 -2
- package/navbar/_navbar-item_horizontal.scss +31 -23
- package/navbar/_navbar-item_vertical.scss +0 -2
- package/navbar/navbar-item.scss +7 -0
- package/navbar/public-api.d.ts +2 -2
- package/package.json +6 -6
- package/popover/popover.component.d.ts +1 -1
- package/popover/public-api.d.ts +2 -2
- package/prebuilt-themes/dark-theme.css +1 -1
- package/prebuilt-themes/light-theme.css +1 -1
- package/progress-bar/public-api.d.ts +1 -1
- package/progress-spinner/public-api.d.ts +1 -1
- package/radio/_radio-theme.scss +1 -0
- package/radio/public-api.d.ts +1 -1
- package/radio/radio.scss +12 -2
- package/risk-level/public-api.d.ts +1 -1
- package/schematics/ng-add/index.js +4 -4
- package/scrollbar/public-api.d.ts +1 -1
- package/scrollbar/scrollbar.directive.d.ts +1 -1
- package/scrollbar/scrollbar.types.d.ts +1 -1
- package/select/public-api.d.ts +2 -2
- package/select/select.component.d.ts +1 -1
- package/sidebar/public-api.d.ts +1 -1
- package/sidepanel/public-api.d.ts +3 -3
- package/sidepanel/sidepanel.scss +1 -1
- package/splitter/public-api.d.ts +1 -1
- package/table/public-api.d.ts +1 -1
- package/tabs/paginated-tab-header.d.ts +1 -1
- package/tabs/public-api.d.ts +5 -5
- package/tabs/tab-body.component.d.ts +3 -3
- package/tabs/tab-group.component.d.ts +1 -1
- package/tags/public-api.d.ts +4 -4
- package/tags/tag-input.d.ts +1 -1
- package/textarea/textarea.component.d.ts +1 -1
- package/timepicker/public-api.d.ts +1 -1
- package/timepicker/timepicker.constants.d.ts +2 -0
- package/timepicker/timepicker.directive.d.ts +10 -3
- package/timezone/timezone-option.directive.d.ts +1 -1
- package/timezone/timezone.utils.d.ts +1 -1
- package/title/public-api.d.ts +1 -1
- package/toast/public-api.d.ts +3 -3
- package/toast/toast.component.scss +4 -1
- package/toast/toast.service.d.ts +2 -2
- package/toast/toast.type.d.ts +1 -1
- package/toggle/public-api.d.ts +1 -1
- package/tooltip/public-api.d.ts +1 -1
- package/tooltip/tooltip.component.d.ts +2 -2
- package/tree/public-api.d.ts +10 -10
- package/tree/tree-base.d.ts +1 -1
- package/tree/tree-option.component.d.ts +1 -1
- package/tree/tree-selection.component.d.ts +1 -1
- package/tree-select/public-api.d.ts +1 -1
- package/tree-select/tree-select.component.d.ts +6 -4
|
@@ -1,30 +1,22 @@
|
|
|
1
1
|
import { trigger, state, style, transition, animate, group } from '@angular/animations';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { InjectionToken, isDevMode, NgModule, Optional, Inject, inject, LOCALE_ID, Injectable, Pipe, Directive, ContentChildren, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, EventEmitter, ViewChild, Output,
|
|
3
|
+
import { InjectionToken, isDevMode, NgModule, Optional, Inject, inject, LOCALE_ID, Injectable, Pipe, Directive, ContentChildren, Component, ViewEncapsulation, ChangeDetectionStrategy, ContentChild, Input, EventEmitter, ViewChild, Output, TemplateRef, Version } from '@angular/core';
|
|
4
4
|
import * as i2$1 from '@angular/cdk/bidi';
|
|
5
5
|
import { BidiModule } from '@angular/cdk/bidi';
|
|
6
6
|
import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';
|
|
7
7
|
import * as i1 from '@koobiq/date-adapter';
|
|
8
8
|
import { DateAdapter as DateAdapter$1 } from '@koobiq/date-adapter';
|
|
9
9
|
import { DateFormatter as DateFormatter$1 } from '@koobiq/date-formatter';
|
|
10
|
-
import { BehaviorSubject, Subject, Subscription, pairwise } from 'rxjs';
|
|
11
10
|
import * as i2 from '@angular/common';
|
|
12
11
|
import { DOCUMENT, CommonModule } from '@angular/common';
|
|
13
|
-
import {
|
|
12
|
+
import { BehaviorSubject, Subject, Subscription, pairwise } from 'rxjs';
|
|
14
13
|
import * as i1$1 from '@angular/cdk/a11y';
|
|
14
|
+
import { SPACE, ENTER, TAB, ESCAPE, HOME, END } from '@koobiq/cdk/keycodes';
|
|
15
15
|
import { takeUntil, distinctUntilChanged, delay } from 'rxjs/operators';
|
|
16
16
|
import * as i1$2 from '@angular/cdk/overlay';
|
|
17
17
|
import { Overlay } from '@angular/cdk/overlay';
|
|
18
18
|
import { ComponentPortal } from '@angular/cdk/portal';
|
|
19
19
|
|
|
20
|
-
const fadeAnimation = trigger('fadeAnimation', [
|
|
21
|
-
state('void', style({ opacity: 0 })),
|
|
22
|
-
state('true', style({ opacity: 1 })),
|
|
23
|
-
state('false', style({ opacity: 0 })),
|
|
24
|
-
transition('* => true', animate('150ms cubic-bezier(0.0, 0.0, 0.2, 1)')),
|
|
25
|
-
transition('* => void', animate('150ms cubic-bezier(0.4, 0.0, 1, 1)'))
|
|
26
|
-
]);
|
|
27
|
-
|
|
28
20
|
var AnimationCurves;
|
|
29
21
|
(function (AnimationCurves) {
|
|
30
22
|
AnimationCurves["StandardCurve"] = "cubic-bezier(0.4,0.0,0.2,1)";
|
|
@@ -33,6 +25,14 @@ var AnimationCurves;
|
|
|
33
25
|
AnimationCurves["SharpCurve"] = "cubic-bezier(0.4,0.0,0.6,1)";
|
|
34
26
|
})(AnimationCurves || (AnimationCurves = {}));
|
|
35
27
|
|
|
28
|
+
const fadeAnimation = trigger('fadeAnimation', [
|
|
29
|
+
state('void', style({ opacity: 0 })),
|
|
30
|
+
state('true', style({ opacity: 1 })),
|
|
31
|
+
state('false', style({ opacity: 0 })),
|
|
32
|
+
transition('* => true', animate('150ms cubic-bezier(0.0, 0.0, 0.2, 1)')),
|
|
33
|
+
transition('* => void', animate('150ms cubic-bezier(0.4, 0.0, 1, 1)'))
|
|
34
|
+
]);
|
|
35
|
+
|
|
36
36
|
/**
|
|
37
37
|
* The following are all the animations for the kbq-select component, with each
|
|
38
38
|
* const containing the metadata for one animation.
|
|
@@ -77,6 +77,53 @@ const kbqSelectAnimations = {
|
|
|
77
77
|
const transformPanel = kbqSelectAnimations.transformPanel;
|
|
78
78
|
const fadeInContent = kbqSelectAnimations.fadeInContent;
|
|
79
79
|
|
|
80
|
+
var ThemePalette;
|
|
81
|
+
(function (ThemePalette) {
|
|
82
|
+
ThemePalette["Primary"] = "primary";
|
|
83
|
+
ThemePalette["Secondary"] = "secondary";
|
|
84
|
+
ThemePalette["Error"] = "error";
|
|
85
|
+
ThemePalette["Info"] = "info";
|
|
86
|
+
ThemePalette["Warning"] = "warning";
|
|
87
|
+
ThemePalette["Success"] = "success";
|
|
88
|
+
ThemePalette["Default"] = "secondary";
|
|
89
|
+
ThemePalette["Empty"] = "";
|
|
90
|
+
})(ThemePalette || (ThemePalette = {}));
|
|
91
|
+
var KbqComponentColors;
|
|
92
|
+
(function (KbqComponentColors) {
|
|
93
|
+
KbqComponentColors["Theme"] = "theme";
|
|
94
|
+
KbqComponentColors["ThemeFade"] = "theme-fade";
|
|
95
|
+
KbqComponentColors["Contrast"] = "contrast";
|
|
96
|
+
KbqComponentColors["ContrastFade"] = "contrast-fade";
|
|
97
|
+
KbqComponentColors["Error"] = "error";
|
|
98
|
+
KbqComponentColors["Warning"] = "warning";
|
|
99
|
+
KbqComponentColors["Success"] = "success";
|
|
100
|
+
KbqComponentColors["Default"] = "contrast";
|
|
101
|
+
KbqComponentColors["Empty"] = "";
|
|
102
|
+
})(KbqComponentColors || (KbqComponentColors = {}));
|
|
103
|
+
function mixinColor(base, defaultColor = KbqComponentColors.Empty) {
|
|
104
|
+
return class extends base {
|
|
105
|
+
get color() {
|
|
106
|
+
return this._color;
|
|
107
|
+
}
|
|
108
|
+
set color(value) {
|
|
109
|
+
const colorPalette = value || defaultColor;
|
|
110
|
+
if (colorPalette !== this._color) {
|
|
111
|
+
if (this._color) {
|
|
112
|
+
this.elementRef.nativeElement.classList.remove(`kbq-${this._color}`);
|
|
113
|
+
}
|
|
114
|
+
if (colorPalette) {
|
|
115
|
+
this.elementRef.nativeElement.classList.add(`kbq-${colorPalette}`);
|
|
116
|
+
}
|
|
117
|
+
this._color = colorPalette;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
constructor(...args) {
|
|
121
|
+
super(...args);
|
|
122
|
+
this.color = defaultColor;
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
|
|
80
127
|
// Injection token that configures whether the koobiq sanity checks are enabled.
|
|
81
128
|
const KBQ_SANITY_CHECKS = new InjectionToken('kbq-sanity-checks', {
|
|
82
129
|
providedIn: 'root',
|
|
@@ -173,47 +220,23 @@ function mixinDisabled(base) {
|
|
|
173
220
|
};
|
|
174
221
|
}
|
|
175
222
|
|
|
176
|
-
|
|
177
|
-
(function (ThemePalette) {
|
|
178
|
-
ThemePalette["Primary"] = "primary";
|
|
179
|
-
ThemePalette["Secondary"] = "secondary";
|
|
180
|
-
ThemePalette["Error"] = "error";
|
|
181
|
-
ThemePalette["Info"] = "info";
|
|
182
|
-
ThemePalette["Warning"] = "warning";
|
|
183
|
-
ThemePalette["Success"] = "success";
|
|
184
|
-
ThemePalette["Default"] = "secondary";
|
|
185
|
-
ThemePalette["Empty"] = "";
|
|
186
|
-
})(ThemePalette || (ThemePalette = {}));
|
|
187
|
-
var KbqComponentColors;
|
|
188
|
-
(function (KbqComponentColors) {
|
|
189
|
-
KbqComponentColors["Theme"] = "theme";
|
|
190
|
-
KbqComponentColors["ThemeFade"] = "theme-fade";
|
|
191
|
-
KbqComponentColors["Contrast"] = "contrast";
|
|
192
|
-
KbqComponentColors["ContrastFade"] = "contrast-fade";
|
|
193
|
-
KbqComponentColors["Error"] = "error";
|
|
194
|
-
KbqComponentColors["Warning"] = "warning";
|
|
195
|
-
KbqComponentColors["Success"] = "success";
|
|
196
|
-
KbqComponentColors["Default"] = "contrast";
|
|
197
|
-
KbqComponentColors["Empty"] = "";
|
|
198
|
-
})(KbqComponentColors || (KbqComponentColors = {}));
|
|
199
|
-
function mixinColor(base, defaultColor = KbqComponentColors.Empty) {
|
|
223
|
+
function mixinErrorState(base) {
|
|
200
224
|
return class extends base {
|
|
201
|
-
get color() { return this._color; }
|
|
202
|
-
set color(value) {
|
|
203
|
-
const colorPalette = value || defaultColor;
|
|
204
|
-
if (colorPalette !== this._color) {
|
|
205
|
-
if (this._color) {
|
|
206
|
-
this.elementRef.nativeElement.classList.remove(`kbq-${this._color}`);
|
|
207
|
-
}
|
|
208
|
-
if (colorPalette) {
|
|
209
|
-
this.elementRef.nativeElement.classList.add(`kbq-${colorPalette}`);
|
|
210
|
-
}
|
|
211
|
-
this._color = colorPalette;
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
225
|
constructor(...args) {
|
|
215
226
|
super(...args);
|
|
216
|
-
|
|
227
|
+
/** Whether the component is in an error state. */
|
|
228
|
+
this.errorState = false;
|
|
229
|
+
}
|
|
230
|
+
updateErrorState() {
|
|
231
|
+
const oldState = this.errorState;
|
|
232
|
+
const parent = this.parentFormGroup || this.parentForm;
|
|
233
|
+
const matcher = this.errorStateMatcher || this.defaultErrorStateMatcher;
|
|
234
|
+
const control = this.ngControl ? this.ngControl.control : null;
|
|
235
|
+
const newState = matcher.isErrorState(control, parent);
|
|
236
|
+
if (newState !== oldState) {
|
|
237
|
+
this.errorState = newState;
|
|
238
|
+
this.stateChanges.next();
|
|
239
|
+
}
|
|
217
240
|
}
|
|
218
241
|
};
|
|
219
242
|
}
|
|
@@ -235,31 +258,8 @@ function mixinTabIndex(base, defaultTabIndex = 0) {
|
|
|
235
258
|
};
|
|
236
259
|
}
|
|
237
260
|
|
|
238
|
-
function mixinErrorState(base) {
|
|
239
|
-
return class extends base {
|
|
240
|
-
constructor(...args) {
|
|
241
|
-
super(...args);
|
|
242
|
-
/** Whether the component is in an error state. */
|
|
243
|
-
this.errorState = false;
|
|
244
|
-
}
|
|
245
|
-
updateErrorState() {
|
|
246
|
-
const oldState = this.errorState;
|
|
247
|
-
const parent = this.parentFormGroup || this.parentForm;
|
|
248
|
-
const matcher = this.errorStateMatcher || this.defaultErrorStateMatcher;
|
|
249
|
-
const control = this.ngControl ? this.ngControl.control : null;
|
|
250
|
-
const newState = matcher.isErrorState(control, parent);
|
|
251
|
-
if (newState !== oldState) {
|
|
252
|
-
this.errorState = newState;
|
|
253
|
-
this.stateChanges.next();
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
};
|
|
257
|
-
}
|
|
258
|
-
|
|
259
261
|
const KBQ_PARENT_ANIMATION_COMPONENT = new InjectionToken('kbq-parent-animation-component');
|
|
260
262
|
|
|
261
|
-
const KBQ_DATE_FORMATS = new InjectionToken('kbq-date-formats');
|
|
262
|
-
|
|
263
263
|
/** InjectionToken for datepicker that can be used to override default locale code. */
|
|
264
264
|
const KBQ_DATE_LOCALE = new InjectionToken('KBQ_DATE_LOCALE', {
|
|
265
265
|
providedIn: 'root',
|
|
@@ -273,6 +273,8 @@ function KBQ_DATE_LOCALE_FACTORY() {
|
|
|
273
273
|
class DateAdapter extends DateAdapter$1 {
|
|
274
274
|
}
|
|
275
275
|
|
|
276
|
+
const KBQ_DATE_FORMATS = new InjectionToken('kbq-date-formats');
|
|
277
|
+
|
|
276
278
|
/** Error state matcher that matches when a control is invalid and dirty. */
|
|
277
279
|
class ShowOnDirtyErrorStateMatcher {
|
|
278
280
|
isErrorState(control, form) {
|
|
@@ -297,6 +299,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
297
299
|
args: [{ providedIn: 'root' }]
|
|
298
300
|
}] });
|
|
299
301
|
|
|
302
|
+
/**
|
|
303
|
+
* Injection token that can be used to inject an instances of `KbqFormField`. It serves
|
|
304
|
+
* as alternative token to the actual `KbqFormField` class which would cause unnecessary
|
|
305
|
+
* retention of the `KbqFormField` class and its component metadata.
|
|
306
|
+
*/
|
|
307
|
+
const KBQ_FORM_FIELD_REF = new InjectionToken('KbqFormFieldRef');
|
|
308
|
+
|
|
300
309
|
class DateFormatter extends DateFormatter$1 {
|
|
301
310
|
constructor(adapter, locale) {
|
|
302
311
|
super(adapter, locale);
|
|
@@ -655,8 +664,8 @@ const ruRULocaleData = {
|
|
|
655
664
|
},
|
|
656
665
|
timepicker: {
|
|
657
666
|
placeholder: {
|
|
658
|
-
full: '
|
|
659
|
-
short: '
|
|
667
|
+
full: 'чч:мм:сс',
|
|
668
|
+
short: 'чч:мм'
|
|
660
669
|
}
|
|
661
670
|
},
|
|
662
671
|
fileUpload: {
|
|
@@ -950,7 +959,10 @@ function KBQ_DEFAULT_LOCALE_DATA_FACTORY() {
|
|
|
950
959
|
'fa-IR': { ...faIRLocaleData, ...faIRFormattersData }
|
|
951
960
|
};
|
|
952
961
|
}
|
|
953
|
-
const KBQ_LOCALE_DATA = new InjectionToken('KBQ_LOCALE_DATA', {
|
|
962
|
+
const KBQ_LOCALE_DATA = new InjectionToken('KBQ_LOCALE_DATA', {
|
|
963
|
+
providedIn: 'root',
|
|
964
|
+
factory: KBQ_DEFAULT_LOCALE_DATA_FACTORY
|
|
965
|
+
});
|
|
954
966
|
const KBQ_LOCALE_SERVICE = new InjectionToken('KBQ_LOCALE_SERVICE');
|
|
955
967
|
class KbqLocaleService {
|
|
956
968
|
constructor(id, localeData) {
|
|
@@ -1090,8 +1102,7 @@ class KbqDecimalPipe {
|
|
|
1090
1102
|
this.localeService = localeService;
|
|
1091
1103
|
this.options = options;
|
|
1092
1104
|
this.options = this.options || KBQ_NUMBER_FORMATTER_DEFAULT_OPTIONS;
|
|
1093
|
-
this.localeService?.changes
|
|
1094
|
-
.subscribe((newId) => this.id = newId);
|
|
1105
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1095
1106
|
}
|
|
1096
1107
|
/**
|
|
1097
1108
|
* @param value The number to be formatted.
|
|
@@ -1172,8 +1183,7 @@ class KbqTableNumberPipe {
|
|
|
1172
1183
|
this.localeService = localeService;
|
|
1173
1184
|
this.options = options;
|
|
1174
1185
|
this.options = this.options || KBQ_NUMBER_FORMATTER_DEFAULT_OPTIONS;
|
|
1175
|
-
this.localeService?.changes
|
|
1176
|
-
.subscribe((newId) => this.id = newId);
|
|
1186
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1177
1187
|
}
|
|
1178
1188
|
/**
|
|
1179
1189
|
* @param value The number to be formatted.
|
|
@@ -1249,8 +1259,7 @@ class KbqRoundDecimalPipe {
|
|
|
1249
1259
|
constructor(id, localeService) {
|
|
1250
1260
|
this.id = id;
|
|
1251
1261
|
this.localeService = localeService;
|
|
1252
|
-
this.localeService?.changes
|
|
1253
|
-
.subscribe((newId) => this.id = newId);
|
|
1262
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1254
1263
|
}
|
|
1255
1264
|
transform(value, locale) {
|
|
1256
1265
|
if (isEmpty(value)) {
|
|
@@ -1266,17 +1275,17 @@ class KbqRoundDecimalPipe {
|
|
|
1266
1275
|
}
|
|
1267
1276
|
let parts = {};
|
|
1268
1277
|
if (intervalsConfig.supportedLanguages.includes(currentLocale)) {
|
|
1269
|
-
intervalsConfig.intervals
|
|
1270
|
-
.find(({ startRange, endRange, precision }) => {
|
|
1278
|
+
intervalsConfig.intervals.find(({ startRange, endRange, precision }) => {
|
|
1271
1279
|
const within = isWithin(startRange, endRange, num);
|
|
1272
1280
|
if (within) {
|
|
1273
1281
|
if (precision) {
|
|
1274
|
-
parts =
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1282
|
+
parts =
|
|
1283
|
+
unit === 'thousand'
|
|
1284
|
+
? this.calculatePartsForThousands(num)
|
|
1285
|
+
: {
|
|
1286
|
+
num: Math.trunc(num / ROUNDING_UNITS[unit]),
|
|
1287
|
+
fraction: this.calculateDecimal(num, ROUNDING_UNITS[unit])
|
|
1288
|
+
};
|
|
1280
1289
|
}
|
|
1281
1290
|
else {
|
|
1282
1291
|
parts = { num: Math.round(num / ROUNDING_UNITS[unit]) };
|
|
@@ -1285,10 +1294,12 @@ class KbqRoundDecimalPipe {
|
|
|
1285
1294
|
return within;
|
|
1286
1295
|
});
|
|
1287
1296
|
}
|
|
1288
|
-
parts = parts.num
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1297
|
+
parts = parts.num
|
|
1298
|
+
? parts
|
|
1299
|
+
: {
|
|
1300
|
+
num: Math.trunc(num / ROUNDING_UNITS[unit]),
|
|
1301
|
+
fraction: this.calculateDecimal(num, ROUNDING_UNITS[unit])
|
|
1302
|
+
};
|
|
1292
1303
|
Object.keys(parts).forEach((key) => {
|
|
1293
1304
|
parts[key] = Intl.NumberFormat.call(this, currentLocale, { useGrouping: false }).format(parts[key]);
|
|
1294
1305
|
});
|
|
@@ -1303,7 +1314,7 @@ class KbqRoundDecimalPipe {
|
|
|
1303
1314
|
}
|
|
1304
1315
|
calculateDecimal(num, divider) {
|
|
1305
1316
|
/* tslint:disable-next-line:no-magic-numbers */
|
|
1306
|
-
return Math.round(num / divider % 1 * 10);
|
|
1317
|
+
return Math.round(((num / divider) % 1) * 10);
|
|
1307
1318
|
}
|
|
1308
1319
|
/**
|
|
1309
1320
|
* 2 * 1000 is a number in the interval of [1500...2500)
|
|
@@ -1433,13 +1444,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1433
1444
|
}]
|
|
1434
1445
|
}] });
|
|
1435
1446
|
|
|
1436
|
-
/**
|
|
1437
|
-
* Injection token that can be used to inject an instances of `KbqFormField`. It serves
|
|
1438
|
-
* as alternative token to the actual `KbqFormField` class which would cause unnecessary
|
|
1439
|
-
* retention of the `KbqFormField` class and its component metadata.
|
|
1440
|
-
*/
|
|
1441
|
-
const KBQ_FORM_FIELD_REF = new InjectionToken('KbqFormFieldRef');
|
|
1442
|
-
|
|
1443
1447
|
class KbqFormElement {
|
|
1444
1448
|
constructor(element) {
|
|
1445
1449
|
this.element = element;
|
|
@@ -1631,7 +1635,127 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1631
1635
|
}]
|
|
1632
1636
|
}] });
|
|
1633
1637
|
|
|
1634
|
-
const
|
|
1638
|
+
const KBQ_OPTION_ACTION_PARENT = new InjectionToken('KBQ_OPTION_ACTION_PARENT');
|
|
1639
|
+
/** @docs-private */
|
|
1640
|
+
class KbqOptionActionBase {
|
|
1641
|
+
}
|
|
1642
|
+
/** @docs-private */
|
|
1643
|
+
const KbqOptionActionMixinBase = mixinTabIndex(mixinDisabled(KbqOptionActionBase));
|
|
1644
|
+
class KbqOptionActionComponent extends KbqOptionActionMixinBase {
|
|
1645
|
+
get active() {
|
|
1646
|
+
return this.hasFocus || !!this.option.dropdownTrigger?.opened;
|
|
1647
|
+
}
|
|
1648
|
+
constructor(elementRef, focusMonitor, option) {
|
|
1649
|
+
super();
|
|
1650
|
+
this.elementRef = elementRef;
|
|
1651
|
+
this.focusMonitor = focusMonitor;
|
|
1652
|
+
this.option = option;
|
|
1653
|
+
this.hasFocus = false;
|
|
1654
|
+
this.destroy = new Subject();
|
|
1655
|
+
this.focusMonitor.monitor(this.elementRef.nativeElement);
|
|
1656
|
+
}
|
|
1657
|
+
ngAfterViewInit() {
|
|
1658
|
+
if (!this.option.dropdownTrigger) {
|
|
1659
|
+
return;
|
|
1660
|
+
}
|
|
1661
|
+
this.option.dropdownTrigger.restoreFocus = false;
|
|
1662
|
+
this.option.dropdownTrigger.dropdownClosed.pipe(takeUntil(this.destroy)).subscribe(() => {
|
|
1663
|
+
this.preventShowingTooltip();
|
|
1664
|
+
const destroyReason = this.option.dropdownTrigger.lastDestroyReason === 'keydown' ? 'keyboard' : 'program';
|
|
1665
|
+
this.focus(destroyReason);
|
|
1666
|
+
});
|
|
1667
|
+
}
|
|
1668
|
+
ngOnDestroy() {
|
|
1669
|
+
this.destroy.next();
|
|
1670
|
+
this.destroy.complete();
|
|
1671
|
+
this.focusMonitor.stopMonitoring(this.elementRef.nativeElement);
|
|
1672
|
+
}
|
|
1673
|
+
focus(origin, options) {
|
|
1674
|
+
if (this.focusMonitor && origin) {
|
|
1675
|
+
this.focusMonitor.focusVia(this.elementRef.nativeElement, origin, options);
|
|
1676
|
+
}
|
|
1677
|
+
else {
|
|
1678
|
+
this.elementRef.nativeElement.focus();
|
|
1679
|
+
}
|
|
1680
|
+
this.hasFocus = true;
|
|
1681
|
+
}
|
|
1682
|
+
onFocus($event) {
|
|
1683
|
+
$event.stopPropagation();
|
|
1684
|
+
this.hasFocus = true;
|
|
1685
|
+
}
|
|
1686
|
+
onBlur() {
|
|
1687
|
+
this.hasFocus = false;
|
|
1688
|
+
}
|
|
1689
|
+
onClick($event) {
|
|
1690
|
+
$event.stopPropagation();
|
|
1691
|
+
}
|
|
1692
|
+
onKeyDown($event) {
|
|
1693
|
+
if ([SPACE, ENTER].includes($event.keyCode) && this.option.dropdownTrigger) {
|
|
1694
|
+
this.option.dropdownTrigger.openedBy = 'keyboard';
|
|
1695
|
+
this.option.dropdownTrigger.toggle();
|
|
1696
|
+
}
|
|
1697
|
+
else if ($event.shiftKey && $event.keyCode === TAB) {
|
|
1698
|
+
this.hasFocus = false;
|
|
1699
|
+
this.option.focus();
|
|
1700
|
+
}
|
|
1701
|
+
else if ($event.keyCode === TAB) {
|
|
1702
|
+
return;
|
|
1703
|
+
}
|
|
1704
|
+
$event.preventDefault();
|
|
1705
|
+
$event.stopPropagation();
|
|
1706
|
+
}
|
|
1707
|
+
preventShowingTooltip() {
|
|
1708
|
+
if (!this.option.tooltipTrigger) {
|
|
1709
|
+
return;
|
|
1710
|
+
}
|
|
1711
|
+
this.option.tooltipTrigger.disabled = true;
|
|
1712
|
+
setTimeout(() => (this.option.tooltipTrigger.disabled = false));
|
|
1713
|
+
}
|
|
1714
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptionActionComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.FocusMonitor }, { token: KBQ_OPTION_ACTION_PARENT }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1715
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOptionActionComponent, selector: "kbq-option-action", inputs: { disabled: "disabled" }, host: { listeners: { "focus": "onFocus($event)", "blur": "onBlur()", "click": "onClick($event)", "keydown": "onKeyDown($event)" }, properties: { "class.kbq-expanded": "false", "class.kbq-disabled": "disabled", "attr.disabled": "disabled || null", "attr.tabIndex": "-1" }, classAttribute: "kbq-option-action" }, queries: [{ propertyName: "customIcon", first: true, predicate: ["customIcon"], descendants: true }], exportAs: ["kbqOptionAction"], usesInheritance: true, ngImport: i0, template: `
|
|
1716
|
+
<ng-container [ngSwitch]="!!customIcon">
|
|
1717
|
+
<i
|
|
1718
|
+
class="mc kbq-icon mc-ellipsis_16"
|
|
1719
|
+
*ngSwitchCase="false"
|
|
1720
|
+
></i>
|
|
1721
|
+
<ng-content
|
|
1722
|
+
*ngSwitchCase="true"
|
|
1723
|
+
select="[kbq-icon]"
|
|
1724
|
+
></ng-content>
|
|
1725
|
+
</ng-container>
|
|
1726
|
+
`, isInline: true, styles: [".kbq-option-action{box-sizing:border-box;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:24px;height:24px;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.kbq-option-action.kbq-disabled{cursor:default}\n"], dependencies: [{ kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1727
|
+
}
|
|
1728
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptionActionComponent, decorators: [{
|
|
1729
|
+
type: Component,
|
|
1730
|
+
args: [{ selector: 'kbq-option-action', exportAs: 'kbqOptionAction', template: `
|
|
1731
|
+
<ng-container [ngSwitch]="!!customIcon">
|
|
1732
|
+
<i
|
|
1733
|
+
class="mc kbq-icon mc-ellipsis_16"
|
|
1734
|
+
*ngSwitchCase="false"
|
|
1735
|
+
></i>
|
|
1736
|
+
<ng-content
|
|
1737
|
+
*ngSwitchCase="true"
|
|
1738
|
+
select="[kbq-icon]"
|
|
1739
|
+
></ng-content>
|
|
1740
|
+
</ng-container>
|
|
1741
|
+
`, host: {
|
|
1742
|
+
class: 'kbq-option-action',
|
|
1743
|
+
'[class.kbq-expanded]': 'false',
|
|
1744
|
+
'[class.kbq-disabled]': 'disabled',
|
|
1745
|
+
'[attr.disabled]': 'disabled || null',
|
|
1746
|
+
'[attr.tabIndex]': '-1',
|
|
1747
|
+
'(focus)': 'onFocus($event)',
|
|
1748
|
+
'(blur)': 'onBlur()',
|
|
1749
|
+
'(click)': 'onClick($event)',
|
|
1750
|
+
'(keydown)': 'onKeyDown($event)'
|
|
1751
|
+
}, inputs: ['disabled'], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".kbq-option-action{box-sizing:border-box;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:24px;height:24px;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.kbq-option-action.kbq-disabled{cursor:default}\n"] }]
|
|
1752
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1$1.FocusMonitor }, { type: undefined, decorators: [{
|
|
1753
|
+
type: Inject,
|
|
1754
|
+
args: [KBQ_OPTION_ACTION_PARENT]
|
|
1755
|
+
}] }], propDecorators: { customIcon: [{
|
|
1756
|
+
type: ContentChild,
|
|
1757
|
+
args: ['customIcon']
|
|
1758
|
+
}] } });
|
|
1635
1759
|
|
|
1636
1760
|
/** @docs-private */
|
|
1637
1761
|
class KbqOptgroupBase {
|
|
@@ -1649,18 +1773,20 @@ class KbqOptgroup extends KbqOptgroupMixinBase {
|
|
|
1649
1773
|
this.labelId = `kbq-optgroup-label-${uniqueOptgroupIdCounter++}`;
|
|
1650
1774
|
}
|
|
1651
1775
|
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptgroup, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
1652
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOptgroup, selector: "kbq-optgroup", inputs: { disabled: "disabled", label: "label" }, host: { properties: { "class.kbq-disabled": "disabled" }, classAttribute: "kbq-optgroup" }, exportAs: ["kbqOptgroup"], usesInheritance: true, ngImport: i0, template: "<label
|
|
1776
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOptgroup, selector: "kbq-optgroup", inputs: { disabled: "disabled", label: "label" }, host: { properties: { "class.kbq-disabled": "disabled" }, classAttribute: "kbq-optgroup" }, exportAs: ["kbqOptgroup"], usesInheritance: true, ngImport: i0, template: "<label\n class=\"kbq-optgroup-label\"\n [id]=\"labelId\"\n>\n {{ label }}\n</label>\n<ng-content select=\"kbq-option, kbq-list-option, kbq-timezone-option, ng-container\"></ng-content>\n", styles: [".kbq-optgroup-label{padding-left:var(--kbq-size-m, 12px);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1653
1777
|
}
|
|
1654
1778
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptgroup, decorators: [{
|
|
1655
1779
|
type: Component,
|
|
1656
1780
|
args: [{ selector: 'kbq-optgroup', exportAs: 'kbqOptgroup', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, inputs: ['disabled'], host: {
|
|
1657
1781
|
class: 'kbq-optgroup',
|
|
1658
1782
|
'[class.kbq-disabled]': 'disabled'
|
|
1659
|
-
}, template: "<label
|
|
1783
|
+
}, template: "<label\n class=\"kbq-optgroup-label\"\n [id]=\"labelId\"\n>\n {{ label }}\n</label>\n<ng-content select=\"kbq-option, kbq-list-option, kbq-timezone-option, ng-container\"></ng-content>\n", styles: [".kbq-optgroup-label{padding-left:var(--kbq-size-m, 12px);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}\n"] }]
|
|
1660
1784
|
}], propDecorators: { label: [{
|
|
1661
1785
|
type: Input
|
|
1662
1786
|
}] } });
|
|
1663
1787
|
|
|
1788
|
+
const KBQ_TITLE_TEXT_REF = new InjectionToken('KbqTitleTextRef');
|
|
1789
|
+
|
|
1664
1790
|
// Boilerplate for applying mixins to KbqPseudoCheckbox.
|
|
1665
1791
|
/** @docs-private */
|
|
1666
1792
|
class KbqPseudoCheckboxBase {
|
|
@@ -1921,9 +2047,12 @@ class KbqOption extends KbqOptionBase {
|
|
|
1921
2047
|
return this.element.nativeElement;
|
|
1922
2048
|
}
|
|
1923
2049
|
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOption, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: KBQ_OPTION_PARENT_COMPONENT, optional: true }, { token: KbqOptgroup, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1924
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOption, selector: "kbq-option", inputs: { value: "value", showCheckbox: "showCheckbox", disabled: "disabled" }, outputs: { onSelectionChange: "onSelectionChange" }, host: { listeners: { "click": "selectViaInteraction()", "keydown": "handleKeydown($event)" }, properties: { "attr.tabindex": "getTabIndex()", "class.kbq-selected": "selected", "class.kbq-option-multiple": "multiple", "class.kbq-active": "active", "class.kbq-disabled": "disabled", "id": "id" }, classAttribute: "kbq-option" }, providers: [
|
|
1925
|
-
|
|
1926
|
-
|
|
2050
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOption, selector: "kbq-option", inputs: { value: "value", showCheckbox: "showCheckbox", disabled: "disabled" }, outputs: { onSelectionChange: "onSelectionChange" }, host: { listeners: { "click": "selectViaInteraction()", "keydown": "handleKeydown($event)" }, properties: { "attr.tabindex": "getTabIndex()", "class.kbq-selected": "selected", "class.kbq-option-multiple": "multiple", "class.kbq-active": "active", "class.kbq-disabled": "disabled", "id": "id" }, classAttribute: "kbq-option" }, providers: [
|
|
2051
|
+
{
|
|
2052
|
+
provide: KBQ_TITLE_TEXT_REF,
|
|
2053
|
+
useExisting: KbqOption
|
|
2054
|
+
}
|
|
2055
|
+
], viewQueries: [{ propertyName: "textElement", first: true, predicate: ["kbqTitleText"], descendants: true }], exportAs: ["kbqOption"], usesInheritance: true, ngImport: i0, template: "<kbq-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [disabled]=\"disabled\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n></kbq-pseudo-checkbox>\n\n<span\n #kbqTitleText\n class=\"kbq-option-text\"\n>\n <ng-content></ng-content>\n</span>\n", styles: ["@keyframes kbq-progress{0%{background-position:0 0}to{background-position:64px 0}}.kbq-progress{position:relative}.kbq-progress:after{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite}.kbq-group{display:flex;flex-direction:row}.kbq-group .kbq-group_justified>.kbq-group-item{width:100%}.kbq-group .kbq-group-item+.kbq-group-item{margin-left:calc(-1 * var(--kbq-button-size-border-width, 2px))}.kbq-group>.kbq-group-item:first-child:not(:last-child){border-bottom-right-radius:0;border-top-right-radius:0}.kbq-group>.kbq-group-item:first-child:not(:last-child)>.kbq-form-field__container{border-bottom-right-radius:0;border-top-right-radius:0}.kbq-group>.kbq-group-item:last-child:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.kbq-group>.kbq-group-item:last-child:not(:first-child)>.kbq-form-field__container{border-bottom-left-radius:0;border-top-left-radius:0}.kbq-group>.kbq-group-item:not(:first-child):not(:last-child){border-radius:0}.kbq-group>.kbq-group-item:not(:first-child):not(:last-child)>.kbq-form-field__container{border-radius:0}.kbq-vertical-group{display:flex;flex-direction:column}.kbq-vertical-group>.kbq-group-item:first-child:not(:last-child){border-bottom-right-radius:0;border-bottom-left-radius:0;border-top-right-radius:var(--kbq-button-size-border-radius, 8px)}.kbq-vertical-group>.kbq-group-item:first-child:not(:last-child)>.kbq-form-field__container{border-bottom-right-radius:0;border-bottom-left-radius:0}.kbq-vertical-group>.kbq-group-item:last-child:not(:first-child){border-top-right-radius:0;border-top-left-radius:0;border-bottom-left-radius:var(--kbq-button-size-border-radius, 8px)}.kbq-vertical-group>.kbq-group-item:last-child:not(:first-child)>.kbq-form-field__container{border-top-right-radius:0;border-top-left-radius:0}.kbq-vertical-group>.kbq-group-item:not(:first-child):not(:last-child){border-radius:0}.kbq-vertical-group>.kbq-group-item:not(:first-child):not(:last-child)>.kbq-form-field__container{border-radius:0}.kbq-vertical-group .kbq-group-item+.kbq-group-item{margin-top:calc(-1 * var(--kbq-button-size-border-width, 2px))}.kbq-no-select{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.kbq-option{position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s, 8px);border:var(--kbq-size-3xs, 2px) solid transparent;padding-top:var(--kbq-size-xxs, 4px);padding-left:var(--kbq-size-m, 12px);padding-right:var(--kbq-size-m, 12px);padding-bottom:var(--kbq-size-xxs, 4px)}.kbq-option .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-option .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-option .kbq-list-text:empty{display:none}.kbq-option .kbq-list-option-caption{padding-top:var(--kbq-size-3xs, 2px)}.kbq-option:not(.kbq-disabled){cursor:pointer}.kbq-option-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-option-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-option-text:empty{display:none}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: KbqPseudoCheckbox, selector: "kbq-pseudo-checkbox", inputs: ["color", "big", "state", "disabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
1927
2056
|
}
|
|
1928
2057
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOption, decorators: [{
|
|
1929
2058
|
type: Component,
|
|
@@ -1937,9 +2066,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1937
2066
|
'[id]': 'id',
|
|
1938
2067
|
'(click)': 'selectViaInteraction()',
|
|
1939
2068
|
'(keydown)': 'handleKeydown($event)'
|
|
1940
|
-
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
1941
|
-
|
|
1942
|
-
|
|
2069
|
+
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
2070
|
+
{
|
|
2071
|
+
provide: KBQ_TITLE_TEXT_REF,
|
|
2072
|
+
useExisting: KbqOption
|
|
2073
|
+
}
|
|
2074
|
+
], template: "<kbq-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [disabled]=\"disabled\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n></kbq-pseudo-checkbox>\n\n<span\n #kbqTitleText\n class=\"kbq-option-text\"\n>\n <ng-content></ng-content>\n</span>\n", styles: ["@keyframes kbq-progress{0%{background-position:0 0}to{background-position:64px 0}}.kbq-progress{position:relative}.kbq-progress:after{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite}.kbq-group{display:flex;flex-direction:row}.kbq-group .kbq-group_justified>.kbq-group-item{width:100%}.kbq-group .kbq-group-item+.kbq-group-item{margin-left:calc(-1 * var(--kbq-button-size-border-width, 2px))}.kbq-group>.kbq-group-item:first-child:not(:last-child){border-bottom-right-radius:0;border-top-right-radius:0}.kbq-group>.kbq-group-item:first-child:not(:last-child)>.kbq-form-field__container{border-bottom-right-radius:0;border-top-right-radius:0}.kbq-group>.kbq-group-item:last-child:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0}.kbq-group>.kbq-group-item:last-child:not(:first-child)>.kbq-form-field__container{border-bottom-left-radius:0;border-top-left-radius:0}.kbq-group>.kbq-group-item:not(:first-child):not(:last-child){border-radius:0}.kbq-group>.kbq-group-item:not(:first-child):not(:last-child)>.kbq-form-field__container{border-radius:0}.kbq-vertical-group{display:flex;flex-direction:column}.kbq-vertical-group>.kbq-group-item:first-child:not(:last-child){border-bottom-right-radius:0;border-bottom-left-radius:0;border-top-right-radius:var(--kbq-button-size-border-radius, 8px)}.kbq-vertical-group>.kbq-group-item:first-child:not(:last-child)>.kbq-form-field__container{border-bottom-right-radius:0;border-bottom-left-radius:0}.kbq-vertical-group>.kbq-group-item:last-child:not(:first-child){border-top-right-radius:0;border-top-left-radius:0;border-bottom-left-radius:var(--kbq-button-size-border-radius, 8px)}.kbq-vertical-group>.kbq-group-item:last-child:not(:first-child)>.kbq-form-field__container{border-top-right-radius:0;border-top-left-radius:0}.kbq-vertical-group>.kbq-group-item:not(:first-child):not(:last-child){border-radius:0}.kbq-vertical-group>.kbq-group-item:not(:first-child):not(:last-child)>.kbq-form-field__container{border-radius:0}.kbq-vertical-group .kbq-group-item+.kbq-group-item{margin-top:calc(-1 * var(--kbq-button-size-border-width, 2px))}.kbq-no-select{-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.kbq-option{position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s, 8px);border:var(--kbq-size-3xs, 2px) solid transparent;padding-top:var(--kbq-size-xxs, 4px);padding-left:var(--kbq-size-m, 12px);padding-right:var(--kbq-size-m, 12px);padding-bottom:var(--kbq-size-xxs, 4px)}.kbq-option .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-option .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-option .kbq-list-text:empty{display:none}.kbq-option .kbq-list-option-caption{padding-top:var(--kbq-size-3xs, 2px)}.kbq-option:not(.kbq-disabled){cursor:pointer}.kbq-option-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-option-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-option-text:empty{display:none}\n"] }]
|
|
1943
2075
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
1944
2076
|
type: Optional
|
|
1945
2077
|
}, {
|
|
@@ -1999,120 +2131,6 @@ function getOptionScrollPosition(optionIndex, optionHeight, currentScrollPositio
|
|
|
1999
2131
|
return currentScrollPosition;
|
|
2000
2132
|
}
|
|
2001
2133
|
|
|
2002
|
-
const KBQ_OPTION_ACTION_PARENT = new InjectionToken('KBQ_OPTION_ACTION_PARENT');
|
|
2003
|
-
/** @docs-private */
|
|
2004
|
-
class KbqOptionActionBase {
|
|
2005
|
-
}
|
|
2006
|
-
/** @docs-private */
|
|
2007
|
-
const KbqOptionActionMixinBase = mixinTabIndex(mixinDisabled(KbqOptionActionBase));
|
|
2008
|
-
class KbqOptionActionComponent extends KbqOptionActionMixinBase {
|
|
2009
|
-
get active() {
|
|
2010
|
-
return this.hasFocus || !!this.option.dropdownTrigger?.opened;
|
|
2011
|
-
}
|
|
2012
|
-
constructor(elementRef, focusMonitor, option) {
|
|
2013
|
-
super();
|
|
2014
|
-
this.elementRef = elementRef;
|
|
2015
|
-
this.focusMonitor = focusMonitor;
|
|
2016
|
-
this.option = option;
|
|
2017
|
-
this.hasFocus = false;
|
|
2018
|
-
this.destroy = new Subject();
|
|
2019
|
-
this.focusMonitor.monitor(this.elementRef.nativeElement);
|
|
2020
|
-
}
|
|
2021
|
-
ngAfterViewInit() {
|
|
2022
|
-
if (!this.option.dropdownTrigger) {
|
|
2023
|
-
return;
|
|
2024
|
-
}
|
|
2025
|
-
this.option.dropdownTrigger.restoreFocus = false;
|
|
2026
|
-
this.option.dropdownTrigger.dropdownClosed
|
|
2027
|
-
.pipe(takeUntil(this.destroy))
|
|
2028
|
-
.subscribe(() => {
|
|
2029
|
-
this.preventShowingTooltip();
|
|
2030
|
-
const destroyReason = this.option.dropdownTrigger.lastDestroyReason === 'keydown' ?
|
|
2031
|
-
'keyboard' :
|
|
2032
|
-
'program';
|
|
2033
|
-
this.focus(destroyReason);
|
|
2034
|
-
});
|
|
2035
|
-
}
|
|
2036
|
-
ngOnDestroy() {
|
|
2037
|
-
this.destroy.next();
|
|
2038
|
-
this.destroy.complete();
|
|
2039
|
-
this.focusMonitor.stopMonitoring(this.elementRef.nativeElement);
|
|
2040
|
-
}
|
|
2041
|
-
focus(origin, options) {
|
|
2042
|
-
if (this.focusMonitor && origin) {
|
|
2043
|
-
this.focusMonitor.focusVia(this.elementRef.nativeElement, origin, options);
|
|
2044
|
-
}
|
|
2045
|
-
else {
|
|
2046
|
-
this.elementRef.nativeElement.focus();
|
|
2047
|
-
}
|
|
2048
|
-
this.hasFocus = true;
|
|
2049
|
-
}
|
|
2050
|
-
onFocus($event) {
|
|
2051
|
-
$event.stopPropagation();
|
|
2052
|
-
this.hasFocus = true;
|
|
2053
|
-
}
|
|
2054
|
-
onBlur() {
|
|
2055
|
-
this.hasFocus = false;
|
|
2056
|
-
}
|
|
2057
|
-
onClick($event) {
|
|
2058
|
-
$event.stopPropagation();
|
|
2059
|
-
}
|
|
2060
|
-
onKeyDown($event) {
|
|
2061
|
-
if ([SPACE, ENTER].includes($event.keyCode) && this.option.dropdownTrigger) {
|
|
2062
|
-
this.option.dropdownTrigger.openedBy = 'keyboard';
|
|
2063
|
-
this.option.dropdownTrigger.toggle();
|
|
2064
|
-
}
|
|
2065
|
-
else if ($event.shiftKey && $event.keyCode === TAB) {
|
|
2066
|
-
this.hasFocus = false;
|
|
2067
|
-
this.option.focus();
|
|
2068
|
-
}
|
|
2069
|
-
else if ($event.keyCode === TAB) {
|
|
2070
|
-
return;
|
|
2071
|
-
}
|
|
2072
|
-
$event.preventDefault();
|
|
2073
|
-
$event.stopPropagation();
|
|
2074
|
-
}
|
|
2075
|
-
preventShowingTooltip() {
|
|
2076
|
-
if (!this.option.tooltipTrigger) {
|
|
2077
|
-
return;
|
|
2078
|
-
}
|
|
2079
|
-
this.option.tooltipTrigger.disabled = true;
|
|
2080
|
-
setTimeout(() => this.option.tooltipTrigger.disabled = false);
|
|
2081
|
-
}
|
|
2082
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptionActionComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.FocusMonitor }, { token: KBQ_OPTION_ACTION_PARENT }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2083
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.2.0", type: KbqOptionActionComponent, selector: "kbq-option-action", inputs: { disabled: "disabled" }, host: { listeners: { "focus": "onFocus($event)", "blur": "onBlur()", "click": "onClick($event)", "keydown": "onKeyDown($event)" }, properties: { "class.kbq-expanded": "false", "class.kbq-disabled": "disabled", "attr.disabled": "disabled || null", "attr.tabIndex": "-1" }, classAttribute: "kbq-option-action" }, queries: [{ propertyName: "customIcon", first: true, predicate: ["customIcon"], descendants: true }], exportAs: ["kbqOptionAction"], usesInheritance: true, ngImport: i0, template: `
|
|
2084
|
-
<ng-container [ngSwitch]="!!customIcon">
|
|
2085
|
-
<i class="mc kbq-icon mc-ellipsis_16" *ngSwitchCase="false"></i>
|
|
2086
|
-
<ng-content select="[kbq-icon]" *ngSwitchCase="true"></ng-content>
|
|
2087
|
-
</ng-container>
|
|
2088
|
-
`, isInline: true, styles: [".kbq-option-action{box-sizing:border-box;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:24px;height:24px;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.kbq-option-action.kbq-disabled{cursor:default}\n"], dependencies: [{ kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
2089
|
-
}
|
|
2090
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptionActionComponent, decorators: [{
|
|
2091
|
-
type: Component,
|
|
2092
|
-
args: [{ selector: 'kbq-option-action', exportAs: 'kbqOptionAction', template: `
|
|
2093
|
-
<ng-container [ngSwitch]="!!customIcon">
|
|
2094
|
-
<i class="mc kbq-icon mc-ellipsis_16" *ngSwitchCase="false"></i>
|
|
2095
|
-
<ng-content select="[kbq-icon]" *ngSwitchCase="true"></ng-content>
|
|
2096
|
-
</ng-container>
|
|
2097
|
-
`, host: {
|
|
2098
|
-
class: 'kbq-option-action',
|
|
2099
|
-
'[class.kbq-expanded]': 'false',
|
|
2100
|
-
'[class.kbq-disabled]': 'disabled',
|
|
2101
|
-
'[attr.disabled]': 'disabled || null',
|
|
2102
|
-
'[attr.tabIndex]': '-1',
|
|
2103
|
-
'(focus)': 'onFocus($event)',
|
|
2104
|
-
'(blur)': 'onBlur()',
|
|
2105
|
-
'(click)': 'onClick($event)',
|
|
2106
|
-
'(keydown)': 'onKeyDown($event)'
|
|
2107
|
-
}, inputs: ['disabled'], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".kbq-option-action{box-sizing:border-box;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:24px;height:24px;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.kbq-option-action.kbq-disabled{cursor:default}\n"] }]
|
|
2108
|
-
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1$1.FocusMonitor }, { type: undefined, decorators: [{
|
|
2109
|
-
type: Inject,
|
|
2110
|
-
args: [KBQ_OPTION_ACTION_PARENT]
|
|
2111
|
-
}] }], propDecorators: { customIcon: [{
|
|
2112
|
-
type: ContentChild,
|
|
2113
|
-
args: ['customIcon']
|
|
2114
|
-
}] } });
|
|
2115
|
-
|
|
2116
2134
|
var MultipleMode;
|
|
2117
2135
|
(function (MultipleMode) {
|
|
2118
2136
|
MultipleMode["CHECKBOX"] = "checkbox";
|
|
@@ -2562,8 +2580,10 @@ class KbqPopUpTrigger {
|
|
|
2562
2580
|
let newPlacement = this.placement;
|
|
2563
2581
|
const { originX, originY, overlayX, overlayY } = $event.connectionPair;
|
|
2564
2582
|
Object.keys(this.availablePositions).some((key) => {
|
|
2565
|
-
if (originX === this.availablePositions[key].originX &&
|
|
2566
|
-
|
|
2583
|
+
if (originX === this.availablePositions[key].originX &&
|
|
2584
|
+
originY === this.availablePositions[key].originY &&
|
|
2585
|
+
overlayX === this.availablePositions[key].overlayX &&
|
|
2586
|
+
overlayY === this.availablePositions[key].overlayY) {
|
|
2567
2587
|
newPlacement = key;
|
|
2568
2588
|
return true;
|
|
2569
2589
|
}
|
|
@@ -2625,7 +2645,8 @@ class KbqPopUpTrigger {
|
|
|
2625
2645
|
}
|
|
2626
2646
|
}
|
|
2627
2647
|
handleKeydown(event) {
|
|
2628
|
-
if (this.isOpen && event.keyCode === ESCAPE) {
|
|
2648
|
+
if (this.isOpen && event.keyCode === ESCAPE) {
|
|
2649
|
+
// tslint:disable-line
|
|
2629
2650
|
this.hide();
|
|
2630
2651
|
}
|
|
2631
2652
|
}
|
|
@@ -2641,14 +2662,10 @@ class KbqPopUpTrigger {
|
|
|
2641
2662
|
this.detach();
|
|
2642
2663
|
this.portal = this.portal || new ComponentPortal(this.getOverlayHandleComponentType(), this.hostView);
|
|
2643
2664
|
this.instance = this.overlayRef.attach(this.portal).instance;
|
|
2644
|
-
this.instance.afterHidden()
|
|
2645
|
-
.pipe(takeUntil(this.destroyed))
|
|
2646
|
-
.subscribe(this.detach);
|
|
2665
|
+
this.instance.afterHidden().pipe(takeUntil(this.destroyed)).subscribe(this.detach);
|
|
2647
2666
|
this.updateClassMap();
|
|
2648
2667
|
this.updateData();
|
|
2649
|
-
this.instance.visibleChange
|
|
2650
|
-
.pipe(takeUntil(this.destroyed), distinctUntilChanged())
|
|
2651
|
-
.subscribe((value) => {
|
|
2668
|
+
this.instance.visibleChange.pipe(takeUntil(this.destroyed), distinctUntilChanged()).subscribe((value) => {
|
|
2652
2669
|
this.visible = value;
|
|
2653
2670
|
this.visibleChange.emit(value);
|
|
2654
2671
|
this.isOpen = value;
|
|
@@ -2675,9 +2692,7 @@ class KbqPopUpTrigger {
|
|
|
2675
2692
|
.withPositions([...EXTENDED_OVERLAY_POSITIONS])
|
|
2676
2693
|
.withLockedPosition()
|
|
2677
2694
|
.withScrollableContainers(this.scrollDispatcher.getAncestorScrollContainers(this.elementRef));
|
|
2678
|
-
strategy.positionChanges
|
|
2679
|
-
.pipe(takeUntil(this.destroyed))
|
|
2680
|
-
.subscribe(this.onPositionChange);
|
|
2695
|
+
strategy.positionChanges.pipe(takeUntil(this.destroyed)).subscribe(this.onPositionChange);
|
|
2681
2696
|
this.overlayRef = this.overlay.create({
|
|
2682
2697
|
...this.overlayConfig,
|
|
2683
2698
|
direction: this.direction,
|
|
@@ -2685,16 +2700,13 @@ class KbqPopUpTrigger {
|
|
|
2685
2700
|
scrollStrategy: this.scrollStrategy()
|
|
2686
2701
|
});
|
|
2687
2702
|
this.subscribeOnClosingActions();
|
|
2688
|
-
this.overlayRef.detachments()
|
|
2689
|
-
.pipe(takeUntil(this.destroyed))
|
|
2690
|
-
.subscribe(this.detach);
|
|
2703
|
+
this.overlayRef.detachments().pipe(takeUntil(this.destroyed)).subscribe(this.detach);
|
|
2691
2704
|
return this.overlayRef;
|
|
2692
2705
|
}
|
|
2693
2706
|
initListeners() {
|
|
2694
2707
|
this.clearListeners();
|
|
2695
2708
|
if (this.trigger.includes(PopUpTriggers.Click)) {
|
|
2696
|
-
this.listeners
|
|
2697
|
-
.set(...this.createListener('click', this.show));
|
|
2709
|
+
this.listeners.set(...this.createListener('click', this.show));
|
|
2698
2710
|
}
|
|
2699
2711
|
if (this.trigger.includes(PopUpTriggers.Hover)) {
|
|
2700
2712
|
this.listeners
|
|
@@ -2707,15 +2719,13 @@ class KbqPopUpTrigger {
|
|
|
2707
2719
|
.set(...this.createListener('blur', this.hide));
|
|
2708
2720
|
}
|
|
2709
2721
|
if (this.trigger.includes(PopUpTriggers.Keydown)) {
|
|
2710
|
-
this.listeners
|
|
2711
|
-
.set('keydown', (event) => {
|
|
2722
|
+
this.listeners.set('keydown', (event) => {
|
|
2712
2723
|
if (event instanceof KeyboardEvent && [ENTER, SPACE].includes(event.keyCode)) {
|
|
2713
2724
|
this.show();
|
|
2714
2725
|
}
|
|
2715
2726
|
});
|
|
2716
2727
|
}
|
|
2717
|
-
this.listeners
|
|
2718
|
-
.forEach(this.addEventListener);
|
|
2728
|
+
this.listeners.forEach(this.addEventListener);
|
|
2719
2729
|
}
|
|
2720
2730
|
/** Updates the position of the current popover. */
|
|
2721
2731
|
updatePosition(reapplyPosition = false) {
|
|
@@ -2781,59 +2791,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
2781
2791
|
type: Directive
|
|
2782
2792
|
}], ctorParameters: () => [{ type: i1$2.Overlay }, { type: i0.ElementRef }, { type: i0.NgZone }, { type: i1$2.ScrollDispatcher }, { type: i0.ViewContainerRef }, { type: undefined }, { type: i2$1.Directionality }] });
|
|
2783
2793
|
|
|
2784
|
-
const selectEvents = 'selectEvents';
|
|
2785
|
-
|
|
2786
|
-
/**
|
|
2787
|
-
* Returns an exception to be thrown when attempting to change a select's `multiple` option
|
|
2788
|
-
* after initialization.
|
|
2789
|
-
* @docs-private
|
|
2790
|
-
*/
|
|
2791
|
-
function getKbqSelectDynamicMultipleError() {
|
|
2792
|
-
return Error('Cannot change `multiple` mode of select after initialization.');
|
|
2793
|
-
}
|
|
2794
|
-
/**
|
|
2795
|
-
* Returns an exception to be thrown when attempting to assign a non-array value to a select
|
|
2796
|
-
* in `multiple` mode. Note that `undefined` and `null` are still valid values to allow for
|
|
2797
|
-
* resetting the value.
|
|
2798
|
-
* @docs-private
|
|
2799
|
-
*/
|
|
2800
|
-
function getKbqSelectNonArrayValueError() {
|
|
2801
|
-
return Error('Value must be an array in multiple-selection mode.');
|
|
2802
|
-
}
|
|
2803
|
-
/**
|
|
2804
|
-
* Returns an exception to be thrown when assigning a non-function value to the comparator
|
|
2805
|
-
* used to determine if a value corresponds to an option. Note that whether the function
|
|
2806
|
-
* actually takes two values and returns a boolean is not checked.
|
|
2807
|
-
*/
|
|
2808
|
-
function getKbqSelectNonFunctionValueError() {
|
|
2809
|
-
return Error('`compareWith` must be a function.');
|
|
2810
|
-
}
|
|
2811
|
-
|
|
2812
|
-
/** The max height of the select's overlay panel */
|
|
2813
|
-
const SELECT_PANEL_MAX_HEIGHT = 224;
|
|
2814
|
-
/** The panel's padding on the x-axis */
|
|
2815
|
-
const SELECT_PANEL_PADDING_X = 1;
|
|
2816
|
-
/** The panel's x axis padding if it is indented (e.g. there is an option group). */
|
|
2817
|
-
/* tslint:disable-next-line:no-magic-numbers */
|
|
2818
|
-
const SELECT_PANEL_INDENT_PADDING_X = SELECT_PANEL_PADDING_X * 2;
|
|
2819
|
-
/**
|
|
2820
|
-
* The select panel will only "fit" inside the viewport if it is positioned at
|
|
2821
|
-
* this value or more away from the viewport boundary.
|
|
2822
|
-
*/
|
|
2823
|
-
const SELECT_PANEL_VIEWPORT_PADDING = 8;
|
|
2824
|
-
/** Injection token that determines the scroll handling while a select is open. */
|
|
2825
|
-
const KBQ_SELECT_SCROLL_STRATEGY = new InjectionToken('kbq-select-scroll-strategy');
|
|
2826
|
-
/** @docs-private */
|
|
2827
|
-
function kbqSelectScrollStrategyProviderFactory(overlay) {
|
|
2828
|
-
return () => overlay.scrollStrategies.reposition();
|
|
2829
|
-
}
|
|
2830
|
-
/** @docs-private */
|
|
2831
|
-
const KBQ_SELECT_SCROLL_STRATEGY_PROVIDER = {
|
|
2832
|
-
provide: KBQ_SELECT_SCROLL_STRATEGY,
|
|
2833
|
-
deps: [Overlay],
|
|
2834
|
-
useFactory: kbqSelectScrollStrategyProviderFactory
|
|
2835
|
-
};
|
|
2836
|
-
|
|
2837
2794
|
/* tslint:disable:no-empty */
|
|
2838
2795
|
class KbqSelectTrigger {
|
|
2839
2796
|
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqSelectTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
@@ -2949,6 +2906,59 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
2949
2906
|
}]
|
|
2950
2907
|
}] });
|
|
2951
2908
|
|
|
2909
|
+
/** The max height of the select's overlay panel */
|
|
2910
|
+
const SELECT_PANEL_MAX_HEIGHT = 224;
|
|
2911
|
+
/** The panel's padding on the x-axis */
|
|
2912
|
+
const SELECT_PANEL_PADDING_X = 1;
|
|
2913
|
+
/** The panel's x axis padding if it is indented (e.g. there is an option group). */
|
|
2914
|
+
/* tslint:disable-next-line:no-magic-numbers */
|
|
2915
|
+
const SELECT_PANEL_INDENT_PADDING_X = SELECT_PANEL_PADDING_X * 2;
|
|
2916
|
+
/**
|
|
2917
|
+
* The select panel will only "fit" inside the viewport if it is positioned at
|
|
2918
|
+
* this value or more away from the viewport boundary.
|
|
2919
|
+
*/
|
|
2920
|
+
const SELECT_PANEL_VIEWPORT_PADDING = 8;
|
|
2921
|
+
/** Injection token that determines the scroll handling while a select is open. */
|
|
2922
|
+
const KBQ_SELECT_SCROLL_STRATEGY = new InjectionToken('kbq-select-scroll-strategy');
|
|
2923
|
+
/** @docs-private */
|
|
2924
|
+
function kbqSelectScrollStrategyProviderFactory(overlay) {
|
|
2925
|
+
return () => overlay.scrollStrategies.reposition();
|
|
2926
|
+
}
|
|
2927
|
+
/** @docs-private */
|
|
2928
|
+
const KBQ_SELECT_SCROLL_STRATEGY_PROVIDER = {
|
|
2929
|
+
provide: KBQ_SELECT_SCROLL_STRATEGY,
|
|
2930
|
+
deps: [Overlay],
|
|
2931
|
+
useFactory: kbqSelectScrollStrategyProviderFactory
|
|
2932
|
+
};
|
|
2933
|
+
|
|
2934
|
+
/**
|
|
2935
|
+
* Returns an exception to be thrown when attempting to change a select's `multiple` option
|
|
2936
|
+
* after initialization.
|
|
2937
|
+
* @docs-private
|
|
2938
|
+
*/
|
|
2939
|
+
function getKbqSelectDynamicMultipleError() {
|
|
2940
|
+
return Error('Cannot change `multiple` mode of select after initialization.');
|
|
2941
|
+
}
|
|
2942
|
+
/**
|
|
2943
|
+
* Returns an exception to be thrown when attempting to assign a non-array value to a select
|
|
2944
|
+
* in `multiple` mode. Note that `undefined` and `null` are still valid values to allow for
|
|
2945
|
+
* resetting the value.
|
|
2946
|
+
* @docs-private
|
|
2947
|
+
*/
|
|
2948
|
+
function getKbqSelectNonArrayValueError() {
|
|
2949
|
+
return Error('Value must be an array in multiple-selection mode.');
|
|
2950
|
+
}
|
|
2951
|
+
/**
|
|
2952
|
+
* Returns an exception to be thrown when assigning a non-function value to the comparator
|
|
2953
|
+
* used to determine if a value corresponds to an option. Note that whether the function
|
|
2954
|
+
* actually takes two values and returns a boolean is not checked.
|
|
2955
|
+
*/
|
|
2956
|
+
function getKbqSelectNonFunctionValueError() {
|
|
2957
|
+
return Error('`compareWith` must be a function.');
|
|
2958
|
+
}
|
|
2959
|
+
|
|
2960
|
+
const selectEvents = 'selectEvents';
|
|
2961
|
+
|
|
2952
2962
|
class KbqMeasureScrollbarService {
|
|
2953
2963
|
get scrollBarWidth() {
|
|
2954
2964
|
if (this._scrollBarWidth) {
|
|
@@ -3022,9 +3032,7 @@ class ThemeService {
|
|
|
3022
3032
|
}
|
|
3023
3033
|
};
|
|
3024
3034
|
this.renderer = this.rendererFactory.createRenderer(null, null);
|
|
3025
|
-
this.subscription = this.current
|
|
3026
|
-
.pipe(pairwise())
|
|
3027
|
-
.subscribe(this.update);
|
|
3035
|
+
this.subscription = this.current.pipe(pairwise()).subscribe(this.update);
|
|
3028
3036
|
}
|
|
3029
3037
|
ngOnDestroy() {
|
|
3030
3038
|
this.subscription.unsubscribe();
|
|
@@ -3054,11 +3062,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
3054
3062
|
args: [{ providedIn: 'root' }]
|
|
3055
3063
|
}], ctorParameters: () => [{ type: i0.RendererFactory2 }] });
|
|
3056
3064
|
|
|
3057
|
-
function isBoolean(val) { return typeof val === 'boolean'; }
|
|
3058
|
-
function toBoolean(value) {
|
|
3059
|
-
return value != null && `${value}` !== 'false';
|
|
3060
|
-
}
|
|
3061
|
-
|
|
3062
3065
|
var MeasurementSystem;
|
|
3063
3066
|
(function (MeasurementSystem) {
|
|
3064
3067
|
MeasurementSystem["SI"] = "SI";
|
|
@@ -3074,9 +3077,7 @@ const formatDataSize = (value, precision, system) => {
|
|
|
3074
3077
|
volume = result.toString();
|
|
3075
3078
|
}
|
|
3076
3079
|
else {
|
|
3077
|
-
volume = result
|
|
3078
|
-
.toFixed(precision)
|
|
3079
|
-
.replace(/\./g, ',');
|
|
3080
|
+
volume = result.toFixed(precision).replace(/\./g, ',');
|
|
3080
3081
|
}
|
|
3081
3082
|
return {
|
|
3082
3083
|
value: volume,
|
|
@@ -3094,8 +3095,7 @@ const getHumanizedBytes = (value, system, threshold) => {
|
|
|
3094
3095
|
if (!Number.isFinite(value)) {
|
|
3095
3096
|
throw new Error('Argument "value" must be number!');
|
|
3096
3097
|
}
|
|
3097
|
-
const calculatedThreshold = Number.isFinite(threshold)
|
|
3098
|
-
? threshold : Math.pow(system.base, system.power);
|
|
3098
|
+
const calculatedThreshold = Number.isFinite(threshold) ? threshold : Math.pow(system.base, system.power);
|
|
3099
3099
|
const orderOfMagnitude = Math.pow(system.base, system.power);
|
|
3100
3100
|
let result = value;
|
|
3101
3101
|
let step = 0;
|
|
@@ -3120,8 +3120,7 @@ class KbqDataSizePipe {
|
|
|
3120
3120
|
this.updateLocaleParams = () => {
|
|
3121
3121
|
this.config = this.externalConfig || this.localeService?.getParams('sizeUnits');
|
|
3122
3122
|
};
|
|
3123
|
-
this.localeService?.changes
|
|
3124
|
-
.subscribe(this.updateLocaleParams);
|
|
3123
|
+
this.localeService?.changes.subscribe(this.updateLocaleParams);
|
|
3125
3124
|
if (!localeService) {
|
|
3126
3125
|
this.config = KBQ_SIZE_UNITS_DEFAULT_CONFIG;
|
|
3127
3126
|
}
|
|
@@ -3153,11 +3152,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
3153
3152
|
args: [KBQ_LOCALE_SERVICE]
|
|
3154
3153
|
}] }] });
|
|
3155
3154
|
|
|
3155
|
+
function isBoolean(val) {
|
|
3156
|
+
return typeof val === 'boolean';
|
|
3157
|
+
}
|
|
3158
|
+
function toBoolean(value) {
|
|
3159
|
+
return value != null && `${value}` !== 'false';
|
|
3160
|
+
}
|
|
3161
|
+
|
|
3156
3162
|
const validationTooltipShowDelay = 10;
|
|
3157
3163
|
const validationTooltipHideDelay = 3000;
|
|
3158
|
-
const KBQ_VALIDATION = new InjectionToken('KbqUseValidation', {
|
|
3164
|
+
const KBQ_VALIDATION = new InjectionToken('KbqUseValidation', {
|
|
3165
|
+
factory: () => ({ useValidation: true })
|
|
3166
|
+
});
|
|
3159
3167
|
|
|
3160
|
-
const VERSION = new Version('17.0.0-rc.
|
|
3168
|
+
const VERSION = new Version('17.0.0-rc.12+sha-3d08353');
|
|
3161
3169
|
|
|
3162
3170
|
/**
|
|
3163
3171
|
* Generated bundle index. Do not edit.
|