Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Add delimiter #1174

Merged
merged 7 commits into from
Dec 17, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions packages/profile/src/components/inventory/token/send.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,17 @@ export function SendToken() {
<FormLabel>Amount</FormLabel>
<div className="flex items-center gap-2">
<FormLabel>Balance:</FormLabel>
<div className="text-xs">
{t.balance.formatted} {t.meta.symbol}
<div
className="text-xs cursor-pointer hover:underline"
onClick={() =>
form.setValue(
"amount",
parseFloat(t.balance.formatted),
)
}
>
{parseFloat(t.balance.formatted).toLocaleString()}{" "}
{t.meta.symbol}
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion packages/profile/src/components/inventory/token/token.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ function ERC20() {
t.balance === undefined ? (
<Skeleton className="h-[20px] w-[120px] rounded" />
) : (
t.balance.formatted
parseFloat(t.balance.formatted).toLocaleString()
)
} ${t.meta.symbol}`}
description={countervalue && `${countervalue.formatted} (USD)`}
Expand Down
8 changes: 5 additions & 3 deletions packages/profile/src/components/inventory/token/tokens.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,14 @@ function TokenCardContent({

<div className="bg-secondary flex flex-1 gap-x-1.5 items-center justify-between p-3 text-medium">
<div className="flex items-center gap-2">
<div>{token.balance.formatted}</div>
<div className="text-muted-foreground">{token.meta.symbol}</div>
<p>{parseFloat(token.balance.formatted).toLocaleString()}</p>
<span className="text-muted-foreground">{token.meta.symbol}</span>
</div>

{countervalue && (
<div className="text-muted-foreground">{countervalue.formatted}</div>
<span className="text-muted-foreground">
{countervalue.formatted}
</span>
)}
</div>
</CardContent>
Expand Down
Loading