We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a845127 + aa609c8 commit 5c29c1fCopy full SHA for 5c29c1f
src/datepicker/datepicker.component.ts
@@ -477,6 +477,9 @@ export class DatePicker implements
477
// flatpickr calendar using a keyboard.
478
const addFocusCalendarListener = (element: HTMLInputElement) => {
479
element.addEventListener("keydown", (event: KeyboardEvent) => {
480
+ if (event.key === "Escape") {
481
+ this.flatpickrInstance.close();
482
+ }
483
if (event.key === "ArrowDown") {
484
if (!this.flatpickrInstance.isOpen) {
485
this.flatpickrInstance.open();
0 commit comments