zepio/app/views/receive.js

40 lines
871 B
JavaScript
Raw Normal View History

// @flow
import React from 'react';
2019-01-07 10:06:40 -08:00
import styled from 'styled-components';
import { InputLabelComponent } from '../components/input-label';
import { RowComponent } from '../components/row';
import { WalletAddress } from '../components/wallet-address';
2019-01-07 10:06:40 -08:00
type Props = {
addresses: Array<string>,
};
const Wrapper = styled.div`
margin-top: ${props => props.theme.layoutContentPaddingTop};
`;
const Row = styled(RowComponent)`
margin-bottom: 10px;
`;
2019-01-07 10:06:40 -08:00
const Label = styled(InputLabelComponent)`
margin: 0;
margin-bottom: 10px;
`;
2019-01-07 10:06:40 -08:00
export const ReceiveView = ({ addresses }: Props) => (
<Wrapper>
<Label value='Addresses: ' />
2019-01-07 10:06:40 -08:00
{(addresses || []).map(address => (
<Row
key={address}
alignItems='center'
justifyContent='space-between'
>
<WalletAddress address={address} />
</Row>
2019-01-07 10:06:40 -08:00
))}
</Wrapper>
);