chore: add logseq.api.download_graph_pages

pull/2722/head
Tienson Qin 2021-08-25 23:39:58 +08:00
parent b6ca78678b
commit 5994093218
1 changed files with 6 additions and 0 deletions

View File

@ -5,6 +5,7 @@
[frontend.handler.block :as block-handler]
[frontend.handler.editor :as editor-handler]
[frontend.handler.dnd :as editor-dnd-handler]
[frontend.handler.export :as export-handler]
[frontend.modules.outliner.core :as outliner]
[frontend.modules.outliner.tree :as outliner-tree]
[frontend.util :as util]
@ -459,6 +460,11 @@
(.setAttribute anchor "download" (str (string/replace repo "/" " ") ".transit"))
(.click anchor))))))
(defn ^:export download_graph_pages
[]
(when-let [repo (state/get-current-repo)]
(export-handler/export-repo-as-zip! repo)))
;; helpers
(defn ^:export show_msg
([content] (show_msg content :success))