View token-gated requirements is shown for non toked gated communities (i.e. Status) #20237 (#20240)

This commit is contained in:
flexsurfer 2024-05-30 15:05:30 +02:00 committed by GitHub
parent 382c810199
commit 2ebe8fd4c9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 12 additions and 11 deletions

View File

@ -27,7 +27,7 @@
(h/render [options/community-options-bottom-sheet {:id "test"}])
(h/is-truthy (h/get-by-translation-text :t/view-members))
(h/is-truthy (h/get-by-translation-text :t/view-community-rules))
(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
;(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
(h/is-truthy (h/get-by-translation-text :t/mark-as-read))
(h/is-truthy (h/get-by-translation-text :t/mute-community))
;(h/is-truthy (h/get-by-translation-text :t/notification-settings))
@ -79,7 +79,7 @@
:communities/community {:role-permissions? true}})
(h/render [options/community-options-bottom-sheet {:id "test"}])
(h/is-truthy (h/get-by-translation-text :t/invite-people-from-contacts))
(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
;(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
(h/is-truthy (h/get-by-translation-text :t/show-qr))
(h/is-truthy (h/get-by-translation-text :t/share-community))
(h/is-truthy (h/get-by-translation-text :t/cancel-request-to-join)))
@ -100,7 +100,7 @@
:role-permissions? true}})
(h/render [options/community-options-bottom-sheet {:id "test"}])
(h/is-truthy (h/get-by-translation-text :t/invite-people-from-contacts))
(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
;(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
(h/is-truthy (h/get-by-translation-text :t/show-qr))
(h/is-truthy (h/get-by-translation-text :t/share-community)))
@ -110,7 +110,7 @@
:role-permissions? true}})
(h/render [options/community-options-bottom-sheet {:id "test"}])
(h/is-truthy (h/get-by-translation-text :t/invite-people-from-contacts))
(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
;(h/is-truthy (h/get-by-translation-text :t/view-token-gating))
(h/is-truthy (h/get-by-translation-text :t/show-qr))
(h/is-truthy (h/get-by-translation-text :t/share-community)))

View File

@ -36,13 +36,14 @@
(defn view-token-gating
[id]
{:icon :i/token
:right-icon :i/chevron-right
:accessibility-label :view-token-gating
:on-press #(rf/dispatch [:show-bottom-sheet
{:content (fn [] [permissions-sheet/view id])
:padding-bottom-override 16}])
:label (i18n/label :t/view-token-gating)})
(when config/show-not-implemented-features?
{:icon :i/token
:right-icon :i/chevron-right
:accessibility-label :view-token-gating
:on-press #(rf/dispatch [:show-bottom-sheet
{:content (fn [] [permissions-sheet/view id])
:padding-bottom-override 16}])
:label (i18n/label :t/view-token-gating)}))
(defn edit-shared-addresses
[id]