Skip to content

Commit 56851b8

Browse files
committed
tweak: hide contact-request button if contact-request is already sent
1 parent 7b35e13 commit 56851b8

File tree

1 file changed

+11
-5
lines changed
  • src/status_im/contexts/profile/contact/header

1 file changed

+11
-5
lines changed

src/status_im/contexts/profile/contact/header/view.cljs

+11-5
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,14 @@
4545
:description :text
4646
:description-text bio
4747
:emoji-dash emoji-hash}]
48-
[rn/view {:style style/button-wrapper}
49-
[quo/button
50-
{:on-press on-contact-request
51-
:icon-left :i/add-user}
52-
(i18n/label :t/send-contact-request)]]]))
48+
49+
(cond
50+
(or (not contact-request-state)
51+
(= contact-request-state constants/contact-request-state-none))
52+
[rn/view {:style style/button-wrapper}
53+
[quo/button
54+
{:on-press on-contact-request
55+
:icon-left :i/add-user}
56+
(i18n/label :t/send-contact-request)]]
57+
58+
:else nil)]))

0 commit comments

Comments
 (0)