Extending the Theme
To add a new variable:
-
Add it to both
:root.lightand:root.darkblocks invariables.css::root.light {
/* existing variables... */
--my-custom-color: #abcdef;
}
:root.dark {
/* existing variables... */
--my-custom-color: #123456;
} -
Use it in your component:
.my-element {
color: var(--my-custom-color);
}