@ionic/core 8.8.9-dev.11780493937.17fe092d → 8.8.9-dev.11780683233.1c5e9d9b
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/ion-action-sheet.js +1 -1
- package/components/ion-alert.js +1 -1
- package/components/ion-back-button.js +1 -1
- package/components/ion-button.js +1 -1
- package/components/ion-card.js +1 -1
- package/components/ion-chip.js +1 -1
- package/components/ion-content.js +1 -1
- package/components/ion-datetime-button.js +1 -1
- package/components/ion-datetime.js +1 -1
- package/components/ion-fab-button.js +1 -1
- package/components/ion-footer.js +1 -1
- package/components/ion-gallery-item.d.ts +11 -0
- package/components/ion-gallery-item.js +4 -0
- package/components/ion-gallery.js +1 -1
- package/components/ion-grid.js +1 -1
- package/components/ion-header.js +1 -1
- package/components/ion-img.js +1 -1
- package/components/ion-infinite-scroll-content.js +1 -1
- package/components/ion-infinite-scroll.js +1 -1
- package/components/ion-input-otp.js +1 -1
- package/components/ion-input-password-toggle.js +1 -1
- package/components/ion-input.js +1 -1
- package/components/ion-item-divider.js +1 -1
- package/components/ion-item-group.js +1 -1
- package/components/ion-item-option.js +1 -1
- package/components/ion-item-options.js +1 -1
- package/components/ion-item-sliding.js +1 -1
- package/components/ion-item.js +1 -1
- package/components/ion-label.js +1 -1
- package/components/ion-list-header.js +1 -1
- package/components/ion-list.js +1 -1
- package/components/ion-loading.js +1 -1
- package/components/ion-menu-button.js +1 -1
- package/components/ion-menu-toggle.js +1 -1
- package/components/ion-menu.js +1 -1
- package/components/ion-modal.js +1 -1
- package/components/ion-nav-link.js +1 -1
- package/components/ion-nav.js +1 -1
- package/components/ion-note.js +1 -1
- package/components/ion-picker-column-option.js +1 -1
- package/components/ion-picker-legacy-column.js +1 -1
- package/components/ion-picker-legacy.js +1 -1
- package/components/ion-popover.js +1 -1
- package/components/ion-progress-bar.js +1 -1
- package/components/ion-radio-group.js +1 -1
- package/components/ion-radio.js +1 -1
- package/components/ion-range.js +1 -1
- package/components/ion-refresher-content.js +1 -1
- package/components/ion-refresher.js +1 -1
- package/components/ion-reorder-group.js +1 -1
- package/components/ion-reorder.js +1 -1
- package/components/ion-ripple-effect.js +1 -1
- package/components/ion-router-link.js +1 -1
- package/components/ion-router-outlet.js +1 -1
- package/components/ion-row.js +1 -1
- package/components/ion-searchbar.js +1 -1
- package/components/ion-segment-button.js +1 -1
- package/components/ion-segment-content.js +1 -1
- package/components/ion-segment-view.js +1 -1
- package/components/ion-segment.js +1 -1
- package/components/ion-select-modal.js +1 -1
- package/components/ion-select-option.js +1 -1
- package/components/ion-select-popover.js +1 -1
- package/components/ion-select.js +1 -1
- package/components/ion-skeleton-text.js +1 -1
- package/components/ion-spinner.js +1 -1
- package/components/ion-split-pane.js +1 -1
- package/components/ion-tab-bar.js +1 -1
- package/components/ion-tab-button.js +1 -1
- package/components/ion-tab.js +1 -1
- package/components/ion-tabs.js +1 -1
- package/components/ion-text.js +1 -1
- package/components/ion-textarea.js +1 -1
- package/components/ion-thumbnail.js +1 -1
- package/components/ion-title.js +1 -1
- package/components/ion-toast.js +1 -1
- package/components/ion-toggle.js +1 -1
- package/components/ion-toolbar.js +1 -1
- package/components/p-7kL3tltU.js +4 -0
- package/components/{p-CPm7KgOP.js → p-BFZBl0TS.js} +1 -1
- package/components/{p-pvh0bjpw.js → p-BVi3gqm6.js} +1 -1
- package/components/{p-D6g8ud1e.js → p-BVk7LVs0.js} +1 -1
- package/components/{p-B9MABkWm.js → p-BdUtZxku.js} +1 -1
- package/components/{p-CzC_ZSgb.js → p-Be8tHurp.js} +1 -1
- package/components/{p-C8kBejTT.js → p-CG3ZV6ON.js} +1 -1
- package/components/{p-CBS0sBAa.js → p-CaqTORfV.js} +1 -1
- package/components/{p-D2mReIu8.js → p-CkA0SI9d.js} +1 -1
- package/components/{p-DAXhdEp5.js → p-CsakePQg.js} +1 -1
- package/components/{p-CgSn4J7d.js → p-D1gEOh9B.js} +1 -1
- package/components/{p-IYdTEyGb.js → p-D3qBmaqi.js} +1 -1
- package/components/{p-Do7NMUwR.js → p-DGn-jQpr.js} +1 -1
- package/components/p-DH4JHV73.js +4 -0
- package/components/{p-DCS3n7Uq.js → p-DYK0qX7x.js} +1 -1
- package/components/{p-Dp2x0MpA.js → p-DfV7pOtM.js} +1 -1
- package/components/{p-BhkGOA7t.js → p-F3N54OKJ.js} +1 -1
- package/components/{p-CgZLVOCc.js → p-MPREydZp.js} +1 -1
- package/components/{p-kKYBfhbe.js → p-OFfrVDLw.js} +1 -1
- package/components/p-iZO3WzZT.js +4 -0
- package/components/p-qclL-gNR.js +4 -0
- package/dist/cjs/ion-app_8.cjs.entry.js +33 -291
- package/dist/cjs/ion-avatar_3.cjs.entry.js +2 -2
- package/dist/cjs/ion-col_3.cjs.entry.js +4 -4
- package/dist/cjs/ion-datetime_3.cjs.entry.js +4 -4
- package/dist/cjs/ion-gallery-item.cjs.entry.js +79 -0
- package/dist/cjs/ion-gallery.cjs.entry.js +96 -14
- package/dist/cjs/ion-img.cjs.entry.js +2 -2
- package/dist/cjs/ion-infinite-scroll_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-input-otp.cjs.entry.js +3 -3
- package/dist/cjs/ion-input-password-toggle.cjs.entry.js +3 -3
- package/dist/cjs/ion-input.cjs.entry.js +4 -4
- package/dist/cjs/ion-item-option_3.cjs.entry.js +4 -4
- package/dist/cjs/ion-item_8.cjs.entry.js +12 -12
- package/dist/cjs/ion-loading.cjs.entry.js +2 -2
- package/dist/cjs/ion-menu_3.cjs.entry.js +6 -6
- package/dist/cjs/ion-modal.cjs.entry.js +4 -4
- package/dist/cjs/ion-nav_2.cjs.entry.js +2 -2
- package/dist/cjs/ion-picker-column-option.cjs.entry.js +2 -2
- package/dist/cjs/ion-popover.cjs.entry.js +2 -2
- package/dist/cjs/ion-progress-bar.cjs.entry.js +1 -1
- package/dist/cjs/ion-radio_2.cjs.entry.js +5 -5
- package/dist/cjs/ion-range.cjs.entry.js +3 -3
- package/dist/cjs/ion-refresher_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-reorder_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-ripple-effect.cjs.entry.js +1 -1
- package/dist/cjs/ion-route_4.cjs.entry.js +2 -2
- package/dist/cjs/ion-searchbar.cjs.entry.js +4 -4
- package/dist/cjs/ion-segment-content.cjs.entry.js +1 -1
- package/dist/cjs/ion-segment-view.cjs.entry.js +2 -2
- package/dist/cjs/ion-segment_2.cjs.entry.js +4 -4
- package/dist/cjs/ion-select-modal.cjs.entry.js +1 -1
- package/dist/cjs/ion-select_3.cjs.entry.js +6 -6
- package/dist/cjs/ion-spinner.cjs.entry.js +1 -1
- package/dist/cjs/ion-split-pane.cjs.entry.js +2 -2
- package/dist/cjs/ion-tab-bar_2.cjs.entry.js +4 -4
- package/dist/cjs/ion-tab_2.cjs.entry.js +3 -3
- package/dist/cjs/ion-text.cjs.entry.js +2 -2
- package/dist/cjs/ion-textarea.cjs.entry.js +3 -3
- package/dist/cjs/ion-toast.cjs.entry.js +2 -2
- package/dist/cjs/ion-toggle.cjs.entry.js +3 -3
- package/dist/cjs/ionic.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/content/content.css +0 -56
- package/dist/collection/components/footer/footer.ios.css +0 -13
- package/dist/collection/components/footer/footer.js +18 -65
- package/dist/collection/components/footer/footer.md.css +0 -13
- package/dist/collection/components/footer/footer.utils.js +0 -9
- package/dist/collection/components/gallery/gallery.css +1 -86
- package/dist/collection/components/gallery/gallery.js +85 -16
- package/dist/collection/components/gallery/test/utils.js +13 -13
- package/dist/collection/components/gallery-item/gallery-item.css +87 -0
- package/dist/collection/components/gallery-item/gallery-item.js +95 -0
- package/dist/collection/components/grid/grid.js +2 -2
- package/dist/collection/components/header/header.ionic.css +0 -75
- package/dist/collection/components/header/header.ios.css +0 -75
- package/dist/collection/components/header/header.js +11 -41
- package/dist/collection/components/header/header.md.css +0 -75
- package/dist/collection/components/header/header.utils.js +0 -9
- package/dist/collection/components/img/img.js +2 -2
- package/dist/collection/components/infinite-scroll/infinite-scroll.js +1 -1
- package/dist/collection/components/infinite-scroll-content/infinite-scroll-content.js +2 -2
- package/dist/collection/components/input/input.js +4 -4
- package/dist/collection/components/input-otp/input-otp.js +3 -3
- package/dist/collection/components/input-password-toggle/input-password-toggle.js +3 -3
- package/dist/collection/components/item-divider/item-divider.js +2 -2
- package/dist/collection/components/item-group/item-group.js +1 -1
- package/dist/collection/components/item-option/item-option.js +2 -2
- package/dist/collection/components/item-options/item-options.js +1 -1
- package/dist/collection/components/item-sliding/item-sliding.js +1 -1
- package/dist/collection/components/label/label.js +2 -2
- package/dist/collection/components/list/list.js +1 -1
- package/dist/collection/components/list-header/list-header.js +2 -2
- package/dist/collection/components/loading/loading.js +2 -2
- package/dist/collection/components/menu/menu.js +2 -2
- package/dist/collection/components/menu-button/menu-button.js +2 -2
- package/dist/collection/components/menu-toggle/menu-toggle.js +2 -2
- package/dist/collection/components/modal/modal.js +4 -4
- package/dist/collection/components/nav/nav.js +1 -1
- package/dist/collection/components/nav-link/nav-link.js +1 -1
- package/dist/collection/components/note/note.js +2 -2
- package/dist/collection/components/picker-column-option/picker-column-option.js +2 -2
- package/dist/collection/components/picker-legacy/picker.js +2 -2
- package/dist/collection/components/picker-legacy-column/picker-column.js +2 -2
- package/dist/collection/components/popover/popover.js +2 -2
- package/dist/collection/components/progress-bar/progress-bar.js +1 -1
- package/dist/collection/components/radio/radio.js +3 -3
- package/dist/collection/components/radio-group/radio-group.js +2 -2
- package/dist/collection/components/range/range.js +3 -3
- package/dist/collection/components/refresher/refresher.js +1 -1
- package/dist/collection/components/refresher-content/refresher-content.js +2 -2
- package/dist/collection/components/reorder/reorder.js +2 -2
- package/dist/collection/components/reorder-group/reorder-group.js +1 -1
- package/dist/collection/components/ripple-effect/ripple-effect.js +1 -1
- package/dist/collection/components/router-link/router-link.js +2 -2
- package/dist/collection/components/router-outlet/router-outlet.js +1 -1
- package/dist/collection/components/row/row.js +2 -2
- package/dist/collection/components/searchbar/searchbar.js +4 -4
- package/dist/collection/components/segment/segment.js +2 -2
- package/dist/collection/components/segment-button/segment-button.js +2 -2
- package/dist/collection/components/segment-content/segment-content.js +1 -1
- package/dist/collection/components/segment-view/segment-view.js +2 -2
- package/dist/collection/components/select/select.js +3 -3
- package/dist/collection/components/select-modal/select-modal.js +1 -1
- package/dist/collection/components/select-option/select-option.js +1 -1
- package/dist/collection/components/select-popover/select-popover.js +2 -2
- package/dist/collection/components/skeleton-text/skeleton-text.js +2 -2
- package/dist/collection/components/spinner/spinner.js +1 -1
- package/dist/collection/components/split-pane/split-pane.js +2 -2
- package/dist/collection/components/tab/tab.js +2 -2
- package/dist/collection/components/tab-bar/tab-bar.js +2 -2
- package/dist/collection/components/tab-button/tab-button.js +2 -2
- package/dist/collection/components/tabs/tabs.js +1 -1
- package/dist/collection/components/text/text.js +2 -2
- package/dist/collection/components/textarea/textarea.js +3 -3
- package/dist/collection/components/thumbnail/thumbnail.js +2 -2
- package/dist/collection/components/title/title.js +2 -2
- package/dist/collection/components/toast/toast.js +2 -2
- package/dist/collection/components/toggle/toggle.js +3 -3
- package/dist/collection/components/toolbar/toolbar.js +2 -2
- package/dist/collection/utils/css-value-validation.js +14 -0
- package/dist/docs.json +96 -20
- package/dist/esm/ion-app_8.entry.js +33 -291
- package/dist/esm/ion-avatar_3.entry.js +2 -2
- package/dist/esm/ion-col_3.entry.js +4 -4
- package/dist/esm/ion-datetime_3.entry.js +4 -4
- package/dist/esm/ion-gallery-item.entry.js +77 -0
- package/dist/esm/ion-gallery.entry.js +96 -14
- package/dist/esm/ion-img.entry.js +2 -2
- package/dist/esm/ion-infinite-scroll_2.entry.js +3 -3
- package/dist/esm/ion-input-otp.entry.js +3 -3
- package/dist/esm/ion-input-password-toggle.entry.js +3 -3
- package/dist/esm/ion-input.entry.js +4 -4
- package/dist/esm/ion-item-option_3.entry.js +4 -4
- package/dist/esm/ion-item_8.entry.js +12 -12
- package/dist/esm/ion-loading.entry.js +2 -2
- package/dist/esm/ion-menu_3.entry.js +6 -6
- package/dist/esm/ion-modal.entry.js +4 -4
- package/dist/esm/ion-nav_2.entry.js +2 -2
- package/dist/esm/ion-picker-column-option.entry.js +2 -2
- package/dist/esm/ion-popover.entry.js +2 -2
- package/dist/esm/ion-progress-bar.entry.js +1 -1
- package/dist/esm/ion-radio_2.entry.js +5 -5
- package/dist/esm/ion-range.entry.js +3 -3
- package/dist/esm/ion-refresher_2.entry.js +3 -3
- package/dist/esm/ion-reorder_2.entry.js +3 -3
- package/dist/esm/ion-ripple-effect.entry.js +1 -1
- package/dist/esm/ion-route_4.entry.js +2 -2
- package/dist/esm/ion-searchbar.entry.js +4 -4
- package/dist/esm/ion-segment-content.entry.js +1 -1
- package/dist/esm/ion-segment-view.entry.js +2 -2
- package/dist/esm/ion-segment_2.entry.js +4 -4
- package/dist/esm/ion-select-modal.entry.js +1 -1
- package/dist/esm/ion-select_3.entry.js +6 -6
- package/dist/esm/ion-spinner.entry.js +1 -1
- package/dist/esm/ion-split-pane.entry.js +2 -2
- package/dist/esm/ion-tab-bar_2.entry.js +4 -4
- package/dist/esm/ion-tab_2.entry.js +3 -3
- package/dist/esm/ion-text.entry.js +2 -2
- package/dist/esm/ion-textarea.entry.js +3 -3
- package/dist/esm/ion-toast.entry.js +2 -2
- package/dist/esm/ion-toggle.entry.js +3 -3
- package/dist/esm/ionic.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/html.html-data.json +45 -9
- package/dist/ionic/ionic.esm.js +1 -1
- package/dist/ionic/{p-f7ca50a5.entry.js → p-0592c549.entry.js} +1 -1
- package/dist/ionic/{p-67c2d349.entry.js → p-0aa510cd.entry.js} +1 -1
- package/dist/ionic/{p-9ccfb733.entry.js → p-0cd5fd9d.entry.js} +1 -1
- package/dist/ionic/{p-bf0c5a8d.entry.js → p-0e9d4e11.entry.js} +1 -1
- package/dist/ionic/{p-497f6391.entry.js → p-11a38333.entry.js} +1 -1
- package/dist/ionic/{p-0030507d.entry.js → p-1a009a51.entry.js} +1 -1
- package/dist/ionic/{p-7186786e.entry.js → p-23e524f8.entry.js} +1 -1
- package/dist/ionic/{p-1439fecb.entry.js → p-2826761a.entry.js} +1 -1
- package/dist/ionic/{p-93315d96.entry.js → p-2c4170d8.entry.js} +1 -1
- package/dist/ionic/p-2d5a2511.entry.js +4 -0
- package/dist/ionic/{p-7f294078.entry.js → p-3706ea52.entry.js} +1 -1
- package/dist/ionic/{p-b69add0e.entry.js → p-3e376501.entry.js} +1 -1
- package/dist/ionic/{p-c684a3b6.entry.js → p-44597202.entry.js} +1 -1
- package/dist/ionic/{p-8458f1b6.entry.js → p-4a27a79a.entry.js} +1 -1
- package/dist/ionic/{p-b7235e85.entry.js → p-4f07113d.entry.js} +1 -1
- package/dist/ionic/{p-88e7f52a.entry.js → p-52b85650.entry.js} +1 -1
- package/dist/ionic/{p-199bffb3.entry.js → p-5a6e0ae1.entry.js} +1 -1
- package/dist/ionic/p-6906dca7.entry.js +4 -0
- package/dist/ionic/{p-19a1ff9a.entry.js → p-7b09c19d.entry.js} +1 -1
- package/dist/ionic/{p-76c70824.entry.js → p-7b886782.entry.js} +1 -1
- package/dist/ionic/{p-89eab395.entry.js → p-82c05be2.entry.js} +1 -1
- package/dist/ionic/{p-b653f4c2.entry.js → p-83c0eb9b.entry.js} +1 -1
- package/dist/ionic/{p-b4fd91b8.entry.js → p-85ff1314.entry.js} +1 -1
- package/dist/ionic/{p-3f18dfe9.entry.js → p-8eca5ba1.entry.js} +1 -1
- package/dist/ionic/{p-f08edb25.entry.js → p-96f52444.entry.js} +1 -1
- package/dist/ionic/{p-f167c55c.entry.js → p-a3b047e0.entry.js} +1 -1
- package/dist/ionic/{p-40d9e029.entry.js → p-a73caa5e.entry.js} +1 -1
- package/dist/ionic/{p-1ad16c09.entry.js → p-b0dfd018.entry.js} +1 -1
- package/dist/ionic/{p-a3f9be52.entry.js → p-b6130fe4.entry.js} +1 -1
- package/dist/ionic/{p-084c2623.entry.js → p-c5f745b4.entry.js} +1 -1
- package/dist/ionic/{p-52ed96a8.entry.js → p-c781241c.entry.js} +1 -1
- package/dist/ionic/p-cb154afe.entry.js +4 -0
- package/dist/ionic/{p-031df892.entry.js → p-cde69f38.entry.js} +1 -1
- package/dist/ionic/p-d6f0a698.entry.js +4 -0
- package/dist/ionic/{p-dd2981d0.entry.js → p-d9804d04.entry.js} +1 -1
- package/dist/ionic/{p-7054a1b9.entry.js → p-e342b205.entry.js} +1 -1
- package/dist/ionic/p-e4071bf8.entry.js +4 -0
- package/dist/ionic/{p-9dfbe98d.entry.js → p-e8916b04.entry.js} +1 -1
- package/dist/ionic/{p-dac1d4de.entry.js → p-f10f8f95.entry.js} +1 -1
- package/dist/ionic/p-fdcbe59a.entry.js +4 -0
- package/dist/types/components/footer/footer.d.ts +2 -12
- package/dist/types/components/footer/footer.utils.d.ts +0 -1
- package/dist/types/components/gallery/gallery.d.ts +33 -8
- package/dist/types/components/gallery/test/utils.d.ts +1 -1
- package/dist/types/components/gallery-item/gallery-item.d.ts +35 -0
- package/dist/types/components/header/header.d.ts +3 -10
- package/dist/types/components/header/header.utils.d.ts +0 -1
- package/dist/types/components.d.ts +41 -12
- package/dist/types/utils/css-value-validation.d.ts +9 -0
- package/hydrate/index.js +334 -421
- package/hydrate/index.mjs +334 -421
- package/package.json +1 -1
- package/components/p-BF5oFX1I.js +0 -4
- package/components/p-CpFORZud.js +0 -4
- package/components/p-GElQZ38c.js +0 -4
- package/components/p-d77Zk1DK.js +0 -4
- package/components/p-hdGd8ben.js +0 -4
- package/dist/collection/utils/on-scroll/collapse-hide.utils.js +0 -168
- package/dist/ionic/p-04b5794c.entry.js +0 -4
- package/dist/ionic/p-2aa7567e.entry.js +0 -4
- package/dist/ionic/p-44d483c2.entry.js +0 -4
- package/dist/ionic/p-ad4d0138.entry.js +0 -4
- package/dist/ionic/p-ff09d2a5.entry.js +0 -4
- package/dist/types/utils/on-scroll/collapse-hide.utils.d.ts +0 -26
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* (C) Ionic http://ionicframework.com - MIT License
|
|
3
|
+
*/
|
|
4
|
+
import { Host, h } from "@stencil/core";
|
|
5
|
+
import { printIonWarning } from "../../utils/logging/index";
|
|
6
|
+
import { getIonTheme } from "../../global/ionic-global";
|
|
7
|
+
/**
|
|
8
|
+
* @virtualProp {"ios" | "md"} mode - The mode determines the platform behaviors of the component.
|
|
9
|
+
* @virtualProp {"ios" | "md" | "ionic"} theme - The theme determines the visual appearance of the component.
|
|
10
|
+
*
|
|
11
|
+
* @slot - The content placed inside of the gallery item. This is typically an
|
|
12
|
+
* `img`, but can be any element (e.g. a `figure` wrapping an image and caption).
|
|
13
|
+
*/
|
|
14
|
+
export class GalleryItem {
|
|
15
|
+
constructor() {
|
|
16
|
+
this.hasWarnedInvalidParent = false;
|
|
17
|
+
this.onSlotChange = () => {
|
|
18
|
+
this.warnInvalidParent();
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
componentWillLoad() {
|
|
22
|
+
var _a;
|
|
23
|
+
this.galleryEl = (_a = this.el.closest('ion-gallery')) !== null && _a !== void 0 ? _a : undefined;
|
|
24
|
+
this.syncLayoutClasses();
|
|
25
|
+
}
|
|
26
|
+
componentDidLoad() {
|
|
27
|
+
this.watchGalleryLayoutClasses();
|
|
28
|
+
this.warnInvalidParent();
|
|
29
|
+
}
|
|
30
|
+
disconnectedCallback() {
|
|
31
|
+
var _a;
|
|
32
|
+
(_a = this.galleryClassObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
33
|
+
this.galleryClassObserver = undefined;
|
|
34
|
+
this.galleryEl = undefined;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Warn when the item is not a descendant of an `ion-gallery`.
|
|
38
|
+
*/
|
|
39
|
+
warnInvalidParent() {
|
|
40
|
+
if (this.hasWarnedInvalidParent || this.galleryEl !== undefined) {
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
printIonWarning('[ion-gallery-item] - This component should be used as a child of an "ion-gallery" component.', this.el);
|
|
44
|
+
this.hasWarnedInvalidParent = true;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Watch the parent gallery's class list so the item can react to layout
|
|
48
|
+
* changes (the gallery reflects its layout as a `gallery-layout-*` class).
|
|
49
|
+
*/
|
|
50
|
+
watchGalleryLayoutClasses() {
|
|
51
|
+
var _a;
|
|
52
|
+
const galleryEl = this.galleryEl;
|
|
53
|
+
if (galleryEl === undefined) {
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
(_a = this.galleryClassObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
57
|
+
this.galleryClassObserver = new MutationObserver(() => this.syncLayoutClasses());
|
|
58
|
+
this.galleryClassObserver.observe(galleryEl, {
|
|
59
|
+
attributes: true,
|
|
60
|
+
attributeFilter: ['class'],
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
syncLayoutClasses() {
|
|
64
|
+
var _a;
|
|
65
|
+
const layout = (_a = this.galleryEl) === null || _a === void 0 ? void 0 : _a.layout;
|
|
66
|
+
this.galleryLayout = layout === 'masonry' || layout === 'uniform' ? layout : undefined;
|
|
67
|
+
}
|
|
68
|
+
render() {
|
|
69
|
+
const { galleryLayout } = this;
|
|
70
|
+
const theme = getIonTheme(this);
|
|
71
|
+
return (h(Host, { key: 'b3de6bf2df4af01ed274188a96d9e8cd82c9f5cd', class: {
|
|
72
|
+
[theme]: true,
|
|
73
|
+
'in-gallery-layout-uniform': galleryLayout === 'uniform',
|
|
74
|
+
'in-gallery-layout-masonry': galleryLayout === 'masonry',
|
|
75
|
+
} }, h("slot", { key: '5bef4549c5101178fec9b590cb6b553ddc5376c4', onSlotchange: this.onSlotChange })));
|
|
76
|
+
}
|
|
77
|
+
static get is() { return "ion-gallery-item"; }
|
|
78
|
+
static get encapsulation() { return "shadow"; }
|
|
79
|
+
static get originalStyleUrls() {
|
|
80
|
+
return {
|
|
81
|
+
"$": ["gallery-item.scss"]
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
static get styleUrls() {
|
|
85
|
+
return {
|
|
86
|
+
"$": ["gallery-item.css"]
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
static get states() {
|
|
90
|
+
return {
|
|
91
|
+
"galleryLayout": {}
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
static get elementRef() { return "el"; }
|
|
95
|
+
}
|
|
@@ -16,10 +16,10 @@ export class Grid {
|
|
|
16
16
|
}
|
|
17
17
|
render() {
|
|
18
18
|
const theme = getIonTheme(this);
|
|
19
|
-
return (h(Host, { key: '
|
|
19
|
+
return (h(Host, { key: 'e3320fc2fc5391d26898cc119505cd3be30dd48b', class: {
|
|
20
20
|
[theme]: true,
|
|
21
21
|
'grid-fixed': this.fixed,
|
|
22
|
-
} }, h("slot", { key: '
|
|
22
|
+
} }, h("slot", { key: '2000e6b336c294aadf4585269c301d734d2fe478' })));
|
|
23
23
|
}
|
|
24
24
|
static get is() { return "ion-grid"; }
|
|
25
25
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1,64 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Convert a pixels given value into rem
|
|
3
|
-
*
|
|
4
|
-
* @param pixels - Value in pixels to be converted (i.e. px)
|
|
5
|
-
* @param context (optional) - Baseline value
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* Convert a font size to a dynamic font size.
|
|
9
|
-
* Fonts that participate in Dynamic Type should use
|
|
10
|
-
* dynamic font sizes.
|
|
11
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
12
|
-
* @param unit (optional) - The unit to convert to. Use this if you want to
|
|
13
|
-
* convert to a unit other than $baselineUnit.
|
|
14
|
-
*/
|
|
15
|
-
/**
|
|
16
|
-
* Convert a font size to a dynamic font size but impose
|
|
17
|
-
* a maximum font size.
|
|
18
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
19
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
20
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
21
|
-
* convert to a unit other than $baselineUnit.
|
|
22
|
-
*/
|
|
23
|
-
/**
|
|
24
|
-
* Convert a font size to a dynamic font size but impose
|
|
25
|
-
* a minimum font size.
|
|
26
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
27
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
28
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
29
|
-
* convert to a unit other than $baselineUnit.
|
|
30
|
-
*/
|
|
31
|
-
/**
|
|
32
|
-
* Convert a font size to a dynamic font size but impose
|
|
33
|
-
* maximum and minimum font sizes.
|
|
34
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
35
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
36
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
37
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
38
|
-
* convert to a unit other than $baselineUnit.
|
|
39
|
-
*/
|
|
40
|
-
/**
|
|
41
|
-
* A heuristic that applies CSS to tablet
|
|
42
|
-
* viewports.
|
|
43
|
-
*
|
|
44
|
-
* Usage:
|
|
45
|
-
* @include tablet-viewport() {
|
|
46
|
-
* :host {
|
|
47
|
-
* background-color: green;
|
|
48
|
-
* }
|
|
49
|
-
* }
|
|
50
|
-
*/
|
|
51
|
-
/**
|
|
52
|
-
* A heuristic that applies CSS to mobile
|
|
53
|
-
* viewports (i.e. phones, not tablets).
|
|
54
|
-
*
|
|
55
|
-
* Usage:
|
|
56
|
-
* @include mobile-viewport() {
|
|
57
|
-
* :host {
|
|
58
|
-
* background-color: blue;
|
|
59
|
-
* }
|
|
60
|
-
* }
|
|
61
|
-
*/
|
|
62
1
|
ion-header {
|
|
63
2
|
display: block;
|
|
64
3
|
position: relative;
|
|
@@ -70,20 +9,6 @@ ion-header ion-toolbar:first-of-type {
|
|
|
70
9
|
padding-top: var(--ion-safe-area-top, 0);
|
|
71
10
|
}
|
|
72
11
|
|
|
73
|
-
ion-header.header-collapse-hide {
|
|
74
|
-
transform: translateY(0);
|
|
75
|
-
transition: transform 300ms cubic-bezier(0, 0, 0.2, 1), opacity 300ms cubic-bezier(0, 0, 0.2, 1);
|
|
76
|
-
opacity: 1;
|
|
77
|
-
z-index: 10;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
ion-header.header-collapse-hide.header-collapse-hide-hidden {
|
|
81
|
-
transform: translateY(calc(-1 * var(--header-hide-slide-y, 0px)));
|
|
82
|
-
pointer-events: none;
|
|
83
|
-
transition: transform 200ms cubic-bezier(0.4, 0, 1, 1), opacity 300ms cubic-bezier(0.4, 0, 1, 1);
|
|
84
|
-
opacity: 0;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
12
|
/**
|
|
88
13
|
* A heuristic that applies CSS to tablet
|
|
89
14
|
* viewports.
|
|
@@ -1,64 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Convert a pixels given value into rem
|
|
3
|
-
*
|
|
4
|
-
* @param pixels - Value in pixels to be converted (i.e. px)
|
|
5
|
-
* @param context (optional) - Baseline value
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* Convert a font size to a dynamic font size.
|
|
9
|
-
* Fonts that participate in Dynamic Type should use
|
|
10
|
-
* dynamic font sizes.
|
|
11
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
12
|
-
* @param unit (optional) - The unit to convert to. Use this if you want to
|
|
13
|
-
* convert to a unit other than $baselineUnit.
|
|
14
|
-
*/
|
|
15
|
-
/**
|
|
16
|
-
* Convert a font size to a dynamic font size but impose
|
|
17
|
-
* a maximum font size.
|
|
18
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
19
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
20
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
21
|
-
* convert to a unit other than $baselineUnit.
|
|
22
|
-
*/
|
|
23
|
-
/**
|
|
24
|
-
* Convert a font size to a dynamic font size but impose
|
|
25
|
-
* a minimum font size.
|
|
26
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
27
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
28
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
29
|
-
* convert to a unit other than $baselineUnit.
|
|
30
|
-
*/
|
|
31
|
-
/**
|
|
32
|
-
* Convert a font size to a dynamic font size but impose
|
|
33
|
-
* maximum and minimum font sizes.
|
|
34
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
35
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
36
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
37
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
38
|
-
* convert to a unit other than $baselineUnit.
|
|
39
|
-
*/
|
|
40
|
-
/**
|
|
41
|
-
* A heuristic that applies CSS to tablet
|
|
42
|
-
* viewports.
|
|
43
|
-
*
|
|
44
|
-
* Usage:
|
|
45
|
-
* @include tablet-viewport() {
|
|
46
|
-
* :host {
|
|
47
|
-
* background-color: green;
|
|
48
|
-
* }
|
|
49
|
-
* }
|
|
50
|
-
*/
|
|
51
|
-
/**
|
|
52
|
-
* A heuristic that applies CSS to mobile
|
|
53
|
-
* viewports (i.e. phones, not tablets).
|
|
54
|
-
*
|
|
55
|
-
* Usage:
|
|
56
|
-
* @include mobile-viewport() {
|
|
57
|
-
* :host {
|
|
58
|
-
* background-color: blue;
|
|
59
|
-
* }
|
|
60
|
-
* }
|
|
61
|
-
*/
|
|
62
1
|
ion-header {
|
|
63
2
|
display: block;
|
|
64
3
|
position: relative;
|
|
@@ -70,20 +9,6 @@ ion-header ion-toolbar:first-of-type {
|
|
|
70
9
|
padding-top: var(--ion-safe-area-top, 0);
|
|
71
10
|
}
|
|
72
11
|
|
|
73
|
-
ion-header.header-collapse-hide {
|
|
74
|
-
transform: translateY(0);
|
|
75
|
-
transition: transform 300ms cubic-bezier(0, 0, 0.2, 1), opacity 300ms cubic-bezier(0, 0, 0.2, 1);
|
|
76
|
-
opacity: 1;
|
|
77
|
-
z-index: 10;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
ion-header.header-collapse-hide.header-collapse-hide-hidden {
|
|
81
|
-
transform: translateY(calc(-1 * var(--header-hide-slide-y, 0px)));
|
|
82
|
-
pointer-events: none;
|
|
83
|
-
transition: transform 200ms cubic-bezier(0.4, 0, 1, 1), opacity 300ms cubic-bezier(0.4, 0, 1, 1);
|
|
84
|
-
opacity: 0;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
12
|
/**
|
|
88
13
|
* Convert a pixels given value into rem
|
|
89
14
|
*
|
|
@@ -7,7 +7,7 @@ import { inheritAriaAttributes } from "../../utils/helpers";
|
|
|
7
7
|
import { hostContext } from "../../utils/theme";
|
|
8
8
|
import { config } from "../../global/config";
|
|
9
9
|
import { getIonTheme } from "../../global/ionic-global";
|
|
10
|
-
import { cloneElement,
|
|
10
|
+
import { cloneElement, createHeaderIndex, handleContentScroll, handleHeaderFade, handleToolbarIntersection, setHeaderActive, setToolbarBackgroundOpacity, getRoleType, } from "./header.utils";
|
|
11
11
|
/**
|
|
12
12
|
* @virtualProp {"ios" | "md"} mode - The mode determines the platform behaviors of the component.
|
|
13
13
|
* @virtualProp {"ios" | "md" | "ionic"} theme - The theme determines the visual appearance of the component.
|
|
@@ -15,7 +15,6 @@ import { cloneElement, createHeaderHideInteraction, createHeaderIndex, handleCon
|
|
|
15
15
|
export class Header {
|
|
16
16
|
constructor() {
|
|
17
17
|
this.inheritedAttributes = {};
|
|
18
|
-
this.didLoad = false;
|
|
19
18
|
/**
|
|
20
19
|
* If `true`, the header will have a line at the bottom.
|
|
21
20
|
* TODO(ROU-10855): add support for this prop on ios/md themes
|
|
@@ -46,37 +45,25 @@ export class Header {
|
|
|
46
45
|
this.inheritedAttributes = inheritAriaAttributes(this.el);
|
|
47
46
|
}
|
|
48
47
|
componentDidLoad() {
|
|
49
|
-
this.didLoad = true;
|
|
50
48
|
this.checkCollapsibleHeader();
|
|
51
49
|
}
|
|
52
50
|
componentDidUpdate() {
|
|
53
51
|
this.checkCollapsibleHeader();
|
|
54
52
|
}
|
|
55
|
-
connectedCallback() {
|
|
56
|
-
// On re-attach (didLoad already true but disconnectedCallback ran since),
|
|
57
|
-
// componentDidLoad will not fire again — re-run setup here.
|
|
58
|
-
if (this.didLoad) {
|
|
59
|
-
this.checkCollapsibleHeader();
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
53
|
disconnectedCallback() {
|
|
63
54
|
this.destroyCollapsibleHeader();
|
|
64
55
|
}
|
|
65
56
|
async checkCollapsibleHeader() {
|
|
66
57
|
const theme = getIonTheme(this);
|
|
58
|
+
if (theme !== 'ios') {
|
|
59
|
+
return;
|
|
60
|
+
}
|
|
67
61
|
const { collapse } = this;
|
|
68
62
|
const hasCondense = collapse === 'condense';
|
|
69
63
|
const hasFade = collapse === 'fade';
|
|
70
|
-
const hasHide = collapse === 'hide';
|
|
71
|
-
const runIosCollapse = theme === 'ios' && (hasCondense || hasFade);
|
|
72
|
-
const runHide = hasHide;
|
|
73
|
-
if (!runIosCollapse && !runHide) {
|
|
74
|
-
this.destroyCollapsibleHeader();
|
|
75
|
-
return;
|
|
76
|
-
}
|
|
77
64
|
this.destroyCollapsibleHeader();
|
|
78
65
|
const appRootSelector = config.get('appRootSelector', 'ion-app');
|
|
79
|
-
if (
|
|
66
|
+
if (hasCondense) {
|
|
80
67
|
const pageEl = this.el.closest(`${appRootSelector},ion-page,.ion-page,page-inner`);
|
|
81
68
|
const contentEl = pageEl ? findIonContent(pageEl) : null;
|
|
82
69
|
// Cloned elements are always needed in iOS transition
|
|
@@ -87,7 +74,7 @@ export class Header {
|
|
|
87
74
|
});
|
|
88
75
|
await this.setupCondenseHeader(contentEl, pageEl);
|
|
89
76
|
}
|
|
90
|
-
else if (
|
|
77
|
+
else if (hasFade) {
|
|
91
78
|
const pageEl = this.el.closest(`${appRootSelector},ion-page,.ion-page,page-inner`);
|
|
92
79
|
const contentEl = pageEl ? findIonContent(pageEl) : null;
|
|
93
80
|
if (!contentEl) {
|
|
@@ -97,29 +84,12 @@ export class Header {
|
|
|
97
84
|
const condenseHeader = contentEl.querySelector('ion-header[collapse="condense"]');
|
|
98
85
|
await this.setupFadeHeader(contentEl, condenseHeader);
|
|
99
86
|
}
|
|
100
|
-
if (runHide) {
|
|
101
|
-
const pageEl = this.el.closest(`${appRootSelector},ion-page,.ion-page,page-inner`);
|
|
102
|
-
const contentEl = pageEl ? findIonContent(pageEl) : null;
|
|
103
|
-
if (!contentEl) {
|
|
104
|
-
printIonContentErrorMsg(this.el);
|
|
105
|
-
return;
|
|
106
|
-
}
|
|
107
|
-
await this.setupHideHeader(contentEl);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
async setupHideHeader(contentEl) {
|
|
111
|
-
const scrollEl = (this.scrollEl = await getScrollElement(contentEl));
|
|
112
|
-
this.headerHideCleanup = createHeaderHideInteraction(this.el, scrollEl);
|
|
113
87
|
}
|
|
114
88
|
destroyCollapsibleHeader() {
|
|
115
89
|
if (this.intersectionObserver) {
|
|
116
90
|
this.intersectionObserver.disconnect();
|
|
117
91
|
this.intersectionObserver = undefined;
|
|
118
92
|
}
|
|
119
|
-
if (this.headerHideCleanup) {
|
|
120
|
-
this.headerHideCleanup();
|
|
121
|
-
this.headerHideCleanup = undefined;
|
|
122
|
-
}
|
|
123
93
|
if (this.scrollEl && this.contentScrollCallback) {
|
|
124
94
|
this.scrollEl.removeEventListener('scroll', this.contentScrollCallback);
|
|
125
95
|
this.contentScrollCallback = undefined;
|
|
@@ -186,7 +156,7 @@ export class Header {
|
|
|
186
156
|
const isCondensed = collapse === 'condense';
|
|
187
157
|
// banner role must be at top level, so remove role if inside a menu
|
|
188
158
|
const roleType = getRoleType(hostContext('ion-menu', this.el), isCondensed, theme);
|
|
189
|
-
return (h(Host, Object.assign({ key: '
|
|
159
|
+
return (h(Host, Object.assign({ key: '3395dedfd5165ba6e9f3ad1a25f0bb5b3678704a', role: roleType, class: {
|
|
190
160
|
[theme]: true,
|
|
191
161
|
// Used internally for styling
|
|
192
162
|
[`header-${theme}`]: true,
|
|
@@ -194,7 +164,7 @@ export class Header {
|
|
|
194
164
|
[`header-collapse-${collapse}`]: true,
|
|
195
165
|
[`header-translucent-${theme}`]: this.translucent,
|
|
196
166
|
['header-divider']: divider,
|
|
197
|
-
} }, inheritedAttributes), theme !== 'md' && translucent && h("div", { key: '
|
|
167
|
+
} }, inheritedAttributes), theme !== 'md' && translucent && h("div", { key: 'cafeb88b6e73d64b264514ea46590fd3477b3052', class: "header-background" }), h("slot", { key: 'ad681aaf866d7e7a5e5e731c0b5d6f5cc9fe94d2' })));
|
|
198
168
|
}
|
|
199
169
|
static get is() { return "ion-header"; }
|
|
200
170
|
static get originalStyleUrls() {
|
|
@@ -217,15 +187,15 @@ export class Header {
|
|
|
217
187
|
"type": "string",
|
|
218
188
|
"mutable": false,
|
|
219
189
|
"complexType": {
|
|
220
|
-
"original": "'condense' | 'fade'
|
|
221
|
-
"resolved": "\"condense\" | \"fade\" |
|
|
190
|
+
"original": "'condense' | 'fade'",
|
|
191
|
+
"resolved": "\"condense\" | \"fade\" | undefined",
|
|
222
192
|
"references": {}
|
|
223
193
|
},
|
|
224
194
|
"required": false,
|
|
225
195
|
"optional": true,
|
|
226
196
|
"docs": {
|
|
227
197
|
"tags": [],
|
|
228
|
-
"text": "Describes the scroll effect that will be applied to the header.\
|
|
198
|
+
"text": "Describes the scroll effect that will be applied to the header.\nOnly applies when the theme is `\"ios\"`.\n\nTypically used for [Collapsible Large Titles](https://ionicframework.com/docs/api/title#collapsible-large-titles)"
|
|
229
199
|
},
|
|
230
200
|
"getter": false,
|
|
231
201
|
"setter": false,
|
|
@@ -1,64 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Convert a pixels given value into rem
|
|
3
|
-
*
|
|
4
|
-
* @param pixels - Value in pixels to be converted (i.e. px)
|
|
5
|
-
* @param context (optional) - Baseline value
|
|
6
|
-
*/
|
|
7
|
-
/**
|
|
8
|
-
* Convert a font size to a dynamic font size.
|
|
9
|
-
* Fonts that participate in Dynamic Type should use
|
|
10
|
-
* dynamic font sizes.
|
|
11
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
12
|
-
* @param unit (optional) - The unit to convert to. Use this if you want to
|
|
13
|
-
* convert to a unit other than $baselineUnit.
|
|
14
|
-
*/
|
|
15
|
-
/**
|
|
16
|
-
* Convert a font size to a dynamic font size but impose
|
|
17
|
-
* a maximum font size.
|
|
18
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
19
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
20
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
21
|
-
* convert to a unit other than $baselineUnit.
|
|
22
|
-
*/
|
|
23
|
-
/**
|
|
24
|
-
* Convert a font size to a dynamic font size but impose
|
|
25
|
-
* a minimum font size.
|
|
26
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
27
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
28
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
29
|
-
* convert to a unit other than $baselineUnit.
|
|
30
|
-
*/
|
|
31
|
-
/**
|
|
32
|
-
* Convert a font size to a dynamic font size but impose
|
|
33
|
-
* maximum and minimum font sizes.
|
|
34
|
-
* @param size - The initial font size including the unit (i.e. px or pt)
|
|
35
|
-
* @param minScale - The minimum scale of the font (i.e. 0.8 for a minimum 80% scale).
|
|
36
|
-
* @param maxScale - The maximum scale of the font (i.e. 2.5 for a maximum 250% scale).
|
|
37
|
-
* @param unit (optional) - The unit to convert the initial font size to. Use this if you want to
|
|
38
|
-
* convert to a unit other than $baselineUnit.
|
|
39
|
-
*/
|
|
40
|
-
/**
|
|
41
|
-
* A heuristic that applies CSS to tablet
|
|
42
|
-
* viewports.
|
|
43
|
-
*
|
|
44
|
-
* Usage:
|
|
45
|
-
* @include tablet-viewport() {
|
|
46
|
-
* :host {
|
|
47
|
-
* background-color: green;
|
|
48
|
-
* }
|
|
49
|
-
* }
|
|
50
|
-
*/
|
|
51
|
-
/**
|
|
52
|
-
* A heuristic that applies CSS to mobile
|
|
53
|
-
* viewports (i.e. phones, not tablets).
|
|
54
|
-
*
|
|
55
|
-
* Usage:
|
|
56
|
-
* @include mobile-viewport() {
|
|
57
|
-
* :host {
|
|
58
|
-
* background-color: blue;
|
|
59
|
-
* }
|
|
60
|
-
* }
|
|
61
|
-
*/
|
|
62
1
|
ion-header {
|
|
63
2
|
display: block;
|
|
64
3
|
position: relative;
|
|
@@ -70,20 +9,6 @@ ion-header ion-toolbar:first-of-type {
|
|
|
70
9
|
padding-top: var(--ion-safe-area-top, 0);
|
|
71
10
|
}
|
|
72
11
|
|
|
73
|
-
ion-header.header-collapse-hide {
|
|
74
|
-
transform: translateY(0);
|
|
75
|
-
transition: transform 300ms cubic-bezier(0, 0, 0.2, 1), opacity 300ms cubic-bezier(0, 0, 0.2, 1);
|
|
76
|
-
opacity: 1;
|
|
77
|
-
z-index: 10;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
ion-header.header-collapse-hide.header-collapse-hide-hidden {
|
|
81
|
-
transform: translateY(calc(-1 * var(--header-hide-slide-y, 0px)));
|
|
82
|
-
pointer-events: none;
|
|
83
|
-
transition: transform 200ms cubic-bezier(0.4, 0, 1, 1), opacity 300ms cubic-bezier(0.4, 0, 1, 1);
|
|
84
|
-
opacity: 0;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
12
|
/**
|
|
88
13
|
* Convert a pixels given value into rem
|
|
89
14
|
*
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import { readTask, writeTask } from "@stencil/core";
|
|
5
5
|
import { clamp } from "../../utils/helpers";
|
|
6
|
-
import { createCollapseHideInteraction } from "../../utils/on-scroll/collapse-hide.utils";
|
|
7
6
|
const TRANSITION = 'all 0.2s ease-in-out';
|
|
8
7
|
const ROLE_NONE = 'none';
|
|
9
8
|
const ROLE_BANNER = 'banner';
|
|
@@ -180,14 +179,6 @@ export const scaleLargeTitles = (toolbars = [], scale = 1, transition = false) =
|
|
|
180
179
|
titleDiv.style.transform = `scale3d(${scale}, ${scale}, 1)`;
|
|
181
180
|
});
|
|
182
181
|
};
|
|
183
|
-
export const createHeaderHideInteraction = (headerEl, scrollEl) => createCollapseHideInteraction({
|
|
184
|
-
regionEl: headerEl,
|
|
185
|
-
scrollEl,
|
|
186
|
-
slideCssVar: '--header-hide-slide-y',
|
|
187
|
-
contentPartnerClass: 'content-header-hide-scroll-partner',
|
|
188
|
-
contentHiddenClass: 'content-header-hide-scroll-hidden',
|
|
189
|
-
regionHiddenClass: 'header-collapse-hide-hidden',
|
|
190
|
-
});
|
|
191
182
|
export const handleHeaderFade = (scrollEl, baseEl, condenseHeader) => {
|
|
192
183
|
readTask(() => {
|
|
193
184
|
const scrollTop = scrollEl.scrollTop;
|
|
@@ -80,9 +80,9 @@ export class Img {
|
|
|
80
80
|
const { loadSrc, alt, onLoad, loadError, inheritedAttributes } = this;
|
|
81
81
|
const { draggable } = inheritedAttributes;
|
|
82
82
|
const theme = getIonTheme(this);
|
|
83
|
-
return (h(Host, { key: '
|
|
83
|
+
return (h(Host, { key: 'ba84621055567b2a35387709d9d89b97ad853274', class: {
|
|
84
84
|
[theme]: true,
|
|
85
|
-
} }, h("img", { key: '
|
|
85
|
+
} }, h("img", { key: '9d6118bbf69e2cccbb0603802c03b9a0d101e2c3', decoding: "async", src: loadSrc, alt: alt, onLoad: onLoad, onError: loadError, part: "image", draggable: isDraggable(draggable) })));
|
|
86
86
|
}
|
|
87
87
|
static get is() { return "ion-img"; }
|
|
88
88
|
static get encapsulation() { return "shadow"; }
|
|
@@ -264,7 +264,7 @@ export class InfiniteScroll {
|
|
|
264
264
|
render() {
|
|
265
265
|
const theme = getIonTheme(this);
|
|
266
266
|
const disabled = this.disabled;
|
|
267
|
-
return (h(Host, { key: '
|
|
267
|
+
return (h(Host, { key: 'e3a3cde079dfd6f07e565eb462765df757cbb128', class: {
|
|
268
268
|
[theme]: true,
|
|
269
269
|
'infinite-scroll-loading': this.isLoading,
|
|
270
270
|
'infinite-scroll-enabled': !disabled,
|
|
@@ -29,11 +29,11 @@ export class InfiniteScrollContent {
|
|
|
29
29
|
}
|
|
30
30
|
render() {
|
|
31
31
|
const theme = getIonTheme(this);
|
|
32
|
-
return (h(Host, { key: '
|
|
32
|
+
return (h(Host, { key: '263a27297159ced042f7552a1e14b8c6aba62fa8', class: {
|
|
33
33
|
[theme]: true,
|
|
34
34
|
// Used internally for styling
|
|
35
35
|
[`infinite-scroll-content-${theme}`]: true,
|
|
36
|
-
} }, h("div", { key: '
|
|
36
|
+
} }, h("div", { key: 'ee38d3c52df9dc5de186406b3087f20917a17252', class: "infinite-loading" }, this.loadingSpinner && (h("div", { key: 'e2348727f79a26f52f42641d4334a0ba9d4aa03e', class: "infinite-loading-spinner" }, h("ion-spinner", { key: '41be6f2747f3af5f46c8738e2ef56083ecd95e99', name: this.loadingSpinner }))), this.loadingText !== undefined && this.renderLoadingText())));
|
|
37
37
|
}
|
|
38
38
|
static get is() { return "ion-infinite-scroll-content"; }
|
|
39
39
|
static get originalStyleUrls() {
|
|
@@ -617,7 +617,7 @@ export class Input {
|
|
|
617
617
|
* TODO(FW-5592): Remove hasStartEndSlots condition
|
|
618
618
|
*/
|
|
619
619
|
const labelShouldFloat = labelPlacement === 'stacked' || (labelPlacement === 'floating' && (hasValue || hasFocus || hasStartEndSlots));
|
|
620
|
-
return (h(Host, { key: '
|
|
620
|
+
return (h(Host, { key: '3da29d837b5abe22de740ac96c8142422fce537a', class: createColorClasses(this.color, {
|
|
621
621
|
[theme]: true,
|
|
622
622
|
'has-value': hasValue,
|
|
623
623
|
'has-focus': hasFocus,
|
|
@@ -630,7 +630,7 @@ export class Input {
|
|
|
630
630
|
'in-item-color': hostContext('ion-item.ion-color', this.el),
|
|
631
631
|
'input-disabled': disabled,
|
|
632
632
|
'input-readonly': readonly,
|
|
633
|
-
}) }, h("label", { key: '
|
|
633
|
+
}) }, h("label", { key: '142a8230382a05938887e9c0790832218ac37697', class: "input-wrapper", htmlFor: inputId, onClick: this.onLabelClick }, this.renderLabelContainer(), h("div", { key: '953f247ea2f40545e01e0346549d9b7aa344b720', class: "native-wrapper", onClick: this.onLabelClick },
|
|
634
634
|
/**
|
|
635
635
|
* For the ionic theme, we render the outline container here
|
|
636
636
|
* instead of higher up, so it can be positioned relative to
|
|
@@ -640,14 +640,14 @@ export class Input {
|
|
|
640
640
|
* <label> element, ensuring that clicking the label text
|
|
641
641
|
* focuses the input.
|
|
642
642
|
*/
|
|
643
|
-
theme === 'ionic' && h("div", { key: '
|
|
643
|
+
theme === 'ionic' && h("div", { key: 'fd09b37c6a798900c5074e7cbe2e790ea050c29d', class: "input-outline" }), h("slot", { key: '3eef4c4748104d8722f3254a04ff88e2b70c560e', name: "start" }), h("input", Object.assign({ key: '012a3fa52e19422d7fbc227845e9771c7d8fbe4a', class: "native-input", ref: (input) => (this.nativeInput = input), id: inputId, disabled: disabled, autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, enterKeyHint: this.enterkeyhint, inputMode: this.inputmode, min: this.min, max: this.max, minLength: this.minlength, maxLength: this.maxlength, multiple: this.multiple, name: this.name, pattern: this.pattern, placeholder: this.placeholder || '', readOnly: readonly, required: this.required, spellcheck: this.spellcheck, step: this.step, type: this.type, value: value, onInput: this.onInput, onChange: this.onChange, onBlur: this.onBlur, onFocus: this.onFocus, onKeyDown: this.onKeydown, onCompositionstart: this.onCompositionStart, onCompositionend: this.onCompositionEnd, "aria-describedby": this.getHintTextID(), "aria-invalid": this.isInvalid ? 'true' : undefined, "aria-labelledby": this.getLabelledById() }, this.inheritedAttributes)), clearInput && !readonly && !disabled && (h("button", { key: 'b115494d9611aea57a976d3102026f3d9b430bfb', "aria-label": "reset", type: "button", class: "input-clear-icon", onPointerDown: (ev) => {
|
|
644
644
|
/**
|
|
645
645
|
* This prevents mobile browsers from
|
|
646
646
|
* blurring the input when the clear
|
|
647
647
|
* button is activated.
|
|
648
648
|
*/
|
|
649
649
|
ev.preventDefault();
|
|
650
|
-
}, onClick: this.clearTextInput }, h("ion-icon", { key: '
|
|
650
|
+
}, onClick: this.clearTextInput }, h("ion-icon", { key: 'a259afa47a9914b2e0656364bed40644fa2c87c4', "aria-hidden": "true", icon: inputClearIcon }))), h("slot", { key: 'beec86eb500f6b335149c8734afc7c3945a10219', name: "end" })), shouldRenderHighlight && h("div", { key: '77a25d118934f369e09edbc2ffa6f90e3e760338', class: "input-highlight" })), this.renderBottomContent()));
|
|
651
651
|
}
|
|
652
652
|
static get is() { return "ion-input"; }
|
|
653
653
|
static get encapsulation() { return "scoped"; }
|
|
@@ -680,7 +680,7 @@ export class InputOTP {
|
|
|
680
680
|
const tabbableIndex = this.getTabbableIndex();
|
|
681
681
|
const pattern = this.getPattern();
|
|
682
682
|
const hasDescription = ((_b = (_a = el.querySelector('.input-otp-description')) === null || _a === void 0 ? void 0 : _a.textContent) === null || _b === void 0 ? void 0 : _b.trim()) !== '';
|
|
683
|
-
return (h(Host, { key: '
|
|
683
|
+
return (h(Host, { key: 'f39e98cd24cbf50f7db4e891dda9499f6def7986', class: createColorClasses(color, {
|
|
684
684
|
[mode]: true,
|
|
685
685
|
'has-focus': hasFocus,
|
|
686
686
|
[`input-otp-size-${size}`]: true,
|
|
@@ -688,10 +688,10 @@ export class InputOTP {
|
|
|
688
688
|
[`input-otp-fill-${fill}`]: true,
|
|
689
689
|
'input-otp-disabled': disabled,
|
|
690
690
|
'input-otp-readonly': readonly,
|
|
691
|
-
}) }, h("div", Object.assign({ key: '
|
|
691
|
+
}) }, h("div", Object.assign({ key: '624adcd552947708162003353b331cd92df062ef', role: "group", "aria-label": "One-time password input", class: "input-otp-group", part: "group" }, inheritedAttributes), Array.from({ length }).map((_, index) => (h(Fragment, null, h("div", { class: "native-wrapper", part: "container" }, h("input", { class: "native-input", part: "native", id: `${inputId}-${index}`, "aria-label": `Input ${index + 1} of ${length}`, type: "text", autoCapitalize: autocapitalize, inputmode: inputmode, pattern: pattern, disabled: disabled, readOnly: readonly, tabIndex: index === tabbableIndex ? 0 : -1, value: inputValues[index] || '', autocomplete: "one-time-code", ref: (el) => (inputRefs[index] = el), onInput: this.onInput(index), onBlur: this.onBlur, onFocus: this.onFocus(index), onKeyDown: this.onKeyDown(index), onPaste: this.onPaste })), this.showSeparator(index) && h("div", { class: "input-otp-separator", part: "separator" }))))), h("div", { key: 'c518d83ab0236a3ebbe631582ce6f1c2edfbcd29', class: {
|
|
692
692
|
'input-otp-description': true,
|
|
693
693
|
'input-otp-description-hidden': !hasDescription,
|
|
694
|
-
}, part: "description" }, h("slot", { key: '
|
|
694
|
+
}, part: "description" }, h("slot", { key: '15c7c8549c1788748e1ae31bd227a7f918cb5eca' }))));
|
|
695
695
|
}
|
|
696
696
|
static get is() { return "ion-input-otp"; }
|
|
697
697
|
static get encapsulation() { return "shadow"; }
|
|
@@ -94,16 +94,16 @@ export class InputPasswordToggle {
|
|
|
94
94
|
const { color, inputPasswordHideIcon, inputPasswordShowIcon, type } = this;
|
|
95
95
|
const mode = getIonMode(this);
|
|
96
96
|
const isPasswordVisible = type === 'text';
|
|
97
|
-
return (h(Host, { key: '
|
|
97
|
+
return (h(Host, { key: 'f11e3bf4d3255e003aec504e6dd3ee1e0caaf767', class: createColorClasses(color, {
|
|
98
98
|
[mode]: true,
|
|
99
|
-
}) }, h("ion-button", { key: '
|
|
99
|
+
}) }, h("ion-button", { key: '5bba43f7755857fd9347612bb906c389b60386b4', mode: mode, color: color, fill: "clear", shape: "round", "aria-label": isPasswordVisible ? 'Hide password' : 'Show password', "aria-pressed": isPasswordVisible ? 'true' : 'false', type: "button", onPointerDown: (ev) => {
|
|
100
100
|
/**
|
|
101
101
|
* This prevents mobile browsers from
|
|
102
102
|
* blurring the input when the password toggle
|
|
103
103
|
* button is activated.
|
|
104
104
|
*/
|
|
105
105
|
ev.preventDefault();
|
|
106
|
-
}, onClick: this.togglePasswordVisibility }, h("ion-icon", { key: '
|
|
106
|
+
}, onClick: this.togglePasswordVisibility }, h("ion-icon", { key: 'c0eb0e4e2f3e9553bfd519ff655064c9f62af406', slot: "icon-only", "aria-hidden": "true", icon: isPasswordVisible ? inputPasswordHideIcon : inputPasswordShowIcon }))));
|
|
107
107
|
}
|
|
108
108
|
static get is() { return "ion-input-password-toggle"; }
|
|
109
109
|
static get encapsulation() { return "shadow"; }
|