Closed ryantanrk closed 4 months ago
Attention: Patch coverage is 97.69585%
with 5 lines
in your changes are missing coverage. Please review.
Project coverage is 96.67%. Comparing base (
d594e74
) to head (04f208c
).
Files | Patch % | Lines |
---|---|---|
src/index.tsx | 96.29% | 4 Missing :warning: |
src/week_number.tsx | 0.00% | 1 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@ryantanrk thanks for the extensive pull request. Since there has been some discussions with the pull request team, I wanted to check if there's any outstanding items to address.
hi @martijnrusschen , i have yet to rewrite the logic according to Luciano's comments, as well as adding more test coverage. i'll update when it's done :)
PR should be good for another review. @martijnrusschen
Would like some opinions on how the edge case where all dates are disabled should be handled
name: Allow for skipping of excluded dates/weeks/months about: Create a pull request to improve this repository title: Allow for skipping of excluded dates/weeks/months labels: "" assignees: ""
Description
Linked issue: #4731
Problem Currently, the date picker only stops when the user is about to navigate to an excluded month, which, if let's say there are multiple disabled dates side by side spanning the whole row, the user is unable to navigate to the months after it. This only happens on the month picker.
Changes I have made recursive functions in the keydown functionality of the month and day calendar to get a new day/month if the date is disabled/excluded. Even though this is only a month picker thing, I have changed the behavior of the day calendar as well to make it consistent.
Screenshots
Day
https://github.com/Hacker0x01/react-datepicker/assets/49902829/5637ad57-2773-4d69-ba58-a9714167bfed
Week
https://github.com/Hacker0x01/react-datepicker/assets/49902829/ccae4796-7db5-4292-b552-52cc5c74cb72
Month
https://github.com/Hacker0x01/react-datepicker/assets/49902829/54e07d27-1298-4562-a337-f03ab33c6675
To reviewers
If this behavior should be made optional, please let me know
Contribution checklist