-
I wanted to try and change the default The usual way of using text (e.g. However, I guess using hex values for
Primary is red (#FF0000) Build and then run the server shows the page in the default Material theme colors. Tested on Chrome, FF, and Safari. I have tried using a CSS override, and that works fine, but just wanted to see if the simpler Am I doing something wrong or is this expected behavior? Thank you. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
This is expected behavior as per the docs on custom color palettes. If you want to use custom colors not aliased by the builtin color variables (
You can also define custom color palettes this way and reference them in your Hope that helps! |
Beta Was this translation helpful? Give feedback.
This is expected behavior as per the docs on custom color palettes.
If you want to use custom colors not aliased by the builtin color variables (
red
,green
,blue
,indigo
etc.), you'll need to do the following:Set the palette(s) colors to
custom
:Configure color variables in e.g.
docs/stylesheets/extra.css
:Configure Material to use the additional CSS:
You can also define custom color palettes this way and reference them in your
mkdocs.yaml
, see the first link above.Hope that helps!