diff --git a/.changeset/stale-suits-share.md b/.changeset/stale-suits-share.md
new file mode 100644
index 0000000..df6cdb2
--- /dev/null
+++ b/.changeset/stale-suits-share.md
@@ -0,0 +1,5 @@
+---
+'minotaur-wallet': minor
+---
+
+Add Transaction Display page
diff --git a/apps/wallet/src/components/tx/TxDisplay.tsx b/apps/wallet/src/components/tx/TxDisplay.tsx
index c3ceef1..2f4bed1 100644
--- a/apps/wallet/src/components/tx/TxDisplay.tsx
+++ b/apps/wallet/src/components/tx/TxDisplay.tsx
@@ -1,13 +1,12 @@
import { openTxInBrowser } from '@/action/tx';
import ErgAmount from '@/components/amounts-display/ErgAmount';
-import IssuedBurntTokenAmount from '@/components/token-amount/IssuedBurntTokenAmount';
import useIssuedAndBurntTokens from '@/hooks/useIssuedAndBurntTokens';
import useTxValues from '@/hooks/useTxValues';
import TxAssetDetail from '@/pages/wallet-page/transaction/TxAssetDetail';
import { StateWallet } from '@/store/reducer/wallet';
import { getValueColor } from '@/utils/functions';
import { OpenInNew } from '@mui/icons-material';
-import { IconButton, Stack, Typography } from '@mui/material';
+import { IconButton, Typography } from '@mui/material';
import React from 'react';
import * as wasm from 'ergo-lib-wasm-browser';
@@ -20,7 +19,7 @@ interface TxDisplayPropsType {
const TxDisplay = ({ tx, boxes, wallet, date }: TxDisplayPropsType) => {
const txId = tx.id().to_str();
- const issuedAndBurnt = useIssuedAndBurntTokens(tx, boxes);
+ const { mapped } = useIssuedAndBurntTokens(tx, boxes);
const { txValues } = useTxValues(tx, boxes, wallet);
const openTx = () => openTxInBrowser(wallet.networkType, txId ?? '');
return (
@@ -58,49 +57,22 @@ const TxDisplay = ({ tx, boxes, wallet, date }: TxDisplayPropsType) => {
{Object.entries(txValues.tokens).map((item) => (
-
- ))}
- {issuedAndBurnt.burnt.length > 0 ? (
-
- Burnt tokens
-
-
- {issuedAndBurnt.burnt.map((item) => (
-
- ))}
-
+
+
- ) : null}
- {issuedAndBurnt.issued.length > 0 ? (
-
-
- Issued tokens
-
-
- {issuedAndBurnt.issued.map((item) => (
-
- ))}
-
-
- ) : null}
+ ))}
);
};
diff --git a/apps/wallet/src/hooks/useIssuedAndBurntTokens.ts b/apps/wallet/src/hooks/useIssuedAndBurntTokens.ts
index a314480..fece8e2 100644
--- a/apps/wallet/src/hooks/useIssuedAndBurntTokens.ts
+++ b/apps/wallet/src/hooks/useIssuedAndBurntTokens.ts
@@ -19,6 +19,9 @@ const useIssuedAndBurntTokens = (
tx: wasm.UnsignedTransaction | wasm.Transaction | undefined,
boxes: Array,
) => {
+ const [mapped, setMapped] = useState