diff --git a/README.md b/README.md index a49a6457..c32bbdc0 100644 --- a/README.md +++ b/README.md @@ -64,24 +64,24 @@ The easiest way to use other base16 styles is to place .css file from https://gi Or to define a wholly custom theme, you will need to define the following CSS variables for the following base16 colours (see [base16-dark.css](blob/main/static/css/palettes/base16-dark.css) for an example): -| Base | Default colour | Used for | Examples | -| ---- | -------------- | -------- | -------- | -| 00 | Dark | Background | Page background | -| 01 | │ | Alt. background | Content background | -| 02 | │ | In-text backgrounds | `
`, ``, ``, `` |
-| 03   | │              | Muted text | `:before` & `:marker` symbols |
-| 04   | │              | Alt. foreground | Aside text          |
-| 05   | │              | Foreground         | Content text         |
-| 06   | │              |          |          |
-| 07   | Light          |          |          |
-| 08   | Red            |          |          |
-| 09   | Orange         |          |          |
-| 0A   | Yellow         | Highlights | Selected text, `` |
-| 0B   | Green          | Primary accent | Logo          |
-| 0C   | Cyan           | Active links | `a:active`, `a:hover`         |
-| 0D   | Blue           | Links    | `a:link`, `a:visited`         |
-| 0E   | Magenta        |          |          |
-| 0F   | Brown          |          |          |
+| Base | Default colour                             | Used for            | Examples                             |
+| ---- | ------------------------------------------ | ------------------- | ------------------------------------ |
+| 00   | Dark           | Background          | Page background                      |
+| 01   |               | Alt. background     | Content background                   |
+| 02   |               | In-text backgrounds | `
`, ``, ``, `` |
+| 03   |               | Muted text          | `:before` & `:marker` symbols        |
+| 04   |               | Alt. foreground     | Aside text                           |
+| 05   |               | Foreground          | Content text                         |
+| 06   |               |                     |                                      |
+| 07   | Light          |                     |                                      |
+| 08   | Red            |                     |                                      |
+| 09   | Orange         |                     |                                      |
+| 0A   | Yellow         | Highlights          | Selected text, ``              |
+| 0B   | Green          | Primary accent      | Logo                                 |
+| 0C   | Cyan           | Active links        | `a:active`, `a:hover`                |
+| 0D   | Blue           | Links               | `a:link`, `a:visited`                |
+| 0E   | Magenta        |                     |                                      |
+| 0F   | Brown          |                     |                                      |
 
 For light mode palettes, the sequence of 00–07 should be reversed (light to dark, not dark to light).
 Note that not all colours are currently used in the theme.
diff --git a/static/css/typography.css b/static/css/typography.css
index fcf63b6e..086cd40e 100644
--- a/static/css/typography.css
+++ b/static/css/typography.css
@@ -219,3 +219,37 @@ img {
     height: auto;
 }
 
+/* Colour classes */
+.base00 { color: var(--base00); }
+.base01 { color: var(--base01); }
+.base02 { color: var(--base02); }
+.base03 { color: var(--base03); }
+.base04 { color: var(--base04); }
+.base05 { color: var(--base05); }
+.base06 { color: var(--base06); }
+.base07 { color: var(--base07); }
+.base08 { color: var(--base08); }
+.base09 { color: var(--base09); }
+.base0A { color: var(--base0A); }
+.base0B { color: var(--base0B); }
+.base0C { color: var(--base0C); }
+.base0D { color: var(--base0D); }
+.base0E { color: var(--base0E); }
+.base0F { color: var(--base0F); }
+
+.bg-base00 { background-color: var(--base00); }
+.bg-base01 { background-color: var(--base01); }
+.bg-base02 { background-color: var(--base02); }
+.bg-base03 { background-color: var(--base03); }
+.bg-base04 { background-color: var(--base04); }
+.bg-base05 { background-color: var(--base05); }
+.bg-base06 { background-color: var(--base06); }
+.bg-base07 { background-color: var(--base07); }
+.bg-base08 { background-color: var(--base08); }
+.bg-base09 { background-color: var(--base09); }
+.bg-base0A { background-color: var(--base0A); }
+.bg-base0B { background-color: var(--base0B); }
+.bg-base0C { background-color: var(--base0C); }
+.bg-base0D { background-color: var(--base0D); }
+.bg-base0E { background-color: var(--base0E); }
+.bg-base0F { background-color: var(--base0F); }