diff --git a/src/main/frontend/handler/editor.cljs b/src/main/frontend/handler/editor.cljs index 4ebc8a3af1..6012e4aa6b 100644 --- a/src/main/frontend/handler/editor.cljs +++ b/src/main/frontend/handler/editor.cljs @@ -1372,8 +1372,11 @@ (defn cut-block! [block-id] (when-let [block (db/pull [:block/uuid block-id])] - (let [content (:block/content block)] - (common-handler/copy-to-clipboard-without-id-property! (:block/format block) content) + (let [repo (state/get-current-repo) + content (:block/content block) + ;; TODO: support org mode + [md-content _tree] (compose-copied-blocks-contents-&-block-tree repo [block-id])] + (common-handler/copy-to-clipboard-without-id-property! (:block/format block) md-content) (delete-block-aux! block true)))) (defn clear-last-selected-block! @@ -1865,11 +1868,6 @@ (util/stop event) (state/append-current-edit-content! doc-text)))))) -(defn- block-and-children-content - [block-children] - (-> (map :block/content block-children) - string/join)) - (defn- reorder-selected-blocks [blocks] (let [repo (state/get-current-repo)