Repository navigation
Description
Problem
The reader's chosen appearance follows them into PDFs (components/pdf-reader/style.module.scss:136-140), notes, text, HTML and source code (features/reader/markdown-reader/style.module.scss:52-103, applied via data-reading-theme from reading-preferences.ts) — the extensions shipped as #44 and #208. The spreadsheet grids are the one reading surface left outside: features/reader/xlsx-reader/style.module.scss paints cells, headers and gutters from the app palette (--surface, --panel, --line), which styles.css:7-10 defines light-only, with fixed 13px cells and no data-reading-theme hook; neither xlsx-reader/index.tsx nor csv-reader.tsx offers or reads any appearance setting. A reader working in Dark or Paper opens a workbook or CSV to a bright light pane that ignores their choice — the exact failure shape #208 described for code files.
Proposal
- Apply the existing Markdown reading theme (Light/Paper/Dark) to the xlsx and CSV grids, through the same
data-reading-thememechanism the text readers use, covering cells, headers, gutters and the sheet tabs. - The grids need no new control: they take the theme the reader already set, as source code now does (Let the reading appearance reach source code — code files stay a fixed 13px light pane with light-tuned highlighting whatever the reader chose, while the same theme already colors code inside notes #208).
- Keep Paper/Dark as background-and-ink changes only; do not recolor cell values that carry their own formatting (dates, percents, error cells) beyond what the light theme already does.
Goal
After this, a reader who chose Dark or Paper reads a workbook or CSV in that theme; every reading surface — PDF, text, HTML, code, spreadsheets — follows the one choice, and none flips the page to bright light.
Verification
grep -rq "data-reading-theme" ui-packages/web/src/features/reader/xlsx-reader
pnpm --filter @gamma-reader/web test --silent
pnpm checkRefs
- ui-packages/web/src/features/reader/xlsx-reader/index.tsx, sheet-grid.tsx, style.module.scss — the light-fixed grid
- ui-packages/web/src/features/reader/csv-reader.tsx — same grid, same palette
- ui-packages/web/src/styles.css:7-10 — app palette is light-only; nothing else darkens the grid
- ui-packages/web/src/features/reader/markdown-reader/reading-preferences.ts — the preference the grids would read
- ui-packages/web/src/features/reader/markdown-reader/style.module.scss:52-103, ui-packages/web/src/components/pdf-reader/style.module.scss:136-140 — the
data-reading-thememechanism to reuse - Let reading appearance follow the reader into text and HTML documents, not stop at the format line #44, Let the reading appearance reach source code — code files stay a fixed 13px light pane with light-tuned highlighting whatever the reader chose, while the same theme already colors code inside notes #208 — the same appearance preference's earlier extensions to text/HTML and code; this completes it for the remaining reading surface
- Say which rows and columns the workbook hides — today the data Excel kept out of sight sits as ordinary cells, and neither reader nor assistant can tell the author concealed it #245, Show spreadsheet numbers as the sheet states them — a percent cell reads 0.153 where Excel says 15.3%, for reader and assistant alike #161 — open and shipped grid work, the grid being a first-class reading surface
Activity
bencode commentedon Oct 27, 2026
Independent review — posted by the scheduled issue-reviewer loop, independent of the authoring session, under the maintainer's standing instruction.
Evidence audit (against
main@ad4bc66): the behavioral claims all hold; one citation sharpened.pdf-reader/style.module.scss:136,140(.scroll[data-reading-theme='paper'/'dark']),markdown-reader/style.module.scss:52,63,74,103(.previewScroll[...]).data-reading-theme/ preference references anywhere infeatures/reader/xlsx-reader/orcsv-reader.tsx;xlsx-reader/style.module.scss:17-62paints fromvar(--line),var(--panel),var(--surface), whichstyles.css:7-9defines light-only. Confirmed to the line.data-reading-themeis not applied fromreading-preferences.ts— that file holds only the preference store/type; the application sites aremarkdown-reader/index.tsx:234andpdf-reader/index.tsx:189(data-reading-theme={theme}). An implementation copies those two lines' pattern, not anything in reading-preferences.ts.Duplicate check: #44/#208 are the same series on different surfaces, not duplicates; no overlap in open or closed titles.
Sensor: lint ✓, verify ✗ — the grep gate is red today (correctly: not implemented); as noted on #253,
pnpm checkis currently red on main for unrelated reasons, so this block can't pass until main is green.Verdict: valid, keep open. The scope line "background-and-ink only; don't recolor self-formatted values" is the right guard — the #161 number-format work made those cells carry their own ink.
bencode commentedon Nov 2, 2026
Posted by the scheduled issue-reviewer loop, independent of the authoring session.
Re-audit at
d05b6b6— second-stalest review (12 commits since the first review @ad4bc66, none touching a cited file:git diff --stat ad4bc66..HEADoverfeatures/reader/xlsx-reader,csv-reader.tsx, bothstyle.module.scss,markdown-reader/,styles.cssis empty). Valid, stays open; no edits.pdf-reader/style.module.scss:136-140;markdown-reader/style.module.scss:52+, 4data-reading-themerules), applied atmarkdown-reader/index.tsx:234andpdf-reader/index.tsx:189(the first review's corrected application sites). The grids remain theme-blind: zerodata-reading-theme/reading-preferencesreferences infeatures/reader/xlsx-reader/orcsv-reader.tsx;xlsx-reader/style.module.scss:16-62still paints fromvar(--muted|--line|--panel|--surface), whichstyles.css:7-10still defines light-only.pnpm checkwas red on main atad4bc66"for unrelated reasons" — it is green ond05b6b6(Biome + tsc + unit + 85 integration tests, verified this beat). The block can now pass once implemented. Sensor: lint ✓; verify ✗ on main ✓ (thedata-reading-themegrep is red for the right reason). Gate healthy as written.05fcd10(a selected cell's whole text above the grid,xlsx-reader/cell-bar.tsx) styles from the samestyle.module.scss(styles.cellBar,cellName,cellValue). It postdates this issue's Problem section but is now part of the reading surface: a theming change that swaps the module's palette consumers covers it automatically — just includestyles.cellBarin the themed set so the bar doesn't stay a light strip above a dark grid.bencode commentedon Nov 13, 2026
Posted by the scheduled issue-reviewer loop, independent of the authoring session.
Re-audit (third pass) @
d05b6b6— HEAD unchanged since the 11-02 pass (zero commits since 2026-10-28); valid, stays open; no edits.data-reading-theme/reading-preferencesreferences infeatures/reader/xlsx-reader/orcsv-reader.tsx;xlsx-reader/style.module.scss:16-62still paints fromvar(--muted|--line|--panel|--surface), whichstyles.css:7-10still defines light-only. Application sites confirmed atmarkdown-reader/index.tsx:234andpdf-reader/index.tsx:189; hooks atpdf-reader/style.module.scss:136,140andmarkdown-reader/style.module.scss:52/63/74/103.data-reading-themegrep is red for the right reason. Gate healthy as written.styles.cellBarin the themed set so the cell bar doesn't stay a light strip above a dark grid.