mirror of
https://github.com/zadam/trilium.git
synced 2025-01-14 02:58:39 +08:00
fix clicking internal link in the ckeditor toolbar, closes #3236
This commit is contained in:
parent
f6ad1c6aa7
commit
c7acfd4d4e
3 changed files with 4 additions and 15 deletions
2
libraries/ckeditor/ckeditor.js
vendored
2
libraries/ckeditor/ckeditor.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -230,18 +230,7 @@ function focusSavedElement() {
|
|||
return;
|
||||
}
|
||||
|
||||
if ($lastFocusedElement.hasClass("ck")) {
|
||||
// must handle CKEditor separately because of this bug: https://github.com/ckeditor/ckeditor5/issues/607
|
||||
|
||||
const editor = $lastFocusedElement
|
||||
.closest('.ck-editor__editable')
|
||||
.prop('ckeditorInstance');
|
||||
|
||||
editor.editing.view.focus();
|
||||
} else {
|
||||
$lastFocusedElement.focus();
|
||||
}
|
||||
|
||||
$lastFocusedElement.focus();
|
||||
$lastFocusedElement = null;
|
||||
}
|
||||
|
||||
|
@ -252,7 +241,7 @@ async function openDialog($dialog, closeActDialog = true) {
|
|||
}
|
||||
|
||||
saveFocusedElement();
|
||||
|
||||
-
|
||||
$dialog.modal();
|
||||
|
||||
$dialog.on('hidden.bs.modal', () => {
|
||||
|
|
Loading…
Reference in a new issue