Skip to content

feat: timezone-corrected timestamps#69

Merged
eclectic-coding merged 1 commit into
mainfrom
feat/timezone-timestamps
May 26, 2026
Merged

feat: timezone-corrected timestamps#69
eclectic-coding merged 1 commit into
mainfrom
feat/timezone-timestamps

Conversation

@eclectic-coding
Copy link
Copy Markdown
Owner

Summary

  • Adds a timestamp_controller.js Stimulus controller that reads <time datetime="ISO8601"> elements and reformats them in the browser's local timezone using Intl.DateTimeFormat
  • Adds a local_time view helper that renders <time> elements with UTC ISO 8601 datetime attributes and UTC fallback text (degrades gracefully without JS)
  • Updates all 18 timestamp displays across jobs, failed jobs, history, processes, queues, recurring tasks, cache entries, cable channels, and the dashboard to use the new helper
  • Relative timestamps (oldest cache entry, oldest cable message, cable message list) use Intl.RelativeTimeFormat with the full local timestamp exposed on hover via title

Test plan

  • All 256 existing request specs pass (bundle exec rake)
  • Jobs index shows enqueued-at timestamps in local timezone
  • Jobs show page displays enqueued/scheduled/finished times in local timezone
  • Failed jobs index and detail page show local timestamps
  • History page shows finished-at in local timezone
  • Processes page shows last heartbeat in local timezone
  • Recurring tasks show next run / last run in local timezone
  • Cache entries index and detail show created-at in local timezone
  • Cable channel browser shows last message time in local timezone
  • Cable message list shows relative time with full local timestamp on hover
  • Dashboard oldest cache / oldest cable message shows relative time with hover title
  • Fallback (UTC text) visible when inspecting the raw HTML <time> element

Closes #58

🤖 Generated with Claude Code

All timestamps across the dashboard are now rendered as <time datetime="ISO8601">
elements. A new timestamp_controller.js reformats each one to the browser's local
timezone using Intl.DateTimeFormat; relative timestamps use Intl.RelativeTimeFormat
with the full local time shown on hover. Degrades to UTC text without JS.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@eclectic-coding eclectic-coding merged commit 1a0daeb into main May 26, 2026
4 checks passed
@eclectic-coding eclectic-coding deleted the feat/timezone-timestamps branch May 26, 2026 21:08
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.

[v0.7.0] UX: timezone-corrected timestamps

1 participant