Implement Onboarding - New intro screen
This commit is contained in:
parent
3e67a0f163
commit
bc6de0722f
|
@ -15,12 +15,12 @@
|
|||
[utils.re-frame :as rf]))
|
||||
|
||||
(def header-text
|
||||
[{:text (i18n/label :t/join-decentralised-communities)
|
||||
:sub-text (i18n/label :t/participate-in-the-metaverse)}
|
||||
[{:text (i18n/label :t/own-your-crypto)
|
||||
:sub-text (i18n/label :t/use-the-multichain-wallet)}
|
||||
{:text (i18n/label :t/store-your-asets-on-keycard)
|
||||
:sub-text (i18n/label :t/be-safe-with-secure-cold-wallet)}
|
||||
{:text (i18n/label :t/chat-with-friends)
|
||||
:sub-text (i18n/label :t/with-full-encryption)}
|
||||
{:text (i18n/label :t/own-your-crypto)
|
||||
:sub-text (i18n/label :t/use-the-multichain-wallet)}
|
||||
{:text (i18n/label :t/discover-web3)
|
||||
:sub-text (i18n/label :t/explore-the-decentralized-web)}])
|
||||
|
||||
|
|
|
@ -6,17 +6,10 @@
|
|||
{:flex 1
|
||||
:justify-content :flex-end})
|
||||
|
||||
(def text-container
|
||||
{:flex 1
|
||||
:flex-direction :row
|
||||
:flex-wrap :wrap
|
||||
:align-self :flex-start})
|
||||
|
||||
(def terms-privacy-container
|
||||
{:flex-direction :row
|
||||
:padding-horizontal 20
|
||||
{:padding-horizontal 20
|
||||
:padding-vertical 8
|
||||
:gap 8})
|
||||
:align-items :center})
|
||||
|
||||
(def plain-text
|
||||
{:color colors/white-opa-70})
|
||||
|
|
|
@ -20,20 +20,13 @@
|
|||
(rf/dispatch [:show-bottom-sheet {:content privacy/privacy-statement :shell? true}]))
|
||||
|
||||
(defn- terms
|
||||
[terms-accepted? set-terms-accepted?]
|
||||
[]
|
||||
[rn/view {:style style/terms-privacy-container}
|
||||
[rn/view
|
||||
{:accessibility-label :terms-privacy-checkbox-container}
|
||||
[quo/selectors
|
||||
{:type :checkbox
|
||||
:blur? true
|
||||
:checked? terms-accepted?
|
||||
:on-change #(set-terms-accepted? not)}]]
|
||||
[rn/view {:style style/text-container}
|
||||
[quo/text
|
||||
{:style style/plain-text
|
||||
:size :paragraph-2}
|
||||
(str (i18n/label :t/accept-status-tos-prefix) " ")]
|
||||
[quo/text
|
||||
{:style style/plain-text
|
||||
:size :paragraph-2}
|
||||
(str (i18n/label :t/accept-status-tos-prefix))]
|
||||
[rn/view {:style {:flex-direction :row}}
|
||||
[quo/text
|
||||
{:on-press show-terms-of-use
|
||||
:style style/highlighted-text
|
||||
|
@ -69,35 +62,31 @@
|
|||
|
||||
(defn view
|
||||
[]
|
||||
(let [[terms-accepted? set-terms-accepted?] (rn/use-state false)
|
||||
has-profiles-and-unaccepted-terms? (rf/sub [:profile/has-profiles-and-unaccepted-terms?])]
|
||||
(let [has-profiles-and-unaccepted-terms? (rf/sub [:profile/has-profiles-and-unaccepted-terms?])]
|
||||
[rn/view {:style style/page-container}
|
||||
[background/view false]
|
||||
[quo/bottom-actions
|
||||
(cond->
|
||||
{:container-style (style/bottom-actions-container (safe-area/get-bottom))
|
||||
:actions :two-vertical-actions
|
||||
:description :top
|
||||
:description-top-text [terms terms-accepted? set-terms-accepted?]}
|
||||
{:container-style (style/bottom-actions-container (safe-area/get-bottom))
|
||||
:actions :two-vertical-actions
|
||||
:description :bottom
|
||||
:description-text [terms]}
|
||||
|
||||
has-profiles-and-unaccepted-terms?
|
||||
(assoc
|
||||
:actions :one-action
|
||||
:button-one-label (i18n/label :t/explore-the-new-status)
|
||||
:button-one-props {:disabled? (not terms-accepted?)
|
||||
:accessibility-label :explore-new-status
|
||||
:button-one-props {:accessibility-label :explore-new-status
|
||||
:on-press explore-new-status})
|
||||
|
||||
(not has-profiles-and-unaccepted-terms?)
|
||||
(assoc
|
||||
:actions :two-vertical-actions
|
||||
:button-one-label (i18n/label :t/sync-or-recover-profile)
|
||||
:button-one-label (i18n/label :t/log-in)
|
||||
:button-one-props {:type :dark-grey
|
||||
:disabled? (not terms-accepted?)
|
||||
:accessibility-label :already-use-status-button
|
||||
:accessibility-label :log-in
|
||||
:on-press sync-or-recover-profile}
|
||||
:button-two-label (i18n/label :t/create-profile)
|
||||
:button-two-props {:accessibility-label :new-to-status-button
|
||||
:disabled? (not terms-accepted?)
|
||||
:on-press create-profile}))]
|
||||
[overlay/view]]))
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
"accept-and-share-address": "Accept and share address",
|
||||
"accept-community-rules": "I agree with the community rules",
|
||||
"accept-new-chats-from": "Accept new chats from",
|
||||
"accept-status-tos-prefix": "I accept Status",
|
||||
"accept-status-tos-prefix": "By proceeding you accept Status ",
|
||||
"accepted": "Accepted",
|
||||
"access-existing-keys": "Access existing keys",
|
||||
"access-key": "Access key",
|
||||
|
@ -189,6 +189,7 @@
|
|||
"backup-through-waku": "Backup through waku",
|
||||
"bad-fees-description": "Your priority fee is below our suggested parameters.",
|
||||
"balance": "Balance",
|
||||
"be-safe-with-secure-cold-wallet": "Be safe with secure cold wallet",
|
||||
"begin-set-up": "Begin setup",
|
||||
"below-base-fee": "max fee below base fee",
|
||||
"beta": "Beta",
|
||||
|
@ -1295,7 +1296,6 @@
|
|||
"join-a-community": "or join a community",
|
||||
"join-as": "Join as {{role}}",
|
||||
"join-community-to-post": "Join community to post",
|
||||
"join-decentralised-communities": "Join Decentralized Communities",
|
||||
"join-group-chat": "Join group",
|
||||
"join-group-chat-description": "{{username}} invited you to join the group {{group-name}}",
|
||||
"join-me": "Hey join me on Status: {{url}}",
|
||||
|
@ -1893,7 +1893,6 @@
|
|||
"pairing-please-set-a-name": "Please set a name for your device.",
|
||||
"pairing-slots-occupied": "All pairing slots are occupied",
|
||||
"paraswap-error": "Paraswap error: {{paraswap-error}}",
|
||||
"participate-in-the-metaverse": "Participate in the truly free metaverse",
|
||||
"passphrase": "Passphrase",
|
||||
"password": "Password",
|
||||
"password-creation-confirm": "Confirm password",
|
||||
|
@ -2438,6 +2437,7 @@
|
|||
"sticker-market": "Sticker market",
|
||||
"storage": "Storage",
|
||||
"store-confirmations": "Store confirmations",
|
||||
"store-your-asets-on-keycard": "Store your assets on Keycard",
|
||||
"strength-divider-okay-label": "Okay",
|
||||
"strength-divider-strong-label": "Strong",
|
||||
"strength-divider-very-strong-label": "Very strong",
|
||||
|
|
Loading…
Reference in New Issue