Add when when too many accounts (#7677)

This commit is contained in:
Amaury Martiny 2018-01-23 16:34:02 +01:00 committed by Jaco Greeff
parent 66322c769e
commit 6d60286bf6
2 changed files with 8 additions and 5 deletions

View File

@ -26,11 +26,14 @@
.list {
margin: 0 !important;
padding: 1em 1em !important;
background-color: #f5f5f5;
background-color: white;
}
.isDefault {
background-color: white;
.accountsList {
background-color: #f5f5f5;
height: 300px;
overflow-y: auto;
}
.hasOtherAccounts {

View File

@ -68,14 +68,14 @@ class DefaultAccount extends Component {
}
content={
<div>
<List relaxed='very' selection className={ [styles.list, styles.isDefault, allAccounts.length > 1 && styles.hasOtherAccounts].join(' ') }>
<List relaxed='very' selection className={ [styles.list, allAccounts.length > 1 && styles.hasOtherAccounts].join(' ') }>
<AccountItem
isDefault
account={ defaultAccount }
/>
</List>
{allAccounts.length > 1 &&
<List relaxed='very' selection className={ styles.list } divided>
<List relaxed='very' selection className={ [styles.list, styles.accountsList].join(' ') } divided>
{allAccounts
.filter(({ address }) => address !== defaultAddress)
.map(account => (