@mui/codemod 6.0.0-alpha.9 → 6.0.0-beta.0
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/README.md +423 -168
- package/codemod.js +0 -2
- package/node/deprecations/all/deprecations-all.js +34 -26
- package/node/deprecations/all/postcss.config.js +7 -1
- package/node/deprecations/autocomplete-props/autocomplete-props.js +0 -32
- package/node/deprecations/autocomplete-props/test-cases/actual.js +13 -35
- package/node/deprecations/autocomplete-props/test-cases/expected.js +13 -41
- package/node/deprecations/autocomplete-props/test-cases/theme.actual.js +0 -18
- package/node/deprecations/autocomplete-props/test-cases/theme.expected.js +0 -22
- package/node/deprecations/backdrop-props/backdrop-props.js +3 -5
- package/node/deprecations/backdrop-props/test-cases/actual.js +30 -14
- package/node/deprecations/backdrop-props/test-cases/expected.js +23 -13
- package/node/deprecations/backdrop-props/test-cases/theme.actual.js +32 -6
- package/node/deprecations/backdrop-props/test-cases/theme.expected.js +27 -5
- package/node/deprecations/filled-input-props/filled-input-props.js +22 -0
- package/node/deprecations/filled-input-props/index.js +13 -0
- package/node/deprecations/filled-input-props/test-cases/actual.js +60 -0
- package/node/deprecations/filled-input-props/test-cases/expected.js +52 -0
- package/node/deprecations/filled-input-props/test-cases/theme.actual.js +73 -0
- package/node/deprecations/filled-input-props/test-cases/theme.expected.js +65 -0
- package/node/deprecations/input-base-props/index.js +13 -0
- package/node/deprecations/input-base-props/input-base-props.js +22 -0
- package/node/deprecations/input-base-props/test-cases/actual.js +60 -0
- package/node/deprecations/input-base-props/test-cases/expected.js +52 -0
- package/node/deprecations/input-base-props/test-cases/theme.actual.js +73 -0
- package/node/deprecations/input-base-props/test-cases/theme.expected.js +65 -0
- package/node/deprecations/input-props/index.js +13 -0
- package/node/deprecations/input-props/input-props.js +22 -0
- package/node/deprecations/input-props/test-cases/actual.js +60 -0
- package/node/deprecations/input-props/test-cases/expected.js +52 -0
- package/node/deprecations/input-props/test-cases/theme.actual.js +73 -0
- package/node/deprecations/input-props/test-cases/theme.expected.js +65 -0
- package/node/deprecations/modal-props/index.js +13 -0
- package/node/deprecations/modal-props/modal-props.js +22 -0
- package/node/deprecations/modal-props/test-cases/actual.js +43 -0
- package/node/deprecations/modal-props/test-cases/expected.js +40 -0
- package/node/deprecations/modal-props/test-cases/theme.actual.js +56 -0
- package/node/deprecations/modal-props/test-cases/theme.expected.js +53 -0
- package/node/deprecations/outlined-input-props/index.js +13 -0
- package/node/deprecations/outlined-input-props/outlined-input-props.js +22 -0
- package/node/deprecations/outlined-input-props/test-cases/actual.js +60 -0
- package/node/deprecations/outlined-input-props/test-cases/expected.js +52 -0
- package/node/deprecations/outlined-input-props/test-cases/theme.actual.js +73 -0
- package/node/deprecations/outlined-input-props/test-cases/theme.expected.js +65 -0
- package/node/deprecations/step-label-props/step-label-props.js +0 -14
- package/node/deprecations/step-label-props/test-cases/actual.js +0 -23
- package/node/deprecations/step-label-props/test-cases/expected.js +0 -27
- package/node/deprecations/step-label-props/test-cases/theme.actual.js +0 -22
- package/node/deprecations/step-label-props/test-cases/theme.expected.js +0 -28
- package/node/deprecations/tab-classes/index.js +13 -0
- package/node/deprecations/tab-classes/postcss-plugin.js +30 -0
- package/node/deprecations/tab-classes/postcss.config.js +8 -0
- package/node/deprecations/tab-classes/tab-classes.js +53 -0
- package/node/deprecations/tab-classes/test-cases/actual.js +5 -0
- package/node/deprecations/tab-classes/test-cases/expected.js +5 -0
- package/node/deprecations/table-sort-label-classes/index.js +13 -0
- package/node/deprecations/table-sort-label-classes/postcss-plugin.js +33 -0
- package/node/deprecations/table-sort-label-classes/postcss.config.js +8 -0
- package/node/deprecations/table-sort-label-classes/table-sort-label-classes.js +77 -0
- package/node/deprecations/table-sort-label-classes/test-cases/actual.js +7 -0
- package/node/deprecations/table-sort-label-classes/test-cases/expected.js +7 -0
- package/node/util/migrateToVariants.js +91 -43
- package/node/v5.0.0/theme-spacing.test/large-actual.js +1 -1
- package/node/v5.0.0/theme-spacing.test/large-expected.js +1 -1
- package/node/v6.0.0/grid-v2-props/grid-v2-props.js +149 -0
- package/node/v6.0.0/grid-v2-props/index.js +13 -0
- package/node/v6.0.0/grid-v2-props/test-cases/actual.js +85 -0
- package/node/v6.0.0/grid-v2-props/test-cases/custom-breakpoints.actual.js +18 -0
- package/node/v6.0.0/grid-v2-props/test-cases/custom-breakpoints.expected.js +22 -0
- package/node/v6.0.0/grid-v2-props/test-cases/expected.js +97 -0
- package/node/v6.0.0/styled/test-cases/ConditionalStyled.expected.js +9 -22
- package/node/v6.0.0/styled/test-cases/DynamicPropsStyled.actual.js +39 -0
- package/node/v6.0.0/styled/test-cases/DynamicPropsStyled.expected.js +65 -0
- package/node/v6.0.0/styled/test-cases/LogicalStyled.actual.js +31 -1
- package/node/v6.0.0/styled/test-cases/LogicalStyled.expected.js +39 -1
- package/node/v6.0.0/styled/test-cases/NestedSpread.expected.js +11 -13
- package/node/v6.0.0/sx-prop/sx-v6.js +80 -30
- package/node/v6.0.0/sx-prop/test-cases/sx-css-vars.actual.js +14 -0
- package/node/v6.0.0/sx-prop/test-cases/sx-css-vars.expected.js +33 -16
- package/node/v6.0.0/sx-prop/test-cases/sx-dynamic.actual.js +21 -1
- package/node/v6.0.0/sx-prop/test-cases/sx-dynamic.expected.js +19 -1
- package/node/v6.0.0/sx-prop/test-cases/sx-line-break.actual.js +69 -0
- package/node/v6.0.0/sx-prop/test-cases/sx-line-break.expected.js +69 -0
- package/node/v6.0.0/sx-prop/test-cases/sx-value-callback.actual.js +102 -0
- package/node/v6.0.0/sx-prop/test-cases/sx-value-callback.expected.js +111 -0
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -106,7 +106,7 @@ JS transforms:
|
|
|
106
106
|
- [`& .${accordionSummaryClasses.contentGutters}`]: {
|
|
107
107
|
+ [`&.${accordionSummaryClasses.gutters} .${accordionSummaryClasses.content}`]: {
|
|
108
108
|
color: 'red',
|
|
109
|
-
|
|
109
|
+
},
|
|
110
110
|
},
|
|
111
111
|
},
|
|
112
112
|
},
|
|
@@ -119,7 +119,7 @@ JS transforms:
|
|
|
119
119
|
- '& .MuiAccordionSummary-contentGutters': {
|
|
120
120
|
+ '&.MuiAccordionSummary-gutters .MuiAccordionSummary-content': {
|
|
121
121
|
color: 'red',
|
|
122
|
-
|
|
122
|
+
},
|
|
123
123
|
},
|
|
124
124
|
},
|
|
125
125
|
},
|
|
@@ -130,7 +130,6 @@ CSS transforms:
|
|
|
130
130
|
```diff
|
|
131
131
|
-.MuiAccordionSummary-root .MuiAccordionSummary-contentGutters
|
|
132
132
|
+.MuiAccordionSummary-root.MuiAccordionSummary-gutters .MuiAccordionSummary-content
|
|
133
|
-
/>
|
|
134
133
|
```
|
|
135
134
|
|
|
136
135
|
```bash
|
|
@@ -150,51 +149,51 @@ JS transforms:
|
|
|
150
149
|
- [`&.${alertClasses.standardSuccess}`]: {
|
|
151
150
|
+ [`&.${alertClasses.standard}.${alertClasses.colorSuccess}`]: {
|
|
152
151
|
color: 'red',
|
|
153
|
-
|
|
152
|
+
},
|
|
154
153
|
- [`&.${alertClasses.standardInfo}`]: {
|
|
155
154
|
+ [`&.${alertClasses.standard}.${alertClasses.colorInfo}`]: {
|
|
156
155
|
color: 'red',
|
|
157
|
-
|
|
156
|
+
},
|
|
158
157
|
- [`&.${alertClasses.standardWarning}`]: {
|
|
159
158
|
+ [`&.${alertClasses.standard}.${alertClasses.colorWarning}`]: {
|
|
160
159
|
color: 'red',
|
|
161
|
-
|
|
160
|
+
},
|
|
162
161
|
- [`&.${alertClasses.standardError}`]: {
|
|
163
162
|
+ [`&.${alertClasses.standard}.${alertClasses.colorError}`]: {
|
|
164
163
|
color: 'red',
|
|
165
|
-
|
|
164
|
+
},
|
|
166
165
|
- [`&.${alertClasses.outlinedSuccess}`]: {
|
|
167
166
|
+ [`&.${alertClasses.outlined}.${alertClasses.colorSuccess}`]: {
|
|
168
167
|
color: 'red',
|
|
169
|
-
|
|
168
|
+
},
|
|
170
169
|
- [`&.${alertClasses.outlinedInfo}`]: {
|
|
171
170
|
+ [`&.${alertClasses.outlined}.${alertClasses.colorInfo}`]: {
|
|
172
171
|
color: 'red',
|
|
173
|
-
|
|
172
|
+
},
|
|
174
173
|
- [`&.${alertClasses.outlinedWarning}`]: {
|
|
175
174
|
+ [`&.${alertClasses.outlined}.${alertClasses.colorWarning}`]: {
|
|
176
175
|
color: 'red',
|
|
177
|
-
|
|
176
|
+
},
|
|
178
177
|
- [`&.${alertClasses.outlinedError}`]: {
|
|
179
178
|
+ [`&.${alertClasses.outlined}.${alertClasses.colorError}`]: {
|
|
180
179
|
color: 'red',
|
|
181
|
-
|
|
180
|
+
},
|
|
182
181
|
- [`&.${alertClasses.filledSuccess}`]: {
|
|
183
182
|
+ [`&.${alertClasses.filled}.${alertClasses.colorSuccess}`]: {
|
|
184
183
|
color: 'red',
|
|
185
|
-
|
|
184
|
+
},
|
|
186
185
|
- [`&.${alertClasses.filledInfo}`]: {
|
|
187
186
|
+ [`&.${alertClasses.filled}.${alertClasses.colorInfo}`]: {
|
|
188
187
|
color: 'red',
|
|
189
|
-
|
|
188
|
+
},
|
|
190
189
|
- [`&.${alertClasses.filledWarning}`]: {
|
|
191
190
|
+ [`&.${alertClasses.filled}.${alertClasses.colorWarning}`]: {
|
|
192
191
|
color: 'red',
|
|
193
|
-
|
|
192
|
+
},
|
|
194
193
|
- [`&.${alertClasses.filledError}`]: {
|
|
195
194
|
+ [`&.${alertClasses.filled}.${alertClasses.colorError}`]: {
|
|
196
195
|
color: 'red',
|
|
197
|
-
|
|
196
|
+
},
|
|
198
197
|
},
|
|
199
198
|
},
|
|
200
199
|
},
|
|
@@ -238,8 +237,8 @@ npx @mui/codemod@next deprecations/alert-classes <path>
|
|
|
238
237
|
```diff
|
|
239
238
|
<Alert
|
|
240
239
|
- components={{ CloseButton: CustomButton }}
|
|
241
|
-
+ slots={{ closeButton: CustomButton }}
|
|
242
240
|
- componentsProps={{ closeButton: { testid: 'test-id' } }}
|
|
241
|
+
+ slots={{ closeButton: CustomButton }}
|
|
243
242
|
+ slotProps={{ closeButton: { testid: 'test-id' } }}
|
|
244
243
|
/>
|
|
245
244
|
```
|
|
@@ -248,10 +247,10 @@ npx @mui/codemod@next deprecations/alert-classes <path>
|
|
|
248
247
|
MuiAlert: {
|
|
249
248
|
defaultProps: {
|
|
250
249
|
- components: { CloseButton: CustomButton }
|
|
251
|
-
+ slots: { closeButton: CustomButton },
|
|
252
250
|
- componentsProps: { closeButton: { testid: 'test-id' }}
|
|
251
|
+
+ slots: { closeButton: CustomButton },
|
|
253
252
|
+ slotProps: { closeButton: { testid: 'test-id' } },
|
|
254
|
-
|
|
253
|
+
},
|
|
255
254
|
},
|
|
256
255
|
```
|
|
257
256
|
|
|
@@ -330,29 +329,29 @@ npx @mui/codemod@next deprecations/autocomplete-props <path>
|
|
|
330
329
|
```diff
|
|
331
330
|
<AvatarGroup
|
|
332
331
|
- componentsProps={{
|
|
333
|
-
- additionalAvatar: {color:
|
|
332
|
+
- additionalAvatar: { color: 'red' },
|
|
334
333
|
+ slotProps={{
|
|
335
|
-
+ surplus: {color:
|
|
334
|
+
+ surplus: { color: 'red' },
|
|
336
335
|
}}
|
|
337
|
-
|
|
336
|
+
/>
|
|
338
337
|
```
|
|
339
338
|
|
|
340
339
|
```diff
|
|
341
340
|
<AvatarGroup
|
|
342
341
|
slotProps={{
|
|
343
|
-
- additionalAvatar: {color:
|
|
344
|
-
+ surplus: {color:
|
|
342
|
+
- additionalAvatar: { color: 'red' },
|
|
343
|
+
+ surplus: { color: 'red' },
|
|
345
344
|
}}
|
|
346
|
-
|
|
345
|
+
/>
|
|
347
346
|
```
|
|
348
347
|
|
|
349
348
|
```diff
|
|
350
349
|
MuiAvatarGroup: {
|
|
351
350
|
defaultProps: {
|
|
352
351
|
- componentsProps: {
|
|
353
|
-
- additionalAvatar: {color:
|
|
352
|
+
- additionalAvatar: { color: 'red' },
|
|
354
353
|
+ slotProps: {
|
|
355
|
-
+ surplus: {color:
|
|
354
|
+
+ surplus: { color: 'red' },
|
|
356
355
|
},
|
|
357
356
|
},
|
|
358
357
|
},
|
|
@@ -362,8 +361,8 @@ npx @mui/codemod@next deprecations/autocomplete-props <path>
|
|
|
362
361
|
MuiAvatarGroup: {
|
|
363
362
|
defaultProps: {
|
|
364
363
|
slotProps: {
|
|
365
|
-
- additionalAvatar: {color:
|
|
366
|
-
+ surplus: {color:
|
|
364
|
+
- additionalAvatar: { color: 'red' },
|
|
365
|
+
+ surplus: { color: 'red' },
|
|
367
366
|
},
|
|
368
367
|
},
|
|
369
368
|
},
|
|
@@ -384,17 +383,37 @@ npx @mui/codemod@next deprecations/avatar-group-props <path>
|
|
|
384
383
|
+ img: {
|
|
385
384
|
+ onError: () => {},
|
|
386
385
|
+ onLoad: () => {},
|
|
387
|
-
+ }
|
|
386
|
+
+ },
|
|
388
387
|
}}
|
|
389
|
-
|
|
388
|
+
/>
|
|
390
389
|
```
|
|
391
390
|
|
|
392
391
|
#### `backdrop-props`
|
|
393
392
|
|
|
394
393
|
```diff
|
|
395
394
|
<Backdrop
|
|
396
|
-
-
|
|
397
|
-
|
|
395
|
+
- components={{ Root: CustomRoot }}
|
|
396
|
+
- componentsProps={{ root: { testid: 'test-id' } }}
|
|
397
|
+
+ slots={{ root: CustomRoot }}
|
|
398
|
+
+ slotProps={{ root: { testid: 'test-id' } }}
|
|
399
|
+
/>
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
```diff
|
|
403
|
+
MuiBackdrop: {
|
|
404
|
+
defaultProps: {
|
|
405
|
+
- components: { Root: CustomRoot }
|
|
406
|
+
- componentsProps: { root: { testid: 'root-id' } }
|
|
407
|
+
+ slots: { root: CustomRoot },
|
|
408
|
+
+ slotProps: { root: { testid: 'root-id' } },
|
|
409
|
+
},
|
|
410
|
+
},
|
|
411
|
+
```
|
|
412
|
+
|
|
413
|
+
```diff
|
|
414
|
+
<Backdrop
|
|
415
|
+
- TransitionComponent={CustomTransition}
|
|
416
|
+
+ slots={{ transition: CustomTransition }}
|
|
398
417
|
/>
|
|
399
418
|
```
|
|
400
419
|
|
|
@@ -407,8 +426,8 @@ npx @mui/codemod@next deprecations/backdrop-props <path>
|
|
|
407
426
|
```diff
|
|
408
427
|
<Badge
|
|
409
428
|
- components={{ Root: CustomRoot }}
|
|
410
|
-
+ slots={{ root: CustomRoot }}
|
|
411
429
|
- componentsProps={{ root: { testid: 'test-id' } }}
|
|
430
|
+
+ slots={{ root: CustomRoot }}
|
|
412
431
|
+ slotProps={{ root: { testid: 'test-id' } }}
|
|
413
432
|
/>
|
|
414
433
|
```
|
|
@@ -417,8 +436,8 @@ npx @mui/codemod@next deprecations/backdrop-props <path>
|
|
|
417
436
|
MuiBadge: {
|
|
418
437
|
defaultProps: {
|
|
419
438
|
- components: { Root: CustomRoot }
|
|
420
|
-
+ slots: { root: CustomRoot },
|
|
421
439
|
- componentsProps: { root: { testid: 'test-id' }}
|
|
440
|
+
+ slots: { root: CustomRoot },
|
|
422
441
|
+ slotProps: { root: { testid: 'test-id' } },
|
|
423
442
|
},
|
|
424
443
|
},
|
|
@@ -441,135 +460,135 @@ JS transforms:
|
|
|
441
460
|
- [`&.${buttonClasses.textInherit}`]: {
|
|
442
461
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorInherit}`]: {
|
|
443
462
|
color: 'red',
|
|
444
|
-
|
|
463
|
+
},
|
|
445
464
|
- [`&.${buttonClasses.textPrimary}`]: {
|
|
446
465
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorPrimary}`]: {
|
|
447
466
|
color: 'red',
|
|
448
|
-
|
|
467
|
+
},
|
|
449
468
|
- [`&.${buttonClasses.textSecondary}`]: {
|
|
450
469
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorSecondary}`]: {
|
|
451
470
|
color: 'red',
|
|
452
|
-
|
|
471
|
+
},
|
|
453
472
|
- [`&.${buttonClasses.textSuccess}`]: {
|
|
454
473
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorSuccess}`]: {
|
|
455
474
|
color: 'red',
|
|
456
|
-
|
|
475
|
+
},
|
|
457
476
|
- [`&.${buttonClasses.textError}`]: {
|
|
458
477
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorError}`]: {
|
|
459
478
|
color: 'red',
|
|
460
|
-
|
|
479
|
+
},
|
|
461
480
|
- [`&.${buttonClasses.textInfo}`]: {
|
|
462
481
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorInfo}`]: {
|
|
463
482
|
color: 'red',
|
|
464
|
-
|
|
483
|
+
},
|
|
465
484
|
- [`&.${buttonClasses.textWarning}`]: {
|
|
466
485
|
+ [`&.${buttonClasses.text}.${buttonClasses.colorWarning}`]: {
|
|
467
486
|
color: 'red',
|
|
468
|
-
|
|
487
|
+
},
|
|
469
488
|
- [`&.${buttonClasses.outlinedInherit}`]: {
|
|
470
489
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorInherit}`]: {
|
|
471
490
|
color: 'red',
|
|
472
|
-
|
|
491
|
+
},
|
|
473
492
|
- [`&.${buttonClasses.outlinedPrimary}`]: {
|
|
474
493
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorPrimary}`]: {
|
|
475
494
|
color: 'red',
|
|
476
|
-
|
|
495
|
+
},
|
|
477
496
|
- [`&.${buttonClasses.outlinedSecondary}`]: {
|
|
478
497
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorSecondary}`]: {
|
|
479
498
|
color: 'red',
|
|
480
|
-
|
|
499
|
+
},
|
|
481
500
|
- [`&.${buttonClasses.outlinedSuccess}`]: {
|
|
482
501
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorSuccess}`]: {
|
|
483
502
|
color: 'red',
|
|
484
|
-
|
|
503
|
+
},
|
|
485
504
|
- [`&.${buttonClasses.outlinedError}`]: {
|
|
486
505
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorError}`]: {
|
|
487
506
|
color: 'red',
|
|
488
|
-
|
|
507
|
+
},
|
|
489
508
|
- [`&.${buttonClasses.outlinedInfo}`]: {
|
|
490
509
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorInfo}`]: {
|
|
491
510
|
color: 'red',
|
|
492
|
-
|
|
511
|
+
},
|
|
493
512
|
- [`&.${buttonClasses.outlinedWarning}`]: {
|
|
494
513
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.colorWarning}`]: {
|
|
495
514
|
color: 'red',
|
|
496
|
-
|
|
515
|
+
},
|
|
497
516
|
- [`&.${buttonClasses.containedInherit}`]: {
|
|
498
517
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorInherit}`]: {
|
|
499
518
|
color: 'red',
|
|
500
|
-
|
|
519
|
+
},
|
|
501
520
|
- [`&.${buttonClasses.containedPrimary}`]: {
|
|
502
521
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorPrimary}`]: {
|
|
503
522
|
color: 'red',
|
|
504
|
-
|
|
523
|
+
},
|
|
505
524
|
- [`&.${buttonClasses.containedSecondary}`]: {
|
|
506
525
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorSecondary}`]: {
|
|
507
526
|
color: 'red',
|
|
508
|
-
|
|
527
|
+
},
|
|
509
528
|
- [`&.${buttonClasses.containedSuccess}`]: {
|
|
510
529
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorSuccess}`]: {
|
|
511
530
|
color: 'red',
|
|
512
|
-
|
|
531
|
+
},
|
|
513
532
|
- [`&.${buttonClasses.containedError}`]: {
|
|
514
533
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorError}`]: {
|
|
515
534
|
color: 'red',
|
|
516
|
-
|
|
535
|
+
},
|
|
517
536
|
- [`&.${buttonClasses.containedInfo}`]: {
|
|
518
537
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorInfo}`]: {
|
|
519
538
|
color: 'red',
|
|
520
|
-
|
|
539
|
+
},
|
|
521
540
|
- [`&.${buttonClasses.containedWarning}`]: {
|
|
522
541
|
+ [`&.${buttonClasses.contained}.${buttonClasses.colorWarning}`]: {
|
|
523
542
|
color: 'red',
|
|
524
|
-
|
|
543
|
+
},
|
|
525
544
|
- [`&.${buttonClasses.containedSizeSmall}`]: {
|
|
526
545
|
+ [`&.${buttonClasses.contained}.${buttonClasses.sizeSmall}`]: {
|
|
527
546
|
color: 'red',
|
|
528
|
-
|
|
547
|
+
},
|
|
529
548
|
- [`&.${buttonClasses.containedSizeMedium}`]: {
|
|
530
549
|
+ [`&.${buttonClasses.contained}.${buttonClasses.sizeMedium}`]: {
|
|
531
550
|
color: 'red',
|
|
532
|
-
|
|
551
|
+
},
|
|
533
552
|
- [`&.${buttonClasses.containedSizeLarge}`]: {
|
|
534
553
|
+ [`&.${buttonClasses.contained}.${buttonClasses.sizeLarge}`]: {
|
|
535
554
|
color: 'red',
|
|
536
|
-
|
|
555
|
+
},
|
|
537
556
|
- [`&.${buttonClasses.textSizeSmall}`]: {
|
|
538
557
|
+ [`&.${buttonClasses.text}.${buttonClasses.sizeSmall}`]: {
|
|
539
558
|
color: 'red',
|
|
540
|
-
|
|
559
|
+
},
|
|
541
560
|
- [`&.${buttonClasses.textSizeMedium}`]: {
|
|
542
561
|
+ [`&.${buttonClasses.text}.${buttonClasses.sizeMedium}`]: {
|
|
543
562
|
color: 'red',
|
|
544
|
-
|
|
563
|
+
},
|
|
545
564
|
- [`&.${buttonClasses.textSizeLarge}`]: {
|
|
546
565
|
+ [`&.${buttonClasses.text}.${buttonClasses.sizeLarge}`]: {
|
|
547
566
|
color: 'red',
|
|
548
|
-
|
|
567
|
+
},
|
|
549
568
|
- [`&.${buttonClasses.outlinedSizeSmall}`]: {
|
|
550
569
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.sizeSmall}`]: {
|
|
551
570
|
color: 'red',
|
|
552
|
-
|
|
571
|
+
},
|
|
553
572
|
- [`&.${buttonClasses.outlinedSizeMedium}`]: {
|
|
554
573
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.sizeMedium}`]: {
|
|
555
574
|
color: 'red',
|
|
556
|
-
|
|
575
|
+
},
|
|
557
576
|
- [`&.${buttonClasses.outlinedSizeLarge}`]: {
|
|
558
577
|
+ [`&.${buttonClasses.outlined}.${buttonClasses.sizeLarge}`]: {
|
|
559
578
|
color: 'red',
|
|
560
|
-
|
|
579
|
+
},
|
|
561
580
|
- [`& .${buttonClasses.iconSizeSmall}`]: {
|
|
562
581
|
+ [`&.${buttonClasses.sizeSmall} > .${buttonClasses.icon}`]: {
|
|
563
582
|
color: 'red',
|
|
564
|
-
|
|
583
|
+
},
|
|
565
584
|
- [`& .${buttonClasses.iconSizeMedium}`]: {
|
|
566
585
|
+ [`&.${buttonClasses.sizeMedium} > .${buttonClasses.icon}`]: {
|
|
567
586
|
color: 'red',
|
|
568
|
-
|
|
587
|
+
},
|
|
569
588
|
- [`& .${buttonClasses.iconSizeLarge}`]: {
|
|
570
589
|
+ [`&.${buttonClasses.sizeLarge} > .${buttonClasses.icon}`]: {
|
|
571
590
|
color: 'red',
|
|
572
|
-
|
|
591
|
+
},
|
|
573
592
|
},
|
|
574
593
|
},
|
|
575
594
|
},
|
|
@@ -644,7 +663,6 @@ CSS transforms:
|
|
|
644
663
|
+.MuiButton-root.MuiButton-sizeMedium > .MuiButton-icon
|
|
645
664
|
-.MuiButton-root .MuiButton-iconSizeLarge
|
|
646
665
|
+.MuiButton-root.MuiButton-sizeLarge > .MuiButton-icon
|
|
647
|
-
/>
|
|
648
666
|
```
|
|
649
667
|
|
|
650
668
|
```bash
|
|
@@ -664,71 +682,71 @@ JS transforms:
|
|
|
664
682
|
- [`& .${buttonGroupClasses.groupedHorizontal}`]: {
|
|
665
683
|
+ [`&.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
666
684
|
color: 'red',
|
|
667
|
-
|
|
685
|
+
},
|
|
668
686
|
- [`& .${buttonGroupClasses.groupedVertical}`]: {
|
|
669
687
|
+ [`&.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
670
688
|
color: 'red',
|
|
671
|
-
|
|
689
|
+
},
|
|
672
690
|
- [`& .${buttonGroupClasses.groupedText}`]: {
|
|
673
691
|
+ [`&.${buttonGroupClasses.text} > .${buttonGroupClasses.grouped}`]: {
|
|
674
692
|
color: 'red',
|
|
675
|
-
|
|
693
|
+
},
|
|
676
694
|
- [`& .${buttonGroupClasses.groupedTextHorizontal}`]: {
|
|
677
695
|
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
678
696
|
color: 'red',
|
|
679
|
-
|
|
697
|
+
},
|
|
680
698
|
- [`& .${buttonGroupClasses.groupedTextVertical}`]: {
|
|
681
699
|
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
682
700
|
color: 'red',
|
|
683
|
-
|
|
701
|
+
},
|
|
684
702
|
- [`& .${buttonGroupClasses.groupedTextPrimary}`]: {
|
|
685
703
|
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
686
704
|
color: 'red',
|
|
687
|
-
|
|
705
|
+
},
|
|
688
706
|
- [`& .${buttonGroupClasses.groupedTextSecondary}`]: {
|
|
689
707
|
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
690
708
|
color: 'red',
|
|
691
|
-
|
|
709
|
+
},
|
|
692
710
|
- [`& .${buttonGroupClasses.groupedOutlined}`]: {
|
|
693
711
|
+ [`&.${buttonGroupClasses.outlined} > .${buttonGroupClasses.grouped}`]: {
|
|
694
712
|
color: 'red',
|
|
695
|
-
|
|
713
|
+
},
|
|
696
714
|
- [`& .${buttonGroupClasses.groupedOutlinedHorizontal}`]: {
|
|
697
715
|
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
698
716
|
color: 'red',
|
|
699
|
-
|
|
717
|
+
},
|
|
700
718
|
- [`& .${buttonGroupClasses.groupedOutlinedVertical}`]: {
|
|
701
719
|
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
702
720
|
color: 'red',
|
|
703
|
-
|
|
721
|
+
},
|
|
704
722
|
- [`& .${buttonGroupClasses.groupedOutlinedPrimary}`]: {
|
|
705
723
|
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
706
724
|
color: 'red',
|
|
707
|
-
|
|
725
|
+
},
|
|
708
726
|
- [`& .${buttonGroupClasses.groupedOutlinedSecondary}`]: {
|
|
709
727
|
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
710
728
|
color: 'red',
|
|
711
|
-
|
|
729
|
+
},
|
|
712
730
|
- [`& .${buttonGroupClasses.groupedContained}`]: {
|
|
713
731
|
+ [`&.${buttonGroupClasses.contained} > .${buttonGroupClasses.grouped}`]: {
|
|
714
732
|
color: 'red',
|
|
715
|
-
|
|
733
|
+
},
|
|
716
734
|
- [`& .${buttonGroupClasses.groupedContainedHorizontal}`]: {
|
|
717
735
|
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
718
736
|
color: 'red',
|
|
719
|
-
|
|
737
|
+
},
|
|
720
738
|
- [`& .${buttonGroupClasses.groupedContainedVertical}`]: {
|
|
721
739
|
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
722
740
|
color: 'red',
|
|
723
|
-
|
|
741
|
+
},
|
|
724
742
|
- [`& .${buttonGroupClasses.groupedContainedPrimary}`]: {
|
|
725
743
|
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
726
744
|
color: 'red',
|
|
727
|
-
|
|
745
|
+
},
|
|
728
746
|
- [`& .${buttonGroupClasses.groupedContainedSecondary}`]: {
|
|
729
747
|
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
730
748
|
color: 'red',
|
|
731
|
-
|
|
749
|
+
},
|
|
732
750
|
},
|
|
733
751
|
},
|
|
734
752
|
},
|
|
@@ -791,107 +809,107 @@ JS transforms:
|
|
|
791
809
|
- [`&.${chipClasses.clickableColorPrimary}`]: {
|
|
792
810
|
+ [`&.${chipClasses.clickable}.${chipClasses.colorPrimary}`]: {
|
|
793
811
|
color: 'red',
|
|
794
|
-
|
|
812
|
+
},
|
|
795
813
|
- [`&.${chipClasses.clickableColorSecondary}`]: {
|
|
796
814
|
+ [`&.${chipClasses.clickable}.${chipClasses.colorSecondary}`]: {
|
|
797
815
|
color: 'red',
|
|
798
|
-
|
|
816
|
+
},
|
|
799
817
|
- [`&.${chipClasses.deletableColorPrimary}`]: {
|
|
800
818
|
+ [`&.${chipClasses.deletable}.${chipClasses.colorPrimary}`]: {
|
|
801
819
|
color: 'red',
|
|
802
|
-
|
|
820
|
+
},
|
|
803
821
|
- [`&.${chipClasses.deletableColorSecondary}`]: {
|
|
804
822
|
+ [`&.${chipClasses.deletable}.${chipClasses.colorSecondary}`]: {
|
|
805
823
|
color: 'red',
|
|
806
|
-
|
|
824
|
+
},
|
|
807
825
|
- [`&.${chipClasses.outlinedPrimary}`]: {
|
|
808
826
|
+ [`&.${chipClasses.outlined}.${chipClasses.colorPrimary}`]: {
|
|
809
827
|
color: 'red',
|
|
810
|
-
|
|
828
|
+
},
|
|
811
829
|
- [`&.${chipClasses.outlinedSecondary}`]: {
|
|
812
830
|
+ [`&.${chipClasses.outlined}.${chipClasses.colorSecondary}`]: {
|
|
813
831
|
color: 'red',
|
|
814
|
-
|
|
832
|
+
},
|
|
815
833
|
- [`&.${chipClasses.filledPrimary}`]: {
|
|
816
834
|
+ [`&.${chipClasses.filled}.${chipClasses.colorPrimary}`]: {
|
|
817
835
|
color: 'red',
|
|
818
|
-
|
|
836
|
+
},
|
|
819
837
|
- [`&.${chipClasses.filledSecondary}`]: {
|
|
820
838
|
+ [`&.${chipClasses.filled}.${chipClasses.colorSecondary}`]: {
|
|
821
839
|
color: 'red',
|
|
822
|
-
|
|
840
|
+
},
|
|
823
841
|
- [`& .${chipClasses.avatarSmall}`]: {
|
|
824
842
|
+ [`&.${chipClasses.sizeSmall} > .${chipClasses.avatar}`]: {
|
|
825
843
|
color: 'red',
|
|
826
|
-
|
|
844
|
+
},
|
|
827
845
|
- [`& .${chipClasses.avatarMedium}`]: {
|
|
828
846
|
+ [`&.${chipClasses.sizeMedium} > .${chipClasses.avatar}`]: {
|
|
829
847
|
color: 'red',
|
|
830
|
-
|
|
848
|
+
},
|
|
831
849
|
- [`& .${chipClasses.avatarColorPrimary}`]: {
|
|
832
850
|
+ [`&.${chipClasses.colorPrimary} > .${chipClasses.avatar}`]: {
|
|
833
851
|
color: 'red',
|
|
834
|
-
|
|
852
|
+
},
|
|
835
853
|
- [`& .${chipClasses.avatarColorSecondary}`]: {
|
|
836
854
|
+ [`&.${chipClasses.colorSecondary} > .${chipClasses.avatar}`]: {
|
|
837
855
|
color: 'red',
|
|
838
|
-
|
|
856
|
+
},
|
|
839
857
|
- [`& .${chipClasses.iconSmall}`]: {
|
|
840
858
|
+ [`&.${chipClasses.sizeSmall} > .${chipClasses.icon}`]: {
|
|
841
859
|
color: 'red',
|
|
842
|
-
|
|
860
|
+
},
|
|
843
861
|
- [`& .${chipClasses.iconMedium}`]: {
|
|
844
862
|
+ [`&.${chipClasses.sizeMedium} > .${chipClasses.icon}`]: {
|
|
845
863
|
color: 'red',
|
|
846
|
-
|
|
864
|
+
},
|
|
847
865
|
- [`& .${chipClasses.iconColorPrimary}`]: {
|
|
848
866
|
+ [`&.${chipClasses.colorPrimary} > .${chipClasses.icon}`]: {
|
|
849
867
|
color: 'red',
|
|
850
|
-
|
|
868
|
+
},
|
|
851
869
|
- [`& .${chipClasses.iconColorSecondary}`]: {
|
|
852
870
|
+ [`&.${chipClasses.colorSecondary} > .${chipClasses.icon}`]: {
|
|
853
871
|
color: 'red',
|
|
854
|
-
|
|
872
|
+
},
|
|
855
873
|
- [`& .${chipClasses.labelSmall}`]: {
|
|
856
874
|
+ [`&.${chipClasses.sizeSmall} > .${chipClasses.label}`]: {
|
|
857
875
|
color: 'red',
|
|
858
|
-
|
|
876
|
+
},
|
|
859
877
|
- [`& .${chipClasses.labelMedium}`]: {
|
|
860
878
|
+ [`&.${chipClasses.sizeMedium} > .${chipClasses.label}`]: {
|
|
861
879
|
color: 'red',
|
|
862
|
-
|
|
880
|
+
},
|
|
863
881
|
- [`& .${chipClasses.deleteIconSmall}`]: {
|
|
864
882
|
+ [`&.${chipClasses.sizeSmall} > .${chipClasses.deleteIcon}`]: {
|
|
865
883
|
color: 'red',
|
|
866
|
-
|
|
884
|
+
},
|
|
867
885
|
- [`& .${chipClasses.deleteIconMedium}`]: {
|
|
868
886
|
+ [`&.${chipClasses.sizeMedium} > .${chipClasses.deleteIcon}`]: {
|
|
869
887
|
color: 'red',
|
|
870
|
-
|
|
888
|
+
},
|
|
871
889
|
- [`& .${chipClasses.deleteIconColorPrimary}`]: {
|
|
872
890
|
+ [`&.${chipClasses.colorPrimary} > .${chipClasses.deleteIcon}`]: {
|
|
873
891
|
color: 'red',
|
|
874
|
-
|
|
892
|
+
},
|
|
875
893
|
- [`& .${chipClasses.deleteIconColorSecondary}`]: {
|
|
876
894
|
+ [`&.${chipClasses.colorSecondary} > .${chipClasses.deleteIcon}`]: {
|
|
877
895
|
color: 'red',
|
|
878
|
-
|
|
896
|
+
},
|
|
879
897
|
- [`& .${chipClasses.deleteIconOutlinedColorPrimary}`]: {
|
|
880
898
|
+ [`&.${chipClasses.outlined}.${chipClasses.colorPrimary} > .${chipClasses.deleteIcon}`]: {
|
|
881
899
|
color: 'red',
|
|
882
|
-
|
|
900
|
+
},
|
|
883
901
|
- [`& .${chipClasses.deleteIconOutlinedColorSecondary}`]: {
|
|
884
902
|
+ [`&.${chipClasses.outlined}.${chipClasses.colorSecondary} > .${chipClasses.deleteIcon}`]: {
|
|
885
903
|
color: 'red',
|
|
886
|
-
|
|
904
|
+
},
|
|
887
905
|
- [`& .${chipClasses.deleteIconFilledColorPrimary}`]: {
|
|
888
906
|
+ [`&.${chipClasses.filled}.${chipClasses.colorPrimary} > .${chipClasses.deleteIcon}`]: {
|
|
889
907
|
color: 'red',
|
|
890
|
-
|
|
908
|
+
},
|
|
891
909
|
- [`& .${chipClasses.deleteIconFilledColorSecondary}`]: {
|
|
892
910
|
+ [`&.${chipClasses.filled}.${chipClasses.colorSecondary} > .${chipClasses.deleteIcon}`]: {
|
|
893
911
|
color: 'red',
|
|
894
|
-
|
|
912
|
+
},
|
|
895
913
|
},
|
|
896
914
|
},
|
|
897
915
|
},
|
|
@@ -972,11 +990,11 @@ JS transforms:
|
|
|
972
990
|
- [`& .${circularProgressClasses.circleDeterminate}`]: {
|
|
973
991
|
+ [`&.${circularProgressClasses.determinate} > .${circularProgressClasses.circle}`]: {
|
|
974
992
|
color: 'red',
|
|
975
|
-
|
|
993
|
+
},
|
|
976
994
|
- [`& .${circularProgressClasses.circleIndeterminate}`]: {
|
|
977
995
|
+ [`&.${circularProgressClasses.indeterminate} > .${circularProgressClasses.circle}`]: {
|
|
978
996
|
color: 'red',
|
|
979
|
-
|
|
997
|
+
},
|
|
980
998
|
},
|
|
981
999
|
},
|
|
982
1000
|
},
|
|
@@ -985,9 +1003,12 @@ JS transforms:
|
|
|
985
1003
|
CSS transforms:
|
|
986
1004
|
|
|
987
1005
|
```diff
|
|
988
|
-
|
|
1006
|
+
-.MuiCircularProgress-circleDeterminate
|
|
989
1007
|
+.MuiCircularProgress-determinate > .MuiCircularProgress-circle
|
|
990
|
-
|
|
1008
|
+
```
|
|
1009
|
+
|
|
1010
|
+
```diff
|
|
1011
|
+
-.MuiCircularProgress-circleIndeterminate
|
|
991
1012
|
+.MuiCircularProgress-indeterminate > .MuiCircularProgress-circle
|
|
992
1013
|
```
|
|
993
1014
|
|
|
@@ -1000,7 +1021,7 @@ npx @mui/codemod@next deprecations/circular-progress-classes <path>
|
|
|
1000
1021
|
```diff
|
|
1001
1022
|
<Divider
|
|
1002
1023
|
- light
|
|
1003
|
-
+ sx={{opacity:
|
|
1024
|
+
+ sx={{ opacity: 0.6 }}
|
|
1004
1025
|
/>
|
|
1005
1026
|
```
|
|
1006
1027
|
|
|
@@ -1008,6 +1029,32 @@ npx @mui/codemod@next deprecations/circular-progress-classes <path>
|
|
|
1008
1029
|
npx @mui/codemod@next deprecations/divider-props <path>
|
|
1009
1030
|
```
|
|
1010
1031
|
|
|
1032
|
+
#### `filled-input-props`
|
|
1033
|
+
|
|
1034
|
+
```diff
|
|
1035
|
+
<FilledInput
|
|
1036
|
+
- components={{ Input: CustomInput, Root: CustomRoot }}
|
|
1037
|
+
- componentsProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1038
|
+
+ slots={{ input: CustomInput, root: CustomRoot }}
|
|
1039
|
+
+ slotProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1040
|
+
/>
|
|
1041
|
+
```
|
|
1042
|
+
|
|
1043
|
+
```diff
|
|
1044
|
+
MuiFilledInput: {
|
|
1045
|
+
defaultProps: {
|
|
1046
|
+
- components: { Input: CustomInput, Root: CustomRoot }
|
|
1047
|
+
- componentsProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }
|
|
1048
|
+
+ slots: { input: CustomInput, root: CustomRoot },
|
|
1049
|
+
+ slotProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } },
|
|
1050
|
+
},
|
|
1051
|
+
},
|
|
1052
|
+
```
|
|
1053
|
+
|
|
1054
|
+
```bash
|
|
1055
|
+
npx @mui/codemod@next deprecations/filled-input-props <path>
|
|
1056
|
+
```
|
|
1057
|
+
|
|
1011
1058
|
#### `form-control-label-props`
|
|
1012
1059
|
|
|
1013
1060
|
```diff
|
|
@@ -1020,9 +1067,9 @@ npx @mui/codemod@next deprecations/divider-props <path>
|
|
|
1020
1067
|
```diff
|
|
1021
1068
|
MuiFormControlLabel: {
|
|
1022
1069
|
defaultProps: {
|
|
1023
|
-
-
|
|
1024
|
-
+
|
|
1025
|
-
|
|
1070
|
+
- componentsProps={{ typography: typographyProps }}
|
|
1071
|
+
+ slotProps={{ typography: typographyProps }}
|
|
1072
|
+
},
|
|
1026
1073
|
},
|
|
1027
1074
|
```
|
|
1028
1075
|
|
|
@@ -1036,8 +1083,8 @@ npx @mui/codemod@next deprecations/form-control-label-props <path>
|
|
|
1036
1083
|
```diff
|
|
1037
1084
|
<ListItem
|
|
1038
1085
|
- components={{ Root: CustomRoot }}
|
|
1039
|
-
+ slots={{ root: CustomRoot }}
|
|
1040
1086
|
- componentsProps={{ root: { testid: 'test-id' } }}
|
|
1087
|
+
+ slots={{ root: CustomRoot }}
|
|
1041
1088
|
+ slotProps={{ root: { testid: 'test-id' } }}
|
|
1042
1089
|
/>
|
|
1043
1090
|
```
|
|
@@ -1046,8 +1093,8 @@ npx @mui/codemod@next deprecations/form-control-label-props <path>
|
|
|
1046
1093
|
MuiListItem: {
|
|
1047
1094
|
defaultProps: {
|
|
1048
1095
|
- components: { Root: CustomRoot }
|
|
1049
|
-
+ slots: { root: CustomRoot },
|
|
1050
1096
|
- componentsProps: { root: { testid: 'test-id' }}
|
|
1097
|
+
+ slots: { root: CustomRoot },
|
|
1051
1098
|
+ slotProps: { root: { testid: 'test-id' } },
|
|
1052
1099
|
},
|
|
1053
1100
|
},
|
|
@@ -1061,8 +1108,8 @@ npx @mui/codemod@next deprecations/list-item-props <path>
|
|
|
1061
1108
|
|
|
1062
1109
|
```diff
|
|
1063
1110
|
<Grid
|
|
1064
|
-
-
|
|
1065
|
-
+
|
|
1111
|
+
- wrap="nowrap"
|
|
1112
|
+
+ flexWrap="nowrap"
|
|
1066
1113
|
/>
|
|
1067
1114
|
```
|
|
1068
1115
|
|
|
@@ -1070,6 +1117,84 @@ npx @mui/codemod@next deprecations/list-item-props <path>
|
|
|
1070
1117
|
npx @mui/codemod@next deprecations/grid-props <path>
|
|
1071
1118
|
```
|
|
1072
1119
|
|
|
1120
|
+
#### `input-base-props`
|
|
1121
|
+
|
|
1122
|
+
```diff
|
|
1123
|
+
<InputBase
|
|
1124
|
+
- components={{ Input: CustomInput, Root: CustomRoot }}
|
|
1125
|
+
- componentsProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1126
|
+
+ slots={{ input: CustomInput, root: CustomRoot }}
|
|
1127
|
+
+ slotProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1128
|
+
/>
|
|
1129
|
+
```
|
|
1130
|
+
|
|
1131
|
+
```diff
|
|
1132
|
+
MuiInputBase: {
|
|
1133
|
+
defaultProps: {
|
|
1134
|
+
- components: { Input: CustomInput, Root: CustomRoot }
|
|
1135
|
+
- componentsProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }
|
|
1136
|
+
+ slots: { input: CustomInput, root: CustomRoot },
|
|
1137
|
+
+ slotProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } },
|
|
1138
|
+
},
|
|
1139
|
+
},
|
|
1140
|
+
```
|
|
1141
|
+
|
|
1142
|
+
```bash
|
|
1143
|
+
npx @mui/codemod@next deprecations/input-base-props <path>
|
|
1144
|
+
```
|
|
1145
|
+
|
|
1146
|
+
#### `input-props`
|
|
1147
|
+
|
|
1148
|
+
```diff
|
|
1149
|
+
<Input
|
|
1150
|
+
- components={{ Input: CustomInput, Root: CustomRoot }}
|
|
1151
|
+
- componentsProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1152
|
+
+ slots={{ input: CustomInput, root: CustomRoot }}
|
|
1153
|
+
+ slotProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1154
|
+
/>
|
|
1155
|
+
```
|
|
1156
|
+
|
|
1157
|
+
```diff
|
|
1158
|
+
MuiInput: {
|
|
1159
|
+
defaultProps: {
|
|
1160
|
+
- components: { Input: CustomInput, Root: CustomRoot }
|
|
1161
|
+
- componentsProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }
|
|
1162
|
+
+ slots: { input: CustomInput, root: CustomRoot },
|
|
1163
|
+
+ slotProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } },
|
|
1164
|
+
},
|
|
1165
|
+
},
|
|
1166
|
+
```
|
|
1167
|
+
|
|
1168
|
+
```bash
|
|
1169
|
+
npx @mui/codemod@next deprecations/input-props <path>
|
|
1170
|
+
```
|
|
1171
|
+
|
|
1172
|
+
#### `modal-props`
|
|
1173
|
+
|
|
1174
|
+
```diff
|
|
1175
|
+
<Modal
|
|
1176
|
+
- components={{ Root: CustomRoot, Backdrop: CustomBackdrop }}
|
|
1177
|
+
- componentsProps={{ root: { testid: 'root-id' }, backdrop: { testid: 'backdrop-id' } }}
|
|
1178
|
+
+ slots={{ root: CustomRoot, backdrop: CustomBackdrop }}
|
|
1179
|
+
+ slotProps={{ root: { testid: 'root-id' }, backdrop: { testid: 'backdrop-id' } }}
|
|
1180
|
+
/>
|
|
1181
|
+
```
|
|
1182
|
+
|
|
1183
|
+
```diff
|
|
1184
|
+
MuiModal: {
|
|
1185
|
+
defaultProps: {
|
|
1186
|
+
- components: { Root: CustomRoot, Backdrop: CustomBackdrop }
|
|
1187
|
+
- componentsProps: { root: { testid: 'root-id' }, backdrop: { testid: 'backdrop-id' }}
|
|
1188
|
+
+ slots: { root: CustomRoot, backdrop: CustomBackdrop },
|
|
1189
|
+
+ slotProps: { root: { testid: 'root-id' }, backdrop: { testid: 'backdrop-id' } },
|
|
1190
|
+
},
|
|
1191
|
+
},
|
|
1192
|
+
```
|
|
1193
|
+
|
|
1194
|
+
```bash
|
|
1195
|
+
npx @mui/codemod@next deprecations/modal-props <path>
|
|
1196
|
+
```
|
|
1197
|
+
|
|
1073
1198
|
#### `pagination-item-classes`
|
|
1074
1199
|
|
|
1075
1200
|
JS transforms:
|
|
@@ -1083,35 +1208,35 @@ JS transforms:
|
|
|
1083
1208
|
- [`&.${paginationItemClasses.textPrimary}`]: {
|
|
1084
1209
|
+ [`&.${paginationItemClasses.text}.${paginationItemClasses.colorPrimary}`]: {
|
|
1085
1210
|
color: 'red',
|
|
1086
|
-
|
|
1211
|
+
},
|
|
1087
1212
|
- [`&.${paginationItemClasses.textSecondary}`]: {
|
|
1088
1213
|
+ [`&.${paginationItemClasses.text}.${paginationItemClasses.colorSecondary}`]: {
|
|
1089
1214
|
color: 'red',
|
|
1090
|
-
|
|
1215
|
+
},
|
|
1091
1216
|
- [`&.${paginationItemClasses.outlinedPrimary}`]: {
|
|
1092
1217
|
+ [`&.${paginationItemClasses.outlined}.${paginationItemClasses.colorPrimary}`]: {
|
|
1093
1218
|
color: 'red',
|
|
1094
|
-
|
|
1219
|
+
},
|
|
1095
1220
|
- [`&.${paginationItemClasses.outlinedSecondary}`]: {
|
|
1096
1221
|
+ [`&.${paginationItemClasses.outlined}.${paginationItemClasses.colorSecondary}`]: {
|
|
1097
1222
|
color: 'red',
|
|
1098
|
-
|
|
1223
|
+
},
|
|
1099
1224
|
- '&.MuiPaginationItem-textPrimary': {
|
|
1100
1225
|
+ '&.MuiPaginationItem-text.MuiPaginationItem-colorPrimary': {
|
|
1101
1226
|
color: 'red',
|
|
1102
|
-
|
|
1227
|
+
},
|
|
1103
1228
|
- '&.MuiPaginationItem-textSecondary': {
|
|
1104
1229
|
+ '&.MuiPaginationItem-text.MuiPaginationItem-colorSecondary': {
|
|
1105
1230
|
color: 'red',
|
|
1106
|
-
|
|
1231
|
+
},
|
|
1107
1232
|
- '&.MuiPaginationItem-outlinedPrimary': {
|
|
1108
1233
|
+ '&.MuiPaginationItem-outlined.MuiPaginationItem-colorPrimary': {
|
|
1109
1234
|
color: 'red',
|
|
1110
|
-
|
|
1235
|
+
},
|
|
1111
1236
|
- '&.MuiPaginationItem-outlinedSecondary': {
|
|
1112
1237
|
+ '&.MuiPaginationItem-outlined.MuiPaginationItem-colorSecondary': {
|
|
1113
1238
|
color: 'red',
|
|
1114
|
-
|
|
1239
|
+
},
|
|
1115
1240
|
},
|
|
1116
1241
|
},
|
|
1117
1242
|
},
|
|
@@ -1161,8 +1286,8 @@ npx @mui/codemod@next deprecations/pagination-item-props <path>
|
|
|
1161
1286
|
```diff
|
|
1162
1287
|
<Popper
|
|
1163
1288
|
- components={{ Root: CustomRoot }}
|
|
1164
|
-
+ slots={{ root: CustomRoot }}
|
|
1165
1289
|
- componentsProps={{ root: { testid: 'test-id' } }}
|
|
1290
|
+
+ slots={{ root: CustomRoot }}
|
|
1166
1291
|
+ slotProps={{ root: { testid: 'test-id' } }}
|
|
1167
1292
|
/>
|
|
1168
1293
|
```
|
|
@@ -1171,8 +1296,8 @@ npx @mui/codemod@next deprecations/pagination-item-props <path>
|
|
|
1171
1296
|
MuiPopper: {
|
|
1172
1297
|
defaultProps: {
|
|
1173
1298
|
- components: { Root: CustomRoot }
|
|
1174
|
-
+ slots: { root: CustomRoot },
|
|
1175
1299
|
- componentsProps: { root: { testid: 'test-id' }}
|
|
1300
|
+
+ slots: { root: CustomRoot },
|
|
1176
1301
|
+ slotProps: { root: { testid: 'test-id' } },
|
|
1177
1302
|
},
|
|
1178
1303
|
},
|
|
@@ -1182,13 +1307,39 @@ npx @mui/codemod@next deprecations/pagination-item-props <path>
|
|
|
1182
1307
|
npx @mui/codemod@next deprecations/popper-props <path>
|
|
1183
1308
|
```
|
|
1184
1309
|
|
|
1310
|
+
#### `outlined-input-props`
|
|
1311
|
+
|
|
1312
|
+
```diff
|
|
1313
|
+
<OutlinedInput
|
|
1314
|
+
- components={{ Input: CustomInput, Root: CustomRoot }}
|
|
1315
|
+
- componentsProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1316
|
+
+ slots={{ input: CustomInput, root: CustomRoot }}
|
|
1317
|
+
+ slotProps={{ input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }}
|
|
1318
|
+
/>
|
|
1319
|
+
```
|
|
1320
|
+
|
|
1321
|
+
```diff
|
|
1322
|
+
MuiOutlinedInput: {
|
|
1323
|
+
defaultProps: {
|
|
1324
|
+
- components: { Input: CustomInput, Root: CustomRoot }
|
|
1325
|
+
- componentsProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } }
|
|
1326
|
+
+ slots: { input: CustomInput, root: CustomRoot },
|
|
1327
|
+
+ slotProps: { input: { id: 'test-input-id' }, root: { id: 'test-root-id' } },
|
|
1328
|
+
},
|
|
1329
|
+
},
|
|
1330
|
+
```
|
|
1331
|
+
|
|
1332
|
+
```bash
|
|
1333
|
+
npx @mui/codemod@next deprecations/outlined-input-props <path>
|
|
1334
|
+
```
|
|
1335
|
+
|
|
1185
1336
|
#### `slider-props`
|
|
1186
1337
|
|
|
1187
1338
|
```diff
|
|
1188
1339
|
<Slider
|
|
1189
1340
|
- components={{ Track: CustomTrack }}
|
|
1190
|
-
+ slots={{ track: CustomTrack }}
|
|
1191
1341
|
- componentsProps={{ track: { testid: 'test-id' } }}
|
|
1342
|
+
+ slots={{ track: CustomTrack }}
|
|
1192
1343
|
+ slotProps={{ track: { testid: 'test-id' } }}
|
|
1193
1344
|
/>
|
|
1194
1345
|
```
|
|
@@ -1197,8 +1348,8 @@ npx @mui/codemod@next deprecations/popper-props <path>
|
|
|
1197
1348
|
MuiSlider: {
|
|
1198
1349
|
defaultProps: {
|
|
1199
1350
|
- components: { Track: CustomTrack }
|
|
1200
|
-
+ slots: { track: CustomTrack },
|
|
1201
1351
|
- componentsProps: { track: { testid: 'test-id' }}
|
|
1352
|
+
+ slots: { track: CustomTrack },
|
|
1202
1353
|
+ slotProps: { track: { testid: 'test-id' } },
|
|
1203
1354
|
},
|
|
1204
1355
|
},
|
|
@@ -1213,8 +1364,8 @@ npx @mui/codemod@next deprecations/slider-props <path>
|
|
|
1213
1364
|
```diff
|
|
1214
1365
|
<Tooltip
|
|
1215
1366
|
- components={{ Arrow: CustomArrow }}
|
|
1216
|
-
+ slots={{ arrow: CustomArrow }}
|
|
1217
1367
|
- componentsProps={{ arrow: { testid: 'test-id' } }}
|
|
1368
|
+
+ slots={{ arrow: CustomArrow }}
|
|
1218
1369
|
+ slotProps={{ arrow: { testid: 'test-id' } }}
|
|
1219
1370
|
/>
|
|
1220
1371
|
```
|
|
@@ -1247,11 +1398,11 @@ JS transforms:
|
|
|
1247
1398
|
- [`& .${stepConnectorClasses.lineHorizontal}`]: {
|
|
1248
1399
|
+ [`&.${stepConnectorClasses.horizontal} > .${stepConnectorClasses.line}`]: {
|
|
1249
1400
|
color: 'red',
|
|
1250
|
-
|
|
1401
|
+
},
|
|
1251
1402
|
- [`& .${stepConnectorClasses.lineVertical}`]: {
|
|
1252
1403
|
+ [`&.${stepConnectorClasses.vertical} > .${stepConnectorClasses.line}`]: {
|
|
1253
1404
|
color: 'red',
|
|
1254
|
-
|
|
1405
|
+
},
|
|
1255
1406
|
},
|
|
1256
1407
|
},
|
|
1257
1408
|
},
|
|
@@ -1291,18 +1442,18 @@ npx @mui/codemod@latest deprecations/step-label-props <path>
|
|
|
1291
1442
|
|
|
1292
1443
|
```diff
|
|
1293
1444
|
<TextField
|
|
1294
|
-
-
|
|
1295
|
-
-
|
|
1296
|
-
-
|
|
1297
|
-
-
|
|
1298
|
-
-
|
|
1299
|
-
+
|
|
1300
|
-
+
|
|
1301
|
-
+
|
|
1302
|
-
+
|
|
1303
|
-
+
|
|
1304
|
-
+
|
|
1305
|
-
+
|
|
1445
|
+
- InputProps={CustomInputProps}
|
|
1446
|
+
- inputProps={CustomHtmlInputProps}
|
|
1447
|
+
- SelectProps={CustomSelectProps}
|
|
1448
|
+
- InputLabelProps={CustomInputLabelProps}
|
|
1449
|
+
- FormHelperTextProps={CustomFormHelperProps}
|
|
1450
|
+
+ slotProps={{
|
|
1451
|
+
+ input: CustomInputProps,
|
|
1452
|
+
+ htmlInput: CustomHtmlInputProps,
|
|
1453
|
+
+ select: CustomSelectProps,
|
|
1454
|
+
+ inputLabel: CustomInputLabelProps,
|
|
1455
|
+
+ formHelper: CustomFormHelperProps,
|
|
1456
|
+
+ }}
|
|
1306
1457
|
/>
|
|
1307
1458
|
```
|
|
1308
1459
|
|
|
@@ -1323,11 +1474,11 @@ JS transforms:
|
|
|
1323
1474
|
- [`& .${toggleButtonGroupClasses.groupedHorizontal}`]: {
|
|
1324
1475
|
+ [`&.${toggleButtonGroupClasses.horizontal} > .${toggleButtonGroupClasses.grouped}`]: {
|
|
1325
1476
|
color: 'red',
|
|
1326
|
-
|
|
1477
|
+
},
|
|
1327
1478
|
- [`& .${toggleButtonGroupClasses.groupedVertical}`]: {
|
|
1328
1479
|
+ [`&.${toggleButtonGroupClasses.vertical} > .${toggleButtonGroupClasses.grouped}`]: {
|
|
1329
1480
|
color: 'red',
|
|
1330
|
-
|
|
1481
|
+
},
|
|
1331
1482
|
},
|
|
1332
1483
|
},
|
|
1333
1484
|
},
|
|
@@ -1338,9 +1489,11 @@ CSS transforms:
|
|
|
1338
1489
|
```diff
|
|
1339
1490
|
-.MuiToggleButtonGroup-root .MuiToggleButtonGroup-groupedHorizontal
|
|
1340
1491
|
+.MuiToggleButtonGroup-root.MuiToggleButtonGroup-horizontal > .MuiToggleButtonGroup-grouped
|
|
1492
|
+
```
|
|
1493
|
+
|
|
1494
|
+
```diff
|
|
1341
1495
|
-.MuiToggleButtonGroup-root .MuiToggleButtonGroup-groupedVertical
|
|
1342
1496
|
+.MuiToggleButtonGroup-root.MuiToggleButtonGroup-vertical > .MuiToggleButtonGroup-grouped
|
|
1343
|
-
/>
|
|
1344
1497
|
```
|
|
1345
1498
|
|
|
1346
1499
|
```bash
|
|
@@ -1350,9 +1503,12 @@ npx @mui/codemod@latest deprecations/toggle-button-group-classes <path>
|
|
|
1350
1503
|
CSS transforms:
|
|
1351
1504
|
|
|
1352
1505
|
```diff
|
|
1353
|
-
|
|
1506
|
+
-.MuiStepConnector-lineHorizontal
|
|
1354
1507
|
+.MuiStepConnector-horizontal > .MuiStepConnector-line
|
|
1355
|
-
|
|
1508
|
+
```
|
|
1509
|
+
|
|
1510
|
+
```diff
|
|
1511
|
+
-.MuiStepConnector-lineVertical
|
|
1356
1512
|
+.MuiStepConnector-vertical > .MuiStepConnector-line
|
|
1357
1513
|
```
|
|
1358
1514
|
|
|
@@ -1360,6 +1516,75 @@ CSS transforms:
|
|
|
1360
1516
|
npx @mui/codemod@next deprecations/step-connector-classes <path>
|
|
1361
1517
|
```
|
|
1362
1518
|
|
|
1519
|
+
#### `tab-classes`
|
|
1520
|
+
|
|
1521
|
+
JS transforms:
|
|
1522
|
+
|
|
1523
|
+
```diff
|
|
1524
|
+
import { tabClasses } from '@mui/material/Tab';
|
|
1525
|
+
|
|
1526
|
+
MuiTab: {
|
|
1527
|
+
styleOverrides: {
|
|
1528
|
+
root: {
|
|
1529
|
+
- [`& .${tabClasses.iconWrapper}`]: {
|
|
1530
|
+
+ [`& .${tabClasses.icon}`]: {
|
|
1531
|
+
color: 'red',
|
|
1532
|
+
},
|
|
1533
|
+
},
|
|
1534
|
+
},
|
|
1535
|
+
},
|
|
1536
|
+
```
|
|
1537
|
+
|
|
1538
|
+
CSS transforms:
|
|
1539
|
+
|
|
1540
|
+
```diff
|
|
1541
|
+
-.MuiTab-iconWrapper
|
|
1542
|
+
+.MuiTab-icon
|
|
1543
|
+
```
|
|
1544
|
+
|
|
1545
|
+
```bash
|
|
1546
|
+
npx @mui/codemod@next deprecations/tab-classes <path>
|
|
1547
|
+
```
|
|
1548
|
+
|
|
1549
|
+
#### `table-sort-label-classes`
|
|
1550
|
+
|
|
1551
|
+
JS transforms:
|
|
1552
|
+
|
|
1553
|
+
```diff
|
|
1554
|
+
import { tableSortLabelClasses } from '@mui/material/TableSortLabel';
|
|
1555
|
+
|
|
1556
|
+
MuiTableSortLabel: {
|
|
1557
|
+
styleOverrides: {
|
|
1558
|
+
root: {
|
|
1559
|
+
- [`& .${tableSortLabelClasses.iconDirectionDesc}`]: {
|
|
1560
|
+
+ [`&.${tableSortLabelClasses.directionDesc} > .${tableSortLabelClasses.icon}`]: {
|
|
1561
|
+
color: 'red',
|
|
1562
|
+
},
|
|
1563
|
+
- [`& .${tableSortLabelClasses.iconDirectionAsc}`]: {
|
|
1564
|
+
+ [`&.${tableSortLabelClasses.directionAsc} > .${tableSortLabelClasses.icon}`]: {
|
|
1565
|
+
color: 'red',
|
|
1566
|
+
},
|
|
1567
|
+
},
|
|
1568
|
+
},
|
|
1569
|
+
},
|
|
1570
|
+
```
|
|
1571
|
+
|
|
1572
|
+
CSS transforms:
|
|
1573
|
+
|
|
1574
|
+
```diff
|
|
1575
|
+
-.MuiTableSortLabel-iconDirectionDesc
|
|
1576
|
+
+.MuiTableSortLabel-directionDesc > .MuiTableSortLabel-icon
|
|
1577
|
+
```
|
|
1578
|
+
|
|
1579
|
+
```diff
|
|
1580
|
+
-.MuiTableSortLabel-iconDirectionAsc
|
|
1581
|
+
+.MuiTableSortLabel-directionAsc > .MuiTableSortLabel-icon
|
|
1582
|
+
```
|
|
1583
|
+
|
|
1584
|
+
```bash
|
|
1585
|
+
npx @mui/codemod@next deprecations/table-sort-label-classes <path>
|
|
1586
|
+
```
|
|
1587
|
+
|
|
1363
1588
|
### v6.0.0
|
|
1364
1589
|
|
|
1365
1590
|
#### `sx-prop`
|
|
@@ -1374,7 +1599,7 @@ Update the usage of the `sx` prop to be compatible with `@pigment-css/react`.
|
|
|
1374
1599
|
<Box
|
|
1375
1600
|
- sx={{
|
|
1376
1601
|
- backgroundColor: (theme) =>
|
|
1377
|
-
-
|
|
1602
|
+
- theme.palette.mode === 'light' ? theme.palette.grey[100] : theme.palette.grey[900],
|
|
1378
1603
|
- }}
|
|
1379
1604
|
+ sx={theme => ({
|
|
1380
1605
|
+ backgroundColor: theme.palette.grey[900],
|
|
@@ -1394,8 +1619,8 @@ npx @mui/codemod@next v6.0.0/system-props <path>
|
|
|
1394
1619
|
Remove system props and add them to the `sx` prop.
|
|
1395
1620
|
|
|
1396
1621
|
```diff
|
|
1397
|
-
|
|
1398
|
-
|
|
1622
|
+
-<Box ml="2px" py={1} color="primary.main" />
|
|
1623
|
+
+<Box sx={{ ml: '2px', py: 1, color: 'primary.main' }} />
|
|
1399
1624
|
```
|
|
1400
1625
|
|
|
1401
1626
|
#### `theme-v6`
|
|
@@ -1414,14 +1639,14 @@ Update the theme creation from `@mui/system@v5` to be compatible with `@pigment-
|
|
|
1414
1639
|
createTheme({
|
|
1415
1640
|
components: {
|
|
1416
1641
|
MuiButton: {
|
|
1417
|
-
-
|
|
1418
|
-
-
|
|
1419
|
-
-
|
|
1420
|
-
-
|
|
1421
|
-
-
|
|
1422
|
-
-
|
|
1423
|
-
-
|
|
1424
|
-
-
|
|
1642
|
+
- variants: [
|
|
1643
|
+
- {
|
|
1644
|
+
- props: { color: 'primary' },
|
|
1645
|
+
- style: {
|
|
1646
|
+
- color: 'red',
|
|
1647
|
+
- },
|
|
1648
|
+
- },
|
|
1649
|
+
- ],
|
|
1425
1650
|
styleOverrides: {
|
|
1426
1651
|
- root: ({ theme, ownerState }) => ({
|
|
1427
1652
|
+ root: ({ theme }) => ({
|
|
@@ -1534,6 +1759,36 @@ However, it has some **limitations**:
|
|
|
1534
1759
|
}));
|
|
1535
1760
|
```
|
|
1536
1761
|
|
|
1762
|
+
#### `grid-v2-props`
|
|
1763
|
+
|
|
1764
|
+
```bash
|
|
1765
|
+
npx @mui/codemod@next v6.0.0/grid-v2-props <path>
|
|
1766
|
+
```
|
|
1767
|
+
|
|
1768
|
+
Updates the usage of the `Unstable_Grid` (Grid v2) component to have the same API as the `PigmentGrid`.
|
|
1769
|
+
|
|
1770
|
+
```diff
|
|
1771
|
+
<Grid
|
|
1772
|
+
- xs={12}
|
|
1773
|
+
- sm={6}
|
|
1774
|
+
- xsOffset={2}
|
|
1775
|
+
- smOffset={3}
|
|
1776
|
+
+ size={{ xs: 12, sm: 6 }}
|
|
1777
|
+
+ offset={{ xs: 2, sm: 3 }}
|
|
1778
|
+
/>
|
|
1779
|
+
```
|
|
1780
|
+
|
|
1781
|
+
You can provide the theme breakpoints via options, for example, `--jscodeshift='--muiBreakpoints=mobile,desktop'`, to use your custom breakpoints in the transformation.
|
|
1782
|
+
|
|
1783
|
+
```bash
|
|
1784
|
+
npx @mui/codemod@next v6.0.0/grid-v2-props <path> --jscodeshift='--muiBreakpoints=mobile,desktop'
|
|
1785
|
+
```
|
|
1786
|
+
|
|
1787
|
+
```diff
|
|
1788
|
+
- <Grid mobile={12} mobileOffset={2} desktop={6} desktopOffset={4} >
|
|
1789
|
+
+ <Grid size={{ mobile: 12, desktop: 6 }} offset={{ mobile: 2, desktop: 4 }} >
|
|
1790
|
+
```
|
|
1791
|
+
|
|
1537
1792
|
### v5.0.0
|
|
1538
1793
|
|
|
1539
1794
|
#### `base-use-named-exports`
|
|
@@ -1633,7 +1888,7 @@ Transforms `row` prop to `orientation` prop across `Card`, `List` and `RadioGrou
|
|
|
1633
1888
|
```diff
|
|
1634
1889
|
<Card
|
|
1635
1890
|
- row
|
|
1636
|
-
+ orientation=
|
|
1891
|
+
+ orientation="horizontal"
|
|
1637
1892
|
/>;
|
|
1638
1893
|
```
|
|
1639
1894
|
|
|
@@ -1661,7 +1916,7 @@ npx @mui/codemod@next v5.0.0/joy-avatar-remove-imgProps <path>
|
|
|
1661
1916
|
|
|
1662
1917
|
#### `joy-text-field-to-input`
|
|
1663
1918
|
|
|
1664
|
-
Replace `<TextField>` with composition of
|
|
1919
|
+
Replace `<TextField>` with a composition of input components:
|
|
1665
1920
|
|
|
1666
1921
|
This change only affects Joy UI components.
|
|
1667
1922
|
|