diff options
author | frankiebee <frankie.diamond@gmail.com> | 2017-08-05 02:43:08 +0800 |
---|---|---|
committer | frankiebee <frankie.diamond@gmail.com> | 2017-08-05 02:43:08 +0800 |
commit | fa3df576bcf879904b303c4ed1015d27db64642d (patch) | |
tree | cc79aed9e73765338e8ff89b6c4b78a9693ced05 /ui/app | |
parent | cddff73703e9f6611e5ad793d6d05ba91ee96e06 (diff) | |
download | tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar.gz tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar.bz2 tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar.lz tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar.xz tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.tar.zst tangerine-wallet-browser-fa3df576bcf879904b303c4ed1015d27db64642d.zip |
fixed: showing tx-s as errors vs. warning
Diffstat (limited to 'ui/app')
-rw-r--r-- | ui/app/components/transaction-list-item.js | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/ui/app/components/transaction-list-item.js b/ui/app/components/transaction-list-item.js index dbda66a31..01355abad 100644 --- a/ui/app/components/transaction-list-item.js +++ b/ui/app/components/transaction-list-item.js @@ -154,12 +154,21 @@ function failIfFailed (transaction) { if (transaction.status === 'rejected') { return h('span.error', ' (Rejected)') } - if (transaction.err) { + if (transaction.err || transaction.warning) { + const { err, warning = {} } = transaction + const errFirst = !!(( err && warning ) || err) + const message = errFirst ? err.message : warning.message + + errFirst ? err.message : warning.message + + return h(Tooltip, { - title: transaction.err.message, + title: message, position: 'bottom', }, [ - h('span.error', ' (Failed)'), + h(`span.${errFirst ? 'error' : 'warning'}`, + ` (${errFirst ? 'Failed' : 'Warning'})` + ), ]) } } |