SakaniUI

Event Calendar

Month and week calendars that show events, with drag to move and a day panel for busy time and free gaps.

Calendar is a date picker; these show a schedule. They own no data: you pass events and the view reports what the person did (a click, a drag) through callbacks, so it works with any backend. Events are coloured from the chart tokens, which follow light and dark. For finished screens see the Calendar blocks.

An event

Plain data. meta carries anything of yours (a calendar id, your row).

Month

Chips for timed events, bars across the days for all-day and multi-day ones, “N more” when a day is full, a lit day. Drag a chip or a bar to another day; with a keyboard, focus it and press Alt + an arrow.

November 2026

Week

A time grid: events as tall as they are long, overlapping ones side by side, all-day events in a lane under the day heads, and a line for the current time. Drag an event to another day or time (it snaps to 15 minutes), or move it with Alt + arrows.

November 2026

Mon9
Tue10
Wed11
Thu12
Fri13
Sat14
Sun15
all-day

Day panel

Put it beside either view. It says how many events there are and how much of the working day is booked and free, draws the day as a strip, lists the schedule, and offers each free gap as a Block focus time button.

Thursday, November 12Today

7 events · 4h 30m booked · 4h 30m free

All day

Schedule

  • Free 9:30 AM to 10:00 AM 30m
  • Free 10:45 AM to 11:30 AM 45m
  • Free 1:30 PM to 2:00 PM 30m
  • Free 3:00 PM to 4:30 PM 1h 30m
  • Free 5:00 PM to 6:00 PM 1h

Calendar Event

The event as the views draw it, in three shapes. Use it to build your own agenda or list.

Accessibility

  • Every event is a button whose label carries its title, time and place. The week and month grids have their own labels; today is marked.
  • Moving an event never needs a pointer: focus it and press Alt + an arrow. The same callback fires as for a drag.
  • Colour is never the only signal: an event always has its title, and the day panel lists the time and place as text.
  • A week grid you drag on takes over touch on the events themselves (touch-action: none), so give people the keyboard or your own card as another way to move them.

MonthCalendar props

PropTypeDefaultDescription
eventsCalendarEventData[]The events. You own them; the view reports changes.
date / defaultDate / onDateChangeDateThe month shown (any date in it). The header has previous, next and Today.
selectedDate / onSelectedDateChangeDate | nullThe lit day, for a day panel beside the grid.
weekStartsOn0 | 1 | … | 610 = Sunday, 1 = Monday.
maxRowsnumber4Rows of events a cell holds before it says "N more".
onEventClick(event, el) => voidAn event was pressed. el is its element, to place a card beside it.
onEventMove(event, { start, end }) => voidAn event was dragged to another day, or moved with Alt + arrows (a day left and right, a week up and down).
onMoreClick(date, el) => void"N more" was pressed (and its button, to place a card beside it).
activeEventIdstring | nullThe event whose card is open: it stays lit.
today / hideHeaderDate / booleanToday for the highlight (default: now). Hide the header to draw your own.

WeekCalendar props

PropTypeDefaultDescription
eventsCalendarEventData[]The events. All-day and multi-day events go in the lane under the day heads.
date / defaultDate / onDateChangeDateAny date in the week shown.
days5 | 77A work week shows the first five days.
weekStartsOn0 | 1 | … | 610 = Sunday, 1 = Monday.
hourHeight / scrollToHour / heightnumber48 / 8 / 640Pixels per hour, the hour the grid opens at, and the height of the scrolling grid.
snapMinutesnumber15A drag, and Alt + up or down, move by this many minutes.
onEventClick / onEventMovecallbacksAs in the month view. A drag moves across days and times; touch drags work too.
onSlotClick(start) => voidAn empty slot was pressed: the time under the pointer, snapped.
now / activeEventIdDate / string | nullThe current time, for the line and Today (default: the real time, and it moves). The event whose card is open.

DayPanel props

PropTypeDefaultDescription
date / eventsDate / CalendarEventData[]The day and the events (it picks those on that day).
workHours[start, end][9, 18]The working day, in hours: booked and free time are counted inside it.
minGapnumber30The smallest free gap offered, in minutes.
onEventClick / onBlockFocus / onCreatecallbacksAn event was pressed; Block focus time was pressed on a gap (start, end); New event was pressed.