Skip to content

Booking Card

Book a meeting in one card: a month calendar beside the day's free times, a duration, a repeat rule and the time zone, then a confirm step with a summary and a note. Slots come from your function, so the card never fetches. Narrow-first: under 560px the times become a three-column grid.

On this page

Examples

Clock

Narrow

Installation

npx knowns-ui@latest add booking-card
For Claude Code, Cursor or Codex: installs it and wires the props to your own data.

Props

getSlots
(day, duration) => TimeSlot[]
The times of a day for a duration, in order. Booked ones come back disabled with a note. buildSlots makes them from busy blocks.
title
ReactNode
Default"Schedule a call"
The card's heading.
description
ReactNode
Under the heading: what is booked and with whom.
durations
number[]
Default[15, 30, 45, 60]
Duration choices in minutes.
defaultDuration
number
Defaultthe second choice
The duration picked first.
recurrences
Recurrence[]
Defaultall four
"none", "weekly", "biweekly", "monthly". Pass [] to hide the Repeat row.
defaultRecurrence
Recurrence
Default"none"
The repeat rule picked first.
defaultDay
Date
Defaulttoday
The day open first.
defaultTime
Date
A slot start picked from the start, e.g. when changing a booking.
min / max / isDateDisabled
Date / Date / (d) => boolean
Days that can be booked.
timeZone
string
Defaultthe viewer's
IANA zone the times are shown in.
onChangeTimeZone
() => void
Shows Change after the time zone line.
host
{ name, timeZone? }
The other side. With a zone, the confirm step says what time it is for them.
where
{ label, detail? }
A Where row on the confirm step.
notePlaceholder
string | null
Defaultset
The note's placeholder. null hides the note.
onConfirm
(booking: Booking) => void | Promise
Gets start, end, duration, recurrence, timeZone and note. The button spins until it resolves, then the card shows it booked.
onCancel
() => void
Shows Cancel on the first step.
step / defaultStep / onStepChange
"pick" | "confirm" | "done"
Default - / "pick" / -
The screen, controlled or not. Confirm shows the summary and needs a picked time (defaultTime).
hourCycle
"12" | "24"
Defaultthe locale's
The clock.

When to use

When to use

  • A public booking page or a dialog where someone picks a day, a free time and how long, then confirms.
  • Recurring calls where the repeat rule and the other person's time zone matter.

When not to use

Using with AI

Use Copy page for AI above to give your assistant this page, Copy prompt under the install command to have it installed and wired to your data, or connect the Knowns UI MCP server and just ask:

  • Add the Knowns UI Booking Card to my app and wire it to my own data.
  • I need a public booking page or a dialog where someone picks a day, a free time and how long, then confirms. Set that up with the Knowns UI Booking Card.
  • Which Booking Card props do I need for a minimal setup? Show me a short example.

With the server connected, your assistant calls get_component({ name: "booking-card" }) and search_docs({ query: "booking card" }).

Need help?

Stuck on Booking Card, or found something off? We read every message.