Skip to content

Releases: gpbl/react-day-picker

v9.6.2

12 Mar 23:16
Compare
Choose a tag to compare

Fix issues when importing the Persian calendar or the CSS types declaration.

What's Changed

New Contributors

Full Changelog: v9.6.1...v9.6.2

v9.6.1

08 Mar 20:35
Compare
Choose a tag to compare

This release addresses an accessibility issue, adds a new animate prop and fixes other minor bugs.

Possible Breaking Change in Custom Styles

To address a focus lost bug affecting navigation buttons, we updated the buttons to use aria-disabled instead of the disabled attribute.

This change may cause custom styles for those disabled buttons to break. To fix it in your code, update the CSS selector to target [aria-disabled="true"]:

- .rdp-button_next:disabled,
+ .rdp-button_next[aria-disabled="true"] {
  /* your custom CSS */
}
- .rdp-button_previous:disabled,
+ .rdp-button_previous[aria-disabled="true"] {
  /* your custom CSS */
}

Animating Month Transitions

Thanks to the work by @rodgobbi, we have added animations to DayPicker. The new animate prop enables CSS transitions for captions and weeks when navigating between months:

<DayPicker animate />

Customizing the animation style can be challenging due to the HTML table structure of the grid. We may address this in the future. Please leave your feedback in DayPicker Discussions.

What's Changed

  • feat: new animate prop by @rodgobbi in #2684
  • feat(performance): add sideEffects property to package.json by @rodgobbi in #2673
  • fix(accessibility): focus lost when navigation button is disabled by @gpbl in #2685
  • fix: render selected days with selected modifier when disabled by @rodgobbi in #2700
  • fix(build): remove extra files from package.json by @gpbl in #2692
  • chore(types): fix deprecation of select event handler types by @timothyis in #2680

v9.6.1

  • fix(build): add missing .css entries in package.json files by @gpbl in #2703

New Contributors

Full Changelog: v9.5.1...v9.6.1

v9.6.0

08 Mar 14:42
Compare
Choose a tag to compare

This release addresses an accessibility issue, adds a new animate prop and fixes other minor bugs.

⚠️ Note v9.6.0 presents a bug when importing style.css. Please upgrade to v9.6.1 for a fix.

v9.5.1

27 Jan 14:41
Compare
Choose a tag to compare

This release fixes the calendar breaking its layout when passing a month not included between startMonth and endMonth props.

What's Changed

  • fix: display calendar in a valid month when month prop is invalid by @rodgobbi in #2672
  • fix(test): using new Date() instead of today() fails test by @gpbl in #2656
  • chore(types): update DateLib to not import types from date-fns by @gpbl in #2655
  • docs: fix broken style.css link by @jakedee in #2666
  • docs: custom components guide to display better examples by @rodgobbi in #2668

New Contributors

Full Changelog: v9.5.0...v9.5.1

v9.5.0

29 Dec 23:05
Compare
Choose a tag to compare

This release adds full support for the Persian calendar and a new numerals prop to set the numbering system.

Breaking Change: Dropdown Formatters

The formatMonthDropdown and formatYearDropdown now receive a Date (instead of a number) as first argument.

<DayPicker formatters={{ 
-     formatMonthDropdown: (month) => format(new Date(month), "mmmm") }} 
+     formatMonthDropdown: (date) => format(date, "mmmm") }} />
-     formatYearDropdown: (year) => format(new Date(year), "yyyy") }} 
+     formatYearDropdown: (date) => format(date, "yyyy") }} />
/>

Persian Calendar

Persian Calendar get fulls support in DayPicker and replaces the previous "Jalali Calendar".

If you were using DayPicker from react-day-picker/jalali, change your imports to react-day-picker/persian:

- import { DayPicker } from  `react-day-picker/jalali`;
+ import { DayPicker } from  `react-day-picker/persian`;

See the Persian calendar documentation for more details about using Persian calendar in DayPicker.

What's Changed

  • feat: add Persian calendar support by @gpbl in #2645
  • feat: add new numerals prop by @gpbl in #2647
  • feat: add today, newDate, timeZone to the DateLib class by @gpbl in #2642
  • feat: remove startMonth/endMonth constraints when caption layout is dropdown-months by @rodgobbi in #2648
  • build: add date-fns-jalali to the package dependencies by @gpbl in #2640
  • fix(breaking): dropdown formatters to use dateLib format by @gpbl in #2644
  • fix(jalali): incorrect Jalali month names when using dropdown layouts by @gpbl in #2645
  • fix(chore): always use Date constructor from dateLib by @gpbl in #2636
  • fix(chore): use dateLib for getting days/months/years from a Date by @gpbl in #2643

Full Changelog: v9.4.4...v9.5.0

v9.4.4

15 Dec 19:07
ee20914
Compare
Choose a tag to compare

This release fixes an issue with the month names in the Jalali calendar.

What's Changed

  • fix(jalali): defaults calendar to faIR locale and RTL direction by @gpbl in #2624

Full Changelog: v9.4.3...v9.4.4

v9.4.3

11 Dec 22:58
Compare
Choose a tag to compare

This release enhances compatibility with React 19.

What's Changed

  • chore(types): update HTML attributes for React 19 compatibility by @gpbl in #2621
  • refactor(jest): switch to @swc/jest for faster transforms by @thevuong in #2620

New Contributors

Full Changelog: v9.4.2...v9.4.3

v9.4.2

08 Dec 23:11
a617141
Compare
Choose a tag to compare

This release addresses some bugs in the dropdown caption layout.

What's Changed

New Contributors

Full Changelog: v9.4.1...v9.4.2

v9.4.1

30 Nov 23:50
35a2824
Compare
Choose a tag to compare

This release improves support for screen readers and fixes a VoiceOver issue when navigating the calendar.

What's Changed

  • fix(a11y): improve screen reader and VoiceOver support by @gpbl in #2609
  • feat(a11y): added role and aria-label props by @gpbl in #2609
  • chore(style): remove unused CSS variable by @gpbl in #2610
  • chore: use callbacks for dropdown event handlers by @gpbl in #2602

Full Changelog: v9.4.0...v9.4.1

v9.4.0

24 Nov 15:12
10bbecb
Compare
Choose a tag to compare

This version includes support for broadcast calendars and some style fixes.

What's Changed

  • feat: add support for broadcast calendars by @Nradar in #2597
  • fix(styles): dropdown not appearing as focused by @gpbl in #2600
  • fix(styles): inconsistent cell size when selection mode is set by @gpbl in #2601
    • please note that the CSS variables --rdp-day-height, --rdp-day-width, --rdp-day-button-height, --rdp-day-button-width have been updated to pixel values (44px for day cells and 42px for day buttons).

New Contributors

Full Changelog: v9.3.2...v9.4.0