Public Event List
BlockInstallation
pnpm add @corew500/feature-eventsUsage
import { PublicEventList } from "@corew500/feature-events"
<PublicEventList>Content</PublicEventList>API Reference
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| events* | EventWithCount[] | — | Events data (typically only published events) |
| loading | enum | — | Loading state |
| locale | string | en | Locale for date formatting |
| upcomingTitle | string | Upcoming Events | Section title for upcoming events |
| pastTitle | string | Past Events | Section title for past events |
| showPastEvents | enum | false | Whether to show past events section |
| emptyContent | enum | — | Custom empty state content |
| emptyTitle | string | No upcoming events | Custom empty title |
| emptyDescription | string | Check back soon for new events. | Custom empty description |
| renderAction | (event: EventWithCount) => ReactNode | — | Render function for custom action per event (e.g., register button) |
| className | string | — | Additional CSS classes |
Accessibility
Screen Readers
- Icons are decorative (aria-hidden)
Additional
- - Sections use heading hierarchy
- Cards are semantic with proper structure
Localization
Translatable Content
- - All text props are customizable for translation
Locale-Specific Formatting
- Date formatting uses locale-aware Intl.DateTimeFormat