@mui/codemod 5.15.14 → 6.0.0-alpha.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 +256 -95
- package/node/deprecations/all/deprecations-all.js +6 -0
- package/node/deprecations/all/postcss.config.js +4 -1
- package/node/deprecations/backdrop-props/backdrop-props.js +80 -0
- package/node/deprecations/backdrop-props/index.js +13 -0
- package/node/deprecations/backdrop-props/test-cases/actual.js +33 -0
- package/node/deprecations/backdrop-props/test-cases/expected.js +38 -0
- package/node/deprecations/backdrop-props/test-cases/theme.actual.js +19 -0
- package/node/deprecations/backdrop-props/test-cases/theme.expected.js +21 -0
- package/node/deprecations/button-group-classes/button-group-classes.js +77 -0
- package/node/deprecations/button-group-classes/index.js +13 -0
- package/node/deprecations/button-group-classes/postcss-plugin.js +78 -0
- package/node/deprecations/button-group-classes/postcss.config.js +8 -0
- package/node/deprecations/button-group-classes/test-cases/actual.js +37 -0
- package/node/deprecations/button-group-classes/test-cases/expected.js +37 -0
- package/node/deprecations/step-label-props/index.js +13 -0
- package/node/deprecations/step-label-props/step-label-props.js +22 -0
- package/node/deprecations/step-label-props/test-cases/actual.js +21 -0
- package/node/deprecations/step-label-props/test-cases/expected.js +19 -0
- package/node/deprecations/step-label-props/test-cases/theme.actual.js +23 -0
- package/node/deprecations/step-label-props/test-cases/theme.expected.js +22 -0
- package/node/v1.0.0/color-imports.test/actual.js +1 -1
- package/node/v1.0.0/color-imports.test/expected.js +1 -1
- package/node/v1.0.0/import-path.test/actual.js +1 -1
- package/node/v1.0.0/import-path.test/expected.js +1 -1
- package/node/v4.0.0/optimal-imports.test/actual.js +1 -1
- package/node/v4.0.0/optimal-imports.test/expected.js +1 -1
- package/node/v4.0.0/top-level-imports.test/actual.js +1 -1
- package/node/v4.0.0/top-level-imports.test/expected.js +1 -1
- package/node/v5.0.0/base-hook-imports.test/actual.js +1 -1
- package/node/v5.0.0/base-hook-imports.test/expected.js +1 -1
- package/node/v5.0.0/base-remove-unstyled-suffix.test/actual.js +1 -1
- package/node/v5.0.0/base-remove-unstyled-suffix.test/expected.js +1 -1
- package/node/v5.0.0/base-use-named-exports.test/actual-with-warning.js +1 -1
- package/node/v5.0.0/base-use-named-exports.test/actual.js +1 -1
- package/node/v5.0.0/box-sx-prop.test/actual.js +1 -1
- package/node/v5.0.0/box-sx-prop.test/alias-actual.js +1 -1
- package/node/v5.0.0/box-sx-prop.test/alias-expected.js +1 -1
- package/node/v5.0.0/box-sx-prop.test/expected.js +1 -1
- package/node/v5.0.0/date-pickers-moved-to-x.test/actual-sub-module.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/Anonymous.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/Anonymous.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/eighth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/eighth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/eleventh.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/eleventh.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/exportClass.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/exportClass.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/exportFunction.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/exportFunction.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/fifth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/fifth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/first.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/first.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/fourth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/fourth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/multipleWithStyles.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/multipleWithStyles.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/nineth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/nineth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/second.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/second.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/seventh.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/seventh.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/sixth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/sixth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/tenth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/tenth.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/third.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/third.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/twelfth.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles1.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles1.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles2.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles2.expected.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles3.actual.js +1 -1
- package/node/v5.0.0/jss-to-styled.test/withCreateStyles3.expected.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/actual-todo-comments.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/actual-typescript-docs-example.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/actual-typescript.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/expected-todo-comments.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/expected-typescript-docs-example.js +1 -1
- package/node/v5.0.0/jss-to-tss-react.test/expected-typescript.js +1 -1
- package/node/v5.0.0/preset-safe.test/actual.js +1 -1
- package/node/v5.0.0/preset-safe.test/expected.js +1 -1
- package/node/v5.0.0/styled-engine-provider.test/mui-theme-provider.actual.js +1 -1
- package/node/v5.0.0/styled-engine-provider.test/mui-theme-provider.expected.js +1 -1
- package/node/v5.0.0/styled-engine-provider.test/theme-provider.actual.js +1 -1
- package/node/v5.0.0/styled-engine-provider.test/theme-provider.expected.js +1 -1
- 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/v5.0.0/top-level-imports.test/actual.js +1 -1
- package/node/v5.0.0/top-level-imports.test/expected.js +1 -1
- package/node/v5.0.0/transitions.test/actual.js +1 -1
- package/node/v5.0.0/transitions.test/expected.js +1 -1
- package/node/v5.0.0/tree-view-moved-to-x.test/actual-sub-module.js +1 -1
- package/node/v5.0.0/use-autocomplete.test/expected.js +1 -1
- package/node/v5.0.0/variant-prop.test/actual.js +1 -1
- package/node/v5.0.0/variant-prop.test/expected.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -14,7 +14,7 @@ Some of the codemods also run [postcss](https://github.com/postcss/postcss) plug
|
|
|
14
14
|
<!-- #default-branch-switch -->
|
|
15
15
|
|
|
16
16
|
```bash
|
|
17
|
-
npx @mui/codemod@
|
|
17
|
+
npx @mui/codemod@next <codemod> <paths...>
|
|
18
18
|
|
|
19
19
|
Applies a `@mui/codemod` to the specified paths
|
|
20
20
|
|
|
@@ -34,10 +34,10 @@ Options:
|
|
|
34
34
|
--jscodeshift [string] [default: false]
|
|
35
35
|
|
|
36
36
|
Examples:
|
|
37
|
-
npx @mui/codemod@
|
|
38
|
-
npx @mui/codemod@
|
|
37
|
+
npx @mui/codemod@next v4.0.0/theme-spacing-api src
|
|
38
|
+
npx @mui/codemod@next v5.0.0/component-rename-prop src --
|
|
39
39
|
--component=Grid --from=prop --to=newProp
|
|
40
|
-
npx @mui/codemod@
|
|
40
|
+
npx @mui/codemod@next v5.0.0/preset-safe src --parser=flow
|
|
41
41
|
```
|
|
42
42
|
|
|
43
43
|
### jscodeshift options
|
|
@@ -45,7 +45,7 @@ Examples:
|
|
|
45
45
|
To pass more options directly to jscodeshift, use `--jscodeshift="..."`. For example:
|
|
46
46
|
|
|
47
47
|
```bash
|
|
48
|
-
npx @mui/codemod@
|
|
48
|
+
npx @mui/codemod@next --jscodeshift="--run-in-band --verbose=2"
|
|
49
49
|
```
|
|
50
50
|
|
|
51
51
|
See all available options [here](https://github.com/facebook/jscodeshift#usage-cli).
|
|
@@ -56,7 +56,7 @@ Options to [recast](https://github.com/benjamn/recast)'s printer can be provided
|
|
|
56
56
|
through jscodeshift's `printOptions` command line argument
|
|
57
57
|
|
|
58
58
|
```bash
|
|
59
|
-
npx @mui/codemod@
|
|
59
|
+
npx @mui/codemod@next <transform> <path> --jscodeshift="--printOptions='{\"quote\":\"double\"}'"
|
|
60
60
|
```
|
|
61
61
|
|
|
62
62
|
## Included scripts
|
|
@@ -70,7 +70,7 @@ npx @mui/codemod@latest <transform> <path> --jscodeshift="--printOptions='{\"quo
|
|
|
70
70
|
### Deprecations
|
|
71
71
|
|
|
72
72
|
```bash
|
|
73
|
-
npx @mui/codemod@
|
|
73
|
+
npx @mui/codemod@next deprecations/all <path>
|
|
74
74
|
```
|
|
75
75
|
|
|
76
76
|
#### `all`
|
|
@@ -89,7 +89,7 @@ A combination of all deprecations.
|
|
|
89
89
|
```
|
|
90
90
|
|
|
91
91
|
```bash
|
|
92
|
-
npx @mui/codemod@
|
|
92
|
+
npx @mui/codemod@next deprecations/accordion-props <path>
|
|
93
93
|
```
|
|
94
94
|
|
|
95
95
|
#### `accordion-summary-classes`
|
|
@@ -133,7 +133,7 @@ CSS transforms:
|
|
|
133
133
|
```
|
|
134
134
|
|
|
135
135
|
```bash
|
|
136
|
-
npx @mui/codemod@
|
|
136
|
+
npx @mui/codemod@next deprecations/accordion-summary-classes <path>
|
|
137
137
|
```
|
|
138
138
|
|
|
139
139
|
#### `alert-classes`
|
|
@@ -229,7 +229,7 @@ CSS transforms:
|
|
|
229
229
|
```
|
|
230
230
|
|
|
231
231
|
```bash
|
|
232
|
-
npx @mui/codemod@
|
|
232
|
+
npx @mui/codemod@next deprecations/alert-classes <path>
|
|
233
233
|
```
|
|
234
234
|
|
|
235
235
|
#### `alert-props`
|
|
@@ -255,7 +255,7 @@ npx @mui/codemod@latest deprecations/alert-classes <path>
|
|
|
255
255
|
```
|
|
256
256
|
|
|
257
257
|
```bash
|
|
258
|
-
npx @mui/codemod@
|
|
258
|
+
npx @mui/codemod@next deprecations/alert-props <path>
|
|
259
259
|
```
|
|
260
260
|
|
|
261
261
|
#### `avatar-props`
|
|
@@ -274,6 +274,19 @@ npx @mui/codemod@latest deprecations/alert-props <path>
|
|
|
274
274
|
/>;
|
|
275
275
|
```
|
|
276
276
|
|
|
277
|
+
#### `backdrop-props`
|
|
278
|
+
|
|
279
|
+
```diff
|
|
280
|
+
<Backdrop
|
|
281
|
+
- TransitionComponent={CustomTransition}
|
|
282
|
+
+ slots={{ transition: CustomTransition }}
|
|
283
|
+
/>
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
```bash
|
|
287
|
+
npx @mui/codemod@next deprecations/backdrop-props <path>
|
|
288
|
+
```
|
|
289
|
+
|
|
277
290
|
#### `button-classes`
|
|
278
291
|
|
|
279
292
|
JS transforms:
|
|
@@ -494,7 +507,133 @@ CSS transforms:
|
|
|
494
507
|
```
|
|
495
508
|
|
|
496
509
|
```bash
|
|
497
|
-
npx @mui/codemod@
|
|
510
|
+
npx @mui/codemod@next deprecations/button-classes <path>
|
|
511
|
+
```
|
|
512
|
+
|
|
513
|
+
#### `button-group-classes`
|
|
514
|
+
|
|
515
|
+
JS transforms:
|
|
516
|
+
|
|
517
|
+
```diff
|
|
518
|
+
import { buttonGroupClasses } from '@mui/material/ButtonGroup';
|
|
519
|
+
|
|
520
|
+
MuiButtonGroup: {
|
|
521
|
+
styleOverrides: {
|
|
522
|
+
root: {
|
|
523
|
+
- [`& .${buttonGroupClasses.groupedHorizontal}`]: {
|
|
524
|
+
+ [`&.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
525
|
+
color: 'red',
|
|
526
|
+
},
|
|
527
|
+
- [`& .${buttonGroupClasses.groupedVertical}`]: {
|
|
528
|
+
+ [`&.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
529
|
+
color: 'red',
|
|
530
|
+
},
|
|
531
|
+
- [`& .${buttonGroupClasses.groupedText}`]: {
|
|
532
|
+
+ [`&.${buttonGroupClasses.text} > .${buttonGroupClasses.grouped}`]: {
|
|
533
|
+
color: 'red',
|
|
534
|
+
},
|
|
535
|
+
- [`& .${buttonGroupClasses.groupedTextHorizontal}`]: {
|
|
536
|
+
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
537
|
+
color: 'red',
|
|
538
|
+
},
|
|
539
|
+
- [`& .${buttonGroupClasses.groupedTextVertical}`]: {
|
|
540
|
+
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
541
|
+
color: 'red',
|
|
542
|
+
},
|
|
543
|
+
- [`& .${buttonGroupClasses.groupedTextPrimary}`]: {
|
|
544
|
+
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
545
|
+
color: 'red',
|
|
546
|
+
},
|
|
547
|
+
- [`& .${buttonGroupClasses.groupedTextSecondary}`]: {
|
|
548
|
+
+ [`&.${buttonGroupClasses.text}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
549
|
+
color: 'red',
|
|
550
|
+
},
|
|
551
|
+
- [`& .${buttonGroupClasses.groupedOutlined}`]: {
|
|
552
|
+
+ [`&.${buttonGroupClasses.outlined} > .${buttonGroupClasses.grouped}`]: {
|
|
553
|
+
color: 'red',
|
|
554
|
+
},
|
|
555
|
+
- [`& .${buttonGroupClasses.groupedOutlinedHorizontal}`]: {
|
|
556
|
+
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
557
|
+
color: 'red',
|
|
558
|
+
},
|
|
559
|
+
- [`& .${buttonGroupClasses.groupedOutlinedVertical}`]: {
|
|
560
|
+
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
561
|
+
color: 'red',
|
|
562
|
+
},
|
|
563
|
+
- [`& .${buttonGroupClasses.groupedOutlinedPrimary}`]: {
|
|
564
|
+
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
565
|
+
color: 'red',
|
|
566
|
+
},
|
|
567
|
+
- [`& .${buttonGroupClasses.groupedOutlinedSecondary}`]: {
|
|
568
|
+
+ [`&.${buttonGroupClasses.outlined}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
569
|
+
color: 'red',
|
|
570
|
+
},
|
|
571
|
+
- [`& .${buttonGroupClasses.groupedContained}`]: {
|
|
572
|
+
+ [`&.${buttonGroupClasses.contained} > .${buttonGroupClasses.grouped}`]: {
|
|
573
|
+
color: 'red',
|
|
574
|
+
},
|
|
575
|
+
- [`& .${buttonGroupClasses.groupedContainedHorizontal}`]: {
|
|
576
|
+
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.horizontal} > .${buttonGroupClasses.grouped}`]: {
|
|
577
|
+
color: 'red',
|
|
578
|
+
},
|
|
579
|
+
- [`& .${buttonGroupClasses.groupedContainedVertical}`]: {
|
|
580
|
+
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.vertical} > .${buttonGroupClasses.grouped}`]: {
|
|
581
|
+
color: 'red',
|
|
582
|
+
},
|
|
583
|
+
- [`& .${buttonGroupClasses.groupedContainedPrimary}`]: {
|
|
584
|
+
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.colorPrimary} > .${buttonGroupClasses.grouped}`]: {
|
|
585
|
+
color: 'red',
|
|
586
|
+
},
|
|
587
|
+
- [`& .${buttonGroupClasses.groupedContainedSecondary}`]: {
|
|
588
|
+
+ [`&.${buttonGroupClasses.contained}.${buttonGroupClasses.colorSecondary} > .${buttonGroupClasses.grouped}`]: {
|
|
589
|
+
color: 'red',
|
|
590
|
+
},
|
|
591
|
+
},
|
|
592
|
+
},
|
|
593
|
+
},
|
|
594
|
+
```
|
|
595
|
+
|
|
596
|
+
CSS transforms:
|
|
597
|
+
|
|
598
|
+
```diff
|
|
599
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedHorizontal
|
|
600
|
+
+.MuiButtonGroup-root.MuiButtonGroup-horizontal > .MuiButtonGroup-grouped
|
|
601
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedVertical
|
|
602
|
+
+.MuiButtonGroup-root.MuiButtonGroup-vertical > .MuiButtonGroup-grouped
|
|
603
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedText
|
|
604
|
+
+.MuiButtonGroup-root.MuiButtonGroup-text > .MuiButtonGroup-grouped
|
|
605
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedTextHorizontal
|
|
606
|
+
+.MuiButtonGroup-root.MuiButtonGroup-text.MuiButtonGroup-horizontal > .MuiButtonGroup-grouped
|
|
607
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedTextVertical
|
|
608
|
+
+.MuiButtonGroup-root.MuiButtonGroup-text.MuiButtonGroup-vertical > .MuiButtonGroup-grouped
|
|
609
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedTextPrimary
|
|
610
|
+
+.MuiButtonGroup-root.MuiButtonGroup-text.MuiButtonGroup-colorPrimary > .MuiButtonGroup-grouped
|
|
611
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedTextSecondary
|
|
612
|
+
+.MuiButtonGroup-root.MuiButtonGroup-text.MuiButtonGroup-colorSecondary > .MuiButtonGroup-grouped
|
|
613
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedOutlined
|
|
614
|
+
+.MuiButtonGroup-root.MuiButtonGroup-outlined > .MuiButtonGroup-grouped
|
|
615
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedOutlinedHorizontal
|
|
616
|
+
+.MuiButtonGroup-root.MuiButtonGroup-outlined.MuiButtonGroup-horizontal > .MuiButtonGroup-grouped
|
|
617
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedOutlinedVertical
|
|
618
|
+
+.MuiButtonGroup-root.MuiButtonGroup-outlined.MuiButtonGroup-vertical > .MuiButtonGroup-grouped
|
|
619
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedOutlinedPrimary
|
|
620
|
+
+.MuiButtonGroup-root.MuiButtonGroup-outlined.MuiButtonGroup-colorPrimary > .MuiButtonGroup-grouped
|
|
621
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedOutlinedSecondary
|
|
622
|
+
+.MuiButtonGroup-root.MuiButtonGroup-outlined.MuiButtonGroup-colorSecondary > .MuiButtonGroup-grouped
|
|
623
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedContained
|
|
624
|
+
+.MuiButtonGroup-root.MuiButtonGroup-contained > .MuiButtonGroup-grouped
|
|
625
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedContainedHorizontal
|
|
626
|
+
+.MuiButtonGroup-root.MuiButtonGroup-contained.MuiButtonGroup-horizontal > .MuiButtonGroup-grouped
|
|
627
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedContainedVertical
|
|
628
|
+
+.MuiButtonGroup-root.MuiButtonGroup-contained.MuiButtonGroup-vertical > .MuiButtonGroup-grouped
|
|
629
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedContainedPrimary
|
|
630
|
+
+.MuiButtonGroup-root.MuiButtonGroup-contained.MuiButtonGroup-colorPrimary > .MuiButtonGroup-grouped
|
|
631
|
+
-.MuiButtonGroup-root .MuiButtonGroup-groupedContainedSecondary
|
|
632
|
+
+.MuiButtonGroup-root.MuiButtonGroup-contained.MuiButtonGroup-colorSecondary > .MuiButtonGroup-grouped
|
|
633
|
+
```
|
|
634
|
+
|
|
635
|
+
```bash
|
|
636
|
+
npx @mui/codemod@latest deprecations/button-group-classes <path>
|
|
498
637
|
```
|
|
499
638
|
|
|
500
639
|
#### `chip-classes`
|
|
@@ -676,7 +815,7 @@ CSS transforms:
|
|
|
676
815
|
```
|
|
677
816
|
|
|
678
817
|
```bash
|
|
679
|
-
npx @mui/codemod@
|
|
818
|
+
npx @mui/codemod@next deprecations/chip-classes <path>
|
|
680
819
|
```
|
|
681
820
|
|
|
682
821
|
#### `divider-props`
|
|
@@ -689,7 +828,7 @@ npx @mui/codemod@latest deprecations/chip-classes <path>
|
|
|
689
828
|
```
|
|
690
829
|
|
|
691
830
|
```bash
|
|
692
|
-
npx @mui/codemod@
|
|
831
|
+
npx @mui/codemod@next deprecations/divider-props <path>
|
|
693
832
|
```
|
|
694
833
|
|
|
695
834
|
#### `pagination-item-classes`
|
|
@@ -750,11 +889,10 @@ CSS transforms:
|
|
|
750
889
|
+.MuiPaginationItem-outlined.MuiPaginationItem-primary
|
|
751
890
|
-.MuiPaginationItem-outlinedSecondary
|
|
752
891
|
+.MuiPaginationItem-outlined.MuiPaginationItem-secondary
|
|
753
|
-
/>
|
|
754
892
|
```
|
|
755
893
|
|
|
756
894
|
```bash
|
|
757
|
-
npx @mui/codemod@
|
|
895
|
+
npx @mui/codemod@next deprecations/pagination-item-classes <path>
|
|
758
896
|
```
|
|
759
897
|
|
|
760
898
|
#### `slider-props`
|
|
@@ -780,7 +918,30 @@ npx @mui/codemod@latest deprecations/pagination-item-classes <path>
|
|
|
780
918
|
```
|
|
781
919
|
|
|
782
920
|
```bash
|
|
783
|
-
npx @mui/codemod@
|
|
921
|
+
npx @mui/codemod@next deprecations/slider-props <path>
|
|
922
|
+
```
|
|
923
|
+
|
|
924
|
+
#### `step-label-props`
|
|
925
|
+
|
|
926
|
+
```diff
|
|
927
|
+
<StepLabel
|
|
928
|
+
- componentsProps={{ label: labelProps }}
|
|
929
|
+
+ slotProps={{ label: labelProps }}
|
|
930
|
+
/>
|
|
931
|
+
```
|
|
932
|
+
|
|
933
|
+
```diff
|
|
934
|
+
MuiStepLabel: {
|
|
935
|
+
defaultProps: {
|
|
936
|
+
- componentsProps={{ label: labelProps }}
|
|
937
|
+
+ slotProps={{ label: labelProps }}
|
|
938
|
+
},
|
|
939
|
+
},
|
|
940
|
+
```
|
|
941
|
+
|
|
942
|
+
```bash
|
|
943
|
+
npx @mui/codemod@latest deprecations/step-label-props <path>
|
|
944
|
+
|
|
784
945
|
```
|
|
785
946
|
|
|
786
947
|
### v5.0.0
|
|
@@ -801,7 +962,7 @@ This codemod updates the import and re-export statements.
|
|
|
801
962
|
```
|
|
802
963
|
|
|
803
964
|
```bash
|
|
804
|
-
npx @mui/codemod@
|
|
965
|
+
npx @mui/codemod@next v5.0.0/base-use-named-exports <path>
|
|
805
966
|
```
|
|
806
967
|
|
|
807
968
|
#### `base-remove-unstyled-suffix`
|
|
@@ -814,7 +975,7 @@ The `Unstyled` suffix has been removed from all Base UI component names, includ
|
|
|
814
975
|
```
|
|
815
976
|
|
|
816
977
|
```bash
|
|
817
|
-
npx @mui/codemod@
|
|
978
|
+
npx @mui/codemod@next v5.0.0/base-remove-unstyled-suffix <path>
|
|
818
979
|
```
|
|
819
980
|
|
|
820
981
|
#### `base-remove-component-prop`
|
|
@@ -829,7 +990,7 @@ This change only affects Base UI components.
|
|
|
829
990
|
```
|
|
830
991
|
|
|
831
992
|
```bash
|
|
832
|
-
npx @mui/codemod@
|
|
993
|
+
npx @mui/codemod@next v5.0.0/base-remove-component-prop <path>
|
|
833
994
|
```
|
|
834
995
|
|
|
835
996
|
#### `rename-css-variables`
|
|
@@ -844,7 +1005,7 @@ Updates the names of the CSS variables of the Joy UI components to adapt to the
|
|
|
844
1005
|
```
|
|
845
1006
|
|
|
846
1007
|
```bash
|
|
847
|
-
npx @mui/codemod@
|
|
1008
|
+
npx @mui/codemod@next v5.0.0/rename-css-variables <path>
|
|
848
1009
|
```
|
|
849
1010
|
|
|
850
1011
|
#### `base-hook-imports`
|
|
@@ -857,7 +1018,7 @@ Updates the sources of the imports of the Base UI hooks to adapt to the new dir
|
|
|
857
1018
|
```
|
|
858
1019
|
|
|
859
1020
|
```bash
|
|
860
|
-
npx @mui/codemod@
|
|
1021
|
+
npx @mui/codemod@next v5.0.0/base-hook-imports <path>
|
|
861
1022
|
```
|
|
862
1023
|
|
|
863
1024
|
#### `joy-rename-classname-prefix`
|
|
@@ -872,7 +1033,7 @@ Renames the classname prefix from `'Joy'` to `'Mui'` for Joy UI components.
|
|
|
872
1033
|
```
|
|
873
1034
|
|
|
874
1035
|
```bash
|
|
875
|
-
npx @mui/codemod@
|
|
1036
|
+
npx @mui/codemod@next v5.0.0/joy-rename-classname-prefix <path>
|
|
876
1037
|
```
|
|
877
1038
|
|
|
878
1039
|
#### `joy-rename-row-prop`
|
|
@@ -887,7 +1048,7 @@ Transforms `row` prop to `orientation` prop across `Card`, `List` and `RadioGrou
|
|
|
887
1048
|
```
|
|
888
1049
|
|
|
889
1050
|
```bash
|
|
890
|
-
npx @mui/codemod@
|
|
1051
|
+
npx @mui/codemod@next v5.0.0/joy-rename-row-prop <path>
|
|
891
1052
|
```
|
|
892
1053
|
|
|
893
1054
|
#### `joy-avatar-remove-imgProps`
|
|
@@ -905,7 +1066,7 @@ This change only affects Joy UI Avatar component.
|
|
|
905
1066
|
```
|
|
906
1067
|
|
|
907
1068
|
```bash
|
|
908
|
-
npx @mui/codemod@
|
|
1069
|
+
npx @mui/codemod@next v5.0.0/joy-avatar-remove-imgProps <path>
|
|
909
1070
|
```
|
|
910
1071
|
|
|
911
1072
|
#### `joy-text-field-to-input`
|
|
@@ -963,7 +1124,7 @@ This change only affects Joy UI components.
|
|
|
963
1124
|
```
|
|
964
1125
|
|
|
965
1126
|
```bash
|
|
966
|
-
npx @mui/codemod@
|
|
1127
|
+
npx @mui/codemod@next v5.0.0/joy-text-field-to-input <path>
|
|
967
1128
|
```
|
|
968
1129
|
|
|
969
1130
|
#### `joy-rename-components-to-slots`
|
|
@@ -982,7 +1143,7 @@ This change only affects Joy UI components.
|
|
|
982
1143
|
```
|
|
983
1144
|
|
|
984
1145
|
```bash
|
|
985
|
-
npx @mui/codemod@
|
|
1146
|
+
npx @mui/codemod@next v5.0.0/joy-rename-components-to-slots <path>
|
|
986
1147
|
```
|
|
987
1148
|
|
|
988
1149
|
The associated breaking change was done in [#34997](https://github.com/mui/material-ui/pull/34997).
|
|
@@ -992,7 +1153,7 @@ The associated breaking change was done in [#34997](https://github.com/mui/mater
|
|
|
992
1153
|
Rename the imports of Date and Time Pickers from `@mui/lab` to `@mui/x-date-pickers` and `@mui/x-date-pickers-pro`.
|
|
993
1154
|
|
|
994
1155
|
```bash
|
|
995
|
-
npx @mui/codemod@
|
|
1156
|
+
npx @mui/codemod@next v5.0.0/date-pickers-moved-to-x <path>
|
|
996
1157
|
```
|
|
997
1158
|
|
|
998
1159
|
#### `tree-view-moved-to-x`
|
|
@@ -1000,7 +1161,7 @@ npx @mui/codemod@latest v5.0.0/date-pickers-moved-to-x <path>
|
|
|
1000
1161
|
Rename the imports of Tree View from `@mui/lab` to `@mui/x-tree-view`.
|
|
1001
1162
|
|
|
1002
1163
|
```bash
|
|
1003
|
-
npx @mui/codemod@
|
|
1164
|
+
npx @mui/codemod@next v5.0.0/tree-view-moved-to-x <path>
|
|
1004
1165
|
```
|
|
1005
1166
|
|
|
1006
1167
|
#### 🚀 `preset-safe`
|
|
@@ -1008,7 +1169,7 @@ npx @mui/codemod@latest v5.0.0/tree-view-moved-to-x <path>
|
|
|
1008
1169
|
A combination of all important transformers for migrating v4 to v5. ⚠️ This codemod should be run only once.
|
|
1009
1170
|
|
|
1010
1171
|
```bash
|
|
1011
|
-
npx @mui/codemod@
|
|
1172
|
+
npx @mui/codemod@next v5.0.0/preset-safe <path|folder>
|
|
1012
1173
|
```
|
|
1013
1174
|
|
|
1014
1175
|
The list includes these transformers
|
|
@@ -1075,7 +1236,7 @@ Imports and inserts `adaptV4Theme` into `createTheme` (or `createMuiTheme`)
|
|
|
1075
1236
|
```
|
|
1076
1237
|
|
|
1077
1238
|
```bash
|
|
1078
|
-
npx @mui/codemod@
|
|
1239
|
+
npx @mui/codemod@next v5.0.0/adapter-v4 <path>
|
|
1079
1240
|
```
|
|
1080
1241
|
|
|
1081
1242
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -1092,7 +1253,7 @@ Renames `Autocomplete`'s `closeIcon` prop to `clearIcon`.
|
|
|
1092
1253
|
<!-- #default-branch-switch -->
|
|
1093
1254
|
|
|
1094
1255
|
```bash
|
|
1095
|
-
npx @mui/codemod@
|
|
1256
|
+
npx @mui/codemod@next v5.0.0/autocomplete-rename-closeicon <path>
|
|
1096
1257
|
```
|
|
1097
1258
|
|
|
1098
1259
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#autocomplete).
|
|
@@ -1111,7 +1272,7 @@ Renames `Autocomplete`'s `getOptionSelected` to `isOptionEqualToValue`.
|
|
|
1111
1272
|
<!-- #default-branch-switch -->
|
|
1112
1273
|
|
|
1113
1274
|
```bash
|
|
1114
|
-
npx @mui/codemod@
|
|
1275
|
+
npx @mui/codemod@next v5.0.0/autocomplete-rename-option <path>
|
|
1115
1276
|
```
|
|
1116
1277
|
|
|
1117
1278
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#autocomplete).
|
|
@@ -1130,7 +1291,7 @@ Updates the `Avatar`'s `variant` value and `classes` key from 'circle' to 'circu
|
|
|
1130
1291
|
<!-- #default-branch-switch -->
|
|
1131
1292
|
|
|
1132
1293
|
```bash
|
|
1133
|
-
npx @mui/codemod@
|
|
1294
|
+
npx @mui/codemod@next v5.0.0/avatar-circle-circular <path>
|
|
1134
1295
|
```
|
|
1135
1296
|
|
|
1136
1297
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#avatar).
|
|
@@ -1165,7 +1326,7 @@ Renames the badge's props.
|
|
|
1165
1326
|
<!-- #default-branch-switch -->
|
|
1166
1327
|
|
|
1167
1328
|
```bash
|
|
1168
|
-
npx @mui/codemod@
|
|
1329
|
+
npx @mui/codemod@next v5.0.0/badge-overlap-value <path>
|
|
1169
1330
|
```
|
|
1170
1331
|
|
|
1171
1332
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#badge).
|
|
@@ -1189,7 +1350,7 @@ This change only affects Base UI components.
|
|
|
1189
1350
|
<!-- #default-branch-switch -->
|
|
1190
1351
|
|
|
1191
1352
|
```bash
|
|
1192
|
-
npx @mui/codemod@
|
|
1353
|
+
npx @mui/codemod@next v5.0.0/base-rename-components-to-slots <path>
|
|
1193
1354
|
```
|
|
1194
1355
|
|
|
1195
1356
|
The associated breaking change was done in [#34693](https://github.com/mui/material-ui/pull/34693).
|
|
@@ -1208,7 +1369,7 @@ Updates the Box API from separate system props to `sx`.
|
|
|
1208
1369
|
<!-- #default-branch-switch -->
|
|
1209
1370
|
|
|
1210
1371
|
```bash
|
|
1211
|
-
npx @mui/codemod@
|
|
1372
|
+
npx @mui/codemod@next v5.0.0/box-borderradius-values <path>
|
|
1212
1373
|
```
|
|
1213
1374
|
|
|
1214
1375
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#box).
|
|
@@ -1223,7 +1384,7 @@ Renames the Box `css` prop to `sx`
|
|
|
1223
1384
|
```
|
|
1224
1385
|
|
|
1225
1386
|
```bash
|
|
1226
|
-
npx @mui/codemod@
|
|
1387
|
+
npx @mui/codemod@next v5.0.0/box-rename-css <path>
|
|
1227
1388
|
```
|
|
1228
1389
|
|
|
1229
1390
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#box).
|
|
@@ -1244,7 +1405,7 @@ Renames the Box `grid*Gap` props.
|
|
|
1244
1405
|
<!-- #default-branch-switch -->
|
|
1245
1406
|
|
|
1246
1407
|
```bash
|
|
1247
|
-
npx @mui/codemod@
|
|
1408
|
+
npx @mui/codemod@next v5.0.0/box-rename-gap <path>
|
|
1248
1409
|
```
|
|
1249
1410
|
|
|
1250
1411
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#box).
|
|
@@ -1261,7 +1422,7 @@ Removes the outdated `color` prop values.
|
|
|
1261
1422
|
<!-- #default-branch-switch -->
|
|
1262
1423
|
|
|
1263
1424
|
```bash
|
|
1264
|
-
npx @mui/codemod@
|
|
1425
|
+
npx @mui/codemod@next v5.0.0/button-color-prop <path>
|
|
1265
1426
|
```
|
|
1266
1427
|
|
|
1267
1428
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#button).
|
|
@@ -1278,7 +1439,7 @@ Removes the Chip `variant` prop if the value is `"default"`.
|
|
|
1278
1439
|
<!-- #default-branch-switch -->
|
|
1279
1440
|
|
|
1280
1441
|
```bash
|
|
1281
|
-
npx @mui/codemod@
|
|
1442
|
+
npx @mui/codemod@next v5.0.0/chip-variant-prop <path>
|
|
1282
1443
|
```
|
|
1283
1444
|
|
|
1284
1445
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#chip).
|
|
@@ -1295,7 +1456,7 @@ Renames the CircularProgress `static` variant to `determinate`.
|
|
|
1295
1456
|
<!-- #default-branch-switch -->
|
|
1296
1457
|
|
|
1297
1458
|
```bash
|
|
1298
|
-
npx @mui/codemod@
|
|
1459
|
+
npx @mui/codemod@next v5.0.0/circularprogress-variant <path>
|
|
1299
1460
|
```
|
|
1300
1461
|
|
|
1301
1462
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#circularprogress).
|
|
@@ -1314,7 +1475,7 @@ Renames `Collapse`'s `collapsedHeight` prop to `collapsedSize`.
|
|
|
1314
1475
|
<!-- #default-branch-switch -->
|
|
1315
1476
|
|
|
1316
1477
|
```bash
|
|
1317
|
-
npx @mui/codemod@
|
|
1478
|
+
npx @mui/codemod@next v5.0.0/collapse-rename-collapsedheight <path>
|
|
1318
1479
|
```
|
|
1319
1480
|
|
|
1320
1481
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#collapse).
|
|
@@ -1333,7 +1494,7 @@ A generic codemod to rename any component prop.
|
|
|
1333
1494
|
<!-- #default-branch-switch -->
|
|
1334
1495
|
|
|
1335
1496
|
```bash
|
|
1336
|
-
npx @mui/codemod@
|
|
1497
|
+
npx @mui/codemod@next v5.0.0/component-rename-prop <path> -- --component=Grid --from=prop --to=newProp
|
|
1337
1498
|
```
|
|
1338
1499
|
|
|
1339
1500
|
#### `core-styles-import`
|
|
@@ -1346,7 +1507,7 @@ Renames private import from `core/styles/*` to `core/styles`
|
|
|
1346
1507
|
```
|
|
1347
1508
|
|
|
1348
1509
|
```bash
|
|
1349
|
-
npx @mui/codemod@
|
|
1510
|
+
npx @mui/codemod@next v5.0.0/core-styles-import <path>
|
|
1350
1511
|
```
|
|
1351
1512
|
|
|
1352
1513
|
#### `create-theme`
|
|
@@ -1359,7 +1520,7 @@ Renames the function `createMuiTheme` to `createTheme`
|
|
|
1359
1520
|
```
|
|
1360
1521
|
|
|
1361
1522
|
```bash
|
|
1362
|
-
npx @mui/codemod@
|
|
1523
|
+
npx @mui/codemod@next v5.0.0/create-theme <path>
|
|
1363
1524
|
```
|
|
1364
1525
|
|
|
1365
1526
|
#### `dialog-props`
|
|
@@ -1372,7 +1533,7 @@ Remove `disableBackdropClick` prop from `<Dialog>`
|
|
|
1372
1533
|
```
|
|
1373
1534
|
|
|
1374
1535
|
```bash
|
|
1375
|
-
npx @mui/codemod@
|
|
1536
|
+
npx @mui/codemod@next v5.0.0/dialog-props <path>
|
|
1376
1537
|
```
|
|
1377
1538
|
|
|
1378
1539
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#dialog).
|
|
@@ -1387,7 +1548,7 @@ Remove `disableTypography` prop from `<DialogTitle>`
|
|
|
1387
1548
|
```
|
|
1388
1549
|
|
|
1389
1550
|
```bash
|
|
1390
|
-
npx @mui/codemod@
|
|
1551
|
+
npx @mui/codemod@next v5.0.0/dialog-title-props <path>
|
|
1391
1552
|
```
|
|
1392
1553
|
|
|
1393
1554
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#dialog).
|
|
@@ -1404,7 +1565,7 @@ Adds `prepend: true` to Emotion `createCache`
|
|
|
1404
1565
|
```
|
|
1405
1566
|
|
|
1406
1567
|
```bash
|
|
1407
|
-
npx @mui/codemod@
|
|
1568
|
+
npx @mui/codemod@next v5.0.0/create-theme <path>
|
|
1408
1569
|
```
|
|
1409
1570
|
|
|
1410
1571
|
#### `expansion-panel-component`
|
|
@@ -1412,7 +1573,7 @@ npx @mui/codemod@latest v5.0.0/create-theme <path>
|
|
|
1412
1573
|
Renames `ExpansionPanel*` to `Accordion*`
|
|
1413
1574
|
|
|
1414
1575
|
```bash
|
|
1415
|
-
npx @mui/codemod@
|
|
1576
|
+
npx @mui/codemod@next v5.0.0/expansion-panel-component <path>
|
|
1416
1577
|
```
|
|
1417
1578
|
|
|
1418
1579
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#expansionpanel).
|
|
@@ -1425,7 +1586,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1425
1586
|
```
|
|
1426
1587
|
|
|
1427
1588
|
```bash
|
|
1428
|
-
npx @mui/codemod@
|
|
1589
|
+
npx @mui/codemod@next v5.0.0/fab-variant <path>
|
|
1429
1590
|
```
|
|
1430
1591
|
|
|
1431
1592
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#fab).
|
|
@@ -1445,7 +1606,7 @@ Renames the `fade` style utility import and calls to `alpha`.
|
|
|
1445
1606
|
<!-- #default-branch-switch -->
|
|
1446
1607
|
|
|
1447
1608
|
```bash
|
|
1448
|
-
npx @mui/codemod@
|
|
1609
|
+
npx @mui/codemod@next v5.0.0/fade-rename-alpha <path>
|
|
1449
1610
|
```
|
|
1450
1611
|
|
|
1451
1612
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#styles).
|
|
@@ -1462,7 +1623,7 @@ Renames `Grid`'s `justify` prop to `justifyContent`.
|
|
|
1462
1623
|
<!-- #default-branch-switch -->
|
|
1463
1624
|
|
|
1464
1625
|
```bash
|
|
1465
|
-
npx @mui/codemod@
|
|
1626
|
+
npx @mui/codemod@next v5.0.0/grid-justify-justifycontent <path>
|
|
1466
1627
|
```
|
|
1467
1628
|
|
|
1468
1629
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#grid).
|
|
@@ -1472,7 +1633,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1472
1633
|
Renames `GridList*` to `ImageList*`
|
|
1473
1634
|
|
|
1474
1635
|
```bash
|
|
1475
|
-
npx @mui/codemod@
|
|
1636
|
+
npx @mui/codemod@next v5.0.0/grid-list-component <path>
|
|
1476
1637
|
```
|
|
1477
1638
|
|
|
1478
1639
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#gridlist).
|
|
@@ -1489,7 +1650,7 @@ Adds `size="large"` if `size` is not defined to get the same appearance as v4.
|
|
|
1489
1650
|
```
|
|
1490
1651
|
|
|
1491
1652
|
```bash
|
|
1492
|
-
npx @mui/codemod@
|
|
1653
|
+
npx @mui/codemod@next v5.0.0/icon-button-size <path>
|
|
1493
1654
|
```
|
|
1494
1655
|
|
|
1495
1656
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#iconbutton).
|
|
@@ -1554,7 +1715,7 @@ Replace JSS styling with `makeStyles` or `withStyles` to `styled` API.
|
|
|
1554
1715
|
```
|
|
1555
1716
|
|
|
1556
1717
|
```bash
|
|
1557
|
-
npx @mui/codemod@
|
|
1718
|
+
npx @mui/codemod@next v5.0.0/jss-to-styled <path>
|
|
1558
1719
|
```
|
|
1559
1720
|
|
|
1560
1721
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#1-use-styled-or-sx-api).
|
|
@@ -1626,7 +1787,7 @@ Migrate JSS styling with `makeStyles` or `withStyles` to the corresponding `tss-
|
|
|
1626
1787
|
```
|
|
1627
1788
|
|
|
1628
1789
|
```bash
|
|
1629
|
-
npx @mui/codemod@
|
|
1790
|
+
npx @mui/codemod@next v5.0.0/jss-to-tss-react <path>
|
|
1630
1791
|
```
|
|
1631
1792
|
|
|
1632
1793
|
The following scenarios are not currently handled by this codemod and will be marked with a
|
|
@@ -1654,7 +1815,7 @@ Apply `underline="hover"` to `<Link />` that does not define `underline` prop (t
|
|
|
1654
1815
|
```
|
|
1655
1816
|
|
|
1656
1817
|
```bash
|
|
1657
|
-
npx @mui/codemod@
|
|
1818
|
+
npx @mui/codemod@next v5.0.0/link-underline-hover <path>
|
|
1658
1819
|
```
|
|
1659
1820
|
|
|
1660
1821
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#link).
|
|
@@ -1692,7 +1853,7 @@ Moves JSS imports to `@material-ui/styles`
|
|
|
1692
1853
|
```
|
|
1693
1854
|
|
|
1694
1855
|
```bash
|
|
1695
|
-
npx @mui/codemod@
|
|
1856
|
+
npx @mui/codemod@next v5.0.0/material-ui-styles <path>
|
|
1696
1857
|
```
|
|
1697
1858
|
|
|
1698
1859
|
#### `material-ui-types`
|
|
@@ -1705,7 +1866,7 @@ Renames `Omit` import from `@material-ui/types` to `DistributiveOmit`
|
|
|
1705
1866
|
```
|
|
1706
1867
|
|
|
1707
1868
|
```bash
|
|
1708
|
-
npx @mui/codemod@
|
|
1869
|
+
npx @mui/codemod@next v5.0.0/material-ui-types <path>
|
|
1709
1870
|
```
|
|
1710
1871
|
|
|
1711
1872
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#material-ui-types).
|
|
@@ -1722,7 +1883,7 @@ Removes `disableBackdropClick` and `onEscapeKeyDown` from `<Modal>`
|
|
|
1722
1883
|
```
|
|
1723
1884
|
|
|
1724
1885
|
```bash
|
|
1725
|
-
npx @mui/codemod@
|
|
1886
|
+
npx @mui/codemod@next v5.0.0/modal-props <path>
|
|
1726
1887
|
```
|
|
1727
1888
|
|
|
1728
1889
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#modal).
|
|
@@ -1746,7 +1907,7 @@ or
|
|
|
1746
1907
|
<!-- #default-branch-switch -->
|
|
1747
1908
|
|
|
1748
1909
|
```bash
|
|
1749
|
-
npx @mui/codemod@
|
|
1910
|
+
npx @mui/codemod@next v5.0.0/moved-lab-modules <path>
|
|
1750
1911
|
```
|
|
1751
1912
|
|
|
1752
1913
|
You can find more details about this breaking change in the migration guide.
|
|
@@ -1771,7 +1932,7 @@ Renames `Pagination*`'s `shape` values from 'round' to 'circular'.
|
|
|
1771
1932
|
```
|
|
1772
1933
|
|
|
1773
1934
|
```bash
|
|
1774
|
-
npx @mui/codemod@
|
|
1935
|
+
npx @mui/codemod@next v5.0.0/pagination-round-circular <path>
|
|
1775
1936
|
```
|
|
1776
1937
|
|
|
1777
1938
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#pagination).
|
|
@@ -1790,7 +1951,7 @@ Fix private import paths.
|
|
|
1790
1951
|
<!-- #default-branch-switch -->
|
|
1791
1952
|
|
|
1792
1953
|
```bash
|
|
1793
|
-
npx @mui/codemod@
|
|
1954
|
+
npx @mui/codemod@next v5.0.0/optimal-imports <path>
|
|
1794
1955
|
```
|
|
1795
1956
|
|
|
1796
1957
|
#### `root-ref`
|
|
@@ -1798,7 +1959,7 @@ npx @mui/codemod@latest v5.0.0/optimal-imports <path>
|
|
|
1798
1959
|
Removes `RootRef` from the codebase.
|
|
1799
1960
|
|
|
1800
1961
|
```bash
|
|
1801
|
-
npx @mui/codemod@
|
|
1962
|
+
npx @mui/codemod@next v5.0.0/root-ref <path>
|
|
1802
1963
|
```
|
|
1803
1964
|
|
|
1804
1965
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#rootref).
|
|
@@ -1813,7 +1974,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1813
1974
|
```
|
|
1814
1975
|
|
|
1815
1976
|
```bash
|
|
1816
|
-
npx @mui/codemod@
|
|
1977
|
+
npx @mui/codemod@next v5.0.0/skeleton-variant <path>
|
|
1817
1978
|
```
|
|
1818
1979
|
|
|
1819
1980
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#skeleton).
|
|
@@ -1823,7 +1984,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1823
1984
|
Applies `StyledEngineProvider` to the files that contains `ThemeProvider`.
|
|
1824
1985
|
|
|
1825
1986
|
```bash
|
|
1826
|
-
npx @mui/codemod@
|
|
1987
|
+
npx @mui/codemod@next v5.0.0/styled-engine-provider <path>
|
|
1827
1988
|
```
|
|
1828
1989
|
|
|
1829
1990
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-style-changes/#style-library).
|
|
@@ -1849,7 +2010,7 @@ Renames props in `Table*` components.
|
|
|
1849
2010
|
```
|
|
1850
2011
|
|
|
1851
2012
|
```bash
|
|
1852
|
-
npx @mui/codemod@
|
|
2013
|
+
npx @mui/codemod@next v5.0.0/table-props <path>
|
|
1853
2014
|
```
|
|
1854
2015
|
|
|
1855
2016
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#table).
|
|
@@ -1868,7 +2029,7 @@ Renames the `Tabs`'s `scrollButtons` prop values.
|
|
|
1868
2029
|
```
|
|
1869
2030
|
|
|
1870
2031
|
```bash
|
|
1871
|
-
npx @mui/codemod@
|
|
2032
|
+
npx @mui/codemod@next v5.0.0/tabs-scroll-buttons <path>
|
|
1872
2033
|
```
|
|
1873
2034
|
|
|
1874
2035
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#tabs).
|
|
@@ -1887,7 +2048,7 @@ Renames `TextField`'s rows props.
|
|
|
1887
2048
|
```
|
|
1888
2049
|
|
|
1889
2050
|
```bash
|
|
1890
|
-
npx @mui/codemod@
|
|
2051
|
+
npx @mui/codemod@next v5.0.0/textarea-minmax-rows <path>
|
|
1891
2052
|
```
|
|
1892
2053
|
|
|
1893
2054
|
You can find more details about this breaking change in the migration guide.
|
|
@@ -1900,7 +2061,7 @@ You can find more details about this breaking change in the migration guide.
|
|
|
1900
2061
|
Adds `DefaultTheme` module augmentation to TypeScript projects.
|
|
1901
2062
|
|
|
1902
2063
|
```bash
|
|
1903
|
-
npx @mui/codemod@
|
|
2064
|
+
npx @mui/codemod@next v5.0.0/theme-augment <path>
|
|
1904
2065
|
```
|
|
1905
2066
|
|
|
1906
2067
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#material-ui-styles).
|
|
@@ -1919,7 +2080,7 @@ Updates breakpoint values to match new logic. ⚠️ This mod is not idempotent,
|
|
|
1919
2080
|
<!-- #default-branch-switch -->
|
|
1920
2081
|
|
|
1921
2082
|
```bash
|
|
1922
|
-
npx @mui/codemod@
|
|
2083
|
+
npx @mui/codemod@next v5.0.0/theme-breakpoints <path>
|
|
1923
2084
|
```
|
|
1924
2085
|
|
|
1925
2086
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -1929,7 +2090,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1929
2090
|
Renames `theme.breakpoints.width('md')` to `theme.breakpoints.values.md`.
|
|
1930
2091
|
|
|
1931
2092
|
```bash
|
|
1932
|
-
npx @mui/codemod@
|
|
2093
|
+
npx @mui/codemod@next v5.0.0/theme-breakpoints-width <path>
|
|
1933
2094
|
```
|
|
1934
2095
|
|
|
1935
2096
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -1942,7 +2103,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1942
2103
|
```
|
|
1943
2104
|
|
|
1944
2105
|
```bash
|
|
1945
|
-
npx @mui/codemod@
|
|
2106
|
+
npx @mui/codemod@next v5.0.0/theme-options <path>
|
|
1946
2107
|
```
|
|
1947
2108
|
|
|
1948
2109
|
#### `theme-palette-mode`
|
|
@@ -1964,7 +2125,7 @@ Renames `type` to `mode`.
|
|
|
1964
2125
|
```
|
|
1965
2126
|
|
|
1966
2127
|
```bash
|
|
1967
|
-
npx @mui/codemod@
|
|
2128
|
+
npx @mui/codemod@next v5.0.0/theme-palette-mode <path>
|
|
1968
2129
|
```
|
|
1969
2130
|
|
|
1970
2131
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -1974,7 +2135,7 @@ You can find more details about this breaking change in [the migration guide](ht
|
|
|
1974
2135
|
Renames `MuiThemeProvider` to `ThemeProvider`.
|
|
1975
2136
|
|
|
1976
2137
|
```bash
|
|
1977
|
-
npx @mui/codemod@
|
|
2138
|
+
npx @mui/codemod@next v5.0.0/theme-provider <path>
|
|
1978
2139
|
```
|
|
1979
2140
|
|
|
1980
2141
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#material-ui-core-styles).
|
|
@@ -1993,7 +2154,7 @@ Removes the 'px' suffix from some template strings.
|
|
|
1993
2154
|
<!-- #default-branch-switch -->
|
|
1994
2155
|
|
|
1995
2156
|
```bash
|
|
1996
|
-
npx @mui/codemod@
|
|
2157
|
+
npx @mui/codemod@next v5.0.0/theme-spacing <path>
|
|
1997
2158
|
```
|
|
1998
2159
|
|
|
1999
2160
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -2008,7 +2169,7 @@ Renames `theme.typography.round($number)` to `Math.round($number * 1e5) / 1e5`.
|
|
|
2008
2169
|
```
|
|
2009
2170
|
|
|
2010
2171
|
```bash
|
|
2011
|
-
npx @mui/codemod@
|
|
2172
|
+
npx @mui/codemod@next v5.0.0/theme-typography-round <path>
|
|
2012
2173
|
```
|
|
2013
2174
|
|
|
2014
2175
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#theme).
|
|
@@ -2026,7 +2187,7 @@ Converts all `@mui/material` submodule imports to the root module:
|
|
|
2026
2187
|
<!-- #default-branch-switch -->
|
|
2027
2188
|
|
|
2028
2189
|
```bash
|
|
2029
|
-
npx @mui/codemod@
|
|
2190
|
+
npx @mui/codemod@next v5.0.0/top-level-imports <path>
|
|
2030
2191
|
```
|
|
2031
2192
|
|
|
2032
2193
|
Head to https://mui.com/guides/minimizing-bundle-size/ to understand when it's useful.
|
|
@@ -2036,7 +2197,7 @@ Head to https://mui.com/guides/minimizing-bundle-size/ to understand when it's u
|
|
|
2036
2197
|
Renames import `transitions` to `createTransitions`
|
|
2037
2198
|
|
|
2038
2199
|
```bash
|
|
2039
|
-
npx @mui/codemod@
|
|
2200
|
+
npx @mui/codemod@next v5.0.0/transitions <path>
|
|
2040
2201
|
```
|
|
2041
2202
|
|
|
2042
2203
|
#### `use-autocomplete`
|
|
@@ -2049,7 +2210,7 @@ Renames `useAutocomplete` related import from lab to core
|
|
|
2049
2210
|
```
|
|
2050
2211
|
|
|
2051
2212
|
```bash
|
|
2052
|
-
npx @mui/codemod@
|
|
2213
|
+
npx @mui/codemod@next v5.0.0/use-autocomplete <path>
|
|
2053
2214
|
```
|
|
2054
2215
|
|
|
2055
2216
|
#### `use-transitionprops`
|
|
@@ -2078,7 +2239,7 @@ Updates Dialog, Menu, Popover, and Snackbar to use the `TransitionProps` prop to
|
|
|
2078
2239
|
<!-- #default-branch-switch -->
|
|
2079
2240
|
|
|
2080
2241
|
```bash
|
|
2081
|
-
npx @mui/codemod@
|
|
2242
|
+
npx @mui/codemod@next v5.0.0/use-transitionprops <path>
|
|
2082
2243
|
```
|
|
2083
2244
|
|
|
2084
2245
|
You can find more details about this breaking change in [the migration guide](/material-ui/migration/v5-component-changes/#dialog).
|
|
@@ -2108,7 +2269,7 @@ The diff should look like this:
|
|
|
2108
2269
|
<!-- #default-branch-switch -->
|
|
2109
2270
|
|
|
2110
2271
|
```bash
|
|
2111
|
-
npx @mui/codemod@
|
|
2272
|
+
npx @mui/codemod@next v5.0.0/variant-prop <path>
|
|
2112
2273
|
```
|
|
2113
2274
|
|
|
2114
2275
|
#### `with-mobile-dialog`
|
|
@@ -2122,7 +2283,7 @@ Removes imported `withMobileDialog`, and inserts hardcoded version to prevent ap
|
|
|
2122
2283
|
```
|
|
2123
2284
|
|
|
2124
2285
|
```bash
|
|
2125
|
-
npx @mui/codemod@
|
|
2286
|
+
npx @mui/codemod@next v5.0.0/with-mobile-dialog <path>
|
|
2126
2287
|
```
|
|
2127
2288
|
|
|
2128
2289
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-component-changes/#dialog).
|
|
@@ -2138,7 +2299,7 @@ Removes `withWidth` import, and inserts hardcoded version to prevent application
|
|
|
2138
2299
|
```
|
|
2139
2300
|
|
|
2140
2301
|
```bash
|
|
2141
|
-
npx @mui/codemod@
|
|
2302
|
+
npx @mui/codemod@next v5.0.0/with-width <path>
|
|
2142
2303
|
```
|
|
2143
2304
|
|
|
2144
2305
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/v5-style-changes/#material-ui-core-styles).
|
|
@@ -2199,7 +2360,7 @@ Replace every occurrence of `material-ui` related package with the new package n
|
|
|
2199
2360
|
```
|
|
2200
2361
|
|
|
2201
2362
|
```bash
|
|
2202
|
-
npx @mui/codemod@
|
|
2363
|
+
npx @mui/codemod@next v5.0.0/mui-replace <path>
|
|
2203
2364
|
```
|
|
2204
2365
|
|
|
2205
2366
|
You can find more details about this breaking change in [the migration guide](https://mui.com/material-ui/migration/migration-v4/#update-material-ui-version).
|
|
@@ -2219,7 +2380,7 @@ The diff should look like this:
|
|
|
2219
2380
|
<!-- #default-branch-switch -->
|
|
2220
2381
|
|
|
2221
2382
|
```bash
|
|
2222
|
-
npx @mui/codemod@
|
|
2383
|
+
npx @mui/codemod@next v4.0.0/theme-spacing-api <path>
|
|
2223
2384
|
```
|
|
2224
2385
|
|
|
2225
2386
|
This codemod tries to perform a basic expression simplification which can be improved for expressions that use more than one operation.
|
|
@@ -2246,7 +2407,7 @@ Converts all `@material-ui/core` imports more than 1 level deep to the optimal f
|
|
|
2246
2407
|
<!-- #default-branch-switch -->
|
|
2247
2408
|
|
|
2248
2409
|
```bash
|
|
2249
|
-
npx @mui/codemod@
|
|
2410
|
+
npx @mui/codemod@next v4.0.0/optimal-imports <path>
|
|
2250
2411
|
```
|
|
2251
2412
|
|
|
2252
2413
|
Head to https://mui.com/guides/minimizing-bundle-size/ to understand when it's useful.
|
|
@@ -2264,7 +2425,7 @@ Converts all `@material-ui/core` submodule imports to the root module:
|
|
|
2264
2425
|
<!-- #default-branch-switch -->
|
|
2265
2426
|
|
|
2266
2427
|
```bash
|
|
2267
|
-
npx @mui/codemod@
|
|
2428
|
+
npx @mui/codemod@next v4.0.0/top-level-imports <path>
|
|
2268
2429
|
```
|
|
2269
2430
|
|
|
2270
2431
|
Head to https://mui.com/guides/minimizing-bundle-size/ to understand when it's useful.
|
|
@@ -2285,7 +2446,7 @@ The diff should look like this:
|
|
|
2285
2446
|
<!-- #default-branch-switch -->
|
|
2286
2447
|
|
|
2287
2448
|
```bash
|
|
2288
|
-
npx @mui/codemod@
|
|
2449
|
+
npx @mui/codemod@next v1.0.0/import-path <path>
|
|
2289
2450
|
```
|
|
2290
2451
|
|
|
2291
2452
|
**Notice**: if you are migrating from pre-v1.0, and your imports use `material-ui`, you will need to manually find and replace all references to `material-ui` in your code to `@material-ui/core`. E.g.:
|
|
@@ -2312,7 +2473,7 @@ The diff should look like this:
|
|
|
2312
2473
|
<!-- #default-branch-switch -->
|
|
2313
2474
|
|
|
2314
2475
|
```bash
|
|
2315
|
-
npx @mui/codemod@
|
|
2476
|
+
npx @mui/codemod@next v1.0.0/color-imports <path>
|
|
2316
2477
|
```
|
|
2317
2478
|
|
|
2318
2479
|
**additional options**
|
|
@@ -2320,7 +2481,7 @@ npx @mui/codemod@latest v1.0.0/color-imports <path>
|
|
|
2320
2481
|
<!-- #default-branch-switch -->
|
|
2321
2482
|
|
|
2322
2483
|
```bash
|
|
2323
|
-
npx @mui/codemod@
|
|
2484
|
+
npx @mui/codemod@next v1.0.0/color-imports <path> -- --importPath='mui/styles/colors' --targetPath='mui/colors'
|
|
2324
2485
|
```
|
|
2325
2486
|
|
|
2326
2487
|
#### `svg-icon-imports`
|
|
@@ -2338,7 +2499,7 @@ The diff should look like this:
|
|
|
2338
2499
|
<!-- #default-branch-switch -->
|
|
2339
2500
|
|
|
2340
2501
|
```bash
|
|
2341
|
-
npx @mui/codemod@
|
|
2502
|
+
npx @mui/codemod@next v1.0.0/svg-icon-imports <path>
|
|
2342
2503
|
```
|
|
2343
2504
|
|
|
2344
2505
|
#### `menu-item-primary-text`
|
|
@@ -2356,7 +2517,7 @@ The diff should look like this:
|
|
|
2356
2517
|
<!-- #default-branch-switch -->
|
|
2357
2518
|
|
|
2358
2519
|
```bash
|
|
2359
|
-
npx @mui/codemod@
|
|
2520
|
+
npx @mui/codemod@next v1.0.0/menu-item-primary-text <path>
|
|
2360
2521
|
```
|
|
2361
2522
|
|
|
2362
2523
|
### v0.15.0
|
|
@@ -2380,5 +2541,5 @@ The diff should look like this:
|
|
|
2380
2541
|
<!-- #default-branch-switch -->
|
|
2381
2542
|
|
|
2382
2543
|
```bash
|
|
2383
|
-
npx @mui/codemod@
|
|
2544
|
+
npx @mui/codemod@next v0.15.0/import-path <path>
|
|
2384
2545
|
```
|