@ionic/angular 8.8.19 → 8.8.20-dev.11787158518.168a2fea
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -7
- package/dist/common/directives/control-value-accessors/index.js +2 -0
- package/dist/common/directives/control-value-accessors/index.js.map +1 -0
- package/{common → dist/common}/directives/control-value-accessors/value-accessor.d.ts +1 -1
- package/dist/common/directives/control-value-accessors/value-accessor.js +152 -0
- package/dist/common/directives/control-value-accessors/value-accessor.js.map +1 -0
- package/{common → dist/common}/directives/navigation/back-button.d.ts +1 -1
- package/dist/common/directives/navigation/back-button.js +61 -0
- package/dist/common/directives/navigation/back-button.js.map +1 -0
- package/dist/common/directives/navigation/nav-params.js +47 -0
- package/dist/common/directives/navigation/nav-params.js.map +1 -0
- package/{common → dist/common}/directives/navigation/nav.d.ts +1 -1
- package/dist/common/directives/navigation/nav.js +49 -0
- package/dist/common/directives/navigation/nav.js.map +1 -0
- package/{common → dist/common}/directives/navigation/router-link-delegate.d.ts +2 -2
- package/dist/common/directives/navigation/router-link-delegate.js +188 -0
- package/dist/common/directives/navigation/router-link-delegate.js.map +1 -0
- package/{common → dist/common}/directives/navigation/router-outlet.d.ts +1 -1
- package/dist/common/directives/navigation/router-outlet.js +476 -0
- package/dist/common/directives/navigation/router-outlet.js.map +1 -0
- package/dist/common/directives/navigation/stack-controller.js +282 -0
- package/dist/common/directives/navigation/stack-controller.js.map +1 -0
- package/dist/common/directives/navigation/stack-utils.js +73 -0
- package/dist/common/directives/navigation/stack-utils.js.map +1 -0
- package/{common → dist/common}/directives/navigation/tabs.d.ts +9 -1
- package/dist/common/directives/navigation/tabs.js +290 -0
- package/dist/common/directives/navigation/tabs.js.map +1 -0
- package/{common → dist/common}/index.d.ts +1 -1
- package/dist/common/index.js +20 -0
- package/dist/common/index.js.map +1 -0
- package/{common → dist/common}/overlays/modal.d.ts +1 -1
- package/dist/common/overlays/modal.js +96 -0
- package/dist/common/overlays/modal.js.map +1 -0
- package/{common → dist/common}/overlays/popover.d.ts +1 -1
- package/dist/common/overlays/popover.js +84 -0
- package/dist/common/overlays/popover.js.map +1 -0
- package/{common → dist/common}/providers/angular-delegate.d.ts +2 -2
- package/dist/common/providers/angular-delegate.js +229 -0
- package/dist/common/providers/angular-delegate.js.map +1 -0
- package/dist/common/providers/config.js +44 -0
- package/dist/common/providers/config.js.map +1 -0
- package/dist/common/providers/dom-controller.js +44 -0
- package/dist/common/providers/dom-controller.js.map +1 -0
- package/dist/common/providers/menu-controller.js +114 -0
- package/dist/common/providers/menu-controller.js.map +1 -0
- package/dist/common/providers/nav-controller.js +232 -0
- package/dist/common/providers/nav-controller.js.map +1 -0
- package/dist/common/providers/platform.js +256 -0
- package/dist/common/providers/platform.js.map +1 -0
- package/dist/common/types/interfaces.js +2 -0
- package/dist/common/types/interfaces.js.map +1 -0
- package/dist/common/types/ionic-lifecycle-hooks.js +5 -0
- package/dist/common/types/ionic-lifecycle-hooks.js.map +1 -0
- package/dist/common/types/overlay-options.js +2 -0
- package/dist/common/types/overlay-options.js.map +1 -0
- package/dist/common/utils/overlay.js +26 -0
- package/dist/common/utils/overlay.js.map +1 -0
- package/dist/common/utils/proxy.js +47 -0
- package/dist/common/utils/proxy.js.map +1 -0
- package/dist/common/utils/routing.js +55 -0
- package/dist/common/utils/routing.js.map +1 -0
- package/dist/common/utils/util.js +10 -0
- package/dist/common/utils/util.js.map +1 -0
- package/dist/lazy/app-initialize.js +29 -0
- package/dist/lazy/app-initialize.js.map +1 -0
- package/dist/lazy/directives/angular-component-lib/utils.js +59 -0
- package/dist/lazy/directives/angular-component-lib/utils.js.map +1 -0
- package/{directives → dist/lazy/directives}/control-value-accessors/boolean-value-accessor.d.ts +1 -1
- package/dist/lazy/directives/control-value-accessors/boolean-value-accessor.js +47 -0
- package/dist/lazy/directives/control-value-accessors/boolean-value-accessor.js.map +1 -0
- package/dist/lazy/directives/control-value-accessors/index.js +5 -0
- package/dist/lazy/directives/control-value-accessors/index.js.map +1 -0
- package/{directives → dist/lazy/directives}/control-value-accessors/numeric-value-accessor.d.ts +1 -1
- package/dist/lazy/directives/control-value-accessors/numeric-value-accessor.js +55 -0
- package/dist/lazy/directives/control-value-accessors/numeric-value-accessor.js.map +1 -0
- package/{directives → dist/lazy/directives}/control-value-accessors/select-value-accessor.d.ts +1 -1
- package/dist/lazy/directives/control-value-accessors/select-value-accessor.js +44 -0
- package/dist/lazy/directives/control-value-accessors/select-value-accessor.js.map +1 -0
- package/{directives → dist/lazy/directives}/control-value-accessors/text-value-accessor.d.ts +1 -1
- package/dist/lazy/directives/control-value-accessors/text-value-accessor.js +43 -0
- package/dist/lazy/directives/control-value-accessors/text-value-accessor.js.map +1 -0
- package/dist/lazy/directives/navigation/ion-back-button.js +24 -0
- package/dist/lazy/directives/navigation/ion-back-button.js.map +1 -0
- package/dist/lazy/directives/navigation/ion-nav.js +21 -0
- package/dist/lazy/directives/navigation/ion-nav.js.map +1 -0
- package/dist/lazy/directives/navigation/ion-router-outlet.js +52 -0
- package/dist/lazy/directives/navigation/ion-router-outlet.js.map +1 -0
- package/dist/lazy/directives/navigation/ion-tabs.js +58 -0
- package/dist/lazy/directives/navigation/ion-tabs.js.map +1 -0
- package/dist/lazy/directives/navigation/router-link-delegate.js +32 -0
- package/dist/lazy/directives/navigation/router-link-delegate.js.map +1 -0
- package/dist/lazy/directives/overlays/modal.js +22 -0
- package/dist/lazy/directives/overlays/modal.js.map +1 -0
- package/dist/lazy/directives/overlays/popover.js +18 -0
- package/dist/lazy/directives/overlays/popover.js.map +1 -0
- package/{directives → dist/lazy/directives}/proxies-list.d.ts +1 -1
- package/dist/lazy/directives/proxies-list.js +89 -0
- package/dist/lazy/directives/proxies-list.js.map +1 -0
- package/{directives → dist/lazy/directives}/proxies.d.ts +290 -191
- package/dist/lazy/directives/proxies.js +2759 -0
- package/dist/lazy/directives/proxies.js.map +1 -0
- package/dist/lazy/directives/validators/index.js +3 -0
- package/dist/lazy/directives/validators/index.js.map +1 -0
- package/dist/lazy/directives/validators/max-validator.js +26 -0
- package/dist/lazy/directives/validators/max-validator.js.map +1 -0
- package/dist/lazy/directives/validators/min-validator.js +26 -0
- package/dist/lazy/directives/validators/min-validator.js.map +1 -0
- package/{index.d.ts → dist/lazy/index.d.ts} +1 -2
- package/dist/lazy/index.js +34 -0
- package/dist/lazy/index.js.map +1 -0
- package/dist/lazy/ionic-module.d.ts +38 -0
- package/dist/lazy/ionic-module.js +121 -0
- package/dist/lazy/ionic-module.js.map +1 -0
- package/dist/lazy/providers/action-sheet-controller.js +18 -0
- package/dist/lazy/providers/action-sheet-controller.js.map +1 -0
- package/dist/lazy/providers/alert-controller.js +18 -0
- package/dist/lazy/providers/alert-controller.js.map +1 -0
- package/dist/lazy/providers/animation-controller.js +37 -0
- package/dist/lazy/providers/animation-controller.js.map +1 -0
- package/dist/lazy/providers/gesture-controller.js +32 -0
- package/dist/lazy/providers/gesture-controller.js.map +1 -0
- package/dist/lazy/providers/loading-controller.js +18 -0
- package/dist/lazy/providers/loading-controller.js.map +1 -0
- package/dist/lazy/providers/menu-controller.js +18 -0
- package/dist/lazy/providers/menu-controller.js.map +1 -0
- package/dist/lazy/providers/modal-controller.js +25 -0
- package/dist/lazy/providers/modal-controller.js.map +1 -0
- package/dist/lazy/providers/popover-controller.js +19 -0
- package/dist/lazy/providers/popover-controller.js.map +1 -0
- package/dist/lazy/providers/toast-controller.js +18 -0
- package/dist/lazy/providers/toast-controller.js.map +1 -0
- package/{schematics → dist/schematics}/add/index.js +6 -6
- package/dist/schematics/utils/ast.js +64 -0
- package/{schematics → dist/schematics}/utils/config.js +10 -11
- package/{schematics → dist/schematics}/utils/package.js +6 -4
- package/dist/standalone/directives/angular-component-lib/utils.js +59 -0
- package/dist/standalone/directives/angular-component-lib/utils.js.map +1 -0
- package/dist/standalone/directives/checkbox.js +75 -0
- package/dist/standalone/directives/checkbox.js.map +1 -0
- package/dist/standalone/directives/datetime.js +93 -0
- package/dist/standalone/directives/datetime.js.map +1 -0
- package/dist/standalone/directives/icon.js +35 -0
- package/dist/standalone/directives/icon.js.map +1 -0
- package/dist/standalone/directives/index.js +13 -0
- package/dist/standalone/directives/index.js.map +1 -0
- package/dist/standalone/directives/input-otp.js +89 -0
- package/dist/standalone/directives/input-otp.js.map +1 -0
- package/dist/standalone/directives/input.js +112 -0
- package/dist/standalone/directives/input.js.map +1 -0
- package/dist/standalone/directives/ion-accordion-group.d.ts +21 -0
- package/dist/standalone/directives/ion-accordion-group.js +40 -0
- package/dist/standalone/directives/ion-accordion-group.js.map +1 -0
- package/dist/standalone/directives/ion-accordion.d.ts +12 -0
- package/dist/standalone/directives/ion-accordion.js +36 -0
- package/dist/standalone/directives/ion-accordion.js.map +1 -0
- package/dist/standalone/directives/ion-action-sheet.d.ts +58 -0
- package/dist/standalone/directives/ion-action-sheet.js +62 -0
- package/dist/standalone/directives/ion-action-sheet.js.map +1 -0
- package/dist/standalone/directives/ion-alert.d.ts +58 -0
- package/dist/standalone/directives/ion-alert.js +62 -0
- package/dist/standalone/directives/ion-alert.js.map +1 -0
- package/dist/standalone/directives/ion-app.d.ts +12 -0
- package/dist/standalone/directives/ion-app.js +36 -0
- package/dist/standalone/directives/ion-app.js.map +1 -0
- package/dist/standalone/directives/ion-avatar.d.ts +12 -0
- package/dist/standalone/directives/ion-avatar.js +35 -0
- package/dist/standalone/directives/ion-avatar.js.map +1 -0
- package/dist/standalone/directives/ion-backdrop.d.ts +18 -0
- package/dist/standalone/directives/ion-backdrop.js +40 -0
- package/dist/standalone/directives/ion-backdrop.js.map +1 -0
- package/dist/standalone/directives/ion-badge.d.ts +12 -0
- package/dist/standalone/directives/ion-badge.js +36 -0
- package/dist/standalone/directives/ion-badge.js.map +1 -0
- package/dist/standalone/directives/ion-breadcrumb.d.ts +23 -0
- package/dist/standalone/directives/ion-breadcrumb.js +43 -0
- package/dist/standalone/directives/ion-breadcrumb.js.map +1 -0
- package/dist/standalone/directives/ion-breadcrumbs.d.ts +19 -0
- package/dist/standalone/directives/ion-breadcrumbs.js +40 -0
- package/dist/standalone/directives/ion-breadcrumbs.js.map +1 -0
- package/dist/standalone/directives/ion-button.d.ts +23 -0
- package/dist/standalone/directives/ion-button.js +43 -0
- package/dist/standalone/directives/ion-button.js.map +1 -0
- package/dist/standalone/directives/ion-buttons.d.ts +12 -0
- package/dist/standalone/directives/ion-buttons.js +36 -0
- package/dist/standalone/directives/ion-buttons.js.map +1 -0
- package/dist/standalone/directives/ion-card-content.d.ts +12 -0
- package/dist/standalone/directives/ion-card-content.js +36 -0
- package/dist/standalone/directives/ion-card-content.js.map +1 -0
- package/dist/standalone/directives/ion-card-header.d.ts +12 -0
- package/dist/standalone/directives/ion-card-header.js +36 -0
- package/dist/standalone/directives/ion-card-header.js.map +1 -0
- package/dist/standalone/directives/ion-card-subtitle.d.ts +12 -0
- package/dist/standalone/directives/ion-card-subtitle.js +36 -0
- package/dist/standalone/directives/ion-card-subtitle.js.map +1 -0
- package/dist/standalone/directives/ion-card-title.d.ts +12 -0
- package/dist/standalone/directives/ion-card-title.js +36 -0
- package/dist/standalone/directives/ion-card-title.js.map +1 -0
- package/dist/standalone/directives/ion-card.d.ts +12 -0
- package/dist/standalone/directives/ion-card.js +36 -0
- package/dist/standalone/directives/ion-card.js.map +1 -0
- package/dist/standalone/directives/ion-chip.d.ts +12 -0
- package/dist/standalone/directives/ion-chip.js +36 -0
- package/dist/standalone/directives/ion-chip.js.map +1 -0
- package/dist/standalone/directives/ion-col.d.ts +12 -0
- package/dist/standalone/directives/ion-col.js +36 -0
- package/dist/standalone/directives/ion-col.js.map +1 -0
- package/dist/standalone/directives/ion-content.d.ts +33 -0
- package/dist/standalone/directives/ion-content.js +47 -0
- package/dist/standalone/directives/ion-content.js.map +1 -0
- package/dist/standalone/directives/ion-datetime-button.d.ts +12 -0
- package/dist/standalone/directives/ion-datetime-button.js +36 -0
- package/dist/standalone/directives/ion-datetime-button.js.map +1 -0
- package/dist/standalone/directives/ion-fab-button.d.ts +23 -0
- package/dist/standalone/directives/ion-fab-button.js +43 -0
- package/dist/standalone/directives/ion-fab-button.js.map +1 -0
- package/dist/standalone/directives/ion-fab-list.d.ts +12 -0
- package/dist/standalone/directives/ion-fab-list.js +36 -0
- package/dist/standalone/directives/ion-fab-list.js.map +1 -0
- package/dist/standalone/directives/ion-fab.d.ts +12 -0
- package/dist/standalone/directives/ion-fab.js +37 -0
- package/dist/standalone/directives/ion-fab.js.map +1 -0
- package/dist/standalone/directives/ion-footer.d.ts +12 -0
- package/dist/standalone/directives/ion-footer.js +36 -0
- package/dist/standalone/directives/ion-footer.js.map +1 -0
- package/dist/standalone/directives/ion-grid.d.ts +12 -0
- package/dist/standalone/directives/ion-grid.js +36 -0
- package/dist/standalone/directives/ion-grid.js.map +1 -0
- package/dist/standalone/directives/ion-header.d.ts +12 -0
- package/dist/standalone/directives/ion-header.js +36 -0
- package/dist/standalone/directives/ion-header.js.map +1 -0
- package/dist/standalone/directives/ion-img.d.ts +28 -0
- package/dist/standalone/directives/ion-img.js +46 -0
- package/dist/standalone/directives/ion-img.js.map +1 -0
- package/dist/standalone/directives/ion-infinite-scroll-content.d.ts +12 -0
- package/dist/standalone/directives/ion-infinite-scroll-content.js +36 -0
- package/dist/standalone/directives/ion-infinite-scroll-content.js.map +1 -0
- package/dist/standalone/directives/ion-infinite-scroll.d.ts +21 -0
- package/dist/standalone/directives/ion-infinite-scroll.js +41 -0
- package/dist/standalone/directives/ion-infinite-scroll.js.map +1 -0
- package/dist/standalone/directives/ion-input-password-toggle.d.ts +12 -0
- package/dist/standalone/directives/ion-input-password-toggle.js +36 -0
- package/dist/standalone/directives/ion-input-password-toggle.js.map +1 -0
- package/dist/standalone/directives/ion-item-divider.d.ts +12 -0
- package/dist/standalone/directives/ion-item-divider.js +36 -0
- package/dist/standalone/directives/ion-item-divider.js.map +1 -0
- package/dist/standalone/directives/ion-item-group.d.ts +12 -0
- package/dist/standalone/directives/ion-item-group.js +35 -0
- package/dist/standalone/directives/ion-item-group.js.map +1 -0
- package/dist/standalone/directives/ion-item-option.d.ts +12 -0
- package/dist/standalone/directives/ion-item-option.js +36 -0
- package/dist/standalone/directives/ion-item-option.js.map +1 -0
- package/dist/standalone/directives/ion-item-options.d.ts +18 -0
- package/dist/standalone/directives/ion-item-options.js +40 -0
- package/dist/standalone/directives/ion-item-options.js.map +1 -0
- package/dist/standalone/directives/ion-item-sliding.d.ts +18 -0
- package/dist/standalone/directives/ion-item-sliding.js +41 -0
- package/dist/standalone/directives/ion-item-sliding.js.map +1 -0
- package/dist/standalone/directives/ion-item.d.ts +12 -0
- package/dist/standalone/directives/ion-item.js +36 -0
- package/dist/standalone/directives/ion-item.js.map +1 -0
- package/dist/standalone/directives/ion-label.d.ts +12 -0
- package/dist/standalone/directives/ion-label.js +36 -0
- package/dist/standalone/directives/ion-label.js.map +1 -0
- package/dist/standalone/directives/ion-list-header.d.ts +12 -0
- package/dist/standalone/directives/ion-list-header.js +36 -0
- package/dist/standalone/directives/ion-list-header.js.map +1 -0
- package/dist/standalone/directives/ion-list.d.ts +12 -0
- package/dist/standalone/directives/ion-list.js +37 -0
- package/dist/standalone/directives/ion-list.js.map +1 -0
- package/dist/standalone/directives/ion-loading.d.ts +58 -0
- package/dist/standalone/directives/ion-loading.js +62 -0
- package/dist/standalone/directives/ion-loading.js.map +1 -0
- package/dist/standalone/directives/ion-menu-button.d.ts +12 -0
- package/dist/standalone/directives/ion-menu-button.js +36 -0
- package/dist/standalone/directives/ion-menu-button.js.map +1 -0
- package/dist/standalone/directives/ion-menu-toggle.d.ts +12 -0
- package/dist/standalone/directives/ion-menu-toggle.js +36 -0
- package/dist/standalone/directives/ion-menu-toggle.js.map +1 -0
- package/dist/standalone/directives/ion-menu.d.ts +34 -0
- package/dist/standalone/directives/ion-menu.js +50 -0
- package/dist/standalone/directives/ion-menu.js.map +1 -0
- package/dist/standalone/directives/ion-nav-link.d.ts +12 -0
- package/dist/standalone/directives/ion-nav-link.js +36 -0
- package/dist/standalone/directives/ion-nav-link.js.map +1 -0
- package/dist/standalone/directives/ion-note.d.ts +12 -0
- package/dist/standalone/directives/ion-note.js +36 -0
- package/dist/standalone/directives/ion-note.js.map +1 -0
- package/dist/standalone/directives/ion-picker-column-option.d.ts +12 -0
- package/dist/standalone/directives/ion-picker-column-option.js +36 -0
- package/dist/standalone/directives/ion-picker-column-option.js.map +1 -0
- package/dist/standalone/directives/ion-picker-column.d.ts +21 -0
- package/dist/standalone/directives/ion-picker-column.js +41 -0
- package/dist/standalone/directives/ion-picker-column.js.map +1 -0
- package/dist/standalone/directives/ion-picker.d.ts +12 -0
- package/dist/standalone/directives/ion-picker.js +36 -0
- package/dist/standalone/directives/ion-picker.js.map +1 -0
- package/dist/standalone/directives/ion-progress-bar.d.ts +12 -0
- package/dist/standalone/directives/ion-progress-bar.js +36 -0
- package/dist/standalone/directives/ion-progress-bar.js.map +1 -0
- package/dist/standalone/directives/ion-radio.d.ts +23 -0
- package/dist/standalone/directives/ion-radio.js +43 -0
- package/dist/standalone/directives/ion-radio.js.map +1 -0
- package/dist/standalone/directives/ion-refresher-content.d.ts +12 -0
- package/dist/standalone/directives/ion-refresher-content.js +36 -0
- package/dist/standalone/directives/ion-refresher-content.js.map +1 -0
- package/dist/standalone/directives/ion-refresher.d.ts +45 -0
- package/dist/standalone/directives/ion-refresher.js +53 -0
- package/dist/standalone/directives/ion-refresher.js.map +1 -0
- package/dist/standalone/directives/ion-reorder-group.d.ts +44 -0
- package/dist/standalone/directives/ion-reorder-group.js +50 -0
- package/dist/standalone/directives/ion-reorder-group.js.map +1 -0
- package/dist/standalone/directives/ion-reorder.d.ts +12 -0
- package/dist/standalone/directives/ion-reorder.js +35 -0
- package/dist/standalone/directives/ion-reorder.js.map +1 -0
- package/dist/standalone/directives/ion-ripple-effect.d.ts +12 -0
- package/dist/standalone/directives/ion-ripple-effect.js +37 -0
- package/dist/standalone/directives/ion-ripple-effect.js.map +1 -0
- package/dist/standalone/directives/ion-row.d.ts +12 -0
- package/dist/standalone/directives/ion-row.js +35 -0
- package/dist/standalone/directives/ion-row.js.map +1 -0
- package/dist/standalone/directives/ion-segment-button.d.ts +12 -0
- package/dist/standalone/directives/ion-segment-button.js +36 -0
- package/dist/standalone/directives/ion-segment-button.js.map +1 -0
- package/dist/standalone/directives/ion-segment-content.d.ts +12 -0
- package/dist/standalone/directives/ion-segment-content.js +35 -0
- package/dist/standalone/directives/ion-segment-content.js.map +1 -0
- package/dist/standalone/directives/ion-segment-view.d.ts +19 -0
- package/dist/standalone/directives/ion-segment-view.js +40 -0
- package/dist/standalone/directives/ion-segment-view.js.map +1 -0
- package/dist/standalone/directives/ion-select-modal.d.ts +12 -0
- package/dist/standalone/directives/ion-select-modal.js +36 -0
- package/dist/standalone/directives/ion-select-modal.js.map +1 -0
- package/dist/standalone/directives/ion-select-option.d.ts +12 -0
- package/dist/standalone/directives/ion-select-option.js +36 -0
- package/dist/standalone/directives/ion-select-option.js.map +1 -0
- package/dist/standalone/directives/ion-skeleton-text.d.ts +12 -0
- package/dist/standalone/directives/ion-skeleton-text.js +36 -0
- package/dist/standalone/directives/ion-skeleton-text.js.map +1 -0
- package/dist/standalone/directives/ion-spinner.d.ts +12 -0
- package/dist/standalone/directives/ion-spinner.js +36 -0
- package/dist/standalone/directives/ion-spinner.js.map +1 -0
- package/dist/standalone/directives/ion-split-pane.d.ts +22 -0
- package/dist/standalone/directives/ion-split-pane.js +40 -0
- package/dist/standalone/directives/ion-split-pane.js.map +1 -0
- package/dist/standalone/directives/ion-tab-bar.d.ts +12 -0
- package/dist/standalone/directives/ion-tab-bar.js +36 -0
- package/dist/standalone/directives/ion-tab-bar.js.map +1 -0
- package/dist/standalone/directives/ion-tab-button.d.ts +12 -0
- package/dist/standalone/directives/ion-tab-button.js +36 -0
- package/dist/standalone/directives/ion-tab-button.js.map +1 -0
- package/dist/standalone/directives/ion-tab.d.ts +12 -0
- package/dist/standalone/directives/ion-tab.js +37 -0
- package/dist/standalone/directives/ion-tab.js.map +1 -0
- package/dist/standalone/directives/ion-text.d.ts +12 -0
- package/dist/standalone/directives/ion-text.js +36 -0
- package/dist/standalone/directives/ion-text.js.map +1 -0
- package/dist/standalone/directives/ion-thumbnail.d.ts +12 -0
- package/dist/standalone/directives/ion-thumbnail.js +35 -0
- package/dist/standalone/directives/ion-thumbnail.js.map +1 -0
- package/dist/standalone/directives/ion-title.d.ts +12 -0
- package/dist/standalone/directives/ion-title.js +36 -0
- package/dist/standalone/directives/ion-title.js.map +1 -0
- package/dist/standalone/directives/ion-toast.d.ts +58 -0
- package/dist/standalone/directives/ion-toast.js +62 -0
- package/dist/standalone/directives/ion-toast.js.map +1 -0
- package/dist/standalone/directives/ion-toolbar.d.ts +12 -0
- package/dist/standalone/directives/ion-toolbar.js +36 -0
- package/dist/standalone/directives/ion-toolbar.js.map +1 -0
- package/dist/standalone/directives/proxies.d.ts +77 -0
- package/dist/standalone/directives/proxies.js +79 -0
- package/dist/standalone/directives/proxies.js.map +1 -0
- package/dist/standalone/directives/radio-group.js +59 -0
- package/dist/standalone/directives/radio-group.js.map +1 -0
- package/dist/standalone/directives/range.js +77 -0
- package/dist/standalone/directives/range.js.map +1 -0
- package/dist/standalone/directives/searchbar.js +81 -0
- package/dist/standalone/directives/searchbar.js.map +1 -0
- package/dist/standalone/directives/segment.js +59 -0
- package/dist/standalone/directives/segment.js.map +1 -0
- package/dist/standalone/directives/select.js +83 -0
- package/dist/standalone/directives/select.js.map +1 -0
- package/dist/standalone/directives/textarea.js +90 -0
- package/dist/standalone/directives/textarea.js.map +1 -0
- package/dist/standalone/directives/toggle.js +75 -0
- package/dist/standalone/directives/toggle.js.map +1 -0
- package/{standalone → dist/standalone}/index.d.ts +1 -2
- package/dist/standalone/index.js +24 -0
- package/dist/standalone/index.js.map +1 -0
- package/dist/standalone/navigation/back-button.js +32 -0
- package/dist/standalone/navigation/back-button.js.map +1 -0
- package/dist/standalone/navigation/nav.js +28 -0
- package/dist/standalone/navigation/nav.js.map +1 -0
- package/dist/standalone/navigation/router-link-delegate.js +26 -0
- package/dist/standalone/navigation/router-link-delegate.js.map +1 -0
- package/dist/standalone/navigation/router-outlet.js +60 -0
- package/dist/standalone/navigation/router-outlet.js.map +1 -0
- package/dist/standalone/navigation/tabs.js +57 -0
- package/dist/standalone/navigation/tabs.js.map +1 -0
- package/dist/standalone/overlays/modal.js +32 -0
- package/dist/standalone/overlays/modal.js.map +1 -0
- package/dist/standalone/overlays/popover.js +28 -0
- package/dist/standalone/overlays/popover.js.map +1 -0
- package/dist/standalone/providers/action-sheet-controller.js +20 -0
- package/dist/standalone/providers/action-sheet-controller.js.map +1 -0
- package/dist/standalone/providers/alert-controller.js +20 -0
- package/dist/standalone/providers/alert-controller.js.map +1 -0
- package/dist/standalone/providers/animation-controller.js +37 -0
- package/dist/standalone/providers/animation-controller.js.map +1 -0
- package/dist/standalone/providers/gesture-controller.js +32 -0
- package/dist/standalone/providers/gesture-controller.js.map +1 -0
- package/dist/standalone/providers/ionic-angular.js +38 -0
- package/dist/standalone/providers/ionic-angular.js.map +1 -0
- package/dist/standalone/providers/loading-controller.js +20 -0
- package/dist/standalone/providers/loading-controller.js.map +1 -0
- package/dist/standalone/providers/menu-controller.js +18 -0
- package/dist/standalone/providers/menu-controller.js.map +1 -0
- package/dist/standalone/providers/modal-controller.js +27 -0
- package/dist/standalone/providers/modal-controller.js.map +1 -0
- package/dist/standalone/providers/popover-controller.js +21 -0
- package/dist/standalone/providers/popover-controller.js.map +1 -0
- package/dist/standalone/providers/toast-controller.js +20 -0
- package/dist/standalone/providers/toast-controller.js.map +1 -0
- package/package.json +172 -30
- package/esm2022/app-initialize.mjs +0 -29
- package/esm2022/common/directives/control-value-accessors/index.mjs +0 -2
- package/esm2022/common/directives/control-value-accessors/value-accessor.mjs +0 -153
- package/esm2022/common/directives/navigation/back-button.mjs +0 -61
- package/esm2022/common/directives/navigation/nav-params.mjs +0 -47
- package/esm2022/common/directives/navigation/nav.mjs +0 -49
- package/esm2022/common/directives/navigation/router-link-delegate.mjs +0 -190
- package/esm2022/common/directives/navigation/router-outlet.mjs +0 -480
- package/esm2022/common/directives/navigation/stack-controller.mjs +0 -283
- package/esm2022/common/directives/navigation/stack-utils.mjs +0 -73
- package/esm2022/common/directives/navigation/tabs.mjs +0 -279
- package/esm2022/common/index.mjs +0 -20
- package/esm2022/common/ionic-angular-common.mjs +0 -5
- package/esm2022/common/overlays/modal.mjs +0 -103
- package/esm2022/common/overlays/popover.mjs +0 -91
- package/esm2022/common/providers/angular-delegate.mjs +0 -210
- package/esm2022/common/providers/config.mjs +0 -45
- package/esm2022/common/providers/dom-controller.mjs +0 -45
- package/esm2022/common/providers/menu-controller.mjs +0 -114
- package/esm2022/common/providers/nav-controller.mjs +0 -235
- package/esm2022/common/providers/platform.mjs +0 -258
- package/esm2022/common/types/interfaces.mjs +0 -2
- package/esm2022/common/types/ionic-lifecycle-hooks.mjs +0 -5
- package/esm2022/common/types/overlay-options.mjs +0 -2
- package/esm2022/common/utils/overlay.mjs +0 -26
- package/esm2022/common/utils/proxy.mjs +0 -47
- package/esm2022/common/utils/routing.mjs +0 -55
- package/esm2022/common/utils/util.mjs +0 -10
- package/esm2022/directives/angular-component-lib/utils.mjs +0 -59
- package/esm2022/directives/control-value-accessors/boolean-value-accessor.mjs +0 -42
- package/esm2022/directives/control-value-accessors/index.mjs +0 -5
- package/esm2022/directives/control-value-accessors/numeric-value-accessor.mjs +0 -50
- package/esm2022/directives/control-value-accessors/select-value-accessor.mjs +0 -39
- package/esm2022/directives/control-value-accessors/text-value-accessor.mjs +0 -38
- package/esm2022/directives/navigation/ion-back-button.mjs +0 -24
- package/esm2022/directives/navigation/ion-nav.mjs +0 -21
- package/esm2022/directives/navigation/ion-router-outlet.mjs +0 -52
- package/esm2022/directives/navigation/ion-tabs.mjs +0 -59
- package/esm2022/directives/navigation/router-link-delegate.mjs +0 -32
- package/esm2022/directives/overlays/modal.mjs +0 -22
- package/esm2022/directives/overlays/popover.mjs +0 -18
- package/esm2022/directives/proxies-list.mjs +0 -90
- package/esm2022/directives/proxies.mjs +0 -2373
- package/esm2022/directives/validators/index.mjs +0 -3
- package/esm2022/directives/validators/max-validator.mjs +0 -27
- package/esm2022/directives/validators/min-validator.mjs +0 -27
- package/esm2022/index.mjs +0 -32
- package/esm2022/ionic-angular.mjs +0 -5
- package/esm2022/ionic-module.mjs +0 -111
- package/esm2022/providers/action-sheet-controller.mjs +0 -19
- package/esm2022/providers/alert-controller.mjs +0 -19
- package/esm2022/providers/animation-controller.mjs +0 -38
- package/esm2022/providers/gesture-controller.mjs +0 -33
- package/esm2022/providers/loading-controller.mjs +0 -19
- package/esm2022/providers/menu-controller.mjs +0 -19
- package/esm2022/providers/modal-controller.mjs +0 -26
- package/esm2022/providers/picker-controller.mjs +0 -22
- package/esm2022/providers/popover-controller.mjs +0 -19
- package/esm2022/providers/toast-controller.mjs +0 -19
- package/esm2022/standalone/directives/angular-component-lib/utils.mjs +0 -59
- package/esm2022/standalone/directives/checkbox.mjs +0 -76
- package/esm2022/standalone/directives/datetime.mjs +0 -95
- package/esm2022/standalone/directives/icon.mjs +0 -35
- package/esm2022/standalone/directives/index.mjs +0 -13
- package/esm2022/standalone/directives/input-otp.mjs +0 -90
- package/esm2022/standalone/directives/input.mjs +0 -113
- package/esm2022/standalone/directives/proxies.mjs +0 -2260
- package/esm2022/standalone/directives/radio-group.mjs +0 -60
- package/esm2022/standalone/directives/range.mjs +0 -78
- package/esm2022/standalone/directives/searchbar.mjs +0 -82
- package/esm2022/standalone/directives/segment.mjs +0 -60
- package/esm2022/standalone/directives/select.mjs +0 -84
- package/esm2022/standalone/directives/textarea.mjs +0 -91
- package/esm2022/standalone/directives/toggle.mjs +0 -76
- package/esm2022/standalone/index.mjs +0 -25
- package/esm2022/standalone/ionic-angular-standalone.mjs +0 -5
- package/esm2022/standalone/navigation/back-button.mjs +0 -32
- package/esm2022/standalone/navigation/nav.mjs +0 -28
- package/esm2022/standalone/navigation/router-link-delegate.mjs +0 -28
- package/esm2022/standalone/navigation/router-outlet.mjs +0 -60
- package/esm2022/standalone/navigation/tabs.mjs +0 -58
- package/esm2022/standalone/overlays/modal.mjs +0 -32
- package/esm2022/standalone/overlays/popover.mjs +0 -28
- package/esm2022/standalone/providers/action-sheet-controller.mjs +0 -21
- package/esm2022/standalone/providers/alert-controller.mjs +0 -21
- package/esm2022/standalone/providers/animation-controller.mjs +0 -38
- package/esm2022/standalone/providers/gesture-controller.mjs +0 -33
- package/esm2022/standalone/providers/ionic-angular.mjs +0 -38
- package/esm2022/standalone/providers/loading-controller.mjs +0 -21
- package/esm2022/standalone/providers/menu-controller.mjs +0 -19
- package/esm2022/standalone/providers/modal-controller.mjs +0 -28
- package/esm2022/standalone/providers/picker-controller.mjs +0 -24
- package/esm2022/standalone/providers/popover-controller.mjs +0 -21
- package/esm2022/standalone/providers/toast-controller.mjs +0 -21
- package/fesm2022/ionic-angular-common.mjs +0 -2791
- package/fesm2022/ionic-angular-common.mjs.map +0 -1
- package/fesm2022/ionic-angular-standalone.mjs +0 -3562
- package/fesm2022/ionic-angular-standalone.mjs.map +0 -1
- package/fesm2022/ionic-angular.mjs +0 -3139
- package/fesm2022/ionic-angular.mjs.map +0 -1
- package/ionic-module.d.ts +0 -28
- package/providers/picker-controller.d.ts +0 -11
- package/schematics/utils/ast.js +0 -32
- package/standalone/directives/proxies.d.ts +0 -1035
- package/standalone/providers/picker-controller.d.ts +0 -11
- /package/{common → dist/common}/directives/control-value-accessors/index.d.ts +0 -0
- /package/{common → dist/common}/directives/navigation/nav-params.d.ts +0 -0
- /package/{common → dist/common}/directives/navigation/stack-controller.d.ts +0 -0
- /package/{common → dist/common}/directives/navigation/stack-utils.d.ts +0 -0
- /package/{common → dist/common}/providers/config.d.ts +0 -0
- /package/{common → dist/common}/providers/dom-controller.d.ts +0 -0
- /package/{common → dist/common}/providers/menu-controller.d.ts +0 -0
- /package/{common → dist/common}/providers/nav-controller.d.ts +0 -0
- /package/{common → dist/common}/providers/platform.d.ts +0 -0
- /package/{common → dist/common}/types/interfaces.d.ts +0 -0
- /package/{common → dist/common}/types/ionic-lifecycle-hooks.d.ts +0 -0
- /package/{common → dist/common}/types/overlay-options.d.ts +0 -0
- /package/{common → dist/common}/utils/overlay.d.ts +0 -0
- /package/{common → dist/common}/utils/proxy.d.ts +0 -0
- /package/{common → dist/common}/utils/routing.d.ts +0 -0
- /package/{common → dist/common}/utils/util.d.ts +0 -0
- /package/{app-initialize.d.ts → dist/lazy/app-initialize.d.ts} +0 -0
- /package/{directives → dist/lazy/directives}/angular-component-lib/utils.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/control-value-accessors/index.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/navigation/ion-back-button.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/navigation/ion-nav.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/navigation/ion-router-outlet.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/navigation/ion-tabs.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/navigation/router-link-delegate.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/overlays/modal.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/overlays/popover.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/validators/index.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/validators/max-validator.d.ts +0 -0
- /package/{directives → dist/lazy/directives}/validators/min-validator.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/action-sheet-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/alert-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/animation-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/gesture-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/loading-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/menu-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/modal-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/popover-controller.d.ts +0 -0
- /package/{providers → dist/lazy/providers}/toast-controller.d.ts +0 -0
- /package/{schematics → dist/schematics}/add/files/root/theme/variables.css +0 -0
- /package/{schematics → dist/schematics}/add/schema.json +0 -0
- /package/{schematics → dist/schematics}/collection.json +0 -0
- /package/{standalone → dist/standalone}/directives/angular-component-lib/utils.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/checkbox.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/datetime.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/icon.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/index.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/input-otp.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/input.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/radio-group.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/range.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/searchbar.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/segment.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/select.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/textarea.d.ts +0 -0
- /package/{standalone → dist/standalone}/directives/toggle.d.ts +0 -0
- /package/{standalone → dist/standalone}/navigation/back-button.d.ts +0 -0
- /package/{standalone → dist/standalone}/navigation/nav.d.ts +0 -0
- /package/{standalone → dist/standalone}/navigation/router-link-delegate.d.ts +0 -0
- /package/{standalone → dist/standalone}/navigation/router-outlet.d.ts +0 -0
- /package/{standalone → dist/standalone}/navigation/tabs.d.ts +0 -0
- /package/{standalone → dist/standalone}/overlays/modal.d.ts +0 -0
- /package/{standalone → dist/standalone}/overlays/popover.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/action-sheet-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/alert-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/animation-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/gesture-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/ionic-angular.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/loading-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/menu-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/modal-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/popover-controller.d.ts +0 -0
- /package/{standalone → dist/standalone}/providers/toast-controller.d.ts +0 -0
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
import { Directive, ElementRef, EventEmitter, HostListener, Output, ViewChild, } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import * as i1 from "../../providers/nav-controller";
|
|
4
|
+
/**
|
|
5
|
+
* Extracts `queryParams` and `fragment` from a tab button's href for use
|
|
6
|
+
* as Angular `NavigationExtras`. Returns `undefined` when neither is present.
|
|
7
|
+
*/
|
|
8
|
+
const parseHrefExtras = (href) => {
|
|
9
|
+
if (!href) {
|
|
10
|
+
return undefined;
|
|
11
|
+
}
|
|
12
|
+
const hashIndex = href.indexOf('#');
|
|
13
|
+
// Treat a bare `#` (no fragment text) as no fragment.
|
|
14
|
+
const fragment = hashIndex >= 0 && hashIndex < href.length - 1 ? href.slice(hashIndex + 1) : undefined;
|
|
15
|
+
const beforeHash = hashIndex >= 0 ? href.slice(0, hashIndex) : href;
|
|
16
|
+
const queryIndex = beforeHash.indexOf('?');
|
|
17
|
+
const search = queryIndex >= 0 ? beforeHash.slice(queryIndex + 1) : '';
|
|
18
|
+
let queryParams;
|
|
19
|
+
if (search) {
|
|
20
|
+
const params = new URLSearchParams(search);
|
|
21
|
+
queryParams = {};
|
|
22
|
+
for (const key of new Set(params.keys())) {
|
|
23
|
+
const all = params.getAll(key);
|
|
24
|
+
queryParams[key] = all.length > 1 ? all : all[0];
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
if (!queryParams && fragment === undefined) {
|
|
28
|
+
return undefined;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Build the result with only the populated keys so that a spread of the
|
|
32
|
+
* returned object does not overwrite saved `queryParams`/`fragment` with
|
|
33
|
+
* `undefined` (which `Object.assign`/spread would copy as a real key).
|
|
34
|
+
*/
|
|
35
|
+
const extras = {};
|
|
36
|
+
if (queryParams)
|
|
37
|
+
extras.queryParams = queryParams;
|
|
38
|
+
if (fragment !== undefined)
|
|
39
|
+
extras.fragment = fragment;
|
|
40
|
+
return extras;
|
|
41
|
+
};
|
|
42
|
+
export class IonTabs {
|
|
43
|
+
navCtrl;
|
|
44
|
+
tabsInner;
|
|
45
|
+
/**
|
|
46
|
+
* Emitted before the tab view is changed.
|
|
47
|
+
*/
|
|
48
|
+
ionTabsWillChange = new EventEmitter();
|
|
49
|
+
/**
|
|
50
|
+
* Emitted after the tab view is changed.
|
|
51
|
+
*/
|
|
52
|
+
ionTabsDidChange = new EventEmitter();
|
|
53
|
+
tabBarSlot = 'bottom';
|
|
54
|
+
hasTab = false;
|
|
55
|
+
selectedTab;
|
|
56
|
+
leavingTab;
|
|
57
|
+
constructor(navCtrl) {
|
|
58
|
+
this.navCtrl = navCtrl;
|
|
59
|
+
}
|
|
60
|
+
ngAfterViewInit() {
|
|
61
|
+
/**
|
|
62
|
+
* Developers must pass at least one ion-tab
|
|
63
|
+
* inside of ion-tabs if they want to use a
|
|
64
|
+
* basic tab-based navigation without the
|
|
65
|
+
* history stack or URL updates associated
|
|
66
|
+
* with the router.
|
|
67
|
+
*/
|
|
68
|
+
const firstTab = this.tabs.length > 0 ? this.tabs.first : undefined;
|
|
69
|
+
if (firstTab) {
|
|
70
|
+
this.hasTab = true;
|
|
71
|
+
this.setActiveTab(firstTab.tab);
|
|
72
|
+
this.tabSwitch();
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
ngAfterContentInit() {
|
|
76
|
+
this.detectSlotChanges();
|
|
77
|
+
}
|
|
78
|
+
ngAfterContentChecked() {
|
|
79
|
+
this.detectSlotChanges();
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* @internal
|
|
83
|
+
*/
|
|
84
|
+
onStackWillChange({ enteringView, tabSwitch }) {
|
|
85
|
+
const stackId = enteringView.stackId;
|
|
86
|
+
if (tabSwitch && stackId !== undefined) {
|
|
87
|
+
this.ionTabsWillChange.emit({ tab: stackId });
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* @internal
|
|
92
|
+
*/
|
|
93
|
+
onStackDidChange({ enteringView, tabSwitch }) {
|
|
94
|
+
const stackId = enteringView.stackId;
|
|
95
|
+
if (tabSwitch && stackId !== undefined) {
|
|
96
|
+
if (this.tabBar) {
|
|
97
|
+
this.tabBar.selectedTab = stackId;
|
|
98
|
+
}
|
|
99
|
+
this.ionTabsDidChange.emit({ tab: stackId });
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Host listener for the `ionTabButtonClick` event. Angular 22 enabled stricter
|
|
104
|
+
* host-binding type checking, which types `$event` as the DOM `Event`. That is
|
|
105
|
+
* not assignable to `select`'s public `string | CustomEvent` parameter, so this
|
|
106
|
+
* thin wrapper narrows the event before forwarding to keep `select`'s public
|
|
107
|
+
* signature intact.
|
|
108
|
+
*/
|
|
109
|
+
onTabButtonClick(ev) {
|
|
110
|
+
return this.select(ev);
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* When a tab button is clicked, there are several scenarios:
|
|
114
|
+
* 1. If the selected tab is currently active (the tab button has been clicked
|
|
115
|
+
* again), then it should go to the root view for that tab.
|
|
116
|
+
*
|
|
117
|
+
* a. Get the saved root view from the router outlet. If the saved root view
|
|
118
|
+
* matches the tabRootUrl, set the route view to this view including the
|
|
119
|
+
* navigation extras. Any `queryParams` or `fragment` declared on the tab
|
|
120
|
+
* button's `href` are also forwarded.
|
|
121
|
+
* b. If the saved root view from the router outlet does not match, navigate
|
|
122
|
+
* to the tabRootUrl, forwarding any `queryParams`/`fragment` declared on
|
|
123
|
+
* the tab button's `href`.
|
|
124
|
+
*
|
|
125
|
+
* 2. If the current tab tab is not currently selected, get the last route
|
|
126
|
+
* view from the router outlet.
|
|
127
|
+
*
|
|
128
|
+
* a. If the last route view exists, navigate to that view including any
|
|
129
|
+
* navigation extras.
|
|
130
|
+
* b. If the last route view doesn't exist, then navigate to the default
|
|
131
|
+
* tabRootUrl, forwarding any `queryParams`/`fragment` declared on the
|
|
132
|
+
* tab button's `href`.
|
|
133
|
+
*/
|
|
134
|
+
select(tabOrEvent) {
|
|
135
|
+
const isTabString = typeof tabOrEvent === 'string';
|
|
136
|
+
const tab = isTabString ? tabOrEvent : tabOrEvent.detail.tab;
|
|
137
|
+
const href = isTabString ? undefined : tabOrEvent.detail.href;
|
|
138
|
+
/**
|
|
139
|
+
* If the tabs are not using the router, then
|
|
140
|
+
* the tab switch logic is handled by the tabs
|
|
141
|
+
* component itself.
|
|
142
|
+
*/
|
|
143
|
+
if (this.hasTab) {
|
|
144
|
+
this.setActiveTab(tab);
|
|
145
|
+
this.tabSwitch();
|
|
146
|
+
return;
|
|
147
|
+
}
|
|
148
|
+
const alreadySelected = this.outlet.getActiveStackId() === tab;
|
|
149
|
+
const tabRootUrl = `${this.outlet.tabsPrefix}/${tab}`;
|
|
150
|
+
/**
|
|
151
|
+
* The href pathname is ignored here; tab routing is driven by `tabsPrefix/tab`.
|
|
152
|
+
* Only the query and fragment are forwarded as navigation extras.
|
|
153
|
+
*/
|
|
154
|
+
const hrefExtras = parseHrefExtras(href);
|
|
155
|
+
/**
|
|
156
|
+
* If this is a nested tab, prevent the event
|
|
157
|
+
* from bubbling otherwise the outer tabs
|
|
158
|
+
* will respond to this event too, causing
|
|
159
|
+
* the app to get directed to the wrong place.
|
|
160
|
+
*/
|
|
161
|
+
if (!isTabString) {
|
|
162
|
+
tabOrEvent.stopPropagation();
|
|
163
|
+
}
|
|
164
|
+
if (alreadySelected) {
|
|
165
|
+
const activeStackId = this.outlet.getActiveStackId();
|
|
166
|
+
const activeView = this.outlet.getLastRouteView(activeStackId);
|
|
167
|
+
// If on root tab, do not navigate to root tab again
|
|
168
|
+
if (activeView?.url === tabRootUrl) {
|
|
169
|
+
return;
|
|
170
|
+
}
|
|
171
|
+
const rootView = this.outlet.getRootView(tab);
|
|
172
|
+
// Keep the explicit rootView null-guard; an optional-chain rewrite changes the short-circuit value spread below.
|
|
173
|
+
// eslint-disable-next-line @typescript-eslint/prefer-optional-chain
|
|
174
|
+
const navigationExtras = rootView && tabRootUrl === rootView.url && rootView.savedExtras;
|
|
175
|
+
return this.navCtrl.navigateRoot(tabRootUrl, {
|
|
176
|
+
...navigationExtras,
|
|
177
|
+
...hrefExtras,
|
|
178
|
+
animated: true,
|
|
179
|
+
animationDirection: 'back',
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
else {
|
|
183
|
+
const lastRoute = this.outlet.getLastRouteView(tab);
|
|
184
|
+
/**
|
|
185
|
+
* If there is a lastRoute, goto that, otherwise goto the fallback url of the
|
|
186
|
+
* selected tab. When falling back to the tab root, honor query params and
|
|
187
|
+
* fragment declared on the tab button's href.
|
|
188
|
+
*/
|
|
189
|
+
const url = lastRoute?.url || tabRootUrl;
|
|
190
|
+
const navigationExtras = lastRoute?.savedExtras ?? (url === tabRootUrl ? hrefExtras : undefined);
|
|
191
|
+
return this.navCtrl.navigateRoot(url, {
|
|
192
|
+
...navigationExtras,
|
|
193
|
+
animated: true,
|
|
194
|
+
animationDirection: 'back',
|
|
195
|
+
});
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
setActiveTab(tab) {
|
|
199
|
+
const tabs = this.tabs;
|
|
200
|
+
const selectedTab = tabs.find((t) => t.tab === tab);
|
|
201
|
+
if (!selectedTab) {
|
|
202
|
+
console.error(`[Ionic Error]: Tab with id: "${tab}" does not exist`);
|
|
203
|
+
return;
|
|
204
|
+
}
|
|
205
|
+
this.leavingTab = this.selectedTab;
|
|
206
|
+
this.selectedTab = selectedTab;
|
|
207
|
+
this.ionTabsWillChange.emit({ tab });
|
|
208
|
+
selectedTab.el.active = true;
|
|
209
|
+
}
|
|
210
|
+
tabSwitch() {
|
|
211
|
+
const { selectedTab, leavingTab } = this;
|
|
212
|
+
if (this.tabBar && selectedTab) {
|
|
213
|
+
this.tabBar.selectedTab = selectedTab.tab;
|
|
214
|
+
}
|
|
215
|
+
if (leavingTab?.tab !== selectedTab?.tab) {
|
|
216
|
+
if (leavingTab?.el) {
|
|
217
|
+
leavingTab.el.active = false;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
if (selectedTab) {
|
|
221
|
+
this.ionTabsDidChange.emit({ tab: selectedTab.tab });
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
getSelected() {
|
|
225
|
+
if (this.hasTab) {
|
|
226
|
+
return this.selectedTab?.tab;
|
|
227
|
+
}
|
|
228
|
+
return this.outlet.getActiveStackId();
|
|
229
|
+
}
|
|
230
|
+
/**
|
|
231
|
+
* Detects changes to the slot attribute of the tab bar.
|
|
232
|
+
*
|
|
233
|
+
* If the slot attribute has changed, then the tab bar
|
|
234
|
+
* should be relocated to the new slot position.
|
|
235
|
+
*/
|
|
236
|
+
detectSlotChanges() {
|
|
237
|
+
this.tabBars.forEach((tabBar) => {
|
|
238
|
+
// el is a protected attribute from the generated component wrapper
|
|
239
|
+
const currentSlot = tabBar.el.getAttribute('slot');
|
|
240
|
+
if (currentSlot !== this.tabBarSlot) {
|
|
241
|
+
this.tabBarSlot = currentSlot;
|
|
242
|
+
this.relocateTabBar();
|
|
243
|
+
}
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* Relocates the tab bar to the new slot position.
|
|
248
|
+
*/
|
|
249
|
+
relocateTabBar() {
|
|
250
|
+
/**
|
|
251
|
+
* `el` is a protected attribute from the generated component wrapper.
|
|
252
|
+
* To avoid having to manually create the wrapper for tab bar, we
|
|
253
|
+
* cast the tab bar to any and access the protected attribute.
|
|
254
|
+
*/
|
|
255
|
+
const tabBar = this.tabBar.el;
|
|
256
|
+
if (this.tabBarSlot === 'top') {
|
|
257
|
+
/**
|
|
258
|
+
* A tab bar with a slot of "top" should be inserted
|
|
259
|
+
* at the top of the container.
|
|
260
|
+
*/
|
|
261
|
+
this.tabsInner.nativeElement.before(tabBar);
|
|
262
|
+
}
|
|
263
|
+
else {
|
|
264
|
+
/**
|
|
265
|
+
* A tab bar with a slot of "bottom" or without a slot
|
|
266
|
+
* should be inserted at the end of the container.
|
|
267
|
+
*/
|
|
268
|
+
this.tabsInner.nativeElement.after(tabBar);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
/** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonTabs, deps: [{ token: i1.NavController }], target: i0.ɵɵFactoryTarget.Directive });
|
|
272
|
+
/** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.0", type: IonTabs, isStandalone: true, selector: "ion-tabs", outputs: { ionTabsWillChange: "ionTabsWillChange", ionTabsDidChange: "ionTabsDidChange" }, host: { listeners: { "ionTabButtonClick": "onTabButtonClick($event)" } }, viewQueries: [{ propertyName: "tabsInner", first: true, predicate: ["tabsInner"], descendants: true, read: ElementRef, static: true }], ngImport: i0 });
|
|
273
|
+
}
|
|
274
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonTabs, decorators: [{
|
|
275
|
+
type: Directive,
|
|
276
|
+
args: [{
|
|
277
|
+
selector: 'ion-tabs',
|
|
278
|
+
}]
|
|
279
|
+
}], ctorParameters: () => [{ type: i1.NavController }], propDecorators: { tabsInner: [{
|
|
280
|
+
type: ViewChild,
|
|
281
|
+
args: ['tabsInner', { read: ElementRef, static: true }]
|
|
282
|
+
}], ionTabsWillChange: [{
|
|
283
|
+
type: Output
|
|
284
|
+
}], ionTabsDidChange: [{
|
|
285
|
+
type: Output
|
|
286
|
+
}], onTabButtonClick: [{
|
|
287
|
+
type: HostListener,
|
|
288
|
+
args: ['ionTabButtonClick', ['$event']]
|
|
289
|
+
}] } });
|
|
290
|
+
//# sourceMappingURL=tabs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tabs.js","sourceRoot":"","sources":["../../../../src/common/directives/navigation/tabs.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,SAAS,EACT,UAAU,EACV,YAAY,EACZ,YAAY,EACZ,MAAM,EACN,SAAS,GAGV,MAAM,eAAe,CAAC;;;AAOvB;;;GAGG;AACH,MAAM,eAAe,GAAG,CAAC,IAAwB,EAA2D,EAAE;IAC5G,IAAI,CAAC,IAAI,EAAE,CAAC;QACV,OAAO,SAAS,CAAC;IACnB,CAAC;IAED,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IACpC,sDAAsD;IACtD,MAAM,QAAQ,GAAG,SAAS,IAAI,CAAC,IAAI,SAAS,GAAG,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IACvG,MAAM,UAAU,GAAG,SAAS,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IAEpE,MAAM,UAAU,GAAG,UAAU,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IAC3C,MAAM,MAAM,GAAG,UAAU,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,KAAK,CAAC,UAAU,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;IAEvE,IAAI,WAA+B,CAAC;IACpC,IAAI,MAAM,EAAE,CAAC;QACX,MAAM,MAAM,GAAG,IAAI,eAAe,CAAC,MAAM,CAAC,CAAC;QAC3C,WAAW,GAAG,EAAE,CAAC;QACjB,KAAK,MAAM,GAAG,IAAI,IAAI,GAAG,CAAC,MAAM,CAA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AAM,CAAC,CAAC;QAC7C,CAAC;IACH,CAAC;0HA7QmB,OAAO;8GAAP,OAAO,4TAUK,UAAU;;2FAVtB,OAAO;kBAH5B,SAAS;mBAAC;oBACT,QAAQ,EAAE,UAAU;iBACrB;;sBAWE,SAAS;uBAAC,WAAW,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,IAAI,EAAE;;sBAKzD,MAAM;;sBAIN,MAAM;;sBAiEN,YAAY;uBAAC,mBAAmB,EAAE,CAAC,QAAQ,CAAC","sourcesContent":["import {\n AfterContentChecked,\n AfterContentInit,\n Directive,\n ElementRef,\n EventEmitter,\n HostListener,\n Output,\n ViewChild,\n AfterViewInit,\n QueryList,\n} from '@angular/core';\nimport type { Params } from '@angular/router';\n\nimport { NavController } from '../../providers/nav-controller';\n\nimport { StackDidChangeEvent, StackWillChangeEvent } from './stack-utils';\n\n/**\n * Extracts `queryParams` and `fragment` from a tab button's href for use\n * as Angular `NavigationExtras`. Returns `undefined` when neither is present.\n */\nconst parseHrefExtras = (href: string | undefined): { queryParams?: Params; fragment?: string } | undefined => {\n if (!href) {\n return undefined;\n }\n\n const hashIndex = href.indexOf('#');\n // Treat a bare `#` (no fragment text) as no fragment.\n const fragment = hashIndex >= 0 && hashIndex < href.length - 1 ? href.slice(hashIndex + 1) : undefined;\n const beforeHash = hashIndex >= 0 ? href.slice(0, hashIndex) : href;\n\n const queryIndex = beforeHash.indexOf('?');\n const search = queryIndex >= 0 ? beforeHash.slice(queryIndex + 1) : '';\n\n let queryParams: Params | undefined;\n if (search) {\n const params = new URLSearchParams(search);\n queryParams = {};\n for (const key of new Set(params.keys())) {\n const all = params.getAll(key);\n queryParams[key] = all.length > 1 ? all : all[0];\n }\n }\n\n if (!queryParams && fragment === undefined) {\n return undefined;\n }\n\n /**\n * Build the result with only the populated keys so that a spread of the\n * returned object does not overwrite saved `queryParams`/`fragment` with\n * `undefined` (which `Object.assign`/spread would copy as a real key).\n */\n const extras: { queryParams?: Params; fragment?: string } = {};\n if (queryParams) extras.queryParams = queryParams;\n if (fragment !== undefined) extras.fragment = fragment;\n return extras;\n};\n\n@Directive({\n selector: 'ion-tabs',\n})\nexport abstract class IonTabs implements AfterViewInit, AfterContentInit, AfterContentChecked {\n /**\n * Note: These must be redeclared on each child class since it needs\n * access to generated components such as IonRouterOutlet and IonTabBar.\n */\n abstract outlet: any;\n abstract tabBar: any;\n abstract tabBars: QueryList<any>;\n abstract tabs: QueryList<any>;\n\n @ViewChild('tabsInner', { read: ElementRef, static: true }) tabsInner: ElementRef<HTMLDivElement>;\n\n /**\n * Emitted before the tab view is changed.\n */\n @Output() ionTabsWillChange = new EventEmitter<{ tab: string }>();\n /**\n * Emitted after the tab view is changed.\n */\n @Output() ionTabsDidChange = new EventEmitter<{ tab: string }>();\n\n private tabBarSlot = 'bottom';\n\n private hasTab = false;\n private selectedTab?: { tab: string };\n private leavingTab?: any;\n\n constructor(private navCtrl: NavController) {}\n\n ngAfterViewInit(): void {\n /**\n * Developers must pass at least one ion-tab\n * inside of ion-tabs if they want to use a\n * basic tab-based navigation without the\n * history stack or URL updates associated\n * with the router.\n */\n const firstTab = this.tabs.length > 0 ? this.tabs.first : undefined;\n\n if (firstTab) {\n this.hasTab = true;\n this.setActiveTab(firstTab.tab);\n this.tabSwitch();\n }\n }\n\n ngAfterContentInit(): void {\n this.detectSlotChanges();\n }\n\n ngAfterContentChecked(): void {\n this.detectSlotChanges();\n }\n\n /**\n * @internal\n */\n onStackWillChange({ enteringView, tabSwitch }: StackWillChangeEvent): void {\n const stackId = enteringView.stackId;\n if (tabSwitch && stackId !== undefined) {\n this.ionTabsWillChange.emit({ tab: stackId });\n }\n }\n\n /**\n * @internal\n */\n onStackDidChange({ enteringView, tabSwitch }: StackDidChangeEvent): void {\n const stackId = enteringView.stackId;\n if (tabSwitch && stackId !== undefined) {\n if (this.tabBar) {\n this.tabBar.selectedTab = stackId;\n }\n this.ionTabsDidChange.emit({ tab: stackId });\n }\n }\n\n /**\n * Host listener for the `ionTabButtonClick` event. Angular 22 enabled stricter\n * host-binding type checking, which types `$event` as the DOM `Event`. That is\n * not assignable to `select`'s public `string | CustomEvent` parameter, so this\n * thin wrapper narrows the event before forwarding to keep `select`'s public\n * signature intact.\n */\n @HostListener('ionTabButtonClick', ['$event'])\n onTabButtonClick(ev: Event): Promise<boolean> | undefined {\n return this.select(ev as CustomEvent);\n }\n\n /**\n * When a tab button is clicked, there are several scenarios:\n * 1. If the selected tab is currently active (the tab button has been clicked\n * again), then it should go to the root view for that tab.\n *\n * a. Get the saved root view from the router outlet. If the saved root view\n * matches the tabRootUrl, set the route view to this view including the\n * navigation extras. Any `queryParams` or `fragment` declared on the tab\n * button's `href` are also forwarded.\n * b. If the saved root view from the router outlet does not match, navigate\n * to the tabRootUrl, forwarding any `queryParams`/`fragment` declared on\n * the tab button's `href`.\n *\n * 2. If the current tab tab is not currently selected, get the last route\n * view from the router outlet.\n *\n * a. If the last route view exists, navigate to that view including any\n * navigation extras.\n * b. If the last route view doesn't exist, then navigate to the default\n * tabRootUrl, forwarding any `queryParams`/`fragment` declared on the\n * tab button's `href`.\n */\n select(tabOrEvent: string | CustomEvent): Promise<boolean> | undefined {\n const isTabString = typeof tabOrEvent === 'string';\n const tab = isTabString ? tabOrEvent : (tabOrEvent as CustomEvent).detail.tab;\n const href: string | undefined = isTabString ? undefined : (tabOrEvent as CustomEvent).detail.href;\n\n /**\n * If the tabs are not using the router, then\n * the tab switch logic is handled by the tabs\n * component itself.\n */\n if (this.hasTab) {\n this.setActiveTab(tab);\n this.tabSwitch();\n\n return;\n }\n\n const alreadySelected = this.outlet.getActiveStackId() === tab;\n const tabRootUrl = `${this.outlet.tabsPrefix}/${tab}`;\n\n /**\n * The href pathname is ignored here; tab routing is driven by `tabsPrefix/tab`.\n * Only the query and fragment are forwarded as navigation extras.\n */\n const hrefExtras = parseHrefExtras(href);\n\n /**\n * If this is a nested tab, prevent the event\n * from bubbling otherwise the outer tabs\n * will respond to this event too, causing\n * the app to get directed to the wrong place.\n */\n if (!isTabString) {\n (tabOrEvent as CustomEvent).stopPropagation();\n }\n\n if (alreadySelected) {\n const activeStackId = this.outlet.getActiveStackId();\n const activeView = this.outlet.getLastRouteView(activeStackId);\n\n // If on root tab, do not navigate to root tab again\n if (activeView?.url === tabRootUrl) {\n return;\n }\n\n const rootView = this.outlet.getRootView(tab);\n // Keep the explicit rootView null-guard; an optional-chain rewrite changes the short-circuit value spread below.\n // eslint-disable-next-line @typescript-eslint/prefer-optional-chain\n const navigationExtras = rootView && tabRootUrl === rootView.url && rootView.savedExtras;\n return this.navCtrl.navigateRoot(tabRootUrl, {\n ...navigationExtras,\n ...hrefExtras,\n animated: true,\n animationDirection: 'back',\n });\n } else {\n const lastRoute = this.outlet.getLastRouteView(tab);\n /**\n * If there is a lastRoute, goto that, otherwise goto the fallback url of the\n * selected tab. When falling back to the tab root, honor query params and\n * fragment declared on the tab button's href.\n */\n const url = lastRoute?.url || tabRootUrl;\n const navigationExtras = lastRoute?.savedExtras ?? (url === tabRootUrl ? hrefExtras : undefined);\n\n return this.navCtrl.navigateRoot(url, {\n ...navigationExtras,\n animated: true,\n animationDirection: 'back',\n });\n }\n }\n\n private setActiveTab(tab: string): void {\n const tabs = this.tabs;\n const selectedTab = tabs.find((t: any) => t.tab === tab);\n\n if (!selectedTab) {\n console.error(`[Ionic Error]: Tab with id: \"${tab}\" does not exist`);\n return;\n }\n\n this.leavingTab = this.selectedTab;\n this.selectedTab = selectedTab;\n\n this.ionTabsWillChange.emit({ tab });\n\n selectedTab.el.active = true;\n }\n\n private tabSwitch(): void {\n const { selectedTab, leavingTab } = this;\n\n if (this.tabBar && selectedTab) {\n this.tabBar.selectedTab = selectedTab.tab;\n }\n\n if (leavingTab?.tab !== selectedTab?.tab) {\n if (leavingTab?.el) {\n leavingTab.el.active = false;\n }\n }\n\n if (selectedTab) {\n this.ionTabsDidChange.emit({ tab: selectedTab.tab });\n }\n }\n\n getSelected(): string | undefined {\n if (this.hasTab) {\n return this.selectedTab?.tab;\n }\n\n return this.outlet.getActiveStackId();\n }\n\n /**\n * Detects changes to the slot attribute of the tab bar.\n *\n * If the slot attribute has changed, then the tab bar\n * should be relocated to the new slot position.\n */\n private detectSlotChanges(): void {\n this.tabBars.forEach((tabBar: any) => {\n // el is a protected attribute from the generated component wrapper\n const currentSlot = tabBar.el.getAttribute('slot');\n\n if (currentSlot !== this.tabBarSlot) {\n this.tabBarSlot = currentSlot;\n this.relocateTabBar();\n }\n });\n }\n\n /**\n * Relocates the tab bar to the new slot position.\n */\n private relocateTabBar(): void {\n /**\n * `el` is a protected attribute from the generated component wrapper.\n * To avoid having to manually create the wrapper for tab bar, we\n * cast the tab bar to any and access the protected attribute.\n */\n const tabBar = (this.tabBar as any).el as HTMLElement;\n\n if (this.tabBarSlot === 'top') {\n /**\n * A tab bar with a slot of \"top\" should be inserted\n * at the top of the container.\n */\n this.tabsInner.nativeElement.before(tabBar);\n } else {\n /**\n * A tab bar with a slot of \"bottom\" or without a slot\n * should be inserted at the end of the container.\n */\n this.tabsInner.nativeElement.after(tabBar);\n }\n }\n}\n"]}
|
|
@@ -3,7 +3,7 @@ export { MenuController } from './providers/menu-controller';
|
|
|
3
3
|
export { NavController } from './providers/nav-controller';
|
|
4
4
|
export { Config, ConfigToken } from './providers/config';
|
|
5
5
|
export { Platform } from './providers/platform';
|
|
6
|
-
export { AngularDelegate,
|
|
6
|
+
export { AngularDelegate, IonModalToken } from './providers/angular-delegate';
|
|
7
7
|
export type { IonicWindow } from './types/interfaces';
|
|
8
8
|
export type { ViewDidEnter, ViewDidLeave, ViewWillEnter, ViewWillLeave } from './types/ionic-lifecycle-hooks';
|
|
9
9
|
export type { ModalOptions, PopoverOptions } from './types/overlay-options';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export { DomController } from './providers/dom-controller';
|
|
2
|
+
export { MenuController } from './providers/menu-controller';
|
|
3
|
+
export { NavController } from './providers/nav-controller';
|
|
4
|
+
export { Config, ConfigToken } from './providers/config';
|
|
5
|
+
export { Platform } from './providers/platform';
|
|
6
|
+
export { AngularDelegate, IonModalToken } from './providers/angular-delegate';
|
|
7
|
+
export { NavParams } from './directives/navigation/nav-params';
|
|
8
|
+
export { IonModal } from './overlays/modal';
|
|
9
|
+
export { IonPopover } from './overlays/popover';
|
|
10
|
+
export { IonRouterOutlet, provideComponentInputBinding } from './directives/navigation/router-outlet';
|
|
11
|
+
export * from './directives/control-value-accessors';
|
|
12
|
+
export { IonBackButton } from './directives/navigation/back-button';
|
|
13
|
+
export { IonNav } from './directives/navigation/nav';
|
|
14
|
+
export { RouterLinkDelegateDirective, RouterLinkWithHrefDelegateDirective, } from './directives/navigation/router-link-delegate';
|
|
15
|
+
export { IonTabs } from './directives/navigation/tabs';
|
|
16
|
+
export { ProxyCmp } from './utils/proxy';
|
|
17
|
+
export { OverlayBaseController } from './utils/overlay';
|
|
18
|
+
export { IonicRouteStrategy } from './utils/routing';
|
|
19
|
+
export { raf } from './utils/util';
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/common/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAE3D,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAM9E,OAAO,EAAE,SAAS,EAAE,MAAM,oCAAoC,CAAC;AAE/D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD,OAAO,EAAE,eAAe,EAAE,4BAA4B,EAAE,MAAM,uCAAuC,CAAC;AAEtG,cAAc,sCAAsC,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EAAE,MAAM,EAAE,MAAM,6BAA6B,CAAC;AACrD,OAAO,EACL,2BAA2B,EAC3B,mCAAmC,GACpC,MAAM,8CAA8C,CAAC;AACtD,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AAEvD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAEzC,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAErD,OAAO,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC","sourcesContent":["export { DomController } from './providers/dom-controller';\nexport { MenuController } from './providers/menu-controller';\nexport { NavController } from './providers/nav-controller';\n\nexport { Config, ConfigToken } from './providers/config';\nexport { Platform } from './providers/platform';\n\nexport { AngularDelegate, IonModalToken } from './providers/angular-delegate';\n\nexport type { IonicWindow } from './types/interfaces';\nexport type { ViewDidEnter, ViewDidLeave, ViewWillEnter, ViewWillLeave } from './types/ionic-lifecycle-hooks';\nexport type { ModalOptions, PopoverOptions } from './types/overlay-options';\n\nexport { NavParams } from './directives/navigation/nav-params';\n\nexport { IonModal } from './overlays/modal';\nexport { IonPopover } from './overlays/popover';\n\nexport { IonRouterOutlet, provideComponentInputBinding } from './directives/navigation/router-outlet';\n\nexport * from './directives/control-value-accessors';\nexport { IonBackButton } from './directives/navigation/back-button';\nexport { IonNav } from './directives/navigation/nav';\nexport {\n RouterLinkDelegateDirective,\n RouterLinkWithHrefDelegateDirective,\n} from './directives/navigation/router-link-delegate';\nexport { IonTabs } from './directives/navigation/tabs';\n\nexport { ProxyCmp } from './utils/proxy';\n\nexport { OverlayBaseController } from './utils/overlay';\nexport { IonicRouteStrategy } from './utils/routing';\n\nexport { raf } from './utils/util';\n"]}
|
|
@@ -58,5 +58,5 @@ export declare class IonModal {
|
|
|
58
58
|
protected el: HTMLElement;
|
|
59
59
|
constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone);
|
|
60
60
|
static ɵfac: i0.ɵɵFactoryDeclaration<IonModal, never>;
|
|
61
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<IonModal, "ion-modal", never, { "animated": { "alias": "animated"; "required": false; }; "keepContentsMounted": { "alias": "keepContentsMounted"; "required": false; }; "backdropBreakpoint": { "alias": "backdropBreakpoint"; "required": false; }; "backdropDismiss": { "alias": "backdropDismiss"; "required": false; }; "breakpoints": { "alias": "breakpoints"; "required": false; }; "canDismiss": { "alias": "canDismiss"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "enterAnimation": { "alias": "enterAnimation"; "required": false; }; "expandToScroll": { "alias": "expandToScroll"; "required": false; }; "event": { "alias": "event"; "required": false; }; "focusTrap": { "alias": "focusTrap"; "required": false; }; "handle": { "alias": "handle"; "required": false; }; "handleBehavior": { "alias": "handleBehavior"; "required": false; }; "initialBreakpoint": { "alias": "initialBreakpoint"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; "keyboardClose": { "alias": "keyboardClose"; "required": false; }; "leaveAnimation": { "alias": "leaveAnimation"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "presentingElement": { "alias": "presentingElement"; "required": false; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; }; "translucent": { "alias": "translucent"; "required": false; }; "trigger": { "alias": "trigger"; "required": false; }; }, {}, ["template"], never,
|
|
61
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<IonModal, "ion-modal", never, { "animated": { "alias": "animated"; "required": false; }; "keepContentsMounted": { "alias": "keepContentsMounted"; "required": false; }; "backdropBreakpoint": { "alias": "backdropBreakpoint"; "required": false; }; "backdropDismiss": { "alias": "backdropDismiss"; "required": false; }; "breakpoints": { "alias": "breakpoints"; "required": false; }; "canDismiss": { "alias": "canDismiss"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "enterAnimation": { "alias": "enterAnimation"; "required": false; }; "expandToScroll": { "alias": "expandToScroll"; "required": false; }; "event": { "alias": "event"; "required": false; }; "focusTrap": { "alias": "focusTrap"; "required": false; }; "handle": { "alias": "handle"; "required": false; }; "handleBehavior": { "alias": "handleBehavior"; "required": false; }; "initialBreakpoint": { "alias": "initialBreakpoint"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; "keyboardClose": { "alias": "keyboardClose"; "required": false; }; "leaveAnimation": { "alias": "leaveAnimation"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "presentingElement": { "alias": "presentingElement"; "required": false; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; }; "translucent": { "alias": "translucent"; "required": false; }; "trigger": { "alias": "trigger"; "required": false; }; }, {}, ["template"], never, true, never>;
|
|
62
62
|
}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { ContentChild, Directive, TemplateRef, } from '@angular/core';
|
|
3
|
+
import { ProxyCmp, proxyOutputs } from '../utils/proxy';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
const MODAL_INPUTS = [
|
|
6
|
+
'animated',
|
|
7
|
+
'keepContentsMounted',
|
|
8
|
+
'backdropBreakpoint',
|
|
9
|
+
'backdropDismiss',
|
|
10
|
+
'breakpoints',
|
|
11
|
+
'canDismiss',
|
|
12
|
+
'cssClass',
|
|
13
|
+
'enterAnimation',
|
|
14
|
+
'expandToScroll',
|
|
15
|
+
'event',
|
|
16
|
+
'focusTrap',
|
|
17
|
+
'handle',
|
|
18
|
+
'handleBehavior',
|
|
19
|
+
'initialBreakpoint',
|
|
20
|
+
'isOpen',
|
|
21
|
+
'keyboardClose',
|
|
22
|
+
'leaveAnimation',
|
|
23
|
+
'mode',
|
|
24
|
+
'presentingElement',
|
|
25
|
+
'showBackdrop',
|
|
26
|
+
'translucent',
|
|
27
|
+
'trigger',
|
|
28
|
+
];
|
|
29
|
+
const MODAL_METHODS = [
|
|
30
|
+
'present',
|
|
31
|
+
'dismiss',
|
|
32
|
+
'onDidDismiss',
|
|
33
|
+
'onWillDismiss',
|
|
34
|
+
'setCurrentBreakpoint',
|
|
35
|
+
'getCurrentBreakpoint',
|
|
36
|
+
];
|
|
37
|
+
let IonModal = class IonModal {
|
|
38
|
+
z;
|
|
39
|
+
// TODO(FW-2827): type
|
|
40
|
+
template;
|
|
41
|
+
isCmpOpen = false;
|
|
42
|
+
el;
|
|
43
|
+
constructor(c, r, z) {
|
|
44
|
+
this.z = z;
|
|
45
|
+
this.el = r.nativeElement;
|
|
46
|
+
this.el.addEventListener('ionMount', () => {
|
|
47
|
+
this.isCmpOpen = true;
|
|
48
|
+
c.detectChanges();
|
|
49
|
+
});
|
|
50
|
+
this.el.addEventListener('didDismiss', () => {
|
|
51
|
+
this.isCmpOpen = false;
|
|
52
|
+
c.detectChanges();
|
|
53
|
+
});
|
|
54
|
+
proxyOutputs(this, this.el, [
|
|
55
|
+
'ionModalDidPresent',
|
|
56
|
+
'ionModalWillPresent',
|
|
57
|
+
'ionModalWillDismiss',
|
|
58
|
+
'ionModalDidDismiss',
|
|
59
|
+
'ionBreakpointDidChange',
|
|
60
|
+
'didPresent',
|
|
61
|
+
'willPresent',
|
|
62
|
+
'willDismiss',
|
|
63
|
+
'didDismiss',
|
|
64
|
+
'ionDragStart',
|
|
65
|
+
'ionDragMove',
|
|
66
|
+
'ionDragEnd',
|
|
67
|
+
]);
|
|
68
|
+
}
|
|
69
|
+
/** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonModal, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
|
|
70
|
+
/** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.0", type: IonModal, isStandalone: true, selector: "ion-modal", inputs: { animated: "animated", keepContentsMounted: "keepContentsMounted", backdropBreakpoint: "backdropBreakpoint", backdropDismiss: "backdropDismiss", breakpoints: "breakpoints", canDismiss: "canDismiss", cssClass: "cssClass", enterAnimation: "enterAnimation", expandToScroll: "expandToScroll", event: "event", focusTrap: "focusTrap", handle: "handle", handleBehavior: "handleBehavior", initialBreakpoint: "initialBreakpoint", isOpen: "isOpen", keyboardClose: "keyboardClose", leaveAnimation: "leaveAnimation", mode: "mode", presentingElement: "presentingElement", showBackdrop: "showBackdrop", translucent: "translucent", trigger: "trigger" }, queries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }], ngImport: i0 });
|
|
71
|
+
};
|
|
72
|
+
IonModal = __decorate([
|
|
73
|
+
ProxyCmp({
|
|
74
|
+
inputs: MODAL_INPUTS,
|
|
75
|
+
methods: MODAL_METHODS,
|
|
76
|
+
})
|
|
77
|
+
/**
|
|
78
|
+
* @Component extends from @Directive
|
|
79
|
+
* so by defining the inputs here we
|
|
80
|
+
* do not need to re-define them for the
|
|
81
|
+
* lazy loaded popover.
|
|
82
|
+
*/
|
|
83
|
+
], IonModal);
|
|
84
|
+
export { IonModal };
|
|
85
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonModal, decorators: [{
|
|
86
|
+
type: Directive,
|
|
87
|
+
args: [{
|
|
88
|
+
selector: 'ion-modal',
|
|
89
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
90
|
+
inputs: MODAL_INPUTS,
|
|
91
|
+
}]
|
|
92
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }], propDecorators: { template: [{
|
|
93
|
+
type: ContentChild,
|
|
94
|
+
args: [TemplateRef, { static: false }]
|
|
95
|
+
}] } });
|
|
96
|
+
//# sourceMappingURL=modal.js.map
|
|
@@ -0,0 +1 @@
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C,CAAC,CAAC;QACH,YAAY,CAAC,IAAI,EAAE,IAAI,CAAC,EAAE,EAAE;YAC1B,oBAAoB;YACpB,qBAAqB;YACrB,qBAAqB;YACrB,oBAAoB;YACpB,wBAAwB;YACxB,YAAY;YACZ,aAAa;YACb,aAAa;YACb,YAAY;YACZ,cAAc;YACd,aAAa;YACb,YAAY;SACb,CAAC,CAAC;IACL,CAAC;0HAjCU,QAAQ;8GAAR,QAAQ,mvBAEL,WAAW;;AAFd,QAAQ;IAfpB,QAAQ,CAAC;QACR,MAAM,EAAE,YAAY;QACpB,OAAO,EAAE,aAAa;KACvB,CAAC;IACF;;;;;OAKG;GAMU,QAAQ,CAkCpB;;2FAlCY,QAAQ;kBALpB,SAAS;mBAAC;oBACT,QAAQ,EAAE,WAAW;oBACrB,uEAAuE;oBACvE,MAAM,EAAE,YAAY;iBACrB;;sBAGE,YAAY;uBAAC,WAAW,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE","sourcesContent":["import {\n ChangeDetectorRef,\n ContentChild,\n Directive,\n ElementRef,\n EventEmitter,\n NgZone,\n TemplateRef,\n} from '@angular/core';\nimport type { Components, ModalBreakpointChangeEventDetail, ModalDragEventDetail } from '@ionic/core/components';\n\nimport { ProxyCmp, proxyOutputs } from '../utils/proxy';\n\nexport declare interface IonModal extends Components.IonModal {\n /**\n * Emitted after the modal has presented.\n **/\n ionModalDidPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the modal has presented.\n */\n ionModalWillPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the modal has dismissed.\n */\n ionModalWillDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the modal has dismissed.\n */\n ionModalDidDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the modal breakpoint has changed.\n */\n ionBreakpointDidChange: EventEmitter<CustomEvent<ModalBreakpointChangeEventDetail>>;\n /**\n * Emitted when the sheet or card modal has started being dragged.\n */\n ionDragStart: EventEmitter<void>;\n /**\n * Emitted while the sheet or card modal is being dragged.\n */\n ionDragMove: EventEmitter<CustomEvent<ModalDragEventDetail>>;\n /**\n * Emitted when the sheet or card modal has finished being dragged.\n */\n ionDragEnd: EventEmitter<CustomEvent<ModalDragEventDetail>>;\n /**\n * Emitted after the modal has presented. Shorthand for ionModalDidPresent.\n */\n didPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the modal has presented. Shorthand for ionModalWillPresent.\n */\n willPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the modal has dismissed. Shorthand for ionModalWillDismiss.\n */\n willDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the modal has dismissed. Shorthand for ionModalDidDismiss.\n */\n didDismiss: EventEmitter<CustomEvent>;\n}\n\nconst MODAL_INPUTS = [\n 'animated',\n 'keepContentsMounted',\n 'backdropBreakpoint',\n 'backdropDismiss',\n 'breakpoints',\n 'canDismiss',\n 'cssClass',\n 'enterAnimation',\n 'expandToScroll',\n 'event',\n 'focusTrap',\n 'handle',\n 'handleBehavior',\n 'initialBreakpoint',\n 'isOpen',\n 'keyboardClose',\n 'leaveAnimation',\n 'mode',\n 'presentingElement',\n 'showBackdrop',\n 'translucent',\n 'trigger',\n];\n\nconst MODAL_METHODS = [\n 'present',\n 'dismiss',\n 'onDidDismiss',\n 'onWillDismiss',\n 'setCurrentBreakpoint',\n 'getCurrentBreakpoint',\n];\n\n@ProxyCmp({\n inputs: MODAL_INPUTS,\n methods: MODAL_METHODS,\n})\n/**\n * @Component extends from @Directive\n * so by defining the inputs here we\n * do not need to re-define them for the\n * lazy loaded popover.\n */\n@Directive({\n selector: 'ion-modal',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: MODAL_INPUTS,\n})\nexport class IonModal {\n // TODO(FW-2827): type\n @ContentChild(TemplateRef, { static: false }) template: TemplateRef<any>;\n\n isCmpOpen = false;\n\n protected el: HTMLElement;\n\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) {\n this.el = r.nativeElement;\n\n this.el.addEventListener('ionMount', () => {\n this.isCmpOpen = true;\n c.detectChanges();\n });\n this.el.addEventListener('didDismiss', () => {\n this.isCmpOpen = false;\n c.detectChanges();\n });\n proxyOutputs(this, this.el, [\n 'ionModalDidPresent',\n 'ionModalWillPresent',\n 'ionModalWillDismiss',\n 'ionModalDidDismiss',\n 'ionBreakpointDidChange',\n 'didPresent',\n 'willPresent',\n 'willDismiss',\n 'didDismiss',\n 'ionDragStart',\n 'ionDragMove',\n 'ionDragEnd',\n ]);\n }\n}\n"]}
|
|
@@ -42,5 +42,5 @@ export declare class IonPopover {
|
|
|
42
42
|
protected el: HTMLElement;
|
|
43
43
|
constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone);
|
|
44
44
|
static ɵfac: i0.ɵɵFactoryDeclaration<IonPopover, never>;
|
|
45
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<IonPopover, "ion-popover", never, { "alignment": { "alias": "alignment"; "required": false; }; "animated": { "alias": "animated"; "required": false; }; "arrow": { "alias": "arrow"; "required": false; }; "keepContentsMounted": { "alias": "keepContentsMounted"; "required": false; }; "backdropDismiss": { "alias": "backdropDismiss"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "dismissOnSelect": { "alias": "dismissOnSelect"; "required": false; }; "enterAnimation": { "alias": "enterAnimation"; "required": false; }; "event": { "alias": "event"; "required": false; }; "focusTrap": { "alias": "focusTrap"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; "keyboardClose": { "alias": "keyboardClose"; "required": false; }; "leaveAnimation": { "alias": "leaveAnimation"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; }; "translucent": { "alias": "translucent"; "required": false; }; "trigger": { "alias": "trigger"; "required": false; }; "triggerAction": { "alias": "triggerAction"; "required": false; }; "reference": { "alias": "reference"; "required": false; }; "size": { "alias": "size"; "required": false; }; "side": { "alias": "side"; "required": false; }; }, {}, ["template"], never,
|
|
45
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<IonPopover, "ion-popover", never, { "alignment": { "alias": "alignment"; "required": false; }; "animated": { "alias": "animated"; "required": false; }; "arrow": { "alias": "arrow"; "required": false; }; "keepContentsMounted": { "alias": "keepContentsMounted"; "required": false; }; "backdropDismiss": { "alias": "backdropDismiss"; "required": false; }; "cssClass": { "alias": "cssClass"; "required": false; }; "dismissOnSelect": { "alias": "dismissOnSelect"; "required": false; }; "enterAnimation": { "alias": "enterAnimation"; "required": false; }; "event": { "alias": "event"; "required": false; }; "focusTrap": { "alias": "focusTrap"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; "keyboardClose": { "alias": "keyboardClose"; "required": false; }; "leaveAnimation": { "alias": "leaveAnimation"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "showBackdrop": { "alias": "showBackdrop"; "required": false; }; "translucent": { "alias": "translucent"; "required": false; }; "trigger": { "alias": "trigger"; "required": false; }; "triggerAction": { "alias": "triggerAction"; "required": false; }; "reference": { "alias": "reference"; "required": false; }; "size": { "alias": "size"; "required": false; }; "side": { "alias": "side"; "required": false; }; }, {}, ["template"], never, true, never>;
|
|
46
46
|
}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { ContentChild, Directive, TemplateRef, } from '@angular/core';
|
|
3
|
+
import { ProxyCmp, proxyOutputs } from '../utils/proxy';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
const POPOVER_INPUTS = [
|
|
6
|
+
'alignment',
|
|
7
|
+
'animated',
|
|
8
|
+
'arrow',
|
|
9
|
+
'keepContentsMounted',
|
|
10
|
+
'backdropDismiss',
|
|
11
|
+
'cssClass',
|
|
12
|
+
'dismissOnSelect',
|
|
13
|
+
'enterAnimation',
|
|
14
|
+
'event',
|
|
15
|
+
'focusTrap',
|
|
16
|
+
'isOpen',
|
|
17
|
+
'keyboardClose',
|
|
18
|
+
'leaveAnimation',
|
|
19
|
+
'mode',
|
|
20
|
+
'showBackdrop',
|
|
21
|
+
'translucent',
|
|
22
|
+
'trigger',
|
|
23
|
+
'triggerAction',
|
|
24
|
+
'reference',
|
|
25
|
+
'size',
|
|
26
|
+
'side',
|
|
27
|
+
];
|
|
28
|
+
const POPOVER_METHODS = ['present', 'dismiss', 'onDidDismiss', 'onWillDismiss'];
|
|
29
|
+
let IonPopover = class IonPopover {
|
|
30
|
+
z;
|
|
31
|
+
// TODO(FW-2827): type
|
|
32
|
+
template;
|
|
33
|
+
isCmpOpen = false;
|
|
34
|
+
el;
|
|
35
|
+
constructor(c, r, z) {
|
|
36
|
+
this.z = z;
|
|
37
|
+
this.el = r.nativeElement;
|
|
38
|
+
this.el.addEventListener('ionMount', () => {
|
|
39
|
+
this.isCmpOpen = true;
|
|
40
|
+
c.detectChanges();
|
|
41
|
+
});
|
|
42
|
+
this.el.addEventListener('didDismiss', () => {
|
|
43
|
+
this.isCmpOpen = false;
|
|
44
|
+
c.detectChanges();
|
|
45
|
+
});
|
|
46
|
+
proxyOutputs(this, this.el, [
|
|
47
|
+
'ionPopoverDidPresent',
|
|
48
|
+
'ionPopoverWillPresent',
|
|
49
|
+
'ionPopoverWillDismiss',
|
|
50
|
+
'ionPopoverDidDismiss',
|
|
51
|
+
'didPresent',
|
|
52
|
+
'willPresent',
|
|
53
|
+
'willDismiss',
|
|
54
|
+
'didDismiss',
|
|
55
|
+
]);
|
|
56
|
+
}
|
|
57
|
+
/** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonPopover, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
|
|
58
|
+
/** @nocollapse */ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.0", type: IonPopover, isStandalone: true, selector: "ion-popover", inputs: { alignment: "alignment", animated: "animated", arrow: "arrow", keepContentsMounted: "keepContentsMounted", backdropDismiss: "backdropDismiss", cssClass: "cssClass", dismissOnSelect: "dismissOnSelect", enterAnimation: "enterAnimation", event: "event", focusTrap: "focusTrap", isOpen: "isOpen", keyboardClose: "keyboardClose", leaveAnimation: "leaveAnimation", mode: "mode", showBackdrop: "showBackdrop", translucent: "translucent", trigger: "trigger", triggerAction: "triggerAction", reference: "reference", size: "size", side: "side" }, queries: [{ propertyName: "template", first: true, predicate: TemplateRef, descendants: true }], ngImport: i0 });
|
|
59
|
+
};
|
|
60
|
+
IonPopover = __decorate([
|
|
61
|
+
ProxyCmp({
|
|
62
|
+
inputs: POPOVER_INPUTS,
|
|
63
|
+
methods: POPOVER_METHODS,
|
|
64
|
+
})
|
|
65
|
+
/**
|
|
66
|
+
* @Component extends from @Directive
|
|
67
|
+
* so by defining the inputs here we
|
|
68
|
+
* do not need to re-define them for the
|
|
69
|
+
* lazy loaded popover.
|
|
70
|
+
*/
|
|
71
|
+
], IonPopover);
|
|
72
|
+
export { IonPopover };
|
|
73
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonPopover, decorators: [{
|
|
74
|
+
type: Directive,
|
|
75
|
+
args: [{
|
|
76
|
+
selector: 'ion-popover',
|
|
77
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
78
|
+
inputs: POPOVER_INPUTS,
|
|
79
|
+
}]
|
|
80
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }], propDecorators: { template: [{
|
|
81
|
+
type: ContentChild,
|
|
82
|
+
args: [TemplateRef, { static: false }]
|
|
83
|
+
}] } });
|
|
84
|
+
//# sourceMappingURL=popover.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"popover.js","sourceRoot":"","sources":["../../../src/common/overlays/popover.ts"],"names":[],"mappings":";AAAA,OAAO,EAEL,YAAY,EACZ,SAAS,EAIT,WAAW,GACZ,MAAM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CAAC;0HA7BU,UAAU;8GAAV,UAAU,+oBAEP,WAAW;;AAFd,UAAU;IAftB,QAAQ,CAAC;QACR,MAAM,EAAE,cAAc;QACtB,OAAO,EAAE,eAAe;KACzB,CAAC;IACF;;;;;OAKG;GAMU,UAAU,CA8BtB;;2FA9BY,UAAU;kBALtB,SAAS;mBAAC;oBACT,QAAQ,EAAE,aAAa;oBACvB,uEAAuE;oBACvE,MAAM,EAAE,cAAc;iBACvB;;sBAGE,YAAY;uBAAC,WAAW,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE","sourcesContent":["import {\n ChangeDetectorRef,\n ContentChild,\n Directive,\n ElementRef,\n EventEmitter,\n NgZone,\n TemplateRef,\n} from '@angular/core';\nimport type { Components } from '@ionic/core/components';\n\nimport { ProxyCmp, proxyOutputs } from '../utils/proxy';\n\nexport declare interface IonPopover extends Components.IonPopover {\n /**\n * Emitted after the popover has presented.\n */\n ionPopoverDidPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the popover has presented.\n */\n ionPopoverWillPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted after the popover has dismissed.\n */\n ionPopoverWillDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the popover has dismissed.\n */\n ionPopoverDidDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the popover has presented. Shorthand for ionPopoverDidPresent.\n */\n didPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted before the popover has presented. Shorthand for ionPopoverWillPresent.\n */\n willPresent: EventEmitter<CustomEvent>;\n /**\n * Emitted after the popover has presented. Shorthand for ionPopoverWillDismiss.\n */\n willDismiss: EventEmitter<CustomEvent>;\n /**\n * Emitted after the popover has dismissed. Shorthand for ionPopoverDidDismiss.\n */\n didDismiss: EventEmitter<CustomEvent>;\n}\n\nconst POPOVER_INPUTS = [\n 'alignment',\n 'animated',\n 'arrow',\n 'keepContentsMounted',\n 'backdropDismiss',\n 'cssClass',\n 'dismissOnSelect',\n 'enterAnimation',\n 'event',\n 'focusTrap',\n 'isOpen',\n 'keyboardClose',\n 'leaveAnimation',\n 'mode',\n 'showBackdrop',\n 'translucent',\n 'trigger',\n 'triggerAction',\n 'reference',\n 'size',\n 'side',\n];\n\nconst POPOVER_METHODS = ['present', 'dismiss', 'onDidDismiss', 'onWillDismiss'];\n\n@ProxyCmp({\n inputs: POPOVER_INPUTS,\n methods: POPOVER_METHODS,\n})\n/**\n * @Component extends from @Directive\n * so by defining the inputs here we\n * do not need to re-define them for the\n * lazy loaded popover.\n */\n@Directive({\n selector: 'ion-popover',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: POPOVER_INPUTS,\n})\nexport class IonPopover {\n // TODO(FW-2827): type\n @ContentChild(TemplateRef, { static: false }) template: TemplateRef<any>;\n\n isCmpOpen = false;\n\n protected el: HTMLElement;\n\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) {\n this.el = r.nativeElement;\n\n this.el.addEventListener('ionMount', () => {\n this.isCmpOpen = true;\n c.detectChanges();\n });\n this.el.addEventListener('didDismiss', () => {\n this.isCmpOpen = false;\n c.detectChanges();\n });\n proxyOutputs(this, this.el, [\n 'ionPopoverDidPresent',\n 'ionPopoverWillPresent',\n 'ionPopoverWillDismiss',\n 'ionPopoverDidDismiss',\n 'didPresent',\n 'willPresent',\n 'willDismiss',\n 'didDismiss',\n ]);\n }\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApplicationRef, ComponentRef, EnvironmentInjector, InjectionToken, Injector, NgZone } from '@angular/core';
|
|
1
|
+
import { ApplicationRef, ChangeDetectorRef, ComponentRef, EnvironmentInjector, InjectionToken, Injector, NgZone } from '@angular/core';
|
|
2
2
|
import { FrameworkDelegate } from '@ionic/core/components';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
export declare const IonModalToken: InjectionToken<HTMLIonModalElement>;
|
|
@@ -25,4 +25,4 @@ export declare class AngularFrameworkDelegate implements FrameworkDelegate {
|
|
|
25
25
|
removeViewFromDom(_container: any, component: any): Promise<void>;
|
|
26
26
|
}
|
|
27
27
|
export declare const attachView: (zone: NgZone, environmentInjector: EnvironmentInjector, injector: Injector, applicationRef: ApplicationRef, elRefMap: WeakMap<HTMLElement, ComponentRef<any>>, elEventsMap: WeakMap<HTMLElement, () => void>, container: any, component: any, params: any, cssClasses: string[] | undefined, elementReferenceKey: string | undefined, enableSignalsSupport: boolean | undefined, customInjector?: Injector) => any;
|
|
28
|
-
export declare const bindLifecycleEvents: (zone: NgZone, instance: any, element: HTMLElement) => (() => void);
|
|
28
|
+
export declare const bindLifecycleEvents: (zone: NgZone, changeDetectorRef: ChangeDetectorRef, instance: any, element: HTMLElement) => (() => void);
|