Skip to content

Commit d358328

Browse files
committed
remove from contacts option
1 parent c8eb740 commit d358328

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/status_im/common/home/actions/view.cljs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,13 +132,23 @@
132132

133133
(defn mark-as-untrusted-action
134134
[{:keys [public-key primary-name] :as item}]
135+
(tap> item)
135136
(hide-sheet-and-dispatch
136137
[:show-bottom-sheet
137138
{:content (fn []
138139
[confirmation-drawer/confirmation-drawer
139140
{:title (i18n/label :t/mark-as-untrusted)
140141
:description (i18n/label :t/mark-as-untrusted-description
141142
{:username (:primary-name item)})
143+
:extra-action (fn []
144+
(rf/dispatch [:toasts/upsert
145+
{:id :remove-contact
146+
:type :positive
147+
:text (->> (i18n/label :t/removed-from-contacts)
148+
(string/lower-case)
149+
(str primary-name " "))}])
150+
(rf/dispatch [:contact.ui/remove-contact-pressed item]))
151+
:extra-text (i18n/label :t/remove-contact)
142152
:context item
143153
:accessibility-label :block-user
144154
:button-text (i18n/label :t/mark-as-untrusted-button)

0 commit comments

Comments
 (0)