@ionic/core 8.5.4-dev.11744052844.17c6a004 → 8.5.4-dev.11744209290.123af9eb
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/action-sheet.js +37 -23
- package/components/alert.js +41 -25
- package/components/animation.js +1 -1
- package/components/backdrop.js +11 -4
- package/components/button-active.js +1 -1
- package/components/button.js +29 -23
- package/components/buttons.js +14 -4
- package/components/capacitor.js +1 -1
- package/components/checkbox.js +40 -16
- package/components/content.js +24 -5
- package/components/data.js +1 -1
- package/components/gesture-controller.js +1 -1
- package/components/haptic.js +1 -1
- package/components/hardware-back-button.js +1 -1
- package/components/header.js +12 -7
- package/components/helpers.js +2 -5
- package/components/icon.js +1 -2
- package/components/index3.js +3 -5
- package/components/index4.js +1 -1
- package/components/index5.js +28 -3
- package/components/index7.js +163 -27
- package/components/index8.js +1 -1
- package/components/index9.js +3 -163
- package/components/input-shims.js +2 -2
- package/components/input.utils.js +1 -1
- package/components/ion-accordion-group.js +19 -6
- package/components/ion-accordion.js +32 -14
- package/components/ion-app.js +3 -4
- package/components/ion-avatar.js +2 -4
- package/components/ion-back-button.js +12 -13
- package/components/ion-badge.js +2 -5
- package/components/ion-breadcrumb.js +22 -20
- package/components/ion-breadcrumbs.js +14 -10
- package/components/ion-card-content.js +2 -4
- package/components/ion-card-header.js +7 -5
- package/components/ion-card-subtitle.js +2 -5
- package/components/ion-card-title.js +2 -5
- package/components/ion-card.js +16 -11
- package/components/ion-chip.js +8 -5
- package/components/ion-col.js +1 -26
- package/components/ion-datetime-button.js +15 -13
- package/components/ion-datetime.js +126 -53
- package/components/ion-fab-button.js +37 -20
- package/components/ion-fab-list.js +7 -2
- package/components/ion-fab.js +10 -4
- package/components/ion-footer.js +13 -8
- package/components/ion-grid.js +4 -2
- package/components/ion-img.js +1 -6
- package/components/ion-infinite-scroll-content.js +2 -6
- package/components/ion-infinite-scroll.js +27 -6
- package/components/ion-input-password-toggle.js +7 -9
- package/components/ion-input.js +69 -41
- package/components/ion-item-divider.js +9 -5
- package/components/ion-item-group.js +2 -4
- package/components/ion-item-option.js +14 -12
- package/components/ion-item-options.js +6 -4
- package/components/ion-item-sliding.js +4 -2
- package/components/ion-loading.js +36 -19
- package/components/ion-menu-button.js +15 -10
- package/components/ion-menu-toggle.js +9 -5
- package/components/ion-menu.js +25 -9
- package/components/ion-nav-link.js +6 -6
- package/components/ion-nav.js +7 -10
- package/components/ion-note.js +2 -5
- package/components/ion-picker-legacy.js +44 -24
- package/components/ion-progress-bar.js +19 -6
- package/components/ion-range.js +65 -25
- package/components/ion-refresher-content.js +1 -5
- package/components/ion-refresher.js +54 -6
- package/components/ion-reorder-group.js +6 -4
- package/components/ion-reorder.js +3 -5
- package/components/ion-route-redirect.js +0 -2
- package/components/ion-route.js +9 -7
- package/components/ion-router-link.js +7 -9
- package/components/ion-router-outlet.js +10 -8
- package/components/ion-router.js +18 -0
- package/components/ion-row.js +1 -2
- package/components/ion-searchbar.js +78 -29
- package/components/ion-segment-button.js +19 -10
- package/components/ion-segment-content.js +1 -2
- package/components/ion-segment-view.js +5 -5
- package/components/ion-segment.js +22 -11
- package/components/ion-select-option.js +4 -3
- package/components/ion-select.js +58 -32
- package/components/ion-skeleton-text.js +4 -2
- package/components/ion-split-pane.js +10 -5
- package/components/ion-tab-bar.js +7 -6
- package/components/ion-tab-button.js +10 -12
- package/components/ion-tab.js +2 -5
- package/components/ion-tabs.js +3 -4
- package/components/ion-text.js +1 -3
- package/components/ion-textarea.js +62 -34
- package/components/ion-thumbnail.js +1 -2
- package/components/ion-toast.js +55 -32
- package/components/ion-toggle.js +44 -20
- package/components/item.js +20 -14
- package/components/keyboard-controller.js +2 -2
- package/components/keyboard.js +134 -69
- package/components/keyboard2.js +69 -134
- package/components/label.js +2 -6
- package/components/list-header.js +2 -6
- package/components/list.js +5 -5
- package/components/modal.js +117 -39
- package/components/notch-controller.js +1 -1
- package/components/overlays.js +2 -2
- package/components/picker-column-option.js +18 -5
- package/components/picker-column.js +25 -10
- package/components/picker-column2.js +5 -8
- package/components/picker.js +2 -4
- package/components/popover.js +129 -37
- package/components/radio-group.js +10 -10
- package/components/radio.js +27 -13
- package/components/refresher.utils.js +2 -2
- package/components/ripple-effect.js +10 -2
- package/components/select-modal.js +3 -8
- package/components/select-popover.js +5 -8
- package/components/spinner.js +4 -5
- package/components/swipe-back.js +1 -1
- package/components/title.js +2 -6
- package/components/toolbar.js +2 -5
- package/css/global.bundle.css +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/structure.css +1 -1
- package/css/structure.css.map +1 -1
- package/dist/cjs/{animation-b4fdf128.js → animation-Bz5ImL40.js} +1 -1
- package/dist/cjs/{app-globals-dd592863.js → app-globals-Di9ZJzjm.js} +1 -1
- package/dist/cjs/{button-active-43e2b419.js → button-active-BlMN9Iyq.js} +3 -3
- package/dist/cjs/{capacitor-c04564bf.js → capacitor-DmA66EwP.js} +1 -1
- package/dist/cjs/{data-27cc2c9c.js → data-DlPf8ZXm.js} +1 -1
- package/dist/cjs/{framework-delegate-50a86d56.js → framework-delegate-B0-bTZ_Y.js} +1 -1
- package/dist/cjs/{gesture-controller-9436f482.js → gesture-controller-dtqlP_q4.js} +1 -1
- package/dist/cjs/{haptic-f6b37aa3.js → haptic-ClPPQ_PS.js} +1 -1
- package/dist/cjs/{hardware-back-button-5a99001f.js → hardware-back-button-lTgcqUpk.js} +3 -3
- package/dist/cjs/{helpers-3a248559.js → helpers-CLmZlPvl.js} +1 -4
- package/dist/cjs/{index-e36bd277.js → index-B4SdCKIQ.js} +2 -2
- package/dist/cjs/{index-e630fd95.js → index-BE9YH63j.js} +6 -6
- package/dist/cjs/{index-2e236a04.js → index-BVfbh2cJ.js} +1378 -671
- package/dist/cjs/{index-ee07ed59.js → index-CAvQ7Tka.js} +3 -4
- package/dist/cjs/{index-073c7cdc.js → index-CPbAsnJK.js} +1 -0
- package/dist/cjs/{index-4b70187a.js → index-CXThGkw7.js} +9 -9
- package/dist/cjs/{index-509ca0d3.js → index-CquwaYOd.js} +3 -3
- package/dist/cjs/{index-48b2a28e.js → index-rYFHa7ZR.js} +1 -1
- package/dist/cjs/index.cjs.js +18 -20
- package/dist/cjs/{input-shims-22a9973f.js → input-shims-DA_nJulF.js} +8 -8
- package/dist/cjs/{input.utils-e82b8ed0.js → input.utils-UHOCoNWM.js} +3 -3
- package/dist/cjs/ion-accordion_2.cjs.entry.js +54 -25
- package/dist/cjs/ion-action-sheet.cjs.entry.js +50 -38
- package/dist/cjs/ion-alert.cjs.entry.js +55 -41
- package/dist/cjs/ion-app_8.cjs.entry.js +96 -65
- package/dist/cjs/ion-avatar_3.cjs.entry.js +8 -16
- package/dist/cjs/ion-back-button.cjs.entry.js +15 -18
- package/dist/cjs/ion-backdrop.cjs.entry.js +13 -8
- package/dist/cjs/ion-breadcrumb_2.cjs.entry.js +38 -34
- package/dist/cjs/ion-button_2.cjs.entry.js +33 -30
- package/dist/cjs/ion-card_5.cjs.entry.js +32 -35
- package/dist/cjs/ion-checkbox.cjs.entry.js +44 -22
- package/dist/cjs/ion-chip.cjs.entry.js +11 -10
- package/dist/cjs/ion-col_3.cjs.entry.js +8 -34
- package/dist/cjs/ion-datetime-button.cjs.entry.js +20 -20
- package/dist/cjs/ion-datetime_3.cjs.entry.js +182 -94
- package/dist/cjs/ion-fab_3.cjs.entry.js +57 -31
- package/dist/cjs/ion-img.cjs.entry.js +4 -11
- package/dist/cjs/ion-infinite-scroll_2.cjs.entry.js +35 -20
- package/dist/cjs/ion-input-password-toggle.cjs.entry.js +11 -15
- package/dist/cjs/ion-input.cjs.entry.js +76 -50
- package/dist/cjs/ion-item-option_3.cjs.entry.js +32 -28
- package/dist/cjs/ion-item_8.cjs.entry.js +49 -52
- package/dist/cjs/ion-loading.cjs.entry.js +46 -31
- package/dist/cjs/ion-menu_3.cjs.entry.js +62 -39
- package/dist/cjs/ion-modal.cjs.entry.js +128 -52
- package/dist/cjs/ion-nav_2.cjs.entry.js +17 -22
- package/dist/cjs/ion-picker-column-option.cjs.entry.js +22 -11
- package/dist/cjs/ion-picker-column.cjs.entry.js +30 -17
- package/dist/cjs/ion-picker.cjs.entry.js +4 -8
- package/dist/cjs/ion-popover.cjs.entry.js +137 -47
- package/dist/cjs/ion-progress-bar.cjs.entry.js +22 -11
- package/dist/cjs/ion-radio_2.cjs.entry.js +42 -30
- package/dist/cjs/ion-range.cjs.entry.js +71 -33
- package/dist/cjs/ion-refresher_2.cjs.entry.js +68 -26
- package/dist/cjs/ion-reorder_2.cjs.entry.js +17 -19
- package/dist/cjs/ion-ripple-effect.cjs.entry.js +12 -6
- package/dist/cjs/ion-route_4.cjs.entry.js +34 -20
- package/dist/cjs/ion-searchbar.cjs.entry.js +83 -36
- package/dist/cjs/ion-segment-content.cjs.entry.js +2 -5
- package/dist/cjs/ion-segment-view.cjs.entry.js +6 -8
- package/dist/cjs/ion-segment_2.cjs.entry.js +47 -29
- package/dist/cjs/ion-select-modal.cjs.entry.js +13 -20
- package/dist/cjs/ion-select_3.cjs.entry.js +79 -57
- package/dist/cjs/ion-spinner.cjs.entry.js +8 -11
- package/dist/cjs/ion-split-pane.cjs.entry.js +12 -9
- package/dist/cjs/ion-tab-bar_2.cjs.entry.js +25 -28
- package/dist/cjs/ion-tab_2.cjs.entry.js +8 -14
- package/dist/cjs/ion-text.cjs.entry.js +4 -8
- package/dist/cjs/ion-textarea.cjs.entry.js +69 -43
- package/dist/cjs/ion-toast.cjs.entry.js +65 -44
- package/dist/cjs/ion-toggle.cjs.entry.js +53 -31
- package/dist/cjs/{ionic-global-acb665ad.js → ionic-global-AdqEvgj6.js} +1 -1
- package/dist/cjs/ionic.cjs.js +8 -8
- package/dist/cjs/{ios.transition-ae7afca9.js → ios.transition-B8HcmmPx.js} +7 -7
- package/dist/cjs/{keyboard-0272231f.js → keyboard-UuAS4D_9.js} +1 -1
- package/dist/cjs/{keyboard-controller-c05e747a.js → keyboard-controller-GXBiBRKS.js} +2 -2
- package/dist/cjs/{keyboard-af1bb365.js → keyboard-hHzlEQpk.js} +3 -3
- package/dist/cjs/loader.cjs.js +4 -6
- package/dist/cjs/{md.transition-26003e25.js → md.transition-54O0AjJC.js} +7 -7
- package/dist/cjs/{notch-controller-ae03a497.js → notch-controller-DNfj7cO6.js} +2 -2
- package/dist/cjs/{overlays-32e1b66b.js → overlays-CSyZW4m0.js} +7 -7
- package/dist/cjs/{status-tap-03023755.js → status-tap-B1Kcv7yf.js} +5 -5
- package/dist/cjs/{swipe-back-cd0d9f77.js → swipe-back-Di-t3rsI.js} +4 -4
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/accordion/accordion.js +43 -13
- package/dist/collection/components/accordion-group/accordion-group.js +35 -8
- package/dist/collection/components/action-sheet/action-sheet.js +84 -31
- package/dist/collection/components/alert/alert.js +94 -34
- package/dist/collection/components/back-button/back-button.js +30 -14
- package/dist/collection/components/backdrop/backdrop.js +18 -3
- package/dist/collection/components/badge/badge.js +3 -4
- package/dist/collection/components/breadcrumb/breadcrumb.js +57 -26
- package/dist/collection/components/breadcrumbs/breadcrumbs.js +24 -10
- package/dist/collection/components/button/button.js +74 -33
- package/dist/collection/components/buttons/buttons.js +15 -1
- package/dist/collection/components/card/card.js +44 -16
- package/dist/collection/components/card-header/card-header.js +11 -3
- package/dist/collection/components/card-subtitle/card-subtitle.js +3 -4
- package/dist/collection/components/card-title/card-title.js +3 -4
- package/dist/collection/components/checkbox/checkbox.js +74 -24
- package/dist/collection/components/chip/chip.js +15 -4
- package/dist/collection/components/col/col.js +72 -50
- package/dist/collection/components/content/content.js +43 -9
- package/dist/collection/components/datetime/datetime.js +211 -72
- package/dist/collection/components/datetime-button/datetime-button.js +21 -11
- package/dist/collection/components/fab/fab.js +21 -6
- package/dist/collection/components/fab-button/fab-button.js +76 -28
- package/dist/collection/components/fab-list/fab-list.js +12 -2
- package/dist/collection/components/footer/footer.js +16 -5
- package/dist/collection/components/grid/grid.js +6 -1
- package/dist/collection/components/header/header.js +15 -4
- package/dist/collection/components/img/img.js +6 -6
- package/dist/collection/components/infinite-scroll/infinite-scroll.js +35 -7
- package/dist/collection/components/infinite-scroll-content/infinite-scroll-content.js +6 -4
- package/dist/collection/components/input/input.js +168 -69
- package/dist/collection/components/input-password-toggle/input-password-toggle.js +16 -8
- package/dist/collection/components/item/item.js +56 -21
- package/dist/collection/components/item-divider/item-divider.js +13 -3
- package/dist/collection/components/item-option/item-option.js +36 -16
- package/dist/collection/components/item-options/item-options.js +7 -1
- package/dist/collection/components/item-sliding/item-sliding.js +6 -1
- package/dist/collection/components/label/label.js +6 -4
- package/dist/collection/components/list/list.js +9 -3
- package/dist/collection/components/list-header/list-header.js +6 -6
- package/dist/collection/components/loading/loading.js +86 -29
- package/dist/collection/components/menu/menu.js +42 -10
- package/dist/collection/components/menu-button/menu-button.js +27 -10
- package/dist/collection/components/menu-toggle/menu-toggle.js +14 -5
- package/dist/collection/components/modal/modal.js +188 -51
- package/dist/collection/components/nav/nav.js +24 -11
- package/dist/collection/components/nav-link/nav-link.js +18 -8
- package/dist/collection/components/note/note.js +3 -4
- package/dist/collection/components/picker-column/picker-column.js +34 -10
- package/dist/collection/components/picker-column-option/picker-column-option.js +25 -4
- package/dist/collection/components/picker-legacy/picker.js +91 -31
- package/dist/collection/components/picker-legacy-column/picker-column.js +4 -2
- package/dist/collection/components/popover/popover.js +208 -55
- package/dist/collection/components/progress-bar/progress-bar.js +31 -6
- package/dist/collection/components/radio/radio.js +46 -16
- package/dist/collection/components/radio-group/radio-group.js +26 -12
- package/dist/collection/components/range/range.js +109 -34
- package/dist/collection/components/refresher/refresher.js +68 -6
- package/dist/collection/components/refresher-content/refresher-content.js +12 -8
- package/dist/collection/components/reorder-group/reorder-group.js +6 -1
- package/dist/collection/components/ripple-effect/ripple-effect.js +12 -1
- package/dist/collection/components/route/route.js +24 -9
- package/dist/collection/components/route-redirect/route-redirect.js +6 -6
- package/dist/collection/components/router/router.js +24 -2
- package/dist/collection/components/router-link/router-link.js +24 -12
- package/dist/collection/components/router-outlet/router-outlet.js +24 -8
- package/dist/collection/components/searchbar/searchbar.js +141 -46
- package/dist/collection/components/segment/segment.js +38 -13
- package/dist/collection/components/segment-button/segment-button.js +32 -11
- package/dist/collection/components/segment-view/segment-view.js +6 -2
- package/dist/collection/components/select/select.ios.css +3 -5
- package/dist/collection/components/select/select.js +117 -45
- package/dist/collection/components/select/select.md.css +15 -51
- package/dist/collection/components/select-modal/select-modal.js +9 -4
- package/dist/collection/components/select-option/select-option.js +9 -3
- package/dist/collection/components/select-popover/select-popover.js +18 -8
- package/dist/collection/components/skeleton-text/skeleton-text.js +6 -1
- package/dist/collection/components/spinner/spinner.js +15 -7
- package/dist/collection/components/split-pane/split-pane.js +17 -4
- package/dist/collection/components/tab/tab.js +14 -7
- package/dist/collection/components/tab-bar/tab-bar.js +14 -5
- package/dist/collection/components/tab-button/tab-button.js +32 -16
- package/dist/collection/components/tabs/tabs.js +5 -3
- package/dist/collection/components/text/text.js +3 -4
- package/dist/collection/components/textarea/textarea.js +144 -57
- package/dist/collection/components/title/title.js +6 -6
- package/dist/collection/components/toast/toast.js +119 -45
- package/dist/collection/components/toggle/toggle.js +75 -25
- package/dist/collection/components/toolbar/toolbar.js +3 -2
- package/dist/docs.d.ts +8 -0
- package/dist/docs.json +1799 -584
- package/dist/esm/{animation-eab5a4ca.js → animation-CCtpQcsN.js} +1 -1
- package/dist/esm/{app-globals-7b6cbf1a.js → app-globals-CispSZgz.js} +1 -1
- package/dist/esm/{button-active-90f1dbc4.js → button-active-D92yWoWC.js} +3 -3
- package/dist/esm/{capacitor-59395cbd.js → capacitor-CFERIeaU.js} +1 -1
- package/dist/esm/{data-174ad5e0.js → data-Dq3-TN9Z.js} +2 -2
- package/dist/esm/{framework-delegate-2eea1763.js → framework-delegate-D3CI7y6x.js} +1 -1
- package/dist/esm/{gesture-controller-314a54f6.js → gesture-controller-BTEOs1at.js} +1 -1
- package/dist/esm/{haptic-ac164e4c.js → haptic-DzAMWJuk.js} +2 -2
- package/dist/esm/{hardware-back-button-864101a3.js → hardware-back-button-CRemSDoj.js} +3 -3
- package/dist/esm/{helpers-78efeec3.js → helpers-Di6ciXLG.js} +2 -5
- package/dist/esm/{index-40894f4b.js → index-B2_fY2up.js} +2 -2
- package/dist/esm/{index-e2cf2ceb.js → index-BLV6ykCk.js} +2 -1
- package/dist/esm/{index-527b9e34.js → index-C5UXyyFe.js} +1378 -651
- package/dist/esm/{index-39782642.js → index-CfgBF1SE.js} +4 -6
- package/dist/esm/{index-e919e353.js → index-DWiwgv23.js} +3 -3
- package/dist/esm/{index-ecb55b8d.js → index-DYJvRcE0.js} +6 -6
- package/dist/esm/{index-f9f5d018.js → index-DZLiflRE.js} +6 -6
- package/dist/esm/{index-738d7504.js → index-PfJyigSK.js} +2 -2
- package/dist/esm/index.js +18 -18
- package/dist/esm/{input-shims-7dc1f6dc.js → input-shims-BL_oixbH.js} +8 -8
- package/dist/esm/{input.utils-28bf4ef0.js → input.utils-Bd73EHpQ.js} +3 -3
- package/dist/esm/ion-accordion_2.entry.js +54 -23
- package/dist/esm/ion-action-sheet.entry.js +50 -36
- package/dist/esm/ion-alert.entry.js +55 -39
- package/dist/esm/ion-app_8.entry.js +96 -63
- package/dist/esm/ion-avatar_3.entry.js +8 -14
- package/dist/esm/ion-back-button.entry.js +15 -16
- package/dist/esm/ion-backdrop.entry.js +13 -6
- package/dist/esm/ion-breadcrumb_2.entry.js +38 -32
- package/dist/esm/ion-button_2.entry.js +33 -28
- package/dist/esm/ion-card_5.entry.js +32 -33
- package/dist/esm/ion-checkbox.entry.js +44 -20
- package/dist/esm/ion-chip.entry.js +11 -8
- package/dist/esm/ion-col_3.entry.js +8 -32
- package/dist/esm/ion-datetime-button.entry.js +20 -18
- package/dist/esm/ion-datetime_3.entry.js +182 -92
- package/dist/esm/ion-fab_3.entry.js +57 -29
- package/dist/esm/ion-img.entry.js +4 -9
- package/dist/esm/ion-infinite-scroll_2.entry.js +35 -18
- package/dist/esm/ion-input-password-toggle.entry.js +11 -13
- package/dist/esm/ion-input.entry.js +76 -48
- package/dist/esm/ion-item-option_3.entry.js +32 -26
- package/dist/esm/ion-item_8.entry.js +49 -50
- package/dist/esm/ion-loading.entry.js +46 -29
- package/dist/esm/ion-menu_3.entry.js +62 -37
- package/dist/esm/ion-modal.entry.js +128 -50
- package/dist/esm/ion-nav_2.entry.js +17 -20
- package/dist/esm/ion-picker-column-option.entry.js +22 -9
- package/dist/esm/ion-picker-column.entry.js +30 -15
- package/dist/esm/ion-picker.entry.js +4 -6
- package/dist/esm/ion-popover.entry.js +137 -45
- package/dist/esm/ion-progress-bar.entry.js +22 -9
- package/dist/esm/ion-radio_2.entry.js +42 -28
- package/dist/esm/ion-range.entry.js +71 -31
- package/dist/esm/ion-refresher_2.entry.js +68 -24
- package/dist/esm/ion-reorder_2.entry.js +17 -17
- package/dist/esm/ion-ripple-effect.entry.js +12 -4
- package/dist/esm/ion-route_4.entry.js +34 -18
- package/dist/esm/ion-searchbar.entry.js +83 -34
- package/dist/esm/ion-segment-content.entry.js +2 -3
- package/dist/esm/ion-segment-view.entry.js +6 -6
- package/dist/esm/ion-segment_2.entry.js +47 -27
- package/dist/esm/ion-select-modal.entry.js +13 -18
- package/dist/esm/ion-select_3.entry.js +79 -55
- package/dist/esm/ion-spinner.entry.js +8 -9
- package/dist/esm/ion-split-pane.entry.js +12 -7
- package/dist/esm/ion-tab-bar_2.entry.js +25 -26
- package/dist/esm/ion-tab_2.entry.js +8 -12
- package/dist/esm/ion-text.entry.js +4 -6
- package/dist/esm/ion-textarea.entry.js +69 -41
- package/dist/esm/ion-toast.entry.js +65 -42
- package/dist/esm/ion-toggle.entry.js +53 -29
- package/dist/esm/{ionic-global-ca86cf32.js → ionic-global-GkM1xiqt.js} +1 -1
- package/dist/esm/ionic.js +7 -6
- package/dist/esm/{ios.transition-7fe5dbea.js → ios.transition-BcTzvx5_.js} +7 -7
- package/dist/esm/{keyboard-73175e24.js → keyboard-CUw4ekVy.js} +1 -1
- package/dist/esm/{keyboard-controller-ec5c2bfa.js → keyboard-controller-BaaVITYt.js} +2 -2
- package/dist/esm/{keyboard-52278bd7.js → keyboard-ywgs5efA.js} +3 -3
- package/dist/esm/loader.js +5 -5
- package/dist/esm/{md.transition-8dc58b46.js → md.transition-DYGWIgPE.js} +7 -7
- package/dist/esm/{notch-controller-00d92e89.js → notch-controller-PoOhjO4o.js} +2 -2
- package/dist/esm/{overlays-41a5d51b.js → overlays-BuSzwtlC.js} +7 -7
- package/dist/esm/{status-tap-f6d08e9e.js → status-tap-BPk7Ddsi.js} +5 -5
- package/dist/esm/{swipe-back-07df2095.js → swipe-back-Df75PJ2J.js} +4 -4
- package/dist/html.html-data.json +212 -0
- package/dist/index.js +1 -1
- package/dist/ionic/index.esm.js +1 -1
- package/dist/ionic/ionic.esm.js +1 -1
- package/dist/ionic/p-06d06c2f.entry.js +4 -0
- package/dist/ionic/p-10e11b67.entry.js +4 -0
- package/dist/ionic/p-10f11601.entry.js +4 -0
- package/dist/ionic/p-171d5d3e.entry.js +4 -0
- package/dist/ionic/p-210385cd.entry.js +4 -0
- package/dist/ionic/p-2469206a.entry.js +4 -0
- package/dist/ionic/p-261e3a47.entry.js +4 -0
- package/dist/ionic/p-2a2ab89d.entry.js +4 -0
- package/dist/ionic/p-2f416d26.entry.js +4 -0
- package/dist/ionic/p-3628b1f7.entry.js +4 -0
- package/dist/ionic/p-3bd766ca.entry.js +4 -0
- package/dist/ionic/p-414f60f0.entry.js +4 -0
- package/dist/ionic/p-49419ffd.entry.js +4 -0
- package/dist/ionic/p-49b72347.entry.js +4 -0
- package/dist/ionic/p-52eca165.entry.js +4 -0
- package/dist/ionic/p-6a8928b1.entry.js +4 -0
- package/dist/ionic/p-6d4f1c6e.entry.js +4 -0
- package/dist/ionic/{p-e8245753.entry.js → p-6f5d9223.entry.js} +1 -1
- package/dist/ionic/p-72d7dd7c.entry.js +4 -0
- package/dist/ionic/p-75959e43.entry.js +4 -0
- package/dist/ionic/p-76878c5f.entry.js +4 -0
- package/dist/ionic/p-7deacfed.entry.js +4 -0
- package/dist/ionic/p-841761ee.entry.js +4 -0
- package/dist/ionic/p-85d22d84.entry.js +4 -0
- package/dist/ionic/{p-c005cc37.entry.js → p-879a7b00.entry.js} +1 -1
- package/dist/ionic/p-8ca2b22c.entry.js +4 -0
- package/dist/ionic/p-8e57bbf1.entry.js +4 -0
- package/dist/ionic/p-92aed080.entry.js +4 -0
- package/dist/ionic/p-930ec949.entry.js +4 -0
- package/dist/ionic/p-9ca05f27.entry.js +4 -0
- package/dist/ionic/p-9d7d6758.entry.js +4 -0
- package/dist/ionic/p-9d8be89a.entry.js +4 -0
- package/dist/ionic/p-9eeaBrnk.js +4 -0
- package/dist/ionic/p-B1sP_kPm.js +4 -0
- package/dist/ionic/{p-f53ee2e7.js → p-B3UoCFcu.js} +1 -1
- package/dist/ionic/p-B61pJgh5.js +4 -0
- package/dist/ionic/p-B8iLKNde.js +4 -0
- package/dist/ionic/p-BBmUb2In.js +4 -0
- package/dist/ionic/{p-da2b833b.js → p-BLV6ykCk.js} +1 -1
- package/dist/ionic/p-BTEIaRld.js +4 -0
- package/dist/ionic/p-BwAZiDRk.js +4 -0
- package/dist/ionic/{p-624ecf03.js → p-C3eOXAUO.js} +1 -1
- package/dist/ionic/p-C5UXyyFe.js +5 -0
- package/dist/ionic/p-CIGNaXM1.js +4 -0
- package/dist/ionic/{p-89b61afc.js → p-CKvCXMs9.js} +1 -1
- package/dist/ionic/{p-f7ce606e.js → p-CdKu7oC9.js} +1 -1
- package/dist/ionic/{p-22bc235f.js → p-CdWpy93z.js} +1 -1
- package/dist/ionic/{p-3f4327f7.js → p-CeCT60rb.js} +1 -1
- package/dist/ionic/p-CiN6q3Lh.js +4 -0
- package/dist/ionic/p-Cl0B-RWe.js +4 -0
- package/dist/ionic/p-CtWGkNnJ.js +4 -0
- package/dist/ionic/{p-27281edd.js → p-D13Eaw-8.js} +1 -1
- package/dist/ionic/p-DFllLYu2.js +4 -0
- package/dist/ionic/p-DYo1kLGy.js +4 -0
- package/dist/ionic/p-Di6ciXLG.js +4 -0
- package/dist/ionic/{p-597ff9af.js → p-XWSYNdC9.js} +1 -1
- package/dist/ionic/p-a1581941.entry.js +4 -0
- package/dist/ionic/p-a1767652.entry.js +4 -0
- package/dist/ionic/p-a3ec5708.entry.js +4 -0
- package/dist/ionic/p-a8506291.entry.js +4 -0
- package/dist/ionic/p-a951373a.entry.js +4 -0
- package/dist/ionic/p-b3485dee.entry.js +4 -0
- package/dist/ionic/{p-2567237c.entry.js → p-b8a159eb.entry.js} +1 -1
- package/dist/ionic/p-bb3cf0f1.entry.js +4 -0
- package/dist/ionic/p-c0634ff3.entry.js +4 -0
- package/dist/ionic/p-ccbc5737.entry.js +4 -0
- package/dist/ionic/{p-9b069739.entry.js → p-d3ee5846.entry.js} +1 -1
- package/dist/ionic/p-d6a3361a.entry.js +4 -0
- package/dist/ionic/p-d7a76cd0.entry.js +4 -0
- package/dist/ionic/p-d85dfc51.entry.js +4 -0
- package/dist/ionic/{p-b87a9f1d.entry.js → p-dcf2e017.entry.js} +1 -1
- package/dist/ionic/p-ddc1c497.entry.js +4 -0
- package/dist/ionic/p-e01503b2.entry.js +4 -0
- package/dist/ionic/p-f9c55d46.entry.js +4 -0
- package/dist/ionic/p-fc3eb210.entry.js +4 -0
- package/dist/ionic/{p-756e4559.js → p-lw61HGQ-.js} +1 -1
- package/dist/ionic/{p-b9fa7882.js → p-mxKP5hf-.js} +1 -1
- package/dist/ionic/p-umtghMQY.js +4 -0
- package/dist/ionic/p-yluxF5qo.js +4 -0
- package/dist/ionic/p-zEz12j4K.js +4 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/stencil-public-runtime.d.ts +9 -0
- package/hydrate/index.d.ts +40 -5
- package/hydrate/index.js +4540 -2180
- package/hydrate/index.mjs +4539 -2179
- package/loader/cdn.js +1 -2
- package/loader/index.cjs.js +1 -2
- package/loader/index.es2017.js +0 -1
- package/loader/index.js +1 -2
- package/package.json +2 -2
- package/dist/esm/polyfills/core-js.js +0 -11
- package/dist/esm/polyfills/dom.js +0 -79
- package/dist/esm/polyfills/es5-html-element.js +0 -1
- package/dist/esm/polyfills/index.js +0 -34
- package/dist/esm/polyfills/system.js +0 -6
- package/dist/esm-es5/animation-eab5a4ca.js +0 -4
- package/dist/esm-es5/app-globals-7b6cbf1a.js +0 -4
- package/dist/esm-es5/button-active-90f1dbc4.js +0 -4
- package/dist/esm-es5/capacitor-59395cbd.js +0 -4
- package/dist/esm-es5/compare-with-utils-a96ff2ea.js +0 -4
- package/dist/esm-es5/config-49c88215.js +0 -4
- package/dist/esm-es5/cubic-bezier-fe2083dc.js +0 -4
- package/dist/esm-es5/data-174ad5e0.js +0 -4
- package/dist/esm-es5/dir-babeabeb.js +0 -4
- package/dist/esm-es5/focus-visible-dd40d69f.js +0 -4
- package/dist/esm-es5/framework-delegate-2eea1763.js +0 -4
- package/dist/esm-es5/gesture-controller-314a54f6.js +0 -4
- package/dist/esm-es5/haptic-ac164e4c.js +0 -4
- package/dist/esm-es5/hardware-back-button-864101a3.js +0 -4
- package/dist/esm-es5/helpers-78efeec3.js +0 -4
- package/dist/esm-es5/index-39782642.js +0 -4
- package/dist/esm-es5/index-40894f4b.js +0 -4
- package/dist/esm-es5/index-527b9e34.js +0 -5
- package/dist/esm-es5/index-738d7504.js +0 -4
- package/dist/esm-es5/index-a5d50daf.js +0 -4
- package/dist/esm-es5/index-e2cf2ceb.js +0 -4
- package/dist/esm-es5/index-e919e353.js +0 -4
- package/dist/esm-es5/index-ecb55b8d.js +0 -4
- package/dist/esm-es5/index-f9f5d018.js +0 -4
- package/dist/esm-es5/index.js +0 -4
- package/dist/esm-es5/input-shims-7dc1f6dc.js +0 -4
- package/dist/esm-es5/input.utils-28bf4ef0.js +0 -4
- package/dist/esm-es5/ion-accordion_2.entry.js +0 -4
- package/dist/esm-es5/ion-action-sheet.entry.js +0 -4
- package/dist/esm-es5/ion-alert.entry.js +0 -4
- package/dist/esm-es5/ion-app_8.entry.js +0 -4
- package/dist/esm-es5/ion-avatar_3.entry.js +0 -4
- package/dist/esm-es5/ion-back-button.entry.js +0 -4
- package/dist/esm-es5/ion-backdrop.entry.js +0 -4
- package/dist/esm-es5/ion-breadcrumb_2.entry.js +0 -4
- package/dist/esm-es5/ion-button_2.entry.js +0 -4
- package/dist/esm-es5/ion-card_5.entry.js +0 -4
- package/dist/esm-es5/ion-checkbox.entry.js +0 -4
- package/dist/esm-es5/ion-chip.entry.js +0 -4
- package/dist/esm-es5/ion-col_3.entry.js +0 -4
- package/dist/esm-es5/ion-datetime-button.entry.js +0 -4
- package/dist/esm-es5/ion-datetime_3.entry.js +0 -4
- package/dist/esm-es5/ion-fab_3.entry.js +0 -4
- package/dist/esm-es5/ion-img.entry.js +0 -4
- package/dist/esm-es5/ion-infinite-scroll_2.entry.js +0 -4
- package/dist/esm-es5/ion-input-password-toggle.entry.js +0 -4
- package/dist/esm-es5/ion-input.entry.js +0 -4
- package/dist/esm-es5/ion-item-option_3.entry.js +0 -4
- package/dist/esm-es5/ion-item_8.entry.js +0 -4
- package/dist/esm-es5/ion-loading.entry.js +0 -4
- package/dist/esm-es5/ion-menu_3.entry.js +0 -4
- package/dist/esm-es5/ion-modal.entry.js +0 -4
- package/dist/esm-es5/ion-nav_2.entry.js +0 -4
- package/dist/esm-es5/ion-picker-column-option.entry.js +0 -4
- package/dist/esm-es5/ion-picker-column.entry.js +0 -4
- package/dist/esm-es5/ion-picker.entry.js +0 -4
- package/dist/esm-es5/ion-popover.entry.js +0 -4
- package/dist/esm-es5/ion-progress-bar.entry.js +0 -4
- package/dist/esm-es5/ion-radio_2.entry.js +0 -4
- package/dist/esm-es5/ion-range.entry.js +0 -4
- package/dist/esm-es5/ion-refresher_2.entry.js +0 -4
- package/dist/esm-es5/ion-reorder_2.entry.js +0 -4
- package/dist/esm-es5/ion-ripple-effect.entry.js +0 -4
- package/dist/esm-es5/ion-route_4.entry.js +0 -4
- package/dist/esm-es5/ion-searchbar.entry.js +0 -4
- package/dist/esm-es5/ion-segment-content.entry.js +0 -4
- package/dist/esm-es5/ion-segment-view.entry.js +0 -4
- package/dist/esm-es5/ion-segment_2.entry.js +0 -4
- package/dist/esm-es5/ion-select-modal.entry.js +0 -4
- package/dist/esm-es5/ion-select_3.entry.js +0 -4
- package/dist/esm-es5/ion-spinner.entry.js +0 -4
- package/dist/esm-es5/ion-split-pane.entry.js +0 -4
- package/dist/esm-es5/ion-tab-bar_2.entry.js +0 -4
- package/dist/esm-es5/ion-tab_2.entry.js +0 -4
- package/dist/esm-es5/ion-text.entry.js +0 -4
- package/dist/esm-es5/ion-textarea.entry.js +0 -4
- package/dist/esm-es5/ion-toast.entry.js +0 -4
- package/dist/esm-es5/ion-toggle.entry.js +0 -4
- package/dist/esm-es5/ionic-global-ca86cf32.js +0 -4
- package/dist/esm-es5/ionic.js +0 -4
- package/dist/esm-es5/ios.transition-7fe5dbea.js +0 -4
- package/dist/esm-es5/keyboard-52278bd7.js +0 -4
- package/dist/esm-es5/keyboard-73175e24.js +0 -4
- package/dist/esm-es5/keyboard-controller-ec5c2bfa.js +0 -4
- package/dist/esm-es5/loader.js +0 -4
- package/dist/esm-es5/lock-controller-316928be.js +0 -4
- package/dist/esm-es5/md.transition-8dc58b46.js +0 -4
- package/dist/esm-es5/notch-controller-00d92e89.js +0 -4
- package/dist/esm-es5/overlays-41a5d51b.js +0 -4
- package/dist/esm-es5/spinner-configs-964f7cf3.js +0 -4
- package/dist/esm-es5/status-tap-f6d08e9e.js +0 -4
- package/dist/esm-es5/swipe-back-07df2095.js +0 -4
- package/dist/esm-es5/theme-01f3f29c.js +0 -4
- package/dist/esm-es5/watch-options-c2911ace.js +0 -4
- package/dist/ionic/ionic.js +0 -127
- package/dist/ionic/p-012c3ceb.system.js +0 -4
- package/dist/ionic/p-027a48f1.entry.js +0 -4
- package/dist/ionic/p-058b7f35.js +0 -4
- package/dist/ionic/p-05b65d7a.entry.js +0 -4
- package/dist/ionic/p-08e01816.system.js +0 -4
- package/dist/ionic/p-09d185ff.system.js +0 -4
- package/dist/ionic/p-0a456b7f.entry.js +0 -4
- package/dist/ionic/p-0adb6909.system.entry.js +0 -4
- package/dist/ionic/p-0bedc891.system.entry.js +0 -4
- package/dist/ionic/p-0d1be7c9.system.entry.js +0 -4
- package/dist/ionic/p-0ec5b7cf.system.js +0 -4
- package/dist/ionic/p-14114a59.system.entry.js +0 -4
- package/dist/ionic/p-15bb1dde.system.js +0 -4
- package/dist/ionic/p-180b4f9a.entry.js +0 -4
- package/dist/ionic/p-19c32a76.entry.js +0 -4
- package/dist/ionic/p-1b0b2210.entry.js +0 -4
- package/dist/ionic/p-1bf5ec17.system.js +0 -4
- package/dist/ionic/p-1c1d781d.system.entry.js +0 -4
- package/dist/ionic/p-1c8b3ac9.entry.js +0 -4
- package/dist/ionic/p-1de5dfcd.system.entry.js +0 -4
- package/dist/ionic/p-1dfc11b3.system.js +0 -4
- package/dist/ionic/p-1e4371bd.js +0 -4
- package/dist/ionic/p-1e955a45.system.js +0 -4
- package/dist/ionic/p-20d469d0.system.js +0 -4
- package/dist/ionic/p-21891ead.js +0 -4
- package/dist/ionic/p-28c81576.entry.js +0 -4
- package/dist/ionic/p-29a5b4e4.entry.js +0 -4
- package/dist/ionic/p-29da3dcd.entry.js +0 -4
- package/dist/ionic/p-2a2c6bf4.system.entry.js +0 -4
- package/dist/ionic/p-2b7827c7.js +0 -4
- package/dist/ionic/p-33518a04.entry.js +0 -4
- package/dist/ionic/p-35f14792.entry.js +0 -4
- package/dist/ionic/p-383a6058.entry.js +0 -4
- package/dist/ionic/p-3855fef7.system.js +0 -4
- package/dist/ionic/p-38eaf9cf.system.entry.js +0 -4
- package/dist/ionic/p-3ba2a2cd.system.js +0 -4
- package/dist/ionic/p-3e1e14d9.system.js +0 -4
- package/dist/ionic/p-41e70fa2.entry.js +0 -4
- package/dist/ionic/p-44fde7d5.system.entry.js +0 -4
- package/dist/ionic/p-44ff75ea.js +0 -4
- package/dist/ionic/p-455cd7cc.system.js +0 -4
- package/dist/ionic/p-4609d030.system.js +0 -4
- package/dist/ionic/p-4630688e.system.entry.js +0 -4
- package/dist/ionic/p-4662a25c.system.entry.js +0 -4
- package/dist/ionic/p-48ded460.entry.js +0 -4
- package/dist/ionic/p-49d53551.system.entry.js +0 -4
- package/dist/ionic/p-4b07c60a.system.js +0 -4
- package/dist/ionic/p-4c7e6fec.system.entry.js +0 -4
- package/dist/ionic/p-4ea4c73a.system.entry.js +0 -4
- package/dist/ionic/p-4eeca839.system.entry.js +0 -4
- package/dist/ionic/p-4f255d5a.system.js +0 -4
- package/dist/ionic/p-50e0ce13.entry.js +0 -4
- package/dist/ionic/p-51479be0.system.entry.js +0 -4
- package/dist/ionic/p-5578033e.system.entry.js +0 -4
- package/dist/ionic/p-5fb1321f.entry.js +0 -4
- package/dist/ionic/p-607aa181.entry.js +0 -4
- package/dist/ionic/p-61373098.js +0 -4
- package/dist/ionic/p-6155027f.system.entry.js +0 -4
- package/dist/ionic/p-61e794fb.entry.js +0 -4
- package/dist/ionic/p-64d8ac48.js +0 -4
- package/dist/ionic/p-657ada6a.entry.js +0 -4
- package/dist/ionic/p-65943bec.system.entry.js +0 -4
- package/dist/ionic/p-65e732b9.entry.js +0 -4
- package/dist/ionic/p-66a5d6a8.js +0 -5
- package/dist/ionic/p-69a96be9.system.entry.js +0 -4
- package/dist/ionic/p-6c044a1d.system.js +0 -4
- package/dist/ionic/p-7058a5e4.system.entry.js +0 -4
- package/dist/ionic/p-705fda69.system.js +0 -4
- package/dist/ionic/p-707408c5.system.entry.js +0 -4
- package/dist/ionic/p-70abb1f2.system.entry.js +0 -4
- package/dist/ionic/p-747f9517.entry.js +0 -4
- package/dist/ionic/p-772d1657.system.js +0 -4
- package/dist/ionic/p-77aa5fef.system.entry.js +0 -4
- package/dist/ionic/p-792919fd.system.js +0 -4
- package/dist/ionic/p-7b886108.system.entry.js +0 -4
- package/dist/ionic/p-7c9daa6f.entry.js +0 -4
- package/dist/ionic/p-7cc33a9a.system.js +0 -4
- package/dist/ionic/p-7e3b5638.system.entry.js +0 -4
- package/dist/ionic/p-7f49a9c4.entry.js +0 -4
- package/dist/ionic/p-843ac05d.system.entry.js +0 -4
- package/dist/ionic/p-87b0d2c9.entry.js +0 -4
- package/dist/ionic/p-8985cdb6.system.js +0 -4
- package/dist/ionic/p-8b1c1fd7.entry.js +0 -4
- package/dist/ionic/p-8b22be32.system.entry.js +0 -4
- package/dist/ionic/p-8d98e2bb.entry.js +0 -4
- package/dist/ionic/p-8ededb41.js +0 -4
- package/dist/ionic/p-9146695e.system.js +0 -4
- package/dist/ionic/p-959cf042.system.entry.js +0 -4
- package/dist/ionic/p-96eec056.entry.js +0 -4
- package/dist/ionic/p-978bdf4c.system.js +0 -4
- package/dist/ionic/p-979d4f5c.system.js +0 -4
- package/dist/ionic/p-9870728f.js +0 -4
- package/dist/ionic/p-99803283.entry.js +0 -4
- package/dist/ionic/p-9af7f110.js +0 -4
- package/dist/ionic/p-9e45532a.system.js +0 -4
- package/dist/ionic/p-a26d7667.system.entry.js +0 -4
- package/dist/ionic/p-a3c931ad.system.js +0 -4
- package/dist/ionic/p-a4866e3e.system.js +0 -4
- package/dist/ionic/p-a520973b.entry.js +0 -4
- package/dist/ionic/p-a6625de8.system.js +0 -4
- package/dist/ionic/p-a75a9e5a.system.entry.js +0 -4
- package/dist/ionic/p-a768ae50.entry.js +0 -4
- package/dist/ionic/p-a7830ff8.entry.js +0 -4
- package/dist/ionic/p-a9198501.system.entry.js +0 -4
- package/dist/ionic/p-a93873de.system.js +0 -4
- package/dist/ionic/p-ab7337e1.entry.js +0 -4
- package/dist/ionic/p-abe101da.system.js +0 -4
- package/dist/ionic/p-ac09b6e9.system.entry.js +0 -4
- package/dist/ionic/p-ac58d726.system.entry.js +0 -4
- package/dist/ionic/p-b06ac4a5.system.js +0 -4
- package/dist/ionic/p-b1673667.entry.js +0 -4
- package/dist/ionic/p-b1f9fbe8.system.entry.js +0 -4
- package/dist/ionic/p-b2ee0628.system.entry.js +0 -4
- package/dist/ionic/p-b8a461f5.system.entry.js +0 -4
- package/dist/ionic/p-bf64af90.system.js +0 -4
- package/dist/ionic/p-c095b902.entry.js +0 -4
- package/dist/ionic/p-c27c57ea.system.entry.js +0 -4
- package/dist/ionic/p-c3f9d9fe.js +0 -4
- package/dist/ionic/p-c468af8a.system.js +0 -4
- package/dist/ionic/p-c53c414d.system.entry.js +0 -4
- package/dist/ionic/p-c61cc894.js +0 -4
- package/dist/ionic/p-c63d8dc1.js +0 -4
- package/dist/ionic/p-c7e16491.js +0 -4
- package/dist/ionic/p-ccb740ea.entry.js +0 -4
- package/dist/ionic/p-cec54707.system.entry.js +0 -4
- package/dist/ionic/p-cfc08422.entry.js +0 -4
- package/dist/ionic/p-cff4f96c.entry.js +0 -4
- package/dist/ionic/p-d40f2b7a.js +0 -4
- package/dist/ionic/p-d70a9e6d.system.js +0 -4
- package/dist/ionic/p-d823e7b6.system.entry.js +0 -4
- package/dist/ionic/p-d882f1e2.system.entry.js +0 -4
- package/dist/ionic/p-d8d84afa.system.js +0 -4
- package/dist/ionic/p-db3b409e.system.entry.js +0 -4
- package/dist/ionic/p-e11ff516.entry.js +0 -4
- package/dist/ionic/p-e29c5aab.system.entry.js +0 -4
- package/dist/ionic/p-e2ce5f8b.entry.js +0 -4
- package/dist/ionic/p-e3284879.system.entry.js +0 -4
- package/dist/ionic/p-e3e4eed7.entry.js +0 -4
- package/dist/ionic/p-e4683bfd.system.entry.js +0 -4
- package/dist/ionic/p-e4d2c281.entry.js +0 -4
- package/dist/ionic/p-e65b8460.entry.js +0 -4
- package/dist/ionic/p-e673a0a2.system.js +0 -4
- package/dist/ionic/p-e6cdfa96.system.entry.js +0 -4
- package/dist/ionic/p-ece78e7b.js +0 -4
- package/dist/ionic/p-ee86cfff.system.js +0 -4
- package/dist/ionic/p-f11a9436.system.js +0 -5
- package/dist/ionic/p-f201b53a.system.js +0 -4
- package/dist/ionic/p-f23124c4.system.js +0 -4
- package/dist/ionic/p-f233f1e0.system.js +0 -4
- package/dist/ionic/p-f387b3c6.system.entry.js +0 -4
- package/dist/ionic/p-f5a04e5e.system.entry.js +0 -4
- package/dist/ionic/p-f6bb9be7.system.entry.js +0 -4
- package/dist/ionic/p-f70fc14a.entry.js +0 -4
- package/dist/ionic/p-f834322a.entry.js +0 -4
- package/dist/ionic/p-f896194a.system.entry.js +0 -4
- package/dist/ionic/p-fa70eaab.entry.js +0 -4
- package/dist/ionic/p-ffa3ba3c.js +0 -4
- package/loader/package.json +0 -11
- /package/dist/cjs/{compare-with-utils-df1001d7.js → compare-with-utils-DSicavqM.js} +0 -0
- /package/dist/cjs/{config-4f60b98a.js → config-BHiHGeHc.js} +0 -0
- /package/dist/cjs/{cubic-bezier-f2dccc53.js → cubic-bezier-DAjy1V-e.js} +0 -0
- /package/dist/cjs/{dir-94c21456.js → dir-Cn0z1rJH.js} +0 -0
- /package/dist/cjs/{focus-visible-7a0ce04f.js → focus-visible-CCvKiLh3.js} +0 -0
- /package/dist/cjs/{index-c8d52405.js → index-DkNv4J_i.js} +0 -0
- /package/dist/cjs/{lock-controller-6585a42a.js → lock-controller-aDB9wrEf.js} +0 -0
- /package/dist/cjs/{spinner-configs-282fd50a.js → spinner-configs-DxHKnd3-.js} +0 -0
- /package/dist/cjs/{theme-d1c573d2.js → theme-CeDs6Hcv.js} +0 -0
- /package/dist/cjs/{watch-options-f5f3e158.js → watch-options-CviOsrTS.js} +0 -0
- /package/dist/esm/{compare-with-utils-a96ff2ea.js → compare-with-utils-sObYyvOy.js} +0 -0
- /package/dist/esm/{config-49c88215.js → config-O8NobGs3.js} +0 -0
- /package/dist/esm/{cubic-bezier-fe2083dc.js → cubic-bezier-hHmYLOfE.js} +0 -0
- /package/dist/esm/{dir-babeabeb.js → dir-C53feagD.js} +0 -0
- /package/dist/esm/{focus-visible-dd40d69f.js → focus-visible-BmVRXR1y.js} +0 -0
- /package/dist/esm/{index-a5d50daf.js → index-ZjP4CjeZ.js} +0 -0
- /package/dist/esm/{lock-controller-316928be.js → lock-controller-B-hirT0v.js} +0 -0
- /package/dist/esm/{spinner-configs-964f7cf3.js → spinner-configs-D4RIp70E.js} +0 -0
- /package/dist/esm/{theme-01f3f29c.js → theme-DiVJyqlX.js} +0 -0
- /package/dist/esm/{watch-options-c2911ace.js → watch-options-Dtdm8lKC.js} +0 -0
- /package/dist/ionic/{p-ccd02320.js → p-B-hirT0v.js} +0 -0
- /package/dist/ionic/{p-9b97df10.js → p-BTEOs1at.js} +0 -0
- /package/dist/ionic/{p-d47265c8.js → p-BmVRXR1y.js} +0 -0
- /package/dist/ionic/{p-fb813dab.js → p-C53feagD.js} +0 -0
- /package/dist/ionic/{p-f0c2a614.js → p-D4RIp70E.js} +0 -0
- /package/dist/ionic/{p-47794def.js → p-DiVJyqlX.js} +0 -0
- /package/dist/ionic/{p-459d13d5.js → p-Dtdm8lKC.js} +0 -0
- /package/dist/ionic/{p-41d5544e.js → p-O8NobGs3.js} +0 -0
- /package/dist/ionic/{p-7b30edcc.js → p-ZjP4CjeZ.js} +0 -0
- /package/dist/ionic/{p-2408c236.js → p-hHmYLOfE.js} +0 -0
- /package/dist/ionic/{p-de756e5c.js → p-sObYyvOy.js} +0 -0
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* (C) Ionic http://ionicframework.com - MIT License
|
|
3
3
|
*/
|
|
4
4
|
const NAMESPACE = 'ionic';
|
|
5
|
-
const BUILD = /* ionic */ {
|
|
5
|
+
const BUILD = /* ionic */ { experimentalSlotFixes: true, hydratedSelectorName: "hydrated", lazyLoad: true, shadowDom: true, slotRelocation: true, updatable: true};
|
|
6
6
|
|
|
7
7
|
/*
|
|
8
|
-
Stencil Client Platform v4.
|
|
8
|
+
Stencil Client Platform v4.29.2 | MIT Licensed | https://stenciljs.com
|
|
9
9
|
*/
|
|
10
10
|
var __defProp = Object.defineProperty;
|
|
11
11
|
var __export = (target, all) => {
|
|
@@ -13,14 +13,47 @@ var __export = (target, all) => {
|
|
|
13
13
|
__defProp(target, name, { get: all[name], enumerable: true });
|
|
14
14
|
};
|
|
15
15
|
var Build = {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
var
|
|
22
|
-
|
|
23
|
-
|
|
16
|
+
isBrowser: true};
|
|
17
|
+
|
|
18
|
+
// src/utils/constants.ts
|
|
19
|
+
var SVG_NS = "http://www.w3.org/2000/svg";
|
|
20
|
+
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
|
21
|
+
var PrimitiveType = /* @__PURE__ */ ((PrimitiveType2) => {
|
|
22
|
+
PrimitiveType2["Undefined"] = "undefined";
|
|
23
|
+
PrimitiveType2["Null"] = "null";
|
|
24
|
+
PrimitiveType2["String"] = "string";
|
|
25
|
+
PrimitiveType2["Number"] = "number";
|
|
26
|
+
PrimitiveType2["SpecialNumber"] = "number";
|
|
27
|
+
PrimitiveType2["Boolean"] = "boolean";
|
|
28
|
+
PrimitiveType2["BigInt"] = "bigint";
|
|
29
|
+
return PrimitiveType2;
|
|
30
|
+
})(PrimitiveType || {});
|
|
31
|
+
var NonPrimitiveType = /* @__PURE__ */ ((NonPrimitiveType2) => {
|
|
32
|
+
NonPrimitiveType2["Array"] = "array";
|
|
33
|
+
NonPrimitiveType2["Date"] = "date";
|
|
34
|
+
NonPrimitiveType2["Map"] = "map";
|
|
35
|
+
NonPrimitiveType2["Object"] = "object";
|
|
36
|
+
NonPrimitiveType2["RegularExpression"] = "regexp";
|
|
37
|
+
NonPrimitiveType2["Set"] = "set";
|
|
38
|
+
NonPrimitiveType2["Channel"] = "channel";
|
|
39
|
+
NonPrimitiveType2["Symbol"] = "symbol";
|
|
40
|
+
return NonPrimitiveType2;
|
|
41
|
+
})(NonPrimitiveType || {});
|
|
42
|
+
var TYPE_CONSTANT = "type";
|
|
43
|
+
var VALUE_CONSTANT = "value";
|
|
44
|
+
var SERIALIZED_PREFIX = "serialized:";
|
|
45
|
+
|
|
46
|
+
// src/client/client-host-ref.ts
|
|
47
|
+
var getHostRef = (ref) => {
|
|
48
|
+
if (ref.__stencil__getHostRef) {
|
|
49
|
+
return ref.__stencil__getHostRef();
|
|
50
|
+
}
|
|
51
|
+
return void 0;
|
|
52
|
+
};
|
|
53
|
+
var registerInstance = (lazyInstance, hostRef) => {
|
|
54
|
+
lazyInstance.__stencil__getHostRef = () => hostRef;
|
|
55
|
+
hostRef.$lazyInstance$ = lazyInstance;
|
|
56
|
+
};
|
|
24
57
|
var registerHost = (hostElement, cmpMeta) => {
|
|
25
58
|
const hostRef = {
|
|
26
59
|
$flags$: 0,
|
|
@@ -36,7 +69,9 @@ var registerHost = (hostElement, cmpMeta) => {
|
|
|
36
69
|
hostElement["s-p"] = [];
|
|
37
70
|
hostElement["s-rc"] = [];
|
|
38
71
|
}
|
|
39
|
-
|
|
72
|
+
const ref = hostRef;
|
|
73
|
+
hostElement.__stencil__getHostRef = () => ref;
|
|
74
|
+
return ref;
|
|
40
75
|
};
|
|
41
76
|
var isMemberInElement = (elm, memberName) => memberName in elm;
|
|
42
77
|
var consoleError = (e, el) => (0, console.error)(e, el);
|
|
@@ -60,12 +95,17 @@ var loadModule = (cmpMeta, hostRef, hmrVersionId) => {
|
|
|
60
95
|
/* webpackExclude: /\.system\.entry\.js$/ */
|
|
61
96
|
/* webpackMode: "lazy" */
|
|
62
97
|
`./${bundleId}.entry.js${""}`
|
|
63
|
-
).then(
|
|
64
|
-
{
|
|
65
|
-
|
|
98
|
+
).then(
|
|
99
|
+
(importedModule) => {
|
|
100
|
+
{
|
|
101
|
+
cmpModules.set(bundleId, importedModule);
|
|
102
|
+
}
|
|
103
|
+
return importedModule[exportName];
|
|
104
|
+
},
|
|
105
|
+
(e) => {
|
|
106
|
+
consoleError(e, hostRef.$hostElement$);
|
|
66
107
|
}
|
|
67
|
-
|
|
68
|
-
}, consoleError);
|
|
108
|
+
);
|
|
69
109
|
};
|
|
70
110
|
|
|
71
111
|
// src/client/client-style.ts
|
|
@@ -77,6 +117,7 @@ var CONTENT_REF_ID = "r";
|
|
|
77
117
|
var ORG_LOCATION_ID = "o";
|
|
78
118
|
var SLOT_NODE_ID = "s";
|
|
79
119
|
var TEXT_NODE_ID = "t";
|
|
120
|
+
var COMMENT_NODE_ID = "c";
|
|
80
121
|
var HYDRATE_ID = "s-id";
|
|
81
122
|
var HYDRATED_STYLE_ID = "sty-id";
|
|
82
123
|
var HYDRATE_CHILD_ID = "c-id";
|
|
@@ -84,7 +125,6 @@ var HYDRATED_CSS = "{visibility:hidden}.hydrated{visibility:inherit}";
|
|
|
84
125
|
var SLOT_FB_CSS = "slot-fb{display:contents}slot-fb[hidden]{display:none}";
|
|
85
126
|
var XLINK_NS = "http://www.w3.org/1999/xlink";
|
|
86
127
|
var win = typeof window !== "undefined" ? window : {};
|
|
87
|
-
var doc = win.document || { head: {} };
|
|
88
128
|
var H = win.HTMLElement || class {
|
|
89
129
|
};
|
|
90
130
|
var plt = {
|
|
@@ -98,9 +138,10 @@ var plt = {
|
|
|
98
138
|
};
|
|
99
139
|
var supportsShadow = BUILD.shadowDom;
|
|
100
140
|
var supportsListenerOptions = /* @__PURE__ */ (() => {
|
|
141
|
+
var _a;
|
|
101
142
|
let supportsListenerOptions2 = false;
|
|
102
143
|
try {
|
|
103
|
-
|
|
144
|
+
(_a = win.document) == null ? void 0 : _a.addEventListener(
|
|
104
145
|
"e",
|
|
105
146
|
null,
|
|
106
147
|
Object.defineProperty({}, "passive", {
|
|
@@ -165,24 +206,114 @@ var getAssetPath = (path) => {
|
|
|
165
206
|
return assetUrl.origin !== win.location.origin ? assetUrl.href : assetUrl.pathname;
|
|
166
207
|
};
|
|
167
208
|
|
|
168
|
-
// src/utils/constants.ts
|
|
169
|
-
var EMPTY_OBJ = {};
|
|
170
|
-
var SVG_NS = "http://www.w3.org/2000/svg";
|
|
171
|
-
var HTML_NS = "http://www.w3.org/1999/xhtml";
|
|
172
|
-
|
|
173
209
|
// src/utils/helpers.ts
|
|
174
|
-
var isDef = (v) => v != null;
|
|
210
|
+
var isDef = (v) => v != null && v !== void 0;
|
|
175
211
|
var isComplexType = (o) => {
|
|
176
212
|
o = typeof o;
|
|
177
213
|
return o === "object" || o === "function";
|
|
178
214
|
};
|
|
179
215
|
|
|
180
216
|
// src/utils/query-nonce-meta-tag-content.ts
|
|
181
|
-
function queryNonceMetaTagContent(
|
|
217
|
+
function queryNonceMetaTagContent(doc) {
|
|
182
218
|
var _a, _b, _c;
|
|
183
|
-
return (_c = (_b = (_a =
|
|
219
|
+
return (_c = (_b = (_a = doc.head) == null ? void 0 : _a.querySelector('meta[name="csp-nonce"]')) == null ? void 0 : _b.getAttribute("content")) != null ? _c : void 0;
|
|
184
220
|
}
|
|
185
221
|
|
|
222
|
+
// src/utils/remote-value.ts
|
|
223
|
+
var RemoteValue = class _RemoteValue {
|
|
224
|
+
/**
|
|
225
|
+
* Deserializes a LocalValue serialized object back to its original JavaScript representation
|
|
226
|
+
*
|
|
227
|
+
* @param serialized The serialized LocalValue object
|
|
228
|
+
* @returns The original JavaScript value/object
|
|
229
|
+
*/
|
|
230
|
+
static fromLocalValue(serialized) {
|
|
231
|
+
const type = serialized[TYPE_CONSTANT];
|
|
232
|
+
const value = VALUE_CONSTANT in serialized ? serialized[VALUE_CONSTANT] : void 0;
|
|
233
|
+
switch (type) {
|
|
234
|
+
case "string" /* String */:
|
|
235
|
+
return value;
|
|
236
|
+
case "boolean" /* Boolean */:
|
|
237
|
+
return value;
|
|
238
|
+
case "bigint" /* BigInt */:
|
|
239
|
+
return BigInt(value);
|
|
240
|
+
case "undefined" /* Undefined */:
|
|
241
|
+
return void 0;
|
|
242
|
+
case "null" /* Null */:
|
|
243
|
+
return null;
|
|
244
|
+
case "number" /* Number */:
|
|
245
|
+
if (value === "NaN") return NaN;
|
|
246
|
+
if (value === "-0") return -0;
|
|
247
|
+
if (value === "Infinity") return Infinity;
|
|
248
|
+
if (value === "-Infinity") return -Infinity;
|
|
249
|
+
return value;
|
|
250
|
+
case "array" /* Array */:
|
|
251
|
+
return value.map((item) => _RemoteValue.fromLocalValue(item));
|
|
252
|
+
case "date" /* Date */:
|
|
253
|
+
return new Date(value);
|
|
254
|
+
case "map" /* Map */:
|
|
255
|
+
const map2 = /* @__PURE__ */ new Map();
|
|
256
|
+
for (const [key, val] of value) {
|
|
257
|
+
const deserializedKey = typeof key === "object" && key !== null ? _RemoteValue.fromLocalValue(key) : key;
|
|
258
|
+
const deserializedValue = _RemoteValue.fromLocalValue(val);
|
|
259
|
+
map2.set(deserializedKey, deserializedValue);
|
|
260
|
+
}
|
|
261
|
+
return map2;
|
|
262
|
+
case "object" /* Object */:
|
|
263
|
+
const obj = {};
|
|
264
|
+
for (const [key, val] of value) {
|
|
265
|
+
obj[key] = _RemoteValue.fromLocalValue(val);
|
|
266
|
+
}
|
|
267
|
+
return obj;
|
|
268
|
+
case "regexp" /* RegularExpression */:
|
|
269
|
+
const { pattern, flags } = value;
|
|
270
|
+
return new RegExp(pattern, flags);
|
|
271
|
+
case "set" /* Set */:
|
|
272
|
+
const set = /* @__PURE__ */ new Set();
|
|
273
|
+
for (const item of value) {
|
|
274
|
+
set.add(_RemoteValue.fromLocalValue(item));
|
|
275
|
+
}
|
|
276
|
+
return set;
|
|
277
|
+
case "symbol" /* Symbol */:
|
|
278
|
+
return Symbol(value);
|
|
279
|
+
default:
|
|
280
|
+
throw new Error(`Unsupported type: ${type}`);
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
/**
|
|
284
|
+
* Utility method to deserialize multiple LocalValues at once
|
|
285
|
+
*
|
|
286
|
+
* @param serializedValues Array of serialized LocalValue objects
|
|
287
|
+
* @returns Array of deserialized JavaScript values
|
|
288
|
+
*/
|
|
289
|
+
static fromLocalValueArray(serializedValues) {
|
|
290
|
+
return serializedValues.map((value) => _RemoteValue.fromLocalValue(value));
|
|
291
|
+
}
|
|
292
|
+
/**
|
|
293
|
+
* Verifies if the given object matches the structure of a serialized LocalValue
|
|
294
|
+
*
|
|
295
|
+
* @param obj Object to verify
|
|
296
|
+
* @returns boolean indicating if the object has LocalValue structure
|
|
297
|
+
*/
|
|
298
|
+
static isLocalValueObject(obj) {
|
|
299
|
+
if (typeof obj !== "object" || obj === null) {
|
|
300
|
+
return false;
|
|
301
|
+
}
|
|
302
|
+
if (!obj.hasOwnProperty(TYPE_CONSTANT)) {
|
|
303
|
+
return false;
|
|
304
|
+
}
|
|
305
|
+
const type = obj[TYPE_CONSTANT];
|
|
306
|
+
const hasTypeProperty = Object.values({ ...PrimitiveType, ...NonPrimitiveType }).includes(type);
|
|
307
|
+
if (!hasTypeProperty) {
|
|
308
|
+
return false;
|
|
309
|
+
}
|
|
310
|
+
if (type !== "null" /* Null */ && type !== "undefined" /* Undefined */) {
|
|
311
|
+
return obj.hasOwnProperty(VALUE_CONSTANT);
|
|
312
|
+
}
|
|
313
|
+
return true;
|
|
314
|
+
}
|
|
315
|
+
};
|
|
316
|
+
|
|
186
317
|
// src/utils/result.ts
|
|
187
318
|
var result_exports = {};
|
|
188
319
|
__export(result_exports, {
|
|
@@ -231,6 +362,527 @@ var unwrapErr = (result) => {
|
|
|
231
362
|
throw result.value;
|
|
232
363
|
}
|
|
233
364
|
};
|
|
365
|
+
|
|
366
|
+
// src/utils/serialize.ts
|
|
367
|
+
function deserializeProperty(value) {
|
|
368
|
+
if (typeof value !== "string" || !value.startsWith(SERIALIZED_PREFIX)) {
|
|
369
|
+
return value;
|
|
370
|
+
}
|
|
371
|
+
return RemoteValue.fromLocalValue(JSON.parse(atob(value.slice(SERIALIZED_PREFIX.length))));
|
|
372
|
+
}
|
|
373
|
+
var updateFallbackSlotVisibility = (elm) => {
|
|
374
|
+
const childNodes = internalCall(elm, "childNodes");
|
|
375
|
+
if (elm.tagName && elm.tagName.includes("-") && elm["s-cr"] && elm.tagName !== "SLOT-FB") {
|
|
376
|
+
getHostSlotNodes(childNodes, elm.tagName).forEach((slotNode) => {
|
|
377
|
+
if (slotNode.nodeType === 1 /* ElementNode */ && slotNode.tagName === "SLOT-FB") {
|
|
378
|
+
if (getSlotChildSiblings(slotNode, getSlotName(slotNode), false).length) {
|
|
379
|
+
slotNode.hidden = true;
|
|
380
|
+
} else {
|
|
381
|
+
slotNode.hidden = false;
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
});
|
|
385
|
+
}
|
|
386
|
+
let i2 = 0;
|
|
387
|
+
for (i2 = 0; i2 < childNodes.length; i2++) {
|
|
388
|
+
const childNode = childNodes[i2];
|
|
389
|
+
if (childNode.nodeType === 1 /* ElementNode */ && internalCall(childNode, "childNodes").length) {
|
|
390
|
+
updateFallbackSlotVisibility(childNode);
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
};
|
|
394
|
+
var getSlottedChildNodes = (childNodes) => {
|
|
395
|
+
const result = [];
|
|
396
|
+
for (let i2 = 0; i2 < childNodes.length; i2++) {
|
|
397
|
+
const slottedNode = childNodes[i2]["s-nr"] || void 0;
|
|
398
|
+
if (slottedNode && slottedNode.isConnected) {
|
|
399
|
+
result.push(slottedNode);
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
return result;
|
|
403
|
+
};
|
|
404
|
+
function getHostSlotNodes(childNodes, hostName, slotName) {
|
|
405
|
+
let i2 = 0;
|
|
406
|
+
let slottedNodes = [];
|
|
407
|
+
let childNode;
|
|
408
|
+
for (; i2 < childNodes.length; i2++) {
|
|
409
|
+
childNode = childNodes[i2];
|
|
410
|
+
if (childNode["s-sr"] && (!hostName || childNode["s-hn"] === hostName) && (slotName === void 0 || getSlotName(childNode) === slotName)) {
|
|
411
|
+
slottedNodes.push(childNode);
|
|
412
|
+
if (typeof slotName !== "undefined") return slottedNodes;
|
|
413
|
+
}
|
|
414
|
+
slottedNodes = [...slottedNodes, ...getHostSlotNodes(childNode.childNodes, hostName, slotName)];
|
|
415
|
+
}
|
|
416
|
+
return slottedNodes;
|
|
417
|
+
}
|
|
418
|
+
var getSlotChildSiblings = (slot, slotName, includeSlot = true) => {
|
|
419
|
+
const childNodes = [];
|
|
420
|
+
if (includeSlot && slot["s-sr"] || !slot["s-sr"]) childNodes.push(slot);
|
|
421
|
+
let node = slot;
|
|
422
|
+
while (node = node.nextSibling) {
|
|
423
|
+
if (getSlotName(node) === slotName && (includeSlot || !node["s-sr"])) childNodes.push(node);
|
|
424
|
+
}
|
|
425
|
+
return childNodes;
|
|
426
|
+
};
|
|
427
|
+
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
428
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
429
|
+
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
430
|
+
return true;
|
|
431
|
+
}
|
|
432
|
+
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
433
|
+
return true;
|
|
434
|
+
}
|
|
435
|
+
return false;
|
|
436
|
+
}
|
|
437
|
+
if (nodeToRelocate["s-sn"] === slotName) {
|
|
438
|
+
return true;
|
|
439
|
+
}
|
|
440
|
+
return slotName === "";
|
|
441
|
+
};
|
|
442
|
+
var addSlotRelocateNode = (newChild, slotNode, prepend, position) => {
|
|
443
|
+
if (newChild["s-ol"] && newChild["s-ol"].isConnected) {
|
|
444
|
+
return;
|
|
445
|
+
}
|
|
446
|
+
const slottedNodeLocation = document.createTextNode("");
|
|
447
|
+
slottedNodeLocation["s-nr"] = newChild;
|
|
448
|
+
if (!slotNode["s-cr"] || !slotNode["s-cr"].parentNode) return;
|
|
449
|
+
const parent = slotNode["s-cr"].parentNode;
|
|
450
|
+
const appendMethod = prepend ? internalCall(parent, "prepend") : internalCall(parent, "appendChild");
|
|
451
|
+
if (typeof position !== "undefined") {
|
|
452
|
+
slottedNodeLocation["s-oo"] = position;
|
|
453
|
+
const childNodes = internalCall(parent, "childNodes");
|
|
454
|
+
const slotRelocateNodes = [slottedNodeLocation];
|
|
455
|
+
childNodes.forEach((n) => {
|
|
456
|
+
if (n["s-nr"]) slotRelocateNodes.push(n);
|
|
457
|
+
});
|
|
458
|
+
slotRelocateNodes.sort((a, b) => {
|
|
459
|
+
if (!a["s-oo"] || a["s-oo"] < (b["s-oo"] || 0)) return -1;
|
|
460
|
+
else if (!b["s-oo"] || b["s-oo"] < a["s-oo"]) return 1;
|
|
461
|
+
return 0;
|
|
462
|
+
});
|
|
463
|
+
slotRelocateNodes.forEach((n) => appendMethod.call(parent, n));
|
|
464
|
+
} else {
|
|
465
|
+
appendMethod.call(parent, slottedNodeLocation);
|
|
466
|
+
}
|
|
467
|
+
newChild["s-ol"] = slottedNodeLocation;
|
|
468
|
+
newChild["s-sh"] = slotNode["s-hn"];
|
|
469
|
+
};
|
|
470
|
+
var getSlotName = (node) => typeof node["s-sn"] === "string" ? node["s-sn"] : node.nodeType === 1 && node.getAttribute("slot") || void 0;
|
|
471
|
+
function patchSlotNode(node) {
|
|
472
|
+
if (node.assignedElements || node.assignedNodes || !node["s-sr"]) return;
|
|
473
|
+
const assignedFactory = (elementsOnly) => (function(opts) {
|
|
474
|
+
const toReturn = [];
|
|
475
|
+
const slotName = this["s-sn"];
|
|
476
|
+
if (opts == null ? void 0 : opts.flatten) {
|
|
477
|
+
console.error(`
|
|
478
|
+
Flattening is not supported for Stencil non-shadow slots.
|
|
479
|
+
You can use \`.childNodes\` to nested slot fallback content.
|
|
480
|
+
If you have a particular use case, please open an issue on the Stencil repo.
|
|
481
|
+
`);
|
|
482
|
+
}
|
|
483
|
+
const parent = this["s-cr"].parentElement;
|
|
484
|
+
const slottedNodes = parent.__childNodes ? parent.childNodes : getSlottedChildNodes(parent.childNodes);
|
|
485
|
+
slottedNodes.forEach((n) => {
|
|
486
|
+
if (slotName === getSlotName(n)) {
|
|
487
|
+
toReturn.push(n);
|
|
488
|
+
}
|
|
489
|
+
});
|
|
490
|
+
if (elementsOnly) {
|
|
491
|
+
return toReturn.filter((n) => n.nodeType === 1 /* ElementNode */);
|
|
492
|
+
}
|
|
493
|
+
return toReturn;
|
|
494
|
+
}).bind(node);
|
|
495
|
+
node.assignedElements = assignedFactory(true);
|
|
496
|
+
node.assignedNodes = assignedFactory(false);
|
|
497
|
+
}
|
|
498
|
+
function dispatchSlotChangeEvent(elm) {
|
|
499
|
+
elm.dispatchEvent(new CustomEvent("slotchange", { bubbles: false, cancelable: false, composed: false }));
|
|
500
|
+
}
|
|
501
|
+
function findSlotFromSlottedNode(slottedNode, parentHost) {
|
|
502
|
+
var _a;
|
|
503
|
+
parentHost = parentHost || ((_a = slottedNode["s-ol"]) == null ? void 0 : _a.parentElement);
|
|
504
|
+
if (!parentHost) return { slotNode: null, slotName: "" };
|
|
505
|
+
const slotName = slottedNode["s-sn"] = getSlotName(slottedNode) || "";
|
|
506
|
+
const childNodes = internalCall(parentHost, "childNodes");
|
|
507
|
+
const slotNode = getHostSlotNodes(childNodes, parentHost.tagName, slotName)[0];
|
|
508
|
+
return { slotNode, slotName };
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
// src/runtime/dom-extras.ts
|
|
512
|
+
var patchPseudoShadowDom = (hostElementPrototype) => {
|
|
513
|
+
patchCloneNode(hostElementPrototype);
|
|
514
|
+
patchSlotAppendChild(hostElementPrototype);
|
|
515
|
+
patchSlotAppend(hostElementPrototype);
|
|
516
|
+
patchSlotPrepend(hostElementPrototype);
|
|
517
|
+
patchSlotInsertAdjacentElement(hostElementPrototype);
|
|
518
|
+
patchSlotInsertAdjacentHTML(hostElementPrototype);
|
|
519
|
+
patchSlotInsertAdjacentText(hostElementPrototype);
|
|
520
|
+
patchInsertBefore(hostElementPrototype);
|
|
521
|
+
patchTextContent(hostElementPrototype);
|
|
522
|
+
patchChildSlotNodes(hostElementPrototype);
|
|
523
|
+
patchSlotRemoveChild(hostElementPrototype);
|
|
524
|
+
};
|
|
525
|
+
var patchCloneNode = (HostElementPrototype) => {
|
|
526
|
+
const orgCloneNode = HostElementPrototype.cloneNode;
|
|
527
|
+
HostElementPrototype.cloneNode = function(deep) {
|
|
528
|
+
const srcNode = this;
|
|
529
|
+
const isShadowDom = srcNode.shadowRoot && supportsShadow ;
|
|
530
|
+
const clonedNode = orgCloneNode.call(srcNode, isShadowDom ? deep : false);
|
|
531
|
+
if (!isShadowDom && deep) {
|
|
532
|
+
let i2 = 0;
|
|
533
|
+
let slotted, nonStencilNode;
|
|
534
|
+
const stencilPrivates = [
|
|
535
|
+
"s-id",
|
|
536
|
+
"s-cr",
|
|
537
|
+
"s-lr",
|
|
538
|
+
"s-rc",
|
|
539
|
+
"s-sc",
|
|
540
|
+
"s-p",
|
|
541
|
+
"s-cn",
|
|
542
|
+
"s-sr",
|
|
543
|
+
"s-sn",
|
|
544
|
+
"s-hn",
|
|
545
|
+
"s-ol",
|
|
546
|
+
"s-nr",
|
|
547
|
+
"s-si",
|
|
548
|
+
"s-rf",
|
|
549
|
+
"s-scs"
|
|
550
|
+
];
|
|
551
|
+
const childNodes = this.__childNodes || this.childNodes;
|
|
552
|
+
for (; i2 < childNodes.length; i2++) {
|
|
553
|
+
slotted = childNodes[i2]["s-nr"];
|
|
554
|
+
nonStencilNode = stencilPrivates.every((privateField) => !childNodes[i2][privateField]);
|
|
555
|
+
if (slotted) {
|
|
556
|
+
if (clonedNode.__appendChild) {
|
|
557
|
+
clonedNode.__appendChild(slotted.cloneNode(true));
|
|
558
|
+
} else {
|
|
559
|
+
clonedNode.appendChild(slotted.cloneNode(true));
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
if (nonStencilNode) {
|
|
563
|
+
clonedNode.appendChild(childNodes[i2].cloneNode(true));
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
}
|
|
567
|
+
return clonedNode;
|
|
568
|
+
};
|
|
569
|
+
};
|
|
570
|
+
var patchSlotAppendChild = (HostElementPrototype) => {
|
|
571
|
+
HostElementPrototype.__appendChild = HostElementPrototype.appendChild;
|
|
572
|
+
HostElementPrototype.appendChild = function(newChild) {
|
|
573
|
+
const { slotName, slotNode } = findSlotFromSlottedNode(newChild, this);
|
|
574
|
+
if (slotNode) {
|
|
575
|
+
addSlotRelocateNode(newChild, slotNode);
|
|
576
|
+
const slotChildNodes = getSlotChildSiblings(slotNode, slotName);
|
|
577
|
+
const appendAfter = slotChildNodes[slotChildNodes.length - 1];
|
|
578
|
+
const parent = internalCall(appendAfter, "parentNode");
|
|
579
|
+
const insertedNode = internalCall(parent, "insertBefore")(newChild, appendAfter.nextSibling);
|
|
580
|
+
dispatchSlotChangeEvent(slotNode);
|
|
581
|
+
updateFallbackSlotVisibility(this);
|
|
582
|
+
return insertedNode;
|
|
583
|
+
}
|
|
584
|
+
return this.__appendChild(newChild);
|
|
585
|
+
};
|
|
586
|
+
};
|
|
587
|
+
var patchSlotRemoveChild = (ElementPrototype) => {
|
|
588
|
+
ElementPrototype.__removeChild = ElementPrototype.removeChild;
|
|
589
|
+
ElementPrototype.removeChild = function(toRemove) {
|
|
590
|
+
if (toRemove && typeof toRemove["s-sn"] !== "undefined") {
|
|
591
|
+
const childNodes = this.__childNodes || this.childNodes;
|
|
592
|
+
const slotNode = getHostSlotNodes(childNodes, this.tagName, toRemove["s-sn"]);
|
|
593
|
+
if (slotNode && toRemove.isConnected) {
|
|
594
|
+
toRemove.remove();
|
|
595
|
+
updateFallbackSlotVisibility(this);
|
|
596
|
+
return;
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
return this.__removeChild(toRemove);
|
|
600
|
+
};
|
|
601
|
+
};
|
|
602
|
+
var patchSlotPrepend = (HostElementPrototype) => {
|
|
603
|
+
HostElementPrototype.__prepend = HostElementPrototype.prepend;
|
|
604
|
+
HostElementPrototype.prepend = function(...newChildren) {
|
|
605
|
+
newChildren.forEach((newChild) => {
|
|
606
|
+
if (typeof newChild === "string") {
|
|
607
|
+
newChild = this.ownerDocument.createTextNode(newChild);
|
|
608
|
+
}
|
|
609
|
+
const slotName = (newChild["s-sn"] = getSlotName(newChild)) || "";
|
|
610
|
+
const childNodes = internalCall(this, "childNodes");
|
|
611
|
+
const slotNode = getHostSlotNodes(childNodes, this.tagName, slotName)[0];
|
|
612
|
+
if (slotNode) {
|
|
613
|
+
addSlotRelocateNode(newChild, slotNode, true);
|
|
614
|
+
const slotChildNodes = getSlotChildSiblings(slotNode, slotName);
|
|
615
|
+
const appendAfter = slotChildNodes[0];
|
|
616
|
+
const parent = internalCall(appendAfter, "parentNode");
|
|
617
|
+
const toReturn = internalCall(parent, "insertBefore")(newChild, internalCall(appendAfter, "nextSibling"));
|
|
618
|
+
dispatchSlotChangeEvent(slotNode);
|
|
619
|
+
return toReturn;
|
|
620
|
+
}
|
|
621
|
+
if (newChild.nodeType === 1 && !!newChild.getAttribute("slot")) {
|
|
622
|
+
newChild.hidden = true;
|
|
623
|
+
}
|
|
624
|
+
return HostElementPrototype.__prepend(newChild);
|
|
625
|
+
});
|
|
626
|
+
};
|
|
627
|
+
};
|
|
628
|
+
var patchSlotAppend = (HostElementPrototype) => {
|
|
629
|
+
HostElementPrototype.__append = HostElementPrototype.append;
|
|
630
|
+
HostElementPrototype.append = function(...newChildren) {
|
|
631
|
+
newChildren.forEach((newChild) => {
|
|
632
|
+
if (typeof newChild === "string") {
|
|
633
|
+
newChild = this.ownerDocument.createTextNode(newChild);
|
|
634
|
+
}
|
|
635
|
+
this.appendChild(newChild);
|
|
636
|
+
});
|
|
637
|
+
};
|
|
638
|
+
};
|
|
639
|
+
var patchSlotInsertAdjacentHTML = (HostElementPrototype) => {
|
|
640
|
+
const originalInsertAdjacentHtml = HostElementPrototype.insertAdjacentHTML;
|
|
641
|
+
HostElementPrototype.insertAdjacentHTML = function(position, text) {
|
|
642
|
+
if (position !== "afterbegin" && position !== "beforeend") {
|
|
643
|
+
return originalInsertAdjacentHtml.call(this, position, text);
|
|
644
|
+
}
|
|
645
|
+
const container = this.ownerDocument.createElement("_");
|
|
646
|
+
let node;
|
|
647
|
+
container.innerHTML = text;
|
|
648
|
+
if (position === "afterbegin") {
|
|
649
|
+
while (node = container.firstChild) {
|
|
650
|
+
this.prepend(node);
|
|
651
|
+
}
|
|
652
|
+
} else if (position === "beforeend") {
|
|
653
|
+
while (node = container.firstChild) {
|
|
654
|
+
this.append(node);
|
|
655
|
+
}
|
|
656
|
+
}
|
|
657
|
+
};
|
|
658
|
+
};
|
|
659
|
+
var patchSlotInsertAdjacentText = (HostElementPrototype) => {
|
|
660
|
+
HostElementPrototype.insertAdjacentText = function(position, text) {
|
|
661
|
+
this.insertAdjacentHTML(position, text);
|
|
662
|
+
};
|
|
663
|
+
};
|
|
664
|
+
var patchInsertBefore = (HostElementPrototype) => {
|
|
665
|
+
const eleProto = HostElementPrototype;
|
|
666
|
+
if (eleProto.__insertBefore) return;
|
|
667
|
+
eleProto.__insertBefore = HostElementPrototype.insertBefore;
|
|
668
|
+
HostElementPrototype.insertBefore = function(newChild, currentChild) {
|
|
669
|
+
const { slotName, slotNode } = findSlotFromSlottedNode(newChild, this);
|
|
670
|
+
const slottedNodes = this.__childNodes ? this.childNodes : getSlottedChildNodes(this.childNodes);
|
|
671
|
+
if (slotNode) {
|
|
672
|
+
let found = false;
|
|
673
|
+
slottedNodes.forEach((childNode) => {
|
|
674
|
+
if (childNode === currentChild || currentChild === null) {
|
|
675
|
+
found = true;
|
|
676
|
+
if (currentChild === null || slotName !== currentChild["s-sn"]) {
|
|
677
|
+
this.appendChild(newChild);
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
680
|
+
if (slotName === currentChild["s-sn"]) {
|
|
681
|
+
addSlotRelocateNode(newChild, slotNode);
|
|
682
|
+
const parent = internalCall(currentChild, "parentNode");
|
|
683
|
+
internalCall(parent, "insertBefore")(newChild, currentChild);
|
|
684
|
+
dispatchSlotChangeEvent(slotNode);
|
|
685
|
+
}
|
|
686
|
+
return;
|
|
687
|
+
}
|
|
688
|
+
});
|
|
689
|
+
if (found) return newChild;
|
|
690
|
+
}
|
|
691
|
+
const parentNode = currentChild == null ? void 0 : currentChild.__parentNode;
|
|
692
|
+
if (parentNode && !this.isSameNode(parentNode)) {
|
|
693
|
+
return this.appendChild(newChild);
|
|
694
|
+
}
|
|
695
|
+
return this.__insertBefore(newChild, currentChild);
|
|
696
|
+
};
|
|
697
|
+
};
|
|
698
|
+
var patchSlotInsertAdjacentElement = (HostElementPrototype) => {
|
|
699
|
+
const originalInsertAdjacentElement = HostElementPrototype.insertAdjacentElement;
|
|
700
|
+
HostElementPrototype.insertAdjacentElement = function(position, element) {
|
|
701
|
+
if (position !== "afterbegin" && position !== "beforeend") {
|
|
702
|
+
return originalInsertAdjacentElement.call(this, position, element);
|
|
703
|
+
}
|
|
704
|
+
if (position === "afterbegin") {
|
|
705
|
+
this.prepend(element);
|
|
706
|
+
return element;
|
|
707
|
+
} else if (position === "beforeend") {
|
|
708
|
+
this.append(element);
|
|
709
|
+
return element;
|
|
710
|
+
}
|
|
711
|
+
return element;
|
|
712
|
+
};
|
|
713
|
+
};
|
|
714
|
+
var patchTextContent = (hostElementPrototype) => {
|
|
715
|
+
patchHostOriginalAccessor("textContent", hostElementPrototype);
|
|
716
|
+
Object.defineProperty(hostElementPrototype, "textContent", {
|
|
717
|
+
get: function() {
|
|
718
|
+
let text = "";
|
|
719
|
+
const childNodes = this.__childNodes ? this.childNodes : getSlottedChildNodes(this.childNodes);
|
|
720
|
+
childNodes.forEach((node) => text += node.textContent || "");
|
|
721
|
+
return text;
|
|
722
|
+
},
|
|
723
|
+
set: function(value) {
|
|
724
|
+
const childNodes = this.__childNodes ? this.childNodes : getSlottedChildNodes(this.childNodes);
|
|
725
|
+
childNodes.forEach((node) => {
|
|
726
|
+
if (node["s-ol"]) node["s-ol"].remove();
|
|
727
|
+
node.remove();
|
|
728
|
+
});
|
|
729
|
+
this.insertAdjacentHTML("beforeend", value);
|
|
730
|
+
}
|
|
731
|
+
});
|
|
732
|
+
};
|
|
733
|
+
var patchChildSlotNodes = (elm) => {
|
|
734
|
+
class FakeNodeList extends Array {
|
|
735
|
+
item(n) {
|
|
736
|
+
return this[n];
|
|
737
|
+
}
|
|
738
|
+
}
|
|
739
|
+
patchHostOriginalAccessor("children", elm);
|
|
740
|
+
Object.defineProperty(elm, "children", {
|
|
741
|
+
get() {
|
|
742
|
+
return this.childNodes.filter((n) => n.nodeType === 1);
|
|
743
|
+
}
|
|
744
|
+
});
|
|
745
|
+
Object.defineProperty(elm, "childElementCount", {
|
|
746
|
+
get() {
|
|
747
|
+
return this.children.length;
|
|
748
|
+
}
|
|
749
|
+
});
|
|
750
|
+
patchHostOriginalAccessor("firstChild", elm);
|
|
751
|
+
Object.defineProperty(elm, "firstChild", {
|
|
752
|
+
get() {
|
|
753
|
+
return this.childNodes[0];
|
|
754
|
+
}
|
|
755
|
+
});
|
|
756
|
+
patchHostOriginalAccessor("lastChild", elm);
|
|
757
|
+
Object.defineProperty(elm, "lastChild", {
|
|
758
|
+
get() {
|
|
759
|
+
return this.childNodes[this.childNodes.length - 1];
|
|
760
|
+
}
|
|
761
|
+
});
|
|
762
|
+
patchHostOriginalAccessor("childNodes", elm);
|
|
763
|
+
Object.defineProperty(elm, "childNodes", {
|
|
764
|
+
get() {
|
|
765
|
+
const result = new FakeNodeList();
|
|
766
|
+
result.push(...getSlottedChildNodes(this.__childNodes));
|
|
767
|
+
return result;
|
|
768
|
+
}
|
|
769
|
+
});
|
|
770
|
+
};
|
|
771
|
+
var patchSlottedNode = (node) => {
|
|
772
|
+
if (!node || node.__nextSibling !== void 0 || !globalThis.Node) return;
|
|
773
|
+
patchNextSibling(node);
|
|
774
|
+
patchPreviousSibling(node);
|
|
775
|
+
patchParentNode(node);
|
|
776
|
+
if (node.nodeType === Node.ELEMENT_NODE) {
|
|
777
|
+
patchNextElementSibling(node);
|
|
778
|
+
patchPreviousElementSibling(node);
|
|
779
|
+
}
|
|
780
|
+
};
|
|
781
|
+
var patchNextSibling = (node) => {
|
|
782
|
+
if (!node || node.__nextSibling) return;
|
|
783
|
+
patchHostOriginalAccessor("nextSibling", node);
|
|
784
|
+
Object.defineProperty(node, "nextSibling", {
|
|
785
|
+
get: function() {
|
|
786
|
+
var _a;
|
|
787
|
+
const parentNodes = (_a = this["s-ol"]) == null ? void 0 : _a.parentNode.childNodes;
|
|
788
|
+
const index = parentNodes == null ? void 0 : parentNodes.indexOf(this);
|
|
789
|
+
if (parentNodes && index > -1) {
|
|
790
|
+
return parentNodes[index + 1];
|
|
791
|
+
}
|
|
792
|
+
return this.__nextSibling;
|
|
793
|
+
}
|
|
794
|
+
});
|
|
795
|
+
};
|
|
796
|
+
var patchNextElementSibling = (element) => {
|
|
797
|
+
if (!element || element.__nextElementSibling) return;
|
|
798
|
+
patchHostOriginalAccessor("nextElementSibling", element);
|
|
799
|
+
Object.defineProperty(element, "nextElementSibling", {
|
|
800
|
+
get: function() {
|
|
801
|
+
var _a;
|
|
802
|
+
const parentEles = (_a = this["s-ol"]) == null ? void 0 : _a.parentNode.children;
|
|
803
|
+
const index = parentEles == null ? void 0 : parentEles.indexOf(this);
|
|
804
|
+
if (parentEles && index > -1) {
|
|
805
|
+
return parentEles[index + 1];
|
|
806
|
+
}
|
|
807
|
+
return this.__nextElementSibling;
|
|
808
|
+
}
|
|
809
|
+
});
|
|
810
|
+
};
|
|
811
|
+
var patchPreviousSibling = (node) => {
|
|
812
|
+
if (!node || node.__previousSibling) return;
|
|
813
|
+
patchHostOriginalAccessor("previousSibling", node);
|
|
814
|
+
Object.defineProperty(node, "previousSibling", {
|
|
815
|
+
get: function() {
|
|
816
|
+
var _a;
|
|
817
|
+
const parentNodes = (_a = this["s-ol"]) == null ? void 0 : _a.parentNode.childNodes;
|
|
818
|
+
const index = parentNodes == null ? void 0 : parentNodes.indexOf(this);
|
|
819
|
+
if (parentNodes && index > -1) {
|
|
820
|
+
return parentNodes[index - 1];
|
|
821
|
+
}
|
|
822
|
+
return this.__previousSibling;
|
|
823
|
+
}
|
|
824
|
+
});
|
|
825
|
+
};
|
|
826
|
+
var patchPreviousElementSibling = (element) => {
|
|
827
|
+
if (!element || element.__previousElementSibling) return;
|
|
828
|
+
patchHostOriginalAccessor("previousElementSibling", element);
|
|
829
|
+
Object.defineProperty(element, "previousElementSibling", {
|
|
830
|
+
get: function() {
|
|
831
|
+
var _a;
|
|
832
|
+
const parentNodes = (_a = this["s-ol"]) == null ? void 0 : _a.parentNode.children;
|
|
833
|
+
const index = parentNodes == null ? void 0 : parentNodes.indexOf(this);
|
|
834
|
+
if (parentNodes && index > -1) {
|
|
835
|
+
return parentNodes[index - 1];
|
|
836
|
+
}
|
|
837
|
+
return this.__previousElementSibling;
|
|
838
|
+
}
|
|
839
|
+
});
|
|
840
|
+
};
|
|
841
|
+
var patchParentNode = (node) => {
|
|
842
|
+
if (!node || node.__parentNode) return;
|
|
843
|
+
patchHostOriginalAccessor("parentNode", node);
|
|
844
|
+
Object.defineProperty(node, "parentNode", {
|
|
845
|
+
get: function() {
|
|
846
|
+
var _a;
|
|
847
|
+
return ((_a = this["s-ol"]) == null ? void 0 : _a.parentNode) || this.__parentNode;
|
|
848
|
+
},
|
|
849
|
+
set: function(value) {
|
|
850
|
+
this.__parentNode = value;
|
|
851
|
+
}
|
|
852
|
+
});
|
|
853
|
+
};
|
|
854
|
+
var validElementPatches = ["children", "nextElementSibling", "previousElementSibling"];
|
|
855
|
+
var validNodesPatches = [
|
|
856
|
+
"childNodes",
|
|
857
|
+
"firstChild",
|
|
858
|
+
"lastChild",
|
|
859
|
+
"nextSibling",
|
|
860
|
+
"previousSibling",
|
|
861
|
+
"textContent",
|
|
862
|
+
"parentNode"
|
|
863
|
+
];
|
|
864
|
+
function patchHostOriginalAccessor(accessorName, node) {
|
|
865
|
+
let accessor;
|
|
866
|
+
if (validElementPatches.includes(accessorName)) {
|
|
867
|
+
accessor = Object.getOwnPropertyDescriptor(Element.prototype, accessorName);
|
|
868
|
+
} else if (validNodesPatches.includes(accessorName)) {
|
|
869
|
+
accessor = Object.getOwnPropertyDescriptor(Node.prototype, accessorName);
|
|
870
|
+
}
|
|
871
|
+
if (!accessor) {
|
|
872
|
+
accessor = Object.getOwnPropertyDescriptor(node, accessorName);
|
|
873
|
+
}
|
|
874
|
+
if (accessor) Object.defineProperty(node, "__" + accessorName, accessor);
|
|
875
|
+
}
|
|
876
|
+
function internalCall(node, method) {
|
|
877
|
+
if ("__" + method in node) {
|
|
878
|
+
const toReturn = node["__" + method];
|
|
879
|
+
if (typeof toReturn !== "function") return toReturn;
|
|
880
|
+
return toReturn.bind(node);
|
|
881
|
+
} else {
|
|
882
|
+
if (typeof node[method] !== "function") return node[method];
|
|
883
|
+
return node[method].bind(node);
|
|
884
|
+
}
|
|
885
|
+
}
|
|
234
886
|
var createTime = (fnName, tagName = "") => {
|
|
235
887
|
{
|
|
236
888
|
return () => {
|
|
@@ -359,54 +1011,166 @@ var convertToPrivate = (node) => {
|
|
|
359
1011
|
|
|
360
1012
|
// src/runtime/client-hydrate.ts
|
|
361
1013
|
var initializeClientHydrate = (hostElm, tagName, hostId, hostRef) => {
|
|
1014
|
+
var _a;
|
|
362
1015
|
const endHydrate = createTime("hydrateClient", tagName);
|
|
363
1016
|
const shadowRoot = hostElm.shadowRoot;
|
|
364
1017
|
const childRenderNodes = [];
|
|
365
1018
|
const slotNodes = [];
|
|
1019
|
+
const slottedNodes = [];
|
|
366
1020
|
const shadowRootNodes = shadowRoot ? [] : null;
|
|
367
|
-
const vnode =
|
|
368
|
-
|
|
369
|
-
|
|
1021
|
+
const vnode = newVNode(tagName, null);
|
|
1022
|
+
vnode.$elm$ = hostElm;
|
|
1023
|
+
const members = Object.entries(((_a = hostRef.$cmpMeta$) == null ? void 0 : _a.$members$) || {});
|
|
1024
|
+
members.forEach(([memberName, [memberFlags, metaAttributeName]]) => {
|
|
1025
|
+
var _a2;
|
|
1026
|
+
if (!(memberFlags & 31 /* Prop */)) {
|
|
1027
|
+
return;
|
|
1028
|
+
}
|
|
1029
|
+
const attributeName = metaAttributeName || memberName;
|
|
1030
|
+
const attrVal = hostElm.getAttribute(attributeName);
|
|
1031
|
+
if (attrVal !== null) {
|
|
1032
|
+
const attrPropVal = parsePropertyValue(attrVal, memberFlags);
|
|
1033
|
+
(_a2 = hostRef == null ? void 0 : hostRef.$instanceValues$) == null ? void 0 : _a2.set(memberName, attrPropVal);
|
|
1034
|
+
}
|
|
1035
|
+
});
|
|
1036
|
+
let scopeId2;
|
|
1037
|
+
{
|
|
1038
|
+
const cmpMeta = hostRef.$cmpMeta$;
|
|
1039
|
+
if (cmpMeta && cmpMeta.$flags$ & 10 /* needsScopedEncapsulation */ && hostElm["s-sc"]) {
|
|
1040
|
+
scopeId2 = hostElm["s-sc"];
|
|
1041
|
+
hostElm.classList.add(scopeId2 + "-h");
|
|
1042
|
+
} else if (hostElm["s-sc"]) {
|
|
1043
|
+
delete hostElm["s-sc"];
|
|
1044
|
+
}
|
|
1045
|
+
}
|
|
1046
|
+
if (win.document && (!plt.$orgLocNodes$ || !plt.$orgLocNodes$.size)) {
|
|
1047
|
+
initializeDocumentHydrate(win.document.body, plt.$orgLocNodes$ = /* @__PURE__ */ new Map());
|
|
370
1048
|
}
|
|
371
1049
|
hostElm[HYDRATE_ID] = hostId;
|
|
372
1050
|
hostElm.removeAttribute(HYDRATE_ID);
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
1051
|
+
hostRef.$vnode$ = clientHydrate(
|
|
1052
|
+
vnode,
|
|
1053
|
+
childRenderNodes,
|
|
1054
|
+
slotNodes,
|
|
1055
|
+
shadowRootNodes,
|
|
1056
|
+
hostElm,
|
|
1057
|
+
hostElm,
|
|
1058
|
+
hostId,
|
|
1059
|
+
slottedNodes
|
|
1060
|
+
);
|
|
1061
|
+
let crIndex = 0;
|
|
1062
|
+
const crLength = childRenderNodes.length;
|
|
1063
|
+
let childRenderNode;
|
|
1064
|
+
for (crIndex; crIndex < crLength; crIndex++) {
|
|
1065
|
+
childRenderNode = childRenderNodes[crIndex];
|
|
1066
|
+
const orgLocationId = childRenderNode.$hostId$ + "." + childRenderNode.$nodeId$;
|
|
376
1067
|
const orgLocationNode = plt.$orgLocNodes$.get(orgLocationId);
|
|
377
|
-
const node =
|
|
378
|
-
if (orgLocationNode && supportsShadow && orgLocationNode["s-en"] === "") {
|
|
379
|
-
orgLocationNode.parentNode.insertBefore(node, orgLocationNode.nextSibling);
|
|
380
|
-
}
|
|
1068
|
+
const node = childRenderNode.$elm$;
|
|
381
1069
|
if (!shadowRoot) {
|
|
382
|
-
node["s-hn"] = tagName;
|
|
383
|
-
if (
|
|
384
|
-
node["s-
|
|
385
|
-
|
|
1070
|
+
node["s-hn"] = tagName.toUpperCase();
|
|
1071
|
+
if (childRenderNode.$tag$ === "slot") {
|
|
1072
|
+
node["s-cr"] = hostElm["s-cr"];
|
|
1073
|
+
}
|
|
1074
|
+
}
|
|
1075
|
+
if (childRenderNode.$tag$ === "slot") {
|
|
1076
|
+
childRenderNode.$name$ = childRenderNode.$elm$["s-sn"] || childRenderNode.$elm$["name"] || null;
|
|
1077
|
+
if (childRenderNode.$children$) {
|
|
1078
|
+
childRenderNode.$flags$ |= 2 /* isSlotFallback */;
|
|
1079
|
+
if (!childRenderNode.$elm$.childNodes.length) {
|
|
1080
|
+
childRenderNode.$children$.forEach((c) => {
|
|
1081
|
+
childRenderNode.$elm$.appendChild(c.$elm$);
|
|
1082
|
+
});
|
|
1083
|
+
}
|
|
1084
|
+
} else {
|
|
1085
|
+
childRenderNode.$flags$ |= 1 /* isSlotReference */;
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
if (orgLocationNode && orgLocationNode.isConnected) {
|
|
1089
|
+
if (shadowRoot && orgLocationNode["s-en"] === "") {
|
|
1090
|
+
orgLocationNode.parentNode.insertBefore(node, orgLocationNode.nextSibling);
|
|
1091
|
+
}
|
|
1092
|
+
orgLocationNode.parentNode.removeChild(orgLocationNode);
|
|
1093
|
+
if (!shadowRoot) {
|
|
1094
|
+
node["s-oo"] = parseInt(childRenderNode.$nodeId$);
|
|
386
1095
|
}
|
|
387
1096
|
}
|
|
388
1097
|
plt.$orgLocNodes$.delete(orgLocationId);
|
|
389
|
-
}
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
1098
|
+
}
|
|
1099
|
+
const hosts = [];
|
|
1100
|
+
const snLen = slottedNodes.length;
|
|
1101
|
+
let snIndex = 0;
|
|
1102
|
+
let slotGroup;
|
|
1103
|
+
let snGroupIdx;
|
|
1104
|
+
let snGroupLen;
|
|
1105
|
+
let slottedItem;
|
|
1106
|
+
for (snIndex; snIndex < snLen; snIndex++) {
|
|
1107
|
+
slotGroup = slottedNodes[snIndex];
|
|
1108
|
+
if (!slotGroup || !slotGroup.length) continue;
|
|
1109
|
+
snGroupLen = slotGroup.length;
|
|
1110
|
+
snGroupIdx = 0;
|
|
1111
|
+
for (snGroupIdx; snGroupIdx < snGroupLen; snGroupIdx++) {
|
|
1112
|
+
slottedItem = slotGroup[snGroupIdx];
|
|
1113
|
+
if (!hosts[slottedItem.hostId]) {
|
|
1114
|
+
hosts[slottedItem.hostId] = plt.$orgLocNodes$.get(slottedItem.hostId);
|
|
1115
|
+
}
|
|
1116
|
+
if (!hosts[slottedItem.hostId]) continue;
|
|
1117
|
+
const hostEle = hosts[slottedItem.hostId];
|
|
1118
|
+
if (!hostEle.shadowRoot || !shadowRoot) {
|
|
1119
|
+
slottedItem.slot["s-cr"] = hostEle["s-cr"];
|
|
1120
|
+
if (!slottedItem.slot["s-cr"] && hostEle.shadowRoot) {
|
|
1121
|
+
slottedItem.slot["s-cr"] = hostEle;
|
|
1122
|
+
} else {
|
|
1123
|
+
slottedItem.slot["s-cr"] = (hostEle.__childNodes || hostEle.childNodes)[0];
|
|
1124
|
+
}
|
|
1125
|
+
addSlotRelocateNode(slottedItem.node, slottedItem.slot, false, slottedItem.node["s-oo"]);
|
|
1126
|
+
{
|
|
1127
|
+
patchSlottedNode(slottedItem.node);
|
|
1128
|
+
}
|
|
394
1129
|
}
|
|
1130
|
+
if (hostEle.shadowRoot && slottedItem.node.parentElement !== hostEle) {
|
|
1131
|
+
hostEle.appendChild(slottedItem.node);
|
|
1132
|
+
}
|
|
1133
|
+
}
|
|
1134
|
+
}
|
|
1135
|
+
if (scopeId2 && slotNodes.length) {
|
|
1136
|
+
slotNodes.forEach((slot) => {
|
|
1137
|
+
slot.$elm$.parentElement.classList.add(scopeId2 + "-s");
|
|
395
1138
|
});
|
|
396
1139
|
}
|
|
1140
|
+
if (shadowRoot && !shadowRoot.childNodes.length) {
|
|
1141
|
+
let rnIdex = 0;
|
|
1142
|
+
const rnLen = shadowRootNodes.length;
|
|
1143
|
+
if (rnLen) {
|
|
1144
|
+
for (rnIdex; rnIdex < rnLen; rnIdex++) {
|
|
1145
|
+
shadowRoot.appendChild(shadowRootNodes[rnIdex]);
|
|
1146
|
+
}
|
|
1147
|
+
Array.from(hostElm.childNodes).forEach((node) => {
|
|
1148
|
+
if (typeof node["s-sn"] !== "string") {
|
|
1149
|
+
if (node.nodeType === 1 /* ElementNode */ && node.slot && node.hidden) {
|
|
1150
|
+
node.removeAttribute("hidden");
|
|
1151
|
+
} else if (node.nodeType === 8 /* CommentNode */ || node.nodeType === 3 /* TextNode */ && !node.wholeText.trim()) {
|
|
1152
|
+
node.parentNode.removeChild(node);
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
});
|
|
1156
|
+
}
|
|
1157
|
+
}
|
|
1158
|
+
plt.$orgLocNodes$.delete(hostElm["s-id"]);
|
|
1159
|
+
hostRef.$hostElement$ = hostElm;
|
|
397
1160
|
endHydrate();
|
|
398
1161
|
};
|
|
399
|
-
var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes, hostElm, node, hostId) => {
|
|
1162
|
+
var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes, hostElm, node, hostId, slottedNodes = []) => {
|
|
400
1163
|
let childNodeType;
|
|
401
1164
|
let childIdSplt;
|
|
402
1165
|
let childVNode;
|
|
403
1166
|
let i2;
|
|
1167
|
+
const scopeId2 = hostElm["s-sc"];
|
|
404
1168
|
if (node.nodeType === 1 /* ElementNode */) {
|
|
405
1169
|
childNodeType = node.getAttribute(HYDRATE_CHILD_ID);
|
|
406
1170
|
if (childNodeType) {
|
|
407
1171
|
childIdSplt = childNodeType.split(".");
|
|
408
1172
|
if (childIdSplt[0] === hostId || childIdSplt[0] === "0") {
|
|
409
|
-
childVNode = {
|
|
1173
|
+
childVNode = createSimpleVNode({
|
|
410
1174
|
$flags$: 0,
|
|
411
1175
|
$hostId$: childIdSplt[0],
|
|
412
1176
|
$nodeId$: childIdSplt[1],
|
|
@@ -414,18 +1178,43 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
414
1178
|
$index$: childIdSplt[3],
|
|
415
1179
|
$tag$: node.tagName.toLowerCase(),
|
|
416
1180
|
$elm$: node,
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
$
|
|
420
|
-
|
|
421
|
-
$text$: null
|
|
422
|
-
};
|
|
1181
|
+
// If we don't add the initial classes to the VNode, the first `vdom-render.ts` patch
|
|
1182
|
+
// won't try to reconcile them. Classes set on the node will be blown away.
|
|
1183
|
+
$attrs$: { class: node.className || "" }
|
|
1184
|
+
});
|
|
423
1185
|
childRenderNodes.push(childVNode);
|
|
424
1186
|
node.removeAttribute(HYDRATE_CHILD_ID);
|
|
425
1187
|
if (!parentVNode.$children$) {
|
|
426
1188
|
parentVNode.$children$ = [];
|
|
427
1189
|
}
|
|
428
|
-
|
|
1190
|
+
if (scopeId2) {
|
|
1191
|
+
node["s-si"] = scopeId2;
|
|
1192
|
+
childVNode.$attrs$.class += " " + scopeId2;
|
|
1193
|
+
}
|
|
1194
|
+
const slotName = childVNode.$elm$.getAttribute("s-sn");
|
|
1195
|
+
if (typeof slotName === "string") {
|
|
1196
|
+
if (childVNode.$tag$ === "slot-fb") {
|
|
1197
|
+
addSlot(
|
|
1198
|
+
slotName,
|
|
1199
|
+
childIdSplt[2],
|
|
1200
|
+
childVNode,
|
|
1201
|
+
node,
|
|
1202
|
+
parentVNode,
|
|
1203
|
+
childRenderNodes,
|
|
1204
|
+
slotNodes,
|
|
1205
|
+
shadowRootNodes,
|
|
1206
|
+
slottedNodes
|
|
1207
|
+
);
|
|
1208
|
+
if (scopeId2) {
|
|
1209
|
+
node.classList.add(scopeId2);
|
|
1210
|
+
}
|
|
1211
|
+
}
|
|
1212
|
+
childVNode.$elm$["s-sn"] = slotName;
|
|
1213
|
+
childVNode.$elm$.removeAttribute("s-sn");
|
|
1214
|
+
}
|
|
1215
|
+
if (childVNode.$index$ !== void 0) {
|
|
1216
|
+
parentVNode.$children$[childVNode.$index$] = childVNode;
|
|
1217
|
+
}
|
|
429
1218
|
parentVNode = childVNode;
|
|
430
1219
|
if (shadowRootNodes && childVNode.$depth$ === "0") {
|
|
431
1220
|
shadowRootNodes[childVNode.$index$] = childVNode.$elm$;
|
|
@@ -441,31 +1230,33 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
441
1230
|
shadowRootNodes,
|
|
442
1231
|
hostElm,
|
|
443
1232
|
node.shadowRoot.childNodes[i2],
|
|
444
|
-
hostId
|
|
1233
|
+
hostId,
|
|
1234
|
+
slottedNodes
|
|
445
1235
|
);
|
|
446
1236
|
}
|
|
447
1237
|
}
|
|
448
|
-
|
|
1238
|
+
const nonShadowNodes = node.__childNodes || node.childNodes;
|
|
1239
|
+
for (i2 = nonShadowNodes.length - 1; i2 >= 0; i2--) {
|
|
449
1240
|
clientHydrate(
|
|
450
1241
|
parentVNode,
|
|
451
1242
|
childRenderNodes,
|
|
452
1243
|
slotNodes,
|
|
453
1244
|
shadowRootNodes,
|
|
454
1245
|
hostElm,
|
|
455
|
-
|
|
456
|
-
hostId
|
|
1246
|
+
nonShadowNodes[i2],
|
|
1247
|
+
hostId,
|
|
1248
|
+
slottedNodes
|
|
457
1249
|
);
|
|
458
1250
|
}
|
|
459
1251
|
} else if (node.nodeType === 8 /* CommentNode */) {
|
|
460
1252
|
childIdSplt = node.nodeValue.split(".");
|
|
461
1253
|
if (childIdSplt[1] === hostId || childIdSplt[1] === "0") {
|
|
462
1254
|
childNodeType = childIdSplt[0];
|
|
463
|
-
childVNode = {
|
|
464
|
-
$flags$: 0,
|
|
1255
|
+
childVNode = createSimpleVNode({
|
|
465
1256
|
$hostId$: childIdSplt[1],
|
|
466
1257
|
$nodeId$: childIdSplt[2],
|
|
467
1258
|
$depth$: childIdSplt[3],
|
|
468
|
-
$index$: childIdSplt[4],
|
|
1259
|
+
$index$: childIdSplt[4] || "0",
|
|
469
1260
|
$elm$: node,
|
|
470
1261
|
$attrs$: null,
|
|
471
1262
|
$children$: null,
|
|
@@ -473,46 +1264,43 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
473
1264
|
$name$: null,
|
|
474
1265
|
$tag$: null,
|
|
475
1266
|
$text$: null
|
|
476
|
-
};
|
|
1267
|
+
});
|
|
477
1268
|
if (childNodeType === TEXT_NODE_ID) {
|
|
478
|
-
childVNode.$elm$ = node
|
|
1269
|
+
childVNode.$elm$ = findCorrespondingNode(node, 3 /* TextNode */);
|
|
479
1270
|
if (childVNode.$elm$ && childVNode.$elm$.nodeType === 3 /* TextNode */) {
|
|
480
1271
|
childVNode.$text$ = childVNode.$elm$.textContent;
|
|
481
1272
|
childRenderNodes.push(childVNode);
|
|
482
1273
|
node.remove();
|
|
483
|
-
if (
|
|
484
|
-
parentVNode.$children$
|
|
1274
|
+
if (hostId === childVNode.$hostId$) {
|
|
1275
|
+
if (!parentVNode.$children$) {
|
|
1276
|
+
parentVNode.$children$ = [];
|
|
1277
|
+
}
|
|
1278
|
+
parentVNode.$children$[childVNode.$index$] = childVNode;
|
|
485
1279
|
}
|
|
486
|
-
parentVNode.$children$[childVNode.$index$] = childVNode;
|
|
487
1280
|
if (shadowRootNodes && childVNode.$depth$ === "0") {
|
|
488
1281
|
shadowRootNodes[childVNode.$index$] = childVNode.$elm$;
|
|
489
1282
|
}
|
|
490
1283
|
}
|
|
1284
|
+
} else if (childNodeType === COMMENT_NODE_ID) {
|
|
1285
|
+
childVNode.$elm$ = findCorrespondingNode(node, 8 /* CommentNode */);
|
|
1286
|
+
if (childVNode.$elm$ && childVNode.$elm$.nodeType === 8 /* CommentNode */) {
|
|
1287
|
+
childRenderNodes.push(childVNode);
|
|
1288
|
+
node.remove();
|
|
1289
|
+
}
|
|
491
1290
|
} else if (childVNode.$hostId$ === hostId) {
|
|
492
1291
|
if (childNodeType === SLOT_NODE_ID) {
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
node.parentNode.insertBefore(childVNode.$elm$, node);
|
|
506
|
-
node.remove();
|
|
507
|
-
if (childVNode.$depth$ === "0") {
|
|
508
|
-
shadowRootNodes[childVNode.$index$] = childVNode.$elm$;
|
|
509
|
-
}
|
|
510
|
-
}
|
|
511
|
-
slotNodes.push(childVNode);
|
|
512
|
-
if (!parentVNode.$children$) {
|
|
513
|
-
parentVNode.$children$ = [];
|
|
514
|
-
}
|
|
515
|
-
parentVNode.$children$[childVNode.$index$] = childVNode;
|
|
1292
|
+
const slotName = node["s-sn"] = childIdSplt[5] || "";
|
|
1293
|
+
addSlot(
|
|
1294
|
+
slotName,
|
|
1295
|
+
childIdSplt[2],
|
|
1296
|
+
childVNode,
|
|
1297
|
+
node,
|
|
1298
|
+
parentVNode,
|
|
1299
|
+
childRenderNodes,
|
|
1300
|
+
slotNodes,
|
|
1301
|
+
shadowRootNodes,
|
|
1302
|
+
slottedNodes
|
|
1303
|
+
);
|
|
516
1304
|
} else if (childNodeType === CONTENT_REF_ID) {
|
|
517
1305
|
if (shadowRootNodes) {
|
|
518
1306
|
node.remove();
|
|
@@ -528,18 +1316,28 @@ var clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes,
|
|
|
528
1316
|
vnode.$elm$ = node;
|
|
529
1317
|
vnode.$index$ = "0";
|
|
530
1318
|
parentVNode.$children$ = [vnode];
|
|
1319
|
+
} else {
|
|
1320
|
+
if (node.nodeType === 3 /* TextNode */ && !node.wholeText.trim()) {
|
|
1321
|
+
node.remove();
|
|
1322
|
+
}
|
|
531
1323
|
}
|
|
1324
|
+
return parentVNode;
|
|
532
1325
|
};
|
|
533
1326
|
var initializeDocumentHydrate = (node, orgLocNodes) => {
|
|
534
1327
|
if (node.nodeType === 1 /* ElementNode */) {
|
|
1328
|
+
const componentId = node[HYDRATE_ID] || node.getAttribute(HYDRATE_ID);
|
|
1329
|
+
if (componentId) {
|
|
1330
|
+
orgLocNodes.set(componentId, node);
|
|
1331
|
+
}
|
|
535
1332
|
let i2 = 0;
|
|
536
1333
|
if (node.shadowRoot) {
|
|
537
1334
|
for (; i2 < node.shadowRoot.childNodes.length; i2++) {
|
|
538
1335
|
initializeDocumentHydrate(node.shadowRoot.childNodes[i2], orgLocNodes);
|
|
539
1336
|
}
|
|
540
1337
|
}
|
|
541
|
-
|
|
542
|
-
|
|
1338
|
+
const nonShadowNodes = node.__childNodes || node.childNodes;
|
|
1339
|
+
for (i2 = 0; i2 < nonShadowNodes.length; i2++) {
|
|
1340
|
+
initializeDocumentHydrate(nonShadowNodes[i2], orgLocNodes);
|
|
543
1341
|
}
|
|
544
1342
|
} else if (node.nodeType === 8 /* CommentNode */) {
|
|
545
1343
|
const childIdSplt = node.nodeValue.split(".");
|
|
@@ -550,18 +1348,98 @@ var initializeDocumentHydrate = (node, orgLocNodes) => {
|
|
|
550
1348
|
}
|
|
551
1349
|
}
|
|
552
1350
|
};
|
|
1351
|
+
var createSimpleVNode = (vnode) => {
|
|
1352
|
+
const defaultVNode = {
|
|
1353
|
+
$flags$: 0,
|
|
1354
|
+
$hostId$: null,
|
|
1355
|
+
$nodeId$: null,
|
|
1356
|
+
$depth$: null,
|
|
1357
|
+
$index$: "0",
|
|
1358
|
+
$elm$: null,
|
|
1359
|
+
$attrs$: null,
|
|
1360
|
+
$children$: null,
|
|
1361
|
+
$key$: null,
|
|
1362
|
+
$name$: null,
|
|
1363
|
+
$tag$: null,
|
|
1364
|
+
$text$: null
|
|
1365
|
+
};
|
|
1366
|
+
return { ...defaultVNode, ...vnode };
|
|
1367
|
+
};
|
|
1368
|
+
function addSlot(slotName, slotId, childVNode, node, parentVNode, childRenderNodes, slotNodes, shadowRootNodes, slottedNodes) {
|
|
1369
|
+
node["s-sr"] = true;
|
|
1370
|
+
childVNode.$name$ = slotName || null;
|
|
1371
|
+
childVNode.$tag$ = "slot";
|
|
1372
|
+
const parentNodeId = (parentVNode == null ? void 0 : parentVNode.$elm$) ? parentVNode.$elm$["s-id"] || parentVNode.$elm$.getAttribute("s-id") : "";
|
|
1373
|
+
if (shadowRootNodes && win.document) {
|
|
1374
|
+
const slot = childVNode.$elm$ = win.document.createElement(childVNode.$tag$);
|
|
1375
|
+
if (childVNode.$name$) {
|
|
1376
|
+
childVNode.$elm$.setAttribute("name", slotName);
|
|
1377
|
+
}
|
|
1378
|
+
if (parentNodeId && parentNodeId !== childVNode.$hostId$) {
|
|
1379
|
+
parentVNode.$elm$.insertBefore(slot, parentVNode.$elm$.children[0]);
|
|
1380
|
+
} else {
|
|
1381
|
+
node.parentNode.insertBefore(childVNode.$elm$, node);
|
|
1382
|
+
}
|
|
1383
|
+
addSlottedNodes(slottedNodes, slotId, slotName, node, childVNode.$hostId$);
|
|
1384
|
+
node.remove();
|
|
1385
|
+
if (childVNode.$depth$ === "0") {
|
|
1386
|
+
shadowRootNodes[childVNode.$index$] = childVNode.$elm$;
|
|
1387
|
+
}
|
|
1388
|
+
} else {
|
|
1389
|
+
const slot = childVNode.$elm$;
|
|
1390
|
+
const shouldMove = parentNodeId && parentNodeId !== childVNode.$hostId$ && parentVNode.$elm$.shadowRoot;
|
|
1391
|
+
addSlottedNodes(slottedNodes, slotId, slotName, node, shouldMove ? parentNodeId : childVNode.$hostId$);
|
|
1392
|
+
patchSlotNode(node);
|
|
1393
|
+
if (shouldMove) {
|
|
1394
|
+
parentVNode.$elm$.insertBefore(slot, parentVNode.$elm$.children[0]);
|
|
1395
|
+
}
|
|
1396
|
+
childRenderNodes.push(childVNode);
|
|
1397
|
+
}
|
|
1398
|
+
slotNodes.push(childVNode);
|
|
1399
|
+
if (!parentVNode.$children$) {
|
|
1400
|
+
parentVNode.$children$ = [];
|
|
1401
|
+
}
|
|
1402
|
+
parentVNode.$children$[childVNode.$index$] = childVNode;
|
|
1403
|
+
}
|
|
1404
|
+
var addSlottedNodes = (slottedNodes, slotNodeId, slotName, slotNode, hostId) => {
|
|
1405
|
+
let slottedNode = slotNode.nextSibling;
|
|
1406
|
+
slottedNodes[slotNodeId] = slottedNodes[slotNodeId] || [];
|
|
1407
|
+
while (slottedNode && ((slottedNode["getAttribute"] && slottedNode.getAttribute("slot") || slottedNode["s-sn"]) === slotName || slotName === "" && !slottedNode["s-sn"] && (slottedNode.nodeType === 8 /* CommentNode */ && slottedNode.nodeValue.indexOf(".") !== 1 || slottedNode.nodeType === 3 /* TextNode */))) {
|
|
1408
|
+
slottedNode["s-sn"] = slotName;
|
|
1409
|
+
slottedNodes[slotNodeId].push({ slot: slotNode, node: slottedNode, hostId });
|
|
1410
|
+
slottedNode = slottedNode.nextSibling;
|
|
1411
|
+
}
|
|
1412
|
+
};
|
|
1413
|
+
var findCorrespondingNode = (node, type) => {
|
|
1414
|
+
let sibling = node;
|
|
1415
|
+
do {
|
|
1416
|
+
sibling = sibling.nextSibling;
|
|
1417
|
+
} while (sibling && (sibling.nodeType !== type || !sibling.nodeValue));
|
|
1418
|
+
return sibling;
|
|
1419
|
+
};
|
|
553
1420
|
|
|
554
1421
|
// src/runtime/mode.ts
|
|
555
1422
|
var computeMode = (elm) => modeResolutionChain.map((h2) => h2(elm)).find((m) => !!m);
|
|
556
1423
|
var setMode = (handler) => modeResolutionChain.push(handler);
|
|
557
1424
|
var getMode = (ref) => getHostRef(ref).$modeName$;
|
|
558
1425
|
var parsePropertyValue = (propValue, propType) => {
|
|
1426
|
+
if (typeof propValue === "string" && (propValue.startsWith("{") && propValue.endsWith("}") || propValue.startsWith("[") && propValue.endsWith("]"))) {
|
|
1427
|
+
try {
|
|
1428
|
+
propValue = JSON.parse(propValue);
|
|
1429
|
+
return propValue;
|
|
1430
|
+
} catch (e) {
|
|
1431
|
+
}
|
|
1432
|
+
}
|
|
1433
|
+
if (typeof propValue === "string" && propValue.startsWith(SERIALIZED_PREFIX)) {
|
|
1434
|
+
propValue = deserializeProperty(propValue);
|
|
1435
|
+
return propValue;
|
|
1436
|
+
}
|
|
559
1437
|
if (propValue != null && !isComplexType(propValue)) {
|
|
560
1438
|
if (propType & 4 /* Boolean */) {
|
|
561
1439
|
return propValue === "false" ? false : propValue === "" || !!propValue;
|
|
562
1440
|
}
|
|
563
1441
|
if (propType & 2 /* Number */) {
|
|
564
|
-
return parseFloat(propValue);
|
|
1442
|
+
return typeof propValue === "string" ? parseFloat(propValue) : typeof propValue === "number" ? propValue : NaN;
|
|
565
1443
|
}
|
|
566
1444
|
if (propType & 1 /* String */) {
|
|
567
1445
|
return String(propValue);
|
|
@@ -610,7 +1488,10 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
610
1488
|
var _a;
|
|
611
1489
|
const scopeId2 = getScopeId(cmpMeta, mode);
|
|
612
1490
|
const style = styles.get(scopeId2);
|
|
613
|
-
|
|
1491
|
+
if (!win.document) {
|
|
1492
|
+
return scopeId2;
|
|
1493
|
+
}
|
|
1494
|
+
styleContainerNode = styleContainerNode.nodeType === 11 /* DocumentFragment */ ? styleContainerNode : win.document;
|
|
614
1495
|
if (style) {
|
|
615
1496
|
if (typeof style === "string") {
|
|
616
1497
|
styleContainerNode = styleContainerNode.head || styleContainerNode;
|
|
@@ -623,23 +1504,39 @@ var addStyle = (styleContainerNode, cmpMeta, mode) => {
|
|
|
623
1504
|
if (styleContainerNode.host && (styleElm = styleContainerNode.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`))) {
|
|
624
1505
|
styleElm.innerHTML = style;
|
|
625
1506
|
} else {
|
|
626
|
-
styleElm =
|
|
1507
|
+
styleElm = document.querySelector(`[${HYDRATED_STYLE_ID}="${scopeId2}"]`) || win.document.createElement("style");
|
|
627
1508
|
styleElm.innerHTML = style;
|
|
628
|
-
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(
|
|
1509
|
+
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(win.document);
|
|
629
1510
|
if (nonce != null) {
|
|
630
1511
|
styleElm.setAttribute("nonce", nonce);
|
|
631
1512
|
}
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
1513
|
+
if (!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */)) {
|
|
1514
|
+
if (styleContainerNode.nodeName === "HEAD") {
|
|
1515
|
+
const preconnectLinks = styleContainerNode.querySelectorAll("link[rel=preconnect]");
|
|
1516
|
+
const referenceNode2 = preconnectLinks.length > 0 ? preconnectLinks[preconnectLinks.length - 1].nextSibling : styleContainerNode.querySelector("style");
|
|
1517
|
+
styleContainerNode.insertBefore(
|
|
1518
|
+
styleElm,
|
|
1519
|
+
(referenceNode2 == null ? void 0 : referenceNode2.parentNode) === styleContainerNode ? referenceNode2 : null
|
|
1520
|
+
);
|
|
1521
|
+
} else if ("host" in styleContainerNode) {
|
|
1522
|
+
if (supportsConstructableStylesheets) {
|
|
1523
|
+
const stylesheet = new CSSStyleSheet();
|
|
1524
|
+
stylesheet.replaceSync(style);
|
|
1525
|
+
styleContainerNode.adoptedStyleSheets = [stylesheet, ...styleContainerNode.adoptedStyleSheets];
|
|
1526
|
+
} else {
|
|
1527
|
+
const existingStyleContainer = styleContainerNode.querySelector("style");
|
|
1528
|
+
if (existingStyleContainer) {
|
|
1529
|
+
existingStyleContainer.innerHTML = style + existingStyleContainer.innerHTML;
|
|
1530
|
+
} else {
|
|
1531
|
+
styleContainerNode.prepend(styleElm);
|
|
1532
|
+
}
|
|
1533
|
+
}
|
|
1534
|
+
} else {
|
|
1535
|
+
styleContainerNode.append(styleElm);
|
|
1536
|
+
}
|
|
1537
|
+
}
|
|
1538
|
+
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
1539
|
+
styleContainerNode.insertBefore(styleElm, null);
|
|
643
1540
|
}
|
|
644
1541
|
}
|
|
645
1542
|
if (cmpMeta.$flags$ & 4 /* hasSlotRelocation */) {
|
|
@@ -665,131 +1562,177 @@ var attachStyles = (hostRef) => {
|
|
|
665
1562
|
cmpMeta,
|
|
666
1563
|
hostRef.$modeName$
|
|
667
1564
|
);
|
|
668
|
-
if (flags & 10 /* needsScopedEncapsulation */
|
|
1565
|
+
if (flags & 10 /* needsScopedEncapsulation */) {
|
|
669
1566
|
elm["s-sc"] = scopeId2;
|
|
670
1567
|
elm.classList.add(scopeId2 + "-h");
|
|
671
|
-
if (flags & 2 /* scopedCssEncapsulation */) {
|
|
672
|
-
elm.classList.add(scopeId2 + "-s");
|
|
673
|
-
}
|
|
674
1568
|
}
|
|
675
1569
|
endAttachStyles();
|
|
676
1570
|
};
|
|
677
1571
|
var getScopeId = (cmp, mode) => "sc-" + (mode && cmp.$flags$ & 32 /* hasMode */ ? cmp.$tagName$ + "-" + mode : cmp.$tagName$);
|
|
678
|
-
var
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
1572
|
+
var convertScopedToShadow = (css) => css.replace(/\/\*!@([^\/]+)\*\/[^\{]+\{/g, "$1{");
|
|
1573
|
+
var hydrateScopedToShadow = () => {
|
|
1574
|
+
if (!win.document) {
|
|
1575
|
+
return;
|
|
1576
|
+
}
|
|
1577
|
+
const styles2 = win.document.querySelectorAll(`[${HYDRATED_STYLE_ID}]`);
|
|
1578
|
+
let i2 = 0;
|
|
1579
|
+
for (; i2 < styles2.length; i2++) {
|
|
1580
|
+
registerStyle(styles2[i2].getAttribute(HYDRATED_STYLE_ID), convertScopedToShadow(styles2[i2].innerHTML), true);
|
|
1581
|
+
}
|
|
1582
|
+
};
|
|
1583
|
+
var setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags, initialRender) => {
|
|
1584
|
+
if (oldValue === newValue) {
|
|
1585
|
+
return;
|
|
1586
|
+
}
|
|
1587
|
+
let isProp = isMemberInElement(elm, memberName);
|
|
1588
|
+
let ln = memberName.toLowerCase();
|
|
1589
|
+
if (memberName === "class") {
|
|
1590
|
+
const classList = elm.classList;
|
|
1591
|
+
const oldClasses = parseClassList(oldValue);
|
|
1592
|
+
let newClasses = parseClassList(newValue);
|
|
1593
|
+
if (elm["s-si"] && initialRender) {
|
|
1594
|
+
newClasses.push(elm["s-si"]);
|
|
1595
|
+
oldClasses.forEach((c) => {
|
|
1596
|
+
if (c.startsWith(elm["s-si"])) newClasses.push(c);
|
|
1597
|
+
});
|
|
1598
|
+
newClasses = [...new Set(newClasses)];
|
|
1599
|
+
classList.add(...newClasses);
|
|
1600
|
+
} else {
|
|
686
1601
|
classList.remove(...oldClasses.filter((c) => c && !newClasses.includes(c)));
|
|
687
1602
|
classList.add(...newClasses.filter((c) => c && !oldClasses.includes(c)));
|
|
688
|
-
}
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
elm.style.removeProperty(prop);
|
|
694
|
-
} else {
|
|
695
|
-
elm.style[prop] = "";
|
|
696
|
-
}
|
|
697
|
-
}
|
|
698
|
-
}
|
|
699
|
-
}
|
|
700
|
-
for (const prop in newValue) {
|
|
701
|
-
if (!oldValue || newValue[prop] !== oldValue[prop]) {
|
|
1603
|
+
}
|
|
1604
|
+
} else if (memberName === "style") {
|
|
1605
|
+
{
|
|
1606
|
+
for (const prop in oldValue) {
|
|
1607
|
+
if (!newValue || newValue[prop] == null) {
|
|
702
1608
|
if (prop.includes("-")) {
|
|
703
|
-
elm.style.
|
|
1609
|
+
elm.style.removeProperty(prop);
|
|
704
1610
|
} else {
|
|
705
|
-
elm.style[prop] =
|
|
1611
|
+
elm.style[prop] = "";
|
|
706
1612
|
}
|
|
707
1613
|
}
|
|
708
1614
|
}
|
|
709
|
-
}
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
} else if (isMemberInElement(win, ln)) {
|
|
717
|
-
memberName = ln.slice(2);
|
|
718
|
-
} else {
|
|
719
|
-
memberName = ln[2] + memberName.slice(3);
|
|
720
|
-
}
|
|
721
|
-
if (oldValue || newValue) {
|
|
722
|
-
const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);
|
|
723
|
-
memberName = memberName.replace(CAPTURE_EVENT_REGEX, "");
|
|
724
|
-
if (oldValue) {
|
|
725
|
-
plt.rel(elm, memberName, oldValue, capture);
|
|
726
|
-
}
|
|
727
|
-
if (newValue) {
|
|
728
|
-
plt.ael(elm, memberName, newValue, capture);
|
|
1615
|
+
}
|
|
1616
|
+
for (const prop in newValue) {
|
|
1617
|
+
if (!oldValue || newValue[prop] !== oldValue[prop]) {
|
|
1618
|
+
if (prop.includes("-")) {
|
|
1619
|
+
elm.style.setProperty(prop, newValue[prop]);
|
|
1620
|
+
} else {
|
|
1621
|
+
elm.style[prop] = newValue[prop];
|
|
729
1622
|
}
|
|
730
1623
|
}
|
|
1624
|
+
}
|
|
1625
|
+
} else if (memberName === "key") ; else if (memberName === "ref") {
|
|
1626
|
+
if (newValue) {
|
|
1627
|
+
newValue(elm);
|
|
1628
|
+
}
|
|
1629
|
+
} else if ((!isProp ) && memberName[0] === "o" && memberName[1] === "n") {
|
|
1630
|
+
if (memberName[2] === "-") {
|
|
1631
|
+
memberName = memberName.slice(3);
|
|
1632
|
+
} else if (isMemberInElement(win, ln)) {
|
|
1633
|
+
memberName = ln.slice(2);
|
|
731
1634
|
} else {
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
1635
|
+
memberName = ln[2] + memberName.slice(3);
|
|
1636
|
+
}
|
|
1637
|
+
if (oldValue || newValue) {
|
|
1638
|
+
const capture = memberName.endsWith(CAPTURE_EVENT_SUFFIX);
|
|
1639
|
+
memberName = memberName.replace(CAPTURE_EVENT_REGEX, "");
|
|
1640
|
+
if (oldValue) {
|
|
1641
|
+
plt.rel(elm, memberName, oldValue, capture);
|
|
1642
|
+
}
|
|
1643
|
+
if (newValue) {
|
|
1644
|
+
plt.ael(elm, memberName, newValue, capture);
|
|
1645
|
+
}
|
|
1646
|
+
}
|
|
1647
|
+
} else {
|
|
1648
|
+
const isComplex = isComplexType(newValue);
|
|
1649
|
+
if ((isProp || isComplex && newValue !== null) && !isSvg) {
|
|
1650
|
+
try {
|
|
1651
|
+
if (!elm.tagName.includes("-")) {
|
|
1652
|
+
const n = newValue == null ? "" : newValue;
|
|
1653
|
+
if (memberName === "list") {
|
|
1654
|
+
isProp = false;
|
|
1655
|
+
} else if (oldValue == null || elm[memberName] != n) {
|
|
1656
|
+
if (typeof elm.__lookupSetter__(memberName) === "function") {
|
|
740
1657
|
elm[memberName] = n;
|
|
1658
|
+
} else {
|
|
1659
|
+
elm.setAttribute(memberName, n);
|
|
741
1660
|
}
|
|
742
|
-
} else {
|
|
743
|
-
elm[memberName] = newValue;
|
|
744
1661
|
}
|
|
745
|
-
}
|
|
1662
|
+
} else if (elm[memberName] !== newValue) {
|
|
1663
|
+
elm[memberName] = newValue;
|
|
746
1664
|
}
|
|
1665
|
+
} catch (e) {
|
|
747
1666
|
}
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
1667
|
+
}
|
|
1668
|
+
let xlink = false;
|
|
1669
|
+
{
|
|
1670
|
+
if (ln !== (ln = ln.replace(/^xlink\:?/, ""))) {
|
|
1671
|
+
memberName = ln;
|
|
1672
|
+
xlink = true;
|
|
754
1673
|
}
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
elm.removeAttributeNS(XLINK_NS, memberName);
|
|
759
|
-
} else {
|
|
760
|
-
elm.removeAttribute(memberName);
|
|
761
|
-
}
|
|
762
|
-
}
|
|
763
|
-
} else if ((!isProp || flags & 4 /* isHost */ || isSvg) && !isComplex) {
|
|
764
|
-
newValue = newValue === true ? "" : newValue;
|
|
1674
|
+
}
|
|
1675
|
+
if (newValue == null || newValue === false) {
|
|
1676
|
+
if (newValue !== false || elm.getAttribute(memberName) === "") {
|
|
765
1677
|
if (xlink) {
|
|
766
|
-
elm.
|
|
1678
|
+
elm.removeAttributeNS(XLINK_NS, memberName);
|
|
767
1679
|
} else {
|
|
768
|
-
elm.
|
|
1680
|
+
elm.removeAttribute(memberName);
|
|
769
1681
|
}
|
|
770
1682
|
}
|
|
1683
|
+
} else if ((!isProp || flags & 4 /* isHost */ || isSvg) && !isComplex && elm.nodeType === 1 /* ElementNode */) {
|
|
1684
|
+
newValue = newValue === true ? "" : newValue;
|
|
1685
|
+
if (xlink) {
|
|
1686
|
+
elm.setAttributeNS(XLINK_NS, memberName, newValue);
|
|
1687
|
+
} else {
|
|
1688
|
+
elm.setAttribute(memberName, newValue);
|
|
1689
|
+
}
|
|
771
1690
|
}
|
|
772
1691
|
}
|
|
773
1692
|
};
|
|
774
1693
|
var parseClassListRegex = /\s/;
|
|
775
|
-
var parseClassList = (value) =>
|
|
1694
|
+
var parseClassList = (value) => {
|
|
1695
|
+
if (typeof value === "object" && value && "baseVal" in value) {
|
|
1696
|
+
value = value.baseVal;
|
|
1697
|
+
}
|
|
1698
|
+
if (!value || typeof value !== "string") {
|
|
1699
|
+
return [];
|
|
1700
|
+
}
|
|
1701
|
+
return value.split(parseClassListRegex);
|
|
1702
|
+
};
|
|
776
1703
|
var CAPTURE_EVENT_SUFFIX = "Capture";
|
|
777
1704
|
var CAPTURE_EVENT_REGEX = new RegExp(CAPTURE_EVENT_SUFFIX + "$");
|
|
778
1705
|
|
|
779
1706
|
// src/runtime/vdom/update-element.ts
|
|
780
|
-
var updateElement = (oldVnode, newVnode, isSvgMode2) => {
|
|
1707
|
+
var updateElement = (oldVnode, newVnode, isSvgMode2, isInitialRender) => {
|
|
781
1708
|
const elm = newVnode.$elm$.nodeType === 11 /* DocumentFragment */ && newVnode.$elm$.host ? newVnode.$elm$.host : newVnode.$elm$;
|
|
782
|
-
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ ||
|
|
783
|
-
const newVnodeAttrs = newVnode.$attrs$ ||
|
|
1709
|
+
const oldVnodeAttrs = oldVnode && oldVnode.$attrs$ || {};
|
|
1710
|
+
const newVnodeAttrs = newVnode.$attrs$ || {};
|
|
784
1711
|
{
|
|
785
1712
|
for (const memberName of sortedAttrNames(Object.keys(oldVnodeAttrs))) {
|
|
786
1713
|
if (!(memberName in newVnodeAttrs)) {
|
|
787
|
-
setAccessor(
|
|
1714
|
+
setAccessor(
|
|
1715
|
+
elm,
|
|
1716
|
+
memberName,
|
|
1717
|
+
oldVnodeAttrs[memberName],
|
|
1718
|
+
void 0,
|
|
1719
|
+
isSvgMode2,
|
|
1720
|
+
newVnode.$flags$,
|
|
1721
|
+
isInitialRender
|
|
1722
|
+
);
|
|
788
1723
|
}
|
|
789
1724
|
}
|
|
790
1725
|
}
|
|
791
1726
|
for (const memberName of sortedAttrNames(Object.keys(newVnodeAttrs))) {
|
|
792
|
-
setAccessor(
|
|
1727
|
+
setAccessor(
|
|
1728
|
+
elm,
|
|
1729
|
+
memberName,
|
|
1730
|
+
oldVnodeAttrs[memberName],
|
|
1731
|
+
newVnodeAttrs[memberName],
|
|
1732
|
+
isSvgMode2,
|
|
1733
|
+
newVnode.$flags$,
|
|
1734
|
+
isInitialRender
|
|
1735
|
+
);
|
|
793
1736
|
}
|
|
794
1737
|
};
|
|
795
1738
|
function sortedAttrNames(attrNames) {
|
|
@@ -810,7 +1753,7 @@ var useNativeShadowDom = false;
|
|
|
810
1753
|
var checkSlotFallbackVisibility = false;
|
|
811
1754
|
var checkSlotRelocate = false;
|
|
812
1755
|
var isSvgMode = false;
|
|
813
|
-
var createElm = (oldParentVNode, newParentVNode, childIndex
|
|
1756
|
+
var createElm = (oldParentVNode, newParentVNode, childIndex) => {
|
|
814
1757
|
var _a;
|
|
815
1758
|
const newVNode2 = newParentVNode.$children$[childIndex];
|
|
816
1759
|
let i2 = 0;
|
|
@@ -820,9 +1763,6 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
820
1763
|
if (!useNativeShadowDom) {
|
|
821
1764
|
checkSlotRelocate = true;
|
|
822
1765
|
if (newVNode2.$tag$ === "slot") {
|
|
823
|
-
if (scopeId) {
|
|
824
|
-
parentElm.classList.add(scopeId + "-s");
|
|
825
|
-
}
|
|
826
1766
|
newVNode2.$flags$ |= newVNode2.$children$ ? (
|
|
827
1767
|
// slot element has fallback content
|
|
828
1768
|
// still create an element that "mocks" the slot element
|
|
@@ -836,14 +1776,22 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
836
1776
|
}
|
|
837
1777
|
}
|
|
838
1778
|
if (newVNode2.$text$ !== null) {
|
|
839
|
-
elm = newVNode2.$elm$ =
|
|
1779
|
+
elm = newVNode2.$elm$ = win.document.createTextNode(newVNode2.$text$);
|
|
840
1780
|
} else if (newVNode2.$flags$ & 1 /* isSlotReference */) {
|
|
841
|
-
elm = newVNode2.$elm$ =
|
|
1781
|
+
elm = newVNode2.$elm$ = win.document.createTextNode("");
|
|
1782
|
+
{
|
|
1783
|
+
updateElement(null, newVNode2, isSvgMode);
|
|
1784
|
+
}
|
|
842
1785
|
} else {
|
|
843
1786
|
if (!isSvgMode) {
|
|
844
1787
|
isSvgMode = newVNode2.$tag$ === "svg";
|
|
845
1788
|
}
|
|
846
|
-
|
|
1789
|
+
if (!win.document) {
|
|
1790
|
+
throw new Error(
|
|
1791
|
+
"You are trying to render a Stencil component in an environment that doesn't support the DOM. Make sure to populate the [`window`](https://developer.mozilla.org/en-US/docs/Web/API/Window/window) object before rendering a component."
|
|
1792
|
+
);
|
|
1793
|
+
}
|
|
1794
|
+
elm = newVNode2.$elm$ = win.document.createElementNS(
|
|
847
1795
|
isSvgMode ? SVG_NS : HTML_NS,
|
|
848
1796
|
!useNativeShadowDom && BUILD.slotRelocation && newVNode2.$flags$ & 2 /* isSlotFallback */ ? "slot-fb" : newVNode2.$tag$
|
|
849
1797
|
) ;
|
|
@@ -853,17 +1801,12 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
853
1801
|
{
|
|
854
1802
|
updateElement(null, newVNode2, isSvgMode);
|
|
855
1803
|
}
|
|
856
|
-
|
|
857
|
-
const isElementWithinShadowRoot = !rootNode.querySelector("body");
|
|
858
|
-
if (!isElementWithinShadowRoot && BUILD.scoped && isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
1804
|
+
if (isDef(scopeId) && elm["s-si"] !== scopeId) {
|
|
859
1805
|
elm.classList.add(elm["s-si"] = scopeId);
|
|
860
1806
|
}
|
|
861
|
-
{
|
|
862
|
-
updateElementScopeIds(elm, parentElm);
|
|
863
|
-
}
|
|
864
1807
|
if (newVNode2.$children$) {
|
|
865
1808
|
for (i2 = 0; i2 < newVNode2.$children$.length; ++i2) {
|
|
866
|
-
childNode = createElm(oldParentVNode, newVNode2, i2
|
|
1809
|
+
childNode = createElm(oldParentVNode, newVNode2, i2);
|
|
867
1810
|
if (childNode) {
|
|
868
1811
|
elm.appendChild(childNode);
|
|
869
1812
|
}
|
|
@@ -884,12 +1827,16 @@ var createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
884
1827
|
elm["s-cr"] = contentRef;
|
|
885
1828
|
elm["s-sn"] = newVNode2.$name$ || "";
|
|
886
1829
|
elm["s-rf"] = (_a = newVNode2.$attrs$) == null ? void 0 : _a.ref;
|
|
1830
|
+
patchSlotNode(elm);
|
|
887
1831
|
oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];
|
|
888
1832
|
if (oldVNode && oldVNode.$tag$ === newVNode2.$tag$ && oldParentVNode.$elm$) {
|
|
889
1833
|
{
|
|
890
1834
|
relocateToHostRoot(oldParentVNode.$elm$);
|
|
891
1835
|
}
|
|
892
1836
|
}
|
|
1837
|
+
{
|
|
1838
|
+
addRemoveSlotScopedClass(contentRef, elm, newParentVNode.$elm$, oldParentVNode == null ? void 0 : oldParentVNode.$elm$);
|
|
1839
|
+
}
|
|
893
1840
|
}
|
|
894
1841
|
}
|
|
895
1842
|
return elm;
|
|
@@ -898,8 +1845,12 @@ var relocateToHostRoot = (parentElm) => {
|
|
|
898
1845
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
899
1846
|
const host = parentElm.closest(hostTagName.toLowerCase());
|
|
900
1847
|
if (host != null) {
|
|
901
|
-
const contentRefNode = Array.from(host.childNodes).find(
|
|
902
|
-
|
|
1848
|
+
const contentRefNode = Array.from(host.__childNodes || host.childNodes).find(
|
|
1849
|
+
(ref) => ref["s-cr"]
|
|
1850
|
+
);
|
|
1851
|
+
const childNodeArray = Array.from(
|
|
1852
|
+
parentElm.__childNodes || parentElm.childNodes
|
|
1853
|
+
);
|
|
903
1854
|
for (const childNode of contentRefNode ? childNodeArray.reverse() : childNodeArray) {
|
|
904
1855
|
if (childNode["s-sh"] != null) {
|
|
905
1856
|
insertBefore(host, childNode, contentRefNode != null ? contentRefNode : null);
|
|
@@ -908,11 +1859,11 @@ var relocateToHostRoot = (parentElm) => {
|
|
|
908
1859
|
}
|
|
909
1860
|
}
|
|
910
1861
|
}
|
|
911
|
-
plt.$flags$ &=
|
|
1862
|
+
plt.$flags$ &= -2 /* isTmpDisconnected */;
|
|
912
1863
|
};
|
|
913
1864
|
var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
914
1865
|
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
915
|
-
const oldSlotChildNodes = Array.from(parentElm.childNodes);
|
|
1866
|
+
const oldSlotChildNodes = Array.from(parentElm.__childNodes || parentElm.childNodes);
|
|
916
1867
|
if (parentElm["s-sr"] && BUILD.experimentalSlotFixes) {
|
|
917
1868
|
let node = parentElm;
|
|
918
1869
|
while (node = node.nextSibling) {
|
|
@@ -924,7 +1875,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
|
924
1875
|
for (let i2 = oldSlotChildNodes.length - 1; i2 >= 0; i2--) {
|
|
925
1876
|
const childNode = oldSlotChildNodes[i2];
|
|
926
1877
|
if (childNode["s-hn"] !== hostTagName && childNode["s-ol"]) {
|
|
927
|
-
insertBefore(
|
|
1878
|
+
insertBefore(referenceNode(childNode).parentNode, childNode, referenceNode(childNode));
|
|
928
1879
|
childNode["s-ol"].remove();
|
|
929
1880
|
childNode["s-ol"] = void 0;
|
|
930
1881
|
childNode["s-sh"] = void 0;
|
|
@@ -934,7 +1885,7 @@ var putBackInOriginalLocation = (parentElm, recursive) => {
|
|
|
934
1885
|
putBackInOriginalLocation(childNode, recursive);
|
|
935
1886
|
}
|
|
936
1887
|
}
|
|
937
|
-
plt.$flags$ &=
|
|
1888
|
+
plt.$flags$ &= -2 /* isTmpDisconnected */;
|
|
938
1889
|
};
|
|
939
1890
|
var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
940
1891
|
let containerElm = parentElm["s-cr"] && parentElm["s-cr"].parentNode || parentElm;
|
|
@@ -944,7 +1895,7 @@ var addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
|
944
1895
|
}
|
|
945
1896
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
946
1897
|
if (vnodes[startIdx]) {
|
|
947
|
-
childNode = createElm(null, parentVNode, startIdx
|
|
1898
|
+
childNode = createElm(null, parentVNode, startIdx);
|
|
948
1899
|
if (childNode) {
|
|
949
1900
|
vnodes[startIdx].$elm$ = childNode;
|
|
950
1901
|
insertBefore(containerElm, childNode, referenceNode(before) );
|
|
@@ -1031,7 +1982,7 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
1031
1982
|
if (idxInOld >= 0) {
|
|
1032
1983
|
elmToMove = oldCh[idxInOld];
|
|
1033
1984
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
|
1034
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld
|
|
1985
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, idxInOld);
|
|
1035
1986
|
} else {
|
|
1036
1987
|
patch(elmToMove, newStartVnode, isInitialRender);
|
|
1037
1988
|
oldCh[idxInOld] = void 0;
|
|
@@ -1039,12 +1990,16 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
1039
1990
|
}
|
|
1040
1991
|
newStartVnode = newCh[++newStartIdx];
|
|
1041
1992
|
} else {
|
|
1042
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx
|
|
1993
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode2, newStartIdx);
|
|
1043
1994
|
newStartVnode = newCh[++newStartIdx];
|
|
1044
1995
|
}
|
|
1045
1996
|
if (node) {
|
|
1046
1997
|
{
|
|
1047
|
-
insertBefore(
|
|
1998
|
+
insertBefore(
|
|
1999
|
+
referenceNode(oldStartVnode.$elm$).parentNode,
|
|
2000
|
+
node,
|
|
2001
|
+
referenceNode(oldStartVnode.$elm$)
|
|
2002
|
+
);
|
|
1048
2003
|
}
|
|
1049
2004
|
}
|
|
1050
2005
|
}
|
|
@@ -1065,28 +2020,19 @@ var updateChildren = (parentElm, oldCh, newVNode2, newCh, isInitialRender = fals
|
|
|
1065
2020
|
var isSameVnode = (leftVNode, rightVNode, isInitialRender = false) => {
|
|
1066
2021
|
if (leftVNode.$tag$ === rightVNode.$tag$) {
|
|
1067
2022
|
if (leftVNode.$tag$ === "slot") {
|
|
1068
|
-
if (
|
|
1069
|
-
// The component gets hydrated and no VDOM has been initialized.
|
|
1070
|
-
// Here the comparison can't happen as $name$ property is not set for `leftNode`.
|
|
1071
|
-
"$nodeId$" in leftVNode && isInitialRender && // `leftNode` is not from type HTMLComment which would cause many
|
|
1072
|
-
// hydration comments to be removed
|
|
1073
|
-
leftVNode.$elm$.nodeType !== 8
|
|
1074
|
-
) {
|
|
1075
|
-
return false;
|
|
1076
|
-
}
|
|
1077
2023
|
return leftVNode.$name$ === rightVNode.$name$;
|
|
1078
2024
|
}
|
|
1079
2025
|
if (!isInitialRender) {
|
|
1080
2026
|
return leftVNode.$key$ === rightVNode.$key$;
|
|
1081
2027
|
}
|
|
2028
|
+
if (isInitialRender && !leftVNode.$key$ && rightVNode.$key$) {
|
|
2029
|
+
leftVNode.$key$ = rightVNode.$key$;
|
|
2030
|
+
}
|
|
1082
2031
|
return true;
|
|
1083
2032
|
}
|
|
1084
2033
|
return false;
|
|
1085
2034
|
};
|
|
1086
|
-
var referenceNode = (node) =>
|
|
1087
|
-
return node && node["s-ol"] || node;
|
|
1088
|
-
};
|
|
1089
|
-
var parentReferenceNode = (node) => (node["s-ol"] ? node["s-ol"] : node).parentNode;
|
|
2035
|
+
var referenceNode = (node) => node && node["s-ol"] || node;
|
|
1090
2036
|
var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
1091
2037
|
const elm = newVNode2.$elm$ = oldVNode.$elm$;
|
|
1092
2038
|
const oldChildren = oldVNode.$children$;
|
|
@@ -1104,9 +2050,8 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
1104
2050
|
newVNode2.$elm$["s-sn"] = newVNode2.$name$ || "";
|
|
1105
2051
|
relocateToHostRoot(newVNode2.$elm$.parentElement);
|
|
1106
2052
|
}
|
|
1107
|
-
} else {
|
|
1108
|
-
updateElement(oldVNode, newVNode2, isSvgMode);
|
|
1109
2053
|
}
|
|
2054
|
+
updateElement(oldVNode, newVNode2, isSvgMode, isInitialRender);
|
|
1110
2055
|
}
|
|
1111
2056
|
if (oldChildren !== null && newChildren !== null) {
|
|
1112
2057
|
updateChildren(elm, oldChildren, newVNode2, newChildren, isInitialRender);
|
|
@@ -1125,36 +2070,9 @@ var patch = (oldVNode, newVNode2, isInitialRender = false) => {
|
|
|
1125
2070
|
isSvgMode = false;
|
|
1126
2071
|
}
|
|
1127
2072
|
} else if ((defaultHolder = elm["s-cr"])) {
|
|
1128
|
-
defaultHolder.parentNode.textContent = text;
|
|
1129
|
-
} else if (oldVNode.$text$ !== text) {
|
|
1130
|
-
elm.data = text;
|
|
1131
|
-
}
|
|
1132
|
-
};
|
|
1133
|
-
var updateFallbackSlotVisibility = (elm) => {
|
|
1134
|
-
const childNodes = elm.childNodes;
|
|
1135
|
-
for (const childNode of childNodes) {
|
|
1136
|
-
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
1137
|
-
if (childNode["s-sr"]) {
|
|
1138
|
-
const slotName = childNode["s-sn"];
|
|
1139
|
-
childNode.hidden = false;
|
|
1140
|
-
for (const siblingNode of childNodes) {
|
|
1141
|
-
if (siblingNode !== childNode) {
|
|
1142
|
-
if (siblingNode["s-hn"] !== childNode["s-hn"] || slotName !== "") {
|
|
1143
|
-
if (siblingNode.nodeType === 1 /* ElementNode */ && (slotName === siblingNode.getAttribute("slot") || slotName === siblingNode["s-sn"]) || siblingNode.nodeType === 3 /* TextNode */ && slotName === siblingNode["s-sn"]) {
|
|
1144
|
-
childNode.hidden = true;
|
|
1145
|
-
break;
|
|
1146
|
-
}
|
|
1147
|
-
} else {
|
|
1148
|
-
if (siblingNode.nodeType === 1 /* ElementNode */ || siblingNode.nodeType === 3 /* TextNode */ && siblingNode.textContent.trim() !== "") {
|
|
1149
|
-
childNode.hidden = true;
|
|
1150
|
-
break;
|
|
1151
|
-
}
|
|
1152
|
-
}
|
|
1153
|
-
}
|
|
1154
|
-
}
|
|
1155
|
-
}
|
|
1156
|
-
updateFallbackSlotVisibility(childNode);
|
|
1157
|
-
}
|
|
2073
|
+
defaultHolder.parentNode.textContent = text;
|
|
2074
|
+
} else if (oldVNode.$text$ !== text) {
|
|
2075
|
+
elm.data = text;
|
|
1158
2076
|
}
|
|
1159
2077
|
};
|
|
1160
2078
|
var relocateNodes = [];
|
|
@@ -1162,9 +2080,10 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
1162
2080
|
let node;
|
|
1163
2081
|
let hostContentNodes;
|
|
1164
2082
|
let j;
|
|
1165
|
-
|
|
2083
|
+
const children = elm.__childNodes || elm.childNodes;
|
|
2084
|
+
for (const childNode of children) {
|
|
1166
2085
|
if (childNode["s-sr"] && (node = childNode["s-cr"]) && node.parentNode) {
|
|
1167
|
-
hostContentNodes = node.parentNode.childNodes;
|
|
2086
|
+
hostContentNodes = node.parentNode.__childNodes || node.parentNode.childNodes;
|
|
1168
2087
|
const slotName = childNode["s-sn"];
|
|
1169
2088
|
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
1170
2089
|
node = hostContentNodes[j];
|
|
@@ -1206,21 +2125,6 @@ var markSlotContentForRelocation = (elm) => {
|
|
|
1206
2125
|
}
|
|
1207
2126
|
}
|
|
1208
2127
|
};
|
|
1209
|
-
var isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
|
|
1210
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1211
|
-
if (nodeToRelocate.getAttribute("slot") === null && slotName === "") {
|
|
1212
|
-
return true;
|
|
1213
|
-
}
|
|
1214
|
-
if (nodeToRelocate.getAttribute("slot") === slotName) {
|
|
1215
|
-
return true;
|
|
1216
|
-
}
|
|
1217
|
-
return false;
|
|
1218
|
-
}
|
|
1219
|
-
if (nodeToRelocate["s-sn"] === slotName) {
|
|
1220
|
-
return true;
|
|
1221
|
-
}
|
|
1222
|
-
return slotName === "";
|
|
1223
|
-
};
|
|
1224
2128
|
var nullifyVNodeRefs = (vNode) => {
|
|
1225
2129
|
{
|
|
1226
2130
|
vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
|
|
@@ -1228,44 +2132,51 @@ var nullifyVNodeRefs = (vNode) => {
|
|
|
1228
2132
|
}
|
|
1229
2133
|
};
|
|
1230
2134
|
var insertBefore = (parent, newNode, reference) => {
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
}
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
);
|
|
2135
|
+
if (typeof newNode["s-sn"] === "string" && !!newNode["s-sr"] && !!newNode["s-cr"]) {
|
|
2136
|
+
addRemoveSlotScopedClass(newNode["s-cr"], newNode, parent, newNode.parentElement);
|
|
2137
|
+
} else if (typeof newNode["s-sn"] === "string") {
|
|
2138
|
+
if (parent.getRootNode().nodeType !== 11 /* DOCUMENT_FRAGMENT_NODE */) {
|
|
2139
|
+
patchParentNode(newNode);
|
|
2140
|
+
}
|
|
2141
|
+
parent.insertBefore(newNode, reference);
|
|
2142
|
+
const { slotNode } = findSlotFromSlottedNode(newNode);
|
|
2143
|
+
if (slotNode) dispatchSlotChangeEvent(slotNode);
|
|
2144
|
+
return newNode;
|
|
2145
|
+
}
|
|
2146
|
+
if (parent.__insertBefore) {
|
|
2147
|
+
return parent.__insertBefore(newNode, reference);
|
|
2148
|
+
} else {
|
|
2149
|
+
return parent == null ? void 0 : parent.insertBefore(newNode, reference);
|
|
1246
2150
|
}
|
|
1247
|
-
return scopeIds;
|
|
1248
2151
|
};
|
|
1249
|
-
|
|
1250
|
-
var _a;
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
2152
|
+
function addRemoveSlotScopedClass(reference, slotNode, newParent, oldParent) {
|
|
2153
|
+
var _a, _b;
|
|
2154
|
+
let scopeId2;
|
|
2155
|
+
if (reference && typeof slotNode["s-sn"] === "string" && !!slotNode["s-sr"] && reference.parentNode && reference.parentNode["s-sc"] && (scopeId2 = slotNode["s-si"] || reference.parentNode["s-sc"])) {
|
|
2156
|
+
const scopeName = slotNode["s-sn"];
|
|
2157
|
+
const hostName = slotNode["s-hn"];
|
|
2158
|
+
(_a = newParent.classList) == null ? void 0 : _a.add(scopeId2 + "-s");
|
|
2159
|
+
if (oldParent && ((_b = oldParent.classList) == null ? void 0 : _b.contains(scopeId2 + "-s"))) {
|
|
2160
|
+
let child = (oldParent.__childNodes || oldParent.childNodes)[0];
|
|
2161
|
+
let found = false;
|
|
2162
|
+
while (child) {
|
|
2163
|
+
if (child["s-sn"] !== scopeName && child["s-hn"] === hostName && !!child["s-sr"]) {
|
|
2164
|
+
found = true;
|
|
2165
|
+
break;
|
|
1258
2166
|
}
|
|
2167
|
+
child = child.nextSibling;
|
|
1259
2168
|
}
|
|
2169
|
+
if (!found) oldParent.classList.remove(scopeId2 + "-s");
|
|
1260
2170
|
}
|
|
1261
2171
|
}
|
|
1262
|
-
}
|
|
2172
|
+
}
|
|
1263
2173
|
var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
1264
2174
|
var _a, _b, _c, _d, _e;
|
|
1265
2175
|
const hostElm = hostRef.$hostElement$;
|
|
1266
2176
|
const cmpMeta = hostRef.$cmpMeta$;
|
|
1267
2177
|
const oldVNode = hostRef.$vnode$ || newVNode(null, null);
|
|
1268
|
-
const
|
|
2178
|
+
const isHostElement = isHost(renderFnResults);
|
|
2179
|
+
const rootVnode = isHostElement ? renderFnResults : h(null, null, renderFnResults);
|
|
1269
2180
|
hostTagName = hostElm.tagName;
|
|
1270
2181
|
if (cmpMeta.$attrsToReflect$) {
|
|
1271
2182
|
rootVnode.$attrs$ = rootVnode.$attrs$ || {};
|
|
@@ -1287,7 +2198,7 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1287
2198
|
{
|
|
1288
2199
|
scopeId = hostElm["s-sc"];
|
|
1289
2200
|
}
|
|
1290
|
-
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */)
|
|
2201
|
+
useNativeShadowDom = !!(cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) && !(cmpMeta.$flags$ & 128 /* shadowNeedsScopedCss */);
|
|
1291
2202
|
{
|
|
1292
2203
|
contentRef = hostElm["s-cr"];
|
|
1293
2204
|
checkSlotFallbackVisibility = false;
|
|
@@ -1299,8 +2210,8 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1299
2210
|
markSlotContentForRelocation(rootVnode.$elm$);
|
|
1300
2211
|
for (const relocateData of relocateNodes) {
|
|
1301
2212
|
const nodeToRelocate = relocateData.$nodeToRelocate$;
|
|
1302
|
-
if (!nodeToRelocate["s-ol"]) {
|
|
1303
|
-
const orgLocationNode =
|
|
2213
|
+
if (!nodeToRelocate["s-ol"] && win.document) {
|
|
2214
|
+
const orgLocationNode = win.document.createTextNode("");
|
|
1304
2215
|
orgLocationNode["s-nr"] = nodeToRelocate;
|
|
1305
2216
|
insertBefore(nodeToRelocate.parentNode, nodeToRelocate["s-ol"] = orgLocationNode, nodeToRelocate);
|
|
1306
2217
|
}
|
|
@@ -1311,11 +2222,11 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1311
2222
|
if (slotRefNode) {
|
|
1312
2223
|
const parentNodeRef = slotRefNode.parentNode;
|
|
1313
2224
|
let insertBeforeNode = slotRefNode.nextSibling;
|
|
1314
|
-
if (insertBeforeNode && insertBeforeNode.nodeType === 1 /* ElementNode */) {
|
|
2225
|
+
if ((insertBeforeNode && insertBeforeNode.nodeType === 1 /* ElementNode */)) {
|
|
1315
2226
|
let orgLocationNode = (_a = nodeToRelocate["s-ol"]) == null ? void 0 : _a.previousSibling;
|
|
1316
2227
|
while (orgLocationNode) {
|
|
1317
2228
|
let refNode = (_b = orgLocationNode["s-nr"]) != null ? _b : null;
|
|
1318
|
-
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === refNode.parentNode) {
|
|
2229
|
+
if (refNode && refNode["s-sn"] === nodeToRelocate["s-sn"] && parentNodeRef === (refNode.__parentNode || refNode.parentNode)) {
|
|
1319
2230
|
refNode = refNode.nextSibling;
|
|
1320
2231
|
while (refNode === nodeToRelocate || (refNode == null ? void 0 : refNode["s-sr"])) {
|
|
1321
2232
|
refNode = refNode == null ? void 0 : refNode.nextSibling;
|
|
@@ -1328,15 +2239,17 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1328
2239
|
orgLocationNode = orgLocationNode.previousSibling;
|
|
1329
2240
|
}
|
|
1330
2241
|
}
|
|
1331
|
-
|
|
2242
|
+
const parent = nodeToRelocate.__parentNode || nodeToRelocate.parentNode;
|
|
2243
|
+
const nextSibling = nodeToRelocate.__nextSibling || nodeToRelocate.nextSibling;
|
|
2244
|
+
if (!insertBeforeNode && parentNodeRef !== parent || nextSibling !== insertBeforeNode) {
|
|
1332
2245
|
if (nodeToRelocate !== insertBeforeNode) {
|
|
1333
2246
|
insertBefore(parentNodeRef, nodeToRelocate, insertBeforeNode);
|
|
1334
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
2247
|
+
if (nodeToRelocate.nodeType === 1 /* ElementNode */ && nodeToRelocate.tagName !== "SLOT-FB") {
|
|
1335
2248
|
nodeToRelocate.hidden = (_c = nodeToRelocate["s-ih"]) != null ? _c : false;
|
|
1336
2249
|
}
|
|
1337
2250
|
}
|
|
1338
2251
|
}
|
|
1339
|
-
nodeToRelocate && typeof slotRefNode["s-rf"] === "function" && slotRefNode["s-rf"](
|
|
2252
|
+
nodeToRelocate && typeof slotRefNode["s-rf"] === "function" && slotRefNode["s-rf"](slotRefNode);
|
|
1340
2253
|
} else {
|
|
1341
2254
|
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1342
2255
|
if (isInitialLoad) {
|
|
@@ -1350,11 +2263,12 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1350
2263
|
if (checkSlotFallbackVisibility) {
|
|
1351
2264
|
updateFallbackSlotVisibility(rootVnode.$elm$);
|
|
1352
2265
|
}
|
|
1353
|
-
plt.$flags$ &=
|
|
2266
|
+
plt.$flags$ &= -2 /* isTmpDisconnected */;
|
|
1354
2267
|
relocateNodes.length = 0;
|
|
1355
2268
|
}
|
|
1356
2269
|
if (cmpMeta.$flags$ & 2 /* scopedCssEncapsulation */) {
|
|
1357
|
-
|
|
2270
|
+
const children = rootVnode.$elm$.__childNodes || rootVnode.$elm$.childNodes;
|
|
2271
|
+
for (const childNode of children) {
|
|
1358
2272
|
if (childNode["s-hn"] !== hostTagName && !childNode["s-sh"]) {
|
|
1359
2273
|
if (isInitialLoad && childNode["s-ih"] == null) {
|
|
1360
2274
|
childNode["s-ih"] = (_e = childNode.hidden) != null ? _e : false;
|
|
@@ -1369,7 +2283,14 @@ var renderVdom = (hostRef, renderFnResults, isInitialLoad = false) => {
|
|
|
1369
2283
|
// src/runtime/update-component.ts
|
|
1370
2284
|
var attachToAncestor = (hostRef, ancestorComponent) => {
|
|
1371
2285
|
if (ancestorComponent && !hostRef.$onRenderResolve$ && ancestorComponent["s-p"]) {
|
|
1372
|
-
ancestorComponent["s-p"].push(
|
|
2286
|
+
const index = ancestorComponent["s-p"].push(
|
|
2287
|
+
new Promise(
|
|
2288
|
+
(r) => hostRef.$onRenderResolve$ = () => {
|
|
2289
|
+
ancestorComponent["s-p"].splice(index - 1, 1);
|
|
2290
|
+
r();
|
|
2291
|
+
}
|
|
2292
|
+
)
|
|
2293
|
+
);
|
|
1373
2294
|
}
|
|
1374
2295
|
};
|
|
1375
2296
|
var scheduleUpdate = (hostRef, isInitialLoad) => {
|
|
@@ -1398,17 +2319,15 @@ var dispatchHooks = (hostRef, isInitialLoad) => {
|
|
|
1398
2319
|
{
|
|
1399
2320
|
hostRef.$flags$ |= 256 /* isListenReady */;
|
|
1400
2321
|
if (hostRef.$queuedListeners$) {
|
|
1401
|
-
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
|
|
2322
|
+
hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event, elm));
|
|
1402
2323
|
hostRef.$queuedListeners$ = void 0;
|
|
1403
2324
|
}
|
|
1404
2325
|
}
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
}
|
|
1409
|
-
{
|
|
1410
|
-
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender"));
|
|
2326
|
+
maybePromise = safeCall(instance, "componentWillLoad", void 0, elm);
|
|
2327
|
+
} else {
|
|
2328
|
+
maybePromise = safeCall(instance, "componentWillUpdate", void 0, elm);
|
|
1411
2329
|
}
|
|
2330
|
+
maybePromise = enqueue(maybePromise, () => safeCall(instance, "componentWillRender", void 0, elm));
|
|
1412
2331
|
endSchedule();
|
|
1413
2332
|
return enqueue(maybePromise, () => updateComponent(hostRef, instance, isInitialLoad));
|
|
1414
2333
|
};
|
|
@@ -1451,7 +2370,7 @@ var callRender = (hostRef, instance, elm, isInitialLoad) => {
|
|
|
1451
2370
|
try {
|
|
1452
2371
|
instance = instance.render && instance.render();
|
|
1453
2372
|
{
|
|
1454
|
-
hostRef.$flags$ &=
|
|
2373
|
+
hostRef.$flags$ &= -17 /* isQueuedForUpdate */;
|
|
1455
2374
|
}
|
|
1456
2375
|
{
|
|
1457
2376
|
hostRef.$flags$ |= 2 /* hasRendered */;
|
|
@@ -1474,17 +2393,13 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1474
2393
|
const endPostUpdate = createTime("postUpdate", tagName);
|
|
1475
2394
|
const instance = hostRef.$lazyInstance$ ;
|
|
1476
2395
|
const ancestorComponent = hostRef.$ancestorComponent$;
|
|
1477
|
-
|
|
1478
|
-
safeCall(instance, "componentDidRender");
|
|
1479
|
-
}
|
|
2396
|
+
safeCall(instance, "componentDidRender", void 0, elm);
|
|
1480
2397
|
if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
|
|
1481
2398
|
hostRef.$flags$ |= 64 /* hasLoadedComponent */;
|
|
1482
2399
|
{
|
|
1483
2400
|
addHydratedFlag(elm);
|
|
1484
2401
|
}
|
|
1485
|
-
|
|
1486
|
-
safeCall(instance, "componentDidLoad");
|
|
1487
|
-
}
|
|
2402
|
+
safeCall(instance, "componentDidLoad", void 0, elm);
|
|
1488
2403
|
endPostUpdate();
|
|
1489
2404
|
{
|
|
1490
2405
|
hostRef.$onReadyResolve$(elm);
|
|
@@ -1493,9 +2408,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1493
2408
|
}
|
|
1494
2409
|
}
|
|
1495
2410
|
} else {
|
|
1496
|
-
|
|
1497
|
-
safeCall(instance, "componentDidUpdate");
|
|
1498
|
-
}
|
|
2411
|
+
safeCall(instance, "componentDidUpdate", void 0, elm);
|
|
1499
2412
|
endPostUpdate();
|
|
1500
2413
|
}
|
|
1501
2414
|
{
|
|
@@ -1509,7 +2422,7 @@ var postUpdateComponent = (hostRef) => {
|
|
|
1509
2422
|
if (hostRef.$flags$ & 512 /* needsRerender */) {
|
|
1510
2423
|
nextTick(() => scheduleUpdate(hostRef, false));
|
|
1511
2424
|
}
|
|
1512
|
-
hostRef.$flags$ &=
|
|
2425
|
+
hostRef.$flags$ &= -517;
|
|
1513
2426
|
}
|
|
1514
2427
|
};
|
|
1515
2428
|
var forceUpdate = (ref) => {
|
|
@@ -1523,17 +2436,14 @@ var forceUpdate = (ref) => {
|
|
|
1523
2436
|
}
|
|
1524
2437
|
};
|
|
1525
2438
|
var appDidLoad = (who) => {
|
|
1526
|
-
{
|
|
1527
|
-
addHydratedFlag(doc.documentElement);
|
|
1528
|
-
}
|
|
1529
2439
|
nextTick(() => emitEvent(win, "appload", { detail: { namespace: NAMESPACE } }));
|
|
1530
2440
|
};
|
|
1531
|
-
var safeCall = (instance, method, arg) => {
|
|
2441
|
+
var safeCall = (instance, method, arg, elm) => {
|
|
1532
2442
|
if (instance && instance[method]) {
|
|
1533
2443
|
try {
|
|
1534
2444
|
return instance[method](arg);
|
|
1535
2445
|
} catch (e) {
|
|
1536
|
-
consoleError(e);
|
|
2446
|
+
consoleError(e, elm);
|
|
1537
2447
|
}
|
|
1538
2448
|
}
|
|
1539
2449
|
return void 0;
|
|
@@ -1549,7 +2459,7 @@ var setValue = (ref, propName, newVal, cmpMeta) => {
|
|
|
1549
2459
|
const hostRef = getHostRef(ref);
|
|
1550
2460
|
if (!hostRef) {
|
|
1551
2461
|
throw new Error(
|
|
1552
|
-
`Couldn't find host element for "${cmpMeta.$tagName$}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/
|
|
2462
|
+
`Couldn't find host element for "${cmpMeta.$tagName$}" as it is unknown to this Stencil runtime. This usually happens when integrating a 3rd party Stencil component with another Stencil component or application. Please reach out to the maintainers of the 3rd party Stencil component or report this on the Stencil Discord server (https://chat.stenciljs.com) or comment on this similar [GitHub issue](https://github.com/stenciljs/core/issues/5457).`
|
|
1553
2463
|
);
|
|
1554
2464
|
}
|
|
1555
2465
|
const elm = hostRef.$hostElement$ ;
|
|
@@ -1575,6 +2485,11 @@ var setValue = (ref, propName, newVal, cmpMeta) => {
|
|
|
1575
2485
|
}
|
|
1576
2486
|
}
|
|
1577
2487
|
if ((flags & (2 /* hasRendered */ | 16 /* isQueuedForUpdate */)) === 2 /* hasRendered */) {
|
|
2488
|
+
if (instance.componentShouldUpdate) {
|
|
2489
|
+
if (instance.componentShouldUpdate(newVal, oldVal, propName) === false) {
|
|
2490
|
+
return;
|
|
2491
|
+
}
|
|
2492
|
+
}
|
|
1578
2493
|
scheduleUpdate(hostRef, false);
|
|
1579
2494
|
}
|
|
1580
2495
|
}
|
|
@@ -1592,15 +2507,68 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1592
2507
|
const members = Object.entries((_a = cmpMeta.$members$) != null ? _a : {});
|
|
1593
2508
|
members.map(([memberName, [memberFlags]]) => {
|
|
1594
2509
|
if ((memberFlags & 31 /* Prop */ || (flags & 2 /* proxyState */) && memberFlags & 32 /* State */)) {
|
|
2510
|
+
const { get: origGetter, set: origSetter } = Object.getOwnPropertyDescriptor(prototype, memberName) || {};
|
|
2511
|
+
if (origGetter) cmpMeta.$members$[memberName][0] |= 2048 /* Getter */;
|
|
2512
|
+
if (origSetter) cmpMeta.$members$[memberName][0] |= 4096 /* Setter */;
|
|
2513
|
+
if (flags & 1 /* isElementConstructor */ || !origGetter) {
|
|
2514
|
+
Object.defineProperty(prototype, memberName, {
|
|
2515
|
+
get() {
|
|
2516
|
+
{
|
|
2517
|
+
if ((cmpMeta.$members$[memberName][0] & 2048 /* Getter */) === 0) {
|
|
2518
|
+
return getValue(this, memberName);
|
|
2519
|
+
}
|
|
2520
|
+
const ref = getHostRef(this);
|
|
2521
|
+
const instance = ref ? ref.$lazyInstance$ : prototype;
|
|
2522
|
+
if (!instance) return;
|
|
2523
|
+
return instance[memberName];
|
|
2524
|
+
}
|
|
2525
|
+
},
|
|
2526
|
+
configurable: true,
|
|
2527
|
+
enumerable: true
|
|
2528
|
+
});
|
|
2529
|
+
}
|
|
1595
2530
|
Object.defineProperty(prototype, memberName, {
|
|
1596
|
-
get() {
|
|
1597
|
-
return getValue(this, memberName);
|
|
1598
|
-
},
|
|
1599
2531
|
set(newValue) {
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
2532
|
+
const ref = getHostRef(this);
|
|
2533
|
+
if (origSetter) {
|
|
2534
|
+
const currentValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
2535
|
+
if (typeof currentValue === "undefined" && ref.$instanceValues$.get(memberName)) {
|
|
2536
|
+
newValue = ref.$instanceValues$.get(memberName);
|
|
2537
|
+
} else if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
2538
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
2539
|
+
}
|
|
2540
|
+
origSetter.apply(this, [parsePropertyValue(newValue, memberFlags)]);
|
|
2541
|
+
newValue = memberFlags & 32 /* State */ ? this[memberName] : ref.$hostElement$[memberName];
|
|
2542
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
2543
|
+
return;
|
|
2544
|
+
}
|
|
2545
|
+
{
|
|
2546
|
+
if ((flags & 1 /* isElementConstructor */) === 0 || (cmpMeta.$members$[memberName][0] & 4096 /* Setter */) === 0) {
|
|
2547
|
+
setValue(this, memberName, newValue, cmpMeta);
|
|
2548
|
+
if (flags & 1 /* isElementConstructor */ && !ref.$lazyInstance$) {
|
|
2549
|
+
ref.$onReadyPromise$.then(() => {
|
|
2550
|
+
if (cmpMeta.$members$[memberName][0] & 4096 /* Setter */ && ref.$lazyInstance$[memberName] !== ref.$instanceValues$.get(memberName)) {
|
|
2551
|
+
ref.$lazyInstance$[memberName] = newValue;
|
|
2552
|
+
}
|
|
2553
|
+
});
|
|
2554
|
+
}
|
|
2555
|
+
return;
|
|
2556
|
+
}
|
|
2557
|
+
const setterSetVal = () => {
|
|
2558
|
+
const currentValue = ref.$lazyInstance$[memberName];
|
|
2559
|
+
if (!ref.$instanceValues$.get(memberName) && currentValue) {
|
|
2560
|
+
ref.$instanceValues$.set(memberName, currentValue);
|
|
2561
|
+
}
|
|
2562
|
+
ref.$lazyInstance$[memberName] = parsePropertyValue(newValue, memberFlags);
|
|
2563
|
+
setValue(this, memberName, ref.$lazyInstance$[memberName], cmpMeta);
|
|
2564
|
+
};
|
|
2565
|
+
if (ref.$lazyInstance$) {
|
|
2566
|
+
setterSetVal();
|
|
2567
|
+
} else {
|
|
2568
|
+
ref.$onReadyPromise$.then(() => setterSetVal());
|
|
2569
|
+
}
|
|
2570
|
+
}
|
|
2571
|
+
}
|
|
1604
2572
|
});
|
|
1605
2573
|
} else if (flags & 1 /* isElementConstructor */ && memberFlags & 64 /* Method */) {
|
|
1606
2574
|
Object.defineProperty(prototype, memberName, {
|
|
@@ -1621,7 +2589,7 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1621
2589
|
plt.jmp(() => {
|
|
1622
2590
|
var _a2;
|
|
1623
2591
|
const propName = attrNameToPropName.get(attrName);
|
|
1624
|
-
if (this.hasOwnProperty(propName)) {
|
|
2592
|
+
if (this.hasOwnProperty(propName) && BUILD.lazyLoad) {
|
|
1625
2593
|
newValue = this[propName];
|
|
1626
2594
|
delete this[propName];
|
|
1627
2595
|
} else if (prototype.hasOwnProperty(propName) && typeof this[propName] === "number" && // cast type to number to avoid TS compiler issues
|
|
@@ -1641,7 +2609,11 @@ var proxyComponent = (Cstr, cmpMeta, flags) => {
|
|
|
1641
2609
|
}
|
|
1642
2610
|
return;
|
|
1643
2611
|
}
|
|
1644
|
-
|
|
2612
|
+
const propDesc = Object.getOwnPropertyDescriptor(prototype, propName);
|
|
2613
|
+
newValue = newValue === null && typeof this[propName] === "boolean" ? false : newValue;
|
|
2614
|
+
if (newValue !== this[propName] && (!propDesc.get || !!propDesc.set)) {
|
|
2615
|
+
this[propName] = newValue;
|
|
2616
|
+
}
|
|
1645
2617
|
});
|
|
1646
2618
|
};
|
|
1647
2619
|
Cstr.observedAttributes = Array.from(
|
|
@@ -1670,7 +2642,7 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1670
2642
|
hostRef.$flags$ |= 32 /* hasInitializedComponent */;
|
|
1671
2643
|
const bundleId = cmpMeta.$lazyBundleId$;
|
|
1672
2644
|
if (bundleId) {
|
|
1673
|
-
const CstrImport = loadModule(cmpMeta);
|
|
2645
|
+
const CstrImport = loadModule(cmpMeta, hostRef);
|
|
1674
2646
|
if (CstrImport && "then" in CstrImport) {
|
|
1675
2647
|
const endLoad = uniqueTime();
|
|
1676
2648
|
Cstr = await CstrImport;
|
|
@@ -1695,16 +2667,16 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1695
2667
|
try {
|
|
1696
2668
|
new Cstr(hostRef);
|
|
1697
2669
|
} catch (e) {
|
|
1698
|
-
consoleError(e);
|
|
2670
|
+
consoleError(e, elm);
|
|
1699
2671
|
}
|
|
1700
2672
|
{
|
|
1701
|
-
hostRef.$flags$ &=
|
|
2673
|
+
hostRef.$flags$ &= -9 /* isConstructingInstance */;
|
|
1702
2674
|
}
|
|
1703
2675
|
{
|
|
1704
2676
|
hostRef.$flags$ |= 128 /* isWatchReady */;
|
|
1705
2677
|
}
|
|
1706
2678
|
endNewInstance();
|
|
1707
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
2679
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1708
2680
|
} else {
|
|
1709
2681
|
Cstr = elm.constructor;
|
|
1710
2682
|
const cmpTag = elm.localName;
|
|
@@ -1736,9 +2708,9 @@ var initializeComponent = async (elm, hostRef, cmpMeta, hmrVersionId) => {
|
|
|
1736
2708
|
schedule();
|
|
1737
2709
|
}
|
|
1738
2710
|
};
|
|
1739
|
-
var fireConnectedCallback = (instance) => {
|
|
2711
|
+
var fireConnectedCallback = (instance, elm) => {
|
|
1740
2712
|
{
|
|
1741
|
-
safeCall(instance, "connectedCallback");
|
|
2713
|
+
safeCall(instance, "connectedCallback", void 0, elm);
|
|
1742
2714
|
}
|
|
1743
2715
|
};
|
|
1744
2716
|
|
|
@@ -1757,6 +2729,9 @@ var connectedCallback = (elm) => {
|
|
|
1757
2729
|
if (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) {
|
|
1758
2730
|
const scopeId2 = addStyle(elm.shadowRoot, cmpMeta, elm.getAttribute("s-mode")) ;
|
|
1759
2731
|
elm.classList.remove(scopeId2 + "-h", scopeId2 + "-s");
|
|
2732
|
+
} else if (cmpMeta.$flags$ & 2 /* scopedCssEncapsulation */) {
|
|
2733
|
+
const scopeId2 = getScopeId(cmpMeta, elm.getAttribute("s-mode") );
|
|
2734
|
+
elm["s-sc"] = scopeId2;
|
|
1760
2735
|
}
|
|
1761
2736
|
initializeClientHydrate(elm, cmpMeta.$tagName$, hostId, hostRef);
|
|
1762
2737
|
}
|
|
@@ -1791,24 +2766,27 @@ var connectedCallback = (elm) => {
|
|
|
1791
2766
|
} else {
|
|
1792
2767
|
addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
|
|
1793
2768
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1794
|
-
fireConnectedCallback(hostRef.$lazyInstance
|
|
2769
|
+
fireConnectedCallback(hostRef.$lazyInstance$, elm);
|
|
1795
2770
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1796
|
-
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance
|
|
2771
|
+
hostRef.$onReadyPromise$.then(() => fireConnectedCallback(hostRef.$lazyInstance$, elm));
|
|
1797
2772
|
}
|
|
1798
2773
|
}
|
|
1799
2774
|
endConnected();
|
|
1800
2775
|
}
|
|
1801
2776
|
};
|
|
1802
2777
|
var setContentReference = (elm) => {
|
|
1803
|
-
|
|
2778
|
+
if (!win.document) {
|
|
2779
|
+
return;
|
|
2780
|
+
}
|
|
2781
|
+
const contentRefElm = elm["s-cr"] = win.document.createComment(
|
|
1804
2782
|
""
|
|
1805
2783
|
);
|
|
1806
2784
|
contentRefElm["s-cn"] = true;
|
|
1807
2785
|
insertBefore(elm, contentRefElm, elm.firstChild);
|
|
1808
2786
|
};
|
|
1809
|
-
var disconnectInstance = (instance) => {
|
|
2787
|
+
var disconnectInstance = (instance, elm) => {
|
|
1810
2788
|
{
|
|
1811
|
-
safeCall(instance, "disconnectedCallback");
|
|
2789
|
+
safeCall(instance, "disconnectedCallback", void 0, elm || instance);
|
|
1812
2790
|
}
|
|
1813
2791
|
};
|
|
1814
2792
|
var disconnectedCallback = async (elm) => {
|
|
@@ -1821,312 +2799,44 @@ var disconnectedCallback = async (elm) => {
|
|
|
1821
2799
|
}
|
|
1822
2800
|
}
|
|
1823
2801
|
if (hostRef == null ? void 0 : hostRef.$lazyInstance$) {
|
|
1824
|
-
disconnectInstance(hostRef.$lazyInstance
|
|
2802
|
+
disconnectInstance(hostRef.$lazyInstance$, elm);
|
|
1825
2803
|
} else if (hostRef == null ? void 0 : hostRef.$onReadyPromise$) {
|
|
1826
|
-
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance
|
|
1827
|
-
}
|
|
1828
|
-
}
|
|
1829
|
-
};
|
|
1830
|
-
var patchPseudoShadowDom = (hostElementPrototype, descriptorPrototype) => {
|
|
1831
|
-
patchCloneNode(hostElementPrototype);
|
|
1832
|
-
patchSlotAppendChild(hostElementPrototype);
|
|
1833
|
-
patchSlotAppend(hostElementPrototype);
|
|
1834
|
-
patchSlotPrepend(hostElementPrototype);
|
|
1835
|
-
patchSlotInsertAdjacentElement(hostElementPrototype);
|
|
1836
|
-
patchSlotInsertAdjacentHTML(hostElementPrototype);
|
|
1837
|
-
patchSlotInsertAdjacentText(hostElementPrototype);
|
|
1838
|
-
patchTextContent(hostElementPrototype);
|
|
1839
|
-
patchChildSlotNodes(hostElementPrototype, descriptorPrototype);
|
|
1840
|
-
patchSlotRemoveChild(hostElementPrototype);
|
|
1841
|
-
};
|
|
1842
|
-
var patchCloneNode = (HostElementPrototype) => {
|
|
1843
|
-
const orgCloneNode = HostElementPrototype.cloneNode;
|
|
1844
|
-
HostElementPrototype.cloneNode = function(deep) {
|
|
1845
|
-
const srcNode = this;
|
|
1846
|
-
const isShadowDom = srcNode.shadowRoot && supportsShadow ;
|
|
1847
|
-
const clonedNode = orgCloneNode.call(srcNode, isShadowDom ? deep : false);
|
|
1848
|
-
if (!isShadowDom && deep) {
|
|
1849
|
-
let i2 = 0;
|
|
1850
|
-
let slotted, nonStencilNode;
|
|
1851
|
-
const stencilPrivates = [
|
|
1852
|
-
"s-id",
|
|
1853
|
-
"s-cr",
|
|
1854
|
-
"s-lr",
|
|
1855
|
-
"s-rc",
|
|
1856
|
-
"s-sc",
|
|
1857
|
-
"s-p",
|
|
1858
|
-
"s-cn",
|
|
1859
|
-
"s-sr",
|
|
1860
|
-
"s-sn",
|
|
1861
|
-
"s-hn",
|
|
1862
|
-
"s-ol",
|
|
1863
|
-
"s-nr",
|
|
1864
|
-
"s-si",
|
|
1865
|
-
"s-rf",
|
|
1866
|
-
"s-scs"
|
|
1867
|
-
];
|
|
1868
|
-
for (; i2 < srcNode.childNodes.length; i2++) {
|
|
1869
|
-
slotted = srcNode.childNodes[i2]["s-nr"];
|
|
1870
|
-
nonStencilNode = stencilPrivates.every((privateField) => !srcNode.childNodes[i2][privateField]);
|
|
1871
|
-
if (slotted) {
|
|
1872
|
-
if (clonedNode.__appendChild) {
|
|
1873
|
-
clonedNode.__appendChild(slotted.cloneNode(true));
|
|
1874
|
-
} else {
|
|
1875
|
-
clonedNode.appendChild(slotted.cloneNode(true));
|
|
1876
|
-
}
|
|
1877
|
-
}
|
|
1878
|
-
if (nonStencilNode) {
|
|
1879
|
-
clonedNode.appendChild(srcNode.childNodes[i2].cloneNode(true));
|
|
1880
|
-
}
|
|
1881
|
-
}
|
|
1882
|
-
}
|
|
1883
|
-
return clonedNode;
|
|
1884
|
-
};
|
|
1885
|
-
};
|
|
1886
|
-
var patchSlotAppendChild = (HostElementPrototype) => {
|
|
1887
|
-
HostElementPrototype.__appendChild = HostElementPrototype.appendChild;
|
|
1888
|
-
HostElementPrototype.appendChild = function(newChild) {
|
|
1889
|
-
const slotName = newChild["s-sn"] = getSlotName(newChild);
|
|
1890
|
-
const slotNode = getHostSlotNode(this.childNodes, slotName, this.tagName);
|
|
1891
|
-
if (slotNode) {
|
|
1892
|
-
const slotChildNodes = getHostSlotChildNodes(slotNode, slotName);
|
|
1893
|
-
const appendAfter = slotChildNodes[slotChildNodes.length - 1];
|
|
1894
|
-
const insertedNode = insertBefore(appendAfter.parentNode, newChild, appendAfter.nextSibling);
|
|
1895
|
-
updateFallbackSlotVisibility(this);
|
|
1896
|
-
return insertedNode;
|
|
1897
|
-
}
|
|
1898
|
-
return this.__appendChild(newChild);
|
|
1899
|
-
};
|
|
1900
|
-
};
|
|
1901
|
-
var patchSlotRemoveChild = (ElementPrototype) => {
|
|
1902
|
-
ElementPrototype.__removeChild = ElementPrototype.removeChild;
|
|
1903
|
-
ElementPrototype.removeChild = function(toRemove) {
|
|
1904
|
-
if (toRemove && typeof toRemove["s-sn"] !== "undefined") {
|
|
1905
|
-
const slotNode = getHostSlotNode(this.childNodes, toRemove["s-sn"], this.tagName);
|
|
1906
|
-
if (slotNode) {
|
|
1907
|
-
const slotChildNodes = getHostSlotChildNodes(slotNode, toRemove["s-sn"]);
|
|
1908
|
-
const existingNode = slotChildNodes.find((n) => n === toRemove);
|
|
1909
|
-
if (existingNode) {
|
|
1910
|
-
existingNode.remove();
|
|
1911
|
-
updateFallbackSlotVisibility(this);
|
|
1912
|
-
return;
|
|
1913
|
-
}
|
|
1914
|
-
}
|
|
1915
|
-
}
|
|
1916
|
-
return this.__removeChild(toRemove);
|
|
1917
|
-
};
|
|
1918
|
-
};
|
|
1919
|
-
var patchSlotPrepend = (HostElementPrototype) => {
|
|
1920
|
-
const originalPrepend = HostElementPrototype.prepend;
|
|
1921
|
-
HostElementPrototype.prepend = function(...newChildren) {
|
|
1922
|
-
newChildren.forEach((newChild) => {
|
|
1923
|
-
if (typeof newChild === "string") {
|
|
1924
|
-
newChild = this.ownerDocument.createTextNode(newChild);
|
|
1925
|
-
}
|
|
1926
|
-
const slotName = newChild["s-sn"] = getSlotName(newChild);
|
|
1927
|
-
const slotNode = getHostSlotNode(this.childNodes, slotName, this.tagName);
|
|
1928
|
-
if (slotNode) {
|
|
1929
|
-
const slotPlaceholder = document.createTextNode("");
|
|
1930
|
-
slotPlaceholder["s-nr"] = newChild;
|
|
1931
|
-
slotNode["s-cr"].parentNode.__appendChild(slotPlaceholder);
|
|
1932
|
-
newChild["s-ol"] = slotPlaceholder;
|
|
1933
|
-
const slotChildNodes = getHostSlotChildNodes(slotNode, slotName);
|
|
1934
|
-
const appendAfter = slotChildNodes[0];
|
|
1935
|
-
return insertBefore(appendAfter.parentNode, newChild, appendAfter.nextSibling);
|
|
1936
|
-
}
|
|
1937
|
-
if (newChild.nodeType === 1 && !!newChild.getAttribute("slot")) {
|
|
1938
|
-
newChild.hidden = true;
|
|
1939
|
-
}
|
|
1940
|
-
return originalPrepend.call(this, newChild);
|
|
1941
|
-
});
|
|
1942
|
-
};
|
|
1943
|
-
};
|
|
1944
|
-
var patchSlotAppend = (HostElementPrototype) => {
|
|
1945
|
-
HostElementPrototype.append = function(...newChildren) {
|
|
1946
|
-
newChildren.forEach((newChild) => {
|
|
1947
|
-
if (typeof newChild === "string") {
|
|
1948
|
-
newChild = this.ownerDocument.createTextNode(newChild);
|
|
1949
|
-
}
|
|
1950
|
-
this.appendChild(newChild);
|
|
1951
|
-
});
|
|
1952
|
-
};
|
|
1953
|
-
};
|
|
1954
|
-
var patchSlotInsertAdjacentHTML = (HostElementPrototype) => {
|
|
1955
|
-
const originalInsertAdjacentHtml = HostElementPrototype.insertAdjacentHTML;
|
|
1956
|
-
HostElementPrototype.insertAdjacentHTML = function(position, text) {
|
|
1957
|
-
if (position !== "afterbegin" && position !== "beforeend") {
|
|
1958
|
-
return originalInsertAdjacentHtml.call(this, position, text);
|
|
1959
|
-
}
|
|
1960
|
-
const container = this.ownerDocument.createElement("_");
|
|
1961
|
-
let node;
|
|
1962
|
-
container.innerHTML = text;
|
|
1963
|
-
if (position === "afterbegin") {
|
|
1964
|
-
while (node = container.firstChild) {
|
|
1965
|
-
this.prepend(node);
|
|
1966
|
-
}
|
|
1967
|
-
} else if (position === "beforeend") {
|
|
1968
|
-
while (node = container.firstChild) {
|
|
1969
|
-
this.append(node);
|
|
1970
|
-
}
|
|
1971
|
-
}
|
|
1972
|
-
};
|
|
1973
|
-
};
|
|
1974
|
-
var patchSlotInsertAdjacentText = (HostElementPrototype) => {
|
|
1975
|
-
HostElementPrototype.insertAdjacentText = function(position, text) {
|
|
1976
|
-
this.insertAdjacentHTML(position, text);
|
|
1977
|
-
};
|
|
1978
|
-
};
|
|
1979
|
-
var patchSlotInsertAdjacentElement = (HostElementPrototype) => {
|
|
1980
|
-
const originalInsertAdjacentElement = HostElementPrototype.insertAdjacentElement;
|
|
1981
|
-
HostElementPrototype.insertAdjacentElement = function(position, element) {
|
|
1982
|
-
if (position !== "afterbegin" && position !== "beforeend") {
|
|
1983
|
-
return originalInsertAdjacentElement.call(this, position, element);
|
|
1984
|
-
}
|
|
1985
|
-
if (position === "afterbegin") {
|
|
1986
|
-
this.prepend(element);
|
|
1987
|
-
return element;
|
|
1988
|
-
} else if (position === "beforeend") {
|
|
1989
|
-
this.append(element);
|
|
1990
|
-
return element;
|
|
1991
|
-
}
|
|
1992
|
-
return element;
|
|
1993
|
-
};
|
|
1994
|
-
};
|
|
1995
|
-
var patchTextContent = (hostElementPrototype) => {
|
|
1996
|
-
const descriptor = Object.getOwnPropertyDescriptor(Node.prototype, "textContent");
|
|
1997
|
-
Object.defineProperty(hostElementPrototype, "__textContent", descriptor);
|
|
1998
|
-
{
|
|
1999
|
-
Object.defineProperty(hostElementPrototype, "textContent", {
|
|
2000
|
-
// To mimic shadow root behavior, we need to return the text content of all
|
|
2001
|
-
// nodes in a slot reference node
|
|
2002
|
-
get() {
|
|
2003
|
-
const slotRefNodes = getAllChildSlotNodes(this.childNodes);
|
|
2004
|
-
const textContent = slotRefNodes.map((node) => {
|
|
2005
|
-
var _a, _b;
|
|
2006
|
-
const text = [];
|
|
2007
|
-
let slotContent = node.nextSibling;
|
|
2008
|
-
while (slotContent && slotContent["s-sn"] === node["s-sn"]) {
|
|
2009
|
-
if (slotContent.nodeType === 3 /* TEXT_NODE */ || slotContent.nodeType === 1 /* ELEMENT_NODE */) {
|
|
2010
|
-
text.push((_b = (_a = slotContent.textContent) == null ? void 0 : _a.trim()) != null ? _b : "");
|
|
2011
|
-
}
|
|
2012
|
-
slotContent = slotContent.nextSibling;
|
|
2013
|
-
}
|
|
2014
|
-
return text.filter((ref) => ref !== "").join(" ");
|
|
2015
|
-
}).filter((text) => text !== "").join(" ");
|
|
2016
|
-
return " " + textContent + " ";
|
|
2017
|
-
},
|
|
2018
|
-
// To mimic shadow root behavior, we need to overwrite all nodes in a slot
|
|
2019
|
-
// reference node. If a default slot reference node exists, the text content will be
|
|
2020
|
-
// placed there. Otherwise, the new text node will be hidden
|
|
2021
|
-
set(value) {
|
|
2022
|
-
const slotRefNodes = getAllChildSlotNodes(this.childNodes);
|
|
2023
|
-
slotRefNodes.forEach((node) => {
|
|
2024
|
-
let slotContent = node.nextSibling;
|
|
2025
|
-
while (slotContent && slotContent["s-sn"] === node["s-sn"]) {
|
|
2026
|
-
const tmp = slotContent;
|
|
2027
|
-
slotContent = slotContent.nextSibling;
|
|
2028
|
-
tmp.remove();
|
|
2029
|
-
}
|
|
2030
|
-
if (node["s-sn"] === "") {
|
|
2031
|
-
const textNode = this.ownerDocument.createTextNode(value);
|
|
2032
|
-
textNode["s-sn"] = "";
|
|
2033
|
-
insertBefore(node.parentElement, textNode, node.nextSibling);
|
|
2034
|
-
} else {
|
|
2035
|
-
node.remove();
|
|
2036
|
-
}
|
|
2037
|
-
});
|
|
2038
|
-
}
|
|
2039
|
-
});
|
|
2040
|
-
}
|
|
2041
|
-
};
|
|
2042
|
-
var patchChildSlotNodes = (elm, cmpMeta) => {
|
|
2043
|
-
class FakeNodeList extends Array {
|
|
2044
|
-
item(n) {
|
|
2045
|
-
return this[n];
|
|
2046
|
-
}
|
|
2047
|
-
}
|
|
2048
|
-
if (cmpMeta.$flags$ & 8 /* needsShadowDomShim */) {
|
|
2049
|
-
const childNodesFn = elm.__lookupGetter__("childNodes");
|
|
2050
|
-
Object.defineProperty(elm, "children", {
|
|
2051
|
-
get() {
|
|
2052
|
-
return this.childNodes.map((n) => n.nodeType === 1);
|
|
2053
|
-
}
|
|
2054
|
-
});
|
|
2055
|
-
Object.defineProperty(elm, "childElementCount", {
|
|
2056
|
-
get() {
|
|
2057
|
-
return elm.children.length;
|
|
2058
|
-
}
|
|
2059
|
-
});
|
|
2060
|
-
Object.defineProperty(elm, "childNodes", {
|
|
2061
|
-
get() {
|
|
2062
|
-
const childNodes = childNodesFn.call(this);
|
|
2063
|
-
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0 && getHostRef(this).$flags$ & 2 /* hasRendered */) {
|
|
2064
|
-
const result = new FakeNodeList();
|
|
2065
|
-
for (let i2 = 0; i2 < childNodes.length; i2++) {
|
|
2066
|
-
const slot = childNodes[i2]["s-nr"];
|
|
2067
|
-
if (slot) {
|
|
2068
|
-
result.push(slot);
|
|
2069
|
-
}
|
|
2070
|
-
}
|
|
2071
|
-
return result;
|
|
2072
|
-
}
|
|
2073
|
-
return FakeNodeList.from(childNodes);
|
|
2074
|
-
}
|
|
2075
|
-
});
|
|
2076
|
-
}
|
|
2077
|
-
};
|
|
2078
|
-
var getAllChildSlotNodes = (childNodes) => {
|
|
2079
|
-
const slotRefNodes = [];
|
|
2080
|
-
for (const childNode of Array.from(childNodes)) {
|
|
2081
|
-
if (childNode["s-sr"]) {
|
|
2082
|
-
slotRefNodes.push(childNode);
|
|
2804
|
+
hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$, elm));
|
|
2083
2805
|
}
|
|
2084
|
-
slotRefNodes.push(...getAllChildSlotNodes(childNode.childNodes));
|
|
2085
2806
|
}
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
var getSlotName = (node) => node["s-sn"] || node.nodeType === 1 && node.getAttribute("slot") || "";
|
|
2089
|
-
var getHostSlotNode = (childNodes, slotName, hostName) => {
|
|
2090
|
-
let i2 = 0;
|
|
2091
|
-
let childNode;
|
|
2092
|
-
for (; i2 < childNodes.length; i2++) {
|
|
2093
|
-
childNode = childNodes[i2];
|
|
2094
|
-
if (childNode["s-sr"] && childNode["s-sn"] === slotName && childNode["s-hn"] === hostName) {
|
|
2095
|
-
return childNode;
|
|
2096
|
-
}
|
|
2097
|
-
childNode = getHostSlotNode(childNode.childNodes, slotName, hostName);
|
|
2098
|
-
if (childNode) {
|
|
2099
|
-
return childNode;
|
|
2100
|
-
}
|
|
2807
|
+
if (rootAppliedStyles.has(elm)) {
|
|
2808
|
+
rootAppliedStyles.delete(elm);
|
|
2101
2809
|
}
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
var getHostSlotChildNodes = (n, slotName) => {
|
|
2105
|
-
const childNodes = [n];
|
|
2106
|
-
while ((n = n.nextSibling) && n["s-sn"] === slotName) {
|
|
2107
|
-
childNodes.push(n);
|
|
2810
|
+
if (elm.shadowRoot && rootAppliedStyles.has(elm.shadowRoot)) {
|
|
2811
|
+
rootAppliedStyles.delete(elm.shadowRoot);
|
|
2108
2812
|
}
|
|
2109
|
-
return childNodes;
|
|
2110
2813
|
};
|
|
2111
2814
|
|
|
2112
2815
|
// src/runtime/bootstrap-lazy.ts
|
|
2113
2816
|
var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
2114
2817
|
var _a;
|
|
2818
|
+
if (!win.document) {
|
|
2819
|
+
console.warn("Stencil: No document found. Skipping bootstrapping lazy components.");
|
|
2820
|
+
return;
|
|
2821
|
+
}
|
|
2115
2822
|
const endBootstrap = createTime();
|
|
2116
2823
|
const cmpTags = [];
|
|
2117
2824
|
const exclude = options.exclude || [];
|
|
2118
2825
|
const customElements2 = win.customElements;
|
|
2119
|
-
const head =
|
|
2826
|
+
const head = win.document.head;
|
|
2120
2827
|
const metaCharset = /* @__PURE__ */ head.querySelector("meta[charset]");
|
|
2121
|
-
const dataStyles = /* @__PURE__ */
|
|
2828
|
+
const dataStyles = /* @__PURE__ */ win.document.createElement("style");
|
|
2122
2829
|
const deferredConnectedCallbacks = [];
|
|
2123
2830
|
let appLoadFallback;
|
|
2124
2831
|
let isBootstrapping = true;
|
|
2125
2832
|
Object.assign(plt, options);
|
|
2126
|
-
plt.$resourcesUrl$ = new URL(options.resourcesUrl || "./",
|
|
2833
|
+
plt.$resourcesUrl$ = new URL(options.resourcesUrl || "./", win.document.baseURI).href;
|
|
2127
2834
|
{
|
|
2128
2835
|
plt.$flags$ |= 2 /* appLoaded */;
|
|
2129
2836
|
}
|
|
2837
|
+
{
|
|
2838
|
+
hydrateScopedToShadow();
|
|
2839
|
+
}
|
|
2130
2840
|
let hasSlotRelocation = false;
|
|
2131
2841
|
lazyBundles.map((lazyBundle) => {
|
|
2132
2842
|
lazyBundle[1].map((compactMeta) => {
|
|
@@ -2197,6 +2907,17 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2197
2907
|
}
|
|
2198
2908
|
disconnectedCallback() {
|
|
2199
2909
|
plt.jmp(() => disconnectedCallback(this));
|
|
2910
|
+
plt.raf(() => {
|
|
2911
|
+
var _a3;
|
|
2912
|
+
const hostRef = getHostRef(this);
|
|
2913
|
+
const i2 = deferredConnectedCallbacks.findIndex((host) => host === this);
|
|
2914
|
+
if (i2 > -1) {
|
|
2915
|
+
deferredConnectedCallbacks.splice(i2, 1);
|
|
2916
|
+
}
|
|
2917
|
+
if (((_a3 = hostRef == null ? void 0 : hostRef.$vnode$) == null ? void 0 : _a3.$elm$) instanceof Node && !hostRef.$vnode$.$elm$.isConnected) {
|
|
2918
|
+
delete hostRef.$vnode$.$elm$;
|
|
2919
|
+
}
|
|
2920
|
+
});
|
|
2200
2921
|
}
|
|
2201
2922
|
componentOnReady() {
|
|
2202
2923
|
return getHostRef(this).$onReadyPromise$;
|
|
@@ -2204,7 +2925,7 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2204
2925
|
};
|
|
2205
2926
|
{
|
|
2206
2927
|
if (cmpMeta.$flags$ & 2 /* scopedCssEncapsulation */) {
|
|
2207
|
-
patchPseudoShadowDom(HostElement.prototype
|
|
2928
|
+
patchPseudoShadowDom(HostElement.prototype);
|
|
2208
2929
|
}
|
|
2209
2930
|
}
|
|
2210
2931
|
cmpMeta.$lazyBundleId$ = lazyBundle[0];
|
|
@@ -2226,7 +2947,7 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2226
2947
|
}
|
|
2227
2948
|
if (dataStyles.innerHTML.length) {
|
|
2228
2949
|
dataStyles.setAttribute("data-styles", "");
|
|
2229
|
-
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(
|
|
2950
|
+
const nonce = (_a = plt.$nonce$) != null ? _a : queryNonceMetaTagContent(win.document);
|
|
2230
2951
|
if (nonce != null) {
|
|
2231
2952
|
dataStyles.setAttribute("nonce", nonce);
|
|
2232
2953
|
}
|
|
@@ -2244,9 +2965,9 @@ var bootstrapLazy = (lazyBundles, options = {}) => {
|
|
|
2244
2965
|
endBootstrap();
|
|
2245
2966
|
};
|
|
2246
2967
|
var addHostEventListeners = (elm, hostRef, listeners, attachParentListeners) => {
|
|
2247
|
-
if (listeners) {
|
|
2968
|
+
if (listeners && win.document) {
|
|
2248
2969
|
listeners.map(([flags, name, method]) => {
|
|
2249
|
-
const target = getHostListenerTarget(elm, flags) ;
|
|
2970
|
+
const target = getHostListenerTarget(win.document, elm, flags) ;
|
|
2250
2971
|
const handler = hostListenerProxy(hostRef, method);
|
|
2251
2972
|
const opts = hostListenerOpts(flags);
|
|
2252
2973
|
plt.ael(target, name, handler, opts);
|
|
@@ -2265,13 +2986,19 @@ var hostListenerProxy = (hostRef, methodName) => (ev) => {
|
|
|
2265
2986
|
}
|
|
2266
2987
|
}
|
|
2267
2988
|
} catch (e) {
|
|
2268
|
-
consoleError(e);
|
|
2989
|
+
consoleError(e, hostRef.$hostElement$);
|
|
2269
2990
|
}
|
|
2270
2991
|
};
|
|
2271
|
-
var getHostListenerTarget = (elm, flags) => {
|
|
2272
|
-
if (flags & 4 /* TargetDocument */)
|
|
2273
|
-
|
|
2274
|
-
|
|
2992
|
+
var getHostListenerTarget = (doc, elm, flags) => {
|
|
2993
|
+
if (flags & 4 /* TargetDocument */) {
|
|
2994
|
+
return doc;
|
|
2995
|
+
}
|
|
2996
|
+
if (flags & 8 /* TargetWindow */) {
|
|
2997
|
+
return win;
|
|
2998
|
+
}
|
|
2999
|
+
if (flags & 16 /* TargetBody */) {
|
|
3000
|
+
return doc.body;
|
|
3001
|
+
}
|
|
2275
3002
|
return elm;
|
|
2276
3003
|
};
|
|
2277
3004
|
var hostListenerOpts = (flags) => supportsListenerOptions ? {
|
|
@@ -2282,4 +3009,4 @@ var hostListenerOpts = (flags) => supportsListenerOptions ? {
|
|
|
2282
3009
|
// src/runtime/nonce.ts
|
|
2283
3010
|
var setNonce = (nonce) => plt.$nonce$ = nonce;
|
|
2284
3011
|
|
|
2285
|
-
export { Build as B, H,
|
|
3012
|
+
export { Build as B, H, readTask as a, bootstrapLazy as b, createEvent as c, Host as d, getAssetPath as e, forceUpdate as f, getElement as g, h, getMode as i, setMode as j, promiseResolve as p, registerInstance as r, setNonce as s, writeTask as w };
|