{t(peers.options.name)}
{status}
+
+
+ {status}
+ {t('Connected to ')}{translations[iconCode]}
+
+
+ {peers.data.currentNode}
+
-
-
- {peers.data.currentNode}
-
:
null
);
diff --git a/src/components/account/account.test.js b/src/components/account/account.test.js
index 1fee5fc171..39e888b191 100644
--- a/src/components/account/account.test.js
+++ b/src/components/account/account.test.js
@@ -1,7 +1,9 @@
import React from 'react';
+import Lisk from 'lisk-elements';
import { expect } from 'chai';
import { shallow } from 'enzyme';
import sinon from 'sinon';
+import networks from '../../constants/networks';
import Account from './account';
describe('Account', () => {
@@ -13,6 +15,7 @@ describe('Account', () => {
i18n: {},
store: {},
onActivePeerUpdated: sinon.spy(),
+ showNetworkIndicator: true,
peers: {
status: {
online: false,
@@ -41,9 +44,28 @@ describe('Account', () => {
expect(wrapper.find('Address')).to.have.lengthOf(1);
});
- it('depicts being online when peers.status.online is true', () => {
+ it('shows network indicator online', () => {
props.peers.status.online = true;
const wrapper = shallow(
);
- expect(wrapper.find('.status FontIcon')).to.have.className('online');
+ wrapper.update();
+ expect(wrapper).to.have.exactly(1).descendants('.online');
+ });
+
+ it('shows network indicator offline', () => {
+ props.peers.status.online = false;
+ const wrapper = shallow(
);
+ wrapper.update();
+ expect(wrapper).to.have.exactly(1).descendants('.offline');
+ });
+
+ it('shows testnet icon when online and nethash matches', () => {
+ props.peers.status.online = true;
+ props.peers.options.nethash = Lisk.constants.TESTNET_NETHASH;
+ props.peers.options.code = networks.customNode.code;
+ props.peers.data.currentNode = 'http://localhost:4000';
+ const wrapper = shallow(
);
+ wrapper.update();
+ expect(wrapper).to.have.exactly(1).descendants('.online');
+ expect(wrapper).to.have.exactly(1).descendants('.testnet-title');
});
});
diff --git a/src/components/app/global.css b/src/components/app/global.css
index e3550b8b2a..2ca92f62be 100644
--- a/src/components/app/global.css
+++ b/src/components/app/global.css
@@ -39,12 +39,6 @@ order to be available application wide
padding: 0px 30px;
}
-:global .appLoaded {
- & .searchBar {
- display: inline-block;
- }
-}
-
@media (--medium-viewport) {
:global body.contentFocused {
margin-top: 0;
diff --git a/src/components/autoSuggest/autoSuggest.css b/src/components/autoSuggest/autoSuggest.css
index 1b44ea5ee6..b0a3156eab 100644
--- a/src/components/autoSuggest/autoSuggest.css
+++ b/src/components/autoSuggest/autoSuggest.css
@@ -45,7 +45,8 @@
pointer-events: none;
opacity: 0.5;
padding: 0;
- width: 100%;
+ width: calc(30vw - 74px); /* stylelint-disable-line */
+ text-overflow: ellipsis;
}
.input {
diff --git a/src/components/header/header.css b/src/components/header/header.css
index fd625f1513..31002bece9 100644
--- a/src/components/header/header.css
+++ b/src/components/header/header.css
@@ -15,7 +15,9 @@
}
.wrapper {
- text-align: right;
+ display: flex;
+ flex-direction: row;
+ justify-content: space-between;
& .noPadding {
padding: 0px;
@@ -25,6 +27,7 @@
display: inline-block;
float: left;
margin-bottom: 30px;
+ margin-right: 32px;
}
}
@@ -218,6 +221,12 @@
.loginInfo {
width: 100%;
float: none;
+
+ & > div {
+ display: flex;
+ flex-direction: row;
+ justify-content: space-between;
+ }
}
.wrapper {
@@ -233,6 +242,7 @@
& .searchBar {
width: 100%;
margin-bottom: 0;
+ display: none;
}
}
diff --git a/src/components/header/header.js b/src/components/header/header.js
index 0b317584d9..a539661b60 100644
--- a/src/components/header/header.js
+++ b/src/components/header/header.js
@@ -58,8 +58,18 @@ class Header extends React.Component {
}
render() {
+ const { peers, t, showNetworkIndicator } = this.props;
return (
);
}
diff --git a/src/components/header/index.js b/src/components/header/index.js
index f519a1b6e4..7f7c4ce171 100644
--- a/src/components/header/index.js
+++ b/src/components/header/index.js
@@ -14,6 +14,7 @@ const mapStateToProps = state => ({
autoLog: state.settings.autoLog,
isAuthenticated: !!state.account.publicKey,
peers: state.peers,
+ showNetworkIndicator: state.settings.showNetwork,
});
const mapDispatchToProps = dispatch => ({
diff --git a/src/components/searchBar/searchBar.css b/src/components/searchBar/searchBar.css
index c04d2b4d20..0a2e5504c8 100644
--- a/src/components/searchBar/searchBar.css
+++ b/src/components/searchBar/searchBar.css
@@ -10,11 +10,10 @@
}
.searchBar {
- display: none;
vertical-align: top;
position: relative;
width: var(--search-box-width-l);
- margin-right: 50px;
+ margin-right: 32px;
& .icon {
position: absolute;
diff --git a/src/components/transactions/transactionRow.css b/src/components/transactions/transactionRow.css
index 22d6c80bac..d106ed1bfa 100644
--- a/src/components/transactions/transactionRow.css
+++ b/src/components/transactions/transactionRow.css
@@ -9,12 +9,32 @@
--result-address-font-weight: var(--font-weight-semi-bold);
--grid-header-line-height: 60px;
--main-row-line-height: 70px;
+ --box-padding-right-M: 0;
+ --box-padding-right-L: 0;
+ --box-padding-right-XL: 0;
}
.header {
color: var(--grid-header-color);
line-height: var(--grid-header-line-height);
font-weight: var(--font-weight-very-bold);
+
+ &:nth-child(2) {
+ text-align: left;
+ }
+}
+
+.reference {
+ text-overflow: ellipsis;
+ white-space: nowrap;
+ overflow: hidden;
+ text-align: left;
+}
+
+.arrowRow {
+ & span {
+ margin-right: 8px;
+ }
}
.rows {
@@ -58,7 +78,7 @@
}
.rows {
- padding: 0px var(--box-padding-left-XL);
+ padding: 0 var(--box-padding-right-XL) 0 var(--box-padding-left-XL);
}
}
@@ -68,7 +88,7 @@
}
.rows {
- padding: 0px var(--box-padding-left-L);
+ padding: 0 var(--box-padding-right-L) 0 var(--box-padding-left-L);
}
}
@@ -78,7 +98,7 @@
}
.rows {
- padding: 0px var(--box-padding-left-M);
+ padding: 0 var(--box-padding-right-M) 0 var(--box-padding-left-M);
&:nth-of-type(even) {
background: var(--gradient-greyscale-mobile);
@@ -88,10 +108,22 @@
background: var(--color-grayscale-mobile-background);
}
}
+
+ .arrowRow {
+ text-align: right;
+
+ & span {
+ margin-right: 8px;
+ }
+ }
}
@media (--small-viewport) {
.hiddenXs {
display: none;
}
+
+ .arrowRow {
+ text-align: right;
+ }
}
diff --git a/src/components/transactions/transactionRow.js b/src/components/transactions/transactionRow.js
index 22e9a449ba..8d47361fb2 100644
--- a/src/components/transactions/transactionRow.js
+++ b/src/components/transactions/transactionRow.js
@@ -19,21 +19,28 @@ class TransactionRow extends React.Component {
const onClick = !props.onClick ? (() => {}) : () => props.onClick(this.props);
return (
-
+
+
+
+ {props.value.asset && props.value.asset.data ?
+ {props.value.asset.data}
+ : '-'}
+
+
{props.value.confirmations ?
: }
-
+
-
diff --git a/src/components/transactions/transactionRow.test.js b/src/components/transactions/transactionRow.test.js
index a396d9a9ca..0993b96364 100644
--- a/src/components/transactions/transactionRow.test.js
+++ b/src/components/transactions/transactionRow.test.js
@@ -56,7 +56,7 @@ describe('TransactionRow', () => {
, options);
- expect(wrapper.find('.transactions-cell')).to.have.lengthOf(4);
+ expect(wrapper.find('.transactions-cell')).to.have.lengthOf(5);
});
it('should not cause any error on click if props.onClick is not defined', () => {
diff --git a/src/components/transactions/transactionsHeader.js b/src/components/transactions/transactionsHeader.js
index b65d09f641..1dbbdde48a 100644
--- a/src/components/transactions/transactionsHeader.js
+++ b/src/components/transactions/transactionsHeader.js
@@ -5,7 +5,8 @@ import styles from './transactionRow.css';
const TransactionsHeader = ({ t }) => (