FeaturedEvents
ImplementedSection wrapper for an EventGrid (or any children) — locale-ready heading (h1–h6 via headingAs, default h2, useId-derived id unless headingId given), optional 'View all' link (rendered only when both viewAllLabel and viewAllHref are set, sized at --ep-tap-min), tone light/dark background, responsive max-w-7xl padding, locale-aware empty-state message (locale 'en' default / 'fr' opt-in; emptyMessage override). NOT a carousel — no events prop, no auto-advance; children-less render shows a dashed role='status' 'No content available.' fallback. Server-renderable (no 'use client').
components/organisms/featuredevents/FeaturedEvents.tsxSection wrapper that adds a locale-aware heading, an optional "View all" link, and responsive padding around an EventGrid (or any children). Not a carousel — content arrives via children. Server-renderable layout organism (no "use client" directive).
FeaturedEvents
Storefront organism (Family 7 — Tier 1)
Section wrapper that adds a locale-aware heading, a "View all" link, and responsive padding around an EventGrid (or any children). Pure server-renderable layout component — no "use client" directive.
Usage
import { FeaturedEvents, EventGrid } from '@epasslive/design-system'
<FeaturedEvents
heading="Upcoming Events"
viewAllLabel="View all"
viewAllHref="/events"
headingId="upcoming-events-heading"
tone="light"
>
<EventGrid events={eventConfigs} columns={{ sm: 1, md: 2, lg: 4 }} />
</FeaturedEvents>
// French — locale switches the organism-authored empty-state message
<FeaturedEvents
heading="À la une"
locale="fr"
viewAllLabel="Voir tout"
viewAllHref="/evenements"
>
<EventGrid events={events} locale="fr" />
</FeaturedEvents>Accessibility
Semantic <section> named via aria-labelledby pointing at the heading id (level configurable via headingAs, default <h2>). The "View all" link is sized at --ep-tap-min and has focus-visible:ring-2 focus-visible:ring-ep-text-teal (5.45:1 on the light section background — WCAG 1.4.11). The empty state uses role="status".
Props
heading*stringSection heading text (already localized by the caller).
viewAllLabelstringLocalized "View all" link text. If omitted, the link is not rendered.
viewAllHrefstring"View all" link target. If omitted, the link is not rendered.
headingIdstringOptional id applied to the rendered heading tag (default <h2>; use headingAs to change the level) so the consuming page can link to it.
headingAs1 | 2 | 3 | 4 | 5 | 62Heading level for the section title — renders <h1>–<h6>. Pass 3/4 when embedding inside a page that already owns the h2 (FooterColumn headingAs precedent). The aria-labelledby id follows the rendered tag.
locale"en" | "fr"enLocale for the strings FeaturedEvents itself authors — the default empty-state message ("No content available." / « Aucun contenu disponible. »). EN default keeps the pre-i18n output byte-identical; FR is opt-in via "fr". heading/viewAllLabel stay caller-localized.
emptyMessagestringlocale defaultOverrides the locale default for the empty-state message.
tone'light' | 'dark'lightVisual tone. "light" = light background, "dark" = dark background. The empty-state fallback surface is identical for both tones (theme-adaptive).
classNamestringExtra class names merged onto the inner container.
childrenReact.ReactNodePass-through. Typically a <EventGrid> instance; when omitted, a dashed role="status" empty state renders.
Props
FeaturedEvents
headingstring—Section heading text (already localized by the caller).
viewAllLabelstring—Localized 'View all' link text; link renders only when both label and href are provided.
viewAllHrefstring—'View all' link target; link renders only when both label and href are provided.
headingIdstringuseId-derivedOptional id on the rendered heading tag (default <h2>; use headingAs to change the level) so the consuming page can link to it.
headingAsHeadingLevel (1 | 2 | 3 | 4 | 5 | 6)'2'Heading level for the section title — renders <h1>–<h6>. Pass 3/4 when the page already owns the h2 (FooterColumn headingAs precedent); the aria-labelledby id follows the rendered tag.
locale"en" | "fr"'en'Locale for the strings FeaturedEvents itself authors (the default empty-state message). EN default keeps the pre-i18n output byte-identical; FR is opt-in via 'fr' (EventGrid inline-literal precedent). heading/viewAllLabel stay caller-localized.
emptyMessagestringlocale defaultOverrides the locale default for the empty-state message ('No content available.' / 'Aucun contenu disponible.').
toneFeaturedEventsTone'light''light' (bg-ep-bg-secondary) or 'dark' (bg-ep-bg); the empty-state fallback surface is identical for both tones (theme-adaptive ep-bg/ep-border).
classNamestring—Extra classes merged onto the inner container.
childrenReact.ReactNodefallbackPass-through content — typically an <EventGrid>. When omitted, a dashed role='status' 'No content available.' block renders.
<FeaturedEvents />Accessibility
ARIA
1 ruletap-target
1 ruletoken
1 rulelayout
1 ruleUsage
Import
import { FeaturedEvents } from "@epasslive/design-system"Example 1
<FeaturedEvents heading="Featured events"><EventGrid events={events} /></FeaturedEvents>Example 2
<FeaturedEvents heading="À la une" locale="fr" viewAllLabel="Voir tout" viewAllHref="/evenements"><EventGrid events={events} locale="fr" /></FeaturedEvents>Anti-patterns
— Do not fetch data directly in organisms
— Avoid tight coupling to specific data sources
— Do not pass data props — the organism takes none; the grid comes in as children