boardui

Date Calendar

Component

About

An inline month calendar for picking a single date or a date range directly on the page, with today marked and unavailable days struck through.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Date Calendar to your project and fits it to your theme.

Code

How Date Calendar is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import { DateRangeCalendar } from "@/components/ui/date-calendar";
import { useState } from "react";
import { getLocalTimeZone, today } from "@internationalized/date";

export default function DateRangeCalendarDemo() {
  const now = today(getLocalTimeZone());
  const nextWeek = now.add({ weeks: 1 });
  const [range, setRange] = useState({
    start: nextWeek,
    end: nextWeek.add({ days: 4 }),
  });
  return (
    <DateRangeCalendar
      aria-label="Stay"
      value={range}
      onChange={setRange}
      minValue={now}
    />
  );
}

Dependencies

More by boardui

View all
  • Social Button

    Social Button

    4
  • Modal Dialog

    Modal Dialog

    3
  • Select

    Select

    1
  • Accordion

    Accordion

    1
  • Segmented Control

    Segmented Control

  • Composer Loader

    Composer Loader

  • Slider

    Slider

  • File Upload

    File Upload