Data displayAlea Pro
AgendaView
The events of the next days as a list, day by day: all-day events first, then by time, with a multi-day event on each of its days.
import { AgendaView } from '@alea-design/pro';
Examples
Upcoming
The next days as a list: all-day events first, then by time, and a multi-day event on each of its days. Press an event to open it.
Tokens
The design tokens this component reads, with their value in the current theme. Override any of them to restyle it.
Color
--alea-accent-strong…--alea-accent-subtle…--alea-border-control…--alea-status-danger…--alea-status-danger-bg…--alea-status-info…--alea-status-info-bg…--alea-status-success…--alea-status-success-bg…--alea-status-warning…--alea-status-warning-bg…--alea-surface-raised…--alea-text…--alea-text-muted…
Space
--alea-space-0-5…--alea-space-1…--alea-space-2…--alea-space-3…--alea-space-5…--alea-space-6…
Radius
--alea-radius-sm…
Type
--alea-font-family-body…--alea-font-size-md…--alea-font-size-xs…--alea-font-weight-medium…--alea-font-weight-semibold…
Component
--alea-hit-min…
Props
AgendaView props
The events of the next days as a list, day by day: the view for a phone, for a printout, and for anyone who reads a calendar better than they scan a grid. All-day events come first, then the rest by start time; an event that lasts several days appears on each of them. It is a plain list of headings and rows, so a screen reader and the keyboard need nothing special.
| Prop | Type | Default | Description |
|---|---|---|---|
eventsrequired | ScheduleEvent[] | The events, in any order. The same objects the Scheduler takes. | |
aria-label | string | "Schedule" | Names the list for screen readers. Default "Schedule" (translated). |
className | string | none | Extra class names for the root element. |
days | number | 14 | How many days to cover. Default 14. |
emptyMessage | ReactNode | "No events" | Shown when the period has no events at all. Default "No events". |
from | Date | today | The first day shown. Default today. |
onEventPress | ((event: ScheduleEvent) => void) | none | Makes each event a button and calls this when it is pressed. Without it the events are plain rows. |
showEmptyDays | boolean | false | Lists days that have no events too, each with "No events". Default false: only days with something. |
Specs
Generated from the source: the variants in the types, the states and tokens in the CSS, and the motion patterns that apply. The grids render the real component in both themes; the numbers are measured from the page.
- States
- Hover (CSS)
- Dark and light
- Every color comes from theme tokens, so it follows data-theme (and presets like Graphite) on the page or any wrapper. Contrast is checked in both themes.
- Styling hooks
.alea-agenda-empty.alea-agenda.alea-agenda-day.alea-agenda-heading.alea-agenda-list.alea-agenda-time.alea-agenda-main.alea-agenda-title.alea-agenda-status.alea-agenda-detail.alea-agenda-item.alea-agenda-row- Data attributes
data-tone=successdata-tone=warningdata-tone=dangerdata-tone=infodata-tone=neutraldata-muted
Accessibility
- It is a region named "Schedule" with a heading per day and a list of events under it, so a screen reader goes through it by headings and lists.
- Each day heading holds a time element with the machine date; the time range is written in the language of the page.
- With onEventPress each event is a real button; without it the rows are plain text.
- The color stripe of an event is extra: the time and the title carry everything.
Keyboard
| Key | Does |
|---|---|
| Tab | Moves through the events when they are buttons |
| Enter or Space | Presses the focused event |
Do and don't
Do
- Use it on a phone, in a print view, or next to a month calendar as the list of what is coming.
- Pass the same events as the Scheduler: one list feeds both.
- Give the list a name with aria-label when the page has more than one.
Don't
- Don't use it to move or resize events: that is the Scheduler.
- Don't pass a year of events: cover the days people look at (days), and page by changing from.
In Figma
The properties of the Figma components, generated from the kit, so they always match it. The last column is the React prop each one stands for.
Agenda view · 1 variants
| Figma property | Kind | Values | Default | React prop |
|---|