Files
SubMiner/backlog/tasks/task-97 - Add-configurable-character-name-token-highlighting.md

1.8 KiB

id, title, status, assignee, created_date, updated_date, labels, dependencies, references, priority
id title status assignee created_date updated_date labels dependencies references priority
TASK-97 Add configurable character-name token highlighting Done
2026-03-06 10:15 2026-03-06 10:15
subtitle
dictionary
renderer
/home/sudacode/projects/japanese/SubMiner/src/core/services/tokenizer.ts
/home/sudacode/projects/japanese/SubMiner/src/core/services/tokenizer/yomitan-parser-runtime.ts
/home/sudacode/projects/japanese/SubMiner/src/renderer/subtitle-render.ts
medium

Description

Color subtitle tokens that match entries from the SubMiner character dictionary, with a configurable default color and a config toggle that disables both rendering and name-match detection work.

Acceptance Criteria

  • #1 Tokens matched from the SubMiner character dictionary receive dedicated renderer styling.
  • #2 subtitleStyle.nameMatchEnabled disables name-match detection work when false.
  • #3 subtitleStyle.nameMatchColor overrides the default #f5bde6.
  • #4 Regression coverage verifies config parsing, tokenizer propagation, scanner gating, and renderer class/CSS behavior.

Final Summary

Added configurable character-name token highlighting with default color #f5bde6 and config gate subtitleStyle.nameMatchEnabled. When enabled, left-to-right Yomitan scanning tags tokens whose winning dictionary entry comes from the SubMiner character dictionary; when disabled, the tokenizer skips that metadata work and the renderer suppresses name-match styling. Added focused regression tests for config parsing, main-deps wiring, Yomitan scan gating, token propagation, renderer classes, and CSS behavior.