Usage
You can use @carbon/themes in JavaScript or Sass by including this package in your project. By default, @carbon/themes provides a set of color tokens that are pre-defined for a specific theme. Currently, we offer the following color themes: white, gray 10, gray 90, gray 100.
You can preview all of the token values for this on the color guidelines page.
By default, the white theme will be initialized. If you would like to include another theme, you can do so by configuring the sass module using with. For example:
Inline theming of theme switching can be done by using the mixin. For example:
Themes can also be extended with your own custom tokens:
Some designs include a sections in the opposite theme.