Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disabled dates can be selected using keyboard #2660

Open
vchandransuja-athene opened this issue Jun 14, 2022 · 0 comments
Open

Disabled dates can be selected using keyboard #2660

vchandransuja-athene opened this issue Jun 14, 2022 · 0 comments

Comments

@vchandransuja-athene
Copy link

Expected behaviour

It should not select a disabled date(disabled using the beforeShowDay option https://bootstrap-datepicker.readthedocs.io/en/stable/options.html#beforeshowday) even when we navigate and select using keyboard.

Actual behaviour

Even when a date is set to be disabled using beforeShowDay option, the date can still be selected using the keyboard(using arrow keys + enter key), however, it's not selectable using the mouse(which is expected). And using options such as daysOfWeekDisabled and datesDisabled to disable dates works fine, however trying to use beforeShowDay to disable dates doesnt work.

Datepicker version used

ex. v1.9.0

Example code

https://jsbin.com/jisotevoni/edit?html,js,console,output this jsbin reproduces the issue

I did a search on the same issue and I was able to find similar old issue #1365 and according to those issue it was fixed a long time back but I can still reproduce the same issue in 1.9.0. Or is it that I am doing something wrong?

Any help is appreciated, thanks in advance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant