diff --git a/src/status_im2/contexts/communities/overview/style.cljs b/src/status_im2/contexts/communities/overview/style.cljs index b50237c7a5..ca6f2b8c03 100644 --- a/src/status_im2/contexts/communities/overview/style.cljs +++ b/src/status_im2/contexts/communities/overview/style.cljs @@ -1,6 +1,7 @@ (ns status-im2.contexts.communities.overview.style (:require - [quo.foundations.colors :as colors])) + [quo.foundations.colors :as colors] + [status-im2.contexts.shell.jump-to.constants :as jump-to.constants])) (def screen-horizontal-padding 20) @@ -41,6 +42,16 @@ :right 0 :bottom 0}) +(def floating-shell-button + {:position :absolute + :bottom 21}) + +(defn channel-list-component + [] + {:margin-top 8 + :margin-bottom (+ 21 jump-to.constants/floating-shell-button-height) + :flex 1}) + (defn token-gated-container [] {:border-radius 16 diff --git a/src/status_im2/contexts/communities/overview/view.cljs b/src/status_im2/contexts/communities/overview/view.cljs index 95df0ee1e1..fd99e99c10 100644 --- a/src/status_im2/contexts/communities/overview/view.cljs +++ b/src/status_im2/contexts/communities/overview/view.cljs @@ -82,7 +82,7 @@ {:on-layout #(on-first-channel-height-changed (+ 38 (int (Math/ceil (layout-y %)))) (into #{} (map (comp :name second) channels-list))) - :style {:margin-top 8 :flex 1}} + :style (style/channel-list-component)} (for [[category-id {:keys [chats name collapsed?]}] channels-list] [rn/view {:key category-id @@ -91,12 +91,13 @@ :on-layout #(on-category-layout name (int (layout-y %)))} (when-not (= constants/empty-category-id category-id) [quo/divider-label - {:on-press #(collapse-category community-id category-id collapsed?) - :chevron-icon (if collapsed? :i/chevron-right :i/chevron-down) - :chevron :left} + {:on-press #(collapse-category community-id category-id collapsed?) + :chevron-icon (if collapsed? :i/chevron-right :i/chevron-down) + :container-style {:margin-top 8} + :chevron :left} name]) (when-not collapsed? - [rn/view {:style {:padding-horizontal 8 :padding-bottom 8}} + [rn/view {:style {:padding-horizontal 8}} (for [chat chats] ^{:key (:id chat)} [channel-chat-item community-id community-color chat])])])]) @@ -375,5 +376,4 @@ {:jump-to {:on-press #(rf/dispatch [:shell/navigate-to-jump-to]) :customization-color customization-color :label (i18n/label :t/jump-to)}} - {:position :absolute - :bottom 34}]])) + style/floating-shell-button]]))