CueTrack normalizes subtitles; phone shows the transcript #4
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
mobrule/kurageyomi#4
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent
#1 — PRD: Kurageyomi
What to build
The phone shows the transcript of what is playing.
Add
CueTrack: it takes a raw subtitle track and returns normalized Cues — start, end, andtext — with styling and positioning markup removed and ruby furigana handled rather than dumped
inline as tags. Timings are in ticks. Keep Jellyfin types off its boundary so it can be tested
as a pure transform.
An endpoint serves the Cues for the playing item's Japanese text track, and the page renders
them as a scrollable list. Static for now — following the Playhead is #5.
Text tracks only. Image-based tracks (PGS, VOBSUB) are out of scope permanently, not
deferred. When the only available track is an image track, the page says so explicitly and
explains why mining is unavailable. A blank screen or a silent failure is a bug in this slice.
Acceptance criteria
CueTrackreturns normalized Cues with correct tick timings from a raw text trackCueTrackhas tests covering the above, using fixtures rather than real mediaBlocked by
Implemented and merged to
mainatc8440ee. Held open deliberately: the code is unit-tested but has never run on the real server, and this issue's criteria include behaviour only observable there. #6 deploys it; this closes once that confirms it.Verified on dionysus: the transcript renders on the phone from a real Japanese subtitle track. Merged in
main.CueTrack is covered by 14 tests. One bug found during review that the tests then pinned: 《》 is ruby only when it holds a reading — around a title it is quotation punctuation, and stripping it was deleting words from lines (
《ハンター試験》に合格したbecameに合格した).