@ionic/core 8.7.18-dev.11771365900.125bf49c → 8.7.18-dev.11772037614.10c71570
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-app.js +17 -12
- package/components/ion-content.js +1 -1
- package/components/ion-datetime.js +8 -5
- package/components/ion-fab-list.js +10 -3
- package/components/ion-img.js +11 -2
- package/components/ion-label.js +1 -1
- package/components/ion-modal.js +1 -1
- package/components/ion-popover.js +1 -1
- package/components/ion-radio-group.js +1 -1
- package/components/ion-searchbar.js +17 -6
- package/components/ion-select-modal.js +1 -1
- package/components/ion-select-popover.js +1 -1
- package/components/ion-select.js +7 -7
- package/components/{p-BnpDIASH.js → p-BANeLH_G.js} +2 -2
- package/components/{p-DRHwNkVo.js → p-C6dkQWq2.js} +152 -30
- package/components/{p-CJrGvZ1Z.js → p-CFZWrvIQ.js} +2 -2
- package/components/{p-CUfY9DTD.js → p-Cdm3dKWf.js} +8 -3
- package/components/{p-D3KEyQ8e.js → p-CslsoGzv.js} +2 -2
- package/components/{p-DPm73mCi.js → p-DGOrLIyS.js} +7 -3
- package/components/{p-IHgAGzvW.js → p-iyo0Toaz.js} +326 -17
- package/dist/cjs/ion-app_8.cjs.entry.js +22 -13
- package/dist/cjs/ion-datetime_3.cjs.entry.js +7 -4
- package/dist/cjs/ion-fab_3.cjs.entry.js +10 -3
- package/dist/cjs/ion-img.cjs.entry.js +11 -2
- package/dist/cjs/ion-item_8.cjs.entry.js +8 -3
- package/dist/cjs/ion-modal.cjs.entry.js +326 -17
- package/dist/cjs/ion-popover.cjs.entry.js +152 -30
- package/dist/cjs/ion-radio_2.cjs.entry.js +2 -2
- package/dist/cjs/ion-searchbar.cjs.entry.js +17 -6
- package/dist/collection/components/app/app.js +15 -10
- package/dist/collection/components/content/content.js +7 -3
- package/dist/collection/components/datetime/datetime.ios.css +2 -4
- package/dist/collection/components/datetime/datetime.js +6 -3
- package/dist/collection/components/fab-list/fab-list.js +10 -3
- package/dist/collection/components/img/img.js +11 -2
- package/dist/collection/components/label/label.js +8 -3
- package/dist/collection/components/modal/modal.ios.css +6 -5
- package/dist/collection/components/modal/modal.js +164 -15
- package/dist/collection/components/modal/modal.md.css +6 -5
- package/dist/collection/components/modal/safe-area-utils.js +165 -0
- package/dist/collection/components/popover/animations/ios.enter.js +33 -8
- package/dist/collection/components/popover/animations/md.enter.js +26 -6
- package/dist/collection/components/popover/utils.js +96 -19
- package/dist/collection/components/radio-group/radio-group.ios.css +0 -4
- package/dist/collection/components/radio-group/radio-group.md.css +0 -4
- package/dist/collection/components/searchbar/searchbar.js +17 -6
- package/dist/docs.json +1 -1
- package/dist/esm/ion-app_8.entry.js +24 -15
- package/dist/esm/ion-datetime_3.entry.js +7 -4
- package/dist/esm/ion-fab_3.entry.js +10 -3
- package/dist/esm/ion-img.entry.js +11 -2
- package/dist/esm/ion-item_8.entry.js +8 -3
- package/dist/esm/ion-modal.entry.js +326 -17
- package/dist/esm/ion-popover.entry.js +152 -30
- package/dist/esm/ion-radio_2.entry.js +2 -2
- package/dist/esm/ion-searchbar.entry.js +17 -6
- package/dist/ionic/ionic.esm.js +1 -1
- package/dist/ionic/{p-72af946b.entry.js → p-2ac254dc.entry.js} +1 -1
- package/dist/ionic/p-7cad388a.entry.js +4 -0
- package/dist/ionic/p-915b3e3d.entry.js +4 -0
- package/dist/ionic/p-9b6d46f2.entry.js +4 -0
- package/dist/ionic/{p-eaf3f5ff.entry.js → p-b0ebf9f8.entry.js} +1 -1
- package/dist/ionic/p-e4c57008.entry.js +4 -0
- package/dist/ionic/p-e5d6d0f0.entry.js +4 -0
- package/dist/ionic/p-f1dfee25.entry.js +4 -0
- package/dist/ionic/{p-6444c606.entry.js → p-f9f7b9db.entry.js} +1 -1
- package/dist/types/components/app/app.d.ts +3 -0
- package/dist/types/components/datetime/datetime.d.ts +1 -0
- package/dist/types/components/fab-list/fab-list.d.ts +2 -0
- package/dist/types/components/img/img.d.ts +2 -0
- package/dist/types/components/label/label.d.ts +2 -0
- package/dist/types/components/modal/modal.d.ts +35 -0
- package/dist/types/components/modal/safe-area-utils.d.ts +66 -0
- package/dist/types/components/popover/utils.d.ts +23 -1
- package/dist/types/components/searchbar/searchbar.d.ts +3 -0
- package/hydrate/index.js +554 -71
- package/hydrate/index.mjs +554 -71
- package/package.json +1 -1
- package/dist/ionic/p-01e27965.entry.js +0 -4
- package/dist/ionic/p-3ec563c1.entry.js +0 -4
- package/dist/ionic/p-42db6404.entry.js +0 -4
- package/dist/ionic/p-46d74291.entry.js +0 -4
- package/dist/ionic/p-bc293244.entry.js +0 -4
- package/dist/ionic/p-e338f669.entry.js +0 -4
|
@@ -12,6 +12,58 @@ import { e as deepReady, w as waitForMount } from './p-DTWZF6wg.js';
|
|
|
12
12
|
import { c as createAnimation } from './p-CL12ApCQ.js';
|
|
13
13
|
import { d as defineCustomElement$1 } from './p-Bhnhnzjz.js';
|
|
14
14
|
|
|
15
|
+
/**
|
|
16
|
+
* Shared per-frame cache for safe-area insets. Avoids creating a temporary
|
|
17
|
+
* DOM element and forcing a synchronous reflow on every call within the same
|
|
18
|
+
* frame (e.g., multiple popovers presenting simultaneously). Invalidated
|
|
19
|
+
* after the next animation frame so values stay fresh across orientation
|
|
20
|
+
* changes and viewport resizes.
|
|
21
|
+
*/
|
|
22
|
+
let cachedInsets = null;
|
|
23
|
+
let cacheInvalidationScheduled = false;
|
|
24
|
+
/**
|
|
25
|
+
* Resolves the current --ion-safe-area-* CSS custom property values
|
|
26
|
+
* to actual pixel numbers. A temporary element is needed because
|
|
27
|
+
* getComputedStyle on :root returns the declared value of custom
|
|
28
|
+
* properties (e.g. "env(safe-area-inset-top)") rather than a
|
|
29
|
+
* resolved number. By assigning them to standard padding properties,
|
|
30
|
+
* the browser resolves the value.
|
|
31
|
+
*
|
|
32
|
+
* Results are cached for the current frame to avoid repeated reflows.
|
|
33
|
+
*/
|
|
34
|
+
const getSafeAreaInsets = (doc) => {
|
|
35
|
+
if (cachedInsets !== null) {
|
|
36
|
+
return cachedInsets;
|
|
37
|
+
}
|
|
38
|
+
if (doc.body === null) {
|
|
39
|
+
return { top: 0, bottom: 0, left: 0, right: 0 };
|
|
40
|
+
}
|
|
41
|
+
const el = doc.createElement('div');
|
|
42
|
+
el.style.cssText =
|
|
43
|
+
'position:fixed;visibility:hidden;pointer-events:none;top:0;left:0;' +
|
|
44
|
+
'padding-top:var(--ion-safe-area-top,0px);' +
|
|
45
|
+
'padding-bottom:var(--ion-safe-area-bottom,0px);' +
|
|
46
|
+
'padding-left:var(--ion-safe-area-left,0px);' +
|
|
47
|
+
'padding-right:var(--ion-safe-area-right,0px);';
|
|
48
|
+
doc.body.appendChild(el);
|
|
49
|
+
const style = getComputedStyle(el);
|
|
50
|
+
const insets = {
|
|
51
|
+
top: parseFloat(style.paddingTop) || 0,
|
|
52
|
+
bottom: parseFloat(style.paddingBottom) || 0,
|
|
53
|
+
left: parseFloat(style.paddingLeft) || 0,
|
|
54
|
+
right: parseFloat(style.paddingRight) || 0,
|
|
55
|
+
};
|
|
56
|
+
el.remove();
|
|
57
|
+
cachedInsets = insets;
|
|
58
|
+
if (!cacheInvalidationScheduled) {
|
|
59
|
+
cacheInvalidationScheduled = true;
|
|
60
|
+
raf(() => {
|
|
61
|
+
cachedInsets = null;
|
|
62
|
+
cacheInvalidationScheduled = false;
|
|
63
|
+
});
|
|
64
|
+
}
|
|
65
|
+
return insets;
|
|
66
|
+
};
|
|
15
67
|
/**
|
|
16
68
|
* Returns the dimensions of the popover
|
|
17
69
|
* arrow on `ios` mode. If arrow is disabled
|
|
@@ -647,8 +699,10 @@ const calculatePopoverCenterAlign = (side, triggerBoundingBox, contentWidth, con
|
|
|
647
699
|
* Adjusts popover positioning coordinates
|
|
648
700
|
* such that popover does not appear offscreen
|
|
649
701
|
* or overlapping safe area bounds.
|
|
702
|
+
*
|
|
703
|
+
* @internal - This is not part of the public API.
|
|
650
704
|
*/
|
|
651
|
-
const calculateWindowAdjustment = (side, coordTop, coordLeft, bodyPadding, bodyWidth, bodyHeight, contentWidth, contentHeight,
|
|
705
|
+
const calculateWindowAdjustment = (side, coordTop, coordLeft, bodyPadding, bodyWidth, bodyHeight, contentWidth, contentHeight, safeArea, contentOriginX, contentOriginY, triggerCoordinates, coordArrowTop = 0, coordArrowLeft = 0, arrowHeight = 0) => {
|
|
652
706
|
let arrowTop = coordArrowTop;
|
|
653
707
|
const arrowLeft = coordArrowLeft;
|
|
654
708
|
let left = coordLeft;
|
|
@@ -658,16 +712,19 @@ const calculateWindowAdjustment = (side, coordTop, coordLeft, bodyPadding, bodyW
|
|
|
658
712
|
let originY = contentOriginY;
|
|
659
713
|
let checkSafeAreaLeft = false;
|
|
660
714
|
let checkSafeAreaRight = false;
|
|
715
|
+
let checkSafeAreaTop = false;
|
|
716
|
+
let checkSafeAreaBottom = false;
|
|
661
717
|
const triggerTop = triggerCoordinates
|
|
662
718
|
? triggerCoordinates.top + triggerCoordinates.height
|
|
663
719
|
: bodyHeight / 2 - contentHeight / 2;
|
|
664
720
|
const triggerHeight = triggerCoordinates ? triggerCoordinates.height : 0;
|
|
665
721
|
let addPopoverBottomClass = false;
|
|
722
|
+
const hideArrow = false;
|
|
666
723
|
/**
|
|
667
724
|
* Adjust popover so it does not
|
|
668
725
|
* go off the left of the screen.
|
|
669
726
|
*/
|
|
670
|
-
if (left < bodyPadding +
|
|
727
|
+
if (left < bodyPadding + safeArea.left) {
|
|
671
728
|
left = bodyPadding;
|
|
672
729
|
checkSafeAreaLeft = true;
|
|
673
730
|
originX = 'left';
|
|
@@ -676,41 +733,58 @@ const calculateWindowAdjustment = (side, coordTop, coordLeft, bodyPadding, bodyW
|
|
|
676
733
|
* go off the right of the screen.
|
|
677
734
|
*/
|
|
678
735
|
}
|
|
679
|
-
else if (contentWidth + bodyPadding + left +
|
|
736
|
+
else if (contentWidth + bodyPadding + left + safeArea.right > bodyWidth) {
|
|
680
737
|
checkSafeAreaRight = true;
|
|
681
738
|
left = bodyWidth - contentWidth - bodyPadding;
|
|
682
739
|
originX = 'right';
|
|
683
740
|
}
|
|
684
741
|
/**
|
|
685
742
|
* Adjust popover so it does not
|
|
686
|
-
* go off the
|
|
743
|
+
* go off the bottom of the screen
|
|
744
|
+
* or overlap the bottom safe area.
|
|
687
745
|
* If popover is on the left or the right of
|
|
688
746
|
* the trigger, then we should not adjust top
|
|
689
747
|
* margins.
|
|
690
748
|
*/
|
|
691
|
-
if (triggerTop + triggerHeight + contentHeight > bodyHeight
|
|
692
|
-
|
|
749
|
+
if (triggerTop + triggerHeight + contentHeight > bodyHeight - safeArea.bottom &&
|
|
750
|
+
(side === 'top' || side === 'bottom')) {
|
|
751
|
+
/**
|
|
752
|
+
* Calculate where the popover top would be if flipped
|
|
753
|
+
* above the trigger. Check whether that position clears
|
|
754
|
+
* the top safe area with room for bodyPadding.
|
|
755
|
+
*/
|
|
756
|
+
const idealFlipTop = triggerTop - contentHeight - triggerHeight - (arrowHeight - 1);
|
|
757
|
+
if (idealFlipTop >= safeArea.top + bodyPadding) {
|
|
693
758
|
/**
|
|
694
|
-
*
|
|
695
|
-
*
|
|
696
|
-
*
|
|
697
|
-
* off the bottom of the screen. However, we do not want to move
|
|
698
|
-
* the popover up so much that it goes off the top of the screen.
|
|
699
|
-
*
|
|
700
|
-
* We chose 12 here so that the popover position looks a bit nicer as
|
|
701
|
-
* it is not right up against the edge of the screen.
|
|
759
|
+
* Popover fits above the trigger without overlapping
|
|
760
|
+
* the top safe area. Use the ideal position directly —
|
|
761
|
+
* no safe-area CSS vars needed since it clears both edges.
|
|
702
762
|
*/
|
|
703
|
-
top =
|
|
763
|
+
top = idealFlipTop;
|
|
704
764
|
arrowTop = top + contentHeight;
|
|
705
765
|
originY = 'bottom';
|
|
706
766
|
addPopoverBottomClass = true;
|
|
707
|
-
/**
|
|
708
|
-
* If not enough room for popover to appear
|
|
709
|
-
* above trigger, then cut it off.
|
|
710
|
-
*/
|
|
711
767
|
}
|
|
712
768
|
else {
|
|
769
|
+
/**
|
|
770
|
+
* Can't flip above the trigger. Constrain the bottom
|
|
771
|
+
* edge while keeping the top near the trigger. This
|
|
772
|
+
* creates a scrollable area anchored to the trigger.
|
|
773
|
+
*/
|
|
713
774
|
bottom = bodyPadding;
|
|
775
|
+
checkSafeAreaBottom = true;
|
|
776
|
+
/**
|
|
777
|
+
* When the trigger is near the bottom of the screen,
|
|
778
|
+
* the calculated top may be at or past the bottom
|
|
779
|
+
* constraint, leaving zero visible height. In that
|
|
780
|
+
* case, pull top up to the top safe area so the
|
|
781
|
+
* popover fills the available space between safe areas.
|
|
782
|
+
*/
|
|
783
|
+
const bottomEdge = bodyHeight - safeArea.bottom - bodyPadding;
|
|
784
|
+
if (top >= bottomEdge) {
|
|
785
|
+
top = safeArea.top + bodyPadding;
|
|
786
|
+
checkSafeAreaTop = true;
|
|
787
|
+
}
|
|
714
788
|
}
|
|
715
789
|
}
|
|
716
790
|
return {
|
|
@@ -721,9 +795,12 @@ const calculateWindowAdjustment = (side, coordTop, coordLeft, bodyPadding, bodyW
|
|
|
721
795
|
originY,
|
|
722
796
|
checkSafeAreaLeft,
|
|
723
797
|
checkSafeAreaRight,
|
|
798
|
+
checkSafeAreaTop,
|
|
799
|
+
checkSafeAreaBottom,
|
|
724
800
|
arrowTop,
|
|
725
801
|
arrowLeft,
|
|
726
802
|
addPopoverBottomClass,
|
|
803
|
+
hideArrow,
|
|
727
804
|
};
|
|
728
805
|
};
|
|
729
806
|
const shouldShowArrow = (side, didAdjustBounds = false, ev, trigger) => {
|
|
@@ -753,6 +830,15 @@ const shouldShowArrow = (side, didAdjustBounds = false, ev, trigger) => {
|
|
|
753
830
|
};
|
|
754
831
|
|
|
755
832
|
const POPOVER_IOS_BODY_PADDING = 5;
|
|
833
|
+
/**
|
|
834
|
+
* Minimum edge margin for iOS popovers ensures visual spacing from screen
|
|
835
|
+
* edges on devices without safe areas (e.g., older iPhones without notches).
|
|
836
|
+
* Previously this was a hardcoded `safeAreaMargin = 25` that served dual
|
|
837
|
+
* purpose: safe-area avoidance AND visual spacing. Now that actual safe-area
|
|
838
|
+
* insets are read dynamically, this floor preserves the visual spacing when
|
|
839
|
+
* safe-area values are 0.
|
|
840
|
+
*/
|
|
841
|
+
const POPOVER_IOS_MIN_EDGE_MARGIN = 25;
|
|
756
842
|
/**
|
|
757
843
|
* iOS Popover Enter Animation
|
|
758
844
|
*/
|
|
@@ -778,8 +864,16 @@ const iosEnterAnimation = (baseEl, opts) => {
|
|
|
778
864
|
};
|
|
779
865
|
const results = getPopoverPosition(isRTL, contentWidth, contentHeight, arrowWidth, arrowHeight, reference, side, align, defaultPosition, trigger, ev);
|
|
780
866
|
const padding = size === 'cover' ? 0 : POPOVER_IOS_BODY_PADDING;
|
|
781
|
-
const
|
|
782
|
-
const
|
|
867
|
+
const rawSafeArea = getSafeAreaInsets(doc);
|
|
868
|
+
const safeArea = size === 'cover'
|
|
869
|
+
? { top: 0, bottom: 0, left: 0, right: 0 }
|
|
870
|
+
: {
|
|
871
|
+
top: Math.max(rawSafeArea.top, POPOVER_IOS_MIN_EDGE_MARGIN),
|
|
872
|
+
bottom: Math.max(rawSafeArea.bottom, POPOVER_IOS_MIN_EDGE_MARGIN),
|
|
873
|
+
left: Math.max(rawSafeArea.left, POPOVER_IOS_MIN_EDGE_MARGIN),
|
|
874
|
+
right: Math.max(rawSafeArea.right, POPOVER_IOS_MIN_EDGE_MARGIN),
|
|
875
|
+
};
|
|
876
|
+
const { originX, originY, top, left, bottom, checkSafeAreaLeft, checkSafeAreaRight, checkSafeAreaTop, checkSafeAreaBottom, arrowTop, arrowLeft, addPopoverBottomClass} = calculateWindowAdjustment(side, results.top, results.left, padding, bodyWidth, bodyHeight, contentWidth, contentHeight, safeArea, results.originX, results.originY, results.referenceCoordinates, results.arrowTop, results.arrowLeft, arrowHeight);
|
|
783
877
|
const baseAnimation = createAnimation();
|
|
784
878
|
const backdropAnimation = createAnimation();
|
|
785
879
|
const contentAnimation = createAnimation();
|
|
@@ -810,10 +904,14 @@ const iosEnterAnimation = (baseEl, opts) => {
|
|
|
810
904
|
baseEl.classList.add('popover-bottom');
|
|
811
905
|
}
|
|
812
906
|
if (bottom !== undefined) {
|
|
813
|
-
|
|
907
|
+
let bottomValue = `${bottom}px`;
|
|
908
|
+
if (checkSafeAreaBottom) {
|
|
909
|
+
bottomValue = `${bottom}px + var(--ion-safe-area-bottom, 0px)`;
|
|
910
|
+
}
|
|
911
|
+
contentEl.style.setProperty('bottom', `calc(${bottomValue})`);
|
|
814
912
|
}
|
|
815
|
-
const safeAreaLeft = ' + var(--ion-safe-area-left,
|
|
816
|
-
const safeAreaRight = ' - var(--ion-safe-area-right,
|
|
913
|
+
const safeAreaLeft = ' + var(--ion-safe-area-left, 0px)';
|
|
914
|
+
const safeAreaRight = ' - var(--ion-safe-area-right, 0px)';
|
|
817
915
|
let leftValue = `${left}px`;
|
|
818
916
|
if (checkSafeAreaLeft) {
|
|
819
917
|
leftValue = `${left}px${safeAreaLeft}`;
|
|
@@ -821,7 +919,11 @@ const iosEnterAnimation = (baseEl, opts) => {
|
|
|
821
919
|
if (checkSafeAreaRight) {
|
|
822
920
|
leftValue = `${left}px${safeAreaRight}`;
|
|
823
921
|
}
|
|
824
|
-
|
|
922
|
+
let topValue = `${top}px`;
|
|
923
|
+
if (checkSafeAreaTop) {
|
|
924
|
+
topValue = `${top}px + var(--ion-safe-area-top, 0px)`;
|
|
925
|
+
}
|
|
926
|
+
contentEl.style.setProperty('top', `calc(${topValue} + var(--offset-y, 0))`);
|
|
825
927
|
contentEl.style.setProperty('left', `calc(${leftValue} + var(--offset-x, 0))`);
|
|
826
928
|
contentEl.style.setProperty('transform-origin', `${originY} ${originX}`);
|
|
827
929
|
if (arrowEl !== null) {
|
|
@@ -897,7 +999,23 @@ const mdEnterAnimation = (baseEl, opts) => {
|
|
|
897
999
|
};
|
|
898
1000
|
const results = getPopoverPosition(isRTL, contentWidth, contentHeight, 0, 0, reference, side, align, defaultPosition, trigger, ev);
|
|
899
1001
|
const padding = size === 'cover' ? 0 : POPOVER_MD_BODY_PADDING;
|
|
900
|
-
|
|
1002
|
+
// MD mode now applies safe-area insets (previously passed 0, ignoring all safe areas).
|
|
1003
|
+
// This is needed for Android edge-to-edge (API 36+) where system bars overlap content.
|
|
1004
|
+
const safeArea = size === 'cover' ? { top: 0, bottom: 0, left: 0, right: 0 } : getSafeAreaInsets(doc);
|
|
1005
|
+
const { originX, originY, top, left, bottom, checkSafeAreaLeft, checkSafeAreaRight, checkSafeAreaTop, checkSafeAreaBottom, addPopoverBottomClass, } = calculateWindowAdjustment(side, results.top, results.left, padding, bodyWidth, bodyHeight, contentWidth, contentHeight, safeArea, results.originX, results.originY, results.referenceCoordinates);
|
|
1006
|
+
const safeAreaLeftCalc = ' + var(--ion-safe-area-left, 0px)';
|
|
1007
|
+
const safeAreaRightCalc = ' - var(--ion-safe-area-right, 0px)';
|
|
1008
|
+
let leftValue = `${left}px`;
|
|
1009
|
+
if (checkSafeAreaLeft) {
|
|
1010
|
+
leftValue = `${left}px${safeAreaLeftCalc}`;
|
|
1011
|
+
}
|
|
1012
|
+
if (checkSafeAreaRight) {
|
|
1013
|
+
leftValue = `${left}px${safeAreaRightCalc}`;
|
|
1014
|
+
}
|
|
1015
|
+
let topValue = `${top}px`;
|
|
1016
|
+
if (checkSafeAreaTop) {
|
|
1017
|
+
topValue = `${top}px + var(--ion-safe-area-top, 0px)`;
|
|
1018
|
+
}
|
|
901
1019
|
const baseAnimation = createAnimation();
|
|
902
1020
|
const backdropAnimation = createAnimation();
|
|
903
1021
|
const wrapperAnimation = createAnimation();
|
|
@@ -914,13 +1032,17 @@ const mdEnterAnimation = (baseEl, opts) => {
|
|
|
914
1032
|
contentAnimation
|
|
915
1033
|
.addElement(contentEl)
|
|
916
1034
|
.beforeStyles({
|
|
917
|
-
top: `calc(${
|
|
918
|
-
left: `calc(${
|
|
1035
|
+
top: `calc(${topValue} + var(--offset-y, 0px))`,
|
|
1036
|
+
left: `calc(${leftValue} + var(--offset-x, 0px))`,
|
|
919
1037
|
'transform-origin': `${originY} ${originX}`,
|
|
920
1038
|
})
|
|
921
1039
|
.beforeAddWrite(() => {
|
|
922
1040
|
if (bottom !== undefined) {
|
|
923
|
-
|
|
1041
|
+
let bottomValue = `${bottom}px`;
|
|
1042
|
+
if (checkSafeAreaBottom) {
|
|
1043
|
+
bottomValue = `${bottom}px + var(--ion-safe-area-bottom, 0px)`;
|
|
1044
|
+
}
|
|
1045
|
+
contentEl.style.setProperty('bottom', `calc(${bottomValue})`);
|
|
924
1046
|
}
|
|
925
1047
|
})
|
|
926
1048
|
.fromTo('transform', 'scale(0.8)', 'scale(1)');
|
|
@@ -932,7 +1054,7 @@ const mdEnterAnimation = (baseEl, opts) => {
|
|
|
932
1054
|
if (size === 'cover') {
|
|
933
1055
|
baseEl.style.setProperty('--width', `${contentWidth}px`);
|
|
934
1056
|
}
|
|
935
|
-
if (
|
|
1057
|
+
if (addPopoverBottomClass) {
|
|
936
1058
|
baseEl.classList.add('popover-bottom');
|
|
937
1059
|
}
|
|
938
1060
|
})
|
|
@@ -8,13 +8,13 @@ import { g as getClassMap } from './p-DiVJyqlX.js';
|
|
|
8
8
|
import { d as defineCustomElement$d } from './p-DK2Bn1Mc.js';
|
|
9
9
|
import { d as defineCustomElement$c } from './p-BBFQmhcD.js';
|
|
10
10
|
import { d as defineCustomElement$b } from './p-DyFBFrV7.js';
|
|
11
|
-
import { d as defineCustomElement$a } from './p-
|
|
11
|
+
import { d as defineCustomElement$a } from './p-DGOrLIyS.js';
|
|
12
12
|
import { d as defineCustomElement$9 } from './p-DX0w75a9.js';
|
|
13
13
|
import { d as defineCustomElement$8 } from './p-Wro9IPHE.js';
|
|
14
14
|
import { d as defineCustomElement$7 } from './p-aIWC4ZEV.js';
|
|
15
15
|
import { d as defineCustomElement$6 } from './p-B25GjpND.js';
|
|
16
16
|
import { d as defineCustomElement$5 } from './p-Bt_moUyl.js';
|
|
17
|
-
import { d as defineCustomElement$4 } from './p-
|
|
17
|
+
import { d as defineCustomElement$4 } from './p-BANeLH_G.js';
|
|
18
18
|
import { d as defineCustomElement$3 } from './p-LgLeKTkH.js';
|
|
19
19
|
import { d as defineCustomElement$2 } from './p-BTlwXR9e.js';
|
|
20
20
|
import { d as defineCustomElement$1 } from './p-Dt8zaCLQ.js';
|
|
@@ -28,11 +28,16 @@ const Label = /*@__PURE__*/ proxyCustomElement(class Label extends H {
|
|
|
28
28
|
}
|
|
29
29
|
componentDidLoad() {
|
|
30
30
|
if (this.noAnimate) {
|
|
31
|
-
setTimeout(() => {
|
|
31
|
+
this.loadTimeout = setTimeout(() => {
|
|
32
32
|
this.noAnimate = false;
|
|
33
33
|
}, 1000);
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
|
+
disconnectedCallback() {
|
|
37
|
+
if (this.loadTimeout) {
|
|
38
|
+
clearTimeout(this.loadTimeout);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
36
41
|
colorChanged() {
|
|
37
42
|
this.emitColor();
|
|
38
43
|
}
|
|
@@ -61,13 +66,13 @@ const Label = /*@__PURE__*/ proxyCustomElement(class Label extends H {
|
|
|
61
66
|
render() {
|
|
62
67
|
const position = this.position;
|
|
63
68
|
const mode = getIonMode(this);
|
|
64
|
-
return (h(Host, { key: '
|
|
69
|
+
return (h(Host, { key: 'd603670c442213c28737b0c052c094705b8c84ef', class: createColorClasses(this.color, {
|
|
65
70
|
[mode]: true,
|
|
66
71
|
'in-item-color': hostContext('ion-item.ion-color', this.el),
|
|
67
72
|
[`label-${position}`]: position !== undefined,
|
|
68
73
|
[`label-no-animate`]: this.noAnimate,
|
|
69
74
|
'label-rtl': document.dir === 'rtl',
|
|
70
|
-
}) }, h("slot", { key: '
|
|
75
|
+
}) }, h("slot", { key: 'a8c3aed240a20ee5856c423662878481a1e6d4cf' })));
|
|
71
76
|
}
|
|
72
77
|
get el() { return this; }
|
|
73
78
|
static get watchers() { return {
|
|
@@ -8,11 +8,11 @@ import { b as getIonMode } from './p-Bxl5etF4.js';
|
|
|
8
8
|
import { d as defineCustomElement$9 } from './p-DyFBFrV7.js';
|
|
9
9
|
import { d as defineCustomElement$8 } from './p-Wro9IPHE.js';
|
|
10
10
|
import { d as defineCustomElement$7 } from './p-aIWC4ZEV.js';
|
|
11
|
-
import { d as defineCustomElement$6 } from './p-
|
|
11
|
+
import { d as defineCustomElement$6 } from './p-Cdm3dKWf.js';
|
|
12
12
|
import { d as defineCustomElement$5 } from './p-B25GjpND.js';
|
|
13
13
|
import { d as defineCustomElement$4 } from './p-NhiRFRn9.js';
|
|
14
14
|
import { d as defineCustomElement$3 } from './p-Bt_moUyl.js';
|
|
15
|
-
import { d as defineCustomElement$2 } from './p-
|
|
15
|
+
import { d as defineCustomElement$2 } from './p-BANeLH_G.js';
|
|
16
16
|
import { d as defineCustomElement$1 } from './p-LgLeKTkH.js';
|
|
17
17
|
|
|
18
18
|
const selectPopoverIosCss = ".sc-ion-select-popover-ios-h ion-list.sc-ion-select-popover-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}ion-list-header.sc-ion-select-popover-ios,ion-label.sc-ion-select-popover-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0}.sc-ion-select-popover-ios-h{overflow-y:auto}";
|
|
@@ -134,6 +134,10 @@ const Content = /*@__PURE__*/ proxyCustomElement(class Content extends H {
|
|
|
134
134
|
this.tabsElement = null;
|
|
135
135
|
this.tabsLoadCallback = undefined;
|
|
136
136
|
}
|
|
137
|
+
if (this.resizeTimeout) {
|
|
138
|
+
clearTimeout(this.resizeTimeout);
|
|
139
|
+
this.resizeTimeout = null;
|
|
140
|
+
}
|
|
137
141
|
}
|
|
138
142
|
/**
|
|
139
143
|
* Rotating certain devices can update
|
|
@@ -372,7 +376,7 @@ const Content = /*@__PURE__*/ proxyCustomElement(class Content extends H {
|
|
|
372
376
|
const forceOverscroll = this.shouldForceOverscroll();
|
|
373
377
|
const transitionShadow = mode === 'ios';
|
|
374
378
|
this.resize();
|
|
375
|
-
return (h(Host, Object.assign({ key: '
|
|
379
|
+
return (h(Host, Object.assign({ key: '287f5bb78888b0f66394a35ba2a3ad636d8f3412', role: isMainContent ? 'main' : undefined, class: createColorClasses(this.color, {
|
|
376
380
|
[mode]: true,
|
|
377
381
|
'content-sizing': hostContext('ion-popover', this.el),
|
|
378
382
|
overscroll: forceOverscroll,
|
|
@@ -380,12 +384,12 @@ const Content = /*@__PURE__*/ proxyCustomElement(class Content extends H {
|
|
|
380
384
|
}), style: {
|
|
381
385
|
'--offset-top': `${this.cTop}px`,
|
|
382
386
|
'--offset-bottom': `${this.cBottom}px`,
|
|
383
|
-
} }, inheritedAttributes), h("div", { key: '
|
|
387
|
+
} }, inheritedAttributes), h("div", { key: '2e70e5e0ab4209478ea711a630058fa0e83af7f8', ref: (el) => (this.backgroundContentEl = el), id: "background-content", part: "background" }), fixedSlotPlacement === 'before' ? h("slot", { name: "fixed" }) : null, h("div", { key: '018a83406173ec7f7725f09b4bd1c0d964874ee4', class: {
|
|
384
388
|
'inner-scroll': true,
|
|
385
389
|
'scroll-x': scrollX,
|
|
386
390
|
'scroll-y': scrollY,
|
|
387
391
|
overscroll: (scrollX || scrollY) && forceOverscroll,
|
|
388
|
-
}, ref: (scrollEl) => (this.scrollEl = scrollEl), onScroll: this.scrollEvents ? (ev) => this.onScroll(ev) : undefined, part: "scroll" }, h("slot", { key: '
|
|
392
|
+
}, ref: (scrollEl) => (this.scrollEl = scrollEl), onScroll: this.scrollEvents ? (ev) => this.onScroll(ev) : undefined, part: "scroll" }, h("slot", { key: '6f028eeb7c9dc7e1b82a8e549e1dd8aaf1d15fca' })), transitionShadow ? (h("div", { class: "transition-effect" }, h("div", { class: "transition-cover" }), h("div", { class: "transition-shadow" }))) : null, fixedSlotPlacement === 'after' ? h("slot", { name: "fixed" }) : null));
|
|
389
393
|
}
|
|
390
394
|
get el() { return this; }
|
|
391
395
|
static get style() { return contentCss; }
|