github mantinedev/mantine 4.2.0

latest releases: 7.13.2, 7.13.1, 7.13.0...
2 years ago

View changelog with demos on Mantine docs website

primaryShade on theme

New theme.primaryShade property is used to determine which shade will be used for the components that have color prop,
it defaults to 6. Note that for some variants with dark color scheme primaryShade will not be used as it will cause contrast issues.

import { MantineProvider, Group, Button } from '@mantine/core';

function Demo() {
  return (
    <MantineProvider theme={{ primaryShade: 6 }}>
      <App />
    </MantineProvider>
  );
}

primaryShade can also be customized for dark and light color scheme separately:

import { MantineProvider } from '@mantine/core';

function Demo() {
  return (
    <MantineProvider theme={{ primaryShade: { light: 6, dark: 8 } }}>
      <App />
    </MantineProvider>
  );
}

New features

Don't miss a new mantine release

NewReleases is sending notifications on new releases.