@mui/x-date-pickers 7.0.0-alpha.8 → 7.0.0-alpha.9
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/AdapterLuxon/AdapterLuxon.d.ts +1 -1
- package/AdapterLuxon/AdapterLuxon.js +4 -12
- package/CHANGELOG.md +379 -2
- package/DatePicker/DatePicker.js +0 -3
- package/DatePicker/DatePickerToolbar.js +0 -3
- package/DateTimePicker/DateTimePicker.js +0 -3
- package/DateTimePicker/DateTimePickerToolbar.js +0 -3
- package/DesktopDatePicker/DesktopDatePicker.js +0 -3
- package/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
- package/DesktopTimePicker/DesktopTimePicker.js +0 -3
- package/MobileDatePicker/MobileDatePicker.js +0 -3
- package/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
- package/MobileTimePicker/MobileTimePicker.js +0 -3
- package/MonthCalendar/MonthCalendar.js +0 -3
- package/MonthCalendar/MonthCalendar.types.d.ts +0 -3
- package/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
- package/PickersCalendarHeader/PickersCalendarHeader.types.d.ts +0 -3
- package/PickersSectionList/PickersSectionList.js +6 -1
- package/PickersTextField/PickersFilledInput/PickersFilledInput.d.ts +11 -0
- package/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +98 -25
- package/PickersTextField/PickersFilledInput/index.d.ts +4 -0
- package/PickersTextField/PickersFilledInput/index.js +2 -0
- package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.d.ts +23 -0
- package/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
- package/PickersTextField/PickersInput/PickersInput.d.ts +10 -0
- package/PickersTextField/PickersInput/PickersInput.js +196 -0
- package/{internals/components → PickersTextField}/PickersInput/index.d.ts +2 -2
- package/PickersTextField/PickersInput/index.js +2 -0
- package/PickersTextField/PickersInput/pickersInputClasses.d.ts +22 -0
- package/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
- package/PickersTextField/PickersInputBase/PickersInputBase.d.ts +16 -0
- package/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
- package/{internals/components/PickersInput/PickersInput.types.d.ts → PickersTextField/PickersInputBase/PickersInputBase.types.d.ts} +3 -13
- package/PickersTextField/PickersInputBase/index.d.ts +4 -0
- package/PickersTextField/PickersInputBase/index.js +2 -0
- package/PickersTextField/PickersInputBase/pickersInputBaseClasses.d.ts +31 -0
- package/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
- package/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.d.ts +3 -0
- package/{modern/internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.d.ts +10 -0
- package/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +190 -0
- package/PickersTextField/PickersOutlinedInput/index.d.ts +4 -0
- package/PickersTextField/PickersOutlinedInput/index.js +2 -0
- package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.d.ts +22 -0
- package/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
- package/PickersTextField/PickersTextField.d.ts +3 -0
- package/PickersTextField/PickersTextField.js +258 -0
- package/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.d.ts +5 -2
- package/PickersTextField/index.d.ts +8 -0
- package/PickersTextField/index.js +6 -0
- package/PickersTextField/package.json +6 -0
- package/README.md +1 -1
- package/StaticDatePicker/StaticDatePicker.js +0 -3
- package/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
- package/StaticTimePicker/StaticTimePicker.js +0 -3
- package/TimePicker/TimePicker.js +0 -3
- package/TimePicker/TimePickerToolbar.js +0 -3
- package/YearCalendar/YearCalendar.js +0 -3
- package/YearCalendar/YearCalendar.types.d.ts +0 -3
- package/index.d.ts +2 -1
- package/index.js +3 -2
- package/internals/hooks/useField/useField.js +6 -4
- package/internals/hooks/useField/useField.types.d.ts +4 -2
- package/internals/hooks/useField/useField.utils.d.ts +19 -9
- package/internals/hooks/useField/useField.utils.js +68 -21
- package/internals/hooks/useField/useFieldCharacterEditing.d.ts +2 -1
- package/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
- package/internals/hooks/useField/useFieldState.d.ts +1 -0
- package/internals/hooks/useField/useFieldState.js +9 -7
- package/internals/models/props/basePickerProps.d.ts +0 -3
- package/internals/models/props/toolbar.d.ts +0 -3
- package/internals/utils/valueManagers.js +2 -2
- package/legacy/AdapterLuxon/AdapterLuxon.js +4 -12
- package/legacy/DatePicker/DatePicker.js +0 -3
- package/legacy/DatePicker/DatePickerToolbar.js +0 -3
- package/legacy/DateTimePicker/DateTimePicker.js +0 -3
- package/legacy/DateTimePicker/DateTimePickerToolbar.js +0 -3
- package/legacy/DesktopDatePicker/DesktopDatePicker.js +0 -3
- package/legacy/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
- package/legacy/DesktopTimePicker/DesktopTimePicker.js +0 -3
- package/legacy/MobileDatePicker/MobileDatePicker.js +0 -3
- package/legacy/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
- package/legacy/MobileTimePicker/MobileTimePicker.js +0 -3
- package/legacy/MonthCalendar/MonthCalendar.js +0 -3
- package/legacy/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
- package/legacy/PickersSectionList/PickersSectionList.js +6 -1
- package/legacy/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +99 -26
- package/legacy/PickersTextField/PickersFilledInput/index.js +2 -0
- package/legacy/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
- package/legacy/PickersTextField/PickersInput/PickersInput.js +190 -0
- package/legacy/PickersTextField/PickersInput/index.js +2 -0
- package/legacy/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
- package/legacy/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
- package/legacy/PickersTextField/PickersInputBase/index.js +2 -0
- package/legacy/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
- package/legacy/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +7 -1
- package/legacy/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +183 -0
- package/legacy/PickersTextField/PickersOutlinedInput/index.js +2 -0
- package/legacy/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
- package/legacy/{internals/components/PickersTextField → PickersTextField}/PickersTextField.js +128 -8
- package/legacy/PickersTextField/index.js +6 -0
- package/legacy/StaticDatePicker/StaticDatePicker.js +0 -3
- package/legacy/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
- package/legacy/StaticTimePicker/StaticTimePicker.js +0 -3
- package/legacy/TimePicker/TimePicker.js +0 -3
- package/legacy/TimePicker/TimePickerToolbar.js +0 -3
- package/legacy/YearCalendar/YearCalendar.js +0 -3
- package/legacy/index.js +3 -2
- package/legacy/internals/hooks/useField/useField.js +6 -4
- package/legacy/internals/hooks/useField/useField.utils.js +71 -20
- package/legacy/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
- package/legacy/internals/hooks/useField/useFieldState.js +15 -11
- package/legacy/internals/utils/valueManagers.js +2 -2
- package/modern/AdapterLuxon/AdapterLuxon.js +3 -11
- package/modern/DatePicker/DatePicker.js +0 -3
- package/modern/DatePicker/DatePickerToolbar.js +0 -3
- package/modern/DateTimePicker/DateTimePicker.js +0 -3
- package/modern/DateTimePicker/DateTimePickerToolbar.js +0 -3
- package/modern/DesktopDatePicker/DesktopDatePicker.js +0 -3
- package/modern/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
- package/modern/DesktopTimePicker/DesktopTimePicker.js +0 -3
- package/modern/MobileDatePicker/MobileDatePicker.js +0 -3
- package/modern/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
- package/modern/MobileTimePicker/MobileTimePicker.js +0 -3
- package/modern/MonthCalendar/MonthCalendar.js +0 -3
- package/modern/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
- package/modern/PickersSectionList/PickersSectionList.js +6 -1
- package/modern/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +98 -25
- package/modern/PickersTextField/PickersFilledInput/index.js +2 -0
- package/modern/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +8 -0
- package/modern/PickersTextField/PickersInput/PickersInput.js +196 -0
- package/modern/PickersTextField/PickersInput/index.js +2 -0
- package/modern/PickersTextField/PickersInput/pickersInputClasses.js +8 -0
- package/modern/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +106 -27
- package/modern/PickersTextField/PickersInputBase/index.js +2 -0
- package/modern/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +6 -0
- package/{internals/components/PickersInput → modern/PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
- package/modern/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +190 -0
- package/modern/PickersTextField/PickersOutlinedInput/index.js +2 -0
- package/modern/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +8 -0
- package/modern/PickersTextField/PickersTextField.js +258 -0
- package/modern/PickersTextField/index.js +6 -0
- package/modern/StaticDatePicker/StaticDatePicker.js +0 -3
- package/modern/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
- package/modern/StaticTimePicker/StaticTimePicker.js +0 -3
- package/modern/TimePicker/TimePicker.js +0 -3
- package/modern/TimePicker/TimePickerToolbar.js +0 -3
- package/modern/YearCalendar/YearCalendar.js +0 -3
- package/modern/index.js +3 -2
- package/modern/internals/hooks/useField/useField.js +5 -3
- package/modern/internals/hooks/useField/useField.utils.js +68 -21
- package/modern/internals/hooks/useField/useFieldCharacterEditing.js +12 -8
- package/modern/internals/hooks/useField/useFieldState.js +9 -7
- package/modern/internals/utils/valueManagers.js +2 -2
- package/node/AdapterLuxon/AdapterLuxon.js +3 -11
- package/node/DatePicker/DatePicker.js +0 -3
- package/node/DatePicker/DatePickerToolbar.js +0 -3
- package/node/DateTimePicker/DateTimePicker.js +0 -3
- package/node/DateTimePicker/DateTimePickerToolbar.js +0 -3
- package/node/DesktopDatePicker/DesktopDatePicker.js +0 -3
- package/node/DesktopDateTimePicker/DesktopDateTimePicker.js +0 -3
- package/node/DesktopTimePicker/DesktopTimePicker.js +0 -3
- package/node/MobileDatePicker/MobileDatePicker.js +0 -3
- package/node/MobileDateTimePicker/MobileDateTimePicker.js +0 -3
- package/node/MobileTimePicker/MobileTimePicker.js +0 -3
- package/node/MonthCalendar/MonthCalendar.js +0 -3
- package/node/PickersCalendarHeader/PickersCalendarHeader.js +0 -3
- package/node/PickersSectionList/PickersSectionList.js +6 -1
- package/node/{internals/components/PickersInput → PickersTextField/PickersFilledInput}/PickersFilledInput.js +102 -30
- package/node/PickersTextField/PickersFilledInput/index.js +25 -0
- package/node/PickersTextField/PickersFilledInput/pickersFilledInputClasses.js +16 -0
- package/node/PickersTextField/PickersInput/PickersInput.js +204 -0
- package/node/{internals/components → PickersTextField}/PickersInput/index.js +0 -7
- package/node/PickersTextField/PickersInput/pickersInputClasses.js +16 -0
- package/node/{internals/components/PickersInput/PickersInput.js → PickersTextField/PickersInputBase/PickersInputBase.js} +105 -27
- package/node/PickersTextField/PickersInputBase/index.js +25 -0
- package/node/PickersTextField/PickersInputBase/pickersInputBaseClasses.js +14 -0
- package/node/{internals/components/PickersInput → PickersTextField/PickersOutlinedInput}/Outline.js +5 -1
- package/node/PickersTextField/PickersOutlinedInput/PickersOutlinedInput.js +197 -0
- package/node/PickersTextField/PickersOutlinedInput/index.js +25 -0
- package/node/PickersTextField/PickersOutlinedInput/pickersOutlinedInputClasses.js +16 -0
- package/node/{internals/components/PickersTextField → PickersTextField}/PickersTextField.js +128 -9
- package/node/PickersTextField/index.js +78 -0
- package/node/StaticDatePicker/StaticDatePicker.js +0 -3
- package/node/StaticDateTimePicker/StaticDateTimePicker.js +0 -3
- package/node/StaticTimePicker/StaticTimePicker.js +0 -3
- package/node/TimePicker/TimePicker.js +0 -3
- package/node/TimePicker/TimePickerToolbar.js +0 -3
- package/node/YearCalendar/YearCalendar.js +0 -3
- package/node/index.js +17 -5
- package/node/internals/hooks/useField/useField.js +5 -3
- package/node/internals/hooks/useField/useField.utils.js +73 -22
- package/node/internals/hooks/useField/useFieldCharacterEditing.js +11 -7
- package/node/internals/hooks/useField/useFieldState.js +8 -6
- package/node/internals/utils/valueManagers.js +2 -2
- package/package.json +7 -7
- package/themeAugmentation/components.d.ts +26 -0
- package/themeAugmentation/overrides.d.ts +16 -0
- package/themeAugmentation/props.d.ts +16 -0
- package/internals/components/PickersInput/PickersFilledInput.d.ts +0 -3
- package/internals/components/PickersInput/PickersInput.d.ts +0 -13
- package/internals/components/PickersInput/PickersOutlinedInput.d.ts +0 -3
- package/internals/components/PickersInput/PickersOutlinedInput.js +0 -117
- package/internals/components/PickersInput/PickersStandardInput.d.ts +0 -3
- package/internals/components/PickersInput/PickersStandardInput.js +0 -123
- package/internals/components/PickersInput/index.js +0 -3
- package/internals/components/PickersInput/pickersInputClasses.d.ts +0 -84
- package/internals/components/PickersInput/pickersInputClasses.js +0 -18
- package/internals/components/PickersTextField/PickersTextField.d.ts +0 -2
- package/internals/components/PickersTextField/PickersTextField.js +0 -138
- package/internals/components/PickersTextField/index.d.ts +0 -1
- package/internals/components/PickersTextField/index.js +0 -1
- package/legacy/internals/components/PickersInput/PickersOutlinedInput.js +0 -110
- package/legacy/internals/components/PickersInput/PickersStandardInput.js +0 -117
- package/legacy/internals/components/PickersInput/index.js +0 -3
- package/legacy/internals/components/PickersInput/pickersInputClasses.js +0 -18
- package/legacy/internals/components/PickersTextField/index.js +0 -1
- package/modern/internals/components/PickersInput/PickersOutlinedInput.js +0 -117
- package/modern/internals/components/PickersInput/PickersStandardInput.js +0 -123
- package/modern/internals/components/PickersInput/index.js +0 -3
- package/modern/internals/components/PickersInput/pickersInputClasses.js +0 -18
- package/modern/internals/components/PickersTextField/PickersTextField.js +0 -138
- package/modern/internals/components/PickersTextField/index.js +0 -1
- package/node/internals/components/PickersInput/PickersOutlinedInput.js +0 -125
- package/node/internals/components/PickersInput/PickersStandardInput.js +0 -132
- package/node/internals/components/PickersInput/pickersInputClasses.js +0 -29
- package/node/internals/components/PickersTextField/index.js +0 -12
- /package/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
- /package/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
- /package/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.d.ts +0 -0
- /package/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
- /package/legacy/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
- /package/legacy/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
- /package/legacy/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
- /package/modern/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
- /package/modern/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
- /package/modern/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
- /package/node/{internals/components/PickersInput/PickersInput.types.js → PickersTextField/PickersInputBase/PickersInputBase.types.js} +0 -0
- /package/node/{internals/components/PickersTextField → PickersTextField}/PickersTextField.types.js +0 -0
- /package/node/{internals/components/PickersTextField → PickersTextField}/pickersTextFieldClasses.js +0 -0
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
4
|
+
var _excluded = ["label", "autoFocus", "ownerState", "notched"];
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import PropTypes from 'prop-types';
|
|
7
|
+
import { useFormControl } from '@mui/material/FormControl';
|
|
8
|
+
import { styled, useThemeProps } from '@mui/material/styles';
|
|
9
|
+
import composeClasses from '@mui/utils/composeClasses';
|
|
10
|
+
import { pickersOutlinedInputClasses, getPickersOutlinedInputUtilityClass } from './pickersOutlinedInputClasses';
|
|
11
|
+
import Outline from './Outline';
|
|
12
|
+
import { PickersInputBase } from '../PickersInputBase';
|
|
13
|
+
import { PickersInputBaseRoot, PickersInputBaseSectionsContainer } from '../PickersInputBase/PickersInputBase';
|
|
14
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
15
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
16
|
+
var PickersOutlinedInputRoot = styled(PickersInputBaseRoot, {
|
|
17
|
+
name: 'MuiPickersOutlinedInput',
|
|
18
|
+
slot: 'Root',
|
|
19
|
+
overridesResolver: function overridesResolver(props, styles) {
|
|
20
|
+
return styles.root;
|
|
21
|
+
}
|
|
22
|
+
})(function (_ref) {
|
|
23
|
+
var theme = _ref.theme,
|
|
24
|
+
ownerState = _ref.ownerState;
|
|
25
|
+
var borderColor = theme.palette.mode === 'light' ? 'rgba(0, 0, 0, 0.23)' : 'rgba(255, 255, 255, 0.23)';
|
|
26
|
+
return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
27
|
+
padding: '0 14px',
|
|
28
|
+
borderRadius: (theme.vars || theme).shape.borderRadius
|
|
29
|
+
}, "&:hover .".concat(pickersOutlinedInputClasses.notchedOutline), {
|
|
30
|
+
borderColor: (theme.vars || theme).palette.text.primary
|
|
31
|
+
}), '@media (hover: none)', _defineProperty({}, "&:hover .".concat(pickersOutlinedInputClasses.notchedOutline), {
|
|
32
|
+
borderColor: theme.vars ? "rgba(".concat(theme.vars.palette.common.onBackgroundChannel, " / 0.23)") : borderColor
|
|
33
|
+
})), "&.".concat(pickersOutlinedInputClasses.focused, " .").concat(pickersOutlinedInputClasses.notchedOutline), {
|
|
34
|
+
borderStyle: 'solid',
|
|
35
|
+
// @ts-ignore
|
|
36
|
+
borderColor: (theme.vars || theme).palette[ownerState.color].main,
|
|
37
|
+
borderWidth: 2
|
|
38
|
+
}), "&.".concat(pickersOutlinedInputClasses.disabled), _defineProperty(_defineProperty({}, "& .".concat(pickersOutlinedInputClasses.notchedOutline), {
|
|
39
|
+
borderColor: (theme.vars || theme).palette.action.disabled
|
|
40
|
+
}), '*', {
|
|
41
|
+
color: (theme.vars || theme).palette.action.disabled
|
|
42
|
+
})), "&.".concat(pickersOutlinedInputClasses.error, " .").concat(pickersOutlinedInputClasses.notchedOutline), {
|
|
43
|
+
borderColor: (theme.vars || theme).palette.error.main
|
|
44
|
+
});
|
|
45
|
+
});
|
|
46
|
+
var PickersOutlinedInputSectionsContainer = styled(PickersInputBaseSectionsContainer, {
|
|
47
|
+
name: 'MuiPickersOutlinedInput',
|
|
48
|
+
slot: 'SectionsContainer',
|
|
49
|
+
overridesResolver: function overridesResolver(props, styles) {
|
|
50
|
+
return styles.sectionsContainer;
|
|
51
|
+
}
|
|
52
|
+
})(function (_ref3) {
|
|
53
|
+
var ownerState = _ref3.ownerState;
|
|
54
|
+
return _extends({
|
|
55
|
+
padding: '16.5px 0'
|
|
56
|
+
}, ownerState.size === 'small' && {
|
|
57
|
+
padding: '8.5px 0'
|
|
58
|
+
});
|
|
59
|
+
});
|
|
60
|
+
var useUtilityClasses = function useUtilityClasses(ownerState) {
|
|
61
|
+
var classes = ownerState.classes;
|
|
62
|
+
var slots = {
|
|
63
|
+
root: ['root'],
|
|
64
|
+
notchedOutline: ['notchedOutline'],
|
|
65
|
+
input: ['input']
|
|
66
|
+
};
|
|
67
|
+
var composedClasses = composeClasses(slots, getPickersOutlinedInputUtilityClass, classes);
|
|
68
|
+
return _extends({}, classes, composedClasses);
|
|
69
|
+
};
|
|
70
|
+
/**
|
|
71
|
+
* @ignore - internal component.
|
|
72
|
+
*/
|
|
73
|
+
var PickersOutlinedInput = /*#__PURE__*/React.forwardRef(function PickersOutlinedInput(inProps, ref) {
|
|
74
|
+
var props = useThemeProps({
|
|
75
|
+
props: inProps,
|
|
76
|
+
name: 'MuiPickersOutlinedInput'
|
|
77
|
+
});
|
|
78
|
+
var label = props.label,
|
|
79
|
+
autoFocus = props.autoFocus,
|
|
80
|
+
ownerStateProp = props.ownerState,
|
|
81
|
+
notched = props.notched,
|
|
82
|
+
other = _objectWithoutProperties(props, _excluded);
|
|
83
|
+
var muiFormControl = useFormControl();
|
|
84
|
+
var ownerState = _extends({}, props, ownerStateProp, muiFormControl, {
|
|
85
|
+
color: (muiFormControl == null ? void 0 : muiFormControl.color) || 'primary'
|
|
86
|
+
});
|
|
87
|
+
var classes = useUtilityClasses(ownerState);
|
|
88
|
+
return /*#__PURE__*/_jsx(PickersInputBase, _extends({
|
|
89
|
+
slots: {
|
|
90
|
+
root: PickersOutlinedInputRoot,
|
|
91
|
+
input: PickersOutlinedInputSectionsContainer
|
|
92
|
+
},
|
|
93
|
+
renderSuffix: function renderSuffix(state) {
|
|
94
|
+
return /*#__PURE__*/_jsx(Outline, {
|
|
95
|
+
shrink: Boolean(notched || state.adornedStart || state.focused || state.filled),
|
|
96
|
+
notched: Boolean(notched || state.adornedStart || state.focused || state.filled),
|
|
97
|
+
className: classes.notchedOutline,
|
|
98
|
+
label: label != null && label !== '' && muiFormControl != null && muiFormControl.required ? /*#__PURE__*/_jsxs(React.Fragment, {
|
|
99
|
+
children: [label, "\u2009", '*']
|
|
100
|
+
}) : label,
|
|
101
|
+
ownerState: ownerState
|
|
102
|
+
});
|
|
103
|
+
}
|
|
104
|
+
}, other, {
|
|
105
|
+
label: label,
|
|
106
|
+
classes: classes,
|
|
107
|
+
ref: ref
|
|
108
|
+
}));
|
|
109
|
+
});
|
|
110
|
+
process.env.NODE_ENV !== "production" ? PickersOutlinedInput.propTypes = {
|
|
111
|
+
// ----------------------------- Warning --------------------------------
|
|
112
|
+
// | These PropTypes are generated from the TypeScript type definitions |
|
|
113
|
+
// | To update them edit the TypeScript types and run "yarn proptypes" |
|
|
114
|
+
// ----------------------------------------------------------------------
|
|
115
|
+
/**
|
|
116
|
+
* Is `true` if the current values equals the empty value.
|
|
117
|
+
* For a single item value, it means that `value === null`
|
|
118
|
+
* For a range value, it means that `value === [null, null]`
|
|
119
|
+
*/
|
|
120
|
+
areAllSectionsEmpty: PropTypes.bool.isRequired,
|
|
121
|
+
className: PropTypes.string,
|
|
122
|
+
/**
|
|
123
|
+
* The component used for the root node.
|
|
124
|
+
* Either a string to use a HTML element or a component.
|
|
125
|
+
*/
|
|
126
|
+
component: PropTypes.elementType,
|
|
127
|
+
/**
|
|
128
|
+
* If true, the whole element is editable.
|
|
129
|
+
* Useful when all the sections are selected.
|
|
130
|
+
*/
|
|
131
|
+
contentEditable: PropTypes.bool.isRequired,
|
|
132
|
+
/**
|
|
133
|
+
* The elements to render.
|
|
134
|
+
* Each element contains the prop to edit a section of the value.
|
|
135
|
+
*/
|
|
136
|
+
elements: PropTypes.arrayOf(PropTypes.shape({
|
|
137
|
+
after: PropTypes.object.isRequired,
|
|
138
|
+
before: PropTypes.object.isRequired,
|
|
139
|
+
container: PropTypes.object.isRequired,
|
|
140
|
+
content: PropTypes.object.isRequired
|
|
141
|
+
})).isRequired,
|
|
142
|
+
endAdornment: PropTypes.node,
|
|
143
|
+
fullWidth: PropTypes.bool,
|
|
144
|
+
id: PropTypes.string,
|
|
145
|
+
inputProps: PropTypes.object,
|
|
146
|
+
inputRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
|
|
147
|
+
current: PropTypes.object
|
|
148
|
+
})]),
|
|
149
|
+
label: PropTypes.node,
|
|
150
|
+
margin: PropTypes.oneOf(['dense', 'none', 'normal']),
|
|
151
|
+
notched: PropTypes.bool,
|
|
152
|
+
onChange: PropTypes.func.isRequired,
|
|
153
|
+
onClick: PropTypes.func.isRequired,
|
|
154
|
+
onInput: PropTypes.func.isRequired,
|
|
155
|
+
onKeyDown: PropTypes.func.isRequired,
|
|
156
|
+
onPaste: PropTypes.func.isRequired,
|
|
157
|
+
ownerState: PropTypes.any,
|
|
158
|
+
readOnly: PropTypes.bool,
|
|
159
|
+
renderSuffix: PropTypes.func,
|
|
160
|
+
sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
|
|
161
|
+
current: PropTypes.shape({
|
|
162
|
+
getRoot: PropTypes.func.isRequired,
|
|
163
|
+
getSectionContainer: PropTypes.func.isRequired,
|
|
164
|
+
getSectionContent: PropTypes.func.isRequired,
|
|
165
|
+
getSectionIndexFromDOMElement: PropTypes.func.isRequired
|
|
166
|
+
})
|
|
167
|
+
})]),
|
|
168
|
+
/**
|
|
169
|
+
* The components used for each slot inside.
|
|
170
|
+
*
|
|
171
|
+
* @default {}
|
|
172
|
+
*/
|
|
173
|
+
slots: PropTypes.object,
|
|
174
|
+
startAdornment: PropTypes.node,
|
|
175
|
+
style: PropTypes.object,
|
|
176
|
+
/**
|
|
177
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
178
|
+
*/
|
|
179
|
+
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
180
|
+
value: PropTypes.string.isRequired
|
|
181
|
+
} : void 0;
|
|
182
|
+
export { PickersOutlinedInput };
|
|
183
|
+
PickersOutlinedInput.muiName = 'Input';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
|
+
import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
|
|
3
|
+
import generateUtilityClass from '@mui/utils/generateUtilityClass';
|
|
4
|
+
import { pickersInputBaseClasses } from '../PickersInputBase';
|
|
5
|
+
export function getPickersOutlinedInputUtilityClass(slot) {
|
|
6
|
+
return generateUtilityClass('MuiPickersOutlinedInput', slot);
|
|
7
|
+
}
|
|
8
|
+
export var pickersOutlinedInputClasses = _extends({}, pickersInputBaseClasses, generateUtilityClasses('MuiPickersOutlinedInput', ['root', 'notchedOutline', 'input']));
|
package/legacy/{internals/components/PickersTextField → PickersTextField}/PickersTextField.js
RENAMED
|
@@ -2,21 +2,23 @@ import _extends from "@babel/runtime/helpers/esm/extends";
|
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
3
3
|
var _excluded = ["onFocus", "onBlur", "className", "color", "disabled", "error", "variant", "required", "InputProps", "inputProps", "inputRef", "sectionListRef", "elements", "areAllSectionsEmpty", "onClick", "onKeyDown", "onKeyUp", "onPaste", "onInput", "endAdornment", "startAdornment", "tabIndex", "contentEditable", "focused", "value", "onChange", "fullWidth", "id", "helperText", "FormHelperTextProps", "label", "InputLabelProps"];
|
|
4
4
|
import * as React from 'react';
|
|
5
|
+
import PropTypes from 'prop-types';
|
|
5
6
|
import clsx from 'clsx';
|
|
6
|
-
import { styled } from '@mui/material/styles';
|
|
7
|
+
import { styled, useThemeProps } from '@mui/material/styles';
|
|
7
8
|
import useForkRef from '@mui/utils/useForkRef';
|
|
8
|
-
import
|
|
9
|
+
import composeClasses from '@mui/utils/composeClasses';
|
|
10
|
+
import useId from '@mui/utils/useId';
|
|
9
11
|
import InputLabel from '@mui/material/InputLabel';
|
|
10
12
|
import FormHelperText from '@mui/material/FormHelperText';
|
|
11
13
|
import FormControl from '@mui/material/FormControl';
|
|
12
14
|
import { getPickersTextFieldUtilityClass } from './pickersTextFieldClasses';
|
|
13
|
-
import { PickersOutlinedInput } from '
|
|
14
|
-
import { PickersFilledInput } from '
|
|
15
|
-
import {
|
|
15
|
+
import { PickersOutlinedInput } from './PickersOutlinedInput';
|
|
16
|
+
import { PickersFilledInput } from './PickersFilledInput';
|
|
17
|
+
import { PickersInput } from './PickersInput';
|
|
16
18
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
17
19
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
18
20
|
var VARIANT_COMPONENT = {
|
|
19
|
-
standard:
|
|
21
|
+
standard: PickersInput,
|
|
20
22
|
filled: PickersFilledInput,
|
|
21
23
|
outlined: PickersOutlinedInput
|
|
22
24
|
};
|
|
@@ -37,7 +39,11 @@ var useUtilityClasses = function useUtilityClasses(ownerState) {
|
|
|
37
39
|
};
|
|
38
40
|
return composeClasses(slots, getPickersTextFieldUtilityClass, classes);
|
|
39
41
|
};
|
|
40
|
-
|
|
42
|
+
var PickersTextField = /*#__PURE__*/React.forwardRef(function PickersTextField(inProps, ref) {
|
|
43
|
+
var props = useThemeProps({
|
|
44
|
+
props: inProps,
|
|
45
|
+
name: 'MuiPickersTextField'
|
|
46
|
+
});
|
|
41
47
|
var onFocus = props.onFocus,
|
|
42
48
|
onBlur = props.onBlur,
|
|
43
49
|
className = props.className,
|
|
@@ -135,4 +141,118 @@ export var PickersTextField = /*#__PURE__*/React.forwardRef(function PickersText
|
|
|
135
141
|
children: helperText
|
|
136
142
|
}))]
|
|
137
143
|
}));
|
|
138
|
-
});
|
|
144
|
+
});
|
|
145
|
+
process.env.NODE_ENV !== "production" ? PickersTextField.propTypes = {
|
|
146
|
+
// ----------------------------- Warning --------------------------------
|
|
147
|
+
// | These PropTypes are generated from the TypeScript type definitions |
|
|
148
|
+
// | To update them edit the TypeScript types and run "yarn proptypes" |
|
|
149
|
+
// ----------------------------------------------------------------------
|
|
150
|
+
/**
|
|
151
|
+
* Is `true` if the current values equals the empty value.
|
|
152
|
+
* For a single item value, it means that `value === null`
|
|
153
|
+
* For a range value, it means that `value === [null, null]`
|
|
154
|
+
*/
|
|
155
|
+
areAllSectionsEmpty: PropTypes.bool.isRequired,
|
|
156
|
+
className: PropTypes.string,
|
|
157
|
+
/**
|
|
158
|
+
* The color of the component.
|
|
159
|
+
* It supports both default and custom theme colors, which can be added as shown in the
|
|
160
|
+
* [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).
|
|
161
|
+
* @default 'primary'
|
|
162
|
+
*/
|
|
163
|
+
color: PropTypes.oneOf(['error', 'info', 'primary', 'secondary', 'success', 'warning']),
|
|
164
|
+
component: PropTypes.elementType,
|
|
165
|
+
/**
|
|
166
|
+
* If true, the whole element is editable.
|
|
167
|
+
* Useful when all the sections are selected.
|
|
168
|
+
*/
|
|
169
|
+
contentEditable: PropTypes.bool.isRequired,
|
|
170
|
+
disabled: PropTypes.bool.isRequired,
|
|
171
|
+
/**
|
|
172
|
+
* The elements to render.
|
|
173
|
+
* Each element contains the prop to edit a section of the value.
|
|
174
|
+
*/
|
|
175
|
+
elements: PropTypes.arrayOf(PropTypes.shape({
|
|
176
|
+
after: PropTypes.object.isRequired,
|
|
177
|
+
before: PropTypes.object.isRequired,
|
|
178
|
+
container: PropTypes.object.isRequired,
|
|
179
|
+
content: PropTypes.object.isRequired
|
|
180
|
+
})).isRequired,
|
|
181
|
+
endAdornment: PropTypes.node,
|
|
182
|
+
error: PropTypes.bool.isRequired,
|
|
183
|
+
/**
|
|
184
|
+
* If `true`, the component is displayed in focused state.
|
|
185
|
+
*/
|
|
186
|
+
focused: PropTypes.bool,
|
|
187
|
+
FormHelperTextProps: PropTypes.object,
|
|
188
|
+
fullWidth: PropTypes.bool,
|
|
189
|
+
/**
|
|
190
|
+
* The helper text content.
|
|
191
|
+
*/
|
|
192
|
+
helperText: PropTypes.node,
|
|
193
|
+
/**
|
|
194
|
+
* If `true`, the label is hidden.
|
|
195
|
+
* This is used to increase density for a `FilledInput`.
|
|
196
|
+
* Be sure to add `aria-label` to the `input` element.
|
|
197
|
+
* @default false
|
|
198
|
+
*/
|
|
199
|
+
hiddenLabel: PropTypes.bool,
|
|
200
|
+
id: PropTypes.string,
|
|
201
|
+
InputLabelProps: PropTypes.object,
|
|
202
|
+
inputProps: PropTypes.object,
|
|
203
|
+
/**
|
|
204
|
+
* Props applied to the Input element.
|
|
205
|
+
* It will be a [`FilledInput`](/material-ui/api/filled-input/),
|
|
206
|
+
* [`OutlinedInput`](/material-ui/api/outlined-input/) or [`Input`](/material-ui/api/input/)
|
|
207
|
+
* component depending on the `variant` prop value.
|
|
208
|
+
*/
|
|
209
|
+
InputProps: PropTypes.object,
|
|
210
|
+
inputRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
|
|
211
|
+
current: PropTypes.object
|
|
212
|
+
})]),
|
|
213
|
+
label: PropTypes.node,
|
|
214
|
+
/**
|
|
215
|
+
* If `dense` or `normal`, will adjust vertical spacing of this and contained components.
|
|
216
|
+
* @default 'none'
|
|
217
|
+
*/
|
|
218
|
+
margin: PropTypes.oneOf(['dense', 'none', 'normal']),
|
|
219
|
+
onBlur: PropTypes.func.isRequired,
|
|
220
|
+
onChange: PropTypes.func.isRequired,
|
|
221
|
+
onClick: PropTypes.func.isRequired,
|
|
222
|
+
onFocus: PropTypes.func.isRequired,
|
|
223
|
+
onInput: PropTypes.func.isRequired,
|
|
224
|
+
onKeyDown: PropTypes.func.isRequired,
|
|
225
|
+
onPaste: PropTypes.func.isRequired,
|
|
226
|
+
readOnly: PropTypes.bool,
|
|
227
|
+
/**
|
|
228
|
+
* If `true`, the label will indicate that the `input` is required.
|
|
229
|
+
* @default false
|
|
230
|
+
*/
|
|
231
|
+
required: PropTypes.bool,
|
|
232
|
+
sectionListRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
|
|
233
|
+
current: PropTypes.shape({
|
|
234
|
+
getRoot: PropTypes.func.isRequired,
|
|
235
|
+
getSectionContainer: PropTypes.func.isRequired,
|
|
236
|
+
getSectionContent: PropTypes.func.isRequired,
|
|
237
|
+
getSectionIndexFromDOMElement: PropTypes.func.isRequired
|
|
238
|
+
})
|
|
239
|
+
})]),
|
|
240
|
+
/**
|
|
241
|
+
* The size of the component.
|
|
242
|
+
* @default 'medium'
|
|
243
|
+
*/
|
|
244
|
+
size: PropTypes.oneOf(['medium', 'small']),
|
|
245
|
+
startAdornment: PropTypes.node,
|
|
246
|
+
style: PropTypes.object,
|
|
247
|
+
/**
|
|
248
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
249
|
+
*/
|
|
250
|
+
sx: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.bool])), PropTypes.func, PropTypes.object]),
|
|
251
|
+
value: PropTypes.string.isRequired,
|
|
252
|
+
/**
|
|
253
|
+
* The variant to use.
|
|
254
|
+
* @default 'outlined'
|
|
255
|
+
*/
|
|
256
|
+
variant: PropTypes.oneOf(['filled', 'outlined', 'standard'])
|
|
257
|
+
} : void 0;
|
|
258
|
+
export { PickersTextField };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { PickersTextField } from './PickersTextField';
|
|
2
|
+
export { pickersTextFieldClasses, getPickersTextFieldUtilityClass } from './pickersTextFieldClasses';
|
|
3
|
+
export * from './PickersInput';
|
|
4
|
+
export * from './PickersFilledInput';
|
|
5
|
+
export * from './PickersOutlinedInput';
|
|
6
|
+
export * from './PickersInputBase';
|
|
@@ -59,9 +59,6 @@ StaticDatePicker.propTypes = {
|
|
|
59
59
|
* - the `input` element if there is a field rendered.
|
|
60
60
|
*/
|
|
61
61
|
autoFocus: PropTypes.bool,
|
|
62
|
-
/**
|
|
63
|
-
* Class name applied to the root element.
|
|
64
|
-
*/
|
|
65
62
|
className: PropTypes.string,
|
|
66
63
|
/**
|
|
67
64
|
* Formats the day of week displayed in the calendar header.
|
|
@@ -79,9 +79,6 @@ StaticDateTimePicker.propTypes = {
|
|
|
79
79
|
* - the `input` element if there is a field rendered.
|
|
80
80
|
*/
|
|
81
81
|
autoFocus: PropTypes.bool,
|
|
82
|
-
/**
|
|
83
|
-
* Class name applied to the root element.
|
|
84
|
-
*/
|
|
85
82
|
className: PropTypes.string,
|
|
86
83
|
/**
|
|
87
84
|
* Formats the day of week displayed in the calendar header.
|
|
@@ -64,9 +64,6 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
|
|
|
64
64
|
* - the `input` element if there is a field rendered.
|
|
65
65
|
*/
|
|
66
66
|
autoFocus: PropTypes.bool,
|
|
67
|
-
/**
|
|
68
|
-
* Class name applied to the root element.
|
|
69
|
-
*/
|
|
70
67
|
className: PropTypes.string,
|
|
71
68
|
/**
|
|
72
69
|
* If `true`, the popover or modal will close after submitting the full date.
|
|
@@ -223,9 +223,6 @@ process.env.NODE_ENV !== "production" ? TimePickerToolbar.propTypes = {
|
|
|
223
223
|
ampm: PropTypes.bool,
|
|
224
224
|
ampmInClock: PropTypes.bool,
|
|
225
225
|
classes: PropTypes.object,
|
|
226
|
-
/**
|
|
227
|
-
* className applied to the root component.
|
|
228
|
-
*/
|
|
229
226
|
className: PropTypes.string,
|
|
230
227
|
disabled: PropTypes.bool,
|
|
231
228
|
/**
|
|
@@ -278,9 +278,6 @@ process.env.NODE_ENV !== "production" ? YearCalendar.propTypes = {
|
|
|
278
278
|
* Override or extend the styles applied to the component.
|
|
279
279
|
*/
|
|
280
280
|
classes: PropTypes.object,
|
|
281
|
-
/**
|
|
282
|
-
* className applied to the root element.
|
|
283
|
-
*/
|
|
284
281
|
className: PropTypes.string,
|
|
285
282
|
/**
|
|
286
283
|
* The default selected value.
|
package/legacy/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @mui/x-date-pickers v7.0.0-alpha.
|
|
2
|
+
* @mui/x-date-pickers v7.0.0-alpha.9
|
|
3
3
|
*
|
|
4
4
|
* @license MIT
|
|
5
5
|
* This source code is licensed under the MIT license found in the
|
|
@@ -11,7 +11,7 @@ export * from './DigitalClock';
|
|
|
11
11
|
export * from './MultiSectionDigitalClock';
|
|
12
12
|
export * from './LocalizationProvider';
|
|
13
13
|
export * from './PickersDay';
|
|
14
|
-
export * from './locales';
|
|
14
|
+
export * from './locales/utils/pickersLocaleTextApi';
|
|
15
15
|
|
|
16
16
|
// Fields
|
|
17
17
|
export * from './DateField';
|
|
@@ -51,6 +51,7 @@ export * from './PickersShortcuts';
|
|
|
51
51
|
export * from './PickersCalendarHeader';
|
|
52
52
|
|
|
53
53
|
// Field utilities
|
|
54
|
+
export * from './PickersTextField';
|
|
54
55
|
export * from './PickersSectionList';
|
|
55
56
|
export { DEFAULT_DESKTOP_MODE_MEDIA_QUERY } from './internals/utils/utils';
|
|
56
57
|
export * from './models';
|
|
@@ -25,6 +25,7 @@ export var useField = function useField(params) {
|
|
|
25
25
|
updateValueFromValueStr = _useFieldState.updateValueFromValueStr,
|
|
26
26
|
setTempAndroidValueStr = _useFieldState.setTempAndroidValueStr,
|
|
27
27
|
sectionsValueBoundaries = _useFieldState.sectionsValueBoundaries,
|
|
28
|
+
localizedDigits = _useFieldState.localizedDigits,
|
|
28
29
|
placeholder = _useFieldState.placeholder,
|
|
29
30
|
timezone = _useFieldState.timezone;
|
|
30
31
|
var internalProps = params.internalProps,
|
|
@@ -53,6 +54,7 @@ export var useField = function useField(params) {
|
|
|
53
54
|
sections: state.sections,
|
|
54
55
|
updateSectionValue: updateSectionValue,
|
|
55
56
|
sectionsValueBoundaries: sectionsValueBoundaries,
|
|
57
|
+
localizedDigits: localizedDigits,
|
|
56
58
|
setTempAndroidValueStr: setTempAndroidValueStr,
|
|
57
59
|
timezone: timezone
|
|
58
60
|
}),
|
|
@@ -200,7 +202,7 @@ export var useField = function useField(params) {
|
|
|
200
202
|
if (selectedSectionIndexes.startIndex === 0 && selectedSectionIndexes.endIndex === state.sections.length - 1 && cleanValueStr.length === 1) {
|
|
201
203
|
keyPressed = cleanValueStr;
|
|
202
204
|
} else {
|
|
203
|
-
var prevValueStr = cleanString(fieldValueManager.getValueStrFromSections(state.sections, isRTL));
|
|
205
|
+
var prevValueStr = cleanString(fieldValueManager.getValueStrFromSections(state.sections, localizedDigits, isRTL));
|
|
204
206
|
var startOfDiffIndex = -1;
|
|
205
207
|
var endOfDiffIndex = -1;
|
|
206
208
|
for (var i = 0; i < prevValueStr.length; i += 1) {
|
|
@@ -310,7 +312,7 @@ export var useField = function useField(params) {
|
|
|
310
312
|
}
|
|
311
313
|
var activeSection = state.sections[selectedSectionIndexes.startIndex];
|
|
312
314
|
var activeDateManager = fieldValueManager.getActiveDateManager(utils, state, activeSection);
|
|
313
|
-
var newSectionValue = adjustSectionValue(utils, timezone, activeSection, event.key, sectionsValueBoundaries, activeDateManager.date, {
|
|
315
|
+
var newSectionValue = adjustSectionValue(utils, timezone, activeSection, event.key, sectionsValueBoundaries, localizedDigits, activeDateManager.date, {
|
|
314
316
|
minutesStep: minutesStep
|
|
315
317
|
});
|
|
316
318
|
updateSectionValue({
|
|
@@ -397,8 +399,8 @@ export var useField = function useField(params) {
|
|
|
397
399
|
|
|
398
400
|
var valueStr = React.useMemo(function () {
|
|
399
401
|
var _state$tempValueStrAn;
|
|
400
|
-
return (_state$tempValueStrAn = state.tempValueStrAndroid) != null ? _state$tempValueStrAn : fieldValueManager.getValueStrFromSections(state.sections, isRTL);
|
|
401
|
-
}, [state.sections, fieldValueManager, state.tempValueStrAndroid, isRTL]);
|
|
402
|
+
return (_state$tempValueStrAn = state.tempValueStrAndroid) != null ? _state$tempValueStrAn : fieldValueManager.getValueStrFromSections(state.sections, localizedDigits, isRTL);
|
|
403
|
+
}, [state.sections, fieldValueManager, state.tempValueStrAndroid, localizedDigits, isRTL]);
|
|
402
404
|
var inputMode = React.useMemo(function () {
|
|
403
405
|
if (selectedSectionIndexes == null) {
|
|
404
406
|
return 'text';
|