mango-v4-ui/components/trade/PerpSideBadge.tsx

16 lines
317 B
TypeScript
Raw Normal View History

2022-11-01 06:10:08 -07:00
import SideBadge from '@components/shared/SideBadge'
2023-01-16 19:50:20 -08:00
const PerpSideBadge = ({ basePosition }: { basePosition: number }) => {
return (
<>
{basePosition !== 0 ? (
<SideBadge side={basePosition > 0 ? 'long' : 'short'} />
) : (
'--'
)}
</>
)
}
2022-11-01 06:10:08 -07:00
export default PerpSideBadge