linting
This commit is contained in:
parent
c0124a558f
commit
aed48dfb22
|
@ -80,9 +80,8 @@ export default function BetButton(props: {
|
||||||
|
|
||||||
export function BinaryMobileBetting(props: {
|
export function BinaryMobileBetting(props: {
|
||||||
contract: CPMMBinaryContract | Contract
|
contract: CPMMBinaryContract | Contract
|
||||||
className?: string
|
|
||||||
}) {
|
}) {
|
||||||
const { contract, className } = props
|
const { contract } = props
|
||||||
const user = useUser()
|
const user = useUser()
|
||||||
if (user) {
|
if (user) {
|
||||||
return (
|
return (
|
||||||
|
@ -104,7 +103,7 @@ export function SignedInBinaryMobileBetting(props: {
|
||||||
user: User
|
user: User
|
||||||
}) {
|
}) {
|
||||||
const { contract, user } = props
|
const { contract, user } = props
|
||||||
const [betChoice, setBetChoice] = useState<'YES' | 'NO' | undefined>(
|
const [betChoice, _setBetChoice] = useState<'YES' | 'NO' | undefined>(
|
||||||
undefined
|
undefined
|
||||||
)
|
)
|
||||||
const unfilledBets = useUnfilledBets(contract.id) ?? []
|
const unfilledBets = useUnfilledBets(contract.id) ?? []
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import clsx from 'clsx'
|
import clsx from 'clsx'
|
||||||
import React, { useState } from 'react'
|
import React, { useState } from 'react'
|
||||||
import { clamp, floor, partition, sumBy } from 'lodash'
|
import { clamp, partition, sumBy } from 'lodash'
|
||||||
|
|
||||||
import { useUser } from 'web/hooks/use-user'
|
import { useUser } from 'web/hooks/use-user'
|
||||||
import { CPMMBinaryContract, PseudoNumericContract } from 'common/contract'
|
import { CPMMBinaryContract, PseudoNumericContract } from 'common/contract'
|
||||||
|
@ -174,21 +174,11 @@ export function BuyPanel(props: {
|
||||||
user: User | null | undefined
|
user: User | null | undefined
|
||||||
unfilledBets: Bet[]
|
unfilledBets: Bet[]
|
||||||
hidden: boolean
|
hidden: boolean
|
||||||
selected?: 'YES' | 'NO'
|
|
||||||
onBuySuccess?: () => void
|
onBuySuccess?: () => void
|
||||||
onAdvanced?: () => void
|
|
||||||
mobileView?: boolean
|
mobileView?: boolean
|
||||||
}) {
|
}) {
|
||||||
const {
|
const { contract, user, unfilledBets, hidden, onBuySuccess, mobileView } =
|
||||||
contract,
|
props
|
||||||
user,
|
|
||||||
unfilledBets,
|
|
||||||
hidden,
|
|
||||||
selected,
|
|
||||||
onBuySuccess,
|
|
||||||
onAdvanced,
|
|
||||||
mobileView,
|
|
||||||
} = props
|
|
||||||
|
|
||||||
const initialProb = getProbability(contract)
|
const initialProb = getProbability(contract)
|
||||||
const isPseudoNumeric = contract.outcomeType === 'PSEUDO_NUMERIC'
|
const isPseudoNumeric = contract.outcomeType === 'PSEUDO_NUMERIC'
|
||||||
|
|
Loading…
Reference in New Issue
Block a user