Skip to content

Releases: gpbl/react-day-picker

v10.0.0

08 May 07:44
2c5ba1f

Choose a tag to compare

DayPicker v10 removes the public APIs deprecated in v9 and introduces a new @daypicker/react package name. Non-Gregorian calendars are now published as standalone @daypicker/* packages.

If your app already uses the current v9 API, the upgrade should be relatively small. If your app still relies on deprecated v9 APIs, those usages should be updated before upgrading.

See the full v10 changelog, the upgrade guide, and the v10 announcement for questions and upgrade feedback.

Install

npm install react-day-picker@latest

For new projects, prefer the scoped package name:

npm install @daypicker/react@latest
import { DayPicker } from "@daypicker/react";
import "@daypicker/react/style.css";

The react-day-picker package remains available in v10 for compatibility.

Breaking Changes

Deprecated navigation props removed

Removed prop Use instead
fromMonth startMonth
fromYear startMonth={new Date(year, 0)}
toMonth endMonth
toYear endMonth={new Date(year, 11)}
fromDate hidden={{ before: date }} and optionally startMonth
toDate hidden={{ after: date }} and optionally endMonth

Deprecated focus and event props removed

Removed prop Use instead
initialFocus autoFocus
onWeekNumberClick A custom WeekNumber component
onDayKeyUp A custom DayButton component
onDayKeyPress A custom DayButton component
onDayPointerEnter A custom DayButton component
onDayPointerLeave A custom DayButton component
onDayTouchCancel A custom DayButton component
onDayTouchEnd A custom DayButton component
onDayTouchMove A custom DayButton component
onDayTouchStart A custom DayButton component

Deprecated aliases removed

Removed API Use instead
formatMonthCaption formatCaption
formatYearCaption formatYearDropdown
labelDay labelDayButton
labelCaption labelGrid
isMatch dateMatchModifiers
isDateInRange rangeIncludesDate

Other removed compatibility APIs

  • Removed deprecated type exports from types/deprecated.
  • Removed the deprecated components.Button customization entry. Use PreviousMonthButton and NextMonthButton.
  • Removed deprecated DeprecatedUI compatibility typing for classNames and styles.
  • Removed deprecated DateLib exports: FormatOptions, LabelOptions, dateLib, and DateLib.Date.
  • Removed the deprecated react-day-picker/jalali subpath. Use the Persian calendar package instead.

Calendar Package Changes

Non-Gregorian calendars are now published as standalone packages under the @daypicker/* scope:

npm install @daypicker/react @daypicker/persian
npm install @daypicker/react @daypicker/hebrew
npm install @daypicker/react @daypicker/buddhist
npm install @daypicker/react @daypicker/ethiopic
npm install @daypicker/react @daypicker/hijri

The amET locale export moved to @daypicker/ethiopic.

Fixes

  • Fixed dropdown navigation in multi-month calendars so changing month or year shows the expected month.

What's Changed

  • feat!: remove deprecated public APIs by @gpbl in #2920
  • feat!: extract @daypicker/hijri and @daypicker/persian by @gpbl in #2938
  • feat!: extract @daypicker/buddhist, @daypicker/ethiopic, and @daypicker/hebrew by @gpbl in #2939
  • feat: add @daypicker/react as the preferred package name by @gpbl in #2970
  • fix: move the amET locale export to @daypicker/ethiopic by @gpbl in #2968
  • fix: show the expected month after dropdown changes in multi-month calendars by @hackgray47-eng in #2977

Full Changelog: v9.14.0...v10.0.0

v8.10.2

03 May 09:18

Choose a tag to compare

Expands the React peer dependency to include React 19, helping projects still using DayPicker v8 adopt newer React versions without peer dependency warnings.

Upgrading to v9

Please note that DayPicker v8 is in maintenance mode. This release is intended to help existing v8 users stay unblocked, but upgrading to v9 is recommended when possible.

If you are still on v8, review the updated upgrade guide:
https://daypicker.dev/upgrading-v8-to-v10

What's Changed

Full Changelog: v8.10.1...v8.10.2

v9.14.0

26 Feb 15:00
a5b0c43

Choose a tag to compare

This release introduces a new resetOnSelect prop and adds support for the Hijri calendar.

Resetting Selections in Range Mode

When in range selection mode, use the new resetOnSelect prop to start a new range when a full range is already selected.

Hijri Calendar

To use the Hijri (Umm al-Qura) calendar, import DayPicker from react-day-picker/hijri:

import { DayPicker } from "react-day-picker/hijri";

export function HijriCalendar() {
  return <DayPicker />;
}

Read more in the documentation and play with it in playground.

What's Changed

  • feat: Add Hijri calendar support (Umm al-Qura) by @ws-rush in #2904
  • feat: New resetOnSelect prop to reset date range when selecting date with completed range by @rodgobbi in #2906
  • feat: add default lang prop to DayPicker root element by @gpbl in #2907

New Contributors

Full Changelog: v9.13.2...v9.14.0

v9.13.2

10 Feb 00:14
38e1b27

Choose a tag to compare

What's Changed

  • fix(build): add correct type declaration for style.css export by @NotNestor in #2897
  • fix(locale): correct Northern Sami (se) and Japanese Hiragana (ja-Hira) labels by @gpbl in #2898

New Contributors

Full Changelog: v9.13.1...v9.13.2

v9.13.1

06 Feb 22:35
375f48a

Choose a tag to compare

Persian calendar improvements.

What's Changed

  • feat: add narrow weekday format for Persian calendar by @rezaaa in #2895

New Contributors

Full Changelog: v9.13.0...v9.13.1

v9.13.0

18 Dec 09:40
103fe7f

Choose a tag to compare

This release introduces an experimental noonSafe prop to help deal with historical time zones with second offsets. See https://daypicker.dev/localization/setting-time-zone#noonsafe for more details.

What's Changed

  • feat: add experimental noonSafe prop for timezone offsets by @gpbl in #2879

Full Changelog: v9.12.0...v9.13.0

v9.12.0

06 Dec 18:08
b157efb

Choose a tag to compare

This release adds translated labels to built-in locales and fixes issues with array modifiers and the Hebrew calendar.

Translated Locales

DayPicker locales now ship with localized labels (e.g., “Go to next month”, “Today”), so you no longer need to supply them via labels. To use a locale:

import { es } from "react-day-picker/locale";
<DayPicker locale={es} /> // Use Spanish locale, now with translated labels.

If you previously set the labels prop for translations, you can remove it. For details on switching locales, see https://daypicker.dev/localization/changing-locale.

What's Changed

  • feat: add locale-aware labels and translated locale wrappers by @gpbl in #2861
  • fix: match Date[] modifiers by day by @gpbl in #2865
  • fix: correct Hebrew date conversion timezone handling by @gpbl in #2870

Full Changelog: v9.11.3...v9.12.0

v9.11.3

29 Nov 11:17
567cc8a

Choose a tag to compare

Rendered HTML now includes empty cells in grids when endMonth is set, and fixes the v9.11.2 regression where JSDOM tests could fail when focusing disabled days.

Possible low impact breaking change: The grid markup changed, so brittle snapshot tests or custom CSS that depended on the old structure may need updates. Adjust snapshots/CSS accordingly.

What's Changed

  • fix: ensure final week renders when endMonth clips the calendar by @gpbl in #2856
  • fix: prevent selecting disabled focused days by @gpbl in #2860

Full Changelog: v9.11.2...v9.11.3

v9.11.2

23 Nov 13:08
9ee9bbf

Choose a tag to compare

What's Changed

  • fix: ensure modifiers honor the timeZone prop by @gpbl in #2849
  • fix: allow focused disabled days to remain focusable by @gpbl in #2851
  • chore(performance): cache resolved today across helpers for better performance by @gpbl in #2848
  • chore(performance): memoize calendar and reuse ISO date ids in day rendering by @gpbl in #2850

Full Changelog: v9.11.1...v9.11.2

v9.11.1

08 Oct 10:58
ec9b1eb

Choose a tag to compare

What's Changed

  • fix: duplicated years in dropdown for some timezones by @gpbl in #2836
  • fix: prevent focus navigation past disabled bounds by @gpbl in #2839

Full Changelog: v9.11.0...v9.11.1