From 736129eb338f5eed3fc2b512022d6db41dbf638c Mon Sep 17 00:00:00 2001 From: Tienson Qin Date: Fri, 30 Apr 2021 20:37:59 +0800 Subject: [PATCH] chore: disable raw file editing mode temporally --- src/main/frontend/components/page.cljs | 26 +++++++++---------- .../frontend/modules/shortcut/binding.cljc | 2 +- .../frontend/modules/shortcut/handler.cljs | 2 +- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/main/frontend/components/page.cljs b/src/main/frontend/components/page.cljs index dad3e77d3..61a9c1281 100644 --- a/src/main/frontend/components/page.cljs +++ b/src/main/frontend/components/page.cljs @@ -385,19 +385,19 @@ page-name path-page-name))]]) [:div - [:div.content - (when (and file-path - (not sidebar?) - (not block?) - (not (state/hide-file?)) - (not config/publishing?)) - [:div.text-sm.ml-1.mb-4.flex-1.inline-flex - {:key "page-file"} - [:span.opacity-50 {:style {:margin-top 2}} (t :file/file)] - [:a.bg-base-2.px-1.ml-1.mr-3 {:style {:border-radius 4 - :word-break "break-word"} - :href (rfe/href :file {:path file-path})} - file-path]])] + ;; [:div.content + ;; (when (and file-path + ;; (not sidebar?) + ;; (not block?) + ;; (not (state/hide-file?)) + ;; (not config/publishing?)) + ;; [:div.text-sm.ml-1.mb-4.flex-1.inline-flex + ;; {:key "page-file"} + ;; [:span.opacity-50 {:style {:margin-top 2}} (t :file/file)] + ;; [:a.bg-base-2.px-1.ml-1.mr-3 {:style {:border-radius 4 + ;; :word-break "break-word"} + ;; :href (rfe/href :file {:path file-path})} + ;; file-path]])] (when (and repo (not block?)) (let [alias (db/get-page-alias-names repo page-name)] diff --git a/src/main/frontend/modules/shortcut/binding.cljc b/src/main/frontend/modules/shortcut/binding.cljc index 45697f636..6fea0908a 100644 --- a/src/main/frontend/modules/shortcut/binding.cljc +++ b/src/main/frontend/modules/shortcut/binding.cljc @@ -61,7 +61,7 @@ :ui/toggle-new-block "t e" :ui/show-contents "t c" :ui/toggle-wide-mode "t w" - :ui/toggle-between-page-and-file "s" + ;; :ui/toggle-between-page-and-file "s" :ui/fold "tab" :ui/un-fold "shift+tab" :ui/toggle-brackets "mod+c mod+b" diff --git a/src/main/frontend/modules/shortcut/handler.cljs b/src/main/frontend/modules/shortcut/handler.cljs index 60af2fe4d..2af641719 100644 --- a/src/main/frontend/modules/shortcut/handler.cljs +++ b/src/main/frontend/modules/shortcut/handler.cljs @@ -72,7 +72,7 @@ :ui/toggle-new-block state/toggle-new-block-shortcut! :ui/show-contents ui-handler/toggle-contents! :ui/toggle-wide-mode ui-handler/toggle-wide-mode! - :ui/toggle-between-page-and-file route-handler/toggle-between-page-and-file! + ;; :ui/toggle-between-page-and-file route-handler/toggle-between-page-and-file! :ui/fold (editor-handler/on-tab :right) :ui/un-fold (editor-handler/on-tab :left)