Skip to content

Only call the map "live" when viewing today's date - #12

Merged
Jbithell merged 1 commit into
mainfrom
claude/map-tracking-language-date-rt7zjc
Aug 22, 2026
Merged

Only call the map "live" when viewing today's date#12
Jbithell merged 1 commit into
mainfrom
claude/map-tracking-language-date-rt7zjc

Conversation

@Jbithell

Copy link
Copy Markdown
Collaborator

Summary

  • The date menu tile and the per-date nav bar always said "Live tracking map" / "Follow along on the map", even when viewing a past date's map, which isn't live.
  • Added todayUtcDay/isTodayUtcDay helpers (website/app/utils/dateTime.ts) that compare a YYYY-MM-DD UTC day bucket against today, consistent with how urlDate buckets are computed elsewhere.
  • The menu tile (website/app/routes/date/index.tsx) and the page nav button (website/app/components/DatePageNav.tsx) now show "Live tracking map" / "Follow along on the map" only when urlDate is today, and "Map" / "See this day on the map" otherwise.

Test plan

  • npx tsc --noEmit passes
  • Manually verify in a browser that today's date shows "Live tracking map" wording and a past date shows "Map" / "See this day on the map" wording, on both the menu page and the nav bar

Generated by Claude Code

For past dates the menu tile and page nav now just say "Map" / "See
this day on the map" instead of "Live tracking map" / "Follow along
on the map", since there's nothing live about a historic day.
@Jbithell
Jbithell marked this pull request as ready for review August 22, 2026 08:59
Copilot AI lite review requested due to automatic review settings August 22, 2026 08:59
@Jbithell
Jbithell merged commit 045bca2 into main Aug 22, 2026
@Jbithell
Jbithell deleted the claude/map-tracking-language-date-rt7zjc branch August 22, 2026 09:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Updates date-specific UI copy so “Live tracking map” wording is only used when viewing today’s UTC date bucket, avoiding misleading “live” phrasing for historical dates.

Changes:

  • Add todayUtcDay / isTodayUtcDay helpers for comparing YYYY-MM-DD UTC day buckets.
  • Update the date menu tile wording to “Live tracking map” only when urlDate is today.
  • Update the per-date nav button label so the “live” page is labeled “Map” on non-today dates.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
website/app/utils/dateTime.ts Adds helpers for “today” comparisons in the same UTC bucket format used by stored events.
website/app/routes/date/index.tsx Switches menu tile copy between “Live tracking map” and “Map” depending on whether urlDate is today.
website/app/components/DatePageNav.tsx Renames the “live” nav button to “Map” when viewing a non-today date.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines 57 to 60
export default function Page({ loaderData }: Route.ComponentProps) {
const theme = useMantineTheme();
const isToday = isTodayUtcDay(loaderData.urlDate);
if (!loaderData.hasData) {
Comment on lines 33 to 36
export function DatePageNav({ password, urlDate, current }: DatePageNavProps) {
const basePath = `/${password}/${urlDate}`;
const isToday = isTodayUtcDay(urlDate);

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.

3 participants