Jodit Version: 4.1.2
Browser: Safary
OS: Mac
Is React App: True
Reproduced on xdsoft.net: False
Description
When the editor loses focus, it is impossible to insert content into the original cursor by calling APIs such as insertHTML and insertImage elsewhere;
Moreover, methods such as editor. s. save() and editor. s. restore() are ineffective, and editor. s. focus cannot be refocused;
Only appears on macOS, not on Windows!
Test like this Code
// editor config
{
buttons: [
// When the editor loses focus, click here,It won't take effect, the cursor cannot be added correctly to the editor
{
name: 'testFocus',
tooltip: 'testFocus',
exec: (e) => {
// e === window._MDEditor
e.selection.restore()
e.selection.focus()
},
},
]
event: {
blur: () => {
window._MDEditor.selection.save()
}
}
}
Expected behavior:
The cursor can be correctly restored. Consistent with running on windows.
Jodit Version: 4.1.2
Browser: Safary
OS: Mac
Is React App: True
Reproduced on xdsoft.net: False
Description
When the editor loses focus, it is impossible to insert content into the original cursor by calling APIs such as
insertHTMLandinsertImageelsewhere;Moreover, methods such as
editor. s. save()andeditor. s. restore()are ineffective, andeditor. s. focuscannot be refocused;Only appears on macOS, not on Windows!
Test like this Code
Expected behavior:
The cursor can be correctly restored. Consistent with running on windows.