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

[material-ui][Snackbar] Deprecate *Component and *Props #42314

Closed
wants to merge 28 commits into from

Conversation

fedirjh
Copy link
Contributor

@fedirjh fedirjh commented May 21, 2024

Part of: #41281

Description

  • Deprecate TransitionComponent in favor of slots.

  • Deprecate TransitionProps, ClickAwayListenerProps and ContentProps in favor of slotProps.

  • Added snackbar-props section in the migration guide

  • Added snackbar-props codemod

  • I have followed (at least) the PR section of the contributing guide.

@fedirjh fedirjh marked this pull request as ready for review May 21, 2024 13:04
@zannager zannager added the component: snackbar This is the name of the generic UI component, not the React module! label May 21, 2024
@zannager zannager requested a review from DiegoAndai May 21, 2024 13:17
Updated Snackbar component's `ClickAwayListenerProps`, `ContentProps`, and `TransitionProps` to now be accessed via the `slotProps` prop for standardization and backwards compatibility. Deprecated the use of individual prop usage, set to be removed in v7.
Updated the Snackbar component in various test cases and documentation to reflect the deprecation of 'ClickAwayListenerProps' and 'ContentProps'. These properties are now recommended to be defined within 'slotProps'. Adjusted codemod transformations to handle this change.
All the slot props (`*Props`) in Snackbar have been marked as deprecated and replaced with equivalent `slotProps` entries. This change is reflected in both the migration guide and the README file of the mui-codemod package.
@fedirjh fedirjh changed the title [material-ui][Snackbar] Deprecate TransitionComponent and TransitionProps [material-ui][Snackbar] Deprecate *Component and *Props May 21, 2024
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label May 23, 2024
# Conflicts:
#	packages/mui-codemod/README.md
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label May 24, 2024
Streamlined the test logic for snackbar-props deprecations by using the describeJscodeshiftTransform utility.
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label May 24, 2024
# Conflicts:
#	packages/mui-codemod/README.md
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label May 24, 2024
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label May 24, 2024
# Conflicts:
#	packages/mui-codemod/src/deprecations/all/deprecations-all.js
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label May 25, 2024
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label May 29, 2024
# Conflicts:
#	packages/mui-codemod/src/deprecations/all/deprecations-all.js
@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label May 30, 2024
@DiegoAndai
Copy link
Member

Hey @fedirjh! thanks for working on this. Please see #41281 (comment).

@fedirjh fedirjh closed this May 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: snackbar This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants