-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
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
[Accordion] Fix invalid HTML inside heading #44408
Open
ZeeshanTamboli
wants to merge
35
commits into
mui:master
Choose a base branch
from
ZeeshanTamboli:issue-44153-accordion
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ZeeshanTamboli
added
the
component: accordion
This is the name of the generic UI component, not the React module!
label
Nov 14, 2024
Netlify deploy previewhttps://deploy-preview-44408--material-ui.netlify.app/ Bundle size reportDetails of bundle changes (Toolpad) |
oliviertassinari
changed the title
[material-ui][Accordion] Fix invalid HTML inside heading
[Accordion] Fix invalid HTML inside heading
Nov 15, 2024
…boli/material-ui into issue-44153-accordion
ZeeshanTamboli
added
bug 🐛
Something doesn't work
breaking change
package: material-ui
Specific to @mui/material
regression
A bug, but worse
labels
Nov 18, 2024
github-actions
bot
added
the
PR: out-of-date
The pull request has merge conflicts and can't be merged
label
Nov 18, 2024
github-actions
bot
removed
the
PR: out-of-date
The pull request has merge conflicts and can't be merged
label
Nov 19, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
breaking change
bug 🐛
Something doesn't work
component: accordion
This is the name of the generic UI component, not the React module!
package: material-ui
Specific to @mui/material
regression
A bug, but worse
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #44153
This PR resolves a regression introduced in #42914 by making the following changes to ensure valid HTML structure for the Accordion component:
button
.span
.Additionally, typography has been removed from the demos since the
p
element rendered by Typography is invalid inside aspan
. Typography styles are now applied directly to the summary button usingtheme.typography.body1
, making the extra Typography component unnecessary.Breaking Change
button
.span
.div
element for styling in the AccordionSummary should update their styling. Additionally, those using Typography, which defaults to rendering ap
tag, should replace it with aspan
or remove it for valid HTML, as shown in the updated demos.These changes are critical to fix the regression but introduce a breaking change. IMO, this should be released in a minor version (
v6.x
) and documented in the migration guide. I know this is not ideal but the fix is also important.If approved, I’ll include a note in the migration guide detailing these changes.