-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #292 from LiskHQ/137-send-to-address
Add "send to this address" - Closes #137
- Loading branch information
Showing
17 changed files
with
354 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,10 @@ | |
|
||
.wrapper { | ||
min-width: 100%; | ||
|
||
& .sendTo { | ||
width: 100%; | ||
} | ||
} | ||
|
||
@media (--xLarge-viewport) { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
import React from 'react'; | ||
import { Link } from 'react-router-dom'; | ||
import grid from 'flexboxgrid/dist/flexboxgrid.css'; | ||
import { TertiaryButton } from './../toolbox/buttons/button'; | ||
import { FontIcon } from '../fontIcon'; | ||
import Box from '../box'; | ||
import LiskAmount from '../liskAmount'; | ||
import AccountVisual from '../accountVisual'; | ||
import CopyToClipboard from '../copyToClipboard'; | ||
import routes from './../../constants/routes'; | ||
import styles from './sendTo.css'; | ||
|
||
class SendTo extends React.Component { | ||
shouldComponentUpdate(nextProps) { | ||
return nextProps.address !== this.props.address; | ||
} | ||
|
||
render() { | ||
return (<Box className={`${styles.wrapper} ${grid.row}`}> | ||
<section className={styles.content}> | ||
<div className={` | ||
${grid['col-xs-12']} | ||
${grid['col-sm-6']} | ||
${grid['col-md-12']} | ||
${grid['col-lg-12']} | ||
${grid['middle-sm']} | ||
${grid.row} | ||
`}> | ||
<AccountVisual | ||
address={this.props.address} | ||
className={` | ||
${grid['col-xs-4']} | ||
${grid['col-sm-4']} | ||
${grid['col-md-12']} | ||
${grid['col-lg-12']} | ||
${grid['middle-sm']} | ||
`} | ||
size={144} mobileSize={90}/> | ||
<div className={`${styles.account} | ||
${grid['col-xs-8']} | ||
${grid['col-sm-8']} | ||
${grid['col-md-12']} | ||
${grid['col-lg-12']} | ||
`}> | ||
<h2> | ||
<span> | ||
<LiskAmount val={this.props.balance}/> | ||
</span> <small className={styles.balanceUnit}>LSK</small> | ||
</h2> | ||
<CopyToClipboard value={this.props.address} className={`${styles.address}`} copyClassName={styles.copy} /> | ||
</div> | ||
</div> | ||
<div className={` | ||
${grid['col-xs-12']} | ||
${grid['col-sm-6']} | ||
${grid['col-md-12']} | ||
${grid['col-lg-12']} | ||
${grid['middle-sm']} | ||
${styles.sendButton} | ||
`}> | ||
<Link to={`${routes.wallet.long}?address=${this.props.address}`}> | ||
<TertiaryButton className={styles.button} > | ||
<FontIcon value={'send-token'}/> {this.props.t('Send to this address')} | ||
</TertiaryButton> | ||
</Link> | ||
</div> | ||
</section> | ||
</Box> | ||
); | ||
} | ||
} | ||
|
||
export default SendTo; |
Oops, something went wrong.