@mui/material 5.14.7 → 5.14.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/Accordion/Accordion.d.ts +2 -2
  2. package/AccordionSummary/AccordionSummary.d.ts +22 -20
  3. package/AppBar/AppBar.d.ts +33 -31
  4. package/Avatar/Avatar.d.ts +49 -50
  5. package/Backdrop/Backdrop.d.ts +87 -85
  6. package/Badge/Badge.d.ts +2 -2
  7. package/BottomNavigation/BottomNavigation.d.ts +35 -33
  8. package/BottomNavigationAction/BottomNavigationAction.d.ts +39 -37
  9. package/Breadcrumbs/Breadcrumbs.d.ts +69 -67
  10. package/Button/Button.d.ts +72 -73
  11. package/ButtonBase/ButtonBase.d.ts +83 -81
  12. package/ButtonGroup/ButtonGroup.d.ts +72 -70
  13. package/CHANGELOG.md +111 -19
  14. package/Card/Card.d.ts +19 -18
  15. package/CardActionArea/CardActionArea.d.ts +15 -13
  16. package/CardContent/CardContent.d.ts +18 -16
  17. package/CardHeader/CardHeader.d.ts +77 -67
  18. package/CardMedia/CardMedia.d.ts +30 -28
  19. package/Chip/Chip.d.ts +84 -82
  20. package/CircularProgress/CircularProgress.d.ts +1 -1
  21. package/CircularProgress/CircularProgress.js +1 -1
  22. package/Container/Container.d.ts +35 -33
  23. package/DialogContentText/DialogContentText.d.ts +14 -12
  24. package/DialogTitle/DialogTitle.d.ts +18 -16
  25. package/Divider/Divider.d.ts +49 -50
  26. package/Fab/Fab.d.ts +59 -56
  27. package/FormControl/FormControl.d.ts +74 -72
  28. package/FormHelperText/FormHelperText.d.ts +52 -50
  29. package/FormLabel/FormLabel.d.ts +7 -4
  30. package/Grid/Grid.d.ts +69 -68
  31. package/Hidden/Hidden.d.ts +10 -10
  32. package/Icon/Icon.d.ts +50 -48
  33. package/IconButton/IconButton.d.ts +52 -50
  34. package/ImageList/ImageList.d.ts +41 -39
  35. package/ImageListItem/ImageListItem.d.ts +28 -26
  36. package/ImageListItem/ImageListItem.js +2 -1
  37. package/InputAdornment/InputAdornment.d.ts +39 -37
  38. package/InputBase/InputBase.js +1 -1
  39. package/InputLabel/InputLabel.d.ts +58 -56
  40. package/InputLabel/InputLabel.js +2 -1
  41. package/Link/Link.d.ts +37 -39
  42. package/List/List.d.ts +34 -35
  43. package/ListItem/ListItem.d.ts +53 -49
  44. package/ListItemButton/ListItemButton.d.ts +9 -3
  45. package/ListSubheader/ListSubheader.d.ts +38 -36
  46. package/MenuItem/MenuItem.d.ts +47 -44
  47. package/MenuList/MenuList.d.ts +37 -35
  48. package/Modal/Modal.d.ts +172 -178
  49. package/PaginationItem/PaginationItem.d.ts +85 -83
  50. package/Paper/Paper.d.ts +2 -2
  51. package/Radio/Radio.js +3 -2
  52. package/Radio/radioClasses.d.ts +2 -0
  53. package/Radio/radioClasses.js +1 -1
  54. package/ScopedCssBaseline/ScopedCssBaseline.d.ts +25 -23
  55. package/Select/SelectInput.js +9 -5
  56. package/Skeleton/Skeleton.d.ts +42 -40
  57. package/Slider/Slider.d.ts +249 -247
  58. package/Stack/Stack.d.ts +39 -38
  59. package/Step/Step.d.ts +46 -44
  60. package/StepButton/StepButton.d.ts +27 -25
  61. package/Stepper/Stepper.d.ts +45 -44
  62. package/SvgIcon/SvgIcon.d.ts +77 -75
  63. package/SwipeableDrawer/SwipeableDrawer.js +4 -4
  64. package/Tab/Tab.d.ts +52 -50
  65. package/TabScrollButton/TabScrollButton.d.ts +3 -2
  66. package/Table/Table.d.ts +35 -33
  67. package/TableBody/TableBody.d.ts +18 -16
  68. package/TableContainer/TableContainer.d.ts +18 -16
  69. package/TableFooter/TableFooter.d.ts +18 -16
  70. package/TableHead/TableHead.d.ts +18 -16
  71. package/TablePagination/TablePagination.d.ts +113 -112
  72. package/TableRow/TableRow.d.ts +28 -26
  73. package/TableSortLabel/TableSortLabel.d.ts +40 -36
  74. package/Tabs/Tabs.d.ts +153 -150
  75. package/ToggleButton/ToggleButton.d.ts +72 -70
  76. package/Toolbar/Toolbar.d.ts +29 -27
  77. package/Typography/Typography.d.ts +2 -2
  78. package/index.js +1 -1
  79. package/legacy/CircularProgress/CircularProgress.js +1 -1
  80. package/legacy/ImageListItem/ImageListItem.js +2 -1
  81. package/legacy/InputBase/InputBase.js +1 -1
  82. package/legacy/InputLabel/InputLabel.js +2 -1
  83. package/legacy/Radio/Radio.js +3 -2
  84. package/legacy/Radio/radioClasses.js +1 -1
  85. package/legacy/Select/SelectInput.js +9 -5
  86. package/legacy/SwipeableDrawer/SwipeableDrawer.js +4 -4
  87. package/legacy/index.js +1 -1
  88. package/modern/CircularProgress/CircularProgress.js +1 -1
  89. package/modern/ImageListItem/ImageListItem.js +2 -1
  90. package/modern/InputBase/InputBase.js +1 -1
  91. package/modern/InputLabel/InputLabel.js +2 -1
  92. package/modern/Radio/Radio.js +3 -2
  93. package/modern/Radio/radioClasses.js +1 -1
  94. package/modern/Select/SelectInput.js +8 -5
  95. package/modern/SwipeableDrawer/SwipeableDrawer.js +4 -4
  96. package/modern/index.js +1 -1
  97. package/node/CircularProgress/CircularProgress.js +1 -1
  98. package/node/ImageListItem/ImageListItem.js +2 -1
  99. package/node/InputBase/InputBase.js +1 -1
  100. package/node/InputLabel/InputLabel.js +2 -1
  101. package/node/Radio/Radio.js +3 -2
  102. package/node/Radio/radioClasses.js +1 -1
  103. package/node/Select/SelectInput.js +9 -5
  104. package/node/SwipeableDrawer/SwipeableDrawer.js +4 -4
  105. package/node/index.js +1 -1
  106. package/package.json +5 -5
  107. package/umd/material-ui.development.js +50 -23
  108. package/umd/material-ui.production.min.js +5 -5
@@ -12,77 +12,79 @@ export interface BreadcrumbsOwnerState extends BreadcrumbsProps {
12
12
  expanded: boolean;
13
13
  }
14
14
 
15
- export interface BreadcrumbsTypeMap<
16
- AdditionalProps = {},
17
- DefaultComponent extends React.ElementType = 'nav',
18
- > {
19
- props: AdditionalProps & {
20
- /**
21
- * The content of the component.
22
- */
23
- children?: React.ReactNode;
24
- /**
25
- * Override or extend the styles applied to the component.
26
- */
27
- classes?: Partial<BreadcrumbsClasses>;
28
- /**
29
- * The components used for each slot inside the Breadcumb.
30
- * Either a string to use a HTML element or a component.
31
- * @default {}
32
- */
33
- slots?: {
34
- CollapsedIcon?: React.ElementType;
35
- };
15
+ export interface BreadcrumbsOwnProps {
16
+ /**
17
+ * The content of the component.
18
+ */
19
+ children?: React.ReactNode;
20
+ /**
21
+ * Override or extend the styles applied to the component.
22
+ */
23
+ classes?: Partial<BreadcrumbsClasses>;
24
+ /**
25
+ * The components used for each slot inside the Breadcumb.
26
+ * Either a string to use a HTML element or a component.
27
+ * @default {}
28
+ */
29
+ slots?: {
30
+ CollapsedIcon?: React.ElementType;
31
+ };
32
+ /**
33
+ * The props used for each slot inside the Breadcumb.
34
+ * @default {}
35
+ */
36
+ slotProps?: {
36
37
  /**
37
- * The props used for each slot inside the Breadcumb.
38
+ * Props applied to the CollapsedIcon slot.
38
39
  * @default {}
39
40
  */
40
- slotProps?: {
41
- /**
42
- * Props applied to the CollapsedIcon slot.
43
- * @default {}
44
- */
45
- collapsedIcon?: SlotComponentProps<
46
- typeof SvgIcon,
47
- BreadcrumbsCollapsedIconSlotPropsOverrides,
48
- BreadcrumbsOwnerState
49
- >;
50
- };
51
- /**
52
- * Override the default label for the expand button.
53
- *
54
- * For localization purposes, you can use the provided [translations](/material-ui/guides/localization/).
55
- * @default 'Show path'
56
- */
57
- expandText?: string;
58
- /**
59
- * If max items is exceeded, the number of items to show after the ellipsis.
60
- * @default 1
61
- */
62
- itemsAfterCollapse?: number;
63
- /**
64
- * If max items is exceeded, the number of items to show before the ellipsis.
65
- * @default 1
66
- */
67
- itemsBeforeCollapse?: number;
68
- /**
69
- * Specifies the maximum number of breadcrumbs to display. When there are more
70
- * than the maximum number, only the first `itemsBeforeCollapse` and last `itemsAfterCollapse`
71
- * will be shown, with an ellipsis in between.
72
- * @default 8
73
- */
74
- maxItems?: number;
75
- /**
76
- * Custom separator node.
77
- * @default '/'
78
- */
79
- separator?: React.ReactNode;
80
- /**
81
- * The system prop that allows defining system overrides as well as additional CSS styles.
82
- */
83
- sx?: SxProps<Theme>;
41
+ collapsedIcon?: SlotComponentProps<
42
+ typeof SvgIcon,
43
+ BreadcrumbsCollapsedIconSlotPropsOverrides,
44
+ BreadcrumbsOwnerState
45
+ >;
84
46
  };
85
- defaultComponent: DefaultComponent;
47
+ /**
48
+ * Override the default label for the expand button.
49
+ *
50
+ * For localization purposes, you can use the provided [translations](/material-ui/guides/localization/).
51
+ * @default 'Show path'
52
+ */
53
+ expandText?: string;
54
+ /**
55
+ * If max items is exceeded, the number of items to show after the ellipsis.
56
+ * @default 1
57
+ */
58
+ itemsAfterCollapse?: number;
59
+ /**
60
+ * If max items is exceeded, the number of items to show before the ellipsis.
61
+ * @default 1
62
+ */
63
+ itemsBeforeCollapse?: number;
64
+ /**
65
+ * Specifies the maximum number of breadcrumbs to display. When there are more
66
+ * than the maximum number, only the first `itemsBeforeCollapse` and last `itemsAfterCollapse`
67
+ * will be shown, with an ellipsis in between.
68
+ * @default 8
69
+ */
70
+ maxItems?: number;
71
+ /**
72
+ * Custom separator node.
73
+ * @default '/'
74
+ */
75
+ separator?: React.ReactNode;
76
+ /**
77
+ * The system prop that allows defining system overrides as well as additional CSS styles.
78
+ */
79
+ sx?: SxProps<Theme>;
80
+ }
81
+
82
+ export interface BreadcrumbsTypeMap<
83
+ AdditionalProps = {},
84
+ RootComponent extends React.ElementType = 'nav',
85
+ > {
86
+ props: AdditionalProps & BreadcrumbsOwnProps;
87
+ defaultComponent: RootComponent;
86
88
  }
87
89
 
88
90
  /**
@@ -12,82 +12,81 @@ export interface ButtonPropsColorOverrides {}
12
12
 
13
13
  export interface ButtonPropsSizeOverrides {}
14
14
 
15
+ export interface ButtonOwnProps {
16
+ /**
17
+ * The content of the component.
18
+ */
19
+ children?: React.ReactNode;
20
+ /**
21
+ * Override or extend the styles applied to the component.
22
+ */
23
+ classes?: Partial<ButtonClasses>;
24
+ /**
25
+ * The color of the component.
26
+ * It supports both default and custom theme colors, which can be added as shown in the
27
+ * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
28
+ * @default 'primary'
29
+ */
30
+ color?: OverridableStringUnion<
31
+ 'inherit' | 'primary' | 'secondary' | 'success' | 'error' | 'info' | 'warning',
32
+ ButtonPropsColorOverrides
33
+ >;
34
+ /**
35
+ * If `true`, the component is disabled.
36
+ * @default false
37
+ */
38
+ disabled?: boolean;
39
+ /**
40
+ * If `true`, no elevation is used.
41
+ * @default false
42
+ */
43
+ disableElevation?: boolean;
44
+ /**
45
+ * If `true`, the keyboard focus ripple is disabled.
46
+ * @default false
47
+ */
48
+ disableFocusRipple?: boolean;
49
+ /**
50
+ * Element placed after the children.
51
+ */
52
+ endIcon?: React.ReactNode;
53
+ /**
54
+ * If `true`, the button will take up the full width of its container.
55
+ * @default false
56
+ */
57
+ fullWidth?: boolean;
58
+ /**
59
+ * The URL to link to when the button is clicked.
60
+ * If defined, an `a` element will be used as the root node.
61
+ */
62
+ href?: string;
63
+ /**
64
+ * The size of the component.
65
+ * `small` is equivalent to the dense button styling.
66
+ * @default 'medium'
67
+ */
68
+ size?: OverridableStringUnion<'small' | 'medium' | 'large', ButtonPropsSizeOverrides>;
69
+ /**
70
+ * Element placed before the children.
71
+ */
72
+ startIcon?: React.ReactNode;
73
+ /**
74
+ * The system prop that allows defining system overrides as well as additional CSS styles.
75
+ */
76
+ sx?: SxProps<Theme>;
77
+ /**
78
+ * The variant to use.
79
+ * @default 'text'
80
+ */
81
+ variant?: OverridableStringUnion<'text' | 'outlined' | 'contained', ButtonPropsVariantOverrides>;
82
+ }
83
+
15
84
  export type ButtonTypeMap<
16
85
  AdditionalProps = {},
17
- DefaultComponent extends React.ElementType = 'button',
86
+ RootComponent extends React.ElementType = 'button',
18
87
  > = ExtendButtonBaseTypeMap<{
19
- props: AdditionalProps & {
20
- /**
21
- * The content of the component.
22
- */
23
- children?: React.ReactNode;
24
- /**
25
- * Override or extend the styles applied to the component.
26
- */
27
- classes?: Partial<ButtonClasses>;
28
- /**
29
- * The color of the component.
30
- * It supports both default and custom theme colors, which can be added as shown in the
31
- * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
32
- * @default 'primary'
33
- */
34
- color?: OverridableStringUnion<
35
- 'inherit' | 'primary' | 'secondary' | 'success' | 'error' | 'info' | 'warning',
36
- ButtonPropsColorOverrides
37
- >;
38
- /**
39
- * If `true`, the component is disabled.
40
- * @default false
41
- */
42
- disabled?: boolean;
43
- /**
44
- * If `true`, no elevation is used.
45
- * @default false
46
- */
47
- disableElevation?: boolean;
48
- /**
49
- * If `true`, the keyboard focus ripple is disabled.
50
- * @default false
51
- */
52
- disableFocusRipple?: boolean;
53
- /**
54
- * Element placed after the children.
55
- */
56
- endIcon?: React.ReactNode;
57
- /**
58
- * If `true`, the button will take up the full width of its container.
59
- * @default false
60
- */
61
- fullWidth?: boolean;
62
- /**
63
- * The URL to link to when the button is clicked.
64
- * If defined, an `a` element will be used as the root node.
65
- */
66
- href?: string;
67
- /**
68
- * The size of the component.
69
- * `small` is equivalent to the dense button styling.
70
- * @default 'medium'
71
- */
72
- size?: OverridableStringUnion<'small' | 'medium' | 'large', ButtonPropsSizeOverrides>;
73
- /**
74
- * Element placed before the children.
75
- */
76
- startIcon?: React.ReactNode;
77
- /**
78
- * The system prop that allows defining system overrides as well as additional CSS styles.
79
- */
80
- sx?: SxProps<Theme>;
81
- /**
82
- * The variant to use.
83
- * @default 'text'
84
- */
85
- variant?: OverridableStringUnion<
86
- 'text' | 'outlined' | 'contained',
87
- ButtonPropsVariantOverrides
88
- >;
89
- };
90
- defaultComponent: DefaultComponent;
88
+ props: AdditionalProps & ButtonOwnProps;
89
+ defaultComponent: RootComponent;
91
90
  }>;
92
91
 
93
92
  /**
@@ -5,90 +5,92 @@ import { TouchRippleActions, TouchRippleProps } from './TouchRipple';
5
5
  import { OverrideProps, OverridableComponent, OverridableTypeMap } from '../OverridableComponent';
6
6
  import { ButtonBaseClasses } from './buttonBaseClasses';
7
7
 
8
+ export interface ButtonBaseOwnProps {
9
+ /**
10
+ * A ref for imperative actions.
11
+ * It currently only supports `focusVisible()` action.
12
+ */
13
+ action?: React.Ref<ButtonBaseActions>;
14
+ /**
15
+ * If `true`, the ripples are centered.
16
+ * They won't start at the cursor interaction position.
17
+ * @default false
18
+ */
19
+ centerRipple?: boolean;
20
+ /**
21
+ * The content of the component.
22
+ */
23
+ children?: React.ReactNode;
24
+ /**
25
+ * Override or extend the styles applied to the component.
26
+ */
27
+ classes?: Partial<ButtonBaseClasses>;
28
+ /**
29
+ * If `true`, the component is disabled.
30
+ * @default false
31
+ */
32
+ disabled?: boolean;
33
+ /**
34
+ * If `true`, the ripple effect is disabled.
35
+ *
36
+ * ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure
37
+ * to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
38
+ * @default false
39
+ */
40
+ disableRipple?: boolean;
41
+ /**
42
+ * If `true`, the touch ripple effect is disabled.
43
+ * @default false
44
+ */
45
+ disableTouchRipple?: boolean;
46
+ /**
47
+ * If `true`, the base button will have a keyboard focus ripple.
48
+ * @default false
49
+ */
50
+ focusRipple?: boolean;
51
+ /**
52
+ * This prop can help identify which element has keyboard focus.
53
+ * The class name will be applied when the element gains the focus through keyboard interaction.
54
+ * It's a polyfill for the [CSS :focus-visible selector](https://drafts.csswg.org/selectors-4/#the-focus-visible-pseudo).
55
+ * The rationale for using this feature [is explained here](https://github.com/WICG/focus-visible/blob/HEAD/explainer.md).
56
+ * A [polyfill can be used](https://github.com/WICG/focus-visible) to apply a `focus-visible` class to other components
57
+ * if needed.
58
+ */
59
+ focusVisibleClassName?: string;
60
+ /**
61
+ * The component used to render a link when the `href` prop is provided.
62
+ * @default 'a'
63
+ */
64
+ LinkComponent?: React.ElementType;
65
+ /**
66
+ * Callback fired when the component is focused with a keyboard.
67
+ * We trigger a `onFocus` callback too.
68
+ */
69
+ onFocusVisible?: React.FocusEventHandler<any>;
70
+ /**
71
+ * The system prop that allows defining system overrides as well as additional CSS styles.
72
+ */
73
+ sx?: SxProps<Theme>;
74
+ /**
75
+ * @default 0
76
+ */
77
+ tabIndex?: NonNullable<React.HTMLAttributes<any>['tabIndex']>;
78
+ /**
79
+ * Props applied to the `TouchRipple` element.
80
+ */
81
+ TouchRippleProps?: Partial<TouchRippleProps>;
82
+ /**
83
+ * A ref that points to the `TouchRipple` element.
84
+ */
85
+ touchRippleRef?: React.Ref<TouchRippleActions>;
86
+ }
87
+
8
88
  export interface ButtonBaseTypeMap<
9
89
  AdditionalProps = {},
10
- DefaultComponent extends React.ElementType = 'button',
90
+ RootComponent extends React.ElementType = 'button',
11
91
  > {
12
- props: AdditionalProps & {
13
- /**
14
- * A ref for imperative actions.
15
- * It currently only supports `focusVisible()` action.
16
- */
17
- action?: React.Ref<ButtonBaseActions>;
18
- /**
19
- * If `true`, the ripples are centered.
20
- * They won't start at the cursor interaction position.
21
- * @default false
22
- */
23
- centerRipple?: boolean;
24
- /**
25
- * The content of the component.
26
- */
27
- children?: React.ReactNode;
28
- /**
29
- * Override or extend the styles applied to the component.
30
- */
31
- classes?: Partial<ButtonBaseClasses>;
32
- /**
33
- * If `true`, the component is disabled.
34
- * @default false
35
- */
36
- disabled?: boolean;
37
- /**
38
- * If `true`, the ripple effect is disabled.
39
- *
40
- * ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure
41
- * to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
42
- * @default false
43
- */
44
- disableRipple?: boolean;
45
- /**
46
- * If `true`, the touch ripple effect is disabled.
47
- * @default false
48
- */
49
- disableTouchRipple?: boolean;
50
- /**
51
- * If `true`, the base button will have a keyboard focus ripple.
52
- * @default false
53
- */
54
- focusRipple?: boolean;
55
- /**
56
- * This prop can help identify which element has keyboard focus.
57
- * The class name will be applied when the element gains the focus through keyboard interaction.
58
- * It's a polyfill for the [CSS :focus-visible selector](https://drafts.csswg.org/selectors-4/#the-focus-visible-pseudo).
59
- * The rationale for using this feature [is explained here](https://github.com/WICG/focus-visible/blob/HEAD/explainer.md).
60
- * A [polyfill can be used](https://github.com/WICG/focus-visible) to apply a `focus-visible` class to other components
61
- * if needed.
62
- */
63
- focusVisibleClassName?: string;
64
- /**
65
- * The component used to render a link when the `href` prop is provided.
66
- * @default 'a'
67
- */
68
- LinkComponent?: React.ElementType;
69
- /**
70
- * Callback fired when the component is focused with a keyboard.
71
- * We trigger a `onFocus` callback too.
72
- */
73
- onFocusVisible?: React.FocusEventHandler<any>;
74
- /**
75
- * The system prop that allows defining system overrides as well as additional CSS styles.
76
- */
77
- sx?: SxProps<Theme>;
78
- /**
79
- * @default 0
80
- */
81
- tabIndex?: NonNullable<React.HTMLAttributes<any>['tabIndex']>;
82
- /**
83
- * Props applied to the `TouchRipple` element.
84
- */
85
- TouchRippleProps?: Partial<TouchRippleProps>;
86
- /**
87
- * A ref that points to the `TouchRipple` element.
88
- */
89
- touchRippleRef?: React.Ref<TouchRippleActions>;
90
- };
91
- defaultComponent: DefaultComponent;
92
+ props: AdditionalProps & ButtonBaseOwnProps;
93
+ defaultComponent: RootComponent;
92
94
  }
93
95
 
94
96
  /**
@@ -9,79 +9,81 @@ export interface ButtonGroupPropsColorOverrides {}
9
9
  export interface ButtonGroupPropsVariantOverrides {}
10
10
  export interface ButtonGroupPropsSizeOverrides {}
11
11
 
12
+ export interface ButtonGroupOwnProps {
13
+ /**
14
+ * The content of the component.
15
+ */
16
+ children?: React.ReactNode;
17
+ /**
18
+ * Override or extend the styles applied to the component.
19
+ */
20
+ classes?: Partial<ButtonGroupClasses>;
21
+ /**
22
+ * The color of the component.
23
+ * It supports both default and custom theme colors, which can be added as shown in the
24
+ * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
25
+ * @default 'primary'
26
+ */
27
+ color?: OverridableStringUnion<
28
+ 'inherit' | 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning',
29
+ ButtonGroupPropsColorOverrides
30
+ >;
31
+ /**
32
+ * If `true`, the component is disabled.
33
+ * @default false
34
+ */
35
+ disabled?: boolean;
36
+ /**
37
+ * If `true`, no elevation is used.
38
+ * @default false
39
+ */
40
+ disableElevation?: boolean;
41
+ /**
42
+ * If `true`, the button keyboard focus ripple is disabled.
43
+ * @default false
44
+ */
45
+ disableFocusRipple?: boolean;
46
+ /**
47
+ * If `true`, the button ripple effect is disabled.
48
+ * @default false
49
+ */
50
+ disableRipple?: boolean;
51
+ /**
52
+ * If `true`, the buttons will take up the full width of its container.
53
+ * @default false
54
+ */
55
+ fullWidth?: boolean;
56
+ /**
57
+ * The component orientation (layout flow direction).
58
+ * @default 'horizontal'
59
+ */
60
+ orientation?: 'vertical' | 'horizontal';
61
+ /**
62
+ * The size of the component.
63
+ * `small` is equivalent to the dense button styling.
64
+ * @default 'medium'
65
+ */
66
+ size?: OverridableStringUnion<'small' | 'medium' | 'large', ButtonGroupPropsSizeOverrides>;
67
+ /**
68
+ * The variant to use.
69
+ * @default 'outlined'
70
+ */
71
+ variant?: OverridableStringUnion<
72
+ 'text' | 'outlined' | 'contained',
73
+ ButtonGroupPropsVariantOverrides
74
+ >;
75
+ /**
76
+ * The system prop that allows defining system overrides as well as additional CSS styles.
77
+ */
78
+ sx?: SxProps<Theme>;
79
+ }
80
+
12
81
  export interface ButtonGroupTypeMap<
13
82
  AdditionalProps = {},
14
- DefaultComponent extends React.ElementType = 'div',
83
+ RootComponent extends React.ElementType = 'div',
15
84
  > {
16
- props: AdditionalProps & {
17
- /**
18
- * The content of the component.
19
- */
20
- children?: React.ReactNode;
21
- /**
22
- * Override or extend the styles applied to the component.
23
- */
24
- classes?: Partial<ButtonGroupClasses>;
25
- /**
26
- * The color of the component.
27
- * It supports both default and custom theme colors, which can be added as shown in the
28
- * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
29
- * @default 'primary'
30
- */
31
- color?: OverridableStringUnion<
32
- 'inherit' | 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning',
33
- ButtonGroupPropsColorOverrides
34
- >;
35
- /**
36
- * If `true`, the component is disabled.
37
- * @default false
38
- */
39
- disabled?: boolean;
40
- /**
41
- * If `true`, no elevation is used.
42
- * @default false
43
- */
44
- disableElevation?: boolean;
45
- /**
46
- * If `true`, the button keyboard focus ripple is disabled.
47
- * @default false
48
- */
49
- disableFocusRipple?: boolean;
50
- /**
51
- * If `true`, the button ripple effect is disabled.
52
- * @default false
53
- */
54
- disableRipple?: boolean;
55
- /**
56
- * If `true`, the buttons will take up the full width of its container.
57
- * @default false
58
- */
59
- fullWidth?: boolean;
60
- /**
61
- * The component orientation (layout flow direction).
62
- * @default 'horizontal'
63
- */
64
- orientation?: 'vertical' | 'horizontal';
65
- /**
66
- * The size of the component.
67
- * `small` is equivalent to the dense button styling.
68
- * @default 'medium'
69
- */
70
- size?: OverridableStringUnion<'small' | 'medium' | 'large', ButtonGroupPropsSizeOverrides>;
71
- /**
72
- * The variant to use.
73
- * @default 'outlined'
74
- */
75
- variant?: OverridableStringUnion<
76
- 'text' | 'outlined' | 'contained',
77
- ButtonGroupPropsVariantOverrides
78
- >;
79
- /**
80
- * The system prop that allows defining system overrides as well as additional CSS styles.
81
- */
82
- sx?: SxProps<Theme>;
83
- };
84
- defaultComponent: DefaultComponent;
85
+ props: AdditionalProps & ButtonGroupOwnProps;
86
+ defaultComponent: RootComponent;
85
87
  }
86
88
 
87
89
  /**