@odx/angular 1.0.0-rc.1 → 1.0.0-rc.10
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/LICENSE +1 -0
- package/README.md +43 -0
- package/animations/index.d.ts +4 -2
- package/animations/{config.d.ts → lib/config.d.ts} +0 -0
- package/animations/lib/expand.d.ts +2 -0
- package/animations/{fade.d.ts → lib/fade.d.ts} +0 -0
- package/animations/{slide.d.ts → lib/slide.d.ts} +0 -0
- package/animations/lib/wait-for-child-animations.d.ts +1 -0
- package/cdk/a11y/README.md +3 -0
- package/cdk/a11y/index.d.ts +2 -0
- package/cdk/a11y/lib/a11y.module.d.ts +11 -0
- package/cdk/a11y/lib/directives/index.d.ts +3 -0
- package/cdk/a11y/lib/directives/interactive.directive.d.ts +11 -0
- package/cdk/a11y/lib/directives/list-focus-manager-option.directive.d.ts +11 -0
- package/cdk/a11y/lib/directives/list-focus-manager.directive.d.ts +12 -0
- package/cdk/active-indicator/README.md +3 -0
- package/cdk/active-indicator/index.d.ts +2 -0
- package/cdk/active-indicator/lib/active-indicator.directive.d.ts +25 -0
- package/cdk/active-indicator/lib/models/active-indicator-direction.d.ts +5 -0
- package/cdk/active-indicator/lib/models/active-indicator-position.d.ts +6 -0
- package/cdk/active-indicator/lib/models/index.d.ts +2 -0
- package/cdk/checkbox-control/README.md +3 -0
- package/cdk/checkbox-control/index.d.ts +1 -0
- package/cdk/checkbox-control/lib/checkbox-control.directive.d.ts +15 -0
- package/cdk/connected-overlay/README.md +3 -0
- package/cdk/connected-overlay/index.d.ts +3 -0
- package/cdk/connected-overlay/lib/connected-overlay.component.d.ts +28 -0
- package/cdk/connected-overlay/lib/connected-overlay.service.d.ts +10 -0
- package/cdk/connected-overlay/lib/helpers/compute-overlay-position.d.ts +3 -0
- package/cdk/connected-overlay/lib/helpers/index.d.ts +1 -0
- package/cdk/connected-overlay/lib/models/connected-overlay-options.d.ts +25 -0
- package/cdk/connected-overlay/lib/models/connected-overlay-ref.d.ts +12 -0
- package/cdk/connected-overlay/lib/models/index.d.ts +2 -0
- package/cdk/custom-form-control/README.md +3 -0
- package/cdk/custom-form-control/index.d.ts +2 -0
- package/{lib/directives → cdk/custom-form-control/lib}/control.directive.d.ts +2 -4
- package/cdk/custom-form-control/lib/custom-form-control.d.ts +32 -0
- package/cdk/dynamic-view/lib/dynamic-view.component.d.ts +4 -4
- package/cdk/dynamic-view/lib/dynamic-view.directive.d.ts +4 -2
- package/cdk/dynamic-view/lib/dynamic-view.service.d.ts +1 -0
- package/cdk/dynamic-view/lib/facade/dynamic-content.d.ts +1 -1
- package/cdk/dynamic-view/lib/facade/dynamic-view-ref.d.ts +2 -1
- package/cdk/dynamic-view/lib/facade/index.d.ts +0 -1
- package/cdk/dynamic-view/lib/helpers/create-projectable-nodes.d.ts +2 -0
- package/cdk/dynamic-view/lib/helpers/index.d.ts +1 -2
- package/cdk/dynamic-view/lib/models/dynamic-component-ref.d.ts +6 -3
- package/cdk/dynamic-view/lib/models/dynamic-template-ref.d.ts +2 -1
- package/cdk/dynamic-view/lib/models/dynamic-view-options.d.ts +7 -3
- package/cdk/dynamic-view/lib/tokens/dynamic-view-default-host.d.ts +3 -0
- package/cdk/dynamic-view/lib/tokens/index.d.ts +1 -0
- package/cdk/expandable/README.md +3 -0
- package/cdk/expandable/index.d.ts +4 -0
- package/cdk/expandable/lib/directives/expandable-item.directive.d.ts +18 -0
- package/cdk/expandable/lib/directives/extandable-container.directive.d.ts +13 -0
- package/cdk/expandable/lib/directives/index.d.ts +2 -0
- package/cdk/expandable/lib/expandable.module.d.ts +8 -0
- package/cdk/expandable/lib/expandable.tokens.d.ts +3 -0
- package/cdk/expandable/lib/facade/expandable-container.d.ts +6 -0
- package/cdk/expandable/lib/facade/expandable-item.d.ts +7 -0
- package/cdk/expandable/lib/facade/index.d.ts +2 -0
- package/cdk/radio-group-control/README.md +3 -0
- package/cdk/radio-group-control/index.d.ts +3 -0
- package/cdk/radio-group-control/lib/radio-control.directive.d.ts +13 -0
- package/cdk/radio-group-control/lib/radio-group-control.directive.d.ts +10 -0
- package/cdk/radio-group-control/lib/radio-group-control.module.d.ts +9 -0
- package/components/accordion/README.md +3 -0
- package/components/accordion/index.d.ts +4 -0
- package/components/accordion/lib/accordion.component.d.ts +7 -0
- package/components/accordion/lib/accordion.module.d.ts +10 -0
- package/components/accordion/lib/components/accordion-item/accordion-item.component.d.ts +16 -0
- package/components/accordion/lib/components/index.d.ts +1 -0
- package/components/accordion/lib/directives/accordion-item-title.d.ts +5 -0
- package/components/accordion/lib/directives/index.d.ts +1 -0
- package/components/action-group/action-group.component.d.ts +2 -4
- package/components/area-header/area-header.component.d.ts +2 -4
- package/components/area-header/area-header.module.d.ts +2 -1
- package/components/area-header/directives/area-header-content.directive.d.ts +1 -1
- package/components/area-header/directives/area-header-subtitle.directive.d.ts +1 -1
- package/components/avatar/lib/avatar.component.d.ts +4 -5
- package/components/avatar/lib/models/avatar-variant.d.ts +5 -0
- package/components/avatar/lib/models/index.d.ts +1 -0
- package/components/badge/lib/badge.component.d.ts +8 -20
- package/components/badge/lib/badge.directive.d.ts +17 -14
- package/components/badge/lib/models/index.d.ts +0 -1
- package/components/bar/README.md +3 -0
- package/components/bar/index.d.ts +5 -0
- package/components/bar/lib/bar.component.d.ts +6 -0
- package/components/bar/lib/bar.module.d.ts +10 -0
- package/components/bar/lib/directives/bar-button.directive.d.ts +10 -0
- package/components/bar/lib/directives/bar-label.directive.d.ts +6 -0
- package/components/bar/lib/models/bar-button-variant.d.ts +5 -0
- package/components/breadcrumbs/README.md +3 -0
- package/components/breadcrumbs/index.d.ts +1 -0
- package/components/breadcrumbs/lib/breadcrumbs.component.d.ts +17 -0
- package/components/button/lib/button.component.d.ts +6 -15
- package/components/button/lib/models/button-size.d.ts +5 -0
- package/components/button/lib/models/index.d.ts +1 -0
- package/components/button-group/README.md +3 -0
- package/components/button-group/index.d.ts +1 -0
- package/components/button-group/lib/button-group.component.d.ts +15 -0
- package/components/checkbox/index.d.ts +2 -0
- package/components/checkbox/lib/checkbox.component.d.ts +6 -12
- package/components/checkbox/lib/checkbox.module.d.ts +9 -0
- package/components/checkbox/lib/checkbox.validator.d.ts +6 -0
- package/components/chip/README.md +3 -0
- package/components/chip/index.d.ts +2 -0
- package/components/chip/lib/chip.component.d.ts +15 -0
- package/components/chip/lib/models/chip-size.d.ts +5 -0
- package/components/chip/lib/models/chip-variant.d.ts +7 -0
- package/components/chip/lib/models/index.d.ts +2 -0
- package/components/circular-progress/README.md +3 -0
- package/components/circular-progress/index.d.ts +2 -0
- package/components/circular-progress/lib/circular-progress.component.d.ts +29 -0
- package/components/circular-progress/lib/models/circular-progress-size.d.ts +7 -0
- package/components/circular-progress/lib/models/index.d.ts +1 -0
- package/components/content-box/lib/content-box.component.d.ts +1 -1
- package/components/content-box/lib/directives/content-box-footer-directive.d.ts +1 -1
- package/components/content-box/lib/directives/content-box-header-directive.d.ts +1 -1
- package/components/dropdown/README.md +3 -0
- package/components/dropdown/index.d.ts +5 -0
- package/components/dropdown/lib/dropdown.component.d.ts +12 -0
- package/components/dropdown/lib/dropdown.directive.d.ts +42 -0
- package/components/dropdown/lib/dropdown.module.d.ts +8 -0
- package/components/dropdown/lib/helpers/close-current-dropdown.d.ts +1 -0
- package/components/dropdown/lib/helpers/index.d.ts +1 -0
- package/components/dropdown/lib/models/close-dropdown-event.d.ts +4 -0
- package/components/dropdown/lib/models/dropdown-options.d.ts +3 -0
- package/components/dropdown/lib/models/index.d.ts +2 -0
- package/components/form-field/README.md +3 -0
- package/components/form-field/index.d.ts +6 -0
- package/components/form-field/lib/components/form-field-info/form-field-info.component.d.ts +9 -0
- package/components/form-field/lib/components/form-group/form-group.component.d.ts +13 -0
- package/components/form-field/lib/components/index.d.ts +2 -0
- package/components/form-field/lib/directives/form-field-control.directive.d.ts +21 -0
- package/components/form-field/lib/directives/form-field-error.directive.d.ts +10 -0
- package/components/form-field/lib/directives/form-field-hint.directive.d.ts +8 -0
- package/components/form-field/lib/directives/form-field-label.directive.d.ts +6 -0
- package/components/form-field/lib/directives/form.directive.d.ts +9 -0
- package/components/form-field/lib/directives/index.d.ts +5 -0
- package/components/form-field/lib/form-field.component.d.ts +19 -0
- package/components/form-field/lib/form-field.config.d.ts +14 -0
- package/components/form-field/lib/form-field.module.d.ts +18 -0
- package/components/form-field/lib/form-field.service.d.ts +30 -0
- package/components/form-field/lib/models/form-field-error-resolver.d.ts +27 -0
- package/components/form-field/lib/models/form-field-error.d.ts +7 -0
- package/components/form-field/lib/models/index.d.ts +2 -0
- package/components/form-field/lib/services/form-field-error.service.d.ts +18 -0
- package/components/form-field/lib/services/index.d.ts +1 -0
- package/components/header/lib/directives/header-avatar.directive.d.ts +5 -2
- package/components/header/lib/directives/header-title.directive.d.ts +1 -1
- package/components/header/lib/header.component.d.ts +2 -4
- package/components/header/lib/header.module.d.ts +2 -2
- package/components/icon/lib/icon.component.d.ts +9 -5
- package/components/icon/lib/models/icon-size.d.ts +2 -1
- package/components/inline-message/README.md +3 -0
- package/components/inline-message/index.d.ts +2 -0
- package/components/inline-message/lib/inline-message.component.d.ts +9 -0
- package/components/inline-message/lib/models/index.d.ts +1 -0
- package/components/inline-message/lib/models/inline-message-variant.d.ts +7 -0
- package/components/launch-tile/README.md +3 -0
- package/components/launch-tile/index.d.ts +3 -0
- package/components/launch-tile/lib/components/index.d.ts +2 -0
- package/components/launch-tile/lib/components/launch-tile-footer/launch-tile-footer.component.d.ts +5 -0
- package/components/launch-tile/lib/components/launch-tile-subtitle/launch-tile-subtitle.component.d.ts +5 -0
- package/components/launch-tile/lib/launch-tile.component.d.ts +13 -0
- package/components/launch-tile/lib/launch-tile.module.d.ts +14 -0
- package/components/link/link.directive.d.ts +3 -7
- package/components/list/README.md +3 -0
- package/components/list/index.d.ts +3 -0
- package/components/list/lib/components/index.d.ts +1 -0
- package/components/list/lib/components/list-item/list-item.component.d.ts +12 -0
- package/components/list/lib/list.component.d.ts +6 -0
- package/components/list/lib/list.module.d.ts +9 -0
- package/components/loading-spinner/README.md +3 -0
- package/components/loading-spinner/index.d.ts +3 -0
- package/components/loading-spinner/lib/loading-spinner.component.d.ts +15 -0
- package/components/loading-spinner/lib/loading-spinner.directive.d.ts +25 -0
- package/components/loading-spinner/lib/loading-spinner.module.d.ts +9 -0
- package/components/logo/logo.directive.d.ts +2 -4
- package/components/main-menu/lib/directives/main-menu-button.directive.d.ts +2 -5
- package/components/main-menu/lib/directives/main-menu-item.directive.d.ts +8 -6
- package/components/main-menu/lib/main-menu.component.d.ts +5 -5
- package/components/main-menu/lib/main-menu.module.d.ts +6 -6
- package/components/menu/README.md +3 -0
- package/components/menu/index.d.ts +4 -0
- package/components/menu/lib/directives/index.d.ts +1 -0
- package/components/menu/lib/directives/menu-item.directive.d.ts +9 -0
- package/components/menu/lib/menu.component.d.ts +8 -0
- package/components/menu/lib/menu.directive.d.ts +15 -0
- package/components/menu/lib/menu.module.d.ts +10 -0
- package/components/modal/README.md +3 -0
- package/components/modal/index.d.ts +8 -0
- package/components/modal/lib/components/basic-modal/basic-modal.component.d.ts +10 -0
- package/components/modal/lib/components/index.d.ts +4 -0
- package/components/modal/lib/components/modal-footer/modal-footer.component.d.ts +6 -0
- package/components/modal/lib/components/modal-header/modal-header.component.d.ts +12 -0
- package/components/modal/lib/components/modal-hero/modal-hero.component.d.ts +11 -0
- package/components/modal/lib/directives/index.d.ts +3 -0
- package/components/modal/lib/directives/modal-close.directive.d.ts +8 -0
- package/components/modal/lib/directives/modal-content.directive.d.ts +6 -0
- package/components/modal/lib/directives/modal-dismiss.directive.d.ts +7 -0
- package/components/modal/lib/helpers/index.d.ts +2 -0
- package/components/modal/lib/helpers/inject-modal-ref.d.ts +2 -0
- package/components/modal/lib/helpers/provide-modal-ref.d.ts +3 -0
- package/components/modal/lib/modal.component.d.ts +21 -0
- package/components/modal/lib/modal.config.d.ts +3 -0
- package/components/modal/lib/modal.directive.d.ts +18 -0
- package/components/modal/lib/modal.module.d.ts +22 -0
- package/components/modal/lib/modal.service.d.ts +23 -0
- package/components/modal/lib/models/basic-modal-options.d.ts +17 -0
- package/components/modal/lib/models/index.d.ts +7 -0
- package/components/modal/lib/models/modal-hero-variant.d.ts +7 -0
- package/components/modal/lib/models/modal-options.d.ts +15 -0
- package/components/modal/lib/models/modal-ref.d.ts +20 -0
- package/components/modal/lib/models/modal-size.d.ts +6 -0
- package/components/modal/lib/models/modal-type.d.ts +8 -0
- package/components/modal/lib/models/modal-variant.d.ts +5 -0
- package/components/progress/README.md +3 -0
- package/components/progress/index.d.ts +1 -0
- package/components/progress/lib/progress.component.d.ts +14 -0
- package/components/radio-group/lib/components/radio-button/radio-button.component.d.ts +4 -11
- package/components/radio-group/lib/radio-group.component.d.ts +4 -6
- package/components/radio-group/lib/radio-group.module.d.ts +4 -4
- package/components/rail-navigation/README.md +3 -0
- package/components/rail-navigation/index.d.ts +3 -0
- package/components/rail-navigation/lib/components/rail-navigation-item.component.d.ts +13 -0
- package/components/rail-navigation/lib/rail-navigation.component.d.ts +14 -0
- package/components/rail-navigation/lib/rail-navigation.module.d.ts +9 -0
- package/components/select/README.md +3 -0
- package/components/select/index.d.ts +7 -0
- package/components/select/lib/abstract/index.d.ts +2 -0
- package/components/select/lib/abstract/select-control-option.d.ts +7 -0
- package/components/select/lib/abstract/select-control.d.ts +11 -0
- package/components/select/lib/components/index.d.ts +1 -0
- package/components/select/lib/components/option/option.component.d.ts +22 -0
- package/components/select/lib/directives/index.d.ts +1 -0
- package/components/select/lib/directives/select-search-field.directive.d.ts +13 -0
- package/components/select/lib/pipes/index.d.ts +1 -0
- package/components/select/lib/pipes/select-search-filter.pipe.d.ts +13 -0
- package/components/select/lib/select.component.d.ts +50 -0
- package/components/select/lib/select.module.d.ts +11 -0
- package/components/select/lib/select.tokens.d.ts +3 -0
- package/components/slider/README.md +3 -0
- package/components/slider/index.d.ts +1 -0
- package/components/slider/lib/slider.directive.d.ts +12 -0
- package/components/spinbox/README.md +3 -0
- package/components/spinbox/index.d.ts +1 -0
- package/components/spinbox/lib/spinbox.component.d.ts +25 -0
- package/components/switch/README.md +3 -0
- package/components/switch/index.d.ts +3 -0
- package/components/switch/lib/switch.component.d.ts +7 -0
- package/components/switch/lib/switch.module.d.ts +9 -0
- package/components/switch/lib/switch.validator.d.ts +6 -0
- package/components/tab-bar/README.md +3 -0
- package/components/tab-bar/index.d.ts +4 -0
- package/components/tab-bar/lib/components/index.d.ts +1 -0
- package/components/tab-bar/lib/components/tab-bar-item/tab-bar-item.component.d.ts +20 -0
- package/components/tab-bar/lib/models/index.d.ts +1 -0
- package/components/tab-bar/lib/models/tab-change-event.d.ts +5 -0
- package/components/tab-bar/lib/tab-bar.component.d.ts +31 -0
- package/components/tab-bar/lib/tab-bar.config.d.ts +3 -0
- package/components/tab-bar/lib/tab-bar.module.d.ts +9 -0
- package/components/toast/README.md +3 -0
- package/components/toast/index.d.ts +5 -0
- package/components/toast/lib/components/index.d.ts +2 -0
- package/components/toast/lib/components/toast-container/toast-container.component.d.ts +23 -0
- package/components/toast/lib/components/toast-item/toast-item.component.d.ts +20 -0
- package/components/toast/lib/models/index.d.ts +5 -0
- package/components/toast/lib/models/toast-action.d.ts +7 -0
- package/components/toast/lib/models/toast-ref.d.ts +7 -0
- package/components/toast/lib/models/toast-variant.d.ts +7 -0
- package/components/toast/lib/models/toast.d.ts +10 -0
- package/components/toast/lib/models/toast.options.d.ts +4 -0
- package/components/toast/lib/toast.config.d.ts +3 -0
- package/components/toast/lib/toast.module.d.ts +13 -0
- package/components/toast/lib/toast.service.d.ts +16 -0
- package/components/toggle-button-group/README.md +3 -0
- package/components/toggle-button-group/index.d.ts +3 -0
- package/components/toggle-button-group/lib/components/index.d.ts +1 -0
- package/components/toggle-button-group/lib/components/toggle-button/toggle-button.component.d.ts +7 -0
- package/components/toggle-button-group/lib/toggle-button-group.component.d.ts +11 -0
- package/components/toggle-button-group/lib/toggle-button-group.module.d.ts +9 -0
- package/components/tooltip/README.md +3 -0
- package/components/tooltip/index.d.ts +3 -0
- package/components/tooltip/lib/helpers/index.d.ts +1 -0
- package/components/tooltip/lib/helpers/resolve-tooltip-trigger-events.d.ts +2 -0
- package/components/tooltip/lib/models/index.d.ts +3 -0
- package/components/tooltip/lib/models/tooltip-options.d.ts +10 -0
- package/components/tooltip/lib/models/tooltip-size.d.ts +7 -0
- package/components/tooltip/lib/models/tooltip-trigger.d.ts +1 -0
- package/components/tooltip/lib/tooltip.component.d.ts +12 -0
- package/components/tooltip/lib/tooltip.directive.d.ts +33 -0
- package/esm2020/animations/index.mjs +5 -3
- package/esm2020/animations/lib/config.mjs +8 -0
- package/esm2020/animations/lib/expand.mjs +14 -0
- package/esm2020/animations/lib/fade.mjs +9 -0
- package/esm2020/animations/lib/slide.mjs +34 -0
- package/esm2020/animations/lib/wait-for-child-animations.mjs +3 -0
- package/esm2020/cdk/a11y/index.mjs +3 -0
- package/esm2020/cdk/a11y/lib/a11y.module.mjs +19 -0
- package/esm2020/cdk/a11y/lib/directives/index.mjs +4 -0
- package/esm2020/cdk/a11y/lib/directives/interactive.directive.mjs +49 -0
- package/esm2020/cdk/a11y/lib/directives/list-focus-manager-option.directive.mjs +28 -0
- package/esm2020/cdk/a11y/lib/directives/list-focus-manager.directive.mjs +40 -0
- package/esm2020/cdk/a11y/odx-angular-cdk-a11y.mjs +5 -0
- package/esm2020/cdk/active-indicator/index.mjs +3 -0
- package/esm2020/cdk/active-indicator/lib/active-indicator.directive.mjs +128 -0
- package/esm2020/cdk/active-indicator/lib/models/active-indicator-direction.mjs +5 -0
- package/esm2020/cdk/active-indicator/lib/models/active-indicator-position.mjs +6 -0
- package/esm2020/cdk/active-indicator/lib/models/index.mjs +3 -0
- package/esm2020/cdk/active-indicator/odx-angular-cdk-active-indicator.mjs +5 -0
- package/esm2020/cdk/checkbox-control/index.mjs +2 -0
- package/esm2020/cdk/checkbox-control/lib/checkbox-control.directive.mjs +41 -0
- package/esm2020/cdk/checkbox-control/odx-angular-cdk-checkbox-control.mjs +5 -0
- package/esm2020/cdk/connected-overlay/index.mjs +4 -0
- package/esm2020/cdk/connected-overlay/lib/connected-overlay.component.mjs +116 -0
- package/esm2020/cdk/connected-overlay/lib/connected-overlay.service.mjs +25 -0
- package/esm2020/cdk/connected-overlay/lib/helpers/compute-overlay-position.mjs +55 -0
- package/esm2020/cdk/connected-overlay/lib/helpers/index.mjs +2 -0
- package/esm2020/cdk/connected-overlay/lib/models/connected-overlay-options.mjs +12 -0
- package/esm2020/cdk/connected-overlay/lib/models/connected-overlay-ref.mjs +15 -0
- package/esm2020/cdk/connected-overlay/lib/models/index.mjs +3 -0
- package/esm2020/cdk/connected-overlay/odx-angular-cdk-connected-overlay.mjs +5 -0
- package/esm2020/cdk/custom-form-control/index.mjs +3 -0
- package/esm2020/cdk/custom-form-control/lib/control.directive.mjs +19 -0
- package/esm2020/cdk/custom-form-control/lib/custom-form-control.mjs +94 -0
- package/esm2020/cdk/custom-form-control/odx-angular-cdk-custom-form-control.mjs +5 -0
- package/esm2020/cdk/dynamic-view/lib/dynamic-view.component.mjs +23 -14
- package/esm2020/cdk/dynamic-view/lib/dynamic-view.directive.mjs +31 -16
- package/esm2020/cdk/dynamic-view/lib/dynamic-view.service.mjs +11 -9
- package/esm2020/cdk/dynamic-view/lib/facade/dynamic-content.mjs +1 -1
- package/esm2020/cdk/dynamic-view/lib/facade/dynamic-view-ref.mjs +1 -1
- package/esm2020/cdk/dynamic-view/lib/facade/index.mjs +1 -2
- package/esm2020/cdk/dynamic-view/lib/helpers/create-projectable-nodes.mjs +9 -0
- package/esm2020/cdk/dynamic-view/lib/helpers/index.mjs +2 -3
- package/esm2020/cdk/dynamic-view/lib/helpers/is-dynamic-text-content.mjs +2 -2
- package/esm2020/cdk/dynamic-view/lib/models/dynamic-component-ref.mjs +32 -12
- package/esm2020/cdk/dynamic-view/lib/models/dynamic-template-ref.mjs +17 -7
- package/esm2020/cdk/dynamic-view/lib/models/dynamic-view-options.mjs +1 -1
- package/esm2020/cdk/dynamic-view/lib/tokens/dynamic-view-default-host.mjs +10 -0
- package/esm2020/cdk/dynamic-view/lib/tokens/index.mjs +2 -1
- package/esm2020/cdk/expandable/index.mjs +5 -0
- package/esm2020/cdk/expandable/lib/directives/expandable-item.directive.mjs +47 -0
- package/esm2020/cdk/expandable/lib/directives/extandable-container.directive.mjs +41 -0
- package/esm2020/cdk/expandable/lib/directives/index.mjs +3 -0
- package/esm2020/cdk/expandable/lib/expandable.module.mjs +17 -0
- package/esm2020/cdk/expandable/lib/expandable.tokens.mjs +3 -0
- package/esm2020/cdk/expandable/lib/facade/expandable-container.mjs +2 -0
- package/esm2020/cdk/expandable/lib/facade/expandable-item.mjs +2 -0
- package/esm2020/cdk/expandable/lib/facade/index.mjs +3 -0
- package/esm2020/cdk/expandable/odx-angular-cdk-expandable.mjs +5 -0
- package/esm2020/cdk/radio-group-control/index.mjs +4 -0
- package/esm2020/cdk/radio-group-control/lib/radio-control.directive.mjs +39 -0
- package/esm2020/cdk/radio-group-control/lib/radio-group-control.directive.mjs +43 -0
- package/esm2020/cdk/radio-group-control/lib/radio-group-control.module.mjs +19 -0
- package/esm2020/cdk/radio-group-control/odx-angular-cdk-radio-group-control.mjs +5 -0
- package/esm2020/components/accordion/index.mjs +5 -0
- package/esm2020/components/accordion/lib/accordion.component.mjs +24 -0
- package/esm2020/components/accordion/lib/accordion.module.mjs +20 -0
- package/esm2020/components/accordion/lib/components/accordion-item/accordion-item.component.mjs +56 -0
- package/esm2020/components/accordion/lib/components/index.mjs +2 -0
- package/esm2020/components/accordion/lib/directives/accordion-item-title.mjs +14 -0
- package/esm2020/components/accordion/lib/directives/index.mjs +2 -0
- package/esm2020/components/accordion/odx-angular-components-accordion.mjs +5 -0
- package/esm2020/components/action-group/action-group.component.mjs +15 -18
- package/esm2020/components/area-header/area-header.component.mjs +11 -11
- package/esm2020/components/area-header/area-header.module.mjs +9 -8
- package/esm2020/components/area-header/directives/area-header-content.directive.mjs +4 -5
- package/esm2020/components/area-header/directives/area-header-subtitle.directive.mjs +4 -5
- package/esm2020/components/avatar/lib/avatar.component.mjs +19 -11
- package/esm2020/components/avatar/lib/models/avatar-variant.mjs +5 -0
- package/esm2020/components/avatar/lib/models/index.mjs +2 -1
- package/esm2020/components/badge/lib/badge.component.mjs +20 -70
- package/esm2020/components/badge/lib/badge.directive.mjs +52 -27
- package/esm2020/components/badge/lib/models/index.mjs +1 -2
- package/esm2020/components/bar/index.mjs +6 -0
- package/esm2020/components/bar/lib/bar.component.mjs +21 -0
- package/esm2020/components/bar/lib/bar.module.mjs +20 -0
- package/esm2020/components/bar/lib/directives/bar-button.directive.mjs +39 -0
- package/esm2020/components/bar/lib/directives/bar-label.directive.mjs +24 -0
- package/esm2020/components/bar/lib/models/bar-button-variant.mjs +5 -0
- package/esm2020/components/bar/odx-angular-components-bar.mjs +5 -0
- package/esm2020/components/breadcrumbs/index.mjs +2 -0
- package/esm2020/components/breadcrumbs/lib/breadcrumbs.component.mjs +50 -0
- package/esm2020/components/breadcrumbs/odx-angular-components-breadcrumbs.mjs +5 -0
- package/esm2020/components/button/lib/button.component.mjs +24 -35
- package/esm2020/components/button/lib/models/button-size.mjs +5 -0
- package/esm2020/components/button/lib/models/index.mjs +2 -1
- package/esm2020/components/button-group/index.mjs +2 -0
- package/esm2020/components/button-group/lib/button-group.component.mjs +54 -0
- package/esm2020/components/button-group/odx-angular-components-button-group.mjs +5 -0
- package/esm2020/components/checkbox/index.mjs +3 -1
- package/esm2020/components/checkbox/lib/checkbox.component.mjs +16 -32
- package/esm2020/components/checkbox/lib/checkbox.module.mjs +19 -0
- package/esm2020/components/checkbox/lib/checkbox.validator.mjs +28 -0
- package/esm2020/components/chip/index.mjs +3 -0
- package/esm2020/components/chip/lib/chip.component.mjs +54 -0
- package/esm2020/components/chip/lib/models/chip-size.mjs +5 -0
- package/esm2020/components/chip/lib/models/chip-variant.mjs +7 -0
- package/esm2020/components/chip/lib/models/index.mjs +3 -0
- package/esm2020/components/chip/odx-angular-components-chip.mjs +5 -0
- package/esm2020/components/circular-progress/index.mjs +3 -0
- package/esm2020/components/circular-progress/lib/circular-progress.component.mjs +98 -0
- package/esm2020/components/circular-progress/lib/models/circular-progress-size.mjs +7 -0
- package/esm2020/components/circular-progress/lib/models/index.mjs +2 -0
- package/esm2020/components/circular-progress/odx-angular-components-circular-progress.mjs +5 -0
- package/esm2020/components/content-box/lib/content-box.component.mjs +3 -3
- package/esm2020/components/content-box/lib/content-box.module.mjs +4 -4
- package/esm2020/components/content-box/lib/directives/content-box-footer-directive.mjs +4 -5
- package/esm2020/components/content-box/lib/directives/content-box-header-directive.mjs +4 -5
- package/esm2020/components/dropdown/index.mjs +6 -0
- package/esm2020/components/dropdown/lib/dropdown.component.mjs +40 -0
- package/esm2020/components/dropdown/lib/dropdown.directive.mjs +156 -0
- package/esm2020/components/dropdown/lib/dropdown.module.mjs +18 -0
- package/esm2020/components/dropdown/lib/helpers/close-current-dropdown.mjs +5 -0
- package/esm2020/components/dropdown/lib/helpers/index.mjs +2 -0
- package/esm2020/components/dropdown/lib/models/close-dropdown-event.mjs +7 -0
- package/esm2020/components/dropdown/lib/models/dropdown-options.mjs +8 -0
- package/esm2020/components/dropdown/lib/models/index.mjs +3 -0
- package/esm2020/components/dropdown/odx-angular-components-dropdown.mjs +5 -0
- package/esm2020/components/form-field/index.mjs +7 -0
- package/esm2020/components/form-field/lib/components/form-field-info/form-field-info.component.mjs +24 -0
- package/esm2020/components/form-field/lib/components/form-group/form-group.component.mjs +34 -0
- package/esm2020/components/form-field/lib/components/index.mjs +3 -0
- package/esm2020/components/form-field/lib/directives/form-field-control.directive.mjs +75 -0
- package/esm2020/components/form-field/lib/directives/form-field-error.directive.mjs +25 -0
- package/esm2020/components/form-field/lib/directives/form-field-hint.directive.mjs +23 -0
- package/esm2020/components/form-field/lib/directives/form-field-label.directive.mjs +24 -0
- package/esm2020/components/form-field/lib/directives/form.directive.mjs +28 -0
- package/esm2020/components/form-field/lib/directives/index.mjs +6 -0
- package/esm2020/components/form-field/lib/form-field.component.mjs +48 -0
- package/esm2020/components/form-field/lib/form-field.config.mjs +6 -0
- package/esm2020/components/form-field/lib/form-field.module.mjs +49 -0
- package/esm2020/components/form-field/lib/form-field.service.mjs +53 -0
- package/esm2020/components/form-field/lib/models/form-field-error-resolver.mjs +2 -0
- package/esm2020/components/form-field/lib/models/form-field-error.mjs +2 -0
- package/esm2020/components/form-field/lib/models/index.mjs +3 -0
- package/esm2020/components/form-field/lib/services/form-field-error.service.mjs +56 -0
- package/esm2020/components/form-field/lib/services/index.mjs +2 -0
- package/esm2020/components/form-field/odx-angular-components-form-field.mjs +5 -0
- package/esm2020/components/header/lib/directives/header-avatar.directive.mjs +13 -6
- package/esm2020/components/header/lib/directives/header-title.directive.mjs +4 -5
- package/esm2020/components/header/lib/header.component.mjs +12 -13
- package/esm2020/components/header/lib/header.module.mjs +10 -14
- package/esm2020/components/icon/lib/icon.component.mjs +36 -12
- package/esm2020/components/icon/lib/models/icon-size.mjs +2 -1
- package/esm2020/components/inline-message/index.mjs +3 -0
- package/esm2020/components/inline-message/lib/inline-message.component.mjs +43 -0
- package/esm2020/components/inline-message/lib/models/index.mjs +2 -0
- package/esm2020/components/inline-message/lib/models/inline-message-variant.mjs +7 -0
- package/esm2020/components/inline-message/odx-angular-components-inline-message.mjs +5 -0
- package/esm2020/components/launch-tile/index.mjs +4 -0
- package/esm2020/components/launch-tile/lib/components/index.mjs +3 -0
- package/esm2020/components/launch-tile/lib/components/launch-tile-footer/launch-tile-footer.component.mjs +13 -0
- package/esm2020/components/launch-tile/lib/components/launch-tile-subtitle/launch-tile-subtitle.component.mjs +13 -0
- package/esm2020/components/launch-tile/lib/launch-tile.component.mjs +51 -0
- package/esm2020/components/launch-tile/lib/launch-tile.module.mjs +23 -0
- package/esm2020/components/launch-tile/odx-angular-components-launch-tile.mjs +5 -0
- package/esm2020/components/link/link.directive.mjs +14 -25
- package/esm2020/components/list/index.mjs +4 -0
- package/esm2020/components/list/lib/components/index.mjs +2 -0
- package/esm2020/components/list/lib/components/list-item/list-item.component.mjs +40 -0
- package/esm2020/components/list/lib/list.component.mjs +21 -0
- package/esm2020/components/list/lib/list.module.mjs +19 -0
- package/esm2020/components/list/odx-angular-components-list.mjs +5 -0
- package/esm2020/components/loading-spinner/index.mjs +4 -0
- package/esm2020/components/loading-spinner/lib/loading-spinner.component.mjs +58 -0
- package/esm2020/components/loading-spinner/lib/loading-spinner.directive.mjs +91 -0
- package/esm2020/components/loading-spinner/lib/loading-spinner.module.mjs +19 -0
- package/esm2020/components/loading-spinner/odx-angular-components-loading-spinner.mjs +5 -0
- package/esm2020/components/logo/logo.directive.mjs +10 -11
- package/esm2020/components/main-menu/lib/directives/main-menu-button.directive.mjs +12 -13
- package/esm2020/components/main-menu/lib/directives/main-menu-item.directive.mjs +25 -20
- package/esm2020/components/main-menu/lib/main-menu.component.mjs +26 -26
- package/esm2020/components/main-menu/lib/main-menu.module.mjs +7 -7
- package/esm2020/components/main-menu/lib/main-menu.service.mjs +5 -5
- package/esm2020/components/menu/index.mjs +5 -0
- package/esm2020/components/menu/lib/directives/index.mjs +2 -0
- package/esm2020/components/menu/lib/directives/menu-item.directive.mjs +39 -0
- package/esm2020/components/menu/lib/menu.component.mjs +35 -0
- package/esm2020/components/menu/lib/menu.directive.mjs +51 -0
- package/esm2020/components/menu/lib/menu.module.mjs +20 -0
- package/esm2020/components/menu/odx-angular-components-menu.mjs +5 -0
- package/esm2020/components/modal/index.mjs +9 -0
- package/esm2020/components/modal/lib/components/basic-modal/basic-modal.component.mjs +42 -0
- package/esm2020/components/modal/lib/components/index.mjs +5 -0
- package/esm2020/components/modal/lib/components/modal-footer/modal-footer.component.mjs +21 -0
- package/esm2020/components/modal/lib/components/modal-header/modal-header.component.mjs +40 -0
- package/esm2020/components/modal/lib/components/modal-hero/modal-hero.component.mjs +39 -0
- package/esm2020/components/modal/lib/directives/index.mjs +4 -0
- package/esm2020/components/modal/lib/directives/modal-close.directive.mjs +34 -0
- package/esm2020/components/modal/lib/directives/modal-content.directive.mjs +24 -0
- package/esm2020/components/modal/lib/directives/modal-dismiss.directive.mjs +24 -0
- package/esm2020/components/modal/lib/helpers/index.mjs +3 -0
- package/esm2020/components/modal/lib/helpers/inject-modal-ref.mjs +6 -0
- package/esm2020/components/modal/lib/helpers/provide-modal-ref.mjs +5 -0
- package/esm2020/components/modal/lib/modal.component.mjs +86 -0
- package/esm2020/components/modal/lib/modal.config.mjs +10 -0
- package/esm2020/components/modal/lib/modal.directive.mjs +51 -0
- package/esm2020/components/modal/lib/modal.module.mjs +58 -0
- package/esm2020/components/modal/lib/modal.service.mjs +77 -0
- package/esm2020/components/modal/lib/models/basic-modal-options.mjs +2 -0
- package/esm2020/components/modal/lib/models/index.mjs +8 -0
- package/esm2020/components/modal/lib/models/modal-hero-variant.mjs +7 -0
- package/esm2020/components/modal/lib/models/modal-options.mjs +2 -0
- package/esm2020/components/modal/lib/models/modal-ref.mjs +48 -0
- package/esm2020/components/modal/lib/models/modal-size.mjs +6 -0
- package/esm2020/components/modal/lib/models/modal-type.mjs +2 -0
- package/esm2020/components/modal/lib/models/modal-variant.mjs +5 -0
- package/esm2020/components/modal/odx-angular-components-modal.mjs +5 -0
- package/esm2020/components/progress/index.mjs +2 -0
- package/esm2020/components/progress/lib/progress.component.mjs +51 -0
- package/esm2020/components/progress/odx-angular-components-progress.mjs +5 -0
- package/esm2020/components/radio-group/lib/components/radio-button/radio-button.component.mjs +20 -40
- package/esm2020/components/radio-group/lib/radio-group.component.mjs +33 -16
- package/esm2020/components/radio-group/lib/radio-group.module.mjs +7 -7
- package/esm2020/components/rail-navigation/index.mjs +4 -0
- package/esm2020/components/rail-navigation/lib/components/rail-navigation-item.component.mjs +38 -0
- package/esm2020/components/rail-navigation/lib/rail-navigation.component.mjs +47 -0
- package/esm2020/components/rail-navigation/lib/rail-navigation.module.mjs +19 -0
- package/esm2020/components/rail-navigation/odx-angular-components-rail-navigation.mjs +5 -0
- package/esm2020/components/select/index.mjs +8 -0
- package/esm2020/components/select/lib/abstract/index.mjs +3 -0
- package/esm2020/components/select/lib/abstract/select-control-option.mjs +2 -0
- package/esm2020/components/select/lib/abstract/select-control.mjs +2 -0
- package/esm2020/components/select/lib/components/index.mjs +2 -0
- package/esm2020/components/select/lib/components/option/option.component.mjs +77 -0
- package/esm2020/components/select/lib/directives/index.mjs +2 -0
- package/esm2020/components/select/lib/directives/select-search-field.directive.mjs +47 -0
- package/esm2020/components/select/lib/pipes/index.mjs +2 -0
- package/esm2020/components/select/lib/pipes/select-search-filter.pipe.mjs +51 -0
- package/esm2020/components/select/lib/select.component.mjs +186 -0
- package/esm2020/components/select/lib/select.module.mjs +21 -0
- package/esm2020/components/select/lib/select.tokens.mjs +3 -0
- package/esm2020/components/select/odx-angular-components-select.mjs +5 -0
- package/esm2020/components/slider/index.mjs +2 -0
- package/esm2020/components/slider/lib/slider.directive.mjs +42 -0
- package/esm2020/components/slider/odx-angular-components-slider.mjs +5 -0
- package/esm2020/components/spinbox/index.mjs +2 -0
- package/esm2020/components/spinbox/lib/spinbox.component.mjs +91 -0
- package/esm2020/components/spinbox/odx-angular-components-spinbox.mjs +5 -0
- package/esm2020/components/switch/index.mjs +4 -0
- package/esm2020/components/switch/lib/switch.component.mjs +23 -0
- package/esm2020/components/switch/lib/switch.module.mjs +19 -0
- package/esm2020/components/switch/lib/switch.validator.mjs +28 -0
- package/esm2020/components/switch/odx-angular-components-switch.mjs +5 -0
- package/esm2020/components/tab-bar/index.mjs +5 -0
- package/esm2020/components/tab-bar/lib/components/index.mjs +2 -0
- package/esm2020/components/tab-bar/lib/components/tab-bar-item/tab-bar-item.component.mjs +70 -0
- package/esm2020/components/tab-bar/lib/models/index.mjs +2 -0
- package/esm2020/components/tab-bar/lib/models/tab-change-event.mjs +2 -0
- package/esm2020/components/tab-bar/lib/tab-bar.component.mjs +115 -0
- package/esm2020/components/tab-bar/lib/tab-bar.config.mjs +3 -0
- package/esm2020/components/tab-bar/lib/tab-bar.module.mjs +19 -0
- package/esm2020/components/tab-bar/odx-angular-components-tab-bar.mjs +5 -0
- package/esm2020/components/toast/index.mjs +6 -0
- package/esm2020/components/toast/lib/components/index.mjs +3 -0
- package/esm2020/components/toast/lib/components/toast-container/toast-container.component.mjs +87 -0
- package/esm2020/components/toast/lib/components/toast-item/toast-item.component.mjs +74 -0
- package/esm2020/components/toast/lib/models/index.mjs +6 -0
- package/esm2020/components/toast/lib/models/toast-action.mjs +2 -0
- package/esm2020/components/toast/lib/models/toast-ref.mjs +2 -0
- package/esm2020/components/toast/lib/models/toast-variant.mjs +7 -0
- package/esm2020/components/toast/lib/models/toast.mjs +2 -0
- package/esm2020/components/toast/lib/models/toast.options.mjs +2 -0
- package/esm2020/components/toast/lib/toast.config.mjs +6 -0
- package/esm2020/components/toast/lib/toast.module.mjs +26 -0
- package/esm2020/components/toast/lib/toast.service.mjs +38 -0
- package/esm2020/components/toast/odx-angular-components-toast.mjs +5 -0
- package/esm2020/components/toggle-button-group/index.mjs +4 -0
- package/esm2020/components/toggle-button-group/lib/components/index.mjs +2 -0
- package/esm2020/components/toggle-button-group/lib/components/toggle-button/toggle-button.component.mjs +26 -0
- package/esm2020/components/toggle-button-group/lib/toggle-button-group.component.mjs +50 -0
- package/esm2020/components/toggle-button-group/lib/toggle-button-group.module.mjs +19 -0
- package/esm2020/components/toggle-button-group/odx-angular-components-toggle-button-group.mjs +5 -0
- package/esm2020/components/tooltip/index.mjs +4 -0
- package/esm2020/components/tooltip/lib/helpers/index.mjs +2 -0
- package/esm2020/components/tooltip/lib/helpers/resolve-tooltip-trigger-events.mjs +9 -0
- package/esm2020/components/tooltip/lib/models/index.mjs +4 -0
- package/esm2020/components/tooltip/lib/models/tooltip-options.mjs +10 -0
- package/esm2020/components/tooltip/lib/models/tooltip-size.mjs +7 -0
- package/esm2020/components/tooltip/lib/models/tooltip-trigger.mjs +2 -0
- package/esm2020/components/tooltip/lib/tooltip.component.mjs +39 -0
- package/esm2020/components/tooltip/lib/tooltip.directive.mjs +132 -0
- package/esm2020/components/tooltip/odx-angular-components-tooltip.mjs +5 -0
- package/esm2020/index.mjs +2 -2
- package/esm2020/internal/decorators/css-modifier.mjs +6 -5
- package/esm2020/internal/helpers/camel-to-kebab-case.mjs +12 -0
- package/esm2020/internal/helpers/index.mjs +2 -4
- package/esm2020/internal/index.mjs +1 -4
- package/esm2020/lib/controllers/controller.mjs +39 -0
- package/esm2020/lib/controllers/disabled.controller.mjs +32 -46
- package/esm2020/lib/controllers/index.mjs +3 -1
- package/esm2020/lib/controllers/readonly.controller.mjs +69 -0
- package/esm2020/lib/core.module.mjs +11 -10
- package/esm2020/lib/directives/click-outside.directive.mjs +59 -0
- package/esm2020/lib/directives/index.mjs +5 -3
- package/esm2020/lib/directives/let.directive.mjs +36 -0
- package/esm2020/lib/directives/with-disabled-state.directive.mjs +41 -0
- package/esm2020/lib/directives/with-tabindex.directive.mjs +23 -0
- package/esm2020/lib/services/index.mjs +1 -2
- package/esm2020/lib/services/window-ref.mjs +11 -7
- package/esm2020/lib/tokens/identity-matcher.mjs +7 -0
- package/esm2020/lib/tokens/index.mjs +4 -0
- package/esm2020/lib/tokens/string-search-handler.mjs +9 -0
- package/esm2020/lib/tokens/stringify.mjs +8 -0
- package/esm2020/rxjs/index.mjs +4 -1
- package/esm2020/rxjs/lib/delay-until.mjs +5 -0
- package/esm2020/rxjs/lib/form-query-list.mjs +5 -0
- package/esm2020/rxjs/lib/from-element-resize.mjs +14 -0
- package/esm2020/utils/index.mjs +2 -1
- package/esm2020/utils/lib/decorators/index.mjs +2 -1
- package/esm2020/utils/lib/decorators/pure.mjs +37 -0
- package/esm2020/utils/lib/helpers/angular.mjs +33 -0
- package/esm2020/utils/lib/helpers/defer-fn.mjs +4 -0
- package/esm2020/utils/lib/helpers/dom.mjs +52 -0
- package/esm2020/utils/lib/helpers/event-manager.mjs +30 -0
- package/esm2020/utils/lib/helpers/get-axis.mjs +14 -0
- package/esm2020/utils/lib/helpers/get-opposite-side.mjs +15 -0
- package/esm2020/utils/lib/helpers/get-side.mjs +4 -0
- package/esm2020/utils/lib/helpers/get-unique-id.mjs +7 -0
- package/esm2020/utils/lib/helpers/index.mjs +13 -1
- package/esm2020/utils/lib/helpers/ng-changes.mjs +1 -1
- package/esm2020/utils/lib/helpers/provide-module-config.mjs +21 -0
- package/esm2020/utils/lib/helpers/queue.mjs +49 -0
- package/esm2020/utils/lib/helpers/type-guards.mjs +29 -0
- package/esm2020/utils/lib/helpers/until-destroyed.mjs +13 -0
- package/esm2020/utils/lib/types/axis.mjs +5 -0
- package/esm2020/utils/lib/types/get-properties.mjs +2 -0
- package/esm2020/utils/lib/types/index.mjs +5 -0
- package/esm2020/utils/lib/types/position.mjs +15 -0
- package/esm2020/utils/lib/types/side.mjs +7 -0
- package/fesm2015/odx-angular-animations.mjs +17 -3
- package/fesm2015/odx-angular-animations.mjs.map +1 -1
- package/fesm2015/odx-angular-cdk-a11y.mjs +132 -0
- package/fesm2015/odx-angular-cdk-a11y.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-active-indicator.mjs +145 -0
- package/fesm2015/odx-angular-cdk-active-indicator.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-checkbox-control.mjs +48 -0
- package/fesm2015/odx-angular-cdk-checkbox-control.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-connected-overlay.mjs +222 -0
- package/fesm2015/odx-angular-cdk-connected-overlay.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-custom-form-control.mjs +123 -0
- package/fesm2015/odx-angular-cdk-custom-form-control.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-dynamic-view.mjs +126 -78
- package/fesm2015/odx-angular-cdk-dynamic-view.mjs.map +1 -1
- package/fesm2015/odx-angular-cdk-expandable.mjs +108 -0
- package/fesm2015/odx-angular-cdk-expandable.mjs.map +1 -0
- package/fesm2015/odx-angular-cdk-radio-group-control.mjs +99 -0
- package/fesm2015/odx-angular-cdk-radio-group-control.mjs.map +1 -0
- package/fesm2015/odx-angular-components-accordion.mjs +106 -0
- package/fesm2015/odx-angular-components-accordion.mjs.map +1 -0
- package/fesm2015/odx-angular-components-action-group.mjs +14 -17
- package/fesm2015/odx-angular-components-action-group.mjs.map +1 -1
- package/fesm2015/odx-angular-components-area-header.mjs +24 -25
- package/fesm2015/odx-angular-components-area-header.mjs.map +1 -1
- package/fesm2015/odx-angular-components-avatar.mjs +23 -10
- package/fesm2015/odx-angular-components-avatar.mjs.map +1 -1
- package/fesm2015/odx-angular-components-badge.mjs +67 -104
- package/fesm2015/odx-angular-components-badge.mjs.map +1 -1
- package/fesm2015/odx-angular-components-bar.mjs +96 -0
- package/fesm2015/odx-angular-components-bar.mjs.map +1 -0
- package/fesm2015/odx-angular-components-breadcrumbs.mjs +56 -0
- package/fesm2015/odx-angular-components-breadcrumbs.mjs.map +1 -0
- package/fesm2015/odx-angular-components-button-group.mjs +60 -0
- package/fesm2015/odx-angular-components-button-group.mjs.map +1 -0
- package/fesm2015/odx-angular-components-button.mjs +28 -39
- package/fesm2015/odx-angular-components-button.mjs.map +1 -1
- package/fesm2015/odx-angular-components-checkbox.mjs +56 -31
- package/fesm2015/odx-angular-components-checkbox.mjs.map +1 -1
- package/fesm2015/odx-angular-components-chip.mjs +71 -0
- package/fesm2015/odx-angular-components-chip.mjs.map +1 -0
- package/fesm2015/odx-angular-components-circular-progress.mjs +110 -0
- package/fesm2015/odx-angular-components-circular-progress.mjs.map +1 -0
- package/fesm2015/odx-angular-components-content-box.mjs +13 -15
- package/fesm2015/odx-angular-components-content-box.mjs.map +1 -1
- package/fesm2015/odx-angular-components-dropdown.mjs +222 -0
- package/fesm2015/odx-angular-components-dropdown.mjs.map +1 -0
- package/fesm2015/odx-angular-components-form-field.mjs +383 -0
- package/fesm2015/odx-angular-components-form-field.mjs.map +1 -0
- package/fesm2015/odx-angular-components-header.mjs +34 -33
- package/fesm2015/odx-angular-components-header.mjs.map +1 -1
- package/fesm2015/odx-angular-components-icon.mjs +36 -11
- package/fesm2015/odx-angular-components-icon.mjs.map +1 -1
- package/fesm2015/odx-angular-components-inline-message.mjs +55 -0
- package/fesm2015/odx-angular-components-inline-message.mjs.map +1 -0
- package/fesm2015/odx-angular-components-launch-tile.mjs +95 -0
- package/fesm2015/odx-angular-components-launch-tile.mjs.map +1 -0
- package/fesm2015/odx-angular-components-link.mjs +13 -25
- package/fesm2015/odx-angular-components-link.mjs.map +1 -1
- package/fesm2015/odx-angular-components-list.mjs +76 -0
- package/fesm2015/odx-angular-components-list.mjs.map +1 -0
- package/fesm2015/odx-angular-components-loading-spinner.mjs +163 -0
- package/fesm2015/odx-angular-components-loading-spinner.mjs.map +1 -0
- package/fesm2015/odx-angular-components-logo.mjs +9 -10
- package/fesm2015/odx-angular-components-logo.mjs.map +1 -1
- package/fesm2015/odx-angular-components-main-menu.mjs +62 -61
- package/fesm2015/odx-angular-components-main-menu.mjs.map +1 -1
- package/fesm2015/odx-angular-components-menu.mjs +127 -0
- package/fesm2015/odx-angular-components-menu.mjs.map +1 -0
- package/fesm2015/odx-angular-components-modal.mjs +495 -0
- package/fesm2015/odx-angular-components-modal.mjs.map +1 -0
- package/fesm2015/odx-angular-components-progress.mjs +57 -0
- package/fesm2015/odx-angular-components-progress.mjs.map +1 -0
- package/fesm2015/odx-angular-components-radio-group.mjs +65 -69
- package/fesm2015/odx-angular-components-radio-group.mjs.map +1 -1
- package/fesm2015/odx-angular-components-rail-navigation.mjs +97 -0
- package/fesm2015/odx-angular-components-rail-navigation.mjs.map +1 -0
- package/fesm2015/odx-angular-components-select.mjs +371 -0
- package/fesm2015/odx-angular-components-select.mjs.map +1 -0
- package/fesm2015/odx-angular-components-slider.mjs +48 -0
- package/fesm2015/odx-angular-components-slider.mjs.map +1 -0
- package/fesm2015/odx-angular-components-spinbox.mjs +100 -0
- package/fesm2015/odx-angular-components-spinbox.mjs.map +1 -0
- package/fesm2015/odx-angular-components-switch.mjs +69 -0
- package/fesm2015/odx-angular-components-switch.mjs.map +1 -0
- package/fesm2015/odx-angular-components-tab-bar.mjs +200 -0
- package/fesm2015/odx-angular-components-tab-bar.mjs.map +1 -0
- package/fesm2015/odx-angular-components-toast.mjs +221 -0
- package/fesm2015/odx-angular-components-toast.mjs.map +1 -0
- package/fesm2015/odx-angular-components-toggle-button-group.mjs +87 -0
- package/fesm2015/odx-angular-components-toggle-button-group.mjs.map +1 -0
- package/fesm2015/odx-angular-components-tooltip.mjs +187 -0
- package/fesm2015/odx-angular-components-tooltip.mjs.map +1 -0
- package/fesm2015/odx-angular-internal.mjs +39 -104
- package/fesm2015/odx-angular-internal.mjs.map +1 -1
- package/fesm2015/odx-angular-rxjs.mjs +23 -2
- package/fesm2015/odx-angular-rxjs.mjs.map +1 -1
- package/fesm2015/odx-angular-utils.mjs +329 -1
- package/fesm2015/odx-angular-utils.mjs.map +1 -1
- package/fesm2015/odx-angular.mjs +296 -228
- package/fesm2015/odx-angular.mjs.map +1 -1
- package/fesm2020/odx-angular-animations.mjs +17 -6
- package/fesm2020/odx-angular-animations.mjs.map +1 -1
- package/fesm2020/odx-angular-cdk-a11y.mjs +128 -0
- package/fesm2020/odx-angular-cdk-a11y.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-active-indicator.mjs +143 -0
- package/fesm2020/odx-angular-cdk-active-indicator.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-checkbox-control.mjs +48 -0
- package/fesm2020/odx-angular-cdk-checkbox-control.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-connected-overlay.mjs +218 -0
- package/fesm2020/odx-angular-cdk-connected-overlay.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-custom-form-control.mjs +117 -0
- package/fesm2020/odx-angular-cdk-custom-form-control.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-dynamic-view.mjs +115 -57
- package/fesm2020/odx-angular-cdk-dynamic-view.mjs.map +1 -1
- package/fesm2020/odx-angular-cdk-expandable.mjs +107 -0
- package/fesm2020/odx-angular-cdk-expandable.mjs.map +1 -0
- package/fesm2020/odx-angular-cdk-radio-group-control.mjs +99 -0
- package/fesm2020/odx-angular-cdk-radio-group-control.mjs.map +1 -0
- package/fesm2020/odx-angular-components-accordion.mjs +105 -0
- package/fesm2020/odx-angular-components-accordion.mjs.map +1 -0
- package/fesm2020/odx-angular-components-action-group.mjs +14 -17
- package/fesm2020/odx-angular-components-action-group.mjs.map +1 -1
- package/fesm2020/odx-angular-components-area-header.mjs +24 -25
- package/fesm2020/odx-angular-components-area-header.mjs.map +1 -1
- package/fesm2020/odx-angular-components-avatar.mjs +23 -10
- package/fesm2020/odx-angular-components-avatar.mjs.map +1 -1
- package/fesm2020/odx-angular-components-badge.mjs +64 -97
- package/fesm2020/odx-angular-components-badge.mjs.map +1 -1
- package/fesm2020/odx-angular-components-bar.mjs +96 -0
- package/fesm2020/odx-angular-components-bar.mjs.map +1 -0
- package/fesm2020/odx-angular-components-breadcrumbs.mjs +56 -0
- package/fesm2020/odx-angular-components-breadcrumbs.mjs.map +1 -0
- package/fesm2020/odx-angular-components-button-group.mjs +60 -0
- package/fesm2020/odx-angular-components-button-group.mjs.map +1 -0
- package/fesm2020/odx-angular-components-button.mjs +28 -34
- package/fesm2020/odx-angular-components-button.mjs.map +1 -1
- package/fesm2020/odx-angular-components-checkbox.mjs +56 -31
- package/fesm2020/odx-angular-components-checkbox.mjs.map +1 -1
- package/fesm2020/odx-angular-components-chip.mjs +71 -0
- package/fesm2020/odx-angular-components-chip.mjs.map +1 -0
- package/fesm2020/odx-angular-components-circular-progress.mjs +110 -0
- package/fesm2020/odx-angular-components-circular-progress.mjs.map +1 -0
- package/fesm2020/odx-angular-components-content-box.mjs +13 -15
- package/fesm2020/odx-angular-components-content-box.mjs.map +1 -1
- package/fesm2020/odx-angular-components-dropdown.mjs +225 -0
- package/fesm2020/odx-angular-components-dropdown.mjs.map +1 -0
- package/fesm2020/odx-angular-components-form-field.mjs +380 -0
- package/fesm2020/odx-angular-components-form-field.mjs.map +1 -0
- package/fesm2020/odx-angular-components-header.mjs +34 -33
- package/fesm2020/odx-angular-components-header.mjs.map +1 -1
- package/fesm2020/odx-angular-components-icon.mjs +36 -11
- package/fesm2020/odx-angular-components-icon.mjs.map +1 -1
- package/fesm2020/odx-angular-components-inline-message.mjs +55 -0
- package/fesm2020/odx-angular-components-inline-message.mjs.map +1 -0
- package/fesm2020/odx-angular-components-launch-tile.mjs +94 -0
- package/fesm2020/odx-angular-components-launch-tile.mjs.map +1 -0
- package/fesm2020/odx-angular-components-link.mjs +13 -24
- package/fesm2020/odx-angular-components-link.mjs.map +1 -1
- package/fesm2020/odx-angular-components-list.mjs +76 -0
- package/fesm2020/odx-angular-components-list.mjs.map +1 -0
- package/fesm2020/odx-angular-components-loading-spinner.mjs +162 -0
- package/fesm2020/odx-angular-components-loading-spinner.mjs.map +1 -0
- package/fesm2020/odx-angular-components-logo.mjs +9 -10
- package/fesm2020/odx-angular-components-logo.mjs.map +1 -1
- package/fesm2020/odx-angular-components-main-menu.mjs +62 -60
- package/fesm2020/odx-angular-components-main-menu.mjs.map +1 -1
- package/fesm2020/odx-angular-components-menu.mjs +129 -0
- package/fesm2020/odx-angular-components-menu.mjs.map +1 -0
- package/fesm2020/odx-angular-components-modal.mjs +497 -0
- package/fesm2020/odx-angular-components-modal.mjs.map +1 -0
- package/fesm2020/odx-angular-components-progress.mjs +57 -0
- package/fesm2020/odx-angular-components-progress.mjs.map +1 -0
- package/fesm2020/odx-angular-components-radio-group.mjs +65 -68
- package/fesm2020/odx-angular-components-radio-group.mjs.map +1 -1
- package/fesm2020/odx-angular-components-rail-navigation.mjs +97 -0
- package/fesm2020/odx-angular-components-rail-navigation.mjs.map +1 -0
- package/fesm2020/odx-angular-components-select.mjs +358 -0
- package/fesm2020/odx-angular-components-select.mjs.map +1 -0
- package/fesm2020/odx-angular-components-slider.mjs +48 -0
- package/fesm2020/odx-angular-components-slider.mjs.map +1 -0
- package/fesm2020/odx-angular-components-spinbox.mjs +97 -0
- package/fesm2020/odx-angular-components-spinbox.mjs.map +1 -0
- package/fesm2020/odx-angular-components-switch.mjs +69 -0
- package/fesm2020/odx-angular-components-switch.mjs.map +1 -0
- package/fesm2020/odx-angular-components-tab-bar.mjs +195 -0
- package/fesm2020/odx-angular-components-tab-bar.mjs.map +1 -0
- package/fesm2020/odx-angular-components-toast.mjs +220 -0
- package/fesm2020/odx-angular-components-toast.mjs.map +1 -0
- package/fesm2020/odx-angular-components-toggle-button-group.mjs +87 -0
- package/fesm2020/odx-angular-components-toggle-button-group.mjs.map +1 -0
- package/fesm2020/odx-angular-components-tooltip.mjs +192 -0
- package/fesm2020/odx-angular-components-tooltip.mjs.map +1 -0
- package/fesm2020/odx-angular-internal.mjs +38 -102
- package/fesm2020/odx-angular-internal.mjs.map +1 -1
- package/fesm2020/odx-angular-rxjs.mjs +23 -2
- package/fesm2020/odx-angular-rxjs.mjs.map +1 -1
- package/fesm2020/odx-angular-utils.mjs +322 -1
- package/fesm2020/odx-angular-utils.mjs.map +1 -1
- package/fesm2020/odx-angular.mjs +292 -224
- package/fesm2020/odx-angular.mjs.map +1 -1
- package/index.d.ts +1 -1
- package/internal/helpers/camel-to-kebab-case.d.ts +2 -0
- package/internal/helpers/index.d.ts +1 -3
- package/internal/index.d.ts +0 -3
- package/{internal/abstract → lib/controllers}/controller.d.ts +3 -3
- package/lib/controllers/disabled.controller.d.ts +8 -11
- package/lib/controllers/index.d.ts +2 -0
- package/lib/controllers/readonly.controller.d.ts +20 -0
- package/lib/core.module.d.ts +5 -4
- package/lib/directives/click-outside.directive.d.ts +18 -0
- package/lib/directives/index.d.ts +4 -2
- package/lib/directives/let.directive.d.ts +17 -0
- package/lib/directives/with-disabled-state.directive.d.ts +13 -0
- package/lib/directives/with-tabindex.directive.d.ts +7 -0
- package/lib/services/index.d.ts +0 -1
- package/lib/services/window-ref.d.ts +2 -0
- package/lib/tokens/identity-matcher.d.ts +3 -0
- package/lib/tokens/index.d.ts +3 -0
- package/lib/tokens/string-search-handler.d.ts +3 -0
- package/lib/tokens/stringify.d.ts +3 -0
- package/package.json +265 -13
- package/rxjs/index.d.ts +3 -0
- package/rxjs/lib/delay-until.d.ts +2 -0
- package/rxjs/lib/form-query-list.d.ts +3 -0
- package/rxjs/lib/from-element-resize.d.ts +2 -0
- package/utils/index.d.ts +1 -0
- package/utils/lib/decorators/index.d.ts +1 -0
- package/utils/lib/decorators/pure.d.ts +1 -0
- package/utils/lib/helpers/angular.d.ts +6 -0
- package/utils/lib/helpers/defer-fn.d.ts +1 -0
- package/utils/lib/helpers/dom.d.ts +10 -0
- package/utils/lib/helpers/event-manager.d.ts +12 -0
- package/utils/lib/helpers/get-axis.d.ts +2 -0
- package/utils/lib/helpers/get-opposite-side.d.ts +2 -0
- package/utils/lib/helpers/get-side.d.ts +2 -0
- package/utils/lib/helpers/get-unique-id.d.ts +1 -0
- package/utils/lib/helpers/index.d.ts +12 -0
- package/utils/lib/helpers/ng-changes.d.ts +1 -1
- package/utils/lib/helpers/provide-module-config.d.ts +12 -0
- package/utils/lib/helpers/queue.d.ts +22 -0
- package/{internal → utils/lib}/helpers/type-guards.d.ts +2 -1
- package/utils/lib/helpers/until-destroyed.d.ts +2 -0
- package/utils/lib/types/axis.d.ts +5 -0
- package/{internal → utils/lib}/types/get-properties.d.ts +1 -1
- package/utils/lib/types/index.d.ts +4 -0
- package/utils/lib/types/position.d.ts +15 -0
- package/utils/lib/types/side.d.ts +7 -0
- package/cdk/dynamic-view/lib/facade/animated-component.d.ts +0 -4
- package/cdk/dynamic-view/lib/helpers/is-animated-component.d.ts +0 -3
- package/cdk/dynamic-view/lib/helpers/wait-for-animations.d.ts +0 -3
- package/components/badge/lib/badge.config.d.ts +0 -3
- package/components/badge/lib/facade/badge-host.d.ts +0 -3
- package/components/badge/lib/facade/index.d.ts +0 -1
- package/components/badge/lib/models/badge-position.d.ts +0 -5
- package/esm2020/animations/config.mjs +0 -8
- package/esm2020/animations/fade.mjs +0 -12
- package/esm2020/animations/slide.mjs +0 -34
- package/esm2020/cdk/dynamic-view/lib/facade/animated-component.mjs +0 -2
- package/esm2020/cdk/dynamic-view/lib/helpers/is-animated-component.mjs +0 -5
- package/esm2020/cdk/dynamic-view/lib/helpers/wait-for-animations.mjs +0 -9
- package/esm2020/components/badge/lib/badge.config.mjs +0 -3
- package/esm2020/components/badge/lib/facade/badge-host.mjs +0 -2
- package/esm2020/components/badge/lib/facade/index.mjs +0 -2
- package/esm2020/components/badge/lib/models/badge-position.mjs +0 -5
- package/esm2020/internal/abstract/controller.mjs +0 -29
- package/esm2020/internal/abstract/index.mjs +0 -2
- package/esm2020/internal/helpers/dom.mjs +0 -7
- package/esm2020/internal/helpers/type-guards.mjs +0 -27
- package/esm2020/internal/helpers/watch.mjs +0 -8
- package/esm2020/internal/providers/index.mjs +0 -2
- package/esm2020/internal/providers/watched-controller-provider.mjs +0 -9
- package/esm2020/internal/types/get-properties.mjs +0 -2
- package/esm2020/internal/types/index.mjs +0 -2
- package/esm2020/lib/controls/custom-form-control.mjs +0 -133
- package/esm2020/lib/controls/index.mjs +0 -2
- package/esm2020/lib/directives/control.directive.mjs +0 -18
- package/esm2020/lib/directives/monitor-focus.directive.mjs +0 -34
- package/esm2020/lib/services/destroy.service.mjs +0 -18
- package/internal/abstract/index.d.ts +0 -1
- package/internal/helpers/dom.d.ts +0 -2
- package/internal/helpers/watch.d.ts +0 -4
- package/internal/providers/index.d.ts +0 -1
- package/internal/providers/watched-controller-provider.d.ts +0 -5
- package/internal/types/index.d.ts +0 -1
- package/lib/controls/custom-form-control.d.ts +0 -40
- package/lib/controls/index.d.ts +0 -1
- package/lib/directives/monitor-focus.directive.d.ts +0 -12
- package/lib/services/destroy.service.d.ts +0 -9
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { __decorate } from 'tslib';
|
|
2
|
+
import * as i0 from '@angular/core';
|
|
3
|
+
import { Component, ViewEncapsulation, ChangeDetectionStrategy, ContentChildren, NgModule } from '@angular/core';
|
|
4
|
+
import { DisabledController, ReadonlyController, CoreModule } from '@odx/angular';
|
|
5
|
+
import { RadioControlDirective, RadioGroupControlDirective, RADIO_GROUP_CONTROL } from '@odx/angular/cdk/radio-group-control';
|
|
6
|
+
import { CSSComponent } from '@odx/angular/internal';
|
|
7
|
+
import { injectElement } from '@odx/angular/utils';
|
|
8
|
+
import * as i1 from '@angular/common';
|
|
9
|
+
import { CommonModule } from '@angular/common';
|
|
10
|
+
import { ActiveIndicatorDirective } from '@odx/angular/cdk/active-indicator';
|
|
11
|
+
import { defer, merge, startWith, map, tap } from 'rxjs';
|
|
12
|
+
|
|
13
|
+
let ToggleButtonComponent = class ToggleButtonComponent extends RadioControlDirective {
|
|
14
|
+
constructor() {
|
|
15
|
+
super(...arguments);
|
|
16
|
+
this.element = injectElement();
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
ToggleButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
20
|
+
ToggleButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: ToggleButtonComponent, isStandalone: true, selector: "odx-toggle-button", host: { attributes: { "role": "button" } }, providers: [DisabledController.connect(), ReadonlyController.connect()], usesInheritance: true, ngImport: i0, template: "<label class=\"odx-toggle-button__label\">\n <input\n class=\"odx-radio-button__input\"\n type=\"radio\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"radioGroupControl.hasError || null\"\n [attr.aria-readonly]=\"readonlyController?.readonly || null\"\n [attr.aria-required]=\"radioGroupControl.isRequired || null\"\n [checked]=\"isActive\"\n [disabled]=\"disabledController?.disabled || readonlyController?.readonly\"\n [name]=\"radioGroupControl.name\"\n [readonly]=\"readonlyController?.readonly\"\n [required]=\"radioGroupControl.isRequired\"\n [value]=\"value\"\n (change)=\"radioGroupControl.updateValue(value)\"\n />\n <ng-content></ng-content>\n</label>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
21
|
+
ToggleButtonComponent = __decorate([
|
|
22
|
+
CSSComponent('toggle-button')
|
|
23
|
+
], ToggleButtonComponent);
|
|
24
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonComponent, decorators: [{
|
|
25
|
+
type: Component,
|
|
26
|
+
args: [{ standalone: true, selector: 'odx-toggle-button', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [DisabledController.connect(), ReadonlyController.connect()], host: {
|
|
27
|
+
role: 'button',
|
|
28
|
+
}, template: "<label class=\"odx-toggle-button__label\">\n <input\n class=\"odx-radio-button__input\"\n type=\"radio\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"radioGroupControl.hasError || null\"\n [attr.aria-readonly]=\"readonlyController?.readonly || null\"\n [attr.aria-required]=\"radioGroupControl.isRequired || null\"\n [checked]=\"isActive\"\n [disabled]=\"disabledController?.disabled || readonlyController?.readonly\"\n [name]=\"radioGroupControl.name\"\n [readonly]=\"readonlyController?.readonly\"\n [required]=\"radioGroupControl.isRequired\"\n [value]=\"value\"\n (change)=\"radioGroupControl.updateValue(value)\"\n />\n <ng-content></ng-content>\n</label>\n" }]
|
|
29
|
+
}] });
|
|
30
|
+
|
|
31
|
+
var ToggleButtonGroupComponent_1;
|
|
32
|
+
let ToggleButtonGroupComponent = ToggleButtonGroupComponent_1 = class ToggleButtonGroupComponent extends RadioGroupControlDirective {
|
|
33
|
+
constructor() {
|
|
34
|
+
super(...arguments);
|
|
35
|
+
this.activeElement$ = defer(() => merge(this.toggleButtons.changes, this.change$)).pipe(startWith(undefined), map(() => this.toggleButtons.find((button) => button.isActive)?.element.nativeElement ?? null), tap((activeElement) => this.element.nativeElement.classList.toggle('is-active', !!activeElement)));
|
|
36
|
+
this.element = injectElement();
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
ToggleButtonGroupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
40
|
+
ToggleButtonGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: ToggleButtonGroupComponent, isStandalone: true, selector: "odx-toggle-button-group", providers: [
|
|
41
|
+
{
|
|
42
|
+
provide: RADIO_GROUP_CONTROL,
|
|
43
|
+
useExisting: ToggleButtonGroupComponent_1,
|
|
44
|
+
multi: false,
|
|
45
|
+
},
|
|
46
|
+
DisabledController.connect(),
|
|
47
|
+
ReadonlyController.connect(),
|
|
48
|
+
], queries: [{ propertyName: "toggleButtons", predicate: ToggleButtonComponent }], usesInheritance: true, ngImport: i0, template: "<ng-content select=\"odx-toggle-button\"> </ng-content>\n<div class=\"odx-toggle-button-group__indicator\" [odxActiveIndicator]=\"activeElement$ | async\"></div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i1.AsyncPipe, name: "async" }, { kind: "directive", type: ActiveIndicatorDirective, selector: "[odxActiveIndicator]", inputs: ["odxActiveIndicator", "odxActiveIndicatorParent", "odxActiveIndicatorDirection", "odxActiveIndicatorPosition"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
49
|
+
ToggleButtonGroupComponent = ToggleButtonGroupComponent_1 = __decorate([
|
|
50
|
+
CSSComponent('toggle-button-group')
|
|
51
|
+
], ToggleButtonGroupComponent);
|
|
52
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupComponent, decorators: [{
|
|
53
|
+
type: Component,
|
|
54
|
+
args: [{ standalone: true, selector: 'odx-toggle-button-group', imports: [CommonModule, ActiveIndicatorDirective], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [
|
|
55
|
+
{
|
|
56
|
+
provide: RADIO_GROUP_CONTROL,
|
|
57
|
+
useExisting: ToggleButtonGroupComponent,
|
|
58
|
+
multi: false,
|
|
59
|
+
},
|
|
60
|
+
DisabledController.connect(),
|
|
61
|
+
ReadonlyController.connect(),
|
|
62
|
+
], template: "<ng-content select=\"odx-toggle-button\"> </ng-content>\n<div class=\"odx-toggle-button-group__indicator\" [odxActiveIndicator]=\"activeElement$ | async\"></div>\n" }]
|
|
63
|
+
}], propDecorators: { toggleButtons: [{
|
|
64
|
+
type: ContentChildren,
|
|
65
|
+
args: [ToggleButtonComponent]
|
|
66
|
+
}] } });
|
|
67
|
+
|
|
68
|
+
const modules = [ToggleButtonGroupComponent, ToggleButtonComponent];
|
|
69
|
+
class ToggleButtonGroupModule {
|
|
70
|
+
}
|
|
71
|
+
ToggleButtonGroupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
72
|
+
ToggleButtonGroupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupModule, imports: [ToggleButtonGroupComponent, ToggleButtonComponent], exports: [CoreModule, ToggleButtonGroupComponent, ToggleButtonComponent] });
|
|
73
|
+
ToggleButtonGroupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupModule, imports: [modules, CoreModule] });
|
|
74
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: ToggleButtonGroupModule, decorators: [{
|
|
75
|
+
type: NgModule,
|
|
76
|
+
args: [{
|
|
77
|
+
imports: modules,
|
|
78
|
+
exports: [CoreModule, ...modules],
|
|
79
|
+
}]
|
|
80
|
+
}] });
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* Generated bundle index. Do not edit.
|
|
84
|
+
*/
|
|
85
|
+
|
|
86
|
+
export { ToggleButtonComponent, ToggleButtonGroupComponent, ToggleButtonGroupModule };
|
|
87
|
+
//# sourceMappingURL=odx-angular-components-toggle-button-group.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"odx-angular-components-toggle-button-group.mjs","sources":["../../../../libs/angular/components/toggle-button-group/src/lib/components/toggle-button/toggle-button.component.ts","../../../../libs/angular/components/toggle-button-group/src/lib/components/toggle-button/toggle-button.component.html","../../../../libs/angular/components/toggle-button-group/src/lib/toggle-button-group.component.ts","../../../../libs/angular/components/toggle-button-group/src/lib/toggle-button-group.component.html","../../../../libs/angular/components/toggle-button-group/src/lib/toggle-button-group.module.ts","../../../../libs/angular/components/toggle-button-group/src/odx-angular-components-toggle-button-group.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, ViewEncapsulation } from '@angular/core';\nimport { DisabledController, ReadonlyController } from '@odx/angular';\nimport { RadioControlDirective } from '@odx/angular/cdk/radio-group-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\n\n@CSSComponent('toggle-button')\n@Component({\n standalone: true,\n selector: 'odx-toggle-button',\n templateUrl: './toggle-button.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [DisabledController.connect(), ReadonlyController.connect()],\n host: {\n role: 'button',\n },\n})\nexport class ToggleButtonComponent<T = unknown> extends RadioControlDirective<T> {\n public readonly element = injectElement();\n}\n","<label class=\"odx-toggle-button__label\">\n <input\n class=\"odx-radio-button__input\"\n type=\"radio\"\n [attr.aria-checked]=\"ariaChecked\"\n [attr.aria-invalid]=\"radioGroupControl.hasError || null\"\n [attr.aria-readonly]=\"readonlyController?.readonly || null\"\n [attr.aria-required]=\"radioGroupControl.isRequired || null\"\n [checked]=\"isActive\"\n [disabled]=\"disabledController?.disabled || readonlyController?.readonly\"\n [name]=\"radioGroupControl.name\"\n [readonly]=\"readonlyController?.readonly\"\n [required]=\"radioGroupControl.isRequired\"\n [value]=\"value\"\n (change)=\"radioGroupControl.updateValue(value)\"\n />\n <ng-content></ng-content>\n</label>\n","import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ContentChildren, QueryList, ViewEncapsulation } from '@angular/core';\nimport { DisabledController, ReadonlyController } from '@odx/angular';\nimport { ActiveIndicatorDirective } from '@odx/angular/cdk/active-indicator';\nimport { RadioGroupControlDirective, RADIO_GROUP_CONTROL } from '@odx/angular/cdk/radio-group-control';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { injectElement } from '@odx/angular/utils';\nimport { defer, map, merge, startWith, tap } from 'rxjs';\nimport { ToggleButtonComponent } from './components';\n\n@CSSComponent('toggle-button-group')\n@Component({\n standalone: true,\n selector: 'odx-toggle-button-group',\n imports: [CommonModule, ActiveIndicatorDirective],\n templateUrl: './toggle-button-group.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n {\n provide: RADIO_GROUP_CONTROL,\n useExisting: ToggleButtonGroupComponent,\n multi: false,\n },\n DisabledController.connect(),\n ReadonlyController.connect(),\n ],\n})\nexport class ToggleButtonGroupComponent<T = unknown> extends RadioGroupControlDirective<T> {\n protected activeElement$ = defer(() => merge(this.toggleButtons.changes, this.change$)).pipe(\n startWith(undefined),\n map(() => this.toggleButtons.find((button) => button.isActive)?.element.nativeElement ?? null),\n tap((activeElement) => this.element.nativeElement.classList.toggle('is-active', !!activeElement))\n );\n\n @ContentChildren(ToggleButtonComponent)\n protected toggleButtons!: QueryList<ToggleButtonComponent>;\n\n public readonly element = injectElement();\n}\n","<ng-content select=\"odx-toggle-button\"> </ng-content>\n<div class=\"odx-toggle-button-group__indicator\" [odxActiveIndicator]=\"activeElement$ | async\"></div>\n","import { NgModule } from '@angular/core';\nimport { CoreModule } from '@odx/angular';\nimport { ToggleButtonComponent } from './components';\nimport { ToggleButtonGroupComponent } from './toggle-button-group.component';\n\nconst modules = [ToggleButtonGroupComponent, ToggleButtonComponent];\n\n@NgModule({\n imports: modules,\n exports: [CoreModule, ...modules],\n})\nexport class ToggleButtonGroupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAkBO,IAAM,qBAAqB,GAA3B,MAAM,qBAAmC,SAAQ,qBAAwB,CAAA;AAAzE,IAAA,WAAA,GAAA;;QACW,IAAO,CAAA,OAAA,GAAG,aAAa,EAAE,CAAC;AAC3C,KAAA;;kHAFY,qBAAqB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAArB,qBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,qBAAqB,EALrB,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,mBAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,MAAA,EAAA,QAAA,EAAA,EAAA,EAAA,SAAA,EAAA,CAAC,kBAAkB,CAAC,OAAO,EAAE,EAAE,kBAAkB,CAAC,OAAO,EAAE,CAAC,iDCbzE,mtBAkBA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,aAAA,EAAA,EAAA,CAAA,iBAAA,CAAA,IAAA,EAAA,CAAA,CAAA;ADAa,qBAAqB,GAAA,UAAA,CAAA;IAZjC,YAAY,CAAC,eAAe,CAAC;AAYjB,CAAA,EAAA,qBAAqB,CAEjC,CAAA;2FAFY,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAXjC,SAAS;iCACI,IAAI,EAAA,QAAA,EACN,mBAAmB,EAEd,aAAA,EAAA,iBAAiB,CAAC,IAAI,EAAA,eAAA,EACpB,uBAAuB,CAAC,MAAM,EAAA,SAAA,EACpC,CAAC,kBA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AAC,qBAAqB,CAAA;;;AE9BxC,MAAM,OAAO,GAAG,CAAC,0BAA0B,EAAE,qBAAqB,CAAC,CAAC;MAMvD,uBAAuB,CAAA;;oHAAvB,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;qHAAvB,uBAAuB,EAAA,OAAA,EAAA,CANnB,0BAA0B,EAAE,qBAAqB,aAItD,UAAU,EAJL,0BAA0B,EAAE,qBAAqB,CAAA,EAAA,CAAA,CAAA;qHAMrD,uBAAuB,EAAA,OAAA,EAAA,CAHzB,OAAO,EACN,UAAU,CAAA,EAAA,CAAA,CAAA;2FAET,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAJnC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,OAAO;AAChB,oBAAA,OAAO,EAAE,CAAC,UAAU,EAAE,GAAG,OAAO,CAAC;AAClC,iBAAA,CAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -0,0 +1,192 @@
|
|
|
1
|
+
import { __decorate, __metadata } from 'tslib';
|
|
2
|
+
import { coerceBooleanProperty } from '@angular/cdk/coercion';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Component, ViewEncapsulation, ChangeDetectionStrategy, Input, inject, Directive } from '@angular/core';
|
|
5
|
+
import { ConnectedOverlayService } from '@odx/angular/cdk/connected-overlay';
|
|
6
|
+
import { CSSModifier, CSSComponent } from '@odx/angular/internal';
|
|
7
|
+
import { delayUntil } from '@odx/angular/rxjs';
|
|
8
|
+
import { getInjector, injectElement, EventManager, untilDestroyed, hasChanged, Transform } from '@odx/angular/utils';
|
|
9
|
+
import { deepmerge } from 'deepmerge-ts';
|
|
10
|
+
import { Subject, filter, tap, merge } from 'rxjs';
|
|
11
|
+
import { DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';
|
|
12
|
+
|
|
13
|
+
function resolveTooltipTriggerEvents(trigger) {
|
|
14
|
+
if (trigger === 'click') {
|
|
15
|
+
return ['click', null];
|
|
16
|
+
}
|
|
17
|
+
else {
|
|
18
|
+
return ['mouseenter', 'mouseleave'];
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const TooltipSize = {
|
|
23
|
+
AUTO: 'auto',
|
|
24
|
+
SMALL: 'small',
|
|
25
|
+
MEDIUM: 'medium',
|
|
26
|
+
LARGE: 'large',
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
const DefaultTooltipOptions = {
|
|
30
|
+
matchReferenceWidth: false,
|
|
31
|
+
size: TooltipSize.AUTO,
|
|
32
|
+
trigger: 'hover',
|
|
33
|
+
position: 'top',
|
|
34
|
+
delayIn: 0,
|
|
35
|
+
delayOut: 0,
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
let TooltipComponent = class TooltipComponent {
|
|
39
|
+
constructor() {
|
|
40
|
+
this.injector = getInjector();
|
|
41
|
+
this.element = injectElement();
|
|
42
|
+
this.id = null;
|
|
43
|
+
this.size = TooltipSize.AUTO;
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
TooltipComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TooltipComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
47
|
+
TooltipComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: TooltipComponent, isStandalone: true, selector: "odx-tooltip", inputs: { id: "id", content: "content", size: "size" }, host: { attributes: { "role": "tooltip" }, properties: { "attr.id": "id" } }, ngImport: i0, template: "<ng-template [odxDynamicView]=\"content\" [odxDynamicViewInjector]=\"injector\"></ng-template>\n", dependencies: [{ kind: "directive", type: DynamicViewDirective, selector: "ng-template[odxDynamicView]", inputs: ["odxDynamicView", "odxDynamicViewInjector", "odxDynamicViewContext"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
48
|
+
__decorate([
|
|
49
|
+
CSSModifier(),
|
|
50
|
+
__metadata("design:type", String)
|
|
51
|
+
], TooltipComponent.prototype, "size", void 0);
|
|
52
|
+
TooltipComponent = __decorate([
|
|
53
|
+
CSSComponent('tooltip')
|
|
54
|
+
], TooltipComponent);
|
|
55
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TooltipComponent, decorators: [{
|
|
56
|
+
type: Component,
|
|
57
|
+
args: [{ standalone: true, selector: 'odx-tooltip', imports: [DynamicViewDirective], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
58
|
+
'[attr.id]': 'id',
|
|
59
|
+
role: 'tooltip',
|
|
60
|
+
}, template: "<ng-template [odxDynamicView]=\"content\" [odxDynamicViewInjector]=\"injector\"></ng-template>\n" }]
|
|
61
|
+
}], propDecorators: { id: [{
|
|
62
|
+
type: Input
|
|
63
|
+
}], content: [{
|
|
64
|
+
type: Input
|
|
65
|
+
}], size: [{
|
|
66
|
+
type: Input
|
|
67
|
+
}] } });
|
|
68
|
+
|
|
69
|
+
var TooltipDirective_1;
|
|
70
|
+
let TooltipDirective = TooltipDirective_1 = class TooltipDirective {
|
|
71
|
+
constructor() {
|
|
72
|
+
this.eventManager = inject(EventManager);
|
|
73
|
+
this.connectedOverlayService = inject(ConnectedOverlayService);
|
|
74
|
+
this.showTrigger$$ = new Subject();
|
|
75
|
+
this.hideTrigger$$ = new Subject();
|
|
76
|
+
this.connectedOverlayRef = null;
|
|
77
|
+
this.tooltipOptions = DefaultTooltipOptions;
|
|
78
|
+
this.tooltipId = null;
|
|
79
|
+
this.element = injectElement();
|
|
80
|
+
this.content = null;
|
|
81
|
+
this.disabled = false;
|
|
82
|
+
this.size = null;
|
|
83
|
+
this.visible = false;
|
|
84
|
+
const takeUntilDestroyed = untilDestroyed();
|
|
85
|
+
const show$ = this.showTrigger$$.pipe(filter(() => !this.isOpen), delayUntil(() => this.tooltipOptions.delayIn, this.hideTrigger$$), tap(() => this.show()));
|
|
86
|
+
const hide$ = this.hideTrigger$$.pipe(filter(() => this.isOpen), delayUntil(() => this.tooltipOptions.delayOut, this.showTrigger$$), tap(() => this.hide()));
|
|
87
|
+
merge(show$, hide$).pipe(takeUntilDestroyed()).subscribe();
|
|
88
|
+
}
|
|
89
|
+
set options(value) {
|
|
90
|
+
this.tooltipOptions = deepmerge(DefaultTooltipOptions, value);
|
|
91
|
+
}
|
|
92
|
+
get isOpen() {
|
|
93
|
+
return this.connectedOverlayRef !== null;
|
|
94
|
+
}
|
|
95
|
+
ngOnInit() {
|
|
96
|
+
this.registerEvents();
|
|
97
|
+
}
|
|
98
|
+
ngOnChanges(changes) {
|
|
99
|
+
if (hasChanged(changes, 'disabled') && this.disabled) {
|
|
100
|
+
this.hide();
|
|
101
|
+
}
|
|
102
|
+
if (hasChanged(changes, ['content', 'size'])) {
|
|
103
|
+
this.connectedOverlayRef?.update({ context: { content: this.content, size: this.size } });
|
|
104
|
+
}
|
|
105
|
+
if (hasChanged(changes, 'options')) {
|
|
106
|
+
this.connectedOverlayRef?.update(this.tooltipOptions);
|
|
107
|
+
this.registerEvents();
|
|
108
|
+
}
|
|
109
|
+
if (this.visible && !this.disabled) {
|
|
110
|
+
this.show();
|
|
111
|
+
}
|
|
112
|
+
else {
|
|
113
|
+
this.hide();
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
show() {
|
|
117
|
+
if (this.isOpen || this.disabled)
|
|
118
|
+
return;
|
|
119
|
+
this.tooltipId = `odx-tooltip-${TooltipDirective_1.ID++}`;
|
|
120
|
+
this.connectedOverlayRef = this.connectedOverlayService.createOverlay(this.element.nativeElement, {
|
|
121
|
+
...this.tooltipOptions,
|
|
122
|
+
containerClass: 'odx-tooltip-overlay',
|
|
123
|
+
content: TooltipComponent,
|
|
124
|
+
context: { content: this.content, size: this.size, id: this.tooltipId },
|
|
125
|
+
showArrow: true,
|
|
126
|
+
enableFallback: true,
|
|
127
|
+
});
|
|
128
|
+
}
|
|
129
|
+
hide() {
|
|
130
|
+
if (!this.isOpen || (this.visible && !this.disabled))
|
|
131
|
+
return;
|
|
132
|
+
this.connectedOverlayRef?.close();
|
|
133
|
+
this.connectedOverlayRef = null;
|
|
134
|
+
this.tooltipId = null;
|
|
135
|
+
}
|
|
136
|
+
registerEvents() {
|
|
137
|
+
const [openEvent, closeEvent] = resolveTooltipTriggerEvents(this.tooltipOptions.trigger);
|
|
138
|
+
this.eventManager.destroyListeners();
|
|
139
|
+
this.eventManager.register([openEvent, 'focusin'], () => this.showTrigger$$.next());
|
|
140
|
+
this.eventManager.register([closeEvent, 'focusout'], () => this.hideTrigger$$.next());
|
|
141
|
+
this.eventManager.register(['keyup.esc'], () => this.hideTrigger$$.next(), 'document');
|
|
142
|
+
}
|
|
143
|
+
};
|
|
144
|
+
TooltipDirective.ID = 0;
|
|
145
|
+
TooltipDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TooltipDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
146
|
+
TooltipDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.1.5", type: TooltipDirective, isStandalone: true, selector: "[odxTooltip]", inputs: { content: ["odxTooltip", "content"], disabled: ["odxTooltipDisabled", "disabled"], options: ["odxTooltipOptions", "options"], size: ["odxTooltipSize", "size"], visible: ["odxTooltipVisible", "visible"] }, host: { properties: { "attr.aria-describedby": "tooltipId" } }, providers: [EventManager], exportAs: ["odxTooltip"], usesOnChanges: true, ngImport: i0 });
|
|
147
|
+
__decorate([
|
|
148
|
+
Transform(coerceBooleanProperty),
|
|
149
|
+
__metadata("design:type", Object)
|
|
150
|
+
], TooltipDirective.prototype, "disabled", void 0);
|
|
151
|
+
__decorate([
|
|
152
|
+
Transform(coerceBooleanProperty),
|
|
153
|
+
__metadata("design:type", Object)
|
|
154
|
+
], TooltipDirective.prototype, "visible", void 0);
|
|
155
|
+
TooltipDirective = TooltipDirective_1 = __decorate([
|
|
156
|
+
CSSComponent('tooltip-host'),
|
|
157
|
+
__metadata("design:paramtypes", [])
|
|
158
|
+
], TooltipDirective);
|
|
159
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: TooltipDirective, decorators: [{
|
|
160
|
+
type: Directive,
|
|
161
|
+
args: [{
|
|
162
|
+
standalone: true,
|
|
163
|
+
selector: '[odxTooltip]',
|
|
164
|
+
exportAs: 'odxTooltip',
|
|
165
|
+
providers: [EventManager],
|
|
166
|
+
host: {
|
|
167
|
+
'[attr.aria-describedby]': 'tooltipId',
|
|
168
|
+
},
|
|
169
|
+
}]
|
|
170
|
+
}], ctorParameters: function () { return []; }, propDecorators: { content: [{
|
|
171
|
+
type: Input,
|
|
172
|
+
args: ['odxTooltip']
|
|
173
|
+
}], disabled: [{
|
|
174
|
+
type: Input,
|
|
175
|
+
args: ['odxTooltipDisabled']
|
|
176
|
+
}], options: [{
|
|
177
|
+
type: Input,
|
|
178
|
+
args: ['odxTooltipOptions']
|
|
179
|
+
}], size: [{
|
|
180
|
+
type: Input,
|
|
181
|
+
args: ['odxTooltipSize']
|
|
182
|
+
}], visible: [{
|
|
183
|
+
type: Input,
|
|
184
|
+
args: ['odxTooltipVisible']
|
|
185
|
+
}] } });
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* Generated bundle index. Do not edit.
|
|
189
|
+
*/
|
|
190
|
+
|
|
191
|
+
export { DefaultTooltipOptions, TooltipDirective, TooltipSize, resolveTooltipTriggerEvents };
|
|
192
|
+
//# sourceMappingURL=odx-angular-components-tooltip.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"odx-angular-components-tooltip.mjs","sources":["../../../../libs/angular/components/tooltip/src/lib/helpers/resolve-tooltip-trigger-events.ts","../../../../libs/angular/components/tooltip/src/lib/models/tooltip-size.ts","../../../../libs/angular/components/tooltip/src/lib/models/tooltip-options.ts","../../../../libs/angular/components/tooltip/src/lib/tooltip.component.ts","../../../../libs/angular/components/tooltip/src/lib/tooltip.component.html","../../../../libs/angular/components/tooltip/src/lib/tooltip.directive.ts","../../../../libs/angular/components/tooltip/src/odx-angular-components-tooltip.ts"],"sourcesContent":["import { TooltipTrigger } from '../models';\n\nexport function resolveTooltipTriggerEvents(trigger: TooltipTrigger): [string, string | null] {\n if (trigger === 'click') {\n return ['click', null];\n } else {\n return ['mouseenter', 'mouseleave'];\n }\n}\n","export type TooltipSize = typeof TooltipSize[keyof typeof TooltipSize];\n\nexport const TooltipSize = {\n AUTO: 'auto',\n SMALL: 'small',\n MEDIUM: 'medium',\n LARGE: 'large',\n} as const;\n","import { ConnectedOverlayOptions } from '@odx/angular/cdk/connected-overlay';\nimport { TooltipSize } from './tooltip-size';\nimport { TooltipTrigger } from './tooltip-trigger';\n\nexport interface TooltipOptions extends Pick<ConnectedOverlayOptions, 'position' | 'matchReferenceWidth'> {\n trigger: TooltipTrigger;\n delayIn: number;\n delayOut: number;\n size: TooltipSize;\n}\n\nexport const DefaultTooltipOptions: TooltipOptions = {\n matchReferenceWidth: false,\n size: TooltipSize.AUTO,\n trigger: 'hover',\n position: 'top',\n delayIn: 0,\n delayOut: 0,\n};\n","import { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from '@angular/core';\nimport { DynamicTextContent, DynamicViewDirective } from '@odx/angular/cdk/dynamic-view';\nimport { CSSComponent, CSSModifier } from '@odx/angular/internal';\nimport { getInjector, injectElement } from '@odx/angular/utils';\nimport { TooltipSize } from './models';\n\n@CSSComponent('tooltip')\n@Component({\n standalone: true,\n selector: 'odx-tooltip',\n imports: [DynamicViewDirective],\n templateUrl: './tooltip.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n host: {\n '[attr.id]': 'id',\n role: 'tooltip',\n },\n})\nexport class TooltipComponent {\n protected readonly injector = getInjector();\n public readonly element = injectElement();\n\n @Input()\n public id: string | null = null;\n\n @Input()\n public content?: DynamicTextContent | null;\n\n @CSSModifier()\n @Input()\n public size: TooltipSize = TooltipSize.AUTO;\n}\n","<ng-template [odxDynamicView]=\"content\" [odxDynamicViewInjector]=\"injector\"></ng-template>\n","import { BooleanInput, coerceBooleanProperty } from '@angular/cdk/coercion';\nimport { Directive, inject, Input, OnChanges, OnInit } from '@angular/core';\nimport { ConnectedOverlayRef, ConnectedOverlayService } from '@odx/angular/cdk/connected-overlay';\nimport { DynamicTextContent } from '@odx/angular/cdk/dynamic-view';\nimport { CSSComponent } from '@odx/angular/internal';\nimport { delayUntil } from '@odx/angular/rxjs';\nimport { EventManager, hasChanged, injectElement, NgChanges, Transform, untilDestroyed } from '@odx/angular/utils';\nimport { deepmerge } from 'deepmerge-ts';\nimport { filter, merge, Subject, tap } from 'rxjs';\nimport { resolveTooltipTriggerEvents } from './helpers';\nimport { DefaultTooltipOptions, TooltipOptions, TooltipSize } from './models';\nimport { TooltipComponent } from './tooltip.component';\n\n@CSSComponent('tooltip-host')\n@Directive({\n standalone: true,\n selector: '[odxTooltip]',\n exportAs: 'odxTooltip',\n providers: [EventManager],\n host: {\n '[attr.aria-describedby]': 'tooltipId',\n },\n})\nexport class TooltipDirective implements OnInit, OnChanges {\n private static ID = 0;\n\n public static ngAcceptInputType_disabled: BooleanInput;\n public static ngAcceptInputType_visible: BooleanInput;\n\n private readonly eventManager = inject(EventManager);\n private readonly connectedOverlayService = inject(ConnectedOverlayService);\n private readonly showTrigger$$ = new Subject<void>();\n private readonly hideTrigger$$ = new Subject<void>();\n private connectedOverlayRef: ConnectedOverlayRef | null = null;\n private tooltipOptions = DefaultTooltipOptions;\n\n protected tooltipId: string | null = null;\n public readonly element = injectElement();\n\n @Input('odxTooltip')\n public content?: DynamicTextContent | null = null;\n\n @Transform(coerceBooleanProperty)\n @Input('odxTooltipDisabled')\n public disabled = false;\n\n @Input('odxTooltipOptions')\n public set options(value: Partial<TooltipOptions> | null | undefined) {\n this.tooltipOptions = deepmerge(DefaultTooltipOptions, value) as TooltipOptions;\n }\n\n @Input('odxTooltipSize')\n public size?: TooltipSize | null = null;\n\n @Transform(coerceBooleanProperty)\n @Input('odxTooltipVisible')\n public visible = false;\n\n public get isOpen(): boolean {\n return this.connectedOverlayRef !== null;\n }\n\n constructor() {\n const takeUntilDestroyed = untilDestroyed();\n const show$ = this.showTrigger$$.pipe(\n filter(() => !this.isOpen),\n delayUntil(() => this.tooltipOptions.delayIn, this.hideTrigger$$),\n tap(() => this.show())\n );\n const hide$ = this.hideTrigger$$.pipe(\n filter(() => this.isOpen),\n delayUntil(() => this.tooltipOptions.delayOut, this.showTrigger$$),\n tap(() => this.hide())\n );\n merge(show$, hide$).pipe(takeUntilDestroyed()).subscribe();\n }\n\n public ngOnInit(): void {\n this.registerEvents();\n }\n\n public ngOnChanges(changes: NgChanges<TooltipDirective>): void {\n if (hasChanged(changes, 'disabled') && this.disabled) {\n this.hide();\n }\n if (hasChanged(changes, ['content', 'size'])) {\n this.connectedOverlayRef?.update({ context: { content: this.content, size: this.size } });\n }\n if (hasChanged(changes, 'options')) {\n this.connectedOverlayRef?.update(this.tooltipOptions);\n this.registerEvents();\n }\n if (this.visible && !this.disabled) {\n this.show();\n } else {\n this.hide();\n }\n }\n\n public show(): void {\n if (this.isOpen || this.disabled) return;\n this.tooltipId = `odx-tooltip-${TooltipDirective.ID++}`;\n this.connectedOverlayRef = this.connectedOverlayService.createOverlay(this.element.nativeElement, {\n ...this.tooltipOptions,\n containerClass: 'odx-tooltip-overlay',\n content: TooltipComponent,\n context: { content: this.content, size: this.size, id: this.tooltipId },\n showArrow: true,\n enableFallback: true,\n });\n }\n\n public hide(): void {\n if (!this.isOpen || (this.visible && !this.disabled)) return;\n this.connectedOverlayRef?.close();\n this.connectedOverlayRef = null;\n this.tooltipId = null;\n }\n\n private registerEvents(): void {\n const [openEvent, closeEvent] = resolveTooltipTriggerEvents(this.tooltipOptions.trigger);\n this.eventManager.destroyListeners();\n this.eventManager.register([openEvent, 'focusin'], () => this.showTrigger$$.next());\n this.eventManager.register([closeEvent, 'focusout'], () => this.hideTrigger$$.next());\n this.eventManager.register(['keyup.esc'], () => this.hideTrigger$$.next(), 'document');\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAEM,SAAU,2BAA2B,CAAC,OAAuB,EAAA;IACjE,IAAI,OAAO,KAAK,OAAO,EAAE;AACvB,QAAA,OAAO,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;AACxB,KAAA;AAAM,SAAA;AACL,QAAA,OAAO,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;AACrC,KAAA;AACH;;ACNa,MAAA,WAAW,GAAG;AACzB,IAAA,IAAI,EAAE,MAAM;AACZ,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,MAAM,EAAE,QAAQ;AAChB,IAAA,KAAK,EAAE,OAAO;;;ACKH,MAAA,qBAAqB,GAAmB;AACnD,IAAA,mBAAmB,EAAE,KAAK;IAC1B,IAAI,EAAE,WAAW,CAAC,IAAI;AACtB,IAAA,OAAO,EAAE,OAAO;AAChB,IAAA,QAAQ,EAAE,KAAK;AACf,IAAA,OAAO,EAAE,CAAC;AACV,IAAA,QAAQ,EAAE,CAAC;;;ACEN,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB,CAAA;AAAtB,IAAA,WAAA,GAAA;QACc,IAAQ,CAAA,QAAA,GAAG,WAAW,EAAE,CAAC;QAC5B,IAAO,CAAA,OAAA,GAAG,aAAa,EAAE,CAAC;QAGnC,IAAE,CAAA,EAAA,GAAkB,IAAI,CAAC;AAOzB,QAAA,IAAA,CAAA,IAAI,GAAgB,WAAW,CAAC,IAAI,CAAC;AAC7C,KAAA;;6GAbY,gBAAgB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA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AS,CAAC,qBAAqB,CAAC;;AAEV,CAAA,EAAA,gBAAA,CAAA,SAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAjCZ,gBAAgB,GAAA,kBAAA,GAAA,UAAA,CAAA;IAV5B,YAAY,CAAC,cAAc,CAAC;;AAUhB,CAAA,EAAA,gBAAgB,CAuG5B,CAAA;2FAvGY,gBAAgB,EAAA,UAAA,EAAA,CAAA;kBAT5B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,UAAU,EAAE,IAAI;AAChB,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,QAAQ,EAAE,YAAY;oBACtB,SAAS,EAAE,CAAC,YAAY,CAAC;AACzB,oBAAA,IAAI,EAAE;AACJ,wBAAA,yBAAyB,EAAE,WAAW;AACvC,qBAAA;AACF,iBAAA,CAAA;0EAkBQ,OAAO,EAAA,CAAA;sBADb,KAAK;uBAAC,YAAY,CAAA;gBAKZ,QAAQ,EAAA,CAAA;sBADd,KAAK;uBAAC,oBAAoB,CAAA;gBAIhB,OAAO,EAAA,CAAA;sBADjB,KAAK;uBAAC,mBAAmB,CAAA;gBAMnB,IAAI,EAAA,CAAA;sBADV,KAAK;uBAAC,gBAAgB,CAAA;gBAKhB,OAAO,EAAA,CAAA;sBADb,KAAK;uBAAC,mBAAmB,CAAA;;;ACvD5B;;AAEG;;;;"}
|
|
@@ -1,13 +1,37 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
const CSS_COMPONENT_NAME = Symbol('__CSSComponentName__');
|
|
2
|
+
const CSS_COMPONENT_MODIFIERS = Symbol('__CSSComponentModifiers__');
|
|
3
|
+
/** @internal */
|
|
4
|
+
/* istanbul ignore next */
|
|
5
|
+
function CSSComponent(name, prefix = 'odx') {
|
|
6
|
+
return (target) => {
|
|
7
|
+
const cssClass = `${prefix}-${name}`;
|
|
8
|
+
Object.defineProperty(target.prototype, CSS_COMPONENT_NAME, {
|
|
9
|
+
value: cssClass,
|
|
10
|
+
});
|
|
11
|
+
(function (ngOnInit) {
|
|
12
|
+
target.prototype.ngOnInit = function () {
|
|
13
|
+
this.element.nativeElement.classList.add(cssClass);
|
|
14
|
+
ngOnInit?.call(this);
|
|
15
|
+
if (Array.isArray(this[CSS_COMPONENT_MODIFIERS])) {
|
|
16
|
+
for (const property of this[CSS_COMPONENT_MODIFIERS]) {
|
|
17
|
+
this[property] ?? (this[property] = null);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
})(target.prototype.ngOnInit);
|
|
22
|
+
};
|
|
8
23
|
}
|
|
9
|
-
|
|
10
|
-
|
|
24
|
+
|
|
25
|
+
/** @internal */
|
|
26
|
+
/* istanbul ignore next */
|
|
27
|
+
function camelToKebabCase(value) {
|
|
28
|
+
if (value !== value.toLowerCase()) {
|
|
29
|
+
return value.replace(/[A-Z]/g, (match, index) => {
|
|
30
|
+
const char = match.toLowerCase();
|
|
31
|
+
return index === 0 ? char : `-${char}`;
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
return value;
|
|
11
35
|
}
|
|
12
36
|
|
|
13
37
|
/* istanbul ignore next */
|
|
@@ -45,39 +69,6 @@ function getEnumValues(e) {
|
|
|
45
69
|
return keys.filter((key) => e[key] !== undefined).map((key) => e[key]);
|
|
46
70
|
}
|
|
47
71
|
|
|
48
|
-
function isViewContainer(value) {
|
|
49
|
-
return isFunction(value?.createComponent);
|
|
50
|
-
}
|
|
51
|
-
function isTemplateRef(value) {
|
|
52
|
-
return value instanceof TemplateRef;
|
|
53
|
-
}
|
|
54
|
-
function isComponent(value) {
|
|
55
|
-
return isFunction(value);
|
|
56
|
-
}
|
|
57
|
-
function isString(value) {
|
|
58
|
-
return typeof value === 'string';
|
|
59
|
-
}
|
|
60
|
-
function isNonEmptyString(value) {
|
|
61
|
-
return isString(value) && value.length > 0;
|
|
62
|
-
}
|
|
63
|
-
function isBoolean(value) {
|
|
64
|
-
return typeof value === 'boolean';
|
|
65
|
-
}
|
|
66
|
-
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
67
|
-
function isFunction(value) {
|
|
68
|
-
return typeof value === 'function';
|
|
69
|
-
}
|
|
70
|
-
function isPresent(value) {
|
|
71
|
-
return value !== null && value !== undefined;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
/** @internal */
|
|
75
|
-
function watch(changeDetectorRef) {
|
|
76
|
-
return tap(() => {
|
|
77
|
-
changeDetectorRef.markForCheck();
|
|
78
|
-
});
|
|
79
|
-
}
|
|
80
|
-
|
|
81
72
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
82
73
|
/** @internal */
|
|
83
74
|
/* istanbul ignore next */
|
|
@@ -115,55 +106,6 @@ function ɵwithMultipleDescriptors(target, key, symbol) {
|
|
|
115
106
|
};
|
|
116
107
|
}
|
|
117
108
|
|
|
118
|
-
function detectControllerChanges(changeDetector, ...controllers) {
|
|
119
|
-
return combineLatest(controllers.reduce((changes, controller) => (controller ? changes.concat(controller.change$) : changes), [])).pipe(watch(changeDetector));
|
|
120
|
-
}
|
|
121
|
-
/** @internal */
|
|
122
|
-
class Controller {
|
|
123
|
-
constructor() {
|
|
124
|
-
this.change$$ = new BehaviorSubject(undefined);
|
|
125
|
-
this.change$ = this.change$$.pipe(shareReplay({ refCount: true }));
|
|
126
|
-
}
|
|
127
|
-
ngOnChanges() {
|
|
128
|
-
this.triggerControllerChange();
|
|
129
|
-
}
|
|
130
|
-
ngOnDestroy() {
|
|
131
|
-
this.change$$.complete();
|
|
132
|
-
}
|
|
133
|
-
triggerControllerChange() {
|
|
134
|
-
this.change$$.next();
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
Controller.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.2", ngImport: i0, type: Controller, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
138
|
-
Controller.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.2", type: Controller, usesOnChanges: true, ngImport: i0 });
|
|
139
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.2", ngImport: i0, type: Controller, decorators: [{
|
|
140
|
-
type: Directive
|
|
141
|
-
}] });
|
|
142
|
-
|
|
143
|
-
const CSS_COMPONENT_NAME = Symbol('__CSSComponentName__');
|
|
144
|
-
const CSS_COMPONENT_MODIFIERS = Symbol('__CSSComponentModifiers__');
|
|
145
|
-
/** @internal */
|
|
146
|
-
/* istanbul ignore next */
|
|
147
|
-
function CSSComponent(name, prefix = 'odx') {
|
|
148
|
-
return (target) => {
|
|
149
|
-
const cssClass = `${prefix}-${name}`;
|
|
150
|
-
Object.defineProperty(target.prototype, CSS_COMPONENT_NAME, {
|
|
151
|
-
value: cssClass,
|
|
152
|
-
});
|
|
153
|
-
(function (ngOnInit) {
|
|
154
|
-
target.prototype.ngOnInit = function () {
|
|
155
|
-
this.element.nativeElement.classList.add(cssClass);
|
|
156
|
-
ngOnInit?.call(this);
|
|
157
|
-
if (Array.isArray(this[CSS_COMPONENT_MODIFIERS])) {
|
|
158
|
-
for (const property of this[CSS_COMPONENT_MODIFIERS]) {
|
|
159
|
-
this[property] ?? (this[property] = null);
|
|
160
|
-
}
|
|
161
|
-
}
|
|
162
|
-
};
|
|
163
|
-
})(target.prototype.ngOnInit);
|
|
164
|
-
};
|
|
165
|
-
}
|
|
166
|
-
|
|
167
109
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
168
110
|
/** @internal */
|
|
169
111
|
/* istanbul ignore next */
|
|
@@ -171,10 +113,11 @@ function CSSModifier(options) {
|
|
|
171
113
|
return (target, propertyKey) => {
|
|
172
114
|
const propertySymbol = Symbol(`__CSSModifier{${propertyKey.toString()}}__`);
|
|
173
115
|
const descriptors = ɵwithMultipleDescriptors(target, propertyKey, propertySymbol);
|
|
116
|
+
const propertyKeyKebabCase = camelToKebabCase(propertyKey.toString());
|
|
174
117
|
function createModifierClass(value) {
|
|
175
118
|
value = value ?? options?.default ?? null;
|
|
176
|
-
if (
|
|
177
|
-
let modifier =
|
|
119
|
+
if (typeof value === 'boolean' || (typeof value === 'string' && value.length > 0)) {
|
|
120
|
+
let modifier = typeof value === 'boolean' ? propertyKeyKebabCase : value;
|
|
178
121
|
if (options?.withPrefix) {
|
|
179
122
|
modifier = [propertyKey, modifier].join('-');
|
|
180
123
|
}
|
|
@@ -197,7 +140,7 @@ function CSSModifier(options) {
|
|
|
197
140
|
}
|
|
198
141
|
this[propertySymbol][i] = currentValue;
|
|
199
142
|
const newModifierClass = createModifierClass.apply(this, [this[propertySymbol][i]]);
|
|
200
|
-
if (newModifierClass !== null && (
|
|
143
|
+
if (newModifierClass !== null && (typeof currentValue === 'boolean' ? currentValue : true)) {
|
|
201
144
|
this.element.nativeElement.classList.add(newModifierClass);
|
|
202
145
|
}
|
|
203
146
|
}
|
|
@@ -212,16 +155,9 @@ function CSSModifier(options) {
|
|
|
212
155
|
};
|
|
213
156
|
}
|
|
214
157
|
|
|
215
|
-
/** @internal */
|
|
216
|
-
function watchedControllerFactory(controller, changeDetectorRef, destroy$) {
|
|
217
|
-
const changes$ = controller?.change$ ?? EMPTY;
|
|
218
|
-
changes$.pipe(watch(changeDetectorRef), takeUntil(destroy$)).subscribe();
|
|
219
|
-
return controller;
|
|
220
|
-
}
|
|
221
|
-
|
|
222
158
|
/**
|
|
223
159
|
* Generated bundle index. Do not edit.
|
|
224
160
|
*/
|
|
225
161
|
|
|
226
|
-
export { CSSComponent, CSSModifier, CSS_COMPONENT_MODIFIERS, CSS_COMPONENT_NAME,
|
|
162
|
+
export { CSSComponent, CSSModifier, CSS_COMPONENT_MODIFIERS, CSS_COMPONENT_NAME, camelToKebabCase, getCSSVariables, getEnumValues, ɵwithMultipleDescriptors };
|
|
227
163
|
//# sourceMappingURL=odx-angular-internal.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odx-angular-internal.mjs","sources":["../../../../libs/angular/internal/src/helpers/dom.ts","../../../../libs/angular/internal/src/helpers/get-css-variables.ts","../../../../libs/angular/internal/src/helpers/get-enum-values.ts","../../../../libs/angular/internal/src/helpers/type-guards.ts","../../../../libs/angular/internal/src/helpers/watch.ts","../../../../libs/angular/internal/src/helpers/with-mutiple-descriptors.ts","../../../../libs/angular/internal/src/abstract/controller.ts","../../../../libs/angular/internal/src/decorators/css-component.ts","../../../../libs/angular/internal/src/decorators/css-modifier.ts","../../../../libs/angular/internal/src/providers/watched-controller-provider.ts","../../../../libs/angular/internal/src/odx-angular-internal.ts"],"sourcesContent":["export function px(value: number): string {\n return `${Math.round(value)}px`;\n}\n\nexport function applyStyles(element: HTMLElement, styles: Partial<CSSStyleDeclaration | Record<keyof CSSStyleDeclaration, string | null>>): void {\n Object.assign(element.style, styles);\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\ninterface ColorDefinition {\n name: string;\n variableName: string;\n value: string;\n}\n\n/* istanbul ignore next */\nfunction isSameDomain(styleSheet: StyleSheet): boolean {\n if (!styleSheet.href) {\n return true;\n }\n\n return styleSheet.href.indexOf(window.location.origin) === 0;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function getCSSVariables(filter: RegExp): ColorDefinition[] {\n const stylesheets = Array.from(document.styleSheets).filter(isSameDomain);\n return stylesheets.reduce<any[]>((variables, { cssRules }) => {\n for (const { style, type } of Array.from(cssRules) as any[]) {\n if (type === 1) {\n for (const prop of Array.from(style ?? []) as string[]) {\n const name = prop.trim();\n if (name.startsWith('--') && filter.test(name)) {\n variables.push({\n name: name,\n value: style.getPropertyValue(prop).trim(),\n });\n }\n }\n }\n }\n return variables;\n }, []);\n}\n","/** @internal */\nexport function getEnumValues<TEnum, TKeys extends string>(e: { [key in TKeys]: TEnum }): TEnum[] {\n const keys = Object.keys(e) as TKeys[];\n return keys.filter((key) => e[key] !== undefined).map((key) => e[key]);\n}\n","import { TemplateRef, Type, ViewContainerRef } from '@angular/core';\n\nexport function isViewContainer(value: unknown): value is ViewContainerRef {\n return isFunction((value as ViewContainerRef)?.createComponent);\n}\n\nexport function isTemplateRef<T = unknown>(value: unknown): value is TemplateRef<T> {\n return value instanceof TemplateRef;\n}\n\nexport function isComponent<T = unknown>(value: unknown): value is Type<T> {\n return isFunction(value);\n}\n\nexport function isString(value: unknown): value is string {\n return typeof value === 'string';\n}\n\nexport function isNonEmptyString(value: unknown): value is string {\n return isString(value) && value.length > 0;\n}\n\nexport function isBoolean(value: unknown): value is boolean {\n return typeof value === 'boolean';\n}\n\n// eslint-disable-next-line @typescript-eslint/ban-types\nexport function isFunction(value: unknown): value is Function {\n return typeof value === 'function';\n}\n\nexport function isPresent<T>(value: T | null | undefined): value is NonNullable<T> {\n return value !== null && value !== undefined;\n}\n","import { ChangeDetectorRef } from '@angular/core';\nimport { MonoTypeOperatorFunction } from 'rxjs';\nimport { tap } from 'rxjs/operators';\n\n/** @internal */\nexport function watch<T>(changeDetectorRef: ChangeDetectorRef): MonoTypeOperatorFunction<T> {\n return tap(() => {\n changeDetectorRef.markForCheck();\n });\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\n\n/** @internal */\ninterface DescriptiorManager {\n addGetter: (value: any) => void;\n addSetter: (value: any) => void;\n init: () => void;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function ɵwithMultipleDescriptors(target: any, key: PropertyKey, symbol: symbol): DescriptiorManager {\n const setters = (target[`__propSetters__${target.constructor}__${key.toString()}`] ??= []);\n const getters = (target[`__propGetters__${target.constructor}__${key.toString()}`] ??= []);\n const propertyValue = `__propValue_${String(key)}__`;\n return {\n addSetter(fn: (this: any, value: any) => void) {\n setters.push({ fn, propertySymbol: symbol });\n },\n addGetter(fn: (this: any, value: any) => void) {\n getters.push({ fn });\n },\n init() {\n Object.defineProperty(target, key, {\n set(value) {\n this[propertyValue] = setters.reduce((result: any, { fn, propertySymbol }: any) => {\n fn.call(this, result);\n return this[propertySymbol];\n }, value);\n },\n get() {\n if (Array.isArray(getters)) {\n return getters.reduce((_: any, { fn }: any) => fn.call(this), this[propertyValue]);\n } else {\n return this[propertyValue];\n }\n },\n configurable: true,\n });\n },\n };\n}\n","import { ChangeDetectorRef, Directive, OnChanges, OnDestroy } from '@angular/core';\nimport { BehaviorSubject, combineLatest, Observable, shareReplay } from 'rxjs';\nimport { watch } from '../helpers';\n\nexport function detectControllerChanges(changeDetector: ChangeDetectorRef, ...controllers: Array<Controller | undefined | null>): Observable<void[]> {\n return combineLatest(controllers.reduce<Observable<void>[]>((changes, controller) => (controller ? changes.concat(controller.change$) : changes), [])).pipe(\n watch(changeDetector)\n );\n}\n\n/** @internal */\n@Directive()\nexport abstract class Controller implements OnChanges, OnDestroy {\n private readonly change$$ = new BehaviorSubject<void>(undefined);\n\n public readonly change$ = this.change$$.pipe(shareReplay({ refCount: true }));\n\n public ngOnChanges(): void {\n this.triggerControllerChange();\n }\n\n public ngOnDestroy(): void {\n this.change$$.complete();\n }\n\n protected triggerControllerChange() {\n this.change$$.next();\n }\n}\n","import { ElementRef, Type } from '@angular/core';\n\nexport const CSS_COMPONENT_NAME = Symbol('__CSSComponentName__');\n\nexport const CSS_COMPONENT_MODIFIERS = Symbol('__CSSComponentModifiers__');\n\n/** @internal */\nexport interface CSSComponent {\n readonly element: ElementRef<unknown>;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function CSSComponent(name: string, prefix = 'odx') {\n return (target: Type<CSSComponent>) => {\n const cssClass = `${prefix}-${name}`;\n Object.defineProperty(target.prototype, CSS_COMPONENT_NAME, {\n value: cssClass,\n });\n\n (function (this: unknown, ngOnInit?: () => void) {\n target.prototype.ngOnInit = function () {\n this.element.nativeElement.classList.add(cssClass);\n ngOnInit?.call(this);\n\n if (Array.isArray(this[CSS_COMPONENT_MODIFIERS])) {\n for (const property of this[CSS_COMPONENT_MODIFIERS]) {\n this[property] ??= null;\n }\n }\n };\n })(target.prototype.ngOnInit);\n };\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { isBoolean, isNonEmptyString, ɵwithMultipleDescriptors } from '../helpers';\nimport { CSS_COMPONENT_MODIFIERS, CSS_COMPONENT_NAME } from './css-component';\n\n/** @internal */\ninterface CSSModifierOptions {\n isArray?: boolean;\n withComponentPrefix?: boolean;\n default?: string;\n withPrefix?: boolean;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function CSSModifier(options?: CSSModifierOptions) {\n return (target: any, propertyKey: PropertyKey) => {\n const propertySymbol = Symbol(`__CSSModifier{${propertyKey.toString()}}__`);\n const descriptors = ɵwithMultipleDescriptors(target, propertyKey, propertySymbol);\n\n function createModifierClass(this: any, value: any) {\n value = value ?? options?.default ?? null;\n\n if (isBoolean(value) || isNonEmptyString(value)) {\n let modifier = isBoolean(value) ? propertyKey.toString() : value;\n if (options?.withPrefix) {\n modifier = [propertyKey, modifier].join('-');\n }\n return [options?.withComponentPrefix ?? true ? this[CSS_COMPONENT_NAME] : null, modifier].filter(Boolean).join('--');\n }\n return null;\n }\n\n if (options?.default) {\n target[CSS_COMPONENT_MODIFIERS] = (target[CSS_COMPONENT_MODIFIERS] || []).concat(propertyKey);\n }\n\n function setter(this: any, value: any) {\n const values = options?.isArray ? value : [value];\n this[propertySymbol] = this[propertySymbol] || [];\n for (let i = 0; i < values.length; ++i) {\n const currentValue = values[i];\n if (this[propertySymbol].length < 1 || currentValue !== this[propertySymbol][i]) {\n const currentModifierClass = createModifierClass.apply(this, [this[propertySymbol][i]]);\n if (currentModifierClass !== null) {\n this.element.nativeElement.classList.remove(currentModifierClass);\n }\n this[propertySymbol][i] = currentValue;\n const newModifierClass = createModifierClass.apply(this, [this[propertySymbol][i]]);\n if (newModifierClass !== null && (isBoolean(currentValue) ? currentValue : true)) {\n this.element.nativeElement.classList.add(newModifierClass);\n }\n }\n }\n }\n\n function getter(this: any) {\n return options?.isArray ? this[propertySymbol] : this[propertySymbol]?.[0];\n }\n\n descriptors.addSetter(setter);\n descriptors.addGetter(getter);\n descriptors.init();\n };\n}\n","import { ChangeDetectorRef } from '@angular/core';\nimport { EMPTY, Observable, takeUntil } from 'rxjs';\nimport { Controller } from '../abstract';\nimport { watch } from '../helpers';\n\n/** @internal */\nexport function watchedControllerFactory(controller: Controller | null, changeDetectorRef: ChangeDetectorRef, destroy$: Observable<void>): Controller | null {\n const changes$ = controller?.change$ ?? EMPTY;\n changes$.pipe(watch(changeDetectorRef), takeUntil(destroy$)).subscribe();\n\n return controller;\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAM,SAAU,EAAE,CAAC,KAAa,EAAA;IAC9B,OAAO,CAAA,EAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC;AAClC,CAAC;AAEe,SAAA,WAAW,CAAC,OAAoB,EAAE,MAAuF,EAAA;IACvI,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;AACvC;;ACCA;AACA,SAAS,YAAY,CAAC,UAAsB,EAAA;AAC1C,IAAA,IAAI,CAAC,UAAU,CAAC,IAAI,EAAE;AACpB,QAAA,OAAO,IAAI,CAAC;AACb,KAAA;AAED,IAAA,OAAO,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AAC/D,CAAC;AAED;AACA;AACM,SAAU,eAAe,CAAC,MAAc,EAAA;AAC5C,IAAA,MAAM,WAAW,GAAG,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC;IAC1E,OAAO,WAAW,CAAC,MAAM,CAAQ,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,KAAI;AAC3D,QAAA,KAAK,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,IAAI,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAU,EAAE;YAC3D,IA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AAC,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC;AACvC,oBAAA,MAAM,gBAAgB,GAAG,mBAAmB,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACpF,oBAAA,IAAI,gBAAgB,KAAK,IAAI,KAAK,SAAS,CAAC,YAAY,CAAC,GAAG,YAAY,GAAG,IAAI,CAAC,EAAE;wBAChF,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,SAAS,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;AAC5D,qBAAA;AACF,iBAAA;AACF,aAAA;SACF;AAED,QAAA,SAAS,MAAM,GAAA;YACb,OAAO,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,cAAc,CAAC,GAAG,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;SAC5E;AAED,QAAA,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;AAC9B,QAAA,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAC9B,WAAW,CAAC,IAAI,EAAE,CAAC;AACrB,KAAC,CAAC;AACJ;;AC1DA;SACgB,wBAAwB,CAAC,UAA6B,EAAE,iBAAoC,EAAE,QAA0B,EAAA;AACtI,IAAA,MAAM,QAAQ,GAAG,UAAU,EAAE,OAAO,IAAI,KAAK,CAAC;AAC9C,IAAA,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,EAAE,SAAS,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC;AAEzE,IAAA,OAAO,UAAU,CAAC;AACpB;;ACXA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"odx-angular-internal.mjs","sources":["../../../../libs/angular/internal/src/decorators/css-component.ts","../../../../libs/angular/internal/src/helpers/camel-to-kebab-case.ts","../../../../libs/angular/internal/src/helpers/get-css-variables.ts","../../../../libs/angular/internal/src/helpers/get-enum-values.ts","../../../../libs/angular/internal/src/helpers/with-mutiple-descriptors.ts","../../../../libs/angular/internal/src/decorators/css-modifier.ts","../../../../libs/angular/internal/src/odx-angular-internal.ts"],"sourcesContent":["import { ElementRef, Type } from '@angular/core';\n\nexport const CSS_COMPONENT_NAME = Symbol('__CSSComponentName__');\n\nexport const CSS_COMPONENT_MODIFIERS = Symbol('__CSSComponentModifiers__');\n\n/** @internal */\nexport interface CSSComponent {\n readonly element: ElementRef<unknown>;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function CSSComponent(name: string, prefix = 'odx') {\n return (target: Type<CSSComponent>) => {\n const cssClass = `${prefix}-${name}`;\n Object.defineProperty(target.prototype, CSS_COMPONENT_NAME, {\n value: cssClass,\n });\n\n (function (this: unknown, ngOnInit?: () => void) {\n target.prototype.ngOnInit = function () {\n this.element.nativeElement.classList.add(cssClass);\n ngOnInit?.call(this);\n\n if (Array.isArray(this[CSS_COMPONENT_MODIFIERS])) {\n for (const property of this[CSS_COMPONENT_MODIFIERS]) {\n this[property] ??= null;\n }\n }\n };\n })(target.prototype.ngOnInit);\n };\n}\n","/** @internal */\n/* istanbul ignore next */\nexport function camelToKebabCase(value: string): string {\n if (value !== value.toLowerCase()) {\n return value.replace(/[A-Z]/g, (match, index) => {\n const char = match.toLowerCase();\n\n return index === 0 ? char : `-${char}`;\n });\n }\n return value;\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\ninterface ColorDefinition {\n name: string;\n variableName: string;\n value: string;\n}\n\n/* istanbul ignore next */\nfunction isSameDomain(styleSheet: StyleSheet): boolean {\n if (!styleSheet.href) {\n return true;\n }\n\n return styleSheet.href.indexOf(window.location.origin) === 0;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function getCSSVariables(filter: RegExp): ColorDefinition[] {\n const stylesheets = Array.from(document.styleSheets).filter(isSameDomain);\n return stylesheets.reduce<any[]>((variables, { cssRules }) => {\n for (const { style, type } of Array.from(cssRules) as any[]) {\n if (type === 1) {\n for (const prop of Array.from(style ?? []) as string[]) {\n const name = prop.trim();\n if (name.startsWith('--') && filter.test(name)) {\n variables.push({\n name: name,\n value: style.getPropertyValue(prop).trim(),\n });\n }\n }\n }\n }\n return variables;\n }, []);\n}\n","/** @internal */\nexport function getEnumValues<TEnum, TKeys extends string>(e: { [key in TKeys]: TEnum }): TEnum[] {\n const keys = Object.keys(e) as TKeys[];\n return keys.filter((key) => e[key] !== undefined).map((key) => e[key]);\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\n\n/** @internal */\ninterface DescriptiorManager {\n addGetter: (value: any) => void;\n addSetter: (value: any) => void;\n init: () => void;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function ɵwithMultipleDescriptors(target: any, key: PropertyKey, symbol: symbol): DescriptiorManager {\n const setters = (target[`__propSetters__${target.constructor}__${key.toString()}`] ??= []);\n const getters = (target[`__propGetters__${target.constructor}__${key.toString()}`] ??= []);\n const propertyValue = `__propValue_${String(key)}__`;\n return {\n addSetter(fn: (this: any, value: any) => void) {\n setters.push({ fn, propertySymbol: symbol });\n },\n addGetter(fn: (this: any, value: any) => void) {\n getters.push({ fn });\n },\n init() {\n Object.defineProperty(target, key, {\n set(value) {\n this[propertyValue] = setters.reduce((result: any, { fn, propertySymbol }: any) => {\n fn.call(this, result);\n return this[propertySymbol];\n }, value);\n },\n get() {\n if (Array.isArray(getters)) {\n return getters.reduce((_: any, { fn }: any) => fn.call(this), this[propertyValue]);\n } else {\n return this[propertyValue];\n }\n },\n configurable: true,\n });\n },\n };\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { camelToKebabCase, ɵwithMultipleDescriptors } from '../helpers';\nimport { CSS_COMPONENT_MODIFIERS, CSS_COMPONENT_NAME } from './css-component';\n\n/** @internal */\ninterface CSSModifierOptions {\n isArray?: boolean;\n withComponentPrefix?: boolean;\n default?: string;\n withPrefix?: boolean;\n}\n\n/** @internal */\n/* istanbul ignore next */\nexport function CSSModifier(options?: CSSModifierOptions) {\n return (target: any, propertyKey: PropertyKey) => {\n const propertySymbol = Symbol(`__CSSModifier{${propertyKey.toString()}}__`);\n const descriptors = ɵwithMultipleDescriptors(target, propertyKey, propertySymbol);\n const propertyKeyKebabCase = camelToKebabCase(propertyKey.toString());\n\n function createModifierClass(this: any, value: any) {\n value = value ?? options?.default ?? null;\n\n if (typeof value === 'boolean' || (typeof value === 'string' && value.length > 0)) {\n let modifier = typeof value === 'boolean' ? propertyKeyKebabCase : value;\n if (options?.withPrefix) {\n modifier = [propertyKey, modifier].join('-');\n }\n return [options?.withComponentPrefix ?? true ? this[CSS_COMPONENT_NAME] : null, modifier].filter(Boolean).join('--');\n }\n return null;\n }\n\n if (options?.default) {\n target[CSS_COMPONENT_MODIFIERS] = (target[CSS_COMPONENT_MODIFIERS] || []).concat(propertyKey);\n }\n\n function setter(this: any, value: any) {\n const values = options?.isArray ? value : [value];\n this[propertySymbol] = this[propertySymbol] || [];\n for (let i = 0; i < values.length; ++i) {\n const currentValue = values[i];\n if (this[propertySymbol].length < 1 || currentValue !== this[propertySymbol][i]) {\n const currentModifierClass = createModifierClass.apply(this, [this[propertySymbol][i]]);\n if (currentModifierClass !== null) {\n this.element.nativeElement.classList.remove(currentModifierClass);\n }\n this[propertySymbol][i] = currentValue;\n const newModifierClass = createModifierClass.apply(this, [this[propertySymbol][i]]);\n if (newModifierClass !== null && (typeof currentValue === 'boolean' ? currentValue : true)) {\n this.element.nativeElement.classList.add(newModifierClass);\n }\n }\n }\n }\n\n function getter(this: any) {\n return options?.isArray ? this[propertySymbol] : this[propertySymbol]?.[0];\n }\n\n descriptors.addSetter(setter);\n descriptors.addGetter(getter);\n descriptors.init();\n };\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":"MAEa,kBAAkB,GAAG,MAAM,CAAC,sBAAsB,EAAE;MAEpD,uBAAuB,GAAG,MAAM,CAAC,2BAA2B,EAAE;AAO3E;AACA;SACgB,YAAY,CAAC,IAAY,E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CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;oBACxF,IAAI,oBAAoB,KAAK,IAAI,EAAE;wBACjC,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,SAAS,CAAC,MAAM,CAAC,oBAAoB,CAAC,CAAC;AACnE,qBAAA;oBACD,IAAI,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC;AACvC,oBAAA,MAAM,gBAAgB,GAAG,mBAAmB,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACpF,oBAAA,IAAI,gBAAgB,KAAK,IAAI,KAAK,OAAO,YAAY,KAAK,SAAS,GAAG,YAAY,GAAG,IAAI,CAAC,EAAE;wBAC1F,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,SAAS,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;AAC5D,qBAAA;AACF,iBAAA;AACF,aAAA;SACF;AAED,QAAA,SAAS,MAAM,GAAA;YACb,OAAO,OAAO,EAAE,OAAO,GAAG,IAAI,CAAC,cAAc,CAAC,GAAG,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;SAC5E;AAED,QAAA,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;AAC9B,QAAA,WAAW,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAC9B,WAAW,CAAC,IAAI,EAAE,CAAC;AACrB,KAAC,CAAC;AACJ;;AChEA;;AAEG;;;;"}
|
|
@@ -1,4 +1,25 @@
|
|
|
1
|
-
import { merge, fromEvent } from 'rxjs';
|
|
1
|
+
import { switchMap, timer, map, takeUntil, startWith, Observable, debounceTime, merge, fromEvent } from 'rxjs';
|
|
2
|
+
import { createResizeObserver } from '@odx/angular/utils';
|
|
3
|
+
|
|
4
|
+
function delayUntil(delay, notifier) {
|
|
5
|
+
return (source$) => source$.pipe(switchMap((value) => timer(delay()).pipe(map(() => value), takeUntil(notifier))));
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
function fromQueryList(queryList) {
|
|
9
|
+
return queryList.changes.pipe(startWith(queryList));
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
function fromElementResize$(element, debounceDuration = 50) {
|
|
13
|
+
return new Observable((observer) => {
|
|
14
|
+
const resizeObserver = createResizeObserver((events) => {
|
|
15
|
+
if (events.length > 0) {
|
|
16
|
+
observer.next();
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
observer.add(() => resizeObserver.disconnect());
|
|
20
|
+
resizeObserver.observe(element);
|
|
21
|
+
}).pipe(debounceTime(debounceDuration));
|
|
22
|
+
}
|
|
2
23
|
|
|
3
24
|
function fromEvents(target, ...events) {
|
|
4
25
|
return merge(...events.map((event) => fromEvent(target, event)));
|
|
@@ -8,5 +29,5 @@ function fromEvents(target, ...events) {
|
|
|
8
29
|
* Generated bundle index. Do not edit.
|
|
9
30
|
*/
|
|
10
31
|
|
|
11
|
-
export { fromEvents };
|
|
32
|
+
export { delayUntil, fromElementResize$, fromEvents, fromQueryList };
|
|
12
33
|
//# sourceMappingURL=odx-angular-rxjs.mjs.map
|