move fees into trade box, prevent wrapping in market menu item

This commit is contained in:
Tyler Shipe 2021-11-01 16:20:30 -04:00
parent b49237df50
commit 56b7466799
3 changed files with 6 additions and 42 deletions

View File

@ -94,45 +94,6 @@ const FeeDiscountsTable = () => {
</div>
) : null}
</div>
<div className="pl-10">
<div className="text-center text-lg">{t('perp-fees')}</div>
<div
className={`flex flex-col sm:flex-row justify-between text-th-fgd-4 text-center mt-4`}
>
<div className="px-4 mt-4 sm:mt-0">
<div>{t('maker-fee')}</div>
<div className="text-th-fgd-3 text-normal">
{percentFormat.format(-0.0004)}
</div>
</div>
<div className="px-4 mt-4 sm:mt-0">
<div className="flex items-center">
<div>{t('taker-fee')}</div>
</div>
<div className="text-th-fgd-3 text-normal">
{percentFormat.format(0.0005)}
</div>
</div>
</div>
<div
className={`flex flex-col sm:flex-row justify-between text-th-fgd-4 text-center mt-4`}
>
<div className="px-4 mt-4 sm:mt-0">
<div>FTT {t('maker-fee')}</div>
<div className="text-th-fgd-3 text-normal">
{percentFormat.format(0.0)}
</div>
</div>
<div className="px-4 mt-4 sm:mt-0">
<div className="flex items-center">
<div>FTT {t('taker-fee')}</div>
</div>
<div className="text-th-fgd-3 text-normal">
{percentFormat.format(0.0005)}
</div>
</div>
</div>
</div>
{showDeposit ? (
<DepositMsrmModal
isOpen={showDeposit}

View File

@ -91,7 +91,7 @@ export default function MarketMenuItem({ menuTitle = '', linksArray = [] }) {
key={m.name}
>
<a
className={`block py-2 text-th-fgd-1 text-xs hover:text-th-primary ${
className={`block py-2 text-th-fgd-1 text-xs hover:text-th-primary whitespace-nowrap ${
asPath.includes(menuTitle)
? (asPath.includes('perp') &&
m.name.slice(-4) === 'PERP') ||

View File

@ -56,7 +56,7 @@ export default function AdvancedTradeForm({
const [reduceOnly, setReduceOnly] = useState(false)
const [spotMargin, setSpotMargin] = useState(true)
const [positionSizePercent, setPositionSizePercent] = useState('')
const { takerFee } = useFees()
const { takerFee, makerFee } = useFees()
const { totalMsrm } = useSrmAccount()
const mangoGroup = useMangoStore((s) => s.selectedMangoGroup.current)
@ -832,7 +832,6 @@ export default function AdvancedTradeForm({
<EstPriceImpact priceImpact={priceImpact} />
) : null}
</div>
<div className={`flex pt-4`}>
{ipAllowed ? (
<Button
@ -872,6 +871,10 @@ export default function AdvancedTradeForm({
</Button>
)}
</div>
<div className="flex text-xs text-th-fgd-4 px-6 mt-2.5 justify-center">
Maker fee: {(makerFee * 100).toFixed(2)}% | Taker fee:{' '}
{takerFee * 100}%
</div>
</div>
</div>
</div>