Adjust preimage app layout/media (#8663)
This commit is contained in:
parent
732eb2e444
commit
10dc3d46d8
@ -21,21 +21,19 @@ function Preimage ({ className, value }: Props): React.ReactElement<Props> {
|
||||
const info = usePreimage(value);
|
||||
|
||||
return (
|
||||
<tr className={ className }>
|
||||
<tr className={className}>
|
||||
<Hash value={value} />
|
||||
<Call value={info} />
|
||||
<td className='number'>
|
||||
<td className='number media--1000'>
|
||||
{info?.bytes && formatNumber(info.bytes.length)}
|
||||
</td>
|
||||
<td className='number'>
|
||||
{info?.status?.type}
|
||||
<td className='preimage-status together media--1200'>
|
||||
<div>{info?.status?.type}</div>
|
||||
{info && <Free value={info} />}
|
||||
</td>
|
||||
<td className='number media--1400'>
|
||||
{info && info.count !== 0 && formatNumber(info.count)}
|
||||
</td>
|
||||
<td className='button'>
|
||||
{info && <Free value={info} />}
|
||||
</td>
|
||||
</tr>
|
||||
);
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
import type { SubmittableExtrinsicFunction } from '@polkadot/api/types';
|
||||
|
||||
import React, { useRef } from 'react';
|
||||
import styled from 'styled-components';
|
||||
|
||||
import { Button, Table } from '@polkadot/react-components';
|
||||
|
||||
@ -26,10 +27,9 @@ function Hashes ({ className }: Props): React.ReactElement<Props> {
|
||||
const headerRef = useRef([
|
||||
[t('preimages'), 'start', 2],
|
||||
[undefined, 'media--1300'],
|
||||
[t('size')],
|
||||
[t('status')],
|
||||
[t('count'), 'media--1400'],
|
||||
[]
|
||||
[t('size'), 'media--1000'],
|
||||
[t('status'), 'start media--1200'],
|
||||
[t('count'), 'media--1400']
|
||||
]);
|
||||
|
||||
return (
|
||||
@ -54,4 +54,10 @@ function Hashes ({ className }: Props): React.ReactElement<Props> {
|
||||
);
|
||||
}
|
||||
|
||||
export default React.memo(Hashes);
|
||||
export default React.memo(styled(Hashes)`
|
||||
td.preimage-status {
|
||||
div+.ui--Button {
|
||||
margin-top: 0.25rem;
|
||||
}
|
||||
}
|
||||
`);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user