Skip to content

Surface merge time on the changelog page and in the feeds - #260

Merged
crs48 merged 1 commit into
mainfrom
claude/changelog-merge-time-display
Jun 25, 2026
Merged

Surface merge time on the changelog page and in the feeds#260
crs48 merged 1 commit into
mainfrom
claude/changelog-merge-time-display

Conversation

@crs48

@crs48 crs48 commented Jun 25, 2026

Copy link
Copy Markdown
Owner

Follow-up to #259 (which sorts the changelog by real merge time). That made the order correct but nothing actually showed the merge time, so the page looked unchanged. This surfaces it.

What changed

Changelog page (index.astro) — each entry now shows its merge time-of-day next to the date:

JUNE 24, 2026 · 02:22 UTC

Rendered in UTC so the statically-built output is deterministic across build environments, with a machine-readable <time datetime="2026-06-25T02:22:28Z"> and a title="Merged …" tooltip carrying the full instant. Entries without a resolved merge time render date-only (no fake 00:00).

Feeds (changelog-feed.ts) — both feeds previously built their timestamp from the entry id:

date_published: `${entry.id}T00:00:00Z`   // → "2026-06-24-fooT00:00:00Z" (malformed)

For slugged ids this produced a malformed JSON date_published and "Invalid Date" in RSS. New entryInstant() helper uses the real mergedAt (falling back to a well-formed midnight-UTC of the date prefix), so:

  • JSON date_published → full merge instant, plus _xnet.mergedAt for the in-app surface
  • RSS pubDate → valid RFC-822 (Thu, 25 Jun 2026 02:22:28 GMT)

In-app What's New (feed.ts) — parses the new mergedAt field (+ test).

Verification

Ran a real astro build (89 pages) and inspected the output:

  • Page: <time datetime="2026-06-25T02:22:28Z" …>June 24, 2026<span> · 02:22 UTC</span></time>
  • JSON: "date_published": "2026-06-25T02:22:28Z" + "_xnet": { "mergedAt": "2026-06-25T02:22:28Z" }
  • RSS: <pubDate>Thu, 25 Jun 2026 02:22:28 GMT</pubDate>

feed.test.ts 10/10 pass; validate:changelog 87 fragments OK; prettier clean on the format-checked apps/** files.

Note: the human date label (e.g. "June 24") is the author-local release label and mergedAt is UTC, so a near-midnight merge can show a UTC time on the "next" day — the explicit UTC suffix + tooltip keep that unambiguous.

🤖 Generated with Claude Code

The merge instant (mergedAt) was used only for sorting; nothing displayed
it, and both feeds derived their timestamp from the entry id — which is
malformed for slugged ids (`2026-06-24-foo` → `…-fooT00:00:00Z`, and
"Invalid Date" in RSS).

- changelog page: show each entry's merge time-of-day (UTC, deterministic
  for a static build) next to its date, with a machine-readable
  `<time datetime>` and a "Merged …" tooltip.
- feeds: new `entryInstant()` helper → JSON `date_published` and RSS
  `pubDate` use the real merge time (falling back to a well-formed
  midnight-UTC of the id date prefix), and expose `mergedAt` in the
  `_xnet` extension for the in-app What's New.
- apps/web feed consumer parses the new `mergedAt` field (+ test).

Verified against a real `astro build`: page renders "· HH:MM UTC", JSON
date_published is a full instant, RSS pubDate is valid RFC-822.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@crs48
crs48 temporarily deployed to pr-260 June 25, 2026 02:44 — with GitHub Actions Inactive
@github-actions

Copy link
Copy Markdown
Contributor

🖼️ UI changes in this PR

No UI changes detected in this PR.

@github-actions

github-actions Bot commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

Preview removed for PR #260.

github-actions Bot added a commit that referenced this pull request Jun 25, 2026
@crs48
crs48 merged commit 5e8dc1f into main Jun 25, 2026
13 checks passed
@crs48
crs48 deleted the claude/changelog-merge-time-display branch June 25, 2026 02:50
github-actions Bot added a commit that referenced this pull request Jun 25, 2026
* fallback well-formed for a slugged id — `2026-06-24-foo` →
* `2026-06-24T00:00:00Z`, not the malformed `2026-06-24-fooT00:00:00Z`.
*/
export function entryInstant(entry: ChangelogEntry): string {
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.

2 participants