[material-ui][ListItem] Document *Component and *Props props deprecations#42263
Merged
aarongarciah merged 1 commit intomui:nextfrom May 23, 2024
Conversation
aarongarciah
commented
May 16, 2024
|
|
||
| ### ContainerComponent | ||
|
|
||
| The ListItem's `ContainerComponent` prop was deprecated in favor of `slots.root` or `component` instead. |
Member
Author
There was a problem hiding this comment.
slots.root and component are not a direct replacement for ContainerComponent, since the latter was only rendered if the consumers was using ListItemSecondaryAction, but not sure it's worth going into more detail here.
Netlify deploy previewBundle size report |
aarongarciah
commented
May 16, 2024
| * The container component used when a `ListItemSecondaryAction` is the last child. | ||
| * @default 'li' | ||
| * @deprecated | ||
| * @deprecated Use the `component` or `slots.root` prop instead. This prop will be removed in v7. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details. |
Member
Author
There was a problem hiding this comment.
"Use the component or slots.root prop instead" is not semantically correct since slots.root is not a prop, but I think it's ok. Let me know what you think.
636acca to
5be838c
Compare
*Component and *Props prop deprecations
*Component and *Props prop deprecations*Component and *Props props deprecations
5be838c to
a9e02fc
Compare
DiegoAndai
approved these changes
May 23, 2024
a9e02fc to
e189029
Compare
joserodolfofreitas
pushed a commit
to joserodolfofreitas/material-ui
that referenced
this pull request
Jul 29, 2024
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
ListItem'sContainerComponentandContainerPropsprops were deprecated 3 years ago, but not officially in the docs. This PR just makes the deprecation official adding it to the docs.This deprecation goes hand in hand with
ListItemSecondaryActiondeprecation, so we should probably wait for #42251 to be merged first.Preview link: https://deploy-preview-42263--material-ui.netlify.app/material-ui/migration/migrating-from-deprecated-apis/#listitem