From 471cad3ae95681c5b0ebdaa467e6474d5d07c63c Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Fri, 19 Feb 2021 10:53:41 +0100 Subject: [PATCH] :bug: Disable placeholders on text editor. Causes crash on use IME. --- frontend/src/app/main/ui/workspace/shapes/text/editor.cljs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/frontend/src/app/main/ui/workspace/shapes/text/editor.cljs b/frontend/src/app/main/ui/workspace/shapes/text/editor.cljs index c62865146..961d800e2 100644 --- a/frontend/src/app/main/ui/workspace/shapes/text/editor.cljs +++ b/frontend/src/app/main/ui/workspace/shapes/text/editor.cljs @@ -224,7 +224,7 @@ on-composition-start (mf/use-callback - (fn [] + (fn [event] (.insertText slate/Editor editor ""))) on-change @@ -269,7 +269,8 @@ ;; WARN: monky patch (obj/set! slate/Transforms "deselect" (constantly nil))) :on-composition-start on-composition-start - :placeholder (when (= :fixed grow-type) "Type some text here...")}]]])) + ;; :placeholder (when (= :fixed grow-type) "Type some text here...") + }]]])) (mf/defc text-shape-edit {::mf/wrap [mf/memo]