Skip to content

Commit 32effbd

Browse files
Merge branch 'next' into FW-6987-next
2 parents 0be7a77 + 1b21e07 commit 32effbd

File tree

45 files changed

+663
-111
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+663
-111
lines changed

.github/workflows/actions/download-archive/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ inputs:
1010
runs:
1111
using: 'composite'
1212
steps:
13-
- uses: actions/download-artifact@v6
13+
- uses: actions/download-artifact@v7
1414
with:
1515
name: ${{ inputs.name }}
1616
path: ${{ inputs.path }}

.github/workflows/actions/test-core-screenshot/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ runs:
6262
working-directory: ./core
6363
- name: 📦 Archive Updated Screenshots
6464
if: inputs.update == 'true' && steps.test-and-update.outputs.hasUpdatedScreenshots == 'true'
65-
uses: actions/upload-artifact@v5
65+
uses: actions/upload-artifact@v6
6666
with:
6767
name: updated-screenshots-${{ inputs.shard }}-${{ inputs.totalShards }}
6868
path: UpdatedScreenshots-${{ inputs.shard }}-${{ inputs.totalShards }}.zip

.github/workflows/actions/update-reference-screenshots/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ runs:
1010
- uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
1111
with:
1212
node-version: 24.x
13-
- uses: actions/download-artifact@v6
13+
- uses: actions/download-artifact@v7
1414
with:
1515
path: ./artifacts
1616
- name: 🔎 Extract Archives

.github/workflows/actions/upload-archive/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ runs:
1313
- name: 🗄️ Create Archive
1414
run: zip -q -r ${{ inputs.output }} ${{ inputs.paths }}
1515
shell: bash
16-
- uses: actions/upload-artifact@v5
16+
- uses: actions/upload-artifact@v6
1717
with:
1818
name: ${{ inputs.name }}
1919
path: ${{ inputs.output }}

CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,25 @@
33
All notable changes to this project will be documented in this file.
44
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
55

6+
## [8.7.14](https://github.com/ionic-team/ionic-framework/compare/v8.7.13...v8.7.14) (2025-12-17)
7+
8+
9+
### Bug Fixes
10+
11+
* **tabs:** select correct tab when routes have similar prefixes ([#30863](https://github.com/ionic-team/ionic-framework/issues/30863)) ([03fb422](https://github.com/ionic-team/ionic-framework/commit/03fb422bfa775e3e9dd695ea1857fa88d4245ecd)), closes [#30448](https://github.com/ionic-team/ionic-framework/issues/30448)
12+
13+
14+
15+
16+
17+
## [8.7.13](https://github.com/ionic-team/ionic-framework/compare/v8.7.12...v8.7.13) (2025-12-13)
18+
19+
**Note:** Version bump only for package ionic-framework
20+
21+
22+
23+
24+
625
## [8.7.12](https://github.com/ionic-team/ionic-framework/compare/v8.7.11...v8.7.12) (2025-12-10)
726

827

core/CHANGELOG.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,22 @@
33
All notable changes to this project will be documented in this file.
44
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
55

6+
## [8.7.14](https://github.com/ionic-team/ionic-framework/compare/v8.7.13...v8.7.14) (2025-12-17)
7+
8+
**Note:** Version bump only for package @ionic/core
9+
10+
11+
12+
13+
14+
## [8.7.13](https://github.com/ionic-team/ionic-framework/compare/v8.7.12...v8.7.13) (2025-12-13)
15+
16+
**Note:** Version bump only for package @ionic/core
17+
18+
19+
20+
21+
622
## [8.7.12](https://github.com/ionic-team/ionic-framework/compare/v8.7.11...v8.7.12) (2025-12-10)
723

824

core/package-lock.json

Lines changed: 22 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

core/package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"name": "@ionic/core",
3-
"version": "8.7.12",
3+
"version": "8.7.14",
44
"description": "Base components for Ionic",
55
"engines": {
6-
"node": "24.x"
6+
"node": ">= 16"
77
},
88
"keywords": [
99
"ionic",
@@ -41,10 +41,10 @@
4141
},
4242
"devDependencies": {
4343
"@axe-core/playwright": "^4.11.0",
44-
"@capacitor/core": "^7.0.0",
45-
"@capacitor/haptics": "^7.0.0",
46-
"@capacitor/keyboard": "^7.0.0",
47-
"@capacitor/status-bar": "^7.0.0",
44+
"@capacitor/core": "^8.0.0",
45+
"@capacitor/haptics": "^8.0.0",
46+
"@capacitor/keyboard": "^8.0.0",
47+
"@capacitor/status-bar": "^8.0.0",
4848
"@clack/prompts": "^0.11.0",
4949
"@ionic/eslint-config": "^0.3.0",
5050
"@ionic/prettier-config": "^2.0.0",

core/src/utils/hardware-back-button.ts

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { win } from '@utils/browser';
21
import type { CloseWatcher } from '@utils/browser';
2+
import { win } from '@utils/browser';
33
import { printIonError } from '@utils/logging';
44

55
import { config } from '../global/config';
@@ -69,6 +69,21 @@ export const startHardwareBackButton = () => {
6969
});
7070
doc.dispatchEvent(ev);
7171

72+
/**
73+
* If no handlers have been registered, fall back to the default
74+
* behavior of navigating back in history. This ensures the hardware
75+
* back button works even when no router or custom handler is present.
76+
*/
77+
if (handlers.length === 0) {
78+
handlers.push({
79+
priority: FALLBACK_BACK_BUTTON_PRIORITY,
80+
handler: () => {
81+
win?.history.back();
82+
},
83+
id: index++,
84+
});
85+
}
86+
7287
const executeAction = async (handlerRegister: HandlerRegister | undefined) => {
7388
try {
7489
if (handlerRegister?.handler) {
@@ -138,3 +153,4 @@ export const startHardwareBackButton = () => {
138153

139154
export const OVERLAY_BACK_BUTTON_PRIORITY = 100;
140155
export const MENU_BACK_BUTTON_PRIORITY = 99; // 1 less than overlay priority since menu is displayed behind overlays
156+
const FALLBACK_BACK_BUTTON_PRIORITY = -1; // Fallback when no other handlers are registered

core/src/utils/test/hardware-back-button.spec.ts

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,47 @@ describe('Hardware Back Button', () => {
5454
dispatchBackButtonEvent();
5555
expect(cbSpyTwo).toHaveBeenCalled();
5656
});
57+
58+
it('should fall back to history.back() when no handlers are registered', () => {
59+
const historyBackSpy = jest.fn();
60+
const originalBack = win?.history?.back;
61+
if (win?.history) {
62+
win.history.back = historyBackSpy;
63+
}
64+
65+
// Don't register any ionBackButton handlers
66+
dispatchBackButtonEvent();
67+
68+
expect(historyBackSpy).toHaveBeenCalled();
69+
70+
// Restore original
71+
if (win?.history && originalBack) {
72+
win.history.back = originalBack;
73+
}
74+
});
75+
76+
it('should not call history.back() when a handler is registered', () => {
77+
const historyBackSpy = jest.fn();
78+
const originalBack = win?.history?.back;
79+
if (win?.history) {
80+
win.history.back = historyBackSpy;
81+
}
82+
83+
const cbSpy = jest.fn();
84+
document.addEventListener('ionBackButton', (ev) => {
85+
(ev as BackButtonEvent).detail.register(0, cbSpy);
86+
});
87+
88+
dispatchBackButtonEvent();
89+
90+
expect(cbSpy).toHaveBeenCalled();
91+
expect(historyBackSpy).not.toHaveBeenCalled();
92+
93+
// Restore original
94+
if (win?.history && originalBack) {
95+
win.history.back = originalBack;
96+
}
97+
});
5798
});
5899

59100
describe('Experimental Close Watcher', () => {

0 commit comments

Comments
 (0)