* feat: added Buy/Sell token ratio to the TradingView header * fix: changed the order in the trading view description * feat: added minute timeframe to the chart * fix: changed WBTC to WBTC/USD pyth price feed * fix: adjusted HLS health curve * fix: made HLS accounts unselectable * copy: changed the APY range and Strategy text * tidy: fix the tables layout to be more readable * fix: change the precision of the Trading chart header * feat: added summary collapsable * fix: removed Debt Column for active HLS positions * fix: added Memo to TVChart * fix: adjust Trade page layout * tidy: refactor table meta * fix: DisplayCurrency is able to take options now * tidy: remove unneeded typesafety * fix: adjusted according feedback * env: enabled autoRepay and updated version
28 lines
585 B
TypeScript
28 lines
585 B
TypeScript
import { FormattedNumber } from 'components/FormattedNumber'
|
|
import Loading from 'components/Loading'
|
|
|
|
export const BORROW_RATE_META = {
|
|
accessorKey: 'borrowRate',
|
|
header: 'Borrow Rate APY',
|
|
meta: { className: 'w-40' },
|
|
}
|
|
|
|
interface Props {
|
|
borrowRate: number | null
|
|
}
|
|
|
|
export default function BorrowRate(props: Props) {
|
|
if (props.borrowRate === null) {
|
|
return <Loading />
|
|
}
|
|
|
|
return (
|
|
<FormattedNumber
|
|
className='justify-end text-xs'
|
|
amount={props.borrowRate}
|
|
options={{ minDecimals: 2, maxDecimals: 2, suffix: '%' }}
|
|
animate
|
|
/>
|
|
)
|
|
}
|