voyager-ionic-core 9.0.3 → 9.0.7
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/components/index.js +1 -1
- package/components/ion-accordion-group.js +1 -1
- package/components/ion-accordion.js +1 -1
- package/components/ion-action-sheet.js +1 -1
- package/components/ion-alert.js +1 -1
- package/components/ion-app.js +1 -1
- package/components/ion-avatar.js +1 -1
- package/components/ion-back-button.js +1 -1
- package/components/ion-backdrop.js +1 -1
- package/components/ion-badge.js +1 -1
- package/components/ion-breadcrumb.js +1 -1
- package/components/ion-breadcrumbs.js +1 -1
- package/components/ion-button.js +1 -1
- package/components/ion-buttons.js +1 -1
- package/components/ion-card-content.js +1 -1
- package/components/ion-card-header.js +1 -1
- package/components/ion-card-subtitle.js +1 -1
- package/components/ion-card-title.js +1 -1
- package/components/ion-card.js +1 -1
- package/components/ion-checkbox.js +1 -1
- package/components/ion-chip.js +1 -1
- package/components/ion-col.js +1 -1
- package/components/ion-content.js +1 -1
- package/components/ion-datetime-button.js +1 -1
- package/components/ion-datetime.js +1 -1
- package/components/ion-fab-button.js +1 -1
- package/components/ion-fab-list.js +1 -1
- package/components/ion-fab.js +1 -1
- package/components/ion-footer.js +1 -1
- package/components/ion-grid.js +1 -1
- package/components/ion-header.js +1 -1
- package/components/ion-icon.js +1 -1
- package/components/ion-img.js +1 -1
- package/components/ion-infinite-scroll-content.js +1 -1
- package/components/ion-infinite-scroll.js +1 -1
- package/components/ion-input-otp.js +1 -1
- package/components/ion-input-password-toggle.js +1 -1
- package/components/ion-input.js +1 -1
- package/components/ion-item-divider.js +1 -1
- package/components/ion-item-group.js +1 -1
- package/components/ion-item-option.js +1 -1
- package/components/ion-item-options.js +1 -1
- package/components/ion-item-sliding.js +1 -1
- package/components/ion-item.js +1 -1
- package/components/ion-label.js +1 -1
- package/components/ion-list-header.js +1 -1
- package/components/ion-list.js +1 -1
- package/components/ion-loading.js +1 -1
- package/components/ion-menu-button.js +1 -1
- package/components/ion-menu-toggle.js +1 -1
- package/components/ion-menu.js +1 -1
- package/components/ion-modal.js +1 -1
- package/components/ion-nav-link.js +1 -1
- package/components/ion-nav.js +1 -1
- package/components/ion-note.js +1 -1
- package/components/ion-picker-column-option.js +1 -1
- package/components/ion-picker-column.js +1 -1
- package/components/ion-picker.js +1 -1
- package/components/ion-popover.js +1 -1
- package/components/ion-progress-bar.js +1 -1
- package/components/ion-radio-group.js +1 -1
- package/components/ion-radio.js +1 -1
- package/components/ion-range.js +1 -1
- package/components/ion-refresher-content.js +1 -1
- package/components/ion-refresher.js +1 -1
- package/components/ion-reorder-group.js +1 -1
- package/components/ion-reorder.js +1 -1
- package/components/ion-ripple-effect.js +1 -1
- package/components/ion-route-redirect.js +1 -1
- package/components/ion-route.js +1 -1
- package/components/ion-router-link.js +1 -1
- package/components/ion-router-outlet.js +1 -1
- package/components/ion-router.js +1 -1
- package/components/ion-row.js +1 -1
- package/components/ion-searchbar.js +1 -1
- package/components/ion-segment-button.js +1 -1
- package/components/ion-segment-content.js +1 -1
- package/components/ion-segment-view.js +1 -1
- package/components/ion-segment.js +1 -1
- package/components/ion-select-modal.js +1 -1
- package/components/ion-select-option.js +1 -1
- package/components/ion-select-popover.js +1 -1
- package/components/ion-select.js +1 -1
- package/components/ion-skeleton-text.js +1 -1
- package/components/ion-spinner.js +1 -1
- package/components/ion-split-pane.js +1 -1
- package/components/ion-tab-bar.js +1 -1
- package/components/ion-tab-button.js +1 -1
- package/components/ion-tab.js +1 -1
- package/components/ion-tabs.js +1 -1
- package/components/ion-text.js +1 -1
- package/components/ion-textarea.js +1 -1
- package/components/ion-thumbnail.js +1 -1
- package/components/ion-title.js +1 -1
- package/components/ion-toast.js +1 -1
- package/components/ion-toggle.js +1 -1
- package/components/ion-toolbar.js +1 -1
- package/components/p--cshUOAU.js +4 -0
- package/components/{p-BF48Oc0v.js → p-7KepMw9O.js} +1 -1
- package/components/p-B-5Z9djt.js +4 -0
- package/components/p-B02CcbPD.js +4 -0
- package/components/p-B4IBdPVJ.js +4 -0
- package/components/{p-BYJRZKHa.js → p-BMHdI-wb.js} +1 -1
- package/components/p-BODcC-C0.js +4 -0
- package/components/{p-D7wDJdFn.js → p-Ba9_OzSY.js} +1 -1
- package/components/{p-DMBiAyOR.js → p-BqyLLYLm.js} +1 -1
- package/components/{p-BQyuFxYc.js → p-C1AxSUnp.js} +1 -1
- package/components/p-C7r5Gja6.js +4 -0
- package/components/{p-D5w_FlVa.js → p-CKiqp4Vl.js} +1 -1
- package/components/{p-C8Ck7_Eo.js → p-C_gnmBt2.js} +1 -1
- package/{dist/ionic/p-DTxBioUO.js → components/p-CdrNHfZl.js} +1 -1
- package/components/{p-DM1gJSMP.js → p-ChkSQqfP.js} +1 -1
- package/components/p-ChsJlFCQ.js +4 -0
- package/components/{p-cEN43Ahr.js → p-CjPRDxby.js} +1 -1
- package/components/p-CohRJRIu.js +4 -0
- package/components/{p-DxhHlJln.js → p-CqvARtmt.js} +1 -1
- package/components/p-Ct2aBEue.js +4 -0
- package/components/p-CtiO6_sC.js +4 -0
- package/components/{p-Hp8t4RMX.js → p-CvyvLbPe.js} +1 -1
- package/{dist/ionic/p-BMiZX1LT.js → components/p-CwEis84J.js} +1 -1
- package/components/p-CxEV3Vwy.js +4 -0
- package/components/p-Cyajikho.js +4 -0
- package/components/p-D64Tyi-z.js +4 -0
- package/components/{p-B4lxwJ8N.js → p-DBtFJlTi.js} +1 -1
- package/components/p-DD92Fw3n.js +4 -0
- package/components/p-DDI6VLW9.js +4 -0
- package/components/{p-Fl7ZFU74.js → p-DHo45oj7.js} +1 -1
- package/components/{p-COO0eJOA.js → p-DMPsc_0r.js} +1 -1
- package/{dist/ionic/p-DZ6Hmc-8.js → components/p-Dbi3KqKm.js} +1 -1
- package/components/p-DhfJAkyd.js +4 -0
- package/components/p-DnGlmM4u.js +4 -0
- package/components/{p-CJgnoKcN.js → p-Drpw2dyl.js} +1 -1
- package/components/{p-5ldEpNdG.js → p-Dvyv9SMk.js} +1 -1
- package/components/p-GpqwNbxf.js +4 -0
- package/components/{p-BJr2B5hZ.js → p-HthJZjZ6.js} +1 -1
- package/components/p-IQN1T5zw.js +4 -0
- package/components/{p-DL13ieTa.js → p-KbMCbGRA.js} +1 -1
- package/components/p-ODGeXc3M.js +4 -0
- package/components/p-R4UxBukQ.js +4 -0
- package/components/p-TLtgwTFF.js +4 -0
- package/components/p-Uk13YgEc.js +4 -0
- package/components/{p-qAXsfUff.js → p-V1THdfzs.js} +1 -1
- package/components/{p-C-NbvXu4.js → p-YNnH1_Hs.js} +1 -1
- package/components/{p-CqbGBmqb.js → p-ZrYBjOcc.js} +1 -1
- package/components/p-_y7kwBO8.js +4 -0
- package/components/{p-GGbIHyEF.js → p-hLu-eIbb.js} +1 -1
- package/components/p-jsVMT15X.js +4 -0
- package/components/{p-TWw4e4sO.js → p-r59A3wQk.js} +1 -1
- package/components/p-yGD6MBgf.js +4 -0
- package/css/core.css +1 -1
- package/css/core.css.map +1 -1
- package/css/display.css.map +1 -1
- package/css/flex-utils.css.map +1 -1
- package/css/float-elements.css +1 -1
- package/css/float-elements.css.map +1 -1
- package/css/global.bundle.css.map +1 -1
- package/css/ionic.bundle.css +1 -1
- package/css/ionic.bundle.css.map +1 -1
- package/css/padding.css.map +1 -1
- package/css/structure.css.map +1 -1
- package/css/text-alignment.css.map +1 -1
- package/css/text-transformation.css.map +1 -1
- package/css/typography.css.map +1 -1
- package/css/utils.bundle.css +1 -1
- package/css/utils.bundle.css.map +1 -1
- package/dist/cjs/{animation-Kd1N7WTN.js → animation-DcgLg_PI.js} +3 -3
- package/dist/cjs/{app-globals-b1G4t26O.js → app-globals-BoFCZq0K.js} +1 -1
- package/dist/cjs/attribute-controller-BjTE2TOf.js +131 -0
- package/dist/cjs/{button-active-CQCFubJJ.js → button-active-FdsfRDY_.js} +2 -2
- package/dist/cjs/{capacitor-DmA66EwP.js → capacitor-C6Pp4Z7A.js} +3 -3
- package/dist/cjs/{format-bHU8N1g5.js → format-CVjpvAl1.js} +1 -1
- package/dist/cjs/{framework-delegate-d-fWfeI6.js → framework-delegate-JbKIVMzR.js} +1 -1
- package/dist/cjs/{haptic-Ch-X4gRx.js → haptic--4QteuuM.js} +1 -1
- package/dist/cjs/{helpers-7wzdhdeg.js → helpers-Cqr69qxA.js} +50 -3
- package/dist/cjs/{index-KiSZqhYS.js → index-B4ONUQRp.js} +1 -1
- package/dist/cjs/{index-C74Q3t6a.js → index-BQpSekmz.js} +7 -8
- package/dist/cjs/{index-DFNrCX7M.js → index-BhWiDK25.js} +9 -9
- package/dist/cjs/{index-DXoo08JC.js → index-BiQyIvoc.js} +54 -28
- package/dist/cjs/{index-DtvKGwdh.js → index-CNaZ6SYM.js} +2 -2
- package/dist/cjs/{index-CQfEIyLK.js → index-DUiuw_fH.js} +4 -4
- package/dist/cjs/index.cjs.js +19 -19
- package/dist/cjs/{input-shims-VJIiKBKv.js → input-shims-2AsXPZ5m.js} +16 -17
- package/dist/cjs/{input.utils-EHVE2RK_.js → input.utils-Becpo0ax.js} +1 -1
- package/dist/cjs/ion-accordion_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-action-sheet.cjs.entry.js +26 -28
- package/dist/cjs/ion-alert.cjs.entry.js +27 -29
- package/dist/cjs/ion-app_8.cjs.entry.js +72 -24
- package/dist/cjs/ion-avatar_3.cjs.entry.js +2 -2
- package/dist/cjs/ion-back-button.cjs.entry.js +3 -3
- package/dist/cjs/ion-backdrop.cjs.entry.js +2 -2
- package/dist/cjs/ion-breadcrumb_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-button_2.cjs.entry.js +23 -34
- package/dist/cjs/ion-card_5.cjs.entry.js +19 -7
- package/dist/cjs/ion-checkbox.cjs.entry.js +4 -4
- package/dist/cjs/ion-chip.cjs.entry.js +2 -2
- package/dist/cjs/ion-col_3.cjs.entry.js +2 -2
- package/dist/cjs/ion-datetime-button.cjs.entry.js +4 -4
- package/dist/cjs/ion-datetime.cjs.entry.js +34 -29
- package/dist/cjs/ion-fab_3.cjs.entry.js +3 -3
- package/dist/cjs/ion-img.cjs.entry.js +3 -3
- package/dist/cjs/ion-infinite-scroll_2.cjs.entry.js +5 -5
- package/dist/cjs/ion-input-otp.cjs.entry.js +33 -8
- package/dist/cjs/ion-input-password-toggle.cjs.entry.js +2 -2
- package/dist/cjs/ion-input.cjs.entry.js +12 -16
- package/dist/cjs/ion-item-option_3.cjs.entry.js +4 -4
- package/dist/cjs/ion-item_8.cjs.entry.js +17 -8
- package/dist/cjs/ion-loading.cjs.entry.js +18 -20
- package/dist/cjs/ion-menu_3.cjs.entry.js +18 -19
- package/dist/cjs/ion-modal.cjs.entry.js +177 -172
- package/dist/cjs/ion-nav_2.cjs.entry.js +6 -6
- package/dist/cjs/ion-picker-column-option.cjs.entry.js +3 -3
- package/dist/cjs/ion-picker-column.cjs.entry.js +8 -9
- package/dist/cjs/ion-picker.cjs.entry.js +2 -2
- package/dist/cjs/ion-popover.cjs.entry.js +119 -42
- package/dist/cjs/ion-progress-bar.cjs.entry.js +3 -3
- package/dist/cjs/ion-radio_2.cjs.entry.js +4 -4
- package/dist/cjs/ion-range.cjs.entry.js +4 -4
- package/dist/cjs/ion-refresher_2.cjs.entry.js +8 -9
- package/dist/cjs/ion-reorder_2.cjs.entry.js +6 -7
- package/dist/cjs/ion-ripple-effect.cjs.entry.js +2 -2
- package/dist/cjs/ion-route_4.cjs.entry.js +4 -4
- package/dist/cjs/ion-searchbar.cjs.entry.js +3 -3
- package/dist/cjs/ion-segment-content.cjs.entry.js +1 -1
- package/dist/cjs/ion-segment-view.cjs.entry.js +1 -1
- package/dist/cjs/ion-segment_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-select-modal.cjs.entry.js +8 -10
- package/dist/cjs/ion-select_3.cjs.entry.js +71 -53
- package/dist/cjs/ion-spinner.cjs.entry.js +2 -2
- package/dist/cjs/ion-split-pane.cjs.entry.js +2 -2
- package/dist/cjs/ion-tab-bar_2.cjs.entry.js +6 -7
- package/dist/cjs/ion-tab_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-text.cjs.entry.js +2 -2
- package/dist/cjs/ion-textarea.cjs.entry.js +11 -15
- package/dist/cjs/ion-toast.cjs.entry.js +49 -51
- package/dist/cjs/ion-toggle.cjs.entry.js +6 -7
- package/dist/cjs/{ionic-global-CYJNT-2P.js → ionic-global-48ceLiJ6.js} +1 -1
- package/dist/cjs/ionic.cjs.js +5 -5
- package/dist/cjs/{ios.transition-DYGiD6gM.js → ios.transition-D85_rHf5.js} +4 -5
- package/dist/cjs/{item-multiple-inputs-Dv6qrMhm.js → item-multiple-inputs-C-hz7xrh.js} +1 -1
- package/dist/cjs/{keyboard-cHxZlTyz.js → keyboard-BlHp4a_c.js} +1 -1
- package/dist/cjs/{keyboard-Cix5TVkD.js → keyboard-c2_I35b-.js} +5 -3
- package/dist/cjs/{keyboard-controller-PtZoN2GS.js → keyboard-controller-DHS0BgXp.js} +9 -9
- package/dist/cjs/loader.cjs.js +4 -4
- package/dist/cjs/{md.transition-CrSkaoz6.js → md.transition-Ce9X1WXr.js} +4 -5
- package/dist/cjs/{overlays-BR21NUIG.js → overlays-CLld3axA.js} +224 -12
- package/dist/cjs/{select-option-render-D8ZEjYji.js → select-option-render-CzyhrkOu.js} +2 -2
- package/dist/cjs/{slot-mutation-controller-D6IjSEIh.js → slot-mutation-controller-ClDxh3EK.js} +73 -5
- package/dist/cjs/{status-tap-CNP5eD1R.js → status-tap-CDA0Y3Ad.js} +3 -3
- package/dist/cjs/{swipe-back-CSIJQfu5.js → swipe-back-Dy8pxJCF.js} +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/button/button.js +21 -32
- package/dist/collection/components/card/card.js +17 -6
- package/dist/collection/components/content/content.js +62 -8
- package/dist/collection/components/datetime/datetime.js +27 -20
- package/dist/collection/components/input/input.ios.css +6 -0
- package/dist/collection/components/input/input.js +6 -9
- package/dist/collection/components/input/input.md.css +6 -0
- package/dist/collection/components/input-otp/input-otp.js +29 -3
- package/dist/collection/components/item/item.js +15 -6
- package/dist/collection/components/menu/menu.js +4 -3
- package/dist/collection/components/modal/modal.ios.css +12 -1
- package/dist/collection/components/modal/modal.js +31 -8
- package/dist/collection/components/modal/modal.md.css +12 -1
- package/dist/collection/components/modal/safe-area-utils.js +69 -90
- package/dist/collection/components/modal/utils.js +7 -0
- package/dist/collection/components/popover/animations/ios.enter.js +20 -6
- package/dist/collection/components/popover/animations/md.enter.js +19 -5
- package/dist/collection/components/popover/utils.js +64 -13
- package/dist/collection/components/select/select.ios.css +1 -1
- package/dist/collection/components/select/select.js +67 -38
- package/dist/collection/components/select/select.md.css +1 -1
- package/dist/collection/components/textarea/textarea.ios.css +15 -1
- package/dist/collection/components/textarea/textarea.js +5 -8
- package/dist/collection/components/textarea/textarea.md.css +15 -1
- package/dist/collection/index.js +1 -1
- package/dist/collection/utils/attribute-controller.js +126 -0
- package/dist/collection/utils/forms/click-controller.js +70 -0
- package/dist/collection/utils/forms/index.js +1 -0
- package/dist/collection/utils/hardware-back-button.js +41 -12
- package/dist/collection/utils/helpers.js +44 -3
- package/dist/collection/utils/logging/index.js +4 -0
- package/dist/collection/utils/menu-controller/index.js +2 -1
- package/dist/collection/utils/overlays.js +64 -4
- package/dist/docs.json +9 -3
- package/dist/esm/{animation-BFNVlYum.js → animation-DmtJpz89.js} +2 -2
- package/dist/esm/{app-globals-BgX0BGL1.js → app-globals-CNfpAPW6.js} +1 -1
- package/dist/esm/attribute-controller-DPMIcbef.js +128 -0
- package/dist/esm/{button-active-BfOvDr3b.js → button-active-DVk40Sjl.js} +2 -2
- package/dist/esm/{capacitor-CFERIeaU.js → capacitor-CHJaJ9aX.js} +1 -1
- package/dist/esm/{format-DDFE9jM5.js → format-Ck1cw5z7.js} +1 -1
- package/dist/esm/{framework-delegate-BwNhx9NR.js → framework-delegate-CDjM1vRH.js} +1 -1
- package/dist/esm/{haptic-Cq4UAeka.js → haptic-WXfMCob9.js} +1 -1
- package/dist/esm/{helpers-BSmc0nst.js → helpers-BJqKF1pr.js} +47 -4
- package/dist/esm/{index-DnA_7Bnx.js → index-BBASprVu.js} +4 -4
- package/dist/esm/{index-C23AVPx9.js → index-BpRUsN_W.js} +55 -29
- package/dist/esm/{index-D76bbuoi.js → index-CK8uF0iB.js} +1 -1
- package/dist/esm/{index-CJln0gS3.js → index-Clv8QC5L.js} +2 -3
- package/dist/esm/{index-BuPaALjU.js → index-DIouXecD.js} +6 -6
- package/dist/esm/{index-C1b9CLFg.js → index-TkLga3ma.js} +2 -2
- package/dist/esm/index.js +11 -13
- package/dist/esm/{input-shims-Dqk-Ou25.js → input-shims-C1iYF5JK.js} +5 -6
- package/dist/esm/{input.utils-rqoH22pW.js → input.utils-DZY_K8Po.js} +1 -1
- package/dist/esm/ion-accordion_2.entry.js +3 -3
- package/dist/esm/ion-action-sheet.entry.js +11 -13
- package/dist/esm/ion-alert.entry.js +11 -13
- package/dist/esm/ion-app_8.entry.js +72 -24
- package/dist/esm/ion-avatar_3.entry.js +2 -2
- package/dist/esm/ion-back-button.entry.js +3 -3
- package/dist/esm/ion-backdrop.entry.js +2 -2
- package/dist/esm/ion-breadcrumb_2.entry.js +3 -3
- package/dist/esm/ion-button_2.entry.js +23 -34
- package/dist/esm/ion-card_5.entry.js +19 -7
- package/dist/esm/ion-checkbox.entry.js +4 -4
- package/dist/esm/ion-chip.entry.js +2 -2
- package/dist/esm/ion-col_3.entry.js +2 -2
- package/dist/esm/ion-datetime-button.entry.js +4 -4
- package/dist/esm/ion-datetime.entry.js +33 -28
- package/dist/esm/ion-fab_3.entry.js +3 -3
- package/dist/esm/ion-img.entry.js +3 -3
- package/dist/esm/ion-infinite-scroll_2.entry.js +5 -5
- package/dist/esm/ion-input-otp.entry.js +33 -8
- package/dist/esm/ion-input-password-toggle.entry.js +2 -2
- package/dist/esm/ion-input.entry.js +12 -16
- package/dist/esm/ion-item-option_3.entry.js +4 -4
- package/dist/esm/ion-item_8.entry.js +17 -8
- package/dist/esm/ion-loading.entry.js +7 -9
- package/dist/esm/ion-menu_3.entry.js +10 -11
- package/dist/esm/ion-modal.entry.js +115 -110
- package/dist/esm/ion-nav_2.entry.js +6 -6
- package/dist/esm/ion-picker-column-option.entry.js +3 -3
- package/dist/esm/ion-picker-column.entry.js +5 -6
- package/dist/esm/ion-picker.entry.js +2 -2
- package/dist/esm/ion-popover.entry.js +108 -31
- package/dist/esm/ion-progress-bar.entry.js +3 -3
- package/dist/esm/ion-radio_2.entry.js +4 -4
- package/dist/esm/ion-range.entry.js +4 -4
- package/dist/esm/ion-refresher_2.entry.js +8 -9
- package/dist/esm/ion-reorder_2.entry.js +6 -7
- package/dist/esm/ion-ripple-effect.entry.js +2 -2
- package/dist/esm/ion-route_4.entry.js +4 -4
- package/dist/esm/ion-searchbar.entry.js +3 -3
- package/dist/esm/ion-segment-content.entry.js +1 -1
- package/dist/esm/ion-segment-view.entry.js +1 -1
- package/dist/esm/ion-segment_2.entry.js +3 -3
- package/dist/esm/ion-select-modal.entry.js +7 -9
- package/dist/esm/ion-select_3.entry.js +66 -48
- package/dist/esm/ion-spinner.entry.js +2 -2
- package/dist/esm/ion-split-pane.entry.js +2 -2
- package/dist/esm/ion-tab-bar_2.entry.js +6 -7
- package/dist/esm/ion-tab_2.entry.js +3 -3
- package/dist/esm/ion-text.entry.js +2 -2
- package/dist/esm/ion-textarea.entry.js +11 -15
- package/dist/esm/ion-toast.entry.js +7 -9
- package/dist/esm/ion-toggle.entry.js +6 -7
- package/dist/esm/{ionic-global-ZXjCXKH0.js → ionic-global-Cep6oYzK.js} +1 -1
- package/dist/esm/ionic.js +6 -6
- package/dist/esm/{ios.transition-CWAgfQ1r.js → ios.transition-B8netzsb.js} +4 -5
- package/dist/esm/{item-multiple-inputs-DZnIiOO_.js → item-multiple-inputs-Bd2LO7qK.js} +1 -1
- package/dist/esm/{keyboard-Cj8mLJeq.js → keyboard-B4Y-Gph8.js} +5 -3
- package/dist/esm/{keyboard-DAF8GNJ9.js → keyboard-Cmqp5iZD.js} +1 -1
- package/dist/esm/{keyboard-controller-DEwoa1ev.js → keyboard-controller-B2NoF7bV.js} +2 -2
- package/dist/esm/loader.js +5 -5
- package/dist/esm/{md.transition-ZuqDDdDW.js → md.transition-DNCSSiXk.js} +4 -5
- package/dist/esm/{overlays-DKE0DgvE.js → overlays-DmDY-El7.js} +216 -10
- package/dist/esm/{select-option-render-CRP_teb1.js → select-option-render-BSDT9oSA.js} +2 -2
- package/dist/esm/{slot-mutation-controller-B5NpUZ-N.js → slot-mutation-controller-hAS2uJ7c.js} +69 -3
- package/dist/esm/{status-tap-Cv9gb3ja.js → status-tap-VGRBYwiC.js} +3 -3
- package/dist/esm/{swipe-back-De5HlmeM.js → swipe-back-tCNYR9ZM.js} +2 -2
- package/dist/ionic/index.esm.js +1 -1
- package/dist/ionic/ionic.esm.js +1 -1
- package/dist/ionic/{p-b9b4e85d.entry.js → p-00cd107d.entry.js} +1 -1
- package/dist/ionic/p-01b7e3f2.entry.js +4 -0
- package/dist/ionic/{p-9c5f2691.entry.js → p-0a789930.entry.js} +1 -1
- package/dist/ionic/p-0b09c60e.entry.js +4 -0
- package/dist/ionic/p-0c32c626.entry.js +4 -0
- package/dist/ionic/p-0f97175e.entry.js +4 -0
- package/dist/ionic/p-107a81a6.entry.js +4 -0
- package/dist/ionic/{p-ca1b8865.entry.js → p-230f510c.entry.js} +1 -1
- package/dist/ionic/p-27d96a9b.entry.js +4 -0
- package/dist/ionic/{p-db449915.entry.js → p-28251c5c.entry.js} +1 -1
- package/dist/ionic/{p-099b7f9f.entry.js → p-362dcd86.entry.js} +1 -1
- package/dist/ionic/p-4bd80334.entry.js +4 -0
- package/dist/ionic/p-4d785062.entry.js +4 -0
- package/dist/ionic/{p-efc0cf82.entry.js → p-4e4e5919.entry.js} +1 -1
- package/dist/ionic/{p-837db1b9.entry.js → p-4ed3c460.entry.js} +1 -1
- package/dist/ionic/{p-d8c138d9.entry.js → p-4f25b926.entry.js} +1 -1
- package/dist/ionic/{p-271c3640.entry.js → p-539d6c8e.entry.js} +1 -1
- package/dist/ionic/p-5bb24bce.entry.js +4 -0
- package/dist/ionic/p-60780b88.entry.js +4 -0
- package/dist/ionic/{p-54cbb0a7.entry.js → p-62c87f3d.entry.js} +1 -1
- package/dist/ionic/p-6317d620.entry.js +4 -0
- package/dist/ionic/{p-85599fe3.entry.js → p-64ac3864.entry.js} +1 -1
- package/dist/ionic/{p-191a651e.entry.js → p-6c7b5930.entry.js} +1 -1
- package/dist/ionic/{p-7fbb3319.entry.js → p-77252596.entry.js} +1 -1
- package/dist/ionic/p-7ce9c6f8.entry.js +4 -0
- package/dist/ionic/{p-8b80d9f9.entry.js → p-7db20410.entry.js} +1 -1
- package/dist/ionic/{p-5d9094ac.entry.js → p-7e9c2a97.entry.js} +1 -1
- package/dist/ionic/p-7l6ENjIV.js +4 -0
- package/dist/ionic/p-82abf431.entry.js +4 -0
- package/dist/ionic/p-8b79061e.entry.js +4 -0
- package/dist/ionic/{p-6e386853.entry.js → p-8c85e250.entry.js} +1 -1
- package/dist/ionic/{p-90f50a65.entry.js → p-8d651adb.entry.js} +1 -1
- package/dist/ionic/{p-dd01be0a.entry.js → p-8db08782.entry.js} +1 -1
- package/dist/ionic/p-91f3cd8b.entry.js +4 -0
- package/dist/ionic/{p-f0fb23c1.entry.js → p-930c3538.entry.js} +1 -1
- package/dist/ionic/{p-ee09ac9d.entry.js → p-9ffccbf1.entry.js} +1 -1
- package/dist/ionic/{p-CM5OBjTW.js → p-B0jcOZOE.js} +1 -1
- package/dist/ionic/p-B8IuTu_r.js +4 -0
- package/dist/ionic/p-BNXIurCt.js +4 -0
- package/{components/p-6ZLn6K5e.js → dist/ionic/p-BO10QT9r.js} +1 -1
- package/dist/ionic/p-BOLqP2-V.js +4 -0
- package/dist/ionic/{p-BMPN55of.js → p-BY4FwwBp.js} +1 -1
- package/dist/ionic/p-BdHBcCZF.js +4 -0
- package/{components/p-DiuOa1vw.js → dist/ionic/p-BexAj0yw.js} +1 -1
- package/dist/ionic/p-Bnc1L7Rk.js +4 -0
- package/dist/ionic/p-BpRUsN_W.js +6 -0
- package/dist/ionic/p-Bppj2PE0.js +4 -0
- package/dist/ionic/p-BuLlVedw.js +4 -0
- package/dist/ionic/p-Bx5x5GJV.js +4 -0
- package/dist/ionic/p-C1WYZOZj.js +4 -0
- package/dist/ionic/p-C2LaBx3E.js +4 -0
- package/dist/ionic/{p-Bd72UYI2.js → p-CXs4J83x.js} +1 -1
- package/dist/ionic/p-Co7eql8D.js +4 -0
- package/dist/ionic/p-D13gXhdC.js +4 -0
- package/dist/ionic/p-D926OmIX.js +4 -0
- package/dist/ionic/{p-T71k3C35.js → p-DPNVo1nr.js} +1 -1
- package/{components/p-C4VpVfrJ.js → dist/ionic/p-DQXtveHv.js} +1 -1
- package/dist/ionic/p-DXXGkPA8.js +4 -0
- package/dist/ionic/{p-C8XilMh0.js → p-DfvWlTdB.js} +1 -1
- package/dist/ionic/p-DriE1ZAo.js +4 -0
- package/dist/ionic/{p-D7jHfs0Y.js → p-DxftXYZp.js} +1 -1
- package/dist/ionic/{p-Do3zTvCA.js → p-SEecsUh7.js} +1 -1
- package/dist/ionic/p-a4389f13.entry.js +4 -0
- package/dist/ionic/p-af11d3c6.entry.js +4 -0
- package/dist/ionic/p-af56702e.entry.js +4 -0
- package/dist/ionic/{p-561af487.entry.js → p-b3aadfe8.entry.js} +1 -1
- package/dist/ionic/p-b5bcbbc1.entry.js +4 -0
- package/dist/ionic/p-b9ed3a52.entry.js +4 -0
- package/dist/ionic/{p-3bba83ee.entry.js → p-bfdbe24b.entry.js} +1 -1
- package/dist/ionic/{p-4712a8a9.entry.js → p-c250b6b0.entry.js} +1 -1
- package/dist/ionic/{p-38b9375b.entry.js → p-c293f854.entry.js} +1 -1
- package/dist/ionic/p-c81ec0e8.entry.js +4 -0
- package/dist/ionic/p-c83dbc12.entry.js +4 -0
- package/dist/ionic/p-d0e374f8.entry.js +4 -0
- package/dist/ionic/p-d72accc4.entry.js +4 -0
- package/dist/ionic/p-d9a3dfd1.entry.js +4 -0
- package/dist/ionic/p-e1haAYzm.js +4 -0
- package/dist/ionic/p-e7ab4def.entry.js +4 -0
- package/dist/ionic/{p-d6755739.entry.js → p-eb989dc9.entry.js} +1 -1
- package/dist/ionic/p-ec259ac5.entry.js +4 -0
- package/dist/ionic/{p-DYUjHcuH.js → p-nCAPr1Ah.js} +1 -1
- package/dist/types/components/button/button.d.ts +3 -12
- package/dist/types/components/card/card.d.ts +3 -1
- package/dist/types/components/content/content.d.ts +28 -3
- package/dist/types/components/datetime/datetime.d.ts +5 -10
- package/dist/types/components/input/input.d.ts +1 -0
- package/dist/types/components/input-otp/input-otp.d.ts +7 -0
- package/dist/types/components/item/item.d.ts +1 -1
- package/dist/types/components/modal/modal.d.ts +9 -1
- package/dist/types/components/modal/safe-area-utils.d.ts +28 -14
- package/dist/types/components/modal/utils.d.ts +4 -0
- package/dist/types/components/popover/utils.d.ts +16 -3
- package/dist/types/components/select/select.d.ts +11 -0
- package/dist/types/components/textarea/textarea.d.ts +1 -0
- package/dist/types/components.d.ts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/stencil-public-runtime.d.ts +61 -55
- package/dist/types/utils/attribute-controller.d.ts +56 -0
- package/dist/types/utils/config.d.ts +4 -1
- package/dist/types/utils/forms/click-controller.d.ts +36 -0
- package/dist/types/utils/forms/index.d.ts +1 -0
- package/dist/types/utils/hardware-back-button.d.ts +11 -0
- package/dist/types/utils/helpers.d.ts +27 -2
- package/dist/types/utils/logging/index.d.ts +4 -0
- package/dist/types/utils/overlays.d.ts +20 -2
- package/hydrate/index.js +1249 -484
- package/hydrate/index.mjs +1249 -484
- package/package.json +3 -3
- package/components/p-1sJ0ZDPe.js +0 -4
- package/components/p-B1_TL6RQ.js +0 -4
- package/components/p-BT9-hMMz.js +0 -4
- package/components/p-BU8a2IhR.js +0 -4
- package/components/p-BW_SlU2D.js +0 -4
- package/components/p-BWoa-cki.js +0 -4
- package/components/p-BgkOsq-d.js +0 -4
- package/components/p-Bi-it1EH.js +0 -4
- package/components/p-C09TXohi.js +0 -4
- package/components/p-CG_zZq_I.js +0 -4
- package/components/p-CMRYD_yR.js +0 -4
- package/components/p-CNLioZ3B.js +0 -4
- package/components/p-CWAks_S_.js +0 -4
- package/components/p-Cd1WaN-0.js +0 -4
- package/components/p-CrAKlX71.js +0 -4
- package/components/p-Ctop2IWW.js +0 -4
- package/components/p-Cw6WocLJ.js +0 -4
- package/components/p-DFLJvuRK.js +0 -4
- package/components/p-DZRZic9C.js +0 -4
- package/components/p-DhNuxvJH.js +0 -4
- package/components/p-Djmz-ssp.js +0 -4
- package/components/p-DnBNYc7u.js +0 -4
- package/components/p-DwSXbQSz.js +0 -4
- package/components/p-M34T2gyX.js +0 -4
- package/components/p-YjMkHuvH.js +0 -4
- package/dist/cjs/hardware-back-button-Bu4Dzw8l.js +0 -121
- package/dist/cjs/index-DkNv4J_i.js +0 -10
- package/dist/esm/hardware-back-button-DmkiRgOT.js +0 -115
- package/dist/esm/index-ZjP4CjeZ.js +0 -7
- package/dist/ionic/p-0dcb7bb6.entry.js +0 -4
- package/dist/ionic/p-1347880c.entry.js +0 -4
- package/dist/ionic/p-1f24cb24.entry.js +0 -4
- package/dist/ionic/p-2ea4bb36.entry.js +0 -4
- package/dist/ionic/p-338a02e0.entry.js +0 -4
- package/dist/ionic/p-3e01c744.entry.js +0 -4
- package/dist/ionic/p-458715a9.entry.js +0 -4
- package/dist/ionic/p-4c3e50f8.entry.js +0 -4
- package/dist/ionic/p-5906ea6f.entry.js +0 -4
- package/dist/ionic/p-5cc09b40.entry.js +0 -4
- package/dist/ionic/p-612ea3b1.entry.js +0 -4
- package/dist/ionic/p-68cc89a6.entry.js +0 -4
- package/dist/ionic/p-77c96e08.entry.js +0 -4
- package/dist/ionic/p-7bfeccb3.entry.js +0 -4
- package/dist/ionic/p-7e394cc3.entry.js +0 -4
- package/dist/ionic/p-803059b6.entry.js +0 -4
- package/dist/ionic/p-9595e305.entry.js +0 -4
- package/dist/ionic/p-9ee9c5b6.entry.js +0 -4
- package/dist/ionic/p-BY6BzzPF.js +0 -4
- package/dist/ionic/p-BaeKWZ-a.js +0 -4
- package/dist/ionic/p-BgOvhHy_.js +0 -4
- package/dist/ionic/p-BhamHSw3.js +0 -4
- package/dist/ionic/p-BijjLYjT.js +0 -4
- package/dist/ionic/p-C23AVPx9.js +0 -6
- package/dist/ionic/p-CER8qW8Y.js +0 -4
- package/dist/ionic/p-CFuOr1Tu.js +0 -4
- package/dist/ionic/p-CIGNaXM1.js +0 -4
- package/dist/ionic/p-CMZYmFb4.js +0 -4
- package/dist/ionic/p-CkxVYPtX.js +0 -4
- package/dist/ionic/p-CmXuiRT6.js +0 -4
- package/dist/ionic/p-D5t_-oMk.js +0 -4
- package/dist/ionic/p-D6rHcCvc.js +0 -4
- package/dist/ionic/p-DLM95R4x.js +0 -4
- package/dist/ionic/p-D_gb-kdd.js +0 -4
- package/dist/ionic/p-DajLgJ4d.js +0 -4
- package/dist/ionic/p-ZjP4CjeZ.js +0 -4
- package/dist/ionic/p-a8df96c8.entry.js +0 -4
- package/dist/ionic/p-a8ff2489.entry.js +0 -4
- package/dist/ionic/p-aff52029.entry.js +0 -4
- package/dist/ionic/p-b3532b8d.entry.js +0 -4
- package/dist/ionic/p-cc4320d3.entry.js +0 -4
- package/dist/ionic/p-d526798a.entry.js +0 -4
- package/dist/ionic/p-ec00fd0d.entry.js +0 -4
- package/dist/ionic/p-f83b3e0c.entry.js +0 -4
- package/dist/ionic/p-fa50d493.entry.js +0 -4
- package/dist/ionic/p-zWf7R2xV.js +0 -4
|
@@ -3,14 +3,160 @@
|
|
|
3
3
|
*/
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
|
-
var
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var ionicGlobal = require('./ionic-global-CYJNT-2P.js');
|
|
11
|
-
var frameworkDelegate = require('./framework-delegate-d-fWfeI6.js');
|
|
6
|
+
var helpers = require('./helpers-Cqr69qxA.js');
|
|
7
|
+
var index = require('./index-BiQyIvoc.js');
|
|
8
|
+
var ionicGlobal = require('./ionic-global-48ceLiJ6.js');
|
|
9
|
+
var frameworkDelegate = require('./framework-delegate-JbKIVMzR.js');
|
|
12
10
|
var gestureController = require('./gesture-controller-CeJslptU.js');
|
|
13
11
|
|
|
12
|
+
/**
|
|
13
|
+
* CloseWatcher is a newer API that lets
|
|
14
|
+
* use detect the hardware back button event
|
|
15
|
+
* in a web browser: https://caniuse.com/?search=closewatcher
|
|
16
|
+
* However, not every browser supports it yet.
|
|
17
|
+
*
|
|
18
|
+
* This needs to be a function so that we can
|
|
19
|
+
* check the config once it has been set.
|
|
20
|
+
* Otherwise, this code would be evaluated the
|
|
21
|
+
* moment this file is evaluated which could be
|
|
22
|
+
* before the config is set.
|
|
23
|
+
*/
|
|
24
|
+
const shouldUseCloseWatcher = () => index.config.get('experimentalCloseWatcher', false) && helpers.win !== undefined && 'CloseWatcher' in helpers.win;
|
|
25
|
+
/**
|
|
26
|
+
* When hardwareBackButton: false in config,
|
|
27
|
+
* we need to make sure we also block the default
|
|
28
|
+
* webview behavior. If we don't then it will be
|
|
29
|
+
* possible for users to navigate backward while
|
|
30
|
+
* an overlay is still open. Additionally, it will
|
|
31
|
+
* give the appearance that the hardwareBackButton
|
|
32
|
+
* config is not working as the page transition
|
|
33
|
+
* will still happen.
|
|
34
|
+
*/
|
|
35
|
+
const blockHardwareBackButton = () => {
|
|
36
|
+
document.addEventListener('backbutton', () => { });
|
|
37
|
+
};
|
|
38
|
+
const closeWatcherConditions = [];
|
|
39
|
+
let syncCloseWatcher;
|
|
40
|
+
/**
|
|
41
|
+
* Registers a check for whether the back button
|
|
42
|
+
* has something to close. The CloseWatcher is only
|
|
43
|
+
* active while one of these checks passes.
|
|
44
|
+
*/
|
|
45
|
+
const addCloseWatcherCondition = (condition) => {
|
|
46
|
+
closeWatcherConditions.push(condition);
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* Call this whenever something the back button
|
|
50
|
+
* can close opens or closes.
|
|
51
|
+
*/
|
|
52
|
+
const updateCloseWatcher = () => {
|
|
53
|
+
syncCloseWatcher?.();
|
|
54
|
+
};
|
|
55
|
+
const startHardwareBackButton = () => {
|
|
56
|
+
const doc = document;
|
|
57
|
+
let busy = false;
|
|
58
|
+
const backButtonCallback = () => {
|
|
59
|
+
if (busy) {
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
let index$1 = 0;
|
|
63
|
+
let handlers = [];
|
|
64
|
+
const ev = new CustomEvent('ionBackButton', {
|
|
65
|
+
bubbles: false,
|
|
66
|
+
detail: {
|
|
67
|
+
register(priority, handler) {
|
|
68
|
+
handlers.push({ priority, handler, id: index$1++ });
|
|
69
|
+
},
|
|
70
|
+
},
|
|
71
|
+
});
|
|
72
|
+
doc.dispatchEvent(ev);
|
|
73
|
+
const executeAction = async (handlerRegister) => {
|
|
74
|
+
try {
|
|
75
|
+
if (handlerRegister?.handler) {
|
|
76
|
+
const result = handlerRegister.handler(processHandlers);
|
|
77
|
+
if (result != null) {
|
|
78
|
+
await result;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
catch (e) {
|
|
83
|
+
index.printIonError('[ion-app] - Exception in startHardwareBackButton:', e);
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
const processHandlers = () => {
|
|
87
|
+
if (handlers.length > 0) {
|
|
88
|
+
let selectedHandler = {
|
|
89
|
+
priority: Number.MIN_SAFE_INTEGER,
|
|
90
|
+
handler: () => undefined,
|
|
91
|
+
id: -1,
|
|
92
|
+
};
|
|
93
|
+
handlers.forEach((handler) => {
|
|
94
|
+
if (handler.priority >= selectedHandler.priority) {
|
|
95
|
+
selectedHandler = handler;
|
|
96
|
+
}
|
|
97
|
+
});
|
|
98
|
+
busy = true;
|
|
99
|
+
handlers = handlers.filter((handler) => handler.id !== selectedHandler.id);
|
|
100
|
+
executeAction(selectedHandler).then(() => (busy = false));
|
|
101
|
+
}
|
|
102
|
+
};
|
|
103
|
+
processHandlers();
|
|
104
|
+
};
|
|
105
|
+
/**
|
|
106
|
+
* Android WebView never sends the hardware back
|
|
107
|
+
* button to a CloseWatcher, so hybrid apps still
|
|
108
|
+
* need this. Browsers never fire backbutton.
|
|
109
|
+
*/
|
|
110
|
+
doc.addEventListener('backbutton', backButtonCallback);
|
|
111
|
+
if (shouldUseCloseWatcher()) {
|
|
112
|
+
let watcher;
|
|
113
|
+
/**
|
|
114
|
+
* An active CloseWatcher stops the back button from
|
|
115
|
+
* navigating, so only keep one while there's something to close.
|
|
116
|
+
*/
|
|
117
|
+
syncCloseWatcher = () => {
|
|
118
|
+
const canClose = closeWatcherConditions.some((condition) => condition());
|
|
119
|
+
if (!canClose) {
|
|
120
|
+
watcher?.destroy();
|
|
121
|
+
watcher = undefined;
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
if (watcher !== undefined) {
|
|
125
|
+
return;
|
|
126
|
+
}
|
|
127
|
+
watcher = new helpers.win.CloseWatcher();
|
|
128
|
+
/**
|
|
129
|
+
* Once a close request happens
|
|
130
|
+
* the watcher gets destroyed.
|
|
131
|
+
* As a result, we need to re-configure
|
|
132
|
+
* the watcher so we can respond to other
|
|
133
|
+
* close requests, including after one that
|
|
134
|
+
* closed nothing, like a modal whose canDismiss
|
|
135
|
+
* returned false.
|
|
136
|
+
*/
|
|
137
|
+
watcher.onclose = () => {
|
|
138
|
+
watcher = undefined;
|
|
139
|
+
backButtonCallback();
|
|
140
|
+
syncCloseWatcher?.();
|
|
141
|
+
};
|
|
142
|
+
};
|
|
143
|
+
syncCloseWatcher();
|
|
144
|
+
}
|
|
145
|
+
};
|
|
146
|
+
const OVERLAY_BACK_BUTTON_PRIORITY = 100;
|
|
147
|
+
const MENU_BACK_BUTTON_PRIORITY = 99; // 1 less than overlay priority since menu is displayed behind overlays
|
|
148
|
+
|
|
149
|
+
var hardwareBackButton = /*#__PURE__*/Object.freeze({
|
|
150
|
+
__proto__: null,
|
|
151
|
+
MENU_BACK_BUTTON_PRIORITY: MENU_BACK_BUTTON_PRIORITY,
|
|
152
|
+
OVERLAY_BACK_BUTTON_PRIORITY: OVERLAY_BACK_BUTTON_PRIORITY,
|
|
153
|
+
addCloseWatcherCondition: addCloseWatcherCondition,
|
|
154
|
+
blockHardwareBackButton: blockHardwareBackButton,
|
|
155
|
+
shouldUseCloseWatcher: shouldUseCloseWatcher,
|
|
156
|
+
startHardwareBackButton: startHardwareBackButton,
|
|
157
|
+
updateCloseWatcher: updateCloseWatcher
|
|
158
|
+
});
|
|
159
|
+
|
|
14
160
|
/**
|
|
15
161
|
* This query string selects elements that
|
|
16
162
|
* are eligible to receive focus. We select
|
|
@@ -94,6 +240,11 @@ const focusElementInContext = (hostToFocus, fallbackElement) => {
|
|
|
94
240
|
|
|
95
241
|
let lastOverlayIndex = 0;
|
|
96
242
|
let lastId = 0;
|
|
243
|
+
/**
|
|
244
|
+
* Every overlay except toast, which doesn't trap
|
|
245
|
+
* focus or close on back.
|
|
246
|
+
*/
|
|
247
|
+
const NON_TOAST_OVERLAYS = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-popover';
|
|
97
248
|
const activeAnimations = new WeakMap();
|
|
98
249
|
/**
|
|
99
250
|
* Determines if the overlay's backdrop is always blocking (no background interaction).
|
|
@@ -220,7 +371,7 @@ const focusElementInOverlay = (hostToFocus, overlay) => {
|
|
|
220
371
|
* Should NOT include: Toast
|
|
221
372
|
*/
|
|
222
373
|
const trapKeyboardFocus = (ev, doc) => {
|
|
223
|
-
const lastOverlay = getPresentedOverlay(doc,
|
|
374
|
+
const lastOverlay = getPresentedOverlay(doc, NON_TOAST_OVERLAYS);
|
|
224
375
|
const target = ev.target;
|
|
225
376
|
/**
|
|
226
377
|
* If no active overlay, ignore this event.
|
|
@@ -403,11 +554,16 @@ const connectListeners = (doc) => {
|
|
|
403
554
|
doc.addEventListener('focus', (ev) => {
|
|
404
555
|
trapKeyboardFocus(ev, doc);
|
|
405
556
|
}, true);
|
|
557
|
+
/**
|
|
558
|
+
* Whether the overlay actually dismisses is checked at press time,
|
|
559
|
+
* since `backdropDismiss` can change while it's open.
|
|
560
|
+
*/
|
|
561
|
+
addCloseWatcherCondition(() => getPresentedOverlay(doc, NON_TOAST_OVERLAYS) !== undefined);
|
|
406
562
|
// handle back-button click
|
|
407
563
|
doc.addEventListener('ionBackButton', (ev) => {
|
|
408
564
|
const lastOverlay = getPresentedOverlay(doc);
|
|
409
565
|
if (lastOverlay?.backdropDismiss) {
|
|
410
|
-
ev.detail.register(
|
|
566
|
+
ev.detail.register(OVERLAY_BACK_BUTTON_PRIORITY, () => {
|
|
411
567
|
/**
|
|
412
568
|
* Do not return this promise otherwise
|
|
413
569
|
* the hardware back button utility will
|
|
@@ -430,7 +586,7 @@ const connectListeners = (doc) => {
|
|
|
430
586
|
* this behavior will be handled via the ionBackButton
|
|
431
587
|
* event.
|
|
432
588
|
*/
|
|
433
|
-
if (!
|
|
589
|
+
if (!shouldUseCloseWatcher()) {
|
|
434
590
|
doc.addEventListener('keydown', (ev) => {
|
|
435
591
|
if (ev.key === 'Escape') {
|
|
436
592
|
const lastOverlay = getPresentedOverlay(doc);
|
|
@@ -526,7 +682,8 @@ const setRootAriaHidden = (hidden = false) => {
|
|
|
526
682
|
* Cleans up root `aria-hidden` and `backdrop-no-scroll` when
|
|
527
683
|
* an overlay is removed from the DOM without going through
|
|
528
684
|
* the `dismiss()` flow (e.g., when a framework unmounts the
|
|
529
|
-
* overlay during a route change).
|
|
685
|
+
* overlay during a route change). Also releases the
|
|
686
|
+
* CloseWatcher if nothing is left to close.
|
|
530
687
|
*
|
|
531
688
|
* Should be called from an overlay's `disconnectedCallback`
|
|
532
689
|
* when the overlay was still presented at the time of removal.
|
|
@@ -535,6 +692,7 @@ const cleanupRootFocusTrapAccessibility = () => {
|
|
|
535
692
|
if (typeof document === 'undefined') {
|
|
536
693
|
return;
|
|
537
694
|
}
|
|
695
|
+
updateCloseWatcher();
|
|
538
696
|
const remainingOverlays = getPresentedOverlays(document);
|
|
539
697
|
const hasRemainingLocking = remainingOverlays.some((o) => locksAppRoot(o));
|
|
540
698
|
if (!hasRemainingLocking) {
|
|
@@ -556,7 +714,9 @@ const applyRootLock = (el) => {
|
|
|
556
714
|
};
|
|
557
715
|
/**
|
|
558
716
|
* Re-applies the root lock that `cleanupRootFocusTrapAccessibility()` released.
|
|
559
|
-
* Call from `connectedCallback` when the overlay is still presented.
|
|
717
|
+
* Call from `connectedCallback` when the overlay is still presented. Also
|
|
718
|
+
* re-arms the CloseWatcher, which every overlay needs, so that happens
|
|
719
|
+
* before the `locksAppRoot` check.
|
|
560
720
|
*
|
|
561
721
|
* A synchronous move keeps the overlay connected, so the lock survives. A
|
|
562
722
|
* detach with a re-insert in a later task releases it, which is the shape a
|
|
@@ -566,6 +726,7 @@ const restoreRootFocusTrapAccessibility = (overlayEl) => {
|
|
|
566
726
|
if (typeof document === 'undefined') {
|
|
567
727
|
return;
|
|
568
728
|
}
|
|
729
|
+
updateCloseWatcher();
|
|
569
730
|
const el = overlayEl;
|
|
570
731
|
if (!locksAppRoot(el)) {
|
|
571
732
|
return;
|
|
@@ -716,7 +877,7 @@ const dismiss = async (overlay, data, role, name, iosLeaveAnimation, mdLeaveAnim
|
|
|
716
877
|
if (!overlay.presented) {
|
|
717
878
|
return false;
|
|
718
879
|
}
|
|
719
|
-
const presentedOverlays =
|
|
880
|
+
const presentedOverlays = helpers.doc !== undefined ? getPresentedOverlays(helpers.doc) : [];
|
|
720
881
|
/**
|
|
721
882
|
* For accessibility, toasts lack focus traps and don't receive
|
|
722
883
|
* `aria-hidden` on the root element when presented.
|
|
@@ -779,6 +940,11 @@ const dismiss = async (overlay, data, role, name, iosLeaveAnimation, mdLeaveAnim
|
|
|
779
940
|
index.printIonError(`[${overlay.el.tagName.toLowerCase()}] - `, err);
|
|
780
941
|
}
|
|
781
942
|
overlay.el.remove();
|
|
943
|
+
/**
|
|
944
|
+
* Release the back button if nothing
|
|
945
|
+
* else is left to close.
|
|
946
|
+
*/
|
|
947
|
+
updateCloseWatcher();
|
|
782
948
|
return true;
|
|
783
949
|
};
|
|
784
950
|
const getAppRoot = (doc) => {
|
|
@@ -787,6 +953,12 @@ const getAppRoot = (doc) => {
|
|
|
787
953
|
const overlayAnimation = async (overlay, animationBuilder, baseEl, opts) => {
|
|
788
954
|
// Make overlay visible in case it's hidden
|
|
789
955
|
baseEl.classList.remove('overlay-hidden');
|
|
956
|
+
/**
|
|
957
|
+
* Removing `overlay-hidden` makes the overlay count
|
|
958
|
+
* as presented, so back can dismiss it while it
|
|
959
|
+
* animates in.
|
|
960
|
+
*/
|
|
961
|
+
updateCloseWatcher();
|
|
790
962
|
const aniRoot = overlay.el;
|
|
791
963
|
const animation = animationBuilder(aniRoot, opts);
|
|
792
964
|
if (!overlay.animated || !index.config.getBoolean('animated', true)) {
|
|
@@ -845,6 +1017,40 @@ const safeCall = (handler, arg) => {
|
|
|
845
1017
|
}
|
|
846
1018
|
return undefined;
|
|
847
1019
|
};
|
|
1020
|
+
/**
|
|
1021
|
+
* `--width` and `--height` values that leave an overlay spanning the viewport
|
|
1022
|
+
* on that axis, so it reaches both edges. An empty value means the property
|
|
1023
|
+
* was never overridden.
|
|
1024
|
+
*/
|
|
1025
|
+
const FULLSCREEN_SIZES = ['', '100%', '100vw', '100vh', '100dvw', '100dvh', '100svw', '100svh'];
|
|
1026
|
+
/**
|
|
1027
|
+
* `--width` and `--height` values that size an overlay to its content, leaving
|
|
1028
|
+
* the rendered size dependent on the content and on `--max-width` or
|
|
1029
|
+
* `--max-height`.
|
|
1030
|
+
*/
|
|
1031
|
+
const CONTENT_SIZES = ['auto', 'fit-content', 'min-content', 'max-content'];
|
|
1032
|
+
/**
|
|
1033
|
+
* How an overlay's `--width` or `--height` determines its used size:
|
|
1034
|
+
*
|
|
1035
|
+
* `fullscreen` spans the viewport on that axis. `content` depends on the
|
|
1036
|
+
* overlay's content, so its used size is not known until layout. `definite`
|
|
1037
|
+
* resolves independently of the overlay's content size.
|
|
1038
|
+
*
|
|
1039
|
+
* Values are lowercased because CSS keywords are case-insensitive, while a
|
|
1040
|
+
* custom property preserves the case in which it was authored. Content values
|
|
1041
|
+
* are matched as a suffix so vendor-prefixed values such as `-moz-fit-content`
|
|
1042
|
+
* are recognized.
|
|
1043
|
+
*/
|
|
1044
|
+
const getOverlaySizeType = (size) => {
|
|
1045
|
+
const value = size.trim().toLowerCase();
|
|
1046
|
+
if (FULLSCREEN_SIZES.includes(value)) {
|
|
1047
|
+
return 'fullscreen';
|
|
1048
|
+
}
|
|
1049
|
+
if (CONTENT_SIZES.some((keyword) => value.endsWith(keyword))) {
|
|
1050
|
+
return 'content';
|
|
1051
|
+
}
|
|
1052
|
+
return 'definite';
|
|
1053
|
+
};
|
|
848
1054
|
const BACKDROP = 'backdrop';
|
|
849
1055
|
const GESTURE = 'gesture';
|
|
850
1056
|
const OVERLAY_GESTURE_PRIORITY = 39;
|
|
@@ -979,8 +1185,10 @@ const FOCUS_TRAP_DISABLE_CLASS = 'ion-disable-focus-trap';
|
|
|
979
1185
|
exports.BACKDROP = BACKDROP;
|
|
980
1186
|
exports.FOCUS_TRAP_DISABLE_CLASS = FOCUS_TRAP_DISABLE_CLASS;
|
|
981
1187
|
exports.GESTURE = GESTURE;
|
|
1188
|
+
exports.MENU_BACK_BUTTON_PRIORITY = MENU_BACK_BUTTON_PRIORITY;
|
|
982
1189
|
exports.OVERLAY_GESTURE_PRIORITY = OVERLAY_GESTURE_PRIORITY;
|
|
983
1190
|
exports.actionSheetController = actionSheetController;
|
|
1191
|
+
exports.addCloseWatcherCondition = addCloseWatcherCondition;
|
|
984
1192
|
exports.alertController = alertController;
|
|
985
1193
|
exports.cleanupRootFocusTrapAccessibility = cleanupRootFocusTrapAccessibility;
|
|
986
1194
|
exports.createDelegateController = createDelegateController;
|
|
@@ -989,7 +1197,9 @@ exports.dismiss = dismiss;
|
|
|
989
1197
|
exports.eventMethod = eventMethod;
|
|
990
1198
|
exports.focusFirstDescendant = focusFirstDescendant;
|
|
991
1199
|
exports.focusLastDescendant = focusLastDescendant;
|
|
1200
|
+
exports.getOverlaySizeType = getOverlaySizeType;
|
|
992
1201
|
exports.getPresentedOverlay = getPresentedOverlay;
|
|
1202
|
+
exports.hardwareBackButton = hardwareBackButton;
|
|
993
1203
|
exports.isCancel = isCancel;
|
|
994
1204
|
exports.loadingController = loadingController;
|
|
995
1205
|
exports.modalController = modalController;
|
|
@@ -999,4 +1209,6 @@ exports.present = present;
|
|
|
999
1209
|
exports.restoreRootFocusTrapAccessibility = restoreRootFocusTrapAccessibility;
|
|
1000
1210
|
exports.safeCall = safeCall;
|
|
1001
1211
|
exports.setOverlayId = setOverlayId;
|
|
1212
|
+
exports.shouldUseCloseWatcher = shouldUseCloseWatcher;
|
|
1002
1213
|
exports.toastController = toastController;
|
|
1214
|
+
exports.updateCloseWatcher = updateCloseWatcher;
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*/
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
|
-
var index = require('./index-
|
|
7
|
-
var index$1 = require('./index-
|
|
6
|
+
var index = require('./index-BiQyIvoc.js');
|
|
7
|
+
var index$1 = require('./index-B4ONUQRp.js');
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* Converts a DOM node into a Stencil VNode (or text string) so the
|
package/dist/cjs/{slot-mutation-controller-D6IjSEIh.js → slot-mutation-controller-ClDxh3EK.js}
RENAMED
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
|
-
var
|
|
7
|
-
var helpers = require('./helpers-7wzdhdeg.js');
|
|
6
|
+
var helpers = require('./helpers-Cqr69qxA.js');
|
|
8
7
|
var dir = require('./dir-zwDPRE5K.js');
|
|
9
8
|
|
|
10
9
|
/**
|
|
@@ -96,8 +95,8 @@ const createNotchController = (el, getNotchSpacerEl, getLabelSlot) => {
|
|
|
96
95
|
*/
|
|
97
96
|
width === 0 &&
|
|
98
97
|
notchSpacerEl.offsetParent === null &&
|
|
99
|
-
|
|
100
|
-
'IntersectionObserver' in
|
|
98
|
+
helpers.win !== undefined &&
|
|
99
|
+
'IntersectionObserver' in helpers.win) {
|
|
101
100
|
/**
|
|
102
101
|
* If there is an IO already attached
|
|
103
102
|
* then that will update the notch
|
|
@@ -281,6 +280,73 @@ const createStartContainerController = (el, getStartContainer, shouldApplyAdjust
|
|
|
281
280
|
};
|
|
282
281
|
};
|
|
283
282
|
|
|
283
|
+
/**
|
|
284
|
+
* The content slotted into a form control's start or end slot that a click
|
|
285
|
+
* started on, or `null` when the click did not start on slotted content.
|
|
286
|
+
*
|
|
287
|
+
* The slotted element is compared against the host in case the form control
|
|
288
|
+
* itself is slotted into, for example, an item. Without that check a control
|
|
289
|
+
* carrying slot="start"/"end" would treat every click on itself as a slotted
|
|
290
|
+
* click.
|
|
291
|
+
*/
|
|
292
|
+
const getSlottedClickContent = (ev, el) => {
|
|
293
|
+
const slotted = ev.target.closest('[slot="start"], [slot="end"]');
|
|
294
|
+
return slotted !== null && slotted !== el && el.contains(slotted) ? slotted : null;
|
|
295
|
+
};
|
|
296
|
+
/**
|
|
297
|
+
* Whether a click started on content slotted into a form control's start or
|
|
298
|
+
* end slot.
|
|
299
|
+
*/
|
|
300
|
+
const isSlottedClick = (ev, el) => getSlottedClickContent(ev, el) !== null;
|
|
301
|
+
/**
|
|
302
|
+
* A utility for form components that wrap their content in a <label>, such as
|
|
303
|
+
* ion-input, ion-textarea and ion-select.
|
|
304
|
+
*
|
|
305
|
+
* Clicking slotted content also clicks that label, and the browser follows it
|
|
306
|
+
* with a click on the label's control. That second click would be emitted from
|
|
307
|
+
* the host as a duplicate, so the slotted click is remembered and the click
|
|
308
|
+
* that follows it is suppressed.
|
|
309
|
+
*
|
|
310
|
+
* Browsers skip the forwarding when the click lands on interactive content,
|
|
311
|
+
* such as a slotted button, so the slotted click is remembered for a frame
|
|
312
|
+
* rather than until a forwarded click that may never arrive.
|
|
313
|
+
*
|
|
314
|
+
* @internal
|
|
315
|
+
* @param el - The host element.
|
|
316
|
+
* @param getNativeInput - A callback returning the native form control the
|
|
317
|
+
* label points at, for components that have one. Those components emit the
|
|
318
|
+
* click from the host rather than the control, so the control's click is
|
|
319
|
+
* always stopped and re-dispatched from the host. Omit it for components whose
|
|
320
|
+
* label has no `for` attribute, such as ion-select, where the browser forwards
|
|
321
|
+
* to an internal control that already re-bubbles targeting the host.
|
|
322
|
+
*/
|
|
323
|
+
const createClickController = (el, getNativeInput) => {
|
|
324
|
+
let hasSlottedClick = false;
|
|
325
|
+
const handleClickCapture = (ev) => {
|
|
326
|
+
if (isSlottedClick(ev, el)) {
|
|
327
|
+
hasSlottedClick = true;
|
|
328
|
+
helpers.raf(() => (hasSlottedClick = false));
|
|
329
|
+
return;
|
|
330
|
+
}
|
|
331
|
+
if (getNativeInput === undefined) {
|
|
332
|
+
if (hasSlottedClick) {
|
|
333
|
+
ev.stopPropagation();
|
|
334
|
+
hasSlottedClick = false;
|
|
335
|
+
}
|
|
336
|
+
return;
|
|
337
|
+
}
|
|
338
|
+
const nativeInput = getNativeInput();
|
|
339
|
+
if (nativeInput !== undefined && ev.target === nativeInput) {
|
|
340
|
+
ev.stopPropagation();
|
|
341
|
+
if (!hasSlottedClick) {
|
|
342
|
+
el.click();
|
|
343
|
+
}
|
|
344
|
+
hasSlottedClick = false;
|
|
345
|
+
}
|
|
346
|
+
};
|
|
347
|
+
return { handleClickCapture };
|
|
348
|
+
};
|
|
349
|
+
|
|
284
350
|
/**
|
|
285
351
|
* Used to update a scoped component that uses emulated slots. This fires when
|
|
286
352
|
* content is passed into the slot or when the content inside of a slot changes.
|
|
@@ -293,7 +359,7 @@ const createStartContainerController = (el, getStartContainer, shouldApplyAdjust
|
|
|
293
359
|
const createSlotMutationController = (el, slotName, mutationCallback) => {
|
|
294
360
|
let hostMutationObserver;
|
|
295
361
|
let slottedContentMutationObserver;
|
|
296
|
-
if (
|
|
362
|
+
if (helpers.win !== undefined && 'MutationObserver' in helpers.win) {
|
|
297
363
|
const slots = Array.isArray(slotName) ? slotName : [slotName];
|
|
298
364
|
hostMutationObserver = new MutationObserver((entries) => {
|
|
299
365
|
for (const entry of entries) {
|
|
@@ -392,6 +458,8 @@ const createSlotMutationController = (el, slotName, mutationCallback) => {
|
|
|
392
458
|
};
|
|
393
459
|
};
|
|
394
460
|
|
|
461
|
+
exports.createClickController = createClickController;
|
|
395
462
|
exports.createNotchController = createNotchController;
|
|
396
463
|
exports.createSlotMutationController = createSlotMutationController;
|
|
397
464
|
exports.createStartContainerController = createStartContainerController;
|
|
465
|
+
exports.getSlottedClickContent = getSlottedClickContent;
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
*/
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
|
-
var index = require('./index-
|
|
7
|
-
var index$1 = require('./index-
|
|
8
|
-
var helpers = require('./helpers-
|
|
6
|
+
var index = require('./index-BiQyIvoc.js');
|
|
7
|
+
var index$1 = require('./index-CNaZ6SYM.js');
|
|
8
|
+
var helpers = require('./helpers-Cqr69qxA.js');
|
|
9
9
|
require('./dir-zwDPRE5K.js');
|
|
10
10
|
|
|
11
11
|
const startStatusTap = () => {
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
*/
|
|
4
4
|
'use strict';
|
|
5
5
|
|
|
6
|
-
var helpers = require('./helpers-
|
|
6
|
+
var helpers = require('./helpers-Cqr69qxA.js');
|
|
7
7
|
var dir = require('./dir-zwDPRE5K.js');
|
|
8
8
|
var index = require('./index-DRPqwSvU.js');
|
|
9
|
-
require('./index-
|
|
9
|
+
require('./index-BiQyIvoc.js');
|
|
10
10
|
require('./gesture-controller-CeJslptU.js');
|
|
11
11
|
|
|
12
12
|
const createSwipeBackGesture = (el, canStartHandler, onStartHandler, onMoveHandler, onEndHandler) => {
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
* (C) Ionic http://ionicframework.com - MIT License
|
|
3
3
|
*/
|
|
4
4
|
import { Host, forceUpdate, h } from "@stencil/core";
|
|
5
|
-
import {
|
|
5
|
+
import { createAriaAttributeController } from "../../utils/attribute-controller";
|
|
6
|
+
import { hasShadowDom } from "../../utils/helpers";
|
|
6
7
|
import { printIonWarning } from "../../utils/logging/index";
|
|
7
8
|
import { createColorClasses, hostContext, openURL } from "../../utils/theme";
|
|
8
9
|
import { getIonMode } from "../../global/ionic-global";
|
|
@@ -23,7 +24,6 @@ export class Button {
|
|
|
23
24
|
this.inToolbar = false;
|
|
24
25
|
this.formButtonEl = null;
|
|
25
26
|
this.formEl = null;
|
|
26
|
-
this.inheritedAttributes = {};
|
|
27
27
|
/**
|
|
28
28
|
* If `true`, the button only has an icon.
|
|
29
29
|
*/
|
|
@@ -82,23 +82,6 @@ export class Button {
|
|
|
82
82
|
this.formButtonEl.disabled = disabled;
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
|
-
/**
|
|
86
|
-
* This component is used within the `ion-input-password-toggle` component
|
|
87
|
-
* to toggle the visibility of the password input.
|
|
88
|
-
* These attributes need to update based on the state of the password input.
|
|
89
|
-
* Otherwise, the values will be stale.
|
|
90
|
-
*
|
|
91
|
-
* @param newValue
|
|
92
|
-
* @param _oldValue
|
|
93
|
-
* @param propName
|
|
94
|
-
*/
|
|
95
|
-
onAriaChanged(newValue, _oldValue, propName) {
|
|
96
|
-
this.inheritedAttributes = {
|
|
97
|
-
...this.inheritedAttributes,
|
|
98
|
-
[propName]: newValue,
|
|
99
|
-
};
|
|
100
|
-
forceUpdate(this);
|
|
101
|
-
}
|
|
102
85
|
/**
|
|
103
86
|
* This is responsible for rendering a hidden native
|
|
104
87
|
* button element inside the associated form. This allows
|
|
@@ -136,7 +119,21 @@ export class Button {
|
|
|
136
119
|
this.inToolbar = !!this.el.closest('ion-buttons');
|
|
137
120
|
this.inListHeader = !!this.el.closest('ion-list-header');
|
|
138
121
|
this.inItem = !!this.el.closest('ion-item') || !!this.el.closest('ion-item-divider');
|
|
139
|
-
|
|
122
|
+
/**
|
|
123
|
+
* The ARIA state has to stay live, since `ion-input-password-toggle` rewrites
|
|
124
|
+
* `aria-label` and `aria-pressed` on its `ion-button` on every toggle. We keep
|
|
125
|
+
* `aria-disabled` out of the watch because the `<Host>` below renders it from the
|
|
126
|
+
* `disabled` prop and those writes would clobber a developer's value, and `role` out
|
|
127
|
+
* because a post-load write stays on the host too, which would put the same role on
|
|
128
|
+
* two elements in the accessibility tree.
|
|
129
|
+
*/
|
|
130
|
+
this.ariaController = createAriaAttributeController(this.el, () => forceUpdate(this), ['aria-disabled', 'role']);
|
|
131
|
+
}
|
|
132
|
+
connectedCallback() {
|
|
133
|
+
this.ariaController?.init();
|
|
134
|
+
}
|
|
135
|
+
disconnectedCallback() {
|
|
136
|
+
this.ariaController?.destroy();
|
|
140
137
|
}
|
|
141
138
|
get hasIconOnly() {
|
|
142
139
|
return !!this.el.querySelector('[slot="icon-only"]');
|
|
@@ -211,7 +208,8 @@ export class Button {
|
|
|
211
208
|
}
|
|
212
209
|
render() {
|
|
213
210
|
const mode = getIonMode(this);
|
|
214
|
-
const { buttonType, type, disabled, rel, target, size, href, color, expand, hasIconOnly, shape, strong
|
|
211
|
+
const { buttonType, type, disabled, rel, target, size, href, color, expand, hasIconOnly, shape, strong } = this;
|
|
212
|
+
const inheritedAttributes = this.ariaController?.attributes ?? {};
|
|
215
213
|
const finalSize = size === undefined && this.inItem ? 'small' : size;
|
|
216
214
|
const TagType = href === undefined ? 'button' : 'a';
|
|
217
215
|
const attrs = TagType === 'button'
|
|
@@ -236,7 +234,7 @@ export class Button {
|
|
|
236
234
|
{
|
|
237
235
|
type !== 'button' && this.renderHiddenButton();
|
|
238
236
|
}
|
|
239
|
-
return (h(Host, { key: '
|
|
237
|
+
return (h(Host, { key: 'fd42d1a5836c148cddd6c474c130ce4bb36286ea', onClick: this.handleClick, "aria-disabled": disabled ? 'true' : null, class: createColorClasses(color, {
|
|
240
238
|
[mode]: true,
|
|
241
239
|
[buttonType]: true,
|
|
242
240
|
[`${buttonType}-${expand}`]: expand !== undefined,
|
|
@@ -251,7 +249,7 @@ export class Button {
|
|
|
251
249
|
'button-disabled': disabled,
|
|
252
250
|
'ion-activatable': true,
|
|
253
251
|
'ion-focusable': true,
|
|
254
|
-
}) }, h(TagType, { key: '
|
|
252
|
+
}) }, h(TagType, { key: '97dbf689ea912aed38182dbe0097a2bf5b768816', ...attrs, class: "button-native", part: "native", disabled: disabled, onFocus: this.onFocus, onBlur: this.onBlur, ...inheritedAttributes }, h("span", { key: '0f1ff4c667e95a8e3dc787fee43fe529b95477b7', class: "button-inner" }, h("slot", { key: 'fc1e8b8080d02828c392e9edd6a70e0255435f82', name: "icon-only", onSlotchange: this.slotChanged }), h("slot", { key: 'c1ece4c0d935f4d023d38fee4cf529dd4123d487', name: "start" }), h("slot", { key: '970db0ee1e3633bc9cbff52eca446e4891ff6851' }), h("slot", { key: 'ef8d7d894f01dbe881f381b985620c2a482e55fe', name: "end" })), mode === 'md' && h("ion-ripple-effect", { key: 'fea5e49a54b0efd07b1bd35d9fd5d2d862a2bac1', type: this.rippleType }))));
|
|
255
253
|
}
|
|
256
254
|
static get is() { return "ion-button"; }
|
|
257
255
|
static get encapsulation() { return "shadow"; }
|
|
@@ -647,15 +645,6 @@ export class Button {
|
|
|
647
645
|
return [{
|
|
648
646
|
"propName": "disabled",
|
|
649
647
|
"methodName": "disabledChanged"
|
|
650
|
-
}, {
|
|
651
|
-
"propName": "aria-checked",
|
|
652
|
-
"methodName": "onAriaChanged"
|
|
653
|
-
}, {
|
|
654
|
-
"propName": "aria-label",
|
|
655
|
-
"methodName": "onAriaChanged"
|
|
656
|
-
}, {
|
|
657
|
-
"propName": "aria-pressed",
|
|
658
|
-
"methodName": "onAriaChanged"
|
|
659
648
|
}];
|
|
660
649
|
}
|
|
661
650
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* (C) Ionic http://ionicframework.com - MIT License
|
|
3
3
|
*/
|
|
4
|
-
import { Host, h } from "@stencil/core";
|
|
5
|
-
import {
|
|
4
|
+
import { Host, h, forceUpdate } from "@stencil/core";
|
|
5
|
+
import { createAttributeController } from "../../utils/attribute-controller";
|
|
6
6
|
import { createColorClasses, openURL } from "../../utils/theme";
|
|
7
7
|
import { getIonMode } from "../../global/ionic-global";
|
|
8
8
|
/**
|
|
@@ -12,7 +12,6 @@ import { getIonMode } from "../../global/ionic-global";
|
|
|
12
12
|
*/
|
|
13
13
|
export class Card {
|
|
14
14
|
constructor() {
|
|
15
|
-
this.inheritedAriaAttributes = {};
|
|
16
15
|
/**
|
|
17
16
|
* If `true`, a button tag will be rendered and the card will be tappable.
|
|
18
17
|
*/
|
|
@@ -32,7 +31,18 @@ export class Card {
|
|
|
32
31
|
this.routerDirection = 'forward';
|
|
33
32
|
}
|
|
34
33
|
componentWillLoad() {
|
|
35
|
-
|
|
34
|
+
/**
|
|
35
|
+
* Only the initial copy takes the attribute off the host, so an `aria-label` written
|
|
36
|
+
* after load stays on the host too. That's harmless here, because unlike `ion-item`
|
|
37
|
+
* the card host renders no role of its own, so nothing reads the leftover copy.
|
|
38
|
+
*/
|
|
39
|
+
this.ariaController = createAttributeController(this.el, ['aria-label'], () => forceUpdate(this));
|
|
40
|
+
}
|
|
41
|
+
connectedCallback() {
|
|
42
|
+
this.ariaController?.init();
|
|
43
|
+
}
|
|
44
|
+
disconnectedCallback() {
|
|
45
|
+
this.ariaController?.destroy();
|
|
36
46
|
}
|
|
37
47
|
isClickable() {
|
|
38
48
|
return this.href !== undefined || this.button;
|
|
@@ -42,7 +52,8 @@ export class Card {
|
|
|
42
52
|
if (!clickable) {
|
|
43
53
|
return [h("slot", null)];
|
|
44
54
|
}
|
|
45
|
-
const { href, routerAnimation, routerDirection
|
|
55
|
+
const { href, routerAnimation, routerDirection } = this;
|
|
56
|
+
const inheritedAriaAttributes = this.ariaController?.attributes ?? {};
|
|
46
57
|
const TagType = clickable ? (href === undefined ? 'button' : 'a') : 'div';
|
|
47
58
|
const attrs = TagType === 'button'
|
|
48
59
|
? { type: this.type }
|
|
@@ -56,7 +67,7 @@ export class Card {
|
|
|
56
67
|
}
|
|
57
68
|
render() {
|
|
58
69
|
const mode = getIonMode(this);
|
|
59
|
-
return (h(Host, { key: '
|
|
70
|
+
return (h(Host, { key: '104412c26f53cce36432c3bb4d9e38bbe00c5816', class: createColorClasses(this.color, {
|
|
60
71
|
[mode]: true,
|
|
61
72
|
'card-disabled': this.disabled,
|
|
62
73
|
'ion-activatable': this.isClickable(),
|