@mui/x-date-pickers 9.6.0 → 9.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AdapterDateFns/AdapterDateFns.d.mts +2 -2
- package/AdapterDateFns/AdapterDateFns.d.ts +2 -2
- package/AdapterDateFnsBase/AdapterDateFnsBase.d.mts +2 -2
- package/AdapterDateFnsBase/AdapterDateFnsBase.d.ts +2 -2
- package/AdapterDateFnsJalali/AdapterDateFnsJalali.d.mts +2 -2
- package/AdapterDateFnsJalali/AdapterDateFnsJalali.d.ts +2 -2
- package/AdapterDateFnsJalaliV2/AdapterDateFnsJalaliV2.d.mts +1 -1
- package/AdapterDateFnsJalaliV2/AdapterDateFnsJalaliV2.d.ts +1 -1
- package/AdapterDateFnsV2/AdapterDateFnsV2.d.mts +1 -1
- package/AdapterDateFnsV2/AdapterDateFnsV2.d.ts +1 -1
- package/AdapterDayjs/AdapterDayjs.d.mts +29 -29
- package/AdapterDayjs/AdapterDayjs.d.ts +29 -29
- package/AdapterDayjs/AdapterDayjs.mjs +1 -0
- package/AdapterDayjsBuddhist/AdapterDayjsBuddhist.d.mts +4 -4
- package/AdapterDayjsBuddhist/AdapterDayjsBuddhist.d.ts +4 -4
- package/AdapterDayjsBuddhist/AdapterDayjsBuddhist.mjs +1 -0
- package/AdapterLuxon/AdapterLuxon.d.mts +1 -1
- package/AdapterLuxon/AdapterLuxon.d.ts +1 -1
- package/AdapterMoment/AdapterMoment.d.mts +29 -28
- package/AdapterMoment/AdapterMoment.d.ts +29 -28
- package/AdapterMomentHijri/AdapterMomentHijri.d.mts +14 -13
- package/AdapterMomentHijri/AdapterMomentHijri.d.ts +14 -13
- package/AdapterMomentHijri/AdapterMomentHijri.js +2 -2
- package/AdapterMomentHijri/AdapterMomentHijri.mjs +3 -2
- package/AdapterMomentJalaali/AdapterMomentJalaali.d.mts +13 -12
- package/AdapterMomentJalaali/AdapterMomentJalaali.d.ts +13 -12
- package/AdapterMomentJalaali/AdapterMomentJalaali.js +2 -2
- package/AdapterMomentJalaali/AdapterMomentJalaali.mjs +3 -2
- package/CHANGELOG.md +241 -2
- package/DateCalendar/DateCalendar.d.mts +1 -1
- package/DateCalendar/DateCalendar.d.ts +1 -1
- package/DateCalendar/DateCalendar.types.d.mts +16 -16
- package/DateCalendar/DateCalendar.types.d.ts +16 -16
- package/DateCalendar/DayCalendar.d.mts +9 -9
- package/DateCalendar/DayCalendar.d.ts +9 -9
- package/DateCalendar/DayCalendar.js +5 -4
- package/DateCalendar/DayCalendar.mjs +5 -4
- package/DateCalendar/PickersFadeTransitionGroup.d.mts +1 -1
- package/DateCalendar/PickersFadeTransitionGroup.d.ts +1 -1
- package/DateCalendar/PickersSlideTransition.d.mts +3 -3
- package/DateCalendar/PickersSlideTransition.d.ts +3 -3
- package/DateCalendar/useCalendarState.d.mts +3 -3
- package/DateCalendar/useCalendarState.d.ts +3 -3
- package/DateCalendar/useIsDateDisabled.d.mts +3 -3
- package/DateCalendar/useIsDateDisabled.d.ts +3 -3
- package/DateField/DateField.d.mts +1 -1
- package/DateField/DateField.d.ts +1 -1
- package/DateField/DateField.js +1 -0
- package/DateField/DateField.mjs +1 -0
- package/DateField/DateField.types.d.mts +6 -6
- package/DateField/DateField.types.d.ts +6 -6
- package/DateField/useDateField.d.mts +1 -1
- package/DateField/useDateField.d.ts +1 -1
- package/DatePicker/DatePicker.d.mts +1 -1
- package/DatePicker/DatePicker.d.ts +1 -1
- package/DatePicker/DatePicker.types.d.mts +4 -4
- package/DatePicker/DatePicker.types.d.ts +4 -4
- package/DatePicker/DatePickerToolbar.d.mts +2 -2
- package/DatePicker/DatePickerToolbar.d.ts +2 -2
- package/DatePicker/shared.d.mts +10 -10
- package/DatePicker/shared.d.ts +10 -10
- package/DateTimeField/DateTimeField.d.mts +1 -1
- package/DateTimeField/DateTimeField.d.ts +1 -1
- package/DateTimeField/DateTimeField.js +1 -0
- package/DateTimeField/DateTimeField.mjs +1 -0
- package/DateTimeField/DateTimeField.types.d.mts +7 -7
- package/DateTimeField/DateTimeField.types.d.ts +7 -7
- package/DateTimeField/useDateTimeField.d.mts +1 -1
- package/DateTimeField/useDateTimeField.d.ts +1 -1
- package/DateTimePicker/DateTimePicker.d.mts +1 -1
- package/DateTimePicker/DateTimePicker.d.ts +1 -1
- package/DateTimePicker/DateTimePicker.types.d.mts +5 -5
- package/DateTimePicker/DateTimePicker.types.d.ts +5 -5
- package/DateTimePicker/DateTimePickerTabs.d.mts +2 -2
- package/DateTimePicker/DateTimePickerTabs.d.ts +2 -2
- package/DateTimePicker/DateTimePickerToolbar.d.mts +5 -5
- package/DateTimePicker/DateTimePickerToolbar.d.ts +5 -5
- package/DateTimePicker/shared.d.mts +15 -15
- package/DateTimePicker/shared.d.ts +15 -15
- package/DayCalendarSkeleton/DayCalendarSkeleton.d.mts +3 -3
- package/DayCalendarSkeleton/DayCalendarSkeleton.d.ts +3 -3
- package/DesktopDatePicker/DesktopDatePicker.d.mts +1 -1
- package/DesktopDatePicker/DesktopDatePicker.d.ts +1 -1
- package/DesktopDatePicker/DesktopDatePicker.types.d.mts +4 -4
- package/DesktopDatePicker/DesktopDatePicker.types.d.ts +4 -4
- package/DesktopDateTimePicker/DesktopDateTimePicker.d.mts +1 -1
- package/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +1 -1
- package/DesktopDateTimePicker/DesktopDateTimePicker.types.d.mts +6 -6
- package/DesktopDateTimePicker/DesktopDateTimePicker.types.d.ts +6 -6
- package/DesktopDateTimePicker/DesktopDateTimePickerLayout.d.mts +2 -2
- package/DesktopDateTimePicker/DesktopDateTimePickerLayout.d.ts +2 -2
- package/DesktopTimePicker/DesktopTimePicker.d.mts +1 -1
- package/DesktopTimePicker/DesktopTimePicker.d.ts +1 -1
- package/DesktopTimePicker/DesktopTimePicker.types.d.mts +8 -8
- package/DesktopTimePicker/DesktopTimePicker.types.d.ts +8 -8
- package/DigitalClock/DigitalClock.d.mts +1 -1
- package/DigitalClock/DigitalClock.d.ts +1 -1
- package/DigitalClock/DigitalClock.types.d.mts +6 -6
- package/DigitalClock/DigitalClock.types.d.ts +6 -6
- package/LocalizationProvider/LocalizationProvider.d.mts +2 -2
- package/LocalizationProvider/LocalizationProvider.d.ts +2 -2
- package/MobileDatePicker/MobileDatePicker.d.mts +1 -1
- package/MobileDatePicker/MobileDatePicker.d.ts +1 -1
- package/MobileDatePicker/MobileDatePicker.types.d.mts +3 -3
- package/MobileDatePicker/MobileDatePicker.types.d.ts +3 -3
- package/MobileDateTimePicker/MobileDateTimePicker.d.mts +1 -1
- package/MobileDateTimePicker/MobileDateTimePicker.d.ts +1 -1
- package/MobileDateTimePicker/MobileDateTimePicker.types.d.mts +3 -3
- package/MobileDateTimePicker/MobileDateTimePicker.types.d.ts +3 -3
- package/MobileTimePicker/MobileTimePicker.d.mts +2 -2
- package/MobileTimePicker/MobileTimePicker.d.ts +2 -2
- package/MobileTimePicker/MobileTimePicker.types.d.mts +5 -5
- package/MobileTimePicker/MobileTimePicker.types.d.ts +5 -5
- package/MonthCalendar/MonthCalendar.d.mts +2 -2
- package/MonthCalendar/MonthCalendar.d.ts +2 -2
- package/MonthCalendar/MonthCalendar.types.d.mts +8 -8
- package/MonthCalendar/MonthCalendar.types.d.ts +8 -8
- package/MonthCalendar/MonthCalendarButton.d.mts +2 -2
- package/MonthCalendar/MonthCalendarButton.d.ts +2 -2
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.d.mts +1 -1
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.d.ts +1 -1
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.types.d.mts +7 -7
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.types.d.ts +7 -7
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.utils.d.mts +2 -2
- package/MultiSectionDigitalClock/MultiSectionDigitalClock.utils.d.ts +2 -2
- package/MultiSectionDigitalClock/MultiSectionDigitalClockSection.d.mts +3 -3
- package/MultiSectionDigitalClock/MultiSectionDigitalClockSection.d.ts +3 -3
- package/PickerDay/PickerDay.d.mts +1 -1
- package/PickerDay/PickerDay.d.ts +1 -1
- package/PickerDay/PickerDay.types.d.mts +5 -5
- package/PickerDay/PickerDay.types.d.ts +5 -5
- package/PickersActionBar/PickersActionBar.d.mts +1 -1
- package/PickersActionBar/PickersActionBar.d.ts +1 -1
- package/PickersCalendarHeader/PickersCalendarHeader.d.mts +1 -1
- package/PickersCalendarHeader/PickersCalendarHeader.d.ts +1 -1
- package/PickersCalendarHeader/PickersCalendarHeader.types.d.mts +9 -9
- package/PickersCalendarHeader/PickersCalendarHeader.types.d.ts +9 -9
- package/PickersLayout/PickersLayout.d.mts +2 -2
- package/PickersLayout/PickersLayout.d.ts +2 -2
- package/PickersLayout/PickersLayout.types.d.mts +11 -11
- package/PickersLayout/PickersLayout.types.d.ts +11 -11
- package/PickersLayout/usePickerLayout.d.mts +2 -2
- package/PickersLayout/usePickerLayout.d.ts +2 -2
- package/PickersSectionList/PickersSectionList.types.d.mts +4 -4
- package/PickersSectionList/PickersSectionList.types.d.ts +4 -4
- package/PickersShortcuts/PickersShortcuts.d.mts +3 -3
- package/PickersShortcuts/PickersShortcuts.d.ts +3 -3
- package/PickersTextField/PickersFilledInput/PickersFilledInput.d.mts +2 -2
- package/PickersTextField/PickersFilledInput/PickersFilledInput.d.ts +2 -2
- package/PickersTextField/PickersFilledInput/PickersFilledInput.js +1 -0
- package/PickersTextField/PickersFilledInput/PickersFilledInput.mjs +1 -0
- package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.d.mts +1 -1
- package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.d.ts +1 -1
- package/PickersTextField/PickersInput/PickersInput.d.mts +2 -2
- package/PickersTextField/PickersInput/PickersInput.d.ts +2 -2
- package/PickersTextField/PickersInput/PickersInput.js +1 -0
- package/PickersTextField/PickersInput/PickersInput.mjs +1 -0
- package/PickersTextField/PickersInput/pickersInputClasses.d.mts +1 -1
- package/PickersTextField/PickersInput/pickersInputClasses.d.ts +1 -1
- package/PickersTextField/PickersInputBase/PickersInputBase.d.mts +2 -2
- package/PickersTextField/PickersInputBase/PickersInputBase.d.ts +2 -2
- package/PickersTextField/PickersInputBase/PickersInputBase.js +16 -1
- package/PickersTextField/PickersInputBase/PickersInputBase.mjs +16 -1
- package/PickersTextField/PickersInputBase/PickersInputBase.types.d.mts +6 -5
- package/PickersTextField/PickersInputBase/PickersInputBase.types.d.ts +6 -5
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.d.mts +1 -1
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.d.ts +1 -1
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +12 -8
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.mjs +12 -8
- package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.d.mts +1 -1
- package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.d.ts +1 -1
- package/PickersTextField/PickersTextField.js +4 -1
- package/PickersTextField/PickersTextField.mjs +4 -1
- package/PickersTextField/PickersTextField.types.d.mts +6 -6
- package/PickersTextField/PickersTextField.types.d.ts +6 -6
- package/PickersTextField/usePickerTextFieldOwnerState.d.mts +1 -1
- package/PickersTextField/usePickerTextFieldOwnerState.d.ts +1 -1
- package/StaticDatePicker/StaticDatePicker.d.mts +1 -1
- package/StaticDatePicker/StaticDatePicker.d.ts +1 -1
- package/StaticDatePicker/StaticDatePicker.types.d.mts +3 -3
- package/StaticDatePicker/StaticDatePicker.types.d.ts +3 -3
- package/StaticDateTimePicker/StaticDateTimePicker.d.mts +1 -1
- package/StaticDateTimePicker/StaticDateTimePicker.d.ts +1 -1
- package/StaticDateTimePicker/StaticDateTimePicker.types.d.mts +3 -3
- package/StaticDateTimePicker/StaticDateTimePicker.types.d.ts +3 -3
- package/StaticTimePicker/StaticTimePicker.d.mts +1 -1
- package/StaticTimePicker/StaticTimePicker.d.ts +1 -1
- package/StaticTimePicker/StaticTimePicker.types.d.mts +4 -4
- package/StaticTimePicker/StaticTimePicker.types.d.ts +4 -4
- package/TimeClock/Clock.d.mts +5 -5
- package/TimeClock/Clock.d.ts +5 -5
- package/TimeClock/Clock.js +76 -30
- package/TimeClock/Clock.mjs +76 -30
- package/TimeClock/ClockNumber.d.mts +2 -2
- package/TimeClock/ClockNumber.d.ts +2 -2
- package/TimeClock/ClockNumbers.d.mts +1 -1
- package/TimeClock/ClockNumbers.d.ts +1 -1
- package/TimeClock/ClockPointer.d.mts +2 -2
- package/TimeClock/ClockPointer.d.ts +2 -2
- package/TimeClock/TimeClock.d.mts +1 -1
- package/TimeClock/TimeClock.d.ts +1 -1
- package/TimeClock/TimeClock.types.d.mts +5 -5
- package/TimeClock/TimeClock.types.d.ts +5 -5
- package/TimeField/TimeField.d.mts +1 -1
- package/TimeField/TimeField.d.ts +1 -1
- package/TimeField/TimeField.js +1 -0
- package/TimeField/TimeField.mjs +1 -0
- package/TimeField/TimeField.types.d.mts +7 -7
- package/TimeField/TimeField.types.d.ts +7 -7
- package/TimeField/useTimeField.d.mts +1 -1
- package/TimeField/useTimeField.d.ts +1 -1
- package/TimePicker/TimePicker.d.mts +1 -1
- package/TimePicker/TimePicker.d.ts +1 -1
- package/TimePicker/TimePicker.types.d.mts +4 -4
- package/TimePicker/TimePicker.types.d.ts +4 -4
- package/TimePicker/TimePickerToolbar.d.mts +2 -2
- package/TimePicker/TimePickerToolbar.d.ts +2 -2
- package/TimePicker/shared.d.mts +11 -11
- package/TimePicker/shared.d.ts +11 -11
- package/YearCalendar/YearCalendar.d.mts +1 -1
- package/YearCalendar/YearCalendar.d.ts +1 -1
- package/YearCalendar/YearCalendar.types.d.mts +8 -8
- package/YearCalendar/YearCalendar.types.d.ts +8 -8
- package/YearCalendar/YearCalendarButton.d.mts +2 -2
- package/YearCalendar/YearCalendarButton.d.ts +2 -2
- package/dateViewRenderers/dateViewRenderers.d.mts +3 -3
- package/dateViewRenderers/dateViewRenderers.d.ts +3 -3
- package/hooks/useIsValidValue.d.mts +1 -1
- package/hooks/useIsValidValue.d.ts +1 -1
- package/hooks/usePickerActionsContext.d.mts +2 -2
- package/hooks/usePickerActionsContext.d.ts +2 -2
- package/hooks/usePickerAdapter.d.mts +2 -2
- package/hooks/usePickerAdapter.d.ts +2 -2
- package/hooks/usePickerContext.d.mts +1 -1
- package/hooks/usePickerContext.d.ts +1 -1
- package/hooks/useSplitFieldProps.d.mts +1 -1
- package/hooks/useSplitFieldProps.d.ts +1 -1
- package/index.js +1 -1
- package/index.mjs +1 -1
- package/internals/components/PickerFieldUI.d.mts +7 -7
- package/internals/components/PickerFieldUI.d.ts +7 -7
- package/internals/components/PickerPopper/PickerPopper.d.mts +7 -7
- package/internals/components/PickerPopper/PickerPopper.d.ts +7 -7
- package/internals/components/PickerPopper/PickerPopper.js +1 -1
- package/internals/components/PickerPopper/PickerPopper.mjs +1 -1
- package/internals/components/PickerProvider.d.mts +6 -6
- package/internals/components/PickerProvider.d.ts +6 -6
- package/internals/components/PickersArrowSwitcher/PickersArrowSwitcher.d.mts +1 -1
- package/internals/components/PickersArrowSwitcher/PickersArrowSwitcher.d.ts +1 -1
- package/internals/components/PickersArrowSwitcher/PickersArrowSwitcher.types.d.mts +6 -6
- package/internals/components/PickersArrowSwitcher/PickersArrowSwitcher.types.d.ts +6 -6
- package/internals/components/PickersModalDialog.d.mts +3 -3
- package/internals/components/PickersModalDialog.d.ts +3 -3
- package/internals/components/PickersToolbar.d.mts +2 -2
- package/internals/components/PickersToolbar.d.ts +2 -2
- package/internals/components/PickersToolbarButton.d.mts +4 -4
- package/internals/components/PickersToolbarButton.d.ts +4 -4
- package/internals/components/PickersToolbarText.d.mts +2 -2
- package/internals/components/PickersToolbarText.d.ts +2 -2
- package/internals/demo/DemoContainer.d.mts +2 -2
- package/internals/demo/DemoContainer.d.ts +2 -2
- package/internals/hooks/PickerDay.types.d.mts +1 -1
- package/internals/hooks/PickerDay.types.d.ts +1 -1
- package/internals/hooks/date-helpers-hooks.d.mts +3 -3
- package/internals/hooks/date-helpers-hooks.d.ts +3 -3
- package/internals/hooks/useClockReferenceDate.d.mts +2 -2
- package/internals/hooks/useClockReferenceDate.d.ts +2 -2
- package/internals/hooks/useControlledValue.d.mts +2 -3
- package/internals/hooks/useControlledValue.d.ts +2 -3
- package/internals/hooks/useDesktopPicker/useDesktopPicker.d.mts +2 -2
- package/internals/hooks/useDesktopPicker/useDesktopPicker.d.ts +2 -2
- package/internals/hooks/useDesktopPicker/useDesktopPicker.types.d.mts +10 -10
- package/internals/hooks/useDesktopPicker/useDesktopPicker.types.d.ts +10 -10
- package/internals/hooks/useField/buildSectionsFromFormat.d.mts +2 -2
- package/internals/hooks/useField/buildSectionsFromFormat.d.ts +2 -2
- package/internals/hooks/useField/syncSelectionToDOM.d.mts +3 -3
- package/internals/hooks/useField/syncSelectionToDOM.d.ts +3 -3
- package/internals/hooks/useField/useField.d.mts +2 -2
- package/internals/hooks/useField/useField.d.ts +2 -2
- package/internals/hooks/useField/useField.js +18 -0
- package/internals/hooks/useField/useField.mjs +18 -0
- package/internals/hooks/useField/useField.types.d.mts +5 -4
- package/internals/hooks/useField/useField.types.d.ts +5 -4
- package/internals/hooks/useField/useField.utils.d.mts +3 -5
- package/internals/hooks/useField/useField.utils.d.ts +3 -5
- package/internals/hooks/useField/useField.utils.js +2 -4
- package/internals/hooks/useField/useField.utils.mjs +1 -2
- package/internals/hooks/useField/useFieldCharacterEditing.d.mts +2 -2
- package/internals/hooks/useField/useFieldCharacterEditing.d.ts +2 -2
- package/internals/hooks/useField/useFieldHiddenInputProps.d.mts +2 -2
- package/internals/hooks/useField/useFieldHiddenInputProps.d.ts +2 -2
- package/internals/hooks/useField/useFieldInternalPropsWithDefaults.d.mts +1 -1
- package/internals/hooks/useField/useFieldInternalPropsWithDefaults.d.ts +1 -1
- package/internals/hooks/useField/useFieldRootProps.d.mts +5 -4
- package/internals/hooks/useField/useFieldRootProps.d.ts +5 -4
- package/internals/hooks/useField/useFieldRootProps.js +95 -8
- package/internals/hooks/useField/useFieldRootProps.mjs +95 -8
- package/internals/hooks/useField/useFieldSectionContainerProps.d.mts +2 -2
- package/internals/hooks/useField/useFieldSectionContainerProps.d.ts +2 -2
- package/internals/hooks/useField/useFieldSectionContainerProps.js +35 -4
- package/internals/hooks/useField/useFieldSectionContainerProps.mjs +34 -4
- package/internals/hooks/useField/useFieldSectionContentProps.d.mts +6 -6
- package/internals/hooks/useField/useFieldSectionContentProps.d.ts +6 -6
- package/internals/hooks/useField/useFieldSectionContentProps.js +17 -12
- package/internals/hooks/useField/useFieldSectionContentProps.mjs +17 -12
- package/internals/hooks/useField/useFieldState.d.mts +3 -3
- package/internals/hooks/useField/useFieldState.d.ts +3 -3
- package/internals/hooks/useFieldOwnerState.d.mts +2 -2
- package/internals/hooks/useFieldOwnerState.d.ts +2 -2
- package/internals/hooks/useMobilePicker/useMobilePicker.d.mts +2 -2
- package/internals/hooks/useMobilePicker/useMobilePicker.d.ts +2 -2
- package/internals/hooks/useMobilePicker/useMobilePicker.types.d.mts +10 -10
- package/internals/hooks/useMobilePicker/useMobilePicker.types.d.ts +10 -10
- package/internals/hooks/useNullableFieldPrivateContext.d.mts +2 -2
- package/internals/hooks/useNullableFieldPrivateContext.d.ts +2 -2
- package/internals/hooks/usePicker/hooks/useOrientation.d.mts +1 -1
- package/internals/hooks/usePicker/hooks/useOrientation.d.ts +1 -1
- package/internals/hooks/usePicker/hooks/useValueAndOpenStates.d.mts +5 -5
- package/internals/hooks/usePicker/hooks/useValueAndOpenStates.d.ts +5 -5
- package/internals/hooks/usePicker/usePicker.d.mts +2 -2
- package/internals/hooks/usePicker/usePicker.d.ts +2 -2
- package/internals/hooks/usePicker/usePicker.types.d.mts +10 -10
- package/internals/hooks/usePicker/usePicker.types.d.ts +10 -10
- package/internals/hooks/usePickerDayOwnerState.d.mts +2 -2
- package/internals/hooks/usePickerDayOwnerState.d.ts +2 -2
- package/internals/hooks/useReduceAnimations.js +4 -1
- package/internals/hooks/useReduceAnimations.mjs +4 -1
- package/internals/hooks/useStaticPicker/useStaticPicker.d.mts +2 -2
- package/internals/hooks/useStaticPicker/useStaticPicker.d.ts +2 -2
- package/internals/hooks/useStaticPicker/useStaticPicker.types.d.mts +5 -5
- package/internals/hooks/useStaticPicker/useStaticPicker.types.d.ts +5 -5
- package/internals/hooks/useToolbarOwnerState.d.mts +1 -1
- package/internals/hooks/useToolbarOwnerState.d.ts +1 -1
- package/internals/hooks/useUtils.d.mts +1 -1
- package/internals/hooks/useUtils.d.ts +1 -1
- package/internals/hooks/useViews.d.mts +4 -4
- package/internals/hooks/useViews.d.ts +4 -4
- package/internals/models/common.d.mts +1 -1
- package/internals/models/common.d.ts +1 -1
- package/internals/models/fields.d.mts +1 -1
- package/internals/models/fields.d.ts +1 -1
- package/internals/models/helpers.d.mts +2 -2
- package/internals/models/helpers.d.ts +2 -2
- package/internals/models/manager.d.mts +1 -1
- package/internals/models/manager.d.ts +1 -1
- package/internals/models/props/basePickerProps.d.mts +7 -8
- package/internals/models/props/basePickerProps.d.ts +7 -8
- package/internals/models/props/tabs.d.mts +2 -2
- package/internals/models/props/tabs.d.ts +2 -2
- package/internals/models/props/time.d.mts +6 -6
- package/internals/models/props/time.d.ts +6 -6
- package/internals/models/props/toolbar.d.mts +3 -3
- package/internals/models/props/toolbar.d.ts +3 -3
- package/internals/models/value.d.mts +1 -1
- package/internals/models/value.d.ts +1 -1
- package/internals/utils/createNonRangePickerStepNavigation.d.mts +1 -1
- package/internals/utils/createNonRangePickerStepNavigation.d.ts +1 -1
- package/internals/utils/createStepNavigation.d.mts +1 -1
- package/internals/utils/createStepNavigation.d.ts +1 -1
- package/internals/utils/date-time-utils.d.mts +4 -4
- package/internals/utils/date-time-utils.d.ts +4 -4
- package/internals/utils/date-utils.d.mts +2 -2
- package/internals/utils/date-utils.d.ts +2 -2
- package/internals/utils/getDefaultReferenceDate.d.mts +1 -1
- package/internals/utils/getDefaultReferenceDate.d.ts +1 -1
- package/internals/utils/time-utils.d.mts +2 -2
- package/internals/utils/time-utils.d.ts +2 -2
- package/internals/utils/utils.d.mts +3 -3
- package/internals/utils/utils.d.ts +3 -3
- package/internals/utils/valueManagers.d.mts +2 -3
- package/internals/utils/valueManagers.d.ts +2 -3
- package/internals/utils/views.d.mts +1 -1
- package/internals/utils/views.d.ts +1 -1
- package/locales/beBY.d.mts +1 -1
- package/locales/beBY.d.ts +1 -1
- package/locales/bgBG.d.mts +1 -1
- package/locales/bgBG.d.ts +1 -1
- package/locales/bnBD.d.mts +1 -1
- package/locales/bnBD.d.ts +1 -1
- package/locales/caES.d.mts +1 -1
- package/locales/caES.d.ts +1 -1
- package/locales/csCZ.d.mts +1 -1
- package/locales/csCZ.d.ts +1 -1
- package/locales/daDK.d.mts +1 -1
- package/locales/daDK.d.ts +1 -1
- package/locales/deDE.d.mts +1 -1
- package/locales/deDE.d.ts +1 -1
- package/locales/elGR.d.mts +1 -1
- package/locales/elGR.d.ts +1 -1
- package/locales/enUS.d.mts +1 -1
- package/locales/enUS.d.ts +1 -1
- package/locales/esES.d.mts +1 -1
- package/locales/esES.d.ts +1 -1
- package/locales/eu.d.mts +1 -1
- package/locales/eu.d.ts +1 -1
- package/locales/faIR.d.mts +1 -1
- package/locales/faIR.d.ts +1 -1
- package/locales/fiFI.d.mts +1 -1
- package/locales/fiFI.d.ts +1 -1
- package/locales/frFR.d.mts +1 -1
- package/locales/frFR.d.ts +1 -1
- package/locales/heIL.d.mts +1 -1
- package/locales/heIL.d.ts +1 -1
- package/locales/hrHR.d.mts +1 -1
- package/locales/hrHR.d.ts +1 -1
- package/locales/huHU.d.mts +1 -1
- package/locales/huHU.d.ts +1 -1
- package/locales/isIS.d.mts +1 -1
- package/locales/isIS.d.ts +1 -1
- package/locales/itIT.d.mts +1 -1
- package/locales/itIT.d.ts +1 -1
- package/locales/jaJP.d.mts +1 -1
- package/locales/jaJP.d.ts +1 -1
- package/locales/koKR.d.mts +1 -1
- package/locales/koKR.d.ts +1 -1
- package/locales/kzKZ.d.mts +1 -1
- package/locales/kzKZ.d.ts +1 -1
- package/locales/nbNO.d.mts +1 -1
- package/locales/nbNO.d.ts +1 -1
- package/locales/nlNL.d.mts +1 -1
- package/locales/nlNL.d.ts +1 -1
- package/locales/nnNO.d.mts +1 -1
- package/locales/nnNO.d.ts +1 -1
- package/locales/plPL.d.mts +1 -1
- package/locales/plPL.d.ts +1 -1
- package/locales/ptBR.d.mts +1 -1
- package/locales/ptBR.d.ts +1 -1
- package/locales/ptPT.d.mts +1 -1
- package/locales/ptPT.d.ts +1 -1
- package/locales/roRO.d.mts +1 -1
- package/locales/roRO.d.ts +1 -1
- package/locales/roRO.js +2 -3
- package/locales/roRO.mjs +2 -3
- package/locales/ruRU.d.mts +1 -1
- package/locales/ruRU.d.ts +1 -1
- package/locales/skSK.d.mts +1 -1
- package/locales/skSK.d.ts +1 -1
- package/locales/svSE.d.mts +1 -1
- package/locales/svSE.d.ts +1 -1
- package/locales/thTH.d.mts +1 -1
- package/locales/thTH.d.ts +1 -1
- package/locales/trTR.d.mts +1 -1
- package/locales/trTR.d.ts +1 -1
- package/locales/ukUA.d.mts +1 -1
- package/locales/ukUA.d.ts +1 -1
- package/locales/urPK.d.mts +1 -1
- package/locales/urPK.d.ts +1 -1
- package/locales/utils/getPickersLocalization.d.mts +1 -1
- package/locales/utils/getPickersLocalization.d.ts +1 -1
- package/locales/utils/pickersLocaleTextApi.d.mts +2 -2
- package/locales/utils/pickersLocaleTextApi.d.ts +2 -2
- package/locales/viVN.d.mts +1 -1
- package/locales/viVN.d.ts +1 -1
- package/locales/zhCN.d.mts +1 -1
- package/locales/zhCN.d.ts +1 -1
- package/locales/zhHK.d.mts +1 -1
- package/locales/zhHK.d.ts +1 -1
- package/locales/zhTW.d.mts +1 -1
- package/locales/zhTW.d.ts +1 -1
- package/managers/useDateManager.d.mts +4 -4
- package/managers/useDateManager.d.ts +4 -4
- package/managers/useDateTimeManager.d.mts +5 -5
- package/managers/useDateTimeManager.d.ts +5 -5
- package/managers/useTimeManager.d.mts +5 -5
- package/managers/useTimeManager.d.ts +5 -5
- package/models/adapters.d.mts +3 -3
- package/models/adapters.d.ts +3 -3
- package/models/fields.d.mts +4 -4
- package/models/fields.d.ts +4 -4
- package/models/pickers.d.mts +1 -1
- package/models/pickers.d.ts +1 -1
- package/package.json +3 -3
- package/themeAugmentation/components.d.mts +16 -16
- package/themeAugmentation/components.d.ts +16 -16
- package/themeAugmentation/overrides.d.mts +20 -20
- package/themeAugmentation/overrides.d.ts +20 -20
- package/themeAugmentation/props.d.mts +38 -38
- package/themeAugmentation/props.d.ts +38 -38
- package/timeViewRenderers/timeViewRenderers.d.mts +6 -6
- package/timeViewRenderers/timeViewRenderers.d.ts +6 -6
- package/validation/extractValidationProps.d.mts +1 -1
- package/validation/extractValidationProps.d.ts +1 -1
- package/validation/useValidation.d.mts +2 -3
- package/validation/useValidation.d.ts +2 -3
- package/validation/validateDate.d.mts +4 -4
- package/validation/validateDate.d.ts +4 -4
- package/validation/validateDateTime.d.mts +6 -6
- package/validation/validateDateTime.d.ts +6 -6
- package/validation/validateTime.d.mts +4 -4
- package/validation/validateTime.d.ts +4 -4
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { PickersArrowSwitcherProps } from "./PickersArrowSwitcher.types.mjs";
|
|
2
|
+
import type { PickersArrowSwitcherProps } from "./PickersArrowSwitcher.types.mjs";
|
|
3
3
|
export declare const PickersArrowSwitcher: React.ForwardRefExoticComponent<PickersArrowSwitcherProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { PickersArrowSwitcherProps } from "./PickersArrowSwitcher.types.js";
|
|
2
|
+
import type { PickersArrowSwitcherProps } from "./PickersArrowSwitcher.types.js";
|
|
3
3
|
export declare const PickersArrowSwitcher: React.ForwardRefExoticComponent<PickersArrowSwitcherProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { SlotComponentProps } from '@mui/utils/types';
|
|
3
|
-
import IconButton from '@mui/material/IconButton';
|
|
4
|
-
import SvgIcon from '@mui/material/SvgIcon';
|
|
5
|
-
import { PickersArrowSwitcherClasses } from "./pickersArrowSwitcherClasses.mjs";
|
|
6
|
-
import { PickerOwnerState } from "../../../models/index.mjs";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { SlotComponentProps } from '@mui/utils/types';
|
|
3
|
+
import type IconButton from '@mui/material/IconButton';
|
|
4
|
+
import type SvgIcon from '@mui/material/SvgIcon';
|
|
5
|
+
import type { PickersArrowSwitcherClasses } from "./pickersArrowSwitcherClasses.mjs";
|
|
6
|
+
import type { PickerOwnerState } from "../../../models/index.mjs";
|
|
7
7
|
export interface ExportedPickersArrowSwitcherProps {
|
|
8
8
|
/**
|
|
9
9
|
* Overridable component slots.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { SlotComponentProps } from '@mui/utils/types';
|
|
3
|
-
import IconButton from '@mui/material/IconButton';
|
|
4
|
-
import SvgIcon from '@mui/material/SvgIcon';
|
|
5
|
-
import { PickersArrowSwitcherClasses } from "./pickersArrowSwitcherClasses.js";
|
|
6
|
-
import { PickerOwnerState } from "../../../models/index.js";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { SlotComponentProps } from '@mui/utils/types';
|
|
3
|
+
import type IconButton from '@mui/material/IconButton';
|
|
4
|
+
import type SvgIcon from '@mui/material/SvgIcon';
|
|
5
|
+
import type { PickersArrowSwitcherClasses } from "./pickersArrowSwitcherClasses.js";
|
|
6
|
+
import type { PickerOwnerState } from "../../../models/index.js";
|
|
7
7
|
export interface ExportedPickersArrowSwitcherProps {
|
|
8
8
|
/**
|
|
9
9
|
* Overridable component slots.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DialogProps as MuiDialogProps } from '@mui/material/Dialog';
|
|
3
|
-
import { PaperProps as MuiPaperProps } from '@mui/material/Paper';
|
|
4
|
-
import { TransitionProps as MuiTransitionProps } from '@mui/material/transitions';
|
|
2
|
+
import type { DialogProps as MuiDialogProps } from '@mui/material/Dialog';
|
|
3
|
+
import type { PaperProps as MuiPaperProps } from '@mui/material/Paper';
|
|
4
|
+
import type { TransitionProps as MuiTransitionProps } from '@mui/material/transitions';
|
|
5
5
|
export interface PickersModalDialogSlots {
|
|
6
6
|
/**
|
|
7
7
|
* Custom component for the dialog inside which the views are rendered on mobile.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DialogProps as MuiDialogProps } from '@mui/material/Dialog';
|
|
3
|
-
import { PaperProps as MuiPaperProps } from '@mui/material/Paper';
|
|
4
|
-
import { TransitionProps as MuiTransitionProps } from '@mui/material/transitions';
|
|
2
|
+
import type { DialogProps as MuiDialogProps } from '@mui/material/Dialog';
|
|
3
|
+
import type { PaperProps as MuiPaperProps } from '@mui/material/Paper';
|
|
4
|
+
import type { TransitionProps as MuiTransitionProps } from '@mui/material/transitions';
|
|
5
5
|
export interface PickersModalDialogSlots {
|
|
6
6
|
/**
|
|
7
7
|
* Custom component for the dialog inside which the views are rendered on mobile.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { BaseToolbarProps } from "../models/props/toolbar.mjs";
|
|
3
|
-
import { PickersToolbarClasses } from "./pickersToolbarClasses.mjs";
|
|
2
|
+
import type { BaseToolbarProps } from "../models/props/toolbar.mjs";
|
|
3
|
+
import type { PickersToolbarClasses } from "./pickersToolbarClasses.mjs";
|
|
4
4
|
export interface PickersToolbarProps extends Pick<BaseToolbarProps, 'hidden' | 'titleId'> {
|
|
5
5
|
className?: string;
|
|
6
6
|
landscapeDirection?: 'row' | 'column';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { BaseToolbarProps } from "../models/props/toolbar.js";
|
|
3
|
-
import { PickersToolbarClasses } from "./pickersToolbarClasses.js";
|
|
2
|
+
import type { BaseToolbarProps } from "../models/props/toolbar.js";
|
|
3
|
+
import type { PickersToolbarClasses } from "./pickersToolbarClasses.js";
|
|
4
4
|
export interface PickersToolbarProps extends Pick<BaseToolbarProps, 'hidden' | 'titleId'> {
|
|
5
5
|
className?: string;
|
|
6
6
|
landscapeDirection?: 'row' | 'column';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { ButtonProps } from '@mui/material/Button';
|
|
3
|
-
import { TypographyProps } from '@mui/material/Typography';
|
|
4
|
-
import { ExtendMui } from "../models/helpers.mjs";
|
|
5
|
-
import { PickersToolbarButtonClasses } from "./pickersToolbarButtonClasses.mjs";
|
|
2
|
+
import type { ButtonProps } from '@mui/material/Button';
|
|
3
|
+
import type { TypographyProps } from '@mui/material/Typography';
|
|
4
|
+
import type { ExtendMui } from "../models/helpers.mjs";
|
|
5
|
+
import type { PickersToolbarButtonClasses } from "./pickersToolbarButtonClasses.mjs";
|
|
6
6
|
export interface PickersToolbarButtonProps extends ExtendMui<ButtonProps, 'value' | 'variant'> {
|
|
7
7
|
align?: TypographyProps['align'];
|
|
8
8
|
selected: boolean;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { ButtonProps } from '@mui/material/Button';
|
|
3
|
-
import { TypographyProps } from '@mui/material/Typography';
|
|
4
|
-
import { ExtendMui } from "../models/helpers.js";
|
|
5
|
-
import { PickersToolbarButtonClasses } from "./pickersToolbarButtonClasses.js";
|
|
2
|
+
import type { ButtonProps } from '@mui/material/Button';
|
|
3
|
+
import type { TypographyProps } from '@mui/material/Typography';
|
|
4
|
+
import type { ExtendMui } from "../models/helpers.js";
|
|
5
|
+
import type { PickersToolbarButtonClasses } from "./pickersToolbarButtonClasses.js";
|
|
6
6
|
export interface PickersToolbarButtonProps extends ExtendMui<ButtonProps, 'value' | 'variant'> {
|
|
7
7
|
align?: TypographyProps['align'];
|
|
8
8
|
selected: boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { TypographyProps } from '@mui/material/Typography';
|
|
3
|
-
import { PickersToolbarTextClasses } from "./pickersToolbarTextClasses.mjs";
|
|
2
|
+
import type { TypographyProps } from '@mui/material/Typography';
|
|
3
|
+
import type { PickersToolbarTextClasses } from "./pickersToolbarTextClasses.mjs";
|
|
4
4
|
export interface ExportedPickersToolbarTextProps extends Omit<TypographyProps, 'classes' | 'variant' | 'align'> {
|
|
5
5
|
classes?: Partial<PickersToolbarTextClasses>;
|
|
6
6
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { TypographyProps } from '@mui/material/Typography';
|
|
3
|
-
import { PickersToolbarTextClasses } from "./pickersToolbarTextClasses.js";
|
|
2
|
+
import type { TypographyProps } from '@mui/material/Typography';
|
|
3
|
+
import type { PickersToolbarTextClasses } from "./pickersToolbarTextClasses.js";
|
|
4
4
|
export interface ExportedPickersToolbarTextProps extends Omit<TypographyProps, 'classes' | 'variant' | 'align'> {
|
|
5
5
|
classes?: Partial<PickersToolbarTextClasses>;
|
|
6
6
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { StackProps } from '@mui/material/Stack';
|
|
3
|
-
import { SxProps, Theme } from '@mui/material/styles';
|
|
2
|
+
import type { StackProps } from '@mui/material/Stack';
|
|
3
|
+
import type { SxProps, Theme } from '@mui/material/styles';
|
|
4
4
|
interface DemoGridProps {
|
|
5
5
|
children: React.ReactNode;
|
|
6
6
|
components: string[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { StackProps } from '@mui/material/Stack';
|
|
3
|
-
import { SxProps, Theme } from '@mui/material/styles';
|
|
2
|
+
import type { StackProps } from '@mui/material/Stack';
|
|
3
|
+
import type { SxProps, Theme } from '@mui/material/styles';
|
|
4
4
|
interface DemoGridProps {
|
|
5
5
|
children: React.ReactNode;
|
|
6
6
|
components: string[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PickerOnChangeFn } from "./useViews.mjs";
|
|
2
|
-
import { PickerSelectionState } from "./usePicker/index.mjs";
|
|
3
|
-
import { PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
1
|
+
import type { PickerOnChangeFn } from "./useViews.mjs";
|
|
2
|
+
import type { PickerSelectionState } from "./usePicker/index.mjs";
|
|
3
|
+
import type { PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
4
4
|
export interface MonthValidationOptions {
|
|
5
5
|
disablePast?: boolean;
|
|
6
6
|
disableFuture?: boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PickerOnChangeFn } from "./useViews.js";
|
|
2
|
-
import { PickerSelectionState } from "./usePicker/index.js";
|
|
3
|
-
import { PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
1
|
+
import type { PickerOnChangeFn } from "./useViews.js";
|
|
2
|
+
import type { PickerSelectionState } from "./usePicker/index.js";
|
|
3
|
+
import type { PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
4
4
|
export interface MonthValidationOptions {
|
|
5
5
|
disablePast?: boolean;
|
|
6
6
|
disableFuture?: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MuiPickersAdapter, PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
2
|
-
import { PickerValue } from "../models/index.mjs";
|
|
1
|
+
import type { MuiPickersAdapter, PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
2
|
+
import type { PickerValue } from "../models/index.mjs";
|
|
3
3
|
export declare const useClockReferenceDate: <TProps extends {}>({
|
|
4
4
|
value,
|
|
5
5
|
referenceDate: referenceDateProp,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MuiPickersAdapter, PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
2
|
-
import { PickerValue } from "../models/index.js";
|
|
1
|
+
import type { MuiPickersAdapter, PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
2
|
+
import type { PickerValue } from "../models/index.js";
|
|
3
3
|
export declare const useClockReferenceDate: <TProps extends {}>({
|
|
4
4
|
value,
|
|
5
5
|
referenceDate: referenceDateProp,
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type { PickerRangeValue, PickerValueManager } from "../models/index.mjs";
|
|
2
|
-
import { PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
3
|
-
import { PickerValidValue } from "../models/index.mjs";
|
|
1
|
+
import type { PickerRangeValue, PickerValueManager, PickerValidValue } from "../models/index.mjs";
|
|
2
|
+
import type { PickersTimezone, PickerValidDate } from "../../models/index.mjs";
|
|
4
3
|
/**
|
|
5
4
|
* Hooks controlling the value while making sure that:
|
|
6
5
|
* - The value returned by `onChange` always have the timezone of `props.value` or `props.defaultValue` if defined
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type { PickerRangeValue, PickerValueManager } from "../models/index.js";
|
|
2
|
-
import { PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
3
|
-
import { PickerValidValue } from "../models/index.js";
|
|
1
|
+
import type { PickerRangeValue, PickerValueManager, PickerValidValue } from "../models/index.js";
|
|
2
|
+
import type { PickersTimezone, PickerValidDate } from "../../models/index.js";
|
|
4
3
|
/**
|
|
5
4
|
* Hooks controlling the value while making sure that:
|
|
6
5
|
* - The value returned by `onChange` always have the timezone of `props.value` or `props.defaultValue` if defined
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UseDesktopPickerParams, UseDesktopPickerProps } from "./useDesktopPicker.types.mjs";
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from "../../models/index.mjs";
|
|
1
|
+
import type { UseDesktopPickerParams, UseDesktopPickerProps } from "./useDesktopPicker.types.mjs";
|
|
2
|
+
import type { DateOrTimeViewWithMeridiem } from "../../models/index.mjs";
|
|
3
3
|
/**
|
|
4
4
|
* Hook managing all the single-date desktop pickers:
|
|
5
5
|
* - DesktopDatePicker
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UseDesktopPickerParams, UseDesktopPickerProps } from "./useDesktopPicker.types.js";
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from "../../models/index.js";
|
|
1
|
+
import type { UseDesktopPickerParams, UseDesktopPickerProps } from "./useDesktopPicker.types.js";
|
|
2
|
+
import type { DateOrTimeViewWithMeridiem } from "../../models/index.js";
|
|
3
3
|
/**
|
|
4
4
|
* Hook managing all the single-date desktop pickers:
|
|
5
5
|
* - DesktopDatePicker
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { MakeRequired, SlotComponentPropsFromProps } from '@mui/x-internals/types';
|
|
3
|
-
import { BasePickerProps } from "../../models/props/basePickerProps.mjs";
|
|
4
|
-
import { PickerPopperSlots, PickerPopperSlotProps } from "../../components/PickerPopper/PickerPopper.mjs";
|
|
5
|
-
import { UsePickerParameters, UsePickerNonStaticProps, UsePickerProps } from "../usePicker/index.mjs";
|
|
6
|
-
import { PickerFieldSlotProps, PickerOwnerState } from "../../../models/index.mjs";
|
|
7
|
-
import { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps, PickersLayoutSlotProps } from "../../../PickersLayout/PickersLayout.types.mjs";
|
|
8
|
-
import { DateOrTimeViewWithMeridiem, PickerValue } from "../../models/index.mjs";
|
|
9
|
-
import { PickerFieldUISlotsFromContext, PickerFieldUISlotPropsFromContext } from "../../components/PickerFieldUI.mjs";
|
|
10
|
-
import { PickerStep } from "../../utils/createNonRangePickerStepNavigation.mjs";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { MakeRequired, SlotComponentPropsFromProps } from '@mui/x-internals/types';
|
|
3
|
+
import type { BasePickerProps } from "../../models/props/basePickerProps.mjs";
|
|
4
|
+
import type { PickerPopperSlots, PickerPopperSlotProps } from "../../components/PickerPopper/PickerPopper.mjs";
|
|
5
|
+
import type { UsePickerParameters, UsePickerNonStaticProps, UsePickerProps } from "../usePicker/index.mjs";
|
|
6
|
+
import type { PickerFieldSlotProps, PickerOwnerState } from "../../../models/index.mjs";
|
|
7
|
+
import type { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps, PickersLayoutSlotProps } from "../../../PickersLayout/PickersLayout.types.mjs";
|
|
8
|
+
import type { DateOrTimeViewWithMeridiem, PickerValue } from "../../models/index.mjs";
|
|
9
|
+
import type { PickerFieldUISlotsFromContext, PickerFieldUISlotPropsFromContext } from "../../components/PickerFieldUI.mjs";
|
|
10
|
+
import type { PickerStep } from "../../utils/createNonRangePickerStepNavigation.mjs";
|
|
11
11
|
export interface UseDesktopPickerSlots extends Pick<PickerPopperSlots, 'desktopPaper' | 'desktopTransition' | 'desktopTrapFocus' | 'popper'>, ExportedPickersLayoutSlots<PickerValue>, PickerFieldUISlotsFromContext {
|
|
12
12
|
/**
|
|
13
13
|
* Component used to enter the date with the keyboard.
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { MakeRequired, SlotComponentPropsFromProps } from '@mui/x-internals/types';
|
|
3
|
-
import { BasePickerProps } from "../../models/props/basePickerProps.js";
|
|
4
|
-
import { PickerPopperSlots, PickerPopperSlotProps } from "../../components/PickerPopper/PickerPopper.js";
|
|
5
|
-
import { UsePickerParameters, UsePickerNonStaticProps, UsePickerProps } from "../usePicker/index.js";
|
|
6
|
-
import { PickerFieldSlotProps, PickerOwnerState } from "../../../models/index.js";
|
|
7
|
-
import { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps, PickersLayoutSlotProps } from "../../../PickersLayout/PickersLayout.types.js";
|
|
8
|
-
import { DateOrTimeViewWithMeridiem, PickerValue } from "../../models/index.js";
|
|
9
|
-
import { PickerFieldUISlotsFromContext, PickerFieldUISlotPropsFromContext } from "../../components/PickerFieldUI.js";
|
|
10
|
-
import { PickerStep } from "../../utils/createNonRangePickerStepNavigation.js";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { MakeRequired, SlotComponentPropsFromProps } from '@mui/x-internals/types';
|
|
3
|
+
import type { BasePickerProps } from "../../models/props/basePickerProps.js";
|
|
4
|
+
import type { PickerPopperSlots, PickerPopperSlotProps } from "../../components/PickerPopper/PickerPopper.js";
|
|
5
|
+
import type { UsePickerParameters, UsePickerNonStaticProps, UsePickerProps } from "../usePicker/index.js";
|
|
6
|
+
import type { PickerFieldSlotProps, PickerOwnerState } from "../../../models/index.js";
|
|
7
|
+
import type { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps, PickersLayoutSlotProps } from "../../../PickersLayout/PickersLayout.types.js";
|
|
8
|
+
import type { DateOrTimeViewWithMeridiem, PickerValue } from "../../models/index.js";
|
|
9
|
+
import type { PickerFieldUISlotsFromContext, PickerFieldUISlotPropsFromContext } from "../../components/PickerFieldUI.js";
|
|
10
|
+
import type { PickerStep } from "../../utils/createNonRangePickerStepNavigation.js";
|
|
11
11
|
export interface UseDesktopPickerSlots extends Pick<PickerPopperSlots, 'desktopPaper' | 'desktopTransition' | 'desktopTrapFocus' | 'popper'>, ExportedPickersLayoutSlots<PickerValue>, PickerFieldUISlotsFromContext {
|
|
12
12
|
/**
|
|
13
13
|
* Component used to enter the date with the keyboard.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FieldSection, MuiPickersAdapter, PickerValidDate } from "../../../models/index.mjs";
|
|
2
|
-
import { PickersLocaleText } from "../../../locales/index.mjs";
|
|
1
|
+
import type { FieldSection, MuiPickersAdapter, PickerValidDate } from "../../../models/index.mjs";
|
|
2
|
+
import type { PickersLocaleText } from "../../../locales/index.mjs";
|
|
3
3
|
interface BuildSectionsFromFormatParameters {
|
|
4
4
|
adapter: MuiPickersAdapter;
|
|
5
5
|
format: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FieldSection, MuiPickersAdapter, PickerValidDate } from "../../../models/index.js";
|
|
2
|
-
import { PickersLocaleText } from "../../../locales/index.js";
|
|
1
|
+
import type { FieldSection, MuiPickersAdapter, PickerValidDate } from "../../../models/index.js";
|
|
2
|
+
import type { PickersLocaleText } from "../../../locales/index.js";
|
|
3
3
|
interface BuildSectionsFromFormatParameters {
|
|
4
4
|
adapter: MuiPickersAdapter;
|
|
5
5
|
format: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PickerValidValue } from "../../models/index.mjs";
|
|
2
|
-
import { UseFieldDOMGetters } from "./useField.types.mjs";
|
|
3
|
-
import { UseFieldStateReturnValue } from "./useFieldState.mjs";
|
|
1
|
+
import type { PickerValidValue } from "../../models/index.mjs";
|
|
2
|
+
import type { UseFieldDOMGetters } from "./useField.types.mjs";
|
|
3
|
+
import type { UseFieldStateReturnValue } from "./useFieldState.mjs";
|
|
4
4
|
export declare function syncSelectionToDOM<TValue extends PickerValidValue>(parameters: SyncSelectionToDOMParameters<TValue>): void;
|
|
5
5
|
export interface SyncSelectionToDOMParameters<TValue extends PickerValidValue> {
|
|
6
6
|
domGetters: UseFieldDOMGetters;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { PickerValidValue } from "../../models/index.js";
|
|
2
|
-
import { UseFieldDOMGetters } from "./useField.types.js";
|
|
3
|
-
import { UseFieldStateReturnValue } from "./useFieldState.js";
|
|
1
|
+
import type { PickerValidValue } from "../../models/index.js";
|
|
2
|
+
import type { UseFieldDOMGetters } from "./useField.types.js";
|
|
3
|
+
import type { UseFieldStateReturnValue } from "./useFieldState.js";
|
|
4
4
|
export declare function syncSelectionToDOM<TValue extends PickerValidValue>(parameters: SyncSelectionToDOMParameters<TValue>): void;
|
|
5
5
|
export interface SyncSelectionToDOMParameters<TValue extends PickerValidValue> {
|
|
6
6
|
domGetters: UseFieldDOMGetters;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { UseFieldParameters, UseFieldProps, UseFieldReturnValue } from "./useField.types.mjs";
|
|
2
|
-
import { PickerValidValue } from "../../models/index.mjs";
|
|
1
|
+
import type { UseFieldParameters, UseFieldProps, UseFieldReturnValue } from "./useField.types.mjs";
|
|
2
|
+
import type { PickerValidValue } from "../../models/index.mjs";
|
|
3
3
|
export declare const useField: <TValue extends PickerValidValue, TError, TValidationProps extends {}, TProps extends UseFieldProps>(parameters: UseFieldParameters<TValue, TError, TValidationProps, TProps>) => UseFieldReturnValue<TProps>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { UseFieldParameters, UseFieldProps, UseFieldReturnValue } from "./useField.types.js";
|
|
2
|
-
import { PickerValidValue } from "../../models/index.js";
|
|
1
|
+
import type { UseFieldParameters, UseFieldProps, UseFieldReturnValue } from "./useField.types.js";
|
|
2
|
+
import type { PickerValidValue } from "../../models/index.js";
|
|
3
3
|
export declare const useField: <TValue extends PickerValidValue, TError, TValidationProps extends {}, TProps extends UseFieldProps>(parameters: UseFieldParameters<TValue, TError, TValidationProps, TProps>) => UseFieldReturnValue<TProps>;
|
|
@@ -53,6 +53,7 @@ const useField = parameters => {
|
|
|
53
53
|
sectionListRef: sectionListRefProp,
|
|
54
54
|
onBlur,
|
|
55
55
|
onClick,
|
|
56
|
+
onMouseDown,
|
|
56
57
|
onFocus,
|
|
57
58
|
onInput,
|
|
58
59
|
onPaste,
|
|
@@ -167,6 +168,22 @@ const useField = parameters => {
|
|
|
167
168
|
onClick?.(event);
|
|
168
169
|
rootProps.onClick(event);
|
|
169
170
|
});
|
|
171
|
+
const handleRootMouseDown = (0, _useEventCallback.default)(event => {
|
|
172
|
+
// The `isDefaultPrevented` check skips mousedowns that have already been
|
|
173
|
+
// suppressed before this handler runs -- in particular, propagated events
|
|
174
|
+
// from the clear / open buttons whose own handlers `preventDefault`, and
|
|
175
|
+
// capture-phase parents that intentionally block field interactions.
|
|
176
|
+
// Userland `onMouseDown` calling `event.preventDefault()` does *not*
|
|
177
|
+
// suppress `rootProps.onMouseDown` here: the prevent fires *after* this
|
|
178
|
+
// check, and `rootProps.onMouseDown` is the section-selection mechanism
|
|
179
|
+
// for the field -- letting consumers disable it inline would leave the
|
|
180
|
+
// field unable to focus a section on click.
|
|
181
|
+
if (event.isDefaultPrevented()) {
|
|
182
|
+
return;
|
|
183
|
+
}
|
|
184
|
+
onMouseDown?.(event);
|
|
185
|
+
rootProps.onMouseDown(event);
|
|
186
|
+
});
|
|
170
187
|
const handleRootPaste = (0, _useEventCallback.default)(event => {
|
|
171
188
|
onPaste?.(event);
|
|
172
189
|
rootProps.onPaste(event);
|
|
@@ -253,6 +270,7 @@ Learn more about the field accessible DOM structure on the MUI documentation: ht
|
|
|
253
270
|
return (0, _extends2.default)({}, forwardedProps, rootProps, {
|
|
254
271
|
onBlur: handleRootBlur,
|
|
255
272
|
onClick: handleRootClick,
|
|
273
|
+
onMouseDown: handleRootMouseDown,
|
|
256
274
|
onFocus: handleRootFocus,
|
|
257
275
|
onInput: handleRootInput,
|
|
258
276
|
onPaste: handleRootPaste,
|
|
@@ -46,6 +46,7 @@ export const useField = parameters => {
|
|
|
46
46
|
sectionListRef: sectionListRefProp,
|
|
47
47
|
onBlur,
|
|
48
48
|
onClick,
|
|
49
|
+
onMouseDown,
|
|
49
50
|
onFocus,
|
|
50
51
|
onInput,
|
|
51
52
|
onPaste,
|
|
@@ -160,6 +161,22 @@ export const useField = parameters => {
|
|
|
160
161
|
onClick?.(event);
|
|
161
162
|
rootProps.onClick(event);
|
|
162
163
|
});
|
|
164
|
+
const handleRootMouseDown = useEventCallback(event => {
|
|
165
|
+
// The `isDefaultPrevented` check skips mousedowns that have already been
|
|
166
|
+
// suppressed before this handler runs -- in particular, propagated events
|
|
167
|
+
// from the clear / open buttons whose own handlers `preventDefault`, and
|
|
168
|
+
// capture-phase parents that intentionally block field interactions.
|
|
169
|
+
// Userland `onMouseDown` calling `event.preventDefault()` does *not*
|
|
170
|
+
// suppress `rootProps.onMouseDown` here: the prevent fires *after* this
|
|
171
|
+
// check, and `rootProps.onMouseDown` is the section-selection mechanism
|
|
172
|
+
// for the field -- letting consumers disable it inline would leave the
|
|
173
|
+
// field unable to focus a section on click.
|
|
174
|
+
if (event.isDefaultPrevented()) {
|
|
175
|
+
return;
|
|
176
|
+
}
|
|
177
|
+
onMouseDown?.(event);
|
|
178
|
+
rootProps.onMouseDown(event);
|
|
179
|
+
});
|
|
163
180
|
const handleRootPaste = useEventCallback(event => {
|
|
164
181
|
onPaste?.(event);
|
|
165
182
|
rootProps.onPaste(event);
|
|
@@ -246,6 +263,7 @@ Learn more about the field accessible DOM structure on the MUI documentation: ht
|
|
|
246
263
|
return _extends({}, forwardedProps, rootProps, {
|
|
247
264
|
onBlur: handleRootBlur,
|
|
248
265
|
onClick: handleRootClick,
|
|
266
|
+
onMouseDown: handleRootMouseDown,
|
|
249
267
|
onFocus: handleRootFocus,
|
|
250
268
|
onInput: handleRootInput,
|
|
251
269
|
onPaste: handleRootPaste,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { FieldSectionType, FieldSection, FieldSelectedSections, MuiPickersAdapter, TimezoneProps, FieldSectionContentType, PickerValidDate, FieldRef, OnErrorProps, InferFieldSection, PickerManager, PickerValueType } from "../../../models/index.mjs";
|
|
3
|
-
import { InternalPropNames } from "../../../hooks/useSplitFieldProps.mjs";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { FieldSectionType, FieldSection, FieldSelectedSections, MuiPickersAdapter, TimezoneProps, FieldSectionContentType, PickerValidDate, FieldRef, OnErrorProps, InferFieldSection, PickerManager, PickerValueType } from "../../../models/index.mjs";
|
|
3
|
+
import type { InternalPropNames } from "../../../hooks/useSplitFieldProps.mjs";
|
|
4
4
|
import type { PickersSectionElement, PickersSectionListRef } from "../../../PickersSectionList/index.mjs";
|
|
5
|
-
import { FormProps, InferNonNullablePickerValue, PickerRangeValue, PickerValidValue } from "../../models/index.mjs";
|
|
5
|
+
import type { FormProps, InferNonNullablePickerValue, PickerRangeValue, PickerValidValue } from "../../models/index.mjs";
|
|
6
6
|
export interface UseFieldParameters<TValue extends PickerValidValue, TError, TValidationProps extends {}, TProps extends UseFieldProps> {
|
|
7
7
|
manager: PickerManager<TValue, TError, TValidationProps, any>;
|
|
8
8
|
props: TProps;
|
|
@@ -92,6 +92,7 @@ export interface UseFieldForwardedProps {
|
|
|
92
92
|
focused?: boolean;
|
|
93
93
|
sectionListRef?: React.Ref<PickersSectionListRef>;
|
|
94
94
|
onClick?: React.MouseEventHandler;
|
|
95
|
+
onMouseDown?: React.MouseEventHandler;
|
|
95
96
|
onKeyDown?: React.KeyboardEventHandler;
|
|
96
97
|
onFocus?: React.FocusEventHandler;
|
|
97
98
|
onBlur?: React.FocusEventHandler;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { FieldSectionType, FieldSection, FieldSelectedSections, MuiPickersAdapter, TimezoneProps, FieldSectionContentType, PickerValidDate, FieldRef, OnErrorProps, InferFieldSection, PickerManager, PickerValueType } from "../../../models/index.js";
|
|
3
|
-
import { InternalPropNames } from "../../../hooks/useSplitFieldProps.js";
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import type { FieldSectionType, FieldSection, FieldSelectedSections, MuiPickersAdapter, TimezoneProps, FieldSectionContentType, PickerValidDate, FieldRef, OnErrorProps, InferFieldSection, PickerManager, PickerValueType } from "../../../models/index.js";
|
|
3
|
+
import type { InternalPropNames } from "../../../hooks/useSplitFieldProps.js";
|
|
4
4
|
import type { PickersSectionElement, PickersSectionListRef } from "../../../PickersSectionList/index.js";
|
|
5
|
-
import { FormProps, InferNonNullablePickerValue, PickerRangeValue, PickerValidValue } from "../../models/index.js";
|
|
5
|
+
import type { FormProps, InferNonNullablePickerValue, PickerRangeValue, PickerValidValue } from "../../models/index.js";
|
|
6
6
|
export interface UseFieldParameters<TValue extends PickerValidValue, TError, TValidationProps extends {}, TProps extends UseFieldProps> {
|
|
7
7
|
manager: PickerManager<TValue, TError, TValidationProps, any>;
|
|
8
8
|
props: TProps;
|
|
@@ -92,6 +92,7 @@ export interface UseFieldForwardedProps {
|
|
|
92
92
|
focused?: boolean;
|
|
93
93
|
sectionListRef?: React.Ref<PickersSectionListRef>;
|
|
94
94
|
onClick?: React.MouseEventHandler;
|
|
95
|
+
onMouseDown?: React.MouseEventHandler;
|
|
95
96
|
onKeyDown?: React.KeyboardEventHandler;
|
|
96
97
|
onFocus?: React.FocusEventHandler;
|
|
97
98
|
onBlur?: React.FocusEventHandler;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import { FieldSectionsValueBoundaries, SectionOrdering, FieldSectionValueBoundaries, FieldParsedSelectedSections } from "./useField.types.mjs";
|
|
2
|
-
import { FieldSectionType, FieldSection, MuiPickersAdapter, FieldSectionContentType, PickersTimezone, PickerValidDate, FieldSelectedSections, PickerValueType, InferFieldSection } from "../../../models/index.mjs";
|
|
3
|
-
import { PickerValidValue } from "../../models/index.mjs";
|
|
1
|
+
import type { FieldSectionsValueBoundaries, SectionOrdering, FieldSectionValueBoundaries, FieldParsedSelectedSections } from "./useField.types.mjs";
|
|
2
|
+
import type { FieldSectionType, FieldSection, MuiPickersAdapter, FieldSectionContentType, PickersTimezone, PickerValidDate, FieldSelectedSections, PickerValueType, InferFieldSection } from "../../../models/index.mjs";
|
|
3
|
+
import type { PickerValidValue } from "../../models/index.mjs";
|
|
4
4
|
export declare const getDateSectionConfigFromFormatToken: (adapter: MuiPickersAdapter, formatToken: string) => Pick<FieldSection, "type" | "contentType"> & {
|
|
5
5
|
maxLength: number | undefined;
|
|
6
6
|
};
|
|
7
7
|
export declare const getDaysInWeekStr: (adapter: MuiPickersAdapter, format: string) => string[];
|
|
8
8
|
export declare const getLetterEditingOptions: (adapter: MuiPickersAdapter, timezone: PickersTimezone, sectionType: FieldSectionType, format: string) => string[];
|
|
9
|
-
export declare const FORMAT_SECONDS_NO_LEADING_ZEROS = "s";
|
|
10
9
|
export declare const getLocalizedDigits: (adapter: MuiPickersAdapter) => string[];
|
|
11
10
|
export declare const removeLocalizedDigits: (valueStr: string, localizedDigits: string[]) => string;
|
|
12
11
|
export declare const applyLocalizedDigits: (valueStr: string, localizedDigits: string[]) => string;
|
|
@@ -30,6 +29,5 @@ export declare const createDateStrForHiddenInputFromSections: (sections: FieldSe
|
|
|
30
29
|
export declare const getSectionsBoundaries: (adapter: MuiPickersAdapter, localizedDigits: string[], timezone: PickersTimezone) => FieldSectionsValueBoundaries;
|
|
31
30
|
export declare const validateSections: <TValue extends PickerValidValue>(sections: InferFieldSection<TValue>[], valueType: PickerValueType) => void;
|
|
32
31
|
export declare const mergeDateIntoReferenceDate: (adapter: MuiPickersAdapter, dateToTransferFrom: PickerValidDate, sections: FieldSection[], referenceDate: PickerValidDate, shouldLimitToEditedSections: boolean) => PickerValidDate;
|
|
33
|
-
export declare const isAndroid: () => boolean;
|
|
34
32
|
export declare const getSectionOrder: (sections: FieldSection[]) => SectionOrdering;
|
|
35
33
|
export declare const parseSelectedSections: (selectedSections: FieldSelectedSections, sections: FieldSection[]) => FieldParsedSelectedSections;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import { FieldSectionsValueBoundaries, SectionOrdering, FieldSectionValueBoundaries, FieldParsedSelectedSections } from "./useField.types.js";
|
|
2
|
-
import { FieldSectionType, FieldSection, MuiPickersAdapter, FieldSectionContentType, PickersTimezone, PickerValidDate, FieldSelectedSections, PickerValueType, InferFieldSection } from "../../../models/index.js";
|
|
3
|
-
import { PickerValidValue } from "../../models/index.js";
|
|
1
|
+
import type { FieldSectionsValueBoundaries, SectionOrdering, FieldSectionValueBoundaries, FieldParsedSelectedSections } from "./useField.types.js";
|
|
2
|
+
import type { FieldSectionType, FieldSection, MuiPickersAdapter, FieldSectionContentType, PickersTimezone, PickerValidDate, FieldSelectedSections, PickerValueType, InferFieldSection } from "../../../models/index.js";
|
|
3
|
+
import type { PickerValidValue } from "../../models/index.js";
|
|
4
4
|
export declare const getDateSectionConfigFromFormatToken: (adapter: MuiPickersAdapter, formatToken: string) => Pick<FieldSection, "type" | "contentType"> & {
|
|
5
5
|
maxLength: number | undefined;
|
|
6
6
|
};
|
|
7
7
|
export declare const getDaysInWeekStr: (adapter: MuiPickersAdapter, format: string) => string[];
|
|
8
8
|
export declare const getLetterEditingOptions: (adapter: MuiPickersAdapter, timezone: PickersTimezone, sectionType: FieldSectionType, format: string) => string[];
|
|
9
|
-
export declare const FORMAT_SECONDS_NO_LEADING_ZEROS = "s";
|
|
10
9
|
export declare const getLocalizedDigits: (adapter: MuiPickersAdapter) => string[];
|
|
11
10
|
export declare const removeLocalizedDigits: (valueStr: string, localizedDigits: string[]) => string;
|
|
12
11
|
export declare const applyLocalizedDigits: (valueStr: string, localizedDigits: string[]) => string;
|
|
@@ -30,6 +29,5 @@ export declare const createDateStrForHiddenInputFromSections: (sections: FieldSe
|
|
|
30
29
|
export declare const getSectionsBoundaries: (adapter: MuiPickersAdapter, localizedDigits: string[], timezone: PickersTimezone) => FieldSectionsValueBoundaries;
|
|
31
30
|
export declare const validateSections: <TValue extends PickerValidValue>(sections: InferFieldSection<TValue>[], valueType: PickerValueType) => void;
|
|
32
31
|
export declare const mergeDateIntoReferenceDate: (adapter: MuiPickersAdapter, dateToTransferFrom: PickerValidDate, sections: FieldSection[], referenceDate: PickerValidDate, shouldLimitToEditedSections: boolean) => PickerValidDate;
|
|
33
|
-
export declare const isAndroid: () => boolean;
|
|
34
32
|
export declare const getSectionOrder: (sections: FieldSection[]) => SectionOrdering;
|
|
35
33
|
export declare const parseSelectedSections: (selectedSections: FieldSelectedSections, sections: FieldSection[]) => FieldParsedSelectedSections;
|
|
@@ -4,7 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.validateSections = exports.removeLocalizedDigits = exports.parseSelectedSections = exports.mergeDateIntoReferenceDate = exports.isStringNumber = exports.
|
|
7
|
+
exports.validateSections = exports.removeLocalizedDigits = exports.parseSelectedSections = exports.mergeDateIntoReferenceDate = exports.isStringNumber = exports.getSectionsBoundaries = exports.getSectionVisibleValue = exports.getSectionOrder = exports.getLocalizedDigits = exports.getLetterEditingOptions = exports.getDaysInWeekStr = exports.getDateSectionConfigFromFormatToken = exports.getDateFromDateSections = exports.doesSectionFormatHaveLeadingZeros = exports.createDateStrForHiddenInputFromSections = exports.cleanLeadingZeros = exports.cleanDigitSectionValue = exports.changeSectionValueFormat = exports.applyLocalizedDigits = void 0;
|
|
8
8
|
var _formatErrorMessage2 = _interopRequireDefault(require("@mui/x-internals/formatErrorMessage"));
|
|
9
9
|
var _dateUtils = require("../../utils/date-utils");
|
|
10
10
|
var _timeUtils = require("../../utils/time-utils");
|
|
@@ -66,7 +66,7 @@ const getLetterEditingOptions = (adapter, timezone, sectionType, format) => {
|
|
|
66
66
|
// This format should be the same on all the adapters
|
|
67
67
|
// If some adapter does not respect this convention, then we will need to hardcode the format on each adapter.
|
|
68
68
|
exports.getLetterEditingOptions = getLetterEditingOptions;
|
|
69
|
-
const FORMAT_SECONDS_NO_LEADING_ZEROS =
|
|
69
|
+
const FORMAT_SECONDS_NO_LEADING_ZEROS = 's';
|
|
70
70
|
const NON_LOCALIZED_DIGITS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'];
|
|
71
71
|
const getLocalizedDigits = adapter => {
|
|
72
72
|
const today = adapter.date(undefined);
|
|
@@ -452,8 +452,6 @@ const mergeDateIntoReferenceDate = (adapter, dateToTransferFrom, sections, refer
|
|
|
452
452
|
return mergedDate;
|
|
453
453
|
}, referenceDate);
|
|
454
454
|
exports.mergeDateIntoReferenceDate = mergeDateIntoReferenceDate;
|
|
455
|
-
const isAndroid = () => navigator.userAgent.toLowerCase().includes('android');
|
|
456
|
-
exports.isAndroid = isAndroid;
|
|
457
455
|
const getSectionOrder = sections => {
|
|
458
456
|
const neighbors = {};
|
|
459
457
|
sections.forEach((_, index) => {
|
|
@@ -56,7 +56,7 @@ export const getLetterEditingOptions = (adapter, timezone, sectionType, format)
|
|
|
56
56
|
|
|
57
57
|
// This format should be the same on all the adapters
|
|
58
58
|
// If some adapter does not respect this convention, then we will need to hardcode the format on each adapter.
|
|
59
|
-
|
|
59
|
+
const FORMAT_SECONDS_NO_LEADING_ZEROS = 's';
|
|
60
60
|
const NON_LOCALIZED_DIGITS = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'];
|
|
61
61
|
export const getLocalizedDigits = adapter => {
|
|
62
62
|
const today = adapter.date(undefined);
|
|
@@ -428,7 +428,6 @@ export const mergeDateIntoReferenceDate = (adapter, dateToTransferFrom, sections
|
|
|
428
428
|
}
|
|
429
429
|
return mergedDate;
|
|
430
430
|
}, referenceDate);
|
|
431
|
-
export const isAndroid = () => navigator.userAgent.toLowerCase().includes('android');
|
|
432
431
|
export const getSectionOrder = sections => {
|
|
433
432
|
const neighbors = {};
|
|
434
433
|
sections.forEach((_, index) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UseFieldStateReturnValue } from "./useFieldState.mjs";
|
|
2
|
-
import { PickerValidValue } from "../../models/index.mjs";
|
|
1
|
+
import type { UseFieldStateReturnValue } from "./useFieldState.mjs";
|
|
2
|
+
import type { PickerValidValue } from "../../models/index.mjs";
|
|
3
3
|
/**
|
|
4
4
|
* Update the active section value when the user pressed a key that is not a navigation key (arrow key for example).
|
|
5
5
|
* This hook has two main editing behaviors
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UseFieldStateReturnValue } from "./useFieldState.js";
|
|
2
|
-
import { PickerValidValue } from "../../models/index.js";
|
|
1
|
+
import type { UseFieldStateReturnValue } from "./useFieldState.js";
|
|
2
|
+
import type { PickerValidValue } from "../../models/index.js";
|
|
3
3
|
/**
|
|
4
4
|
* Update the active section value when the user pressed a key that is not a navigation key (arrow key for example).
|
|
5
5
|
* This hook has two main editing behaviors
|