Repository navigation
fix(web): show hours in the Summary tab's chapter timestamps - #3243
Conversation
The Summary tab formatted chapter start times with its own minutes-only helper, so a chapter 1 h 5 m 5 s in read 65:05. Use formatPlayerTime, added for the embed player in CapSoftware#2655, which rolls over into hours. Output under an hour is unchanged.
|
@patrickballard is attempting to deploy a commit to the Cap Software Inc Team on Vercel. A member of the Team first needs to authorize it. |
|
Thanks for this, the change to the Summary tab looks right and sub-hour output is unchanged. One gap before we merge: the share page shows chapters in a second place with the same minutes-only formatting. Could you:
We'll add the new test file to the web test list in CI on our side. |
SummaryChapters, the chapter list under the video, used the same minutes-only formatTimeMinutes, so a chapter 1 h 5 m 5 s in still read 65:05 there. Use formatPlayerTime like the Summary tab, and remove formatTimeMinutes, which nothing else used.
|
Done in 45796a0. |
|
@greptileai review |
The share page shows AI chapters in two places, the Summary tab and the chapter list under the video (
SummaryChapters), and both formatted start times with minutes-only helpers, so any chapter past the hour mark shows a minute count. The same page's header already rolls over into hours.59:5959:5960:001:00:0065:051:05:05123:042:03:04This deletes both helpers (
formatTimeinSummary.tsx, andformatTimeMinutesintranscript-utils.ts, which nothing else used) and usesformatPlayerTimefrom@/lib/player-time, which #2655 added for the embed player's duration.Checks
chapter.startis in seconds:Share.tsx'shandleSeekassigns it tovideo.currentTime, clamped to the video's duration.__tests__/unit/summary-chapters.test.tsrenders both the Summary tab andSummaryChaptersand checks the chapter timestamps each shows, from00:00to10:00:00. Each component's cases fail without its change (60:00instead of1:00:00).bun run typecheck: no errors. Biome: clean on all three files.

Confidence Score: 5/5
The PR appears safe to merge.Summary
Both chapter lists now use
formatPlayerTimeto show hours.Reviews (2) · Last reviewed commit: "fix(web): show hours in the share page's..." · Reviewed by Greptile