diff options
| author | Gabriel Schneider <[email protected]> | 2026-07-31 02:21:01 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-08-01 15:02:08 -0300 |
| commit | 0bfa4615988c0d1bcaa38453375760c60076c5ea (patch) | |
| tree | fab4f972c10b07739aabc9d772c43e102bce2c07 /test/snapshots/theme.snap | |
| parent | be404e0d4f91548af6ed600b2fd2027ad8a041c7 (diff) | |
| download | pardes-0bfa4615988c0d1bcaa38453375760c60076c5ea.tar.gz pardes-0bfa4615988c0d1bcaa38453375760c60076c5ea.zip | |
themes: one file each, generated from helix and zed, picked by stepping a list
Each theme is a .zig file of pure data and nothing enumerates them by hand —
fold() walks the container's declarations, so a theme is a file and that is the
whole registration. Field by field rather than a wholesale coercion, which
makes a missing field a compile error that names it.
tools/gen_themes.zig reads helix .toml and zed .json out of vendor/themes and
emits one .zig each; build.zig reads that directory, so adding a theme is
dropping a file in. Output goes to the build cache rather than the tree, so zig
owns the freshness check and a deleted source cannot leave a stale theme
behind. Vendored, not read from the genizah: the build stays offline. A source
it cannot map is a hard error naming the file and the key, never a silently
black-on-black theme.
ThemeSel is the clever half. Traits gained an `executes` column, so n/N over
that buffer hands the whole line to Exec instead of the leading word to Look —
both arms the ordinary builtin, so a stepped row does exactly what the matching
mouse button on it would. Stepping the list previews each theme live. The trait
is a pane property, not an output-pane branch, so any pane whose lines are
commands can opt in.
Goldens: leader gains SPC t t; theme's fourth NextColor no longer wraps to
helix because the ring is fifteen long. New: themesel.
Diffstat (limited to 'test/snapshots/theme.snap')
| -rw-r--r-- | test/snapshots/theme.snap | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/test/snapshots/theme.snap b/test/snapshots/theme.snap index ca0b22ba..399b1950 100644 --- a/test/snapshots/theme.snap +++ b/test/snapshots/theme.snap @@ -1,9 +1,18 @@ # The theme ring, proved by style and not by text. Boot is "helix" (index 0, # the default): near-black page, tag bar one grey-ramp step off it, grey move # box. NextColor (still in the topbar) then walks to "dark" — the OLD default, -# which has to stay reachable — then to acme-light, then back around to helix. +# which has to stay reachable — then to acme-light. # Colors, which left the bar for its leader path, toggles the recolor passes # off and on from SPC t c — the same builtin either way. +# +# The fourth click used to come back around to helix, because the ring was +# three long. It is not any more: everything vendor/themes exports follows the +# three pardes ships with (pardes.zig: `curated ++ generated`), so the click +# lands on the FIRST GENERATED theme instead. That capture is named for what it +# is rather than for which theme it happens to be, because the generated half +# is sorted by name and a theme dropped into vendor/themes can take the slot. +# The wrap itself is `% themes.len` and clicking twenty times to see it is not +# worth a golden; themesel.snap covers reaching a theme by name. file t.txt x start 30 100 -n 3 wait 8000 t.txt @@ -33,5 +42,5 @@ stable 700 10000 press middle 25 1 release middle 25 1 stable 700 10000 -snap helix-again -snapstyle helix-again +snap generated +snapstyle generated |
