vole
Site
Clone
Read only, no credentials:
https://rodent.software/vole.git
Write over SSH with a registered key:
git clone ssh://git@rodent.software/vole.git
Self-hosted forge that lives in your Git repo.
Restructure documentation around reader tasks
348a43c364fbb04be834af44a7cd43a0931fa280 · Keenan Nemetz · 20d ago · parent b7383c19
Restructure documentation around reader tasks Group the site by getting started, collaboration, CI, publishing, and administration. Rewrite the guides as executable procedures and move issue formats, merge semantics, configuration defaults, customization, and access-control mechanics into dedicated references. Verify the quickstart and review flow against a throwaway instance, execute the service recipe, inspect the rendered site, and run the complete verify workflow. Closes: 01M7B6X6RDYBAP3JVA5SYSA1K8
docs/reference/instance-customization.md +127
| @@ -0,0 +1,127 @@ | |||
| 1 | # Instance customization | ||
| 2 | |||
| 3 | The repository named by `instance_repo` supplies the instance introduction, | ||
| 4 | styles, favicon, and static assets. It is an ordinary private repository by | ||
| 5 | default; visitors can receive its designated public files without receiving | ||
| 6 | repository access. For setup, see | ||
| 7 | [Customizing the instance](../configuration.md#customizing-the-instance). | ||
| 8 | |||
| 9 | ## Customization paths | ||
| 10 | |||
| 11 | | Path | What it does | | ||
| 12 | |---|---| | ||
| 13 | | `profile/README.md` | Sanitized Markdown introduction above the repository list | | ||
| 14 | | `profile/private/README.md` | Replaces the introduction for signed-in viewers | | ||
| 15 | | `profile/custom.css` | Styles loaded after built-in and selected theme styles | | ||
| 16 | | `profile/themes/<id>.css` | One self-describing selectable theme per file | | ||
| 17 | | `profile/favicon.svg` | Replaces the favicon links | | ||
| 18 | | `assets/` | Files served at `/-/static/custom/assets/` | | ||
| 19 | |||
| 20 | Other files are ignored. Assets are limited to CSS, images, and fonts; | ||
| 21 | same-origin scripts are not accepted as customization. Push changes to publish | ||
| 22 | them. Vole reloads the snapshot within a few seconds and keeps the previous | ||
| 23 | snapshot when loading fails. An empty `profile/README.md` removes the | ||
| 24 | introduction body. | ||
| 25 | |||
| 26 | `instance_name` controls the landing-page heading, document titles, and brand | ||
| 27 | link's accessible name. It does not rename the Vole software or replace its | ||
| 28 | brand mark. | ||
| 29 | |||
| 30 | ## Theming | ||
| 31 | |||
| 32 | `profile/custom.css` loads after `vole.css`, `everforest.css`, `palettes.css`, | ||
| 33 | and the selected theme pack. Override design tokens instead of copying component | ||
| 34 | rules so layout, contrast, and responsive behavior remain intact. | ||
| 35 | |||
| 36 | The Appearance picker includes built-in Everforest variants, Catppuccin Mocha | ||
| 37 | and Latte, Nord, Solarized Light, Rosé Pine Moon and Dawn, Kanagawa Wave, | ||
| 38 | Dracula, Tokyo Night, and Ayu Light, followed by instance theme packs. | ||
| 39 | |||
| 40 | ### Theme packs | ||
| 41 | |||
| 42 | Each file under `profile/themes/` defines one theme. Its file name supplies both | ||
| 43 | the id and a human-readable label: `acme-ocean.css` becomes **Acme Ocean**. | ||
| 44 | |||
| 45 | ```css | ||
| 46 | /* profile/themes/acme-ocean.css */ | ||
| 47 | :root[data-theme="acme-ocean"] { | ||
| 48 | color-scheme: dark; | ||
| 49 | --bg: #0b1720; | ||
| 50 | --bg-panel: #102433; | ||
| 51 | --bg-raised: #163041; | ||
| 52 | --fg: #d7e8f0; | ||
| 53 | --fg-muted: #8fb0c0; | ||
| 54 | --fg-faint: #6f8f9f; | ||
| 55 | --accent: #38bdf8; | ||
| 56 | --accent-fg: #04121a; | ||
| 57 | --accent-soft: color-mix(in srgb, var(--accent) 14%, transparent); | ||
| 58 | } | ||
| 59 | ``` | ||
| 60 | |||
| 61 | A light theme must set `color-scheme: light` and light surface and text tokens: | ||
| 62 | |||
| 63 | ```css | ||
| 64 | /* profile/themes/acme-paper.css */ | ||
| 65 | :root[data-theme="acme-paper"] { | ||
| 66 | color-scheme: light; | ||
| 67 | --bg: #fffdf7; | ||
| 68 | --bg-panel: #f8f3e8; | ||
| 69 | --bg-raised: #f1eadc; | ||
| 70 | --fg: #2b2a26; | ||
| 71 | --fg-muted: #6b675d; | ||
| 72 | --fg-faint: #8d887c; | ||
| 73 | --accent: #9a5b13; | ||
| 74 | --accent-fg: #fffdf7; | ||
| 75 | --accent-soft: color-mix(in srgb, var(--accent) 14%, transparent); | ||
| 76 | } | ||
| 77 | ``` | ||
| 78 | |||
| 79 | Theme ids use lowercase letters, digits, and dashes and are at most 41 | ||
| 80 | characters. They cannot collide with `system`, `nord`, `dracula`, `tokyo-night`, | ||
| 81 | or names beginning with `everforest-`, `catppuccin-`, `solarized-`, `rose-pine-`, | ||
| 82 | `kanagawa-`, or `ayu-`. An invalid file fails snapshot loading and leaves the | ||
| 83 | previous theme active. | ||
| 84 | |||
| 85 | Every theme file is linked on every page, so keep theme packs small. A reader's | ||
| 86 | selection lives in browser `localStorage`, not in the account database. Deleting | ||
| 87 | a selected theme returns that browser to System. | ||
| 88 | |||
| 89 | ### Design tokens | ||
| 90 | |||
| 91 | Scope overrides to `:root[data-theme]`, not plain `:root`. Built-in selectors | ||
| 92 | such as `:root[data-theme^="everforest-"]` are more specific than `:root` and | ||
| 93 | would otherwise win. | ||
| 94 | |||
| 95 | ```css | ||
| 96 | :root[data-theme] { | ||
| 97 | --accent: #c678dd; | ||
| 98 | --accent-soft: color-mix(in srgb, var(--accent) 14%, transparent); | ||
| 99 | --radius: 4px; | ||
| 100 | --radius-lg: 6px; | ||
| 101 | --page-max: 1200px; | ||
| 102 | } | ||
| 103 | ``` | ||
| 104 | |||
| 105 | Use these selectors when a value differs between Everforest dark and light | ||
| 106 | variants: | ||
| 107 | |||
| 108 | ```css | ||
| 109 | :root[data-theme^="everforest-dark"] { --bg: #101418; } | ||
| 110 | :root[data-theme^="everforest-light"] { --bg: #fffdf7; } | ||
| 111 | ``` | ||
| 112 | |||
| 113 | | Group | Tokens | | ||
| 114 | |---|---| | ||
| 115 | | Surfaces | `--bg`, `--bg-panel`, `--bg-raised`, `--bg-hover`, `--bg-active`, `--border`, `--border-strong` | | ||
| 116 | | Text | `--fg`, `--fg-muted`, `--fg-faint` | | ||
| 117 | | Identity | `--accent`, `--accent-fg`, `--accent-soft` | | ||
| 118 | | Status | `--good`, `--good-soft`, `--bad`, `--bad-soft`, `--warn`, `--warn-soft`, `--running`, `--merged`, `--merged-soft`, `--status-fg` | | ||
| 119 | | Shape | `--radius`, `--radius-lg`, `--page-max`, `--page-gutter`, `--search-w` | | ||
| 120 | | Type | `--font`, `--mono`, `--fs`, `--lh`; leave `--font-scale` to the reader's text-size preference | | ||
| 121 | | Syntax | `--syn-comment`, `--syn-punctuation`, `--syn-operator`, `--syn-number`, `--syn-string`, `--syn-keyword`, `--syn-function`, `--syn-type`, `--syn-variable`, `--syn-added`, `--syn-deleted` | | ||
| 122 | |||
| 123 | When tokens are insufficient, page-level classes include `.panel`, `.readme`, | ||
| 124 | `.md`, `.repo-card`, `.repo-grid`, `.home-grid`, `.home-rail`, `.repohead`, | ||
| 125 | `.tabs`, `.chip`, `.label`, `.status`, `.config-table`, `.diff`, and `.blob`. | ||
| 126 | These classes are not a stable public API; prefer tokens because upgrades can | ||
| 127 | change markup. | ||