Releases: rehookify/datepicker
Fix Months Buttons
⚙️ fix Months buttons disabled state when min and max dates provided to config.
Edge offset detection
Thanks to @susosamuel and his #51
Now add/subtractOffset
functions defines the edge and allows to switch to the month with max/minDate
but set offset to the edge.
Fix: rollback bad typings
- 🛠️ fix bad typings for Providers
- 🔁 rallback transition to functions
- 🆙 bump all deps to latest
Accessibility improvements
- All instances now have only one item with
tabIndex: 0
it is defined by theactive
prop which is calculated based onoffsetDate
.
It will help navigate the calendar, month, years and time with the Tab key. - Fix the edge case in the create month test where it failed when the current month is December. The date-picker worked as expected tho.
Docs fix
- fix the tutorials link at the bottom of the README.md
- change exports in several files
Colocate variables
- remove
constants.ts
and colocate all variables directly to the places of use - simplify all generative functions for calendars, years, months and time
- move several files from const to var + functions
Array creation performance
Change logic for array creation for calendars, time, month and years.
It should work 2 times faster and make UX much better.
External documentation
- updated README.md with new documentation
Now documentation lives on rehookify.com/datepicker
DevEx improments
In order to simplify setup and CONTRIBUTION to the library we moved to the pnpm with workspace.
It gives us such benefits:
- single install, now you need to run
pnpm i
in the root folder - workspace package linking, examples app will get the latest version of the datepicker automatically
- consistent e2e, because of the previous point we can test over the latest lib version in CI
- the simplicity of running the app for development
pnpm dev
in the root folder will run dev server and build lib in watch mode
All changes was reflected in the CONTRIBUTING.md
Fix month and year button behaviour with min/maxDate
Month and Year buttons now check only if the next offset will be more than the corresponding entity.
It will allow you to see all available dates at the closest edges to min/maxDate
If maxDate is 5 of November then November will be available in the Month picker