Browse Source

chore: bump mldoc

Tienson Qin 4 years ago
parent
commit
3a8da3262a

+ 1 - 1
package.json

@@ -75,7 +75,7 @@
         "ignore": "^5.1.8",
         "is-svg": "4.2.2",
         "jszip": "^3.5.0",
-        "mldoc": "0.7.2",
+        "mldoc": "0.7.3",
         "path": "^0.12.7",
         "posthog-js": "^1.10.2",
         "react": "^17.0.2",

+ 2 - 1
src/main/frontend/components/block.cljs

@@ -1385,7 +1385,8 @@
            (str (:block/uuid block) "-" k)))]
 
       (and pre-block? properties)
-      [:span.opacity-50 "Properties"]
+      (ui/tippy {:title "Click to edit page properties"}
+                [:span "🍵"])
 
       :else
       nil)))

+ 1 - 7
src/main/frontend/components/export.cljs

@@ -27,9 +27,6 @@
         [:li.mb-4
          [:a.font-medium {:on-click #(export/export-repo-as-opml! current-repo)}
           (t :export-opml)]]
-        [:li.mb-4
-         [:a.font-medium {:on-click #(export/export-repo-as-edn! current-repo)}
-          (t :export-datascript-edn)]]
         [:li.mb-4
          [:a.font-medium {:on-click #(export/export-repo-as-edn-v2! current-repo)}
           (t :export-edn)]]
@@ -60,10 +57,7 @@
             (t :export-markdown)]]
           [:li.mb-4
            [:a.font-medium {:on-click #(export/export-page-as-opml! page)}
-            (t :export-opml)]]
-          [:li.mb-4
-           [:a.font-medium {:on-click #(export/convert-page-markdown-unordered-list-or-heading! page)}
-            (t :convert-markdown)]]]
+            (t :export-opml)]]]
          [:a#export-page-as-markdown.hidden]
          [:a#export-page-as-opml.hidden]
          [:a#convert-markdown-to-unordered-list-or-heading.hidden]]))))

+ 0 - 10
src/main/frontend/handler/export.cljs

@@ -93,16 +93,6 @@
         (.setAttribute anchor "download" (str (last (string/split repo #"/")) ".json"))
         (.click anchor)))))
 
-(defn export-repo-as-edn!
-  [repo]
-  (when-let [db (db/get-conn repo)]
-    (let [db-edn (db/db->edn-str db)
-          data-str (str "data:text/edn;charset=utf-8," (js/encodeURIComponent db-edn))]
-      (when-let [anchor (gdom/getElement "download-as-edn")]
-        (.setAttribute anchor "href" data-str)
-        (.setAttribute anchor "download" (str (last (string/split repo #"/")) ".edn"))
-        (.click anchor)))))
-
 (defn download-file!
   [file-path]
   (when-let [content (get-file-content file-path)]

+ 4 - 4
yarn.lock

@@ -3917,10 +3917,10 @@ mkdirp@^0.5.4, mkdirp@~0.5.1:
   dependencies:
     minimist "^1.2.5"
 
[email protected].2:
-  version "0.7.2"
-  resolved "https://registry.yarnpkg.com/mldoc/-/mldoc-0.7.2.tgz#c2ec364f504766fee149fe3fde7bde64bf558671"
-  integrity sha512-EPM9zVJwu7oOQ5d+AmyBJavPqW/XSwsyQ4mAsTXDAa5jiWu0CKcHul35XnFQKNBAQPqM5ao9HEYUydAg5lJh5A==
[email protected].3:
+  version "0.7.3"
+  resolved "https://registry.yarnpkg.com/mldoc/-/mldoc-0.7.3.tgz#ec9e29d08dd6a1cddbfc15de92c16fe7c8be03d6"
+  integrity sha512-BGtnVXw6CERhtjPnSM5QmETnIDTE4Vk1TDB+iwLUfLxY3/gRic+Tgun1VWdmwfo6XnUxkyGUezp76W/INPlg1g==
   dependencies:
     yargs "^12.0.2"