Skip to content

Commit

Permalink
feat: add hash of transaction and round amounts to 5
Browse files Browse the repository at this point in the history
Adds hash to the title of timestamp, rounds transaction amounts to 5 digits.
  • Loading branch information
martinkyselak committed Jan 4, 2024
1 parent a6aff9b commit cf94533
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/WalletFound.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,10 @@ export function WalletFound({ walletData }: Props) {
<li key={transaction.hash} className="py-3">
<div className="flex items-center space-x-4">
<div className="flex-1 min-w-0">
<p className="text-sm font-medium text-gray-900 truncate">
<p
className="text-sm font-medium text-gray-900 truncate"
title={'Hash: ' + transaction.hash}
>
{new Date(transaction.timestamp).toLocaleString()}
</p>
<p className="text-sm text-gray-500 truncate" title="Block #">
Expand All @@ -46,7 +49,7 @@ export function WalletFound({ walletData }: Props) {
className="inline-flex items-center text-base font-semibold text-gray-900"
title={'\u039E ' + transaction.amount}
>
{'\u039E ' + parseFloat(transaction.amount).toFixed(2)}
{'\u039E ' + parseFloat(transaction.amount).toFixed(5)}
</div>
</div>
</li>
Expand Down

0 comments on commit cf94533

Please sign in to comment.