@mui/lab 6.0.0-alpha.7 → 6.0.0-alpha.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. package/Alert/Alert.js +4 -4
  2. package/AlertTitle/AlertTitle.js +4 -4
  3. package/Autocomplete/Autocomplete.js +4 -4
  4. package/AvatarGroup/AvatarGroup.js +4 -4
  5. package/CHANGELOG.md +113 -2
  6. package/CalendarPicker/CalendarPicker.d.ts +1 -1
  7. package/CalendarPickerSkeleton/CalendarPickerSkeleton.d.ts +1 -1
  8. package/ClockPicker/ClockPicker.d.ts +1 -1
  9. package/DatePicker/DatePicker.d.ts +1 -1
  10. package/DateRangePicker/DateRangePicker.d.ts +1 -1
  11. package/DateRangePickerDay/DateRangePickerDay.d.ts +1 -1
  12. package/DateTimePicker/DateTimePicker.d.ts +1 -1
  13. package/DesktopDatePicker/DesktopDatePicker.d.ts +1 -1
  14. package/DesktopDateRangePicker/DesktopDateRangePicker.d.ts +1 -1
  15. package/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +1 -1
  16. package/DesktopTimePicker/DesktopTimePicker.d.ts +1 -1
  17. package/LoadingButton/LoadingButton.js +21 -19
  18. package/LocalizationProvider/LocalizationProvider.d.ts +1 -1
  19. package/Masonry/Masonry.js +35 -30
  20. package/MobileDatePicker/MobileDatePicker.d.ts +1 -1
  21. package/MobileDateRangePicker/MobileDateRangePicker.d.ts +1 -1
  22. package/MobileDateTimePicker/MobileDateTimePicker.d.ts +1 -1
  23. package/MobileTimePicker/MobileTimePicker.d.ts +1 -1
  24. package/MonthPicker/MonthPicker.d.ts +1 -1
  25. package/Pagination/Pagination.js +4 -4
  26. package/PaginationItem/PaginationItem.js +4 -4
  27. package/PickersDay/PickersDay.d.ts +1 -1
  28. package/Rating/Rating.js +4 -4
  29. package/Skeleton/Skeleton.js +4 -4
  30. package/SpeedDial/SpeedDial.js +4 -4
  31. package/SpeedDialAction/SpeedDialAction.js +4 -4
  32. package/SpeedDialIcon/SpeedDialIcon.js +4 -4
  33. package/StaticDatePicker/StaticDatePicker.d.ts +1 -1
  34. package/StaticDateRangePicker/StaticDateRangePicker.d.ts +1 -1
  35. package/StaticDateTimePicker/StaticDateTimePicker.d.ts +1 -1
  36. package/StaticTimePicker/StaticTimePicker.d.ts +1 -1
  37. package/TabContext/TabContext.d.ts +1 -1
  38. package/TabList/TabList.js +6 -8
  39. package/TabPanel/TabPanel.d.ts +1 -1
  40. package/TabPanel/TabPanel.js +13 -14
  41. package/TimePicker/TimePicker.d.ts +1 -1
  42. package/Timeline/Timeline.js +11 -12
  43. package/TimelineConnector/TimelineConnector.d.ts +1 -1
  44. package/TimelineConnector/TimelineConnector.js +7 -9
  45. package/TimelineContent/TimelineContent.d.ts +1 -1
  46. package/TimelineContent/TimelineContent.js +15 -15
  47. package/TimelineDot/TimelineDot.d.ts +1 -1
  48. package/TimelineDot/TimelineDot.js +38 -31
  49. package/TimelineItem/TimelineItem.d.ts +1 -1
  50. package/TimelineItem/TimelineItem.js +33 -31
  51. package/TimelineOppositeContent/TimelineOppositeContent.d.ts +3 -1
  52. package/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  53. package/TimelineSeparator/TimelineSeparator.d.ts +1 -1
  54. package/TimelineSeparator/TimelineSeparator.js +7 -9
  55. package/ToggleButton/ToggleButton.js +4 -4
  56. package/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  57. package/TreeItem/TreeItem.d.ts +1 -1
  58. package/TreeView/TreeView.d.ts +1 -1
  59. package/YearPicker/YearPicker.d.ts +1 -1
  60. package/index.js +1 -1
  61. package/modern/Alert/Alert.js +4 -4
  62. package/modern/AlertTitle/AlertTitle.js +4 -4
  63. package/modern/Autocomplete/Autocomplete.js +4 -4
  64. package/modern/AvatarGroup/AvatarGroup.js +4 -4
  65. package/modern/LoadingButton/LoadingButton.js +21 -19
  66. package/modern/Masonry/Masonry.js +35 -30
  67. package/modern/Pagination/Pagination.js +4 -4
  68. package/modern/PaginationItem/PaginationItem.js +4 -4
  69. package/modern/Rating/Rating.js +4 -4
  70. package/modern/Skeleton/Skeleton.js +4 -4
  71. package/modern/SpeedDial/SpeedDial.js +4 -4
  72. package/modern/SpeedDialAction/SpeedDialAction.js +4 -4
  73. package/modern/SpeedDialIcon/SpeedDialIcon.js +4 -4
  74. package/modern/TabList/TabList.js +6 -8
  75. package/modern/TabPanel/TabPanel.js +13 -14
  76. package/modern/Timeline/Timeline.js +11 -12
  77. package/modern/TimelineConnector/TimelineConnector.js +7 -9
  78. package/modern/TimelineContent/TimelineContent.js +15 -15
  79. package/modern/TimelineDot/TimelineDot.js +38 -31
  80. package/modern/TimelineItem/TimelineItem.js +33 -31
  81. package/modern/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  82. package/modern/TimelineSeparator/TimelineSeparator.js +7 -9
  83. package/modern/ToggleButton/ToggleButton.js +4 -4
  84. package/modern/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  85. package/modern/index.js +1 -1
  86. package/node/Alert/Alert.js +4 -4
  87. package/node/AlertTitle/AlertTitle.js +4 -4
  88. package/node/Autocomplete/Autocomplete.js +4 -4
  89. package/node/AvatarGroup/AvatarGroup.js +4 -4
  90. package/node/LoadingButton/LoadingButton.js +21 -19
  91. package/node/Masonry/Masonry.js +35 -30
  92. package/node/Pagination/Pagination.js +4 -4
  93. package/node/PaginationItem/PaginationItem.js +4 -4
  94. package/node/Rating/Rating.js +4 -4
  95. package/node/Skeleton/Skeleton.js +4 -4
  96. package/node/SpeedDial/SpeedDial.js +4 -4
  97. package/node/SpeedDialAction/SpeedDialAction.js +4 -4
  98. package/node/SpeedDialIcon/SpeedDialIcon.js +4 -4
  99. package/node/TabList/TabList.js +6 -8
  100. package/node/TabPanel/TabPanel.js +13 -14
  101. package/node/Timeline/Timeline.js +11 -12
  102. package/node/TimelineConnector/TimelineConnector.js +7 -9
  103. package/node/TimelineContent/TimelineContent.js +15 -15
  104. package/node/TimelineDot/TimelineDot.js +38 -31
  105. package/node/TimelineItem/TimelineItem.js +33 -31
  106. package/node/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  107. package/node/TimelineSeparator/TimelineSeparator.js +7 -9
  108. package/node/ToggleButton/ToggleButton.js +4 -4
  109. package/node/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  110. package/node/index.js +1 -1
  111. package/package.json +7 -7
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
5
- const _excluded = ["children", "className", "value", "keepMounted"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -36,13 +33,15 @@ const TabPanel = /*#__PURE__*/React.forwardRef(function TabPanel(inProps, ref) {
36
33
  name: 'MuiTabPanel'
37
34
  });
38
35
  const {
39
- children,
40
- className,
41
- value,
42
- keepMounted = false
43
- } = props,
44
- other = _objectWithoutPropertiesLoose(props, _excluded);
45
- const ownerState = _extends({}, props);
36
+ children,
37
+ className,
38
+ value,
39
+ keepMounted = false,
40
+ ...other
41
+ } = props;
42
+ const ownerState = {
43
+ ...props
44
+ };
46
45
  const classes = useUtilityClasses(ownerState);
47
46
  const context = useTabContext();
48
47
  if (context === null) {
@@ -50,17 +49,17 @@ const TabPanel = /*#__PURE__*/React.forwardRef(function TabPanel(inProps, ref) {
50
49
  }
51
50
  const id = getPanelId(context, value);
52
51
  const tabId = getTabId(context, value);
53
- return /*#__PURE__*/_jsx(TabPanelRoot, _extends({
52
+ return /*#__PURE__*/_jsx(TabPanelRoot, {
54
53
  "aria-labelledby": tabId,
55
54
  className: clsx(classes.root, className),
56
55
  hidden: value !== context.value,
57
56
  id: id,
58
57
  ref: ref,
59
58
  role: "tabpanel",
60
- ownerState: ownerState
61
- }, other, {
59
+ ownerState: ownerState,
60
+ ...other,
62
61
  children: (keepMounted || value === context.value) && children
63
- }));
62
+ });
64
63
  });
65
64
  process.env.NODE_ENV !== "production" ? TabPanel.propTypes /* remove-proptypes */ = {
66
65
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
5
- const _excluded = ["position", "className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -54,26 +51,28 @@ const Timeline = /*#__PURE__*/React.forwardRef(function Timeline(inProps, ref) {
54
51
  name: 'MuiTimeline'
55
52
  });
56
53
  const {
57
- position = 'right',
58
- className
59
- } = props,
60
- other = _objectWithoutPropertiesLoose(props, _excluded);
61
- const ownerState = _extends({}, props, {
54
+ position = 'right',
55
+ className,
56
+ ...other
57
+ } = props;
58
+ const ownerState = {
59
+ ...props,
62
60
  position
63
- });
61
+ };
64
62
  const classes = useUtilityClasses(ownerState);
65
63
  const contextValue = React.useMemo(() => ({
66
64
  position
67
65
  }), [position]);
68
66
  return /*#__PURE__*/_jsx(TimelineContext.Provider, {
69
67
  value: contextValue,
70
- children: /*#__PURE__*/_jsx(TimelineRoot, _extends({
68
+ children: /*#__PURE__*/_jsx(TimelineRoot, {
71
69
  className: clsx(classes.root, className),
72
70
  ownerState: ownerState
73
71
  // @ts-expect-error TypeScript bug, need to keep unknown for DX
74
72
  ,
75
- ref: ref
76
- }, other))
73
+ ref: ref,
74
+ ...other
75
+ })
77
76
  });
78
77
  });
79
78
  process.env.NODE_ENV !== "production" ? Timeline.propTypes /* remove-proptypes */ = {
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
5
- const _excluded = ["className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -38,16 +35,17 @@ const TimelineConnector = /*#__PURE__*/React.forwardRef(function TimelineConnect
38
35
  name: 'MuiTimelineConnector'
39
36
  });
40
37
  const {
41
- className
42
- } = props,
43
- other = _objectWithoutPropertiesLoose(props, _excluded);
38
+ className,
39
+ ...other
40
+ } = props;
44
41
  const ownerState = props;
45
42
  const classes = useUtilityClasses(ownerState);
46
- return /*#__PURE__*/_jsx(TimelineConnectorRoot, _extends({
43
+ return /*#__PURE__*/_jsx(TimelineConnectorRoot, {
47
44
  className: clsx(classes.root, className),
48
45
  ownerState: ownerState,
49
- ref: ref
50
- }, other));
46
+ ref: ref,
47
+ ...other
48
+ });
51
49
  });
52
50
  process.env.NODE_ENV !== "production" ? TimelineConnector.propTypes /* remove-proptypes */ = {
53
51
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
4
- import _extends from "@babel/runtime/helpers/esm/extends";
5
- const _excluded = ["className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -34,12 +31,13 @@ const TimelineContentRoot = styled(Typography, {
34
31
  }
35
32
  })(({
36
33
  ownerState
37
- }) => _extends({
34
+ }) => ({
38
35
  flex: 1,
39
36
  padding: '6px 16px',
40
- textAlign: 'left'
41
- }, ownerState.position === 'left' && {
42
- textAlign: 'right'
37
+ textAlign: 'left',
38
+ ...(ownerState.position === 'left' && {
39
+ textAlign: 'right'
40
+ })
43
41
  }));
44
42
  const TimelineContent = /*#__PURE__*/React.forwardRef(function TimelineContent(inProps, ref) {
45
43
  const props = useThemeProps({
@@ -47,22 +45,24 @@ const TimelineContent = /*#__PURE__*/React.forwardRef(function TimelineContent(i
47
45
  name: 'MuiTimelineContent'
48
46
  });
49
47
  const {
50
- className
51
- } = props,
52
- other = _objectWithoutPropertiesLoose(props, _excluded);
48
+ className,
49
+ ...other
50
+ } = props;
53
51
  const {
54
52
  position: positionContext
55
53
  } = React.useContext(TimelineContext);
56
- const ownerState = _extends({}, props, {
54
+ const ownerState = {
55
+ ...props,
57
56
  position: positionContext || 'right'
58
- });
57
+ };
59
58
  const classes = useUtilityClasses(ownerState);
60
- return /*#__PURE__*/_jsx(TimelineContentRoot, _extends({
59
+ return /*#__PURE__*/_jsx(TimelineContentRoot, {
61
60
  component: "div",
62
61
  className: clsx(classes.root, className),
63
62
  ownerState: ownerState,
64
- ref: ref
65
- }, other));
63
+ ref: ref,
64
+ ...other
65
+ });
66
66
  });
67
67
  process.env.NODE_ENV !== "production" ? TimelineContent.propTypes /* remove-proptypes */ = {
68
68
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
4
- import _extends from "@babel/runtime/helpers/esm/extends";
5
- const _excluded = ["className", "color", "variant"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -34,7 +31,7 @@ const TimelineDotRoot = styled('span', {
34
31
  })(({
35
32
  ownerState,
36
33
  theme
37
- }) => _extends({
34
+ }) => ({
38
35
  display: 'flex',
39
36
  alignSelf: 'baseline',
40
37
  borderStyle: 'solid',
@@ -42,44 +39,54 @@ const TimelineDotRoot = styled('span', {
42
39
  padding: 4,
43
40
  borderRadius: '50%',
44
41
  boxShadow: (theme.vars || theme).shadows[1],
45
- margin: '11.5px 0'
46
- }, ownerState.variant === 'filled' && _extends({
47
- borderColor: 'transparent'
48
- }, ownerState.color !== 'inherit' && _extends({}, ownerState.color === 'grey' ? {
49
- color: (theme.vars || theme).palette.grey[50],
50
- backgroundColor: (theme.vars || theme).palette.grey[400]
51
- } : {
52
- color: (theme.vars || theme).palette[ownerState.color].contrastText,
53
- backgroundColor: (theme.vars || theme).palette[ownerState.color].main
54
- })), ownerState.variant === 'outlined' && _extends({
55
- boxShadow: 'none',
56
- backgroundColor: 'transparent'
57
- }, ownerState.color !== 'inherit' && _extends({}, ownerState.color === 'grey' ? {
58
- borderColor: (theme.vars || theme).palette.grey[400]
59
- } : {
60
- borderColor: (theme.vars || theme).palette[ownerState.color].main
61
- }))));
42
+ margin: '11.5px 0',
43
+ ...(ownerState.variant === 'filled' && {
44
+ borderColor: 'transparent',
45
+ ...(ownerState.color !== 'inherit' && {
46
+ ...(ownerState.color === 'grey' ? {
47
+ color: (theme.vars || theme).palette.grey[50],
48
+ backgroundColor: (theme.vars || theme).palette.grey[400]
49
+ } : {
50
+ color: (theme.vars || theme).palette[ownerState.color].contrastText,
51
+ backgroundColor: (theme.vars || theme).palette[ownerState.color].main
52
+ })
53
+ })
54
+ }),
55
+ ...(ownerState.variant === 'outlined' && {
56
+ boxShadow: 'none',
57
+ backgroundColor: 'transparent',
58
+ ...(ownerState.color !== 'inherit' && {
59
+ ...(ownerState.color === 'grey' ? {
60
+ borderColor: (theme.vars || theme).palette.grey[400]
61
+ } : {
62
+ borderColor: (theme.vars || theme).palette[ownerState.color].main
63
+ })
64
+ })
65
+ })
66
+ }));
62
67
  const TimelineDot = /*#__PURE__*/React.forwardRef(function TimelineDot(inProps, ref) {
63
68
  const props = useThemeProps({
64
69
  props: inProps,
65
70
  name: 'MuiTimelineDot'
66
71
  });
67
72
  const {
68
- className,
69
- color = 'grey',
70
- variant = 'filled'
71
- } = props,
72
- other = _objectWithoutPropertiesLoose(props, _excluded);
73
- const ownerState = _extends({}, props, {
73
+ className,
74
+ color = 'grey',
75
+ variant = 'filled',
76
+ ...other
77
+ } = props;
78
+ const ownerState = {
79
+ ...props,
74
80
  color,
75
81
  variant
76
- });
82
+ };
77
83
  const classes = useUtilityClasses(ownerState);
78
- return /*#__PURE__*/_jsx(TimelineDotRoot, _extends({
84
+ return /*#__PURE__*/_jsx(TimelineDotRoot, {
79
85
  className: clsx(classes.root, className),
80
86
  ownerState: ownerState,
81
- ref: ref
82
- }, other));
87
+ ref: ref,
88
+ ...other
89
+ });
83
90
  });
84
91
  process.env.NODE_ENV !== "production" ? TimelineDot.propTypes /* remove-proptypes */ = {
85
92
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
4
- import _extends from "@babel/runtime/helpers/esm/extends";
5
- const _excluded = ["position", "className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -37,29 +34,32 @@ const TimelineItemRoot = styled('li', {
37
34
  }
38
35
  })(({
39
36
  ownerState
40
- }) => _extends({
37
+ }) => ({
41
38
  listStyle: 'none',
42
39
  display: 'flex',
43
40
  position: 'relative',
44
- minHeight: 70
45
- }, ownerState.position === 'left' && {
46
- flexDirection: 'row-reverse'
47
- }, (ownerState.position === 'alternate' || ownerState.position === 'alternate-reverse') && {
48
- [`&:nth-of-type(${ownerState.position === 'alternate' ? 'even' : 'odd'})`]: {
49
- flexDirection: 'row-reverse',
50
- [`& .${timelineContentClasses.root}`]: {
51
- textAlign: 'right'
52
- },
53
- [`& .${timelineOppositeContentClasses.root}`]: {
54
- textAlign: 'left'
41
+ minHeight: 70,
42
+ ...(ownerState.position === 'left' && {
43
+ flexDirection: 'row-reverse'
44
+ }),
45
+ ...((ownerState.position === 'alternate' || ownerState.position === 'alternate-reverse') && {
46
+ [`&:nth-of-type(${ownerState.position === 'alternate' ? 'even' : 'odd'})`]: {
47
+ flexDirection: 'row-reverse',
48
+ [`& .${timelineContentClasses.root}`]: {
49
+ textAlign: 'right'
50
+ },
51
+ [`& .${timelineOppositeContentClasses.root}`]: {
52
+ textAlign: 'left'
53
+ }
55
54
  }
56
- }
57
- }, !ownerState.hasOppositeContent && {
58
- '&::before': {
59
- content: '""',
60
- flex: 1,
61
- padding: '6px 16px'
62
- }
55
+ }),
56
+ ...(!ownerState.hasOppositeContent && {
57
+ '&::before': {
58
+ content: '""',
59
+ flex: 1,
60
+ padding: '6px 16px'
61
+ }
62
+ })
63
63
  }));
64
64
  const TimelineItem = /*#__PURE__*/React.forwardRef(function TimelineItem(inProps, ref) {
65
65
  const props = useThemeProps({
@@ -67,10 +67,10 @@ const TimelineItem = /*#__PURE__*/React.forwardRef(function TimelineItem(inProps
67
67
  name: 'MuiTimelineItem'
68
68
  });
69
69
  const {
70
- position: positionProp,
71
- className
72
- } = props,
73
- other = _objectWithoutPropertiesLoose(props, _excluded);
70
+ position: positionProp,
71
+ className,
72
+ ...other
73
+ } = props;
74
74
  const {
75
75
  position: positionContext
76
76
  } = React.useContext(TimelineContext);
@@ -80,21 +80,23 @@ const TimelineItem = /*#__PURE__*/React.forwardRef(function TimelineItem(inProps
80
80
  hasOppositeContent = true;
81
81
  }
82
82
  });
83
- const ownerState = _extends({}, props, {
83
+ const ownerState = {
84
+ ...props,
84
85
  position: positionProp || positionContext || 'right',
85
86
  hasOppositeContent
86
- });
87
+ };
87
88
  const classes = useUtilityClasses(ownerState);
88
89
  const contextValue = React.useMemo(() => ({
89
90
  position: ownerState.position
90
91
  }), [ownerState.position]);
91
92
  return /*#__PURE__*/_jsx(TimelineContext.Provider, {
92
93
  value: contextValue,
93
- children: /*#__PURE__*/_jsx(TimelineItemRoot, _extends({
94
+ children: /*#__PURE__*/_jsx(TimelineItemRoot, {
94
95
  className: clsx(classes.root, className),
95
96
  ownerState: ownerState,
96
- ref: ref
97
- }, other))
97
+ ref: ref,
98
+ ...other
99
+ })
98
100
  });
99
101
  });
100
102
  process.env.NODE_ENV !== "production" ? TimelineItem.propTypes /* remove-proptypes */ = {
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
4
- import _extends from "@babel/runtime/helpers/esm/extends";
5
- const _excluded = ["className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -34,13 +31,14 @@ const TimelineOppositeContentRoot = styled(Typography, {
34
31
  }
35
32
  })(({
36
33
  ownerState
37
- }) => _extends({
34
+ }) => ({
38
35
  padding: '6px 16px',
39
36
  marginRight: 'auto',
40
37
  textAlign: 'right',
41
- flex: 1
42
- }, ownerState.position === 'left' && {
43
- textAlign: 'left'
38
+ flex: 1,
39
+ ...(ownerState.position === 'left' && {
40
+ textAlign: 'left'
41
+ })
44
42
  }));
45
43
  const TimelineOppositeContent = /*#__PURE__*/React.forwardRef(function TimelineOppositeContent(inProps, ref) {
46
44
  const props = useThemeProps({
@@ -48,22 +46,24 @@ const TimelineOppositeContent = /*#__PURE__*/React.forwardRef(function TimelineO
48
46
  name: 'MuiTimelineOppositeContent'
49
47
  });
50
48
  const {
51
- className
52
- } = props,
53
- other = _objectWithoutPropertiesLoose(props, _excluded);
49
+ className,
50
+ ...other
51
+ } = props;
54
52
  const {
55
53
  position: positionContext
56
54
  } = React.useContext(TimelineContext);
57
- const ownerState = _extends({}, props, {
55
+ const ownerState = {
56
+ ...props,
58
57
  position: positionContext || 'left'
59
- });
58
+ };
60
59
  const classes = useUtilityClasses(ownerState);
61
- return /*#__PURE__*/_jsx(TimelineOppositeContentRoot, _extends({
60
+ return /*#__PURE__*/_jsx(TimelineOppositeContentRoot, {
62
61
  component: "div",
63
62
  className: clsx(classes.root, className),
64
63
  ownerState: ownerState,
65
- ref: ref
66
- }, other));
64
+ ref: ref,
65
+ ...other
66
+ });
67
67
  });
68
68
  process.env.NODE_ENV !== "production" ? TimelineOppositeContent.propTypes /* remove-proptypes */ = {
69
69
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,8 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
5
- const _excluded = ["className"];
6
3
  import * as React from 'react';
7
4
  import PropTypes from 'prop-types';
8
5
  import clsx from 'clsx';
@@ -35,16 +32,17 @@ const TimelineSeparator = /*#__PURE__*/React.forwardRef(function TimelineSeparat
35
32
  name: 'MuiTimelineSeparator'
36
33
  });
37
34
  const {
38
- className
39
- } = props,
40
- other = _objectWithoutPropertiesLoose(props, _excluded);
35
+ className,
36
+ ...other
37
+ } = props;
41
38
  const ownerState = props;
42
39
  const classes = useUtilityClasses(ownerState);
43
- return /*#__PURE__*/_jsx(TimelineSeparatorRoot, _extends({
40
+ return /*#__PURE__*/_jsx(TimelineSeparatorRoot, {
44
41
  className: clsx(classes.root, className),
45
42
  ownerState: ownerState,
46
- ref: ref
47
- }, other));
43
+ ref: ref,
44
+ ...other
45
+ });
48
46
  });
49
47
  process.env.NODE_ENV !== "production" ? TimelineSeparator.propTypes /* remove-proptypes */ = {
50
48
  // ┌────────────────────────────── Warning ──────────────────────────────┐
@@ -1,6 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
3
  import * as React from 'react';
5
4
  import ToggleButton from '@mui/material/ToggleButton';
6
5
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -14,7 +13,8 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedToggleButton(pro
14
13
  console.warn(['MUI: The ToggleButton component was moved from the lab to the core.', '', "You should use `import { ToggleButton } from '@mui/material'`", "or `import ToggleButton from '@mui/material/ToggleButton'`"].join('\n'));
15
14
  warnedOnce = true;
16
15
  }
17
- return /*#__PURE__*/_jsx(ToggleButton, _extends({
18
- ref: ref
19
- }, props));
16
+ return /*#__PURE__*/_jsx(ToggleButton, {
17
+ ref: ref,
18
+ ...props
19
+ });
20
20
  });
@@ -1,6 +1,5 @@
1
1
  'use client';
2
2
 
3
- import _extends from "@babel/runtime/helpers/esm/extends";
4
3
  import * as React from 'react';
5
4
  import ToggleButtonGroup from '@mui/material/ToggleButtonGroup';
6
5
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -14,7 +13,8 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedToggleButtonGrou
14
13
  console.warn(['MUI: The ToggleButtonGroup component was moved from the lab to the core.', '', "You should use `import { ToggleButtonGroup } from '@mui/material'`", "or `import ToggleButtonGroup from '@mui/material/ToggleButtonGroup'`"].join('\n'));
15
14
  warnedOnce = true;
16
15
  }
17
- return /*#__PURE__*/_jsx(ToggleButtonGroup, _extends({
18
- ref: ref
19
- }, props));
16
+ return /*#__PURE__*/_jsx(ToggleButtonGroup, {
17
+ ref: ref,
18
+ ...props
19
+ });
20
20
  });
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/lab v6.0.0-alpha.7
2
+ * @mui/lab v6.0.0-alpha.9
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var React = _interopRequireWildcard(require("react"));
11
10
  var _Alert = _interopRequireDefault(require("@mui/material/Alert"));
12
11
  var _jsxRuntime = require("react/jsx-runtime");
@@ -22,7 +21,8 @@ var _default = exports.default = /*#__PURE__*/React.forwardRef(function Deprecat
22
21
  console.warn(['MUI: The Alert component was moved from the lab to the core.', '', "You should use `import { Alert } from '@mui/material'`", "or `import Alert from '@mui/material/Alert'`"].join('\n'));
23
22
  warnedOnce = true;
24
23
  }
25
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Alert.default, (0, _extends2.default)({
26
- ref: ref
27
- }, props));
24
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Alert.default, {
25
+ ref: ref,
26
+ ...props
27
+ });
28
28
  });
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var React = _interopRequireWildcard(require("react"));
11
10
  var _AlertTitle = _interopRequireDefault(require("@mui/material/AlertTitle"));
12
11
  var _jsxRuntime = require("react/jsx-runtime");
@@ -22,7 +21,8 @@ var _default = exports.default = /*#__PURE__*/React.forwardRef(function Deprecat
22
21
  console.warn(['MUI: The AlertTitle component was moved from the lab to the core.', '', "You should use `import { AlertTitle } from '@mui/material'`", "or `import AlertTitle from '@mui/material/AlertTitle'`"].join('\n'));
23
22
  warnedOnce = true;
24
23
  }
25
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_AlertTitle.default, (0, _extends2.default)({
26
- ref: ref
27
- }, props));
24
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_AlertTitle.default, {
25
+ ref: ref,
26
+ ...props
27
+ });
28
28
  });
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var React = _interopRequireWildcard(require("react"));
11
10
  var _Autocomplete = _interopRequireDefault(require("@mui/material/Autocomplete"));
12
11
  var _jsxRuntime = require("react/jsx-runtime");
@@ -22,7 +21,8 @@ var _default = exports.default = /*#__PURE__*/React.forwardRef(function Deprecat
22
21
  console.warn(['MUI: The Autocomplete component was moved from the lab to the core.', '', "You should use `import { Autocomplete } from '@mui/material'`", "or `import Autocomplete from '@mui/material/Autocomplete'`"].join('\n'));
23
22
  warnedOnce = true;
24
23
  }
25
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Autocomplete.default, (0, _extends2.default)({
26
- ref: ref
27
- }, props));
24
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Autocomplete.default, {
25
+ ref: ref,
26
+ ...props
27
+ });
28
28
  });
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
8
  exports.default = void 0;
9
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
10
9
  var React = _interopRequireWildcard(require("react"));
11
10
  var _AvatarGroup = _interopRequireDefault(require("@mui/material/AvatarGroup"));
12
11
  var _jsxRuntime = require("react/jsx-runtime");
@@ -22,7 +21,8 @@ var _default = exports.default = /*#__PURE__*/React.forwardRef(function Deprecat
22
21
  console.warn(['MUI: The AvatarGroup component was moved from the lab to the core.', '', "You should use `import { AvatarGroup } from '@mui/material'`", "or `import AvatarGroup from '@mui/material/AvatarGroup'`"].join('\n'));
23
22
  warnedOnce = true;
24
23
  }
25
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_AvatarGroup.default, (0, _extends2.default)({
26
- ref: ref
27
- }, props));
24
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_AvatarGroup.default, {
25
+ ref: ref,
26
+ ...props
27
+ });
28
28
  });