@mui/lab 5.0.0-alpha.128 → 5.0.0-alpha.130

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 (119) 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 +244 -0
  6. package/LoadingButton/LoadingButton.js +74 -62
  7. package/Masonry/Masonry.js +34 -29
  8. package/Pagination/Pagination.js +4 -4
  9. package/PaginationItem/PaginationItem.js +4 -4
  10. package/Rating/Rating.js +4 -4
  11. package/Skeleton/Skeleton.js +4 -4
  12. package/SpeedDial/SpeedDial.js +4 -4
  13. package/SpeedDialAction/SpeedDialAction.js +4 -4
  14. package/SpeedDialIcon/SpeedDialIcon.js +4 -4
  15. package/TabList/TabList.js +6 -8
  16. package/TabPanel/TabPanel.js +12 -13
  17. package/Timeline/Timeline.js +14 -12
  18. package/TimelineConnector/TimelineConnector.js +7 -9
  19. package/TimelineContent/TimelineContent.js +15 -15
  20. package/TimelineDot/TimelineDot.js +38 -31
  21. package/TimelineItem/TimelineItem.js +33 -31
  22. package/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  23. package/TimelineSeparator/TimelineSeparator.js +7 -9
  24. package/ToggleButton/ToggleButton.js +4 -4
  25. package/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  26. package/TreeItem/TreeItem.js +37 -37
  27. package/TreeItem/TreeItemContent.js +15 -18
  28. package/TreeView/TreeView.js +35 -33
  29. package/TreeView/descendants.js +13 -14
  30. package/index.js +1 -1
  31. package/legacy/Alert/Alert.js +4 -2
  32. package/legacy/AlertTitle/AlertTitle.js +4 -2
  33. package/legacy/Autocomplete/Autocomplete.js +4 -2
  34. package/legacy/AvatarGroup/AvatarGroup.js +4 -2
  35. package/legacy/LoadingButton/LoadingButton.js +16 -15
  36. package/legacy/Masonry/Masonry.js +10 -8
  37. package/legacy/Pagination/Pagination.js +4 -2
  38. package/legacy/PaginationItem/PaginationItem.js +4 -2
  39. package/legacy/Rating/Rating.js +4 -2
  40. package/legacy/Skeleton/Skeleton.js +4 -2
  41. package/legacy/SpeedDial/SpeedDial.js +4 -2
  42. package/legacy/SpeedDialAction/SpeedDialAction.js +4 -2
  43. package/legacy/SpeedDialIcon/SpeedDialIcon.js +4 -2
  44. package/legacy/TabList/TabList.js +4 -2
  45. package/legacy/TabPanel/TabPanel.js +6 -4
  46. package/legacy/Timeline/Timeline.js +8 -3
  47. package/legacy/TimelineConnector/TimelineConnector.js +4 -2
  48. package/legacy/TimelineContent/TimelineContent.js +6 -4
  49. package/legacy/TimelineDot/TimelineDot.js +10 -8
  50. package/legacy/TimelineItem/TimelineItem.js +7 -6
  51. package/legacy/TimelineOppositeContent/TimelineOppositeContent.js +6 -4
  52. package/legacy/TimelineSeparator/TimelineSeparator.js +4 -2
  53. package/legacy/ToggleButton/ToggleButton.js +4 -2
  54. package/legacy/ToggleButtonGroup/ToggleButtonGroup.js +4 -2
  55. package/legacy/TreeItem/TreeItem.js +9 -8
  56. package/legacy/TreeItem/TreeItemContent.js +5 -3
  57. package/legacy/TreeView/TreeView.js +8 -6
  58. package/legacy/TreeView/descendants.js +6 -4
  59. package/legacy/index.js +1 -1
  60. package/modern/Alert/Alert.js +4 -4
  61. package/modern/AlertTitle/AlertTitle.js +4 -4
  62. package/modern/Autocomplete/Autocomplete.js +4 -4
  63. package/modern/AvatarGroup/AvatarGroup.js +4 -4
  64. package/modern/LoadingButton/LoadingButton.js +74 -62
  65. package/modern/Masonry/Masonry.js +34 -29
  66. package/modern/Pagination/Pagination.js +4 -4
  67. package/modern/PaginationItem/PaginationItem.js +4 -4
  68. package/modern/Rating/Rating.js +4 -4
  69. package/modern/Skeleton/Skeleton.js +4 -4
  70. package/modern/SpeedDial/SpeedDial.js +4 -4
  71. package/modern/SpeedDialAction/SpeedDialAction.js +4 -4
  72. package/modern/SpeedDialIcon/SpeedDialIcon.js +4 -4
  73. package/modern/TabList/TabList.js +6 -8
  74. package/modern/TabPanel/TabPanel.js +12 -13
  75. package/modern/Timeline/Timeline.js +14 -12
  76. package/modern/TimelineConnector/TimelineConnector.js +7 -9
  77. package/modern/TimelineContent/TimelineContent.js +15 -15
  78. package/modern/TimelineDot/TimelineDot.js +38 -31
  79. package/modern/TimelineItem/TimelineItem.js +33 -31
  80. package/modern/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  81. package/modern/TimelineSeparator/TimelineSeparator.js +7 -9
  82. package/modern/ToggleButton/ToggleButton.js +4 -4
  83. package/modern/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  84. package/modern/TreeItem/TreeItem.js +37 -37
  85. package/modern/TreeItem/TreeItemContent.js +15 -18
  86. package/modern/TreeView/TreeView.js +35 -33
  87. package/modern/TreeView/descendants.js +13 -14
  88. package/modern/index.js +1 -1
  89. package/node/Alert/Alert.js +4 -4
  90. package/node/AlertTitle/AlertTitle.js +4 -4
  91. package/node/Autocomplete/Autocomplete.js +4 -4
  92. package/node/AvatarGroup/AvatarGroup.js +4 -4
  93. package/node/LoadingButton/LoadingButton.js +74 -62
  94. package/node/Masonry/Masonry.js +34 -29
  95. package/node/Pagination/Pagination.js +4 -4
  96. package/node/PaginationItem/PaginationItem.js +4 -4
  97. package/node/Rating/Rating.js +4 -4
  98. package/node/Skeleton/Skeleton.js +4 -4
  99. package/node/SpeedDial/SpeedDial.js +4 -4
  100. package/node/SpeedDialAction/SpeedDialAction.js +4 -4
  101. package/node/SpeedDialIcon/SpeedDialIcon.js +4 -4
  102. package/node/TabContext/TabContext.js +1 -2
  103. package/node/TabList/TabList.js +6 -8
  104. package/node/TabPanel/TabPanel.js +12 -13
  105. package/node/Timeline/Timeline.js +13 -12
  106. package/node/TimelineConnector/TimelineConnector.js +7 -9
  107. package/node/TimelineContent/TimelineContent.js +15 -15
  108. package/node/TimelineDot/TimelineDot.js +38 -31
  109. package/node/TimelineItem/TimelineItem.js +33 -31
  110. package/node/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
  111. package/node/TimelineSeparator/TimelineSeparator.js +7 -9
  112. package/node/ToggleButton/ToggleButton.js +4 -4
  113. package/node/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
  114. package/node/TreeItem/TreeItem.js +37 -37
  115. package/node/TreeItem/TreeItemContent.js +16 -20
  116. package/node/TreeView/TreeView.js +35 -33
  117. package/node/TreeView/descendants.js +13 -14
  118. package/node/index.js +1 -1
  119. package/package.json +4 -4
@@ -1,6 +1,3 @@
1
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
- import _extends from "@babel/runtime/helpers/esm/extends";
3
- const _excluded = ["children", "className", "collapseIcon", "ContentComponent", "ContentProps", "endIcon", "expandIcon", "disabled", "icon", "id", "label", "nodeId", "onClick", "onMouseDown", "TransitionComponent", "TransitionProps"];
4
1
  import * as React from 'react';
5
2
  import clsx from 'clsx';
6
3
  import PropTypes from 'prop-types';
@@ -98,13 +95,14 @@ const StyledTreeItemContent = styled(TreeItemContent, {
98
95
  fontSize: 18
99
96
  }
100
97
  },
101
- [`& .${treeItemClasses.label}`]: _extends({
98
+ [`& .${treeItemClasses.label}`]: {
102
99
  width: '100%',
103
100
  // fixes overflow - see https://github.com/mui/material-ui/issues/27372
104
101
  minWidth: 0,
105
102
  paddingLeft: 4,
106
- position: 'relative'
107
- }, theme.typography.body1)
103
+ position: 'relative',
104
+ ...theme.typography.body1
105
+ }
108
106
  }));
109
107
  const TreeItemGroup = styled(Collapse, {
110
108
  name: 'MuiTreeItem',
@@ -121,24 +119,24 @@ const TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
121
119
  name: 'MuiTreeItem'
122
120
  });
123
121
  const {
124
- children,
125
- className,
126
- collapseIcon,
127
- ContentComponent = TreeItemContent,
128
- ContentProps,
129
- endIcon,
130
- expandIcon,
131
- disabled: disabledProp,
132
- icon,
133
- id: idProp,
134
- label,
135
- nodeId,
136
- onClick,
137
- onMouseDown,
138
- TransitionComponent = Collapse,
139
- TransitionProps
140
- } = props,
141
- other = _objectWithoutPropertiesLoose(props, _excluded);
122
+ children,
123
+ className,
124
+ collapseIcon,
125
+ ContentComponent = TreeItemContent,
126
+ ContentProps,
127
+ endIcon,
128
+ expandIcon,
129
+ disabled: disabledProp,
130
+ icon,
131
+ id: idProp,
132
+ label,
133
+ nodeId,
134
+ onClick,
135
+ onMouseDown,
136
+ TransitionComponent = Collapse,
137
+ TransitionProps,
138
+ ...other
139
+ } = props;
142
140
  const {
143
141
  icons: contextIcons = {},
144
142
  focus,
@@ -176,12 +174,13 @@ const TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
176
174
  const focused = isFocused ? isFocused(nodeId) : false;
177
175
  const selected = isSelected ? isSelected(nodeId) : false;
178
176
  const disabled = isDisabled ? isDisabled(nodeId) : false;
179
- const ownerState = _extends({}, props, {
177
+ const ownerState = {
178
+ ...props,
180
179
  expanded,
181
180
  focused,
182
181
  selected,
183
182
  disabled
184
- });
183
+ };
185
184
  const classes = useUtilityClasses(ownerState);
186
185
  let displayIcon;
187
186
  let expansionIcon;
@@ -253,7 +252,7 @@ const TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
253
252
  focus(event, nodeId);
254
253
  }
255
254
  }
256
- return /*#__PURE__*/_jsxs(TreeItemRoot, _extends({
255
+ return /*#__PURE__*/_jsxs(TreeItemRoot, {
257
256
  className: clsx(classes.root, className),
258
257
  role: "treeitem",
259
258
  "aria-expanded": expandable ? expanded : null,
@@ -261,11 +260,11 @@ const TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
261
260
  "aria-disabled": disabled || null,
262
261
  ref: handleRef,
263
262
  id: id,
264
- tabIndex: -1
265
- }, other, {
263
+ tabIndex: -1,
264
+ ...other,
266
265
  ownerState: ownerState,
267
266
  onFocus: handleFocus,
268
- children: [/*#__PURE__*/_jsx(StyledTreeItemContent, _extends({
267
+ children: [/*#__PURE__*/_jsx(StyledTreeItemContent, {
269
268
  as: ContentComponent,
270
269
  ref: contentRef,
271
270
  classes: {
@@ -284,21 +283,22 @@ const TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
284
283
  icon: icon,
285
284
  expansionIcon: expansionIcon,
286
285
  displayIcon: displayIcon,
287
- ownerState: ownerState
288
- }, ContentProps)), children && /*#__PURE__*/_jsx(DescendantProvider, {
286
+ ownerState: ownerState,
287
+ ...ContentProps
288
+ }), children && /*#__PURE__*/_jsx(DescendantProvider, {
289
289
  id: nodeId,
290
- children: /*#__PURE__*/_jsx(TreeItemGroup, _extends({
290
+ children: /*#__PURE__*/_jsx(TreeItemGroup, {
291
291
  as: TransitionComponent,
292
292
  unmountOnExit: true,
293
293
  className: classes.group,
294
294
  in: expanded,
295
295
  component: "ul",
296
- role: "group"
297
- }, TransitionProps, {
296
+ role: "group",
297
+ ...TransitionProps,
298
298
  children: children
299
- }))
299
+ })
300
300
  })]
301
- }));
301
+ });
302
302
  });
303
303
  process.env.NODE_ENV !== "production" ? TreeItem.propTypes /* remove-proptypes */ = {
304
304
  // ----------------------------- Warning --------------------------------
@@ -1,6 +1,3 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
2
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
- const _excluded = ["classes", "className", "displayIcon", "expansionIcon", "icon", "label", "nodeId", "onClick", "onMouseDown"];
4
1
  import * as React from 'react';
5
2
  import clsx from 'clsx';
6
3
  import PropTypes from 'prop-types';
@@ -13,17 +10,17 @@ import { jsx as _jsx } from "react/jsx-runtime";
13
10
  import { jsxs as _jsxs } from "react/jsx-runtime";
14
11
  const TreeItemContent = /*#__PURE__*/React.forwardRef(function TreeItemContent(props, ref) {
15
12
  const {
16
- classes,
17
- className,
18
- displayIcon,
19
- expansionIcon,
20
- icon: iconProp,
21
- label,
22
- nodeId,
23
- onClick,
24
- onMouseDown
25
- } = props,
26
- other = _objectWithoutPropertiesLoose(props, _excluded);
13
+ classes,
14
+ className,
15
+ displayIcon,
16
+ expansionIcon,
17
+ icon: iconProp,
18
+ label,
19
+ nodeId,
20
+ onClick,
21
+ onMouseDown,
22
+ ...other
23
+ } = props;
27
24
  const {
28
25
  disabled,
29
26
  expanded,
@@ -50,12 +47,12 @@ const TreeItemContent = /*#__PURE__*/React.forwardRef(function TreeItemContent(p
50
47
  return (
51
48
  /*#__PURE__*/
52
49
  /* eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions -- Key event is handled by the TreeView */
53
- _jsxs("div", _extends({
50
+ _jsxs("div", {
54
51
  className: clsx(className, classes.root, expanded && classes.expanded, selected && classes.selected, focused && classes.focused, disabled && classes.disabled),
55
52
  onClick: handleClick,
56
53
  onMouseDown: handleMouseDown,
57
- ref: ref
58
- }, other, {
54
+ ref: ref,
55
+ ...other,
59
56
  children: [/*#__PURE__*/_jsx("div", {
60
57
  className: classes.iconContainer,
61
58
  children: icon
@@ -63,7 +60,7 @@ const TreeItemContent = /*#__PURE__*/React.forwardRef(function TreeItemContent(p
63
60
  className: classes.label,
64
61
  children: label
65
62
  })]
66
- }))
63
+ })
67
64
  );
68
65
  });
69
66
  process.env.NODE_ENV !== "production" ? TreeItemContent.propTypes = {
@@ -1,6 +1,3 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
2
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
3
- const _excluded = ["children", "className", "defaultCollapseIcon", "defaultEndIcon", "defaultExpanded", "defaultExpandIcon", "defaultParentIcon", "defaultSelected", "disabledItemsFocusable", "disableSelection", "expanded", "id", "multiSelect", "onBlur", "onFocus", "onKeyDown", "onNodeFocus", "onNodeSelect", "onNodeToggle", "selected"];
4
1
  import * as React from 'react';
5
2
  import clsx from 'clsx';
6
3
  import PropTypes from 'prop-types';
@@ -52,37 +49,38 @@ const TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
52
49
  name: 'MuiTreeView'
53
50
  });
54
51
  const {
55
- children,
56
- className,
57
- defaultCollapseIcon,
58
- defaultEndIcon,
59
- defaultExpanded = defaultDefaultExpanded,
60
- defaultExpandIcon,
61
- defaultParentIcon,
62
- defaultSelected = defaultDefaultSelected,
63
- disabledItemsFocusable = false,
64
- disableSelection = false,
65
- expanded: expandedProp,
66
- id: idProp,
67
- multiSelect = false,
68
- onBlur,
69
- onFocus,
70
- onKeyDown,
71
- onNodeFocus,
72
- onNodeSelect,
73
- onNodeToggle,
74
- selected: selectedProp
75
- } = props,
76
- other = _objectWithoutPropertiesLoose(props, _excluded);
52
+ children,
53
+ className,
54
+ defaultCollapseIcon,
55
+ defaultEndIcon,
56
+ defaultExpanded = defaultDefaultExpanded,
57
+ defaultExpandIcon,
58
+ defaultParentIcon,
59
+ defaultSelected = defaultDefaultSelected,
60
+ disabledItemsFocusable = false,
61
+ disableSelection = false,
62
+ expanded: expandedProp,
63
+ id: idProp,
64
+ multiSelect = false,
65
+ onBlur,
66
+ onFocus,
67
+ onKeyDown,
68
+ onNodeFocus,
69
+ onNodeSelect,
70
+ onNodeToggle,
71
+ selected: selectedProp,
72
+ ...other
73
+ } = props;
77
74
  const theme = useTheme();
78
75
  const isRtl = theme.direction === 'rtl';
79
- const ownerState = _extends({}, props, {
76
+ const ownerState = {
77
+ ...props,
80
78
  defaultExpanded,
81
79
  defaultSelected,
82
80
  disabledItemsFocusable,
83
81
  disableSelection,
84
82
  multiSelect
85
- });
83
+ };
86
84
  const classes = useUtilityClasses(ownerState);
87
85
  const treeId = useId(idProp);
88
86
  const treeRef = React.useRef(null);
@@ -515,7 +513,9 @@ const TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
515
513
  };
516
514
  }, []);
517
515
  const unregisterNode = React.useCallback(id => {
518
- const newMap = _extends({}, nodeMap.current);
516
+ const newMap = {
517
+ ...nodeMap.current
518
+ };
519
519
  delete newMap[id];
520
520
  nodeMap.current = newMap;
521
521
  setFocusedNodeId(oldFocusedNodeId => {
@@ -529,7 +529,9 @@ const TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
529
529
  firstCharMap.current[id] = firstChar;
530
530
  }, []);
531
531
  const unMapFirstChar = React.useCallback(id => {
532
- const newMap = _extends({}, firstCharMap.current);
532
+ const newMap = {
533
+ ...firstCharMap.current
534
+ };
533
535
  delete newMap[id];
534
536
  firstCharMap.current = newMap;
535
537
  }, []);
@@ -705,7 +707,7 @@ const TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
705
707
  treeId
706
708
  },
707
709
  children: /*#__PURE__*/_jsx(DescendantProvider, {
708
- children: /*#__PURE__*/_jsx(TreeViewRoot, _extends({
710
+ children: /*#__PURE__*/_jsx(TreeViewRoot, {
709
711
  role: "tree",
710
712
  id: treeId,
711
713
  "aria-activedescendant": activeDescendant,
@@ -716,10 +718,10 @@ const TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
716
718
  onKeyDown: handleKeyDown,
717
719
  onFocus: handleFocus,
718
720
  onBlur: handleBlur,
719
- ownerState: ownerState
720
- }, other, {
721
+ ownerState: ownerState,
722
+ ...other,
721
723
  children: children
722
- }))
724
+ })
723
725
  })
724
726
  });
725
727
  });
@@ -1,6 +1,3 @@
1
- import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
2
- import _extends from "@babel/runtime/helpers/esm/extends";
3
- const _excluded = ["element"];
4
1
  import * as React from 'react';
5
2
  import PropTypes from 'prop-types';
6
3
  import { unstable_useEnhancedEffect as useEnhancedEffect } from '@mui/material/utils';
@@ -98,9 +95,10 @@ export function useDescendant(descendant) {
98
95
  // Prevent any flashing
99
96
  useEnhancedEffect(() => {
100
97
  if (descendant.element) {
101
- registerDescendant(_extends({}, descendant, {
98
+ registerDescendant({
99
+ ...descendant,
102
100
  index
103
- }));
101
+ });
104
102
  return () => {
105
103
  unregisterDescendant(descendant.element);
106
104
  };
@@ -119,19 +117,19 @@ export function DescendantProvider(props) {
119
117
  id
120
118
  } = props;
121
119
  const [items, set] = React.useState([]);
122
- const registerDescendant = React.useCallback(_ref => {
123
- let {
124
- element
125
- } = _ref,
126
- other = _objectWithoutPropertiesLoose(_ref, _excluded);
120
+ const registerDescendant = React.useCallback(({
121
+ element,
122
+ ...other
123
+ }) => {
127
124
  set(oldItems => {
128
125
  let newItems;
129
126
  if (oldItems.length === 0) {
130
127
  // If there are no items, register at index 0 and bail.
131
- return [_extends({}, other, {
128
+ return [{
129
+ ...other,
132
130
  element,
133
131
  index: 0
134
- })];
132
+ }];
135
133
  }
136
134
  const index = binaryFindElement(oldItems, element);
137
135
  if (oldItems[index] && oldItems[index].element === element) {
@@ -151,10 +149,11 @@ export function DescendantProvider(props) {
151
149
  // we should be sure that this index is accurate when descendent
152
150
  // elements come or go from our component.
153
151
 
154
- const newItem = _extends({}, other, {
152
+ const newItem = {
153
+ ...other,
155
154
  element,
156
155
  index
157
- });
156
+ };
158
157
 
159
158
  // If an index is not found we will push the element to the end.
160
159
  newItems = oldItems.slice();
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/lab v5.0.0-alpha.128
2
+ * @mui/lab v5.0.0-alpha.130
3
3
  *
4
4
  * @license MIT
5
5
  * This source code is licensed under the MIT license found in the
@@ -1,4 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
2
4
  import * as React from 'react';
3
5
  import Alert from '@mui/material/Alert';
4
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -12,7 +14,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAlert(props, ref
12
14
  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'));
13
15
  warnedOnce = true;
14
16
  }
15
- return /*#__PURE__*/_jsx(Alert, _extends({
17
+ return /*#__PURE__*/_jsx(Alert, _objectSpread({
16
18
  ref: ref
17
19
  }, props));
18
20
  });
@@ -1,4 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
2
4
  import * as React from 'react';
3
5
  import AlertTitle from '@mui/material/AlertTitle';
4
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -12,7 +14,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAlertTitle(props
12
14
  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'));
13
15
  warnedOnce = true;
14
16
  }
15
- return /*#__PURE__*/_jsx(AlertTitle, _extends({
17
+ return /*#__PURE__*/_jsx(AlertTitle, _objectSpread({
16
18
  ref: ref
17
19
  }, props));
18
20
  });
@@ -1,4 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
2
4
  import * as React from 'react';
3
5
  import Autocomplete from '@mui/material/Autocomplete';
4
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -12,7 +14,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAutocomplete(pro
12
14
  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'));
13
15
  warnedOnce = true;
14
16
  }
15
- return /*#__PURE__*/_jsx(Autocomplete, _extends({
17
+ return /*#__PURE__*/_jsx(Autocomplete, _objectSpread({
16
18
  ref: ref
17
19
  }, props));
18
20
  });
@@ -1,4 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
2
4
  import * as React from 'react';
3
5
  import AvatarGroup from '@mui/material/AvatarGroup';
4
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -12,7 +14,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAvatarGroup(prop
12
14
  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'));
13
15
  warnedOnce = true;
14
16
  }
15
- return /*#__PURE__*/_jsx(AvatarGroup, _extends({
17
+ return /*#__PURE__*/_jsx(AvatarGroup, _objectSpread({
16
18
  ref: ref
17
19
  }, props));
18
20
  });
@@ -1,6 +1,7 @@
1
1
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
2
2
  import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
3
- import _extends from "@babel/runtime/helpers/esm/extends";
3
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
4
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
4
5
  import * as React from 'react';
5
6
  import PropTypes from 'prop-types';
6
7
  import { chainPropTypes } from '@mui/utils';
@@ -23,7 +24,7 @@ var useUtilityClasses = function useUtilityClasses(ownerState) {
23
24
  loadingIndicator: ['loadingIndicator', loading && "loadingIndicator".concat(capitalize(loadingPosition))]
24
25
  };
25
26
  var composedClasses = composeClasses(slots, getLoadingButtonUtilityClass, classes);
26
- return _extends({}, classes, composedClasses);
27
+ return _objectSpread(_objectSpread({}, classes), composedClasses);
27
28
  };
28
29
 
29
30
  // TODO use `import { rootShouldForwardProp } from '../styles/styled';` once move to core
@@ -42,7 +43,7 @@ var LoadingButtonRoot = styled(Button, {
42
43
  })(function (_ref3) {
43
44
  var ownerState = _ref3.ownerState,
44
45
  theme = _ref3.theme;
45
- return _extends(_defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
46
+ return _objectSpread(_objectSpread(_objectSpread(_defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
46
47
  transition: theme.transitions.create(['opacity'], {
47
48
  duration: theme.transitions.duration.short
48
49
  }),
@@ -53,13 +54,13 @@ var LoadingButtonRoot = styled(Button, {
53
54
  })
54
55
  }, "&.".concat(loadingButtonClasses.loading), {
55
56
  color: 'transparent'
56
- }), ownerState.loadingPosition === 'start' && ownerState.fullWidth && _defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
57
+ })), ownerState.loadingPosition === 'start' && ownerState.fullWidth && _defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
57
58
  transition: theme.transitions.create(['opacity'], {
58
59
  duration: theme.transitions.duration.short
59
60
  }),
60
61
  opacity: 0,
61
62
  marginRight: -8
62
- }), ownerState.loadingPosition === 'end' && ownerState.fullWidth && _defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
63
+ })), ownerState.loadingPosition === 'end' && ownerState.fullWidth && _defineProperty({}, "& .".concat(loadingButtonClasses.startIconLoadingStart, ", & .").concat(loadingButtonClasses.endIconLoadingEnd), {
63
64
  transition: theme.transitions.create(['opacity'], {
64
65
  duration: theme.transitions.duration.short
65
66
  }),
@@ -77,26 +78,26 @@ var LoadingButtonLoadingIndicator = styled('div', {
77
78
  })(function (_ref7) {
78
79
  var theme = _ref7.theme,
79
80
  ownerState = _ref7.ownerState;
80
- return _extends({
81
+ return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({
81
82
  position: 'absolute',
82
83
  visibility: 'visible',
83
84
  display: 'flex'
84
85
  }, ownerState.loadingPosition === 'start' && (ownerState.variant === 'outlined' || ownerState.variant === 'contained') && {
85
86
  left: ownerState.size === 'small' ? 10 : 14
86
- }, ownerState.loadingPosition === 'start' && ownerState.variant === 'text' && {
87
+ }), ownerState.loadingPosition === 'start' && ownerState.variant === 'text' && {
87
88
  left: 6
88
- }, ownerState.loadingPosition === 'center' && {
89
+ }), ownerState.loadingPosition === 'center' && {
89
90
  left: '50%',
90
91
  transform: 'translate(-50%)',
91
92
  color: (theme.vars || theme).palette.action.disabled
92
- }, ownerState.loadingPosition === 'end' && (ownerState.variant === 'outlined' || ownerState.variant === 'contained') && {
93
+ }), ownerState.loadingPosition === 'end' && (ownerState.variant === 'outlined' || ownerState.variant === 'contained') && {
93
94
  right: ownerState.size === 'small' ? 10 : 14
94
- }, ownerState.loadingPosition === 'end' && ownerState.variant === 'text' && {
95
+ }), ownerState.loadingPosition === 'end' && ownerState.variant === 'text' && {
95
96
  right: 6
96
- }, ownerState.loadingPosition === 'start' && ownerState.fullWidth && {
97
+ }), ownerState.loadingPosition === 'start' && ownerState.fullWidth && {
97
98
  position: 'relative',
98
99
  left: -10
99
- }, ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
100
+ }), ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
100
101
  position: 'relative',
101
102
  right: -10
102
103
  });
@@ -124,7 +125,7 @@ var LoadingButton = /*#__PURE__*/React.forwardRef(function LoadingButton(inProps
124
125
  color: "inherit",
125
126
  size: 16
126
127
  });
127
- var ownerState = _extends({}, props, {
128
+ var ownerState = _objectSpread(_objectSpread({}, props), {}, {
128
129
  disabled: disabled,
129
130
  loading: loading,
130
131
  loadingIndicator: loadingIndicator,
@@ -137,11 +138,11 @@ var LoadingButton = /*#__PURE__*/React.forwardRef(function LoadingButton(inProps
137
138
  ownerState: ownerState,
138
139
  children: loadingIndicator
139
140
  }) : null;
140
- return /*#__PURE__*/_jsxs(LoadingButtonRoot, _extends({
141
+ return /*#__PURE__*/_jsxs(LoadingButtonRoot, _objectSpread(_objectSpread({
141
142
  disabled: disabled || loading,
142
143
  id: id,
143
144
  ref: ref
144
- }, other, {
145
+ }, other), {}, {
145
146
  variant: variant,
146
147
  classes: classes,
147
148
  ownerState: ownerState,
@@ -1,7 +1,9 @@
1
1
  import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
2
2
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
3
3
  import _typeof from "@babel/runtime/helpers/esm/typeof";
4
- import _extends from "@babel/runtime/helpers/esm/extends";
4
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
5
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
6
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
5
7
  import { unstable_composeClasses as composeClasses } from '@mui/base';
6
8
  import * as ReactDOM from 'react-dom';
7
9
  import { styled, useThemeProps } from '@mui/material/styles';
@@ -54,11 +56,11 @@ export var getStyle = function getStyle(_ref) {
54
56
  }
55
57
  stylesSSR.height = ownerState.defaultHeight;
56
58
  stylesSSR.margin = -(defaultSpacing / 2);
57
- stylesSSR['& > *'] = _extends({}, styles['& > *'], orderStyleSSR, {
59
+ stylesSSR['& > *'] = _objectSpread(_objectSpread(_objectSpread({}, styles['& > *']), orderStyleSSR), {}, {
58
60
  margin: defaultSpacing / 2,
59
61
  width: "calc(".concat((100 / ownerState.defaultColumns).toFixed(2), "% - ").concat(defaultSpacing, "px)")
60
62
  });
61
- return _extends({}, styles, stylesSSR);
63
+ return _objectSpread(_objectSpread({}, styles), stylesSSR);
62
64
  }
63
65
  var spacingValues = resolveBreakpointValues({
64
66
  values: ownerState.spacing,
@@ -74,7 +76,7 @@ export var getStyle = function getStyle(_ref) {
74
76
  } else {
75
77
  spacing = propValue;
76
78
  }
77
- return _extends({
79
+ return _objectSpread({
78
80
  margin: "calc(0px - (".concat(spacing, " / 2))"),
79
81
  '& > *': {
80
82
  margin: "calc(".concat(spacing, " / 2)")
@@ -158,7 +160,7 @@ var Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
158
160
  var _React$useState2 = React.useState(isSSR ? defaultColumns - 1 : 0),
159
161
  numberOfLineBreaks = _React$useState2[0],
160
162
  setNumberOfLineBreaks = _React$useState2[1];
161
- var ownerState = _extends({}, props, {
163
+ var ownerState = _objectSpread(_objectSpread({}, props), {}, {
162
164
  spacing: spacing,
163
165
  columns: columns,
164
166
  maxColumnHeight: maxColumnHeight,
@@ -247,17 +249,17 @@ var Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
247
249
  var lineBreaks = new Array(numberOfLineBreaks).fill('').map(function (_, index) {
248
250
  return /*#__PURE__*/_jsx("span", {
249
251
  "data-class": "line-break",
250
- style: _extends({}, lineBreakStyle, {
252
+ style: _objectSpread(_objectSpread({}, lineBreakStyle), {}, {
251
253
  order: index + 1
252
254
  })
253
255
  }, index);
254
256
  });
255
- return /*#__PURE__*/_jsxs(MasonryRoot, _extends({
257
+ return /*#__PURE__*/_jsxs(MasonryRoot, _objectSpread(_objectSpread({
256
258
  as: component,
257
259
  className: clsx(classes.root, className),
258
260
  ref: handleRef,
259
261
  ownerState: ownerState
260
- }, other, {
262
+ }, other), {}, {
261
263
  children: [children, lineBreaks]
262
264
  }));
263
265
  });
@@ -1,4 +1,6 @@
1
- import _extends from "@babel/runtime/helpers/esm/extends";
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
2
4
  import * as React from 'react';
3
5
  import Pagination from '@mui/material/Pagination';
4
6
  import { jsx as _jsx } from "react/jsx-runtime";
@@ -12,7 +14,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedPagination(props
12
14
  console.warn(['MUI: The Pagination component was moved from the lab to the core.', '', "You should use `import { Pagination } from '@mui/material'`", "or `import Pagination from '@mui/material/Pagination'`"].join('\n'));
13
15
  warnedOnce = true;
14
16
  }
15
- return /*#__PURE__*/_jsx(Pagination, _extends({
17
+ return /*#__PURE__*/_jsx(Pagination, _objectSpread({
16
18
  ref: ref
17
19
  }, props));
18
20
  });