Repository navigation
Conversation
Changed Files
|
|
This issue highlights a slight incongruity in the Studio's use of "Header" vs "Title". The title is actually the HTML page title and that ends up in the browser tab, which is often not that visible, while the Header is what is clearly shown to the reader of the read-along just above the readalong. The CLI guide should probably say something about this subtlety. In Studio-Web, the HTML title is not separately modifiable, it's always set the the Header instead, so there the filename coming from header==title is unambiguously correct. In the Studio CLI, there is a philosophical question: should the filename be based on the "Title" or on the "Header"? I'll have to think about this before I decide whether to approve this PR as is or change it to use the header. If you have preference as to which one would make more sense to you, I'll consider it before I decide. |
581fcbc to
9c92eb8
Compare
PR Goal?
Use a slugified, explicitly configured title as the offline HTML filename. Missing, empty, default, or punctuation-only titles retain the output basename. Readalong and audio asset filenames keep their existing names.
Fixes?
Fixes #234.
Tests added?
Six integration cases cover explicit and accented titles, the default title, an empty title, punctuation-only text, and no configured title. The existing HTML CLI test now checks the title-based filename.
How to test?
pytest tests/test_align_cli.py -qThe full CLI file passes all 18 tests, including the six new cases. Applicable formatting, lint, and type-check hooks pass; the new title cases were also independently rerun.
Version change?
Feature; no version files changed.