diff --git a/src/quo2/components/list_items/channel.cljs b/src/quo2/components/list_items/channel.cljs index 82982f0b0a..570b586321 100644 --- a/src/quo2/components/list_items/channel.cljs +++ b/src/quo2/components/list_items/channel.cljs @@ -10,48 +10,48 @@ (defn list-item [{:keys [name locked? mentions-count unread-messages? muted? is-active-channel? emoji channel-color on-press] :or {channel-color colors/primary-50}}] - [rn/view {:style (merge {:height 48 - :display :flex - :border-radius 12 - :flex-direction :row - :justify-content :space-between - :align-items :center - :width "100%" - :padding-left 12 - :padding-right 12} - (when is-active-channel? - {:background-color (colors/theme-alpha channel-color 0.05 0.05)})) - :on-press on-press} - [rn/view {:display :flex - :flex-direction :row - :justify-content :flex-start - :align-items :center} - [channel-avatar/channel-avatar - {:big? true - :locked? locked? - :emoji-background-color (colors/theme-alpha channel-color 0.1 0.1) - :emoji emoji}] - [quo2.text/text - {:style (merge {:margin-left 12} - (when (and (not locked?) muted?) - {:color (if (theme/dark?) colors/neutral-60 colors/neutral-40)})) - :weight :medium :size :paragraph-1} (str "# " name)]] - [rn/view {:style {:height 20}} - (when (and (not locked?) - muted?) - [quo2.icons/icon :i/muted - {:size 20 - :no-color true}]) - (when (and (not locked?) - (not muted?) - (pos? (int mentions-count))) - [rn/view {:style {:margin-right 2 - :margin-top 2}} - [quo2.counter/counter {:override-bg-color channel-color} mentions-count]]) - (when (and (not locked?) - (not muted?) - (not (pos? (int mentions-count))) - unread-messages?) - [quo2.icons/icon :i/channel-notification - {:size 20 - :no-color true}])]]) + [rn/touchable-opacity {:on-press on-press} + [rn/view {:style (merge {:height 48 + :display :flex + :border-radius 12 + :flex-direction :row + :justify-content :space-between + :align-items :center + :width "100%" + :padding-left 12 + :padding-right 12} + (when is-active-channel? + {:background-color (colors/theme-alpha channel-color 0.05 0.05)}))} + [rn/view {:display :flex + :flex-direction :row + :justify-content :flex-start + :align-items :center} + [channel-avatar/channel-avatar + {:big? true + :locked? locked? + :emoji-background-color (colors/theme-alpha channel-color 0.1 0.1) + :emoji emoji}] + [quo2.text/text + {:style (merge {:margin-left 12} + (when (and (not locked?) muted?) + {:color (if (theme/dark?) colors/neutral-60 colors/neutral-40)})) + :weight :medium :size :paragraph-1} (str "# " name)]] + [rn/view {:style {:height 20}} + (when (and (not locked?) + muted?) + [quo2.icons/icon :i/muted + {:size 20 + :no-color true}]) + (when (and (not locked?) + (not muted?) + (pos? (int mentions-count))) + [rn/view {:style {:margin-right 2 + :margin-top 2}} + [quo2.counter/counter {:override-bg-color channel-color} mentions-count]]) + (when (and (not locked?) + (not muted?) + (not (pos? (int mentions-count))) + unread-messages?) + [quo2.icons/icon :i/channel-notification + {:size 20 + :no-color true}])]]])