[pickers] Simplify the ownerState
on every slot to only pass a small object with valuable information
#14475
Open
70 of 72 tasks
Labels
breaking change
component: pickers
This is the name of the generic UI component, not the React module!
dx
Related to developers' experience
v8.x
Right now, the
ownerState
passed to styled components or slots is the props of the component calling it (plus 1-2 properties on some occasions).This make these objects very complex to reason about because people don't know which component is calling a certain slot and which props it has.
Additionally some valuable information are not part of those prop (the slots called by the
useXXXPicker
hooks don't even have the opening status).Slots
actionBar
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)calendarHeader
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)clearButton
([pickers] Use the newownerState
inuseClearableField
#15776)clearIcon
([pickers] Use the newownerState
inuseClearableField
#15776)day
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)desktopPaper
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669desktopTransition
(do not support callback signature)desktopTrapFocus
(do not support callback signature)dialog
(do not support callback signature)digitalClockItem
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669digitalClockSectionItem
(do not support callback signature)field
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)fieldRoot
([pickers] Use the newownerState
object in all the field components #15510)fieldSeparator
([pickers] Use the newownerState
object in all the field components #15510)inputAdornment
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)layout
(do not support callback signature)leftArrowIcon
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)mobilePaper
(do not support callback signature)mobileTransition
(do not support callback signature)monthButton
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)nextIconButton
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)openPickerButton
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)openPickerIcon
([pickers] Create the new picker'sownerState
object #14889)popper
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669previousIconButton
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)rightArrowIcon
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)shortcuts
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)switchViewButton
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)switchViewIcon
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)tabs
(do not support callback signature)textField
([pickers] Use the newownerState
object in all the field components #15510)toolbar
([pickers] Use the newownerState
inusePickersLayout
anduseXXXPicker
#14994)yearButton
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)Style overrides
The list might not be complete
Clock
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669ClockNumber
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669ClockPointer
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669DateCalendar
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)DateRangeCalendar
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)DayCalendar
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)DatePickerToolbar
([pickers] Use the newownerState
in the toolbar components #15777)DateRangePickerDay
DateRangePickerToolbar
([pickers] Use the newownerState
in the toolbar components #15777)DateTimePickerTabs
([pickers] Use newownerState
object in<DateTimePickerTabs />
and<DateTimeRangePickerTabs />
#15498)DateTimePickerToolbar
([pickers] Use the newownerState
in the toolbar components #15777)DateTimeRangePickerTabs
([pickers] Use newownerState
object in<DateTimePickerTabs />
and<DateTimeRangePickerTabs />
#15498)DateTimeRangePickerToolbar
([pickers] Use the newownerState
in the toolbar components #15777)DigitalClock
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669MonthCalendar
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)MultiInputDateRangeField
([pickers] Use the newownerState
object in all the field components #15510)MultiInputDateTimeRangeField
([pickers] Use the newownerState
object in all the field components #15510)MultiInputTimeRangeField
([pickers] Use the newownerState
object in all the field components #15510)MultiSectionDigitalClock
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669MultiSectionDigitalClockSection
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669PickersArrowSwitcher
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)PickersCalendarHeader
([pickers] Use the newownerState
in<PickersCalendarHeader />
,<PickersArrowSwitcher />
and<DayCalendarSkeleton />
#15499)PickersDay
PickersFilledInput
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersInput
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersInputBase
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersLayout
([pickers] Removeorientation
,isLandscape
,isRtl
,wrapperVariant
anddisabled
props fromPickersLayout
#15494)PickersMonth
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)PickersOutlinedInput
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersPopper
PickersSectionList
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersTextField
([pickers] Use the newownerState
object on the<PickersTextField />
component #15863)PickersToolbar
([pickers] Use the newownerState
in the toolbar components #15777)PickersToolbarButton
([pickers] Use the newownerState
in the toolbar components #15777)PickersToolbarText
([pickers] Use the newownerState
in the toolbar components #15777)PickersYear
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)TimeClock
[pickers] Use the newownerState
object for the clock components and the desktop / mobile wrappers #15669TimePickerToolbar
([pickers] Use the newownerState
in the toolbar components #15777)YearCalendar
([pickers] Use the newownerState
inDateCalendar
,DateRangeCalendar
,MonthCalendar
andYearCalendar
#15171)Search keywords:
The text was updated successfully, but these errors were encountered: