The value is an object with start and end. Press once for the start and once for the end, or drag.
trip-dates.tsx
RangeCalendar
| Prop | Type | Default | Description |
|---|---|---|---|
| value | RangeValue<T> | null | — | The current value (controlled). |
| default | RangeValue<T> | null | — | The default value (uncontrolled). |
| aria-label | string | — | Defines a string value that labels the current element. |
| aria-labelledby | string | — | Identifies the element (or elements) that labels the current element. |
| aria-describedby | string | — | Identifies the element (or elements) that describes the object. |
| aria-details | string | — | Identifies the element (or elements) that provide a detailed, extended description for the object. |
| id | string | — | The element's unique identifier. See MDN. |
| dir | string | — | |
| lang | string | — | |
| inert | boolean | — | |
| translate | "no""yes" | — | |
| suppress | boolean | — | A React-only flag that suppresses the warning React normally logs when an element's server-rendered content doesn't match the client render during hydration. See React docs. |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | MouseEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | TouchEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | PointerEventHandler<HTMLDivElement> | — | |
| on | UIEventHandler<HTMLDivElement> | — | |
| on | UIEventHandler<HTMLDivElement> | — | |
| on | WheelEventHandler<HTMLDivElement> | — | |
| on | WheelEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | AnimationEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| on | TransitionEventHandler<HTMLDivElement> | — | |
| style | — | The inline style for the element. A function may be provided to compute the style based on component state. | |
| children | — | The children of the component. A function may be provided to alter the children based on component state. | |
| slot | string | null | — | A slot name for the component. Slots allow the component to receive props from a parent component. An explicit null value indicates that the local props completely override all props received from a parent. |
| render | — | Overrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if <button> is expected, you cannot render an <a>). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate. | |
| min | DateValue | null | — | The minimum allowed date that a user may select. |
| max | DateValue | null | — | The maximum allowed date that a user may select. |
| auto | boolean | false | Whether to automatically focus the calendar when it mounts. |
| focused | DateValue | null | — | Controls the currently focused date within the calendar. |
| default | DateValue | null | — | The date that is focused when the calendar first mounts (uncontrolled). |
| on | — | Handler that is called when the focused date changes. | |
| page | "single""visible" | visible | Controls the behavior of paging. Pagination either works by advancing the visible page by visibleDuration (default) or one unit of visibleDuration. |
| first | "fri""mon""sat""sun""thu""tue""wed" | — | The day that starts the week. |
| selection | "center""end""start" | 'center' | Determines the alignment of the visible months on initial render based on the current selection or current date if there is no selection. |
| allows | boolean | — | When combined with isDateUnavailable, determines whether non-contiguous ranges, i.e. ranges containing unavailable dates, may be selected. |
| is | — | Callback that is called for each date of the calendar. If it returns true, then the date is unavailable. The second argument provides the current selection anchor date, if any. This can be used to adjust the available dates based on the user's first selected date. | |
| commit | "clear""reset""select" | 'select' | Controls the behavior when a pointer is released outside the calendar or a blur occurs mid selection: - clear: clear the currently selected range of dates. - reset: reset the selection to the previously selected range of dates. - select: select the currently hovered range of dates. |
| visible | DateDuration | { months: 1 } | The amount of days that will be displayed at once. This affects how pagination works. |
| create | — | A function to create a new Calendar object for a given calendar identifier. If not provided, the createCalendar function from @internationalized/date will be used. | |
| disabled | boolean | — | Turns off the control: no focus, no edits, and the disabled look. |
| read | boolean | — | The user can focus and read the value, but cannot change it. |
| invalid | boolean | — | Shows the invalid look and sets aria-invalid. |
| on | — | Runs on each change, with the new value and the Base UI change details. | |
| class | string | — | |
| size | "default""lg""sm" | "default" | The cell size: sm 28, default 32, lg 36. On a touch screen every size grows to 44. |
| weeks | number | "auto" | — | The rows of a month view. Default 6, so the height never changes when the user pages. "auto": the rows of each month (4 to 6, React Aria). Week and day views ignore it. |
| labels | Partial<{ weekNumber: string; }> | — | The words (CALENDAR_LABELS), to translate them. Keep the object stable. |
| Tab | Moves focus between the previous button, the next button, and the grid. |
|---|---|
| Left ArroworRight Arrow | Moves focus one day back or on. Right to left swaps them. |
| Up ArroworDown Arrow | Moves focus one row up or down. |
| Page UporPage Down | Goes one month back or on. With Shift, goes one year. |
| HomeorEnd | Goes to the start or the end of the month. |
| EnterorSpace | Sets the start date, then the end date. |
| Escape | Drops a half range. |
- CalendarPick Calendar for one date, or many single dates, on a month grid.
- Date Range PickerType a start and an end date, or pick both in a two-month calendar. One field holds both dates, with times and range checks if you need them.
- Date PickerType a date, or pick it in a calendar that opens from the field. It supports limits, closed days, a time row, and form checks.
Built with
Installs with Range Calendar
- Components
- Calendar





