@@ -2,7 +2,7 @@ import Maybe from 'folktale/maybe'
22import React from 'react'
33import * as azimuth from 'azimuth-js'
44import { Row, Col, H1, H3, P, InnerLabel, ShowBlockie, Anchor } from '../components/Base'
5−import { AddressInput, Warning } from '../components/Base'
5+import { AddressInput } from '../components/Base'
66import * as ob from 'urbit-ob'
77
88import { PROXY_TYPE, renderProxyType } from '../lib/proxy'
@@ -12,17 +12,7 @@ import { NETWORK_NAMES } from '../lib/network'
1212
1313import StatelessTransaction from '../components/StatelessTransaction'
1414
15−import { ROUTE_NAMES } from '../lib/router'
16−
17−import {
18− sendSignedTransaction,
19− fromWei,
20− } from '../lib/txn'
21−
22−import {
23− isValidAddress,
24− addressFromSecp256k1Public,
25−} from '../lib/wallet'
15+import { isValidAddress } from '../lib/wallet'
2616
2717const SetManagementProxy = (props) =>
2818 <SetProxy
@@ -101,19 +91,12 @@ class SetProxy extends React.Component {
10191 }
10292
10393 render() {
104−
10594 const { props, state } = this
10695
10796 const renderedProxyType = renderProxyType(props.proxyType)
108−
10997 const validAddress = isValidAddress(state.proxyAddress)
110−
11198 const canGenerate = validAddress === true
11299
113− const canSign = Maybe.Just.hasInstance(state.txn)
114− const canApprove = Maybe.Just.hasInstance(state.stx)
115− const canSend = Maybe.Just.hasInstance(state.stx) && state.userApproval === true
116−
117100 const esvisible =
118101 props.networkType === NETWORK_NAMES.ROPSTEN ||
119102 props.networkType === NETWORK_NAMES.MAINNET
@@ -170,46 +153,8 @@ class SetProxy extends React.Component {
170153 walletType={props.walletType}
171154 walletHdPath={props.walletHdPath}
172155 networkType={props.networkType}
173− // Tx
174− txn={state.txn}
175− stx={state.stx}
176− // Tx details
177− nonce={state.nonce}
178− gasPrice={state.gasPrice}
179− chainId={state.chainId}
180− gasLimit={state.gasLimit}
181− showGasDetails={state.showGasDetails}
182− toggleGasDetails={this.toggleGasDetails}
183156 // Checks
184− userApproval={state.userApproval}
185− canGenerate={ canGenerate }
186− canSign={ canSign }
187− canApprove={ canApprove }
188− canSend={ canSend }
189− // Methods
190− createUnsignedTxn={this.handleCreateUnsignedTxn}
191− setUserApproval={this.handleSetUserApproval}
192− setTxn={this.handleSetTxn}
193− setStx={this.handleSetStx}
194− setNonce={this.handleSetNonce}
195− setChainId={this.handleSetChainId}
196− setGasPrice={this.handleSetGasPrice}
197− setGasLimit={this.handleSetGasLimit}
198− handleSubmit={this.handleSubmit} />
199−
200− {
201− Maybe.Nothing.hasInstance(state.txError)
202− ? ''
203− : <Warning className={'mt-8'}>
204− <H3 style={{marginTop: 0, paddingTop: 0}}>
205− {
206− 'There was an error sending your transaction.'
207− }
208− </H3>
209− { state.txError.value }
210− </Warning>
211− }
212−
157+ canGenerate={ canGenerate } />
213158 </Col>
214159 </Row>
215160 )