-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
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
[Pickers] Don't pass down unnecessary props #27256
Conversation
Update branch
Details of bundle changes (experimental) @material-ui/lab: parsed: +1.62% , gzip: +0.80% |
I just noticed this comment in
So it seems the props should be spread after all. I'll change this PR to spread props on both MonthPicker and YearPicker, but without props that are irrelevant here, like |
Could you check when this was added? I think I planned to explicitly pick which prop goes where and nost just spread everything down. This may add to the bundle size but makes it easier to track which prop goes where. |
Won't these changes break the conformance tests of this public component? |
@oliviertassinari Yes, the current changes broke the conformance test, but we could just disable that check, like in the YearPicker. The question is if we want to:
I think this should be unified across different picker views. |
I think the problem is rather the components that use Removing conformance is a non-starter. |
# Conflicts: # packages/material-ui-lab/src/internal/pickers/Picker/Picker.tsx
Seems like there is not much activity on the pull request, and considering that we are moving the pickers to https://github.com/mui-org/material-ui-x I am closing the pull request. cc @flaviendelangle |
Fixes mui/mui-x#6487.
Demo with the issue: https://codesandbox.io/s/custominput-material-demo-forked-r3064
Demo with the fix: https://codesandbox.io/s/custominput-material-demo-forked-kw722