fix(communities): token-gated community info text (#21338)
This commit is contained in:
parent
63d0aaca2a
commit
ca3720be0a
|
@ -119,38 +119,29 @@
|
||||||
:icon-left :i/communities}
|
:icon-left :i/communities}
|
||||||
(i18n/label :t/request-to-join)])
|
(i18n/label :t/request-to-join)])
|
||||||
|
|
||||||
(defn- info-button-handler
|
(defn token-gated-communities-info
|
||||||
[]
|
[]
|
||||||
(rf/dispatch
|
[quo/documentation-drawers {:title (i18n/label :t/token-gated-communities)}
|
||||||
[:show-bottom-sheet
|
|
||||||
{:content
|
|
||||||
(fn []
|
|
||||||
[quo/documentation-drawers
|
|
||||||
{:title (i18n/label :t/token-gated-communities)
|
|
||||||
:show-button? true
|
|
||||||
:button-label (i18n/label :t/read-more)
|
|
||||||
:button-icon :info}
|
|
||||||
[quo/text {:size :paragraph-2}
|
[quo/text {:size :paragraph-2}
|
||||||
(i18n/label :t/token-gated-communities-info)]])}]))
|
(i18n/label :t/token-gated-communities-info)]])
|
||||||
|
|
||||||
(defn- token-requirements
|
(defn- token-requirements
|
||||||
[{:keys [id color role-permissions?]}]
|
[{:keys [id color role-permissions?]}]
|
||||||
(let [{:keys [can-request-access?
|
(let [{:keys [can-request-access? no-member-permission? networks-not-supported?
|
||||||
no-member-permission?
|
highest-permission-role
|
||||||
tokens
|
tokens]} (rf/sub [:community/token-gated-overview id])
|
||||||
networks-not-supported?
|
highest-role-text (i18n/label
|
||||||
highest-permission-role]} (rf/sub [:community/token-gated-overview id])
|
|
||||||
highest-role-text
|
|
||||||
(i18n/label
|
|
||||||
(communities.utils/role->translation-key highest-permission-role :t/member))
|
(communities.utils/role->translation-key highest-permission-role :t/member))
|
||||||
on-press (rn/use-callback (fn []
|
on-press (rn/use-callback
|
||||||
|
(fn []
|
||||||
(if config/community-accounts-selection-enabled?
|
(if config/community-accounts-selection-enabled?
|
||||||
(rf/dispatch [:open-modal :community-account-selection-sheet
|
(rf/dispatch [:open-modal :community-account-selection-sheet
|
||||||
{:community-id id}])
|
{:community-id id}])
|
||||||
(rf/dispatch [:open-modal :community-requests-to-join
|
(rf/dispatch [:open-modal :community-requests-to-join
|
||||||
{:id
|
{:id id}])))
|
||||||
id}])))
|
[id])
|
||||||
[id])]
|
on-press-info #(rf/dispatch
|
||||||
|
[:show-bottom-sheet {:content token-gated-communities-info}])]
|
||||||
(cond
|
(cond
|
||||||
networks-not-supported?
|
networks-not-supported?
|
||||||
[network-not-supported]
|
[network-not-supported]
|
||||||
|
@ -165,8 +156,7 @@
|
||||||
:community-color color
|
:community-color color
|
||||||
:satisfied? can-request-access?
|
:satisfied? can-request-access?
|
||||||
:on-press on-press
|
:on-press on-press
|
||||||
:on-press-info
|
:on-press-info on-press-info}])))
|
||||||
info-button-handler}])))
|
|
||||||
|
|
||||||
(defn- join-community
|
(defn- join-community
|
||||||
[{:keys [id joined permissions] :as community}]
|
[{:keys [id joined permissions] :as community}]
|
||||||
|
|
|
@ -2486,8 +2486,8 @@
|
||||||
"token-auto-validate-name-error": "Wrong name for token {{symbol}} at address {{address}} - set to {{expected}} but detected as {{actual}}",
|
"token-auto-validate-name-error": "Wrong name for token {{symbol}} at address {{address}} - set to {{expected}} but detected as {{actual}}",
|
||||||
"token-auto-validate-symbol-error": "Wrong symbol for token {{symbol}} at address {{address}} - set to {{expected}} but detected as {{actual}}",
|
"token-auto-validate-symbol-error": "Wrong symbol for token {{symbol}} at address {{address}} - set to {{expected}} but detected as {{actual}}",
|
||||||
"token-details": "Token details",
|
"token-details": "Token details",
|
||||||
"token-gated-communities": "Token gated communities",
|
"token-gated-communities": "Token-gated communities",
|
||||||
"token-gated-communities-info": "Here will be something relevant about this topic. This will help the user get more context and therefore have a better understanding of it.",
|
"token-gated-communities-info": "If you want to join a token-gated community, you need to meet the token requirements set by the community Owner.\n\nThe Status app automatically checks if you meet the community requirements. If you meet the requirements, the option to join the community is available.",
|
||||||
"token-master": "Token Master",
|
"token-master": "Token Master",
|
||||||
"token-not-available-on-networks": "{{token-symbol}} is not available on {{networks}}.",
|
"token-not-available-on-networks": "{{token-symbol}} is not available on {{networks}}.",
|
||||||
"token-not-available-on-receiver-networks": "{{token-symbol}} is not available on the recipient’s desired networks. Proceed with caution.",
|
"token-not-available-on-receiver-networks": "{{token-symbol}} is not available on the recipient’s desired networks. Proceed with caution.",
|
||||||
|
|
Loading…
Reference in New Issue