-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
RFC: Material-UI v4 breaking changes #13663
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
What I would suggest for v4 is unifying callbacks. Table pagination |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Can Grid be eliminated in favour of system? |
How are we supposed to 👍 / 👎 on particular items? Also, please prefix this discussion with [RFC] if you're really open for discussion. |
@fzaninotto Either on the linked issues or open a separate one. A productive discussion about multiple items is really hard within a single issue. This is just a tracking issue. |
|
Icon/SvgIcon change the fontSize value property default -> normal.I think "normal" actually has less concrete meaning than "default"? |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Something changed in the tables alpha.1 to alpha.7 , I now have to add height (not lineHeight) to all rows. Update - I looked at the migration guide PR and see that the table height change is noted there. |
@Falieson Thank you for the problem report. Were you overriding the styles prior to the change of behavior? Any idea what changed? |
@oliviertassinari My table is derived from: https://material-ui.com/demos/tables/#sorting-amp-selecting . I just componentized and hooked it . I might have a fixed height on my tables which is causing the spread? On a new note - would it be a lot of effort to include an upgrade script that will look for all instances of blocks that contain the properties moved from /core/ to /styles/ and update the import?
I tried a simple search/replace which gave me a big chunk of the work, but also created some mistakes. In my 6 week old app, I've had to update 120+ files, and its taken me over 5 hours. |
@Falieson I have taken the demo, and replaced v3 for v4, no issues: https://codesandbox.io/s/j3vjoyp7oy. I don't know what's going on. We need a reproduction.
I'm sorry, that's not needed. What lead you to this path? We don't promote it. |
@oliviertassinari |
@Falieson It's definitely not a bad idea. My point is that it won't change much at the end of the day. All the component demos are using |
@oliviertassinari I didn't realize the properties were removed from the toplevel
|
@Falieson FWIW if you need to rename a bunch of import paths, you can use jscodeshift-transport |
@eps1lon - Something I ran into today when upgrading from 3.9.3 -> 4.0.0-alpha.8. If you are explicitly using JssProvider/Jss to work around bundle splitting/class name generator issues, you need to make sure you upgrade your Might want to add this to the migration-v3 doc. |
@pachuka We do no longer depend on |
@oliviertassinari, haha, sure I can create a codesandbox reproduction + PR note tomorrow. |
Is there an issue with ThemeProvider at this stage? It was working fine previously but now I'm having issues. I've created a custom theme and wrapped my apps in a ThemeProvider yet all components and For example:
The result of this is the typography color is set to the default purple[500] instead of cyan[500] as specified in createMuiTheme. The same issue occurs when using:
Is this a known issue? |
@TidyIQ Interesting. It's not the first time I hear about the problem. But I have never been able to reproduce it. What dependency versions are you using? |
|
@TidyIQ 😨 do you have a github repository I could have a look at? |
Sure. It's a private repo but I'll make it public for a couple of hours so you can take a look. https://github.com/TidyIQ/tidyiq_website edit: Also just FYI, I followed the example repo here to set it up: https://github.com/mui-org/material-ui/tree/next/examples/nextjs-next-with-typescript |
@TidyIQ It works great with a fresh yarn or npm install (rm package-lock.json). However, It's broken with your package-lock.json. I will see if I can find why and even better, add an explicit warning. Thank you! |
Yeah you're right. I deleted all my node_modules and package_lock.json then reinstalled and now it's working fine. Strange... Well at least it's working now! Thanks for your help. |
Thank you, everybody, for the feedback! We are marching toward stable v4. |
@oliviertassinari The change that @Falieson refers to above (createStyles no longer exposed on /core) is a breaking change, but it is not documented anywhere. Worse, the typescript defs still show it being available in /core so VSCode doesn't warn me, but then the compiler fails. Should I raise an issue? |
Tracking issue for all the breaking changes that are planned or proposed for Material-UI v4.
v4 preview: https://next--material-ui.netlify.com/
Unchecked checkboxes mean planned only. If those changes should be discussed then there either exists an existing issue or a separate one should be opened. Checked means a PR is either open or merged into
next
.Changes live in the
next
branch. Beta releases are not planned yet.Releases
4.0.0-alpha.0
MaterialUI
(PR)augmentColor()
immutable (issue, PR)variant
prop documentation). (PR)import Button from '@material-ui/core/es/Button'
(issue, PR)<Grid spacing={1|2|3} />
👍.<Grid spacing={8|16|24} />
👎. (PR)React.memo
instead. (PR)4.0.0-alpha.1
/es
folder from icons build (PR)headlineMapping
->variantMapping
.I'm open to better wording, at least, this one makes it obvious it's related to the variant property. (PR)
Link
: removeblock
prop. (PR)withTheme(options)(Component)
->withTheme(Component)
. There is no need for anoptions
argument. (PR)4.0.0-alpha.2
The more style we have on the root, the easier it's for people to override the component. (PR)
4.0.0-alpha.3
withStyles
(was@material-ui/core/styles/withStyles
will be@material-ui/styles/withStyles
) (issue, PR)4.0.0-alpha.4
inset
property. (PR)nativeColor
->htmlColor
for consistency withhtmlFor
. (PR)4.0.0-alpha.5
4.0.0-alpha.6
component
props to forward refs (Warnings in strict mode #13394 (comment) for rational). (issue)4.0.0-alpha.7
4.0.0-alpha.8
4.0.0-alpha.9
4.0.0-beta.0
🏁
Rejected
@material-ui/core/styles/createMuiTheme
->@material-ui/core/createMuiTheme
As we are moving the styling solution into its own package, this folder only focuses on the theme, we can reflect it in the name of the folder. (issue)
(https://codesandbox.io/s/448wmxwx9, https://github.com/erikras/redux-form-material-ui/blob/v5.0.0-beta-3/src/Checkbox.js).
default
->medium
.This matches the Button size enums and the less often we use
default
, the better. (PR)https://github.com/mui-org/material-ui/pull/13487/files#r230219558. (PR)
Grid List
->Image List
to follow the specification wording. (PR)theme.palette.type
->theme.palette.variant
.We use the
variant
wording all over the place, what's a "type"?InputBase
overInput
by defaultBetter perf.
withMobileDialog
This helper doesn't provide any value when looking at the implementation. It would be better to educate people using
withWidth()
, and the upcoming hook API. (PR)withWidth()
. UseuseMediaQuery
instead. I would like to allow people to use custom breakpoints.withWidth
is blocking this capability.margin?: 'none' | 'normal' | 'dense'
->margin?: false | 'normal' | 'dense'
.theme.palette
->theme.colors
This should be less confusing when using the theme.
I have seen any use case for an options argument, nor I can envision one now, two years later.
focusRipple
->disableFocusRipple
for consistency with our API.Will we still need this component with the design system package? The JS version is interesting.
TabIndicatorProps
->IndicatorProps
.fontSize
.component
->as
? I need to run a Twitter Poll for this one./es
->/src
. This should reduce people confusion.isControlled !== undefined
(motivation).This includes a proposal to consider the
master
branch as 3.x andnext
as 4.0.We can either default to
next
which means we would need to backport changes where necessary or stay atmaster
which would require a port of each PR tonext
. Either way merges betweennext
andmaster
should not be squashed since each commit inmaster
is already squashed. Further squashing reduces the usability of git.Someone with admin rights to the repo should protect the
next
branch against force pushes.cc @mui-org/core-contributors
The text was updated successfully, but these errors were encountered: