+
{txData.tokenTransfers.map((t, i) => (
-
+
))}
diff --git a/src/transaction/Logs.tsx b/src/transaction/Logs.tsx
index eda12be..f965ecc 100644
--- a/src/transaction/Logs.tsx
+++ b/src/transaction/Logs.tsx
@@ -1,6 +1,6 @@
import React from "react";
import ContentFrame from "../ContentFrame";
-import AddressLink from "../components/AddressLink";
+import DecoratedAddressLink from "../components/DecoratedAddressLink";
import { TransactionData } from "../types";
type LogsProps = {
@@ -22,7 +22,12 @@ const Logs: React.FC
= ({ txData }) => (
{l.topics.map((t, i) => (
@@ -45,6 +50,7 @@ const Logs: React.FC = ({ txData }) => (
diff --git a/src/types.ts b/src/types.ts
index 9ee8d3d..29cc6bc 100644
--- a/src/types.ts
+++ b/src/types.ts
@@ -57,12 +57,26 @@ export type TransactionData = {
logs: ethers.providers.Log[];
};
+// The VOID...
+export const ZERO_ADDRESS = "0x0000000000000000000000000000000000000000";
+
+export enum AddressContext {
+ FROM,
+ TO,
+}
+
export type From = {
current: string;
depth: number;
};
+export enum TransferType {
+ TRANSFER = 0,
+ SELF_DESTRUCT = 1,
+}
+
export type Transfer = {
+ type: TransferType;
from: string;
to: string;
value: BigNumber;
diff --git a/src/useErigonHooks.ts b/src/useErigonHooks.ts
new file mode 100644
index 0000000..447408c
--- /dev/null
+++ b/src/useErigonHooks.ts
@@ -0,0 +1,30 @@
+import { ethers } from "ethers";
+import { useState, useEffect } from "react";
+import { getTransactionTransfers } from "./nodeFunctions";
+import { TransactionData, Transfer } from "./types";
+
+export const useInternalTransfers = (
+ provider: ethers.providers.JsonRpcProvider | undefined,
+ txData: TransactionData | undefined
+): Transfer[] | undefined => {
+ const [intTransfers, setIntTransfers] = useState