diff options
author | Frankie <frankie.pangilinan@consensys.net> | 2016-08-13 08:43:24 +0800 |
---|---|---|
committer | Frankie <frankie.pangilinan@consensys.net> | 2016-08-13 08:43:24 +0800 |
commit | 99a788a6f02ffcd53e88222ab0ba4b89d8040f4f (patch) | |
tree | 097fb582484f3c65cb152513167f1b6dbabb8bc6 /ui/app/components | |
parent | b72c00a6c15af9692cbaf46b89a19e5cef45f7b7 (diff) | |
download | tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar.gz tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar.bz2 tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar.lz tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar.xz tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.tar.zst tangerine-wallet-browser-99a788a6f02ffcd53e88222ab0ba4b89d8040f4f.zip |
Add multi message capability to Qr view for market info
Diffstat (limited to 'ui/app/components')
-rw-r--r-- | ui/app/components/qr-code.js | 8 | ||||
-rw-r--r-- | ui/app/components/shapeshift-form.js | 8 |
2 files changed, 13 insertions, 3 deletions
diff --git a/ui/app/components/qr-code.js b/ui/app/components/qr-code.js index 765322239..1c744b234 100644 --- a/ui/app/components/qr-code.js +++ b/ui/app/components/qr-code.js @@ -29,7 +29,7 @@ QrCodeView.prototype.render = function () { alignItems: 'center', }, }, [ - h('h3', Qr.message), + Array.isArray(Qr.message) ? h('.message-container', this.renderMultiMessage()) : h('h3', Qr.message), h('#qr-container.flex-column', { key: 'qr', style: { @@ -48,3 +48,9 @@ QrCodeView.prototype.render = function () { ]), ]) } + +QrCodeView.prototype.renderMultiMessage = function () { + var Qr = this.props.Qr + var multiMessage = Qr.message.map((message) => h('.qr-message', message)) + return multiMessage +} diff --git a/ui/app/components/shapeshift-form.js b/ui/app/components/shapeshift-form.js index 52bacf798..48d220693 100644 --- a/ui/app/components/shapeshift-form.js +++ b/ui/app/components/shapeshift-form.js @@ -194,6 +194,7 @@ ShapeshiftForm.prototype.renderMain = function () { } ShapeshiftForm.prototype.shift = function () { + var props = this.props var withdrawal = this.props.buyView.buyAddress var returnAddress = document.getElementById('fromCoinAddress').value var pair = this.props.buyView.formView.marketinfo.pair @@ -202,9 +203,12 @@ ShapeshiftForm.prototype.shift = function () { 'pair': pair, 'returnAddress': returnAddress, } - + var message = [ + `Deposit Limit: ${props.buyView.formView.marketinfo.limit}`, + `Deposit Minimum:${props.buyView.formView.marketinfo.minimum}`, + ] if (isValidAddress(withdrawal)) { - this.props.dispatch(actions.coinShiftRquest(data)) + this.props.dispatch(actions.coinShiftRquest(data, message)) } } |