Skip to content

[accordion] Remove deprecated props#47963

Open
silviuaavram wants to merge 3 commits intomui:masterfrom
silviuaavram:chore/remove-accordion-deprecated-props
Open

[accordion] Remove deprecated props#47963
silviuaavram wants to merge 3 commits intomui:masterfrom
silviuaavram:chore/remove-accordion-deprecated-props

Conversation

@silviuaavram
Copy link
Member

@silviuaavram silviuaavram commented Mar 13, 2026

Removes accordion deprecated props, the changes are done by agent.

Copilot AI review requested due to automatic review settings March 13, 2026 09:13
@silviuaavram silviuaavram added breaking change Introduces changes that are not backward compatible. scope: autocomplete Changes related to the autocomplete. This includes ComboBox. type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. v9.x labels Mar 13, 2026
@mui-bot
Copy link

mui-bot commented Mar 13, 2026

Netlify deploy preview

Bundle size report

Bundle Parsed size Gzip size
@mui/material ▼-84B(-0.02%) ▼-55B(-0.04%)
@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 b3474b2

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

Removes previously-deprecated Accordion transition customization props (TransitionComponent, TransitionProps) as part of the v9 API surface, standardizing on the slots/slotProps customization model.

Changes:

  • Remove TransitionComponent / TransitionProps from Accordion implementation, TS types, PropTypes, and API docs.
  • Update Accordion tests to use slots.transition / slotProps.transition.
  • Document the breaking removal in the v9 upgrade guide.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/mui-material/src/Accordion/Accordion.js Removes legacy transition props wiring and PropTypes entries.
packages/mui-material/src/Accordion/Accordion.d.ts Removes legacy transition props from the public TypeScript API.
packages/mui-material/src/Accordion/Accordion.test.js Migrates tests from legacy props to slots/slotProps.
docs/pages/material-ui/api/accordion.json Removes legacy props from generated API docs JSON.
docs/data/material/migration/upgrade-to-v9/upgrade-to-v9.md Adds v9 migration notes for the removed props.
Comments suppressed due to low confidence (1)

packages/mui-material/src/Accordion/Accordion.test.js:252

  • Now that the legacy TransitionComponent/TransitionProps props are removed, it would be good to add a regression test asserting they are not forwarded to the DOM (e.g., rendering <Accordion TransitionComponent={...} /> should not set a TransitionComponent attribute on the root). This will catch accidental reintroductions of React unknown-prop warnings while still allowing apps to upgrade incrementally.
  describe('slotProps.transition', () => {
    it('should apply properties to the Transition component', () => {
      render(
        <Accordion slotProps={{ transition: { 'data-testid': 'transition-testid' } }}>
          {minimalChildren}
        </Accordion>,
      );

      expect(screen.getByTestId('transition-testid')).not.to.equal(null);

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

You can also share your feedback on Copilot code review. Take the survey.

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Mar 13, 2026
@silviuaavram silviuaavram force-pushed the chore/remove-accordion-deprecated-props branch from 0e8b4ba to 1b6f975 Compare March 13, 2026 14:40
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged. label Mar 13, 2026
```

#### Accordion deprecated props removed

Copy link
Member

Choose a reason for hiding this comment

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

@silviuaavram silviuaavram force-pushed the chore/remove-accordion-deprecated-props branch from 1b6f975 to b3474b2 Compare March 16, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change Introduces changes that are not backward compatible. scope: autocomplete Changes related to the autocomplete. This includes ComboBox. type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. v9.x

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants