diff --git a/packages/features/src/common/components/MinaIcon.tsx b/packages/features/src/common/components/MinaIcon.tsx new file mode 100644 index 00000000..05e47646 --- /dev/null +++ b/packages/features/src/common/components/MinaIcon.tsx @@ -0,0 +1,16 @@ +export const MinaIcon = ({ stroke = '2', size = '20', className = '' }) => ( + + + +) diff --git a/packages/features/src/common/types.ts b/packages/features/src/common/types.ts index 0a3245bb..68f7e1ee 100644 --- a/packages/features/src/common/types.ts +++ b/packages/features/src/common/types.ts @@ -21,6 +21,7 @@ export type StructurizedTransaction = Mina.TransactionBody & { date: string time: string minaAmount: number + minaFee: number } type StakingAccount = { diff --git a/packages/features/src/overview/components/AssetList.tsx b/packages/features/src/overview/components/AssetList.tsx index 855f2696..eda78cd3 100644 --- a/packages/features/src/overview/components/AssetList.tsx +++ b/packages/features/src/overview/components/AssetList.tsx @@ -4,7 +4,7 @@ import { useNavigate } from 'react-router-dom' import { Avatar, AvatarFallback } from '@/components/ui/avatar' import { Skeleton } from '@/components/ui/skeleton' -import MinaLogo from '../../common/assets/mina.svg' +import { MinaIcon } from '../../common/components/MinaIcon' import { ViewHeading } from '../../common/components/ViewHeading' import { useAccount } from '../../common/hooks/useAccount' @@ -27,8 +27,8 @@ export const AssetList = () => { ) : (
- - + +

MINA

diff --git a/packages/features/src/send/components/ConfirmTransactionForm.tsx b/packages/features/src/send/components/ConfirmTransactionForm.tsx index 3cd5079a..620036e0 100644 --- a/packages/features/src/send/components/ConfirmTransactionForm.tsx +++ b/packages/features/src/send/components/ConfirmTransactionForm.tsx @@ -46,7 +46,7 @@ export const ConfirmTransactionForm = () => { const kind = useTransactionStore((state) => state.kind) const { addPendingTransaction } = usePendingTransactionStore() if (!outgoingTransaction) return null - const rawAmount = parseInt(outgoingTransaction.amount || '0') + const rawAmount = parseFloat(outgoingTransaction.amount || '0.00') const rawFee = parseFloat(outgoingTransaction.fee || '0.01') const amount = BigInt(rawAmount * 1_000_000_000).toString() const fee = BigInt(rawFee * 1_000_000_000).toString() diff --git a/packages/features/src/transactions/components/TxTile.tsx b/packages/features/src/transactions/components/TxTile.tsx index b95dc58e..b8c4ec30 100644 --- a/packages/features/src/transactions/components/TxTile.tsx +++ b/packages/features/src/transactions/components/TxTile.tsx @@ -1,5 +1,7 @@ import { useNavigate } from 'react-router-dom' +import { MinaIcon } from '@/common/components/MinaIcon' + import { StructurizedTransaction, TxKind, TxSide } from '../../common/types' import { TxIndicator } from './TxIndicator' @@ -31,7 +33,17 @@ export const TxTile = ({ tx }: TxTileProps) => {
{getTransactionLabel(tx)}
{tx.time}
-
{tx.minaAmount} MINA
+
+
+ {tx.minaAmount} + +
+
+ {tx.minaFee} + + Fee +
+
) } diff --git a/packages/features/src/transactions/utils/structurizeTransactions.ts b/packages/features/src/transactions/utils/structurizeTransactions.ts index 57954631..d6e4206c 100644 --- a/packages/features/src/transactions/utils/structurizeTransactions.ts +++ b/packages/features/src/transactions/utils/structurizeTransactions.ts @@ -19,7 +19,8 @@ export const structurizeTransaction = ({ ...tx, date: dateFromNow({ dateTime: tx.dateTime! }), time: dayjs(tx.dateTime).format('HH:mm'), - minaAmount: tx.amount / 1_000_000_000, + minaAmount: (Number(tx.amount) / 1_000_000_000).toFixed(3), + minaFee: (Number(tx.fee) / 1_000_000_000).toFixed(3), side: tx.from === walletPublicKey ? TxSide.OUTGOING : TxSide.INCOMING })