@mui/material 5.14.7 → 5.14.9

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 (143) hide show
  1. package/Accordion/Accordion.d.ts +2 -2
  2. package/AccordionSummary/AccordionSummary.d.ts +22 -20
  3. package/AlertTitle/AlertTitle.d.ts +1 -0
  4. package/AppBar/AppBar.d.ts +33 -31
  5. package/Avatar/Avatar.d.ts +49 -50
  6. package/Backdrop/Backdrop.d.ts +87 -85
  7. package/Badge/Badge.d.ts +2 -2
  8. package/BottomNavigation/BottomNavigation.d.ts +35 -33
  9. package/BottomNavigationAction/BottomNavigationAction.d.ts +39 -37
  10. package/Breadcrumbs/Breadcrumbs.d.ts +70 -67
  11. package/Button/Button.d.ts +72 -73
  12. package/Button/Button.js +4 -1
  13. package/ButtonBase/ButtonBase.d.ts +83 -81
  14. package/ButtonGroup/ButtonGroup.d.ts +72 -70
  15. package/ButtonGroup/ButtonGroup.js +86 -54
  16. package/ButtonGroup/ButtonGroupButtonContext.d.ts +6 -0
  17. package/ButtonGroup/ButtonGroupButtonContext.js +9 -0
  18. package/ButtonGroup/buttonGroupClasses.d.ts +6 -0
  19. package/ButtonGroup/buttonGroupClasses.js +1 -1
  20. package/CHANGELOG.md +235 -38
  21. package/Card/Card.d.ts +19 -18
  22. package/CardActionArea/CardActionArea.d.ts +15 -13
  23. package/CardContent/CardContent.d.ts +18 -16
  24. package/CardHeader/CardHeader.d.ts +77 -67
  25. package/CardMedia/CardMedia.d.ts +30 -28
  26. package/Chip/Chip.d.ts +84 -82
  27. package/CircularProgress/CircularProgress.d.ts +1 -1
  28. package/CircularProgress/CircularProgress.js +1 -1
  29. package/Container/Container.d.ts +35 -33
  30. package/DialogContentText/DialogContentText.d.ts +14 -12
  31. package/DialogTitle/DialogTitle.d.ts +19 -16
  32. package/Divider/Divider.d.ts +49 -50
  33. package/Fab/Fab.d.ts +59 -56
  34. package/FormControl/FormControl.d.ts +74 -72
  35. package/FormHelperText/FormHelperText.d.ts +52 -50
  36. package/FormLabel/FormLabel.d.ts +7 -4
  37. package/Grid/Grid.d.ts +69 -68
  38. package/Hidden/Hidden.d.ts +10 -10
  39. package/Icon/Icon.d.ts +50 -48
  40. package/IconButton/IconButton.d.ts +52 -50
  41. package/ImageList/ImageList.d.ts +41 -39
  42. package/ImageListItem/ImageListItem.d.ts +28 -26
  43. package/ImageListItem/ImageListItem.js +2 -1
  44. package/InputAdornment/InputAdornment.d.ts +39 -37
  45. package/InputBase/InputBase.js +1 -1
  46. package/InputLabel/InputLabel.d.ts +58 -56
  47. package/InputLabel/InputLabel.js +2 -1
  48. package/Link/Link.d.ts +37 -39
  49. package/List/List.d.ts +34 -35
  50. package/ListItem/ListItem.d.ts +53 -49
  51. package/ListItemButton/ListItemButton.d.ts +9 -3
  52. package/ListSubheader/ListSubheader.d.ts +38 -36
  53. package/MenuItem/MenuItem.d.ts +47 -44
  54. package/MenuList/MenuList.d.ts +37 -35
  55. package/Modal/Modal.d.ts +172 -178
  56. package/Modal/Modal.js +1 -1
  57. package/PaginationItem/PaginationItem.d.ts +85 -83
  58. package/Paper/Paper.d.ts +2 -2
  59. package/README.md +9 -198
  60. package/Radio/Radio.js +3 -2
  61. package/Radio/radioClasses.d.ts +2 -0
  62. package/Radio/radioClasses.js +1 -1
  63. package/ScopedCssBaseline/ScopedCssBaseline.d.ts +25 -23
  64. package/Select/SelectInput.js +9 -5
  65. package/Skeleton/Skeleton.d.ts +42 -40
  66. package/Slider/Slider.d.ts +249 -247
  67. package/Slider/Slider.js +9 -86
  68. package/Stack/Stack.d.ts +39 -38
  69. package/Step/Step.d.ts +46 -44
  70. package/StepButton/StepButton.d.ts +27 -25
  71. package/Stepper/Stepper.d.ts +45 -44
  72. package/SvgIcon/SvgIcon.d.ts +77 -75
  73. package/SwipeableDrawer/SwipeableDrawer.js +4 -4
  74. package/Tab/Tab.d.ts +52 -50
  75. package/TabScrollButton/TabScrollButton.d.ts +3 -2
  76. package/Table/Table.d.ts +35 -33
  77. package/TableBody/TableBody.d.ts +18 -16
  78. package/TableContainer/TableContainer.d.ts +18 -16
  79. package/TableFooter/TableFooter.d.ts +18 -16
  80. package/TableHead/TableHead.d.ts +18 -16
  81. package/TablePagination/TablePagination.d.ts +113 -112
  82. package/TableRow/TableRow.d.ts +28 -26
  83. package/TableSortLabel/TableSortLabel.d.ts +40 -36
  84. package/Tabs/Tabs.d.ts +153 -150
  85. package/Tabs/Tabs.js +1 -4
  86. package/ToggleButton/ToggleButton.d.ts +72 -70
  87. package/Toolbar/Toolbar.d.ts +29 -27
  88. package/Typography/Typography.d.ts +2 -2
  89. package/index.js +1 -1
  90. package/legacy/Button/Button.js +4 -1
  91. package/legacy/ButtonGroup/ButtonGroup.js +81 -56
  92. package/legacy/ButtonGroup/ButtonGroupButtonContext.js +9 -0
  93. package/legacy/ButtonGroup/buttonGroupClasses.js +1 -1
  94. package/legacy/CircularProgress/CircularProgress.js +1 -1
  95. package/legacy/ImageListItem/ImageListItem.js +2 -1
  96. package/legacy/InputBase/InputBase.js +1 -1
  97. package/legacy/InputLabel/InputLabel.js +2 -1
  98. package/legacy/Modal/Modal.js +3 -1
  99. package/legacy/Radio/Radio.js +3 -2
  100. package/legacy/Radio/radioClasses.js +1 -1
  101. package/legacy/Select/SelectInput.js +9 -5
  102. package/legacy/Slider/Slider.js +9 -86
  103. package/legacy/SwipeableDrawer/SwipeableDrawer.js +4 -4
  104. package/legacy/Tabs/Tabs.js +1 -4
  105. package/legacy/index.js +1 -1
  106. package/legacy/useTouchRipple/useTouchRipple.js +4 -4
  107. package/modern/Button/Button.js +4 -1
  108. package/modern/ButtonGroup/ButtonGroup.js +86 -54
  109. package/modern/ButtonGroup/ButtonGroupButtonContext.js +9 -0
  110. package/modern/ButtonGroup/buttonGroupClasses.js +1 -1
  111. package/modern/CircularProgress/CircularProgress.js +1 -1
  112. package/modern/ImageListItem/ImageListItem.js +2 -1
  113. package/modern/InputBase/InputBase.js +1 -1
  114. package/modern/InputLabel/InputLabel.js +2 -1
  115. package/modern/Modal/Modal.js +1 -1
  116. package/modern/Radio/Radio.js +3 -2
  117. package/modern/Radio/radioClasses.js +1 -1
  118. package/modern/Select/SelectInput.js +8 -5
  119. package/modern/Slider/Slider.js +9 -86
  120. package/modern/SwipeableDrawer/SwipeableDrawer.js +4 -4
  121. package/modern/Tabs/Tabs.js +1 -4
  122. package/modern/index.js +1 -1
  123. package/node/Button/Button.js +4 -1
  124. package/node/ButtonGroup/ButtonGroup.js +86 -54
  125. package/node/ButtonGroup/ButtonGroupButtonContext.js +18 -0
  126. package/node/ButtonGroup/buttonGroupClasses.js +1 -1
  127. package/node/CircularProgress/CircularProgress.js +1 -1
  128. package/node/ImageListItem/ImageListItem.js +2 -1
  129. package/node/InputBase/InputBase.js +1 -1
  130. package/node/InputLabel/InputLabel.js +2 -1
  131. package/node/Modal/Modal.js +1 -1
  132. package/node/Radio/Radio.js +3 -2
  133. package/node/Radio/radioClasses.js +1 -1
  134. package/node/Select/SelectInput.js +9 -5
  135. package/node/Slider/Slider.js +3 -73
  136. package/node/SwipeableDrawer/SwipeableDrawer.js +4 -4
  137. package/node/Tabs/Tabs.js +1 -4
  138. package/node/index.js +1 -1
  139. package/node/useTouchRipple/useTouchRipple.js +4 -4
  140. package/package.json +16 -16
  141. package/umd/material-ui.development.js +258 -254
  142. package/umd/material-ui.production.min.js +18 -18
  143. package/useTouchRipple/useTouchRipple.js +4 -4
@@ -7,59 +7,58 @@ import { DividerClasses } from './dividerClasses';
7
7
 
8
8
  export interface DividerPropsVariantOverrides {}
9
9
 
10
+ export interface DividerOwnProps {
11
+ /**
12
+ * Absolutely position the element.
13
+ * @default false
14
+ */
15
+ absolute?: boolean;
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<DividerClasses>;
24
+ /**
25
+ * If `true`, a vertical divider will have the correct height when used in flex container.
26
+ * (By default, a vertical divider will have a calculated height of `0px` if it is the child of a flex container.)
27
+ * @default false
28
+ */
29
+ flexItem?: boolean;
30
+ /**
31
+ * If `true`, the divider will have a lighter color.
32
+ * @default false
33
+ */
34
+ light?: boolean;
35
+ /**
36
+ * The component orientation.
37
+ * @default 'horizontal'
38
+ */
39
+ orientation?: 'horizontal' | 'vertical';
40
+ /**
41
+ * The system prop that allows defining system overrides as well as additional CSS styles.
42
+ */
43
+ sx?: SxProps<Theme>;
44
+ /**
45
+ * The text alignment.
46
+ * @default 'center'
47
+ */
48
+ textAlign?: 'center' | 'right' | 'left';
49
+ /**
50
+ * The variant to use.
51
+ * @default 'fullWidth'
52
+ */
53
+ variant?: OverridableStringUnion<'fullWidth' | 'inset' | 'middle', DividerPropsVariantOverrides>;
54
+ }
55
+
10
56
  export interface DividerTypeMap<
11
57
  AdditionalProps = {},
12
- DefaultComponent extends React.ElementType = 'hr',
58
+ RootComponent extends React.ElementType = 'hr',
13
59
  > {
14
- props: AdditionalProps & {
15
- /**
16
- * Absolutely position the element.
17
- * @default false
18
- */
19
- absolute?: 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<DividerClasses>;
28
- /**
29
- * If `true`, a vertical divider will have the correct height when used in flex container.
30
- * (By default, a vertical divider will have a calculated height of `0px` if it is the child of a flex container.)
31
- * @default false
32
- */
33
- flexItem?: boolean;
34
- /**
35
- * If `true`, the divider will have a lighter color.
36
- * @default false
37
- */
38
- light?: boolean;
39
- /**
40
- * The component orientation.
41
- * @default 'horizontal'
42
- */
43
- orientation?: 'horizontal' | 'vertical';
44
- /**
45
- * The system prop that allows defining system overrides as well as additional CSS styles.
46
- */
47
- sx?: SxProps<Theme>;
48
- /**
49
- * The text alignment.
50
- * @default 'center'
51
- */
52
- textAlign?: 'center' | 'right' | 'left';
53
- /**
54
- * The variant to use.
55
- * @default 'fullWidth'
56
- */
57
- variant?: OverridableStringUnion<
58
- 'fullWidth' | 'inset' | 'middle',
59
- DividerPropsVariantOverrides
60
- >;
61
- };
62
- defaultComponent: DefaultComponent;
60
+ props: AdditionalProps & DividerOwnProps;
61
+ defaultComponent: RootComponent;
63
62
  }
64
63
 
65
64
  /**
package/Fab/Fab.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import { OverridableStringUnion } from '@mui/types';
2
3
  import { SxProps } from '@mui/system';
3
4
  import { PropTypes, Theme } from '..';
@@ -11,65 +12,67 @@ export interface FabPropsSizeOverrides {}
11
12
 
12
13
  export interface FabPropsColorOverrides {}
13
14
 
15
+ export interface FabOwnProps {
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<FabClasses>;
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 'default'
29
+ */
30
+ color?: OverridableStringUnion<
31
+ PropTypes.Color | 'success' | 'error' | 'info' | 'warning',
32
+ FabPropsColorOverrides
33
+ >;
34
+ /**
35
+ * If `true`, the component is disabled.
36
+ * @default false
37
+ */
38
+ disabled?: boolean;
39
+ /**
40
+ * If `true`, the keyboard focus ripple is disabled.
41
+ * @default false
42
+ */
43
+ disableFocusRipple?: boolean;
44
+ /**
45
+ * If `true`, the ripple effect is disabled.
46
+ */
47
+ disableRipple?: boolean;
48
+ /**
49
+ * The URL to link to when the button is clicked.
50
+ * If defined, an `a` element will be used as the root node.
51
+ */
52
+ href?: string;
53
+ /**
54
+ * The size of the component.
55
+ * `small` is equivalent to the dense button styling.
56
+ * @default 'large'
57
+ */
58
+ size?: OverridableStringUnion<'small' | 'medium' | 'large', FabPropsSizeOverrides>;
59
+ /**
60
+ * The variant to use.
61
+ * @default 'circular'
62
+ */
63
+ variant?: OverridableStringUnion<'circular' | 'extended', FabPropsVariantOverrides>;
64
+ /**
65
+ * The system prop that allows defining system overrides as well as additional CSS styles.
66
+ */
67
+ sx?: SxProps<Theme>;
68
+ }
69
+
14
70
  export type FabTypeMap<
15
71
  AdditionalProps = {},
16
- DefaultComponent extends React.ElementType = 'button',
72
+ RootComponent extends React.ElementType = 'button',
17
73
  > = ExtendButtonBaseTypeMap<{
18
- props: AdditionalProps & {
19
- /**
20
- * The content of the component.
21
- */
22
- children?: React.ReactNode;
23
- /**
24
- * Override or extend the styles applied to the component.
25
- */
26
- classes?: Partial<FabClasses>;
27
- /**
28
- * The color of the component.
29
- * It supports both default and custom theme colors, which can be added as shown in the
30
- * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
31
- * @default 'default'
32
- */
33
- color?: OverridableStringUnion<
34
- PropTypes.Color | 'success' | 'error' | 'info' | 'warning',
35
- FabPropsColorOverrides
36
- >;
37
- /**
38
- * If `true`, the component is disabled.
39
- * @default false
40
- */
41
- disabled?: boolean;
42
- /**
43
- * If `true`, the keyboard focus ripple is disabled.
44
- * @default false
45
- */
46
- disableFocusRipple?: boolean;
47
- /**
48
- * If `true`, the ripple effect is disabled.
49
- */
50
- disableRipple?: boolean;
51
- /**
52
- * The URL to link to when the button is clicked.
53
- * If defined, an `a` element will be used as the root node.
54
- */
55
- href?: string;
56
- /**
57
- * The size of the component.
58
- * `small` is equivalent to the dense button styling.
59
- * @default 'large'
60
- */
61
- size?: OverridableStringUnion<'small' | 'medium' | 'large', FabPropsSizeOverrides>;
62
- /**
63
- * The variant to use.
64
- * @default 'circular'
65
- */
66
- variant?: OverridableStringUnion<'circular' | 'extended', FabPropsVariantOverrides>;
67
- /**
68
- * The system prop that allows defining system overrides as well as additional CSS styles.
69
- */
70
- sx?: SxProps<Theme>;
71
- };
72
- defaultComponent: DefaultComponent;
74
+ props: AdditionalProps & FabOwnProps;
75
+ defaultComponent: RootComponent;
73
76
  }>;
74
77
 
75
78
  /**
@@ -8,81 +8,83 @@ import { FormControlClasses } from './formControlClasses';
8
8
  export interface FormControlPropsSizeOverrides {}
9
9
  export interface FormControlPropsColorOverrides {}
10
10
 
11
+ export interface FormControlOwnProps {
12
+ /**
13
+ * The content of the component.
14
+ */
15
+ children?: React.ReactNode;
16
+ /**
17
+ * Override or extend the styles applied to the component.
18
+ */
19
+ classes?: Partial<FormControlClasses>;
20
+ /**
21
+ * The color of the component.
22
+ * It supports both default and custom theme colors, which can be added as shown in the
23
+ * [palette customization guide](https://mui.com/material-ui/customization/palette/#adding-new-colors).
24
+ * @default 'primary'
25
+ */
26
+ color?: OverridableStringUnion<
27
+ 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning',
28
+ FormControlPropsColorOverrides
29
+ >;
30
+ /**
31
+ * If `true`, the label, input and helper text should be displayed in a disabled state.
32
+ * @default false
33
+ */
34
+ disabled?: boolean;
35
+ /**
36
+ * If `true`, the label is displayed in an error state.
37
+ * @default false
38
+ */
39
+ error?: boolean;
40
+ /**
41
+ * If `true`, the component will take up the full width of its container.
42
+ * @default false
43
+ */
44
+ fullWidth?: boolean;
45
+ /**
46
+ * If `true`, the component is displayed in focused state.
47
+ */
48
+ focused?: boolean;
49
+ /**
50
+ * If `true`, the label is hidden.
51
+ * This is used to increase density for a `FilledInput`.
52
+ * Be sure to add `aria-label` to the `input` element.
53
+ * @default false
54
+ */
55
+ hiddenLabel?: boolean;
56
+ /**
57
+ * If `dense` or `normal`, will adjust vertical spacing of this and contained components.
58
+ * @default 'none'
59
+ */
60
+ margin?: 'dense' | 'normal' | 'none';
61
+ /**
62
+ * If `true`, the label will indicate that the `input` is required.
63
+ * @default false
64
+ */
65
+ required?: boolean;
66
+ /**
67
+ * The size of the component.
68
+ * @default 'medium'
69
+ */
70
+ size?: OverridableStringUnion<'small' | 'medium', FormControlPropsSizeOverrides>;
71
+ /**
72
+ * The system prop that allows defining system overrides as well as additional CSS styles.
73
+ */
74
+ sx?: SxProps<Theme>;
75
+ /**
76
+ * The variant to use.
77
+ * @default 'outlined'
78
+ */
79
+ variant?: 'standard' | 'outlined' | 'filled';
80
+ }
81
+
11
82
  export interface FormControlTypeMap<
12
83
  AdditionalProps = {},
13
- DefaultComponent extends React.ElementType = 'div',
84
+ RootComponent extends React.ElementType = 'div',
14
85
  > {
15
- props: AdditionalProps & {
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<FormControlClasses>;
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
- 'primary' | 'secondary' | 'error' | 'info' | 'success' | 'warning',
32
- FormControlPropsColorOverrides
33
- >;
34
- /**
35
- * If `true`, the label, input and helper text should be displayed in a disabled state.
36
- * @default false
37
- */
38
- disabled?: boolean;
39
- /**
40
- * If `true`, the label is displayed in an error state.
41
- * @default false
42
- */
43
- error?: boolean;
44
- /**
45
- * If `true`, the component will take up the full width of its container.
46
- * @default false
47
- */
48
- fullWidth?: boolean;
49
- /**
50
- * If `true`, the component is displayed in focused state.
51
- */
52
- focused?: boolean;
53
- /**
54
- * If `true`, the label is hidden.
55
- * This is used to increase density for a `FilledInput`.
56
- * Be sure to add `aria-label` to the `input` element.
57
- * @default false
58
- */
59
- hiddenLabel?: boolean;
60
- /**
61
- * If `dense` or `normal`, will adjust vertical spacing of this and contained components.
62
- * @default 'none'
63
- */
64
- margin?: 'dense' | 'normal' | 'none';
65
- /**
66
- * If `true`, the label will indicate that the `input` is required.
67
- * @default false
68
- */
69
- required?: boolean;
70
- /**
71
- * The size of the component.
72
- * @default 'medium'
73
- */
74
- size?: OverridableStringUnion<'small' | 'medium', FormControlPropsSizeOverrides>;
75
- /**
76
- * The system prop that allows defining system overrides as well as additional CSS styles.
77
- */
78
- sx?: SxProps<Theme>;
79
- /**
80
- * The variant to use.
81
- * @default 'outlined'
82
- */
83
- variant?: 'standard' | 'outlined' | 'filled';
84
- };
85
- defaultComponent: DefaultComponent;
86
+ props: AdditionalProps & FormControlOwnProps;
87
+ defaultComponent: RootComponent;
86
88
  }
87
89
 
88
90
  /**
@@ -7,59 +7,61 @@ import { FormHelperTextClasses } from './formHelperTextClasses';
7
7
 
8
8
  export interface FormHelperTextPropsVariantOverrides {}
9
9
 
10
+ export interface FormHelperTextOwnProps {
11
+ /**
12
+ * The content of the component.
13
+ *
14
+ * If `' '` is provided, the component reserves one line height for displaying a future message.
15
+ */
16
+ children?: React.ReactNode;
17
+ /**
18
+ * Override or extend the styles applied to the component.
19
+ */
20
+ classes?: Partial<FormHelperTextClasses>;
21
+ /**
22
+ * If `true`, the helper text should be displayed in a disabled state.
23
+ */
24
+ disabled?: boolean;
25
+ /**
26
+ * If `true`, helper text should be displayed in an error state.
27
+ */
28
+ error?: boolean;
29
+ /**
30
+ * If `true`, the helper text should use filled classes key.
31
+ */
32
+ filled?: boolean;
33
+ /**
34
+ * If `true`, the helper text should use focused classes key.
35
+ */
36
+ focused?: boolean;
37
+ /**
38
+ * If `dense`, will adjust vertical spacing. This is normally obtained via context from
39
+ * FormControl.
40
+ */
41
+ margin?: 'dense';
42
+ /**
43
+ * If `true`, the helper text should use required classes key.
44
+ */
45
+ required?: boolean;
46
+ /**
47
+ * The system prop that allows defining system overrides as well as additional CSS styles.
48
+ */
49
+ sx?: SxProps<Theme>;
50
+ /**
51
+ * The variant to use.
52
+ */
53
+ variant?: OverridableStringUnion<
54
+ 'standard' | 'outlined' | 'filled',
55
+ FormHelperTextPropsVariantOverrides
56
+ >;
57
+ }
58
+
10
59
  export interface FormHelperTextTypeMap<
11
60
  AdditionalProps = {},
12
- DefaultComponent extends React.ElementType = 'p',
61
+ RootComponent extends React.ElementType = 'p',
13
62
  > {
14
- props: AdditionalProps & {
15
- /**
16
- * The content of the component.
17
- *
18
- * If `' '` is provided, the component reserves one line height for displaying a future message.
19
- */
20
- children?: React.ReactNode;
21
- /**
22
- * Override or extend the styles applied to the component.
23
- */
24
- classes?: Partial<FormHelperTextClasses>;
25
- /**
26
- * If `true`, the helper text should be displayed in a disabled state.
27
- */
28
- disabled?: boolean;
29
- /**
30
- * If `true`, helper text should be displayed in an error state.
31
- */
32
- error?: boolean;
33
- /**
34
- * If `true`, the helper text should use filled classes key.
35
- */
36
- filled?: boolean;
37
- /**
38
- * If `true`, the helper text should use focused classes key.
39
- */
40
- focused?: boolean;
41
- /**
42
- * If `dense`, will adjust vertical spacing. This is normally obtained via context from
43
- * FormControl.
44
- */
45
- margin?: 'dense';
46
- /**
47
- * If `true`, the helper text should use required classes key.
48
- */
49
- required?: boolean;
50
- /**
51
- * The system prop that allows defining system overrides as well as additional CSS styles.
52
- */
53
- sx?: SxProps<Theme>;
54
- /**
55
- * The variant to use.
56
- */
57
- variant?: OverridableStringUnion<
58
- 'standard' | 'outlined' | 'filled',
59
- FormHelperTextPropsVariantOverrides
60
- >;
61
- };
62
- defaultComponent: DefaultComponent;
63
+ props: AdditionalProps & FormHelperTextOwnProps;
64
+ defaultComponent: RootComponent;
63
65
  }
64
66
  /**
65
67
  *
@@ -7,6 +7,11 @@ import { FormLabelClasses } from './formLabelClasses';
7
7
 
8
8
  export interface FormLabelPropsColorOverrides {}
9
9
 
10
+ /**
11
+ * This type is kept for compatibility. Use `FormLabelOwnProps` instead.
12
+ */
13
+ export type FormLabelBaseProps = React.LabelHTMLAttributes<HTMLLabelElement>;
14
+
10
15
  export interface FormLabelOwnProps {
11
16
  /**
12
17
  * The content of the component.
@@ -53,10 +58,10 @@ export interface FormLabelOwnProps {
53
58
 
54
59
  export interface FormLabelTypeMap<
55
60
  AdditionalProps = {},
56
- DefaultComponent extends React.ElementType = 'label',
61
+ RootComponent extends React.ElementType = 'label',
57
62
  > {
58
63
  props: AdditionalProps & FormLabelBaseProps & FormLabelOwnProps;
59
- defaultComponent: DefaultComponent;
64
+ defaultComponent: RootComponent;
60
65
  }
61
66
 
62
67
  /**
@@ -73,8 +78,6 @@ export interface FormLabelTypeMap<
73
78
  */
74
79
  declare const FormLabel: OverridableComponent<FormLabelTypeMap>;
75
80
 
76
- export type FormLabelBaseProps = React.LabelHTMLAttributes<HTMLLabelElement>;
77
-
78
81
  export interface ExtendFormLabelTypeMap<TypeMap extends OverridableTypeMap> {
79
82
  props: TypeMap['props'] & Pick<FormLabelOwnProps, 'filled' | 'color'>;
80
83
  defaultComponent: TypeMap['defaultComponent'];
package/Grid/Grid.d.ts CHANGED
@@ -83,77 +83,78 @@ type Breakpoints = IfEquals<
83
83
  CustomBreakpoints
84
84
  >;
85
85
 
86
+ export interface GridOwnProps extends SystemProps<Theme>, Breakpoints {
87
+ /**
88
+ * The content of the component.
89
+ */
90
+ children?: React.ReactNode;
91
+ /**
92
+ * Override or extend the styles applied to the component.
93
+ */
94
+ classes?: Partial<GridClasses>;
95
+ /**
96
+ * The number of columns.
97
+ * @default 12
98
+ */
99
+ columns?: ResponsiveStyleValue<number>;
100
+ /**
101
+ * Defines the horizontal space between the type `item` components.
102
+ * It overrides the value of the `spacing` prop.
103
+ */
104
+ columnSpacing?: ResponsiveStyleValue<GridSpacing>;
105
+ /**
106
+ * If `true`, the component will have the flex *container* behavior.
107
+ * You should be wrapping *items* with a *container*.
108
+ * @default false
109
+ */
110
+ container?: boolean;
111
+ /**
112
+ * Defines the `flex-direction` style property.
113
+ * It is applied for all screen sizes.
114
+ * @default 'row'
115
+ */
116
+ direction?: ResponsiveStyleValue<GridDirection>;
117
+ /**
118
+ * If `true`, the component will have the flex *item* behavior.
119
+ * You should be wrapping *items* with a *container*.
120
+ * @default false
121
+ */
122
+ item?: boolean;
123
+ /**
124
+ * Defines the vertical space between the type `item` components.
125
+ * It overrides the value of the `spacing` prop.
126
+ */
127
+ rowSpacing?: ResponsiveStyleValue<GridSpacing>;
128
+ /**
129
+ * Defines the space between the type `item` components.
130
+ * It can only be used on a type `container` component.
131
+ * @default 0
132
+ */
133
+ spacing?: ResponsiveStyleValue<GridSpacing>;
134
+ /**
135
+ * The system prop that allows defining system overrides as well as additional CSS styles.
136
+ */
137
+ sx?: SxProps<Theme>;
138
+ /**
139
+ * Defines the `flex-wrap` style property.
140
+ * It's applied for all screen sizes.
141
+ * @default 'wrap'
142
+ */
143
+ wrap?: GridWrap;
144
+ /**
145
+ * If `true`, it sets `min-width: 0` on the item.
146
+ * Refer to the limitations section of the documentation to better understand the use case.
147
+ * @default false
148
+ */
149
+ zeroMinWidth?: boolean;
150
+ }
151
+
86
152
  export interface GridTypeMap<
87
153
  AdditionalProps = {},
88
- DefaultComponent extends React.ElementType = 'div',
154
+ RootComponent extends React.ElementType = 'div',
89
155
  > {
90
- props: AdditionalProps &
91
- SystemProps<Theme> & {
92
- /**
93
- * The content of the component.
94
- */
95
- children?: React.ReactNode;
96
- /**
97
- * Override or extend the styles applied to the component.
98
- */
99
- classes?: Partial<GridClasses>;
100
- /**
101
- * The number of columns.
102
- * @default 12
103
- */
104
- columns?: ResponsiveStyleValue<number>;
105
- /**
106
- * Defines the horizontal space between the type `item` components.
107
- * It overrides the value of the `spacing` prop.
108
- */
109
- columnSpacing?: ResponsiveStyleValue<GridSpacing>;
110
- /**
111
- * If `true`, the component will have the flex *container* behavior.
112
- * You should be wrapping *items* with a *container*.
113
- * @default false
114
- */
115
- container?: boolean;
116
- /**
117
- * Defines the `flex-direction` style property.
118
- * It is applied for all screen sizes.
119
- * @default 'row'
120
- */
121
- direction?: ResponsiveStyleValue<GridDirection>;
122
- /**
123
- * If `true`, the component will have the flex *item* behavior.
124
- * You should be wrapping *items* with a *container*.
125
- * @default false
126
- */
127
- item?: boolean;
128
- /**
129
- * Defines the vertical space between the type `item` components.
130
- * It overrides the value of the `spacing` prop.
131
- */
132
- rowSpacing?: ResponsiveStyleValue<GridSpacing>;
133
- /**
134
- * Defines the space between the type `item` components.
135
- * It can only be used on a type `container` component.
136
- * @default 0
137
- */
138
- spacing?: ResponsiveStyleValue<GridSpacing>;
139
- /**
140
- * The system prop that allows defining system overrides as well as additional CSS styles.
141
- */
142
- sx?: SxProps<Theme>;
143
- /**
144
- * Defines the `flex-wrap` style property.
145
- * It's applied for all screen sizes.
146
- * @default 'wrap'
147
- */
148
- wrap?: GridWrap;
149
- /**
150
- * If `true`, it sets `min-width: 0` on the item.
151
- * Refer to the limitations section of the documentation to better understand the use case.
152
- * @default false
153
- */
154
- zeroMinWidth?: boolean;
155
- } & Breakpoints;
156
- defaultComponent: DefaultComponent;
156
+ props: AdditionalProps & GridOwnProps;
157
+ defaultComponent: RootComponent;
157
158
  }
158
159
 
159
160
  /**