Repository navigation
Show the merged chapter calendars on the communities page - #1142
Open
jacquesallen wants to merge 3 commits into
Open
jacquesallen wants to merge 3 commits into
jacquesallen wants to merge 3 commits into
Conversation
✅ Deploy Preview for pauseai canceled.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The problem
The Events section on /communities is a hardcoded iframe of the global calendar (
cal-E1qhLPs5IvlQr8S), so national chapter events never appear in it. Meanwhile/api/calendaralready merges the global calendar with every national chapter calendar innational-chapters.json, and that merged feed is used only to place pins on the map.The result is that chapter events are fetched and then shown nowhere except as map markers. Fetching the live endpoint right now returns 36 events across the UK, Australian, German, French, Dutch and other chapters, none of which a visitor can see in the Events list.
This is the second half of a discovery problem: someone searching for PauseAI events lands here, sees the global calendar, and is sent on to a chapter page. (I have a companion PR on the UK chapter site adding per-city feeds there.)
The change
A new
src/lib/components/UpcomingEvents.svelterenders the merged feed, one row per event with its date and a link to Luma. It fetches/api/calendaritself, in the same shape as the existingNearbyEvent.svelte.The communities page then only swaps the iframe for
<UpcomingEvents />and adds the import. Nothing about the map changes: it keeps its own?days=30request and its markers behave exactly as before.Things for you to decide
--border-luma-embedand--text-subtle. If you would rather keep the Luma look, an embed of a merged calendar would also work, but Luma has no merged-calendar embed as far as I can tell, which is what pushed me to render it here./api/calendar(one withdays=30for the map). I judged the decoupling worth it, given the endpoint sets a one hour cache andNearbyEvent.sveltealready fetches it independently. Happy to thread the data through instead if you prefer./api/calendarreturns the same 36 events for both no parameter and?days=365, ending on 14 October, while the UK calendar alone has events on 20 October, 1 November and 5 December. Something upstream of thedaysfilter is truncating, eitherpaginationLimit: 20or query-string-insensitive caching. This PR does not attempt to fix that.Checks
I could not run the full build here, so this is not as verified as I would like. Both files compile clean under Svelte 5.57 for client and SSR with zero warnings, including no unused-CSS warnings, and both pass your Prettier config unchanged. Neither has been run against a live dev server, so please give the rendering a look on the deploy preview.
Written with Claude and reviewed by me before opening.