diff --git a/react/change.log b/react/change.log
index 534043b..c376a6b 100644
--- a/react/change.log
+++ b/react/change.log
@@ -10,6 +10,9 @@ UI:
- komodod crash report modal
- values rounding (up to 6 decimals)
- add coin multi ui reflow fix
+- reset app setting to default
+- manual balance / transactions list refresh
+- quick access dropdown on login to open settings / about / sync only modals
v0.2.0.21a-beta
--------------
diff --git a/react/package.json b/react/package.json
index 3262370..f50b05e 100644
--- a/react/package.json
+++ b/react/package.json
@@ -38,10 +38,12 @@
"bluebird": "^3.5.0",
"express": "^4.14.0",
"file-loader": "^0.10.0",
+ "qrcode.react": "^0.7.1",
"rc-tree": "^1.4.6",
"react": "^15.3.1",
"react-dom": "^15.3.1",
"react-hot-loader": "^1.3.0",
+ "react-qr-reader": "^1.1.3",
"react-redux": "^5.0.3",
"react-router": "^3.0.2",
"react-router-redux": "^4.0.4",
diff --git a/react/src/actions/actionCreators.js b/react/src/actions/actionCreators.js
index baf8d37..f070101 100644
--- a/react/src/actions/actionCreators.js
+++ b/react/src/actions/actionCreators.js
@@ -25,6 +25,7 @@ import {
DASHBOARD_ACTIVE_COIN_CHANGE,
ACTIVE_COIN_GET_ADDRESSES,
DASHBOARD_ACTIVE_COIN_NATIVE_TXHISTORY,
+ DISPLAY_LOGIN_SETTINGS_MODAL,
DISPLAY_COIND_DOWN_MODAL,
START_INTERVAL,
STOP_INTERVAL
@@ -358,4 +359,11 @@ export function toggleCoindDownModal(display) {
type: DISPLAY_COIND_DOWN_MODAL,
displayCoindDownModal: display,
}
+}
+
+export function toggleLoginSettingsModal(display) {
+ return {
+ type: DISPLAY_LOGIN_SETTINGS_MODAL,
+ displayLoginSettingsModal: display,
+ }
}
\ No newline at end of file
diff --git a/react/src/actions/actions/basiliskCache.js b/react/src/actions/actions/basiliskCache.js
index 07a5713..00d4087 100644
--- a/react/src/actions/actions/basiliskCache.js
+++ b/react/src/actions/actions/basiliskCache.js
@@ -67,10 +67,11 @@ export function fetchNewCacheData(_payload) {
_coin = `&coin=${_payload.coin}`,
_calls = `&calls=${_payload.calls}`,
_address = _payload.address ? (`&address=${_payload.address}`) : '',
+ _skip = _payload.skip ? (`&skip=${_payload.skip}`) : '',
_iguanaInstancePort = Config.useBasiliskInstance ? `&port=${Config.iguanaCorePort + 1}` : '';
return dispatch => {
- return fetch(`http://127.0.0.1:${Config.agamaPort}/shepherd/${_route}${_userpass}${_pubkey}${_coin}${_calls}${_address}${_iguanaInstancePort}`, {
+ return fetch(`http://127.0.0.1:${Config.agamaPort}/shepherd/${_route}${_userpass}${_pubkey}${_coin}${_calls}${_address}${_skip}${_iguanaInstancePort}`, {
method: 'GET',
headers: {
'Content-Type': 'application/json',
diff --git a/react/src/actions/storeType.js b/react/src/actions/storeType.js
index d00021b..23deb33 100644
--- a/react/src/actions/storeType.js
+++ b/react/src/actions/storeType.js
@@ -44,4 +44,5 @@ export const LOAD_APP_INFO = 'LOAD_APP_INFO';
export const LOG_GUI_HTTP = 'LOG_GUI_HTTP';
export const CLI = 'CLI';
export const LOGOUT = 'LOGOUT';
-export const DISPLAY_COIND_DOWN_MODAL = 'DISPLAY_COIND_DOWN_MODAL';
\ No newline at end of file
+export const DISPLAY_COIND_DOWN_MODAL = 'DISPLAY_COIND_DOWN_MODAL';
+export const DISPLAY_LOGIN_SETTINGS_MODAL = 'DISPLAY_LOGIN_SETTINGS_MODAL';
\ No newline at end of file
diff --git a/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.js b/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.js
new file mode 100755
index 0000000..cea9312
--- /dev/null
+++ b/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.js
@@ -0,0 +1,32 @@
+import React from 'react';
+import { getCoinTitle } from '../../../util/coinHelper';
+import { translate } from '../../../translate/translate';
+import { toggleLoginSettingsModal } from '../../../actions/actionCreators';
+import Store from '../../../store';
+
+import { LoginSettingsModalRender } from './loginSettingsModal.render';
+
+class LoginSettingsModal extends React.Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ };
+ this.closeLoginSettingsModal = this.closeLoginSettingsModal.bind(this);
+ }
+
+ closeLoginSettingsModal() {
+ Store.dispatch(toggleLoginSettingsModal(false));
+ }
+
+ render() {
+ if (this.props &&
+ this.props.Main &&
+ this.props.Main.displayLoginSettingsModal) {
+ return LoginSettingsModalRender.call(this);
+ } else {
+ return null;
+ }
+ }
+}
+
+export default LoginSettingsModal;
\ No newline at end of file
diff --git a/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.render.js b/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.render.js
new file mode 100644
index 0000000..8a59705
--- /dev/null
+++ b/react/src/components/dashboard/loginSettingsModal/loginSettingsModal.render.js
@@ -0,0 +1,34 @@
+import React from 'react';
+import { translate } from '../../../translate/translate';
+import About from '../about/about';
+import Settings from '../settings/settings';
+
+export const LoginSettingsModalRender = function() {
+ return (
+
+
+
+
+
+ { this.props.section === 'settings' &&
+
+ }
+ { this.props.section === 'about' &&
+
+ }
+
+
+
+
+
+
+
+
+
+ );
+};
\ No newline at end of file
diff --git a/react/src/components/dashboard/qrModal/qrModal.js b/react/src/components/dashboard/qrModal/qrModal.js
new file mode 100755
index 0000000..0866cc9
--- /dev/null
+++ b/react/src/components/dashboard/qrModal/qrModal.js
@@ -0,0 +1,78 @@
+import React from 'react';
+import ReactDOM from 'react-dom';
+import Store from '../../../store';
+import { translate } from '../../../translate/translate';
+import QrReader from 'react-qr-reader'
+import {
+ QRModalRender,
+ QRModalReaderRender
+} from './qrModal.render';
+
+class QRModal extends React.Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ modalIsOpen: false,
+ error: null,
+ };
+ this.openModal = this.openModal.bind(this);
+ this.closeModal = this.closeModal.bind(this);
+ this.handleScan = this.handleScan.bind(this);
+ this.handleError = this.handleError.bind(this);
+ document.body.addEventListener('click', this.closeModal);
+ }
+
+ handleScan(data) {
+ if (data !== null) {
+ if (this.props.mode === 'scan') {
+ this.props.setRecieverFromScan(data)
+ }
+ this.closeModal();
+ }
+ }
+
+ handleError(err) {
+ this.setState({
+ error: err,
+ });
+ }
+
+ openModal() {
+ this.setState({
+ modalIsOpen: true
+ });
+
+ if (this.props.mode === 'scan') {
+ ReactDOM.render(
+ , document.getElementById('webcam'));
+ }
+ }
+
+ closeModal() {
+ this.setState({
+ modalIsOpen: false,
+ });
+
+ if (this.props.mode === 'scan') {
+ ReactDOM.unmountComponentAtNode(document.getElementById('webcam'));
+ }
+ }
+
+ render() {
+ if (this.props.mode === 'scan') {
+ return QRModalReaderRender.call(this);
+ } else {
+ return QRModalRender.call(this);
+ }
+ }
+}
+
+export default QRModal;
\ No newline at end of file
diff --git a/react/src/components/dashboard/qrModal/qrModal.render.js b/react/src/components/dashboard/qrModal/qrModal.render.js
new file mode 100644
index 0000000..0524407
--- /dev/null
+++ b/react/src/components/dashboard/qrModal/qrModal.render.js
@@ -0,0 +1,82 @@
+import React from 'react';
+import { translate } from '../../../translate/translate';
+import QRCode from 'qrcode.react';
+
+export const QRModalRender = function () {
+ return (
+
+
+
+
+
+
+
+
+
+
{ translate('INDEX.SCAN_QR_CODE') }
+
+
+
+
+
+
+
+ );
+};
+
+export const QRModalReaderRender = function () {
+ return (
+
+
+
+
+
+
+
+
{ translate('INDEX.SCAN_QRCODE_WEBCAM') }
+
+
+
+
+
+ { this.state.error }
+
+
+
+
+
+
+
+
+
+ );
+};
\ No newline at end of file
diff --git a/react/src/components/dashboard/receiveCoin/receiveCoin.render.js b/react/src/components/dashboard/receiveCoin/receiveCoin.render.js
index f5acf16..108fb88 100644
--- a/react/src/components/dashboard/receiveCoin/receiveCoin.render.js
+++ b/react/src/components/dashboard/receiveCoin/receiveCoin.render.js
@@ -1,5 +1,6 @@
import React from 'react';
import { translate } from '../../../translate/translate';
+import QRModal from '../qrModal/qrModal';
export const AddressActionsBasiliskModeRender = function(address) {
return (
@@ -25,6 +26,9 @@ export const AddressActionsBasiliskModeRender = function(address) {
onClick={ () => this._validateAddressBasilisk(address) }>
+
);
};
@@ -41,6 +45,9 @@ export const AddressActionsNonBasiliskModeRender = function(address, type) {
onClick={ () => this._copyCoinAddress(address) }>
{ translate('INDEX.COPY') }
+
);
};
@@ -140,4 +147,5 @@ export const ReceiveCoinRender = function() {
);
-};
\ No newline at end of file
+};
+
diff --git a/react/src/components/dashboard/sendCoin/sendCoin.js b/react/src/components/dashboard/sendCoin/sendCoin.js
index 3d41a4b..39566aa 100644
--- a/react/src/components/dashboard/sendCoin/sendCoin.js
+++ b/react/src/components/dashboard/sendCoin/sendCoin.js
@@ -55,6 +55,7 @@ class SendCoin extends React.Component {
currentStackLength: 0,
totalStackLength: 0,
utxoMethodInProgress: false,
+ isCameraFeatureDetected: false,
};
this.updateInput = this.updateInput.bind(this);
this.handleBasiliskSend = this.handleBasiliskSend.bind(this);
@@ -64,15 +65,44 @@ class SendCoin extends React.Component {
this.toggleSendAPIType = this.toggleSendAPIType.bind(this);
this._fetchNewUTXOData = this._fetchNewUTXOData.bind(this);
this.handleClickOutside = this.handleClickOutside.bind(this);
+ this.setRecieverFromScan = this.setRecieverFromScan.bind(this);
+ this.detectCamera = this.detectCamera.bind(this);
socket.on('messages', msg => this.updateSocketsData(msg));
}
+ // test device camera capabilities
+ detectCamera() {
+ const _getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia || navigator.mozGetUserMedia || navigator.msGetUserMedia;
+
+ _getUserMedia(
+ { 'video': true },
+ function() {
+ this.setState({
+ isCameraFeatureDetected: true,
+ });
+ },
+ function() {
+ console.warn('this device doesn\'t have camera!');
+ }
+ );
+ }
+
+ setRecieverFromScan(receiver) {
+ this.setState({
+ sendTo: receiver
+ });
+
+ document.getElementById('edexcoinSendTo').focus();
+ }
+
componentWillMount() {
document.addEventListener(
'click',
this.handleClickOutside,
false
);
+
+ this.detectCamera();
}
componentWillUnmount() {
@@ -173,7 +203,7 @@ class SendCoin extends React.Component {
this,
refreshCacheData,
isReadyToUpdate,
- waitUntilCallIsFinished,
+ waitUntilCallIsFinished,
timestamp
);
}
@@ -745,7 +775,6 @@ class SendCoin extends React.Component {
return null;
}
-
render() {
if (this.props.ActiveCoin &&
this.props.ActiveCoin.send &&
diff --git a/react/src/components/dashboard/sendCoin/sendCoin.render.js b/react/src/components/dashboard/sendCoin/sendCoin.render.js
index a7fc0a5..5a30302 100644
--- a/react/src/components/dashboard/sendCoin/sendCoin.render.js
+++ b/react/src/components/dashboard/sendCoin/sendCoin.render.js
@@ -5,14 +5,16 @@ import {
secondsToString
} from '../../../util/time';
+import QRModal from '../qrModal/qrModal';
+
export const UTXOCacheInfoRender = function(refreshCacheData, isReadyToUpdate, waitUntilCallIsFinished, timestamp) {
return (
- { translate('SEND.TOTAL_UTXO_AVAILABLE') }:
+ { translate('SEND.TOTAL_UTXO_AVAILABLE') }:
{ refreshCacheData ? refreshCacheData.data && refreshCacheData.data.length : translate('SEND.PRESS_UPDATE_BTN') }
- { translate('SEND.LAST_UPDATED') } @
+ { translate('SEND.LAST_UPDATED') } @
{ secondsToString(refreshCacheData ? refreshCacheData.timestamp : 0, true) } |
{ secondsElapsedToString(timestamp || 0) }&nbps;
{ translate('SEND.AGO') }
@@ -137,7 +139,7 @@ export const OASendUIRender = function () {
export const SendApiTypeSelectorRender = function () {
return (
-
+
+ { this.stateisCameraFeatureDetected &&
+
+
+
+ }
);
};
diff --git a/react/src/components/dashboard/settings/settings.js b/react/src/components/dashboard/settings/settings.js
index c1031cf..3d5f74d 100644
--- a/react/src/components/dashboard/settings/settings.js
+++ b/react/src/components/dashboard/settings/settings.js
@@ -62,6 +62,7 @@ class Settings extends React.Component {
updateProgressPatch: null,
wifkeysPassphrase: '',
trimPassphraseTimer: null,
+ disableWalletSpecificUI: null,
};
this.exportWifKeys = this.exportWifKeys.bind(this);
this.updateInput = this.updateInput.bind(this);
@@ -82,7 +83,9 @@ class Settings extends React.Component {
}
componentDidMount() {
- Store.dispatch(iguanaActiveHandle());
+ if (!this.props.disableWalletSpecificUI) {
+ Store.dispatch(iguanaActiveHandle());
+ }
Store.dispatch(getAppConfig());
Store.dispatch(getAppInfo());
}
@@ -95,6 +98,7 @@ class Settings extends React.Component {
activeTab: this.state.activeTab,
activeTabHeight: _height,
tabElId: this.state.tabElId,
+ disableWalletSpecificUI: props.disableWalletSpecificUI,
}));
}
}
diff --git a/react/src/components/dashboard/settings/settings.render.js b/react/src/components/dashboard/settings/settings.render.js
index 5988490..c6a0ddc 100644
--- a/react/src/components/dashboard/settings/settings.render.js
+++ b/react/src/components/dashboard/settings/settings.render.js
@@ -156,57 +156,59 @@ export const SettingsRender = function() {
-
this.openTab('WalletInfo', 0) }
- className={ 'panel' + (this.state.nativeOnly ? ' hide' : '') }>
-
+ { !this.props.disableWalletSpecificUI &&
-
-
-
-
- { translate('INDEX.KEY') } |
- { translate('INDEX.VALUE') } |
-
-
-
-
- pubkey |
- { this.props.Main.activeHandle.pubkey } |
-
-
- btcpubkey |
- { this.props.Main.activeHandle.btcpubkey } |
-
-
- rmd160 |
- { this.props.Main.activeHandle.rmd160 } |
-
-
- NXT |
- { this.props.Main.activeHandle.NXT } |
-
-
- notary |
- { this.props.Main.activeHandle.notary } |
-
-
- status |
- { this.props.Main.activeHandle.status } |
-
-
-
+ id="WalletInfo"
+ onClick={ () => this.openTab('WalletInfo', 0) }
+ className={ 'panel' + (this.state.nativeOnly ? ' hide' : '') }>
+
+
+
+
+
+
+ { translate('INDEX.KEY') } |
+ { translate('INDEX.VALUE') } |
+
+
+
+
+ pubkey |
+ { this.props.Main.activeHandle.pubkey } |
+
+
+ btcpubkey |
+ { this.props.Main.activeHandle.btcpubkey } |
+
+
+ rmd160 |
+ { this.props.Main.activeHandle.rmd160 } |
+
+
+ NXT |
+ { this.props.Main.activeHandle.NXT } |
+
+
+ notary |
+ { this.props.Main.activeHandle.notary } |
+
+
+ status |
+ { this.props.Main.activeHandle.status } |
+
+
+
+
-
-
+ }
+ { !this.props.disableWalletSpecificUI &&
this.openTab('AddNodeforCoin', 1) }
@@ -292,7 +294,8 @@ export const SettingsRender = function() {
-
+ }
+ { !this.props.disableWalletSpecificUI &&
this.openTab('DumpWallet', 2) }
@@ -308,7 +311,8 @@ export const SettingsRender = function() {
Wallet Backup section to be updated soon.
-
+ }
+ { !this.props.disableWalletSpecificUI &&
this.openTab('FiatCurrencySettings', 3) }
@@ -324,7 +328,8 @@ export const SettingsRender = function() {
Fiat currency settings section to be updated soon.
-
+ }
+ { !this.props.disableWalletSpecificUI &&
this.openTab('ExportKeys', 4) }
@@ -401,7 +406,8 @@ export const SettingsRender = function() {
-
+ }
+ { !this.props.disableWalletSpecificUI &&
this.openTab('ImportKeys', 5) }
@@ -450,6 +456,7 @@ export const SettingsRender = function() {
+ }
{ this.renderAppInfoTab() }
-
this.openTab('Cli', 9) }
- className={ 'panel' + (!this.props.Main.coins.native.length ? ' hide' : '') }>
-
+ { this.props.Main && this.props.Main.coins.native &&
-
-
{ translate('INDEX.CLI_SELECT_A_COIN') }
-
-
+ }
{ this.renderAppUpdateTab() }
diff --git a/react/src/components/dashboard/walletsBalance/walletsBalance.js b/react/src/components/dashboard/walletsBalance/walletsBalance.js
index 1dab912..c0f79c5 100755
--- a/react/src/components/dashboard/walletsBalance/walletsBalance.js
+++ b/react/src/components/dashboard/walletsBalance/walletsBalance.js
@@ -1,12 +1,31 @@
import React from 'react';
import { translate } from '../../../translate/translate';
+import {
+ fetchNewCacheData,
+ getKMDBalanceTotal,
+ iguanaEdexBalance
+} from '../../../actions/actionCreators';
+import Store from '../../../store';
import WalletsBalanceRender from './walletsBalance.render';
class WalletsBalance extends React.Component {
constructor(props) {
super(props);
+ this.state = {
+ currentAddress: null,
+ };
this.isFullySynced = this.isFullySynced.bind(this);
+ this.refreshBalance = this.refreshBalance.bind(this);
+ }
+
+ componentWillReceiveProps(props) {
+ if (!this.state.currentAddress &&
+ this.props.ActiveCoin.activeAddress) {
+ this.setState(Object.assign({}, this.state, {
+ currentAddress: this.props.ActiveCoin.activeAddress,
+ }));
+ }
}
isFullySynced() {
@@ -21,6 +40,30 @@ class WalletsBalance extends React.Component {
}
}
+ refreshBalance() {
+ const _mode = this.props.ActiveCoin.mode;
+ const _coin = this.props.ActiveCoin.coin;
+
+ switch(_mode) {
+ case 'basilisk':
+ Store.dispatch(fetchNewCacheData({
+ 'pubkey': this.props.Dashboard.activeHandle.pubkey,
+ 'allcoins': false,
+ 'coin': this.props.ActiveCoin.coin,
+ 'calls': 'getbalance',
+ 'skip': true,
+ 'address': this.state.currentAddress,
+ }));
+ break;
+ case 'native':
+ Store.dispatch(getKMDBalanceTotal(_coin));
+ break;
+ case 'full':
+ Store.dispatch(iguanaEdexBalance(_coin));
+ break;
+ }
+ }
+
renderBalance(type) {
let _balance = '0';
const _mode = this.props.ActiveCoin.mode;
diff --git a/react/src/components/dashboard/walletsBalance/walletsBalance.render.js b/react/src/components/dashboard/walletsBalance/walletsBalance.render.js
index 5a97998..6ce2b32 100644
--- a/react/src/components/dashboard/walletsBalance/walletsBalance.render.js
+++ b/react/src/components/dashboard/walletsBalance/walletsBalance.render.js
@@ -26,6 +26,9 @@ const WalletsBalanceRender = function() {
+
diff --git a/react/src/components/dashboard/walletsData/walletsData.js b/react/src/components/dashboard/walletsData/walletsData.js
index 43508bc..30755a6 100644
--- a/react/src/components/dashboard/walletsData/walletsData.js
+++ b/react/src/components/dashboard/walletsData/walletsData.js
@@ -17,7 +17,9 @@ import {
getDexNotaries,
deleteCacheFile,
fetchNewCacheData,
- fetchUtxoCache
+ fetchUtxoCache,
+ getNativeTxHistory,
+ getFullTransactionsList
} from '../../../actions/actionCreators';
import Store from '../../../store';
import {
@@ -64,6 +66,7 @@ class WalletsData extends React.Component {
this.restartBasiliskInstance = this.restartBasiliskInstance.bind(this);
this.basiliskRefreshActionOne = this.basiliskRefreshActionOne.bind(this);
this.handleClickOutside = this.handleClickOutside.bind(this);
+ this.refreshTxHistory = this.refreshTxHistory.bind(this);
socket.on('messages', msg => this.updateSocketsData(msg));
}
@@ -213,6 +216,30 @@ class WalletsData extends React.Component {
}
}
+ refreshTxHistory() {
+ const _mode = this.props.ActiveCoin.mode;
+ const _coin = this.props.ActiveCoin.coin;
+
+ switch(_mode) {
+ case 'basilisk':
+ Store.dispatch(fetchNewCacheData({
+ 'pubkey': this.props.Dashboard.activeHandle.pubkey,
+ 'allcoins': false,
+ 'coin': _coin,
+ 'calls': 'listtransactions',
+ 'skip': true,
+ 'address': this.state.currentAddress,
+ }));
+ break;
+ case 'native':
+ Store.dispatch(getNativeTxHistory(_coin));
+ break;
+ case 'full':
+ Store.dispatch(getFullTransactionsList(_coin));
+ break;
+ }
+ }
+
removeAndFetchNewCache() {
Store.dispatch(deleteCacheFile({
'pubkey': this.props.Dashboard.activeHandle.pubkey,
diff --git a/react/src/components/dashboard/walletsData/walletsData.render.js b/react/src/components/dashboard/walletsData/walletsData.render.js
index 63db3df..2570602 100644
--- a/react/src/components/dashboard/walletsData/walletsData.render.js
+++ b/react/src/components/dashboard/walletsData/walletsData.render.js
@@ -174,6 +174,9 @@ export const WalletsDataRender = function() {
+
+
{ this.renderSwallModal() }
@@ -16,12 +20,34 @@ const LoginRender = function () {
alt="SuperNET Iguana" />
-
-
- { translate('LOGIN.DISPLAY_SYNC_ONLY') }
-
+
+
+
+
+ Quick access
+
+
+
diff --git a/react/src/components/login/login.scss b/react/src/components/login/login.scss
index ed3e5c3..4b07173 100644
--- a/react/src/components/login/login.scss
+++ b/react/src/components/login/login.scss
@@ -126,4 +126,30 @@ input[type="password"] {
.floating-label {
font-size: 13px;
}
+}
+
+.login-settings-dropdown {
+ font-size: 16px;
+
+ .dropdown-menu {
+ left: 42%;
+ top: inherit;
+ }
+}
+
+.login-settings-dropdown-trigger {
+ cursor: pointer;
+}
+
+.login-settings-modal {
+ .modal-body {
+ overflow-y: scroll;
+ color: #757575;
+ }
+ .panel-title {
+ color: #757575;
+ }
+ a {
+ color: #fb8c00;
+ }
}
\ No newline at end of file
diff --git a/react/src/components/overrides.scss b/react/src/components/overrides.scss
index 55cd8a3..5bee66c 100644
--- a/react/src/components/overrides.scss
+++ b/react/src/components/overrides.scss
@@ -641,4 +641,11 @@ select{
.backround-gray {
background: #f3f4f5;
+}
+
+.manual-balance-refresh,
+.manual-txhistory-refresh {
+ position: absolute;
+ right: 4px;
+ top: 3px;
}
\ No newline at end of file
diff --git a/react/src/reducers/main.js b/react/src/reducers/main.js
index f000ae6..0381ef1 100644
--- a/react/src/reducers/main.js
+++ b/react/src/reducers/main.js
@@ -1,12 +1,14 @@
import {
GET_ACTIVE_COINS,
LOGIN,
- ACTIVE_HANDLE
+ ACTIVE_HANDLE,
+ DISPLAY_LOGIN_SETTINGS_MODAL
} from '../actions/storeType';
export function Main(state = {
isLoggedIn: false,
activeCoins: [],
+ displayLoginSettingsModal: false,
}, action) {
switch (action.type) {
case GET_ACTIVE_COINS:
@@ -23,6 +25,10 @@ export function Main(state = {
isLoggedIn: action.isLoggedIn,
activeHandle: action.handle,
});
+ case DISPLAY_LOGIN_SETTINGS_MODAL:
+ return Object.assign({}, state, {
+ displayLoginSettingsModal: action.displayLoginSettingsModal,
+ });
default:
return state;
}
diff --git a/react/src/store.js b/react/src/store.js
index acd567c..1047d99 100644
--- a/react/src/store.js
+++ b/react/src/store.js
@@ -3,6 +3,7 @@ import thunkMiddleware from 'redux-thunk';
import createLogger from 'redux-logger';
import { syncHistoryWithStore } from 'react-router-redux';
import { browserHistory } from 'react-router';
+import Config from './config';
import rootReducer from './reducers/index';
@@ -19,7 +20,7 @@ const defaultState = {
/* eslint-disable no-underscore-dangle */
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose;
-const enhancers = composeEnhancers(applyMiddleware(thunkMiddleware, loggerMiddleware));
+const enhancers = Config.debug || Config.dev ? composeEnhancers(applyMiddleware(thunkMiddleware, loggerMiddleware)) : composeEnhancers(applyMiddleware(thunkMiddleware));
const store = createStore(
rootReducer,
defaultState,
diff --git a/react/src/translate/en.js b/react/src/translate/en.js
index bc8fe39..c9f082f 100644
--- a/react/src/translate/en.js
+++ b/react/src/translate/en.js
@@ -250,6 +250,9 @@ export const _lang = {
'ENTER': 'Enter',
'ADDR_SM': 'address',
'ACTIVATING': 'Activating',
+ 'QRCODE': 'Show QR code',
+ 'SCAN_QR_CODE': 'Scan QR Code',
+ 'SCAN_QRCODE_WEBCAM': 'Scan QR Code with webcam',
'NEXT_PAGE': 'Next Page',
'PREVIOUS_PAGE': 'Previous Page'
},