From d92bd642648208148efad331a78e8e908bac300d Mon Sep 17 00:00:00 2001 From: gitstart Date: Thu, 1 Dec 2022 11:28:38 +0000 Subject: [PATCH] chore: corrects wrong editor focus checking method --- .../admin/src/content-manager/components/Wysiwyg/Editor.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/admin/admin/src/content-manager/components/Wysiwyg/Editor.js b/packages/core/admin/admin/src/content-manager/components/Wysiwyg/Editor.js index cd52003914..a5f2f7bb55 100644 --- a/packages/core/admin/admin/src/content-manager/components/Wysiwyg/Editor.js +++ b/packages/core/admin/admin/src/content-manager/components/Wysiwyg/Editor.js @@ -43,7 +43,7 @@ const Editor = ({ }, [editorRef, textareaRef, name, placeholder]); useEffect(() => { - if (value && !editorRef.current.state.focused) { + if (value && !editorRef.current.hasFocus()) { editorRef.current.setValue(value); } }, [editorRef, value]);