show token symbol

This commit is contained in:
Andrea Franz 2020-03-10 17:28:52 +01:00
parent 0a5365f472
commit 545caca025
No known key found for this signature in database
GPG Key ID: 4F0D2F2D9DE7F29D
3 changed files with 4 additions and 6 deletions

View File

@ -54,7 +54,7 @@ const ReceiveDialog = (props: Props) => {
onClose={props.handleClose}
aria-labelledby="alert-dialog-slide-title"
aria-describedby="alert-dialog-slide-description">
<DialogTitle id="alert-dialog-slide-title">Top up your wallet</DialogTitle>
<DialogTitle id="alert-dialog-slide-title">Send only {props.tokenSymbol} tokens</DialogTitle>
<DialogContent className={classes.container}>
<div>
<img alt={props.address} className={classes.qrcode} ref={image} />

View File

@ -48,15 +48,11 @@ const TopPanel = (props: Props) => {
const classes = useStyles();
const [balance, roundedBalance] = roundEther(props.balance);
const [availableBalance, roundedAvailableBalance] = roundEther(props.availableBalance);
return <div className={classes.container}>
<div>
<Typography variant="h2" color="inherit">
{roundedAvailableBalance} Ξ
</Typography>
<Typography variant="body1" color="inherit" style={{textAlign: "center"}}>
{availableBalance}
{roundedBalance} {props.tokenSymbol}
</Typography>
<div className={classes.actions}>
<Button

View File

@ -6,6 +6,7 @@ import TopPanel from '../components/TopPanel';
import { showWalletQRCode } from '../actions/wallet';
export interface StateProps {
tokenSymbol: string | undefined
balance: string | undefined
availableBalance: string | undefined
}
@ -19,6 +20,7 @@ export type Props = StateProps & DispatchProps;
const mapStateToProps = (state: RootState): StateProps => {
return {
balance: state.wallet.balance,
tokenSymbol: state.wallet.erc20Symbol,
availableBalance: state.wallet.availableBalance,
}
}