fix styling of forwards
This commit is contained in:
parent
c3498be5ba
commit
79b58600e9
@ -4,6 +4,7 @@ import InputGroup from 'react-bootstrap/InputGroup'
|
|||||||
import { BOOST_MIN, MAX_FORWARDS } from '../lib/constants'
|
import { BOOST_MIN, MAX_FORWARDS } from '../lib/constants'
|
||||||
import Info from './info'
|
import Info from './info'
|
||||||
import { numWithUnits } from '../lib/format'
|
import { numWithUnits } from '../lib/format'
|
||||||
|
import styles from './adv-post-form.module.css'
|
||||||
|
|
||||||
const EMPTY_FORWARD = { nym: '', pct: '' }
|
const EMPTY_FORWARD = { nym: '', pct: '' }
|
||||||
|
|
||||||
@ -61,7 +62,7 @@ export default function AdvPostForm ({ edit }) {
|
|||||||
name={`forward[${index}].nym`}
|
name={`forward[${index}].nym`}
|
||||||
prepend={<InputGroup.Text>@</InputGroup.Text>}
|
prepend={<InputGroup.Text>@</InputGroup.Text>}
|
||||||
showValid
|
showValid
|
||||||
groupClassName='flex-grow-1 me-3 mb-0'
|
groupClassName={`${styles.name} me-3 mb-0`}
|
||||||
/>
|
/>
|
||||||
<Input
|
<Input
|
||||||
name={`forward[${index}].pct`}
|
name={`forward[${index}].pct`}
|
||||||
@ -69,10 +70,8 @@ export default function AdvPostForm ({ edit }) {
|
|||||||
step={5}
|
step={5}
|
||||||
min={1}
|
min={1}
|
||||||
max={100}
|
max={100}
|
||||||
style={{ minWidth: '3.5rem' }}
|
|
||||||
append={<InputGroup.Text className='text-monospace'>%</InputGroup.Text>}
|
append={<InputGroup.Text className='text-monospace'>%</InputGroup.Text>}
|
||||||
groupClassName='mb-0'
|
groupClassName={`${styles.percent} mb-0`}
|
||||||
inputGroupClassName='flex-nowrap'
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
11
components/adv-post-form.module.css
Normal file
11
components/adv-post-form.module.css
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
.name {
|
||||||
|
display: flex;
|
||||||
|
flex: 1 1 60%;
|
||||||
|
height: fit-content;
|
||||||
|
flex-flow: column;
|
||||||
|
}
|
||||||
|
|
||||||
|
.percent {
|
||||||
|
display: flex;
|
||||||
|
flex: 0 1 fit-content;
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user