# Ink range

A date range calendar where the selection flows like ink.

Also called: date range picker, date picker, range calendar.

> chatcn Pro: needs a Pro license (https://chatcn.dev/pro). Install from the `@chatcn-pro` registry with your license token; setup at https://chatcn.dev/docs/chatcn-pro.

Example: A selection that flows like ink. Drag across the days and the range flows week to week as one shape, wrapping like a text selection, while the dates above roll. Preview: https://chatcn.dev/preview/ink-range-demo

The range is one continuous shape that wraps from week to week like a text selection, its ends flowing across the days on a quick spring as you drag, with fillets where the rows meet. The days under it turn white through a clip of the same shape, rings sit in the settled ends, and the check in, check out and nights above roll the way they moved. Good for booking what an agent found: a stay, a trip, a block of time.

## Installation

```bash
npx shadcn@latest add @chatcn-pro/ink-range
```

## Usage

```tsx
import { InkRange } from "@/components/ui/chatcn/pro/ink-range"

<InkRange month={new Date(2026, 10)} minDay={14} value={range} onValueChange={setRange} />
```

## Props

| Prop | Type | Notes |
| --- | --- | --- |
| `month` | `Date` | Any day in the month to show |
| `value` / `defaultValue` / `onValueChange` | `{ start, end }` | Days of the month, 1 based |
| `minDay` / `today` | `number` | Days before `minDay` can't be picked |
| `labels` | `{ start, end } | null` | The summary; null hides it |
| `footer` / `locale` |  |  |

## Keyboard

| Key | Action |
| --- | --- |
| `Tab` | Move between days |
| `Enter` twice | Pick the start, then the end |

## Accessibility

- Every day is a real button with its full date; the summary is announced as it changes.

## Motion

- The ends ride a quick spring (stiffness 150, damping 22). Reduced motion: the ink jumps to the range.

Source: https://chatcn.dev/docs/components/ink-range