aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/conf-tx.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/app/conf-tx.js')
-rw-r--r--ui/app/conf-tx.js23
1 files changed, 9 insertions, 14 deletions
diff --git a/ui/app/conf-tx.js b/ui/app/conf-tx.js
index 9092c85c9..5c80939b9 100644
--- a/ui/app/conf-tx.js
+++ b/ui/app/conf-tx.js
@@ -3,10 +3,7 @@ const Component = require('react').Component
const ReactCSSTransitionGroup = require('react-addons-css-transition-group')
const h = require('react-hyperscript')
const connect = require('react-redux').connect
-const copyToClipboard = require('copy-to-clipboard')
const actions = require('./actions')
-const AccountPanel = require('./components/account-panel')
-const valuesFor = require('./util').valuesFor
const txHelper = require('../lib/tx-helper')
const ConfirmTx = require('./components/pending-tx')
@@ -14,7 +11,7 @@ const PendingMsg = require('./components/pending-msg')
module.exports = connect(mapStateToProps)(ConfirmTxScreen)
-function mapStateToProps(state) {
+function mapStateToProps (state) {
return {
identities: state.metamask.identities,
accounts: state.metamask.accounts,
@@ -27,12 +24,11 @@ function mapStateToProps(state) {
}
inherits(ConfirmTxScreen, Component)
-function ConfirmTxScreen() {
+function ConfirmTxScreen () {
Component.call(this)
}
-
-ConfirmTxScreen.prototype.render = function() {
+ConfirmTxScreen.prototype.render = function () {
var state = this.props
var unconfTxs = state.unconfTxs
@@ -103,7 +99,6 @@ ConfirmTxScreen.prototype.render = function() {
}
function currentTxView (opts) {
-
if ('txParams' in opts.txData) {
// This is a pending transaction
return h(ConfirmTx, opts)
@@ -113,34 +108,34 @@ function currentTxView (opts) {
}
}
-ConfirmTxScreen.prototype.sendTransaction = function(txData, event){
+ConfirmTxScreen.prototype.sendTransaction = function (txData, event) {
event.stopPropagation()
this.props.dispatch(actions.sendTx(txData))
}
-ConfirmTxScreen.prototype.cancelTransaction = function(txData, event){
+ConfirmTxScreen.prototype.cancelTransaction = function (txData, event) {
event.stopPropagation()
this.props.dispatch(actions.cancelTx(txData))
}
-ConfirmTxScreen.prototype.signMessage = function(msgData, event){
+ConfirmTxScreen.prototype.signMessage = function (msgData, event) {
var params = msgData.msgParams
params.metamaskId = msgData.id
event.stopPropagation()
this.props.dispatch(actions.signMsg(params))
}
-ConfirmTxScreen.prototype.cancelMessage = function(msgData, event){
+ConfirmTxScreen.prototype.cancelMessage = function (msgData, event) {
event.stopPropagation()
this.props.dispatch(actions.cancelMsg(msgData))
}
-ConfirmTxScreen.prototype.goHome = function(event){
+ConfirmTxScreen.prototype.goHome = function (event) {
event.stopPropagation()
this.props.dispatch(actions.goHome())
}
-function warningIfExists(warning) {
+function warningIfExists (warning) {
if (warning) {
return h('span.error', { style: { margin: 'auto' } }, warning)
}