@mui/material 9.0.0-alpha.3 → 9.0.0-alpha.4
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.mts +0 -14
- package/Accordion/Accordion.d.ts +0 -14
- package/Accordion/Accordion.js +3 -25
- package/Accordion/Accordion.mjs +3 -25
- package/AccordionSummary/AccordionSummary.js +1 -1
- package/AccordionSummary/AccordionSummary.mjs +1 -1
- package/AccordionSummary/accordionSummaryClasses.d.mts +0 -5
- package/AccordionSummary/accordionSummaryClasses.d.ts +0 -5
- package/AccordionSummary/accordionSummaryClasses.js +1 -1
- package/AccordionSummary/accordionSummaryClasses.mjs +1 -1
- package/Alert/Alert.d.mts +0 -23
- package/Alert/Alert.d.ts +0 -23
- package/Alert/Alert.js +4 -36
- package/Alert/Alert.mjs +4 -36
- package/Alert/alertClasses.d.mts +0 -72
- package/Alert/alertClasses.d.ts +0 -72
- package/Alert/alertClasses.js +1 -1
- package/Alert/alertClasses.mjs +1 -1
- package/Autocomplete/Autocomplete.d.mts +10 -60
- package/Autocomplete/Autocomplete.d.ts +10 -60
- package/Autocomplete/Autocomplete.js +33 -99
- package/Autocomplete/Autocomplete.mjs +33 -99
- package/Avatar/Avatar.d.mts +0 -8
- package/Avatar/Avatar.d.ts +0 -8
- package/Avatar/Avatar.js +13 -35
- package/Avatar/Avatar.mjs +13 -35
- package/AvatarGroup/AvatarGroup.d.mts +0 -15
- package/AvatarGroup/AvatarGroup.d.ts +0 -15
- package/AvatarGroup/AvatarGroup.js +1 -18
- package/AvatarGroup/AvatarGroup.mjs +1 -18
- package/Backdrop/Backdrop.d.mts +1 -31
- package/Backdrop/Backdrop.d.ts +1 -31
- package/Backdrop/Backdrop.js +2 -42
- package/Backdrop/Backdrop.mjs +2 -42
- package/Badge/Badge.d.mts +0 -20
- package/Badge/Badge.d.ts +0 -20
- package/Badge/Badge.js +2 -35
- package/Badge/Badge.mjs +2 -35
- package/Button/Button.js +6 -6
- package/Button/Button.mjs +6 -6
- package/Button/buttonClasses.d.mts +0 -132
- package/Button/buttonClasses.d.ts +0 -132
- package/Button/buttonClasses.js +1 -1
- package/Button/buttonClasses.mjs +1 -1
- package/ButtonBase/ButtonBase.js +16 -2
- package/ButtonBase/ButtonBase.mjs +16 -2
- package/CHANGELOG.md +154 -0
- package/CircularProgress/CircularProgress.js +2 -2
- package/CircularProgress/CircularProgress.mjs +2 -2
- package/CircularProgress/circularProgressClasses.d.mts +0 -8
- package/CircularProgress/circularProgressClasses.d.ts +0 -8
- package/CircularProgress/circularProgressClasses.js +1 -1
- package/CircularProgress/circularProgressClasses.mjs +1 -1
- package/Divider/Divider.d.mts +0 -6
- package/Divider/Divider.d.ts +0 -6
- package/Divider/Divider.js +2 -18
- package/Divider/Divider.mjs +2 -18
- package/Divider/dividerClasses.d.mts +0 -4
- package/Divider/dividerClasses.d.ts +0 -4
- package/Divider/dividerClasses.js +1 -1
- package/Divider/dividerClasses.mjs +1 -1
- package/FormControlLabel/FormControlLabel.d.mts +1 -14
- package/FormControlLabel/FormControlLabel.d.ts +1 -14
- package/FormControlLabel/FormControlLabel.js +1 -13
- package/FormControlLabel/FormControlLabel.mjs +1 -13
- package/Input/Input.js +2 -1
- package/Input/Input.mjs +2 -1
- package/Menu/Menu.d.mts +0 -13
- package/Menu/Menu.d.ts +0 -13
- package/Menu/Menu.js +5 -44
- package/Menu/Menu.mjs +5 -44
- package/MenuItem/MenuItem.js +21 -1
- package/MenuItem/MenuItem.mjs +23 -1
- package/MenuList/MenuList.js +2 -4
- package/MenuList/MenuList.mjs +2 -4
- package/MobileStepper/MobileStepper.d.mts +0 -5
- package/MobileStepper/MobileStepper.d.ts +0 -5
- package/MobileStepper/MobileStepper.js +1 -10
- package/MobileStepper/MobileStepper.mjs +1 -10
- package/Popover/Popover.d.mts +4 -48
- package/Popover/Popover.d.ts +4 -48
- package/Popover/Popover.js +4 -64
- package/Popover/Popover.mjs +4 -64
- package/Popper/Popper.d.mts +0 -17
- package/Popper/Popper.d.ts +0 -17
- package/Popper/Popper.js +2 -26
- package/Popper/Popper.mjs +2 -26
- package/Popper/index.d.mts +1 -0
- package/Popper/index.d.ts +1 -0
- package/Popper/index.js +11 -2
- package/Popper/index.mjs +1 -0
- package/Select/SelectInput.js +50 -55
- package/Select/SelectInput.mjs +47 -52
- package/Select/index.d.mts +1 -0
- package/Select/index.d.ts +1 -0
- package/Select/index.js +12 -0
- package/Select/index.mjs +1 -0
- package/Select/utils/SelectFocusSourceContext.d.mts +4 -0
- package/Select/utils/SelectFocusSourceContext.d.ts +4 -0
- package/Select/utils/SelectFocusSourceContext.js +19 -0
- package/Select/utils/SelectFocusSourceContext.mjs +13 -0
- package/Select/utils/areEqualValues.d.mts +1 -0
- package/Select/utils/areEqualValues.d.ts +1 -0
- package/Select/utils/areEqualValues.js +14 -0
- package/Select/utils/areEqualValues.mjs +8 -0
- package/Select/utils/getOpenInteractionType.d.mts +1 -0
- package/Select/utils/getOpenInteractionType.d.ts +1 -0
- package/Select/utils/getOpenInteractionType.js +18 -0
- package/Select/utils/getOpenInteractionType.mjs +12 -0
- package/Select/utils/index.d.mts +4 -0
- package/Select/utils/index.d.ts +4 -0
- package/Select/utils/index.js +40 -0
- package/Select/utils/index.mjs +4 -0
- package/Select/utils/isEmpty.d.mts +1 -0
- package/Select/utils/isEmpty.d.ts +1 -0
- package/Select/utils/isEmpty.js +9 -0
- package/Select/utils/isEmpty.mjs +3 -0
- package/Slider/Slider.d.mts +109 -77
- package/Slider/Slider.d.ts +109 -77
- package/Slider/Slider.js +42 -119
- package/Slider/Slider.mjs +42 -119
- package/Slider/sliderClasses.d.mts +7 -7
- package/Slider/sliderClasses.d.ts +7 -7
- package/Slider/useSlider.js +50 -14
- package/Slider/useSlider.mjs +50 -14
- package/Snackbar/Snackbar.d.mts +1 -27
- package/Snackbar/Snackbar.d.ts +1 -27
- package/Snackbar/Snackbar.js +5 -58
- package/Snackbar/Snackbar.mjs +5 -58
- package/SpeedDial/SpeedDial.d.mts +0 -13
- package/SpeedDial/SpeedDial.d.ts +0 -13
- package/SpeedDial/SpeedDial.js +15 -40
- package/SpeedDial/SpeedDial.mjs +15 -40
- package/SpeedDialAction/SpeedDialAction.d.mts +0 -28
- package/SpeedDialAction/SpeedDialAction.d.ts +0 -28
- package/SpeedDialAction/SpeedDialAction.js +5 -46
- package/SpeedDialAction/SpeedDialAction.mjs +5 -46
- package/TablePagination/TablePagination.d.mts +1 -1
- package/TablePagination/TablePagination.d.ts +1 -1
- package/TablePagination/TablePagination.js +4 -2
- package/TablePagination/TablePagination.mjs +4 -2
- package/Tabs/Tabs.d.mts +2 -33
- package/Tabs/Tabs.d.ts +2 -33
- package/Tabs/Tabs.js +8 -38
- package/Tabs/Tabs.mjs +8 -38
- package/TextField/TextField.d.mts +6 -49
- package/TextField/TextField.d.ts +6 -49
- package/TextField/TextField.js +18 -53
- package/TextField/TextField.mjs +18 -53
- package/Tooltip/Tooltip.d.mts +1 -55
- package/Tooltip/Tooltip.d.ts +1 -55
- package/Tooltip/Tooltip.js +9 -87
- package/Tooltip/Tooltip.mjs +9 -87
- package/Typography/Typography.d.mts +0 -6
- package/Typography/Typography.d.ts +0 -6
- package/Typography/Typography.js +3 -19
- package/Typography/Typography.mjs +3 -19
- package/Typography/typographyClasses.d.mts +0 -5
- package/Typography/typographyClasses.d.ts +0 -5
- package/Typography/typographyClasses.js +1 -1
- package/Typography/typographyClasses.mjs +1 -1
- package/index.d.mts +0 -2
- package/index.d.ts +0 -2
- package/index.js +1 -9
- package/index.mjs +1 -2
- package/locale/amET.js +4 -1
- package/locale/amET.mjs +3 -1
- package/locale/arEG.js +4 -1
- package/locale/arEG.mjs +3 -1
- package/locale/arSA.js +4 -1
- package/locale/arSA.mjs +3 -1
- package/locale/arSD.js +4 -1
- package/locale/arSD.mjs +3 -1
- package/locale/beBY.js +4 -1
- package/locale/beBY.mjs +3 -1
- package/locale/bnBD.js +4 -1
- package/locale/bnBD.mjs +3 -1
- package/locale/caES.js +4 -1
- package/locale/caES.mjs +3 -1
- package/locale/csCZ.js +4 -1
- package/locale/csCZ.mjs +3 -1
- package/locale/daDK.js +4 -1
- package/locale/daDK.mjs +3 -1
- package/locale/deDE.js +4 -1
- package/locale/deDE.mjs +3 -1
- package/locale/elGR.js +4 -1
- package/locale/elGR.mjs +3 -1
- package/locale/esES.js +4 -1
- package/locale/esES.mjs +3 -1
- package/locale/etEE.js +4 -1
- package/locale/etEE.mjs +3 -1
- package/locale/faIR.js +4 -1
- package/locale/faIR.mjs +3 -1
- package/locale/fiFI.js +4 -1
- package/locale/fiFI.mjs +3 -1
- package/locale/frFR.js +4 -1
- package/locale/frFR.mjs +3 -1
- package/locale/heIL.js +4 -1
- package/locale/heIL.mjs +3 -1
- package/locale/hiIN.js +4 -1
- package/locale/hiIN.mjs +3 -1
- package/locale/hrHR.js +5 -1
- package/locale/hrHR.mjs +4 -1
- package/locale/isIS.js +4 -1
- package/locale/isIS.mjs +3 -1
- package/locale/itIT.js +4 -1
- package/locale/itIT.mjs +3 -1
- package/locale/jaJP.js +4 -1
- package/locale/jaJP.mjs +3 -1
- package/locale/khKH.js +4 -1
- package/locale/khKH.mjs +3 -1
- package/locale/kkKZ.js +4 -1
- package/locale/kkKZ.mjs +3 -1
- package/locale/koKR.js +4 -1
- package/locale/koKR.mjs +3 -1
- package/locale/kuCKB.js +4 -1
- package/locale/kuCKB.mjs +3 -1
- package/locale/kuLatn.js +4 -1
- package/locale/kuLatn.mjs +3 -1
- package/locale/mkMK.js +5 -1
- package/locale/mkMK.mjs +4 -1
- package/locale/msMS.js +5 -1
- package/locale/msMS.mjs +4 -1
- package/locale/myMY.js +5 -1
- package/locale/myMY.mjs +4 -1
- package/locale/nbNO.js +4 -1
- package/locale/nbNO.mjs +3 -1
- package/locale/neNP.js +5 -1
- package/locale/neNP.mjs +4 -1
- package/locale/nlNL.js +4 -1
- package/locale/nlNL.mjs +3 -1
- package/locale/nnNO.js +4 -1
- package/locale/nnNO.mjs +3 -1
- package/locale/plPL.js +4 -1
- package/locale/plPL.mjs +3 -1
- package/locale/psAF.js +4 -1
- package/locale/psAF.mjs +3 -1
- package/locale/ptBR.js +4 -1
- package/locale/ptBR.mjs +3 -1
- package/locale/ptPT.js +4 -1
- package/locale/ptPT.mjs +3 -1
- package/locale/roRO.js +4 -1
- package/locale/roRO.mjs +3 -1
- package/locale/ruRU.js +4 -1
- package/locale/ruRU.mjs +3 -1
- package/locale/siLK.js +4 -1
- package/locale/siLK.mjs +3 -1
- package/locale/skSK.js +4 -1
- package/locale/skSK.mjs +3 -1
- package/locale/srRS.js +5 -1
- package/locale/srRS.mjs +4 -1
- package/locale/svSE.js +4 -1
- package/locale/svSE.mjs +3 -1
- package/locale/thTH.js +4 -1
- package/locale/thTH.mjs +3 -1
- package/locale/tlTL.js +5 -1
- package/locale/tlTL.mjs +4 -1
- package/locale/trTR.js +4 -1
- package/locale/trTR.mjs +3 -1
- package/locale/ukUA.js +4 -1
- package/locale/ukUA.mjs +3 -1
- package/locale/urPK.js +4 -1
- package/locale/urPK.mjs +3 -1
- package/locale/utils/buildFormatNumber.d.mts +2 -0
- package/locale/utils/buildFormatNumber.d.ts +2 -0
- package/locale/utils/buildFormatNumber.js +23 -0
- package/locale/utils/buildFormatNumber.mjs +17 -0
- package/locale/viVN.js +4 -1
- package/locale/viVN.mjs +3 -1
- package/locale/zhCN.js +4 -1
- package/locale/zhCN.mjs +3 -1
- package/locale/zhHK.js +4 -1
- package/locale/zhHK.mjs +3 -1
- package/locale/zhTW.js +4 -1
- package/locale/zhTW.mjs +3 -1
- package/package.json +6 -20
- package/styles/components.d.mts +0 -5
- package/styles/components.d.ts +0 -5
- package/styles/overrides.d.mts +0 -2
- package/styles/overrides.d.ts +0 -2
- package/styles/props.d.mts +0 -2
- package/styles/props.d.ts +0 -2
- package/useAutocomplete/useAutocomplete.d.mts +0 -12
- package/useAutocomplete/useAutocomplete.d.ts +0 -12
- package/useAutocomplete/useAutocomplete.js +29 -28
- package/useAutocomplete/useAutocomplete.mjs +29 -28
- package/version/index.js +2 -2
- package/version/index.mjs +2 -2
- package/GridLegacy/GridLegacy.d.mts +0 -160
- package/GridLegacy/GridLegacy.d.ts +0 -160
- package/GridLegacy/GridLegacy.js +0 -601
- package/GridLegacy/GridLegacy.mjs +0 -588
- package/GridLegacy/GridLegacyContext.js +0 -17
- package/GridLegacy/GridLegacyContext.mjs +0 -12
- package/GridLegacy/gridLegacyClasses.d.mts +0 -48
- package/GridLegacy/gridLegacyClasses.d.ts +0 -48
- package/GridLegacy/gridLegacyClasses.js +0 -27
- package/GridLegacy/gridLegacyClasses.mjs +0 -19
- package/GridLegacy/index.d.mts +0 -4
- package/GridLegacy/index.d.ts +0 -4
- package/GridLegacy/index.js +0 -35
- package/GridLegacy/index.mjs +0 -3
|
@@ -405,7 +405,6 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
405
405
|
autoHighlight = false,
|
|
406
406
|
autoSelect = false,
|
|
407
407
|
blurOnSelect = false,
|
|
408
|
-
ChipProps: ChipPropsProp,
|
|
409
408
|
className,
|
|
410
409
|
clearIcon = _ClearIcon || (_ClearIcon = /*#__PURE__*/_jsx(ClearIcon, {
|
|
411
410
|
fontSize: "small"
|
|
@@ -414,7 +413,6 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
414
413
|
clearOnEscape = false,
|
|
415
414
|
clearText = 'Clear',
|
|
416
415
|
closeText = 'Close',
|
|
417
|
-
componentsProps,
|
|
418
416
|
defaultValue = props.multiple ? [] : null,
|
|
419
417
|
disableClearable = false,
|
|
420
418
|
disableCloseOnSelect = false,
|
|
@@ -438,8 +436,6 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
438
436
|
includeInputInList = false,
|
|
439
437
|
inputValue: inputValueProp,
|
|
440
438
|
limitTags = -1,
|
|
441
|
-
ListboxComponent: ListboxComponentProp,
|
|
442
|
-
ListboxProps: ListboxPropsProp,
|
|
443
439
|
loading = false,
|
|
444
440
|
loadingText = 'Loading…',
|
|
445
441
|
multiple = false,
|
|
@@ -453,14 +449,11 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
453
449
|
openOnFocus = false,
|
|
454
450
|
openText = 'Open',
|
|
455
451
|
options,
|
|
456
|
-
PaperComponent: PaperComponentProp,
|
|
457
|
-
PopperComponent: PopperComponentProp,
|
|
458
452
|
popupIcon = _ArrowDropDownIcon || (_ArrowDropDownIcon = /*#__PURE__*/_jsx(ArrowDropDownIcon, {})),
|
|
459
453
|
readOnly = false,
|
|
460
454
|
renderGroup: renderGroupProp,
|
|
461
455
|
renderInput,
|
|
462
456
|
renderOption: renderOptionProp,
|
|
463
|
-
renderTags,
|
|
464
457
|
renderValue,
|
|
465
458
|
selectOnFocus = !props.freeSolo,
|
|
466
459
|
size = 'medium',
|
|
@@ -523,17 +516,8 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
523
516
|
};
|
|
524
517
|
const classes = useUtilityClasses(ownerState);
|
|
525
518
|
const externalForwardedProps = {
|
|
526
|
-
slots
|
|
527
|
-
|
|
528
|
-
popper: PopperComponentProp,
|
|
529
|
-
...slots
|
|
530
|
-
},
|
|
531
|
-
slotProps: {
|
|
532
|
-
chip: ChipPropsProp,
|
|
533
|
-
listbox: ListboxPropsProp,
|
|
534
|
-
...componentsProps,
|
|
535
|
-
...slotProps
|
|
536
|
-
}
|
|
519
|
+
slots,
|
|
520
|
+
slotProps
|
|
537
521
|
};
|
|
538
522
|
const [RootSlot, rootProps] = useSlot('root', {
|
|
539
523
|
ref,
|
|
@@ -608,9 +592,7 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
608
592
|
});
|
|
609
593
|
if (multiple) {
|
|
610
594
|
if (value.length > 0) {
|
|
611
|
-
if (
|
|
612
|
-
startAdornment = renderTags(value, getCustomizedItemProps, ownerState);
|
|
613
|
-
} else if (renderValue) {
|
|
595
|
+
if (renderValue) {
|
|
614
596
|
startAdornment = renderValue(value, getCustomizedItemProps, ownerState);
|
|
615
597
|
} else {
|
|
616
598
|
startAdornment = value.map((option, index) => {
|
|
@@ -689,35 +671,37 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
689
671
|
disabled,
|
|
690
672
|
fullWidth: props.fullWidth ?? true,
|
|
691
673
|
size: size === 'small' ? 'small' : undefined,
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
674
|
+
slotProps: {
|
|
675
|
+
inputLabel: getInputLabelProps(),
|
|
676
|
+
input: {
|
|
677
|
+
ref: setAnchorEl,
|
|
678
|
+
className: classes.inputRoot,
|
|
679
|
+
startAdornment,
|
|
680
|
+
onMouseDown: event => {
|
|
681
|
+
if (event.target === event.currentTarget) {
|
|
682
|
+
handleInputMouseDown(event);
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
...((hasClearIcon || hasPopupIcon) && {
|
|
686
|
+
endAdornment: /*#__PURE__*/_jsxs(AutocompleteEndAdornment, {
|
|
687
|
+
className: classes.endAdornment,
|
|
688
|
+
ownerState: ownerState,
|
|
689
|
+
children: [hasClearIcon ? /*#__PURE__*/_jsx(ClearIndicatorSlot, {
|
|
690
|
+
...clearIndicatorProps,
|
|
691
|
+
children: clearIcon
|
|
692
|
+
}) : null, hasPopupIcon ? /*#__PURE__*/_jsx(PopupIndicatorSlot, {
|
|
693
|
+
...popupIndicatorProps,
|
|
694
|
+
children: popupIcon
|
|
695
|
+
}) : null]
|
|
696
|
+
})
|
|
713
697
|
})
|
|
714
|
-
}
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
698
|
+
},
|
|
699
|
+
htmlInput: {
|
|
700
|
+
className: classes.input,
|
|
701
|
+
disabled,
|
|
702
|
+
readOnly,
|
|
703
|
+
...getInputProps()
|
|
704
|
+
}
|
|
721
705
|
}
|
|
722
706
|
})
|
|
723
707
|
}), anchorEl ? /*#__PURE__*/_jsx(AutocompletePopper, {
|
|
@@ -740,7 +724,6 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
740
724
|
},
|
|
741
725
|
children: noOptionsText
|
|
742
726
|
}) : null, groupedOptions.length > 0 ? /*#__PURE__*/_jsx(ListboxSlot, {
|
|
743
|
-
as: ListboxComponentProp,
|
|
744
727
|
...listboxProps,
|
|
745
728
|
children: groupedOptions.map((option, index) => {
|
|
746
729
|
if (groupBy) {
|
|
@@ -794,11 +777,6 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes /* remove-proptyp
|
|
|
794
777
|
* @default false
|
|
795
778
|
*/
|
|
796
779
|
blurOnSelect: PropTypes.oneOfType([PropTypes.oneOf(['mouse', 'touch']), PropTypes.bool]),
|
|
797
|
-
/**
|
|
798
|
-
* Props applied to the [`Chip`](https://mui.com/material-ui/api/chip/) element.
|
|
799
|
-
* @deprecated Use `slotProps.chip` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
800
|
-
*/
|
|
801
|
-
ChipProps: PropTypes.object,
|
|
802
780
|
/**
|
|
803
781
|
* Override or extend the styles applied to the component.
|
|
804
782
|
*/
|
|
@@ -839,16 +817,6 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes /* remove-proptyp
|
|
|
839
817
|
* @default 'Close'
|
|
840
818
|
*/
|
|
841
819
|
closeText: PropTypes.string,
|
|
842
|
-
/**
|
|
843
|
-
* The props used for each slot inside.
|
|
844
|
-
* @deprecated Use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
845
|
-
*/
|
|
846
|
-
componentsProps: PropTypes.shape({
|
|
847
|
-
clearIndicator: PropTypes.object,
|
|
848
|
-
paper: PropTypes.object,
|
|
849
|
-
popper: PropTypes.object,
|
|
850
|
-
popupIndicator: PropTypes.object
|
|
851
|
-
}),
|
|
852
820
|
/**
|
|
853
821
|
* The default value. Use when the component is not controlled.
|
|
854
822
|
* @default props.multiple ? [] : null
|
|
@@ -997,17 +965,6 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes /* remove-proptyp
|
|
|
997
965
|
* @default -1
|
|
998
966
|
*/
|
|
999
967
|
limitTags: integerPropType,
|
|
1000
|
-
/**
|
|
1001
|
-
* The component used to render the listbox.
|
|
1002
|
-
* @default 'ul'
|
|
1003
|
-
* @deprecated Use `slotProps.listbox.component` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
1004
|
-
*/
|
|
1005
|
-
ListboxComponent: PropTypes.elementType,
|
|
1006
|
-
/**
|
|
1007
|
-
* Props applied to the Listbox element.
|
|
1008
|
-
* @deprecated Use `slotProps.listbox` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
1009
|
-
*/
|
|
1010
|
-
ListboxProps: PropTypes.object,
|
|
1011
968
|
/**
|
|
1012
969
|
* If `true`, the component is in a loading state.
|
|
1013
970
|
* This shows the `loadingText` in place of suggestions (only if there are no suggestions to show, for example `options` are empty).
|
|
@@ -1097,18 +1054,6 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes /* remove-proptyp
|
|
|
1097
1054
|
* A list of options that will be shown in the Autocomplete.
|
|
1098
1055
|
*/
|
|
1099
1056
|
options: PropTypes.array.isRequired,
|
|
1100
|
-
/**
|
|
1101
|
-
* The component used to render the body of the popup.
|
|
1102
|
-
* @default Paper
|
|
1103
|
-
* @deprecated Use `slots.paper` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
1104
|
-
*/
|
|
1105
|
-
PaperComponent: PropTypes.elementType,
|
|
1106
|
-
/**
|
|
1107
|
-
* The component used to position the popup.
|
|
1108
|
-
* @default Popper
|
|
1109
|
-
* @deprecated Use `slots.popper` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
1110
|
-
*/
|
|
1111
|
-
PopperComponent: PropTypes.elementType,
|
|
1112
1057
|
/**
|
|
1113
1058
|
* The icon to display in place of the default popup icon.
|
|
1114
1059
|
* @default <ArrowDropDownIcon />
|
|
@@ -1150,17 +1095,6 @@ process.env.NODE_ENV !== "production" ? Autocomplete.propTypes /* remove-proptyp
|
|
|
1150
1095
|
* @returns {ReactNode}
|
|
1151
1096
|
*/
|
|
1152
1097
|
renderOption: PropTypes.func,
|
|
1153
|
-
/**
|
|
1154
|
-
* Render the selected value when doing multiple selections.
|
|
1155
|
-
*
|
|
1156
|
-
* @deprecated Use `renderValue` prop instead
|
|
1157
|
-
*
|
|
1158
|
-
* @param {Value[]} value The `value` provided to the component.
|
|
1159
|
-
* @param {function} getTagProps A tag props getter.
|
|
1160
|
-
* @param {object} ownerState The state of the Autocomplete component.
|
|
1161
|
-
* @returns {ReactNode}
|
|
1162
|
-
*/
|
|
1163
|
-
renderTags: PropTypes.func,
|
|
1164
1098
|
/**
|
|
1165
1099
|
* Renders the selected value(s) as rich content in the input for both single and multiple selections.
|
|
1166
1100
|
*
|
package/Avatar/Avatar.d.mts
CHANGED
|
@@ -59,14 +59,6 @@ export interface AvatarOwnProps {
|
|
|
59
59
|
* Override or extend the styles applied to the component.
|
|
60
60
|
*/
|
|
61
61
|
classes?: Partial<AvatarClasses> | undefined;
|
|
62
|
-
/**
|
|
63
|
-
* [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/img#attributes) applied to the `img` element if the component is used to display an image.
|
|
64
|
-
* It can be used to listen for the loading error event.
|
|
65
|
-
* @deprecated Use `slotProps.img` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
66
|
-
*/
|
|
67
|
-
imgProps?: (React.ImgHTMLAttributes<HTMLImageElement> & {
|
|
68
|
-
sx?: SxProps<Theme> | undefined;
|
|
69
|
-
}) | undefined;
|
|
70
62
|
/**
|
|
71
63
|
* The `sizes` attribute for the `img` element.
|
|
72
64
|
*/
|
package/Avatar/Avatar.d.ts
CHANGED
|
@@ -59,14 +59,6 @@ export interface AvatarOwnProps {
|
|
|
59
59
|
* Override or extend the styles applied to the component.
|
|
60
60
|
*/
|
|
61
61
|
classes?: Partial<AvatarClasses> | undefined;
|
|
62
|
-
/**
|
|
63
|
-
* [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/img#attributes) applied to the `img` element if the component is used to display an image.
|
|
64
|
-
* It can be used to listen for the loading error event.
|
|
65
|
-
* @deprecated Use `slotProps.img` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
66
|
-
*/
|
|
67
|
-
imgProps?: (React.ImgHTMLAttributes<HTMLImageElement> & {
|
|
68
|
-
sx?: SxProps<Theme> | undefined;
|
|
69
|
-
}) | undefined;
|
|
70
62
|
/**
|
|
71
63
|
* The `sizes` attribute for the `img` element.
|
|
72
64
|
*/
|
package/Avatar/Avatar.js
CHANGED
|
@@ -108,12 +108,7 @@ const AvatarFallback = (0, _zeroStyled.styled)(_Person.default, {
|
|
|
108
108
|
width: '75%',
|
|
109
109
|
height: '75%'
|
|
110
110
|
});
|
|
111
|
-
function useLoaded({
|
|
112
|
-
crossOrigin,
|
|
113
|
-
referrerPolicy,
|
|
114
|
-
src,
|
|
115
|
-
srcSet
|
|
116
|
-
}) {
|
|
111
|
+
function useLoaded(src, srcSet, crossOrigin, referrerPolicy) {
|
|
117
112
|
const [loaded, setLoaded] = React.useState(false);
|
|
118
113
|
React.useEffect(() => {
|
|
119
114
|
if (!src && !srcSet) {
|
|
@@ -158,7 +153,6 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
158
153
|
component = 'div',
|
|
159
154
|
slots = {},
|
|
160
155
|
slotProps = {},
|
|
161
|
-
imgProps,
|
|
162
156
|
sizes,
|
|
163
157
|
src,
|
|
164
158
|
srcSet,
|
|
@@ -171,27 +165,28 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
171
165
|
component,
|
|
172
166
|
variant
|
|
173
167
|
};
|
|
174
|
-
|
|
168
|
+
const {
|
|
169
|
+
crossOrigin,
|
|
170
|
+
referrerPolicy
|
|
171
|
+
} = (typeof slotProps.img === 'function' ? slotProps.img(ownerState) : slotProps.img) ?? {};
|
|
175
172
|
// Use a hook instead of onError on the img element to support server-side rendering.
|
|
176
|
-
const loaded = useLoaded(
|
|
177
|
-
...imgProps,
|
|
178
|
-
...(typeof slotProps.img === 'function' ? slotProps.img(ownerState) : slotProps.img),
|
|
179
|
-
src,
|
|
180
|
-
srcSet
|
|
181
|
-
});
|
|
173
|
+
const loaded = useLoaded(src, srcSet, crossOrigin, referrerPolicy);
|
|
182
174
|
const hasImg = src || srcSet;
|
|
183
175
|
const hasImgNotFailing = hasImg && loaded !== 'error';
|
|
184
176
|
ownerState.colorDefault = !hasImgNotFailing;
|
|
185
177
|
// This issue explains why this is required: https://github.com/mui/material-ui/issues/42184
|
|
186
178
|
delete ownerState.ownerState;
|
|
187
179
|
const classes = useUtilityClasses(ownerState);
|
|
180
|
+
const externalForwardedProps = {
|
|
181
|
+
slots,
|
|
182
|
+
slotProps
|
|
183
|
+
};
|
|
188
184
|
const [RootSlot, rootSlotProps] = (0, _useSlot.default)('root', {
|
|
189
185
|
ref,
|
|
190
186
|
className: (0, _clsx.default)(classes.root, className),
|
|
191
187
|
elementType: AvatarRoot,
|
|
192
188
|
externalForwardedProps: {
|
|
193
|
-
|
|
194
|
-
slotProps,
|
|
189
|
+
...externalForwardedProps,
|
|
195
190
|
component,
|
|
196
191
|
...other
|
|
197
192
|
},
|
|
@@ -200,15 +195,7 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
200
195
|
const [ImgSlot, imgSlotProps] = (0, _useSlot.default)('img', {
|
|
201
196
|
className: classes.img,
|
|
202
197
|
elementType: AvatarImg,
|
|
203
|
-
externalForwardedProps
|
|
204
|
-
slots,
|
|
205
|
-
slotProps: {
|
|
206
|
-
img: {
|
|
207
|
-
...imgProps,
|
|
208
|
-
...slotProps.img
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
},
|
|
198
|
+
externalForwardedProps,
|
|
212
199
|
additionalProps: {
|
|
213
200
|
alt,
|
|
214
201
|
src,
|
|
@@ -220,10 +207,7 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
220
207
|
const [FallbackSlot, fallbackSlotProps] = (0, _useSlot.default)('fallback', {
|
|
221
208
|
className: classes.fallback,
|
|
222
209
|
elementType: AvatarFallback,
|
|
223
|
-
externalForwardedProps
|
|
224
|
-
slots,
|
|
225
|
-
slotProps
|
|
226
|
-
},
|
|
210
|
+
externalForwardedProps,
|
|
227
211
|
shouldForwardComponentProp: true,
|
|
228
212
|
ownerState
|
|
229
213
|
});
|
|
@@ -275,12 +259,6 @@ process.env.NODE_ENV !== "production" ? Avatar.propTypes /* remove-proptypes */
|
|
|
275
259
|
* Either a string to use a HTML element or a component.
|
|
276
260
|
*/
|
|
277
261
|
component: _propTypes.default.elementType,
|
|
278
|
-
/**
|
|
279
|
-
* [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/img#attributes) applied to the `img` element if the component is used to display an image.
|
|
280
|
-
* It can be used to listen for the loading error event.
|
|
281
|
-
* @deprecated Use `slotProps.img` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
282
|
-
*/
|
|
283
|
-
imgProps: _propTypes.default.object,
|
|
284
262
|
/**
|
|
285
263
|
* The `sizes` attribute for the `img` element.
|
|
286
264
|
*/
|
package/Avatar/Avatar.mjs
CHANGED
|
@@ -101,12 +101,7 @@ const AvatarFallback = styled(Person, {
|
|
|
101
101
|
width: '75%',
|
|
102
102
|
height: '75%'
|
|
103
103
|
});
|
|
104
|
-
function useLoaded({
|
|
105
|
-
crossOrigin,
|
|
106
|
-
referrerPolicy,
|
|
107
|
-
src,
|
|
108
|
-
srcSet
|
|
109
|
-
}) {
|
|
104
|
+
function useLoaded(src, srcSet, crossOrigin, referrerPolicy) {
|
|
110
105
|
const [loaded, setLoaded] = React.useState(false);
|
|
111
106
|
React.useEffect(() => {
|
|
112
107
|
if (!src && !srcSet) {
|
|
@@ -151,7 +146,6 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
151
146
|
component = 'div',
|
|
152
147
|
slots = {},
|
|
153
148
|
slotProps = {},
|
|
154
|
-
imgProps,
|
|
155
149
|
sizes,
|
|
156
150
|
src,
|
|
157
151
|
srcSet,
|
|
@@ -164,27 +158,28 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
164
158
|
component,
|
|
165
159
|
variant
|
|
166
160
|
};
|
|
167
|
-
|
|
161
|
+
const {
|
|
162
|
+
crossOrigin,
|
|
163
|
+
referrerPolicy
|
|
164
|
+
} = (typeof slotProps.img === 'function' ? slotProps.img(ownerState) : slotProps.img) ?? {};
|
|
168
165
|
// Use a hook instead of onError on the img element to support server-side rendering.
|
|
169
|
-
const loaded = useLoaded(
|
|
170
|
-
...imgProps,
|
|
171
|
-
...(typeof slotProps.img === 'function' ? slotProps.img(ownerState) : slotProps.img),
|
|
172
|
-
src,
|
|
173
|
-
srcSet
|
|
174
|
-
});
|
|
166
|
+
const loaded = useLoaded(src, srcSet, crossOrigin, referrerPolicy);
|
|
175
167
|
const hasImg = src || srcSet;
|
|
176
168
|
const hasImgNotFailing = hasImg && loaded !== 'error';
|
|
177
169
|
ownerState.colorDefault = !hasImgNotFailing;
|
|
178
170
|
// This issue explains why this is required: https://github.com/mui/material-ui/issues/42184
|
|
179
171
|
delete ownerState.ownerState;
|
|
180
172
|
const classes = useUtilityClasses(ownerState);
|
|
173
|
+
const externalForwardedProps = {
|
|
174
|
+
slots,
|
|
175
|
+
slotProps
|
|
176
|
+
};
|
|
181
177
|
const [RootSlot, rootSlotProps] = useSlot('root', {
|
|
182
178
|
ref,
|
|
183
179
|
className: clsx(classes.root, className),
|
|
184
180
|
elementType: AvatarRoot,
|
|
185
181
|
externalForwardedProps: {
|
|
186
|
-
|
|
187
|
-
slotProps,
|
|
182
|
+
...externalForwardedProps,
|
|
188
183
|
component,
|
|
189
184
|
...other
|
|
190
185
|
},
|
|
@@ -193,15 +188,7 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
193
188
|
const [ImgSlot, imgSlotProps] = useSlot('img', {
|
|
194
189
|
className: classes.img,
|
|
195
190
|
elementType: AvatarImg,
|
|
196
|
-
externalForwardedProps
|
|
197
|
-
slots,
|
|
198
|
-
slotProps: {
|
|
199
|
-
img: {
|
|
200
|
-
...imgProps,
|
|
201
|
-
...slotProps.img
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
},
|
|
191
|
+
externalForwardedProps,
|
|
205
192
|
additionalProps: {
|
|
206
193
|
alt,
|
|
207
194
|
src,
|
|
@@ -213,10 +200,7 @@ const Avatar = /*#__PURE__*/React.forwardRef(function Avatar(inProps, ref) {
|
|
|
213
200
|
const [FallbackSlot, fallbackSlotProps] = useSlot('fallback', {
|
|
214
201
|
className: classes.fallback,
|
|
215
202
|
elementType: AvatarFallback,
|
|
216
|
-
externalForwardedProps
|
|
217
|
-
slots,
|
|
218
|
-
slotProps
|
|
219
|
-
},
|
|
203
|
+
externalForwardedProps,
|
|
220
204
|
shouldForwardComponentProp: true,
|
|
221
205
|
ownerState
|
|
222
206
|
});
|
|
@@ -268,12 +252,6 @@ process.env.NODE_ENV !== "production" ? Avatar.propTypes /* remove-proptypes */
|
|
|
268
252
|
* Either a string to use a HTML element or a component.
|
|
269
253
|
*/
|
|
270
254
|
component: PropTypes.elementType,
|
|
271
|
-
/**
|
|
272
|
-
* [Attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/img#attributes) applied to the `img` element if the component is used to display an image.
|
|
273
|
-
* It can be used to listen for the loading error event.
|
|
274
|
-
* @deprecated Use `slotProps.img` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
275
|
-
*/
|
|
276
|
-
imgProps: PropTypes.object,
|
|
277
255
|
/**
|
|
278
256
|
* The `sizes` attribute for the `img` element.
|
|
279
257
|
*/
|
|
@@ -11,10 +11,6 @@ export interface AvatarGroupSlots {
|
|
|
11
11
|
surplus: React.ElementType;
|
|
12
12
|
}
|
|
13
13
|
export type AvatarGroupSlotsAndSlotProps = CreateSlotsAndSlotProps<AvatarGroupSlots, {
|
|
14
|
-
/**
|
|
15
|
-
* @deprecated use `slotProps.surplus` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
16
|
-
* */
|
|
17
|
-
additionalAvatar: React.ComponentPropsWithRef<typeof Avatar> & AvatarGroupComponentsPropsOverrides;
|
|
18
14
|
surplus: SlotProps<React.ElementType<React.ComponentPropsWithRef<typeof Avatar>>, AvatarGroupComponentsPropsOverrides, AvatarGroupOwnerState>;
|
|
19
15
|
}>;
|
|
20
16
|
export interface AvatarGroupOwnProps extends AvatarGroupSlotsAndSlotProps {
|
|
@@ -31,17 +27,6 @@ export interface AvatarGroupOwnProps extends AvatarGroupSlotsAndSlotProps {
|
|
|
31
27
|
* Either a string to use a HTML element or a component.
|
|
32
28
|
*/
|
|
33
29
|
component?: React.ElementType | undefined;
|
|
34
|
-
/**
|
|
35
|
-
* The extra props for the slot components.
|
|
36
|
-
* You can override the existing props or add new ones.
|
|
37
|
-
*
|
|
38
|
-
* This prop is an alias for the `slotProps` prop.
|
|
39
|
-
*
|
|
40
|
-
* @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
41
|
-
*/
|
|
42
|
-
componentsProps?: {
|
|
43
|
-
additionalAvatar?: (React.ComponentPropsWithRef<typeof Avatar> & AvatarGroupComponentsPropsOverrides) | undefined;
|
|
44
|
-
} | undefined;
|
|
45
30
|
/**
|
|
46
31
|
* Max avatars to show before +x.
|
|
47
32
|
* @default 5
|
|
@@ -11,10 +11,6 @@ export interface AvatarGroupSlots {
|
|
|
11
11
|
surplus: React.ElementType;
|
|
12
12
|
}
|
|
13
13
|
export type AvatarGroupSlotsAndSlotProps = CreateSlotsAndSlotProps<AvatarGroupSlots, {
|
|
14
|
-
/**
|
|
15
|
-
* @deprecated use `slotProps.surplus` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
16
|
-
* */
|
|
17
|
-
additionalAvatar: React.ComponentPropsWithRef<typeof Avatar> & AvatarGroupComponentsPropsOverrides;
|
|
18
14
|
surplus: SlotProps<React.ElementType<React.ComponentPropsWithRef<typeof Avatar>>, AvatarGroupComponentsPropsOverrides, AvatarGroupOwnerState>;
|
|
19
15
|
}>;
|
|
20
16
|
export interface AvatarGroupOwnProps extends AvatarGroupSlotsAndSlotProps {
|
|
@@ -31,17 +27,6 @@ export interface AvatarGroupOwnProps extends AvatarGroupSlotsAndSlotProps {
|
|
|
31
27
|
* Either a string to use a HTML element or a component.
|
|
32
28
|
*/
|
|
33
29
|
component?: React.ElementType | undefined;
|
|
34
|
-
/**
|
|
35
|
-
* The extra props for the slot components.
|
|
36
|
-
* You can override the existing props or add new ones.
|
|
37
|
-
*
|
|
38
|
-
* This prop is an alias for the `slotProps` prop.
|
|
39
|
-
*
|
|
40
|
-
* @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
41
|
-
*/
|
|
42
|
-
componentsProps?: {
|
|
43
|
-
additionalAvatar?: (React.ComponentPropsWithRef<typeof Avatar> & AvatarGroupComponentsPropsOverrides) | undefined;
|
|
44
|
-
} | undefined;
|
|
45
30
|
/**
|
|
46
31
|
* Max avatars to show before +x.
|
|
47
32
|
* @default 5
|
|
@@ -65,7 +65,6 @@ const AvatarGroup = /*#__PURE__*/React.forwardRef(function AvatarGroup(inProps,
|
|
|
65
65
|
children: childrenProp,
|
|
66
66
|
className,
|
|
67
67
|
component = 'div',
|
|
68
|
-
componentsProps,
|
|
69
68
|
max = 5,
|
|
70
69
|
renderSurplus,
|
|
71
70
|
slotProps = {},
|
|
@@ -110,11 +109,7 @@ const AvatarGroup = /*#__PURE__*/React.forwardRef(function AvatarGroup(inProps,
|
|
|
110
109
|
}
|
|
111
110
|
const externalForwardedProps = {
|
|
112
111
|
slots,
|
|
113
|
-
slotProps
|
|
114
|
-
surplus: slotProps.additionalAvatar ?? componentsProps?.additionalAvatar,
|
|
115
|
-
...componentsProps,
|
|
116
|
-
...slotProps
|
|
117
|
-
}
|
|
112
|
+
slotProps
|
|
118
113
|
};
|
|
119
114
|
const [SurplusSlot, surplusProps] = (0, _useSlot.default)('surplus', {
|
|
120
115
|
elementType: _Avatar.default,
|
|
@@ -169,17 +164,6 @@ process.env.NODE_ENV !== "production" ? AvatarGroup.propTypes /* remove-proptype
|
|
|
169
164
|
* Either a string to use a HTML element or a component.
|
|
170
165
|
*/
|
|
171
166
|
component: _propTypes.default.elementType,
|
|
172
|
-
/**
|
|
173
|
-
* The extra props for the slot components.
|
|
174
|
-
* You can override the existing props or add new ones.
|
|
175
|
-
*
|
|
176
|
-
* This prop is an alias for the `slotProps` prop.
|
|
177
|
-
*
|
|
178
|
-
* @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
179
|
-
*/
|
|
180
|
-
componentsProps: _propTypes.default.shape({
|
|
181
|
-
additionalAvatar: _propTypes.default.object
|
|
182
|
-
}),
|
|
183
167
|
/**
|
|
184
168
|
* Max avatars to show before +x.
|
|
185
169
|
* @default 5
|
|
@@ -201,7 +185,6 @@ process.env.NODE_ENV !== "production" ? AvatarGroup.propTypes /* remove-proptype
|
|
|
201
185
|
* @default {}
|
|
202
186
|
*/
|
|
203
187
|
slotProps: _propTypes.default.shape({
|
|
204
|
-
additionalAvatar: _propTypes.default.object,
|
|
205
188
|
surplus: _propTypes.default.oneOfType([_propTypes.default.func, _propTypes.default.object])
|
|
206
189
|
}),
|
|
207
190
|
/**
|
|
@@ -58,7 +58,6 @@ const AvatarGroup = /*#__PURE__*/React.forwardRef(function AvatarGroup(inProps,
|
|
|
58
58
|
children: childrenProp,
|
|
59
59
|
className,
|
|
60
60
|
component = 'div',
|
|
61
|
-
componentsProps,
|
|
62
61
|
max = 5,
|
|
63
62
|
renderSurplus,
|
|
64
63
|
slotProps = {},
|
|
@@ -103,11 +102,7 @@ const AvatarGroup = /*#__PURE__*/React.forwardRef(function AvatarGroup(inProps,
|
|
|
103
102
|
}
|
|
104
103
|
const externalForwardedProps = {
|
|
105
104
|
slots,
|
|
106
|
-
slotProps
|
|
107
|
-
surplus: slotProps.additionalAvatar ?? componentsProps?.additionalAvatar,
|
|
108
|
-
...componentsProps,
|
|
109
|
-
...slotProps
|
|
110
|
-
}
|
|
105
|
+
slotProps
|
|
111
106
|
};
|
|
112
107
|
const [SurplusSlot, surplusProps] = useSlot('surplus', {
|
|
113
108
|
elementType: Avatar,
|
|
@@ -162,17 +157,6 @@ process.env.NODE_ENV !== "production" ? AvatarGroup.propTypes /* remove-proptype
|
|
|
162
157
|
* Either a string to use a HTML element or a component.
|
|
163
158
|
*/
|
|
164
159
|
component: PropTypes.elementType,
|
|
165
|
-
/**
|
|
166
|
-
* The extra props for the slot components.
|
|
167
|
-
* You can override the existing props or add new ones.
|
|
168
|
-
*
|
|
169
|
-
* This prop is an alias for the `slotProps` prop.
|
|
170
|
-
*
|
|
171
|
-
* @deprecated use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
172
|
-
*/
|
|
173
|
-
componentsProps: PropTypes.shape({
|
|
174
|
-
additionalAvatar: PropTypes.object
|
|
175
|
-
}),
|
|
176
160
|
/**
|
|
177
161
|
* Max avatars to show before +x.
|
|
178
162
|
* @default 5
|
|
@@ -194,7 +178,6 @@ process.env.NODE_ENV !== "production" ? AvatarGroup.propTypes /* remove-proptype
|
|
|
194
178
|
* @default {}
|
|
195
179
|
*/
|
|
196
180
|
slotProps: PropTypes.shape({
|
|
197
|
-
additionalAvatar: PropTypes.object,
|
|
198
181
|
surplus: PropTypes.oneOfType([PropTypes.func, PropTypes.object])
|
|
199
182
|
}),
|
|
200
183
|
/**
|
package/Backdrop/Backdrop.d.mts
CHANGED
|
@@ -38,27 +38,6 @@ export interface BackdropOwnProps extends Partial<Omit<FadeProps, 'children'>>,
|
|
|
38
38
|
* The content of the component.
|
|
39
39
|
*/
|
|
40
40
|
children?: React.ReactNode;
|
|
41
|
-
/**
|
|
42
|
-
* The components used for each slot inside.
|
|
43
|
-
*
|
|
44
|
-
* @deprecated Use the `slots` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
45
|
-
*
|
|
46
|
-
* @default {}
|
|
47
|
-
*/
|
|
48
|
-
components?: {
|
|
49
|
-
Root?: React.ElementType | undefined;
|
|
50
|
-
} | undefined;
|
|
51
|
-
/**
|
|
52
|
-
* The extra props for the slot components.
|
|
53
|
-
* You can override the existing props or add new ones.
|
|
54
|
-
*
|
|
55
|
-
* @deprecated Use the `slotProps` prop instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](https://mui.com/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
56
|
-
*
|
|
57
|
-
* @default {}
|
|
58
|
-
*/
|
|
59
|
-
componentsProps?: {
|
|
60
|
-
root?: (React.HTMLAttributes<HTMLDivElement> & BackdropComponentsPropsOverrides) | undefined;
|
|
61
|
-
} | undefined;
|
|
62
41
|
/**
|
|
63
42
|
* Override or extend the styles applied to the component.
|
|
64
43
|
*/
|
|
@@ -82,21 +61,12 @@ export interface BackdropOwnProps extends Partial<Omit<FadeProps, 'children'>>,
|
|
|
82
61
|
* You may specify a single timeout for all transitions, or individually with an object.
|
|
83
62
|
*/
|
|
84
63
|
transitionDuration?: TransitionProps['timeout'] | undefined;
|
|
85
|
-
/**
|
|
86
|
-
* The component used for the transition.
|
|
87
|
-
* [Follow this guide](https://mui.com/material-ui/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.
|
|
88
|
-
* @default Fade
|
|
89
|
-
* @deprecated Use `slots.transition` instead. This prop will be removed in a future major release. See [Migrating from deprecated APIs](/material-ui/migration/migrating-from-deprecated-apis/) for more details.
|
|
90
|
-
*/
|
|
91
|
-
TransitionComponent?: React.JSXElementConstructor<TransitionProps & {
|
|
92
|
-
children: React.ReactElement<unknown, any>;
|
|
93
|
-
}> | undefined;
|
|
94
64
|
}
|
|
95
65
|
export interface BackdropTypeMap<AdditionalProps = {}, RootComponent extends React.ElementType = 'div'> {
|
|
96
66
|
props: AdditionalProps & BackdropOwnProps;
|
|
97
67
|
defaultComponent: RootComponent;
|
|
98
68
|
}
|
|
99
|
-
type BackdropRootProps =
|
|
69
|
+
type BackdropRootProps = React.HTMLAttributes<HTMLDivElement> & BackdropComponentsPropsOverrides;
|
|
100
70
|
export declare const BackdropRoot: React.FC<BackdropRootProps>;
|
|
101
71
|
|
|
102
72
|
/**
|