Calendar
Shows a month of days, or two side by side, to pick one day, a start and an end, or several days, with today marked and the days you cannot pick held back.
Examples
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
| Mo | Di | Mi | Do | Fr | Sa | So |
|---|---|---|---|---|---|---|
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
Nov 10 to 12 and Nov 18, 4 of 5 days
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
Nov 12 to 16, 4 nights
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
Viewing on November 20, 2026.
Harbour loft
$145.00 a nightChoose check-in, then check-out
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
States
| Sun | Mon | Tue | Wed | Thu | Fri | Sat |
|---|---|---|---|---|---|---|
Struck-through nights are booked. With check-in on Nov 12, check-out can be Nov 13 to Nov 19, the morning the next booking begins.
Usage
Use it when
- Picking a day where seeing the week and month helps, such as a viewing, a booking or a report date.
- Picking a stay or a reporting period, a start and an end, with the days between in view.
- Picking several separate days, such as study days or the days a desk is needed.
- Showing which days cannot be picked, such as nights already booked.
Use something else when
- A form field for a day. Use DatePicker instead, which opens this in a popover, or a sheet on a phone.
- A birth date or a day years away. Use DatePicker instead, with
typed, so the day is typed rather than paged to. - A choice among a few named periods, such as "Last 30 days". Use SegmentedControl instead.
Rules
General
Content
Avoid
Limits
Install
npx shadcn@latest add https://kaanarici.com/r/cobalt/calendar.jsonimport { Calendar, daysBetween, formatDate, formatDateRange, formatDays, parseDate, weekStartFor, type DateRange } from "@/components/cobalt/ui/calendar"