Skip to content

Conversation

@OS-pedrolourenco
Copy link
Contributor

Issue number: internal


What is the current behavior?

The radio-group's wrapper div is responsible for several issues that have been reported, specially due to making it so that radio elements are not direct children of radio-groups. Now it is also causing problems on the OutSystems side.

What is the new behavior?

The solution involved:

  • Removing the radio-group-wrapper div, which was first added as a workaround to a Stencil issue where radio children would incorrectly fire blur events on focus;
  • Converting the radio-group into a shadow component as another workaround to the Stencil issue;
  • Adjusting the radio-group's styling to the new changes.

Does this introduce a breaking change?

  • Yes
  • No

Other information

@vercel
Copy link

vercel bot commented Dec 3, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
ionic-framework Ready Ready Preview Comment Dec 5, 2025 10:44am

@github-actions github-actions bot added the package: core @ionic/core package label Dec 3, 2025
@OS-pedrolourenco OS-pedrolourenco changed the title refactor(radio-group): refactor(radio-group): remove radio-group-wrapper and use shadow DOM Dec 3, 2025
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.

Looking good, just a few requests!


ion-radio-group {
// Prevents additional pixels from being rendered on top
vertical-align: top;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This became unnecessary by introducing display: block

.radio-group-top {
@include globals.typography(globals.$ion-body-sm-medium);

margin-bottom: globals.$ion-space-400;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This margin was being overridden on the OS side, thus this style makes no sense to exist here. Will remove the override as well.

@brandyscarney brandyscarney changed the title refactor(radio-group): remove radio-group-wrapper and use shadow DOM feat(radio-group): remove radio-group-wrapper and convert to shadow DOM Dec 4, 2025
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.

LGTM! Great work! 🚀

Can we add a section in the breaking changes document that radio group has been converted to shadow: https://github.com/ionic-team/ionic-framework/blob/next/BREAKING.md

Here's an example of when we converted modal in v6: https://github.com/ionic-team/ionic-framework/blob/next/BREAKING_ARCHIVE/v6.md#modal

@OS-pedrolourenco OS-pedrolourenco merged commit 9555a2a into next Dec 5, 2025
49 checks passed
@OS-pedrolourenco OS-pedrolourenco deleted the ROU-12377 branch December 5, 2025 11:25
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.

3 participants