Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(accordion): add skip-accordion-toggle attribute #30292

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

eduardoRoth
Copy link
Contributor

Issue number: resolves #30291


What is the current behavior?

Any component that is clicked inside the slot="header" of an Accordion component will trigger the ionChange event if it's inside an Accordion Group.

You can stop this by using event.stopPropagation() on the component inside the Accordion header, but sometimes you require the event to bubble up, for example when using a Radio Group. In those cases, if you stop the event from bubbling, the Radio Group won't update it's value.

What is the new behavior?

By adding a skip-accordion-toggle attribute to any element inside the slot="header" it will allow the event to bubble up while skipping the accordion from being toggled.

Does this introduce a breaking change?

  • Yes
  • No

Other information

N/A

@eduardoRoth eduardoRoth requested a review from a team as a code owner March 21, 2025 17:42
@eduardoRoth eduardoRoth requested a review from ShaneK March 21, 2025 17:42
Copy link

vercel bot commented Mar 21, 2025

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 Mar 21, 2025 5:44pm

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.

feat: add skip-accordion-toggle attribute
1 participant