@mui/material 6.0.0-alpha.4 → 6.0.0-alpha.6
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/Accordion/Accordion.d.ts +2 -2
- package/Accordion/Accordion.js +2 -2
- package/AccordionSummary/accordionSummaryClasses.d.ts +1 -1
- package/Alert/Alert.d.ts +2 -2
- package/Alert/Alert.js +2 -2
- package/Alert/alertClasses.d.ts +12 -12
- package/Avatar/Avatar.d.ts +1 -1
- package/Avatar/Avatar.js +1 -1
- package/Backdrop/Backdrop.d.ts +1 -1
- package/Backdrop/Backdrop.js +1 -1
- package/Badge/Badge.d.ts +2 -2
- package/Badge/Badge.js +2 -2
- package/Breadcrumbs/BreadcrumbCollapsed.js +1 -1
- package/Button/Button.js +1 -1
- package/Button/buttonClasses.d.ts +33 -33
- package/ButtonGroup/buttonGroupClasses.d.ts +17 -17
- package/CHANGELOG.md +86 -0
- package/Checkbox/Checkbox.js +3 -1
- package/Chip/chipClasses.d.ts +28 -26
- package/Chip/chipClasses.js +1 -1
- package/Collapse/Collapse.js +66 -35
- package/Dialog/Dialog.js +105 -61
- package/DialogActions/DialogActions.js +16 -12
- package/DialogContent/DialogContent.js +25 -15
- package/DialogContentText/DialogContentText.js +3 -2
- package/DialogTitle/DialogTitle.js +2 -2
- package/Divider/Divider.d.ts +1 -1
- package/Divider/Divider.js +1 -1
- package/Drawer/Drawer.js +73 -32
- package/Fab/Fab.js +1 -1
- package/FilledInput/FilledInput.d.ts +1 -0
- package/FilledInput/FilledInput.js +170 -87
- package/FormControlLabel/FormControlLabel.d.ts +21 -14
- package/FormControlLabel/FormControlLabel.js +22 -4
- package/FormHelperText/FormHelperText.js +2 -2
- package/FormLabel/FormLabel.js +23 -13
- package/Grow/Grow.js +3 -1
- package/Icon/Icon.js +63 -23
- package/ImageList/ImageList.js +2 -2
- package/ImageListItem/ImageListItem.js +2 -2
- package/ImageListItemBar/ImageListItemBar.js +2 -2
- package/Input/Input.d.ts +1 -0
- package/Input/Input.js +84 -61
- package/InputAdornment/InputAdornment.js +37 -21
- package/InputBase/InputBase.js +58 -28
- package/InputLabel/InputLabel.js +120 -58
- package/Link/Link.js +99 -54
- package/Link/getTextDecoration.d.ts +2 -8
- package/Link/getTextDecoration.js +16 -8
- package/List/List.js +22 -13
- package/ListItem/ListItem.js +2 -2
- package/ListItemAvatar/ListItemAvatar.js +2 -2
- package/ListItemButton/ListItemButton.js +3 -2
- package/ListItemIcon/ListItemIcon.js +14 -9
- package/ListItemSecondaryAction/ListItemSecondaryAction.js +2 -2
- package/ListItemText/ListItemText.js +2 -2
- package/ListSubheader/ListSubheader.js +5 -3
- package/Menu/Menu.js +3 -2
- package/MenuItem/MenuItem.js +47 -27
- package/NativeSelect/NativeSelectInput.js +78 -49
- package/OutlinedInput/NotchedOutline.js +60 -43
- package/OutlinedInput/OutlinedInput.js +97 -39
- package/Pagination/Pagination.js +2 -2
- package/PaginationItem/PaginationItem.d.ts +26 -14
- package/PaginationItem/PaginationItem.js +64 -20
- package/PaginationItem/paginationItemClasses.d.ts +4 -4
- package/Paper/Paper.js +44 -21
- package/Radio/Radio.js +5 -3
- package/Radio/RadioButtonIcon.js +1 -1
- package/Rating/Rating.js +3 -2
- package/Select/Select.js +2 -1
- package/Select/SelectInput.js +8 -6
- package/Skeleton/Skeleton.js +109 -61
- package/Slider/Slider.d.ts +2 -2
- package/Slider/Slider.js +2 -2
- package/Snackbar/Snackbar.js +66 -40
- package/SnackbarContent/SnackbarContent.js +2 -2
- package/SpeedDial/SpeedDial.d.ts +28 -1
- package/SpeedDial/SpeedDial.js +107 -49
- package/SpeedDialAction/SpeedDialAction.js +50 -24
- package/SpeedDialIcon/SpeedDialIcon.js +37 -16
- package/StepConnector/stepConnectorClasses.d.ts +2 -2
- package/StepLabel/StepLabel.d.ts +3 -3
- package/StepLabel/StepLabel.js +3 -3
- package/SvgIcon/SvgIcon.js +73 -21
- package/SwipeableDrawer/SwipeArea.js +39 -18
- package/Tab/Tab.js +127 -55
- package/TabScrollButton/TabScrollButton.js +27 -15
- package/Table/Table.js +2 -2
- package/TableBody/TableBody.js +2 -2
- package/TableCell/TableCell.js +2 -2
- package/TableContainer/TableContainer.js +2 -2
- package/TableFooter/TableFooter.js +2 -2
- package/TableHead/TableHead.js +2 -2
- package/TablePagination/TablePagination.js +2 -2
- package/TableRow/TableRow.js +2 -2
- package/TableSortLabel/TableSortLabel.js +2 -2
- package/Tabs/Tabs.js +107 -54
- package/TextField/TextField.js +2 -2
- package/ToggleButtonGroup/toggleButtonGroupClasses.d.ts +2 -2
- package/Toolbar/Toolbar.js +3 -7
- package/Tooltip/Tooltip.js +185 -88
- package/Typography/Typography.js +89 -39
- package/index.js +1 -1
- package/internal/SwitchBase.js +39 -11
- package/modern/Accordion/Accordion.js +2 -2
- package/modern/Alert/Alert.js +2 -2
- package/modern/Avatar/Avatar.js +1 -1
- package/modern/Backdrop/Backdrop.js +1 -1
- package/modern/Badge/Badge.js +2 -2
- package/modern/Breadcrumbs/BreadcrumbCollapsed.js +1 -1
- package/modern/Button/Button.js +1 -1
- package/modern/Checkbox/Checkbox.js +3 -1
- package/modern/Chip/chipClasses.js +1 -1
- package/modern/Collapse/Collapse.js +66 -35
- package/modern/Dialog/Dialog.js +105 -61
- package/modern/DialogActions/DialogActions.js +16 -12
- package/modern/DialogContent/DialogContent.js +25 -15
- package/modern/DialogContentText/DialogContentText.js +3 -2
- package/modern/DialogTitle/DialogTitle.js +2 -2
- package/modern/Divider/Divider.js +1 -1
- package/modern/Drawer/Drawer.js +73 -32
- package/modern/Fab/Fab.js +1 -1
- package/modern/FilledInput/FilledInput.js +170 -87
- package/modern/FormControlLabel/FormControlLabel.js +22 -4
- package/modern/FormHelperText/FormHelperText.js +2 -2
- package/modern/FormLabel/FormLabel.js +23 -13
- package/modern/Grow/Grow.js +3 -1
- package/modern/Icon/Icon.js +63 -23
- package/modern/ImageList/ImageList.js +2 -2
- package/modern/ImageListItem/ImageListItem.js +2 -2
- package/modern/ImageListItemBar/ImageListItemBar.js +2 -2
- package/modern/Input/Input.js +84 -61
- package/modern/InputAdornment/InputAdornment.js +37 -21
- package/modern/InputBase/InputBase.js +58 -28
- package/modern/InputLabel/InputLabel.js +120 -58
- package/modern/Link/Link.js +99 -54
- package/modern/Link/getTextDecoration.js +16 -8
- package/modern/List/List.js +22 -13
- package/modern/ListItem/ListItem.js +2 -2
- package/modern/ListItemAvatar/ListItemAvatar.js +2 -2
- package/modern/ListItemButton/ListItemButton.js +3 -2
- package/modern/ListItemIcon/ListItemIcon.js +14 -9
- package/modern/ListItemSecondaryAction/ListItemSecondaryAction.js +2 -2
- package/modern/ListItemText/ListItemText.js +2 -2
- package/modern/ListSubheader/ListSubheader.js +5 -3
- package/modern/Menu/Menu.js +3 -2
- package/modern/MenuItem/MenuItem.js +47 -27
- package/modern/NativeSelect/NativeSelectInput.js +78 -49
- package/modern/OutlinedInput/NotchedOutline.js +60 -43
- package/modern/OutlinedInput/OutlinedInput.js +97 -39
- package/modern/Pagination/Pagination.js +2 -2
- package/modern/PaginationItem/PaginationItem.js +64 -20
- package/modern/Paper/Paper.js +44 -21
- package/modern/Radio/Radio.js +5 -3
- package/modern/Radio/RadioButtonIcon.js +1 -1
- package/modern/Rating/Rating.js +3 -2
- package/modern/Select/Select.js +2 -1
- package/modern/Select/SelectInput.js +8 -6
- package/modern/Skeleton/Skeleton.js +109 -61
- package/modern/Slider/Slider.js +2 -2
- package/modern/Snackbar/Snackbar.js +66 -40
- package/modern/SnackbarContent/SnackbarContent.js +2 -2
- package/modern/SpeedDial/SpeedDial.js +107 -49
- package/modern/SpeedDialAction/SpeedDialAction.js +50 -24
- package/modern/SpeedDialIcon/SpeedDialIcon.js +37 -16
- package/modern/StepLabel/StepLabel.js +3 -3
- package/modern/SvgIcon/SvgIcon.js +73 -21
- package/modern/SwipeableDrawer/SwipeArea.js +39 -18
- package/modern/Tab/Tab.js +127 -55
- package/modern/TabScrollButton/TabScrollButton.js +27 -15
- package/modern/Table/Table.js +2 -2
- package/modern/TableBody/TableBody.js +2 -2
- package/modern/TableCell/TableCell.js +2 -2
- package/modern/TableContainer/TableContainer.js +2 -2
- package/modern/TableFooter/TableFooter.js +2 -2
- package/modern/TableHead/TableHead.js +2 -2
- package/modern/TablePagination/TablePagination.js +2 -2
- package/modern/TableRow/TableRow.js +2 -2
- package/modern/TableSortLabel/TableSortLabel.js +2 -2
- package/modern/Tabs/Tabs.js +107 -54
- package/modern/TextField/TextField.js +2 -2
- package/modern/Toolbar/Toolbar.js +3 -7
- package/modern/Tooltip/Tooltip.js +185 -88
- package/modern/Typography/Typography.js +89 -39
- package/modern/index.js +1 -1
- package/modern/internal/SwitchBase.js +39 -11
- package/node/Accordion/Accordion.js +2 -2
- package/node/Alert/Alert.js +2 -2
- package/node/Avatar/Avatar.js +1 -1
- package/node/Backdrop/Backdrop.js +1 -1
- package/node/Badge/Badge.js +2 -2
- package/node/Breadcrumbs/BreadcrumbCollapsed.js +3 -3
- package/node/Button/Button.js +2 -2
- package/node/Checkbox/Checkbox.js +3 -1
- package/node/Chip/chipClasses.js +1 -1
- package/node/Collapse/Collapse.js +70 -39
- package/node/Dialog/Dialog.js +110 -66
- package/node/DialogActions/DialogActions.js +18 -14
- package/node/DialogContent/DialogContent.js +27 -17
- package/node/DialogContentText/DialogContentText.js +6 -5
- package/node/DialogTitle/DialogTitle.js +4 -4
- package/node/Divider/Divider.js +1 -1
- package/node/Drawer/Drawer.js +78 -37
- package/node/Fab/Fab.js +2 -2
- package/node/FilledInput/FilledInput.js +176 -91
- package/node/FormControlLabel/FormControlLabel.js +23 -5
- package/node/FormHelperText/FormHelperText.js +4 -4
- package/node/FormLabel/FormLabel.js +26 -16
- package/node/Grow/Grow.js +3 -1
- package/node/Icon/Icon.js +65 -25
- package/node/ImageList/ImageList.js +4 -4
- package/node/ImageListItem/ImageListItem.js +4 -4
- package/node/ImageListItemBar/ImageListItemBar.js +8 -8
- package/node/Input/Input.js +87 -64
- package/node/InputAdornment/InputAdornment.js +39 -23
- package/node/InputBase/InputBase.js +61 -31
- package/node/InputLabel/InputLabel.js +123 -61
- package/node/Link/Link.js +101 -56
- package/node/Link/getTextDecoration.js +18 -10
- package/node/List/List.js +24 -15
- package/node/ListItem/ListItem.js +5 -5
- package/node/ListItemAvatar/ListItemAvatar.js +4 -4
- package/node/ListItemButton/ListItemButton.js +6 -5
- package/node/ListItemIcon/ListItemIcon.js +16 -11
- package/node/ListItemSecondaryAction/ListItemSecondaryAction.js +4 -4
- package/node/ListItemText/ListItemText.js +4 -4
- package/node/ListSubheader/ListSubheader.js +7 -5
- package/node/Menu/Menu.js +8 -7
- package/node/MenuItem/MenuItem.js +50 -30
- package/node/NativeSelect/NativeSelectInput.js +80 -53
- package/node/OutlinedInput/NotchedOutline.js +64 -47
- package/node/OutlinedInput/OutlinedInput.js +101 -43
- package/node/Pagination/Pagination.js +5 -5
- package/node/PaginationItem/PaginationItem.js +65 -20
- package/node/Paper/Paper.js +49 -28
- package/node/Radio/Radio.js +6 -4
- package/node/Radio/RadioButtonIcon.js +2 -2
- package/node/Rating/Rating.js +9 -8
- package/node/Select/Select.js +6 -5
- package/node/Select/SelectInput.js +9 -7
- package/node/Skeleton/Skeleton.js +113 -65
- package/node/Slider/Slider.js +2 -2
- package/node/Snackbar/Snackbar.js +68 -42
- package/node/SnackbarContent/SnackbarContent.js +6 -6
- package/node/SpeedDial/SpeedDial.js +111 -53
- package/node/SpeedDialAction/SpeedDialAction.js +54 -28
- package/node/SpeedDialIcon/SpeedDialIcon.js +39 -18
- package/node/StepLabel/StepLabel.js +3 -3
- package/node/SvgIcon/SvgIcon.js +79 -24
- package/node/SwipeableDrawer/SwipeArea.js +41 -20
- package/node/Tab/Tab.js +129 -57
- package/node/TabScrollButton/TabScrollButton.js +29 -17
- package/node/Table/Table.js +4 -4
- package/node/TableBody/TableBody.js +4 -4
- package/node/TableCell/TableCell.js +4 -4
- package/node/TableContainer/TableContainer.js +4 -4
- package/node/TableFooter/TableFooter.js +4 -4
- package/node/TableHead/TableHead.js +4 -4
- package/node/TablePagination/TablePagination.js +10 -10
- package/node/TableRow/TableRow.js +4 -4
- package/node/TableSortLabel/TableSortLabel.js +5 -5
- package/node/Tabs/Tabs.js +113 -60
- package/node/TextField/TextField.js +4 -4
- package/node/Toolbar/Toolbar.js +5 -9
- package/node/Tooltip/Tooltip.js +189 -92
- package/node/Typography/Typography.js +90 -40
- package/node/index.js +1 -1
- package/node/internal/SwitchBase.js +41 -13
- package/package.json +6 -6
- package/umd/material-ui.development.js +2777 -1334
- package/umd/material-ui.production.min.js +4 -4
|
@@ -21,9 +21,10 @@ var _FirstPage = _interopRequireDefault(require("../internal/svg-icons/FirstPage
|
|
|
21
21
|
var _LastPage = _interopRequireDefault(require("../internal/svg-icons/LastPage"));
|
|
22
22
|
var _NavigateBefore = _interopRequireDefault(require("../internal/svg-icons/NavigateBefore"));
|
|
23
23
|
var _NavigateNext = _interopRequireDefault(require("../internal/svg-icons/NavigateNext"));
|
|
24
|
+
var _useSlot = _interopRequireDefault(require("../utils/useSlot"));
|
|
24
25
|
var _zeroStyled = require("../zero-styled");
|
|
25
26
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
26
|
-
const _excluded = ["className", "color", "component", "components", "disabled", "page", "selected", "shape", "size", "slots", "type", "variant"];
|
|
27
|
+
const _excluded = ["className", "color", "component", "components", "disabled", "page", "selected", "shape", "size", "slots", "slotProps", "type", "variant"];
|
|
27
28
|
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); }
|
|
28
29
|
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; }
|
|
29
30
|
const useThemeProps = (0, _zeroStyled.createUseThemeProps)('MuiPaginationItem');
|
|
@@ -274,6 +275,7 @@ const PaginationItemPageIcon = (0, _zeroStyled.styled)('div', {
|
|
|
274
275
|
}]
|
|
275
276
|
}));
|
|
276
277
|
const PaginationItem = /*#__PURE__*/React.forwardRef(function PaginationItem(inProps, ref) {
|
|
278
|
+
var _slots$previous, _slots$next, _slots$first, _slots$last;
|
|
277
279
|
const props = useThemeProps({
|
|
278
280
|
props: inProps,
|
|
279
281
|
name: 'MuiPaginationItem'
|
|
@@ -289,6 +291,7 @@ const PaginationItem = /*#__PURE__*/React.forwardRef(function PaginationItem(inP
|
|
|
289
291
|
shape = 'circular',
|
|
290
292
|
size = 'medium',
|
|
291
293
|
slots = {},
|
|
294
|
+
slotProps = {},
|
|
292
295
|
type = 'page',
|
|
293
296
|
variant = 'text'
|
|
294
297
|
} = props,
|
|
@@ -304,18 +307,53 @@ const PaginationItem = /*#__PURE__*/React.forwardRef(function PaginationItem(inP
|
|
|
304
307
|
});
|
|
305
308
|
const isRtl = (0, _RtlProvider.useRtl)();
|
|
306
309
|
const classes = useUtilityClasses(ownerState);
|
|
307
|
-
const
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
first: slots.first || components.first || _FirstPage.default,
|
|
316
|
-
last: slots.last || components.last || _LastPage.default
|
|
310
|
+
const externalForwardedProps = {
|
|
311
|
+
slots: {
|
|
312
|
+
previous: (_slots$previous = slots.previous) != null ? _slots$previous : components.previous,
|
|
313
|
+
next: (_slots$next = slots.next) != null ? _slots$next : components.next,
|
|
314
|
+
first: (_slots$first = slots.first) != null ? _slots$first : components.first,
|
|
315
|
+
last: (_slots$last = slots.last) != null ? _slots$last : components.last
|
|
316
|
+
},
|
|
317
|
+
slotProps
|
|
317
318
|
};
|
|
318
|
-
const
|
|
319
|
+
const [PreviousSlot, previousSlotProps] = (0, _useSlot.default)('previous', {
|
|
320
|
+
elementType: _NavigateBefore.default,
|
|
321
|
+
externalForwardedProps,
|
|
322
|
+
ownerState
|
|
323
|
+
});
|
|
324
|
+
const [NextSlot, nextSlotProps] = (0, _useSlot.default)('next', {
|
|
325
|
+
elementType: _NavigateNext.default,
|
|
326
|
+
externalForwardedProps,
|
|
327
|
+
ownerState
|
|
328
|
+
});
|
|
329
|
+
const [FirstSlot, firstSlotProps] = (0, _useSlot.default)('first', {
|
|
330
|
+
elementType: _FirstPage.default,
|
|
331
|
+
externalForwardedProps,
|
|
332
|
+
ownerState
|
|
333
|
+
});
|
|
334
|
+
const [LastSlot, lastSlotProps] = (0, _useSlot.default)('last', {
|
|
335
|
+
elementType: _LastPage.default,
|
|
336
|
+
externalForwardedProps,
|
|
337
|
+
ownerState
|
|
338
|
+
});
|
|
339
|
+
const rtlAwareType = isRtl ? {
|
|
340
|
+
previous: 'next',
|
|
341
|
+
next: 'previous',
|
|
342
|
+
first: 'last',
|
|
343
|
+
last: 'first'
|
|
344
|
+
}[type] : type;
|
|
345
|
+
const IconSlot = {
|
|
346
|
+
previous: PreviousSlot,
|
|
347
|
+
next: NextSlot,
|
|
348
|
+
first: FirstSlot,
|
|
349
|
+
last: LastSlot
|
|
350
|
+
}[rtlAwareType];
|
|
351
|
+
const iconSlotProps = {
|
|
352
|
+
previous: previousSlotProps,
|
|
353
|
+
next: nextSlotProps,
|
|
354
|
+
first: firstSlotProps,
|
|
355
|
+
last: lastSlotProps
|
|
356
|
+
}[rtlAwareType];
|
|
319
357
|
return type === 'start-ellipsis' || type === 'end-ellipsis' ? /*#__PURE__*/(0, _jsxRuntime.jsx)(PaginationItemEllipsis, {
|
|
320
358
|
ref: ref,
|
|
321
359
|
ownerState: ownerState,
|
|
@@ -328,11 +366,10 @@ const PaginationItem = /*#__PURE__*/React.forwardRef(function PaginationItem(inP
|
|
|
328
366
|
disabled: disabled,
|
|
329
367
|
className: (0, _clsx.default)(classes.root, className)
|
|
330
368
|
}, other, {
|
|
331
|
-
children: [type === 'page' && page,
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
}) : null]
|
|
369
|
+
children: [type === 'page' && page, IconSlot ? /*#__PURE__*/(0, _jsxRuntime.jsx)(PaginationItemPageIcon, (0, _extends2.default)({}, iconSlotProps, {
|
|
370
|
+
className: classes.icon,
|
|
371
|
+
as: IconSlot
|
|
372
|
+
})) : null]
|
|
336
373
|
}));
|
|
337
374
|
});
|
|
338
375
|
process.env.NODE_ENV !== "production" ? PaginationItem.propTypes /* remove-proptypes */ = {
|
|
@@ -371,6 +408,7 @@ process.env.NODE_ENV !== "production" ? PaginationItem.propTypes /* remove-propt
|
|
|
371
408
|
* It's recommended to use the `slots` prop instead.
|
|
372
409
|
*
|
|
373
410
|
* @default {}
|
|
411
|
+
* @deprecated use the `slots` prop instead. This prop will be removed in v7. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
374
412
|
*/
|
|
375
413
|
components: _propTypes.default.shape({
|
|
376
414
|
first: _propTypes.default.elementType,
|
|
@@ -402,11 +440,18 @@ process.env.NODE_ENV !== "production" ? PaginationItem.propTypes /* remove-propt
|
|
|
402
440
|
* @default 'medium'
|
|
403
441
|
*/
|
|
404
442
|
size: _propTypes.default /* @typescript-to-proptypes-ignore */.oneOfType([_propTypes.default.oneOf(['small', 'medium', 'large']), _propTypes.default.string]),
|
|
443
|
+
/**
|
|
444
|
+
* The props used for each slot inside.
|
|
445
|
+
* @default {}
|
|
446
|
+
*/
|
|
447
|
+
slotProps: _propTypes.default.shape({
|
|
448
|
+
first: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object]),
|
|
449
|
+
last: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object]),
|
|
450
|
+
next: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object]),
|
|
451
|
+
previous: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object])
|
|
452
|
+
}),
|
|
405
453
|
/**
|
|
406
454
|
* The components used for each slot inside.
|
|
407
|
-
*
|
|
408
|
-
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
409
|
-
*
|
|
410
455
|
* @default {}
|
|
411
456
|
*/
|
|
412
457
|
slots: _propTypes.default.shape({
|
package/node/Paper/Paper.js
CHANGED
|
@@ -6,8 +6,8 @@ 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
9
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
|
+
var _objectWithoutPropertiesLoose2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutPropertiesLoose"));
|
|
11
11
|
var React = _interopRequireWildcard(require("react"));
|
|
12
12
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
13
13
|
var _clsx = _interopRequireDefault(require("clsx"));
|
|
@@ -15,15 +15,15 @@ var _integerPropType = _interopRequireDefault(require("@mui/utils/integerPropTyp
|
|
|
15
15
|
var _chainPropTypes = _interopRequireDefault(require("@mui/utils/chainPropTypes"));
|
|
16
16
|
var _composeClasses = _interopRequireDefault(require("@mui/utils/composeClasses"));
|
|
17
17
|
var _colorManipulator = require("@mui/system/colorManipulator");
|
|
18
|
-
var
|
|
18
|
+
var _zeroStyled = require("../zero-styled");
|
|
19
19
|
var _getOverlayAlpha = _interopRequireDefault(require("../styles/getOverlayAlpha"));
|
|
20
|
-
var _useThemeProps = _interopRequireDefault(require("../styles/useThemeProps"));
|
|
21
20
|
var _useTheme = _interopRequireDefault(require("../styles/useTheme"));
|
|
22
21
|
var _paperClasses = require("./paperClasses");
|
|
23
22
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
24
23
|
const _excluded = ["className", "component", "elevation", "square", "variant"];
|
|
25
24
|
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); }
|
|
26
25
|
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
|
+
const useThemeProps = (0, _zeroStyled.createUseThemeProps)('MuiPaper');
|
|
27
27
|
const useUtilityClasses = ownerState => {
|
|
28
28
|
const {
|
|
29
29
|
square,
|
|
@@ -36,7 +36,7 @@ const useUtilityClasses = ownerState => {
|
|
|
36
36
|
};
|
|
37
37
|
return (0, _composeClasses.default)(slots, _paperClasses.getPaperUtilityClass, classes);
|
|
38
38
|
};
|
|
39
|
-
const PaperRoot = (0,
|
|
39
|
+
const PaperRoot = (0, _zeroStyled.styled)('div', {
|
|
40
40
|
name: 'MuiPaper',
|
|
41
41
|
slot: 'Root',
|
|
42
42
|
overridesResolver: (props, styles) => {
|
|
@@ -46,31 +46,42 @@ const PaperRoot = (0, _styled.default)('div', {
|
|
|
46
46
|
return [styles.root, styles[ownerState.variant], !ownerState.square && styles.rounded, ownerState.variant === 'elevation' && styles[`elevation${ownerState.elevation}`]];
|
|
47
47
|
}
|
|
48
48
|
})(({
|
|
49
|
-
theme
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
},
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
49
|
+
theme
|
|
50
|
+
}) => ({
|
|
51
|
+
backgroundColor: (theme.vars || theme).palette.background.paper,
|
|
52
|
+
color: (theme.vars || theme).palette.text.primary,
|
|
53
|
+
transition: theme.transitions.create('box-shadow'),
|
|
54
|
+
variants: [{
|
|
55
|
+
props: ({
|
|
56
|
+
ownerState
|
|
57
|
+
}) => !ownerState.square,
|
|
58
|
+
style: {
|
|
59
|
+
borderRadius: theme.shape.borderRadius
|
|
60
|
+
}
|
|
61
|
+
}, {
|
|
62
|
+
props: {
|
|
63
|
+
variant: 'outlined'
|
|
64
|
+
},
|
|
65
|
+
style: {
|
|
66
|
+
border: `1px solid ${(theme.vars || theme).palette.divider}`
|
|
67
|
+
}
|
|
68
|
+
}, {
|
|
69
|
+
props: {
|
|
70
|
+
variant: 'elevation'
|
|
71
|
+
},
|
|
72
|
+
style: {
|
|
73
|
+
boxShadow: 'var(--Paper-shadow)',
|
|
74
|
+
backgroundImage: 'var(--Paper-overlay)'
|
|
75
|
+
}
|
|
76
|
+
}]
|
|
77
|
+
}));
|
|
69
78
|
const Paper = /*#__PURE__*/React.forwardRef(function Paper(inProps, ref) {
|
|
70
|
-
|
|
79
|
+
var _theme$overlays;
|
|
80
|
+
const props = useThemeProps({
|
|
71
81
|
props: inProps,
|
|
72
82
|
name: 'MuiPaper'
|
|
73
83
|
});
|
|
84
|
+
const theme = (0, _useTheme.default)();
|
|
74
85
|
const {
|
|
75
86
|
className,
|
|
76
87
|
component = 'div',
|
|
@@ -87,8 +98,6 @@ const Paper = /*#__PURE__*/React.forwardRef(function Paper(inProps, ref) {
|
|
|
87
98
|
});
|
|
88
99
|
const classes = useUtilityClasses(ownerState);
|
|
89
100
|
if (process.env.NODE_ENV !== 'production') {
|
|
90
|
-
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
91
|
-
const theme = (0, _useTheme.default)();
|
|
92
101
|
if (theme.shadows[elevation] === undefined) {
|
|
93
102
|
console.error([`MUI: The elevation provided <Paper elevation={${elevation}}> is not available in the theme.`, `Please make sure that \`theme.shadows[${elevation}]\` is defined.`].join('\n'));
|
|
94
103
|
}
|
|
@@ -98,7 +107,15 @@ const Paper = /*#__PURE__*/React.forwardRef(function Paper(inProps, ref) {
|
|
|
98
107
|
ownerState: ownerState,
|
|
99
108
|
className: (0, _clsx.default)(classes.root, className),
|
|
100
109
|
ref: ref
|
|
101
|
-
}, other
|
|
110
|
+
}, other, {
|
|
111
|
+
style: (0, _extends2.default)({}, variant === 'elevation' && (0, _extends2.default)({
|
|
112
|
+
'--Paper-shadow': (theme.vars || theme).shadows[elevation]
|
|
113
|
+
}, theme.vars && {
|
|
114
|
+
'--Paper-overlay': (_theme$overlays = theme.overlays) == null ? void 0 : _theme$overlays[elevation]
|
|
115
|
+
}, !theme.vars && theme.palette.mode === 'dark' && {
|
|
116
|
+
'--Paper-overlay': `linear-gradient(${(0, _colorManipulator.alpha)('#fff', (0, _getOverlayAlpha.default)(elevation))}, ${(0, _colorManipulator.alpha)('#fff', (0, _getOverlayAlpha.default)(elevation))})`
|
|
117
|
+
}), other.style)
|
|
118
|
+
}));
|
|
102
119
|
});
|
|
103
120
|
process.env.NODE_ENV !== "production" ? Paper.propTypes /* remove-proptypes */ = {
|
|
104
121
|
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
@@ -142,6 +159,10 @@ process.env.NODE_ENV !== "production" ? Paper.propTypes /* remove-proptypes */ =
|
|
|
142
159
|
* @default false
|
|
143
160
|
*/
|
|
144
161
|
square: _propTypes.default.bool,
|
|
162
|
+
/**
|
|
163
|
+
* @ignore
|
|
164
|
+
*/
|
|
165
|
+
style: _propTypes.default.object,
|
|
145
166
|
/**
|
|
146
167
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
147
168
|
*/
|
package/node/Radio/Radio.js
CHANGED
|
@@ -20,10 +20,10 @@ var _capitalize = _interopRequireDefault(require("../utils/capitalize"));
|
|
|
20
20
|
var _createChainedFunction = _interopRequireDefault(require("../utils/createChainedFunction"));
|
|
21
21
|
var _useRadioGroup = _interopRequireDefault(require("../RadioGroup/useRadioGroup"));
|
|
22
22
|
var _radioClasses = _interopRequireWildcard(require("./radioClasses"));
|
|
23
|
-
var
|
|
23
|
+
var _rootShouldForwardProp = _interopRequireDefault(require("../styles/rootShouldForwardProp"));
|
|
24
24
|
var _zeroStyled = require("../zero-styled");
|
|
25
25
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
26
|
-
const _excluded = ["checked", "checkedIcon", "color", "icon", "name", "onChange", "size", "className"];
|
|
26
|
+
const _excluded = ["checked", "checkedIcon", "color", "icon", "name", "onChange", "size", "className", "disableRipple"];
|
|
27
27
|
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); }
|
|
28
28
|
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; }
|
|
29
29
|
const useThemeProps = (0, _zeroStyled.createUseThemeProps)('MuiRadio');
|
|
@@ -39,7 +39,7 @@ const useUtilityClasses = ownerState => {
|
|
|
39
39
|
return (0, _extends2.default)({}, classes, (0, _composeClasses.default)(slots, _radioClasses.getRadioUtilityClass, classes));
|
|
40
40
|
};
|
|
41
41
|
const RadioRoot = (0, _zeroStyled.styled)(_SwitchBase.default, {
|
|
42
|
-
shouldForwardProp: prop => (0,
|
|
42
|
+
shouldForwardProp: prop => (0, _rootShouldForwardProp.default)(prop) || prop === 'classes',
|
|
43
43
|
name: 'MuiRadio',
|
|
44
44
|
slot: 'Root',
|
|
45
45
|
overridesResolver: (props, styles) => {
|
|
@@ -125,10 +125,12 @@ const Radio = /*#__PURE__*/React.forwardRef(function Radio(inProps, ref) {
|
|
|
125
125
|
name: nameProp,
|
|
126
126
|
onChange: onChangeProp,
|
|
127
127
|
size = 'medium',
|
|
128
|
-
className
|
|
128
|
+
className,
|
|
129
|
+
disableRipple = false
|
|
129
130
|
} = props,
|
|
130
131
|
other = (0, _objectWithoutPropertiesLoose2.default)(props, _excluded);
|
|
131
132
|
const ownerState = (0, _extends2.default)({}, props, {
|
|
133
|
+
disableRipple,
|
|
132
134
|
color,
|
|
133
135
|
size
|
|
134
136
|
});
|
|
@@ -11,13 +11,13 @@ var React = _interopRequireWildcard(require("react"));
|
|
|
11
11
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
12
12
|
var _RadioButtonUnchecked = _interopRequireDefault(require("../internal/svg-icons/RadioButtonUnchecked"));
|
|
13
13
|
var _RadioButtonChecked = _interopRequireDefault(require("../internal/svg-icons/RadioButtonChecked"));
|
|
14
|
-
var
|
|
14
|
+
var _rootShouldForwardProp = _interopRequireDefault(require("../styles/rootShouldForwardProp"));
|
|
15
15
|
var _zeroStyled = require("../zero-styled");
|
|
16
16
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
17
17
|
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); }
|
|
18
18
|
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; }
|
|
19
19
|
const RadioButtonIconRoot = (0, _zeroStyled.styled)('span', {
|
|
20
|
-
shouldForwardProp:
|
|
20
|
+
shouldForwardProp: _rootShouldForwardProp.default
|
|
21
21
|
})({
|
|
22
22
|
position: 'relative',
|
|
23
23
|
display: 'flex'
|
package/node/Rating/Rating.js
CHANGED
|
@@ -19,14 +19,15 @@ var _RtlProvider = require("@mui/system/RtlProvider");
|
|
|
19
19
|
var _utils = require("../utils");
|
|
20
20
|
var _Star = _interopRequireDefault(require("../internal/svg-icons/Star"));
|
|
21
21
|
var _StarBorder = _interopRequireDefault(require("../internal/svg-icons/StarBorder"));
|
|
22
|
-
var
|
|
23
|
-
var
|
|
22
|
+
var _zeroStyled = require("../zero-styled");
|
|
23
|
+
var _slotShouldForwardProp = _interopRequireDefault(require("../styles/slotShouldForwardProp"));
|
|
24
24
|
var _ratingClasses = _interopRequireWildcard(require("./ratingClasses"));
|
|
25
25
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
26
26
|
const _excluded = ["value"],
|
|
27
27
|
_excluded2 = ["className", "defaultValue", "disabled", "emptyIcon", "emptyLabelText", "getLabelText", "highlightSelectedOnly", "icon", "IconContainerComponent", "max", "name", "onChange", "onChangeActive", "onMouseLeave", "onMouseMove", "precision", "readOnly", "size", "value"];
|
|
28
28
|
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); }
|
|
29
29
|
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; }
|
|
30
|
+
const useThemeProps = (0, _zeroStyled.createUseThemeProps)('MuiRating');
|
|
30
31
|
function getDecimalPrecision(num) {
|
|
31
32
|
const decimalPart = num.toString().split('.')[1];
|
|
32
33
|
return decimalPart ? decimalPart.length : 0;
|
|
@@ -62,7 +63,7 @@ const useUtilityClasses = ownerState => {
|
|
|
62
63
|
};
|
|
63
64
|
return (0, _composeClasses.default)(slots, _ratingClasses.getRatingUtilityClass, classes);
|
|
64
65
|
};
|
|
65
|
-
const RatingRoot = (0,
|
|
66
|
+
const RatingRoot = (0, _zeroStyled.styled)('span', {
|
|
66
67
|
name: 'MuiRating',
|
|
67
68
|
slot: 'Root',
|
|
68
69
|
overridesResolver: (props, styles) => {
|
|
@@ -117,7 +118,7 @@ const RatingRoot = (0, _styled.default)('span', {
|
|
|
117
118
|
}
|
|
118
119
|
}]
|
|
119
120
|
}));
|
|
120
|
-
const RatingLabel = (0,
|
|
121
|
+
const RatingLabel = (0, _zeroStyled.styled)('label', {
|
|
121
122
|
name: 'MuiRating',
|
|
122
123
|
slot: 'Label',
|
|
123
124
|
overridesResolver: ({
|
|
@@ -138,7 +139,7 @@ const RatingLabel = (0, _styled.default)('label', {
|
|
|
138
139
|
}
|
|
139
140
|
}]
|
|
140
141
|
});
|
|
141
|
-
const RatingIcon = (0,
|
|
142
|
+
const RatingIcon = (0, _zeroStyled.styled)('span', {
|
|
142
143
|
name: 'MuiRating',
|
|
143
144
|
slot: 'Icon',
|
|
144
145
|
overridesResolver: (props, styles) => {
|
|
@@ -174,10 +175,10 @@ const RatingIcon = (0, _styled.default)('span', {
|
|
|
174
175
|
}
|
|
175
176
|
}]
|
|
176
177
|
}));
|
|
177
|
-
const RatingDecimal = (0,
|
|
178
|
+
const RatingDecimal = (0, _zeroStyled.styled)('span', {
|
|
178
179
|
name: 'MuiRating',
|
|
179
180
|
slot: 'Decimal',
|
|
180
|
-
shouldForwardProp: prop => (0,
|
|
181
|
+
shouldForwardProp: prop => (0, _slotShouldForwardProp.default)(prop) && prop !== 'iconActive',
|
|
181
182
|
overridesResolver: (props, styles) => {
|
|
182
183
|
const {
|
|
183
184
|
iconActive
|
|
@@ -308,7 +309,7 @@ function defaultLabelText(value) {
|
|
|
308
309
|
return `${value} Star${value !== 1 ? 's' : ''}`;
|
|
309
310
|
}
|
|
310
311
|
const Rating = /*#__PURE__*/React.forwardRef(function Rating(inProps, ref) {
|
|
311
|
-
const props = (
|
|
312
|
+
const props = useThemeProps({
|
|
312
313
|
name: 'MuiRating',
|
|
313
314
|
props: inProps
|
|
314
315
|
});
|
package/node/Select/Select.js
CHANGED
|
@@ -22,7 +22,8 @@ var _FilledInput = _interopRequireDefault(require("../FilledInput"));
|
|
|
22
22
|
var _OutlinedInput = _interopRequireDefault(require("../OutlinedInput"));
|
|
23
23
|
var _useThemeProps = _interopRequireDefault(require("../styles/useThemeProps"));
|
|
24
24
|
var _useForkRef = _interopRequireDefault(require("../utils/useForkRef"));
|
|
25
|
-
var
|
|
25
|
+
var _zeroStyled = require("../zero-styled");
|
|
26
|
+
var _rootShouldForwardProp = _interopRequireDefault(require("../styles/rootShouldForwardProp"));
|
|
26
27
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
27
28
|
const _excluded = ["autoWidth", "children", "classes", "className", "defaultOpen", "displayEmpty", "IconComponent", "id", "input", "inputProps", "label", "labelId", "MenuProps", "multiple", "native", "onClose", "onOpen", "open", "renderValue", "SelectDisplayProps", "variant"],
|
|
28
29
|
_excluded2 = ["root"];
|
|
@@ -37,12 +38,12 @@ const useUtilityClasses = ownerState => {
|
|
|
37
38
|
const styledRootConfig = {
|
|
38
39
|
name: 'MuiSelect',
|
|
39
40
|
overridesResolver: (props, styles) => styles.root,
|
|
40
|
-
shouldForwardProp: prop => (0,
|
|
41
|
+
shouldForwardProp: prop => (0, _rootShouldForwardProp.default)(prop) && prop !== 'variant',
|
|
41
42
|
slot: 'Root'
|
|
42
43
|
};
|
|
43
|
-
const StyledInput = (0,
|
|
44
|
-
const StyledOutlinedInput = (0,
|
|
45
|
-
const StyledFilledInput = (0,
|
|
44
|
+
const StyledInput = (0, _zeroStyled.styled)(_Input.default, styledRootConfig)('');
|
|
45
|
+
const StyledOutlinedInput = (0, _zeroStyled.styled)(_OutlinedInput.default, styledRootConfig)('');
|
|
46
|
+
const StyledFilledInput = (0, _zeroStyled.styled)(_FilledInput.default, styledRootConfig)('');
|
|
46
47
|
const Select = /*#__PURE__*/React.forwardRef(function Select(inProps, ref) {
|
|
47
48
|
const props = (0, _useThemeProps.default)({
|
|
48
49
|
name: 'MuiSelect',
|
|
@@ -21,7 +21,8 @@ var _capitalize = _interopRequireDefault(require("../utils/capitalize"));
|
|
|
21
21
|
var _Menu = _interopRequireDefault(require("../Menu/Menu"));
|
|
22
22
|
var _NativeSelectInput = require("../NativeSelect/NativeSelectInput");
|
|
23
23
|
var _utils = require("../InputBase/utils");
|
|
24
|
-
var
|
|
24
|
+
var _zeroStyled = require("../zero-styled");
|
|
25
|
+
var _slotShouldForwardProp = _interopRequireDefault(require("../styles/slotShouldForwardProp"));
|
|
25
26
|
var _useForkRef = _interopRequireDefault(require("../utils/useForkRef"));
|
|
26
27
|
var _useControlled = _interopRequireDefault(require("../utils/useControlled"));
|
|
27
28
|
var _selectClasses = _interopRequireWildcard(require("./selectClasses"));
|
|
@@ -30,7 +31,7 @@ var _span;
|
|
|
30
31
|
const _excluded = ["aria-describedby", "aria-label", "autoFocus", "autoWidth", "children", "className", "defaultOpen", "defaultValue", "disabled", "displayEmpty", "error", "IconComponent", "inputRef", "labelId", "MenuProps", "multiple", "name", "onBlur", "onChange", "onClose", "onFocus", "onOpen", "open", "readOnly", "renderValue", "SelectDisplayProps", "tabIndex", "type", "value", "variant"];
|
|
31
32
|
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); }
|
|
32
33
|
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; }
|
|
33
|
-
const SelectSelect = (0,
|
|
34
|
+
const SelectSelect = (0, _zeroStyled.styled)(_NativeSelectInput.StyledSelectSelect, {
|
|
34
35
|
name: 'MuiSelect',
|
|
35
36
|
slot: 'Select',
|
|
36
37
|
overridesResolver: (props, styles) => {
|
|
@@ -49,7 +50,7 @@ const SelectSelect = (0, _styled.default)('div', {
|
|
|
49
50
|
[`&.${_selectClasses.default.multiple}`]: styles.multiple
|
|
50
51
|
}];
|
|
51
52
|
}
|
|
52
|
-
})(
|
|
53
|
+
})({
|
|
53
54
|
// Win specificity over the input base
|
|
54
55
|
[`&.${_selectClasses.default.select}`]: {
|
|
55
56
|
height: 'auto',
|
|
@@ -61,7 +62,7 @@ const SelectSelect = (0, _styled.default)('div', {
|
|
|
61
62
|
overflow: 'hidden'
|
|
62
63
|
}
|
|
63
64
|
});
|
|
64
|
-
const SelectIcon = (0,
|
|
65
|
+
const SelectIcon = (0, _zeroStyled.styled)(_NativeSelectInput.StyledSelectIcon, {
|
|
65
66
|
name: 'MuiSelect',
|
|
66
67
|
slot: 'Icon',
|
|
67
68
|
overridesResolver: (props, styles) => {
|
|
@@ -70,9 +71,9 @@ const SelectIcon = (0, _styled.default)('svg', {
|
|
|
70
71
|
} = props;
|
|
71
72
|
return [styles.icon, ownerState.variant && styles[`icon${(0, _capitalize.default)(ownerState.variant)}`], ownerState.open && styles.iconOpen];
|
|
72
73
|
}
|
|
73
|
-
})(
|
|
74
|
-
const SelectNativeInput = (0,
|
|
75
|
-
shouldForwardProp: prop => (0,
|
|
74
|
+
})({});
|
|
75
|
+
const SelectNativeInput = (0, _zeroStyled.styled)('input', {
|
|
76
|
+
shouldForwardProp: prop => (0, _slotShouldForwardProp.default)(prop) && prop !== 'classes',
|
|
76
77
|
name: 'MuiSelect',
|
|
77
78
|
slot: 'NativeInput',
|
|
78
79
|
overridesResolver: (props, styles) => styles.nativeInput
|
|
@@ -444,6 +445,7 @@ const SelectInput = /*#__PURE__*/React.forwardRef(function SelectInput(props, re
|
|
|
444
445
|
const listboxId = (0, _useId.default)();
|
|
445
446
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(React.Fragment, {
|
|
446
447
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(SelectSelect, (0, _extends2.default)({
|
|
448
|
+
as: "div",
|
|
447
449
|
ref: handleDisplayRef,
|
|
448
450
|
tabIndex: tabIndex,
|
|
449
451
|
role: "combobox",
|