Adjust account table layouts (#8637)
This commit is contained in:
parent
727d9c6ee8
commit
089da62e3b
@ -750,7 +750,6 @@ function Account ({ account: { address, meta }, className = '', delegation, filt
|
||||
</Columar.Column>
|
||||
</Columar>
|
||||
</td>
|
||||
<td />
|
||||
<td className='balance top'>
|
||||
<AddressInfo
|
||||
address={address}
|
||||
|
||||
@ -157,23 +157,18 @@ function Overview ({ className = '', onStatusChange }: Props): React.ReactElemen
|
||||
const header = useMemo(
|
||||
(): Record<GroupName, [React.ReactNode?, string?, number?, (() => void)?][]> => {
|
||||
const ret: Record<GroupName, [React.ReactNode?, string?, number?, (() => void)?][]> = {
|
||||
accounts: [[t('accounts')]],
|
||||
hardware: [[t('hardware')]],
|
||||
injected: [[t('extension')]],
|
||||
multisig: [[t('multisig')]],
|
||||
proxied: [[t('proxied')]],
|
||||
qr: [[t('via qr')]],
|
||||
testing: [[t('development')]]
|
||||
accounts: [[<>{t('accounts')}<div className='sub'>{t<string>('all locally stored accounts')}</div></>]],
|
||||
hardware: [[<>{t('hardware')}<div className='sub'>{t<string>('accounts managed via hardware devices')}</div></>]],
|
||||
injected: [[<>{t('extension')}<div className='sub'>{t<string>('accounts available via browser extensions')}</div></>]],
|
||||
multisig: [[<>{t('multisig')}<div className='sub'>{t<string>('on-chain multisig accounts')}</div></>]],
|
||||
proxied: [[<>{t('proxied')}<div className='sub'>{t<string>('on-chain proxied accounts')}</div></>]],
|
||||
qr: [[<>{t('via qr')}<div className='sub'>{t<string>('accounts available via mobile devices')}</div></>]],
|
||||
testing: [[<>{t('development')}<div className='sub'>{t<string>('accounts derived via development seeds')}</div></>]]
|
||||
};
|
||||
|
||||
Object.values(ret).forEach((a): void => {
|
||||
a[0][1] = 'start';
|
||||
a[0][2] = 2;
|
||||
|
||||
a.push(
|
||||
[undefined, 'balances'],
|
||||
[]
|
||||
);
|
||||
a[0][2] = 4;
|
||||
});
|
||||
|
||||
return ret;
|
||||
|
||||
@ -55,7 +55,7 @@ function Group ({ activeIssuance, className, isMember, members, palletReferenda,
|
||||
const [header, key] = useMemo(
|
||||
() => [
|
||||
[
|
||||
[trackName ? <>{trackName}<div>{trackInfo?.text}</div></> : t('referenda'), 'start', 5],
|
||||
[trackName ? <>{trackName}<div className='sub'>{trackInfo?.text}</div></> : t('referenda'), 'start', 5],
|
||||
[undefined, 'number', 3],
|
||||
[headerButton]
|
||||
],
|
||||
@ -93,13 +93,6 @@ function Group ({ activeIssuance, className, isMember, members, palletReferenda,
|
||||
}
|
||||
|
||||
export default React.memo(styled(Group)`
|
||||
th > h1 > div {
|
||||
display: inline-block;
|
||||
font-size: 1rem;
|
||||
padding-left: 1.5rem;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
th.number h1 {
|
||||
display: inline-block;
|
||||
opacity: 0.75;
|
||||
|
||||
@ -59,7 +59,6 @@ function Head ({ children, className = '', filter, header, isEmpty }: Props): Re
|
||||
}
|
||||
|
||||
export default React.memo(styled(Head)`
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
|
||||
th {
|
||||
@ -83,6 +82,13 @@ export default React.memo(styled(Head)`
|
||||
margin-right: 0.5rem;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.sub {
|
||||
display: inline-block;
|
||||
font-size: 1rem;
|
||||
padding-left: 1.5rem;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
|
||||
&:first-child {
|
||||
|
||||
@ -146,6 +146,15 @@ export default React.memo(styled(Table)`
|
||||
}
|
||||
}
|
||||
|
||||
tbody, thead {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
|
||||
tr {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
tbody {
|
||||
position: relative;
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user