@mui/styled-engine 6.0.0-alpha.0 → 6.0.0-alpha.3
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/CHANGELOG.md +243 -4
- package/index.js +1 -1
- package/modern/index.js +1 -1
- package/node/index.js +1 -1
- package/package.json +2 -2
- package/legacy/GlobalStyles/GlobalStyles.js +0 -24
- package/legacy/GlobalStyles/index.js +0 -3
- package/legacy/StyledEngineProvider/StyledEngineProvider.js +0 -38
- package/legacy/StyledEngineProvider/index.js +0 -3
- package/legacy/index.js +0 -43
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,204 @@
|
|
|
1
1
|
# [Versions](https://mui.com/versions/)
|
|
2
2
|
|
|
3
|
+
## v6.0.0-alpha.3
|
|
4
|
+
|
|
5
|
+
<!-- generated comparing v6.0.0-alpha.2..next -->
|
|
6
|
+
|
|
7
|
+
_Apr 17, 2024_
|
|
8
|
+
|
|
9
|
+
A big thanks to the 24 contributors who made this release possible. Here are some highlights ✨:
|
|
10
|
+
|
|
11
|
+
- 🔥 Converted 5 more Material UI components to use Pigment CSS.
|
|
12
|
+
- 🚀 Added container queries utility to the `@mui/system` package (#41674) @siriwatknp.
|
|
13
|
+
|
|
14
|
+
### `@mui/material@6.0.0-alpha.3`
|
|
15
|
+
|
|
16
|
+
- Convert `LinearProgress` to support Pigment CSS (#41816) @siriwatknp
|
|
17
|
+
- [Dialog] Prevent onClick on the root element from being overwritten (#41881) @ryanburr
|
|
18
|
+
- [FloatingActionButton] Convert to support CSS extraction (#41851) @gijsbotje
|
|
19
|
+
- Convert `CircularProgress` to support Pigment CSS (#41776) @siriwatknp
|
|
20
|
+
- [PaginationItem] Convert to support CSS extraction (#41848) @gijsbotje
|
|
21
|
+
- [StepConnector] deprecate composed classes (#41740) @sai6855
|
|
22
|
+
- [StepLabel] Deprecate `StepIconComponent`, `StepIconProps` (#41835) @sai6855
|
|
23
|
+
- [ToggleButton] Convert to support CSS extraction (#41782) @lhilgert9
|
|
24
|
+
- [ToggleButtonGroup] Deprecate composed classes (#41288) @sai6855
|
|
25
|
+
- [Typography] Fix Typography inherit variant styles (#41308) @kealjones-wk
|
|
26
|
+
|
|
27
|
+
### `@mui/system@6.0.0-alpha.3`
|
|
28
|
+
|
|
29
|
+
- Add container queries utility (#41674) @siriwatknp
|
|
30
|
+
|
|
31
|
+
### `@mui/codemod@6.0.0-alpha.3`
|
|
32
|
+
|
|
33
|
+
- Add styled v6 transformation (#41743) @siriwatknp
|
|
34
|
+
|
|
35
|
+
### `@mui/joy@5.0.0-beta.36`
|
|
36
|
+
|
|
37
|
+
- [Button] Disable text highlighting (#41902) @mithun522
|
|
38
|
+
|
|
39
|
+
### `@pigment-css/react@0.0.7`
|
|
40
|
+
|
|
41
|
+
- Patch WyW's WeakRef usage (#41909) @DiegoAndai
|
|
42
|
+
- Implement sx transform for system components (#41861) @brijeshb42
|
|
43
|
+
|
|
44
|
+
### Docs
|
|
45
|
+
|
|
46
|
+
- [material-ui] Add Connect-related content (#40848) @danilo-leal
|
|
47
|
+
- [material-ui] Fix credit comment typo (#41872) @aarongarciah
|
|
48
|
+
- [material-ui] Remove Data Grid v7 beta callout (#41839) @cherniavskii
|
|
49
|
+
- [material-ui] Add stray design tweaks to free templates (#41696) @zanivan
|
|
50
|
+
- [material-ui] Simplify components styling on templates (#41845) @zanivan
|
|
51
|
+
- [material-ui][Button] Add `onChange` event handler to file upload example (#41863) @aarongarciah
|
|
52
|
+
- [material-ui] Fix import statement in migration guide (#41852) @sai6855
|
|
53
|
+
- Fix 301 redirection @oliviertassinari
|
|
54
|
+
- Fix format git diff regression (#41882) @oliviertassinari
|
|
55
|
+
- Fix small SEO issues @oliviertassinari
|
|
56
|
+
- [pigment-css] Fix README typos (#41870) @MohammadShehadeh
|
|
57
|
+
|
|
58
|
+
### Core
|
|
59
|
+
|
|
60
|
+
- Begin removing IE 11-related code (#41709) @iammminzzy
|
|
61
|
+
- [blog] Add post to introduce the Connect plugin (#41763) @danilo-leal
|
|
62
|
+
- [code-infra] Fix require.context with aliases (#41682) @Janpot
|
|
63
|
+
- [code-infra] Allow customizing hooks imports in API docs generator (#41828) @michaldudak
|
|
64
|
+
- [codemod] Add utils for `*Component` and `*Props` props deprecations (#41685) @DiegoAndai
|
|
65
|
+
- Replace bundle size reporter filter (#38979) @Janpot
|
|
66
|
+
- [docs-infra] Make the whole header clickable (#39603) @MoazMirza-13
|
|
67
|
+
- [docs-infra] Improve demo container and related components design (#41827) @danilo-leal
|
|
68
|
+
- [docs-infra] Use edge function for card generation (#41188) (#41836) @alexfauquette
|
|
69
|
+
- [docs-infra] Fix code block layout shift (#41917) @oliviertassinari
|
|
70
|
+
- [docs-infra] Fine-tune the OG card image design (#41862) @danilo-leal
|
|
71
|
+
- [docs-infra] Fix markdown version for material (#41908) @alexfauquette
|
|
72
|
+
- [docs-infra] Support multiple tabs in demos (#40901) @bharatkashyap
|
|
73
|
+
|
|
74
|
+
All contributors of this release in alphabetical order: @aarongarciah, @alexfauquette, @bharatkashyap, @brijeshb42, @cherniavskii, @danilo-leal, @DiegoAndai, @EyaOuenniche, @gijsbotje, @iammminzzy, @Janpot, @kealjones-wk, @lhilgert9, @magnimarels, @michaldudak, @mithun522, @mnajdova, @MoazMirza-13, @MohammadShehadeh, @oliviertassinari, @ryanburr, @sai6855, @siriwatknp, @zanivan
|
|
75
|
+
|
|
76
|
+
## v6.0.0-alpha.2
|
|
77
|
+
|
|
78
|
+
<!-- generated comparing v6.0.0-alpha.1..next -->
|
|
79
|
+
|
|
80
|
+
_Apr 9, 2024_
|
|
81
|
+
|
|
82
|
+
A big thanks to the 5 contributors who made this release possible.
|
|
83
|
+
This release was mostly about 🐛 bug fixes and 📚 documentation improvements.
|
|
84
|
+
|
|
85
|
+
### `@mui/material@6.0.0-alpha.2`
|
|
86
|
+
|
|
87
|
+
- ​<!-- 03 -->[typescript][Select] Fix `muiName` property TypeScript error (#41726) @EyaOuenniche
|
|
88
|
+
- ​<!-- 04 -->[l10n] Fix typo in is-IS locale (#41810) @magnimarels
|
|
89
|
+
|
|
90
|
+
### `@pigment-css/react@0.0.6`
|
|
91
|
+
|
|
92
|
+
- ​<!-- 12 -->[core] Remove `muiName` during eval phase (#41811) @brijeshb42
|
|
93
|
+
|
|
94
|
+
### `@pigment-css/nextjs-plugin@0.0.6`
|
|
95
|
+
|
|
96
|
+
- ​<!-- 02 -->[nextjs] Handle file references passed through imports (#41817) @brijeshb42
|
|
97
|
+
- ​<!-- 01 -->[nextjs] Allow usage of url() CSS function (#41758) @brijeshb42
|
|
98
|
+
|
|
99
|
+
### Docs
|
|
100
|
+
|
|
101
|
+
- ​<!-- 11 -->[docs] Fix 301 links @oliviertassinari
|
|
102
|
+
- ​<!-- 06 -->[pigment-css][docs] Fix README typo (#41808) @aarongarciah
|
|
103
|
+
- ​<!-- 05 -->[pigment-css][docs] Fix output on dynamic styles example (#41805) @aarongarciah
|
|
104
|
+
- ​<!-- 07 -->[material-ui][docs] Fix Material 3 message typo (#41821) @aarongarciah
|
|
105
|
+
- ​<!-- 08 -->[material-ui][docs] Add stray design tweaks to free templates (#41696) @zanivan
|
|
106
|
+
|
|
107
|
+
### Core
|
|
108
|
+
|
|
109
|
+
- ​<!-- 13 -->[core] Remove unused files (#41818) @mnajdova
|
|
110
|
+
- ​<!-- 10 -->[docs-infra] Fix analytics about inline ads (#41474) (#41819) @alexfauquette
|
|
111
|
+
- ​<!-- 08 -->[docs-infra] Fix drawer performances (#41807) @alexfauquette
|
|
112
|
+
|
|
113
|
+
All contributors of this release in alphabetical order: @aarongarciah, @alexfauquette, @brijeshb42, @EyaOuenniche, @oliviertassinari
|
|
114
|
+
|
|
115
|
+
## v6.0.0-alpha.1
|
|
116
|
+
|
|
117
|
+
<!-- generated comparing v6.0.0-alpha.0..next -->
|
|
118
|
+
|
|
119
|
+
_Apr 5, 2024_
|
|
120
|
+
|
|
121
|
+
A big thanks to the 19 contributors who made this release possible. Here are some highlights ✨:
|
|
122
|
+
|
|
123
|
+
- 🔥 Converted 3 more Material UI components to use Pigment CSS. Current progress is 36%!
|
|
124
|
+
- 🚀 Added a spacing CSS variable to the Material UI and Joy UI themes.
|
|
125
|
+
- 💫 Added 3 redesigned free Material UI templates: [Sign-in](https://next.mui.com/material-ui/getting-started/templates/sign-in/), [Sign-in side](https://next.mui.com/material-ui/getting-started/templates/sign-in-side/), and [Sign-up](https://next.mui.com/material-ui/getting-started/templates/sign-up/).
|
|
126
|
+
|
|
127
|
+
### `@mui/material@6.0.0-alpha.1`
|
|
128
|
+
|
|
129
|
+
- [AppBar] Convert to support CSS extraction (#41247) @mnajdova
|
|
130
|
+
- [Badge] Deprecate components and componentsProps (#41655) @skmanoj322
|
|
131
|
+
- [Button] Convert to support CSS extraction (#41378) @siriwatknp
|
|
132
|
+
- [ButtonGroup] Convert to support CSS extraction (#41666) @zanivan
|
|
133
|
+
- [RadioGroup] Apply classnames (#41610) @ZeeshanTamboli
|
|
134
|
+
- [Slider] Move palette styles to the bottom (#41676) @siriwatknp
|
|
135
|
+
- Add the `spacing` theme token (#40224) @siriwatknp
|
|
136
|
+
|
|
137
|
+
### `@mui/system@6.0.0-alpha.1`
|
|
138
|
+
|
|
139
|
+
- Add the `spacing` theme token to be used in `theme.spacing()` (#40224) @siriwatknp
|
|
140
|
+
|
|
141
|
+
### `@mui/codemod@6.0.0-alpha.1`
|
|
142
|
+
|
|
143
|
+
- [codemod] Setup v6 codemod structure (#41668) @DiegoAndai
|
|
144
|
+
|
|
145
|
+
### `@mui/lab@6.0.0-alpha.1`
|
|
146
|
+
|
|
147
|
+
- [TabPanel] Add keepMounted prop to match Joy UI (#41651) @ppaskaris-plooto
|
|
148
|
+
|
|
149
|
+
### `@mui/joy@5.0.0-beta.34`
|
|
150
|
+
|
|
151
|
+
- Add `spacing` theme token (#40224) @siriwatknp
|
|
152
|
+
|
|
153
|
+
### `@pigment-css/react@0.0.5`
|
|
154
|
+
|
|
155
|
+
- Improve sx prop support (#41589) @brijeshb42
|
|
156
|
+
- Fix Emotion styled error (#41699) @siriwatknp
|
|
157
|
+
- Fix propTypes removal during eval stage (#41695) @brijeshb42
|
|
158
|
+
- Fix props forwarding (#41688) @siriwatknp
|
|
159
|
+
- Fix sx prop transformation on Box (#41705) @brijeshb42
|
|
160
|
+
|
|
161
|
+
### `@pigment-css/vite-plugin@0.0.5`
|
|
162
|
+
|
|
163
|
+
- Use constant filename for pigment styles (#41667) @brijeshb42
|
|
164
|
+
|
|
165
|
+
### `@pigment-css/nextjs-plugin@0.0.5`
|
|
166
|
+
|
|
167
|
+
- Add missing RTL implementation (#41751) @brijeshb42
|
|
168
|
+
|
|
169
|
+
### Docs
|
|
170
|
+
|
|
171
|
+
- [pigment-css] Update README.md installation to use the next tag (#41649) @mnajdova
|
|
172
|
+
- [pigment-css] Add "Building design system components" guide with Pigment CSS (#41635) @siriwatknp
|
|
173
|
+
- Continue migration of Base UI to sperate repository @oliviertassinari
|
|
174
|
+
- Stick to one way to write IE 11 @oliviertassinari
|
|
175
|
+
- Fix typo in CONTRIBUTING.md (#41670) @adriancuadrado
|
|
176
|
+
- Drop IE 11 official support (#41611) @iammminzzy
|
|
177
|
+
- [material-ui] Fix typo on the Accordion page (#41687) @connorshea
|
|
178
|
+
- [pigment-css] Add small edits on the README (#41646) @danilo-leal
|
|
179
|
+
- [pigment-css] Edit the example app's README files (#41639) @danilo-leal
|
|
180
|
+
|
|
181
|
+
### Core
|
|
182
|
+
|
|
183
|
+
- [code-infra] Move BrandingProvider/brandingTheme/InfoCard to @mui/docs (#41206) @Janpot
|
|
184
|
+
- [core] Automate cherry-pick of PRs from `next` -> `master` (#41741) @aarongarciah
|
|
185
|
+
- [core] Update the prettier script to use the next branch (#41637) @mnajdova
|
|
186
|
+
- [docs-infra] Skip loading source for non-editable modules (#41588) @bharatkashyap
|
|
187
|
+
- [docs-infra] Vale rule for M3 (#41737) @oliviertassinari
|
|
188
|
+
- [docs-infra] Allows to remove edit button (#41702) @alexfauquette
|
|
189
|
+
- [pigment-css][examples] Add example project with Remix (#41700) @brijeshb42
|
|
190
|
+
- [examples] Update MUI's packages to the next version (#41701) @mnajdova
|
|
191
|
+
- [material-ui] Refine the Sign-in and Sign-up templates (#41192) @zanivan
|
|
192
|
+
- [test] Add test to display options provided to the options prop even if loading is true. (#41675) @ZeeshanTamboli
|
|
193
|
+
- [blog] Refresh the design slightly (#41697) @danilo-leal
|
|
194
|
+
- [website] Use en-US over en-UK for career link @oliviertassinari
|
|
195
|
+
- [website] Add Aarón to About Us (#41736) @aarongarciah
|
|
196
|
+
- [website] Refine button design and other details (#41686) @danilo-leal
|
|
197
|
+
- [website] Improve job og image (#41672) @oliviertassinari
|
|
198
|
+
- [website] Page <title> should have no dots @oliviertassinari
|
|
199
|
+
|
|
200
|
+
All contributors of this release in alphabetical order: @aarongarciah, @adriancuadrado, @alexfauquette, @bharatkashyap, @brijeshb42, @connorshea, @danilo-leal, @DiegoAndai, @iammminzzy, @Janpot, @JCQuintas, @levigunz, @mnajdova, @oliviertassinari, @ppaskaris-plooto, @siriwatknp, @skmanoj322, @zanivan, @ZeeshanTamboli
|
|
201
|
+
|
|
3
202
|
## v6.0.0-alpha.0
|
|
4
203
|
|
|
5
204
|
<!-- generated comparing v5.15.14..next -->
|
|
@@ -79,6 +278,46 @@ A big thanks to the 18 contributors who made this release possible. Here are som
|
|
|
79
278
|
|
|
80
279
|
All contributors of this release in alphabetical order: @aacevski, @brijeshb42, @cherniavskii, @cipherlogs, @danilo-leal, @DiegoAndai, @harry-whorlow, @Janpot, @joserodolfofreitas, @michael-land, @michaldudak, @mnajdova, @nekoya, @sai6855, @siriwatknp, @StylesTrip, @zanivan, @ZeeshanTamboli
|
|
81
280
|
|
|
281
|
+
## v5.15.15
|
|
282
|
+
|
|
283
|
+
<!-- generated comparing v5.15.14..master -->
|
|
284
|
+
|
|
285
|
+
_Apr 4, 2024_
|
|
286
|
+
|
|
287
|
+
A big thanks to the 7 contributors who made this release possible. Here are some highlights ✨:
|
|
288
|
+
This release was mostly about 🐛 bug fixes and 📚 documentation improvements.
|
|
289
|
+
|
|
290
|
+
### `@mui/material@5.15.15`
|
|
291
|
+
|
|
292
|
+
- [Autocomplete] Display options provided to the `options` prop even if loading is true (#41677) @ZeeshanTamboli
|
|
293
|
+
- [RadioGroup] Apply classnames (#41681) @ZeeshanTamboli
|
|
294
|
+
|
|
295
|
+
### `@mui/system@5.15.15`
|
|
296
|
+
|
|
297
|
+
- Fix typo to avoid infinite recursion in function call (#41678) @ZeeshanTamboli
|
|
298
|
+
|
|
299
|
+
### Docs
|
|
300
|
+
|
|
301
|
+
- [material-ui][Slider] Remove `valueLabelFormat` from restricted values demo so that the tooltip thumb label displays the same as the value text (#41679) @ZeeshanTamboli
|
|
302
|
+
- [material-ui] Remove deleted page from the sidenav (#41594) @danilo-leal
|
|
303
|
+
- [material-ui] Fix typo in CSS theme variables customization (#41680) @ZeeshanTamboli
|
|
304
|
+
- Continue migration of Base UI to sperate repository @oliviertassinari
|
|
305
|
+
- Add notification for MUI X v7 blog post (#41587) (#41605) @cherniavskii
|
|
306
|
+
- Update the versions dropdown to show v6 (#41557) @mnajdova
|
|
307
|
+
|
|
308
|
+
### Core
|
|
309
|
+
|
|
310
|
+
- [blog] Link to Romain's blog post in MUI X v7 announcement post (#41641) @cherniavskii
|
|
311
|
+
- [blog] Blog post with MUI X v7.0.0 annoucement (#41563) (#41604) @cherniavskii
|
|
312
|
+
- [blog] Add post about remote (#41565) @danilo-leal
|
|
313
|
+
- [core] Continue rename of Toolpad @oliviertassinari
|
|
314
|
+
- [docs-infra] Add Toolpad product/category IDs to types (#41551) @bharatkashyap
|
|
315
|
+
- [website] Add Aarón to About Us (#41747) @aarongarciah
|
|
316
|
+
- [website] Add stray design adjustments throughout the site (#41642) @mnajdova
|
|
317
|
+
- [website] Update pricing table (#41606) @cherniavskii
|
|
318
|
+
|
|
319
|
+
All contributors of this release in alphabetical order: @aarongarciah, @bharatkashyap, @cherniavskii, @danilo-leal, @mnajdova, @oliviertassinari, @ZeeshanTamboli
|
|
320
|
+
|
|
82
321
|
## v5.15.14
|
|
83
322
|
|
|
84
323
|
<!-- generated comparing v5.15.13..master -->
|
|
@@ -893,7 +1132,7 @@ A big thanks to the 22 contributors who made this release possible. Here are som
|
|
|
893
1132
|
- [material-ui] Revise the Alert demo page (#34892) @samuelsycamore
|
|
894
1133
|
- [material-ui] Revise the Accordion page (#40284) @anle9650
|
|
895
1134
|
- [material-ui] Add docs for complementary Card components (#40346) @anle9650
|
|
896
|
-
- [material-ui] Add Material 3 components page (#40350) @DiegoAndai
|
|
1135
|
+
- [material-ui] Add Material Design 3 components page (#40350) @DiegoAndai
|
|
897
1136
|
- Fix strange italic style @oliviertassinari
|
|
898
1137
|
- Fix references to ESLint @oliviertassinari
|
|
899
1138
|
- Fix 301 redirections @oliviertassinari
|
|
@@ -8001,7 +8240,7 @@ A big thanks to the 25 contributors who made this release possible. Here are som
|
|
|
8001
8240
|
|
|
8002
8241
|
<a href="https://mui.com/components/tables/#unstyled-table"><img width="800" alt="unstyled table" src="https://user-images.githubusercontent.com/4512430/144862194-584356ef-7d9d-462c-a631-186a7e716193.png"></a>
|
|
8003
8242
|
|
|
8004
|
-
You can follow our progress with unstyled components at https://github.com/mui/
|
|
8243
|
+
You can follow our progress with unstyled components at https://github.com/mui/base-ui/issues/10.
|
|
8005
8244
|
|
|
8006
8245
|
- 🎉 We have added an example of how to use MUI with [Remix](https://remix.run/) (#29952) @mnajdova
|
|
8007
8246
|
|
|
@@ -9471,7 +9710,7 @@ A big thanks to the 17 contributors who made this release possible. Here are som
|
|
|
9471
9710
|
|
|
9472
9711
|
<a href="https://mui.com/components/switches/#unstyled"><img width="832" alt="switch" src="https://user-images.githubusercontent.com/3165635/125192249-236f8a80-e247-11eb-9df9-17d476379a32.png"></a>
|
|
9473
9712
|
|
|
9474
|
-
You can follow our progress at https://github.com/mui/
|
|
9713
|
+
You can follow our progress at https://github.com/mui/base-ui/issues/10.
|
|
9475
9714
|
|
|
9476
9715
|
- 💄 We have updated the default `info` `success` `warning` color to be more accessible (#26817) @siriwatknp.
|
|
9477
9716
|
You can find the new [default values](https://mui.com/material-ui/customization/palette/#default-values) in the documentation.
|
|
@@ -13057,7 +13296,7 @@ Here are some highlights ✨:
|
|
|
13057
13296
|
|
|
13058
13297
|
1. `stable` (default, formerly `esm`) which targets a snapshot (on release) of `> 0.5%, last 2 versions, Firefox ESR, not dead, not IE 11"`
|
|
13059
13298
|
2. `node` (formerly default) which targets a snapshot (on release) of `maintained node versions`
|
|
13060
|
-
3. `legacy` (new) which is `stable` +
|
|
13299
|
+
3. `legacy` (new) which is `stable` + IE 11
|
|
13061
13300
|
4. `modern` (formerly `es`) which targets the last 1 version of evergreen browsers and active node (currently that is 14
|
|
13062
13301
|
|
|
13063
13302
|
The change yields a 6% reduction in bundle size 📦 (Babel only).
|
package/index.js
CHANGED
package/modern/index.js
CHANGED
package/node/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/styled-engine",
|
|
3
|
-
"version": "6.0.0-alpha.
|
|
3
|
+
"version": "6.0.0-alpha.3",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "MUI Team",
|
|
6
6
|
"description": "styled() API wrapper package for emotion.",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"url": "https://opencollective.com/mui-org"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@babel/runtime": "^7.
|
|
29
|
+
"@babel/runtime": "^7.24.4",
|
|
30
30
|
"@emotion/cache": "^11.11.0",
|
|
31
31
|
"csstype": "^3.1.3",
|
|
32
32
|
"prop-types": "^15.8.1"
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import * as React from 'react';
|
|
4
|
-
import PropTypes from 'prop-types';
|
|
5
|
-
import { Global } from '@emotion/react';
|
|
6
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
-
function isEmpty(obj) {
|
|
8
|
-
return obj === undefined || obj === null || Object.keys(obj).length === 0;
|
|
9
|
-
}
|
|
10
|
-
export default function GlobalStyles(props) {
|
|
11
|
-
var styles = props.styles,
|
|
12
|
-
_props$defaultTheme = props.defaultTheme,
|
|
13
|
-
defaultTheme = _props$defaultTheme === void 0 ? {} : _props$defaultTheme;
|
|
14
|
-
var globalStyles = typeof styles === 'function' ? function (themeInput) {
|
|
15
|
-
return styles(isEmpty(themeInput) ? defaultTheme : themeInput);
|
|
16
|
-
} : styles;
|
|
17
|
-
return /*#__PURE__*/_jsx(Global, {
|
|
18
|
-
styles: globalStyles
|
|
19
|
-
});
|
|
20
|
-
}
|
|
21
|
-
process.env.NODE_ENV !== "production" ? GlobalStyles.propTypes = {
|
|
22
|
-
defaultTheme: PropTypes.object,
|
|
23
|
-
styles: PropTypes.oneOfType([PropTypes.array, PropTypes.string, PropTypes.object, PropTypes.func])
|
|
24
|
-
} : void 0;
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import _typeof from "@babel/runtime/helpers/esm/typeof";
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import PropTypes from 'prop-types';
|
|
6
|
-
import { CacheProvider } from '@emotion/react';
|
|
7
|
-
import createCache from '@emotion/cache';
|
|
8
|
-
|
|
9
|
-
// prepend: true moves MUI styles to the top of the <head> so they're loaded first.
|
|
10
|
-
// It allows developers to easily override MUI styles with other styling solutions, like CSS modules.
|
|
11
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
|
-
var cache;
|
|
13
|
-
if ((typeof document === "undefined" ? "undefined" : _typeof(document)) === 'object') {
|
|
14
|
-
cache = createCache({
|
|
15
|
-
key: 'css',
|
|
16
|
-
prepend: true
|
|
17
|
-
});
|
|
18
|
-
}
|
|
19
|
-
export default function StyledEngineProvider(props) {
|
|
20
|
-
var injectFirst = props.injectFirst,
|
|
21
|
-
children = props.children;
|
|
22
|
-
return injectFirst && cache ? /*#__PURE__*/_jsx(CacheProvider, {
|
|
23
|
-
value: cache,
|
|
24
|
-
children: children
|
|
25
|
-
}) : children;
|
|
26
|
-
}
|
|
27
|
-
process.env.NODE_ENV !== "production" ? StyledEngineProvider.propTypes = {
|
|
28
|
-
/**
|
|
29
|
-
* Your component tree.
|
|
30
|
-
*/
|
|
31
|
-
children: PropTypes.node,
|
|
32
|
-
/**
|
|
33
|
-
* By default, the styles are injected last in the <head> element of the page.
|
|
34
|
-
* As a result, they gain more specificity than any other style sheet.
|
|
35
|
-
* If you want to override MUI's styles, set this prop.
|
|
36
|
-
*/
|
|
37
|
-
injectFirst: PropTypes.bool
|
|
38
|
-
} : void 0;
|
package/legacy/index.js
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @mui/styled-engine v6.0.0-alpha.0
|
|
3
|
-
*
|
|
4
|
-
* @license MIT
|
|
5
|
-
* This source code is licensed under the MIT license found in the
|
|
6
|
-
* LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/
|
|
8
|
-
'use client';
|
|
9
|
-
|
|
10
|
-
/* eslint-disable no-underscore-dangle */
|
|
11
|
-
import emStyled from '@emotion/styled';
|
|
12
|
-
export default function styled(tag, options) {
|
|
13
|
-
var stylesFactory = emStyled(tag, options);
|
|
14
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
15
|
-
return function () {
|
|
16
|
-
var component = typeof tag === 'string' ? "\"".concat(tag, "\"") : 'component';
|
|
17
|
-
for (var _len = arguments.length, styles = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
18
|
-
styles[_key] = arguments[_key];
|
|
19
|
-
}
|
|
20
|
-
if (styles.length === 0) {
|
|
21
|
-
console.error(["MUI: Seems like you called `styled(".concat(component, ")()` without a `style` argument."), 'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join('\n'));
|
|
22
|
-
} else if (styles.some(function (style) {
|
|
23
|
-
return style === undefined;
|
|
24
|
-
})) {
|
|
25
|
-
console.error("MUI: the styled(".concat(component, ")(...args) API requires all its args to be defined."));
|
|
26
|
-
}
|
|
27
|
-
return stylesFactory.apply(void 0, styles);
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
return stylesFactory;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
34
|
-
export var internal_processStyles = function internal_processStyles(tag, processor) {
|
|
35
|
-
// Emotion attaches all the styles as `__emotion_styles`.
|
|
36
|
-
// Ref: https://github.com/emotion-js/emotion/blob/16d971d0da229596d6bcc39d282ba9753c9ee7cf/packages/styled/src/base.js#L186
|
|
37
|
-
if (Array.isArray(tag.__emotion_styles)) {
|
|
38
|
-
tag.__emotion_styles = processor(tag.__emotion_styles);
|
|
39
|
-
}
|
|
40
|
-
};
|
|
41
|
-
export { ThemeContext, keyframes, css } from '@emotion/react';
|
|
42
|
-
export { default as StyledEngineProvider } from './StyledEngineProvider';
|
|
43
|
-
export { default as GlobalStyles } from './GlobalStyles';
|