From 07fecc4e281790e54892b3fa5eedadea3f94a514 Mon Sep 17 00:00:00 2001 From: Julien Eluard Date: Thu, 18 Jan 2018 15:21:47 +0100 Subject: [PATCH] [BUG #3083] Added extra delete options to current menu --- src/status_im/chat/views/actions.cljs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/status_im/chat/views/actions.cljs b/src/status_im/chat/views/actions.cljs index a0b9985a77..8d1406d52a 100644 --- a/src/status_im/chat/views/actions.cljs +++ b/src/status_im/chat/views/actions.cljs @@ -38,6 +38,15 @@ :height 19} :handler #(re-frame/dispatch [:show-profile chat-id])}) +(defn item-delete [chat-id] + {:title (i18n/label :t/delete-chat) + :icon :search_gray_copy + :icon-style {:width 17 + :height 17} + ;; TODO(jeluard) Refactor this or Jan will have an heart attack + :handler #(do (re-frame/dispatch [:remove-chat chat-id]) + (re-frame/dispatch [:navigation-replace :home]))}) + (def item-search {:title (i18n/label :t/search-chat) :subtitle (i18n/label :t/not-implemented) @@ -73,6 +82,7 @@ (defn user-chat-items [chat-id] [(item-user chat-id) + (item-delete chat-id) item-search item-notifications])