Skip to content

Conversation

@tanner-reits
Copy link
Contributor

@tanner-reits tanner-reits commented Nov 19, 2024

Issue number: resolves internal


What is the current behavior?

Using Tab or Shift + Tab to focus through elements in a modal won't behave as expected when using ion-checkbox or ion-radio within an ion-item. Previously, the behavior would result in the last item in a list getting focus styling, but document.activeElement would still be the first actionable item in the overlay

What is the new behavior?

For checkboxes, the ion-checkbox element itself will be focused rather than the encapsulating ion-item

For radios, the ion-radio-group will be used to focus the appropriate element. This will be the first ion-radio if there is no "checked" item, or the "checked" item if one exists.

Does this introduce a breaking change?

  • Yes
  • No

Other information

@vercel
Copy link

vercel bot commented Nov 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
ionic-framework ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 19, 2024 8:58pm

@github-actions github-actions bot added the package: core @ionic/core package label Nov 19, 2024
@tanner-reits tanner-reits marked this pull request as ready for review November 19, 2024 21:40
@tanner-reits tanner-reits requested a review from a team as a code owner November 19, 2024 21:40
Copy link
Member

@brandyscarney brandyscarney left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works great!

Copy link
Contributor

@thetaPC thetaPC left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@tanner-reits tanner-reits added this pull request to the merge queue Nov 21, 2024
Merged via the queue into main with commit 8ee42bb Nov 21, 2024
49 checks passed
@tanner-reits tanner-reits deleted the tr/ROU-11339-overlay-focus-trap branch November 21, 2024 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants