Skip to content
Cortex

Getting Started With Themes

Create a minimal Cortex theme with a manifest, light.css, dark.css, and vault install location.

1 min readEdit on GitHub

This guide creates a minimal light/dark community theme.

Scaffold#

bash
cortex create warm-notes --themecd warm-notes

The CLI writes a theme that loads in Cortex as-is, with CI and release workflows. The minimal shape is:

text
warm-notes/
  manifest.json
  light.css
  dark.css

Manifest#

json
{	"id": "warm-notes",	"name": "warm-notes",	"displayName": "Warm Notes",	"author": "Your Name",	"version": "0.1.0",	"minAppVersion": "0.1.0",	"colorschemes": {		"light": "light.css",		"dark": "dark.css"	}}

name must equal id; it becomes the theme family name. version is plain MAJOR.MINOR.PATCH. Cortex registers two runtime theme names:

  • warm-notes-light
  • warm-notes-dark

Light CSS#

css
body.theme-warm-notes-light {	color-scheme: light;	--bg-primary: #fbfaf6;	--bg-secondary: #f2efe8;	--bg-elevated: #ffffff;	--text-primary: #2a2621;	--text-muted: #756d62;	--accent: #b84f35;	--accent-hover: #a6462f;	--accent-subtle: #f5ded6;	--border: #ded7ca;	--modal-bg: #ffffff;	--menu-bg: #ffffff;	--markdown-content-width: 760px;}

Dark CSS#

css
body.theme-warm-notes-dark {	color-scheme: dark;	--bg-primary: #201f1d;	--bg-secondary: #2a2825;	--bg-elevated: #302e2a;	--text-primary: #f2ece2;	--text-muted: #aaa197;	--accent: #e0795d;	--accent-hover: #ee8a6e;	--accent-subtle: #4a2b25;	--border: #403b35;	--modal-bg: #2a2825;	--menu-bg: #2a2825;	--markdown-content-width: 760px;}

Run It in a Vault#

bash
cortex dev --vault ~/Notes

cortex dev copies the theme into <vault>/.cortex/themes/warm-notes and recopies it on every change. --once installs and exits; --clean removes the development copy. Prefer it over symlinking the folder: the hot-reload watcher does not follow symlinks.

Cortex watches <vault>/.cortex/themes. Editing a theme file triggers a reload. If the active theme is the edited family, Cortex reapplies the current appearance settings after reload.

Run cortex check before releasing to apply the same checks as the Marketplace registry.

Next steps#

Search docs

Search Cortex documentation pages and headings.