From 11d02c10570ea9908f42f27291d070dac5d1882a Mon Sep 17 00:00:00 2001 From: Parvesh Monu Date: Tue, 13 Dec 2022 14:56:46 +0530 Subject: [PATCH] fix unread badge and add back button accessibility id (#14525) --- src/quo2/components/navigation/page_nav.cljs | 10 ++++++---- src/status_im/chat/models.cljs | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/quo2/components/navigation/page_nav.cljs b/src/quo2/components/navigation/page_nav.cljs index 0097894ff0..8de818f4a4 100644 --- a/src/quo2/components/navigation/page_nav.cljs +++ b/src/quo2/components/navigation/page_nav.cljs @@ -30,10 +30,12 @@ (defn left-section-view [{:keys [on-press icon accessibility-label type] :or {type :grey}} put-middle-section-on-left?] - [rn/view {:style (merge - {:accessibility-label accessibility-label} - (when put-middle-section-on-left? {:margin-right 5}))} - [button/button {:on-press on-press :icon true :type type :size 32} + [rn/view {:style (when put-middle-section-on-left? {:margin-right 5})} + [button/button {:on-press on-press + :icon true + :type type + :size 32 + :accessibility-label accessibility-label} icon]]) (defn- mid-section-comp diff --git a/src/status_im/chat/models.cljs b/src/status_im/chat/models.cljs index bf7ccba309..fd14617f3e 100644 --- a/src/status_im/chat/models.cljs +++ b/src/status_im/chat/models.cljs @@ -214,9 +214,9 @@ (when-let [chat-id (:current-chat-id db)] (chat.state/reset-visible-item) (fx/merge cofx + {:db (dissoc db :current-chat-id)} (delete-for-me/sync-all) (delete-message/send-all) - {:db (dissoc db :current-chat-id)} (offload-messages chat-id)))) (fx/defn force-close-chat