# Calendar

> A month grid for picking a date, with min/max and disabled days.

- Category: [Inputs & forms](https://tarve.dev/docs.md#inputs)
- Import: `import { Calendar } from "@tarve/core";`
- Props type: `CalendarProps`
- Source: [packages/core/src/extra-controls.ts:342](https://github.com/omarcosr/tarve/blob/main/packages/core/src/extra-controls.ts#L342)

## Usage

```tsx title="Calendar.tsx"
import { Calendar } from "@tarve/core";

let month = "2026-09";
let date = "2026-09-22";

<Calendar
  month={month}
  value={date}
  weekStartsOn={1}
  isDateDisabled={(day) => new Date(day).getDay() === 0}
  onMonthChange={(next) => {
    month = next;
  }}
  onValueChange={(next) => {
    date = next;
  }}
/>
```

## Props

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `month` (required) | `string` | — |  |
| `disabled` | `boolean` | — |  |
| `isDateDisabled` | `(date: string) => boolean` | — |  |
| `max` | `string` | — |  |
| `min` | `string` | — |  |
| `onMonthChange` | `(month: string) => void` | — |  |
| `onValueChange` | `(date: string) => void` | — |  |
| `value` | `string` | — |  |
| `weekStartsOn` | `CalendarWeekStartsOn` | `0` |  |

## Common props

Shared by every component (descriptions: https://tarve.dev/docs.md#common-props): `children`, `class`, `className`, `highlight`, `id`, `key`, `motionFrom`, `onHighlight`, `onPaste`, `onPointerLeave`, `onPointerMove`, `onSize`, `onTransitionEnd`, `rovingGroup`, `style`.

## Types

```ts title="CalendarWeekStartsOn"
type CalendarWeekStartsOn = 0 | 1 | 2 | 3 | 4 | 5 | 6;
```

Previous: [ToggleGroup](https://tarve.dev/docs/components/ToggleGroup.md) · Next: [DatePicker](https://tarve.dev/docs/components/DatePicker.md)

---

Tarve v0.13.8 · HTML version: https://tarve.dev/docs/components/Calendar · Index for agents: https://tarve.dev/llms.txt
