@mui/lab 5.0.0-alpha.130 → 5.0.0-alpha.131
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/AdapterDateFns/AdapterDateFns.d.ts +3 -3
- package/AdapterDateFns/index.d.ts +1 -1
- package/AdapterDayjs/AdapterDayjs.d.ts +3 -3
- package/AdapterDayjs/index.d.ts +1 -1
- package/AdapterLuxon/AdapterLuxon.d.ts +3 -3
- package/AdapterLuxon/index.d.ts +1 -1
- package/AdapterMoment/AdapterMoment.d.ts +3 -3
- package/AdapterMoment/index.d.ts +1 -1
- package/Alert/Alert.js +4 -4
- package/AlertTitle/AlertTitle.js +4 -4
- package/Autocomplete/Autocomplete.js +4 -4
- package/AvatarGroup/AvatarGroup.js +4 -4
- package/CHANGELOG.md +41 -0
- package/CalendarPicker/CalendarPicker.d.ts +14 -14
- package/CalendarPicker/index.d.ts +2 -2
- package/CalendarPickerSkeleton/CalendarPickerSkeleton.d.ts +13 -13
- package/CalendarPickerSkeleton/index.d.ts +2 -2
- package/ClockPicker/ClockPicker.d.ts +14 -14
- package/ClockPicker/index.d.ts +2 -2
- package/DatePicker/DatePicker.d.ts +10 -10
- package/DatePicker/index.d.ts +2 -2
- package/DateRangePicker/DateRangePicker.d.ts +11 -11
- package/DateRangePicker/index.d.ts +2 -2
- package/DateRangePickerDay/DateRangePickerDay.d.ts +13 -13
- package/DateRangePickerDay/index.d.ts +2 -2
- package/DateTimePicker/DateTimePicker.d.ts +10 -10
- package/DateTimePicker/index.d.ts +2 -2
- package/DesktopDatePicker/DesktopDatePicker.d.ts +10 -10
- package/DesktopDatePicker/index.d.ts +2 -2
- package/DesktopDateRangePicker/DesktopDateRangePicker.d.ts +10 -10
- package/DesktopDateRangePicker/index.d.ts +2 -2
- package/DesktopDateTimePicker/DesktopDateTimePicker.d.ts +10 -10
- package/DesktopDateTimePicker/index.d.ts +2 -2
- package/DesktopTimePicker/DesktopTimePicker.d.ts +10 -10
- package/DesktopTimePicker/index.d.ts +2 -2
- package/LoadingButton/LoadingButton.js +62 -74
- package/LoadingButton/loadingButtonClasses.d.ts +22 -22
- package/LocalizationProvider/LocalizationProvider.d.ts +10 -10
- package/LocalizationProvider/index.d.ts +2 -2
- package/Masonry/Masonry.js +29 -34
- package/Masonry/masonryClasses.d.ts +8 -8
- package/MobileDatePicker/MobileDatePicker.d.ts +10 -10
- package/MobileDatePicker/index.d.ts +2 -2
- package/MobileDateRangePicker/MobileDateRangePicker.d.ts +10 -10
- package/MobileDateRangePicker/index.d.ts +2 -2
- package/MobileDateTimePicker/MobileDateTimePicker.d.ts +10 -10
- package/MobileDateTimePicker/index.d.ts +2 -2
- package/MobileTimePicker/MobileTimePicker.d.ts +10 -10
- package/MobileTimePicker/index.d.ts +2 -2
- package/MonthPicker/MonthPicker.d.ts +13 -13
- package/MonthPicker/index.d.ts +2 -2
- package/Pagination/Pagination.js +4 -4
- package/PaginationItem/PaginationItem.js +4 -4
- package/PickersDay/PickersDay.d.ts +13 -13
- package/PickersDay/index.d.ts +2 -2
- package/Rating/Rating.js +4 -4
- package/Skeleton/Skeleton.js +4 -4
- package/SpeedDial/SpeedDial.js +4 -4
- package/SpeedDialAction/SpeedDialAction.js +4 -4
- package/SpeedDialIcon/SpeedDialIcon.js +4 -4
- package/StaticDatePicker/StaticDatePicker.d.ts +10 -10
- package/StaticDatePicker/index.d.ts +2 -2
- package/StaticDateRangePicker/StaticDateRangePicker.d.ts +10 -10
- package/StaticDateRangePicker/index.d.ts +2 -2
- package/StaticDateTimePicker/StaticDateTimePicker.d.ts +10 -10
- package/StaticDateTimePicker/index.d.ts +2 -2
- package/StaticTimePicker/StaticTimePicker.d.ts +10 -10
- package/StaticTimePicker/index.d.ts +2 -2
- package/TabList/TabList.js +8 -6
- package/TabPanel/TabPanel.js +13 -12
- package/TabPanel/tabPanelClasses.d.ts +8 -8
- package/TimePicker/TimePicker.d.ts +10 -10
- package/TimePicker/index.d.ts +2 -2
- package/Timeline/Timeline.d.ts +59 -59
- package/Timeline/Timeline.js +12 -11
- package/Timeline/TimelineContext.d.ts +6 -6
- package/Timeline/index.d.ts +5 -5
- package/Timeline/timelineClasses.d.ts +3 -3
- package/TimelineConnector/TimelineConnector.js +9 -7
- package/TimelineConnector/timelineConnectorClasses.d.ts +8 -8
- package/TimelineContent/TimelineContent.js +15 -15
- package/TimelineContent/timelineContentClasses.d.ts +14 -14
- package/TimelineDot/TimelineDot.js +31 -38
- package/TimelineDot/timelineDotClasses.d.ts +24 -24
- package/TimelineItem/TimelineItem.js +31 -33
- package/TimelineItem/timelineItemClasses.d.ts +16 -16
- package/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/TimelineOppositeContent/timelineOppositeContentClasses.d.ts +14 -14
- package/TimelineSeparator/TimelineSeparator.js +9 -7
- package/TimelineSeparator/timelineSeparatorClasses.d.ts +8 -8
- package/ToggleButton/ToggleButton.js +4 -4
- package/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- package/TreeItem/TreeItem.js +37 -37
- package/TreeItem/TreeItemContent.js +18 -15
- package/TreeItem/treeItemClasses.d.ts +24 -24
- package/TreeView/TreeView.js +33 -35
- package/TreeView/descendants.js +14 -13
- package/TreeView/treeViewClasses.d.ts +8 -8
- package/YearPicker/YearPicker.d.ts +14 -14
- package/YearPicker/index.d.ts +2 -2
- package/index.js +1 -1
- package/internal/svg-icons/ArrowDropDown.d.ts +7 -7
- package/internal/svg-icons/ArrowLeft.d.ts +7 -7
- package/internal/svg-icons/ArrowRight.d.ts +7 -7
- package/internal/svg-icons/Calendar.d.ts +7 -7
- package/internal/svg-icons/Clock.d.ts +7 -7
- package/internal/svg-icons/DateRange.d.ts +7 -7
- package/internal/svg-icons/Pen.d.ts +7 -7
- package/internal/svg-icons/Time.d.ts +7 -7
- package/legacy/Alert/Alert.js +2 -4
- package/legacy/AlertTitle/AlertTitle.js +2 -4
- package/legacy/Autocomplete/Autocomplete.js +2 -4
- package/legacy/AvatarGroup/AvatarGroup.js +2 -4
- package/legacy/LoadingButton/LoadingButton.js +15 -16
- package/legacy/Masonry/Masonry.js +8 -10
- package/legacy/Pagination/Pagination.js +2 -4
- package/legacy/PaginationItem/PaginationItem.js +2 -4
- package/legacy/Rating/Rating.js +2 -4
- package/legacy/Skeleton/Skeleton.js +2 -4
- package/legacy/SpeedDial/SpeedDial.js +2 -4
- package/legacy/SpeedDialAction/SpeedDialAction.js +2 -4
- package/legacy/SpeedDialIcon/SpeedDialIcon.js +2 -4
- package/legacy/TabList/TabList.js +2 -4
- package/legacy/TabPanel/TabPanel.js +4 -6
- package/legacy/Timeline/Timeline.js +3 -5
- package/legacy/TimelineConnector/TimelineConnector.js +2 -4
- package/legacy/TimelineContent/TimelineContent.js +4 -6
- package/legacy/TimelineDot/TimelineDot.js +8 -10
- package/legacy/TimelineItem/TimelineItem.js +6 -7
- package/legacy/TimelineOppositeContent/TimelineOppositeContent.js +4 -6
- package/legacy/TimelineSeparator/TimelineSeparator.js +2 -4
- package/legacy/ToggleButton/ToggleButton.js +2 -4
- package/legacy/ToggleButtonGroup/ToggleButtonGroup.js +2 -4
- package/legacy/TreeItem/TreeItem.js +8 -9
- package/legacy/TreeItem/TreeItemContent.js +3 -5
- package/legacy/TreeView/TreeView.js +6 -8
- package/legacy/TreeView/descendants.js +4 -6
- package/legacy/index.js +1 -1
- package/modern/Alert/Alert.js +4 -4
- package/modern/AlertTitle/AlertTitle.js +4 -4
- package/modern/Autocomplete/Autocomplete.js +4 -4
- package/modern/AvatarGroup/AvatarGroup.js +4 -4
- package/modern/LoadingButton/LoadingButton.js +62 -74
- package/modern/Masonry/Masonry.js +29 -34
- package/modern/Pagination/Pagination.js +4 -4
- package/modern/PaginationItem/PaginationItem.js +4 -4
- package/modern/Rating/Rating.js +4 -4
- package/modern/Skeleton/Skeleton.js +4 -4
- package/modern/SpeedDial/SpeedDial.js +4 -4
- package/modern/SpeedDialAction/SpeedDialAction.js +4 -4
- package/modern/SpeedDialIcon/SpeedDialIcon.js +4 -4
- package/modern/TabList/TabList.js +8 -6
- package/modern/TabPanel/TabPanel.js +13 -12
- package/modern/Timeline/Timeline.js +12 -11
- package/modern/TimelineConnector/TimelineConnector.js +9 -7
- package/modern/TimelineContent/TimelineContent.js +15 -15
- package/modern/TimelineDot/TimelineDot.js +31 -38
- package/modern/TimelineItem/TimelineItem.js +31 -33
- package/modern/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/modern/TimelineSeparator/TimelineSeparator.js +9 -7
- package/modern/ToggleButton/ToggleButton.js +4 -4
- package/modern/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- package/modern/TreeItem/TreeItem.js +37 -37
- package/modern/TreeItem/TreeItemContent.js +18 -15
- package/modern/TreeView/TreeView.js +33 -35
- package/modern/TreeView/descendants.js +14 -13
- package/modern/index.js +1 -1
- package/node/Alert/Alert.js +4 -4
- package/node/AlertTitle/AlertTitle.js +4 -4
- package/node/Autocomplete/Autocomplete.js +4 -4
- package/node/AvatarGroup/AvatarGroup.js +4 -4
- package/node/LoadingButton/LoadingButton.js +62 -74
- package/node/Masonry/Masonry.js +29 -34
- package/node/Pagination/Pagination.js +4 -4
- package/node/PaginationItem/PaginationItem.js +4 -4
- package/node/Rating/Rating.js +4 -4
- package/node/Skeleton/Skeleton.js +4 -4
- package/node/SpeedDial/SpeedDial.js +4 -4
- package/node/SpeedDialAction/SpeedDialAction.js +4 -4
- package/node/SpeedDialIcon/SpeedDialIcon.js +4 -4
- package/node/TabList/TabList.js +8 -6
- package/node/TabPanel/TabPanel.js +13 -12
- package/node/Timeline/Timeline.js +12 -13
- package/node/TimelineConnector/TimelineConnector.js +9 -7
- package/node/TimelineContent/TimelineContent.js +15 -15
- package/node/TimelineDot/TimelineDot.js +31 -38
- package/node/TimelineItem/TimelineItem.js +31 -33
- package/node/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/node/TimelineSeparator/TimelineSeparator.js +9 -7
- package/node/ToggleButton/ToggleButton.js +4 -4
- package/node/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- package/node/TreeItem/TreeItem.js +37 -37
- package/node/TreeItem/TreeItemContent.js +22 -18
- package/node/TreeView/TreeView.js +33 -35
- package/node/TreeView/descendants.js +16 -16
- package/node/index.js +1 -1
- package/package.json +3 -3
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import
|
|
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; }
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
4
2
|
import * as React from 'react';
|
|
5
3
|
import ToggleButtonGroup from '@mui/material/ToggleButtonGroup';
|
|
6
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -14,7 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedToggleButtonGrou
|
|
|
14
12
|
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
13
|
warnedOnce = true;
|
|
16
14
|
}
|
|
17
|
-
return /*#__PURE__*/_jsx(ToggleButtonGroup,
|
|
15
|
+
return /*#__PURE__*/_jsx(ToggleButtonGroup, _extends({
|
|
18
16
|
ref: ref
|
|
19
17
|
}, props));
|
|
20
18
|
});
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
3
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
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; }
|
|
5
4
|
import * as React from 'react';
|
|
6
5
|
import clsx from 'clsx';
|
|
7
6
|
import PropTypes from 'prop-types';
|
|
@@ -91,7 +90,7 @@ var StyledTreeItemContent = styled(TreeItemContent, {
|
|
|
91
90
|
'& svg': {
|
|
92
91
|
fontSize: 18
|
|
93
92
|
}
|
|
94
|
-
}), _defineProperty(_ref4, "& .".concat(treeItemClasses.label),
|
|
93
|
+
}), _defineProperty(_ref4, "& .".concat(treeItemClasses.label), _extends({
|
|
95
94
|
width: '100%',
|
|
96
95
|
// fixes overflow - see https://github.com/mui/material-ui/issues/27372
|
|
97
96
|
minWidth: 0,
|
|
@@ -174,7 +173,7 @@ var TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
|
|
|
174
173
|
var focused = isFocused ? isFocused(nodeId) : false;
|
|
175
174
|
var selected = isSelected ? isSelected(nodeId) : false;
|
|
176
175
|
var disabled = isDisabled ? isDisabled(nodeId) : false;
|
|
177
|
-
var ownerState =
|
|
176
|
+
var ownerState = _extends({}, props, {
|
|
178
177
|
expanded: expanded,
|
|
179
178
|
focused: focused,
|
|
180
179
|
selected: selected,
|
|
@@ -251,7 +250,7 @@ var TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
|
|
|
251
250
|
focus(event, nodeId);
|
|
252
251
|
}
|
|
253
252
|
}
|
|
254
|
-
return /*#__PURE__*/_jsxs(TreeItemRoot,
|
|
253
|
+
return /*#__PURE__*/_jsxs(TreeItemRoot, _extends({
|
|
255
254
|
className: clsx(classes.root, className),
|
|
256
255
|
role: "treeitem",
|
|
257
256
|
"aria-expanded": expandable ? expanded : null,
|
|
@@ -260,10 +259,10 @@ var TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
|
|
|
260
259
|
ref: handleRef,
|
|
261
260
|
id: id,
|
|
262
261
|
tabIndex: -1
|
|
263
|
-
}, other
|
|
262
|
+
}, other, {
|
|
264
263
|
ownerState: ownerState,
|
|
265
264
|
onFocus: handleFocus,
|
|
266
|
-
children: [/*#__PURE__*/_jsx(StyledTreeItemContent,
|
|
265
|
+
children: [/*#__PURE__*/_jsx(StyledTreeItemContent, _extends({
|
|
267
266
|
as: ContentComponent,
|
|
268
267
|
ref: contentRef,
|
|
269
268
|
classes: {
|
|
@@ -285,14 +284,14 @@ var TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(inProps, ref) {
|
|
|
285
284
|
ownerState: ownerState
|
|
286
285
|
}, ContentProps)), children && /*#__PURE__*/_jsx(DescendantProvider, {
|
|
287
286
|
id: nodeId,
|
|
288
|
-
children: /*#__PURE__*/_jsx(TreeItemGroup,
|
|
287
|
+
children: /*#__PURE__*/_jsx(TreeItemGroup, _extends({
|
|
289
288
|
as: TransitionComponent,
|
|
290
289
|
unmountOnExit: true,
|
|
291
290
|
className: classes.group,
|
|
292
291
|
in: expanded,
|
|
293
292
|
component: "ul",
|
|
294
293
|
role: "group"
|
|
295
|
-
}, TransitionProps
|
|
294
|
+
}, TransitionProps, {
|
|
296
295
|
children: children
|
|
297
296
|
}))
|
|
298
297
|
})]
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
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; }
|
|
5
3
|
import * as React from 'react';
|
|
6
4
|
import clsx from 'clsx';
|
|
7
5
|
import PropTypes from 'prop-types';
|
|
@@ -48,12 +46,12 @@ var TreeItemContent = /*#__PURE__*/React.forwardRef(function TreeItemContent(pro
|
|
|
48
46
|
return (
|
|
49
47
|
/*#__PURE__*/
|
|
50
48
|
/* eslint-disable-next-line jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions -- Key event is handled by the TreeView */
|
|
51
|
-
_jsxs("div",
|
|
49
|
+
_jsxs("div", _extends({
|
|
52
50
|
className: clsx(className, classes.root, expanded && classes.expanded, selected && classes.selected, focused && classes.focused, disabled && classes.disabled),
|
|
53
51
|
onClick: handleClick,
|
|
54
52
|
onMouseDown: handleMouseDown,
|
|
55
53
|
ref: ref
|
|
56
|
-
}, other
|
|
54
|
+
}, other, {
|
|
57
55
|
children: [/*#__PURE__*/_jsx("div", {
|
|
58
56
|
className: classes.iconContainer,
|
|
59
57
|
children: icon
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
|
-
import
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
-
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; }
|
|
5
|
-
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; }
|
|
6
4
|
import * as React from 'react';
|
|
7
5
|
import clsx from 'clsx';
|
|
8
6
|
import PropTypes from 'prop-types';
|
|
@@ -81,7 +79,7 @@ var TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
|
|
|
81
79
|
other = _objectWithoutProperties(props, ["children", "className", "defaultCollapseIcon", "defaultEndIcon", "defaultExpanded", "defaultExpandIcon", "defaultParentIcon", "defaultSelected", "disabledItemsFocusable", "disableSelection", "expanded", "id", "multiSelect", "onBlur", "onFocus", "onKeyDown", "onNodeFocus", "onNodeSelect", "onNodeToggle", "selected"]);
|
|
82
80
|
var theme = useTheme();
|
|
83
81
|
var isRtl = theme.direction === 'rtl';
|
|
84
|
-
var ownerState =
|
|
82
|
+
var ownerState = _extends({}, props, {
|
|
85
83
|
defaultExpanded: defaultExpanded,
|
|
86
84
|
defaultSelected: defaultSelected,
|
|
87
85
|
disabledItemsFocusable: disabledItemsFocusable,
|
|
@@ -571,7 +569,7 @@ var TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
|
|
|
571
569
|
};
|
|
572
570
|
}, []);
|
|
573
571
|
var unregisterNode = React.useCallback(function (id) {
|
|
574
|
-
var newMap =
|
|
572
|
+
var newMap = _extends({}, nodeMap.current);
|
|
575
573
|
delete newMap[id];
|
|
576
574
|
nodeMap.current = newMap;
|
|
577
575
|
setFocusedNodeId(function (oldFocusedNodeId) {
|
|
@@ -585,7 +583,7 @@ var TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
|
|
|
585
583
|
firstCharMap.current[id] = firstChar;
|
|
586
584
|
}, []);
|
|
587
585
|
var unMapFirstChar = React.useCallback(function (id) {
|
|
588
|
-
var newMap =
|
|
586
|
+
var newMap = _extends({}, firstCharMap.current);
|
|
589
587
|
delete newMap[id];
|
|
590
588
|
firstCharMap.current = newMap;
|
|
591
589
|
}, []);
|
|
@@ -761,7 +759,7 @@ var TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
|
|
|
761
759
|
treeId: treeId
|
|
762
760
|
},
|
|
763
761
|
children: /*#__PURE__*/_jsx(DescendantProvider, {
|
|
764
|
-
children: /*#__PURE__*/_jsx(TreeViewRoot,
|
|
762
|
+
children: /*#__PURE__*/_jsx(TreeViewRoot, _extends({
|
|
765
763
|
role: "tree",
|
|
766
764
|
id: treeId,
|
|
767
765
|
"aria-activedescendant": activeDescendant,
|
|
@@ -773,7 +771,7 @@ var TreeView = /*#__PURE__*/React.forwardRef(function TreeView(inProps, ref) {
|
|
|
773
771
|
onFocus: handleFocus,
|
|
774
772
|
onBlur: handleBlur,
|
|
775
773
|
ownerState: ownerState
|
|
776
|
-
}, other
|
|
774
|
+
}, other, {
|
|
777
775
|
children: children
|
|
778
776
|
}))
|
|
779
777
|
})
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
|
-
import
|
|
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; }
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
5
3
|
import * as React from 'react';
|
|
6
4
|
import PropTypes from 'prop-types';
|
|
7
5
|
import { unstable_useEnhancedEffect as useEnhancedEffect } from '@mui/material/utils';
|
|
@@ -103,7 +101,7 @@ export function useDescendant(descendant) {
|
|
|
103
101
|
// Prevent any flashing
|
|
104
102
|
useEnhancedEffect(function () {
|
|
105
103
|
if (descendant.element) {
|
|
106
|
-
registerDescendant(
|
|
104
|
+
registerDescendant(_extends({}, descendant, {
|
|
107
105
|
index: index
|
|
108
106
|
}));
|
|
109
107
|
return function () {
|
|
@@ -131,7 +129,7 @@ export function DescendantProvider(props) {
|
|
|
131
129
|
var newItems;
|
|
132
130
|
if (oldItems.length === 0) {
|
|
133
131
|
// If there are no items, register at index 0 and bail.
|
|
134
|
-
return [
|
|
132
|
+
return [_extends({}, other, {
|
|
135
133
|
element: element,
|
|
136
134
|
index: 0
|
|
137
135
|
})];
|
|
@@ -154,7 +152,7 @@ export function DescendantProvider(props) {
|
|
|
154
152
|
// we should be sure that this index is accurate when descendent
|
|
155
153
|
// elements come or go from our component.
|
|
156
154
|
|
|
157
|
-
var newItem =
|
|
155
|
+
var newItem = _extends({}, other, {
|
|
158
156
|
element: element,
|
|
159
157
|
index: index
|
|
160
158
|
});
|
package/legacy/index.js
CHANGED
package/modern/Alert/Alert.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import Alert from '@mui/material/Alert';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAlert(props, ref
|
|
|
11
12
|
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'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(Alert, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(Alert, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import AlertTitle from '@mui/material/AlertTitle';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAlertTitle(props
|
|
|
11
12
|
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'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(AlertTitle, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(AlertTitle, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import Autocomplete from '@mui/material/Autocomplete';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAutocomplete(pro
|
|
|
11
12
|
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'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(Autocomplete, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(Autocomplete, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import AvatarGroup from '@mui/material/AvatarGroup';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedAvatarGroup(prop
|
|
|
11
12
|
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'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(AvatarGroup, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(AvatarGroup, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
|
+
const _excluded = ["children", "disabled", "id", "loading", "loadingIndicator", "loadingPosition", "variant"];
|
|
1
4
|
import * as React from 'react';
|
|
2
5
|
import PropTypes from 'prop-types';
|
|
3
6
|
import { chainPropTypes } from '@mui/utils';
|
|
@@ -22,11 +25,7 @@ const useUtilityClasses = ownerState => {
|
|
|
22
25
|
loadingIndicator: ['loadingIndicator', loading && `loadingIndicator${capitalize(loadingPosition)}`]
|
|
23
26
|
};
|
|
24
27
|
const composedClasses = composeClasses(slots, getLoadingButtonUtilityClass, classes);
|
|
25
|
-
return {
|
|
26
|
-
...classes,
|
|
27
|
-
// forward the outlined, color, etc. classes to Button
|
|
28
|
-
...composedClasses
|
|
29
|
-
};
|
|
28
|
+
return _extends({}, classes, composedClasses);
|
|
30
29
|
};
|
|
31
30
|
|
|
32
31
|
// TODO use `import { rootShouldForwardProp } from '../styles/styled';` once move to core
|
|
@@ -45,39 +44,36 @@ const LoadingButtonRoot = styled(Button, {
|
|
|
45
44
|
})(({
|
|
46
45
|
ownerState,
|
|
47
46
|
theme
|
|
48
|
-
}) => ({
|
|
47
|
+
}) => _extends({
|
|
49
48
|
[`& .${loadingButtonClasses.startIconLoadingStart}, & .${loadingButtonClasses.endIconLoadingEnd}`]: {
|
|
50
49
|
transition: theme.transitions.create(['opacity'], {
|
|
51
50
|
duration: theme.transitions.duration.short
|
|
52
51
|
}),
|
|
53
52
|
opacity: 0
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
|
|
53
|
+
}
|
|
54
|
+
}, ownerState.loadingPosition === 'center' && {
|
|
55
|
+
transition: theme.transitions.create(['background-color', 'box-shadow', 'border-color'], {
|
|
56
|
+
duration: theme.transitions.duration.short
|
|
57
|
+
}),
|
|
58
|
+
[`&.${loadingButtonClasses.loading}`]: {
|
|
59
|
+
color: 'transparent'
|
|
60
|
+
}
|
|
61
|
+
}, ownerState.loadingPosition === 'start' && ownerState.fullWidth && {
|
|
62
|
+
[`& .${loadingButtonClasses.startIconLoadingStart}, & .${loadingButtonClasses.endIconLoadingEnd}`]: {
|
|
63
|
+
transition: theme.transitions.create(['opacity'], {
|
|
57
64
|
duration: theme.transitions.duration.short
|
|
58
65
|
}),
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
}),
|
|
72
|
-
...(ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
|
|
73
|
-
[`& .${loadingButtonClasses.startIconLoadingStart}, & .${loadingButtonClasses.endIconLoadingEnd}`]: {
|
|
74
|
-
transition: theme.transitions.create(['opacity'], {
|
|
75
|
-
duration: theme.transitions.duration.short
|
|
76
|
-
}),
|
|
77
|
-
opacity: 0,
|
|
78
|
-
marginLeft: -8
|
|
79
|
-
}
|
|
80
|
-
})
|
|
66
|
+
opacity: 0,
|
|
67
|
+
marginRight: -8
|
|
68
|
+
}
|
|
69
|
+
}, ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
|
|
70
|
+
[`& .${loadingButtonClasses.startIconLoadingStart}, & .${loadingButtonClasses.endIconLoadingEnd}`]: {
|
|
71
|
+
transition: theme.transitions.create(['opacity'], {
|
|
72
|
+
duration: theme.transitions.duration.short
|
|
73
|
+
}),
|
|
74
|
+
opacity: 0,
|
|
75
|
+
marginLeft: -8
|
|
76
|
+
}
|
|
81
77
|
}));
|
|
82
78
|
const LoadingButtonLoadingIndicator = styled('div', {
|
|
83
79
|
name: 'MuiLoadingButton',
|
|
@@ -91,35 +87,28 @@ const LoadingButtonLoadingIndicator = styled('div', {
|
|
|
91
87
|
})(({
|
|
92
88
|
theme,
|
|
93
89
|
ownerState
|
|
94
|
-
}) => ({
|
|
90
|
+
}) => _extends({
|
|
95
91
|
position: 'absolute',
|
|
96
92
|
visibility: 'visible',
|
|
97
|
-
display: 'flex'
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
position: 'relative',
|
|
117
|
-
left: -10
|
|
118
|
-
}),
|
|
119
|
-
...(ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
|
|
120
|
-
position: 'relative',
|
|
121
|
-
right: -10
|
|
122
|
-
})
|
|
93
|
+
display: 'flex'
|
|
94
|
+
}, ownerState.loadingPosition === 'start' && (ownerState.variant === 'outlined' || ownerState.variant === 'contained') && {
|
|
95
|
+
left: ownerState.size === 'small' ? 10 : 14
|
|
96
|
+
}, ownerState.loadingPosition === 'start' && ownerState.variant === 'text' && {
|
|
97
|
+
left: 6
|
|
98
|
+
}, ownerState.loadingPosition === 'center' && {
|
|
99
|
+
left: '50%',
|
|
100
|
+
transform: 'translate(-50%)',
|
|
101
|
+
color: (theme.vars || theme).palette.action.disabled
|
|
102
|
+
}, ownerState.loadingPosition === 'end' && (ownerState.variant === 'outlined' || ownerState.variant === 'contained') && {
|
|
103
|
+
right: ownerState.size === 'small' ? 10 : 14
|
|
104
|
+
}, ownerState.loadingPosition === 'end' && ownerState.variant === 'text' && {
|
|
105
|
+
right: 6
|
|
106
|
+
}, ownerState.loadingPosition === 'start' && ownerState.fullWidth && {
|
|
107
|
+
position: 'relative',
|
|
108
|
+
left: -10
|
|
109
|
+
}, ownerState.loadingPosition === 'end' && ownerState.fullWidth && {
|
|
110
|
+
position: 'relative',
|
|
111
|
+
right: -10
|
|
123
112
|
}));
|
|
124
113
|
const LoadingButton = /*#__PURE__*/React.forwardRef(function LoadingButton(inProps, ref) {
|
|
125
114
|
const props = useThemeProps({
|
|
@@ -127,45 +116,44 @@ const LoadingButton = /*#__PURE__*/React.forwardRef(function LoadingButton(inPro
|
|
|
127
116
|
name: 'MuiLoadingButton'
|
|
128
117
|
});
|
|
129
118
|
const {
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
119
|
+
children,
|
|
120
|
+
disabled = false,
|
|
121
|
+
id: idProp,
|
|
122
|
+
loading = false,
|
|
123
|
+
loadingIndicator: loadingIndicatorProp,
|
|
124
|
+
loadingPosition = 'center',
|
|
125
|
+
variant = 'text'
|
|
126
|
+
} = props,
|
|
127
|
+
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
139
128
|
const id = useId(idProp);
|
|
140
129
|
const loadingIndicator = loadingIndicatorProp ?? /*#__PURE__*/_jsx(CircularProgress, {
|
|
141
130
|
"aria-labelledby": id,
|
|
142
131
|
color: "inherit",
|
|
143
132
|
size: 16
|
|
144
133
|
});
|
|
145
|
-
const ownerState = {
|
|
146
|
-
...props,
|
|
134
|
+
const ownerState = _extends({}, props, {
|
|
147
135
|
disabled,
|
|
148
136
|
loading,
|
|
149
137
|
loadingIndicator,
|
|
150
138
|
loadingPosition,
|
|
151
139
|
variant
|
|
152
|
-
};
|
|
140
|
+
});
|
|
153
141
|
const classes = useUtilityClasses(ownerState);
|
|
154
142
|
const loadingButtonLoadingIndicator = loading ? /*#__PURE__*/_jsx(LoadingButtonLoadingIndicator, {
|
|
155
143
|
className: classes.loadingIndicator,
|
|
156
144
|
ownerState: ownerState,
|
|
157
145
|
children: loadingIndicator
|
|
158
146
|
}) : null;
|
|
159
|
-
return /*#__PURE__*/_jsxs(LoadingButtonRoot, {
|
|
147
|
+
return /*#__PURE__*/_jsxs(LoadingButtonRoot, _extends({
|
|
160
148
|
disabled: disabled || loading,
|
|
161
149
|
id: id,
|
|
162
|
-
ref: ref
|
|
163
|
-
|
|
150
|
+
ref: ref
|
|
151
|
+
}, other, {
|
|
164
152
|
variant: variant,
|
|
165
153
|
classes: classes,
|
|
166
154
|
ownerState: ownerState,
|
|
167
155
|
children: [ownerState.loadingPosition === 'end' ? children : loadingButtonLoadingIndicator, ownerState.loadingPosition === 'end' ? loadingButtonLoadingIndicator : children]
|
|
168
|
-
});
|
|
156
|
+
}));
|
|
169
157
|
});
|
|
170
158
|
process.env.NODE_ENV !== "production" ? LoadingButton.propTypes /* remove-proptypes */ = {
|
|
171
159
|
// ----------------------------- Warning --------------------------------
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
2
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
3
|
+
const _excluded = ["children", "className", "component", "columns", "spacing", "defaultColumns", "defaultHeight", "defaultSpacing"];
|
|
1
4
|
import { unstable_composeClasses as composeClasses } from '@mui/base';
|
|
2
5
|
import * as ReactDOM from 'react-dom';
|
|
3
6
|
import { styled, useThemeProps } from '@mui/material/styles';
|
|
@@ -53,16 +56,11 @@ export const getStyle = ({
|
|
|
53
56
|
}
|
|
54
57
|
stylesSSR.height = ownerState.defaultHeight;
|
|
55
58
|
stylesSSR.margin = -(defaultSpacing / 2);
|
|
56
|
-
stylesSSR['& > *'] = {
|
|
57
|
-
...styles['& > *'],
|
|
58
|
-
...orderStyleSSR,
|
|
59
|
+
stylesSSR['& > *'] = _extends({}, styles['& > *'], orderStyleSSR, {
|
|
59
60
|
margin: defaultSpacing / 2,
|
|
60
61
|
width: `calc(${(100 / ownerState.defaultColumns).toFixed(2)}% - ${defaultSpacing}px)`
|
|
61
|
-
};
|
|
62
|
-
return {
|
|
63
|
-
...styles,
|
|
64
|
-
...stylesSSR
|
|
65
|
-
};
|
|
62
|
+
});
|
|
63
|
+
return _extends({}, styles, stylesSSR);
|
|
66
64
|
}
|
|
67
65
|
const spacingValues = resolveBreakpointValues({
|
|
68
66
|
values: ownerState.spacing,
|
|
@@ -78,15 +76,14 @@ export const getStyle = ({
|
|
|
78
76
|
} else {
|
|
79
77
|
spacing = propValue;
|
|
80
78
|
}
|
|
81
|
-
return {
|
|
79
|
+
return _extends({
|
|
82
80
|
margin: `calc(0px - (${spacing} / 2))`,
|
|
83
81
|
'& > *': {
|
|
84
82
|
margin: `calc(${spacing} / 2)`
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
};
|
|
83
|
+
}
|
|
84
|
+
}, ownerState.maxColumnHeight && {
|
|
85
|
+
height: typeof spacing === 'number' ? Math.ceil(ownerState.maxColumnHeight + parseToNumber(spacing)) : `calc(${ownerState.maxColumnHeight}px + ${spacing})`
|
|
86
|
+
});
|
|
90
87
|
};
|
|
91
88
|
styles = deepmerge(styles, handleBreakpoints({
|
|
92
89
|
theme
|
|
@@ -144,22 +141,21 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
144
141
|
name: 'MuiMasonry'
|
|
145
142
|
});
|
|
146
143
|
const {
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
144
|
+
children,
|
|
145
|
+
className,
|
|
146
|
+
component = 'div',
|
|
147
|
+
columns = 4,
|
|
148
|
+
spacing = 1,
|
|
149
|
+
defaultColumns,
|
|
150
|
+
defaultHeight,
|
|
151
|
+
defaultSpacing
|
|
152
|
+
} = props,
|
|
153
|
+
other = _objectWithoutPropertiesLoose(props, _excluded);
|
|
157
154
|
const masonryRef = React.useRef();
|
|
158
155
|
const [maxColumnHeight, setMaxColumnHeight] = React.useState();
|
|
159
156
|
const isSSR = !maxColumnHeight && defaultHeight && defaultColumns !== undefined && defaultSpacing !== undefined;
|
|
160
157
|
const [numberOfLineBreaks, setNumberOfLineBreaks] = React.useState(isSSR ? defaultColumns - 1 : 0);
|
|
161
|
-
const ownerState = {
|
|
162
|
-
...props,
|
|
158
|
+
const ownerState = _extends({}, props, {
|
|
163
159
|
spacing,
|
|
164
160
|
columns,
|
|
165
161
|
maxColumnHeight,
|
|
@@ -167,7 +163,7 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
167
163
|
defaultHeight,
|
|
168
164
|
defaultSpacing,
|
|
169
165
|
isSSR
|
|
170
|
-
};
|
|
166
|
+
});
|
|
171
167
|
const classes = useUtilityClasses(ownerState);
|
|
172
168
|
const handleResize = masonryChildren => {
|
|
173
169
|
if (!masonryRef.current || !masonryChildren || masonryChildren.length === 0) {
|
|
@@ -245,19 +241,18 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
245
241
|
// a line break at the end of each column prevents columns from merging
|
|
246
242
|
const lineBreaks = new Array(numberOfLineBreaks).fill('').map((_, index) => /*#__PURE__*/_jsx("span", {
|
|
247
243
|
"data-class": "line-break",
|
|
248
|
-
style: {
|
|
249
|
-
...lineBreakStyle,
|
|
244
|
+
style: _extends({}, lineBreakStyle, {
|
|
250
245
|
order: index + 1
|
|
251
|
-
}
|
|
246
|
+
})
|
|
252
247
|
}, index));
|
|
253
|
-
return /*#__PURE__*/_jsxs(MasonryRoot, {
|
|
248
|
+
return /*#__PURE__*/_jsxs(MasonryRoot, _extends({
|
|
254
249
|
as: component,
|
|
255
250
|
className: clsx(classes.root, className),
|
|
256
251
|
ref: handleRef,
|
|
257
|
-
ownerState: ownerState
|
|
258
|
-
|
|
252
|
+
ownerState: ownerState
|
|
253
|
+
}, other, {
|
|
259
254
|
children: [children, lineBreaks]
|
|
260
|
-
});
|
|
255
|
+
}));
|
|
261
256
|
});
|
|
262
257
|
process.env.NODE_ENV !== "production" ? Masonry.propTypes /* remove-proptypes */ = {
|
|
263
258
|
// ----------------------------- Warning --------------------------------
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import Pagination from '@mui/material/Pagination';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedPagination(props
|
|
|
11
12
|
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'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(Pagination, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(Pagination, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import PaginationItem from '@mui/material/PaginationItem';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedPaginationItem(p
|
|
|
11
12
|
console.warn(['MUI: The PaginationItem component was moved from the lab to the core.', '', "You should use `import { PaginationItem } from '@mui/material'`", "or `import PaginationItem from '@mui/material/PaginationItem'`"].join('\n'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(PaginationItem, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(PaginationItem, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|
package/modern/Rating/Rating.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
1
2
|
import * as React from 'react';
|
|
2
3
|
import Rating from '@mui/material/Rating';
|
|
3
4
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -11,8 +12,7 @@ export default /*#__PURE__*/React.forwardRef(function DeprecatedRating(props, re
|
|
|
11
12
|
console.warn(['MUI: The Rating component was moved from the lab to the core.', '', "You should use `import { Rating } from '@mui/material'`", "or `import Rating from '@mui/material/Rating'`"].join('\n'));
|
|
12
13
|
warnedOnce = true;
|
|
13
14
|
}
|
|
14
|
-
return /*#__PURE__*/_jsx(Rating, {
|
|
15
|
-
ref: ref
|
|
16
|
-
|
|
17
|
-
});
|
|
15
|
+
return /*#__PURE__*/_jsx(Rating, _extends({
|
|
16
|
+
ref: ref
|
|
17
|
+
}, props));
|
|
18
18
|
});
|