Add a per-file word-count-target bar in the file list

Each file row now shows a compact progress bar beside its name when the
file sets a Word Count Target, alongside the existing detailed bar in the
status bar for the active file. Same colour scheme (amber under / green in
range / blue over) and a hover tooltip with the exact words / target.

The per-file slug/POV cache is generalised to a FileMeta (slug, POV, goal,
prose word count), filled on open and refreshed on save; the selected
file's row reads live from the buffer so its bar tracks as you type.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N9kRuP7JvXoUGdNNeg5ZSs
This commit is contained in:
landon
2026-08-14 06:55:09 -05:00
parent c926b6696f
commit 894a0746e3
2 changed files with 81 additions and 36 deletions
+13 -4
View File
@@ -121,12 +121,21 @@ any heading level):
## Word Count Target: 1500 - 2000
```
A **progress bar** then appears in the status bar, comparing the file's **prose**
A **progress bar** then appears in two places, comparing the file's **prose**
word count (the body below the draft marker, so header metadata isn't counted)
against the target: **amber** while under the target, **green** once inside the
range, **blue** when over it. A single number (`## Word Count Target: 1800`) sets
a point goal; ranges accept `-`, ``, `to`, and grouped digits (`1,500`). Like
the other header lines, the target is stripped from the exported document.
range, **blue** when over it.
* A **compact bar beside the file name** in the left pane, so you can scan every
chapter's progress at a glance (hover it for the exact `words / target`). It
updates live as you type in the open file, and reflects the last saved state
for the others.
* A larger, labelled bar in the **status bar** for the file you're currently
editing.
A single number (`## Word Count Target: 1800`) sets a point goal; ranges accept
`-`, ``, `to`, and grouped digits (`1,500`). Like the other header lines, the
target is stripped from the exported document.
## Spelling (offline)