-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
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][InputLabel] Changed size prop value from normal
to medium
#45235
base: master
Are you sure you want to change the base?
Conversation
15739d7
to
e92e0cf
Compare
e92e0cf
to
222959d
Compare
normal
to medium
normal
to medium
normal
to medium
normal
to medium
Netlify deploy previewBundle size reportDetails of bundle changes (Toolpad) |
@DiegoAndai @aarongarciah Should we include this breaking change in v7? A similar PR was opened before (#36188). It’s just a prop value change for consistency. I've also added it to the v7 upgrade guide: https://deploy-preview-45235--material-ui.netlify.app/material-ui/migration/upgrade-to-v7/ What do you think? Worth including? |
@ZeeshanTamboli +1 for being consistent. |
The `size` prop for `InputLabel` now follows the standard naming convention used across Material UI. `'normal'` has been replaced with `'medium'` for consistency. | ||
|
||
If you were using `size="normal"`, update it to `size="medium"`: | ||
|
||
```diff | ||
-<InputLabel size="normal">Label</InputLabel> | ||
+<InputLabel size="medium">Label</InputLabel> | ||
``` | ||
|
||
This aligns `InputLabel` with other components like `Button` and `TextField`, which use `'small' | 'medium'`. The default behavior remains unchanged, so no updates are needed unless you explicitly set `size="normal"`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The `size` prop for `InputLabel` now follows the standard naming convention used across Material UI. `'normal'` has been replaced with `'medium'` for consistency. | |
If you were using `size="normal"`, update it to `size="medium"`: | |
```diff | |
-<InputLabel size="normal">Label</InputLabel> | |
+<InputLabel size="medium">Label</InputLabel> | |
``` | |
This aligns `InputLabel` with other components like `Button` and `TextField`, which use `'small' | 'medium'`. The default behavior remains unchanged, so no updates are needed unless you explicitly set `size="normal"`. | |
The `size` prop for `InputLabel` now follows the standard naming convention used across other components like `Button` and `TextField`. `'normal'` has been replaced with `'medium'` for consistency. | |
If you were using `size="normal"`, update it to `size="medium"`: | |
```diff | |
-<InputLabel size="normal">Label</InputLabel> | |
+<InputLabel size="medium">Label</InputLabel> |
The default behavior remains unchanged, so no updates are needed unless you explicitly set size="normal"
.
@ZeeshanTamboli we should add a codemod, too |
From what I can tell the
InputLabel
is the only component with a'small' | 'normal'
size prop. Looking through the rest of components (albeit with a very rudimentary search) the standard seems to be'small' | 'medium'
.This PR updates the propery for the
InputLabel
to match other components.