fix type error
This commit is contained in:
parent
ae68d02e89
commit
124471d26d
|
@ -93,7 +93,7 @@ const Positions = ({
|
|||
<div className="grid grid-cols-1 gap-2">
|
||||
{positions.length ? (
|
||||
positions.map((position, i) => {
|
||||
const {stakeBalance, borrowBalance, bank } = position
|
||||
const { stakeBalance, borrowBalance, bank } = position
|
||||
return bank ? (
|
||||
<div
|
||||
className="rounded-2xl border-2 border-th-fgd-1 bg-th-bkg-1 p-6"
|
||||
|
@ -154,7 +154,9 @@ const Positions = ({
|
|||
<div>
|
||||
<p className="mb-1 text-th-fgd-4">Earned</p>
|
||||
<span className="text-xl font-bold text-th-fgd-1">
|
||||
{balance ? `X.XX ${formatTokenSymbol(bank.name)}` : `0 ${formatTokenSymbol(bank.name)}`}
|
||||
{stakeBalance
|
||||
? `X.XX ${formatTokenSymbol(bank.name)}`
|
||||
: `0 ${formatTokenSymbol(bank.name)}`}
|
||||
</span>
|
||||
</div>
|
||||
<div>
|
||||
|
|
|
@ -28,7 +28,7 @@ const TopBar = () => {
|
|||
<Link href="/" shallow={true}>
|
||||
<div className="flex items-center">
|
||||
<img
|
||||
className="relative h-auto w-10 flex-shrink-0 cursor-pointer"
|
||||
className="relative h-auto w-10 shrink-0 cursor-pointer"
|
||||
src={themeData.logoPath}
|
||||
alt="logo"
|
||||
/>
|
||||
|
@ -46,7 +46,7 @@ const TopBar = () => {
|
|||
</div>
|
||||
{!isOnline ? (
|
||||
<div className="bg-th-down absolute left-1/2 top-3 z-10 flex h-10 w-max -translate-x-1/2 items-center rounded-full px-4 py-2 md:top-8">
|
||||
<ExclamationTriangleIcon className="h-5 w-5 flex-shrink-0 text-th-fgd-1" />
|
||||
<ExclamationTriangleIcon className="h-5 w-5 shrink-0 text-th-fgd-1" />
|
||||
<p className="ml-2 text-th-fgd-1">
|
||||
Your connection appears to be offline
|
||||
</p>
|
||||
|
@ -58,9 +58,15 @@ const TopBar = () => {
|
|||
|
||||
export default TopBar
|
||||
|
||||
const NavLink = (
|
||||
{ active, path, text }: { active: boolean; path: string; text: string },
|
||||
) => {
|
||||
const NavLink = ({
|
||||
active,
|
||||
path,
|
||||
text,
|
||||
}: {
|
||||
active: boolean
|
||||
path: string
|
||||
text: string
|
||||
}) => {
|
||||
return (
|
||||
<Link href={path} shallow={true}>
|
||||
<span
|
||||
|
|
Loading…
Reference in New Issue