Skip to content

Commit 9674438

Browse files
merge main (#30454)
2 parents 1563b7b + 6afcd53 commit 9674438

Some content is hidden

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

54 files changed

+863
-375
lines changed

.github/ionic-issue-bot.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ stale:
9393
- "triage"
9494
- "type: bug"
9595
- "type: feature request"
96+
- "needs: investigation"
9697
exemptAssigned: true
9798
exemptProjects: true
9899
exemptMilestones: true

CHANGELOG.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,40 @@
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.5.9](https://github.com/ionic-team/ionic-framework/compare/v8.5.8...v8.5.9) (2025-06-04)
7+
8+
9+
### Bug Fixes
10+
11+
* **datetime:** display the correct month when multiple values are set ([#29610](https://github.com/ionic-team/ionic-framework/issues/29610)) ([14f32f8](https://github.com/ionic-team/ionic-framework/commit/14f32f8feea7b3880367868ff0a2134b0c28cc07)), closes [#29094](https://github.com/ionic-team/ionic-framework/issues/29094)
12+
* **modal:** move sheet footers instead of cloning while dragging ([#30433](https://github.com/ionic-team/ionic-framework/issues/30433)) ([4cbbbb0](https://github.com/ionic-team/ionic-framework/commit/4cbbbb053ad36d176f1d79ad09777f94ca8076d2)), closes [#30315](https://github.com/ionic-team/ionic-framework/issues/30315) [#30341](https://github.com/ionic-team/ionic-framework/issues/30341) [#30312](https://github.com/ionic-team/ionic-framework/issues/30312)
13+
14+
15+
16+
17+
18+
## [8.5.8](https://github.com/ionic-team/ionic-framework/compare/v8.5.7...v8.5.8) (2025-05-28)
19+
20+
21+
### Bug Fixes
22+
23+
* **input-password-toggle, button:** force update aria attributes ([#30411](https://github.com/ionic-team/ionic-framework/issues/30411)) ([4e38700](https://github.com/ionic-team/ionic-framework/commit/4e387005663b4e8425cb28e41608bb4f924b3864))
24+
25+
26+
27+
28+
29+
## [8.5.7](https://github.com/ionic-team/ionic-framework/compare/v8.5.6...v8.5.7) (2025-05-07)
30+
31+
32+
### Bug Fixes
33+
34+
* **labels:** prevent clicking a label from triggering onClick twice on several components ([#30384](https://github.com/ionic-team/ionic-framework/issues/30384)) ([7d639b0](https://github.com/ionic-team/ionic-framework/commit/7d639b0412120523f758942c855cb69f9a52e9d9)), closes [#30165](https://github.com/ionic-team/ionic-framework/issues/30165)
35+
36+
37+
38+
39+
640
## [8.5.6](https://github.com/ionic-team/ionic-framework/compare/v8.5.5...v8.5.6) (2025-04-30)
741

842

core/CHANGELOG.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,40 @@
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.5.9](https://github.com/ionic-team/ionic-framework/compare/v8.5.8...v8.5.9) (2025-06-04)
7+
8+
9+
### Bug Fixes
10+
11+
* **datetime:** display the correct month when multiple values are set ([#29610](https://github.com/ionic-team/ionic-framework/issues/29610)) ([14f32f8](https://github.com/ionic-team/ionic-framework/commit/14f32f8feea7b3880367868ff0a2134b0c28cc07)), closes [#29094](https://github.com/ionic-team/ionic-framework/issues/29094)
12+
* **modal:** move sheet footers instead of cloning while dragging ([#30433](https://github.com/ionic-team/ionic-framework/issues/30433)) ([4cbbbb0](https://github.com/ionic-team/ionic-framework/commit/4cbbbb053ad36d176f1d79ad09777f94ca8076d2)), closes [#30315](https://github.com/ionic-team/ionic-framework/issues/30315) [#30341](https://github.com/ionic-team/ionic-framework/issues/30341) [#30312](https://github.com/ionic-team/ionic-framework/issues/30312)
13+
14+
15+
16+
17+
18+
## [8.5.8](https://github.com/ionic-team/ionic-framework/compare/v8.5.7...v8.5.8) (2025-05-28)
19+
20+
21+
### Bug Fixes
22+
23+
* **input-password-toggle, button:** force update aria attributes ([#30411](https://github.com/ionic-team/ionic-framework/issues/30411)) ([4e38700](https://github.com/ionic-team/ionic-framework/commit/4e387005663b4e8425cb28e41608bb4f924b3864))
24+
25+
26+
27+
28+
29+
## [8.5.7](https://github.com/ionic-team/ionic-framework/compare/v8.5.6...v8.5.7) (2025-05-07)
30+
31+
32+
### Bug Fixes
33+
34+
* **labels:** prevent clicking a label from triggering onClick twice on several components ([#30384](https://github.com/ionic-team/ionic-framework/issues/30384)) ([7d639b0](https://github.com/ionic-team/ionic-framework/commit/7d639b0412120523f758942c855cb69f9a52e9d9)), closes [#30165](https://github.com/ionic-team/ionic-framework/issues/30165)
35+
36+
37+
38+
39+
640
## [8.5.6](https://github.com/ionic-team/ionic-framework/compare/v8.5.5...v8.5.6) (2025-04-30)
741

842

core/package-lock.json

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

core/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ionic/core",
3-
"version": "8.5.6",
3+
"version": "8.5.9",
44
"description": "Base components for Ionic",
55
"keywords": [
66
"ionic",
@@ -41,7 +41,7 @@
4141
"@capacitor/haptics": "^7.0.0",
4242
"@capacitor/keyboard": "^7.0.0",
4343
"@capacitor/status-bar": "^7.0.0",
44-
"@clack/prompts": "^0.10.0",
44+
"@clack/prompts": "^0.11.0",
4545
"@ionic/eslint-config": "^0.3.0",
4646
"@ionic/prettier-config": "^2.0.0",
4747
"@playwright/test": "^1.52.0",

core/src/components.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2928,7 +2928,7 @@ export namespace Components {
29282928
*/
29292929
"cancelButtonIcon": string;
29302930
/**
2931-
* Set the the cancel button text. Only applies to `ios` mode.
2931+
* Set the cancel button text. Only applies to `ios` mode.
29322932
* @default 'Cancel'
29332933
*/
29342934
"cancelButtonText": string;
@@ -8188,7 +8188,7 @@ declare namespace LocalJSX {
81888188
*/
81898189
"cancelButtonIcon"?: string;
81908190
/**
8191-
* Set the the cancel button text. Only applies to `ios` mode.
8191+
* Set the cancel button text. Only applies to `ios` mode.
81928192
* @default 'Cancel'
81938193
*/
81948194
"cancelButtonText"?: string;

core/src/components/button/button.tsx

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { ComponentInterface, EventEmitter } from '@stencil/core';
2-
import { Component, Element, Event, Host, Prop, Watch, State, h } from '@stencil/core';
2+
import { Component, Element, Event, Host, Prop, Watch, State, forceUpdate, h } from '@stencil/core';
33
import type { AnchorInterface, ButtonInterface } from '@utils/element-interface';
44
import type { Attributes } from '@utils/helpers';
55
import { inheritAriaAttributes, hasShadowDom } from '@utils/helpers';
@@ -158,6 +158,26 @@ export class Button implements ComponentInterface, AnchorInterface, ButtonInterf
158158
*/
159159
@Event() ionBlur!: EventEmitter<void>;
160160

161+
/**
162+
* This component is used within the `ion-input-password-toggle` component
163+
* to toggle the visibility of the password input.
164+
* These attributes need to update based on the state of the password input.
165+
* Otherwise, the values will be stale.
166+
*
167+
* @param newValue
168+
* @param _oldValue
169+
* @param propName
170+
*/
171+
@Watch('aria-checked')
172+
@Watch('aria-label')
173+
onAriaChanged(newValue: string, _oldValue: string, propName: string) {
174+
this.inheritedAttributes = {
175+
...this.inheritedAttributes,
176+
[propName]: newValue,
177+
};
178+
forceUpdate(this);
179+
}
180+
161181
/**
162182
* This is responsible for rendering a hidden native
163183
* button element inside the associated form. This allows

core/src/components/checkbox/checkbox.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,14 @@ export class Checkbox implements ComponentInterface {
199199
this.toggleChecked(ev);
200200
};
201201

202+
/**
203+
* Stops propagation when the display label is clicked,
204+
* otherwise, two clicks will be triggered.
205+
*/
206+
private onDivLabelClick = (ev: MouseEvent) => {
207+
ev.stopPropagation();
208+
};
209+
202210
private getHintTextID(): string | undefined {
203211
const { el, helperText, errorText, helperTextId, errorTextId } = this;
204212

@@ -314,6 +322,7 @@ export class Checkbox implements ComponentInterface {
314322
}}
315323
part="label"
316324
id={this.inputLabelId}
325+
onClick={this.onDivLabelClick}
317326
>
318327
<slot></slot>
319328
{this.renderHintText()}

core/src/components/checkbox/test/basic/checkbox.e2e.ts

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,4 +99,38 @@ configs({ modes: ['ios'], directions: ['ltr'] }).forEach(({ title, config }) =>
9999
expect(ionChange).not.toHaveReceivedEvent();
100100
});
101101
});
102+
103+
test.describe(title('checkbox: click'), () => {
104+
test('should trigger onclick only once when clicking the label', async ({ page }, testInfo) => {
105+
testInfo.annotations.push({
106+
type: 'issue',
107+
description: 'https://github.com/ionic-team/ionic-framework/issues/30165',
108+
});
109+
110+
// Create a spy function in page context
111+
await page.setContent(`<ion-checkbox onclick="console.log('click called')">Test Checkbox</ion-checkbox>`, config);
112+
113+
// Track calls to the exposed function
114+
let clickCount = 0;
115+
page.on('console', (msg) => {
116+
if (msg.text().includes('click called')) {
117+
clickCount++;
118+
}
119+
});
120+
121+
const input = page.locator('div.label-text-wrapper');
122+
123+
// Use position to make sure we click into the label enough to trigger
124+
// what would be the double click
125+
await input.click({
126+
position: {
127+
x: 5,
128+
y: 5,
129+
},
130+
});
131+
132+
// Verify the click was triggered exactly once
133+
expect(clickCount).toBe(1);
134+
});
135+
});
102136
});

0 commit comments

Comments
 (0)