Skip to content

Releases: wojtekmaj/react-calendar

v2.10.0

06 Jan 11:18
Compare
Choose a tag to compare

What's new?

  • Ability to select range. You can enable range selection mode by using selectRange prop.
  • When passed a date range as a value, days can now be partially highlighted just like months, years and decades can. Behavior when passed a single date remains unchanged and won't cause day to be partially highlighted.
  • Internal layout changes. They should not cause issues with custom styling, although in some extreme cases minor adjustments may be necessary.
  • Several performance and size optimizations.

Bug fixes

  • Fixed an accessibility issue with default calendar styling in which tiles selected using keyboard were not properly highlighted.
  • Fixed uncaught error when provided (invalid) value as an array with one element.
  • Fixed uncaught error when provided tileContent function that was not an instance of Function (e.g. Jest mock function).
  • Minor accessibility fix in Test suite.

v2.9.0

27 Dec 08:32
Compare
Choose a tag to compare

What's new?

  • Compiled files are now placed in a standard ./dist category.
  • Sample and Test suites are now using Parcel for bundling.
  • Updated development platform:
    • Updated Jest to version 22.
    • Replaced babel-preset-es2015 with babel-preset-env.

v2.8.0

16 Dec 19:29
Compare
Choose a tag to compare

What's new

  • New callback functions - onActiveDateChange, onDrillUp and onDrillDown. All of them return an object with activeStartDate and view (#18).
  • Optimized performance by using PureComponents.

Bug fixes

  • Fixed an issue that could have caused week numbers to be shifted by one resulting in a React error (#17). Thanks, @amansur!

v2.7.1

15 Dec 16:58
Compare
Choose a tag to compare

Bug fixes

  • Fixed type clash between React-Calendar and React-Date-Picker (#19). Thanks, @archer87pl!

v2.7.0

10 Dec 20:04
Compare
Choose a tag to compare

What's new?

  • You can now pass dates as strings. Be careful though; while non-ISO formats may be resolved correctly, some browsers may fail to do so.
  • Minor enhancements and performance optimizations.

v2.6.0

02 Dec 14:14
Compare
Choose a tag to compare

What's new?

  • You can now use onClickWeekNumber callback to bind events to week numbers, if shown (#12).
  • Added 27 new unit tests.

Bug fixes

  • Fixed a bug that caused YearView, DecadeView and CenturyView tiles to pass dates off by 12 hours to tileClassName/tileContent functions.

v2.5.0

30 Nov 22:46
Compare
Choose a tag to compare

What's new?

  • You can now pass activeStartDate as a prop to Calendar, just like you could to MonthView, YearView etc. before. It will be used to determine a view to display when no value is given. When not provided, React-Calendar will display today's date by default like before (#13).

Bug fixes

  • Fixed an invalid React prop type warning when tileClassName provided was a function.

v2.4.0

28 Nov 20:27
Compare
Choose a tag to compare

What's new?

  • More control over what's displayed in calendar tiles. Use tileContent to provide custom content to the tiles - statically or dynamically. Use tileClassName to apply custom class name to the tiles, also statically or dynamically. See README.md for more details (#9).

What's changed?

  • renderChildren was replaced with much more powerful tileContent. In tileContent, you're no longer limited to passing content by using a function, you can also use a React element or a string. renderChildren will automatically be mapped to tileContent til the next major version.

v2.3.1

15 Nov 22:18
Compare
Choose a tag to compare

What's new?

  • Dates in <time>'s datetime attribute are now local (ISO 8601 compilant) dates, while previously we were using UTC. This makes the dates much more understandable.
    • For example, a tile with the first day of January 2017 is now marked as 2017-01-01T00:00:00.000 while previously it could be 2016-12-31T23:00:00.000Z if you were in UTC+1 timezone.

v2.3.0

14 Nov 17:10
Compare
Choose a tag to compare

What's new?

  • Added TypeScript definitions. Thanks, @third774!
  • Added more classes for easier styling. Now "previous", "next", "previous 2" and "next 2" buttons all have distinct classes.

Bug fixes

  • Fixed minor accessibility issues.
  • Fixed Calendar saving chosen date in its state for no reason.