@v1nvn/statusline 0.27.3 → 0.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -9,8 +9,6 @@ User-facing docs: [root README § statusline](../../README.md#statusline).
9
9
 
10
10
  ## Quickstart
11
11
 
12
- The wizard is the way to configure — both surfaces, live previews, enter saves.
13
-
14
12
  Install once (the runtime the keys point at lives in the plugin cache):
15
13
 
16
14
  ```sh
@@ -18,41 +16,40 @@ claude plugin marketplace add v1nvn/agentic
18
16
  claude plugin install statusline@agentic
19
17
  ```
20
18
 
21
- In Claude Code — type `/lab`, run the wizard it hands you (`!`
22
- runs it in your session with a real terminal):
23
-
24
- ```
25
- ! npx -y @v1nvn/statusline@0.27.3 configure
26
- ```
19
+ In Claude Code — type `/lab`: the agent sketches the themes as plain renders,
20
+ offers the picker in chat, and writes the pick.
27
21
 
28
- In a terminal — same command, bare:
22
+ In a terminal outside Claude Code — the wizard, the terminal guide:
29
23
 
30
24
  ```sh
31
- npx -y @v1nvn/statusline@0.27.3 configure
25
+ npx -y @v1nvn/statusline@0.28.0 configure
32
26
  ```
33
27
 
34
- `j/k` move · `h/l` switch design · `s` sets the focused item to none · `w`
35
- width · enter saves · `q` cancels.
28
+ Pass one stacks the five theme bars: `j/k` focus · `w` width · enter picks.
29
+ Pass two refines the pick: `j/k` move · `h/l` variant · `s` none · `t` back
30
+ to the themes · `w` width · enter saves · `q` cancels.
36
31
 
37
32
  ## Usage
38
33
 
39
- One CLI, both ways: `/lab` inside a session runs these same
40
- commands; `npx` runs them in a terminal. Every subcommand takes `--home <dir>`
41
- to operate on another home instead of `$HOME`.
34
+ One CLI, both ways: `/lab` inside a session runs these same commands; `npx`
35
+ runs them in a terminal. Every subcommand takes `--home <dir>` to operate on
36
+ another home instead of `$HOME`.
42
37
 
43
38
  | Command | Does |
44
39
  |---|---|
45
- | `configure` | bare on a TTY: the wizard. With flags: strict — `--layout '{model effort} {cwd branch}'` names the items, every unflagged item needs `--fallback=default\|existing`; `--dry-run` renders without writing; a foreign key needs `--force` |
46
- | `catalog` | one line per item, `*` marks the live variant |
40
+ | `configure` | write both settings keys. Bare on a TTY: the wizard. With flags: `--theme <name>` (quiet, lean, classic, rich, custom) is the base design, item flags override it, `--layout` overrides its layout; a layout item nothing picks is an error naming it; a foreign key needs `--force` |
41
+ | `preview` | render the candidate bar and panel row through the same resolution `configure` uses, writing nothing; `--plain` strips the color escapes so glyphs survive chat |
42
+ | `catalog` | the themes block (`*` marks the live theme) then one line per item, `*` marking the live variant; `--themes` cuts to the block |
47
43
  | `status` | one row per fact plus a verdict — exit 0 healthy, 1 needs action, every action row names its fix |
48
44
  | `restore` | both keys back to their pre-lab values from `backup.json`, then deletes the lab data — `--dry-run` prints the plan; `--force` splices over a key changed after the takeover |
49
45
 
50
46
  ```sh
51
- npx -y @v1nvn/statusline@0.27.3 catalog
52
- npx -y @v1nvn/statusline@0.27.3 configure --model block --bar gauge --fallback=default --dry-run # preview, write nothing
53
- npx -y @v1nvn/statusline@0.27.3 configure --model block --bar gauge --fallback=default # the write
54
- npx -y @v1nvn/statusline@0.27.3 status
55
- npx -y @v1nvn/statusline@0.27.3 restore
47
+ npx -y @v1nvn/statusline@0.28.0 preview --theme rich --plain # chat-safe sketch, nothing written
48
+ npx -y @v1nvn/statusline@0.28.0 configure --theme rich # the write — live on the next paint
49
+ npx -y @v1nvn/statusline@0.28.0 configure --theme rich --bar percent # one swap on top of the theme
50
+ npx -y @v1nvn/statusline@0.28.0 catalog --themes
51
+ npx -y @v1nvn/statusline@0.28.0 status
52
+ npx -y @v1nvn/statusline@0.28.0 restore
56
53
  ```
57
54
 
58
55
  ## Develop
@@ -69,14 +66,17 @@ Node ≥ 22. One workspace dep: `@v1nvn/agentic-core` (usage/exit helpers).
69
66
 
70
67
  | File | Role |
71
68
  |---|---|
72
- | `src/cli.ts` | commander wiring — four subcommands, help text |
69
+ | `src/cli.ts` | commander wiring — five subcommands, help text |
73
70
  | `src/index.ts` | bin entry — verb dispatch, exit codes, wizard TTY deps |
74
- | `src/configure.ts` | the writer — key composition, ours-matcher, JSON splice engine, backup write, dry-run render |
71
+ | `src/configure.ts` | the writer — theme + flag resolution, key composition, ours-matcher, JSON splice engine, backup write |
75
72
  | `src/resolve.ts` | runtime resolution + key parsing — the one resolution way |
76
73
  | `src/restore.ts` | revert decision tree + explicit-path cleanup |
77
- | `src/status.ts` | diagnostic rows + verdict |
78
- | `src/catalog.ts` | item listing, live variant starred |
79
- | `src/wizard.ts` · `src/wizard-tui.ts` | the terminal wizard — previews both surfaces, saves via `configure` |
74
+ | `src/status.ts` | diagnostic rows + verdict, the live theme named |
75
+ | `src/catalog.ts` | themes block + item listing, live picks starred |
76
+ | `src/themes.ts` | the five theme bundles — layout, one variant per item, summary |
77
+ | `src/live-theme.ts` | the shared matcher — the theme a key equals exactly |
78
+ | `src/preview.ts` | the preview command — a candidate rendered, nothing written |
79
+ | `src/wizard.ts` · `src/wizard-tui.ts` | the terminal wizard — theme pass, then refinement seeded from the pick |
80
80
  | `src/payloads.ts` · `src/demo-repo.ts` | preview plumbing — spawns the runtime with env + stdin; demo git repo for fixtures |
81
81
  | `assets/` | preview fixtures — `payloads/p1–p4.json` (main surface), `ticks/multi.json` (panel) |
82
82
 
@@ -86,6 +86,11 @@ Node ≥ 22. One workspace dep: `@v1nvn/agentic-core` (usage/exit helpers).
86
86
  else on disk except `backup.json` and `captures/`.
87
87
  - The key value is one inline shell command: resolver statement first, env
88
88
  assignments hugging `bash` last; statement order is pinned by golden tests.
89
+ - A theme is configure-time only: a theme write and a flags write of the same
90
+ values produce identical settings text — the runtime never learns themes
91
+ exist.
92
+ - The live theme is re-derived by matching the key against the bundles; no
93
+ theme name is stored in settings.
89
94
  - One resolution way: the newest-plugin-cache glob — `installed_plugins.json`
90
95
  is read nowhere.
91
96
  - One splice home: the settings.json span primitives live in `configure.ts`;