import React from "react"; import { Center, Container, HStack, Text, VStack, IContainerProps, Spinner, Link, View } from "native-base"; import { withTheme } from "../../../theme/hoc/withTheme"; import { openLink } from "@gooddollar/web3sdk-v2"; import { TransButton, TransHeading, TransText, TransTitle } from "../../../core/layout"; import { TxModal } from "../../../core/web3/modals"; import { BasePressable } from "../../../core/buttons"; import { Image } from "../../../core/images"; import BillyWelcome from "../../../assets/images/goodid/billywelcome.png"; import HeartsIcon from "../../../assets/images/goodid/hearts.png"; import InfoIcon from "../../../assets/images/goodid/info.png"; import UbiIcon from "../../../assets/images/goodid/ubi.png"; export interface OnboardScreenProps { isPending: boolean; isWhitelisted?: boolean; expiryDate?: string; onAccept: () => void; innerContainer?: any; fontStyles?: any; } const accessListSimple = [ { label: /*i18n*/ { id: "Crypto UBI", comment: "GoodID feature access list" }, icon: UbiIcon }, { label: /*i18n*/ { id: "Special Offers", comment: "GoodID feature access list" }, icon: HeartsIcon } ]; //todo: define component style configuration /** * OnboardScreen shown to all users who don't have good-id certificate yet * Certificates check should be done before and only show this screen when they don't exist * @param {function} onAccept - callback for alternative in-app navigation for the gooddollar wallet * @param {object} innerContainer - styles for the inner container * @param {object} fontStyles - styles for the text elements */ export const OnboardScreenSimple = withTheme({ name: "OnboardScreen" })( ({ isPending, isWhitelisted, onAccept, innerContainer, fontStyles, ...props }: OnboardScreenProps & IContainerProps) => { const { listLabel, poweredBy } = fontStyles ?? {}; if (isWhitelisted === undefined) return ; const titleCopy = isWhitelisted ? /*i18n*/ "Renew your GoodID to claim UBI" : /*i18n*/ "Get your GoodID to claim UBI"; const actionCopy = isWhitelisted ? /*i18n*/ "I Accept, Renew & Claim" : /*i18n*/ "I Accept, Verify & Claim"; return (
{accessListSimple.map(({ label, icon }, index) => ( ))}
Terms of Use ), privy: ( Privacy Policy ) }} /> openLink("https://gooddollar.org/", "_blank")}>
); } );