Skip to content

fix: show hours in the Chrome extension's timers and mobile chapter times - #3312

Merged
richiemcilroy merged 2 commits into
CapSoftware:mainfrom
patrickballard:fix/extension-mobile-clock-hours
Oct 26, 2026
Merged

richiemcilroy merged 2 commits into
CapSoftware:mainfrom
patrickballard:fix/extension-mobile-clock-hours

Conversation

@patrickballard

@patrickballard patrickballard commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Closes #3303.

The Chrome extension and the mobile app formatted times as minutes and seconds only, so anything past the hour mark read as a minute count, 65:05 instead of 1:05:05:

  • Chrome extension: the recording timer on the page and in the popup, and recording durations on the options page (shared/format-duration.ts)
  • Mobile: chapter times on a cap's page (app/caps/[id].tsx)

Both now print H:MM:SS from an hour on, and under an hour they print exactly what they did before. The extension keeps truncating live timers and rounding finished recordings.

On mobile, formatChapterTime moves into src/utils/format.ts so it can be tested, and the chapter time's fixed 44 pt width becomes a minimum width. Measured with the app's Neue Montreal Medium at 13 pt, every 1:MM:SS label fits in 44 pt (43.3 pt at most), but from two hours on some reach 46.3 pt (6:00:00). Labels that fit keep the same 44 pt column.

Tests

  • Extension: new src/shared/format-duration.test.ts, which fails without the change (60:00 instead of 1:00:00). bun run --cwd apps/chrome-extension test: 39 passed. typecheck clean.
  • Mobile: a new case in src/utils/format.test.ts, which fails without the change. bun run --cwd apps/mobile test: 289 passed. typecheck clean.
  • Biome: clean.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge.

Summary

The PR adds H:MM:SS labels for Chrome extension timers, saved recording durations, and mobile chapter times.

  • Chrome extension recording times show hours for long recordings.
  • Mobile chapter times show hours for long chapters.

No actionable issues were found. Tests and visual checks were not run during this review.

Reviews (1) · Last reviewed commit: "fix(mobile): show hours in chapter times" · Reviewed by Greptile

The recording timer on the page and in the popup, and recording
durations on the options page, counted minutes past 59, so a recording
1 h 5 m 5 s long read 65:05. Print H:MM:SS from an hour on; shorter
times print as before.
A cap's chapter list counted minutes past 59, so a chapter 1 h 5 m in
read 65:05. Move formatChapterTime into utils/format with hours from an
hour on, and make the label's 44 pt width a minimum, since from two
hours on some labels measure up to 46.3 pt.
@vercel

vercel Bot commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
cap-status Skipped Skipped Oct 26, 2026 2:14am UTC

@vercel
vercel Bot temporarily deployed to Preview – cap-status October 26, 2026 02:14 Inactive

@richiemcilroy richiemcilroy left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, checked the output under and over an hour and the tests pin it.

@richiemcilroy
richiemcilroy merged commit de2cae7 into CapSoftware:main Oct 26, 2026
30 of 31 checks passed

This branch was previously deployed

1 inactive deployment
Preview – cap-status — 6b6b50c3 Deployed Oct 26, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Times past an hour show as minutes (65:05 instead of 1:05:05) across the desktop app, web, Chrome extension and mobile app

2 participants