fix(editor): focus the editor when clicking on the whole edit container
This commit is contained in:
parent
5a25685d53
commit
c5ba7fcb73
@ -64,6 +64,7 @@
|
|||||||
class="tiptap__editor"
|
class="tiptap__editor"
|
||||||
:class="{'tiptap__editor-is-edit-enabled': isEditing}"
|
:class="{'tiptap__editor-is-edit-enabled': isEditing}"
|
||||||
:editor="editor"
|
:editor="editor"
|
||||||
|
@click="focusIfEditing()"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<input
|
<input
|
||||||
@ -581,6 +582,12 @@ function setFocusToEditor(event) {
|
|||||||
editor.value?.commands.focus()
|
editor.value?.commands.focus()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function focusIfEditing() {
|
||||||
|
if (isEditing.value) {
|
||||||
|
editor.value?.commands.focus()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function clickTasklistCheckbox(event) {
|
function clickTasklistCheckbox(event) {
|
||||||
event.stopImmediatePropagation()
|
event.stopImmediatePropagation()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user