diff --git a/node_modules/@ionic/core/components/popover.js b/node_modules/@ionic/core/components/popover.js index 394d7e6..1f36f24 100644 --- a/node_modules/@ionic/core/components/popover.js +++ b/node_modules/@ionic/core/components/popover.js @@ -763,8 +763,10 @@ const iosEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const arrowEl = root.querySelector('.popover-arrow'); @@ -884,8 +886,10 @@ const mdEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const referenceSizeEl = trigger || ((_a = ev === null || ev === void 0 ? void 0 : ev.detail) === null || _a === void 0 ? void 0 : _a.ionShadowTarget) || (ev === null || ev === void 0 ? void 0 : ev.target); diff --git a/node_modules/@ionic/core/dist/cjs/ion-popover.cjs.entry.js b/node_modules/@ionic/core/dist/cjs/ion-popover.cjs.entry.js index 004effa..84389bf 100644 --- a/node_modules/@ionic/core/dist/cjs/ion-popover.cjs.entry.js +++ b/node_modules/@ionic/core/dist/cjs/ion-popover.cjs.entry.js @@ -769,8 +769,10 @@ const iosEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = helpers.getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const arrowEl = root.querySelector('.popover-arrow'); @@ -890,8 +892,10 @@ const mdEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = helpers.getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const referenceSizeEl = trigger || ((_a = ev === null || ev === void 0 ? void 0 : ev.detail) === null || _a === void 0 ? void 0 : _a.ionShadowTarget) || (ev === null || ev === void 0 ? void 0 : ev.target); diff --git a/node_modules/@ionic/core/dist/collection/components/popover/animations/ios.enter.js b/node_modules/@ionic/core/dist/collection/components/popover/animations/ios.enter.js index 84b30ff..528af87 100644 --- a/node_modules/@ionic/core/dist/collection/components/popover/animations/ios.enter.js +++ b/node_modules/@ionic/core/dist/collection/components/popover/animations/ios.enter.js @@ -14,8 +14,10 @@ export const iosEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const arrowEl = root.querySelector('.popover-arrow'); diff --git a/node_modules/@ionic/core/dist/collection/components/popover/animations/md.enter.js b/node_modules/@ionic/core/dist/collection/components/popover/animations/md.enter.js index 603923a..ff10a25 100644 --- a/node_modules/@ionic/core/dist/collection/components/popover/animations/md.enter.js +++ b/node_modules/@ionic/core/dist/collection/components/popover/animations/md.enter.js @@ -14,8 +14,10 @@ export const mdEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const referenceSizeEl = trigger || ((_a = ev === null || ev === void 0 ? void 0 : ev.detail) === null || _a === void 0 ? void 0 : _a.ionShadowTarget) || (ev === null || ev === void 0 ? void 0 : ev.target); diff --git a/node_modules/@ionic/core/dist/esm/ion-popover.entry.js b/node_modules/@ionic/core/dist/esm/ion-popover.entry.js index 9b06217..70b4015 100644 --- a/node_modules/@ionic/core/dist/esm/ion-popover.entry.js +++ b/node_modules/@ionic/core/dist/esm/ion-popover.entry.js @@ -765,8 +765,10 @@ const iosEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const arrowEl = root.querySelector('.popover-arrow'); @@ -886,8 +888,10 @@ const mdEnterAnimation = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const referenceSizeEl = trigger || ((_a = ev === null || ev === void 0 ? void 0 : ev.detail) === null || _a === void 0 ? void 0 : _a.ionShadowTarget) || (ev === null || ev === void 0 ? void 0 : ev.target); diff --git a/node_modules/@ionic/core/hydrate/index.js b/node_modules/@ionic/core/hydrate/index.js index c3d2d8e..bc40d4f 100644 --- a/node_modules/@ionic/core/hydrate/index.js +++ b/node_modules/@ionic/core/hydrate/index.js @@ -23882,8 +23882,10 @@ const iosEnterAnimation$1 = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const arrowEl = root.querySelector('.popover-arrow'); @@ -24003,8 +24005,10 @@ const mdEnterAnimation$1 = (baseEl, opts) => { const { event: ev, size, trigger, reference, side, align } = opts; const doc = baseEl.ownerDocument; const isRTL = doc.dir === 'rtl'; - const bodyWidth = doc.defaultView.innerWidth; - const bodyHeight = doc.defaultView.innerHeight; + // Patched: use document.body.clientXXX instead of doc.defaultView.innerXXXX because the latter doesn't return the correct + // dimensions when the `zoom` CSS property is being used. + const bodyWidth = document.body.clientWidth; + const bodyHeight = document.body.clientHeight; const root = getElementRoot(baseEl); const contentEl = root.querySelector('.popover-content'); const referenceSizeEl = trigger || ((_a = ev === null || ev === void 0 ? void 0 : ev.detail) === null || _a === void 0 ? void 0 : _a.ionShadowTarget) || (ev === null || ev === void 0 ? void 0 : ev.target);