@mui/lab 6.0.0-alpha.7 → 6.0.0-alpha.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/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 +37 -2
- package/LoadingButton/LoadingButton.js +21 -19
- package/Masonry/Masonry.js +35 -30
- package/Pagination/Pagination.js +4 -4
- package/PaginationItem/PaginationItem.js +4 -4
- 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/TabList/TabList.js +6 -8
- package/TabPanel/TabPanel.js +13 -14
- package/Timeline/Timeline.js +11 -12
- package/TimelineConnector/TimelineConnector.js +7 -9
- package/TimelineContent/TimelineContent.js +15 -15
- package/TimelineDot/TimelineDot.js +38 -31
- package/TimelineItem/TimelineItem.js +33 -31
- package/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/TimelineSeparator/TimelineSeparator.js +7 -9
- package/ToggleButton/ToggleButton.js +4 -4
- package/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- package/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 +21 -19
- package/modern/Masonry/Masonry.js +35 -30
- 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 +6 -8
- package/modern/TabPanel/TabPanel.js +13 -14
- package/modern/Timeline/Timeline.js +11 -12
- package/modern/TimelineConnector/TimelineConnector.js +7 -9
- package/modern/TimelineContent/TimelineContent.js +15 -15
- package/modern/TimelineDot/TimelineDot.js +38 -31
- package/modern/TimelineItem/TimelineItem.js +33 -31
- package/modern/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/modern/TimelineSeparator/TimelineSeparator.js +7 -9
- package/modern/ToggleButton/ToggleButton.js +4 -4
- package/modern/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- 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 +21 -19
- package/node/Masonry/Masonry.js +35 -30
- 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 +6 -8
- package/node/TabPanel/TabPanel.js +13 -14
- package/node/Timeline/Timeline.js +11 -12
- package/node/TimelineConnector/TimelineConnector.js +7 -9
- package/node/TimelineContent/TimelineContent.js +15 -15
- package/node/TimelineDot/TimelineDot.js +38 -31
- package/node/TimelineItem/TimelineItem.js +33 -31
- package/node/TimelineOppositeContent/TimelineOppositeContent.js +15 -15
- package/node/TimelineSeparator/TimelineSeparator.js +7 -9
- package/node/ToggleButton/ToggleButton.js +4 -4
- package/node/ToggleButtonGroup/ToggleButtonGroup.js +4 -4
- package/node/index.js +1 -1
- package/package.json +5 -5
|
@@ -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
|
-
}) =>
|
|
37
|
+
}) => ({
|
|
41
38
|
listStyle: 'none',
|
|
42
39
|
display: 'flex',
|
|
43
40
|
position: 'relative',
|
|
44
|
-
minHeight: 70
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
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
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
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
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
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 =
|
|
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,
|
|
94
|
+
children: /*#__PURE__*/_jsx(TimelineItemRoot, {
|
|
94
95
|
className: clsx(classes.root, className),
|
|
95
96
|
ownerState: ownerState,
|
|
96
|
-
ref: ref
|
|
97
|
-
|
|
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
|
-
}) =>
|
|
34
|
+
}) => ({
|
|
38
35
|
padding: '6px 16px',
|
|
39
36
|
marginRight: 'auto',
|
|
40
37
|
textAlign: 'right',
|
|
41
|
-
flex: 1
|
|
42
|
-
|
|
43
|
-
|
|
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
|
-
|
|
52
|
-
|
|
53
|
-
|
|
49
|
+
className,
|
|
50
|
+
...other
|
|
51
|
+
} = props;
|
|
54
52
|
const {
|
|
55
53
|
position: positionContext
|
|
56
54
|
} = React.useContext(TimelineContext);
|
|
57
|
-
const ownerState =
|
|
55
|
+
const ownerState = {
|
|
56
|
+
...props,
|
|
58
57
|
position: positionContext || 'left'
|
|
59
|
-
}
|
|
58
|
+
};
|
|
60
59
|
const classes = useUtilityClasses(ownerState);
|
|
61
|
-
return /*#__PURE__*/_jsx(TimelineOppositeContentRoot,
|
|
60
|
+
return /*#__PURE__*/_jsx(TimelineOppositeContentRoot, {
|
|
62
61
|
component: "div",
|
|
63
62
|
className: clsx(classes.root, className),
|
|
64
63
|
ownerState: ownerState,
|
|
65
|
-
ref: ref
|
|
66
|
-
|
|
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
|
-
|
|
39
|
-
|
|
40
|
-
|
|
35
|
+
className,
|
|
36
|
+
...other
|
|
37
|
+
} = props;
|
|
41
38
|
const ownerState = props;
|
|
42
39
|
const classes = useUtilityClasses(ownerState);
|
|
43
|
-
return /*#__PURE__*/_jsx(TimelineSeparatorRoot,
|
|
40
|
+
return /*#__PURE__*/_jsx(TimelineSeparatorRoot, {
|
|
44
41
|
className: clsx(classes.root, className),
|
|
45
42
|
ownerState: ownerState,
|
|
46
|
-
ref: ref
|
|
47
|
-
|
|
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,
|
|
18
|
-
ref: ref
|
|
19
|
-
|
|
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,
|
|
18
|
-
ref: ref
|
|
19
|
-
|
|
16
|
+
return /*#__PURE__*/_jsx(ToggleButtonGroup, {
|
|
17
|
+
ref: ref,
|
|
18
|
+
...props
|
|
19
|
+
});
|
|
20
20
|
});
|
package/modern/index.js
CHANGED
package/node/Alert/Alert.js
CHANGED
|
@@ -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,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
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,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
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,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
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,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_AvatarGroup.default, {
|
|
25
|
+
ref: ref,
|
|
26
|
+
...props
|
|
27
|
+
});
|
|
28
28
|
});
|
|
@@ -6,8 +6,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.default = void 0;
|
|
9
|
-
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
10
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
9
|
var React = _interopRequireWildcard(require("react"));
|
|
12
10
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
13
11
|
var _utils = require("@mui/utils");
|
|
@@ -20,7 +18,6 @@ var _resolveProps = _interopRequireDefault(require("@mui/utils/resolveProps"));
|
|
|
20
18
|
var _zeroStyled = require("../zero-styled");
|
|
21
19
|
var _loadingButtonClasses = _interopRequireWildcard(require("./loadingButtonClasses"));
|
|
22
20
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
23
|
-
const _excluded = ["children", "disabled", "id", "loading", "loadingIndicator", "loadingPosition", "variant"];
|
|
24
21
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
25
22
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
26
23
|
const useThemeProps = (0, _zeroStyled.createUseThemeProps)('MuiLoadingButton');
|
|
@@ -37,7 +34,11 @@ const useUtilityClasses = ownerState => {
|
|
|
37
34
|
loadingIndicator: ['loadingIndicator', loading && `loadingIndicator${(0, _utils2.capitalize)(loadingPosition)}`]
|
|
38
35
|
};
|
|
39
36
|
const composedClasses = (0, _base.unstable_composeClasses)(slots, _loadingButtonClasses.getLoadingButtonUtilityClass, classes);
|
|
40
|
-
return
|
|
37
|
+
return {
|
|
38
|
+
...classes,
|
|
39
|
+
// forward the outlined, color, etc. classes to Button
|
|
40
|
+
...composedClasses
|
|
41
|
+
};
|
|
41
42
|
};
|
|
42
43
|
|
|
43
44
|
// TODO use `import rootShouldForwardProp from '../styles/rootShouldForwardProp';` once move to core
|
|
@@ -200,44 +201,45 @@ const LoadingButton = /*#__PURE__*/React.forwardRef(function LoadingButton(inPro
|
|
|
200
201
|
name: 'MuiLoadingButton'
|
|
201
202
|
});
|
|
202
203
|
const {
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
204
|
+
children,
|
|
205
|
+
disabled = false,
|
|
206
|
+
id: idProp,
|
|
207
|
+
loading = false,
|
|
208
|
+
loadingIndicator: loadingIndicatorProp,
|
|
209
|
+
loadingPosition = 'center',
|
|
210
|
+
variant = 'text',
|
|
211
|
+
...other
|
|
212
|
+
} = props;
|
|
212
213
|
const id = (0, _utils2.unstable_useId)(idProp);
|
|
213
214
|
const loadingIndicator = loadingIndicatorProp != null ? loadingIndicatorProp : /*#__PURE__*/(0, _jsxRuntime.jsx)(_CircularProgress.default, {
|
|
214
215
|
"aria-labelledby": id,
|
|
215
216
|
color: "inherit",
|
|
216
217
|
size: 16
|
|
217
218
|
});
|
|
218
|
-
const ownerState =
|
|
219
|
+
const ownerState = {
|
|
220
|
+
...props,
|
|
219
221
|
disabled,
|
|
220
222
|
loading,
|
|
221
223
|
loadingIndicator,
|
|
222
224
|
loadingPosition,
|
|
223
225
|
variant
|
|
224
|
-
}
|
|
226
|
+
};
|
|
225
227
|
const classes = useUtilityClasses(ownerState);
|
|
226
228
|
const loadingButtonLoadingIndicator = loading ? /*#__PURE__*/(0, _jsxRuntime.jsx)(LoadingButtonLoadingIndicator, {
|
|
227
229
|
className: classes.loadingIndicator,
|
|
228
230
|
ownerState: ownerState,
|
|
229
231
|
children: loadingIndicator
|
|
230
232
|
}) : null;
|
|
231
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(LoadingButtonRoot,
|
|
233
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(LoadingButtonRoot, {
|
|
232
234
|
disabled: disabled || loading,
|
|
233
235
|
id: id,
|
|
234
|
-
ref: ref
|
|
235
|
-
|
|
236
|
+
ref: ref,
|
|
237
|
+
...other,
|
|
236
238
|
variant: variant,
|
|
237
239
|
classes: classes,
|
|
238
240
|
ownerState: ownerState,
|
|
239
241
|
children: [ownerState.loadingPosition === 'end' ? children : loadingButtonLoadingIndicator, ownerState.loadingPosition === 'end' ? loadingButtonLoadingIndicator : children]
|
|
240
|
-
})
|
|
242
|
+
});
|
|
241
243
|
});
|
|
242
244
|
process.env.NODE_ENV !== "production" ? LoadingButton.propTypes /* remove-proptypes */ = {
|
|
243
245
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
package/node/Masonry/Masonry.js
CHANGED
|
@@ -6,8 +6,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.parseToNumber = exports.getStyle = exports.default = void 0;
|
|
9
|
-
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
10
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
9
|
var _base = require("@mui/base");
|
|
12
10
|
var ReactDOM = _interopRequireWildcard(require("react-dom"));
|
|
13
11
|
var _styles = require("@mui/material/styles");
|
|
@@ -18,7 +16,6 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
18
16
|
var React = _interopRequireWildcard(require("react"));
|
|
19
17
|
var _masonryClasses = require("./masonryClasses");
|
|
20
18
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
21
|
-
const _excluded = ["children", "className", "component", "columns", "spacing", "sequential", "defaultColumns", "defaultHeight", "defaultSpacing"];
|
|
22
19
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
23
20
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
24
21
|
const parseToNumber = val => {
|
|
@@ -66,11 +63,16 @@ const getStyle = ({
|
|
|
66
63
|
}
|
|
67
64
|
stylesSSR.height = ownerState.defaultHeight;
|
|
68
65
|
stylesSSR.margin = -(defaultSpacing / 2);
|
|
69
|
-
stylesSSR['& > *'] =
|
|
66
|
+
stylesSSR['& > *'] = {
|
|
67
|
+
...styles['& > *'],
|
|
68
|
+
...orderStyleSSR,
|
|
70
69
|
margin: defaultSpacing / 2,
|
|
71
70
|
width: `calc(${(100 / ownerState.defaultColumns).toFixed(2)}% - ${defaultSpacing}px)`
|
|
72
|
-
}
|
|
73
|
-
return
|
|
71
|
+
};
|
|
72
|
+
return {
|
|
73
|
+
...styles,
|
|
74
|
+
...stylesSSR
|
|
75
|
+
};
|
|
74
76
|
}
|
|
75
77
|
const spacingValues = (0, _system.unstable_resolveBreakpointValues)({
|
|
76
78
|
values: ownerState.spacing,
|
|
@@ -86,14 +88,15 @@ const getStyle = ({
|
|
|
86
88
|
} else {
|
|
87
89
|
spacing = propValue;
|
|
88
90
|
}
|
|
89
|
-
return
|
|
91
|
+
return {
|
|
90
92
|
margin: `calc(0px - (${spacing} / 2))`,
|
|
91
93
|
'& > *': {
|
|
92
94
|
margin: `calc(${spacing} / 2)`
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
95
|
+
},
|
|
96
|
+
...(ownerState.maxColumnHeight && {
|
|
97
|
+
height: typeof spacing === 'number' ? Math.ceil(ownerState.maxColumnHeight + parseToNumber(spacing)) : `calc(${ownerState.maxColumnHeight}px + ${spacing})`
|
|
98
|
+
})
|
|
99
|
+
};
|
|
97
100
|
};
|
|
98
101
|
styles = (0, _utils.deepmerge)(styles, (0, _system.handleBreakpoints)({
|
|
99
102
|
theme
|
|
@@ -152,22 +155,23 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
152
155
|
name: 'MuiMasonry'
|
|
153
156
|
});
|
|
154
157
|
const {
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
158
|
+
children,
|
|
159
|
+
className,
|
|
160
|
+
component = 'div',
|
|
161
|
+
columns = 4,
|
|
162
|
+
spacing = 1,
|
|
163
|
+
sequential = false,
|
|
164
|
+
defaultColumns,
|
|
165
|
+
defaultHeight,
|
|
166
|
+
defaultSpacing,
|
|
167
|
+
...other
|
|
168
|
+
} = props;
|
|
166
169
|
const masonryRef = React.useRef();
|
|
167
170
|
const [maxColumnHeight, setMaxColumnHeight] = React.useState();
|
|
168
171
|
const isSSR = !maxColumnHeight && defaultHeight && defaultColumns !== undefined && defaultSpacing !== undefined;
|
|
169
172
|
const [numberOfLineBreaks, setNumberOfLineBreaks] = React.useState(isSSR ? defaultColumns - 1 : 0);
|
|
170
|
-
const ownerState =
|
|
173
|
+
const ownerState = {
|
|
174
|
+
...props,
|
|
171
175
|
spacing,
|
|
172
176
|
columns,
|
|
173
177
|
maxColumnHeight,
|
|
@@ -175,7 +179,7 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
175
179
|
defaultHeight,
|
|
176
180
|
defaultSpacing,
|
|
177
181
|
isSSR
|
|
178
|
-
}
|
|
182
|
+
};
|
|
179
183
|
const classes = useUtilityClasses(ownerState);
|
|
180
184
|
const handleResize = React.useCallback(masonryChildren => {
|
|
181
185
|
if (!masonryRef.current || !masonryChildren || masonryChildren.length === 0) {
|
|
@@ -273,18 +277,19 @@ const Masonry = /*#__PURE__*/React.forwardRef(function Masonry(inProps, ref) {
|
|
|
273
277
|
// a line break at the end of each column prevents columns from merging
|
|
274
278
|
const lineBreaks = new Array(numberOfLineBreaks).fill('').map((_, index) => /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
|
|
275
279
|
"data-class": "line-break",
|
|
276
|
-
style:
|
|
280
|
+
style: {
|
|
281
|
+
...lineBreakStyle,
|
|
277
282
|
order: index + 1
|
|
278
|
-
}
|
|
283
|
+
}
|
|
279
284
|
}, index));
|
|
280
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(MasonryRoot,
|
|
285
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(MasonryRoot, {
|
|
281
286
|
as: component,
|
|
282
287
|
className: (0, _clsx.default)(classes.root, className),
|
|
283
288
|
ref: handleRef,
|
|
284
|
-
ownerState: ownerState
|
|
285
|
-
|
|
289
|
+
ownerState: ownerState,
|
|
290
|
+
...other,
|
|
286
291
|
children: [children, lineBreaks]
|
|
287
|
-
})
|
|
292
|
+
});
|
|
288
293
|
});
|
|
289
294
|
process.env.NODE_ENV !== "production" ? Masonry.propTypes /* remove-proptypes */ = {
|
|
290
295
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
@@ -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 _Pagination = _interopRequireDefault(require("@mui/material/Pagination"));
|
|
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 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'));
|
|
23
22
|
warnedOnce = true;
|
|
24
23
|
}
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Pagination.default,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Pagination.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 _PaginationItem = _interopRequireDefault(require("@mui/material/PaginationItem"));
|
|
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 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'));
|
|
23
22
|
warnedOnce = true;
|
|
24
23
|
}
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_PaginationItem.default,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_PaginationItem.default, {
|
|
25
|
+
ref: ref,
|
|
26
|
+
...props
|
|
27
|
+
});
|
|
28
28
|
});
|
package/node/Rating/Rating.js
CHANGED
|
@@ -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 _Rating = _interopRequireDefault(require("@mui/material/Rating"));
|
|
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 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'));
|
|
23
22
|
warnedOnce = true;
|
|
24
23
|
}
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Rating.default,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Rating.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 _Skeleton = _interopRequireDefault(require("@mui/material/Skeleton"));
|
|
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 Skeleton component was moved from the lab to the core.', '', "You should use `import { Skeleton } from '@mui/material'`", "or `import Skeleton from '@mui/material/Skeleton'`"].join('\n'));
|
|
23
22
|
warnedOnce = true;
|
|
24
23
|
}
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Skeleton.default,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Skeleton.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 _SpeedDial = _interopRequireDefault(require("@mui/material/SpeedDial"));
|
|
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 SpeedDial component was moved from the lab to the core.', '', "You should use `import { SpeedDial } from '@mui/material'`", "or `import SpeedDial from '@mui/material/SpeedDial'`"].join('\n'));
|
|
23
22
|
warnedOnce = true;
|
|
24
23
|
}
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SpeedDial.default,
|
|
26
|
-
ref: ref
|
|
27
|
-
|
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SpeedDial.default, {
|
|
25
|
+
ref: ref,
|
|
26
|
+
...props
|
|
27
|
+
});
|
|
28
28
|
});
|