@mui/x-date-pickers 6.10.0 → 6.10.2

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.
@@ -9,7 +9,7 @@ import { buildWarning } from '../internals/utils/warning';
9
9
  defaultDayjs.extend(customParseFormatPlugin);
10
10
  defaultDayjs.extend(localizedFormatPlugin);
11
11
  defaultDayjs.extend(isBetweenPlugin);
12
- const localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale with `require('dayjs/locale/{localeUsed}')`", 'fallback on English locale']);
12
+ const localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale from 'dayjs/locale/{localeUsed}'", 'fallback on English locale']);
13
13
  const formatTokenMap = {
14
14
  // Year
15
15
  YY: 'year',
@@ -262,14 +262,14 @@ export class AdapterLuxon {
262
262
  };
263
263
  /* istanbul ignore next */
264
264
  this.is12HourCycleInCurrentLocale = () => {
265
- var _Intl$DateTimeFormat, _Intl$DateTimeFormat$;
265
+ var _Intl$DateTimeFormat;
266
266
  if (typeof Intl === 'undefined' || typeof Intl.DateTimeFormat === 'undefined') {
267
267
  return true; // Luxon defaults to en-US if Intl not found
268
268
  }
269
269
 
270
270
  return Boolean((_Intl$DateTimeFormat = new Intl.DateTimeFormat(this.locale, {
271
271
  hour: 'numeric'
272
- })) == null ? void 0 : (_Intl$DateTimeFormat$ = _Intl$DateTimeFormat.resolvedOptions()) == null ? void 0 : _Intl$DateTimeFormat$.hour12);
272
+ })) == null || (_Intl$DateTimeFormat = _Intl$DateTimeFormat.resolvedOptions()) == null ? void 0 : _Intl$DateTimeFormat.hour12);
273
273
  };
274
274
  this.expandFormat = format => {
275
275
  // Extract escaped section to avoid extending them
package/CHANGELOG.md CHANGED
@@ -3,6 +3,139 @@
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.10.2
7
+
8
+ _Jul 27, 2023_
9
+
10
+ We'd like to offer a big thanks to the 13 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🚀 Improve scatter charts performance
13
+ - 📚 Redesigned component API documentation and side navigation
14
+ - 🐞 Bugfixes
15
+
16
+ ### Data Grid
17
+
18
+ #### `@mui/x-data-grid@v6.10.2`
19
+
20
+ - [DataGrid] Fix quick filter & aggregation error (#9729) @romgrk
21
+ - [DataGrid] Fix row click propagation causing error in nested grid (#9741) @cherniavskii
22
+ - [DataGrid] Keep focused cell in the DOM (#7357) @yaredtsy
23
+ - [l10n] Improve Finnish (fi-FI) locale (#9746) @sambbaahh
24
+
25
+ #### `@mui/x-data-grid-pro@v6.10.2` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
26
+
27
+ Same changes as in `@mui/x-data-grid@v6.10.2`.
28
+
29
+ #### `@mui/x-data-grid-premium@v6.10.2` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link)
30
+
31
+ Same changes as in `@mui/x-data-grid-pro@v6.10.2`, plus:
32
+
33
+ - [DataGridPremium] Allow to customize grouping cell offset (#9417) @cherniavskii
34
+
35
+ ### Date Pickers
36
+
37
+ #### `@mui/x-date-pickers@v6.10.2`
38
+
39
+ - [pickers] Remove the `endOfDate` from `DigitalClock` timeOptions (#9800) @noraleonte
40
+
41
+ #### `@mui/x-date-pickers-pro@v6.10.2` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
42
+
43
+ Same changes as in `@mui/x-date-pickers@v6.10.2`.
44
+
45
+ ### Charts / `@mui/x-charts@v6.0.0-alpha.5`
46
+
47
+ - [charts] Improve JSDoc for axis-related props (#9779) @flaviendelangle
48
+ - [charts] Improve performances of Scatter component (#9527) @flaviendelangle
49
+
50
+ ### Docs
51
+
52
+ - [docs] Add `pnpm` in more places @oliviertassinari
53
+ - [docs] Add `pnpm` installation instructions for MUI X (#9707) @richbustos
54
+ - [docs] Align pickers "uncontrolled vs controlled" sections (#9772) @LukasTy
55
+ - [docs] Apply style guide to the data grid Layout page (#9673) @richbustos
56
+ - [docs] Differentiate between packages in `slotProps` docs (#9668) @cherniavskii
57
+ - [docs] Fix charts width in axis pages (#9801) @alexfauquette
58
+ - [docs] Fix wrong prop name in the Editing page (#9753) @m4theushw
59
+ - [docs] New component API page and side nav design (#9187) @alexfauquette
60
+ - [docs] Update overview page with up to date information about the plans (#9512) @joserodolfofreitas
61
+
62
+ ### Core
63
+
64
+ - [core] Use PR charts version in preview (#9787) @alexfauquette
65
+ - [license] Allow overriding the license on specific parts of the page (#9717) @Janpot
66
+ - [license] Throw in dev mode after 30 days (#9701) @oliviertassinari
67
+ - [license] Only throw in dev mode (#9803) @oliviertassinari
68
+ - [test] Fail the CI when new unexpected files are created (#9728) @oliviertassinari
69
+
70
+ ## 6.10.1
71
+
72
+ _Jul 20, 2023_
73
+
74
+ We'd like to offer a big thanks to the 11 contributors who made this release possible. Here are some highlights ✨:
75
+
76
+ - 🎁 Fix CSV export for values containing double quotes
77
+ - 🚀 Improve tree data performance
78
+ - 🐞 Bugfixes
79
+ - 📚 Documentation improvements
80
+
81
+ ### Data Grid
82
+
83
+ #### `@mui/x-data-grid@v6.10.1`
84
+
85
+ - [DataGrid] Filtering performance: compile filter applier with `eval` (#9635) @romgrk
86
+ - [DataGrid] Fix CSV export for values containing double quotes (#9667) @cherniavskii
87
+ - [DataGrid] Fix column type change not working correctly (#9594) @cherniavskii
88
+ - [DataGrid] Fix quick filter `undefined` row error (#9708) @romgrk
89
+ - [DataGrid] Prevent `viewportOuterSize.height` going negative (#9664) @gitstart
90
+ - [DataGrid] Update focused cell on page change via keyboard (#9203) @m4theushw
91
+ - [DataGrid] Wait for remote stylesheets to load before print (#9665) @cherniavskii
92
+
93
+ #### `@mui/x-data-grid-pro@v6.10.1` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
94
+
95
+ Same changes as in `@mui/x-data-grid@v6.10.1`, plus:
96
+
97
+ - [DataGridPro] Improve tree data performance (#9682) @cherniavskii
98
+ - [DataGridPro] Prevent affecting cells from child DataGrid when resizing a column (#9670) @m4theushw
99
+
100
+ #### `@mui/x-data-grid-premium@v6.10.1` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link)
101
+
102
+ Same changes as in `@mui/x-data-grid-pro@v6.10.1`.
103
+
104
+ ### Date Pickers
105
+
106
+ #### `@mui/x-date-pickers@v6.10.1`
107
+
108
+ - [fields] Fix `format` and `value` update order (#9715) @LukasTy
109
+ - [pickers] Remove `require` usage in comment (#9675) @LukasTy
110
+
111
+ #### `@mui/x-date-pickers-pro@v6.10.1` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
112
+
113
+ Same changes as in `@mui/x-date-pickers@v6.10.1`.
114
+
115
+ ### Charts / `@mui/x-charts@v6.0.0-alpha.4`
116
+
117
+ - [charts] Fix blinking in responsive charts and extremums computation for line charts (#9734) @alexfauquette
118
+ - [charts] Use ESM with imports (#9645) @alexfauquette
119
+
120
+ ### Docs
121
+
122
+ - [docs] Add additional note for license key installation on Next.js (#9575) @joserodolfofreitas
123
+ - [docs] Add paragraph about managing focus of custom edit components (#9658) @m4theushw
124
+ - [docs] Add unsorted icon slot to the custom sort icons demo (#9169) @d4rekanguok
125
+ - [docs] Disable ad for onboarding pages (#9700) @oliviertassinari
126
+ - [docs] Disabling ads without toolbar has no effect @oliviertassinari
127
+ - [docs] Fix Date Pickers usage to Title Case (#9680) @richbustos
128
+ - [docs] Fix sorting in `CustomSortIcons` demo (#9656) @MBilalShafi
129
+ - [docs] Improve the UI for pickers introduction (#9644) @alexfauquette
130
+ - [docs] Improve the demo design @oliviertassinari
131
+ - [docs] Localization progress, polish (#9672) @oliviertassinari
132
+ - [docs] Normalize the WIP items (#9671) @oliviertassinari
133
+
134
+ ### Core
135
+
136
+ - [core] Add `validate` command (#9714) @romgrk
137
+ - [CHANGELOG] Update generator to new format @oliviertassinari
138
+
6
139
  ## 6.10.0
7
140
 
8
141
  _Jul 13, 2023_
@@ -26,11 +159,11 @@ We'd like to offer a big thanks to the 10 contributors who made this release pos
26
159
  - [DataGrid] Make `rowExpansionChange` event public (#9611) @MBilalShafi
27
160
  - [l10n] Improve Polish (pl-PL) locale (#9625) @ch1llysense
28
161
 
29
- #### `@mui/x-data-grid-pro@6.10.0`
162
+ #### `@mui/x-data-grid-pro@6.10.0` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
30
163
 
31
164
  Same changes as in `@mui/x-data-grid@6.10.0`.
32
165
 
33
- #### `@mui/x-data-grid-premium@6.10.0`
166
+ #### `@mui/x-data-grid-premium@6.10.0` [![premium](https://mui.com/r/x-premium-svg)](https://mui.com/r/x-premium-svg-link)
34
167
 
35
168
  Same changes as in `@mui/x-data-grid-pro@6.10.0`.
36
169
 
@@ -41,7 +174,7 @@ Same changes as in `@mui/x-data-grid-pro@6.10.0`.
41
174
  - [pickers] Fix date calendar issues (#9652) @LukasTy
42
175
  - [l10n] Improve Norwegian (nb-NO) locale (#9608) @JosteinBrevik
43
176
 
44
- #### `@mui/x-date-pickers-pro@6.10.0`
177
+ #### `@mui/x-date-pickers-pro@6.10.0` [![pro](https://mui.com/r/x-pro-svg)](https://mui.com/r/x-pro-svg-link)
45
178
 
46
179
  Same changes as in `@mui/x-date-pickers@6.10.0`.
47
180
 
@@ -214,7 +214,7 @@ export const DigitalClock = /*#__PURE__*/React.forwardRef(function DigitalClock(
214
214
  const startOfDay = utils.startOfDay(valueOrReferenceDate);
215
215
  return [startOfDay, ...Array.from({
216
216
  length: Math.ceil(24 * 60 / timeStep) - 1
217
- }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1))), utils.endOfDay(valueOrReferenceDate)];
217
+ }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1)))];
218
218
  }, [valueOrReferenceDate, timeStep, utils]);
219
219
  return /*#__PURE__*/_jsx(DigitalClockRoot, _extends({
220
220
  ref: handleRef,
@@ -60,8 +60,8 @@ export const renderDesktopDateTimeView = ({
60
60
  skipDisabled,
61
61
  timeViewsCount
62
62
  }) => {
63
- var _resolveComponentProp, _resolveComponentProp2, _slotProps$actionBar;
64
- const isActionBarVisible = !!((_resolveComponentProp = resolveComponentProps((_slotProps$actionBar = slotProps == null ? void 0 : slotProps.actionBar) != null ? _slotProps$actionBar : componentsProps == null ? void 0 : componentsProps.actionBar, {})) != null && (_resolveComponentProp2 = _resolveComponentProp.actions) != null && _resolveComponentProp2.length);
63
+ var _resolveComponentProp, _slotProps$actionBar;
64
+ const isActionBarVisible = !!((_resolveComponentProp = resolveComponentProps((_slotProps$actionBar = slotProps == null ? void 0 : slotProps.actionBar) != null ? _slotProps$actionBar : componentsProps == null ? void 0 : componentsProps.actionBar, {})) != null && (_resolveComponentProp = _resolveComponentProp.actions) != null && _resolveComponentProp.length);
65
65
  return /*#__PURE__*/_jsxs(React.Fragment, {
66
66
  children: [/*#__PURE__*/_jsxs(DateTimeViewWrapper, {
67
67
  children: [/*#__PURE__*/_jsx(DateCalendar, {
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.10.0
2
+ * @mui/x-date-pickers v6.10.2
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -48,7 +48,7 @@ export const useDesktopPicker = _ref => {
48
48
  const internalInputRef = React.useRef(null);
49
49
  const containerRef = React.useRef(null);
50
50
  const labelId = useId();
51
- const isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null ? void 0 : (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
51
+ const isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null || (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
52
52
  const {
53
53
  open,
54
54
  actions,
@@ -263,6 +263,14 @@ export const useFieldState = params => {
263
263
  const setTempAndroidValueStr = tempValueStrAndroid => setState(prev => _extends({}, prev, {
264
264
  tempValueStrAndroid
265
265
  }));
266
+ React.useEffect(() => {
267
+ const sections = getSectionsFromValue(state.value);
268
+ validateSections(sections, valueType);
269
+ setState(prevState => _extends({}, prevState, {
270
+ sections
271
+ }));
272
+ }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
273
+
266
274
  React.useEffect(() => {
267
275
  let shouldUpdate = false;
268
276
  if (!valueManager.areValuesEqual(utils, state.value, valueFromTheOutside)) {
@@ -279,14 +287,6 @@ export const useFieldState = params => {
279
287
  }
280
288
  }, [valueFromTheOutside]); // eslint-disable-line react-hooks/exhaustive-deps
281
289
 
282
- React.useEffect(() => {
283
- const sections = getSectionsFromValue(state.value);
284
- validateSections(sections, valueType);
285
- setState(prevState => _extends({}, prevState, {
286
- sections
287
- }));
288
- }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
289
-
290
290
  return {
291
291
  state,
292
292
  selectedSectionIndexes,
@@ -43,7 +43,7 @@ export const useMobilePicker = _ref => {
43
43
  const utils = useUtils();
44
44
  const internalInputRef = React.useRef(null);
45
45
  const labelId = useId();
46
- const isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null ? void 0 : (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
46
+ const isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null || (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
47
47
  const {
48
48
  open,
49
49
  actions,
@@ -56,8 +56,8 @@ export const useStaticPicker = _ref => {
56
56
  children: /*#__PURE__*/_jsx(Layout, _extends({}, layoutProps, slotProps == null ? void 0 : slotProps.layout, {
57
57
  slots: slots,
58
58
  slotProps: slotProps,
59
- sx: [...(Array.isArray(sx) ? sx : [sx]), ...(Array.isArray(slotProps == null ? void 0 : (_slotProps$layout = slotProps.layout) == null ? void 0 : _slotProps$layout.sx) ? slotProps.layout.sx : [slotProps == null ? void 0 : (_slotProps$layout2 = slotProps.layout) == null ? void 0 : _slotProps$layout2.sx])],
60
- className: clsx(className, slotProps == null ? void 0 : (_slotProps$layout3 = slotProps.layout) == null ? void 0 : _slotProps$layout3.className),
59
+ sx: [...(Array.isArray(sx) ? sx : [sx]), ...(Array.isArray(slotProps == null || (_slotProps$layout = slotProps.layout) == null ? void 0 : _slotProps$layout.sx) ? slotProps.layout.sx : [slotProps == null || (_slotProps$layout2 = slotProps.layout) == null ? void 0 : _slotProps$layout2.sx])],
60
+ className: clsx(className, slotProps == null || (_slotProps$layout3 = slotProps.layout) == null ? void 0 : _slotProps$layout3.className),
61
61
  ref: ref,
62
62
  children: renderCurrentView()
63
63
  }))
@@ -12,7 +12,7 @@ import { buildWarning } from '../internals/utils/warning';
12
12
  defaultDayjs.extend(customParseFormatPlugin);
13
13
  defaultDayjs.extend(localizedFormatPlugin);
14
14
  defaultDayjs.extend(isBetweenPlugin);
15
- var localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale with `require('dayjs/locale/{localeUsed}')`", 'fallback on English locale']);
15
+ var localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale from 'dayjs/locale/{localeUsed}'", 'fallback on English locale']);
16
16
  var formatTokenMap = {
17
17
  // Year
18
18
  YY: 'year',
@@ -266,14 +266,14 @@ export var AdapterLuxon = /*#__PURE__*/_createClass(function AdapterLuxon() {
266
266
  };
267
267
  /* istanbul ignore next */
268
268
  this.is12HourCycleInCurrentLocale = function () {
269
- var _Intl$DateTimeFormat, _Intl$DateTimeFormat$;
269
+ var _Intl$DateTimeFormat;
270
270
  if (typeof Intl === 'undefined' || typeof Intl.DateTimeFormat === 'undefined') {
271
271
  return true; // Luxon defaults to en-US if Intl not found
272
272
  }
273
273
 
274
274
  return Boolean((_Intl$DateTimeFormat = new Intl.DateTimeFormat(_this.locale, {
275
275
  hour: 'numeric'
276
- })) == null ? void 0 : (_Intl$DateTimeFormat$ = _Intl$DateTimeFormat.resolvedOptions()) == null ? void 0 : _Intl$DateTimeFormat$.hour12);
276
+ })) == null || (_Intl$DateTimeFormat = _Intl$DateTimeFormat.resolvedOptions()) == null ? void 0 : _Intl$DateTimeFormat.hour12);
277
277
  };
278
278
  this.expandFormat = function (format) {
279
279
  // Extract escaped section to avoid extending them
@@ -229,7 +229,7 @@ export var DigitalClock = /*#__PURE__*/React.forwardRef(function DigitalClock(in
229
229
  length: Math.ceil(24 * 60 / timeStep) - 1
230
230
  }, function (_, index) {
231
231
  return utils.addMinutes(startOfDay, timeStep * (index + 1));
232
- })), [utils.endOfDay(valueOrReferenceDate)]);
232
+ })));
233
233
  }, [valueOrReferenceDate, timeStep, utils]);
234
234
  return /*#__PURE__*/_jsx(DigitalClockRoot, _extends({
235
235
  ref: handleRef,
@@ -11,7 +11,7 @@ import { isDatePickerView } from '../internals/utils/date-utils';
11
11
  import { jsx as _jsx } from "react/jsx-runtime";
12
12
  import { jsxs as _jsxs } from "react/jsx-runtime";
13
13
  export var renderDesktopDateTimeView = function renderDesktopDateTimeView(_ref) {
14
- var _resolveComponentProp, _resolveComponentProp2, _slotProps$actionBar;
14
+ var _resolveComponentProp, _slotProps$actionBar;
15
15
  var view = _ref.view,
16
16
  onViewChange = _ref.onViewChange,
17
17
  views = _ref.views,
@@ -61,7 +61,7 @@ export var renderDesktopDateTimeView = function renderDesktopDateTimeView(_ref)
61
61
  timeSteps = _ref.timeSteps,
62
62
  skipDisabled = _ref.skipDisabled,
63
63
  timeViewsCount = _ref.timeViewsCount;
64
- var isActionBarVisible = !!((_resolveComponentProp = resolveComponentProps((_slotProps$actionBar = slotProps == null ? void 0 : slotProps.actionBar) != null ? _slotProps$actionBar : componentsProps == null ? void 0 : componentsProps.actionBar, {})) != null && (_resolveComponentProp2 = _resolveComponentProp.actions) != null && _resolveComponentProp2.length);
64
+ var isActionBarVisible = !!((_resolveComponentProp = resolveComponentProps((_slotProps$actionBar = slotProps == null ? void 0 : slotProps.actionBar) != null ? _slotProps$actionBar : componentsProps == null ? void 0 : componentsProps.actionBar, {})) != null && (_resolveComponentProp = _resolveComponentProp.actions) != null && _resolveComponentProp.length);
65
65
  return /*#__PURE__*/_jsxs(React.Fragment, {
66
66
  children: [/*#__PURE__*/_jsxs(DateTimeViewWrapper, {
67
67
  children: [/*#__PURE__*/_jsx(DateCalendar, {
package/legacy/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.10.0
2
+ * @mui/x-date-pickers v6.10.2
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -45,7 +45,7 @@ export var useDesktopPicker = function useDesktopPicker(_ref) {
45
45
  var internalInputRef = React.useRef(null);
46
46
  var containerRef = React.useRef(null);
47
47
  var labelId = useId();
48
- var isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null ? void 0 : (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
48
+ var isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null || (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
49
49
  var _usePicker = usePicker(_extends({}, pickerParams, {
50
50
  props: props,
51
51
  inputRef: internalInputRef,
@@ -292,6 +292,16 @@ export var useFieldState = function useFieldState(params) {
292
292
  });
293
293
  });
294
294
  };
295
+ React.useEffect(function () {
296
+ var sections = getSectionsFromValue(state.value);
297
+ validateSections(sections, valueType);
298
+ setState(function (prevState) {
299
+ return _extends({}, prevState, {
300
+ sections: sections
301
+ });
302
+ });
303
+ }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
304
+
295
305
  React.useEffect(function () {
296
306
  var shouldUpdate = false;
297
307
  if (!valueManager.areValuesEqual(utils, state.value, valueFromTheOutside)) {
@@ -310,16 +320,6 @@ export var useFieldState = function useFieldState(params) {
310
320
  }
311
321
  }, [valueFromTheOutside]); // eslint-disable-line react-hooks/exhaustive-deps
312
322
 
313
- React.useEffect(function () {
314
- var sections = getSectionsFromValue(state.value);
315
- validateSections(sections, valueType);
316
- setState(function (prevState) {
317
- return _extends({}, prevState, {
318
- sections: sections
319
- });
320
- });
321
- }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
322
-
323
323
  return {
324
324
  state: state,
325
325
  selectedSectionIndexes: selectedSectionIndexes,
@@ -39,7 +39,7 @@ export var useMobilePicker = function useMobilePicker(_ref) {
39
39
  var utils = useUtils();
40
40
  var internalInputRef = React.useRef(null);
41
41
  var labelId = useId();
42
- var isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null ? void 0 : (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
42
+ var isToolbarHidden = (_innerSlotProps$toolb = innerSlotProps == null || (_innerSlotProps$toolb2 = innerSlotProps.toolbar) == null ? void 0 : _innerSlotProps$toolb2.hidden) != null ? _innerSlotProps$toolb : false;
43
43
  var _usePicker = usePicker(_extends({}, pickerParams, {
44
44
  props: props,
45
45
  inputRef: internalInputRef,
@@ -53,8 +53,8 @@ export var useStaticPicker = function useStaticPicker(_ref2) {
53
53
  children: /*#__PURE__*/_jsx(Layout, _extends({}, layoutProps, slotProps == null ? void 0 : slotProps.layout, {
54
54
  slots: slots,
55
55
  slotProps: slotProps,
56
- sx: [].concat(_toConsumableArray(Array.isArray(sx) ? sx : [sx]), _toConsumableArray(Array.isArray(slotProps == null ? void 0 : (_slotProps$layout = slotProps.layout) == null ? void 0 : _slotProps$layout.sx) ? slotProps.layout.sx : [slotProps == null ? void 0 : (_slotProps$layout2 = slotProps.layout) == null ? void 0 : _slotProps$layout2.sx])),
57
- className: clsx(className, slotProps == null ? void 0 : (_slotProps$layout3 = slotProps.layout) == null ? void 0 : _slotProps$layout3.className),
56
+ sx: [].concat(_toConsumableArray(Array.isArray(sx) ? sx : [sx]), _toConsumableArray(Array.isArray(slotProps == null || (_slotProps$layout = slotProps.layout) == null ? void 0 : _slotProps$layout.sx) ? slotProps.layout.sx : [slotProps == null || (_slotProps$layout2 = slotProps.layout) == null ? void 0 : _slotProps$layout2.sx])),
57
+ className: clsx(className, slotProps == null || (_slotProps$layout3 = slotProps.layout) == null ? void 0 : _slotProps$layout3.className),
58
58
  ref: ref,
59
59
  children: renderCurrentView()
60
60
  }))
@@ -9,7 +9,7 @@ import { buildWarning } from '../internals/utils/warning';
9
9
  defaultDayjs.extend(customParseFormatPlugin);
10
10
  defaultDayjs.extend(localizedFormatPlugin);
11
11
  defaultDayjs.extend(isBetweenPlugin);
12
- const localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale with `require('dayjs/locale/{localeUsed}')`", 'fallback on English locale']);
12
+ const localeNotFoundWarning = buildWarning(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale from 'dayjs/locale/{localeUsed}'", 'fallback on English locale']);
13
13
  const formatTokenMap = {
14
14
  // Year
15
15
  YY: 'year',
@@ -213,7 +213,7 @@ export const DigitalClock = /*#__PURE__*/React.forwardRef(function DigitalClock(
213
213
  const startOfDay = utils.startOfDay(valueOrReferenceDate);
214
214
  return [startOfDay, ...Array.from({
215
215
  length: Math.ceil(24 * 60 / timeStep) - 1
216
- }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1))), utils.endOfDay(valueOrReferenceDate)];
216
+ }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1)))];
217
217
  }, [valueOrReferenceDate, timeStep, utils]);
218
218
  return /*#__PURE__*/_jsx(DigitalClockRoot, _extends({
219
219
  ref: handleRef,
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.10.0
2
+ * @mui/x-date-pickers v6.10.2
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -263,6 +263,14 @@ export const useFieldState = params => {
263
263
  const setTempAndroidValueStr = tempValueStrAndroid => setState(prev => _extends({}, prev, {
264
264
  tempValueStrAndroid
265
265
  }));
266
+ React.useEffect(() => {
267
+ const sections = getSectionsFromValue(state.value);
268
+ validateSections(sections, valueType);
269
+ setState(prevState => _extends({}, prevState, {
270
+ sections
271
+ }));
272
+ }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
273
+
266
274
  React.useEffect(() => {
267
275
  let shouldUpdate = false;
268
276
  if (!valueManager.areValuesEqual(utils, state.value, valueFromTheOutside)) {
@@ -279,14 +287,6 @@ export const useFieldState = params => {
279
287
  }
280
288
  }, [valueFromTheOutside]); // eslint-disable-line react-hooks/exhaustive-deps
281
289
 
282
- React.useEffect(() => {
283
- const sections = getSectionsFromValue(state.value);
284
- validateSections(sections, valueType);
285
- setState(prevState => _extends({}, prevState, {
286
- sections
287
- }));
288
- }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
289
-
290
290
  return {
291
291
  state,
292
292
  selectedSectionIndexes,
@@ -17,7 +17,7 @@ var _warning = require("../internals/utils/warning");
17
17
  _dayjs.default.extend(_customParseFormat.default);
18
18
  _dayjs.default.extend(_localizedFormat.default);
19
19
  _dayjs.default.extend(_isBetween.default);
20
- const localeNotFoundWarning = (0, _warning.buildWarning)(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale with `require('dayjs/locale/{localeUsed}')`", 'fallback on English locale']);
20
+ const localeNotFoundWarning = (0, _warning.buildWarning)(['Your locale has not been found.', 'Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale', "Or you forget to import the locale from 'dayjs/locale/{localeUsed}'", 'fallback on English locale']);
21
21
  const formatTokenMap = {
22
22
  // Year
23
23
  YY: 'year',
@@ -222,7 +222,7 @@ const DigitalClock = /*#__PURE__*/React.forwardRef(function DigitalClock(inProps
222
222
  const startOfDay = utils.startOfDay(valueOrReferenceDate);
223
223
  return [startOfDay, ...Array.from({
224
224
  length: Math.ceil(24 * 60 / timeStep) - 1
225
- }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1))), utils.endOfDay(valueOrReferenceDate)];
225
+ }, (_, index) => utils.addMinutes(startOfDay, timeStep * (index + 1)))];
226
226
  }, [valueOrReferenceDate, timeStep, utils]);
227
227
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(DigitalClockRoot, (0, _extends2.default)({
228
228
  ref: handleRef,
package/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-date-pickers v6.10.0
2
+ * @mui/x-date-pickers v6.10.2
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -272,6 +272,14 @@ const useFieldState = params => {
272
272
  const setTempAndroidValueStr = tempValueStrAndroid => setState(prev => (0, _extends2.default)({}, prev, {
273
273
  tempValueStrAndroid
274
274
  }));
275
+ React.useEffect(() => {
276
+ const sections = getSectionsFromValue(state.value);
277
+ (0, _useField.validateSections)(sections, valueType);
278
+ setState(prevState => (0, _extends2.default)({}, prevState, {
279
+ sections
280
+ }));
281
+ }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
282
+
275
283
  React.useEffect(() => {
276
284
  let shouldUpdate = false;
277
285
  if (!valueManager.areValuesEqual(utils, state.value, valueFromTheOutside)) {
@@ -288,14 +296,6 @@ const useFieldState = params => {
288
296
  }
289
297
  }, [valueFromTheOutside]); // eslint-disable-line react-hooks/exhaustive-deps
290
298
 
291
- React.useEffect(() => {
292
- const sections = getSectionsFromValue(state.value);
293
- (0, _useField.validateSections)(sections, valueType);
294
- setState(prevState => (0, _extends2.default)({}, prevState, {
295
- sections
296
- }));
297
- }, [format, utils.locale]); // eslint-disable-line react-hooks/exhaustive-deps
298
-
299
299
  return {
300
300
  state,
301
301
  selectedSectionIndexes,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/x-date-pickers",
3
- "version": "6.10.0",
3
+ "version": "6.10.2",
4
4
  "description": "The community edition of the date picker components (MUI X).",
5
5
  "author": "MUI Team",
6
6
  "main": "./node/index.js",
@@ -33,8 +33,8 @@
33
33
  "directory": "packages/x-date-pickers"
34
34
  },
35
35
  "dependencies": {
36
- "@babel/runtime": "^7.22.5",
37
- "@mui/utils": "^5.13.6",
36
+ "@babel/runtime": "^7.22.6",
37
+ "@mui/utils": "^5.13.7",
38
38
  "@types/react-transition-group": "^4.4.6",
39
39
  "clsx": "^1.2.1",
40
40
  "prop-types": "^15.8.1",