Close calendar popup with Esc

This commit is contained in:
yflory 2021-04-14 15:18:05 +02:00
parent a789d585e4
commit e6fba31884
2 changed files with 6 additions and 1 deletions

View File

@ -733,6 +733,12 @@ Messages.calendar_allDay = "All day";
});
});
$('body').on('keydown', function (e) {
if (e.which === 27) {
$('.tui-full-calendar-floating-layer').hide();
}
});
updateDateRange();
renderCalendar();

View File

@ -138,7 +138,6 @@ ctx.calendars[channel] = {
var teamId = cfg.storeId;
var data = cfg.data;
var channel = data.channel;
console.error(cfg);
if (!channel) { return; }
var c = ctx.calendars[channel];