Parent Epic
Part of #124 — Landing Page Polish, CTA/Form/Event Tracked Flows & Backend Integration Gaps
Depends on: PR #103 (popup component) being merged. #109 (PostHog provider) must be merged for analytics calls.
🎯 Objective
PR #103 introduced the EventAnnouncementPopup component, but the event date, title, and Discord CTA link are hardcoded in the component. This issue makes the popup configurable, wires the PostHog events from #111, and ensures the popup doesn’t show after the event has passed.
🛠️ Scope
1. Make popup configurable via props (no hardcoded event data)
// components/landing/event-announcement-popup.tsx
type EventAnnouncementPopupProps = {
eventTitle: string
eventDate: Date // used for auto-hide after event passes
eventDescription?: string
ctaLabel: string
ctaHref: string // Discord invite or registration link
ctaTarget?: '_blank' | '_self'
}
2. Auto-hide after event date passes
3. CTA link is a real Discord invite URL
4. Wire PostHog events (from #111)
5. Accessibility
✅ Acceptance Criteria
Parent Epic
Part of #124 — Landing Page Polish, CTA/Form/Event Tracked Flows & Backend Integration Gaps
Depends on: PR #103 (popup component) being merged. #109 (PostHog provider) must be merged for analytics calls.
🎯 Objective
PR #103 introduced the
EventAnnouncementPopupcomponent, but the event date, title, and Discord CTA link are hardcoded in the component. This issue makes the popup configurable, wires the PostHog events from #111, and ensures the popup doesn’t show after the event has passed.🛠️ Scope
1. Make popup configurable via props (no hardcoded event data)
Dateproplib/landing-config.ts(or equivalent) so the next event can be updated by changing one file, not hunting inside a component2. Auto-hide after event date passes
new Date() > eventDatenull)3. CTA link is a real Discord invite URL
ctaHrefreceives the real func(kode) Discord invite URL — not#orhttps://discord.gg/placeholdertarget="_blank" rel="noopener noreferrer"TODOconstant inlib/landing-config.tsso it’s easy to find and update4. Wire PostHog events (from #111)
track(ANALYTICS_EVENTS.ANNOUNCEMENT_POPUP_SHOWN)track(ANALYTICS_EVENTS.ANNOUNCEMENT_CTA_CLICKED, { cta_label, cta_href })track(ANALYTICS_EVENTS.ANNOUNCEMENT_DISMISSED, { method: 'button' })track(ANALYTICS_EVENTS.ANNOUNCEMENT_DISMISSED, { method: 'backdrop' })track(ANALYTICS_EVENTS.ANNOUNCEMENT_DISMISSED, { method: 'escape' })5. Accessibility
role="dialog",aria-modal="true",aria-labelledbypointing to the event titlearia-label="Close announcement"✅ Acceptance Criteria
new Date() > eventDate— no stale announcement shownnpm run buildpasses, no type errors