@mui/material 5.10.12 → 5.10.13
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/accordionClasses.d.ts +18 -18
- package/AccordionActions/accordionActionsClasses.d.ts +10 -10
- package/AccordionDetails/accordionDetailsClasses.d.ts +8 -8
- package/AccordionSummary/accordionSummaryClasses.d.ts +22 -22
- package/Alert/Alert.d.ts +34 -3
- package/Alert/Alert.js +46 -9
- package/Alert/alertClasses.d.ts +44 -44
- package/AlertTitle/alertTitleClasses.d.ts +8 -8
- package/AppBar/appBarClasses.d.ts +28 -28
- package/Autocomplete/Autocomplete.d.ts +10 -0
- package/Autocomplete/Autocomplete.js +27 -11
- package/Autocomplete/autocompleteClasses.d.ts +54 -54
- package/Avatar/avatarClasses.d.ts +20 -20
- package/AvatarGroup/AvatarGroup.d.ts +18 -1
- package/AvatarGroup/AvatarGroup.js +25 -6
- package/AvatarGroup/avatarGroupClasses.d.ts +10 -10
- package/Backdrop/Backdrop.d.ts +33 -3
- package/Backdrop/Backdrop.js +46 -11
- package/Backdrop/backdropClasses.d.ts +10 -10
- package/Badge/Badge.d.ts +11 -3
- package/Badge/Badge.js +11 -3
- package/Badge/badgeClasses.d.ts +56 -56
- package/BottomNavigation/BottomNavigation.js +0 -0
- package/BottomNavigation/bottomNavigationClasses.d.ts +8 -8
- package/BottomNavigationAction/bottomNavigationActionClasses.d.ts +14 -14
- package/Breadcrumbs/breadcrumbsClasses.d.ts +14 -14
- package/Button/buttonClasses.d.ts +100 -100
- package/ButtonBase/buttonBaseClasses.d.ts +12 -12
- package/ButtonBase/touchRippleClasses.d.ts +20 -20
- package/ButtonGroup/ButtonGroupContext.d.ts +18 -18
- package/ButtonGroup/buttonGroupClasses.d.ts +58 -58
- package/CHANGELOG.md +58 -0
- package/Card/cardClasses.d.ts +8 -8
- package/CardActionArea/cardActionAreaClasses.d.ts +12 -12
- package/CardActions/cardActionsClasses.d.ts +10 -10
- package/CardContent/cardContentClasses.d.ts +8 -8
- package/CardHeader/cardHeaderClasses.d.ts +18 -18
- package/CardMedia/cardMediaClasses.d.ts +12 -12
- package/Checkbox/checkboxClasses.d.ts +18 -18
- package/Chip/chipClasses.d.ts +96 -96
- package/CircularProgress/circularProgressClasses.d.ts +26 -26
- package/ClickAwayListener/index.d.ts +2 -2
- package/Collapse/collapseClasses.d.ts +18 -18
- package/Container/containerClasses.d.ts +6 -6
- package/Dialog/DialogContext.d.ts +6 -6
- package/Dialog/dialogClasses.d.ts +36 -36
- package/DialogActions/dialogActionsClasses.d.ts +10 -10
- package/DialogContent/dialogContentClasses.d.ts +10 -10
- package/DialogContentText/dialogContentTextClasses.d.ts +8 -8
- package/DialogTitle/dialogTitleClasses.d.ts +8 -8
- package/Divider/dividerClasses.d.ts +34 -34
- package/Drawer/drawerClasses.d.ts +30 -30
- package/Fab/fabClasses.d.ts +26 -26
- package/FilledInput/FilledInput.js +48 -9
- package/FilledInput/filledInputClasses.d.ts +40 -40
- package/FormControl/formControlClasses.d.ts +14 -14
- package/FormControlLabel/FormControlLabel.d.ts +12 -0
- package/FormControlLabel/FormControlLabel.js +17 -5
- package/FormControlLabel/formControlLabelClasses.d.ts +20 -20
- package/FormGroup/formGroupClasses.d.ts +12 -12
- package/FormHelperText/formHelperTextClasses.d.ts +22 -22
- package/FormLabel/formLabelClasses.d.ts +22 -22
- package/Grid/gridClasses.d.ts +48 -48
- package/Icon/iconClasses.d.ts +24 -24
- package/IconButton/iconButtonClasses.d.ts +26 -26
- package/ImageList/imageListClasses.d.ts +16 -16
- package/ImageListItem/imageListItemClasses.d.ts +18 -18
- package/ImageListItemBar/imageListItemBarClasses.d.ts +30 -30
- package/Input/Input.js +49 -10
- package/Input/inputClasses.d.ts +34 -34
- package/InputAdornment/inputAdornmentClasses.d.ts +24 -24
- package/InputBase/InputBase.d.ts +34 -3
- package/InputBase/InputBase.js +45 -8
- package/InputBase/inputBaseClasses.d.ts +46 -46
- package/InputLabel/inputLabelClasses.d.ts +32 -32
- package/LinearProgress/linearProgressClasses.d.ts +42 -42
- package/Link/getTextDecoration.d.ts +15 -15
- package/Link/linkClasses.d.ts +18 -18
- package/List/listClasses.d.ts +14 -14
- package/ListItem/ListItem.d.ts +32 -3
- package/ListItem/ListItem.js +41 -9
- package/ListItem/listItemClasses.d.ts +30 -30
- package/ListItemAvatar/listItemAvatarClasses.d.ts +10 -10
- package/ListItemButton/listItemButtonClasses.d.ts +22 -22
- package/ListItemIcon/listItemIconClasses.d.ts +10 -10
- package/ListItemSecondaryAction/listItemSecondaryActionClasses.d.ts +10 -10
- package/ListItemText/listItemTextClasses.d.ts +18 -18
- package/ListSubheader/listSubheaderClasses.d.ts +18 -18
- package/Menu/menuClasses.d.ts +12 -12
- package/MenuItem/menuItemClasses.d.ts +20 -20
- package/MobileStepper/mobileStepperClasses.d.ts +22 -22
- package/Modal/Modal.d.ts +11 -3
- package/Modal/Modal.js +11 -3
- package/NativeSelect/NativeSelectInput.js +11 -9
- package/NativeSelect/nativeSelectClasses.d.ts +32 -32
- package/OutlinedInput/OutlinedInput.js +26 -8
- package/OutlinedInput/outlinedInputClasses.d.ts +36 -36
- package/OverridableComponentAugmentation.d.ts +31 -31
- package/Pagination/paginationClasses.d.ts +14 -14
- package/PaginationItem/PaginationItem.d.ts +19 -7
- package/PaginationItem/PaginationItem.js +31 -22
- package/PaginationItem/paginationItemClasses.d.ts +42 -42
- package/Paper/paperClasses.d.ts +39 -39
- package/Popover/popoverClasses.d.ts +10 -10
- package/Popper/Popper.d.ts +37 -37
- package/README.md +1 -0
- package/Radio/radioClasses.d.ts +16 -16
- package/RadioGroup/RadioGroupContext.d.ts +11 -11
- package/RadioGroup/useRadioGroup.d.ts +4 -4
- package/Rating/ratingClasses.d.ts +40 -40
- package/ScopedCssBaseline/scopedCssBaselineClasses.d.ts +8 -8
- package/Select/Select.d.ts +3 -3
- package/Select/Select.js +3 -3
- package/Select/selectClasses.d.ts +30 -30
- package/Skeleton/skeletonClasses.d.ts +26 -26
- package/Slider/Slider.d.ts +14 -2
- package/Slider/Slider.js +12 -3
- package/Snackbar/snackbarClasses.d.ts +20 -20
- package/SnackbarContent/snackbarContentClasses.d.ts +12 -12
- package/SpeedDial/speedDialClasses.d.ts +22 -22
- package/SpeedDialAction/speedDialActionClasses.d.ts +20 -20
- package/SpeedDialIcon/speedDialIconClasses.d.ts +18 -18
- package/Step/StepContext.d.ts +20 -20
- package/Step/stepClasses.d.ts +16 -16
- package/StepButton/stepButtonClasses.d.ts +14 -14
- package/StepConnector/stepConnectorClasses.d.ts +26 -26
- package/StepContent/stepContentClasses.d.ts +12 -12
- package/StepIcon/stepIconClasses.d.ts +16 -16
- package/StepLabel/StepLabel.d.ts +11 -0
- package/StepLabel/StepLabel.js +15 -3
- package/StepLabel/stepLabelClasses.d.ts +28 -28
- package/Stepper/StepperContext.d.ts +18 -18
- package/Stepper/stepperClasses.d.ts +14 -14
- package/SvgIcon/svgIconClasses.d.ts +26 -26
- package/Switch/switchClasses.d.ts +32 -32
- package/Tab/tabClasses.d.ts +26 -26
- package/TabScrollButton/tabScrollButtonClasses.d.ts +12 -12
- package/Table/tableClasses.d.ts +10 -10
- package/TableBody/tableBodyClasses.d.ts +8 -8
- package/TableCell/tableCellClasses.d.ts +32 -32
- package/TableContainer/tableContainerClasses.d.ts +8 -8
- package/TableFooter/tableFooterClasses.d.ts +8 -8
- package/TableHead/tableHeadClasses.d.ts +8 -8
- package/TablePagination/tablePaginationClasses.d.ts +28 -28
- package/TableRow/tableRowClasses.d.ts +16 -16
- package/TableSortLabel/tableSortLabelClasses.d.ts +16 -16
- package/Tabs/tabsClasses.d.ts +32 -32
- package/TextField/textFieldClasses.d.ts +8 -8
- package/ToggleButton/toggleButtonClasses.d.ts +24 -24
- package/ToggleButtonGroup/toggleButtonGroupClasses.d.ts +18 -18
- package/Toolbar/toolbarClasses.d.ts +14 -14
- package/Tooltip/Tooltip.d.ts +43 -6
- package/Tooltip/Tooltip.js +68 -31
- package/Tooltip/tooltipClasses.d.ts +30 -30
- package/Typography/typographyClasses.d.ts +50 -50
- package/Unstable_Grid2/Grid2.d.ts +4 -4
- package/Unstable_Grid2/Grid2Props.d.ts +15 -15
- package/Unstable_Grid2/grid2Classes.d.ts +5 -5
- package/Unstable_Grid2/index.d.ts +4 -4
- package/className/index.d.ts +1 -1
- package/darkScrollbar/index.d.ts +28 -28
- package/esm/Alert/Alert.js +46 -9
- package/esm/Autocomplete/Autocomplete.js +27 -11
- package/esm/AvatarGroup/AvatarGroup.js +25 -6
- package/esm/Backdrop/Backdrop.js +46 -11
- package/esm/Badge/Badge.js +11 -3
- package/esm/BottomNavigation/BottomNavigation.js +0 -0
- package/esm/FilledInput/FilledInput.js +48 -9
- package/esm/FormControlLabel/FormControlLabel.js +17 -5
- package/esm/Input/Input.js +49 -10
- package/esm/InputBase/InputBase.js +45 -8
- package/esm/ListItem/ListItem.js +41 -9
- package/esm/Modal/Modal.js +11 -3
- package/esm/NativeSelect/NativeSelectInput.js +11 -9
- package/esm/OutlinedInput/OutlinedInput.js +26 -8
- package/esm/PaginationItem/PaginationItem.js +31 -22
- package/esm/Select/Select.js +3 -3
- package/esm/Slider/Slider.js +12 -3
- package/esm/StepLabel/StepLabel.js +15 -3
- package/esm/Tooltip/Tooltip.js +68 -31
- package/generateUtilityClass/index.d.ts +2 -2
- package/generateUtilityClasses/index.d.ts +1 -1
- package/index.js +1 -1
- package/internal/switchBaseClasses.d.ts +12 -12
- package/legacy/Alert/Alert.js +48 -9
- package/legacy/Autocomplete/Autocomplete.js +27 -10
- package/legacy/AvatarGroup/AvatarGroup.js +26 -6
- package/legacy/Backdrop/Backdrop.js +48 -11
- package/legacy/Badge/Badge.js +11 -3
- package/legacy/BottomNavigation/BottomNavigation.js +0 -0
- package/legacy/FilledInput/FilledInput.js +49 -9
- package/legacy/FormControlLabel/FormControlLabel.js +17 -4
- package/legacy/Input/Input.js +50 -10
- package/legacy/InputBase/InputBase.js +47 -8
- package/legacy/ListItem/ListItem.js +42 -8
- package/legacy/Modal/Modal.js +11 -3
- package/legacy/NativeSelect/NativeSelectInput.js +11 -9
- package/legacy/OutlinedInput/OutlinedInput.js +27 -8
- package/legacy/PaginationItem/PaginationItem.js +32 -22
- package/legacy/Select/Select.js +3 -3
- package/legacy/Slider/Slider.js +12 -3
- package/legacy/StepLabel/StepLabel.js +16 -3
- package/legacy/Tooltip/Tooltip.js +63 -22
- package/legacy/index.js +1 -1
- package/locale/index.d.ts +72 -72
- package/modern/Alert/Alert.js +45 -8
- package/modern/Autocomplete/Autocomplete.js +26 -10
- package/modern/AvatarGroup/AvatarGroup.js +24 -5
- package/modern/Backdrop/Backdrop.js +45 -10
- package/modern/Badge/Badge.js +11 -3
- package/modern/BottomNavigation/BottomNavigation.js +0 -0
- package/modern/FilledInput/FilledInput.js +46 -9
- package/modern/FormControlLabel/FormControlLabel.js +15 -5
- package/modern/Input/Input.js +47 -10
- package/modern/InputBase/InputBase.js +43 -8
- package/modern/ListItem/ListItem.js +41 -9
- package/modern/Modal/Modal.js +11 -3
- package/modern/NativeSelect/NativeSelectInput.js +11 -9
- package/modern/OutlinedInput/OutlinedInput.js +25 -7
- package/modern/PaginationItem/PaginationItem.js +31 -22
- package/modern/Select/Select.js +3 -3
- package/modern/Slider/Slider.js +12 -3
- package/modern/StepLabel/StepLabel.js +13 -3
- package/modern/Tooltip/Tooltip.js +58 -17
- package/modern/index.js +1 -1
- package/package.json +4 -4
- package/styles/CssVarsProvider.d.ts +14 -14
- package/styles/excludeVariablesFromRoot.d.ts +5 -5
- package/transitions/index.d.ts +1 -1
- package/transitions/transition.d.ts +13 -13
- package/transitions/utils.d.ts +23 -23
- package/umd/material-ui.development.js +534 -165
- package/umd/material-ui.production.min.js +14 -14
- package/useMediaQuery/useMediaQuery.d.ts +31 -31
- package/useTouchRipple/index.d.ts +1 -1
- package/useTouchRipple/useTouchRipple.d.ts +28 -28
- package/utils/getScrollbarSize.d.ts +2 -2
- package/utils/ownerDocument.d.ts +2 -2
- package/utils/ownerWindow.d.ts +2 -2
- package/utils/setRef.d.ts +2 -2
|
@@ -172,6 +172,8 @@ var FilledInputInput = styled(InputBaseInput, {
|
|
|
172
172
|
});
|
|
173
173
|
});
|
|
174
174
|
var FilledInput = /*#__PURE__*/React.forwardRef(function FilledInput(inProps, ref) {
|
|
175
|
+
var _ref5, _slots$root, _ref6, _slots$input;
|
|
176
|
+
|
|
175
177
|
var props = useThemeProps({
|
|
176
178
|
props: inProps,
|
|
177
179
|
name: 'MuiFilledInput'
|
|
@@ -188,9 +190,12 @@ var FilledInput = /*#__PURE__*/React.forwardRef(function FilledInput(inProps, re
|
|
|
188
190
|
inputComponent = _props$inputComponent === void 0 ? 'input' : _props$inputComponent,
|
|
189
191
|
_props$multiline = props.multiline,
|
|
190
192
|
multiline = _props$multiline === void 0 ? false : _props$multiline,
|
|
193
|
+
slotProps = props.slotProps,
|
|
194
|
+
_props$slots = props.slots,
|
|
195
|
+
slots = _props$slots === void 0 ? {} : _props$slots,
|
|
191
196
|
_props$type = props.type,
|
|
192
197
|
type = _props$type === void 0 ? 'text' : _props$type,
|
|
193
|
-
other = _objectWithoutProperties(props, ["disableUnderline", "components", "componentsProps", "fullWidth", "hiddenLabel", "inputComponent", "multiline", "type"]);
|
|
198
|
+
other = _objectWithoutProperties(props, ["disableUnderline", "components", "componentsProps", "fullWidth", "hiddenLabel", "inputComponent", "multiline", "slotProps", "slots", "type"]);
|
|
194
199
|
|
|
195
200
|
var ownerState = _extends({}, props, {
|
|
196
201
|
fullWidth: fullWidth,
|
|
@@ -208,12 +213,14 @@ var FilledInput = /*#__PURE__*/React.forwardRef(function FilledInput(inProps, re
|
|
|
208
213
|
ownerState: ownerState
|
|
209
214
|
}
|
|
210
215
|
};
|
|
211
|
-
var componentsProps = componentsPropsProp ? deepmerge(componentsPropsProp, filledInputComponentsProps) : filledInputComponentsProps;
|
|
216
|
+
var componentsProps = (slotProps != null ? slotProps : componentsPropsProp) ? deepmerge(slotProps != null ? slotProps : componentsPropsProp, filledInputComponentsProps) : filledInputComponentsProps;
|
|
217
|
+
var RootSlot = (_ref5 = (_slots$root = slots.root) != null ? _slots$root : components.Root) != null ? _ref5 : FilledInputRoot;
|
|
218
|
+
var InputSlot = (_ref6 = (_slots$input = slots.input) != null ? _slots$input : components.Input) != null ? _ref6 : FilledInputInput;
|
|
212
219
|
return /*#__PURE__*/_jsx(InputBase, _extends({
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
},
|
|
220
|
+
slots: {
|
|
221
|
+
root: RootSlot,
|
|
222
|
+
input: InputSlot
|
|
223
|
+
},
|
|
217
224
|
componentsProps: componentsProps,
|
|
218
225
|
fullWidth: fullWidth,
|
|
219
226
|
inputComponent: inputComponent,
|
|
@@ -260,8 +267,11 @@ process.env.NODE_ENV !== "production" ? FilledInput.propTypes
|
|
|
260
267
|
.oneOfType([PropTypes.oneOf(['primary', 'secondary']), PropTypes.string]),
|
|
261
268
|
|
|
262
269
|
/**
|
|
263
|
-
* The components used for each slot inside
|
|
264
|
-
*
|
|
270
|
+
* The components used for each slot inside.
|
|
271
|
+
*
|
|
272
|
+
* This prop is an alias for the `slots` prop.
|
|
273
|
+
* It's recommended to use the `slots` prop instead.
|
|
274
|
+
*
|
|
265
275
|
* @default {}
|
|
266
276
|
*/
|
|
267
277
|
components: PropTypes.shape({
|
|
@@ -270,7 +280,12 @@ process.env.NODE_ENV !== "production" ? FilledInput.propTypes
|
|
|
270
280
|
}),
|
|
271
281
|
|
|
272
282
|
/**
|
|
273
|
-
* The props
|
|
283
|
+
* The extra props for the slot components.
|
|
284
|
+
* You can override the existing props or add new ones.
|
|
285
|
+
*
|
|
286
|
+
* This prop is an alias for the `slotProps` prop.
|
|
287
|
+
* It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.
|
|
288
|
+
*
|
|
274
289
|
* @default {}
|
|
275
290
|
*/
|
|
276
291
|
componentsProps: PropTypes.shape({
|
|
@@ -400,6 +415,31 @@ process.env.NODE_ENV !== "production" ? FilledInput.propTypes
|
|
|
400
415
|
*/
|
|
401
416
|
rows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
|
|
402
417
|
|
|
418
|
+
/**
|
|
419
|
+
* The extra props for the slot components.
|
|
420
|
+
* You can override the existing props or add new ones.
|
|
421
|
+
*
|
|
422
|
+
* This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.
|
|
423
|
+
*
|
|
424
|
+
* @default {}
|
|
425
|
+
*/
|
|
426
|
+
slotProps: PropTypes.shape({
|
|
427
|
+
input: PropTypes.object,
|
|
428
|
+
root: PropTypes.object
|
|
429
|
+
}),
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* The components used for each slot inside.
|
|
433
|
+
*
|
|
434
|
+
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
435
|
+
*
|
|
436
|
+
* @default {}
|
|
437
|
+
*/
|
|
438
|
+
slots: PropTypes.shape({
|
|
439
|
+
input: PropTypes.elementType,
|
|
440
|
+
root: PropTypes.elementType
|
|
441
|
+
}),
|
|
442
|
+
|
|
403
443
|
/**
|
|
404
444
|
* Start `InputAdornment` for this component.
|
|
405
445
|
*/
|
|
@@ -70,6 +70,8 @@ export var FormControlLabelRoot = styled('label', {
|
|
|
70
70
|
*/
|
|
71
71
|
|
|
72
72
|
var FormControlLabel = /*#__PURE__*/React.forwardRef(function FormControlLabel(inProps, ref) {
|
|
73
|
+
var _slotProps$typography;
|
|
74
|
+
|
|
73
75
|
var props = useThemeProps({
|
|
74
76
|
props: inProps,
|
|
75
77
|
name: 'MuiFormControlLabel'
|
|
@@ -88,8 +90,10 @@ var FormControlLabel = /*#__PURE__*/React.forwardRef(function FormControlLabel(i
|
|
|
88
90
|
labelPlacement = _props$labelPlacement === void 0 ? 'end' : _props$labelPlacement,
|
|
89
91
|
name = props.name,
|
|
90
92
|
onChange = props.onChange,
|
|
93
|
+
_props$slotProps = props.slotProps,
|
|
94
|
+
slotProps = _props$slotProps === void 0 ? {} : _props$slotProps,
|
|
91
95
|
value = props.value,
|
|
92
|
-
other = _objectWithoutProperties(props, ["checked", "className", "componentsProps", "control", "disabled", "disableTypography", "inputRef", "label", "labelPlacement", "name", "onChange", "value"]);
|
|
96
|
+
other = _objectWithoutProperties(props, ["checked", "className", "componentsProps", "control", "disabled", "disableTypography", "inputRef", "label", "labelPlacement", "name", "onChange", "slotProps", "value"]);
|
|
93
97
|
|
|
94
98
|
var muiFormControl = useFormControl();
|
|
95
99
|
var disabled = disabledProp;
|
|
@@ -123,13 +127,14 @@ var FormControlLabel = /*#__PURE__*/React.forwardRef(function FormControlLabel(i
|
|
|
123
127
|
});
|
|
124
128
|
|
|
125
129
|
var classes = useUtilityClasses(ownerState);
|
|
130
|
+
var typographySlotProps = (_slotProps$typography = slotProps.typography) != null ? _slotProps$typography : componentsProps.typography;
|
|
126
131
|
var label = labelProp;
|
|
127
132
|
|
|
128
133
|
if (label != null && label.type !== Typography && !disableTypography) {
|
|
129
134
|
label = /*#__PURE__*/_jsx(Typography, _extends({
|
|
130
|
-
component: "span"
|
|
131
|
-
|
|
132
|
-
|
|
135
|
+
component: "span"
|
|
136
|
+
}, typographySlotProps, {
|
|
137
|
+
className: clsx(classes.label, typographySlotProps == null ? void 0 : typographySlotProps.className),
|
|
133
138
|
children: label
|
|
134
139
|
}));
|
|
135
140
|
}
|
|
@@ -217,6 +222,14 @@ process.env.NODE_ENV !== "production" ? FormControlLabel.propTypes
|
|
|
217
222
|
*/
|
|
218
223
|
onChange: PropTypes.func,
|
|
219
224
|
|
|
225
|
+
/**
|
|
226
|
+
* The props used for each slot inside.
|
|
227
|
+
* @default {}
|
|
228
|
+
*/
|
|
229
|
+
slotProps: PropTypes.shape({
|
|
230
|
+
typography: PropTypes.object
|
|
231
|
+
}),
|
|
232
|
+
|
|
220
233
|
/**
|
|
221
234
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
222
235
|
*/
|
package/legacy/Input/Input.js
CHANGED
|
@@ -106,6 +106,8 @@ var InputInput = styled(InputBaseInput, {
|
|
|
106
106
|
overridesResolver: inputBaseInputOverridesResolver
|
|
107
107
|
})({});
|
|
108
108
|
var Input = /*#__PURE__*/React.forwardRef(function Input(inProps, ref) {
|
|
109
|
+
var _ref3, _slots$root, _ref4, _slots$input;
|
|
110
|
+
|
|
109
111
|
var props = useThemeProps({
|
|
110
112
|
props: inProps,
|
|
111
113
|
name: 'MuiInput'
|
|
@@ -121,9 +123,12 @@ var Input = /*#__PURE__*/React.forwardRef(function Input(inProps, ref) {
|
|
|
121
123
|
inputComponent = _props$inputComponent === void 0 ? 'input' : _props$inputComponent,
|
|
122
124
|
_props$multiline = props.multiline,
|
|
123
125
|
multiline = _props$multiline === void 0 ? false : _props$multiline,
|
|
126
|
+
slotProps = props.slotProps,
|
|
127
|
+
_props$slots = props.slots,
|
|
128
|
+
slots = _props$slots === void 0 ? {} : _props$slots,
|
|
124
129
|
_props$type = props.type,
|
|
125
130
|
type = _props$type === void 0 ? 'text' : _props$type,
|
|
126
|
-
other = _objectWithoutProperties(props, ["disableUnderline", "components", "componentsProps", "fullWidth", "inputComponent", "multiline", "type"]);
|
|
131
|
+
other = _objectWithoutProperties(props, ["disableUnderline", "components", "componentsProps", "fullWidth", "inputComponent", "multiline", "slotProps", "slots", "type"]);
|
|
127
132
|
|
|
128
133
|
var classes = useUtilityClasses(props);
|
|
129
134
|
var ownerState = {
|
|
@@ -134,13 +139,15 @@ var Input = /*#__PURE__*/React.forwardRef(function Input(inProps, ref) {
|
|
|
134
139
|
ownerState: ownerState
|
|
135
140
|
}
|
|
136
141
|
};
|
|
137
|
-
var componentsProps = componentsPropsProp ? deepmerge(componentsPropsProp, inputComponentsProps) : inputComponentsProps;
|
|
142
|
+
var componentsProps = (slotProps != null ? slotProps : componentsPropsProp) ? deepmerge(slotProps != null ? slotProps : componentsPropsProp, inputComponentsProps) : inputComponentsProps;
|
|
143
|
+
var RootSlot = (_ref3 = (_slots$root = slots.root) != null ? _slots$root : components.Root) != null ? _ref3 : InputRoot;
|
|
144
|
+
var InputSlot = (_ref4 = (_slots$input = slots.input) != null ? _slots$input : components.Input) != null ? _ref4 : InputInput;
|
|
138
145
|
return /*#__PURE__*/_jsx(InputBase, _extends({
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
},
|
|
143
|
-
|
|
146
|
+
slots: {
|
|
147
|
+
root: RootSlot,
|
|
148
|
+
input: InputSlot
|
|
149
|
+
},
|
|
150
|
+
slotProps: componentsProps,
|
|
144
151
|
fullWidth: fullWidth,
|
|
145
152
|
inputComponent: inputComponent,
|
|
146
153
|
multiline: multiline,
|
|
@@ -186,8 +193,11 @@ process.env.NODE_ENV !== "production" ? Input.propTypes
|
|
|
186
193
|
.oneOfType([PropTypes.oneOf(['primary', 'secondary']), PropTypes.string]),
|
|
187
194
|
|
|
188
195
|
/**
|
|
189
|
-
* The components used for each slot inside
|
|
190
|
-
*
|
|
196
|
+
* The components used for each slot inside.
|
|
197
|
+
*
|
|
198
|
+
* This prop is an alias for the `slots` prop.
|
|
199
|
+
* It's recommended to use the `slots` prop instead.
|
|
200
|
+
*
|
|
191
201
|
* @default {}
|
|
192
202
|
*/
|
|
193
203
|
components: PropTypes.shape({
|
|
@@ -196,7 +206,12 @@ process.env.NODE_ENV !== "production" ? Input.propTypes
|
|
|
196
206
|
}),
|
|
197
207
|
|
|
198
208
|
/**
|
|
199
|
-
* The props
|
|
209
|
+
* The extra props for the slot components.
|
|
210
|
+
* You can override the existing props or add new ones.
|
|
211
|
+
*
|
|
212
|
+
* This prop is an alias for the `slotProps` prop.
|
|
213
|
+
* It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.
|
|
214
|
+
*
|
|
200
215
|
* @default {}
|
|
201
216
|
*/
|
|
202
217
|
componentsProps: PropTypes.shape({
|
|
@@ -318,6 +333,31 @@ process.env.NODE_ENV !== "production" ? Input.propTypes
|
|
|
318
333
|
*/
|
|
319
334
|
rows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
|
|
320
335
|
|
|
336
|
+
/**
|
|
337
|
+
* The extra props for the slot components.
|
|
338
|
+
* You can override the existing props or add new ones.
|
|
339
|
+
*
|
|
340
|
+
* This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.
|
|
341
|
+
*
|
|
342
|
+
* @default {}
|
|
343
|
+
*/
|
|
344
|
+
slotProps: PropTypes.shape({
|
|
345
|
+
input: PropTypes.object,
|
|
346
|
+
root: PropTypes.object
|
|
347
|
+
}),
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* The components used for each slot inside.
|
|
351
|
+
*
|
|
352
|
+
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
353
|
+
*
|
|
354
|
+
* @default {}
|
|
355
|
+
*/
|
|
356
|
+
slots: PropTypes.shape({
|
|
357
|
+
input: PropTypes.elementType,
|
|
358
|
+
root: PropTypes.elementType
|
|
359
|
+
}),
|
|
360
|
+
|
|
321
361
|
/**
|
|
322
362
|
* Start `InputAdornment` for this component.
|
|
323
363
|
*/
|
|
@@ -206,6 +206,8 @@ var inputGlobalStyles = /*#__PURE__*/_jsx(GlobalStyles, {
|
|
|
206
206
|
|
|
207
207
|
|
|
208
208
|
var InputBase = /*#__PURE__*/React.forwardRef(function InputBase(inProps, ref) {
|
|
209
|
+
var _slotProps$input;
|
|
210
|
+
|
|
209
211
|
var props = useThemeProps({
|
|
210
212
|
props: inProps,
|
|
211
213
|
name: 'MuiInputBase'
|
|
@@ -250,11 +252,15 @@ var InputBase = /*#__PURE__*/React.forwardRef(function InputBase(inProps, ref) {
|
|
|
250
252
|
renderSuffix = props.renderSuffix,
|
|
251
253
|
rows = props.rows,
|
|
252
254
|
size = props.size,
|
|
255
|
+
_props$slotProps = props.slotProps,
|
|
256
|
+
slotProps = _props$slotProps === void 0 ? {} : _props$slotProps,
|
|
257
|
+
_props$slots = props.slots,
|
|
258
|
+
slots = _props$slots === void 0 ? {} : _props$slots,
|
|
253
259
|
startAdornment = props.startAdornment,
|
|
254
260
|
_props$type = props.type,
|
|
255
261
|
type = _props$type === void 0 ? 'text' : _props$type,
|
|
256
262
|
valueProp = props.value,
|
|
257
|
-
other = _objectWithoutProperties(props, ["aria-describedby", "autoComplete", "autoFocus", "className", "color", "components", "componentsProps", "defaultValue", "disabled", "disableInjectingGlobalStyles", "endAdornment", "error", "fullWidth", "id", "inputComponent", "inputProps", "inputRef", "margin", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onClick", "onFocus", "onKeyDown", "onKeyUp", "placeholder", "readOnly", "renderSuffix", "rows", "size", "startAdornment", "type", "value"]);
|
|
263
|
+
other = _objectWithoutProperties(props, ["aria-describedby", "autoComplete", "autoFocus", "className", "color", "components", "componentsProps", "defaultValue", "disabled", "disableInjectingGlobalStyles", "endAdornment", "error", "fullWidth", "id", "inputComponent", "inputProps", "inputRef", "margin", "maxRows", "minRows", "multiline", "name", "onBlur", "onChange", "onClick", "onFocus", "onKeyDown", "onKeyUp", "placeholder", "readOnly", "renderSuffix", "rows", "size", "slotProps", "slots", "startAdornment", "type", "value"]);
|
|
258
264
|
|
|
259
265
|
var value = inputPropsProp.value != null ? inputPropsProp.value : valueProp;
|
|
260
266
|
|
|
@@ -462,10 +468,10 @@ var InputBase = /*#__PURE__*/React.forwardRef(function InputBase(inProps, ref) {
|
|
|
462
468
|
});
|
|
463
469
|
|
|
464
470
|
var classes = useUtilityClasses(ownerState);
|
|
465
|
-
var Root = components.Root || InputBaseRoot;
|
|
466
|
-
var rootProps = componentsProps.root || {};
|
|
467
|
-
var Input = components.Input || InputBaseComponent;
|
|
468
|
-
inputProps = _extends({}, inputProps, componentsProps.input);
|
|
471
|
+
var Root = slots.root || components.Root || InputBaseRoot;
|
|
472
|
+
var rootProps = slotProps.root || componentsProps.root || {};
|
|
473
|
+
var Input = slots.input || components.Input || InputBaseComponent;
|
|
474
|
+
inputProps = _extends({}, inputProps, (_slotProps$input = slotProps.input) != null ? _slotProps$input : componentsProps.input);
|
|
469
475
|
return /*#__PURE__*/_jsxs(React.Fragment, {
|
|
470
476
|
children: [!disableInjectingGlobalStyles && inputGlobalStyles, /*#__PURE__*/_jsxs(Root, _extends({}, rootProps, !isHostComponent(Root) && {
|
|
471
477
|
ownerState: _extends({}, ownerState, rootProps.ownerState)
|
|
@@ -557,8 +563,11 @@ process.env.NODE_ENV !== "production" ? InputBase.propTypes
|
|
|
557
563
|
.oneOfType([PropTypes.oneOf(['primary', 'secondary', 'error', 'info', 'success', 'warning']), PropTypes.string]),
|
|
558
564
|
|
|
559
565
|
/**
|
|
560
|
-
* The components used for each slot inside
|
|
561
|
-
*
|
|
566
|
+
* The components used for each slot inside.
|
|
567
|
+
*
|
|
568
|
+
* This prop is an alias for the `slots` prop.
|
|
569
|
+
* It's recommended to use the `slots` prop instead.
|
|
570
|
+
*
|
|
562
571
|
* @default {}
|
|
563
572
|
*/
|
|
564
573
|
components: PropTypes.shape({
|
|
@@ -567,7 +576,12 @@ process.env.NODE_ENV !== "production" ? InputBase.propTypes
|
|
|
567
576
|
}),
|
|
568
577
|
|
|
569
578
|
/**
|
|
570
|
-
* The props
|
|
579
|
+
* The extra props for the slot components.
|
|
580
|
+
* You can override the existing props or add new ones.
|
|
581
|
+
*
|
|
582
|
+
* This prop is an alias for the `slotProps` prop.
|
|
583
|
+
* It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.
|
|
584
|
+
*
|
|
571
585
|
* @default {}
|
|
572
586
|
*/
|
|
573
587
|
componentsProps: PropTypes.shape({
|
|
@@ -735,6 +749,31 @@ process.env.NODE_ENV !== "production" ? InputBase.propTypes
|
|
|
735
749
|
/* @typescript-to-proptypes-ignore */
|
|
736
750
|
.oneOfType([PropTypes.oneOf(['medium', 'small']), PropTypes.string]),
|
|
737
751
|
|
|
752
|
+
/**
|
|
753
|
+
* The extra props for the slot components.
|
|
754
|
+
* You can override the existing props or add new ones.
|
|
755
|
+
*
|
|
756
|
+
* This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.
|
|
757
|
+
*
|
|
758
|
+
* @default {}
|
|
759
|
+
*/
|
|
760
|
+
slotProps: PropTypes.shape({
|
|
761
|
+
input: PropTypes.object,
|
|
762
|
+
root: PropTypes.object
|
|
763
|
+
}),
|
|
764
|
+
|
|
765
|
+
/**
|
|
766
|
+
* The components used for each slot inside.
|
|
767
|
+
*
|
|
768
|
+
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
769
|
+
*
|
|
770
|
+
* @default {}
|
|
771
|
+
*/
|
|
772
|
+
slots: PropTypes.shape({
|
|
773
|
+
input: PropTypes.elementType,
|
|
774
|
+
root: PropTypes.elementType
|
|
775
|
+
}),
|
|
776
|
+
|
|
738
777
|
/**
|
|
739
778
|
* Start `InputAdornment` for this component.
|
|
740
779
|
*/
|
|
@@ -164,7 +164,11 @@ var ListItem = /*#__PURE__*/React.forwardRef(function ListItem(inProps, ref) {
|
|
|
164
164
|
secondaryAction = props.secondaryAction,
|
|
165
165
|
_props$selected = props.selected,
|
|
166
166
|
selected = _props$selected === void 0 ? false : _props$selected,
|
|
167
|
-
|
|
167
|
+
_props$slotProps = props.slotProps,
|
|
168
|
+
slotProps = _props$slotProps === void 0 ? {} : _props$slotProps,
|
|
169
|
+
_props$slots = props.slots,
|
|
170
|
+
slots = _props$slots === void 0 ? {} : _props$slots,
|
|
171
|
+
other = _objectWithoutProperties(props, ["alignItems", "autoFocus", "button", "children", "className", "component", "components", "componentsProps", "ContainerComponent", "ContainerProps", "dense", "disabled", "disableGutters", "disablePadding", "divider", "focusVisibleClassName", "secondaryAction", "selected", "slotProps", "slots"]);
|
|
168
172
|
|
|
169
173
|
var context = React.useContext(ListContext);
|
|
170
174
|
var childContext = React.useMemo(function () {
|
|
@@ -203,8 +207,8 @@ var ListItem = /*#__PURE__*/React.forwardRef(function ListItem(inProps, ref) {
|
|
|
203
207
|
|
|
204
208
|
var classes = useUtilityClasses(ownerState);
|
|
205
209
|
var handleRef = useForkRef(listItemRef, ref);
|
|
206
|
-
var Root = components.Root || ListItemRoot;
|
|
207
|
-
var rootProps = componentsProps.root || {};
|
|
210
|
+
var Root = slots.root || components.Root || ListItemRoot;
|
|
211
|
+
var rootProps = slotProps.root || componentsProps.root || {};
|
|
208
212
|
|
|
209
213
|
var componentProps = _extends({
|
|
210
214
|
className: clsx(classes.root, rootProps.className, className),
|
|
@@ -254,8 +258,7 @@ var ListItem = /*#__PURE__*/React.forwardRef(function ListItem(inProps, ref) {
|
|
|
254
258
|
value: childContext,
|
|
255
259
|
children: /*#__PURE__*/_jsxs(Root, _extends({}, rootProps, {
|
|
256
260
|
as: Component,
|
|
257
|
-
ref: handleRef
|
|
258
|
-
ownerState: ownerState
|
|
261
|
+
ref: handleRef
|
|
259
262
|
}, !isHostComponent(Root) && {
|
|
260
263
|
ownerState: _extends({}, ownerState, rootProps.ownerState)
|
|
261
264
|
}, componentProps, {
|
|
@@ -338,8 +341,11 @@ process.env.NODE_ENV !== "production" ? ListItem.propTypes
|
|
|
338
341
|
component: PropTypes.elementType,
|
|
339
342
|
|
|
340
343
|
/**
|
|
341
|
-
* The components used for each slot inside
|
|
342
|
-
*
|
|
344
|
+
* The components used for each slot inside.
|
|
345
|
+
*
|
|
346
|
+
* This prop is an alias for the `slots` prop.
|
|
347
|
+
* It's recommended to use the `slots` prop instead.
|
|
348
|
+
*
|
|
343
349
|
* @default {}
|
|
344
350
|
*/
|
|
345
351
|
components: PropTypes.shape({
|
|
@@ -347,7 +353,12 @@ process.env.NODE_ENV !== "production" ? ListItem.propTypes
|
|
|
347
353
|
}),
|
|
348
354
|
|
|
349
355
|
/**
|
|
350
|
-
* The props
|
|
356
|
+
* The extra props for the slot components.
|
|
357
|
+
* You can override the existing props or add new ones.
|
|
358
|
+
*
|
|
359
|
+
* This prop is an alias for the `slotProps` prop.
|
|
360
|
+
* It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.
|
|
361
|
+
*
|
|
351
362
|
* @default {}
|
|
352
363
|
*/
|
|
353
364
|
componentsProps: PropTypes.shape({
|
|
@@ -417,6 +428,29 @@ process.env.NODE_ENV !== "production" ? ListItem.propTypes
|
|
|
417
428
|
*/
|
|
418
429
|
selected: PropTypes.bool,
|
|
419
430
|
|
|
431
|
+
/**
|
|
432
|
+
* The extra props for the slot components.
|
|
433
|
+
* You can override the existing props or add new ones.
|
|
434
|
+
*
|
|
435
|
+
* This prop is an alias for the `componentsProps` prop, which will be deprecated in the future.
|
|
436
|
+
*
|
|
437
|
+
* @default {}
|
|
438
|
+
*/
|
|
439
|
+
slotProps: PropTypes.shape({
|
|
440
|
+
root: PropTypes.object
|
|
441
|
+
}),
|
|
442
|
+
|
|
443
|
+
/**
|
|
444
|
+
* The components used for each slot inside.
|
|
445
|
+
*
|
|
446
|
+
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
447
|
+
*
|
|
448
|
+
* @default {}
|
|
449
|
+
*/
|
|
450
|
+
slots: PropTypes.shape({
|
|
451
|
+
root: PropTypes.elementType
|
|
452
|
+
}),
|
|
453
|
+
|
|
420
454
|
/**
|
|
421
455
|
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
422
456
|
*/
|
package/legacy/Modal/Modal.js
CHANGED
|
@@ -206,8 +206,11 @@ process.env.NODE_ENV !== "production" ? Modal.propTypes
|
|
|
206
206
|
component: PropTypes.elementType,
|
|
207
207
|
|
|
208
208
|
/**
|
|
209
|
-
* The components used for each slot inside
|
|
210
|
-
*
|
|
209
|
+
* The components used for each slot inside.
|
|
210
|
+
*
|
|
211
|
+
* This prop is an alias for the `slots` prop.
|
|
212
|
+
* It's recommended to use the `slots` prop instead.
|
|
213
|
+
*
|
|
211
214
|
* @default {}
|
|
212
215
|
*/
|
|
213
216
|
components: PropTypes.shape({
|
|
@@ -216,7 +219,12 @@ process.env.NODE_ENV !== "production" ? Modal.propTypes
|
|
|
216
219
|
}),
|
|
217
220
|
|
|
218
221
|
/**
|
|
219
|
-
* The props
|
|
222
|
+
* The extra props for the slot components.
|
|
223
|
+
* You can override the existing props or add new ones.
|
|
224
|
+
*
|
|
225
|
+
* This prop is an alias for the `slotProps` prop.
|
|
226
|
+
* It's recommended to use the `slotProps` prop instead, as `componentsProps` will be deprecated in the future.
|
|
227
|
+
*
|
|
220
228
|
* @default {}
|
|
221
229
|
*/
|
|
222
230
|
componentsProps: PropTypes.shape({
|
|
@@ -41,12 +41,14 @@ export var nativeSelectSelectStyles = function nativeSelectSelectStyles(_ref) {
|
|
|
41
41
|
borderRadius: 0,
|
|
42
42
|
// Reset
|
|
43
43
|
cursor: 'pointer',
|
|
44
|
-
'&:focus': {
|
|
45
|
-
|
|
46
|
-
|
|
44
|
+
'&:focus': _extends({}, theme.vars ? {
|
|
45
|
+
backgroundColor: "rgba(".concat(theme.vars.palette.common.onBackgroundChannel, " / 0.05)")
|
|
46
|
+
} : {
|
|
47
|
+
backgroundColor: theme.palette.mode === 'light' ? 'rgba(0, 0, 0, 0.05)' : 'rgba(255, 255, 255, 0.05)'
|
|
48
|
+
}, {
|
|
47
49
|
borderRadius: 0 // Reset Chrome style
|
|
48
50
|
|
|
49
|
-
},
|
|
51
|
+
}),
|
|
50
52
|
// Remove IE11 arrow
|
|
51
53
|
'&::-ms-expand': {
|
|
52
54
|
display: 'none'
|
|
@@ -56,7 +58,7 @@ export var nativeSelectSelectStyles = function nativeSelectSelectStyles(_ref) {
|
|
|
56
58
|
}), _defineProperty(_extends2, '&[multiple]', {
|
|
57
59
|
height: 'auto'
|
|
58
60
|
}), _defineProperty(_extends2, '&:not([multiple]) option, &:not([multiple]) optgroup', {
|
|
59
|
-
backgroundColor: theme.palette.background.paper
|
|
61
|
+
backgroundColor: (theme.vars || theme).palette.background.paper
|
|
60
62
|
}), _defineProperty(_extends2, '&&&', {
|
|
61
63
|
paddingRight: 24,
|
|
62
64
|
minWidth: 16 // So it doesn't collapse.
|
|
@@ -66,9 +68,9 @@ export var nativeSelectSelectStyles = function nativeSelectSelectStyles(_ref) {
|
|
|
66
68
|
paddingRight: 32
|
|
67
69
|
}
|
|
68
70
|
}, ownerState.variant === 'outlined' && {
|
|
69
|
-
borderRadius: theme.shape.borderRadius,
|
|
71
|
+
borderRadius: (theme.vars || theme).shape.borderRadius,
|
|
70
72
|
'&:focus': {
|
|
71
|
-
borderRadius: theme.shape.borderRadius // Reset the reset for Chrome style
|
|
73
|
+
borderRadius: (theme.vars || theme).shape.borderRadius // Reset the reset for Chrome style
|
|
72
74
|
|
|
73
75
|
},
|
|
74
76
|
'&&&': {
|
|
@@ -97,9 +99,9 @@ export var nativeSelectIconStyles = function nativeSelectIconStyles(_ref3) {
|
|
|
97
99
|
// Center vertically, height is 1em
|
|
98
100
|
pointerEvents: 'none',
|
|
99
101
|
// Don't block pointer events on the select under the icon.
|
|
100
|
-
color: theme.palette.action.active
|
|
102
|
+
color: (theme.vars || theme).palette.action.active
|
|
101
103
|
}, "&.".concat(nativeSelectClasses.disabled), {
|
|
102
|
-
color: theme.palette.action.disabled
|
|
104
|
+
color: (theme.vars || theme).palette.action.disabled
|
|
103
105
|
}), ownerState.open && {
|
|
104
106
|
transform: 'rotate(180deg)'
|
|
105
107
|
}, ownerState.variant === 'filled' && {
|
|
@@ -113,7 +113,7 @@ var OutlinedInputInput = styled(InputBaseInput, {
|
|
|
113
113
|
});
|
|
114
114
|
});
|
|
115
115
|
var OutlinedInput = /*#__PURE__*/React.forwardRef(function OutlinedInput(inProps, ref) {
|
|
116
|
-
var _React$Fragment;
|
|
116
|
+
var _ref5, _slots$root, _ref6, _slots$input, _React$Fragment;
|
|
117
117
|
|
|
118
118
|
var props = useThemeProps({
|
|
119
119
|
props: inProps,
|
|
@@ -130,9 +130,11 @@ var OutlinedInput = /*#__PURE__*/React.forwardRef(function OutlinedInput(inProps
|
|
|
130
130
|
_props$multiline = props.multiline,
|
|
131
131
|
multiline = _props$multiline === void 0 ? false : _props$multiline,
|
|
132
132
|
notched = props.notched,
|
|
133
|
+
_props$slots = props.slots,
|
|
134
|
+
slots = _props$slots === void 0 ? {} : _props$slots,
|
|
133
135
|
_props$type = props.type,
|
|
134
136
|
type = _props$type === void 0 ? 'text' : _props$type,
|
|
135
|
-
other = _objectWithoutProperties(props, ["components", "fullWidth", "inputComponent", "label", "multiline", "notched", "type"]);
|
|
137
|
+
other = _objectWithoutProperties(props, ["components", "fullWidth", "inputComponent", "label", "multiline", "notched", "slots", "type"]);
|
|
136
138
|
|
|
137
139
|
var classes = useUtilityClasses(props);
|
|
138
140
|
var muiFormControl = useFormControl();
|
|
@@ -155,11 +157,13 @@ var OutlinedInput = /*#__PURE__*/React.forwardRef(function OutlinedInput(inProps
|
|
|
155
157
|
type: type
|
|
156
158
|
});
|
|
157
159
|
|
|
160
|
+
var RootSlot = (_ref5 = (_slots$root = slots.root) != null ? _slots$root : components.Root) != null ? _ref5 : OutlinedInputRoot;
|
|
161
|
+
var InputSlot = (_ref6 = (_slots$input = slots.input) != null ? _slots$input : components.Input) != null ? _ref6 : OutlinedInputInput;
|
|
158
162
|
return /*#__PURE__*/_jsx(InputBase, _extends({
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
},
|
|
163
|
+
slots: {
|
|
164
|
+
root: RootSlot,
|
|
165
|
+
input: InputSlot
|
|
166
|
+
},
|
|
163
167
|
renderSuffix: function renderSuffix(state) {
|
|
164
168
|
return /*#__PURE__*/_jsx(NotchedOutlineRoot, {
|
|
165
169
|
ownerState: ownerState,
|
|
@@ -217,8 +221,11 @@ process.env.NODE_ENV !== "production" ? OutlinedInput.propTypes
|
|
|
217
221
|
.oneOfType([PropTypes.oneOf(['primary', 'secondary']), PropTypes.string]),
|
|
218
222
|
|
|
219
223
|
/**
|
|
220
|
-
* The components used for each slot inside
|
|
221
|
-
*
|
|
224
|
+
* The components used for each slot inside.
|
|
225
|
+
*
|
|
226
|
+
* This prop is an alias for the `slots` prop.
|
|
227
|
+
* It's recommended to use the `slots` prop instead.
|
|
228
|
+
*
|
|
222
229
|
* @default {}
|
|
223
230
|
*/
|
|
224
231
|
components: PropTypes.shape({
|
|
@@ -346,6 +353,18 @@ process.env.NODE_ENV !== "production" ? OutlinedInput.propTypes
|
|
|
346
353
|
*/
|
|
347
354
|
rows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),
|
|
348
355
|
|
|
356
|
+
/**
|
|
357
|
+
* The components used for each slot inside.
|
|
358
|
+
*
|
|
359
|
+
* This prop is an alias for the `components` prop, which will be deprecated in the future.
|
|
360
|
+
*
|
|
361
|
+
* @default {}
|
|
362
|
+
*/
|
|
363
|
+
slots: PropTypes.shape({
|
|
364
|
+
input: PropTypes.elementType,
|
|
365
|
+
root: PropTypes.elementType
|
|
366
|
+
}),
|
|
367
|
+
|
|
349
368
|
/**
|
|
350
369
|
* Start `InputAdornment` for this component.
|
|
351
370
|
*/
|