WIP
This commit is contained in:
@@ -137,6 +137,20 @@ export const AccountBalancesCard = (props: IAccountBalancesCardProps) => {
|
||||
Number(accountInfo.total_value.amount),
|
||||
);
|
||||
|
||||
const operatorRewardsAllocation = getAllocation(
|
||||
Number(accountInfo.operator_rewards?.amount || 0),
|
||||
Number(accountInfo.total_value.amount),
|
||||
);
|
||||
|
||||
const operatorRewardsNYM = getNymsFormated(
|
||||
Number(accountInfo.operator_rewards?.amount || 0),
|
||||
);
|
||||
|
||||
const operatorRewardsUSD = getPriceInUSD(
|
||||
Number(accountInfo.operator_rewards?.amount || 0),
|
||||
nymPriceData,
|
||||
);
|
||||
|
||||
const claimableNYM = getNymsFormated(
|
||||
Number(accountInfo.claimable_rewards.amount),
|
||||
);
|
||||
@@ -186,10 +200,10 @@ export const AccountBalancesCard = (props: IAccountBalancesCardProps) => {
|
||||
],
|
||||
},
|
||||
{
|
||||
type: "Self bonded",
|
||||
allocation: 0,
|
||||
amount: 0,
|
||||
value: 0,
|
||||
type: "Operator Rewards",
|
||||
allocation: operatorRewardsAllocation,
|
||||
amount: operatorRewardsNYM,
|
||||
value: operatorRewardsUSD,
|
||||
},
|
||||
];
|
||||
|
||||
|
||||
@@ -97,7 +97,7 @@ const Row = (props: IAccontStatsRowProps) => {
|
||||
}}
|
||||
>
|
||||
<Typography variant="body4" sx={{ color: "pine.950" }}>
|
||||
{amount} NYM
|
||||
{amount.toFixed(4)} NYM
|
||||
</Typography>
|
||||
</TableCell>
|
||||
<TableCell
|
||||
@@ -161,7 +161,7 @@ const Row = (props: IAccontStatsRowProps) => {
|
||||
width: "45%",
|
||||
}}
|
||||
>
|
||||
<Typography>{amount} NYM</Typography>
|
||||
<Typography>{amount.toFixed(4)} NYM</Typography>
|
||||
<Typography>$ {value}</Typography>
|
||||
</TableCell>
|
||||
|
||||
@@ -219,7 +219,7 @@ const Row = (props: IAccontStatsRowProps) => {
|
||||
}}
|
||||
>
|
||||
<Typography variant="body4" sx={{ color: "pine.950" }}>
|
||||
{historyRow.amount} NYM
|
||||
{historyRow.amount.toFixed(4)} NYM
|
||||
</Typography>
|
||||
</TableCell>
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ export const AccountInfoCard = (props: IAccountInfoCardProps) => {
|
||||
|
||||
if (isLoading) {
|
||||
return (
|
||||
<ExplorerCard label="">
|
||||
<ExplorerCard label="Total NYM">
|
||||
<Stack gap={1}>
|
||||
<Skeleton variant="text" height={38} />
|
||||
<Skeleton variant="rectangular" height={128} width={128} />
|
||||
@@ -34,7 +34,7 @@ export const AccountInfoCard = (props: IAccountInfoCardProps) => {
|
||||
|
||||
if (isError || !data) {
|
||||
return (
|
||||
<ExplorerCard label="">
|
||||
<ExplorerCard label="Total NYM">
|
||||
<Typography variant="h5" sx={{ color: "pine.600", letterSpacing: 0.7 }}>
|
||||
Failed to account data.
|
||||
</Typography>
|
||||
@@ -44,14 +44,14 @@ export const AccountInfoCard = (props: IAccountInfoCardProps) => {
|
||||
}
|
||||
|
||||
const balance =
|
||||
data.balances.length > 0 ? Number(data.balances[0].amount) / 1000000 : 0;
|
||||
const balanceFormated = `${balance} NYM`;
|
||||
data.balances.length > 0 ? Number(data.total_value.amount) / 1000000 : 0;
|
||||
const balanceFormated = `${balance.toFixed(4)} NYM`;
|
||||
|
||||
return (
|
||||
<ExplorerCard
|
||||
label=""
|
||||
label="Total NYM"
|
||||
title={balanceFormated}
|
||||
sx={{ height: "100%", pt: 0 }}
|
||||
sx={{ height: "100%" }}
|
||||
>
|
||||
<Stack gap={5}>
|
||||
<Box display={"flex"} justifyContent={"flex-start"}>
|
||||
|
||||
@@ -14,7 +14,8 @@ import { FooterLinks } from "./footer-links";
|
||||
export async function Footer() {
|
||||
const locale = "en";
|
||||
const footerData = await getFooter(locale);
|
||||
const legalContent1 = footerData?.attributes?.legalContent1 || false;
|
||||
const legalContent1 =
|
||||
"Nym Noise Generating Mixnet Explorer, V 2.1.0 Public Beta release.";
|
||||
const legalContent2 = footerData?.attributes?.legalContent2 || false;
|
||||
const footerLinkBlocks = footerData?.attributes?.linkBlocks || [];
|
||||
|
||||
@@ -26,19 +27,9 @@ export async function Footer() {
|
||||
title: "nym.com Privacy statement",
|
||||
url: "https://nym.com/nym-com-privacy-statement",
|
||||
},
|
||||
{ id: 3, title: "NymVPN Terms of use", url: "https://nym.com/vpn-terms" },
|
||||
{ id: 3, title: "Nym Docs", url: "https://nym.com/docs" },
|
||||
{
|
||||
id: 4,
|
||||
title: "NymVPN referrals Terms",
|
||||
url: "https://nym.com/referrals-terms-and-conditions",
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
title: "NymVPN apps Privacy statement",
|
||||
url: "https://nym.com/vpn-privacy-statement",
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
title: "Nym Operators and Validators Terms",
|
||||
url: "https://nym.com/operators-validators-terms",
|
||||
},
|
||||
|
||||
@@ -66,7 +66,7 @@ export const TokenomicsCard = () => {
|
||||
}
|
||||
|
||||
const nymPriceData: NymTokenomics = nymPrice;
|
||||
const nymPriceDataFormated = Number(nymPriceData.quotes.USD.price.toFixed(2));
|
||||
const nymPriceDataFormated = Number(nymPriceData.quotes.USD.price.toFixed(4));
|
||||
|
||||
const titlePrice = {
|
||||
price: nymPriceDataFormated,
|
||||
|
||||
Reference in New Issue
Block a user