# Disabled dates

> Disabled dates

A shadcn/ui block from the [@reui](https://reui.io) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/reui/c-calendar-3).

- Page, with a live preview: https://shadcn.exchange/r/reui/c-calendar-3
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/reui/c-calendar-3-light-e33ebb3141c54f95.png
- Registry item: https://reui.io/r/new-york-v4/c-calendar-3.json
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://reui.io/r/new-york-v4/c-calendar-3.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- npm packages: `date-fns`
- Registry items: `calendar`, `card`

## Files

### `c-calendar-3.tsx`

```tsx
"use client"

import { addDays } from "date-fns"

import { Calendar } from "@/components/ui/calendar"
import { Card, CardContent } from "@/components/ui/card"

export function Pattern() {
  const today = new Date()

  return (
    <Card className="p-0">
      <CardContent className="p-0">
        <Calendar
          disabled={[
            { before: new Date() },
            new Date(),
            { dayOfWeek: [0, 6] },
            {
              from: addDays(today, 14),
              to: addDays(today, 16),
            },
            {
              from: addDays(today, 23),
              to: addDays(today, 24),
            },
          ]}
          excludeDisabled
          mode="range"
        />
      </CardContent>
    </Card>
  )
}
```
