@mui/x-date-pickers-pro 7.0.0-alpha.7 → 7.0.0-alpha.8
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/AdapterDateFnsV3/index.d.ts +1 -0
- package/AdapterDateFnsV3/index.js +1 -0
- package/AdapterDateFnsV3/package.json +6 -0
- package/CHANGELOG.md +175 -49
- package/DateRangeCalendar/DateRangeCalendar.types.d.ts +2 -1
- package/DateRangeCalendar/useDragRange.d.ts +1 -1
- package/DateRangePicker/DateRangePickerToolbar.d.ts +1 -1
- package/DateRangePicker/shared.d.ts +1 -2
- package/MultiInputDateRangeField/MultiInputDateRangeField.types.d.ts +1 -2
- package/MultiInputDateTimeRangeField/MultiInputDateTimeRangeField.types.d.ts +1 -2
- package/MultiInputTimeRangeField/MultiInputTimeRangeField.types.d.ts +1 -2
- package/SingleInputDateTimeRangeField/SingleInputDateTimeRangeField.types.d.ts +1 -1
- package/SingleInputTimeRangeField/SingleInputTimeRangeField.types.d.ts +1 -1
- package/dateRangeViewRenderers/dateRangeViewRenderers.d.ts +1 -1
- package/index.d.ts +0 -1
- package/index.js +1 -1
- package/internals/hooks/useDesktopRangePicker/useDesktopRangePicker.d.ts +1 -1
- package/internals/hooks/useDesktopRangePicker/useDesktopRangePicker.types.d.ts +3 -3
- package/internals/hooks/useEnrichedRangePickerFieldProps.d.ts +3 -3
- package/internals/hooks/useMobileRangePicker/useMobileRangePicker.d.ts +1 -1
- package/internals/hooks/useMobileRangePicker/useMobileRangePicker.types.d.ts +3 -3
- package/internals/hooks/useRangePosition.d.ts +1 -1
- package/internals/hooks/useStaticRangePicker/useStaticRangePicker.d.ts +1 -1
- package/internals/hooks/useStaticRangePicker/useStaticRangePicker.types.d.ts +2 -3
- package/internals/models/dateRange.d.ts +1 -2
- package/internals/models/dateTimeRange.d.ts +1 -2
- package/internals/models/index.d.ts +0 -1
- package/internals/models/index.js +0 -1
- package/internals/models/timeRange.d.ts +1 -2
- package/internals/utils/date-range-manager.d.ts +1 -1
- package/internals/utils/date-utils.d.ts +1 -1
- package/internals/utils/releaseInfo.js +1 -1
- package/internals/utils/validation/validateDateRange.d.ts +2 -2
- package/internals/utils/validation/validateDateTimeRange.d.ts +1 -2
- package/internals/utils/validation/validateTimeRange.d.ts +1 -2
- package/internals/utils/valueManagers.d.ts +1 -2
- package/internals/utils/valueManagers.js +1 -1
- package/legacy/AdapterDateFnsV3/index.js +1 -0
- package/legacy/index.js +1 -1
- package/legacy/internals/models/index.js +0 -1
- package/legacy/internals/utils/releaseInfo.js +1 -1
- package/legacy/internals/utils/valueManagers.js +1 -1
- package/legacy/models/index.js +1 -0
- package/models/index.d.ts +1 -0
- package/models/index.js +1 -0
- package/modern/AdapterDateFnsV3/index.js +1 -0
- package/modern/index.js +1 -1
- package/modern/internals/models/index.js +0 -1
- package/modern/internals/utils/releaseInfo.js +1 -1
- package/modern/internals/utils/valueManagers.js +1 -1
- package/modern/models/index.js +1 -0
- package/node/AdapterDateFnsV3/index.js +12 -0
- package/node/index.js +1 -1
- package/node/internals/models/index.js +0 -11
- package/node/internals/utils/releaseInfo.js +1 -1
- package/node/internals/utils/valueManagers.js +1 -1
- package/node/models/index.js +11 -0
- package/package.json +4 -4
- /package/{internals → legacy}/models/range.js +0 -0
- /package/{internals/models → models}/range.d.ts +0 -0
- /package/{legacy/internals/models → models}/range.js +0 -0
- /package/modern/{internals/models → models}/range.js +0 -0
- /package/node/{internals/models → models}/range.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,90 @@
|
|
|
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
|
+
## 7.0.0-alpha.8
|
|
7
|
+
|
|
8
|
+
_Jan 11, 2024_
|
|
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
|
+
- ⏰ Support date-fns v3 (#11659) @LukasTy
|
|
13
|
+
Pickers support both v2 and v3 of date-fns. For v3 use `AdapterDateFnsV3`.
|
|
14
|
+
```js
|
|
15
|
+
// with date-fns v2.x
|
|
16
|
+
import { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFns';
|
|
17
|
+
import de from 'date-fns/locale/de';
|
|
18
|
+
```
|
|
19
|
+
```js
|
|
20
|
+
// with date-fns v3.x
|
|
21
|
+
import { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
|
22
|
+
import { de } from 'date-fns/locale/de';
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
### Data Grid
|
|
26
|
+
|
|
27
|
+
#### Breaking changes
|
|
28
|
+
|
|
29
|
+
- The import path for locales has been changed:
|
|
30
|
+
|
|
31
|
+
```diff
|
|
32
|
+
-import { enUS } from '@mui/x-data-grid';
|
|
33
|
+
+import { enUS } from '@mui/x-data-grid/locales';
|
|
34
|
+
|
|
35
|
+
-import { enUS } from '@mui/x-data-grid-pro';
|
|
36
|
+
+import { enUS } from '@mui/x-data-grid-pro/locales';
|
|
37
|
+
|
|
38
|
+
-import { enUS } from '@mui/x-data-grid-premium';
|
|
39
|
+
+import { enUS } from '@mui/x-data-grid-premium/locales';
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
#### `@mui/x-data-grid@7.0.0-alpha.8`
|
|
43
|
+
|
|
44
|
+
- [DataGrid] Stop exporting locales from the package root (#11614) @cherniavskii
|
|
45
|
+
|
|
46
|
+
#### `@mui/x-data-grid-pro@7.0.0-alpha.8` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
47
|
+
|
|
48
|
+
Same changes as in `@mui/x-data-grid@7.0.0-alpha.8`.
|
|
49
|
+
|
|
50
|
+
#### `@mui/x-data-grid-premium@7.0.0-alpha.8` [](https://mui.com/r/x-premium-svg-link 'Premium plan')
|
|
51
|
+
|
|
52
|
+
Same changes as in `@mui/x-data-grid-pro@7.0.0-alpha.8`.
|
|
53
|
+
|
|
54
|
+
### Date Pickers
|
|
55
|
+
|
|
56
|
+
#### `@mui/x-date-pickers@7.0.0-alpha.8`
|
|
57
|
+
|
|
58
|
+
- [pickers] Add `date-fns@3.x` adapter (#11462) @LukasTy
|
|
59
|
+
- [pickers] Avoid deeper than 2nd level imports (#11588) @LukasTy
|
|
60
|
+
- [pickers] Fix clearable behavior blocking focus return to `OpenPickerButton` (#11642) @noraleonte
|
|
61
|
+
- [pickers] Move `DateRange` to `@mui/x-date-pickers-pro/models` (#11611) @flaviendelangle
|
|
62
|
+
- [l10n] Add missing Danish (da-DK) locale export (#11640) @etlos
|
|
63
|
+
|
|
64
|
+
#### `@mui/x-date-pickers-pro@7.0.0-alpha.8` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
65
|
+
|
|
66
|
+
Same changes as in `@mui/x-date-pickers@7.0.0-alpha.8`.
|
|
67
|
+
|
|
68
|
+
### Tree View / `@mui/x-tree-view@7.0.0-alpha.8`
|
|
69
|
+
|
|
70
|
+
- [tree view] Cleanup `onKeyDown` handler (#11481) @flaviendelangle
|
|
71
|
+
- [tree view] Define the parameters used by each plugin to avoid listing them in each component (#11473) @flaviendelangle
|
|
72
|
+
|
|
73
|
+
### Docs
|
|
74
|
+
|
|
75
|
+
- [docs] Fix parsing of `x-date-pickers-pro` demo adapter imports (#11628) @LukasTy
|
|
76
|
+
- [docs] Improve `git diff` format @oliviertassinari
|
|
77
|
+
- [docs] Push up the MUI X brand (#11533) @oliviertassinari
|
|
78
|
+
- [docs] Remove old data grid translation files (#11646) @cherniavskii
|
|
79
|
+
- [docs] Improve Server-side data grid docs (#11589) @oliviertassinari
|
|
80
|
+
- [docs] Improve charts landing page (#11570) @oliviertassinari
|
|
81
|
+
|
|
82
|
+
### Core
|
|
83
|
+
|
|
84
|
+
- [core] Lock `jsdom` version (#11652) @cherniavskii
|
|
85
|
+
- [core] Remove PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD (#11608) @oliviertassinari
|
|
86
|
+
- [core] Simplify isSsr logic (#11606) @oliviertassinari
|
|
87
|
+
- [core] Sync playwright cache between MUI X and Material UI (#11607) @oliviertassinari
|
|
88
|
+
- [core] Use MUI X official name in errors (#11645) @oliviertassinari
|
|
89
|
+
|
|
6
90
|
## 7.0.0-alpha.7
|
|
7
91
|
|
|
8
92
|
_Jan 5, 2024_
|
|
@@ -28,7 +112,7 @@ We'd like to offer a big thanks to the 7 contributors who made this release poss
|
|
|
28
112
|
label: 'Node 2',
|
|
29
113
|
},
|
|
30
114
|
];
|
|
31
|
-
|
|
115
|
+
|
|
32
116
|
<RichTreeView
|
|
33
117
|
items={MUI_X_PRODUCTS}
|
|
34
118
|
defaultCollapseIcon={<ExpandMoreIcon />}
|
|
@@ -88,10 +172,10 @@ Same changes as in `@mui/x-date-pickers@7.0.0-alpha.7`.
|
|
|
88
172
|
<TreeView
|
|
89
173
|
- onNodeToggle={handleExpansionChange}
|
|
90
174
|
+ onExpandedNodesChange={handleExpansionChange}
|
|
91
|
-
|
|
175
|
+
|
|
92
176
|
- expanded={expandedNodes}
|
|
93
177
|
+ expandedNodes={expandedNodes}
|
|
94
|
-
|
|
178
|
+
|
|
95
179
|
- defaultExpanded={defaultExpandedNodes}
|
|
96
180
|
+ defaultExpandedNodes={defaultExpandedNodes}
|
|
97
181
|
/>
|
|
@@ -274,10 +358,10 @@ Same changes as in `@mui/x-data-grid-pro@7.0.0-alpha.5`.
|
|
|
274
358
|
The `SlotsComponent` suffix has been replaced with `Slots` and `SlotsComponentsProps` with `SlotProps`.
|
|
275
359
|
|
|
276
360
|
```diff
|
|
277
|
-
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
+
|
|
361
|
+
-DateCalendarSlotsComponent
|
|
362
|
+
-DateCalendarSlotsComponentsProps
|
|
363
|
+
+DateCalendarSlots
|
|
364
|
+
+DateCalendarSlotProps
|
|
281
365
|
```
|
|
282
366
|
|
|
283
367
|
- Move `inputRef` inside the props passed to the field hooks
|
|
@@ -285,26 +369,26 @@ The `SlotsComponent` suffix has been replaced with `Slots` and `SlotsComponentsP
|
|
|
285
369
|
The field hooks now only receive the props instead of an object containing both the props and the `inputRef`.
|
|
286
370
|
|
|
287
371
|
```diff
|
|
288
|
-
-
|
|
289
|
-
-
|
|
290
|
-
+
|
|
372
|
+
-const { inputRef, ...otherProps } = props
|
|
373
|
+
-const fieldResponse = useDateField({ props: otherProps, inputRef });
|
|
374
|
+
+const fieldResponse = useDateField(props);
|
|
291
375
|
```
|
|
292
376
|
|
|
293
377
|
If you are using a multi input range field hook, the same applies to `startInputRef` and `endInputRef` params
|
|
294
378
|
|
|
295
379
|
```diff
|
|
296
|
-
-
|
|
297
|
-
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
-
|
|
302
|
-
-
|
|
303
|
-
-
|
|
304
|
-
-
|
|
305
|
-
+
|
|
306
|
-
+
|
|
307
|
-
|
|
380
|
+
-const { inputRef: startInputRef, ...otherStartTextFieldProps } = startTextFieldProps
|
|
381
|
+
-const { inputRef: endInputRef, ...otherEndTextFieldProps } = endTextFieldProps
|
|
382
|
+
|
|
383
|
+
const fieldResponse = useMultiInputDateRangeField({
|
|
384
|
+
sharedProps,
|
|
385
|
+
- startTextFieldProps: otherStartTextFieldProps,
|
|
386
|
+
- endTextFieldProps: otherEndTextFieldProps,
|
|
387
|
+
- startInputRef
|
|
388
|
+
- endInputRef,
|
|
389
|
+
+ startTextFieldProps,
|
|
390
|
+
+ endTextFieldProps
|
|
391
|
+
});
|
|
308
392
|
```
|
|
309
393
|
|
|
310
394
|
- Rename the ref returned by the field hooks to `inputRef`
|
|
@@ -313,26 +397,26 @@ The `SlotsComponent` suffix has been replaced with `Slots` and `SlotsComponentsP
|
|
|
313
397
|
This ref was previously named `ref` and has been renamed `inputRef` for extra clarity.
|
|
314
398
|
|
|
315
399
|
```diff
|
|
316
|
-
|
|
400
|
+
const fieldResponse = useDateField(props);
|
|
317
401
|
|
|
318
|
-
-
|
|
319
|
-
+
|
|
402
|
+
-return <input ref={fieldResponse.ref} />
|
|
403
|
+
+return <input ref={fieldResponse.inputRef} />
|
|
320
404
|
```
|
|
321
405
|
|
|
322
406
|
If you are using a multi input range field hook, the same applies to the ref in the `startDate` and `endDate` objects
|
|
323
407
|
|
|
324
408
|
```diff
|
|
325
|
-
|
|
409
|
+
const fieldResponse = useDateField(props);
|
|
326
410
|
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
-
|
|
330
|
-
+
|
|
331
|
-
|
|
332
|
-
-
|
|
333
|
-
+
|
|
334
|
-
|
|
335
|
-
|
|
411
|
+
return (
|
|
412
|
+
<div>
|
|
413
|
+
- <input ref={fieldResponse.startDate.ref} />
|
|
414
|
+
+ <input ref={fieldResponse.startDate.inputRef} />
|
|
415
|
+
<span>–</span>
|
|
416
|
+
- <input ref={fieldResponse.endDate.ref} />
|
|
417
|
+
+ <input ref={fieldResponse.endDate.inputRef} />
|
|
418
|
+
</div>
|
|
419
|
+
)
|
|
336
420
|
```
|
|
337
421
|
|
|
338
422
|
- Restructure the API of `useClearableField`
|
|
@@ -342,23 +426,23 @@ The `SlotsComponent` suffix has been replaced with `Slots` and `SlotsComponentsP
|
|
|
342
426
|
You should now be able to directly pass the returned value from your field hook (e.g: `useDateField`) to `useClearableField`
|
|
343
427
|
|
|
344
428
|
```diff
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
-
|
|
348
|
-
-
|
|
349
|
-
-
|
|
350
|
-
-
|
|
351
|
-
-
|
|
352
|
-
-
|
|
353
|
-
-
|
|
354
|
-
-
|
|
355
|
-
-
|
|
429
|
+
const fieldResponse = useDateField(props);
|
|
430
|
+
|
|
431
|
+
-const { InputProps, onClear, clearable, slots, slotProps, ...otherFieldProps } = fieldResponse
|
|
432
|
+
-const { InputProps: ProcessedInputProps, fieldProps: processedFieldProps } = useClearableField({
|
|
433
|
+
- fieldProps: otherFieldProps,
|
|
434
|
+
- InputProps,
|
|
435
|
+
- clearable,
|
|
436
|
+
- onClear,
|
|
437
|
+
- slots,
|
|
438
|
+
- slotProps,
|
|
439
|
+
-});
|
|
356
440
|
-
|
|
357
|
-
-
|
|
441
|
+
- return <MyCustomTextField {...processedFieldProps} InputProps={ProcessedInputProps} />
|
|
358
442
|
|
|
359
|
-
+
|
|
443
|
+
+const processedFieldProps = useClearableField(fieldResponse);
|
|
360
444
|
+
|
|
361
|
-
+
|
|
445
|
+
+return <MyCustomTextField {...processedFieldProps} />
|
|
362
446
|
```
|
|
363
447
|
|
|
364
448
|
#### `@mui/x-date-pickers@7.0.0-alpha.5`
|
|
@@ -1340,6 +1424,48 @@ Here is an example of the renaming for the `<ChartsTooltip />` component.
|
|
|
1340
1424
|
- [core] Update release instructions as per v7 configuration (#10962) @MBilalShafi
|
|
1341
1425
|
- [license] Correctly throw errors (#10924) @oliviertassinari
|
|
1342
1426
|
|
|
1427
|
+
## 6.19.0
|
|
1428
|
+
|
|
1429
|
+
_Jan 11, 2024_
|
|
1430
|
+
|
|
1431
|
+
We'd like to offer a big thanks to the 3 contributors who made this release possible. Here are some highlights ✨:
|
|
1432
|
+
|
|
1433
|
+
- ⏰ Support date-fns v3 (#11659) @LukasTy
|
|
1434
|
+
Pickers support both v2 and v3 of date-fns. For v3 use `AdapterDateFnsV3`.
|
|
1435
|
+
```js
|
|
1436
|
+
// with date-fns v2.x
|
|
1437
|
+
import { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFns';
|
|
1438
|
+
import de from 'date-fns/locale/de';
|
|
1439
|
+
```
|
|
1440
|
+
```js
|
|
1441
|
+
// with date-fns v3.x
|
|
1442
|
+
import { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
|
1443
|
+
import { de } from 'date-fns/locale/de';
|
|
1444
|
+
```
|
|
1445
|
+
|
|
1446
|
+
### Date Pickers
|
|
1447
|
+
|
|
1448
|
+
#### `@mui/x-date-pickers@6.19.0`
|
|
1449
|
+
|
|
1450
|
+
- [pickers] Add date-fns@3.x adapter (#11659) @LukasTy
|
|
1451
|
+
- [pickers] Fix clearable behavior blocking focus return to `OpenPickerButton` (#11643) @noraleonte
|
|
1452
|
+
- [l10n] Add missing Danish (da-DK) locale export (#11641) @etlos
|
|
1453
|
+
|
|
1454
|
+
#### `@mui/x-date-pickers-pro@6.19.0` [](https://mui.com/r/x-pro-svg-link 'Pro plan')
|
|
1455
|
+
|
|
1456
|
+
Same changes as in `@mui/x-date-pickers@6.19.0`.
|
|
1457
|
+
|
|
1458
|
+
### Docs
|
|
1459
|
+
|
|
1460
|
+
- [docs] Add missing component @oliviertassinari
|
|
1461
|
+
- [docs] Fix parsing of `x-date-pickers-pro` demo adapter imports (#11637) @LukasTy
|
|
1462
|
+
- [docs] Push up the MUI X brand (#11533) @oliviertassinari
|
|
1463
|
+
- [docs] Improve Server-side data grid docs (#11589) @oliviertassinari
|
|
1464
|
+
- [docs] Add demo to the charts overview page (#11586) @danilo-leal
|
|
1465
|
+
- [docs] Fix 404 links in the docs @oliviertassinari
|
|
1466
|
+
- [docs] Improve landing page (#11570) @oliviertassinari
|
|
1467
|
+
- [docs] Give a general revision to the docs (#11249) @danilo-leal
|
|
1468
|
+
|
|
1343
1469
|
## 6.18.7
|
|
1344
1470
|
|
|
1345
1471
|
_Jan 5, 2024_
|
|
@@ -5,7 +5,8 @@ import { Theme } from '@mui/material/styles';
|
|
|
5
5
|
import { TimezoneProps } from '@mui/x-date-pickers/models';
|
|
6
6
|
import { PickersCalendarHeader, PickersCalendarHeaderProps, PickersCalendarHeaderSlots, PickersCalendarHeaderSlotProps } from '@mui/x-date-pickers/PickersCalendarHeader';
|
|
7
7
|
import { BaseDateValidationProps, DefaultizedProps, ExportedDayCalendarProps, DayCalendarSlots, DayCalendarSlotProps, PickersArrowSwitcherSlots, PickersArrowSwitcherSlotProps, PickerSelectionState, DayCalendarProps, ExportedUseViewsOptions } from '@mui/x-date-pickers/internals';
|
|
8
|
-
import {
|
|
8
|
+
import { DayRangeValidationProps } from '../internals/models';
|
|
9
|
+
import { DateRange } from '../models';
|
|
9
10
|
import { DateRangeCalendarClasses } from './dateRangeCalendarClasses';
|
|
10
11
|
import { DateRangePickerDay, DateRangePickerDayProps } from '../DateRangePickerDay';
|
|
11
12
|
import { UseRangePositionProps } from '../internals/hooks/useRangePosition';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { MuiPickersAdapter, PickersTimezone } from '@mui/x-date-pickers/models';
|
|
3
3
|
import { DateRangePosition } from './DateRangeCalendar.types';
|
|
4
|
-
import { DateRange } from '../
|
|
4
|
+
import { DateRange } from '../models';
|
|
5
5
|
interface UseDragRangeParams<TDate> {
|
|
6
6
|
disableDragEditing?: boolean;
|
|
7
7
|
utils: MuiPickersAdapter<TDate>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { BaseToolbarProps, ExportedBaseToolbarProps } from '@mui/x-date-pickers/internals';
|
|
3
|
-
import { DateRange } from '../
|
|
3
|
+
import { DateRange } from '../models';
|
|
4
4
|
import { UseRangePositionResponse } from '../internals/hooks/useRangePosition';
|
|
5
5
|
import { DateRangePickerToolbarClasses } from './dateRangePickerToolbarClasses';
|
|
6
6
|
export interface DateRangePickerToolbarProps<TDate> extends Omit<BaseToolbarProps<DateRange<TDate>, 'day'>, 'views' | 'view' | 'onViewChange' | 'onChange' | 'isLandscape'>, Pick<UseRangePositionResponse, 'rangePosition' | 'onRangePositionChange'> {
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { LocalizedComponent } from '@mui/x-date-pickers/locales';
|
|
3
3
|
import { DefaultizedProps, BaseDateValidationProps, BasePickerInputProps, PickerViewRendererLookup } from '@mui/x-date-pickers/internals';
|
|
4
|
-
import { DateRangeValidationError } from '../models';
|
|
5
|
-
import { DateRange } from '../internals/models';
|
|
4
|
+
import { DateRangeValidationError, DateRange } from '../models';
|
|
6
5
|
import { DateRangeCalendarSlots, DateRangeCalendarSlotProps, ExportedDateRangeCalendarProps } from '../DateRangeCalendar';
|
|
7
6
|
import { DateRangePickerToolbarProps, ExportedDateRangePickerToolbarProps } from './DateRangePickerToolbar';
|
|
8
7
|
import { DateRangeViewRendererProps } from '../dateRangeViewRenderers';
|
|
@@ -5,10 +5,9 @@ import Stack, { StackProps } from '@mui/material/Stack';
|
|
|
5
5
|
import TextField from '@mui/material/TextField';
|
|
6
6
|
import { FieldRef } from '@mui/x-date-pickers/models';
|
|
7
7
|
import { UseDateRangeFieldProps } from '../internals/models/dateRange';
|
|
8
|
-
import { RangePosition } from '../internals/models/range';
|
|
9
8
|
import { UseMultiInputRangeFieldParams } from '../internals/hooks/useMultiInputRangeField/useMultiInputRangeField.types';
|
|
10
9
|
import { RangeFieldSection } from '../internals/models/fields';
|
|
11
|
-
import { MultiInputRangeFieldClasses } from '../models';
|
|
10
|
+
import { MultiInputRangeFieldClasses, RangePosition } from '../models';
|
|
12
11
|
export type UseMultiInputDateRangeFieldParams<TDate, TTextFieldSlotProps extends {}> = UseMultiInputRangeFieldParams<UseMultiInputDateRangeFieldProps<TDate>, TTextFieldSlotProps>;
|
|
13
12
|
export interface UseMultiInputDateRangeFieldProps<TDate> extends Omit<UseDateRangeFieldProps<TDate>, 'unstableFieldRef' | 'clearable' | 'onClear'> {
|
|
14
13
|
unstableStartFieldRef?: React.Ref<FieldRef<RangeFieldSection>>;
|
|
@@ -5,10 +5,9 @@ import Typography from '@mui/material/Typography';
|
|
|
5
5
|
import Stack, { StackProps } from '@mui/material/Stack';
|
|
6
6
|
import TextField from '@mui/material/TextField';
|
|
7
7
|
import { UseDateTimeRangeFieldDefaultizedProps, UseDateTimeRangeFieldProps } from '../internals/models/dateTimeRange';
|
|
8
|
-
import { RangePosition } from '../internals/models/range';
|
|
9
8
|
import { RangeFieldSection } from '../internals/models/fields';
|
|
10
9
|
import { UseMultiInputRangeFieldParams } from '../internals/hooks/useMultiInputRangeField/useMultiInputRangeField.types';
|
|
11
|
-
import { MultiInputRangeFieldClasses } from '../models';
|
|
10
|
+
import { MultiInputRangeFieldClasses, RangePosition } from '../models';
|
|
12
11
|
export type UseMultiInputDateTimeRangeFieldParams<TDate, TTextFieldSlotProps extends {}> = UseMultiInputRangeFieldParams<UseMultiInputDateTimeRangeFieldProps<TDate>, TTextFieldSlotProps>;
|
|
13
12
|
export interface UseMultiInputDateTimeRangeFieldProps<TDate> extends Omit<UseDateTimeRangeFieldProps<TDate>, 'unstableFieldRef' | 'clearable' | 'onClear'> {
|
|
14
13
|
unstableStartFieldRef?: React.Ref<FieldRef<RangeFieldSection>>;
|
|
@@ -5,10 +5,9 @@ import Stack, { StackProps } from '@mui/material/Stack';
|
|
|
5
5
|
import TextField from '@mui/material/TextField';
|
|
6
6
|
import { FieldRef } from '@mui/x-date-pickers/models';
|
|
7
7
|
import { UseTimeRangeFieldDefaultizedProps, UseTimeRangeFieldProps } from '../internals/models/timeRange';
|
|
8
|
-
import { RangePosition } from '../internals/models/range';
|
|
9
8
|
import { UseMultiInputRangeFieldParams } from '../internals/hooks/useMultiInputRangeField/useMultiInputRangeField.types';
|
|
10
9
|
import { RangeFieldSection } from '../internals/models/fields';
|
|
11
|
-
import { MultiInputRangeFieldClasses } from '../models';
|
|
10
|
+
import { MultiInputRangeFieldClasses, RangePosition } from '../models';
|
|
12
11
|
export type UseMultiInputTimeRangeFieldParams<TDate, TTextFieldSlotProps extends {}> = UseMultiInputRangeFieldParams<UseMultiInputTimeRangeFieldProps<TDate>, TTextFieldSlotProps>;
|
|
13
12
|
export interface UseMultiInputTimeRangeFieldProps<TDate> extends Omit<UseTimeRangeFieldProps<TDate>, 'unstableFieldRef' | 'clearable' | 'onClear'> {
|
|
14
13
|
unstableStartFieldRef?: React.Ref<FieldRef<RangeFieldSection>>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { SlotComponentProps } from '@mui/base/utils';
|
|
3
3
|
import TextField from '@mui/material/TextField';
|
|
4
|
-
import { FieldsTextFieldProps } from '@mui/x-date-pickers/internals
|
|
4
|
+
import { FieldsTextFieldProps } from '@mui/x-date-pickers/internals';
|
|
5
5
|
import { UseClearableFieldSlots, UseClearableFieldSlotProps } from '@mui/x-date-pickers/hooks';
|
|
6
6
|
import { UseDateTimeRangeFieldDefaultizedProps, UseDateTimeRangeFieldProps } from '../internals/models';
|
|
7
7
|
export interface UseSingleInputDateTimeRangeFieldProps<TDate> extends UseDateTimeRangeFieldProps<TDate> {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { SlotComponentProps } from '@mui/base/utils';
|
|
3
3
|
import TextField from '@mui/material/TextField';
|
|
4
|
-
import { FieldsTextFieldProps } from '@mui/x-date-pickers/internals
|
|
4
|
+
import { FieldsTextFieldProps } from '@mui/x-date-pickers/internals';
|
|
5
5
|
import { UseClearableFieldSlots, UseClearableFieldSlotProps } from '@mui/x-date-pickers/hooks';
|
|
6
6
|
import { UseTimeRangeFieldDefaultizedProps, UseTimeRangeFieldProps } from '../internals/models';
|
|
7
7
|
export interface UseSingleInputTimeRangeFieldProps<TDate> extends UseTimeRangeFieldProps<TDate> {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals
|
|
2
|
+
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { DateRangeCalendarProps } from '../DateRangeCalendar';
|
|
4
4
|
export interface DateRangeViewRendererProps<TDate, TView extends DateOrTimeViewWithMeridiem> extends DateRangeCalendarProps<TDate> {
|
|
5
5
|
view: TView;
|
package/index.d.ts
CHANGED
|
@@ -14,6 +14,5 @@ export * from './DesktopDateRangePicker';
|
|
|
14
14
|
export * from './MobileDateRangePicker';
|
|
15
15
|
export * from './StaticDateRangePicker';
|
|
16
16
|
export * from './dateRangeViewRenderers';
|
|
17
|
-
export type { DateRange, RangePosition } from './internals/models/range';
|
|
18
17
|
export type { UseDateRangeFieldProps } from './internals/models/dateRange';
|
|
19
18
|
export * from './models';
|
package/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals
|
|
2
|
+
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { UseDesktopRangePickerParams, UseDesktopRangePickerProps } from './useDesktopRangePicker.types';
|
|
4
4
|
export declare const useDesktopRangePicker: <TDate, TView extends DateOrTimeViewWithMeridiem, TExternalProps extends UseDesktopRangePickerProps<TDate, TView, any, TExternalProps>>({ props, ...pickerParams }: UseDesktopRangePickerParams<TDate, TView, TExternalProps>) => {
|
|
5
5
|
renderPicker: () => React.JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { UsePickerParams, BasePickerProps, PickersPopperSlots, PickersPopperSlotProps, ExportedBaseToolbarProps, UsePickerViewsProps, BaseNonStaticPickerProps, UsePickerValueNonStaticProps, UsePickerViewsNonStaticProps } from '@mui/x-date-pickers/internals';
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals/models';
|
|
1
|
+
import { UsePickerParams, BasePickerProps, PickersPopperSlots, PickersPopperSlotProps, ExportedBaseToolbarProps, UsePickerViewsProps, BaseNonStaticPickerProps, UsePickerValueNonStaticProps, UsePickerViewsNonStaticProps, DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
2
|
import { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps } from '@mui/x-date-pickers/PickersLayout';
|
|
4
|
-
import {
|
|
3
|
+
import { RangeFieldSection, BaseRangeNonStaticPickerProps } from '../../models';
|
|
4
|
+
import { DateRange } from '../../../models';
|
|
5
5
|
import { UseRangePositionProps, UseRangePositionResponse } from '../useRangePosition';
|
|
6
6
|
import { RangePickerFieldSlots, RangePickerFieldSlotProps } from '../useEnrichedRangePickerFieldProps';
|
|
7
7
|
export interface UseDesktopRangePickerSlots<TDate, TView extends DateOrTimeViewWithMeridiem> extends PickersPopperSlots, ExportedPickersLayoutSlots<DateRange<TDate>, TDate, TView>, RangePickerFieldSlots {
|
|
@@ -5,10 +5,10 @@ import TextField, { TextFieldProps } from '@mui/material/TextField';
|
|
|
5
5
|
import { SlotComponentProps } from '@mui/base/utils';
|
|
6
6
|
import { BaseSingleInputFieldProps } from '@mui/x-date-pickers/models';
|
|
7
7
|
import { UseClearableFieldSlots, UseClearableFieldSlotProps } from '@mui/x-date-pickers/hooks';
|
|
8
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals/models';
|
|
9
8
|
import { PickersInputLocaleText } from '@mui/x-date-pickers/locales';
|
|
10
|
-
import { BaseFieldProps, UsePickerResponse, WrapperVariant, UsePickerProps } from '@mui/x-date-pickers/internals';
|
|
11
|
-
import { BaseMultiInputFieldProps,
|
|
9
|
+
import { BaseFieldProps, UsePickerResponse, WrapperVariant, UsePickerProps, DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
10
|
+
import { BaseMultiInputFieldProps, RangeFieldSection, UseDateRangeFieldProps } from '../models';
|
|
11
|
+
import { DateRange, RangePosition } from '../../models';
|
|
12
12
|
import { UseRangePositionResponse } from './useRangePosition';
|
|
13
13
|
export interface RangePickerFieldSlots extends UseClearableFieldSlots {
|
|
14
14
|
field: React.ElementType;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals
|
|
2
|
+
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { UseMobileRangePickerParams, UseMobileRangePickerProps } from './useMobileRangePicker.types';
|
|
4
4
|
export declare const useMobileRangePicker: <TDate, TView extends DateOrTimeViewWithMeridiem, TExternalProps extends UseMobileRangePickerProps<TDate, TView, any, TExternalProps>>({ props, ...pickerParams }: UseMobileRangePickerParams<TDate, TView, TExternalProps>) => {
|
|
5
5
|
renderPicker: () => React.JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { UsePickerParams, BasePickerProps, PickersModalDialogSlots, PickersModalDialogSlotProps, ExportedBaseToolbarProps, UsePickerViewsProps, BaseNonStaticPickerProps, UsePickerValueNonStaticProps, UsePickerViewsNonStaticProps } from '@mui/x-date-pickers/internals';
|
|
1
|
+
import { UsePickerParams, BasePickerProps, PickersModalDialogSlots, PickersModalDialogSlotProps, ExportedBaseToolbarProps, UsePickerViewsProps, BaseNonStaticPickerProps, UsePickerValueNonStaticProps, UsePickerViewsNonStaticProps, DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
2
2
|
import { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps } from '@mui/x-date-pickers/PickersLayout';
|
|
3
|
-
import {
|
|
4
|
-
import { DateRange
|
|
3
|
+
import { RangeFieldSection, BaseRangeNonStaticPickerProps } from '../../models';
|
|
4
|
+
import { DateRange } from '../../../models';
|
|
5
5
|
import { UseRangePositionProps, UseRangePositionResponse } from '../useRangePosition';
|
|
6
6
|
import { RangePickerFieldSlots, RangePickerFieldSlotProps } from '../useEnrichedRangePickerFieldProps';
|
|
7
7
|
export interface UseMobileRangePickerSlots<TDate, TView extends DateOrTimeViewWithMeridiem> extends PickersModalDialogSlots, ExportedPickersLayoutSlots<DateRange<TDate>, TDate, TView>, RangePickerFieldSlots {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { FieldRef } from '@mui/x-date-pickers/models';
|
|
3
|
-
import { RangePosition } from '
|
|
3
|
+
import { RangePosition } from '../../models';
|
|
4
4
|
import { RangeFieldSection } from '../models/fields';
|
|
5
5
|
export interface UseRangePositionProps {
|
|
6
6
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals
|
|
2
|
+
import { DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { UseStaticRangePickerParams, UseStaticRangePickerProps } from './useStaticRangePicker.types';
|
|
4
4
|
/**
|
|
5
5
|
* Hook managing all the range static pickers:
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { BasePickerProps, UsePickerParams, ExportedBaseToolbarProps, StaticOnlyPickerProps } from '@mui/x-date-pickers/internals';
|
|
2
|
+
import { BasePickerProps, UsePickerParams, ExportedBaseToolbarProps, StaticOnlyPickerProps, DateOrTimeViewWithMeridiem } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { ExportedPickersLayoutSlots, ExportedPickersLayoutSlotProps } from '@mui/x-date-pickers/PickersLayout';
|
|
4
|
-
import {
|
|
5
|
-
import { DateRange } from '../../models/range';
|
|
4
|
+
import { DateRange } from '../../../models';
|
|
6
5
|
import { UseRangePositionProps } from '../useRangePosition';
|
|
7
6
|
import { RangeFieldSection } from '../../models/fields';
|
|
8
7
|
export interface UseStaticRangePickerSlots<TDate, TView extends DateOrTimeViewWithMeridiem> extends ExportedPickersLayoutSlots<DateRange<TDate>, TDate, TView> {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { BaseDateValidationProps, DefaultizedProps, MakeOptional, UseFieldInternalProps } from '@mui/x-date-pickers/internals';
|
|
2
|
-
import { DateRange } from '
|
|
3
|
-
import type { DateRangeValidationError } from '../../models';
|
|
2
|
+
import type { DateRangeValidationError, DateRange } from '../../models';
|
|
4
3
|
import { RangeFieldSection } from './fields';
|
|
5
4
|
/**
|
|
6
5
|
* Props used to validate a day value in range pickers.
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { BaseDateValidationProps, TimeValidationProps, DefaultizedProps, MakeOptional, UseFieldInternalProps, DateTimeValidationProps } from '@mui/x-date-pickers/internals';
|
|
2
2
|
import { BaseRangeProps, DayRangeValidationProps } from './dateRange';
|
|
3
|
-
import { DateRange } from '
|
|
4
|
-
import { DateTimeRangeValidationError } from '../../models';
|
|
3
|
+
import { DateTimeRangeValidationError, DateRange } from '../../models';
|
|
5
4
|
import { RangeFieldSection } from './fields';
|
|
6
5
|
export interface UseDateTimeRangeFieldProps<TDate> extends MakeOptional<UseFieldInternalProps<DateRange<TDate>, TDate, RangeFieldSection, DateTimeRangeValidationError>, 'format'>, DayRangeValidationProps<TDate>, TimeValidationProps<TDate>, BaseDateValidationProps<TDate>, DateTimeValidationProps<TDate>, BaseRangeProps {
|
|
7
6
|
/**
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { BaseTimeValidationProps, TimeValidationProps, DefaultizedProps, MakeOptional, UseFieldInternalProps } from '@mui/x-date-pickers/internals';
|
|
2
|
-
import { DateRange } from '
|
|
3
|
-
import { TimeRangeValidationError } from '../../models';
|
|
2
|
+
import { TimeRangeValidationError, DateRange } from '../../models';
|
|
4
3
|
import { BaseRangeProps } from './dateRange';
|
|
5
4
|
import { RangeFieldSection } from './fields';
|
|
6
5
|
export interface UseTimeRangeFieldProps<TDate> extends MakeOptional<UseFieldInternalProps<DateRange<TDate>, TDate, RangeFieldSection, TimeRangeValidationError>, 'format'>, TimeValidationProps<TDate>, BaseTimeValidationProps, BaseRangeProps {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MuiPickersAdapter } from '@mui/x-date-pickers/models';
|
|
2
|
-
import { DateRange, RangePosition } from '
|
|
2
|
+
import { DateRange, RangePosition } from '../../models';
|
|
3
3
|
interface CalculateRangeChangeOptions<TDate> {
|
|
4
4
|
utils: MuiPickersAdapter<TDate>;
|
|
5
5
|
range: DateRange<TDate>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MuiPickersAdapter } from '@mui/x-date-pickers/models';
|
|
2
|
-
import { DateRange, NonEmptyDateRange } from '
|
|
2
|
+
import { DateRange, NonEmptyDateRange } from '../../models';
|
|
3
3
|
export declare const isRangeValid: <TDate>(utils: MuiPickersAdapter<TDate, any>, range: DateRange<TDate> | null) => range is NonEmptyDateRange<TDate>;
|
|
4
4
|
export declare const isWithinRange: <TDate>(utils: MuiPickersAdapter<TDate, any>, day: TDate, range: DateRange<TDate> | null) => boolean;
|
|
5
5
|
export declare const isStartOfRange: <TDate>(utils: MuiPickersAdapter<TDate, any>, day: TDate, range: DateRange<TDate> | null) => boolean;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export const getReleaseInfo = () => {
|
|
3
|
-
const releaseInfo = "
|
|
3
|
+
const releaseInfo = "MTcwNDkyNzYwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TimezoneProps } from '@mui/x-date-pickers/models';
|
|
2
2
|
import { Validator, BaseDateValidationProps, DefaultizedProps } from '@mui/x-date-pickers/internals';
|
|
3
|
-
import {
|
|
4
|
-
import { DateRangeValidationError } from '../../../models';
|
|
3
|
+
import { DayRangeValidationProps } from '../../models';
|
|
4
|
+
import { DateRangeValidationError, DateRange } from '../../../models';
|
|
5
5
|
export interface DateRangeComponentValidationProps<TDate> extends DayRangeValidationProps<TDate>, Required<BaseDateValidationProps<TDate>>, DefaultizedProps<TimezoneProps, 'timezone'> {
|
|
6
6
|
}
|
|
7
7
|
export declare const validateDateRange: Validator<DateRange<any>, any, DateRangeValidationError, DateRangeComponentValidationProps<any>>;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { TimezoneProps } from '@mui/x-date-pickers/models';
|
|
2
2
|
import { Validator, BaseDateValidationProps, TimeValidationProps, DefaultizedProps } from '@mui/x-date-pickers/internals';
|
|
3
3
|
import { DayRangeValidationProps } from '../../models/dateRange';
|
|
4
|
-
import { DateRange } from '
|
|
5
|
-
import { DateTimeRangeValidationError } from '../../../models';
|
|
4
|
+
import { DateTimeRangeValidationError, DateRange } from '../../../models';
|
|
6
5
|
export interface DateTimeRangeComponentValidationProps<TDate> extends DayRangeValidationProps<TDate>, TimeValidationProps<TDate>, Required<BaseDateValidationProps<TDate>>, DefaultizedProps<TimezoneProps, 'timezone'> {
|
|
7
6
|
}
|
|
8
7
|
export declare const validateDateTimeRange: Validator<DateRange<any>, any, DateTimeRangeValidationError, DateTimeRangeComponentValidationProps<any>>;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { TimezoneProps } from '@mui/x-date-pickers/models';
|
|
2
2
|
import { Validator, BaseTimeValidationProps, DefaultizedProps } from '@mui/x-date-pickers/internals';
|
|
3
|
-
import { DateRange } from '
|
|
4
|
-
import { TimeRangeValidationError } from '../../../models';
|
|
3
|
+
import { TimeRangeValidationError, DateRange } from '../../../models';
|
|
5
4
|
export interface TimeRangeComponentValidationProps extends Required<BaseTimeValidationProps>, DefaultizedProps<TimezoneProps, 'timezone'> {
|
|
6
5
|
}
|
|
7
6
|
export declare const validateTimeRange: Validator<DateRange<any>, any, TimeRangeValidationError, TimeRangeComponentValidationProps>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { PickerValueManager, FieldValueManager } from '@mui/x-date-pickers/internals';
|
|
2
|
-
import { DateRange } from '
|
|
3
|
-
import type { DateRangeValidationError, DateTimeRangeValidationError, TimeRangeValidationError } from '../../models';
|
|
2
|
+
import type { DateRangeValidationError, DateTimeRangeValidationError, TimeRangeValidationError, DateRange } from '../../models';
|
|
4
3
|
import { RangeFieldSection } from '../models/fields';
|
|
5
4
|
export type RangePickerValueManager<TValue = [any, any], TDate = any, TError extends DateRangeValidationError | TimeRangeValidationError | DateTimeRangeValidationError = any> = PickerValueManager<TValue, TDate, TError>;
|
|
6
5
|
export declare const rangeValueManager: RangePickerValueManager;
|
|
@@ -29,7 +29,7 @@ export const rangeValueManager = {
|
|
|
29
29
|
const timezoneStart = value[0] == null || !utils.isValid(value[0]) ? null : utils.getTimezone(value[0]);
|
|
30
30
|
const timezoneEnd = value[1] == null || !utils.isValid(value[1]) ? null : utils.getTimezone(value[1]);
|
|
31
31
|
if (timezoneStart != null && timezoneEnd != null && timezoneStart !== timezoneEnd) {
|
|
32
|
-
throw new Error('MUI: The timezone of the start and the end date should be the same');
|
|
32
|
+
throw new Error('MUI X: The timezone of the start and the end date should be the same.');
|
|
33
33
|
}
|
|
34
34
|
return timezoneStart != null ? timezoneStart : timezoneEnd;
|
|
35
35
|
},
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
package/legacy/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export var getReleaseInfo = function getReleaseInfo() {
|
|
3
|
-
var releaseInfo = "
|
|
3
|
+
var releaseInfo = "MTcwNDkyNzYwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -41,7 +41,7 @@ export var rangeValueManager = {
|
|
|
41
41
|
var timezoneStart = value[0] == null || !utils.isValid(value[0]) ? null : utils.getTimezone(value[0]);
|
|
42
42
|
var timezoneEnd = value[1] == null || !utils.isValid(value[1]) ? null : utils.getTimezone(value[1]);
|
|
43
43
|
if (timezoneStart != null && timezoneEnd != null && timezoneStart !== timezoneEnd) {
|
|
44
|
-
throw new Error('MUI: The timezone of the start and the end date should be the same');
|
|
44
|
+
throw new Error('MUI X: The timezone of the start and the end date should be the same.');
|
|
45
45
|
}
|
|
46
46
|
return timezoneStart != null ? timezoneStart : timezoneEnd;
|
|
47
47
|
},
|
package/legacy/models/index.js
CHANGED
package/models/index.d.ts
CHANGED
package/models/index.js
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { AdapterDateFns } from '@mui/x-date-pickers/AdapterDateFnsV3';
|
package/modern/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ponyfillGlobal } from '@mui/utils';
|
|
2
2
|
export const getReleaseInfo = () => {
|
|
3
|
-
const releaseInfo = "
|
|
3
|
+
const releaseInfo = "MTcwNDkyNzYwMDAwMA==";
|
|
4
4
|
if (process.env.NODE_ENV !== 'production') {
|
|
5
5
|
// A simple hack to set the value in the test environment (has no build step).
|
|
6
6
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -29,7 +29,7 @@ export const rangeValueManager = {
|
|
|
29
29
|
const timezoneStart = value[0] == null || !utils.isValid(value[0]) ? null : utils.getTimezone(value[0]);
|
|
30
30
|
const timezoneEnd = value[1] == null || !utils.isValid(value[1]) ? null : utils.getTimezone(value[1]);
|
|
31
31
|
if (timezoneStart != null && timezoneEnd != null && timezoneStart !== timezoneEnd) {
|
|
32
|
-
throw new Error('MUI: The timezone of the start and the end date should be the same');
|
|
32
|
+
throw new Error('MUI X: The timezone of the start and the end date should be the same.');
|
|
33
33
|
}
|
|
34
34
|
return timezoneStart ?? timezoneEnd;
|
|
35
35
|
},
|
package/modern/models/index.js
CHANGED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "AdapterDateFns", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _AdapterDateFnsV.AdapterDateFns;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
var _AdapterDateFnsV = require("@mui/x-date-pickers/AdapterDateFnsV3");
|
package/node/index.js
CHANGED
|
@@ -14,17 +14,6 @@ Object.keys(_dateRange).forEach(function (key) {
|
|
|
14
14
|
}
|
|
15
15
|
});
|
|
16
16
|
});
|
|
17
|
-
var _range = require("./range");
|
|
18
|
-
Object.keys(_range).forEach(function (key) {
|
|
19
|
-
if (key === "default" || key === "__esModule") return;
|
|
20
|
-
if (key in exports && exports[key] === _range[key]) return;
|
|
21
|
-
Object.defineProperty(exports, key, {
|
|
22
|
-
enumerable: true,
|
|
23
|
-
get: function () {
|
|
24
|
-
return _range[key];
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
});
|
|
28
17
|
var _dateTimeRange = require("./dateTimeRange");
|
|
29
18
|
Object.keys(_dateTimeRange).forEach(function (key) {
|
|
30
19
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -6,7 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.getReleaseInfo = void 0;
|
|
7
7
|
var _utils = require("@mui/utils");
|
|
8
8
|
const getReleaseInfo = () => {
|
|
9
|
-
const releaseInfo = "
|
|
9
|
+
const releaseInfo = "MTcwNDkyNzYwMDAwMA==";
|
|
10
10
|
if (process.env.NODE_ENV !== 'production') {
|
|
11
11
|
// A simple hack to set the value in the test environment (has no build step).
|
|
12
12
|
// eslint-disable-next-line no-useless-concat
|
|
@@ -36,7 +36,7 @@ const rangeValueManager = exports.rangeValueManager = {
|
|
|
36
36
|
const timezoneStart = value[0] == null || !utils.isValid(value[0]) ? null : utils.getTimezone(value[0]);
|
|
37
37
|
const timezoneEnd = value[1] == null || !utils.isValid(value[1]) ? null : utils.getTimezone(value[1]);
|
|
38
38
|
if (timezoneStart != null && timezoneEnd != null && timezoneStart !== timezoneEnd) {
|
|
39
|
-
throw new Error('MUI: The timezone of the start and the end date should be the same');
|
|
39
|
+
throw new Error('MUI X: The timezone of the start and the end date should be the same.');
|
|
40
40
|
}
|
|
41
41
|
return timezoneStart ?? timezoneEnd;
|
|
42
42
|
},
|
package/node/models/index.js
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
var _range = require("./range");
|
|
7
|
+
Object.keys(_range).forEach(function (key) {
|
|
8
|
+
if (key === "default" || key === "__esModule") return;
|
|
9
|
+
if (key in exports && exports[key] === _range[key]) return;
|
|
10
|
+
Object.defineProperty(exports, key, {
|
|
11
|
+
enumerable: true,
|
|
12
|
+
get: function () {
|
|
13
|
+
return _range[key];
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
});
|
|
6
17
|
var _validation = require("./validation");
|
|
7
18
|
Object.keys(_validation).forEach(function (key) {
|
|
8
19
|
if (key === "default" || key === "__esModule") return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/x-date-pickers-pro",
|
|
3
|
-
"version": "7.0.0-alpha.
|
|
3
|
+
"version": "7.0.0-alpha.8",
|
|
4
4
|
"description": "The commercial edition of the date picker components (MUI X).",
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"main": "./node/index.js",
|
|
@@ -35,8 +35,8 @@
|
|
|
35
35
|
"@mui/base": "^5.0.0-beta.29",
|
|
36
36
|
"@mui/system": "^5.15.2",
|
|
37
37
|
"@mui/utils": "^5.15.2",
|
|
38
|
-
"@mui/x-date-pickers": "7.0.0-alpha.
|
|
39
|
-
"@mui/x-license-pro": "7.0.0-alpha.
|
|
38
|
+
"@mui/x-date-pickers": "7.0.0-alpha.8",
|
|
39
|
+
"@mui/x-license-pro": "7.0.0-alpha.8",
|
|
40
40
|
"clsx": "^2.0.0",
|
|
41
41
|
"prop-types": "^15.8.1",
|
|
42
42
|
"react-transition-group": "^4.4.5"
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"@emotion/react": "^11.9.0",
|
|
46
46
|
"@emotion/styled": "^11.8.1",
|
|
47
47
|
"@mui/material": "^5.8.6",
|
|
48
|
-
"date-fns": "^2.25.0",
|
|
48
|
+
"date-fns": "^2.25.0 || ^3.2.0",
|
|
49
49
|
"date-fns-jalali": "^2.13.0-0",
|
|
50
50
|
"dayjs": "^1.10.7",
|
|
51
51
|
"luxon": "^3.0.2",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|