With Poole as a baseline theme for Jekyll, there aren’t many options available out of the box. Basic light and dark mode support is included. Colors are also provided for your own customization, while other Poole themes build on this to create more unique looks.
Dark mode is enabled automatically via CSS media query—you’ll find the source code for this in the _sass/_variables.scss
stylesheet. If you’re familiar with CSS custom properties, you can also use this method to build your own color schemes.
Read more about using CSS dark mode via media queries like this:
// Example media query to detect dark mode
@media (prefers-color-scheme: dark) {
// ...
}
If you want to make your own color schemes, modify the CSS variables in the _sass/_variables.scss
stylesheet with a scoped data attribute or class name.
For example, below we’ve created the beginnings of a blue theme:
// Example blue theme
[data-theme="blue"] {
--body-bg: var(--blue);
--body-color: #fff;
}
Then, apply the theme by adding data-theme="blue"
to the <html>
element.
Change your site styles by modifying the source code with these CSS custom properties. Poole’s colors come from the Open Color project.
There are also ten grayscale colors to choose from.
Specify ga_analytics
in your _config.yml
and restart the server to add Google Analytics tracking code.
# Google Analytics example
ga_analytics: UA-000000-0