Dev: fix(events): align event timing with Luma EDT start/end instants#74
Merged
Conversation
- Use exact startsAt timestamp for upcoming visibility instead of UTC date string - Add endsAt field to CortexEvent (CONNEX: 9 AM - 9 PM EDT) - Show three countdown states: ticking clock, "Happening now", "Event ended" - Add countdown and upcoming test coverage
fix(events): align event timing with Luma EDT start/end instants
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
jhuhnke
approved these changes
Jun 22, 2026
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.
Summary
Event countdowns and upcoming-event visibility now use exact UTC timestamps derived from the event’s EDT start and end times. Previously, event visibility was based on UTC calendar-date strings. This could keep an event in the upcoming list until the end of the UTC day, even after its actual start time had passed. The new logic compares exact timestamps, so an event is removed from upcoming lists once
startsAthas passed.What changed
CortexEventdaterepresented a UTC calendar daystartsAtandendsAtas ISO UTC timestamps.dateLabelis display-onlyevent.date >= todayusing a UTC date keystartsAt > nowusing the exact timestampstartsAt, shows"Happening now"untilendsAt, then shows"Event ended"<time dateTime>event.dateevent.startsAtEvent timing
For CONNEX Tech Fest:
startsAt:2026-06-27T13:00:00ZendsAt:2026-06-28T01:00:00ZThe local EDT times are converted to ISO UTC timestamps for storage and comparisons.
Architecture
Timeline behavior
Test coverage
Added:
getEventTimingStategetUpcomingEventsandgetNextUpcomingEvent14 tests total, all passing.
Known limitations
The event card and header promo are server-rendered with 1-hour ISR caching, so they may stay visible briefly after the event starts. The client-side countdown handles this by showing the correct state in real-time ("Happening now" / "Event ended").
What’s next
Event content is currently hardcoded in
src/lib/content/events.ts. After this event, we’ll build an event-submission pipeline to handle these.