Feature: Ignore / Dismiss contact requests from contact profile (#19166)

* chore: add english translation for "contact request ignored"

* feature: integrate action to ignore contact request and display toast

* wip: default to showing "send contact request" after ignoring contact request
This commit is contained in:
Sean Hagstrom 2024-03-12 13:48:21 +00:00 committed by GitHub
parent d4c8e48441
commit 0efdea6962
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 14 additions and 3 deletions

View File

@ -28,8 +28,17 @@
:text (i18n/label
:t/contact-request-was-accepted)}]))
[contact-request-id])
on-contact-ignore (rn/use-callback (fn []
(rf/dispatch [:hide-bottom-sheet])))]
on-contact-ignore (rn/use-callback
(fn []
(rf/dispatch [:hide-bottom-sheet])
(rf/dispatch [:activity-center.contact-requests/decline
contact-request-id])
(rf/dispatch [:toasts/upsert
{:id :ignore-contact-request
:type :positive
:text (i18n/label
:t/contact-request-was-ignored)}]))
[contact-request-id])]
[:<>
[quo/drawer-top
{:type :context-tag

View File

@ -55,7 +55,8 @@
(cond
(or (not contact-request-state)
(= contact-request-state constants/contact-request-state-none))
(= contact-request-state constants/contact-request-state-none)
(= contact-request-state constants/contact-request-state-dismissed))
[quo/button
{:container-style style/button-wrapper
:on-press on-contact-request

View File

@ -1979,6 +1979,7 @@
"contact-request-was-sent": "Contact request sent",
"contact-request-sent-to": "Contact request sent to",
"contact-request-was-accepted": "Contact request accepted",
"contact-request-was-ignored": "Contact request ignored",
"contact-request-is-now-a-contact": "is now a contact",
"contact-request-removed-you-as-contact": "removed you as a contact",
"contact-request-removed-as-contact": "removed as a contact",