yarn @material-ui/core 5.0.0-alpha.8

latest releases: 4.12.4, 5.0.0-beta.5, 5.0.0-beta.4...
4 years ago
Aug 31, 2020

Big thanks to the 19 contributors who made this release possible.
Here are some highlights ✨:

const theme = createMuiTheme({
  components: {
    MuiIconButton: {
      defaultProps: {
        size: 'small',
      },
      styleOverrides: {
        sizeSmall: {
          marginLeft: 4,
          marginRight: 4,
          padding: 12,
        },
      },
    },
  },
});

@material-ui/core@v5.0.0-alpha.8

Breaking changes

  • [theme] Rename theme keys to defaultProps and styleOverrides (#22347) @mnajdova

  • [theme] Restructure component definitions (#22293) @mnajdova
    The components' definition inside the theme were restructure under the components key, to allow people easier discoverability about the definitions regarding one component.

    1. props
    import { createMuiTheme } from '@material-ui/core/styles';
    
    const theme = createMuitheme({
    -  props: {
    -    MuiButton: {
    -      disableRipple: true,
    -    },
    -  },
    +  components: {
    +    MuiButton: {
    +      defaultProps: {
    +        disableRipple: true,
    +      },
    +    },
    +  },
    });
    1. overrides
    import { createMuiTheme } from '@material-ui/core/styles';
    
    const theme = createMuitheme({
    -  overrides: {
    -    MuiButton: {
    -      root: { padding: 0 },
    -    },
    -  },
    +  components: {
    +    MuiButton: {
    +      styleOverrides: {
    +        root: { padding: 0 },
    +      },
    +    },
    +  },
    });

    Note that if you don't have the time to upgrade the structure of the theme, you
    can use the adaptV4Theme() adapter.

  • [GridList] Rename to ImageList (#22311) @mbrookes

  • [GridList] Rename Tile to Item (#22385) @mbrookes
    Rename the GridList components to ImageList to align with the current Material Design naming.

    -import GridList from '@material-ui/core/GridList';
    -import GridListTile from '@material-ui/core/GridListTile';
    -import GridListTileBar from '@material-ui/core/GridListTileBar';
    +import ImageList from '@material-ui/core/ImageList';
    +import ImageListItem from '@material-ui/core/ImageListItem';
    +import ImageListItemBar from '@material-ui/core/ImageListItemBar';
    
    -<GridList>
    -  <GridListTile>
    +<ImageList>
    +  <ImageListItem>
        <img src="file.jpg" alt="Image title" />
    -    <GridListTileBar
    +    <ImageListItemBar
          title="Title"
          subtitle="Subtitle"
        />
    -  </GridListTile>
    -</GridList>
    +  </ImageListItem>
    +</ImageList>

Changes

@material-ui/lab@v5.0.0-alpha.8

  • [docs] Add IntelliSense for each class in the classes prop (#22312) @eps1lon

@material-ui/styles@v5.0.0-alpha.8

@material-ui/utils@v5.0.0-alpha.8

Docs

Core

Don't miss a new core release

NewReleases is sending notifications on new releases.