Hacker0x01 / react-datepicker

A simple and reusable datepicker component for React
https://reactdatepicker.com/
MIT License
8.12k stars 2.24k forks source link

Week number is highlighted when on first day of the week navigating using arrow keys #5200

Closed Grisu118 closed 2 days ago

Grisu118 commented 4 weeks ago

Describe the bug Week number gets highlighted when selecting the first day of the week with arrow keys, but not when selecting any other day of the week.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://reactdatepicker.com/#example-display-week-numbers
  2. Open the datepicker
  3. Navigate within with the arrow keys
  4. See error

Expected behavior Either the week is always highlighted or never. The current behaviour seems to be weird

Screenshots grafik grafik

Desktop (please complete the following information):

Additional context There was already a similar issue: https://github.com/Hacker0x01/react-datepicker/issues/4489

OlegDev1 commented 4 weeks ago

We need to known in which cases the week should or shouldn't be highlighted. Could you please help with this, @martijnrusschen? Or, if possible, could you mention another contributor responsible for this?

I can work on PR for this issue and write necessary test cases.