Extract Table action classes (#8646)

* Extract Table action classes

* Extract from bounty
This commit is contained in:
Jaco 2022-12-29 09:57:35 +02:00 committed by GitHub
parent 958598f6e9
commit 207fae5961
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 38 additions and 86 deletions

View File

@ -694,8 +694,8 @@ function Account ({ account: { address, meta }, className = '', delegation, filt
withExtended={false}
/>
</td>
<td className='fast-actions'>
<div className='fast-actions-row'>
<td className='actions'>
<div>
{isFunction(api.api.tx.balances?.transfer) && (
<Button
className='send-button'
@ -786,28 +786,4 @@ export default React.memo(styled(Account)`
.devBadge {
opacity: 0.65;
}
&& td.button {
padding-bottom: 0.5rem;
}
&& td.fast-actions {
padding-left: 0.2rem;
padding-right: 1rem;
width: 1%;
.fast-actions-row {
display: flex;
align-items: center;
justify-content: flex-end;
& > * + * {
margin-left: 0.35rem;
}
.send-button {
min-width: 6.5rem;
}
}
}
`);

View File

@ -227,8 +227,8 @@ function Address ({ address, className = '', filter, isFavorite, toggleFavorite
withExtended={false}
/>
</td>
<td className='fast-actions-addresses'>
<div className='fast-actions-row'>
<td className='actions'>
<div>
{isFunction(api.api.tx.balances?.transfer) && (
<Button
className='send-button'
@ -306,28 +306,4 @@ export default React.memo(styled(Address)`
.ui--Columar {
margin: 0.5rem 0 1.5rem 0;
}
&& td.button {
padding-bottom: 0.5rem;
}
.fast-actions-addresses {
padding-left: 0.2rem;
padding-right: 1rem;
width: 1%;
.fast-actions-row {
display: flex;
align-items: center;
justify-content: flex-end;
& > * + * {
margin-left: 0.35rem;
}
.send-button {
min-width: 6.5rem;
}
}
}
`);

View File

@ -100,28 +100,24 @@ function Bounty ({ bestNumber, bounty, className = '', description, index, propo
status={status}
/>
</td>
<td className='td-info-action-row'>
<div className='td-row'>
<BountyInfos
beneficiary={beneficiary}
<td>
<BountyInfos
beneficiary={beneficiary}
proposals={proposals}
status={status}
/>
</td>
<td className='actions'>
<div>
<BountyActions
bestNumber={bestNumber}
description={description}
fee={fee}
index={index}
proposals={proposals}
status={status}
value={value}
/>
<div className='bounty-action-row'>
<BountyActions
bestNumber={bestNumber}
description={description}
fee={fee}
index={index}
proposals={proposals}
status={status}
value={value}
/>
</div>
</div>
</td>
<td className='fast-actions'>
<div className='fast-actions-row'>
<LinkExternal
data={index}
type='bounty'
@ -208,21 +204,6 @@ export default React.memo(styled(Bounty)`
display: inline-flex;
}
& td.fast-actions {
padding-left: 0.2rem;
width: 1%;
.fast-actions-row {
align-items: center;
display: flex;
justify-content: flex-end;
& > * + * {
margin-left: 0.285rem;
}
}
}
& .inline-balance {
width: 50%;
font-size: 1rem;

View File

@ -266,6 +266,25 @@ export default React.memo(styled(Table)`
text-align: right;
}
&.actions {
width: 1%;
> div {
display: flex;
align-items: center;
flex-wrap: nowrap;
justify-content: flex-end;
& > * + * {
margin-left: 0.35rem;
}
.ui--Button {
white-space: nowrap;
}
}
}
&.relative {
position: relative;