浏览代码

fix: code not saved when click the bottom line to add a new block

related to #5406
Tienson Qin 3 年之前
父节点
当前提交
2eb5bbb6e8
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      src/main/frontend/extensions/code.cljs

+ 1 - 0
src/main/frontend/extensions/code.cljs

@@ -168,6 +168,7 @@
               new-content (if (string/blank? value)
                             (str prefix surfix)
                             (str prefix value "\n" surfix))]
+          (state/set-edit-content! (state/get-edit-input-id) new-content)
           (editor-handler/save-block-if-changed! block new-content))
 
         (:file-path config)