@mui/material 5.15.18 → 5.15.20
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/AlertTitle/AlertTitle.d.ts +2 -2
- package/Autocomplete/Autocomplete.js +32 -28
- package/CHANGELOG.md +82 -2
- package/Hidden/Hidden.d.ts +2 -0
- package/Hidden/Hidden.js +2 -0
- package/Pagination/Pagination.js +1 -1
- package/Slider/Slider.js +1 -1
- package/Tab/Tab.js +3 -1
- package/Tab/tabClasses.d.ts +1 -1
- package/index.js +1 -1
- package/legacy/Autocomplete/Autocomplete.js +16 -16
- package/legacy/Hidden/Hidden.js +2 -0
- package/legacy/Pagination/Pagination.js +1 -1
- package/legacy/Slider/Slider.js +1 -1
- package/legacy/Tab/Tab.js +5 -5
- package/legacy/index.js +1 -1
- package/legacy/styles/responsiveFontSizes.js +3 -0
- package/modern/Autocomplete/Autocomplete.js +32 -28
- package/modern/Hidden/Hidden.js +2 -0
- package/modern/Pagination/Pagination.js +1 -1
- package/modern/Slider/Slider.js +1 -1
- package/modern/Tab/Tab.js +3 -1
- package/modern/index.js +1 -1
- package/modern/styles/responsiveFontSizes.js +3 -0
- package/node/Autocomplete/Autocomplete.js +33 -29
- package/node/Hidden/Hidden.js +2 -0
- package/node/Pagination/Pagination.js +1 -1
- package/node/Slider/Slider.js +1 -1
- package/node/Tab/Tab.js +3 -1
- package/node/index.js +1 -1
- package/node/styles/responsiveFontSizes.js +3 -0
- package/package.json +5 -5
- package/styles/responsiveFontSizes.js +3 -0
- package/umd/material-ui.development.js +29 -27
- package/umd/material-ui.production.min.js +3 -3
- package/usePagination/usePagination.d.ts +1 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { SxProps } from '@mui/system';
|
|
3
|
-
import {
|
|
3
|
+
import { Theme, TypographyProps } from '..';
|
|
4
4
|
import { AlertTitleClasses } from './alertTitleClasses';
|
|
5
5
|
|
|
6
|
-
export interface AlertTitleProps extends
|
|
6
|
+
export interface AlertTitleProps extends TypographyProps<'div'> {
|
|
7
7
|
/**
|
|
8
8
|
* The content of the component.
|
|
9
9
|
*/
|
|
@@ -4,7 +4,9 @@ import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWith
|
|
|
4
4
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
5
5
|
var _ClearIcon, _ArrowDropDownIcon;
|
|
6
6
|
const _excluded = ["autoComplete", "autoHighlight", "autoSelect", "blurOnSelect", "ChipProps", "className", "clearIcon", "clearOnBlur", "clearOnEscape", "clearText", "closeText", "componentsProps", "defaultValue", "disableClearable", "disableCloseOnSelect", "disabled", "disabledItemsFocusable", "disableListWrap", "disablePortal", "filterOptions", "filterSelectedOptions", "forcePopupIcon", "freeSolo", "fullWidth", "getLimitTagsText", "getOptionDisabled", "getOptionKey", "getOptionLabel", "isOptionEqualToValue", "groupBy", "handleHomeEndKeys", "id", "includeInputInList", "inputValue", "limitTags", "ListboxComponent", "ListboxProps", "loading", "loadingText", "multiple", "noOptionsText", "onChange", "onClose", "onHighlightChange", "onInputChange", "onOpen", "open", "openOnFocus", "openText", "options", "PaperComponent", "PopperComponent", "popupIcon", "readOnly", "renderGroup", "renderInput", "renderOption", "renderTags", "selectOnFocus", "size", "slotProps", "value"],
|
|
7
|
-
_excluded2 = ["ref"]
|
|
7
|
+
_excluded2 = ["ref"],
|
|
8
|
+
_excluded3 = ["key"],
|
|
9
|
+
_excluded4 = ["key"];
|
|
8
10
|
import * as React from 'react';
|
|
9
11
|
import PropTypes from 'prop-types';
|
|
10
12
|
import clsx from 'clsx';
|
|
@@ -30,7 +32,6 @@ import capitalize from '../utils/capitalize';
|
|
|
30
32
|
import useForkRef from '../utils/useForkRef';
|
|
31
33
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
32
34
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
33
|
-
import { createElement as _createElement } from "react";
|
|
34
35
|
const useThemeProps = createUseThemeProps('MuiAutocomplete');
|
|
35
36
|
const useUtilityClasses = ownerState => {
|
|
36
37
|
const {
|
|
@@ -91,6 +92,15 @@ const AutocompleteRoot = styled('div', {
|
|
|
91
92
|
}, styles.root, fullWidth && styles.fullWidth, hasPopupIcon && styles.hasPopupIcon, hasClearIcon && styles.hasClearIcon];
|
|
92
93
|
}
|
|
93
94
|
})({
|
|
95
|
+
[`&.${autocompleteClasses.focused} .${autocompleteClasses.clearIndicator}`]: {
|
|
96
|
+
visibility: 'visible'
|
|
97
|
+
},
|
|
98
|
+
/* Avoid double tap issue on iOS */
|
|
99
|
+
'@media (pointer: fine)': {
|
|
100
|
+
[`&:hover .${autocompleteClasses.clearIndicator}`]: {
|
|
101
|
+
visibility: 'visible'
|
|
102
|
+
}
|
|
103
|
+
},
|
|
94
104
|
[`& .${autocompleteClasses.tag}`]: {
|
|
95
105
|
margin: 3,
|
|
96
106
|
maxWidth: 'calc(100% - 6px)'
|
|
@@ -107,23 +117,6 @@ const AutocompleteRoot = styled('div', {
|
|
|
107
117
|
minWidth: 30
|
|
108
118
|
}
|
|
109
119
|
},
|
|
110
|
-
[`&.${autocompleteClasses.focused}`]: {
|
|
111
|
-
[`& .${autocompleteClasses.clearIndicator}`]: {
|
|
112
|
-
visibility: 'visible'
|
|
113
|
-
},
|
|
114
|
-
[`& .${autocompleteClasses.input}`]: {
|
|
115
|
-
minWidth: 0
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
/* Avoid double tap issue on iOS */
|
|
119
|
-
'@media (pointer: fine)': {
|
|
120
|
-
[`&:hover .${autocompleteClasses.clearIndicator}`]: {
|
|
121
|
-
visibility: 'visible'
|
|
122
|
-
},
|
|
123
|
-
[`&:hover .${autocompleteClasses.input}`]: {
|
|
124
|
-
minWidth: 0
|
|
125
|
-
}
|
|
126
|
-
},
|
|
127
120
|
[`& .${inputClasses.root}`]: {
|
|
128
121
|
paddingBottom: 1,
|
|
129
122
|
'& .MuiInput-input': {
|
|
@@ -541,12 +534,19 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
541
534
|
if (renderTags) {
|
|
542
535
|
startAdornment = renderTags(value, getCustomizedTagProps, ownerState);
|
|
543
536
|
} else {
|
|
544
|
-
startAdornment = value.map((option, index) =>
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
537
|
+
startAdornment = value.map((option, index) => {
|
|
538
|
+
const _getCustomizedTagProp = getCustomizedTagProps({
|
|
539
|
+
index
|
|
540
|
+
}),
|
|
541
|
+
{
|
|
542
|
+
key
|
|
543
|
+
} = _getCustomizedTagProp,
|
|
544
|
+
customTagProps = _objectWithoutPropertiesLoose(_getCustomizedTagProp, _excluded3);
|
|
545
|
+
return /*#__PURE__*/_jsx(Chip, _extends({
|
|
546
|
+
label: getOptionLabel(option),
|
|
547
|
+
size: size
|
|
548
|
+
}, customTagProps, ChipProps), key);
|
|
549
|
+
});
|
|
550
550
|
}
|
|
551
551
|
}
|
|
552
552
|
if (limitTags > -1 && Array.isArray(startAdornment)) {
|
|
@@ -574,9 +574,13 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
574
574
|
const renderGroup = renderGroupProp || defaultRenderGroup;
|
|
575
575
|
const defaultRenderOption = (props2, option) => {
|
|
576
576
|
// Need to clearly apply key because of https://github.com/vercel/next.js/issues/55642
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
577
|
+
const {
|
|
578
|
+
key
|
|
579
|
+
} = props2,
|
|
580
|
+
otherProps = _objectWithoutPropertiesLoose(props2, _excluded4);
|
|
581
|
+
return /*#__PURE__*/_jsx("li", _extends({}, otherProps, {
|
|
582
|
+
children: getOptionLabel(option)
|
|
583
|
+
}), key);
|
|
580
584
|
};
|
|
581
585
|
const renderOption = renderOptionProp || defaultRenderOption;
|
|
582
586
|
const renderListOption = (option, index) => {
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,85 @@
|
|
|
1
1
|
# [Versions](https://mui.com/versions/)
|
|
2
2
|
|
|
3
|
+
## v5.15.20
|
|
4
|
+
|
|
5
|
+
<!-- generated comparing v5.15.19..master -->
|
|
6
|
+
|
|
7
|
+
_Jun 12, 2024_
|
|
8
|
+
|
|
9
|
+
A big thanks to the 9 contributors who made this release possible.
|
|
10
|
+
|
|
11
|
+
### `@mui/material@5.15.20`
|
|
12
|
+
|
|
13
|
+
- ​<!-- 17 -->[Autocomplete] Shouldn't resize when hovering (@ZeeshanTamboli) (#42535) @ZeeshanTamboli
|
|
14
|
+
- ​<!-- 07 -->[Tab] Fix applying `iconWrapper` styles from theme and update its description (@sai6855) (#42570) @sai6855
|
|
15
|
+
|
|
16
|
+
### `@mui/utils@5.15.15`
|
|
17
|
+
|
|
18
|
+
- ​<!-- 06 -->Allow passing `NaN` as `defaultValue` to `useControlled` (@iammminzzy) (#42571) @iammminzzy
|
|
19
|
+
- ​<!-- 17 -->Fix GitHub-reported prototype pollution vulnerability in `deepmerge` (#41652) (#42608) @DiegoAndai
|
|
20
|
+
|
|
21
|
+
### Docs
|
|
22
|
+
|
|
23
|
+
- ​<!-- 16 -->[docs] Add Pigment CSS and Base UI logos SVGs (#42513) @danilo-leal
|
|
24
|
+
- ​<!-- 15 -->[docs] Update twitter.com to x.com @oliviertassinari
|
|
25
|
+
- ​<!-- 14 -->[docs] Simplify Example projects page @oliviertassinari
|
|
26
|
+
- ​<!-- 13 -->[material-ui] Add docs for complementary stepper components (@anle9650) (#42613) @anle9650
|
|
27
|
+
- ​<!-- 12 -->[docs] Add changelog section to the design kits page (@danilo-leal) (#42463) @danilo-leal
|
|
28
|
+
- ​<!-- 11 -->[material-ui] Fix sentence in the All components page (@danilo-leal) (#42462) @danilo-leal
|
|
29
|
+
- ​<!-- 10 -->[material-ui] Update Figma design kit doc redirect link (@danilo-leal) (#42456) @danilo-leal
|
|
30
|
+
- ​<!-- 09 -->[system] Add "dynamic values" section to sx prop page (@aarongarciah) (#42453) @aarongarciah
|
|
31
|
+
|
|
32
|
+
### Core
|
|
33
|
+
|
|
34
|
+
- ​<!-- 18 -->[website] Move the `React Engineer - X` role to future roles (#42532) @DanailH
|
|
35
|
+
- ​<!-- 08 -->[examples] Remove Pigment CSS examples (#42538) @sai6855
|
|
36
|
+
- ​<!-- 05 -->[website] Close Developer Advocate / Content Engineer role @oliviertassinari
|
|
37
|
+
- ​<!-- 04 -->[website] Update DoiT description and link in Sponsors section (@erezstmn-doit) (#42511) @erezstmn-doit
|
|
38
|
+
- ​<!-- 03 -->[website] Clean up the docs-infra job ad (@danilo-leal) (#42509) @danilo-leal
|
|
39
|
+
- ​<!-- 02 -->[website] Open the Docs-infra engineer role (@danilo-leal) (#42496) @danilo-leal
|
|
40
|
+
- ​<!-- 01 -->[website] Fix locationCountry in about page @oliviertassinari
|
|
41
|
+
|
|
42
|
+
All contributors of this release in alphabetical order: @aarongarciah, @anle9650, @DanailH, @danilo-leal, @erezstmn-doit, @iammminzzy, @oliviertassinari, @sai6855, @ZeeshanTamboli
|
|
43
|
+
|
|
44
|
+
## v5.15.19
|
|
45
|
+
|
|
46
|
+
<!-- generated comparing v5.15.18..master -->
|
|
47
|
+
|
|
48
|
+
_May 29, 2024_
|
|
49
|
+
|
|
50
|
+
A big thanks to the 12 contributors who made this release possible.
|
|
51
|
+
This release was mostly about 🐛 bug fixes and 📚 documentation improvements.
|
|
52
|
+
|
|
53
|
+
### `@mui/material@5.15.19`
|
|
54
|
+
|
|
55
|
+
- ​<!-- 19 -->[AlertTitle] Enable extending Typography props (@lucasgmelo) (#42334) @github-actions[bot]
|
|
56
|
+
- ​<!-- 06 -->[responsiveFontSizes] Handled undefined variants (@brijeshb42) (#42419) @github-actions[bot]
|
|
57
|
+
- ​<!-- 05 -->[Slider] Fix wrong CSS value (@mnajdova) (#42373) @github-actions[bot]
|
|
58
|
+
|
|
59
|
+
### Docs
|
|
60
|
+
|
|
61
|
+
- ​<!-- 13 -->Link to pnpm installation docs (#42420) @aarongarciah
|
|
62
|
+
- ​<!-- 12 -->Remove LocalMonero (@oliviertassinari) (#42315) @github-actions[bot]
|
|
63
|
+
- ​<!-- 10 -->[material-ui] Fix typo in style interoperability with Tailwind CSS docs (@ZeeshanTamboli) (#42312) @github-actions[bot]
|
|
64
|
+
- ​<!-- 09 -->[material-ui][Pagination] Clarify pagination `page` prop API (@Mandar-Pandya) (#42265) @github-actions[bot]
|
|
65
|
+
- ​<!-- 08 -->[material-ui][Tabs] Improve the Basic Tabs demo (@MatheusEli) (#42426) @github-actions[bot]
|
|
66
|
+
- ​<!-- 07 -->[pigment-css] Fix duplication of content (#42410) @oliviertassinari
|
|
67
|
+
|
|
68
|
+
### Core
|
|
69
|
+
|
|
70
|
+
- ​<!-- 18 -->[blog] Add the "Product" tag to the Pigment CSS post (@danilo-leal) (#42366) @github-actions[bot]
|
|
71
|
+
- ​<!-- 17 -->[blog] Update blog post OG image (@danilo-leal) (#42306) @github-actions[bot]
|
|
72
|
+
- ​<!-- 16 -->[blog] Update Pigment CSS post (@danilo-leal) (#42267) @github-actions[bot]
|
|
73
|
+
- ​<!-- 15 -->[core] Fix React 18.3 warnings about spreading keys in the Material UI `Autocomplete` component (#42099) (#42241) @DiegoAndai
|
|
74
|
+
- ​<!-- 14 -->[core] Fix a few more key spread issues (@oliviertassinari) (#42318) @github-actions[bot]
|
|
75
|
+
- ​<!-- 11 -->[docs-infra] Allow JSDoc tags (#42327) @aarongarciah
|
|
76
|
+
- ​<!-- 04 -->[website] Add Nikita to the about page (@nikitaa24) (#42421) @github-actions[bot]
|
|
77
|
+
- ​<!-- 03 -->[website] Fix hero spacing changes applying at the wrong breakpoint (@KenanYusuf) (#42357) @github-actions[bot]
|
|
78
|
+
- ​<!-- 02 -->[website] Adds Kenan Yusuf to about page (@KenanYusuf) (#42330) @github-actions[bot]
|
|
79
|
+
- ​<!-- 01 -->[website] Improve about page @oliviertassinari
|
|
80
|
+
|
|
81
|
+
All contributors of this release in alphabetical order: @aarongarciah, @brijeshb42, @danilo-leal, @DiegoAndai, @KenanYusuf, @lucasgmelo, @Mandar-Pandya, @MatheusEli, @mnajdova, @nikitaa24, @oliviertassinari, @ZeeshanTamboli
|
|
82
|
+
|
|
3
83
|
## v5.15.18
|
|
4
84
|
|
|
5
85
|
<!-- generated comparing v5.15.17..master -->
|
|
@@ -8337,7 +8417,7 @@ A big thanks to the 15 contributors who made this release possible. Here are som
|
|
|
8337
8417
|
|
|
8338
8418
|
- ​<!-- 27 -->[core] Rename mui/core to mui/base (#29585) @michaldudak
|
|
8339
8419
|
|
|
8340
|
-
Based on the results of the [poll](https://
|
|
8420
|
+
Based on the results of the [poll](https://x.com/michaldudak/status/1452630484706635779) and our internal discussions, we decided to rename the `@mui/core` package to `@mui/base`. The main rationale for this is the fact that we use the term "Core" to refer to the core components product family, the one that includes Material Design components, unstyled components, System utilities, etc. Therefore, @mui/core was effectively a subset of MUI Core. This was confusing.
|
|
8341
8421
|
|
|
8342
8422
|
The new name better reflects the purpose of the package: it contains unstyled components, hooks, and utilities that serve as a **base** to build on.
|
|
8343
8423
|
|
|
@@ -12754,7 +12834,7 @@ A big thanks to the 34 contributors who made this release possible. Here are som
|
|
|
12754
12834
|
```
|
|
12755
12835
|
|
|
12756
12836
|
- [Autocomplete] Remove `debug` in favor of `open` and dev tools (#23377) @eps1lon
|
|
12757
|
-
There are a couple of simpler alternatives: `open={true}`, Chrome devtools ["Emulate focused"](https://
|
|
12837
|
+
There are a couple of simpler alternatives: `open={true}`, Chrome devtools ["Emulate focused"](https://x.com/sulco/status/1305841873945272321), or React devtools props.
|
|
12758
12838
|
|
|
12759
12839
|
#### Changes
|
|
12760
12840
|
|
package/Hidden/Hidden.d.ts
CHANGED
|
@@ -90,6 +90,8 @@ export interface HiddenProps {
|
|
|
90
90
|
* API:
|
|
91
91
|
*
|
|
92
92
|
* - [Hidden API](https://mui.com/material-ui/api/hidden/)
|
|
93
|
+
*
|
|
94
|
+
* @deprecated The Hidden component was deprecated in Material UI v5. To learn more, see [the Hidden section](/material-ui/migration/v5-component-changes/#hidden) of the migration docs.
|
|
93
95
|
*/
|
|
94
96
|
declare const Hidden: React.JSXElementConstructor<HiddenProps>;
|
|
95
97
|
|
package/Hidden/Hidden.js
CHANGED
|
@@ -10,6 +10,8 @@ import HiddenCss from './HiddenCss';
|
|
|
10
10
|
|
|
11
11
|
/**
|
|
12
12
|
* Responsively hides children based on the selected implementation.
|
|
13
|
+
*
|
|
14
|
+
* @deprecated The Hidden component was deprecated in Material UI v5. To learn more, see [the Hidden section](/material-ui/migration/v5-component-changes/#hidden) of the migration docs.
|
|
13
15
|
*/
|
|
14
16
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
15
17
|
function Hidden(props) {
|
package/Pagination/Pagination.js
CHANGED
|
@@ -193,7 +193,7 @@ process.env.NODE_ENV !== "production" ? Pagination.propTypes /* remove-proptypes
|
|
|
193
193
|
*/
|
|
194
194
|
onChange: PropTypes.func,
|
|
195
195
|
/**
|
|
196
|
-
* The current page.
|
|
196
|
+
* The current page. Unlike `TablePagination`, which starts numbering from `0`, this pagination starts from `1`.
|
|
197
197
|
*/
|
|
198
198
|
page: integerPropType,
|
|
199
199
|
/**
|
package/Slider/Slider.js
CHANGED
|
@@ -337,7 +337,7 @@ export const SliderThumb = styled('span', {
|
|
|
337
337
|
}
|
|
338
338
|
}),
|
|
339
339
|
[`&.${sliderClasses.active}`]: _extends({}, theme.vars ? {
|
|
340
|
-
boxShadow: `0px 0px 0px 14px rgba(${theme.vars.palette[color].mainChannel} / 0.16)
|
|
340
|
+
boxShadow: `0px 0px 0px 14px rgba(${theme.vars.palette[color].mainChannel} / 0.16)`
|
|
341
341
|
} : {
|
|
342
342
|
boxShadow: `0px 0px 0px 14px ${alpha(theme.palette[color].main, 0.16)}`
|
|
343
343
|
})
|
package/Tab/Tab.js
CHANGED
|
@@ -38,7 +38,9 @@ const TabRoot = styled(ButtonBase, {
|
|
|
38
38
|
const {
|
|
39
39
|
ownerState
|
|
40
40
|
} = props;
|
|
41
|
-
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles[`textColor${capitalize(ownerState.textColor)}`], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped
|
|
41
|
+
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles[`textColor${capitalize(ownerState.textColor)}`], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped, {
|
|
42
|
+
[`& .${tabClasses.iconWrapper}`]: styles.iconWrapper
|
|
43
|
+
}];
|
|
42
44
|
}
|
|
43
45
|
})(({
|
|
44
46
|
theme,
|
package/Tab/tabClasses.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export interface TabClasses {
|
|
|
17
17
|
fullWidth: string;
|
|
18
18
|
/** Styles applied to the root element if `wrapped={true}`. */
|
|
19
19
|
wrapped: string;
|
|
20
|
-
/** Styles applied to the
|
|
20
|
+
/** Styles applied to the `icon` HTML element if both `icon` and `label` are provided. */
|
|
21
21
|
iconWrapper: string;
|
|
22
22
|
}
|
|
23
23
|
export type TabClassKey = keyof TabClasses;
|
package/index.js
CHANGED
|
@@ -29,7 +29,6 @@ import capitalize from '../utils/capitalize';
|
|
|
29
29
|
import useForkRef from '../utils/useForkRef';
|
|
30
30
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
31
31
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
32
|
-
import { createElement as _createElement } from "react";
|
|
33
32
|
var useThemeProps = createUseThemeProps('MuiAutocomplete');
|
|
34
33
|
var useUtilityClasses = function useUtilityClasses(ownerState) {
|
|
35
34
|
var classes = ownerState.classes,
|
|
@@ -73,7 +72,11 @@ var AutocompleteRoot = styled('div', {
|
|
|
73
72
|
size = ownerState.size;
|
|
74
73
|
return [_defineProperty({}, "& .".concat(autocompleteClasses.tag), styles.tag), _defineProperty({}, "& .".concat(autocompleteClasses.tag), styles["tagSize".concat(capitalize(size))]), _defineProperty({}, "& .".concat(autocompleteClasses.inputRoot), styles.inputRoot), _defineProperty({}, "& .".concat(autocompleteClasses.input), styles.input), _defineProperty({}, "& .".concat(autocompleteClasses.input), inputFocused && styles.inputFocused), styles.root, fullWidth && styles.fullWidth, hasPopupIcon && styles.hasPopupIcon, hasClearIcon && styles.hasClearIcon];
|
|
75
74
|
}
|
|
76
|
-
})((_styled = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_styled, "
|
|
75
|
+
})((_styled = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_styled, "&.".concat(autocompleteClasses.focused, " .").concat(autocompleteClasses.clearIndicator), {
|
|
76
|
+
visibility: 'visible'
|
|
77
|
+
}), '@media (pointer: fine)', _defineProperty({}, "&:hover .".concat(autocompleteClasses.clearIndicator), {
|
|
78
|
+
visibility: 'visible'
|
|
79
|
+
})), "& .".concat(autocompleteClasses.tag), {
|
|
77
80
|
margin: 3,
|
|
78
81
|
maxWidth: 'calc(100% - 6px)'
|
|
79
82
|
}), "& .".concat(autocompleteClasses.inputRoot), _defineProperty(_defineProperty(_defineProperty({}, ".".concat(autocompleteClasses.hasPopupIcon, "&, .").concat(autocompleteClasses.hasClearIcon, "&"), {
|
|
@@ -83,14 +86,6 @@ var AutocompleteRoot = styled('div', {
|
|
|
83
86
|
}), "& .".concat(autocompleteClasses.input), {
|
|
84
87
|
width: 0,
|
|
85
88
|
minWidth: 30
|
|
86
|
-
})), "&.".concat(autocompleteClasses.focused), _defineProperty(_defineProperty({}, "& .".concat(autocompleteClasses.clearIndicator), {
|
|
87
|
-
visibility: 'visible'
|
|
88
|
-
}), "& .".concat(autocompleteClasses.input), {
|
|
89
|
-
minWidth: 0
|
|
90
|
-
})), '@media (pointer: fine)', _defineProperty(_defineProperty({}, "&:hover .".concat(autocompleteClasses.clearIndicator), {
|
|
91
|
-
visibility: 'visible'
|
|
92
|
-
}), "&:hover .".concat(autocompleteClasses.input), {
|
|
93
|
-
minWidth: 0
|
|
94
89
|
})), "& .".concat(inputClasses.root), {
|
|
95
90
|
paddingBottom: 1,
|
|
96
91
|
'& .MuiInput-input': {
|
|
@@ -536,12 +531,15 @@ var Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps,
|
|
|
536
531
|
startAdornment = renderTags(value, getCustomizedTagProps, ownerState);
|
|
537
532
|
} else {
|
|
538
533
|
startAdornment = value.map(function (option, index) {
|
|
534
|
+
var _getCustomizedTagProp = getCustomizedTagProps({
|
|
535
|
+
index: index
|
|
536
|
+
}),
|
|
537
|
+
key = _getCustomizedTagProp.key,
|
|
538
|
+
customTagProps = _objectWithoutProperties(_getCustomizedTagProp, ["key"]);
|
|
539
539
|
return /*#__PURE__*/_jsx(Chip, _extends({
|
|
540
540
|
label: getOptionLabel(option),
|
|
541
541
|
size: size
|
|
542
|
-
},
|
|
543
|
-
index: index
|
|
544
|
-
}), ChipProps));
|
|
542
|
+
}, customTagProps, ChipProps), key);
|
|
545
543
|
});
|
|
546
544
|
}
|
|
547
545
|
}
|
|
@@ -572,9 +570,11 @@ var Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps,
|
|
|
572
570
|
var renderGroup = renderGroupProp || defaultRenderGroup;
|
|
573
571
|
var defaultRenderOption = function defaultRenderOption(props2, option) {
|
|
574
572
|
// Need to clearly apply key because of https://github.com/vercel/next.js/issues/55642
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
}
|
|
573
|
+
var key = props2.key,
|
|
574
|
+
otherProps = _objectWithoutProperties(props2, ["key"]);
|
|
575
|
+
return /*#__PURE__*/_jsx("li", _extends({}, otherProps, {
|
|
576
|
+
children: getOptionLabel(option)
|
|
577
|
+
}), key);
|
|
578
578
|
};
|
|
579
579
|
var renderOption = renderOptionProp || defaultRenderOption;
|
|
580
580
|
var renderListOption = function renderListOption(option, index) {
|
package/legacy/Hidden/Hidden.js
CHANGED
|
@@ -9,6 +9,8 @@ import HiddenCss from './HiddenCss';
|
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Responsively hides children based on the selected implementation.
|
|
12
|
+
*
|
|
13
|
+
* @deprecated The Hidden component was deprecated in Material UI v5. To learn more, see [the Hidden section](/material-ui/migration/v5-component-changes/#hidden) of the migration docs.
|
|
12
14
|
*/
|
|
13
15
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
16
|
function Hidden(props) {
|
|
@@ -208,7 +208,7 @@ process.env.NODE_ENV !== "production" ? Pagination.propTypes /* remove-proptypes
|
|
|
208
208
|
*/
|
|
209
209
|
onChange: PropTypes.func,
|
|
210
210
|
/**
|
|
211
|
-
* The current page.
|
|
211
|
+
* The current page. Unlike `TablePagination`, which starts numbering from `0`, this pagination starts from `1`.
|
|
212
212
|
*/
|
|
213
213
|
page: integerPropType,
|
|
214
214
|
/**
|
package/legacy/Slider/Slider.js
CHANGED
|
@@ -332,7 +332,7 @@ export var SliderThumb = styled('span', {
|
|
|
332
332
|
boxShadow: 'none'
|
|
333
333
|
}
|
|
334
334
|
})), "&.".concat(sliderClasses.active), _extends({}, theme.vars ? {
|
|
335
|
-
boxShadow: "0px 0px 0px 14px rgba(".concat(theme.vars.palette[color].mainChannel, " / 0.16)
|
|
335
|
+
boxShadow: "0px 0px 0px 14px rgba(".concat(theme.vars.palette[color].mainChannel, " / 0.16)")
|
|
336
336
|
} : {
|
|
337
337
|
boxShadow: "0px 0px 0px 14px ".concat(alpha(theme.palette[color].main, 0.16))
|
|
338
338
|
}))
|
package/legacy/Tab/Tab.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
-
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
5
4
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
5
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
6
6
|
import * as React from 'react';
|
|
7
7
|
import PropTypes from 'prop-types';
|
|
8
8
|
import clsx from 'clsx';
|
|
@@ -34,11 +34,11 @@ var TabRoot = styled(ButtonBase, {
|
|
|
34
34
|
slot: 'Root',
|
|
35
35
|
overridesResolver: function overridesResolver(props, styles) {
|
|
36
36
|
var ownerState = props.ownerState;
|
|
37
|
-
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles["textColor".concat(capitalize(ownerState.textColor))], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped];
|
|
37
|
+
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles["textColor".concat(capitalize(ownerState.textColor))], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped, _defineProperty({}, "& .".concat(tabClasses.iconWrapper), styles.iconWrapper)];
|
|
38
38
|
}
|
|
39
|
-
})(function (
|
|
40
|
-
var theme =
|
|
41
|
-
ownerState =
|
|
39
|
+
})(function (_ref2) {
|
|
40
|
+
var theme = _ref2.theme,
|
|
41
|
+
ownerState = _ref2.ownerState;
|
|
42
42
|
return _extends({}, theme.typography.button, {
|
|
43
43
|
maxWidth: 360,
|
|
44
44
|
minWidth: 90,
|
package/legacy/index.js
CHANGED
|
@@ -23,6 +23,9 @@ export default function responsiveFontSizes(themeInput) {
|
|
|
23
23
|
});
|
|
24
24
|
variants.forEach(function (variant) {
|
|
25
25
|
var style = typography[variant];
|
|
26
|
+
if (!style) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
26
29
|
var remFontSize = parseFloat(convert(style.fontSize, 'rem'));
|
|
27
30
|
if (remFontSize <= 1) {
|
|
28
31
|
return;
|
|
@@ -4,7 +4,9 @@ import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWith
|
|
|
4
4
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
5
5
|
var _ClearIcon, _ArrowDropDownIcon;
|
|
6
6
|
const _excluded = ["autoComplete", "autoHighlight", "autoSelect", "blurOnSelect", "ChipProps", "className", "clearIcon", "clearOnBlur", "clearOnEscape", "clearText", "closeText", "componentsProps", "defaultValue", "disableClearable", "disableCloseOnSelect", "disabled", "disabledItemsFocusable", "disableListWrap", "disablePortal", "filterOptions", "filterSelectedOptions", "forcePopupIcon", "freeSolo", "fullWidth", "getLimitTagsText", "getOptionDisabled", "getOptionKey", "getOptionLabel", "isOptionEqualToValue", "groupBy", "handleHomeEndKeys", "id", "includeInputInList", "inputValue", "limitTags", "ListboxComponent", "ListboxProps", "loading", "loadingText", "multiple", "noOptionsText", "onChange", "onClose", "onHighlightChange", "onInputChange", "onOpen", "open", "openOnFocus", "openText", "options", "PaperComponent", "PopperComponent", "popupIcon", "readOnly", "renderGroup", "renderInput", "renderOption", "renderTags", "selectOnFocus", "size", "slotProps", "value"],
|
|
7
|
-
_excluded2 = ["ref"]
|
|
7
|
+
_excluded2 = ["ref"],
|
|
8
|
+
_excluded3 = ["key"],
|
|
9
|
+
_excluded4 = ["key"];
|
|
8
10
|
import * as React from 'react';
|
|
9
11
|
import PropTypes from 'prop-types';
|
|
10
12
|
import clsx from 'clsx';
|
|
@@ -30,7 +32,6 @@ import capitalize from '../utils/capitalize';
|
|
|
30
32
|
import useForkRef from '../utils/useForkRef';
|
|
31
33
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
32
34
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
33
|
-
import { createElement as _createElement } from "react";
|
|
34
35
|
const useThemeProps = createUseThemeProps('MuiAutocomplete');
|
|
35
36
|
const useUtilityClasses = ownerState => {
|
|
36
37
|
const {
|
|
@@ -91,6 +92,15 @@ const AutocompleteRoot = styled('div', {
|
|
|
91
92
|
}, styles.root, fullWidth && styles.fullWidth, hasPopupIcon && styles.hasPopupIcon, hasClearIcon && styles.hasClearIcon];
|
|
92
93
|
}
|
|
93
94
|
})({
|
|
95
|
+
[`&.${autocompleteClasses.focused} .${autocompleteClasses.clearIndicator}`]: {
|
|
96
|
+
visibility: 'visible'
|
|
97
|
+
},
|
|
98
|
+
/* Avoid double tap issue on iOS */
|
|
99
|
+
'@media (pointer: fine)': {
|
|
100
|
+
[`&:hover .${autocompleteClasses.clearIndicator}`]: {
|
|
101
|
+
visibility: 'visible'
|
|
102
|
+
}
|
|
103
|
+
},
|
|
94
104
|
[`& .${autocompleteClasses.tag}`]: {
|
|
95
105
|
margin: 3,
|
|
96
106
|
maxWidth: 'calc(100% - 6px)'
|
|
@@ -107,23 +117,6 @@ const AutocompleteRoot = styled('div', {
|
|
|
107
117
|
minWidth: 30
|
|
108
118
|
}
|
|
109
119
|
},
|
|
110
|
-
[`&.${autocompleteClasses.focused}`]: {
|
|
111
|
-
[`& .${autocompleteClasses.clearIndicator}`]: {
|
|
112
|
-
visibility: 'visible'
|
|
113
|
-
},
|
|
114
|
-
[`& .${autocompleteClasses.input}`]: {
|
|
115
|
-
minWidth: 0
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
/* Avoid double tap issue on iOS */
|
|
119
|
-
'@media (pointer: fine)': {
|
|
120
|
-
[`&:hover .${autocompleteClasses.clearIndicator}`]: {
|
|
121
|
-
visibility: 'visible'
|
|
122
|
-
},
|
|
123
|
-
[`&:hover .${autocompleteClasses.input}`]: {
|
|
124
|
-
minWidth: 0
|
|
125
|
-
}
|
|
126
|
-
},
|
|
127
120
|
[`& .${inputClasses.root}`]: {
|
|
128
121
|
paddingBottom: 1,
|
|
129
122
|
'& .MuiInput-input': {
|
|
@@ -537,12 +530,19 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
537
530
|
if (renderTags) {
|
|
538
531
|
startAdornment = renderTags(value, getCustomizedTagProps, ownerState);
|
|
539
532
|
} else {
|
|
540
|
-
startAdornment = value.map((option, index) =>
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
533
|
+
startAdornment = value.map((option, index) => {
|
|
534
|
+
const _getCustomizedTagProp = getCustomizedTagProps({
|
|
535
|
+
index
|
|
536
|
+
}),
|
|
537
|
+
{
|
|
538
|
+
key
|
|
539
|
+
} = _getCustomizedTagProp,
|
|
540
|
+
customTagProps = _objectWithoutPropertiesLoose(_getCustomizedTagProp, _excluded3);
|
|
541
|
+
return /*#__PURE__*/_jsx(Chip, _extends({
|
|
542
|
+
label: getOptionLabel(option),
|
|
543
|
+
size: size
|
|
544
|
+
}, customTagProps, ChipProps), key);
|
|
545
|
+
});
|
|
546
546
|
}
|
|
547
547
|
}
|
|
548
548
|
if (limitTags > -1 && Array.isArray(startAdornment)) {
|
|
@@ -570,9 +570,13 @@ const Autocomplete = /*#__PURE__*/React.forwardRef(function Autocomplete(inProps
|
|
|
570
570
|
const renderGroup = renderGroupProp || defaultRenderGroup;
|
|
571
571
|
const defaultRenderOption = (props2, option) => {
|
|
572
572
|
// Need to clearly apply key because of https://github.com/vercel/next.js/issues/55642
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
573
|
+
const {
|
|
574
|
+
key
|
|
575
|
+
} = props2,
|
|
576
|
+
otherProps = _objectWithoutPropertiesLoose(props2, _excluded4);
|
|
577
|
+
return /*#__PURE__*/_jsx("li", _extends({}, otherProps, {
|
|
578
|
+
children: getOptionLabel(option)
|
|
579
|
+
}), key);
|
|
576
580
|
};
|
|
577
581
|
const renderOption = renderOptionProp || defaultRenderOption;
|
|
578
582
|
const renderListOption = (option, index) => {
|
package/modern/Hidden/Hidden.js
CHANGED
|
@@ -10,6 +10,8 @@ import HiddenCss from './HiddenCss';
|
|
|
10
10
|
|
|
11
11
|
/**
|
|
12
12
|
* Responsively hides children based on the selected implementation.
|
|
13
|
+
*
|
|
14
|
+
* @deprecated The Hidden component was deprecated in Material UI v5. To learn more, see [the Hidden section](/material-ui/migration/v5-component-changes/#hidden) of the migration docs.
|
|
13
15
|
*/
|
|
14
16
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
15
17
|
function Hidden(props) {
|
|
@@ -193,7 +193,7 @@ process.env.NODE_ENV !== "production" ? Pagination.propTypes /* remove-proptypes
|
|
|
193
193
|
*/
|
|
194
194
|
onChange: PropTypes.func,
|
|
195
195
|
/**
|
|
196
|
-
* The current page.
|
|
196
|
+
* The current page. Unlike `TablePagination`, which starts numbering from `0`, this pagination starts from `1`.
|
|
197
197
|
*/
|
|
198
198
|
page: integerPropType,
|
|
199
199
|
/**
|
package/modern/Slider/Slider.js
CHANGED
|
@@ -322,7 +322,7 @@ export const SliderThumb = styled('span', {
|
|
|
322
322
|
}
|
|
323
323
|
}),
|
|
324
324
|
[`&.${sliderClasses.active}`]: _extends({}, theme.vars ? {
|
|
325
|
-
boxShadow: `0px 0px 0px 14px rgba(${theme.vars.palette[color].mainChannel} / 0.16)
|
|
325
|
+
boxShadow: `0px 0px 0px 14px rgba(${theme.vars.palette[color].mainChannel} / 0.16)`
|
|
326
326
|
} : {
|
|
327
327
|
boxShadow: `0px 0px 0px 14px ${alpha(theme.palette[color].main, 0.16)}`
|
|
328
328
|
})
|
package/modern/Tab/Tab.js
CHANGED
|
@@ -38,7 +38,9 @@ const TabRoot = styled(ButtonBase, {
|
|
|
38
38
|
const {
|
|
39
39
|
ownerState
|
|
40
40
|
} = props;
|
|
41
|
-
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles[`textColor${capitalize(ownerState.textColor)}`], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped
|
|
41
|
+
return [styles.root, ownerState.label && ownerState.icon && styles.labelIcon, styles[`textColor${capitalize(ownerState.textColor)}`], ownerState.fullWidth && styles.fullWidth, ownerState.wrapped && styles.wrapped, {
|
|
42
|
+
[`& .${tabClasses.iconWrapper}`]: styles.iconWrapper
|
|
43
|
+
}];
|
|
42
44
|
}
|
|
43
45
|
})(({
|
|
44
46
|
theme,
|
package/modern/index.js
CHANGED
|
@@ -18,6 +18,9 @@ export default function responsiveFontSizes(themeInput, options = {}) {
|
|
|
18
18
|
const breakpointValues = breakpoints.map(x => theme.breakpoints.values[x]);
|
|
19
19
|
variants.forEach(variant => {
|
|
20
20
|
const style = typography[variant];
|
|
21
|
+
if (!style) {
|
|
22
|
+
return;
|
|
23
|
+
}
|
|
21
24
|
const remFontSize = parseFloat(convert(style.fontSize, 'rem'));
|
|
22
25
|
if (remFontSize <= 1) {
|
|
23
26
|
return;
|