From 9d7e8cf4e633ed4b087e7b0f04f6be9c88b44b21 Mon Sep 17 00:00:00 2001 From: Pablo Alba Date: Tue, 9 Apr 2024 19:25:09 +0200 Subject: [PATCH] :bug: fix naming convention of swap --- .../sidebar/options/menus/component.cljs | 20 +++++-------------- .../sidebar/options/menus/component.scss | 9 +-------- 2 files changed, 6 insertions(+), 23 deletions(-) diff --git a/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.cljs b/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.cljs index 570b25faf..8921cc25d 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.cljs +++ b/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.cljs @@ -248,18 +248,13 @@ {::mf/props :obj} [{:keys [item on-enter-group]}] (let [group-name (:name item) - path (cfh/butlast-path-with-dots group-name) on-group-click #(on-enter-group group-name)] [:div {:class (stl/css :component-group) :on-click on-group-click :title group-name} - [:div {:class (stl/css :path-wrapper)} - (when-not (str/blank? path) - [:span {:class (stl/css :component-group-path)} - (str "\u00A0\u2022\u00A0" path)]) - [:span {:class (stl/css :component-group-name)} - (cfh/last-path group-name)]] + [:span {:class (stl/css :component-group-name)} + (cfh/last-path group-name)] [:span {:class (stl/css :arrow-icon)} i/arrow]])) @@ -416,10 +411,7 @@ (mf/use-fn (fn [style] (swap! filters* assoc :listing-thumbs? (= style "grid")))) - - filters-but-last (cfh/butlast-path (:path filters)) - last-filters (cfh/last-path (:path filters)) - filter-path-with-dots (->> filters-but-last (cfh/split-path) (cfh/join-path-with-dot))] + filter-path-with-dots (->> (:path filters) (cfh/split-path) (cfh/join-path-with-dot))] [:div {:class (stl/css :component-swap)} [:div {:class (stl/css :element-set-title)} @@ -462,10 +454,8 @@ :on-click on-go-back :title filter-path-with-dots} [:span {:class (stl/css :back-arrow)} i/arrow] - (when-not (= "" filter-path-with-dots) - [:span {:class (stl/css :path-name)} - (dm/str "\u00A0\u2022\u00A0" filter-path-with-dots)]) - [:span {:class (stl/css :path-name-last)} last-filters]]) + [:span {:class (stl/css :path-name)} + filter-path-with-dots]]) (when (empty? items) [:div {:class (stl/css :component-list-empty)} diff --git a/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.scss b/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.scss index d024187a7..3587d0fbe 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.scss +++ b/frontend/src/app/main/ui/workspace/sidebar/options/menus/component.scss @@ -254,14 +254,7 @@ direction: rtl; height: $s-32; padding: $s-8 0 $s-8 $s-2; -} - -.path-name-last { - @include bodySmallTypography; - @include textEllipsis; - height: $s-32; - padding: $s-8 0 $s-8 $s-2; - color: white; + margin-right: $s-4; } .component-list-empty {