From b595d1fade6978ee8975916e842c59d8320d25be Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Thu, 10 Jul 2025 16:35:44 +0300 Subject: [PATCH] fix(popup_editor): ckeditor modals not showing --- apps/client/src/widgets/dialogs/popup_editor.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/apps/client/src/widgets/dialogs/popup_editor.ts b/apps/client/src/widgets/dialogs/popup_editor.ts index 402d1d5a2..2c3701b1f 100644 --- a/apps/client/src/widgets/dialogs/popup_editor.ts +++ b/apps/client/src/widgets/dialogs/popup_editor.ts @@ -114,7 +114,13 @@ export default class PopupEditorDialog extends Container { async openPopupEditorEvent(noteId: string) { this.noteId = noteId; if (await this.refresh()) { - openDialog(this.$widget); + const $dialog = await openDialog(this.$widget); + $dialog.on("shown.bs.modal", () => { + // Reduce the z-index of modals so that ckeditor popups are properly shown on top of it. + // The backdrop instance is not shared so it's OK to make a one-off modification. + $("body > .modal-backdrop").css("z-index", "998"); + $dialog.css("z-index", "999"); + }); } }