From e65d606417b324c44c62205f581d33bcf9199cf4 Mon Sep 17 00:00:00 2001 From: Tienson Qin Date: Thu, 13 Mar 2025 09:52:32 +0800 Subject: [PATCH] enhance: hide action bar after pressing arrows --- src/main/frontend/components/views.cljs | 6 ++---- src/main/frontend/handler/editor.cljs | 2 ++ 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/frontend/components/views.cljs b/src/main/frontend/components/views.cljs index 52ec993f78..fed064a682 100644 --- a/src/main/frontend/components/views.cljs +++ b/src/main/frontend/components/views.cljs @@ -1625,10 +1625,8 @@ (set-loading! false)))))) []) (if loading? - [:div.flex.flex-col.space-2.gap-2 - (shui/skeleton {:class "h-6 w-full"}) - [:div.flex.flex-col.space-2.gap-2 - (repeat 25 (shui/skeleton {:class "h-6 w-full"}))]] + [:div.flex.flex-col.space-2.gap-2.my-2 + (repeat 25 (shui/skeleton {:class "h-6 w-full"}))] (view-container view-entity (assoc option :items-count items-count :views views diff --git a/src/main/frontend/handler/editor.cljs b/src/main/frontend/handler/editor.cljs index 73dbc1785f..478b459827 100644 --- a/src/main/frontend/handler/editor.cljs +++ b/src/main/frontend/handler/editor.cljs @@ -1827,6 +1827,7 @@ [up?] (fn [event] (util/stop event) + (state/pub-event! [:editor/hide-action-bar]) (let [edit-block-id (:block/uuid (state/get-edit-block)) move-nodes (fn [blocks] (let [blocks' (block-handler/get-top-level-blocks blocks) @@ -2972,6 +2973,7 @@ (state/selection?) (do (util/stop e) + (state/pub-event! [:editor/hide-action-bar]) (on-tab direction))) nil))