Skip to content

Commit 7686e50

Browse files
author
Noah Oleana
committed
add wallet address to clipboard
1 parent de897d5 commit 7686e50

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/kolektivo/components/UserWalletInfoSection.tsx

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,26 @@
11
import React from 'react'
22
import { StyleSheet, Text, View } from 'react-native'
33
import { TouchableOpacity } from 'react-native-gesture-handler'
4+
import { useSelector } from 'react-redux'
45
import KolCurrency from 'src/icons/KolCurrency'
56
import LinearBackground from 'src/kolektivo/components/LinearBackground'
67
import { TokenBalance } from 'src/kolektivo/components/TokenBalance'
78
import Clipboard from 'src/kolektivo/icons/Clipboard'
89
import { typeScale } from 'src/kolektivo/styles/kolektivoFonts'
910
import variables from 'src/kolektivo/styles/variables'
11+
import { currentAccountSelector } from 'src/web3/selectors'
1012

1113
export default function UserWalletInfoSection() {
14+
const account = useSelector(currentAccountSelector)
15+
1216
return (
1317
<View style={styles.container}>
1418
<LinearBackground
1519
borderRadius={10}
1620
backgroundImage={require('src/kolektivo/images/UserWalletDetailsMask.png')}
1721
>
1822
<TouchableOpacity style={styles.addressClipboard}>
19-
<Text style={{ paddingRight: 8 }}>YolandaCW1</Text>
23+
<Text style={{ paddingRight: 8 }}>{account?.slice(0, 9)}...</Text>
2024
<Clipboard />
2125
</TouchableOpacity>
2226
<View style={styles.currency}>

0 commit comments

Comments
 (0)