aboutsummaryrefslogtreecommitdiffstats
path: root/old-ui
diff options
context:
space:
mode:
authornyatla <nyatla39@gmail.com>2018-04-10 16:14:28 +0800
committernyatla <nyatla39@gmail.com>2018-04-10 16:14:28 +0800
commitcc246528b509b80e560715f3b315acf0764e99e7 (patch)
treea04cc12e6c11345bf751726f15fa9d3dd6be4733 /old-ui
parentbc0487006c623f1c81c186ba5b2a7137efb940ec (diff)
parentb91bd818c7c2aec2952036a2f69ab05e0690a06e (diff)
downloadtangerine-wallet-browser-cc246528b509b80e560715f3b315acf0764e99e7.tar.gz
tangerine-wallet-browser-cc246528b509b80e560715f3b315acf0764e99e7.tar.zst
tangerine-wallet-browser-cc246528b509b80e560715f3b315acf0764e99e7.zip
Merge tag 'v4.5.5'
# Conflicts: # app/_locales/ja/messages.json # package-lock.json messages.jsonのローカライズ
Diffstat (limited to 'old-ui')
-rw-r--r--old-ui/app/app.js3
-rw-r--r--old-ui/app/components/buy-button-subview.js1
-rw-r--r--old-ui/app/components/pending-tx.js6
-rw-r--r--old-ui/app/components/qr-code.js1
-rw-r--r--old-ui/app/components/range-slider.js4
-rw-r--r--old-ui/app/components/transaction-list-item.js7
-rw-r--r--old-ui/app/config.js7
-rw-r--r--old-ui/app/util.js1
-rw-r--r--old-ui/css.js4
9 files changed, 16 insertions, 18 deletions
diff --git a/old-ui/app/app.js b/old-ui/app/app.js
index c79ac633a..37611987f 100644
--- a/old-ui/app/app.js
+++ b/old-ui/app/app.js
@@ -171,7 +171,7 @@ App.prototype.renderAppBar = function () {
h('img', {
height: 24,
width: 24,
- src: '/images/icon-128.png',
+ src: './images/icon-128.png',
}),
h(NetworkIndicator, {
@@ -581,7 +581,6 @@ App.prototype.renderPrimary = function () {
case 'qr':
log.debug('rendering show qr screen')
- console.log(`QrView`, QrView);
return h('div', {
style: {
position: 'absolute',
diff --git a/old-ui/app/components/buy-button-subview.js b/old-ui/app/components/buy-button-subview.js
index 843627c33..56d173839 100644
--- a/old-ui/app/components/buy-button-subview.js
+++ b/old-ui/app/components/buy-button-subview.js
@@ -247,7 +247,6 @@ BuyButtonSubview.prototype.backButtonContext = function () {
if (this.props.context === 'confTx') {
this.props.dispatch(actions.showConfTxPage(false))
} else {
- console.log(`actions.goHome`, actions.goHome);
this.props.dispatch(actions.goHome())
}
}
diff --git a/old-ui/app/components/pending-tx.js b/old-ui/app/components/pending-tx.js
index 720df2243..7f63d9fdf 100644
--- a/old-ui/app/components/pending-tx.js
+++ b/old-ui/app/components/pending-tx.js
@@ -62,8 +62,8 @@ PendingTx.prototype.render = function () {
const gasBn = hexToBn(gas)
// default to 8MM gas limit
const gasLimit = new BN(parseInt(blockGasLimit) || '8000000')
- const safeGasLimitBN = this.bnMultiplyByFraction(gasLimit, 19, 20)
- const saferGasLimitBN = this.bnMultiplyByFraction(gasLimit, 18, 20)
+ const safeGasLimitBN = this.bnMultiplyByFraction(gasLimit, 99, 100)
+ const saferGasLimitBN = this.bnMultiplyByFraction(gasLimit, 98, 100)
const safeGasLimit = safeGasLimitBN.toString(10)
// Gas Price
@@ -311,7 +311,7 @@ PendingTx.prototype.render = function () {
style: {
fontSize: '0.9em',
},
- }, 'Gas limit set dangerously high. Approving this transaction is likely to fail.')
+ }, 'Gas limit set dangerously high. Approving this transaction is liable to fail.')
: null,
]),
diff --git a/old-ui/app/components/qr-code.js b/old-ui/app/components/qr-code.js
index fa38dcd92..06b9aed9b 100644
--- a/old-ui/app/components/qr-code.js
+++ b/old-ui/app/components/qr-code.js
@@ -25,7 +25,6 @@ function QrCodeView () {
QrCodeView.prototype.render = function () {
const props = this.props
const Qr = props.Qr
- console.log(`QrCodeView Qr`, Qr);
const address = `${isHexPrefixed(Qr.data) ? 'ethereum:' : ''}${Qr.data}`
const qrImage = qrCode(4, 'M')
qrImage.addData(address)
diff --git a/old-ui/app/components/range-slider.js b/old-ui/app/components/range-slider.js
index 823f5eb01..bae740a74 100644
--- a/old-ui/app/components/range-slider.js
+++ b/old-ui/app/components/range-slider.js
@@ -35,7 +35,7 @@ RangeSlider.prototype.render = function () {
step: increment,
style: range,
value: state.value || defaultValue,
- onChange: mirrorInput ? this.mirrorInputs.bind(this, event) : onInput,
+ onChange: mirrorInput ? this.mirrorInputs.bind(this) : onInput,
}),
// Mirrored input for range
@@ -47,7 +47,7 @@ RangeSlider.prototype.render = function () {
value: state.value || defaultValue,
step: increment,
style: input,
- onChange: this.mirrorInputs.bind(this, event),
+ onChange: this.mirrorInputs.bind(this),
}) : null,
])
)
diff --git a/old-ui/app/components/transaction-list-item.js b/old-ui/app/components/transaction-list-item.js
index 7ab3414e5..b9f82c668 100644
--- a/old-ui/app/components/transaction-list-item.js
+++ b/old-ui/app/components/transaction-list-item.js
@@ -30,7 +30,12 @@ function TransactionListItem () {
TransactionListItem.prototype.showRetryButton = function () {
const { transaction = {}, transactions } = this.props
- const { status, submittedTime, txParams } = transaction
+ const { submittedTime, txParams } = transaction
+
+ if (!txParams) {
+ return false
+ }
+
const currentNonce = txParams.nonce
const currentNonceTxs = transactions.filter(tx => tx.txParams.nonce === currentNonce)
const currentNonceSubmittedTxs = currentNonceTxs.filter(tx => tx.status === 'submitted')
diff --git a/old-ui/app/config.js b/old-ui/app/config.js
index 9e07cf348..508770bd4 100644
--- a/old-ui/app/config.js
+++ b/old-ui/app/config.js
@@ -42,7 +42,7 @@ ConfigScreen.prototype.render = function () {
// subtitle and nav
h('.section-title.flex-row.flex-center', [
h('i.fa.fa-arrow-left.fa-lg.cursor-pointer', {
- onClick: (event) => {
+ onClick: () => {
state.dispatch(actions.goHome())
},
}),
@@ -168,7 +168,6 @@ ConfigScreen.prototype.render = function () {
h('a', {
href: 'http://metamask.helpscoutdocs.com/article/36-resetting-an-account',
target: '_blank',
- onClick (event) { this.navigateTo(event.target.href) },
}, 'Read more.'),
]),
h('br'),
@@ -260,7 +259,3 @@ function currentProviderDisplay (metamaskState) {
h('span', value),
])
}
-
-ConfigScreen.prototype.navigateTo = function (url) {
- global.platform.openWindow({ url })
-}
diff --git a/old-ui/app/util.js b/old-ui/app/util.js
index 3f8b4dcc3..962832ce7 100644
--- a/old-ui/app/util.js
+++ b/old-ui/app/util.js
@@ -231,6 +231,7 @@ function exportAsFile (filename, data) {
window.navigator.msSaveBlob(blob, filename)
} else {
const elem = window.document.createElement('a')
+ elem.target = '_blank'
elem.href = window.URL.createObjectURL(blob)
elem.download = filename
document.body.appendChild(elem)
diff --git a/old-ui/css.js b/old-ui/css.js
index 21b311c28..5e2572e29 100644
--- a/old-ui/css.js
+++ b/old-ui/css.js
@@ -11,7 +11,7 @@ var cssFiles = {
'transitions.css': fs.readFileSync(path.join(__dirname, '/app/css/transitions.css'), 'utf8'),
'first-time.css': fs.readFileSync(path.join(__dirname, '../mascara/src/app/first-time/index.css'), 'utf8'),
'react-tooltip-component.css': fs.readFileSync(path.join(__dirname, '..', 'node_modules', 'react-tooltip-component', 'dist', 'react-tooltip-component.css'), 'utf8'),
- 'react-css': fs.readFileSync(path.join(__dirname, '..', 'node_modules', 'react-select', 'dist', 'react-select.css'), 'utf8'),
+ 'react-css': fs.readFileSync(path.join(__dirname, '..', 'node_modules', 'react-select', 'dist', 'react-select.css'), 'utf8')
}
function bundleCss () {
@@ -19,7 +19,7 @@ function bundleCss () {
var fileContent = cssFiles[fileName]
var output = String()
- output += '/*========== ' + fileName + ' ==========*/\n\n'
+ output += '/ *========== ' + fileName + ' ========== * /\n\n'
output += fileContent
output += '\n\n'