You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FORMS-21023: Close Date-Picker on touch-event in mobile/tablet devices (#1662)
* FORMS-21023: close datepicker on touch event in mobile/tablet devices
* Added event listener for touch event outside the calendar widget
* FORMS-21023: cypress tests for datepicker in mobile/tablet layout
Copy file name to clipboardExpand all lines: ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/datepicker/v1/datepicker/clientlibs/site/js/datepickerwidget.js
+17Lines changed: 17 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -27,6 +27,7 @@ if (typeof window.DatePickerWidget === 'undefined') {
27
27
#dp =null;
28
28
#curInstance =null;
29
29
#calendarIcon =null;
30
+
#documentTouchListener =null;
30
31
static #visible =false;
31
32
static #clickedWindow;
32
33
@@ -550,6 +551,17 @@ if (typeof window.DatePickerWidget === 'undefined') {
550
551
this.#focusedOnLi =false;
551
552
DatePickerWidget.#visible =true;
552
553
this.#position();
554
+
555
+
// Add document touch listener for mobile to close datepicker when tapping outside
0 commit comments