@mui/x-date-pickers 6.18.3 → 6.18.5

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.
Files changed (61) hide show
  1. package/CHANGELOG.md +84 -1
  2. package/DatePicker/DatePicker.js +4 -0
  3. package/DateTimePicker/DateTimePicker.js +4 -0
  4. package/DesktopDatePicker/DesktopDatePicker.js +4 -0
  5. package/DesktopDateTimePicker/DesktopDateTimePicker.js +4 -0
  6. package/DesktopTimePicker/DesktopTimePicker.js +4 -0
  7. package/MobileDatePicker/MobileDatePicker.js +4 -0
  8. package/MobileDateTimePicker/MobileDateTimePicker.js +4 -0
  9. package/MobileTimePicker/MobileTimePicker.js +4 -0
  10. package/MultiSectionDigitalClock/MultiSectionDigitalClockSection.js +8 -2
  11. package/MultiSectionDigitalClock/multiSectionDigitalClockSectionClasses.js +2 -2
  12. package/TimePicker/TimePicker.js +4 -0
  13. package/index.js +1 -1
  14. package/internals/hooks/useDesktopPicker/useDesktopPicker.js +2 -0
  15. package/internals/hooks/useField/useField.types.d.ts +1 -1
  16. package/internals/hooks/useMobilePicker/useMobilePicker.js +3 -1
  17. package/internals/models/props/basePickerProps.d.ts +4 -0
  18. package/legacy/DatePicker/DatePicker.js +4 -0
  19. package/legacy/DateTimePicker/DateTimePicker.js +4 -0
  20. package/legacy/DesktopDatePicker/DesktopDatePicker.js +4 -0
  21. package/legacy/DesktopDateTimePicker/DesktopDateTimePicker.js +4 -0
  22. package/legacy/DesktopTimePicker/DesktopTimePicker.js +4 -0
  23. package/legacy/MobileDatePicker/MobileDatePicker.js +4 -0
  24. package/legacy/MobileDateTimePicker/MobileDateTimePicker.js +4 -0
  25. package/legacy/MobileTimePicker/MobileTimePicker.js +4 -0
  26. package/legacy/MultiSectionDigitalClock/MultiSectionDigitalClockSection.js +8 -2
  27. package/legacy/MultiSectionDigitalClock/multiSectionDigitalClockSectionClasses.js +2 -2
  28. package/legacy/TimePicker/TimePicker.js +4 -0
  29. package/legacy/index.js +1 -1
  30. package/legacy/internals/hooks/useDesktopPicker/useDesktopPicker.js +2 -0
  31. package/legacy/internals/hooks/useMobilePicker/useMobilePicker.js +3 -1
  32. package/models/fields.d.ts +1 -0
  33. package/modern/DatePicker/DatePicker.js +4 -0
  34. package/modern/DateTimePicker/DateTimePicker.js +4 -0
  35. package/modern/DesktopDatePicker/DesktopDatePicker.js +4 -0
  36. package/modern/DesktopDateTimePicker/DesktopDateTimePicker.js +4 -0
  37. package/modern/DesktopTimePicker/DesktopTimePicker.js +4 -0
  38. package/modern/MobileDatePicker/MobileDatePicker.js +4 -0
  39. package/modern/MobileDateTimePicker/MobileDateTimePicker.js +4 -0
  40. package/modern/MobileTimePicker/MobileTimePicker.js +4 -0
  41. package/modern/MultiSectionDigitalClock/MultiSectionDigitalClockSection.js +8 -2
  42. package/modern/MultiSectionDigitalClock/multiSectionDigitalClockSectionClasses.js +2 -2
  43. package/modern/TimePicker/TimePicker.js +4 -0
  44. package/modern/index.js +1 -1
  45. package/modern/internals/hooks/useDesktopPicker/useDesktopPicker.js +2 -0
  46. package/modern/internals/hooks/useMobilePicker/useMobilePicker.js +3 -1
  47. package/node/DatePicker/DatePicker.js +4 -0
  48. package/node/DateTimePicker/DateTimePicker.js +4 -0
  49. package/node/DesktopDatePicker/DesktopDatePicker.js +4 -0
  50. package/node/DesktopDateTimePicker/DesktopDateTimePicker.js +4 -0
  51. package/node/DesktopTimePicker/DesktopTimePicker.js +4 -0
  52. package/node/MobileDatePicker/MobileDatePicker.js +4 -0
  53. package/node/MobileDateTimePicker/MobileDateTimePicker.js +4 -0
  54. package/node/MobileTimePicker/MobileTimePicker.js +4 -0
  55. package/node/MultiSectionDigitalClock/MultiSectionDigitalClockSection.js +8 -2
  56. package/node/MultiSectionDigitalClock/multiSectionDigitalClockSectionClasses.js +2 -2
  57. package/node/TimePicker/TimePicker.js +4 -0
  58. package/node/index.js +1 -1
  59. package/node/internals/hooks/useDesktopPicker/useDesktopPicker.js +2 -0
  60. package/node/internals/hooks/useMobilePicker/useMobilePicker.js +3 -1
  61. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -3,6 +3,88 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## 6.18.5
7
+
8
+ _Dec 14, 2023_
9
+
10
+ We'd like to offer a big thanks to the 7 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🌍 Improve Swedish (sv-SE) and Urdu (ur-PK) locales on the Data Grid
13
+ - 🐞 Bugfixes
14
+
15
+ ### Data Grid
16
+
17
+ #### `@mui/x-data-grid@6.18.5`
18
+
19
+ - [l10n] Improve Swedish (sv-SE) locale (#11379) @fredrikcarlbom
20
+ - [l10n] Improve Urdu (ur-PK) locale for data grid (#11409) @MBilalShafi
21
+
22
+ #### `@mui/x-data-grid-pro@6.18.5` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
23
+
24
+ Same changes as in `@mui/x-data-grid@6.18.5`.
25
+
26
+ #### `@mui/x-data-grid-premium@6.18.5` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link 'Premium plan')
27
+
28
+ Same changes as in `@mui/x-data-grid-pro@6.18.5`.
29
+
30
+ ### Date Pickers
31
+
32
+ #### `@mui/x-date-pickers@6.18.5`
33
+
34
+ - [pickers] Fix field types to avoid error on latest `@types/react` version (#11398) @LukasTy
35
+ - [pickers] Support name prop (#11380) @gitstart
36
+
37
+ #### `@mui/x-date-pickers-pro@6.18.5` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
38
+
39
+ Same changes as in `@mui/x-date-pickers@6.18.5`, plus:
40
+
41
+ - [DateRangePicker] Fix `autoFocus` behavior (#11376) @kealjones-wk
42
+
43
+ ### Docs
44
+
45
+ - [docs] Respect GoT books (#11294) @janoma
46
+ - [test] Fix flaky screenshots (#11391) @cherniavskii
47
+
48
+ ## 6.18.4
49
+
50
+ _Dec 8, 2023_
51
+
52
+ We'd like to offer a big thanks to the 6 contributors who made this release possible. Here are some highlights ✨:
53
+
54
+ - 📚 Add [Pickers FAQ page](https://mui.com/x/react-date-pickers/faq/)
55
+ - 🌍 Improve Danish (da-DK) locale on Data Grid
56
+ - 🐞 Bugfixes
57
+
58
+ ### Data Grid
59
+
60
+ #### `@mui/x-data-grid@6.18.4`
61
+
62
+ - [DataGrid] Fix cell slot style override (#11215) @oliviertassinari
63
+ - [l10n] Improve Danish (da-DK) locale (#11346) @goibon
64
+
65
+ #### `@mui/x-data-grid-pro@6.18.4` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
66
+
67
+ Same changes as in `@mui/x-data-grid@6.18.4`.
68
+
69
+ #### `@mui/x-data-grid-premium@6.18.4` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link 'Premium plan')
70
+
71
+ Same changes as in `@mui/x-data-grid-pro@6.18.4`.
72
+
73
+ ### Date Pickers
74
+
75
+ #### `@mui/x-date-pickers@6.18.4`
76
+
77
+ - [pickers] Fix `MultiSectionDigitalClock` issues (#11308) @LukasTy
78
+
79
+ #### `@mui/x-date-pickers-pro@6.18.4` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link 'Pro plan')
80
+
81
+ Same changes as in `@mui/x-date-pickers@6.18.4`.
82
+
83
+ ### Docs
84
+
85
+ - [docs] Fix typo (#11323) @cadam11
86
+ - [docs] Add FAQ page (#11347) @noraleonte
87
+
6
88
  ## 6.18.3
7
89
 
8
90
  _Dec 4, 2023_
@@ -347,7 +429,7 @@ Same changes as in `@mui/x-date-pickers@6.16.3`, plus:
347
429
 
348
430
  - [charts] Add reference links to area + bar chart components (#10652) @michelengelen
349
431
  - [charts] Add reference links to line chart + sparkline components (#10650) @michelengelen
350
- - [charts] Add reference links to pie + scatter chart components (#10653) @michelengelen
432
+ - [charts] Add reference links to pie + scatter chart components (#10653) @michelengelen
351
433
  - [charts] Render only when `width` and `height` are resolved (#10714) @alexfauquette
352
434
  - [charts] Support animation on `BarChart` (#9926) @alexfauquette
353
435
  - [charts] Use new text component to avoid tick label overflow on x-axis (#10648) @alexfauquette
@@ -423,6 +505,7 @@ It adds line break support and avoids overlapping text in the legend.
423
505
  This comes with some breaking changes.
424
506
 
425
507
  - The DOM structure is modified. An intermediary `<tspan />` element has been added. This can impact how your style is applied.
508
+
426
509
  ```diff
427
510
  - <text>The label</text>
428
511
  + <text><tspan>The label</tspan></text>
@@ -178,6 +178,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
178
178
  * @default 3
179
179
  */
180
180
  monthsPerRow: PropTypes.oneOf([3, 4]),
181
+ /**
182
+ * Name attribute used by the `input` element in the Field.
183
+ */
184
+ name: PropTypes.string,
181
185
  /**
182
186
  * Callback fired when the value is accepted.
183
187
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -216,6 +216,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
216
216
  * @default 3
217
217
  */
218
218
  monthsPerRow: PropTypes.oneOf([3, 4]),
219
+ /**
220
+ * Name attribute used by the `input` element in the Field.
221
+ */
222
+ name: PropTypes.string,
219
223
  /**
220
224
  * Callback fired when the value is accepted.
221
225
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -196,6 +196,10 @@ DesktopDatePicker.propTypes = {
196
196
  * @default 3
197
197
  */
198
198
  monthsPerRow: PropTypes.oneOf([3, 4]),
199
+ /**
200
+ * Name attribute used by the `input` element in the Field.
201
+ */
202
+ name: PropTypes.string,
199
203
  /**
200
204
  * Callback fired when the value is accepted.
201
205
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -273,6 +273,10 @@ DesktopDateTimePicker.propTypes = {
273
273
  * @default 3
274
274
  */
275
275
  monthsPerRow: PropTypes.oneOf([3, 4]),
276
+ /**
277
+ * Name attribute used by the `input` element in the Field.
278
+ */
279
+ name: PropTypes.string,
276
280
  /**
277
281
  * Callback fired when the value is accepted.
278
282
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -201,6 +201,10 @@ DesktopTimePicker.propTypes = {
201
201
  * @default 1
202
202
  */
203
203
  minutesStep: PropTypes.number,
204
+ /**
205
+ * Name attribute used by the `input` element in the Field.
206
+ */
207
+ name: PropTypes.string,
204
208
  /**
205
209
  * Callback fired when the value is accepted.
206
210
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -193,6 +193,10 @@ MobileDatePicker.propTypes = {
193
193
  * @default 3
194
194
  */
195
195
  monthsPerRow: PropTypes.oneOf([3, 4]),
196
+ /**
197
+ * Name attribute used by the `input` element in the Field.
198
+ */
199
+ name: PropTypes.string,
196
200
  /**
197
201
  * Callback fired when the value is accepted.
198
202
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -242,6 +242,10 @@ MobileDateTimePicker.propTypes = {
242
242
  * @default 3
243
243
  */
244
244
  monthsPerRow: PropTypes.oneOf([3, 4]),
245
+ /**
246
+ * Name attribute used by the `input` element in the Field.
247
+ */
248
+ name: PropTypes.string,
245
249
  /**
246
250
  * Callback fired when the value is accepted.
247
251
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -180,6 +180,10 @@ MobileTimePicker.propTypes = {
180
180
  * @default 1
181
181
  */
182
182
  minutesStep: PropTypes.number,
183
+ /**
184
+ * Name attribute used by the `input` element in the Field.
185
+ */
186
+ name: PropTypes.string,
183
187
  /**
184
188
  * Callback fired when the value is accepted.
185
189
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -36,7 +36,12 @@ const MultiSectionDigitalClockSectionRoot = styled(MenuList, {
36
36
  '@media (prefers-reduced-motion: no-preference)': {
37
37
  scrollBehavior: ownerState.alreadyRendered ? 'smooth' : 'auto'
38
38
  },
39
- '&:hover': {
39
+ '@media (pointer: fine)': {
40
+ '&:hover': {
41
+ overflowY: 'auto'
42
+ }
43
+ },
44
+ '@media (pointer: none), (pointer: coarse)': {
40
45
  overflowY: 'auto'
41
46
  },
42
47
  '&:not(:first-of-type)': {
@@ -151,7 +156,8 @@ export const MultiSectionDigitalClockSection = /*#__PURE__*/React.forwardRef(fun
151
156
  ,
152
157
  "aria-disabled": readOnly,
153
158
  "aria-label": option.ariaLabel,
154
- "aria-selected": isSelected
159
+ "aria-selected": isSelected,
160
+ className: classes.item
155
161
  }, slotProps == null ? void 0 : slotProps.digitalClockSectionItem, {
156
162
  children: option.label
157
163
  }), option.label);
@@ -1,6 +1,6 @@
1
1
  import generateUtilityClass from '@mui/utils/generateUtilityClass';
2
2
  import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
3
  export function getMultiSectionDigitalClockSectionUtilityClass(slot) {
4
- return generateUtilityClass('MuiMultiSectionDigitalClock', slot);
4
+ return generateUtilityClass('MuiMultiSectionDigitalClockSection', slot);
5
5
  }
6
- export const multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClock', ['root', 'item']);
6
+ export const multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClockSection', ['root', 'item']);
@@ -161,6 +161,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
161
161
  * @default 1
162
162
  */
163
163
  minutesStep: PropTypes.number,
164
+ /**
165
+ * Name attribute used by the `input` element in the Field.
166
+ */
167
+ name: PropTypes.string,
164
168
  /**
165
169
  * Callback fired when the value is accepted.
166
170
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.18.3
2
+ * @mui/x-date-pickers v6.18.5
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -37,6 +37,7 @@ export const useDesktopPicker = _ref => {
37
37
  format,
38
38
  formatDensity,
39
39
  timezone,
40
+ name,
40
41
  label,
41
42
  inputRef,
42
43
  readOnly,
@@ -104,6 +105,7 @@ export const useDesktopPicker = _ref => {
104
105
  formatDensity,
105
106
  timezone,
106
107
  label,
108
+ name,
107
109
  autoFocus: autoFocus && !props.open,
108
110
  focused: open ? true : undefined
109
111
  }),
@@ -141,7 +141,7 @@ export interface UseFieldForwardedProps {
141
141
  clearable?: boolean;
142
142
  disabled?: boolean;
143
143
  }
144
- export type UseFieldResponse<TForwardedProps extends UseFieldForwardedProps> = Omit<TForwardedProps, keyof UseFieldForwardedProps> & Required<UseFieldForwardedProps> & Pick<React.HTMLAttributes<HTMLInputElement>, 'autoCorrect' | 'inputMode' | 'placeholder'> & {
144
+ export type UseFieldResponse<TForwardedProps extends UseFieldForwardedProps> = Omit<TForwardedProps, keyof UseFieldForwardedProps> & Required<UseFieldForwardedProps> & Pick<React.InputHTMLAttributes<HTMLInputElement>, 'autoCorrect' | 'inputMode' | 'placeholder'> & {
145
145
  ref: React.Ref<HTMLInputElement>;
146
146
  value: string;
147
147
  onChange: React.ChangeEventHandler<HTMLInputElement>;
@@ -34,6 +34,7 @@ export const useMobilePicker = _ref => {
34
34
  format,
35
35
  formatDensity,
36
36
  timezone,
37
+ name,
37
38
  label,
38
39
  inputRef,
39
40
  readOnly,
@@ -74,7 +75,8 @@ export const useMobilePicker = _ref => {
74
75
  format,
75
76
  formatDensity,
76
77
  timezone,
77
- label
78
+ label,
79
+ name
78
80
  }),
79
81
  ownerState: props
80
82
  });
@@ -59,4 +59,8 @@ export interface BaseNonRangeNonStaticPickerProps {
59
59
  * Pass a ref to the `input` element.
60
60
  */
61
61
  inputRef?: React.Ref<HTMLInputElement>;
62
+ /**
63
+ * Name attribute used by the `input` element in the Field.
64
+ */
65
+ name?: string;
62
66
  }
@@ -177,6 +177,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
177
177
  * @default 3
178
178
  */
179
179
  monthsPerRow: PropTypes.oneOf([3, 4]),
180
+ /**
181
+ * Name attribute used by the `input` element in the Field.
182
+ */
183
+ name: PropTypes.string,
180
184
  /**
181
185
  * Callback fired when the value is accepted.
182
186
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -215,6 +215,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
215
215
  * @default 3
216
216
  */
217
217
  monthsPerRow: PropTypes.oneOf([3, 4]),
218
+ /**
219
+ * Name attribute used by the `input` element in the Field.
220
+ */
221
+ name: PropTypes.string,
218
222
  /**
219
223
  * Callback fired when the value is accepted.
220
224
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -195,6 +195,10 @@ DesktopDatePicker.propTypes = {
195
195
  * @default 3
196
196
  */
197
197
  monthsPerRow: PropTypes.oneOf([3, 4]),
198
+ /**
199
+ * Name attribute used by the `input` element in the Field.
200
+ */
201
+ name: PropTypes.string,
198
202
  /**
199
203
  * Callback fired when the value is accepted.
200
204
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -271,6 +271,10 @@ DesktopDateTimePicker.propTypes = {
271
271
  * @default 3
272
272
  */
273
273
  monthsPerRow: PropTypes.oneOf([3, 4]),
274
+ /**
275
+ * Name attribute used by the `input` element in the Field.
276
+ */
277
+ name: PropTypes.string,
274
278
  /**
275
279
  * Callback fired when the value is accepted.
276
280
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -201,6 +201,10 @@ DesktopTimePicker.propTypes = {
201
201
  * @default 1
202
202
  */
203
203
  minutesStep: PropTypes.number,
204
+ /**
205
+ * Name attribute used by the `input` element in the Field.
206
+ */
207
+ name: PropTypes.string,
204
208
  /**
205
209
  * Callback fired when the value is accepted.
206
210
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -192,6 +192,10 @@ MobileDatePicker.propTypes = {
192
192
  * @default 3
193
193
  */
194
194
  monthsPerRow: PropTypes.oneOf([3, 4]),
195
+ /**
196
+ * Name attribute used by the `input` element in the Field.
197
+ */
198
+ name: PropTypes.string,
195
199
  /**
196
200
  * Callback fired when the value is accepted.
197
201
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -241,6 +241,10 @@ MobileDateTimePicker.propTypes = {
241
241
  * @default 3
242
242
  */
243
243
  monthsPerRow: PropTypes.oneOf([3, 4]),
244
+ /**
245
+ * Name attribute used by the `input` element in the Field.
246
+ */
247
+ name: PropTypes.string,
244
248
  /**
245
249
  * Callback fired when the value is accepted.
246
250
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -179,6 +179,10 @@ MobileTimePicker.propTypes = {
179
179
  * @default 1
180
180
  */
181
181
  minutesStep: PropTypes.number,
182
+ /**
183
+ * Name attribute used by the `input` element in the Field.
184
+ */
185
+ name: PropTypes.string,
182
186
  /**
183
187
  * Callback fired when the value is accepted.
184
188
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -36,7 +36,12 @@ var MultiSectionDigitalClockSectionRoot = styled(MenuList, {
36
36
  '@media (prefers-reduced-motion: no-preference)': {
37
37
  scrollBehavior: ownerState.alreadyRendered ? 'smooth' : 'auto'
38
38
  },
39
- '&:hover': {
39
+ '@media (pointer: fine)': {
40
+ '&:hover': {
41
+ overflowY: 'auto'
42
+ }
43
+ },
44
+ '@media (pointer: none), (pointer: coarse)': {
40
45
  overflowY: 'auto'
41
46
  },
42
47
  '&:not(:first-of-type)': {
@@ -157,7 +162,8 @@ export var MultiSectionDigitalClockSection = /*#__PURE__*/React.forwardRef(funct
157
162
  ,
158
163
  "aria-disabled": readOnly,
159
164
  "aria-label": option.ariaLabel,
160
- "aria-selected": isSelected
165
+ "aria-selected": isSelected,
166
+ className: classes.item
161
167
  }, slotProps == null ? void 0 : slotProps.digitalClockSectionItem, {
162
168
  children: option.label
163
169
  }), option.label);
@@ -1,6 +1,6 @@
1
1
  import generateUtilityClass from '@mui/utils/generateUtilityClass';
2
2
  import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
3
  export function getMultiSectionDigitalClockSectionUtilityClass(slot) {
4
- return generateUtilityClass('MuiMultiSectionDigitalClock', slot);
4
+ return generateUtilityClass('MuiMultiSectionDigitalClockSection', slot);
5
5
  }
6
- export var multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClock', ['root', 'item']);
6
+ export var multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClockSection', ['root', 'item']);
@@ -160,6 +160,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
160
160
  * @default 1
161
161
  */
162
162
  minutesStep: PropTypes.number,
163
+ /**
164
+ * Name attribute used by the `input` element in the Field.
165
+ */
166
+ name: PropTypes.string,
163
167
  /**
164
168
  * Callback fired when the value is accepted.
165
169
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
package/legacy/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.18.3
2
+ * @mui/x-date-pickers v6.18.5
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -35,6 +35,7 @@ export var useDesktopPicker = function useDesktopPicker(_ref) {
35
35
  format = props.format,
36
36
  formatDensity = props.formatDensity,
37
37
  timezone = props.timezone,
38
+ name = props.name,
38
39
  label = props.label,
39
40
  inputRef = props.inputRef,
40
41
  readOnly = props.readOnly,
@@ -102,6 +103,7 @@ export var useDesktopPicker = function useDesktopPicker(_ref) {
102
103
  formatDensity: formatDensity,
103
104
  timezone: timezone,
104
105
  label: label,
106
+ name: name,
105
107
  autoFocus: autoFocus && !props.open,
106
108
  focused: open ? true : undefined
107
109
  }),
@@ -31,6 +31,7 @@ export var useMobilePicker = function useMobilePicker(_ref) {
31
31
  format = props.format,
32
32
  formatDensity = props.formatDensity,
33
33
  timezone = props.timezone,
34
+ name = props.name,
34
35
  label = props.label,
35
36
  inputRef = props.inputRef,
36
37
  readOnly = props.readOnly,
@@ -69,7 +70,8 @@ export var useMobilePicker = function useMobilePicker(_ref) {
69
70
  format: format,
70
71
  formatDensity: formatDensity,
71
72
  timezone: timezone,
72
- label: label
73
+ label: label,
74
+ name: name
73
75
  }),
74
76
  ownerState: props
75
77
  });
@@ -118,6 +118,7 @@ export type FieldSelectedSections = number | FieldSectionType | null | 'all' | {
118
118
  export interface BaseSingleInputFieldProps<TValue, TDate, TSection extends FieldSection, TError> extends BaseFieldProps<TValue, TDate, TSection, TError> {
119
119
  label?: React.ReactNode;
120
120
  id?: string;
121
+ name?: string;
121
122
  inputRef?: React.Ref<HTMLInputElement>;
122
123
  onKeyDown?: React.KeyboardEventHandler;
123
124
  onBlur?: React.FocusEventHandler;
@@ -178,6 +178,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
178
178
  * @default 3
179
179
  */
180
180
  monthsPerRow: PropTypes.oneOf([3, 4]),
181
+ /**
182
+ * Name attribute used by the `input` element in the Field.
183
+ */
184
+ name: PropTypes.string,
181
185
  /**
182
186
  * Callback fired when the value is accepted.
183
187
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -216,6 +216,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
216
216
  * @default 3
217
217
  */
218
218
  monthsPerRow: PropTypes.oneOf([3, 4]),
219
+ /**
220
+ * Name attribute used by the `input` element in the Field.
221
+ */
222
+ name: PropTypes.string,
219
223
  /**
220
224
  * Callback fired when the value is accepted.
221
225
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -192,6 +192,10 @@ DesktopDatePicker.propTypes = {
192
192
  * @default 3
193
193
  */
194
194
  monthsPerRow: PropTypes.oneOf([3, 4]),
195
+ /**
196
+ * Name attribute used by the `input` element in the Field.
197
+ */
198
+ name: PropTypes.string,
195
199
  /**
196
200
  * Callback fired when the value is accepted.
197
201
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -269,6 +269,10 @@ DesktopDateTimePicker.propTypes = {
269
269
  * @default 3
270
270
  */
271
271
  monthsPerRow: PropTypes.oneOf([3, 4]),
272
+ /**
273
+ * Name attribute used by the `input` element in the Field.
274
+ */
275
+ name: PropTypes.string,
272
276
  /**
273
277
  * Callback fired when the value is accepted.
274
278
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -197,6 +197,10 @@ DesktopTimePicker.propTypes = {
197
197
  * @default 1
198
198
  */
199
199
  minutesStep: PropTypes.number,
200
+ /**
201
+ * Name attribute used by the `input` element in the Field.
202
+ */
203
+ name: PropTypes.string,
200
204
  /**
201
205
  * Callback fired when the value is accepted.
202
206
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -189,6 +189,10 @@ MobileDatePicker.propTypes = {
189
189
  * @default 3
190
190
  */
191
191
  monthsPerRow: PropTypes.oneOf([3, 4]),
192
+ /**
193
+ * Name attribute used by the `input` element in the Field.
194
+ */
195
+ name: PropTypes.string,
192
196
  /**
193
197
  * Callback fired when the value is accepted.
194
198
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -238,6 +238,10 @@ MobileDateTimePicker.propTypes = {
238
238
  * @default 3
239
239
  */
240
240
  monthsPerRow: PropTypes.oneOf([3, 4]),
241
+ /**
242
+ * Name attribute used by the `input` element in the Field.
243
+ */
244
+ name: PropTypes.string,
241
245
  /**
242
246
  * Callback fired when the value is accepted.
243
247
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -176,6 +176,10 @@ MobileTimePicker.propTypes = {
176
176
  * @default 1
177
177
  */
178
178
  minutesStep: PropTypes.number,
179
+ /**
180
+ * Name attribute used by the `input` element in the Field.
181
+ */
182
+ name: PropTypes.string,
179
183
  /**
180
184
  * Callback fired when the value is accepted.
181
185
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -36,7 +36,12 @@ const MultiSectionDigitalClockSectionRoot = styled(MenuList, {
36
36
  '@media (prefers-reduced-motion: no-preference)': {
37
37
  scrollBehavior: ownerState.alreadyRendered ? 'smooth' : 'auto'
38
38
  },
39
- '&:hover': {
39
+ '@media (pointer: fine)': {
40
+ '&:hover': {
41
+ overflowY: 'auto'
42
+ }
43
+ },
44
+ '@media (pointer: none), (pointer: coarse)': {
40
45
  overflowY: 'auto'
41
46
  },
42
47
  '&:not(:first-of-type)': {
@@ -149,7 +154,8 @@ export const MultiSectionDigitalClockSection = /*#__PURE__*/React.forwardRef(fun
149
154
  ,
150
155
  "aria-disabled": readOnly,
151
156
  "aria-label": option.ariaLabel,
152
- "aria-selected": isSelected
157
+ "aria-selected": isSelected,
158
+ className: classes.item
153
159
  }, slotProps?.digitalClockSectionItem, {
154
160
  children: option.label
155
161
  }), option.label);
@@ -1,6 +1,6 @@
1
1
  import generateUtilityClass from '@mui/utils/generateUtilityClass';
2
2
  import generateUtilityClasses from '@mui/utils/generateUtilityClasses';
3
3
  export function getMultiSectionDigitalClockSectionUtilityClass(slot) {
4
- return generateUtilityClass('MuiMultiSectionDigitalClock', slot);
4
+ return generateUtilityClass('MuiMultiSectionDigitalClockSection', slot);
5
5
  }
6
- export const multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClock', ['root', 'item']);
6
+ export const multiSectionDigitalClockSectionClasses = generateUtilityClasses('MuiMultiSectionDigitalClockSection', ['root', 'item']);
@@ -161,6 +161,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
161
161
  * @default 1
162
162
  */
163
163
  minutesStep: PropTypes.number,
164
+ /**
165
+ * Name attribute used by the `input` element in the Field.
166
+ */
167
+ name: PropTypes.string,
164
168
  /**
165
169
  * Callback fired when the value is accepted.
166
170
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.18.3
2
+ * @mui/x-date-pickers v6.18.5
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -36,6 +36,7 @@ export const useDesktopPicker = _ref => {
36
36
  format,
37
37
  formatDensity,
38
38
  timezone,
39
+ name,
39
40
  label,
40
41
  inputRef,
41
42
  readOnly,
@@ -103,6 +104,7 @@ export const useDesktopPicker = _ref => {
103
104
  formatDensity,
104
105
  timezone,
105
106
  label,
107
+ name,
106
108
  autoFocus: autoFocus && !props.open,
107
109
  focused: open ? true : undefined
108
110
  }),
@@ -33,6 +33,7 @@ export const useMobilePicker = _ref => {
33
33
  format,
34
34
  formatDensity,
35
35
  timezone,
36
+ name,
36
37
  label,
37
38
  inputRef,
38
39
  readOnly,
@@ -73,7 +74,8 @@ export const useMobilePicker = _ref => {
73
74
  format,
74
75
  formatDensity,
75
76
  timezone,
76
- label
77
+ label,
78
+ name
77
79
  }),
78
80
  ownerState: props
79
81
  });
@@ -187,6 +187,10 @@ process.env.NODE_ENV !== "production" ? DatePicker.propTypes = {
187
187
  * @default 3
188
188
  */
189
189
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
190
+ /**
191
+ * Name attribute used by the `input` element in the Field.
192
+ */
193
+ name: _propTypes.default.string,
190
194
  /**
191
195
  * Callback fired when the value is accepted.
192
196
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -225,6 +225,10 @@ process.env.NODE_ENV !== "production" ? DateTimePicker.propTypes = {
225
225
  * @default 3
226
226
  */
227
227
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
228
+ /**
229
+ * Name attribute used by the `input` element in the Field.
230
+ */
231
+ name: _propTypes.default.string,
228
232
  /**
229
233
  * Callback fired when the value is accepted.
230
234
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -201,6 +201,10 @@ DesktopDatePicker.propTypes = {
201
201
  * @default 3
202
202
  */
203
203
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
204
+ /**
205
+ * Name attribute used by the `input` element in the Field.
206
+ */
207
+ name: _propTypes.default.string,
204
208
  /**
205
209
  * Callback fired when the value is accepted.
206
210
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -278,6 +278,10 @@ DesktopDateTimePicker.propTypes = {
278
278
  * @default 3
279
279
  */
280
280
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
281
+ /**
282
+ * Name attribute used by the `input` element in the Field.
283
+ */
284
+ name: _propTypes.default.string,
281
285
  /**
282
286
  * Callback fired when the value is accepted.
283
287
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -206,6 +206,10 @@ DesktopTimePicker.propTypes = {
206
206
  * @default 1
207
207
  */
208
208
  minutesStep: _propTypes.default.number,
209
+ /**
210
+ * Name attribute used by the `input` element in the Field.
211
+ */
212
+ name: _propTypes.default.string,
209
213
  /**
210
214
  * Callback fired when the value is accepted.
211
215
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -198,6 +198,10 @@ MobileDatePicker.propTypes = {
198
198
  * @default 3
199
199
  */
200
200
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
201
+ /**
202
+ * Name attribute used by the `input` element in the Field.
203
+ */
204
+ name: _propTypes.default.string,
201
205
  /**
202
206
  * Callback fired when the value is accepted.
203
207
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -247,6 +247,10 @@ MobileDateTimePicker.propTypes = {
247
247
  * @default 3
248
248
  */
249
249
  monthsPerRow: _propTypes.default.oneOf([3, 4]),
250
+ /**
251
+ * Name attribute used by the `input` element in the Field.
252
+ */
253
+ name: _propTypes.default.string,
250
254
  /**
251
255
  * Callback fired when the value is accepted.
252
256
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -185,6 +185,10 @@ MobileTimePicker.propTypes = {
185
185
  * @default 1
186
186
  */
187
187
  minutesStep: _propTypes.default.number,
188
+ /**
189
+ * Name attribute used by the `input` element in the Field.
190
+ */
191
+ name: _propTypes.default.string,
188
192
  /**
189
193
  * Callback fired when the value is accepted.
190
194
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
@@ -45,7 +45,12 @@ const MultiSectionDigitalClockSectionRoot = (0, _styles.styled)(_MenuList.defaul
45
45
  '@media (prefers-reduced-motion: no-preference)': {
46
46
  scrollBehavior: ownerState.alreadyRendered ? 'smooth' : 'auto'
47
47
  },
48
- '&:hover': {
48
+ '@media (pointer: fine)': {
49
+ '&:hover': {
50
+ overflowY: 'auto'
51
+ }
52
+ },
53
+ '@media (pointer: none), (pointer: coarse)': {
49
54
  overflowY: 'auto'
50
55
  },
51
56
  '&:not(:first-of-type)': {
@@ -158,7 +163,8 @@ const MultiSectionDigitalClockSection = exports.MultiSectionDigitalClockSection
158
163
  ,
159
164
  "aria-disabled": readOnly,
160
165
  "aria-label": option.ariaLabel,
161
- "aria-selected": isSelected
166
+ "aria-selected": isSelected,
167
+ className: classes.item
162
168
  }, slotProps?.digitalClockSectionItem, {
163
169
  children: option.label
164
170
  }), option.label);
@@ -9,6 +9,6 @@ exports.multiSectionDigitalClockSectionClasses = void 0;
9
9
  var _generateUtilityClass = _interopRequireDefault(require("@mui/utils/generateUtilityClass"));
10
10
  var _generateUtilityClasses = _interopRequireDefault(require("@mui/utils/generateUtilityClasses"));
11
11
  function getMultiSectionDigitalClockSectionUtilityClass(slot) {
12
- return (0, _generateUtilityClass.default)('MuiMultiSectionDigitalClock', slot);
12
+ return (0, _generateUtilityClass.default)('MuiMultiSectionDigitalClockSection', slot);
13
13
  }
14
- const multiSectionDigitalClockSectionClasses = exports.multiSectionDigitalClockSectionClasses = (0, _generateUtilityClasses.default)('MuiMultiSectionDigitalClock', ['root', 'item']);
14
+ const multiSectionDigitalClockSectionClasses = exports.multiSectionDigitalClockSectionClasses = (0, _generateUtilityClasses.default)('MuiMultiSectionDigitalClockSection', ['root', 'item']);
@@ -170,6 +170,10 @@ process.env.NODE_ENV !== "production" ? TimePicker.propTypes = {
170
170
  * @default 1
171
171
  */
172
172
  minutesStep: _propTypes.default.number,
173
+ /**
174
+ * Name attribute used by the `input` element in the Field.
175
+ */
176
+ name: _propTypes.default.string,
173
177
  /**
174
178
  * Callback fired when the value is accepted.
175
179
  * @template TValue The value type. Will be either the same type as `value` or `null`. Can be in `[start, end]` format in case of range value.
package/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.18.3
2
+ * @mui/x-date-pickers v6.18.5
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -44,6 +44,7 @@ const useDesktopPicker = _ref => {
44
44
  format,
45
45
  formatDensity,
46
46
  timezone,
47
+ name,
47
48
  label,
48
49
  inputRef,
49
50
  readOnly,
@@ -111,6 +112,7 @@ const useDesktopPicker = _ref => {
111
112
  formatDensity,
112
113
  timezone,
113
114
  label,
115
+ name,
114
116
  autoFocus: autoFocus && !props.open,
115
117
  focused: open ? true : undefined
116
118
  }),
@@ -41,6 +41,7 @@ const useMobilePicker = _ref => {
41
41
  format,
42
42
  formatDensity,
43
43
  timezone,
44
+ name,
44
45
  label,
45
46
  inputRef,
46
47
  readOnly,
@@ -81,7 +82,8 @@ const useMobilePicker = _ref => {
81
82
  format,
82
83
  formatDensity,
83
84
  timezone,
84
- label
85
+ label,
86
+ name
85
87
  }),
86
88
  ownerState: props
87
89
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/x-date-pickers",
3
- "version": "6.18.3",
3
+ "version": "6.18.5",
4
4
  "description": "The community edition of the date picker components (MUI X).",
5
5
  "author": "MUI Team",
6
6
  "main": "./node/index.js",