Skip to content

Comments

[backdrop] Remove aria-hidden by default#47798

Merged
silviuaavram merged 2 commits intomui:masterfrom
silviuaavram:fix/remove-backdrop-aria-hidden
Feb 23, 2026
Merged

[backdrop] Remove aria-hidden by default#47798
silviuaavram merged 2 commits intomui:masterfrom
silviuaavram:fix/remove-backdrop-aria-hidden

Conversation

@silviuaavram
Copy link
Member

@silviuaavram silviuaavram commented Feb 17, 2026

It's bascially #34691 from @chapmanm3 but opened this PR because:

  • rebase
  • Modal now receives aria-hidden directly from useModal so no need to add it again there.

Fixes #33146

Copilot AI review requested due to automatic review settings February 17, 2026 13:01
@silviuaavram silviuaavram added accessibility a11y breaking change Introduces changes that are not backward compatible. scope: backdrop This is the name of the generic UI component, not the React module! v9.x labels Feb 17, 2026
@mui-bot
Copy link

mui-bot commented Feb 17, 2026

Netlify deploy preview

Bundle size report

Bundle Parsed size Gzip size
@mui/material ▼-17B(0.00%) 🔺+1B(0.00%)
@mui/lab 0B(0.00%) 0B(0.00%)
@mui/system 0B(0.00%) 0B(0.00%)
@mui/utils 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against 4ef0c36

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates Backdrop accessibility defaults to address issue #33146 by removing the unconditional aria-hidden attribute, relying on Modal’s useModal-provided props to apply aria-hidden only where appropriate (e.g., Modal backdrops).

Changes:

  • Remove default aria-hidden from Backdrop’s root slot to avoid hiding Backdrop children from assistive tech.
  • Shift responsibility for aria-hidden to Modal’s backdrop props path (via useModal.getBackdropProps), aligning with the issue’s intent.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@silviuaavram silviuaavram changed the title [material-ui][Backdrop] Add aria-hidden by default [material-ui][Backdrop] Remove aria-hidden by default Feb 17, 2026
Copy link
Member

@ZeeshanTamboli ZeeshanTamboli left a comment

Choose a reason for hiding this comment

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

Looks good. Only the entry needs to be added in the "upgrade to v9" guide.

@ZeeshanTamboli ZeeshanTamboli changed the title [material-ui][Backdrop] Remove aria-hidden by default [backdrop] Remove aria-hidden by default Feb 19, 2026
@silviuaavram silviuaavram force-pushed the fix/remove-backdrop-aria-hidden branch from 8898c2b to 6be0bfa Compare February 19, 2026 10:40
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Feb 20, 2026
@silviuaavram silviuaavram force-pushed the fix/remove-backdrop-aria-hidden branch from 6be0bfa to d72a0d3 Compare February 23, 2026 09:59
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Feb 23, 2026
@silviuaavram silviuaavram force-pushed the fix/remove-backdrop-aria-hidden branch from d72a0d3 to 4ef0c36 Compare February 23, 2026 10:02
@silviuaavram silviuaavram merged commit f8aae0a into mui:master Feb 23, 2026
23 checks passed
@silviuaavram silviuaavram deleted the fix/remove-backdrop-aria-hidden branch February 23, 2026 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

accessibility a11y breaking change Introduces changes that are not backward compatible. scope: backdrop This is the name of the generic UI component, not the React module! v9.x

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[material-ui][Backdrop] aria-hidden is set by default

3 participants