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

[pickers] Remove all the props passed by usePickers to PickersLayout and use the new contexts instead #15495

Open
flaviendelangle opened this issue Nov 19, 2024 · 0 comments · May be fixed by #15948
Assignees
Labels
component: pickers This is the name of the generic UI component, not the React module!

Comments

@flaviendelangle
Copy link
Member

flaviendelangle commented Nov 19, 2024

The PickersLayout component (which is overridable with slots.layout) receives a lot of props about the current state of the picker and pass some of them down to the slots it handles (actionBar, toolbar, tabs and shortcut).

I plan to remove all the props it receives outside of the custom one defined in slotProps.layout.

Why?

  • Avoid weird override using slotProps.layout (people should never do slotProps={{ layout: { isRtl: false }}} for instance)

  • Prepare for a composable API

Search keywords:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: pickers This is the name of the generic UI component, not the React module!
Projects
None yet
1 participant