make bet panel smaller
This commit is contained in:
parent
e0b1470814
commit
606e9b2f21
|
@ -150,8 +150,7 @@ export function BetPanelSwitcher(props: {
|
||||||
<Col
|
<Col
|
||||||
className={clsx(
|
className={clsx(
|
||||||
'rounded-b-md bg-white px-8 py-6',
|
'rounded-b-md bg-white px-8 py-6',
|
||||||
!sharesOutcome && 'rounded-t-md',
|
!sharesOutcome && 'rounded-t-md'
|
||||||
className
|
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<Title
|
<Title
|
||||||
|
|
|
@ -15,8 +15,9 @@ export default function BetRow(props: {
|
||||||
contract: FullContract<DPM | CPMM, Binary>
|
contract: FullContract<DPM | CPMM, Binary>
|
||||||
className?: string
|
className?: string
|
||||||
btnClassName?: string
|
btnClassName?: string
|
||||||
|
betPanelClassName?: string
|
||||||
}) {
|
}) {
|
||||||
const { className, btnClassName, contract } = props
|
const { className, btnClassName, betPanelClassName, contract } = props
|
||||||
const [open, setOpen] = useState(false)
|
const [open, setOpen] = useState(false)
|
||||||
const [betChoice, setBetChoice] = useState<'YES' | 'NO' | undefined>(
|
const [betChoice, setBetChoice] = useState<'YES' | 'NO' | undefined>(
|
||||||
undefined
|
undefined
|
||||||
|
@ -60,6 +61,7 @@ export default function BetRow(props: {
|
||||||
/>
|
/>
|
||||||
<Modal open={open} setOpen={setOpen}>
|
<Modal open={open} setOpen={setOpen}>
|
||||||
<BetPanelSwitcher
|
<BetPanelSwitcher
|
||||||
|
className={betPanelClassName}
|
||||||
contract={contract}
|
contract={contract}
|
||||||
title={contract.question}
|
title={contract.question}
|
||||||
selected={betChoice}
|
selected={betChoice}
|
||||||
|
|
|
@ -115,7 +115,10 @@ function ContractEmbed(props: { contract: Contract; bets: Bet[] }) {
|
||||||
|
|
||||||
{isBinary && (
|
{isBinary && (
|
||||||
<Row className="items-center gap-4">
|
<Row className="items-center gap-4">
|
||||||
<BetRow contract={contract as BinaryContract} />
|
<BetRow
|
||||||
|
contract={contract as BinaryContract}
|
||||||
|
betPanelClassName="scale-75"
|
||||||
|
/>
|
||||||
<BinaryResolutionOrChance contract={contract} />
|
<BinaryResolutionOrChance contract={contract} />
|
||||||
</Row>
|
</Row>
|
||||||
)}
|
)}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user