IEvent

interface
Calendar

Public event data shape consumed by OrigamCalendar and useCalendar. Supports single-day, multi-day, all-day and recurring events (RRULE subset: FREQ/INTERVAL/COUNT/UNTIL/BYDAY). start/end accept ISO-8601 strings, Date objects or epoch numbers.

TypeScript

Définition

La définition TypeScript de l'interface telle que trouvée dans le code source d'origam. Cliquez sur l'icône de copie pour copier l'extrait.

typescript

API

Propriétés

Chaque propriété déclarée par cette interface, avec son type, son caractère optionnel et sa valeur par défaut.

id
requis
string | number
Stable identifier used as :key and for click-target wiring.
title
requis
string
Displayed event title — also used as the default aria-label.
description
string
Optional long-form description surfaced in the agenda view.
start
requis
string | Date
Start instant. Accepts ISO-8601 strings, Date objects or epoch numbers.
end
string | Date
End instant. Omit for all-day events or point-in-time events.
allDay
boolean
Render in the all-day band above the time grid (week/day views). No effect in month view.
category
string
Free-form category string — lookup key for categoryColors on the calendar.
color
TIntent | string
Direct color override. Wins over category. Accepts a TIntent value or any CSS color string.
rrule
string
RRULE subset string (FREQ=DAILY|WEEKLY|MONTHLY + INTERVAL/COUNT/UNTIL/BYDAY). The calendar expands recurrences at render time.
metadata
Record<string, unknown>
Free-form payload passed through to the event-click handler.

Écosystème

Utilisé par

Composants et composables qui étendent ou consomment cette interface.

Usage

Exemples

Extraits de code prêts à coller utilisant cette interface.

Weekly recurring meeting event

typescript