mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
Forward focus event on calendar open
This commit is contained in:
committed by
Konrad
parent
e076e23064
commit
ea76615763
@@ -57,6 +57,10 @@ export default class extends Flatpickr {
|
||||
this.fp.setDate(null);
|
||||
}
|
||||
|
||||
open() {
|
||||
this.fp.element.dispatchEvent(new Event("focus"));
|
||||
}
|
||||
|
||||
change(selectedDates, dateStr, instance) {
|
||||
if (this.hasStartTarget && this.hasEndTarget) {
|
||||
this.startTarget.value = selectedDates[0]
|
||||
|
||||
Reference in New Issue
Block a user