mango-ui-v3/components/MarketFee.tsx

23 lines
644 B
TypeScript
Raw Normal View History

2021-10-01 09:21:09 -07:00
import useFees from '../hooks/useFees'
2021-08-18 07:33:03 -07:00
import { percentFormat } from '../utils'
import { useTranslation } from 'next-i18next'
2021-08-17 12:37:07 -07:00
export default function MarketFee() {
const { t } = useTranslation('common')
2021-10-01 09:21:09 -07:00
const { takerFee, makerFee } = useFees()
2021-08-17 12:37:07 -07:00
return (
<div className="mt-2.5 flex px-6 text-xs text-th-fgd-4">
<div className="mx-auto block text-center sm:flex">
<div>
{t('maker-fee')}: {percentFormat.format(makerFee)}
</div>
<div className="hidden px-2 sm:block">|</div>
<div>
{t('taker-fee')}: {percentFormat.format(takerFee)}
</div>
2021-10-01 08:32:15 -07:00
</div>
2021-08-17 12:37:07 -07:00
</div>
)
}