Kendo Jquery Date picker closes modal (not kendo) when selecting a year

2 Answers 20 Views
Date/Time Pickers
Peter
Top achievements
Rank 1
Iron
Peter asked on 15 Jan 2025, 09:42 PM

The modal isn't very large, so the calendar popup shows outside the modal.

When selecting a day or month, the date picker is updated and the modal remains open.
When selecting a year, the modal closes. 

As though the mouse click gets passed to the page.

Kendo: 2024.1.319

2 Answers, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 20 Jan 2025, 10:23 AM

Hello, Peter,

I tested the scenario in this Dojo example, and it appears to be working as expected. Could you please modify it so that I can see the issue you are experiencing?

Looking forward to your reply.

Regards,
Martin
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Peter
Top achievements
Rank 1
Iron
commented on 21 Jan 2025, 11:04 AM | edited

Thanks for the Dojo, we are are using a different kind of modal.   Apparently, when the browser is in device mode, the mouse works properly, but in desktop mode it does not.   Keyboard works also.

We have a click event on the page, that isn't appropriately detecting the calendar in its various modes, hence letting the click through.

 

Martin
Telerik team
commented on 24 Jan 2025, 08:25 AM

Hello, Peter,

In order to investigate further, kindly provide a runnable example with the modal you are using. Another thing you can try is using the Kendo modal Window to see if the issue persists.

0
Peter
Top achievements
Rank 1
Iron
answered on 24 Jan 2025, 11:34 AM
The problem was resolved.   We had a click event on the page which was apparently accounting for Month/day of the calendar, but not the Year/Year Range.

            !$(event.target).closest('.k-calendar').length &&
            !$(event.target).closest('.k-calendar-table').length

Adding the second line, allowed the click event to ignore the Year/Year Range of the date picker's calendar.   Hopefully, class names won't change.

Thanks
Tags
Date/Time Pickers
Asked by
Peter
Top achievements
Rank 1
Iron
Answers by
Martin
Telerik team
Peter
Top achievements
Rank 1
Iron
Share this question
or