@mui/system 5.0.1 → 5.0.5

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 (61) hide show
  1. package/Box/Box.spec.d.ts +1 -1
  2. package/CHANGELOG.md +281 -0
  3. package/LICENSE +21 -21
  4. package/borders.js +1 -1
  5. package/breakpoints.js +4 -3
  6. package/colorManipulator.js +8 -8
  7. package/createStyled.d.ts +16 -215
  8. package/createStyled.js +1 -1
  9. package/createTheme/createBreakpoints.d.ts +53 -6
  10. package/createTheme/createBreakpoints.js +1 -1
  11. package/createTheme/createSpacing.d.ts +10 -10
  12. package/cssVars/createCssVarsProvider.d.ts +81 -0
  13. package/cssVars/createCssVarsProvider.js +206 -0
  14. package/cssVars/createCssVarsProvider.spec.d.ts +1 -0
  15. package/cssVars/cssVarsParser.d.ts +57 -0
  16. package/cssVars/cssVarsParser.js +126 -0
  17. package/cssVars/getInitColorSchemeScript.d.ts +7 -0
  18. package/cssVars/getInitColorSchemeScript.js +38 -0
  19. package/cssVars/index.d.ts +2 -0
  20. package/cssVars/index.js +15 -0
  21. package/cssVars/package.json +6 -0
  22. package/display.js +1 -1
  23. package/esm/cssVars/createCssVarsProvider.js +188 -0
  24. package/esm/cssVars/cssVarsParser.js +112 -0
  25. package/esm/cssVars/getInitColorSchemeScript.js +21 -0
  26. package/esm/cssVars/index.js +1 -0
  27. package/esm/index.js +2 -1
  28. package/esm/spacing.js +2 -2
  29. package/esm/styleFunctionSx/styleFunctionSx.js +6 -6
  30. package/flexbox.js +1 -1
  31. package/getThemeValue.js +1 -1
  32. package/grid.js +1 -1
  33. package/index.d.ts +6 -0
  34. package/index.js +77 -68
  35. package/index.spec.d.ts +1 -1
  36. package/legacy/cssVars/createCssVarsProvider.js +202 -0
  37. package/legacy/cssVars/cssVarsParser.js +125 -0
  38. package/legacy/cssVars/getInitColorSchemeScript.js +18 -0
  39. package/legacy/cssVars/index.js +1 -0
  40. package/legacy/index.js +3 -2
  41. package/legacy/spacing.js +2 -2
  42. package/legacy/styleFunctionSx/styleFunctionSx.js +6 -6
  43. package/modern/cssVars/createCssVarsProvider.js +188 -0
  44. package/modern/cssVars/cssVarsParser.js +112 -0
  45. package/modern/cssVars/getInitColorSchemeScript.js +21 -0
  46. package/modern/cssVars/index.js +1 -0
  47. package/modern/index.js +3 -2
  48. package/modern/spacing.js +2 -2
  49. package/modern/styleFunctionSx/styleFunctionSx.js +6 -6
  50. package/package.json +2 -2
  51. package/palette.js +1 -1
  52. package/positions.js +1 -1
  53. package/sizing.js +1 -1
  54. package/spacing.d.ts +12 -0
  55. package/spacing.js +5 -5
  56. package/style.d.ts +2 -2
  57. package/style.js +1 -1
  58. package/styleFunctionSx/styleFunctionSx.d.ts +8 -3
  59. package/styleFunctionSx/styleFunctionSx.js +6 -6
  60. package/typography.js +1 -1
  61. package/useTheme.js +1 -1
package/Box/Box.spec.d.ts CHANGED
@@ -1 +1 @@
1
- export {};
1
+ export {};
package/CHANGELOG.md CHANGED
@@ -1,5 +1,286 @@
1
1
  ### [Versions](https://mui.com/versions/)
2
2
 
3
+ ## 5.0.5
4
+
5
+ <!-- generated comparing v5.0.4..master -->
6
+
7
+ _Oct 26, 2021_
8
+
9
+ A big thanks to the 19 contributors who made this release possible. Here are some highlights ✨:
10
+
11
+ - 🔧 Implement `Masonry` using Flexbox by @hbjORbj.
12
+ - 🧪 Add three components to `@mui/core` by @rebeccahongsf and @hbjORbj.
13
+
14
+ ### `@mui/codemod@5.0.5`
15
+
16
+ - &#8203;<!-- 38 -->[codemod] Support new package name in `link-underline-hover` transformer (#29214) @siriwatknp
17
+
18
+ ### `@mui/core@5.0.0-alpha.52`
19
+
20
+ - &#8203;<!-- 39 -->[ClickAwayListener] Move to the core package (#29186) @hbjORbj
21
+ - &#8203;<!-- 13 -->[Popper] Move from mui-material to mui-core (#28923) @rebeccahongsf
22
+ - &#8203;<!-- 04 -->[TextareaAutosize] Move to the core package (#29148) @hbjORbj
23
+
24
+ ### `@mui/lab@5.0.0-alpha.52`
25
+
26
+ - &#8203;<!-- 16 -->[Masonry] Improve demo styles (#29218) @hbjORbj
27
+ - &#8203;<!-- 15 -->[Masonry] Implement Masonry using Flexbox (#28059) @hbjORbj
28
+
29
+ ### `@mui/icons@5.0.5`
30
+
31
+ - &#8203;<!-- 19 -->[icons] Add TipsAndUpdates icon (#29004) @hbjORbj
32
+
33
+ ### `@mui/material@5.0.5`
34
+
35
+ - &#8203;<!-- 40 -->[CardMedia] Apply specified `img` role instead of custom `image` role (#29172) @eps1lon
36
+ - &#8203;<!-- 32 -->[CSSBaseline] Remove incorrect @deprecated annotation (#29069) @adamfitzgibbon
37
+ - &#8203;<!-- 20 -->[Grid] Support custom columns with nested grid (#28743) @Devesh21700Kumar
38
+ - &#8203;<!-- 18 -->[InputBase] Remove wrong theme overriding with MUI's default theme (#29157) @hbjORbj
39
+ - &#8203;<!-- 17 -->[LoadingButton] Fix `fullWidth` styling (#28652) @nikitabobers
40
+ - &#8203;<!-- 16 -->[Popper] make Popper display:none whenever it's closed (#29233) @adamfitzgibbon
41
+ - &#8203;<!-- 14 -->[Menu] Reduce min-height & padding in menu-item with dense property (#29180) @jatinsandilya
42
+ - &#8203;<!-- 07 -->[Tab] `iconPosition` prop added in Tab (#28764) @deepanshu2506
43
+ - &#8203;<!-- 03 -->[Tooltip] Correct inconsistent prop precedence (#29132) @michaldudak
44
+
45
+ ### `@mui/system@5.0.5`
46
+
47
+ - &#8203;<!-- 11 -->[system] Allow function type for `sx` prop (#29198) @hbjORbj
48
+ - &#8203;<!-- 10 -->[system] Fix various issues reported by using @mui/styled-engine-sc (#29035) @mnajdova
49
+ - &#8203;<!-- 09 -->[system] Fix `colorScheme` conflict between application (#29139) @siriwatknp
50
+ - &#8203;<!-- 08 -->[system] Add `unstable_createCssVarsProvider` api (#28965) @siriwatknp
51
+
52
+ ### Documentation
53
+
54
+ - &#8203;<!-- 31 -->[docs] Fix path to `DataGrid` CSV export options page (#29220) @DanailH
55
+ - &#8203;<!-- 30 -->[docs] Give anonymous components a name (#29189) @eps1lon
56
+ - &#8203;<!-- 29 -->[docs] Add deploy context variables (#29195) @siriwatknp
57
+ - &#8203;<!-- 28 -->[docs] Add MUI packages explanation (#29073) @siriwatknp
58
+ - &#8203;<!-- 27 -->[docs] Fix typo in CSP policy (#29187) @JuliaNeumann
59
+ - &#8203;<!-- 26 -->[docs] Dark mode conditional content rendering (#28665) @michal-perlakowski
60
+ - &#8203;<!-- 25 -->[docs] Fix ClassNameGenerator introduced version #29177 @siriwatknp
61
+ - &#8203;<!-- 24 -->[docs] Add missing `justifyContent` values and update box styling (#29117) @omarmosid
62
+ - &#8203;<!-- 23 -->[docs] Make landing page hero section scrollable (#29141) @waxidiotic
63
+ - &#8203;<!-- 22 -->[docs] Discourage importing different bundles directly (#29133) @eps1lon
64
+ - &#8203;<!-- 21 -->[docs] Update module augmentation reference url (#29064) @gnowland
65
+ - &#8203;<!-- 12 -->[pricing] Add tooltip to pricing icon (#28959) @siriwatknp
66
+ - &#8203;<!-- 07 -->[Team] Add Alexandre in the about page (#29289)
67
+ - &#8203;<!-- 02 -->[website] Fix status label overflow in AdvancedShowcase (#29143) @LorenzHenk
68
+ - &#8203;<!-- 01 -->[website] Update legacy logos (#28908) @michaldudak
69
+
70
+ ### Core
71
+
72
+ - &#8203;<!-- 37 -->[core] Order repro methods by preference (#29156) @eps1lon
73
+ - &#8203;<!-- 36 -->[core] Remove unnecessary usages of `useEventCallback` (#28910) @NMinhNguyen
74
+ - &#8203;<!-- 35 -->[core] add `unstable_ClassNameGenerator` API (#29051) @siriwatknp
75
+ - &#8203;<!-- 34 -->[core] Fix issues when using styled-components (#29048) @mnajdova
76
+ - &#8203;<!-- 33 -->[core] replace hard-coded classname with classes (#29070) @siriwatknp
77
+ - &#8203;<!-- 06 -->[test] Add documentation for visual regression tests (#29154) @eps1lon
78
+ - &#8203;<!-- 05 -->[test] Enable "missing act" warnings using new proposal (#29167) @eps1lon
79
+
80
+ All contributors of this release in alphabetical order: @adamfitzgibbon, @DanailH, @deepanshu2506, @Devesh21700Kumar, @eps1lon, @gnowland, @hbjORbj, @jatinsandilya, @JuliaNeumann, @LorenzHenk, @michal-perlakowski, @michaldudak, @mnajdova, @nikitabobers, @NMinhNguyen, @omarmosid, @rebeccahongsf, @siriwatknp, @waxidiotic
81
+
82
+ ## 5.0.4
83
+
84
+ <!-- generated comparing v5.0.3..master -->
85
+
86
+ _Oct 14, 2021_
87
+
88
+ A big thanks to the 17 contributors who made this release possible. Here are some highlights ✨:
89
+
90
+ - 🧪 Added `UnstyledInput` and `useInput` hook in the the first component in @mui/core package @michaldudak (#28053)
91
+ - 🐛 Fixed many bugs and improved the documentation 📚.
92
+
93
+ ### `@mui/material@5.0.4`
94
+
95
+ - &#8203;<!-- 31 -->[Chip] disable ripple only if onDelete is present. (#29034) @mottox2
96
+ - &#8203;<!-- 06 -->[Pagination] Fix clicking on `...` triggering `onChange` with page value `null` (#28884) @ZeeshanTamboli
97
+ - &#8203;<!-- 04 -->[Tabs] Alternative way to disable ":first-child is unsafe" error (#28982) @hbjORbj
98
+ - &#8203;<!-- 03 -->[Tabs] Fix ":first-child is potentially unsafe" error (#28890) @hbjORbj
99
+ - &#8203;<!-- 01 -->[transitions] Mark `children` as required where nullish `children` would crash at runtime (#29028) @eps1lon
100
+
101
+ ### `@mui/system@5.0.4`
102
+
103
+ - &#8203;<!-- 05 -->[system] Update typing for `style` function (#28744) @hbjORbj
104
+
105
+ ### `@mui/core@5.0.0-alpha.51`
106
+
107
+ - &#8203;<!-- 07 -->[InputUnstyled] Create unstyled input and useInput hook (#28053) @michaldudak
108
+
109
+ ### `@mui/lab@5.0.0-alpha.51`
110
+
111
+ - &#8203;<!-- 25 -->[DesktopDatePicker] add Paper props to pass down to Paper component (#28865) @amen-souissi
112
+
113
+ ### Docs
114
+
115
+ - &#8203;<!-- 24 -->[docs] Add JSDoc to `theme.breakpoints` (#29039) @eps1lon
116
+ - &#8203;<!-- 23 -->[docs] Rename broken package names in docs pointing to `@mui/material` (#29006) @visualfanatic
117
+ - &#8203;<!-- 22 -->[docs] Add troubleshooting guide for unexpected styles (#28907) @mnajdova
118
+ - &#8203;<!-- 21 -->[docs] Fix issues reported by ahref (#28986) @mnajdova
119
+ - &#8203;<!-- 20 -->[docs] Remove json translations for dropped locales (#28987) @mnajdova
120
+ - &#8203;<!-- 19 -->[docs] Fix type signature of renderGroup in Autocomplete (#28876) @tanyabouman
121
+ - &#8203;<!-- 18 -->[docs] Minor typo in v4-v5 migration docs (#28995) @kgregory
122
+ - &#8203;<!-- 17 -->[docs] Add `mui-image` related project (#28621) @benmneb
123
+ - &#8203;<!-- 16 -->[docs] Update Getting Started Templates' Source URIs (#28929) @epodol
124
+ - &#8203;<!-- 15 -->[docs] Improve search experience (#28801) @siriwatknp
125
+ - &#8203;<!-- 14 -->[docs] Fix demo of the responsive drawer (#28226) @goncalovf
126
+ - &#8203;<!-- 13 -->[docs] Fix global theme link demo (#28974) @ZeeshanTamboli
127
+ - &#8203;<!-- 12 -->[docs] Update box example to use 'backgroundColor' rather than 'bgColor' (#28958) @Jareechang
128
+ - &#8203;<!-- 11 -->[docs] corrected `Box` import for `sx-prop` example (#28873) @phudekar
129
+ - &#8203;<!-- 10 -->[docs] Fix footnote ID links in CONTRIBUTING.md (#28849) @officialpiyush
130
+ - &#8203;<!-- 09 -->[docs] Fix color & density playground (#28803) @siriwatknp
131
+ - &#8203;<!-- 08 -->[docs] Improve visibility of styled engine configuration section in installation guide (#28903) @Jareechang
132
+
133
+ ### Core
134
+
135
+ - &#8203;<!-- 30 -->[core] Prevent yarn cache growing infinitely (#29040) @eps1lon
136
+ - &#8203;<!-- 29 -->[core] Update browserslist (#29025) @eps1lon
137
+ - &#8203;<!-- 28 -->[core] Update `peerDependencies` to require `latest` instead of `next` (#29007) @eps1lon
138
+ - &#8203;<!-- 27 -->[core] Increase memory limit for size:snapshot (#29005) @eps1lon
139
+ - &#8203;<!-- 26 -->[core] Init `private` Joy package (#28957) @siriwatknp
140
+ - &#8203;<!-- 02 -->[test] Remove a11y snapshot tests (#28887) @eps1lon
141
+
142
+ All contributors of this release in alphabetical order: @amen-souissi, @benmneb, @epodol, @eps1lon, @goncalovf, @hbjORbj, @Jareechang, @kgregory, @michaldudak, @mnajdova, @mottox2, @officialpiyush, @phudekar, @siriwatknp, @tanyabouman, @visualfanatic, @ZeeshanTamboli
143
+
144
+ ## 5.0.3
145
+
146
+ <!-- generated comparing v5.0.2..master -->
147
+
148
+ _Oct 7, 2021_
149
+
150
+ A big thanks to the 19 contributors who made this release possible. Here are some highlights ✨:
151
+
152
+ - 🧪 Created the first component in @mui/material-next - our v6 prototype package.
153
+ - 🐛 Fixed many bugs and improved the documentation 📚.
154
+
155
+ ### `@mui/material@5.0.3`
156
+
157
+ - &#8203;<!-- 10 -->[Stack] Add props & variants types in the theme (#28843) @mnajdova
158
+ - &#8203;<!-- 12 -->[InputLabel] Fix condition for applying formControl overrides (#28707) @yevheniiminin
159
+ - &#8203;<!-- 05 -->[Tooltip] Allow overriding internal components and their props (#28692) @michaldudak
160
+ - &#8203;<!-- 04 -->[transitions] Fix `addEndListener` not being called with the DOM node (#28715) @eps1lon
161
+
162
+ ### `@mui/codemod@5.0.3`
163
+
164
+ - &#8203;<!-- 37 -->[codemod] Fix `optimal-imports` to support v4 and v5-alpha, beta (#28812) @siriwatknp
165
+
166
+ ### `@mui/system@5.0.3`
167
+
168
+ - &#8203;<!-- 09 -->[system] Add padding/margin-block/inline to spacing (#28813) @smmoosavi
169
+
170
+ ### `@mui/styled-engine-sc@5.0.3`
171
+
172
+ - &#8203;<!-- 42 -->Don't allow styled-components APIs on mui styled function (#28807) @hbjORbj
173
+
174
+ ### `@mui/core@5.0.0-alpha.50`
175
+
176
+ - &#8203;<!-- 38 -->[ButtonUnstyled] Don't set redundant role=button (#28488) @michaldudak
177
+ - &#8203;<!-- 43 -->[SliderUnstyled] Prevent unknown-prop error when using marks prop (#28868) @hbjORbj
178
+
179
+ ### `@mui/lab@5.0.0-alpha.50`
180
+
181
+ - &#8203;<!-- 11 -->[pickers] Change view even if `onViewChange` is set (#28765) @eps1lon
182
+
183
+ ### `@mui/material-next@6.0.0-alpha.4`
184
+
185
+ - &#8203;<!-- 39 -->[Button-next] Create Button in material-next (#28313) @michaldudak
186
+
187
+ ### Docs
188
+
189
+ - &#8203;<!-- 34 -->[docs] Add alike v4 default button color in migration (#28881) @siriwatknp
190
+ - &#8203;<!-- 34 -->[docs] Use PNG instead of SVG for color preview (#28699) @eps1lon
191
+ - &#8203;<!-- 33 -->[docs] Use client-side navigation when activating docsearch results (#28750) @eps1lon
192
+ - &#8203;<!-- 32 -->[docs] Fluid icon size in icons search (#28747) @eps1lon
193
+ - &#8203;<!-- 31 -->[docs] Fix the wrong import in docs grid page (#28863) @taghi-khavari
194
+ - &#8203;<!-- 30 -->[docs] Fix typo in Pagination docs (#28864) @ZeeshanTamboli
195
+ - &#8203;<!-- 29 -->[docs] Fix 404 links (#28710) @mnajdova
196
+ - &#8203;<!-- 28 -->[docs] Fix typo in Mui CSS classname (#28725) @cacpgomes
197
+ - &#8203;<!-- 27 -->[docs] Match example to codesandbox demo and update ID link (#28762) @AnilSeervi
198
+ - &#8203;<!-- 26 -->[docs] Fix typo in system/box documentation (#28822) @iamsergo
199
+ - &#8203;<!-- 25 -->[docs] Use HTML standards for autocomplete attributes (#28827) @epodol
200
+ - &#8203;<!-- 24 -->[docs] Improve styled-components integration (#28713) @mnajdova
201
+ - &#8203;<!-- 23 -->[docs] Correct Select's menu placement description (#28748) @michaldudak
202
+ - &#8203;<!-- 22 -->[docs] AdapterDayJS -> AdapterDayjs (#28770) @veerreshr
203
+ - &#8203;<!-- 21 -->[docs] Theme documentation, typo fix (#28805) @saeedseyfi
204
+ - &#8203;<!-- 20 -->[docs] Add the last diamond sponsor (#28737) @hbjORbj
205
+ - &#8203;<!-- 19 -->[docs] Fix various links in CONTRIBUTING (#28751) @AnilSeervi
206
+ - &#8203;<!-- 18 -->[docs] Only add JSS to demos (#28698) @eps1lon
207
+ - &#8203;<!-- 17 -->[docs] Update v5 status in release schedule (#28700) @owais635
208
+ - &#8203;<!-- 16 -->[docs] Fix typo in /guides/styled-engine (#28720) @Sharry0
209
+ - &#8203;<!-- 15 -->[docs] Fix typo in chip documentation (#28641) @avranju94
210
+ - &#8203;<!-- 14 -->[docs] Fix versions page (#28682) @mnajdova
211
+ - &#8203;<!-- 13 -->[docs] Remove legacy team page (#28646) @mnajdova
212
+ - &#8203;<!-- 41 -->[website] add "React" to the hero description (#28830) @danilo-leal
213
+ - &#8203;<!-- 03 -->[website] Fix constantly reloading when Russian language is set (#28869) @mnajdova
214
+ - &#8203;<!-- 02 -->[website] Compress one avatar image on about us page (#28823) @hbjORbj
215
+ - &#8203;<!-- 01 -->[website] Hide 'become a diamond sponsor' box on landing page (#28814) @hbjORbj
216
+ - &#8203;<!-- 40 -->[website] Update Benny's profile on about us page (#28816) @hbjORbj
217
+
218
+ ### Core
219
+
220
+ - &#8203;<!-- 36 -->[core] Remove `--exact` from `release:version` (#28840) @siriwatknp
221
+ - &#8203;<!-- 35 -->[core] Neglect framer from release flow (#28680) @siriwatknp
222
+ - &#8203;<!-- 08 -->[test] Add a test for not allowing styled-components' APIs on mui `styled` function (#28862) @hbjORbj
223
+ - &#8203;<!-- 07 -->[test] Fix instances where type tests were only passing due to object being part of ReactNode (#28804) @eps1lon
224
+ - &#8203;<!-- 06 -->[test] Move ByMuiTest to test/utils (#28509) @eps1lon
225
+
226
+ All contributors of this release in alphabetical order: @AnilSeervi, @avranju94, @cacpgomes, @danilo-leal, @epodol, @eps1lon, @hbjORbj, @iamsergo, @michaldudak, @mnajdova, @owais635, @saeedseyfi, @Sharry0, @siriwatknp, @smmoosavi, @taghi-khavari, @veerreshr, @yevheniiminin, @ZeeshanTamboli
227
+
228
+ ## 5.0.2
229
+
230
+ <!-- generated comparing v5.0.1..master -->
231
+
232
+ _Sep 29, 2021_
233
+
234
+ A big thanks to the 15 contributors who made this release possible. Here are some highlights ✨:
235
+
236
+ - 🔧 Improve `jss-to-styled` codemod to use new package names.
237
+ - And many more 🐛 bug fixes and 📚 improvements.
238
+
239
+ ### `@mui/material@5.0.2`
240
+
241
+ - &#8203;<!-- 28 -->[Checkbox] Fix form submission with empty value (#28423) @garronej
242
+ - &#8203;<!-- 08 -->[Slider] Don't error on minimal changes with readonly value (#28472) @eps1lon
243
+ - &#8203;<!-- 07 -->[Switch] Fix style overrides on input (#28576) @praveenkumar-kalidass
244
+ - &#8203;<!-- 03 -->[useMediaQuery] Add types for `matchMedia` option and deprecate exported interfaces (#28413) @eps1lon
245
+
246
+ ### `@mui/codemod@5.0.2`
247
+
248
+ - &#8203;<!-- 27 -->[codemod] Add MenuItem v.1.0.0 transform for primaryText property (#28640) @dmitry-yudakov
249
+ - &#8203;<!-- 26 -->[codemod] Update the imports in `jss-to-styled` to match the new package names (#28667) @mnajdova
250
+
251
+ ### `@mui/system@5.0.2`
252
+
253
+ - &#8203;<!-- 06 -->[system] Fix types to support theme callbacks on pseudo and nested selectors (#28570) @mnajdova
254
+
255
+ ### Docs
256
+
257
+ - &#8203;<!-- 23 -->[docs] Remove languages: fr, de, ja, es, ru (#28663) @mnajdova
258
+ - &#8203;<!-- 22 -->[docs] Improve old doc versions discoverability (#28651) @danilo-leal
259
+ - &#8203;<!-- 21 -->[docs] Make the Toggle Button size demo use default icon size (#28656) @danilo-leal
260
+ - &#8203;<!-- 20 -->[docs] Uniformize the code's font family (#28582) @oliviertassinari
261
+ - &#8203;<!-- 19 -->[docs] Removed duplicate line in date-ranger-picker.md file (#28635) @naveen-bharathi
262
+ - &#8203;<!-- 18 -->[docs] Fix title MUI x2 (#28634) @oliviertassinari
263
+ - &#8203;<!-- 17 -->[docs] Polish email validation logic (#28255) @kiznick
264
+ - &#8203;<!-- 16 -->[docs] Improve migration-v4.md phrasing (#28253) @adamthewebguy
265
+ - &#8203;<!-- 15 -->[docs] Fix color in example (#28527) @alexeagleson
266
+ - &#8203;<!-- 14 -->[docs] Fix typo in generated class names section (#28549) @fxlemire
267
+ - &#8203;<!-- 13 -->[docs] Mention Premium pricing cap (#28581) @oliviertassinari
268
+ - &#8203;<!-- 12 -->[docs] Update examples to use latest mui #28565 @siriwatknp
269
+ - &#8203;<!-- 11 -->[docs] Push the fixes on Next.js's Link to the examples (#28178) @oliviertassinari
270
+ - &#8203;<!-- 10 -->[docs] Fix wrong name for zIndex's property example in /system/ (#28541) @chetrit
271
+ - &#8203;<!-- 08 -->[examples] Nextjs Link missing passHref #28588 (#28661) @Brlaney
272
+ - &#8203;<!-- 02 -->[website] Iteration on the pricing page (#28406) @danilo-leal
273
+ - &#8203;<!-- 01 -->[website] Batch fixes (#28564) @siriwatknp
274
+
275
+ ### Core
276
+
277
+ - &#8203;<!-- 25 -->[core] Improve Renovate groups (#28642) @eps1lon
278
+ - &#8203;<!-- 24 -->[core] Batch small changes (#28553) @oliviertassinari
279
+ - &#8203;<!-- 05 -->[test] Document where the value for SwitchBase#value comes from (#28638) @eps1lon
280
+ - &#8203;<!-- 04 -->[test] Make `seconds` `views` test pass in browsers (#28511) @eps1lon
281
+
282
+ All contributors of this release in alphabetical order: @adamthewebguy, @alexeagleson, @Brlaney, @chetrit, @danilo-leal, @dmitry-yudakov, @eps1lon, @fxlemire, @garronej, @kiznick, @mnajdova, @naveen-bharathi, @oliviertassinari, @praveenkumar-kalidass, @siriwatknp
283
+
3
284
  ## 5.0.1
4
285
 
5
286
  <!-- generated comparing v5.0.0..master -->
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2014 Call-Em-All
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2014 Call-Em-All
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/borders.js CHANGED
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports.default = exports.borderRadius = exports.borderLeftColor = exports.borderBottomColor = exports.borderRightColor = exports.borderTopColor = exports.borderColor = exports.borderLeft = exports.borderBottom = exports.borderRight = exports.borderTop = exports.border = void 0;
8
+ exports.default = exports.borderTopColor = exports.borderTop = exports.borderRightColor = exports.borderRight = exports.borderRadius = exports.borderLeftColor = exports.borderLeft = exports.borderColor = exports.borderBottomColor = exports.borderBottom = exports.border = void 0;
9
9
 
10
10
  var _responsivePropType = _interopRequireDefault(require("./responsivePropType"));
11
11
 
package/breakpoints.js CHANGED
@@ -5,12 +5,13 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports.handleBreakpoints = handleBreakpoints;
9
8
  exports.createEmptyBreakpointObject = createEmptyBreakpointObject;
10
- exports.removeUnusedBreakpoints = removeUnusedBreakpoints;
9
+ exports.default = void 0;
10
+ exports.handleBreakpoints = handleBreakpoints;
11
11
  exports.mergeBreakpointsInOrder = mergeBreakpointsInOrder;
12
+ exports.removeUnusedBreakpoints = removeUnusedBreakpoints;
12
13
  exports.resolveBreakpointValues = resolveBreakpointValues;
13
- exports.default = exports.values = void 0;
14
+ exports.values = void 0;
14
15
 
15
16
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
16
17
 
@@ -3,17 +3,17 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.hexToRgb = hexToRgb;
7
- exports.decomposeColor = decomposeColor;
8
- exports.recomposeColor = recomposeColor;
9
- exports.rgbToHex = rgbToHex;
10
- exports.hslToRgb = hslToRgb;
11
- exports.getLuminance = getLuminance;
12
- exports.getContrastRatio = getContrastRatio;
13
6
  exports.alpha = alpha;
14
7
  exports.darken = darken;
15
- exports.lighten = lighten;
8
+ exports.decomposeColor = decomposeColor;
16
9
  exports.emphasize = emphasize;
10
+ exports.getContrastRatio = getContrastRatio;
11
+ exports.getLuminance = getLuminance;
12
+ exports.hexToRgb = hexToRgb;
13
+ exports.hslToRgb = hslToRgb;
14
+ exports.lighten = lighten;
15
+ exports.recomposeColor = recomposeColor;
16
+ exports.rgbToHex = rgbToHex;
17
17
 
18
18
  var _utils = require("@mui/utils");
19
19
 
package/createStyled.d.ts CHANGED
@@ -1,233 +1,34 @@
1
1
  import * as React from 'react';
2
- import * as CSS from 'csstype';
2
+ import {
3
+ CreateMUIStyled as CreateMUIStyledStyledEngine,
4
+ CSSInterpolation,
5
+ } from '@mui/styled-engine';
3
6
  import { SxProps } from './styleFunctionSx';
4
7
  import { Theme as DefaultTheme } from './createTheme';
5
8
 
6
- export interface SerializedStyles {
7
- name: string;
8
- styles: string;
9
- map?: string;
10
- next?: SerializedStyles;
11
- }
12
-
13
- export type CSSProperties = CSS.PropertiesFallback<number | string>;
14
- export type CSSPropertiesWithMultiValues = {
15
- [K in keyof CSSProperties]: CSSProperties[K] | Array<Extract<CSSProperties[K], string>>;
16
- };
17
- export type CSSPseudos = { [K in CSS.Pseudos]?: unknown | CSSObject };
18
-
19
- export interface CSSOthersObject {
20
- [propertiesName: string]: unknown | CSSInterpolation;
21
- }
22
- export type CSSPseudosForCSSObject = { [K in CSS.Pseudos]?: CSSObject };
23
-
24
- export interface ArrayCSSInterpolation extends Array<CSSInterpolation> {}
25
-
26
- export interface CSSOthersObjectForCSSObject {
27
- [propertiesName: string]: CSSInterpolation;
28
- }
29
-
30
- export interface CSSObject extends CSSPropertiesWithMultiValues, CSSPseudos, CSSOthersObject {}
31
-
32
- export interface ComponentSelector {
33
- __emotion_styles: any;
34
- }
35
-
36
- export type Keyframes = {
37
- name: string;
38
- styles: string;
39
- anim: number;
40
- toString: () => string;
41
- } & string;
42
-
43
- export type Equal<A, B, T, F> = A extends B ? (B extends A ? T : F) : F;
44
-
45
- export type InterpolationPrimitive =
46
- | null
47
- | undefined
48
- | boolean
49
- | number
50
- | string
51
- | ComponentSelector
52
- | Keyframes
53
- | SerializedStyles
54
- | CSSObject;
55
-
56
- export type CSSInterpolation = InterpolationPrimitive | ArrayCSSInterpolation;
57
-
58
- export interface FunctionInterpolation<Props> {
59
- (props: Props): Interpolation<Props>;
60
- }
61
-
62
- export interface ArrayInterpolation<Props> extends Array<Interpolation<Props>> {}
63
-
64
- export type Interpolation<Props> =
65
- | InterpolationPrimitive
66
- | ArrayInterpolation<Props>
67
- | FunctionInterpolation<Props>;
68
-
69
- /**
70
- * @desc Utility type for getting props type of React component.
71
- * It takes `defaultProps` into an account - making props with defaults optional.
72
- */
73
- export type PropsOf<C extends keyof JSX.IntrinsicElements | React.JSXElementConstructor<any>> =
74
- JSX.LibraryManagedAttributes<C, React.ComponentProps<C>>;
75
-
76
- export type Overwrapped<T, U> = Pick<T, Extract<keyof T, keyof U>>;
77
-
78
- export interface StyledComponent<InnerProps, OwnerState, Theme extends object>
79
- extends React.FunctionComponent<InnerProps & OwnerState & { theme?: Theme }>,
80
- ComponentSelector {}
9
+ export function shouldForwardProp(propName: PropertyKey): boolean;
81
10
 
82
- export interface StyledOptions {
83
- label?: string;
84
- shouldForwardProp?(propName: PropertyKey): boolean;
85
- target?: string;
11
+ export interface MUIStyledCommonProps<Theme extends object = DefaultTheme> {
12
+ theme?: Theme;
13
+ as?: React.ElementType;
14
+ sx?: SxProps<Theme>;
86
15
  }
87
16
 
88
17
  export interface MuiStyledOptions {
89
18
  name?: string;
90
19
  slot?: string;
20
+ // The difference between Interpolation and CSSInterpolation is that the former supports functions based on props
21
+ // If we want to support props in the overrides, we will need to change the CSSInterpolation to Interpolation<Props>
91
22
  overridesResolver?: (props: any, styles: Record<string, CSSInterpolation>) => CSSInterpolation;
92
23
  skipVariantsResolver?: boolean;
93
24
  skipSx?: boolean;
94
25
  }
95
26
 
96
- /** Same as StyledOptions but shouldForwardProp must be a type guard */
97
- export interface FilteringStyledOptions<Props, ForwardedProps extends keyof Props = keyof Props> {
98
- label?: string;
99
- shouldForwardProp?(propName: PropertyKey): propName is ForwardedProps;
100
- target?: string;
101
- }
102
-
103
- /**
104
- * @typeparam ComponentProps Props which will be included when withComponent is called
105
- * @typeparam SpecificComponentProps Props which will *not* be included when withComponent is called
106
- */
107
- export interface CreateStyledComponent<
108
- ComponentProps extends {},
109
- SpecificComponentProps extends {} = {},
110
- JSXProps extends {} = {},
111
- > {
112
- /**
113
- * @typeparam AdditionalProps Additional props to add to your styled component
114
- */
115
- <AdditionalProps extends {} = {}>(
116
- ...styles: Array<
117
- Interpolation<
118
- ComponentProps & SpecificComponentProps & AdditionalProps & { theme: DefaultTheme }
119
- >
120
- >
121
- ): StyledComponent<ComponentProps & AdditionalProps, SpecificComponentProps, JSXProps>;
122
-
123
- (
124
- template: TemplateStringsArray,
125
- ...styles: Array<
126
- Interpolation<ComponentProps & SpecificComponentProps & { theme: DefaultTheme }>
127
- >
128
- ): StyledComponent<ComponentProps, SpecificComponentProps, JSXProps>;
129
-
130
- /**
131
- * @typeparam AdditionalProps Additional props to add to your styled component
132
- */
133
- <AdditionalProps extends {}>(
134
- template: TemplateStringsArray,
135
- ...styles: Array<
136
- Interpolation<
137
- ComponentProps & SpecificComponentProps & AdditionalProps & { theme: DefaultTheme }
138
- >
139
- >
140
- ): StyledComponent<ComponentProps & AdditionalProps, SpecificComponentProps, JSXProps>;
141
- }
142
-
143
- export interface CreateMUIStyled<Theme extends object = DefaultTheme> {
144
- <
145
- C extends React.ComponentClass<React.ComponentProps<C>>,
146
- ForwardedProps extends keyof React.ComponentProps<C> = keyof React.ComponentProps<C>,
147
- >(
148
- component: C,
149
- options: FilteringStyledOptions<React.ComponentProps<C>, ForwardedProps> & MuiStyledOptions,
150
- ): CreateStyledComponent<
151
- Pick<PropsOf<C>, ForwardedProps> & {
152
- theme?: Theme;
153
- as?: React.ElementType;
154
- sx?: SxProps<Theme>;
155
- },
156
- {},
157
- {
158
- ref?: React.Ref<InstanceType<C>>;
159
- }
160
- >;
161
-
162
- <C extends React.ComponentClass<React.ComponentProps<C>>>(
163
- component: C,
164
- options?: StyledOptions & MuiStyledOptions,
165
- ): CreateStyledComponent<
166
- PropsOf<C> & {
167
- theme?: Theme;
168
- as?: React.ElementType;
169
- sx?: SxProps<Theme>;
170
- },
171
- {},
172
- {
173
- ref?: React.Ref<InstanceType<C>>;
174
- }
175
- >;
176
-
177
- <
178
- C extends React.JSXElementConstructor<React.ComponentProps<C>>,
179
- ForwardedProps extends keyof React.ComponentProps<C> = keyof React.ComponentProps<C>,
180
- >(
181
- component: C,
182
- options: FilteringStyledOptions<React.ComponentProps<C>, ForwardedProps> & MuiStyledOptions,
183
- ): CreateStyledComponent<
184
- Pick<PropsOf<C>, ForwardedProps> & {
185
- theme?: Theme;
186
- as?: React.ElementType;
187
- sx?: SxProps<Theme>;
188
- }
189
- >;
190
-
191
- <C extends React.JSXElementConstructor<React.ComponentProps<C>>>(
192
- component: C,
193
- options?: StyledOptions & MuiStyledOptions,
194
- ): CreateStyledComponent<
195
- PropsOf<C> & {
196
- theme?: Theme;
197
- as?: React.ElementType;
198
- sx?: SxProps<Theme>;
199
- }
200
- >;
201
-
202
- <
203
- Tag extends keyof JSX.IntrinsicElements,
204
- ForwardedProps extends keyof JSX.IntrinsicElements[Tag] = keyof JSX.IntrinsicElements[Tag],
205
- >(
206
- tag: Tag,
207
- options: FilteringStyledOptions<JSX.IntrinsicElements[Tag], ForwardedProps> & MuiStyledOptions,
208
- ): CreateStyledComponent<
209
- {
210
- theme?: Theme;
211
- as?: React.ElementType;
212
- sx?: SxProps<Theme>;
213
- },
214
- Pick<JSX.IntrinsicElements[Tag], ForwardedProps>
215
- >;
216
-
217
- <Tag extends keyof JSX.IntrinsicElements>(
218
- tag: Tag,
219
- options?: StyledOptions & MuiStyledOptions,
220
- ): CreateStyledComponent<
221
- {
222
- theme?: Theme;
223
- as?: React.ElementType;
224
- sx?: SxProps<Theme>;
225
- },
226
- JSX.IntrinsicElements[Tag]
227
- >;
228
- }
229
-
230
- export function shouldForwardProp(propName: PropertyKey): boolean;
27
+ export type CreateMUIStyled<T extends object = DefaultTheme> = CreateMUIStyledStyledEngine<
28
+ MUIStyledCommonProps<T>,
29
+ MuiStyledOptions,
30
+ T
31
+ >;
231
32
 
232
33
  export default function createStyled<T extends object = DefaultTheme>(options?: {
233
34
  defaultTheme?: T;
package/createStyled.js CHANGED
@@ -5,8 +5,8 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports.shouldForwardProp = shouldForwardProp;
9
8
  exports.default = createStyled;
9
+ exports.shouldForwardProp = shouldForwardProp;
10
10
  exports.systemDefaultTheme = void 0;
11
11
 
12
12
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));