Skip to content

Commit

Permalink
[docs] Remove wrong migration instruction (#22710)
Browse files Browse the repository at this point in the history
Co-authored-by: Matt <[email protected]>
  • Loading branch information
oliviertassinari and mbrookes authored Sep 25, 2020
1 parent 58baccd commit 0acf4de
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 21 deletions.
9 changes: 0 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,6 @@ Here are some highlights ✨:
theme.spacing(2) => '16px'
```

You can restore the previous behavior with:

```diff
-const theme = createMuiTheme();
+const theme = createMuiTheme({
+ spacing: x => x * 8,
+});
```

- [theme] Remove palette.text.hint key (#22537) @mbrookes

The `theme.palette.text.hint` key was available but unused in Material-UI v4 components.
Expand Down
6 changes: 3 additions & 3 deletions docs/src/pages/customization/spacing/spacing.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Material-UI uses [a recommended 8px scaling factor](https://material.io/design/l
```js
const theme = createMuiTheme();

theme.spacing(2); // = 8 * 2
theme.spacing(2); // `${8 * 2}px` = '16px'
```

## Custom spacing
Expand All @@ -21,7 +21,7 @@ const theme = createMuiTheme({
spacing: 4,
});

theme.spacing(2); // = 4 * 2
theme.spacing(2); // `${4 * 2}px` = '8px'
```

- a function
Expand All @@ -41,7 +41,7 @@ const theme = createMuiTheme({
spacing: [0, 4, 8, 16, 32, 64],
});

theme.spacing(2); // = 8
theme.spacing(2); // = '8px'
```

## Multiple arity
Expand Down
9 changes: 0 additions & 9 deletions docs/src/pages/guides/migration-v4/migration-v4.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,15 +123,6 @@ The following changes are supported by the adapter.
theme.spacing(2) => '16px'
```

You can restore the previous behavior with:

```diff
-const theme = createMuiTheme();
+const theme = createMuiTheme({
+ spacing: x => x * 8,
+});
```

- The `theme.palette.text.hint` key was unused in Material-UI components, and has been removed.

```diff
Expand Down

0 comments on commit 0acf4de

Please sign in to comment.