Skip to content

Commit

Permalink
misc
Browse files Browse the repository at this point in the history
  • Loading branch information
monokh committed Sep 7, 2020
1 parent ad60338 commit cbfed43
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/views/Send.vue
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
</div>
<div class="button-group">
<button class="btn btn-light btn-outline-primary btn-lg" @click="$router.go(-1)">Cancel</button>
<button class="btn btn-primary btn-lg" @click="send" :disabled="!canSend">Continue</button>
<button class="btn btn-primary btn-lg" @click="send" :disabled="!canSend">Review Terms</button>
</div>
</div>
</div>
Expand Down Expand Up @@ -77,13 +77,13 @@ export default {
return cryptoassets[this.asset.toLowerCase()].isValidAddress(this.sendAddress)
},
addressError () {
if (!this.isValidAddress) return 'Address invalid.'
if (!this.isValidAddress) return 'Wrong format. Please check the address.'
return null
},
amountError () {
const sendAmount = BN(this.sendAmount)
if (sendAmount.gt(this.balance)) return 'Amount exceeds available balance.'
if (this.asset === 'ETH' && sendAmount.eq(this.balance)) return 'Can\'t send full balance. Subtract enough for fee.'
if (this.asset === 'ETH' && sendAmount.eq(this.balance)) return 'To account for the fee, lower this amount.'
return null
},
canSend () {
Expand Down
2 changes: 1 addition & 1 deletion src/views/Swap.vue
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export default {
const amount = BN(this.safeAmount)
if (amount.gt(this.balance)) return 'Amount exceeds available balance.'
if (this.asset === 'ETH' && amount.eq(this.balance)) return 'Can\'t swap full balance. Subtract enough for fee.'
if (this.asset === 'ETH' && amount.eq(this.balance)) return 'To account for the fee, lower this amount.'
if (amount.gt(this.max)) return 'Please reduce amount. It exceeds maximum.'
if (amount.lt(this.min)) return 'Please increase amount. It is below minimum.'
Expand Down

0 comments on commit cbfed43

Please sign in to comment.