diff --git a/.github/workflows/actions/test-core-screenshot/action.yml b/.github/workflows/actions/test-core-screenshot/action.yml
index 52596467d3..d9cf4bf6f5 100644
--- a/.github/workflows/actions/test-core-screenshot/action.yml
+++ b/.github/workflows/actions/test-core-screenshot/action.yml
@@ -7,6 +7,8 @@ inputs:
description: 'Playwright total number of test shards (ex: 4)'
update:
description: 'Whether or not to update the reference snapshots'
+ component:
+ description: 'The component to update the reference snapshots'
runs:
using: 'composite'
@@ -23,9 +25,29 @@ runs:
run: npm install && npx playwright install && npx playwright install-deps
shell: bash
working-directory: ./core
+ - id: clean-component-name
+ name: Clean Component Name
+ # Remove `ion-` prefix from the `component` variable if it exists.
+ run: |
+ echo "component=$(echo ${{ inputs.component }} | sed 's/ion-//g')" >> $GITHUB_OUTPUT
+ shell: bash
+ - id: set-test-file
+ name: Set Test File
+ # Screenshots can be updated for all components or specified component(s).
+ # If the `component` variable is set, then the test has the option to
+ # - run all the file paths that are in a component folder.
+ # -- For example: if the `component` value is "item", then the test will run all the file paths that are in the "src/components/item" folder.
+ # -- For example: if the `component` value is "item chip", then the test will run all the file paths that are in the "src/components/item" and "src/components/chip" folders.
+ run: |
+ if [ -n "${{ steps.clean-component-name.outputs.component }}" ]; then
+ echo "testFile=\$(echo '${{ steps.clean-component-name.outputs.component }}' | awk '{for(i=1;i<=NF;i++) \$i=\"src/components/\"\$i}1')" >> $GITHUB_OUTPUT
+ else
+ echo "testFile=$(echo '')" >> $GITHUB_OUTPUT
+ fi
+ shell: bash
- name: Test
if: inputs.update != 'true'
- run: npm run test.e2e -- --shard=${{ inputs.shard }}/${{ inputs.totalShards }}
+ run: npm run test.e2e ${{ steps.set-test-file.outputs.testFile }} -- --shard=${{ inputs.shard }}/${{ inputs.totalShards }}
shell: bash
working-directory: ./core
- name: Test and Update
@@ -47,7 +69,7 @@ runs:
# which is why we not using the upload-archive
# composite step here.
run: |
- npm run test.e2e -- --shard=${{ inputs.shard }}/${{ inputs.totalShards }} --update-snapshots
+ npm run test.e2e ${{ steps.set-test-file.outputs.testFile }} -- --shard=${{ inputs.shard }}/${{ inputs.totalShards }} --update-snapshots
git add src/\*.png --force
mkdir updated-screenshots
cd ../ && rsync -R --progress $(git diff --name-only --cached) core/updated-screenshots
diff --git a/.github/workflows/stencil-nightly.yml b/.github/workflows/stencil-nightly.yml
index c5db4e1bb3..01ab63bb5e 100644
--- a/.github/workflows/stencil-nightly.yml
+++ b/.github/workflows/stencil-nightly.yml
@@ -150,7 +150,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- apps: [ng12, ng13, ng14, ng15]
+ apps: [ng16, ng17]
needs: [build-angular, build-angular-server]
runs-on: ubuntu-latest
steps:
diff --git a/.github/workflows/update-screenshots.yml b/.github/workflows/update-screenshots.yml
index 7ff2c49901..b78a13c42a 100644
--- a/.github/workflows/update-screenshots.yml
+++ b/.github/workflows/update-screenshots.yml
@@ -2,6 +2,11 @@ name: 'Update Reference Screenshots'
on:
workflow_dispatch:
+ inputs:
+ component:
+ description: 'What component(s) should be updated? (leave blank to update all or use a space-separated list for multiple components)'
+ required: false
+ default: ''
jobs:
build-core:
@@ -34,6 +39,7 @@ jobs:
shard: ${{ matrix.shard }}
totalShards: ${{ matrix.totalShards }}
update: true
+ component: ${{ inputs.component }}
update-reference-screenshots:
runs-on: ubuntu-latest
diff --git a/CHANGELOG.md b/CHANGELOG.md
index bab77c44f5..6a26de87c6 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -3,6 +3,45 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
+## [7.7.1](https://github.com/ionic-team/ionic-framework/compare/v7.7.0...v7.7.1) (2024-02-07)
+
+
+### Bug Fixes
+
+* **action-sheet:** iOS dismiss animation respects safe area ([#28915](https://github.com/ionic-team/ionic-framework/issues/28915)) ([7449fb4](https://github.com/ionic-team/ionic-framework/commit/7449fb4fed4048f5d01ba068dc6f8e2d7727e95d)), closes [#28541](https://github.com/ionic-team/ionic-framework/issues/28541)
+* **overlays:** tear down animations after dismiss ([#28907](https://github.com/ionic-team/ionic-framework/issues/28907)) ([950fa40](https://github.com/ionic-team/ionic-framework/commit/950fa40c5597c81d5cbaeb9276b09adfea5e79fb)), closes [#28352](https://github.com/ionic-team/ionic-framework/issues/28352)
+* **react:** route with redirect will mount page ([#28961](https://github.com/ionic-team/ionic-framework/issues/28961)) ([5777ce2](https://github.com/ionic-team/ionic-framework/commit/5777ce258119d2715b1326cdc103bd4ad7612bd1)), closes [#28838](https://github.com/ionic-team/ionic-framework/issues/28838)
+* **select:** popover can be scrolled ([#28965](https://github.com/ionic-team/ionic-framework/issues/28965)) ([35ab6b4](https://github.com/ionic-team/ionic-framework/commit/35ab6b4816bd627239de8d8b25ce0c86db8c74b4)), closes [#28963](https://github.com/ionic-team/ionic-framework/issues/28963)
+
+
+
+
+
+# [7.7.0](https://github.com/ionic-team/ionic-framework/compare/v7.6.7...v7.7.0) (2024-01-31)
+
+
+### Features
+
+* add experimental hardware back button support in browsers ([#28705](https://github.com/ionic-team/ionic-framework/issues/28705)) ([658d1ca](https://github.com/ionic-team/ionic-framework/commit/658d1caccd530350843b85c0e24544ec27dd9eb4)), closes [#28703](https://github.com/ionic-team/ionic-framework/issues/28703)
+
+
+
+
+
+## [7.6.7](https://github.com/ionic-team/ionic-framework/compare/v7.6.6...v7.6.7) (2024-01-31)
+
+
+### Bug Fixes
+
+* **accordion:** prevent opening of readonly accordion using keyboard ([#28865](https://github.com/ionic-team/ionic-framework/issues/28865)) ([e10f49c](https://github.com/ionic-team/ionic-framework/commit/e10f49c43daa11fe7deb5a9b9bfd34897542b6b1)), closes [#28344](https://github.com/ionic-team/ionic-framework/issues/28344)
+* **action-sheet, alert, toast:** button roles autocomplete with available options ([#27940](https://github.com/ionic-team/ionic-framework/issues/27940)) ([f6fc22b](https://github.com/ionic-team/ionic-framework/commit/f6fc22bba60388701b80a9421510e3d843d39e9e)), closes [#27965](https://github.com/ionic-team/ionic-framework/issues/27965)
+* **item:** ensure button focus state on property change ([#28892](https://github.com/ionic-team/ionic-framework/issues/28892)) ([bf7922c](https://github.com/ionic-team/ionic-framework/commit/bf7922c8b37b32dbf90650cb74a2e77bedf0c118)), closes [#28525](https://github.com/ionic-team/ionic-framework/issues/28525)
+* **item:** only default slot content wraps ([#28773](https://github.com/ionic-team/ionic-framework/issues/28773)) ([9448783](https://github.com/ionic-team/ionic-framework/commit/9448783bb19b187f867054c86d215e3dc97952c1)), closes [#28769](https://github.com/ionic-team/ionic-framework/issues/28769)
+
+
+
+
+
## [7.6.6](https://github.com/ionic-team/ionic-framework/compare/v7.6.5...v7.6.6) (2024-01-24)
diff --git a/core/CHANGELOG.md b/core/CHANGELOG.md
index de77edeea8..c202684d81 100644
--- a/core/CHANGELOG.md
+++ b/core/CHANGELOG.md
@@ -3,6 +3,44 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
+## [7.7.1](https://github.com/ionic-team/ionic-framework/compare/v7.7.0...v7.7.1) (2024-02-07)
+
+
+### Bug Fixes
+
+* **action-sheet:** iOS dismiss animation respects safe area ([#28915](https://github.com/ionic-team/ionic-framework/issues/28915)) ([7449fb4](https://github.com/ionic-team/ionic-framework/commit/7449fb4fed4048f5d01ba068dc6f8e2d7727e95d)), closes [#28541](https://github.com/ionic-team/ionic-framework/issues/28541)
+* **overlays:** tear down animations after dismiss ([#28907](https://github.com/ionic-team/ionic-framework/issues/28907)) ([950fa40](https://github.com/ionic-team/ionic-framework/commit/950fa40c5597c81d5cbaeb9276b09adfea5e79fb)), closes [#28352](https://github.com/ionic-team/ionic-framework/issues/28352)
+* **select:** popover can be scrolled ([#28965](https://github.com/ionic-team/ionic-framework/issues/28965)) ([35ab6b4](https://github.com/ionic-team/ionic-framework/commit/35ab6b4816bd627239de8d8b25ce0c86db8c74b4)), closes [#28963](https://github.com/ionic-team/ionic-framework/issues/28963)
+
+
+
+
+
+# [7.7.0](https://github.com/ionic-team/ionic-framework/compare/v7.6.7...v7.7.0) (2024-01-31)
+
+
+### Features
+
+* add experimental hardware back button support in browsers ([#28705](https://github.com/ionic-team/ionic-framework/issues/28705)) ([658d1ca](https://github.com/ionic-team/ionic-framework/commit/658d1caccd530350843b85c0e24544ec27dd9eb4)), closes [#28703](https://github.com/ionic-team/ionic-framework/issues/28703)
+
+
+
+
+
+## [7.6.7](https://github.com/ionic-team/ionic-framework/compare/v7.6.6...v7.6.7) (2024-01-31)
+
+
+### Bug Fixes
+
+* **accordion:** prevent opening of readonly accordion using keyboard ([#28865](https://github.com/ionic-team/ionic-framework/issues/28865)) ([e10f49c](https://github.com/ionic-team/ionic-framework/commit/e10f49c43daa11fe7deb5a9b9bfd34897542b6b1)), closes [#28344](https://github.com/ionic-team/ionic-framework/issues/28344)
+* **action-sheet, alert, toast:** button roles autocomplete with available options ([#27940](https://github.com/ionic-team/ionic-framework/issues/27940)) ([f6fc22b](https://github.com/ionic-team/ionic-framework/commit/f6fc22bba60388701b80a9421510e3d843d39e9e)), closes [#27965](https://github.com/ionic-team/ionic-framework/issues/27965)
+* **item:** ensure button focus state on property change ([#28892](https://github.com/ionic-team/ionic-framework/issues/28892)) ([bf7922c](https://github.com/ionic-team/ionic-framework/commit/bf7922c8b37b32dbf90650cb74a2e77bedf0c118)), closes [#28525](https://github.com/ionic-team/ionic-framework/issues/28525)
+* **item:** only default slot content wraps ([#28773](https://github.com/ionic-team/ionic-framework/issues/28773)) ([9448783](https://github.com/ionic-team/ionic-framework/commit/9448783bb19b187f867054c86d215e3dc97952c1)), closes [#28769](https://github.com/ionic-team/ionic-framework/issues/28769)
+
+
+
+
+
## [7.6.6](https://github.com/ionic-team/ionic-framework/compare/v7.6.5...v7.6.6) (2024-01-24)
diff --git a/core/package-lock.json b/core/package-lock.json
index fac0a25cdd..58ea6e39df 100644
--- a/core/package-lock.json
+++ b/core/package-lock.json
@@ -1,32 +1,32 @@
{
"name": "@ionic/core",
- "version": "7.6.6",
+ "version": "7.7.1",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@ionic/core",
- "version": "7.6.6",
+ "version": "7.7.1",
"license": "MIT",
"dependencies": {
- "@stencil/core": "^4.10.0",
+ "@stencil/core": "^4.12.0",
"ionicons": "^7.2.2",
"tslib": "^2.1.0"
},
"devDependencies": {
- "@axe-core/playwright": "^4.8.3",
+ "@axe-core/playwright": "^4.8.4",
"@capacitor/core": "^5.6.0",
- "@capacitor/haptics": "^5.0.6",
- "@capacitor/keyboard": "^5.0.7",
- "@capacitor/status-bar": "^5.0.6",
+ "@capacitor/haptics": "^5.0.7",
+ "@capacitor/keyboard": "^5.0.8",
+ "@capacitor/status-bar": "^5.0.7",
"@ionic/eslint-config": "^0.3.0",
"@ionic/prettier-config": "^2.0.0",
"@playwright/test": "^1.39.0",
"@rollup/plugin-node-resolve": "^8.4.0",
"@rollup/plugin-virtual": "^2.0.3",
- "@stencil/angular-output-target": "^0.8.3",
+ "@stencil/angular-output-target": "^0.8.4",
"@stencil/react-output-target": "^0.5.3",
- "@stencil/sass": "^3.0.8",
+ "@stencil/sass": "^3.0.9",
"@stencil/vue-output-target": "^0.8.7",
"@types/jest": "^29.5.6",
"@types/node": "^14.6.0",
@@ -56,9 +56,9 @@
"dev": true
},
"node_modules/@axe-core/playwright": {
- "version": "4.8.3",
- "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.8.3.tgz",
- "integrity": "sha512-YtbkAWeOp5oQeI8vS6KYqJDa5yTl5O1wJP8KOZAAVjhxeiK/Y1ssxnZuGRobARyVh3eS6O3jdxTv/iCK1RfgaA==",
+ "version": "4.8.4",
+ "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.8.4.tgz",
+ "integrity": "sha512-xpwd+T0BODt19hnXW0eX9xf+H/Ns1rdWwZNmuCV9UoTqjZ9mGm1F80pvh/A1r317ooltq8nwqcoVO9jbHWKSdA==",
"dev": true,
"dependencies": {
"axe-core": "~4.8.3"
@@ -643,27 +643,27 @@
}
},
"node_modules/@capacitor/haptics": {
- "version": "5.0.6",
- "resolved": "https://registry.npmjs.org/@capacitor/haptics/-/haptics-5.0.6.tgz",
- "integrity": "sha512-UrMcR7p2X10ql4VLlowUuH/VckTeu0lj+RQpekxox14uxDmu5AGIFDK/iDTi8W6QZkxTJRZK6sbCjgwYgNJ7Pw==",
+ "version": "5.0.7",
+ "resolved": "https://registry.npmjs.org/@capacitor/haptics/-/haptics-5.0.7.tgz",
+ "integrity": "sha512-/j+7Qa4BxQA5aOU43cwXuiudfSXfoHFsAVfcehH5DkSjxLykZKWHEuE4uFJXqdkSIbAHjS37D0Sde6ENP6G/MA==",
"dev": true,
"peerDependencies": {
"@capacitor/core": "^5.0.0"
}
},
"node_modules/@capacitor/keyboard": {
- "version": "5.0.7",
- "resolved": "https://registry.npmjs.org/@capacitor/keyboard/-/keyboard-5.0.7.tgz",
- "integrity": "sha512-+6lW8z2nXTM2NOG7D7pOasCfIGicz26+EeDRXIj5AtJibbjwtE1Q5GIY+qGHgzpmwOF0qmcrGJBz4zagDwUapg==",
+ "version": "5.0.8",
+ "resolved": "https://registry.npmjs.org/@capacitor/keyboard/-/keyboard-5.0.8.tgz",
+ "integrity": "sha512-XYyBzGlzjgLPqyPVdu5McGLYV6+G2efVR4I3l5cF1B27M6U/oFqv9CQU74WNG08nee28bfccboNpv6eWCLYn1A==",
"dev": true,
"peerDependencies": {
"@capacitor/core": "^5.0.0"
}
},
"node_modules/@capacitor/status-bar": {
- "version": "5.0.6",
- "resolved": "https://registry.npmjs.org/@capacitor/status-bar/-/status-bar-5.0.6.tgz",
- "integrity": "sha512-7od8CxsBnot1XMK3IeOkproFL4hgoKoWAc3pwUvmDOkQsXoxwQm4SR9mLwQavv1XfxtHbFV9Ukd7FwMxOPSViw==",
+ "version": "5.0.7",
+ "resolved": "https://registry.npmjs.org/@capacitor/status-bar/-/status-bar-5.0.7.tgz",
+ "integrity": "sha512-KblB3gV2LDMEjx3fQoNBAzxb+Tr+2mv68SfFLLDCMiMUD3Eile2TAWRWd1yxy496pDFTOs2BJtup8++iuuuJ/w==",
"dev": true,
"peerDependencies": {
"@capacitor/core": "^5.0.0"
@@ -1816,18 +1816,18 @@
}
},
"node_modules/@stencil/angular-output-target": {
- "version": "0.8.3",
- "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-0.8.3.tgz",
- "integrity": "sha512-I/QO1sEx09WWUaNlA30EBhlXYftOSfSBTwYBwC65qlpHDIlD5WU3EAtKhU5IphfwhxnD63kvOoU1YvTUXFHNng==",
+ "version": "0.8.4",
+ "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-0.8.4.tgz",
+ "integrity": "sha512-QvmHTueXXs5vB9W2L12uEzFmAuR8sqATJV2b+SCFmYsjJSaymiSqR3dKo2wnr0tZiTgU1t16BWaUKiSh3wPXpw==",
"dev": true,
"peerDependencies": {
"@stencil/core": ">=2.0.0 || >=3 || >= 4.0.0-beta.0 || >= 4.0.0"
}
},
"node_modules/@stencil/core": {
- "version": "4.10.0",
- "resolved": "https://registry.npmjs.org/@stencil/core/-/core-4.10.0.tgz",
- "integrity": "sha512-7lDTPY1IxXN2/C+wQPHt3e/dYgY4YgelA8MxOsU3ZftXtpzWad/QNWhSAtKisJMrSjQh41jMDOgD0yLBwV6E7w==",
+ "version": "4.12.0",
+ "resolved": "https://registry.npmjs.org/@stencil/core/-/core-4.12.0.tgz",
+ "integrity": "sha512-qAQcfNmp2sdxAh1DlyUhHfDmIUS7mhI+5LAhPphg74zK9sKgFL5vpLzgjs0wohpjlmI4msgJFYiRB8lxVPqjPg==",
"bin": {
"stencil": "bin/stencil"
},
@@ -1846,9 +1846,9 @@
}
},
"node_modules/@stencil/sass": {
- "version": "3.0.8",
- "resolved": "https://registry.npmjs.org/@stencil/sass/-/sass-3.0.8.tgz",
- "integrity": "sha512-QJUG4Dr/b3wSizViwQXorrk1PJzxOsKkq5hSqtUHc3NNG3iomC4DQFYGeu15yNfoCDBtt4qkyHSCynsekQ8F6A==",
+ "version": "3.0.9",
+ "resolved": "https://registry.npmjs.org/@stencil/sass/-/sass-3.0.9.tgz",
+ "integrity": "sha512-GtPMjf5r4/BVBCO3LvcoMSIfOa6T+0wq+SrTGEilC4NCZpuZdAlZffWxXi80caZ1jDclwdzJ2qGwEgCAfvGoNA==",
"dev": true,
"engines": {
"node": ">=12.0.0",
@@ -10899,9 +10899,9 @@
},
"dependencies": {
"@axe-core/playwright": {
- "version": "4.8.3",
- "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.8.3.tgz",
- "integrity": "sha512-YtbkAWeOp5oQeI8vS6KYqJDa5yTl5O1wJP8KOZAAVjhxeiK/Y1ssxnZuGRobARyVh3eS6O3jdxTv/iCK1RfgaA==",
+ "version": "4.8.4",
+ "resolved": "https://registry.npmjs.org/@axe-core/playwright/-/playwright-4.8.4.tgz",
+ "integrity": "sha512-xpwd+T0BODt19hnXW0eX9xf+H/Ns1rdWwZNmuCV9UoTqjZ9mGm1F80pvh/A1r317ooltq8nwqcoVO9jbHWKSdA==",
"dev": true,
"requires": {
"axe-core": "~4.8.3"
@@ -11333,23 +11333,23 @@
}
},
"@capacitor/haptics": {
- "version": "5.0.6",
- "resolved": "https://registry.npmjs.org/@capacitor/haptics/-/haptics-5.0.6.tgz",
- "integrity": "sha512-UrMcR7p2X10ql4VLlowUuH/VckTeu0lj+RQpekxox14uxDmu5AGIFDK/iDTi8W6QZkxTJRZK6sbCjgwYgNJ7Pw==",
+ "version": "5.0.7",
+ "resolved": "https://registry.npmjs.org/@capacitor/haptics/-/haptics-5.0.7.tgz",
+ "integrity": "sha512-/j+7Qa4BxQA5aOU43cwXuiudfSXfoHFsAVfcehH5DkSjxLykZKWHEuE4uFJXqdkSIbAHjS37D0Sde6ENP6G/MA==",
"dev": true,
"requires": {}
},
"@capacitor/keyboard": {
- "version": "5.0.7",
- "resolved": "https://registry.npmjs.org/@capacitor/keyboard/-/keyboard-5.0.7.tgz",
- "integrity": "sha512-+6lW8z2nXTM2NOG7D7pOasCfIGicz26+EeDRXIj5AtJibbjwtE1Q5GIY+qGHgzpmwOF0qmcrGJBz4zagDwUapg==",
+ "version": "5.0.8",
+ "resolved": "https://registry.npmjs.org/@capacitor/keyboard/-/keyboard-5.0.8.tgz",
+ "integrity": "sha512-XYyBzGlzjgLPqyPVdu5McGLYV6+G2efVR4I3l5cF1B27M6U/oFqv9CQU74WNG08nee28bfccboNpv6eWCLYn1A==",
"dev": true,
"requires": {}
},
"@capacitor/status-bar": {
- "version": "5.0.6",
- "resolved": "https://registry.npmjs.org/@capacitor/status-bar/-/status-bar-5.0.6.tgz",
- "integrity": "sha512-7od8CxsBnot1XMK3IeOkproFL4hgoKoWAc3pwUvmDOkQsXoxwQm4SR9mLwQavv1XfxtHbFV9Ukd7FwMxOPSViw==",
+ "version": "5.0.7",
+ "resolved": "https://registry.npmjs.org/@capacitor/status-bar/-/status-bar-5.0.7.tgz",
+ "integrity": "sha512-KblB3gV2LDMEjx3fQoNBAzxb+Tr+2mv68SfFLLDCMiMUD3Eile2TAWRWd1yxy496pDFTOs2BJtup8++iuuuJ/w==",
"dev": true,
"requires": {}
},
@@ -12177,16 +12177,16 @@
}
},
"@stencil/angular-output-target": {
- "version": "0.8.3",
- "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-0.8.3.tgz",
- "integrity": "sha512-I/QO1sEx09WWUaNlA30EBhlXYftOSfSBTwYBwC65qlpHDIlD5WU3EAtKhU5IphfwhxnD63kvOoU1YvTUXFHNng==",
+ "version": "0.8.4",
+ "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-0.8.4.tgz",
+ "integrity": "sha512-QvmHTueXXs5vB9W2L12uEzFmAuR8sqATJV2b+SCFmYsjJSaymiSqR3dKo2wnr0tZiTgU1t16BWaUKiSh3wPXpw==",
"dev": true,
"requires": {}
},
"@stencil/core": {
- "version": "4.10.0",
- "resolved": "https://registry.npmjs.org/@stencil/core/-/core-4.10.0.tgz",
- "integrity": "sha512-7lDTPY1IxXN2/C+wQPHt3e/dYgY4YgelA8MxOsU3ZftXtpzWad/QNWhSAtKisJMrSjQh41jMDOgD0yLBwV6E7w=="
+ "version": "4.12.0",
+ "resolved": "https://registry.npmjs.org/@stencil/core/-/core-4.12.0.tgz",
+ "integrity": "sha512-qAQcfNmp2sdxAh1DlyUhHfDmIUS7mhI+5LAhPphg74zK9sKgFL5vpLzgjs0wohpjlmI4msgJFYiRB8lxVPqjPg=="
},
"@stencil/react-output-target": {
"version": "0.5.3",
@@ -12196,9 +12196,9 @@
"requires": {}
},
"@stencil/sass": {
- "version": "3.0.8",
- "resolved": "https://registry.npmjs.org/@stencil/sass/-/sass-3.0.8.tgz",
- "integrity": "sha512-QJUG4Dr/b3wSizViwQXorrk1PJzxOsKkq5hSqtUHc3NNG3iomC4DQFYGeu15yNfoCDBtt4qkyHSCynsekQ8F6A==",
+ "version": "3.0.9",
+ "resolved": "https://registry.npmjs.org/@stencil/sass/-/sass-3.0.9.tgz",
+ "integrity": "sha512-GtPMjf5r4/BVBCO3LvcoMSIfOa6T+0wq+SrTGEilC4NCZpuZdAlZffWxXi80caZ1jDclwdzJ2qGwEgCAfvGoNA==",
"dev": true,
"requires": {}
},
diff --git a/core/package.json b/core/package.json
index 3a4680c85c..f6a9fdf962 100644
--- a/core/package.json
+++ b/core/package.json
@@ -1,6 +1,6 @@
{
"name": "@ionic/core",
- "version": "7.6.6",
+ "version": "7.7.1",
"description": "Base components for Ionic",
"keywords": [
"ionic",
@@ -31,24 +31,24 @@
"loader/"
],
"dependencies": {
- "@stencil/core": "^4.10.0",
+ "@stencil/core": "^4.12.0",
"ionicons": "^7.2.2",
"tslib": "^2.1.0"
},
"devDependencies": {
- "@axe-core/playwright": "^4.8.3",
+ "@axe-core/playwright": "^4.8.4",
"@capacitor/core": "^5.6.0",
- "@capacitor/haptics": "^5.0.6",
- "@capacitor/keyboard": "^5.0.7",
- "@capacitor/status-bar": "^5.0.6",
+ "@capacitor/haptics": "^5.0.7",
+ "@capacitor/keyboard": "^5.0.8",
+ "@capacitor/status-bar": "^5.0.7",
"@ionic/eslint-config": "^0.3.0",
"@ionic/prettier-config": "^2.0.0",
"@playwright/test": "^1.39.0",
"@rollup/plugin-node-resolve": "^8.4.0",
"@rollup/plugin-virtual": "^2.0.3",
- "@stencil/angular-output-target": "^0.8.3",
+ "@stencil/angular-output-target": "^0.8.4",
"@stencil/react-output-target": "^0.5.3",
- "@stencil/sass": "^3.0.8",
+ "@stencil/sass": "^3.0.9",
"@stencil/vue-output-target": "^0.8.7",
"@types/jest": "^29.5.6",
"@types/node": "^14.6.0",
diff --git a/core/src/components/accordion/test/a11y/index.html b/core/src/components/accordion/test/a11y/index.html
index 0c660ef8dd..e8bd7a67e0 100644
--- a/core/src/components/accordion/test/a11y/index.html
+++ b/core/src/components/accordion/test/a11y/index.html
@@ -23,28 +23,22 @@
- Name
-
+
- Email
-
+
- Phone
-
+
- Extension
-
+
- Country
-
+
- City/Province
-
+
@@ -56,24 +50,19 @@
- Address 1
-
+
- Address 2
-
+
- City
-
+
- State
-
+
- Zip Code
-
+
@@ -85,24 +74,19 @@
- Address 1
-
+
- Address 2
-
+
- City
-
+
- State
-
+
- Zip Code
-
+
diff --git a/core/src/components/action-sheet/action-sheet-interface.ts b/core/src/components/action-sheet/action-sheet-interface.ts
index 90e4e99a26..f9cc06cd32 100644
--- a/core/src/components/action-sheet/action-sheet-interface.ts
+++ b/core/src/components/action-sheet/action-sheet-interface.ts
@@ -1,4 +1,4 @@
-import type { AnimationBuilder, Mode } from '../../interface';
+import type { AnimationBuilder, LiteralUnion, Mode } from '../../interface';
export interface ActionSheetOptions {
header?: string;
@@ -19,7 +19,7 @@ export interface ActionSheetOptions {
export interface ActionSheetButton {
text?: string;
- role?: 'cancel' | 'destructive' | 'selected' | string;
+ role?: LiteralUnion<'cancel' | 'destructive' | 'selected', string>;
icon?: string;
cssClass?: string | string[];
id?: string;
diff --git a/core/src/components/action-sheet/action-sheet.ios.scss b/core/src/components/action-sheet/action-sheet.ios.scss
index bf591b9493..672b072872 100644
--- a/core/src/components/action-sheet/action-sheet.ios.scss
+++ b/core/src/components/action-sheet/action-sheet.ios.scss
@@ -27,7 +27,24 @@
// ---------------------------------------------------
.action-sheet-wrapper {
- @include margin(var(--ion-safe-area-top, 0), auto, var(--ion-safe-area-bottom, 0), auto);
+ @include margin(var(--ion-safe-area-top, 0), auto, null, auto);
+ /**
+ * Bottom safe area is applied as padding so that it impacts the bounding box.
+ * When the action sheet is shown/hidden, this element is transformed by translating
+ * 100% of its height. This translation needs to include the bottom safe area
+ * otherwise part of the action sheet will still be visible at the end of
+ * the show transition.
+ *
+ * If this code is changed, reviewers should verify that the action
+ * sheet still translates out of the viewport completely when the bottom
+ * safe area is a positive value.
+ */
+ @include padding(null, null, var(--ion-safe-area-bottom, 0), null);
+
+ // Using content-box to increase the height of the action sheet
+ // wrapper by the bottom padding (safe area) to animate the
+ // action sheet completely off the screen when safe area is set.
+ box-sizing: content-box;
}
// iOS Action Sheet Container
diff --git a/core/src/components/alert/alert-interface.ts b/core/src/components/alert/alert-interface.ts
index 3f9d6cda8d..326d74484d 100644
--- a/core/src/components/alert/alert-interface.ts
+++ b/core/src/components/alert/alert-interface.ts
@@ -1,4 +1,4 @@
-import type { AnimationBuilder, Mode, TextFieldTypes } from '../../interface';
+import type { AnimationBuilder, LiteralUnion, Mode, TextFieldTypes } from '../../interface';
import type { IonicSafeString } from '../../utils/sanitization';
export interface AlertOptions {
@@ -45,7 +45,7 @@ type AlertButtonOverlayHandler = boolean | void | { [key: string]: any };
export interface AlertButton {
text: string;
- role?: 'cancel' | 'destructive' | string;
+ role?: LiteralUnion<'cancel' | 'destructive', string>;
cssClass?: string | string[];
id?: string;
htmlAttributes?: { [key: string]: any };
diff --git a/core/src/components/app/app.tsx b/core/src/components/app/app.tsx
index b0fc4731b3..44a67d2a15 100644
--- a/core/src/components/app/app.tsx
+++ b/core/src/components/app/app.tsx
@@ -1,6 +1,8 @@
import type { ComponentInterface } from '@stencil/core';
import { Build, Component, Element, Host, Method, h } from '@stencil/core';
import type { FocusVisibleUtility } from '@utils/focus-visible';
+import { shoudUseCloseWatcher } from '@utils/hardware-back-button';
+import { printIonWarning } from '@utils/logging';
import { isPlatform } from '@utils/platform';
import { config } from '../../global/config';
@@ -34,9 +36,20 @@ export class App implements ComponentInterface {
import('../../utils/input-shims/input-shims').then((module) => module.startInputShims(config, platform));
}
const hardwareBackButtonModule = await import('../../utils/hardware-back-button');
- if (config.getBoolean('hardwareBackButton', isHybrid)) {
+ const supportsHardwareBackButtonEvents = isHybrid || shoudUseCloseWatcher();
+ if (config.getBoolean('hardwareBackButton', supportsHardwareBackButtonEvents)) {
hardwareBackButtonModule.startHardwareBackButton();
} else {
+ /**
+ * If an app sets hardwareBackButton: false and experimentalCloseWatcher: true
+ * then the close watcher will not be used.
+ */
+ if (shoudUseCloseWatcher()) {
+ printIonWarning(
+ 'experimentalCloseWatcher was set to `true`, but hardwareBackButton was set to `false`. Both config options must be `true` for the Close Watcher API to be used.'
+ );
+ }
+
hardwareBackButtonModule.blockHardwareBackButton();
}
if (typeof (window as any) !== 'undefined') {
diff --git a/core/src/components/button/test/basic/button.e2e.ts b/core/src/components/button/test/basic/button.e2e.ts
index 2480c2fb2f..51635161b0 100644
--- a/core/src/components/button/test/basic/button.e2e.ts
+++ b/core/src/components/button/test/basic/button.e2e.ts
@@ -57,7 +57,7 @@ configs({ modes: ['md'] }).forEach(({ config, screenshot, title }) => {
await page.mouse.down();
}
- await page.waitForSelector('#default.ion-activated');
+ await page.locator('#default.ion-activated').waitFor();
await expect(button).toHaveScreenshot(screenshot(`button-ripple-effect`));
});
diff --git a/core/src/components/datetime-button/test/basic/datetime-button.e2e.ts b/core/src/components/datetime-button/test/basic/datetime-button.e2e.ts
index cde4a5f150..9a4b90f884 100644
--- a/core/src/components/datetime-button/test/basic/datetime-button.e2e.ts
+++ b/core/src/components/datetime-button/test/basic/datetime-button.e2e.ts
@@ -32,7 +32,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
});
test('should switch to a date-only view when the date button is clicked', async ({ page }) => {
const datetime = page.locator('ion-datetime');
@@ -62,7 +62,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('Jan 1, 2022');
await expect(page.locator('#time-button')).toContainText('6:30 AM');
@@ -75,7 +75,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('January 2022');
await expect(page.locator('#time-button')).toBeHidden();
@@ -88,7 +88,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('2022');
await expect(page.locator('#time-button')).toBeHidden();
@@ -101,7 +101,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('January');
await expect(page.locator('#time-button')).toBeHidden();
@@ -114,7 +114,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#time-button')).toContainText('6:30 AM');
await expect(page.locator('#date-button')).toBeHidden();
@@ -127,7 +127,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const dateTarget = page.locator('#date-button');
@@ -152,7 +152,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('January 2022');
await expect(page.locator('#time-button')).toBeHidden();
@@ -170,7 +170,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('2022');
await expect(page.locator('#time-button')).toBeHidden();
@@ -186,7 +186,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
/**
* The entire text reads 1 ene 2022, but some browsers will add
@@ -204,7 +204,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#time-button')).toContainText('16:30');
});
@@ -216,7 +216,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const timeTarget = page.locator('#time-button');
await expect(timeTarget).toContainText('6:30');
@@ -240,7 +240,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('Jan 1, 2022 6:30 AM');
await expect(page.locator('#time-button')).not.toBeVisible();
@@ -255,7 +255,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('Jan 1, 2022 6:30 AM');
await expect(page.locator('#time-button')).not.toBeVisible();
diff --git a/core/src/components/datetime-button/test/buttons/index.html b/core/src/components/datetime-button/test/buttons/index.html
index 2b6f1f7bcc..ca484632b9 100644
--- a/core/src/components/datetime-button/test/buttons/index.html
+++ b/core/src/components/datetime-button/test/buttons/index.html
@@ -18,7 +18,7 @@
-
+
diff --git a/core/src/components/datetime-button/test/disabled/datetime-button.e2e.ts b/core/src/components/datetime-button/test/disabled/datetime-button.e2e.ts
index 23ef52821f..f8f45fd49c 100644
--- a/core/src/components/datetime-button/test/disabled/datetime-button.e2e.ts
+++ b/core/src/components/datetime-button/test/disabled/datetime-button.e2e.ts
@@ -11,7 +11,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, screenshot, co
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toBeDisabled();
await expect(page.locator('#time-button')).toBeDisabled();
@@ -24,7 +24,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, screenshot, co
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetimeButton = page.locator('ion-datetime-button');
await expect(datetimeButton).toHaveScreenshot(screenshot(`datetime-button-disabled`));
diff --git a/core/src/components/datetime-button/test/multiple/datetime-button.e2e.ts b/core/src/components/datetime-button/test/multiple/datetime-button.e2e.ts
index 901ddc74be..598124b1b0 100644
--- a/core/src/components/datetime-button/test/multiple/datetime-button.e2e.ts
+++ b/core/src/components/datetime-button/test/multiple/datetime-button.e2e.ts
@@ -20,7 +20,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toContainText('3 days');
});
@@ -32,7 +32,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toHaveText('0 days');
});
@@ -49,7 +49,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toHaveText('Jun 1, 2022');
});
@@ -69,7 +69,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toHaveText('Selected: 3');
});
@@ -86,7 +86,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const ionValueChange = await page.spyOnEvent('ionValueChange');
@@ -111,7 +111,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page.locator('#date-button')).toHaveText('Jun 1, 2022');
await expect(page.locator('#time-button')).toHaveText('4:30 PM');
diff --git a/core/src/components/datetime/test/a11y/datetime.e2e.ts b/core/src/components/datetime/test/a11y/datetime.e2e.ts
index 79deb85e23..374798f2fa 100644
--- a/core/src/components/datetime/test/a11y/datetime.e2e.ts
+++ b/core/src/components/datetime/test/a11y/datetime.e2e.ts
@@ -24,7 +24,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
const container = page.locator('#container');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(container).toHaveScreenshot(screenshot(`datetime-scale`));
});
@@ -87,7 +87,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const clearButton = page.locator('#clear-button button');
const selectedDay = page.locator('.calendar-day-active');
@@ -114,7 +114,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
const calendarBody = page.locator('.calendar-body');
await expect(calendarMonthYear).toHaveText('February 2022');
diff --git a/core/src/components/datetime/test/basic/datetime.e2e.ts b/core/src/components/datetime/test/basic/datetime.e2e.ts
index 1482ad3da1..8581fe385b 100644
--- a/core/src/components/datetime/test/basic/datetime.e2e.ts
+++ b/core/src/components/datetime/test/basic/datetime.e2e.ts
@@ -110,7 +110,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const ionChange = await page.spyOnEvent('ionChange');
@@ -255,7 +255,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarBody = page.locator('ion-datetime .calendar-body');
const calendarHeader = page.locator('ion-datetime .calendar-month-year');
@@ -275,7 +275,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarBody = page.locator('ion-datetime .calendar-body');
const calendarHeader = page.locator('ion-datetime .calendar-month-year');
@@ -297,7 +297,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarBody = page.locator('ion-datetime .calendar-body');
const calendarHeader = page.locator('ion-datetime .calendar-month-year');
@@ -331,7 +331,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const monthYearButton = page.locator('ion-datetime .calendar-month-year');
const monthYearInterface = page.locator('ion-datetime .datetime-year');
@@ -349,7 +349,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
await datetime.evaluate((el: HTMLIonDatetimeElement) => el.style.removeProperty('display'));
await expect(datetime).toBeVisible();
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
// month/year interface should be reset
await expect(monthYearInterface).toBeHidden();
@@ -399,7 +399,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const selectedDay = page.locator('ion-datetime .calendar-day-active');
@@ -428,7 +428,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const calendarButtons = page.locator('.calendar-day:not([disabled])');
@@ -447,7 +447,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const datetime = page.locator('ion-datetime');
@@ -487,7 +487,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
const datetime = page.locator('ion-datetime');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(datetime.locator('.calendar-day-today')).toHaveScreenshot(
screenshot(`datetime-today-calendar-button`)
@@ -517,7 +517,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, screenshot, co
const datetime = page.locator('ion-datetime');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(datetime).toHaveScreenshot(screenshot(`date-highlight-start-of-month`));
@@ -543,7 +543,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
diff --git a/core/src/components/datetime/test/basic/index.html b/core/src/components/datetime/test/basic/index.html
index 153c85688a..2023b4a119 100644
--- a/core/src/components/datetime/test/basic/index.html
+++ b/core/src/components/datetime/test/basic/index.html
@@ -214,8 +214,7 @@
- Dark Mode
-
+ Dark Mode
iOS Mode
@@ -225,23 +224,19 @@
- Show Default Title
-
+ Show Default Title
- Show Default Buttons
-
+ Show Default Buttons
- Locale
-
+
- Color
-
+
Primary
Secondary
Tertiary
diff --git a/core/src/components/datetime/test/datetime.e2e.ts b/core/src/components/datetime/test/datetime.e2e.ts
index ec415946b6..2e26aad48e 100644
--- a/core/src/components/datetime/test/datetime.e2e.ts
+++ b/core/src/components/datetime/test/datetime.e2e.ts
@@ -11,7 +11,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
});
test('should switch the calendar header when moving to a month with a different number of days', async ({
diff --git a/core/src/components/datetime/test/disable-dates/datetime.e2e.ts b/core/src/components/datetime/test/disable-dates/datetime.e2e.ts
index 6ae7c54ea9..3fc4b88218 100644
--- a/core/src/components/datetime/test/disable-dates/datetime.e2e.ts
+++ b/core/src/components/datetime/test/disable-dates/datetime.e2e.ts
@@ -113,7 +113,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
test.describe('check example usages', () => {
test.beforeEach(async ({ page }) => {
await page.goto('/src/components/datetime/test/disable-dates', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').first().waitFor();
});
test('should disable a specific date', async ({ page }) => {
diff --git a/core/src/components/datetime/test/disabled/datetime.e2e.ts b/core/src/components/datetime/test/disabled/datetime.e2e.ts
index d794a2d2ef..91b48b736c 100644
--- a/core/src/components/datetime/test/disabled/datetime.e2e.ts
+++ b/core/src/components/datetime/test/disabled/datetime.e2e.ts
@@ -27,7 +27,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const febFirstButton = page.locator(`.calendar-day[data-day='1'][data-month='2']`);
@@ -42,7 +42,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
await expect(calendarMonthYear.locator('button')).toBeDisabled();
});
@@ -71,7 +71,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const clearButton = page.locator('#clear-button button');
@@ -86,7 +86,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
const calendarBody = page.locator('.calendar-body');
await expect(calendarMonthYear).toHaveText('February 2022');
diff --git a/core/src/components/datetime/test/display/datetime.e2e.ts b/core/src/components/datetime/test/display/datetime.e2e.ts
index 0fcb9db898..501bdfeeab 100644
--- a/core/src/components/datetime/test/display/datetime.e2e.ts
+++ b/core/src/components/datetime/test/display/datetime.e2e.ts
@@ -15,7 +15,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-date-time`));
});
@@ -26,7 +26,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-time-date`));
});
@@ -37,7 +37,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-time`));
});
@@ -48,7 +48,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-date`));
});
@@ -69,7 +69,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-cover-date-time`));
});
@@ -80,7 +80,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-cover-time-date`));
});
@@ -91,7 +91,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-cover-time`));
});
@@ -102,7 +102,7 @@ configs({ directions: ['ltr'] }).forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await expect(datetime).toHaveScreenshot(screenshot(`datetime-display-cover-date`));
});
@@ -119,7 +119,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
test('month selection should work after changing presentation', async ({ page }) => {
await page.goto('/src/components/datetime/test/display', config);
const ionWorkingPartsDidChange = await page.spyOnEvent('ionWorkingPartsDidChange');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const select = page.locator('select#presentation');
diff --git a/core/src/components/datetime/test/locale/datetime.e2e.ts b/core/src/components/datetime/test/locale/datetime.e2e.ts
index 6df37a77ba..2ffda6c97a 100644
--- a/core/src/components/datetime/test/locale/datetime.e2e.ts
+++ b/core/src/components/datetime/test/locale/datetime.e2e.ts
@@ -95,7 +95,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetimeButtons = page.locator('ion-datetime .calendar-day:not([disabled])');
@@ -111,7 +111,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetimeYear = page.locator('ion-datetime .year-column ion-picker-column-option').nth(0);
await expect(datetimeYear).toHaveText('٢٠٢٢');
@@ -146,7 +146,7 @@ class DatetimeLocaleFixture {
this.datetime = this.page.locator('ion-datetime');
- await this.page.waitForSelector('.datetime-ready');
+ await this.page.locator('.datetime-ready').waitFor();
}
async expectLocalizedDatePicker(screenshot: ScreenshotFn) {
diff --git a/core/src/components/datetime/test/minmax/datetime.e2e.ts b/core/src/components/datetime/test/minmax/datetime.e2e.ts
index b59c886e45..e7dd39abac 100644
--- a/core/src/components/datetime/test/minmax/datetime.e2e.ts
+++ b/core/src/components/datetime/test/minmax/datetime.e2e.ts
@@ -36,7 +36,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const prevButton = page.locator('ion-datetime .calendar-next-prev ion-button:nth-child(1)');
const nextButton = page.locator('ion-datetime .calendar-next-prev ion-button:nth-child(2)');
@@ -61,7 +61,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
await page.goto('/src/components/datetime/test/minmax', config);
const calendarMonths = page.locator('ion-datetime#inside .calendar-month');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').first().waitFor();
await expect(calendarMonths.nth(0)).not.toHaveClass(/calendar-month-disabled/);
await expect(calendarMonths.nth(1)).not.toHaveClass(/calendar-month-disabled/);
@@ -70,7 +70,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
test('datetime: minmax navigation disabled', async ({ page }) => {
await page.goto('/src/components/datetime/test/minmax', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').first().waitFor();
const navButtons = page.locator('ion-datetime#outside .calendar-next-prev ion-button');
@@ -80,7 +80,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
test('datetime: min including day should not disable month', async ({ page }) => {
await page.goto('/src/components/datetime/test/minmax', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').first().waitFor();
const calendarMonths = page.locator('ion-datetime#min-with-day .calendar-month');
@@ -102,7 +102,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionPopoverDidPresent = await page.spyOnEvent('ionPopoverDidPresent');
@@ -120,7 +120,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
test.describe('setting value outside bounds should show in-bounds month', () => {
const testDisplayedMonth = async (page: E2EPage, content: string, expectedString = /June 2021/) => {
await page.setContent(content, config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
await expect(calendarMonthYear).toHaveText(expectedString);
@@ -170,7 +170,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetimeMonthDidChange = await page.spyOnEvent('datetimeMonthDidChange');
const eventButton = page.locator('button#bind');
@@ -252,7 +252,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const ionChange = await page.spyOnEvent('ionChange');
@@ -275,7 +275,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const ionChange = await page.spyOnEvent('ionChange');
@@ -303,7 +303,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
const monthColumnItems = page.locator('ion-datetime .month-column ion-picker-column-option');
const ionChange = await page.spyOnEvent('ionChange');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await monthColumnItems.nth(0).click(); // switch to January
await ionChange.next();
@@ -338,7 +338,7 @@ configs({ directions: ['ltr'], modes: ['ios'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
// Select Jan 10, 2022
const maxDate = page.locator('ion-datetime .calendar-day[data-day="10"][data-month="1"][data-year="2022"]');
diff --git a/core/src/components/datetime/test/month-year-picker/datetime.e2e.ts b/core/src/components/datetime/test/month-year-picker/datetime.e2e.ts
index f894b0a0fe..4d2dc8e7dd 100644
--- a/core/src/components/datetime/test/month-year-picker/datetime.e2e.ts
+++ b/core/src/components/datetime/test/month-year-picker/datetime.e2e.ts
@@ -8,7 +8,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
test.describe(title('datetime: month-year picker'), () => {
test.beforeEach(async ({ page }) => {
await page.goto('/src/components/datetime/test/month-year-picker', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').first().waitFor();
});
test('should hide the footer when picker is open', async ({ page }) => {
diff --git a/core/src/components/datetime/test/multiple/datetime.e2e.ts b/core/src/components/datetime/test/multiple/datetime.e2e.ts
index c3a195b89b..0e2c0efb38 100644
--- a/core/src/components/datetime/test/multiple/datetime.e2e.ts
+++ b/core/src/components/datetime/test/multiple/datetime.e2e.ts
@@ -62,7 +62,7 @@ class DatetimeMultipleFixture {
);
this.datetime = this.page.locator('ion-datetime');
- await this.page.waitForSelector('.datetime-ready');
+ await this.page.locator('.datetime-ready').waitFor();
return this.datetime;
}
@@ -304,7 +304,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
`,
config
);
- await page.waitForSelector(`.datetime-ready`);
+ await page.locator(`.datetime-ready`).waitFor();
const datetime = page.locator('ion-datetime');
const header = datetime.locator('.datetime-selected-date');
diff --git a/core/src/components/datetime/test/position/datetime.e2e.ts b/core/src/components/datetime/test/position/datetime.e2e.ts
index f2f705c307..c817e3c6d0 100644
--- a/core/src/components/datetime/test/position/datetime.e2e.ts
+++ b/core/src/components/datetime/test/position/datetime.e2e.ts
@@ -11,7 +11,7 @@ configs().forEach(({ title, screenshot, config }) => {
await openDateTimeBtn.click();
await ionPopoverDidPresent.next();
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page).toHaveScreenshot(screenshot(`datetime-position-base`));
diff --git a/core/src/components/datetime/test/prefer-wheel/datetime.e2e.ts b/core/src/components/datetime/test/prefer-wheel/datetime.e2e.ts
index 5da7365797..fb1b2e31eb 100644
--- a/core/src/components/datetime/test/prefer-wheel/datetime.e2e.ts
+++ b/core/src/components/datetime/test/prefer-wheel/datetime.e2e.ts
@@ -23,7 +23,7 @@ configs().forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page).toHaveScreenshot(screenshot(`datetime-wheel-date-diff`));
});
@@ -34,7 +34,7 @@ configs().forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page).toHaveScreenshot(screenshot(`datetime-wheel-date-time-diff`));
});
@@ -45,7 +45,7 @@ configs().forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
await expect(page).toHaveScreenshot(screenshot(`datetime-wheel-time-date-diff`));
});
@@ -56,7 +56,7 @@ configs().forEach(({ title, screenshot, config }) => {
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
@@ -80,7 +80,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .day-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(27);
@@ -93,7 +93,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .day-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(1);
@@ -116,7 +116,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const disabledMonths = page.locator('.month-column ion-picker-column-option.option-disabled');
const disabledYears = page.locator('.year-column ion-picker-column-option.option-disabled');
@@ -141,7 +141,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const monthValues = page.locator('.month-column ion-picker-column-option');
const yearValues = page.locator('.year-column ion-picker-column-option');
@@ -175,7 +175,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const monthValues = page.locator('.month-column ion-picker-column-option');
@@ -209,7 +209,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const dayValues = page.locator('.day-column ion-picker-column-option');
@@ -230,7 +230,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const yearValues = page.locator('.year-column ion-picker-column-option');
@@ -253,7 +253,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await datetime.evaluate((el: HTMLIonDatetimeElement) => (el.value = '2021-05-25T12:40:00.000Z'));
@@ -285,7 +285,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const monthValues = page.locator('.month-column ion-picker-column-option');
const dayValues = page.locator('.day-column ion-picker-column-option');
@@ -305,7 +305,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const columns = page.locator('ion-picker-column');
@@ -326,7 +326,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const columns = page.locator('ion-picker-column');
@@ -345,7 +345,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .date-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(57);
@@ -358,7 +358,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .date-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(41);
@@ -381,7 +381,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const disabledDates = page.locator('.date-column ion-picker-column-option.option-disabled');
@@ -402,7 +402,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateValues = page.locator('.date-column ion-picker-column-option');
@@ -423,7 +423,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateValues = page.locator('.date-column ion-picker-column-option');
await expect(dateValues).toHaveText(['2月1日(火)', '2月2日(水)', '2月3日(木)']);
@@ -442,7 +442,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateColumn = page.locator('.date-column');
const dateColumnScrollEl = dateColumn.locator('.picker-opts');
@@ -473,7 +473,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('.date-column ion-picker-column-option');
@@ -493,7 +493,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('.date-column ion-picker-column-option');
@@ -510,7 +510,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const ionChange = await page.spyOnEvent('ionChange');
const dayValues = page.locator('.date-column ion-picker-column-option');
@@ -530,7 +530,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .date-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(57);
@@ -543,7 +543,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('ion-datetime .date-column ion-picker-column-option');
expect(await dayValues.count()).toEqual(41);
@@ -566,7 +566,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const disabledDates = page.locator('.date-column ion-picker-column-option.option-disabled');
@@ -587,7 +587,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateValues = page.locator('.date-column ion-picker-column-option');
@@ -608,7 +608,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateValues = page.locator('.date-column ion-picker-column-option');
@@ -628,7 +628,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dateColumn = page.locator('.date-column');
const dateColumnScrollEl = dateColumn.locator('.picker-opts');
@@ -659,7 +659,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('.date-column ion-picker-column-option');
@@ -679,7 +679,7 @@ configs({ modes: ['md'], directions: ['ltr'] }).forEach(({ title, config }) => {
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const dayValues = page.locator('.date-column ion-picker-column-option');
diff --git a/core/src/components/datetime/test/presentation/datetime.e2e.ts b/core/src/components/datetime/test/presentation/datetime.e2e.ts
index 9462cc2af4..4af756d516 100644
--- a/core/src/components/datetime/test/presentation/datetime.e2e.ts
+++ b/core/src/components/datetime/test/presentation/datetime.e2e.ts
@@ -117,7 +117,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const monthYearButton = page.locator('ion-datetime .calendar-month-year');
@@ -189,7 +189,7 @@ class DatetimePresentationFixture {
`,
config
);
- await this.page.waitForSelector('.datetime-ready');
+ await this.page.locator('.datetime-ready').waitFor();
this.datetime = this.page.locator('ion-datetime');
}
@@ -214,7 +214,7 @@ class TimePickerFixture {
`,
config
);
- await this.page.waitForSelector('.datetime-ready');
+ await this.page.locator('.datetime-ready').waitFor();
this.timePicker = this.page.locator('ion-datetime');
}
diff --git a/core/src/components/datetime/test/readonly/datetime.e2e.ts b/core/src/components/datetime/test/readonly/datetime.e2e.ts
index ea47e7ded8..288eded09f 100644
--- a/core/src/components/datetime/test/readonly/datetime.e2e.ts
+++ b/core/src/components/datetime/test/readonly/datetime.e2e.ts
@@ -27,7 +27,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const febFirstButton = page.locator(`.calendar-day[data-day='1'][data-month='2']`);
@@ -43,7 +43,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
);
const ionChange = await page.spyOnEvent('ionChange');
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
await expect(calendarMonthYear).toHaveText('February 2022');
@@ -66,7 +66,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
const tabKey = browserName === 'webkit' ? 'Alt+Tab' : 'Tab';
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const calendarMonthYear = page.locator('ion-datetime .calendar-month-year');
const monthYearButton = page.locator('.calendar-month-year-toggle');
await expect(calendarMonthYear).toHaveText('February 2022');
@@ -157,7 +157,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config, scree
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const clearButton = page.locator('#clear-button button');
diff --git a/core/src/components/datetime/test/set-value/datetime.e2e.ts b/core/src/components/datetime/test/set-value/datetime.e2e.ts
index 798b87144a..37daadf2b8 100644
--- a/core/src/components/datetime/test/set-value/datetime.e2e.ts
+++ b/core/src/components/datetime/test/set-value/datetime.e2e.ts
@@ -5,7 +5,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
test.describe(title('datetime: set-value'), () => {
test('should update the active date when value is initially set', async ({ page }) => {
await page.goto('/src/components/datetime/test/set-value', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await datetime.evaluate((el: HTMLIonDatetimeElement) => (el.value = '2021-11-25T12:40:00.000Z'));
@@ -18,7 +18,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
test('should update the active time when value is initially set', async ({ page }) => {
await page.goto('/src/components/datetime/test/set-value', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await datetime.evaluate((el: HTMLIonDatetimeElement) => (el.value = '2021-11-25T12:40:00.000Z'));
@@ -37,7 +37,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
const activeDayButton = page.locator('.calendar-day-active');
@@ -53,7 +53,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
test('should scroll to new month when value is initially set and then updated', async ({ page }) => {
await page.goto('/src/components/datetime/test/set-value', config);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const datetime = page.locator('ion-datetime');
await datetime.evaluate((el: HTMLIonDatetimeElement) => (el.value = '2021-05-25T12:40:00.000Z'));
diff --git a/core/src/components/datetime/test/time-label/datetime.e2e.ts b/core/src/components/datetime/test/time-label/datetime.e2e.ts
index cf3fb9f780..88acbbe857 100644
--- a/core/src/components/datetime/test/time-label/datetime.e2e.ts
+++ b/core/src/components/datetime/test/time-label/datetime.e2e.ts
@@ -10,7 +10,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const timeLabel = page.locator('ion-datetime .time-header');
await expect(timeLabel).toHaveText('Time');
@@ -22,7 +22,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const timeLabel = page.locator('ion-datetime .time-header');
await expect(timeLabel).toHaveText('');
diff --git a/core/src/components/datetime/test/values/datetime.e2e.ts b/core/src/components/datetime/test/values/datetime.e2e.ts
index 23a9e4a382..9001d61b91 100644
--- a/core/src/components/datetime/test/values/datetime.e2e.ts
+++ b/core/src/components/datetime/test/values/datetime.e2e.ts
@@ -10,7 +10,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
`,
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const items = page.locator('.calendar-day:not([disabled])');
@@ -91,7 +91,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const minuteColumn = page.locator('ion-picker-column').nth(1);
const minuteItems = minuteColumn.locator('ion-picker-column-option');
@@ -139,7 +139,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const monthItems = page.locator('.month-column ion-picker-column-option');
await expect(monthItems).toHaveText(['January']);
@@ -171,7 +171,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
config
);
- await page.waitForSelector('.datetime-ready');
+ await page.locator('.datetime-ready').waitFor();
const todayButton = page.locator('.calendar-day[data-day="10"][data-month="10"][data-year="2022"]');
diff --git a/core/src/components/header/test/condense/header.e2e.ts b/core/src/components/header/test/condense/header.e2e.ts
index c2ac59efd0..791c1b720a 100644
--- a/core/src/components/header/test/condense/header.e2e.ts
+++ b/core/src/components/header/test/condense/header.e2e.ts
@@ -16,7 +16,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, screenshot, c
await content.evaluate(async (el: HTMLIonContentElement) => {
await el.scrollToBottom();
});
- await page.waitForSelector('#largeTitleHeader.header-collapse-condense-inactive');
+ await page.locator('#largeTitleHeader.header-collapse-condense-inactive').waitFor();
await expect(smallTitleHeader).toHaveScreenshot(screenshot(`header-condense-large-title-collapsed-diff`));
@@ -30,7 +30,7 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, screenshot, c
await content.evaluate(async (el: HTMLIonContentElement) => {
await el.scrollToTop();
});
- await page.waitForSelector('#smallTitleHeader.header-collapse-condense-inactive');
+ await page.locator('#smallTitleHeader.header-collapse-condense-inactive').waitFor();
await expect(smallTitleHeader).toHaveAttribute('aria-hidden', 'true');
});
diff --git a/core/src/components/item/item.scss b/core/src/components/item/item.scss
index 94329434c3..aa52b7b953 100644
--- a/core/src/components/item/item.scss
+++ b/core/src/components/item/item.scss
@@ -51,15 +51,6 @@
* @prop --highlight-color-valid: The color of the highlight on the item when valid. Only applies to inputs and textareas using the legacy form syntax. DEPRECATED: Highlights can be styled on `ion-input` or `ion-textarea` when using the modern form syntax.
* @prop --highlight-color-invalid: The color of the highlight on the item when invalid. Only applies to inputs and textareas using the legacy form syntax. DEPRECATED: Highlights can be styled on `ion-input` or `ion-textarea` when using the modern form syntax.
*/
-
- /**
- * We change the minimum width as the
- * font size changes. Using a fixed minimum
- * width means that fewer and fewer characters
- * can be displayed in the same space as the
- * text grows.
- */
- --inner-min-width: 4rem;
--border-radius: 0px;
--border-width: 0px;
--border-style: solid;
@@ -230,11 +221,6 @@
display: flex;
position: relative;
- // Flex wrap is required here in order to wrap
- // the start slot + .item-inner content that
- // doesn't fit on the same line
- flex-wrap: wrap;
-
align-items: inherit;
justify-content: inherit;
@@ -258,11 +244,6 @@
box-sizing: border-box;
}
-// TODO(FW-5289): remove
-:host(.item-legacy) .item-native {
- flex-wrap: unset;
-}
-
.item-native::-moz-focus-inner {
border: 0;
}
@@ -307,34 +288,13 @@ button, a {
// This is required to work with an inset highlight
position: relative;
- // This flex property is required in order to make
- // the elements wrap when there is a slotted start
- // element and a label
- flex: 1 0 0;
+ flex: 1;
flex-direction: inherit;
- // Flex wrap is required here in order to wrap
- // .input-wrapper content + the end slot that
- // doesn't fit on the same line
- flex-wrap: wrap;
-
align-items: inherit;
align-self: stretch;
- /**
- * The min-width defines when the
- * content in the default slot should
- * stop wrapping/truncating within its own
- * container. At this point the entire
- * container will wrap to the next line.
- */
- min-width: var(--inner-min-width);
-
- // Max width must be set to 100%, otherwise the
- // elements will overflow this container instead
- // of wrapping
- max-width: 100%;
min-height: inherit;
border-width: var(--inner-border-width);
@@ -346,15 +306,6 @@ button, a {
box-sizing: border-box;
}
-// TODO(FW-5289): remove
-:host(.item-legacy) .item-inner {
- flex: 1;
-
- flex-wrap: unset;
-
- max-width: unset;
-}
-
// Item Bottom
// --------------------------------------------------
@@ -448,38 +399,19 @@ button, a {
// This flex property is required in order to keep
// the label from shrinking when there are wide
// elements next to it
- flex: 1 0 auto;
+ flex: 1;
flex-direction: inherit;
- // Flex wrap is required here in order to wrap
- // content in the default slot (such as a label
- // and a button) that doesn't fit on the same line
- flex-wrap: wrap;
-
align-items: inherit;
align-self: stretch;
- // Max width must be set to 100%, otherwise the
- // elements will overflow this container instead
- // of wrapping
- max-width: 100%;
-
text-overflow: ellipsis;
overflow: inherit;
box-sizing: border-box;
}
-// TODO(FW-5289): remove
-:host(.item-legacy) .input-wrapper {
- flex: 1;
-
- flex-wrap: unset;
-
- max-width: unset;
-}
-
:host(.item-label-stacked),
:host(.item-label-floating) {
align-items: start;
diff --git a/core/src/components/item/item.tsx b/core/src/components/item/item.tsx
index ad056c5cdf..c6c18d4e98 100644
--- a/core/src/components/item/item.tsx
+++ b/core/src/components/item/item.tsx
@@ -150,6 +150,12 @@ export class Item implements ComponentInterface, AnchorInterface, ButtonInterfac
@State() counterString: string | null | undefined;
+ @Watch('button')
+ buttonChanged() {
+ // Update the focusable option when the button option is changed
+ this.focusable = this.isFocusable();
+ }
+
@Watch('counterFormatter')
counterFormatterChanged() {
this.updateCounterOutput(this.getFirstInput());
diff --git a/core/src/components/item/test/a11y/index.html b/core/src/components/item/test/a11y/index.html
index 9aad84631c..18fb4d703d 100644
--- a/core/src/components/item/test/a11y/index.html
+++ b/core/src/components/item/test/a11y/index.html
@@ -16,23 +16,19 @@
Item
- Item with Input
-
+
- Item disabled with Input
-
+
- Item with Input disabled
-
+
- Item with Select
-
+
No Game Console
NES
Nintendo64
@@ -44,8 +40,7 @@
- Item disabled with Select
-
+
No Game Console
NES
Nintendo64
@@ -57,8 +52,7 @@
- Item with Select disabled
-
+
No Game Console
NES
Nintendo64
@@ -70,33 +64,27 @@
- Item with Toggle
-
+ Item with Toggle
- Item disabled with Toggle
-
+ Item disabled with Toggle
- Item with Toggle disabled
-
+ Item with Toggle disabled
- Item with Radio
-
+ Item with Radio
- Item disabled with Radio
-
+ Item disabled with Radio
- Item with Radio disabled
-
+ Item with Radio disabled