Skip to content

Commit 9784c61

Browse files
pkp/pkp-lib#11693 Address modal compatibility with jquery-ui (date picker)
1 parent 86d3eb8 commit 9784c61

File tree

2 files changed

+13
-6
lines changed

2 files changed

+13
-6
lines changed

src/components/Form/fields/FieldRichTextarea.vue

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -406,9 +406,4 @@ export default {
406406
direction: rtl;
407407
}
408408
}
409-
// #11693 reka-ui sets pointer-events: none on body when modal is opened
410-
// which prevented to click on tinyMCE modals
411-
body .tox-tinymce-aux.tox {
412-
pointer-events: auto;
413-
}
414409
</style>

src/components/Modal/SideModalBody.vue

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ const closeModalButton = inject('closeModalButton');
123123
// #11693 When tinyMCE modal is opened inside modal, ignore outside clicks to prevent closing the current modals
124124
function handleOutsideEvent(event) {
125125
// Check if the target is part of TinyMCE's dialog
126-
if (event.target.closest('.tox-tinymce-aux')) {
126+
if (event.target.closest('.tox-tinymce-aux, .ui-widget')) {
127127
event.preventDefault(); // Bypass the focus trap for TinyMCE elements
128128
}
129129
}
@@ -187,3 +187,15 @@ html[dir='rtl'] .DialogContent[data-state='closed'] {
187187
animation: sideModalSlideOutRtl 450ms ease-in-out;
188188
}
189189
</style>
190+
<style>
191+
/** #11693 reka-ui sets pointer-events: none on body when modal is opened */
192+
/** Addresses jquery widgets, like the date selector */
193+
.ui-widget {
194+
pointer-events: auto;
195+
}
196+
197+
/** Addresses tinyMCE modals */
198+
body .tox-tinymce-aux.tox {
199+
pointer-events: auto;
200+
}
201+
</style>

0 commit comments

Comments
 (0)