Skip to content

Commit

Permalink
move banner to top of page
Browse files Browse the repository at this point in the history
  • Loading branch information
ngundotra committed Nov 10, 2024
1 parent 7d8123b commit e060eec
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
4 changes: 1 addition & 3 deletions app/components/LiveTransactionStatsCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ export function LiveTransactionStatsCard() {
<div className="card-header">
<h4 className="card-header-title">Live Transaction Stats</h4>
</div>

<TpsCardBody series={series} setSeries={setSeries} />
<PingStatsCardBody series={series} setSeries={setSeries} />
</div>
Expand Down Expand Up @@ -275,9 +276,6 @@ function PingStatsCardBody({ series, setSeries }: { series: Series; setSeries: S

return (
<>
<div className="alert alert-warning m-2" role="alert">
Note: We are aware of an issue with ping statistic reporting. They may not reflect actual network performance. Please see https://validators.app
</div>
<PingBarChart pingInfo={pingInfo} series={series} setSeries={setSeries} />
</>
);
Expand Down
16 changes: 15 additions & 1 deletion app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,17 @@ export default function Page() {
<StatsProvider>
<SupplyProvider>
<div className="container mt-4">
<div className="alert alert-warning m-2" role="alert">
Note: We are aware of an issue with ping statistic reporting. Ping statistics may not reflect
actual network performance. Please see{' '}
<a
href="https://www.validators.app/ping-thing?locale=en&network=mainnet"
className="text-white text-decoration-underline"
>
validators.app
</a>{' '}
for more information.
</div>
<StakingComponent />
<div className="card">
<div className="card-header">
Expand Down Expand Up @@ -71,7 +82,10 @@ function StakingComponent() {

const activeStake = React.useMemo(() => {
if (voteAccounts && delinquentStake) {
return voteAccounts.current.reduce((prev, current) => prev + current.activatedStake, BigInt(0)) + delinquentStake;
return (
voteAccounts.current.reduce((prev, current) => prev + current.activatedStake, BigInt(0)) +
delinquentStake
);
}
}, [voteAccounts, delinquentStake]);

Expand Down

0 comments on commit e060eec

Please sign in to comment.