Your calm window into the Atmosphere. Mirror of https://github.com/hfrdmnk/morgenblau morgen.blue

Polish digest page: calendar strip, chrome refresh, route rename #23

Merged dominikhofer.me
targeting main
Merged opened by and assigned to dominikhofer.me
targeting main

Summary #

  • Add a horizontal calendar strip to the digest page with day navigation; the selected day true-centers and the digest is preserved while reading an entry.
  • Rename routes: /consume → /digest, /create → /library. Server-side public-route allowlist and frontend paths updated together.
  • Move the refresh action into the window chrome via a useRegisterChromeRefresh hook so individual pages register their refresh handler with the layout.
  • Harden the YouTube feed-finder: populate channel-feed titles by fetching the Atom feed, broaden the consent-bypass regex to cover three embedding shapes, gate fetches on 2xx so error-page UC… strings can't slip into the regex or gofeed parser.

Notable changes #

  • frontend/src/components/calendar-strip.tsx — new component; reads/writes ?date=YYYY-MM-DD, clamps future dates to today, strict regex validation on the URL param.
  • frontend/src/lib/date.ts — new local-day helpers (startOfLocalDay, formatISODate, parseISODate, isSameDay) with month/day round-trip checks.
  • frontend/src/layouts/window/chrome-actions.tsx + hooks/use-chrome-refresh.ts — context + hook for pages to register a refresh handler that the chrome button invokes.
  • internal/feedfinder/feedfinder.go — fetchYTFeedTitle + broadened ytChannelIDInHTML regex ("channelId":"|/channel/|channel_id=); both YouTube fetches now gate on 2xx and drain the body on the discard branch. Comment documents the "first match wins" contract.
  • internal/middleware/auth/auth.go — public-route allowlist string rename for /consume → /digest.

This pull request has no versions submitted yet.