Skip to content

Commit

Permalink
update texts
Browse files Browse the repository at this point in the history
  • Loading branch information
tom2drum committed Oct 15, 2024
1 parent db115fe commit 0defa03
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 5 deletions.
5 changes: 4 additions & 1 deletion ui/myProfile/MyProfileWallet.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Box, Button, Heading, useColorModeValue } from '@chakra-ui/react';
import { Box, Button, Heading, Text, useColorModeValue } from '@chakra-ui/react';
import type { UseQueryResult } from '@tanstack/react-query';
import React from 'react';

Expand All @@ -17,6 +17,9 @@ const MyProfileWallet = ({ profileQuery, onAddWallet }: Props) => {
return (
<section>
<Heading as="h2" size="sm" mb={ 3 }>My linked wallet</Heading>
<Text mb={ 3 } >
This wallet address can be used to login and is used for merit program
</Text>
{ profileQuery.data?.address_hash ? (
<Box px={ 3 } py="18px" bgColor={ bgColor } borderRadius="base">
<AddressEntity
Expand Down
5 changes: 5 additions & 0 deletions ui/pages/MyProfile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import type { Screen } from 'ui/snippets/auth/types';
import config from 'configs/app';
import MyProfileEmail from 'ui/myProfile/MyProfileEmail';
import MyProfileWallet from 'ui/myProfile/MyProfileWallet';
import AccountPageDescription from 'ui/shared/AccountPageDescription';
import ContentLoader from 'ui/shared/ContentLoader';
import DataFetchAlert from 'ui/shared/DataFetchAlert';
import PageTitle from 'ui/shared/Page/PageTitle';
Expand Down Expand Up @@ -45,6 +46,10 @@ const MyProfile = () => {

return (
<>
<AccountPageDescription>
You can add your email to receive watchlist notifications.
Additionally, you can manage your wallet address and email, which can be used for logging into your Blockscout account.
</AccountPageDescription>
<Flex maxW="480px" mt={ 8 } flexDir="column" rowGap={ 12 }>
<MyProfileEmail profileQuery={ profileQuery }/>
{ config.features.blockchainInteraction.isEnabled &&
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 6 additions & 1 deletion ui/snippets/user/profile/UserProfileContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,12 @@ const UserProfileContent = ({ data, onClose, onLogin, onAddEmail, onAddAddress }
{ config.features.blockchainInteraction.isEnabled && (
<Flex p={ 2 } borderColor="divider" borderBottomWidth="1px">
<Box>Address</Box>
<Hint label="Address" boxSize={ 4 } ml={ 1 } mr="auto"/>
<Hint
label="This wallet address is linked to your Blockscout account. It can be used to login and is used for merit program participation"
boxSize={ 4 }
ml={ 1 }
mr="auto"
/>
{ data?.address_hash ?
<Box>{ shortenString(data?.address_hash) }</Box> :
<Link onClick={ onAddAddress } color="text_secondary" _hover={{ color: 'link_hovered', textDecoration: 'none' }}>Add address</Link>
Expand Down
14 changes: 11 additions & 3 deletions ui/snippets/user/profile/UserProfileContentWallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,16 +66,24 @@ const UserProfileContentWallet = ({ onClose, className }: Props) => {
loadingText="Connect Wallet"
w="100%"
>
Connect Wallet
Connect
</Button>
);
})();

return (
<Box className={ className }>
<Flex px={ 2 } py={ 1 } mb={ 1 } fontSize="xs" lineHeight={ 4 } fontWeight="500">
<span>Wallet for apps or contracts</span>
<Hint label="Wallet for apps or contracts" boxSize={ 4 } ml={ 1 }/>
<span>Connected wallet</span>
<Hint
label={
web3Wallet.isConnected ?
'This wallet is currently connected to Blockscout and used for interacting with apps and smart contracts' :
'This wallet is used for interacting with apps and smart contracts'
}
boxSize={ 4 }
ml={ 1 }
/>
</Flex>
{ content }
</Box>
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 0defa03

Please sign in to comment.