forked from BIG-Labs/alliance-dashboard
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from terra-money/feat/whale/alliance/hub
feat: add whale alliance hub
- Loading branch information
Showing
42 changed files
with
3,384 additions
and
873 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { Tooltip } from '@nextui-org/react'; | ||
import LoadingComponent from './LoadingComponent'; | ||
|
||
export interface KpiData { | ||
id: number; | ||
name: string; | ||
symbol: string; | ||
token: string; | ||
} | ||
|
||
export default function Kpi({ kpi, data }: { kpi: KpiData, data?: any }) { | ||
return ( | ||
<div className="flex custom_card gap-3"> | ||
<LoadingComponent isLoading={data === undefined} values={data}> | ||
<div className='flex items-center'> | ||
<Tooltip content={kpi.name}> | ||
<img | ||
src={kpi.symbol} | ||
alt='Coin image' | ||
width={45} | ||
height={45} | ||
className="object-contain" | ||
/> | ||
</Tooltip> | ||
</div> | ||
<div className="flex items-center w-full"> | ||
<h2>${parseFloat(data?.usd ?? '0').toLocaleString('en-US', { | ||
minimumFractionDigits: 4 | ||
})}</h2> | ||
</div> | ||
</LoadingComponent> | ||
</div> | ||
); | ||
} |
Oops, something went wrong.