kekeh / angular-mydatepicker

Angular datepicker and date range picker :date:
https://kekeh.github.io/angular-mydatepicker/
MIT License
1 stars 11 forks source link

Use arrow keys to navigate everywhere #60

Open ccondrup opened 4 years ago

ccondrup commented 4 years ago

Hello! Thanks for a nice package, good job!!

Feature request for using keyboard navigation: I have set a trigger on my input field: <input (focusin)="dp.openCalendar()" ... />

So if I tab into the input field, I see the datepicker automatically, great! I then press arrowDown to go down from the months header to dates, but nothing happens, I have to press Tab 5 times before I can use my arrow keys. It seems arrow keys are ignored.. but why? Even when I set moveFocusByArrowKeys: true?

I would like arrowRight to move focus like Tab, arrowLeft like Shift+Tab, and arrowDown to first focus "Monday" then 1, 7, 14 et cetera.

EDIT: Also, when the input already has a date and the datepicker is shown, it would be nice to have focus jump to the already set date.