Solo is a Jekyll theme. It does single-page websites only, and it does them well. Yes, it’s responsive. This page is a pixel-for-pixel port of Solo to Eleventy — same layout, same fonts, same elements — plus one thing Solo never had: color themes.
Try the two controls in the upper right corner.
This page runs on Solo. It comes from one markdown file.
The port leaves Solo’s layout, type and spacing alone. Everything below is new:
You need Node.js. Clone the repository, then:
npm install
npm start
Eleventy serves the site at http://localhost:8080 and rebuilds on save. npm run build writes the finished site to _site.
You edit src/index.md. It becomes the page.
src/_data/site.json to change the site’s title and description.src/_data/solo.js for Solo’s own colors, or src/_data/palettes.json for the rest.src/_includes/head.njk to add custom code to <head>.src/_includes/scripts.njk to add custom code before </body>.CNAME, robots.txt — into src/static/.README.md before pushing your code.<h1> tagsSkip <h1> tags in src/index.md. The site title owns that level.
Two controls sit in the upper right. They work on separate axes, the same split yolo-11ty uses:
Every palette ships a light and a dark rendering, so the two controls compose.
Pick Matrix Green, then toggle to dark, and you get Matrix Green’s dark variant.
The browser keeps both choices in localStorage.
Solo’s own palette compiles into css/main.css. It paints before a line of
JavaScript runs, in the exact colors of the original Jekyll theme. The other 67
live in src/_data/palettes.json, and a script applies them as CSS custom
properties on <html>. Each palette is twelve colors per mode:
{
"id": "matrix-green",
"name": "Matrix Green",
"light": {
"bg": "#F0FFF4", "text": "#003B00", "heading": "#006400",
"link": "#008000", "primary": "#00C853", "surface": "#ffffff",
"border": "#A5D6A7", "shKeyword": "#008000", "shString": "#2E7D32",
"shFunction": "#00C853", "shVariable": "#1B5E20", "shComment": "#81C784"
},
"dark": { "...": "..." }
}
expand() in src/_includes/theme-init.njk widens those twelve. It fills the
~50 custom properties the stylesheet uses, down to the whole Pygments/Rouge
syntax palette. Add an entry to any group in palettes.json and it shows up in
the menu. Delete one and it’s gone.
For a different default, set theme.default in src/_data/site.json to any
palette id, and theme.mode to light, dark, or auto. Set
theme.switcher to false and both controls disappear. The page then matches
Solo byte for byte.
Everything below is plain markdown, and the theme renders it. Treat it as a proving ground. Switch palettes while you scroll to see every element in every theme.
The site title owns <h1>, so headings on the page start at level 2. Level 2
has its own size. Levels 3 through 6 share a single style.
A plain paragraph, with emphasis, strong emphasis, both at once,
strikethrough, inline code, and a link.
Typographic replacement is on, the way kramdown had it. “Double quotes” and ‘single quotes’ curl. An en dash – and an em dash — fill in. An ellipsis… collapses to one character.
Two trailing spaces end a line
and force a hard break, with no new paragraph.
A backslash escapes markdown syntax, so *this* keeps its asterisks.
Unordered, nested three deep:
Ordered, with a nested ordered list:
A list can start at any number:
Task lists work too:
A loose list puts blank lines between the items. Markdown then wraps each item in a paragraph, which widens the spacing:
The first item, in its own paragraph.
The second item, likewise.
Definition lists come from kramdown, and Solo styles them, so they are here:
dd carries a 1.5rem left margin.A blockquote takes the muted text color and a quarter-rem rule in the border color.
It can hold more than one paragraph. The last one drops its bottom margin, so the box closes tight.
Blockquotes nest:
and the inner one picks up the same border and color again.
Inline code sits on the --code-bg background. Every fenced block gets a
header bar, borrowed from yolo-11ty.
The label names the language. Click anywhere on the bar to copy the block.
A fence with a language gets highlighted at build time, and takes its label from the language:
const palettes = require("./palettes.json");
// Widen twelve colors into the fifty the stylesheet wants.
function expand(palette) {
return Object.assign({}, palette, {
muted: mix(palette.text, palette.bg, 0.75),
});
}
def kramdown_slug(text):
"""The heading ids Solo's pages used."""
return re.sub(r"[^a-z0-9 -]", "", text.lower()).replace(" ", "-")
.container {
max-width: 30rem;
margin: 0 auto;
}
Anything after the language becomes a custom label, so ```yaml Front matter
gives this:
layout: layouts/default.njk
permalink: 404.html
A fence with no language gets the same frame, no highlighting, and a plain
Text label:
$ npm run build
[11ty] Wrote 3 files in 0.06 seconds
An indented block — four spaces — works the same way:
git clone https://github.com/corbtastik/solo
npm install
Styled after yolo-11ty. The header row takes the theme’s accent, the same one the code block header uses, and every internal rule is drawn in it. Click any column header to sort. Click again to reverse.
| Player | BA | HR |
|---|---|---|
| Hank Aaron | .305 | 755 |
| Babe Ruth | .342 | 714 |
| Mookie Wilson | .274 | 67 |
Numeric columns sort as numbers. So 67 lands below 714, not between .305
and 714.
Columns take alignment from the separator row:
| Left | Centered | Right |
|---|---|---|
| Hank Aaron | Right-fielder | .305 |
| Babe Ruth | Outfielder | .342 |
| Mookie Wilson | Center-fielder | .274 |
And a plain reference table:
| Element | Token | Shows up in |
|---|---|---|
| Body text | --text |
Paragraphs, lists |
| Links | --link |
Anchors |
| Rules | --rule |
<hr> and blockquote borders |
| Code | --code-bg |
<pre> and <code> |
An inline link, a link with a title, a bare autolink https://www.11ty.dev/, and a reference link defined below.
The theme centers images and caps them at the column width:
Footnotes are another kramdown feature.[1] They collect at the bottom of the page, under a rule.[2]
Three or more hyphens, asterisks, or underscores make a rule:
Raw HTML passes straight through. So ⌘ + K, marked text, H2O, 210, and CSS all work.
Plain markdown images take the default <img> styling. The theme centers them
and caps them at the column width, so a photo of any size drops in without
overflowing:


For a set size, reach for the size and ratio classes. They are the same set
yolo-11ty uses. Markdown’s ![]()
has nowhere to put a class, so write a raw <img>:
<img class="is-256" src="bluebonnet.jpg" alt="Bluebonnet">
Each class sets a width and an aspect ratio. object-fit: cover crops the photo
to fill the box, so nothing gets squashed.
128px square. Use the thumbnail class.
Classes: is-16 through is-512.
Classes: is-circle-16 through is-circle-512.
Classes: is-100-by-75 through is-640-by-480.
Classes: is-75-by-100 through is-480-by-640.
Classes: is-112-by-63 through is-640-by-360.
Classes: is-63-by-112 through is-360-by-640.
The grid shows images inline. Click one to enlarge it, click again to shrink it.
The arrows and the left and right keys step through the set, and Escape closes
it. The grid comes from yolo-11ty, down
to the data format — its ig-*.yml files drop straight in.
src/_data/ig-images.yml.imageGrid shortcode.{% imageGrid %}












Any file in src/_data/ with an ig- prefix works. The second argument sets
the column count:
{% imageGrid "ig-camping", 2 %}




Embedded video, after yolo-11ty. Add
entries to src/_data/videos.yml, then call the shortcode:
{% video %}
Each entry is name, src and description. The src is an embed URL. For
YouTube that is https://youtube.com/embed/<id>. Pass a different data file as
an argument, the way the image grid does: {% video "talks" %}.
corbtastik built this Eleventy port.
Solo is the original — a Jekyll theme for single-page websites. Shu Uesugi wrote it and released it under the MIT License in 2014. The layout, the 30rem column, the type scale, the spacing, the two typefaces and the syntax palette on this page are all his work. This port only moves them to a different generator. None of the design is mine.
| Reference | Link |
|---|---|
| Original theme | github.com/chibicode/solo |
| Original demo | chibicode.github.io/solo |
| Author | Shu Uesugi (@chibicode) |
| Successor theme | Duo, which Shu recommends over Solo |
Also carried over or borrowed:
_sass/_syntax.scss, kept to the hex value.MIT, the same license Solo carries.