@koobiq/components 17.0.0-rc.9 → 17.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -2
- package/alert/_alert-theme.scss +0 -1
- package/alert/alert.component.d.ts +3 -1
- package/alert/alert.component.scss +14 -14
- package/alert/public-api.d.ts +1 -1
- package/autocomplete/_autocomplete-theme.scss +0 -1
- package/autocomplete/autocomplete.scss +3 -6
- package/autocomplete/public-api.d.ts +2 -2
- package/badge/_badge-theme.scss +1 -2
- package/badge/badge.component.scss +0 -1
- package/badge/public-api.d.ts +1 -1
- package/button/_button-base.scss +0 -1
- package/button/_button-theme.scss +5 -3
- package/button/button.component.d.ts +2 -2
- package/button/button.scss +0 -1
- package/button/public-api.d.ts +1 -1
- package/button-toggle/_button-toggle-theme.scss +2 -3
- package/button-toggle/button-toggle.scss +2 -9
- package/button-toggle/public-api.d.ts +1 -1
- package/card/_card-theme.scss +0 -1
- package/card/card.component.d.ts +1 -1
- package/card/card.component.scss +1 -2
- package/card/public-api.d.ts +1 -1
- package/checkbox/_checkbox-theme.scss +10 -11
- package/checkbox/checkbox.scss +13 -19
- package/code-block/README.md +17 -14
- package/code-block/_code-block-theme.scss +23 -16
- package/code-block/actionbar.component.d.ts +2 -1
- package/code-block/actionbar.component.scss +5 -13
- package/code-block/code-block.component.d.ts +4 -3
- package/code-block/code-block.scss +8 -14
- 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/_forms-theme.scss +0 -1
- package/core/forms/_forms.scss +0 -1
- package/core/forms/index.d.ts +1 -1
- package/core/locales/index.d.ts +1 -1
- package/core/option/_optgroup-theme.scss +0 -1
- package/core/option/_option-action-theme.scss +0 -1
- package/core/option/_option-theme.scss +0 -1
- package/core/option/action.scss +4 -2
- package/core/option/index.d.ts +2 -2
- package/core/option/optgroup.scss +2 -3
- package/core/option/option.scss +0 -1
- package/core/pop-up/_pop-up.scss +0 -1
- package/core/pop-up/pop-up-trigger.d.ts +3 -3
- 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/selection/pseudo-checkbox/_pseudo-checkbox-theme.scss +0 -2
- package/core/selection/pseudo-checkbox/pseudo-checkbox.scss +0 -1
- package/core/services/theme.service.d.ts +3 -2
- package/core/styles/_core.scss +0 -1
- package/core/styles/_koobiq-theme.scss +5 -3
- package/core/styles/common/_animation.scss +11 -10
- package/core/styles/common/_button.scss +0 -2
- package/core/styles/common/_clearfix.scss +1 -1
- package/core/styles/common/_groups.scss +0 -4
- package/core/styles/common/_list.scss +23 -61
- package/core/styles/common/_overlay.scss +4 -3
- package/core/styles/common/_popup.scss +0 -1
- package/core/styles/common/_rtl.scss +4 -4
- package/core/styles/common/_select.scss +37 -26
- package/core/styles/common/_tokens.scss +0 -2
- package/core/styles/functions/_number.scss +14 -19
- package/core/styles/functions/_string.scss +18 -19
- package/core/styles/functions/_timing.scss +24 -24
- package/core/styles/theming/_components-theming.scss +1120 -1208
- package/core/styles/theming/_scrollbar-theme.scss +8 -5
- package/core/styles/theming/_theming.scss +22 -20
- package/core/styles/typography/_typography-utils.scss +9 -3
- package/core/styles/typography/_typography.scss +114 -94
- package/core/styles/visual/_body.scss +0 -2
- package/core/styles/visual/_layout.scss +30 -22
- package/core/utils/data-size/index.d.ts +1 -1
- package/core/utils/public-api.d.ts +1 -1
- package/datepicker/_datepicker-theme.scss +21 -8
- package/datepicker/calendar-body.scss +0 -3
- package/datepicker/calendar-header.scss +0 -1
- package/datepicker/calendar.scss +1 -2
- package/datepicker/datepicker-content.scss +1 -3
- package/datepicker/datepicker-input.directive.d.ts +1 -0
- package/datepicker/datepicker-input.scss +0 -1
- package/datepicker/datepicker-toggle.scss +0 -1
- package/datepicker/datepicker.component.d.ts +2 -2
- package/datepicker/public-api.d.ts +4 -4
- package/divider/_divider-theme.scss +0 -1
- package/divider/divider.scss +0 -1
- package/dl/_dl-theme.scss +0 -2
- package/dl/dl.scss +0 -1
- package/dl/public-api.d.ts +1 -1
- package/dropdown/_dropdown-theme.scss +4 -2
- package/dropdown/dropdown-content.directive.d.ts +1 -1
- package/dropdown/dropdown-item.component.d.ts +1 -1
- package/dropdown/dropdown-item.scss +9 -7
- package/dropdown/dropdown.component.d.ts +1 -1
- package/dropdown/dropdown.scss +0 -1
- package/dropdown/public-api.d.ts +5 -5
- package/ellipsis-center/ellipsis-center.directive.d.ts +1 -1
- package/empty-state/README.md +0 -0
- package/empty-state/_empty-state-theme.scss +56 -0
- package/empty-state/empty-state.component.d.ts +31 -0
- package/empty-state/empty-state.module.d.ts +10 -0
- package/empty-state/empty-state.scss +81 -0
- package/empty-state/index.d.ts +1 -0
- package/empty-state/public-api.d.ts +2 -0
- package/esm2022/alert/alert.component.mjs +7 -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 +25 -42
- 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 +8 -6
- 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 +26 -20
- 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 +4 -5
- 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 -8
- package/esm2022/checkbox/public-api.mjs +1 -1
- package/esm2022/code-block/actionbar.component.mjs +6 -6
- package/esm2022/code-block/code-block.component.mjs +20 -19
- 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 -5
- package/esm2022/core/common-behaviors/constructor.mjs +1 -1
- package/esm2022/core/common-behaviors/disabled.mjs +2 -2
- 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 -2
- 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 -24
- 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/formatters.mjs +1 -3
- 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 +22 -14
- package/esm2022/core/option/index.mjs +3 -3
- package/esm2022/core/option/optgroup.mjs +4 -5
- package/esm2022/core/option/option-module.mjs +1 -1
- package/esm2022/core/option/option.mjs +13 -10
- package/esm2022/core/overlay/overlay-position-map.mjs +1 -1
- package/esm2022/core/pop-up/pop-up-trigger.mjs +14 -24
- package/esm2022/core/pop-up/pop-up.mjs +1 -2
- package/esm2022/core/public-api.mjs +4 -4
- package/esm2022/core/select/common.mjs +2 -5
- package/esm2022/core/select/constants.mjs +1 -2
- 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 -2
- package/esm2022/core/services/theme.service.mjs +5 -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 -5
- package/esm2022/datepicker/calendar-header.component.mjs +8 -8
- 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 +47 -49
- 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 -18
- package/esm2022/datepicker/month-view.component.mjs +14 -14
- 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 +7 -7
- 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 -8
- package/esm2022/dropdown/dropdown-trigger.directive.mjs +24 -33
- package/esm2022/dropdown/dropdown.component.mjs +10 -19
- package/esm2022/dropdown/dropdown.module.mjs +1 -1
- package/esm2022/dropdown/dropdown.types.mjs +1 -2
- package/esm2022/dropdown/public-api.mjs +6 -6
- package/esm2022/ellipsis-center/ellipsis-center.directive.mjs +6 -5
- package/esm2022/empty-state/empty-state.component.mjs +104 -0
- package/esm2022/empty-state/empty-state.module.mjs +50 -0
- package/esm2022/empty-state/index.mjs +2 -0
- package/esm2022/empty-state/koobiq-components-empty-state.mjs +5 -0
- package/esm2022/empty-state/public-api.mjs +3 -0
- package/esm2022/file-upload/file-drop.mjs +3 -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 -14
- package/esm2022/file-upload/public-api.mjs +2 -2
- package/esm2022/file-upload/single-file-upload.component.mjs +14 -12
- package/esm2022/form-field/cleaner.mjs +13 -3
- package/esm2022/form-field/form-field-control.mjs +1 -2
- package/esm2022/form-field/form-field-errors.mjs +1 -1
- package/esm2022/form-field/form-field.mjs +8 -15
- package/esm2022/form-field/form-field.module.mjs +1 -1
- package/esm2022/form-field/hint.mjs +6 -6
- package/esm2022/form-field/password-hint.mjs +15 -15
- 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 -7
- package/esm2022/icon/icon-button.component.mjs +4 -4
- package/esm2022/icon/icon-item.component.mjs +3 -3
- package/esm2022/icon/icon.component.mjs +5 -6
- 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 +29 -41
- package/esm2022/input/input-password.mjs +13 -8
- package/esm2022/input/input-value-accessor.mjs +1 -1
- package/esm2022/input/input.mjs +13 -10
- 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 +36 -41
- package/esm2022/list/list.component.mjs +5 -6
- 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 +6 -2
- package/esm2022/modal/modal-ref.class.mjs +1 -2
- package/esm2022/modal/modal-util.mjs +1 -1
- package/esm2022/modal/modal.component.mjs +60 -33
- package/esm2022/modal/modal.directive.mjs +27 -11
- package/esm2022/modal/modal.module.mjs +2 -2
- package/esm2022/modal/modal.service.mjs +3 -6
- 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 +41 -33
- package/esm2022/navbar/navbar.component.mjs +19 -29
- package/esm2022/navbar/navbar.module.mjs +2 -2
- package/esm2022/navbar/public-api.mjs +3 -3
- package/esm2022/navbar/vertical-navbar.component.mjs +21 -23
- 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 -14
- 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 +3 -3
- package/esm2022/risk-level/risk-level.module.mjs +1 -1
- package/esm2022/scrollbar/public-api.mjs +2 -2
- package/esm2022/scrollbar/scrollbar.component.mjs +19 -21
- package/esm2022/scrollbar/scrollbar.directive.mjs +4 -5
- 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 +45 -71
- 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 +5 -7
- package/esm2022/sidebar/sidebar.module.mjs +1 -1
- package/esm2022/sidepanel/public-api.mjs +4 -4
- package/esm2022/sidepanel/sidepanel-animations.mjs +7 -4
- package/esm2022/sidepanel/sidepanel-config.mjs +1 -1
- package/esm2022/sidepanel/sidepanel-container.component.mjs +4 -4
- package/esm2022/sidepanel/sidepanel-directives.mjs +33 -20
- package/esm2022/sidepanel/sidepanel-ref.mjs +10 -5
- package/esm2022/sidepanel/sidepanel.module.mjs +1 -1
- package/esm2022/sidepanel/sidepanel.service.mjs +11 -15
- package/esm2022/splitter/public-api.mjs +2 -2
- package/esm2022/splitter/splitter.component.mjs +13 -24
- package/esm2022/splitter/splitter.module.mjs +1 -1
- package/esm2022/table/public-api.mjs +2 -2
- package/esm2022/table/table.component.mjs +3 -3
- package/esm2022/table/table.module.mjs +1 -1
- package/esm2022/tabs/paginated-tab-header.mjs +9 -14
- package/esm2022/tabs/public-api.mjs +6 -6
- package/esm2022/tabs/tab-body.component.mjs +10 -11
- 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 +46 -49
- package/esm2022/tabs/tab.component.mjs +7 -10
- 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 -16
- package/esm2022/tags/tag-list.component.mjs +15 -27
- package/esm2022/tags/tag-text-control.mjs +1 -1
- package/esm2022/tags/tag.component.mjs +5 -8
- package/esm2022/tags/tag.module.mjs +9 -7
- package/esm2022/textarea/index.mjs +1 -1
- package/esm2022/textarea/textarea.component.mjs +4 -7
- package/esm2022/textarea/textarea.module.mjs +1 -1
- package/esm2022/timepicker/public-api.mjs +2 -2
- package/esm2022/timepicker/timepicker.constants.mjs +6 -2
- package/esm2022/timepicker/timepicker.directive.mjs +62 -31
- 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.models.mjs +1 -2
- 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 +5 -6
- package/esm2022/toast/toast.component.mjs +6 -6
- package/esm2022/toast/toast.module.mjs +1 -1
- package/esm2022/toast/toast.service.mjs +18 -30
- package/esm2022/toast/toast.type.mjs +1 -1
- package/esm2022/toggle/public-api.mjs +2 -2
- package/esm2022/toggle/toggle.component.mjs +17 -11
- 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 -7
- package/esm2022/tooltip/tooltip.module.mjs +2 -2
- package/esm2022/tree/control/base-tree-control.mjs +1 -2
- 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 -2
- 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 -4
- 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 -7
- package/esm2022/tree/tree-errors.mjs +1 -1
- package/esm2022/tree/tree-option.component.mjs +9 -13
- package/esm2022/tree/tree-selection.component.mjs +20 -36
- package/esm2022/tree/tree.mjs +7 -3
- package/esm2022/tree/tree.module.mjs +2 -3
- package/esm2022/tree-select/public-api.mjs +2 -2
- package/esm2022/tree-select/tree-select.component.mjs +59 -72
- package/esm2022/tree-select/tree-select.module.mjs +1 -1
- package/fesm2022/koobiq-components-alert.mjs +10 -6
- package/fesm2022/koobiq-components-alert.mjs.map +1 -1
- package/fesm2022/koobiq-components-autocomplete.mjs +60 -72
- package/fesm2022/koobiq-components-autocomplete.mjs.map +1 -1
- package/fesm2022/koobiq-components-badge.mjs +10 -8
- package/fesm2022/koobiq-components-badge.mjs.map +1 -1
- package/fesm2022/koobiq-components-button-toggle.mjs +30 -24
- 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 +4 -5
- package/fesm2022/koobiq-components-card.mjs.map +1 -1
- package/fesm2022/koobiq-components-checkbox.mjs +3 -5
- package/fesm2022/koobiq-components-checkbox.mjs.map +1 -1
- package/fesm2022/koobiq-components-code-block.mjs +39 -34
- package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
- package/fesm2022/koobiq-components-core.mjs +325 -336
- package/fesm2022/koobiq-components-core.mjs.map +1 -1
- package/fesm2022/koobiq-components-datepicker.mjs +105 -111
- package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-divider.mjs.map +1 -1
- package/fesm2022/koobiq-components-dl.mjs +9 -9
- package/fesm2022/koobiq-components-dl.mjs.map +1 -1
- package/fesm2022/koobiq-components-dropdown.mjs +125 -147
- package/fesm2022/koobiq-components-dropdown.mjs.map +1 -1
- package/fesm2022/koobiq-components-ellipsis-center.mjs +3 -2
- package/fesm2022/koobiq-components-ellipsis-center.mjs.map +1 -1
- package/fesm2022/koobiq-components-empty-state.mjs +157 -0
- package/fesm2022/koobiq-components-empty-state.mjs.map +1 -0
- package/fesm2022/koobiq-components-file-upload.mjs +46 -41
- package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
- package/fesm2022/koobiq-components-form-field.mjs +75 -73
- package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
- package/fesm2022/koobiq-components-icon.mjs +9 -10
- package/fesm2022/koobiq-components-icon.mjs.map +1 -1
- package/fesm2022/koobiq-components-input.mjs +56 -60
- 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 +43 -49
- 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 +96 -54
- package/fesm2022/koobiq-components-modal.mjs.map +1 -1
- package/fesm2022/koobiq-components-navbar.mjs +82 -86
- 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 -16
- package/fesm2022/koobiq-components-radio.mjs.map +1 -1
- package/fesm2022/koobiq-components-risk-level.mjs +4 -4
- package/fesm2022/koobiq-components-risk-level.mjs.map +1 -1
- package/fesm2022/koobiq-components-scrollbar.mjs +22 -24
- package/fesm2022/koobiq-components-scrollbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-select.mjs +55 -78
- package/fesm2022/koobiq-components-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidebar.mjs +5 -7
- package/fesm2022/koobiq-components-sidebar.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidepanel.mjs +110 -93
- package/fesm2022/koobiq-components-sidepanel.mjs.map +1 -1
- package/fesm2022/koobiq-components-splitter.mjs +15 -26
- package/fesm2022/koobiq-components-splitter.mjs.map +1 -1
- package/fesm2022/koobiq-components-table.mjs +5 -5
- package/fesm2022/koobiq-components-table.mjs.map +1 -1
- package/fesm2022/koobiq-components-tabs.mjs +85 -98
- package/fesm2022/koobiq-components-tabs.mjs.map +1 -1
- package/fesm2022/koobiq-components-tags.mjs +39 -56
- package/fesm2022/koobiq-components-tags.mjs.map +1 -1
- package/fesm2022/koobiq-components-textarea.mjs +2 -5
- package/fesm2022/koobiq-components-textarea.mjs.map +1 -1
- package/fesm2022/koobiq-components-timepicker.mjs +69 -34
- package/fesm2022/koobiq-components-timepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-timezone.mjs +16 -21
- 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 +74 -87
- package/fesm2022/koobiq-components-toast.mjs.map +1 -1
- package/fesm2022/koobiq-components-toggle.mjs +17 -11
- package/fesm2022/koobiq-components-toggle.mjs.map +1 -1
- package/fesm2022/koobiq-components-tooltip.mjs +10 -10
- package/fesm2022/koobiq-components-tooltip.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree-select.mjs +67 -80
- package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree.mjs +509 -541
- package/fesm2022/koobiq-components-tree.mjs.map +1 -1
- package/file-upload/_file-upload-theme.scss +28 -18
- package/file-upload/file-upload.scss +0 -1
- package/file-upload/multiple-file-upload.component.d.ts +2 -2
- package/file-upload/multiple-file-upload.component.scss +17 -27
- package/file-upload/public-api.d.ts +1 -1
- package/file-upload/single-file-upload.component.d.ts +2 -2
- package/file-upload/single-file-upload.component.scss +1 -7
- package/form-field/_form-field-theme.scss +24 -12
- package/form-field/_hint-theme.scss +0 -2
- package/form-field/cleaner.scss +0 -1
- package/form-field/form-field.scss +12 -14
- package/form-field/hint.scss +0 -1
- package/form-field/password-toggle.scss +0 -1
- package/form-field/public-api.d.ts +3 -3
- package/form-field/stepper.scss +0 -1
- package/icon/_icon-button-theme.scss +18 -7
- package/icon/_icon-theme.scss +0 -1
- package/icon/icon-button.scss +2 -5
- package/icon/icon-item.scss +2 -5
- package/icon/icon.scss +0 -1
- package/icon/public-api.d.ts +2 -2
- package/input/_input-theme.scss +0 -1
- package/input/input.scss +9 -9
- package/input/public-api.d.ts +2 -2
- package/link/_link-theme.scss +12 -18
- package/link/link.component.d.ts +1 -1
- package/link/public-api.d.ts +1 -1
- package/list/_list-theme.scss +0 -1
- package/list/list-selection.component.d.ts +3 -3
- package/list/list.scss +1 -3
- package/list/public-api.d.ts +2 -2
- package/loader-overlay/_loader-overlay-theme.scss +6 -4
- package/loader-overlay/loader-overlay.scss +0 -1
- package/loader-overlay/public-api.d.ts +1 -1
- package/markdown/_markdown-theme.scss +11 -8
- package/markdown/markdown.scss +3 -3
- package/modal/README.md +4 -3
- package/modal/_modal-animation.scss +0 -1
- package/modal/_modal-confirm.scss +0 -1
- package/modal/_modal-theme.scss +8 -9
- package/modal/modal.directive.d.ts +3 -3
- package/modal/modal.scss +9 -15
- package/modal/modal.type.d.ts +2 -2
- package/modal/public-api.d.ts +2 -2
- package/navbar/README.md +21 -20
- package/navbar/_navbar-item_horizontal.scss +31 -24
- package/navbar/_navbar-item_vertical.scss +0 -3
- package/navbar/_navbar-theme.scss +3 -6
- package/navbar/navbar-brand.scss +0 -1
- package/navbar/navbar-divider.scss +0 -1
- package/navbar/navbar-item.component.d.ts +1 -1
- package/navbar/navbar-item.scss +9 -2
- package/navbar/navbar.scss +0 -1
- package/navbar/public-api.d.ts +2 -2
- package/navbar/vertical-navbar.scss +0 -1
- package/package.json +12 -6
- package/popover/README.md +17 -14
- package/popover/_popover-theme.scss +0 -1
- package/popover/popover.component.d.ts +1 -1
- package/popover/popover.scss +5 -13
- 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/_progress-bar-theme.scss +0 -1
- package/progress-bar/progress-bar.scss +0 -1
- package/progress-bar/public-api.d.ts +1 -1
- package/progress-spinner/_progress-spinner-theme.scss +0 -1
- package/progress-spinner/progress-spinner.scss +0 -1
- package/progress-spinner/public-api.d.ts +1 -1
- package/radio/_radio-theme.scss +13 -5
- package/radio/public-api.d.ts +1 -1
- package/radio/radio.scss +20 -6
- package/risk-level/_risk-level-theme.scss +0 -1
- package/risk-level/public-api.d.ts +1 -1
- package/risk-level/risk-level.component.scss +1 -4
- package/schematics/ng-add/index.js +4 -4
- package/scrollbar/_scrollbar-component-theme.scss +2 -3
- package/scrollbar/public-api.d.ts +1 -1
- package/scrollbar/scrollbar.component.scss +56 -44
- package/scrollbar/scrollbar.directive.d.ts +1 -1
- package/scrollbar/scrollbar.types.d.ts +1 -1
- package/select/_select-theme.scss +0 -1
- package/select/public-api.d.ts +2 -2
- package/select/select.component.d.ts +4 -1
- package/select/select.scss +0 -1
- package/sidebar/public-api.d.ts +1 -1
- package/sidepanel/_sidepanel-theme.scss +0 -1
- package/sidepanel/public-api.d.ts +3 -3
- package/sidepanel/sidepanel.scss +6 -12
- package/splitter/_splitter-theme.scss +0 -1
- package/splitter/public-api.d.ts +1 -1
- package/splitter/splitter.component.d.ts +2 -2
- package/splitter/splitter.scss +0 -1
- package/table/_table-theme.scss +7 -7
- package/table/public-api.d.ts +1 -1
- package/table/table.scss +2 -2
- package/tabs/_tabs-common.scss +10 -8
- package/tabs/_tabs-theme.scss +0 -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/tabs/tab-group.scss +0 -1
- package/tabs/tab-header.scss +0 -6
- package/tabs/tab-nav-bar/tab-nav-bar.d.ts +17 -17
- package/tabs/tab-nav-bar/tab-nav-bar.scss +0 -1
- package/tags/_tag-theme.scss +0 -2
- package/tags/public-api.d.ts +4 -4
- package/tags/tag-input.d.ts +1 -1
- package/tags/tag-list.scss +9 -7
- package/tags/tag.component.d.ts +2 -2
- package/tags/tag.scss +1 -4
- package/textarea/_textarea-theme.scss +0 -1
- package/textarea/textarea.component.d.ts +1 -1
- package/textarea/textarea.scss +1 -4
- 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/timepicker/timepicker.scss +0 -1
- package/timezone/_timezone-option-theme.scss +0 -1
- package/timezone/timezone-option.component.scss +0 -1
- package/timezone/timezone-option.directive.d.ts +1 -1
- package/timezone/timezone-select.component.scss +0 -1
- package/timezone/timezone.utils.d.ts +1 -1
- package/title/public-api.d.ts +1 -1
- package/title/title.directive.d.ts +2 -2
- package/toast/_toast-theme.scss +0 -2
- package/toast/public-api.d.ts +3 -3
- package/toast/toast-container.component.scss +0 -1
- package/toast/toast.component.scss +4 -2
- package/toast/toast.service.d.ts +2 -2
- package/toast/toast.type.d.ts +1 -1
- package/toggle/_toggle-theme.scss +10 -9
- package/toggle/public-api.d.ts +1 -1
- package/toggle/toggle.component.d.ts +2 -2
- package/toggle/toggle.scss +0 -1
- package/tooltip/_tooltip-theme.scss +0 -1
- package/tooltip/public-api.d.ts +1 -1
- package/tooltip/tooltip.component.d.ts +2 -2
- package/tooltip/tooltip.scss +1 -5
- package/tree/_tree-theme.scss +2 -3
- package/tree/public-api.d.ts +10 -10
- package/tree/toggle.scss +0 -1
- package/tree/tree-base.d.ts +1 -1
- package/tree/tree-option.component.d.ts +1 -1
- package/tree/tree-option.scss +12 -8
- package/tree/tree-selection.component.d.ts +3 -2
- package/tree-select/_tree-select-theme.scss +0 -1
- package/tree-select/public-api.d.ts +1 -1
- package/tree-select/tree-select.component.d.ts +9 -4
- package/tree-select/tree-select.scss +0 -1
|
@@ -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',
|
|
@@ -97,10 +144,8 @@ class KbqCommonModule {
|
|
|
97
144
|
// Whether we've done the global sanity checks (e.g. a theme is loaded, there is a doctype).
|
|
98
145
|
this.hasDoneGlobalChecks = false;
|
|
99
146
|
// Reference to the global `document` object.
|
|
100
|
-
// tslint:disable-next-line: orthodox-getter-and-setter
|
|
101
147
|
this._document = typeof document === 'object' && document ? document : null;
|
|
102
148
|
// Reference to the global 'window' object.
|
|
103
|
-
// tslint:disable-next-line: orthodox-getter-and-setter
|
|
104
149
|
this._window = typeof window === 'object' && window ? window : null;
|
|
105
150
|
if (this.areChecksEnabled() && !this.hasDoneGlobalChecks) {
|
|
106
151
|
this.checkDoctypeIsDefined();
|
|
@@ -114,7 +159,6 @@ class KbqCommonModule {
|
|
|
114
159
|
}
|
|
115
160
|
// Whether the code is running in tests.
|
|
116
161
|
isTestEnv() {
|
|
117
|
-
// tslint:disable-next-line
|
|
118
162
|
return this._window && (this._window['__karma__'] || this._window['jasmine']);
|
|
119
163
|
}
|
|
120
164
|
checkDoctypeIsDefined() {
|
|
@@ -157,6 +201,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
157
201
|
args: [KBQ_SANITY_CHECKS]
|
|
158
202
|
}] }] });
|
|
159
203
|
|
|
204
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
160
205
|
function mixinDisabled(base) {
|
|
161
206
|
return class extends base {
|
|
162
207
|
get disabled() {
|
|
@@ -166,54 +211,29 @@ function mixinDisabled(base) {
|
|
|
166
211
|
this._disabled = coerceBooleanProperty(value);
|
|
167
212
|
}
|
|
168
213
|
constructor(...args) {
|
|
169
|
-
// tslint:disable-next-line
|
|
170
214
|
super(...args);
|
|
171
215
|
this._disabled = false;
|
|
172
216
|
}
|
|
173
217
|
};
|
|
174
218
|
}
|
|
175
219
|
|
|
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) {
|
|
220
|
+
function mixinErrorState(base) {
|
|
200
221
|
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
222
|
constructor(...args) {
|
|
215
223
|
super(...args);
|
|
216
|
-
|
|
224
|
+
/** Whether the component is in an error state. */
|
|
225
|
+
this.errorState = false;
|
|
226
|
+
}
|
|
227
|
+
updateErrorState() {
|
|
228
|
+
const oldState = this.errorState;
|
|
229
|
+
const parent = this.parentFormGroup || this.parentForm;
|
|
230
|
+
const matcher = this.errorStateMatcher || this.defaultErrorStateMatcher;
|
|
231
|
+
const control = this.ngControl ? this.ngControl.control : null;
|
|
232
|
+
const newState = matcher.isErrorState(control, parent);
|
|
233
|
+
if (newState !== oldState) {
|
|
234
|
+
this.errorState = newState;
|
|
235
|
+
this.stateChanges.next();
|
|
236
|
+
}
|
|
217
237
|
}
|
|
218
238
|
};
|
|
219
239
|
}
|
|
@@ -235,44 +255,22 @@ function mixinTabIndex(base, defaultTabIndex = 0) {
|
|
|
235
255
|
};
|
|
236
256
|
}
|
|
237
257
|
|
|
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
258
|
const KBQ_PARENT_ANIMATION_COMPONENT = new InjectionToken('kbq-parent-animation-component');
|
|
260
259
|
|
|
261
|
-
const KBQ_DATE_FORMATS = new InjectionToken('kbq-date-formats');
|
|
262
|
-
|
|
263
260
|
/** InjectionToken for datepicker that can be used to override default locale code. */
|
|
264
261
|
const KBQ_DATE_LOCALE = new InjectionToken('KBQ_DATE_LOCALE', {
|
|
265
262
|
providedIn: 'root',
|
|
266
263
|
factory: KBQ_DATE_LOCALE_FACTORY
|
|
267
264
|
});
|
|
268
265
|
/** @docs-private */
|
|
269
|
-
// tslint:disable-next-line:naming-convention
|
|
270
266
|
function KBQ_DATE_LOCALE_FACTORY() {
|
|
271
267
|
return inject(LOCALE_ID);
|
|
272
268
|
}
|
|
273
269
|
class DateAdapter extends DateAdapter$1 {
|
|
274
270
|
}
|
|
275
271
|
|
|
272
|
+
const KBQ_DATE_FORMATS = new InjectionToken('kbq-date-formats');
|
|
273
|
+
|
|
276
274
|
/** Error state matcher that matches when a control is invalid and dirty. */
|
|
277
275
|
class ShowOnDirtyErrorStateMatcher {
|
|
278
276
|
isErrorState(control, form) {
|
|
@@ -297,6 +295,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
297
295
|
args: [{ providedIn: 'root' }]
|
|
298
296
|
}] });
|
|
299
297
|
|
|
298
|
+
/**
|
|
299
|
+
* Injection token that can be used to inject an instances of `KbqFormField`. It serves
|
|
300
|
+
* as alternative token to the actual `KbqFormField` class which would cause unnecessary
|
|
301
|
+
* retention of the `KbqFormField` class and its component metadata.
|
|
302
|
+
*/
|
|
303
|
+
const KBQ_FORM_FIELD_REF = new InjectionToken('KbqFormFieldRef');
|
|
304
|
+
|
|
300
305
|
class DateFormatter extends DateFormatter$1 {
|
|
301
306
|
constructor(adapter, locale) {
|
|
302
307
|
super(adapter, locale);
|
|
@@ -655,8 +660,8 @@ const ruRULocaleData = {
|
|
|
655
660
|
},
|
|
656
661
|
timepicker: {
|
|
657
662
|
placeholder: {
|
|
658
|
-
full: '
|
|
659
|
-
short: '
|
|
663
|
+
full: 'чч:мм:сс',
|
|
664
|
+
short: 'чч:мм'
|
|
660
665
|
}
|
|
661
666
|
},
|
|
662
667
|
fileUpload: {
|
|
@@ -760,7 +765,6 @@ const esLAFormattersData = {
|
|
|
760
765
|
input: {
|
|
761
766
|
number: {
|
|
762
767
|
// nbsp is generated automatically and used by default in spec
|
|
763
|
-
// tslint:disable-next-line:no-irregular-whitespace
|
|
764
768
|
groupSeparator: [' ', ' '],
|
|
765
769
|
fractionSeparator: ','
|
|
766
770
|
}
|
|
@@ -871,7 +875,6 @@ const ruRUFormattersData = {
|
|
|
871
875
|
input: {
|
|
872
876
|
number: {
|
|
873
877
|
// nbsp is generated automatically and used by default in spec
|
|
874
|
-
// tslint:disable-next-line:no-irregular-whitespace
|
|
875
878
|
groupSeparator: [' ', ' '],
|
|
876
879
|
fractionSeparator: ',',
|
|
877
880
|
startFormattingFrom: 4
|
|
@@ -950,7 +953,10 @@ function KBQ_DEFAULT_LOCALE_DATA_FACTORY() {
|
|
|
950
953
|
'fa-IR': { ...faIRLocaleData, ...faIRFormattersData }
|
|
951
954
|
};
|
|
952
955
|
}
|
|
953
|
-
const KBQ_LOCALE_DATA = new InjectionToken('KBQ_LOCALE_DATA', {
|
|
956
|
+
const KBQ_LOCALE_DATA = new InjectionToken('KBQ_LOCALE_DATA', {
|
|
957
|
+
providedIn: 'root',
|
|
958
|
+
factory: KBQ_DEFAULT_LOCALE_DATA_FACTORY
|
|
959
|
+
});
|
|
954
960
|
const KBQ_LOCALE_SERVICE = new InjectionToken('KBQ_LOCALE_SERVICE');
|
|
955
961
|
class KbqLocaleService {
|
|
956
962
|
constructor(id, localeData) {
|
|
@@ -1009,7 +1015,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1009
1015
|
}]
|
|
1010
1016
|
}] });
|
|
1011
1017
|
|
|
1012
|
-
/* tslint:disable:naming-convention */
|
|
1013
1018
|
const KBQ_NUMBER_FORMATTER_OPTIONS = new InjectionToken('KbqNumberFormatterOptions');
|
|
1014
1019
|
const KBQ_NUMBER_FORMATTER_DEFAULT_OPTIONS = {
|
|
1015
1020
|
useGrouping: true,
|
|
@@ -1034,7 +1039,6 @@ const minIntGroupPosition = 1;
|
|
|
1034
1039
|
const minFractionGroupPosition = 3;
|
|
1035
1040
|
const maxFractionGroupPosition = 5;
|
|
1036
1041
|
const useGroupingPosition = 7;
|
|
1037
|
-
// tslint:disable:no-magic-numbers
|
|
1038
1042
|
const ROUNDING_UNITS = {
|
|
1039
1043
|
thousand: 1e3,
|
|
1040
1044
|
tenThousand: 10 * 1e3,
|
|
@@ -1053,7 +1057,6 @@ const intervalsConfig = {
|
|
|
1053
1057
|
{ startRange: ROUNDING_UNITS.million * 10, endRange: ROUNDING_UNITS.billion }
|
|
1054
1058
|
]
|
|
1055
1059
|
};
|
|
1056
|
-
// tslint:enable:no-magic-numbers
|
|
1057
1060
|
class ParsedDigitsInfo {
|
|
1058
1061
|
}
|
|
1059
1062
|
const defaultValueForGroupingInRULocale = 10000;
|
|
@@ -1090,8 +1093,7 @@ class KbqDecimalPipe {
|
|
|
1090
1093
|
this.localeService = localeService;
|
|
1091
1094
|
this.options = options;
|
|
1092
1095
|
this.options = this.options || KBQ_NUMBER_FORMATTER_DEFAULT_OPTIONS;
|
|
1093
|
-
this.localeService?.changes
|
|
1094
|
-
.subscribe((newId) => this.id = newId);
|
|
1096
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1095
1097
|
}
|
|
1096
1098
|
/**
|
|
1097
1099
|
* @param value The number to be formatted.
|
|
@@ -1172,8 +1174,7 @@ class KbqTableNumberPipe {
|
|
|
1172
1174
|
this.localeService = localeService;
|
|
1173
1175
|
this.options = options;
|
|
1174
1176
|
this.options = this.options || KBQ_NUMBER_FORMATTER_DEFAULT_OPTIONS;
|
|
1175
|
-
this.localeService?.changes
|
|
1176
|
-
.subscribe((newId) => this.id = newId);
|
|
1177
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1177
1178
|
}
|
|
1178
1179
|
/**
|
|
1179
1180
|
* @param value The number to be formatted.
|
|
@@ -1249,8 +1250,7 @@ class KbqRoundDecimalPipe {
|
|
|
1249
1250
|
constructor(id, localeService) {
|
|
1250
1251
|
this.id = id;
|
|
1251
1252
|
this.localeService = localeService;
|
|
1252
|
-
this.localeService?.changes
|
|
1253
|
-
.subscribe((newId) => this.id = newId);
|
|
1253
|
+
this.localeService?.changes.subscribe((newId) => (this.id = newId));
|
|
1254
1254
|
}
|
|
1255
1255
|
transform(value, locale) {
|
|
1256
1256
|
if (isEmpty(value)) {
|
|
@@ -1266,17 +1266,17 @@ class KbqRoundDecimalPipe {
|
|
|
1266
1266
|
}
|
|
1267
1267
|
let parts = {};
|
|
1268
1268
|
if (intervalsConfig.supportedLanguages.includes(currentLocale)) {
|
|
1269
|
-
intervalsConfig.intervals
|
|
1270
|
-
.find(({ startRange, endRange, precision }) => {
|
|
1269
|
+
intervalsConfig.intervals.find(({ startRange, endRange, precision }) => {
|
|
1271
1270
|
const within = isWithin(startRange, endRange, num);
|
|
1272
1271
|
if (within) {
|
|
1273
1272
|
if (precision) {
|
|
1274
|
-
parts =
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1273
|
+
parts =
|
|
1274
|
+
unit === 'thousand'
|
|
1275
|
+
? this.calculatePartsForThousands(num)
|
|
1276
|
+
: {
|
|
1277
|
+
num: Math.trunc(num / ROUNDING_UNITS[unit]),
|
|
1278
|
+
fraction: this.calculateDecimal(num, ROUNDING_UNITS[unit])
|
|
1279
|
+
};
|
|
1280
1280
|
}
|
|
1281
1281
|
else {
|
|
1282
1282
|
parts = { num: Math.round(num / ROUNDING_UNITS[unit]) };
|
|
@@ -1285,10 +1285,12 @@ class KbqRoundDecimalPipe {
|
|
|
1285
1285
|
return within;
|
|
1286
1286
|
});
|
|
1287
1287
|
}
|
|
1288
|
-
parts = parts.num
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1288
|
+
parts = parts.num
|
|
1289
|
+
? parts
|
|
1290
|
+
: {
|
|
1291
|
+
num: Math.trunc(num / ROUNDING_UNITS[unit]),
|
|
1292
|
+
fraction: this.calculateDecimal(num, ROUNDING_UNITS[unit])
|
|
1293
|
+
};
|
|
1292
1294
|
Object.keys(parts).forEach((key) => {
|
|
1293
1295
|
parts[key] = Intl.NumberFormat.call(this, currentLocale, { useGrouping: false }).format(parts[key]);
|
|
1294
1296
|
});
|
|
@@ -1302,8 +1304,7 @@ class KbqRoundDecimalPipe {
|
|
|
1302
1304
|
}
|
|
1303
1305
|
}
|
|
1304
1306
|
calculateDecimal(num, divider) {
|
|
1305
|
-
|
|
1306
|
-
return Math.round(num / divider % 1 * 10);
|
|
1307
|
+
return Math.round(((num / divider) % 1) * 10);
|
|
1307
1308
|
}
|
|
1308
1309
|
/**
|
|
1309
1310
|
* 2 * 1000 is a number in the interval of [1500...2500)
|
|
@@ -1433,13 +1434,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1433
1434
|
}]
|
|
1434
1435
|
}] });
|
|
1435
1436
|
|
|
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
1437
|
class KbqFormElement {
|
|
1444
1438
|
constructor(element) {
|
|
1445
1439
|
this.element = element;
|
|
@@ -1631,12 +1625,131 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1631
1625
|
}]
|
|
1632
1626
|
}] });
|
|
1633
1627
|
|
|
1634
|
-
const
|
|
1628
|
+
const KBQ_OPTION_ACTION_PARENT = new InjectionToken('KBQ_OPTION_ACTION_PARENT');
|
|
1629
|
+
/** @docs-private */
|
|
1630
|
+
class KbqOptionActionBase {
|
|
1631
|
+
}
|
|
1632
|
+
/** @docs-private */
|
|
1633
|
+
const KbqOptionActionMixinBase = mixinTabIndex(mixinDisabled(KbqOptionActionBase));
|
|
1634
|
+
class KbqOptionActionComponent extends KbqOptionActionMixinBase {
|
|
1635
|
+
get active() {
|
|
1636
|
+
return this.hasFocus || !!this.option.dropdownTrigger?.opened;
|
|
1637
|
+
}
|
|
1638
|
+
constructor(elementRef, focusMonitor, option) {
|
|
1639
|
+
super();
|
|
1640
|
+
this.elementRef = elementRef;
|
|
1641
|
+
this.focusMonitor = focusMonitor;
|
|
1642
|
+
this.option = option;
|
|
1643
|
+
this.hasFocus = false;
|
|
1644
|
+
this.destroy = new Subject();
|
|
1645
|
+
this.focusMonitor.monitor(this.elementRef.nativeElement);
|
|
1646
|
+
}
|
|
1647
|
+
ngAfterViewInit() {
|
|
1648
|
+
if (!this.option.dropdownTrigger) {
|
|
1649
|
+
return;
|
|
1650
|
+
}
|
|
1651
|
+
this.option.dropdownTrigger.restoreFocus = false;
|
|
1652
|
+
this.option.dropdownTrigger.dropdownClosed.pipe(takeUntil(this.destroy)).subscribe(() => {
|
|
1653
|
+
this.preventShowingTooltip();
|
|
1654
|
+
const destroyReason = this.option.dropdownTrigger.lastDestroyReason === 'keydown' ? 'keyboard' : 'program';
|
|
1655
|
+
this.focus(destroyReason);
|
|
1656
|
+
});
|
|
1657
|
+
}
|
|
1658
|
+
ngOnDestroy() {
|
|
1659
|
+
this.destroy.next();
|
|
1660
|
+
this.destroy.complete();
|
|
1661
|
+
this.focusMonitor.stopMonitoring(this.elementRef.nativeElement);
|
|
1662
|
+
}
|
|
1663
|
+
focus(origin, options) {
|
|
1664
|
+
if (this.focusMonitor && origin) {
|
|
1665
|
+
this.focusMonitor.focusVia(this.elementRef.nativeElement, origin, options);
|
|
1666
|
+
}
|
|
1667
|
+
else {
|
|
1668
|
+
this.elementRef.nativeElement.focus();
|
|
1669
|
+
}
|
|
1670
|
+
this.hasFocus = true;
|
|
1671
|
+
}
|
|
1672
|
+
onFocus($event) {
|
|
1673
|
+
$event.stopPropagation();
|
|
1674
|
+
this.hasFocus = true;
|
|
1675
|
+
}
|
|
1676
|
+
onBlur() {
|
|
1677
|
+
this.hasFocus = false;
|
|
1678
|
+
}
|
|
1679
|
+
onClick($event) {
|
|
1680
|
+
$event.stopPropagation();
|
|
1681
|
+
}
|
|
1682
|
+
onKeyDown($event) {
|
|
1683
|
+
if ([SPACE, ENTER].includes($event.keyCode) && this.option.dropdownTrigger) {
|
|
1684
|
+
this.option.dropdownTrigger.openedBy = 'keyboard';
|
|
1685
|
+
this.option.dropdownTrigger.toggle();
|
|
1686
|
+
}
|
|
1687
|
+
else if ($event.shiftKey && $event.keyCode === TAB) {
|
|
1688
|
+
this.hasFocus = false;
|
|
1689
|
+
this.option.focus();
|
|
1690
|
+
}
|
|
1691
|
+
else if ($event.keyCode === TAB) {
|
|
1692
|
+
return;
|
|
1693
|
+
}
|
|
1694
|
+
$event.preventDefault();
|
|
1695
|
+
$event.stopPropagation();
|
|
1696
|
+
}
|
|
1697
|
+
preventShowingTooltip() {
|
|
1698
|
+
if (!this.option.tooltipTrigger) {
|
|
1699
|
+
return;
|
|
1700
|
+
}
|
|
1701
|
+
this.option.tooltipTrigger.disabled = true;
|
|
1702
|
+
setTimeout(() => (this.option.tooltipTrigger.disabled = false));
|
|
1703
|
+
}
|
|
1704
|
+
/** @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 }); }
|
|
1705
|
+
/** @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: `
|
|
1706
|
+
<ng-container [ngSwitch]="!!customIcon">
|
|
1707
|
+
<i
|
|
1708
|
+
class="mc kbq-icon mc-ellipsis_16"
|
|
1709
|
+
*ngSwitchCase="false"
|
|
1710
|
+
></i>
|
|
1711
|
+
<ng-content
|
|
1712
|
+
*ngSwitchCase="true"
|
|
1713
|
+
select="[kbq-icon]"
|
|
1714
|
+
/>
|
|
1715
|
+
</ng-container>
|
|
1716
|
+
`, 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:var(--kbq-list-font-text-line-height, 20px);height:var(--kbq-list-font-text-line-height, 20px);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 }); }
|
|
1717
|
+
}
|
|
1718
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptionActionComponent, decorators: [{
|
|
1719
|
+
type: Component,
|
|
1720
|
+
args: [{ selector: 'kbq-option-action', exportAs: 'kbqOptionAction', template: `
|
|
1721
|
+
<ng-container [ngSwitch]="!!customIcon">
|
|
1722
|
+
<i
|
|
1723
|
+
class="mc kbq-icon mc-ellipsis_16"
|
|
1724
|
+
*ngSwitchCase="false"
|
|
1725
|
+
></i>
|
|
1726
|
+
<ng-content
|
|
1727
|
+
*ngSwitchCase="true"
|
|
1728
|
+
select="[kbq-icon]"
|
|
1729
|
+
/>
|
|
1730
|
+
</ng-container>
|
|
1731
|
+
`, host: {
|
|
1732
|
+
class: 'kbq-option-action',
|
|
1733
|
+
'[class.kbq-expanded]': 'false',
|
|
1734
|
+
'[class.kbq-disabled]': 'disabled',
|
|
1735
|
+
'[attr.disabled]': 'disabled || null',
|
|
1736
|
+
'[attr.tabIndex]': '-1',
|
|
1737
|
+
'(focus)': 'onFocus($event)',
|
|
1738
|
+
'(blur)': 'onBlur()',
|
|
1739
|
+
'(click)': 'onClick($event)',
|
|
1740
|
+
'(keydown)': 'onKeyDown($event)'
|
|
1741
|
+
}, 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:var(--kbq-list-font-text-line-height, 20px);height:var(--kbq-list-font-text-line-height, 20px);cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.kbq-option-action.kbq-disabled{cursor:default}\n"] }]
|
|
1742
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1$1.FocusMonitor }, { type: undefined, decorators: [{
|
|
1743
|
+
type: Inject,
|
|
1744
|
+
args: [KBQ_OPTION_ACTION_PARENT]
|
|
1745
|
+
}] }], propDecorators: { customIcon: [{
|
|
1746
|
+
type: ContentChild,
|
|
1747
|
+
args: ['customIcon']
|
|
1748
|
+
}] } });
|
|
1635
1749
|
|
|
1636
1750
|
/** @docs-private */
|
|
1637
1751
|
class KbqOptgroupBase {
|
|
1638
1752
|
}
|
|
1639
|
-
// tslint:disable-next-line: naming-convention
|
|
1640
1753
|
const KbqOptgroupMixinBase = mixinDisabled(KbqOptgroupBase);
|
|
1641
1754
|
let uniqueOptgroupIdCounter = 0;
|
|
1642
1755
|
/**
|
|
@@ -1649,18 +1762,20 @@ class KbqOptgroup extends KbqOptgroupMixinBase {
|
|
|
1649
1762
|
this.labelId = `kbq-optgroup-label-${uniqueOptgroupIdCounter++}`;
|
|
1650
1763
|
}
|
|
1651
1764
|
/** @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
|
|
1765
|
+
/** @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\" />\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
1766
|
}
|
|
1654
1767
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOptgroup, decorators: [{
|
|
1655
1768
|
type: Component,
|
|
1656
1769
|
args: [{ selector: 'kbq-optgroup', exportAs: 'kbqOptgroup', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, inputs: ['disabled'], host: {
|
|
1657
1770
|
class: 'kbq-optgroup',
|
|
1658
1771
|
'[class.kbq-disabled]': 'disabled'
|
|
1659
|
-
}, template: "<label
|
|
1772
|
+
}, 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\" />\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
1773
|
}], propDecorators: { label: [{
|
|
1661
1774
|
type: Input
|
|
1662
1775
|
}] } });
|
|
1663
1776
|
|
|
1777
|
+
const KBQ_TITLE_TEXT_REF = new InjectionToken('KbqTitleTextRef');
|
|
1778
|
+
|
|
1664
1779
|
// Boilerplate for applying mixins to KbqPseudoCheckbox.
|
|
1665
1780
|
/** @docs-private */
|
|
1666
1781
|
class KbqPseudoCheckboxBase {
|
|
@@ -1815,7 +1930,6 @@ class KbqOption extends KbqOptionBase {
|
|
|
1815
1930
|
this.parent = parent;
|
|
1816
1931
|
this.group = group;
|
|
1817
1932
|
/** Event emitted when the option is selected or deselected. */
|
|
1818
|
-
// tslint:disable-next-line:no-output-on-prefix
|
|
1819
1933
|
this.onSelectionChange = new EventEmitter();
|
|
1820
1934
|
/** Emits when the state of the option changes and any parents have to be notified. */
|
|
1821
1935
|
this.stateChanges = new Subject();
|
|
@@ -1843,7 +1957,6 @@ class KbqOption extends KbqOptionBase {
|
|
|
1843
1957
|
this.stateChanges.complete();
|
|
1844
1958
|
}
|
|
1845
1959
|
getHeight() {
|
|
1846
|
-
// tslint:disable-next-line:naming-convention
|
|
1847
1960
|
const DOMRect = this.element.nativeElement.getClientRects()[0];
|
|
1848
1961
|
return DOMRect ? DOMRect.height : 0;
|
|
1849
1962
|
}
|
|
@@ -1895,7 +2008,6 @@ class KbqOption extends KbqOptionBase {
|
|
|
1895
2008
|
}
|
|
1896
2009
|
/** Ensures the option is selected when activated from the keyboard. */
|
|
1897
2010
|
handleKeydown(event) {
|
|
1898
|
-
// tslint:disable-next-line
|
|
1899
2011
|
if (event.keyCode === ENTER || event.keyCode === SPACE) {
|
|
1900
2012
|
this.selectViaInteraction();
|
|
1901
2013
|
// Prevent the page from scrolling down and form submits.
|
|
@@ -1921,9 +2033,12 @@ class KbqOption extends KbqOptionBase {
|
|
|
1921
2033
|
return this.element.nativeElement;
|
|
1922
2034
|
}
|
|
1923
2035
|
/** @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
|
-
|
|
2036
|
+
/** @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: [
|
|
2037
|
+
{
|
|
2038
|
+
provide: KBQ_TITLE_TEXT_REF,
|
|
2039
|
+
useExisting: KbqOption
|
|
2040
|
+
}
|
|
2041
|
+
], 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/>\n\n<span\n #kbqTitleText\n class=\"kbq-option-text\"\n>\n <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, 1px))}.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, 1px))}.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
2042
|
}
|
|
1928
2043
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqOption, decorators: [{
|
|
1929
2044
|
type: Component,
|
|
@@ -1937,9 +2052,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
1937
2052
|
'[id]': 'id',
|
|
1938
2053
|
'(click)': 'selectViaInteraction()',
|
|
1939
2054
|
'(keydown)': 'handleKeydown($event)'
|
|
1940
|
-
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
1941
|
-
|
|
1942
|
-
|
|
2055
|
+
}, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
|
2056
|
+
{
|
|
2057
|
+
provide: KBQ_TITLE_TEXT_REF,
|
|
2058
|
+
useExisting: KbqOption
|
|
2059
|
+
}
|
|
2060
|
+
], template: "<kbq-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [disabled]=\"disabled\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n/>\n\n<span\n #kbqTitleText\n class=\"kbq-option-text\"\n>\n <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, 1px))}.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, 1px))}.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
2061
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
1944
2062
|
type: Optional
|
|
1945
2063
|
}, {
|
|
@@ -1999,120 +2117,6 @@ function getOptionScrollPosition(optionIndex, optionHeight, currentScrollPositio
|
|
|
1999
2117
|
return currentScrollPosition;
|
|
2000
2118
|
}
|
|
2001
2119
|
|
|
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
2120
|
var MultipleMode;
|
|
2117
2121
|
(function (MultipleMode) {
|
|
2118
2122
|
MultipleMode["CHECKBOX"] = "checkbox";
|
|
@@ -2434,7 +2438,6 @@ var PopUpSizes;
|
|
|
2434
2438
|
PopUpSizes["Large"] = "large";
|
|
2435
2439
|
})(PopUpSizes || (PopUpSizes = {}));
|
|
2436
2440
|
|
|
2437
|
-
// tslint:disable-next-line:naming-convention
|
|
2438
2441
|
class KbqPopUp {
|
|
2439
2442
|
constructor(changeDetectorRef) {
|
|
2440
2443
|
this.changeDetectorRef = changeDetectorRef;
|
|
@@ -2531,7 +2534,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
2531
2534
|
type: Directive
|
|
2532
2535
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }] });
|
|
2533
2536
|
|
|
2534
|
-
// tslint:disable-next-line:naming-convention
|
|
2535
2537
|
class KbqPopUpTrigger {
|
|
2536
2538
|
constructor(overlay, elementRef, ngZone, scrollDispatcher, hostView, scrollStrategy, direction) {
|
|
2537
2539
|
this.overlay = overlay;
|
|
@@ -2562,8 +2564,10 @@ class KbqPopUpTrigger {
|
|
|
2562
2564
|
let newPlacement = this.placement;
|
|
2563
2565
|
const { originX, originY, overlayX, overlayY } = $event.connectionPair;
|
|
2564
2566
|
Object.keys(this.availablePositions).some((key) => {
|
|
2565
|
-
if (originX === this.availablePositions[key].originX &&
|
|
2566
|
-
|
|
2567
|
+
if (originX === this.availablePositions[key].originX &&
|
|
2568
|
+
originY === this.availablePositions[key].originY &&
|
|
2569
|
+
overlayX === this.availablePositions[key].overlayX &&
|
|
2570
|
+
overlayY === this.availablePositions[key].overlayY) {
|
|
2567
2571
|
newPlacement = key;
|
|
2568
2572
|
return true;
|
|
2569
2573
|
}
|
|
@@ -2625,7 +2629,7 @@ class KbqPopUpTrigger {
|
|
|
2625
2629
|
}
|
|
2626
2630
|
}
|
|
2627
2631
|
handleKeydown(event) {
|
|
2628
|
-
if (this.isOpen && event.keyCode === ESCAPE) {
|
|
2632
|
+
if (this.isOpen && event.keyCode === ESCAPE) {
|
|
2629
2633
|
this.hide();
|
|
2630
2634
|
}
|
|
2631
2635
|
}
|
|
@@ -2641,14 +2645,10 @@ class KbqPopUpTrigger {
|
|
|
2641
2645
|
this.detach();
|
|
2642
2646
|
this.portal = this.portal || new ComponentPortal(this.getOverlayHandleComponentType(), this.hostView);
|
|
2643
2647
|
this.instance = this.overlayRef.attach(this.portal).instance;
|
|
2644
|
-
this.instance.afterHidden()
|
|
2645
|
-
.pipe(takeUntil(this.destroyed))
|
|
2646
|
-
.subscribe(this.detach);
|
|
2648
|
+
this.instance.afterHidden().pipe(takeUntil(this.destroyed)).subscribe(this.detach);
|
|
2647
2649
|
this.updateClassMap();
|
|
2648
2650
|
this.updateData();
|
|
2649
|
-
this.instance.visibleChange
|
|
2650
|
-
.pipe(takeUntil(this.destroyed), distinctUntilChanged())
|
|
2651
|
-
.subscribe((value) => {
|
|
2651
|
+
this.instance.visibleChange.pipe(takeUntil(this.destroyed), distinctUntilChanged()).subscribe((value) => {
|
|
2652
2652
|
this.visible = value;
|
|
2653
2653
|
this.visibleChange.emit(value);
|
|
2654
2654
|
this.isOpen = value;
|
|
@@ -2675,9 +2675,7 @@ class KbqPopUpTrigger {
|
|
|
2675
2675
|
.withPositions([...EXTENDED_OVERLAY_POSITIONS])
|
|
2676
2676
|
.withLockedPosition()
|
|
2677
2677
|
.withScrollableContainers(this.scrollDispatcher.getAncestorScrollContainers(this.elementRef));
|
|
2678
|
-
strategy.positionChanges
|
|
2679
|
-
.pipe(takeUntil(this.destroyed))
|
|
2680
|
-
.subscribe(this.onPositionChange);
|
|
2678
|
+
strategy.positionChanges.pipe(takeUntil(this.destroyed)).subscribe(this.onPositionChange);
|
|
2681
2679
|
this.overlayRef = this.overlay.create({
|
|
2682
2680
|
...this.overlayConfig,
|
|
2683
2681
|
direction: this.direction,
|
|
@@ -2685,16 +2683,13 @@ class KbqPopUpTrigger {
|
|
|
2685
2683
|
scrollStrategy: this.scrollStrategy()
|
|
2686
2684
|
});
|
|
2687
2685
|
this.subscribeOnClosingActions();
|
|
2688
|
-
this.overlayRef.detachments()
|
|
2689
|
-
.pipe(takeUntil(this.destroyed))
|
|
2690
|
-
.subscribe(this.detach);
|
|
2686
|
+
this.overlayRef.detachments().pipe(takeUntil(this.destroyed)).subscribe(this.detach);
|
|
2691
2687
|
return this.overlayRef;
|
|
2692
2688
|
}
|
|
2693
2689
|
initListeners() {
|
|
2694
2690
|
this.clearListeners();
|
|
2695
2691
|
if (this.trigger.includes(PopUpTriggers.Click)) {
|
|
2696
|
-
this.listeners
|
|
2697
|
-
.set(...this.createListener('click', this.show));
|
|
2692
|
+
this.listeners.set(...this.createListener('click', this.show));
|
|
2698
2693
|
}
|
|
2699
2694
|
if (this.trigger.includes(PopUpTriggers.Hover)) {
|
|
2700
2695
|
this.listeners
|
|
@@ -2707,15 +2702,13 @@ class KbqPopUpTrigger {
|
|
|
2707
2702
|
.set(...this.createListener('blur', this.hide));
|
|
2708
2703
|
}
|
|
2709
2704
|
if (this.trigger.includes(PopUpTriggers.Keydown)) {
|
|
2710
|
-
this.listeners
|
|
2711
|
-
.set('keydown', (event) => {
|
|
2705
|
+
this.listeners.set('keydown', (event) => {
|
|
2712
2706
|
if (event instanceof KeyboardEvent && [ENTER, SPACE].includes(event.keyCode)) {
|
|
2713
2707
|
this.show();
|
|
2714
2708
|
}
|
|
2715
2709
|
});
|
|
2716
2710
|
}
|
|
2717
|
-
this.listeners
|
|
2718
|
-
.forEach(this.addEventListener);
|
|
2711
|
+
this.listeners.forEach(this.addEventListener);
|
|
2719
2712
|
}
|
|
2720
2713
|
/** Updates the position of the current popover. */
|
|
2721
2714
|
updatePosition(reapplyPosition = false) {
|
|
@@ -2781,60 +2774,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
2781
2774
|
type: Directive
|
|
2782
2775
|
}], 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
2776
|
|
|
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
|
-
/* tslint:disable:no-empty */
|
|
2838
2777
|
class KbqSelectTrigger {
|
|
2839
2778
|
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.2.0", ngImport: i0, type: KbqSelectTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
2840
2779
|
/** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.2.0", type: KbqSelectTrigger, isStandalone: true, selector: "kbq-select-trigger, [kbq-select-trigger]", ngImport: i0 }); }
|
|
@@ -2905,14 +2844,12 @@ class KbqSelectSearch {
|
|
|
2905
2844
|
this.searchChangesSubscription.unsubscribe();
|
|
2906
2845
|
}
|
|
2907
2846
|
handleKeydown(event) {
|
|
2908
|
-
// tslint:disable-next-line:deprecation
|
|
2909
2847
|
if (event.keyCode === ESCAPE) {
|
|
2910
2848
|
if (this.value()) {
|
|
2911
2849
|
this.reset();
|
|
2912
2850
|
event.stopPropagation();
|
|
2913
2851
|
}
|
|
2914
2852
|
}
|
|
2915
|
-
// tslint:disable-next-line:deprecation
|
|
2916
2853
|
if ([SPACE, HOME, END].includes(event.keyCode)) {
|
|
2917
2854
|
event.stopPropagation();
|
|
2918
2855
|
}
|
|
@@ -2949,6 +2886,58 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
2949
2886
|
}]
|
|
2950
2887
|
}] });
|
|
2951
2888
|
|
|
2889
|
+
/** The max height of the select's overlay panel */
|
|
2890
|
+
const SELECT_PANEL_MAX_HEIGHT = 224;
|
|
2891
|
+
/** The panel's padding on the x-axis */
|
|
2892
|
+
const SELECT_PANEL_PADDING_X = 1;
|
|
2893
|
+
/** The panel's x axis padding if it is indented (e.g. there is an option group). */
|
|
2894
|
+
const SELECT_PANEL_INDENT_PADDING_X = SELECT_PANEL_PADDING_X * 2;
|
|
2895
|
+
/**
|
|
2896
|
+
* The select panel will only "fit" inside the viewport if it is positioned at
|
|
2897
|
+
* this value or more away from the viewport boundary.
|
|
2898
|
+
*/
|
|
2899
|
+
const SELECT_PANEL_VIEWPORT_PADDING = 8;
|
|
2900
|
+
/** Injection token that determines the scroll handling while a select is open. */
|
|
2901
|
+
const KBQ_SELECT_SCROLL_STRATEGY = new InjectionToken('kbq-select-scroll-strategy');
|
|
2902
|
+
/** @docs-private */
|
|
2903
|
+
function kbqSelectScrollStrategyProviderFactory(overlay) {
|
|
2904
|
+
return () => overlay.scrollStrategies.reposition();
|
|
2905
|
+
}
|
|
2906
|
+
/** @docs-private */
|
|
2907
|
+
const KBQ_SELECT_SCROLL_STRATEGY_PROVIDER = {
|
|
2908
|
+
provide: KBQ_SELECT_SCROLL_STRATEGY,
|
|
2909
|
+
deps: [Overlay],
|
|
2910
|
+
useFactory: kbqSelectScrollStrategyProviderFactory
|
|
2911
|
+
};
|
|
2912
|
+
|
|
2913
|
+
/**
|
|
2914
|
+
* Returns an exception to be thrown when attempting to change a select's `multiple` option
|
|
2915
|
+
* after initialization.
|
|
2916
|
+
* @docs-private
|
|
2917
|
+
*/
|
|
2918
|
+
function getKbqSelectDynamicMultipleError() {
|
|
2919
|
+
return Error('Cannot change `multiple` mode of select after initialization.');
|
|
2920
|
+
}
|
|
2921
|
+
/**
|
|
2922
|
+
* Returns an exception to be thrown when attempting to assign a non-array value to a select
|
|
2923
|
+
* in `multiple` mode. Note that `undefined` and `null` are still valid values to allow for
|
|
2924
|
+
* resetting the value.
|
|
2925
|
+
* @docs-private
|
|
2926
|
+
*/
|
|
2927
|
+
function getKbqSelectNonArrayValueError() {
|
|
2928
|
+
return Error('Value must be an array in multiple-selection mode.');
|
|
2929
|
+
}
|
|
2930
|
+
/**
|
|
2931
|
+
* Returns an exception to be thrown when assigning a non-function value to the comparator
|
|
2932
|
+
* used to determine if a value corresponds to an option. Note that whether the function
|
|
2933
|
+
* actually takes two values and returns a boolean is not checked.
|
|
2934
|
+
*/
|
|
2935
|
+
function getKbqSelectNonFunctionValueError() {
|
|
2936
|
+
return Error('`compareWith` must be a function.');
|
|
2937
|
+
}
|
|
2938
|
+
|
|
2939
|
+
const selectEvents = 'selectEvents';
|
|
2940
|
+
|
|
2952
2941
|
class KbqMeasureScrollbarService {
|
|
2953
2942
|
get scrollBarWidth() {
|
|
2954
2943
|
if (this._scrollBarWidth) {
|
|
@@ -2970,7 +2959,6 @@ class KbqMeasureScrollbarService {
|
|
|
2970
2959
|
}
|
|
2971
2960
|
initScrollBarWidth() {
|
|
2972
2961
|
const scrollDiv = this.document.createElement('div');
|
|
2973
|
-
// tslint:disable-next-line
|
|
2974
2962
|
for (const scrollProp in this.scrollbarMeasure) {
|
|
2975
2963
|
if (this.scrollbarMeasure.hasOwnProperty(scrollProp)) {
|
|
2976
2964
|
scrollDiv.style[scrollProp] = this.scrollbarMeasure[scrollProp];
|
|
@@ -3022,9 +3010,10 @@ class ThemeService {
|
|
|
3022
3010
|
}
|
|
3023
3011
|
};
|
|
3024
3012
|
this.renderer = this.rendererFactory.createRenderer(null, null);
|
|
3025
|
-
this.subscription = this.current
|
|
3026
|
-
|
|
3027
|
-
|
|
3013
|
+
this.subscription = this.current.pipe(pairwise()).subscribe(this.update);
|
|
3014
|
+
}
|
|
3015
|
+
ngOnDestroy() {
|
|
3016
|
+
this.subscription.unsubscribe();
|
|
3028
3017
|
}
|
|
3029
3018
|
setThemes(items) {
|
|
3030
3019
|
this.themes = items;
|
|
@@ -3051,11 +3040,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
3051
3040
|
args: [{ providedIn: 'root' }]
|
|
3052
3041
|
}], ctorParameters: () => [{ type: i0.RendererFactory2 }] });
|
|
3053
3042
|
|
|
3054
|
-
function isBoolean(val) { return typeof val === 'boolean'; }
|
|
3055
|
-
function toBoolean(value) {
|
|
3056
|
-
return value != null && `${value}` !== 'false';
|
|
3057
|
-
}
|
|
3058
|
-
|
|
3059
3043
|
var MeasurementSystem;
|
|
3060
3044
|
(function (MeasurementSystem) {
|
|
3061
3045
|
MeasurementSystem["SI"] = "SI";
|
|
@@ -3071,9 +3055,7 @@ const formatDataSize = (value, precision, system) => {
|
|
|
3071
3055
|
volume = result.toString();
|
|
3072
3056
|
}
|
|
3073
3057
|
else {
|
|
3074
|
-
volume = result
|
|
3075
|
-
.toFixed(precision)
|
|
3076
|
-
.replace(/\./g, ',');
|
|
3058
|
+
volume = result.toFixed(precision).replace(/\./g, ',');
|
|
3077
3059
|
}
|
|
3078
3060
|
return {
|
|
3079
3061
|
value: volume,
|
|
@@ -3091,8 +3073,7 @@ const getHumanizedBytes = (value, system, threshold) => {
|
|
|
3091
3073
|
if (!Number.isFinite(value)) {
|
|
3092
3074
|
throw new Error('Argument "value" must be number!');
|
|
3093
3075
|
}
|
|
3094
|
-
const calculatedThreshold = Number.isFinite(threshold)
|
|
3095
|
-
? threshold : Math.pow(system.base, system.power);
|
|
3076
|
+
const calculatedThreshold = Number.isFinite(threshold) ? threshold : Math.pow(system.base, system.power);
|
|
3096
3077
|
const orderOfMagnitude = Math.pow(system.base, system.power);
|
|
3097
3078
|
let result = value;
|
|
3098
3079
|
let step = 0;
|
|
@@ -3117,8 +3098,7 @@ class KbqDataSizePipe {
|
|
|
3117
3098
|
this.updateLocaleParams = () => {
|
|
3118
3099
|
this.config = this.externalConfig || this.localeService?.getParams('sizeUnits');
|
|
3119
3100
|
};
|
|
3120
|
-
this.localeService?.changes
|
|
3121
|
-
.subscribe(this.updateLocaleParams);
|
|
3101
|
+
this.localeService?.changes.subscribe(this.updateLocaleParams);
|
|
3122
3102
|
if (!localeService) {
|
|
3123
3103
|
this.config = KBQ_SIZE_UNITS_DEFAULT_CONFIG;
|
|
3124
3104
|
}
|
|
@@ -3150,11 +3130,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.2.0", ngImpor
|
|
|
3150
3130
|
args: [KBQ_LOCALE_SERVICE]
|
|
3151
3131
|
}] }] });
|
|
3152
3132
|
|
|
3133
|
+
function isBoolean(val) {
|
|
3134
|
+
return typeof val === 'boolean';
|
|
3135
|
+
}
|
|
3136
|
+
function toBoolean(value) {
|
|
3137
|
+
return value != null && `${value}` !== 'false';
|
|
3138
|
+
}
|
|
3139
|
+
|
|
3153
3140
|
const validationTooltipShowDelay = 10;
|
|
3154
3141
|
const validationTooltipHideDelay = 3000;
|
|
3155
|
-
const KBQ_VALIDATION = new InjectionToken('KbqUseValidation', {
|
|
3142
|
+
const KBQ_VALIDATION = new InjectionToken('KbqUseValidation', {
|
|
3143
|
+
factory: () => ({ useValidation: true })
|
|
3144
|
+
});
|
|
3156
3145
|
|
|
3157
|
-
const VERSION = new Version('17.0.
|
|
3146
|
+
const VERSION = new Version('17.0.1+sha-003de1d');
|
|
3158
3147
|
|
|
3159
3148
|
/**
|
|
3160
3149
|
* Generated bundle index. Do not edit.
|