From c2331897593e1a4c95dbfdb65007bfe58a57136a Mon Sep 17 00:00:00 2001 From: Matt Upham <30577966+mattupham@users.noreply.github.com> Date: Fri, 9 Aug 2024 13:10:00 -0700 Subject: [PATCH] Clean up type --- .../recent-activity/recent-activity-transaction-row.tsx | 4 ++-- packages/web/components/transactions/transaction-row.tsx | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/web/components/transactions/recent-activity/recent-activity-transaction-row.tsx b/packages/web/components/transactions/recent-activity/recent-activity-transaction-row.tsx index b45bbad580..344fcd624b 100644 --- a/packages/web/components/transactions/recent-activity/recent-activity-transaction-row.tsx +++ b/packages/web/components/transactions/recent-activity/recent-activity-transaction-row.tsx @@ -1,7 +1,7 @@ import { FunctionComponent } from "react"; import { FallbackImg, Icon } from "~/components/assets"; -import { TransactionRowTransaction } from "~/components/transactions/transaction-row"; +import { TransactionRow } from "~/components/transactions/transaction-row"; import { displayFiatPrice } from "~/components/transactions/transaction-utils"; import { useTranslation } from "~/hooks"; @@ -21,7 +21,7 @@ export const RecentActivityRow: FunctionComponent<{ ); }; -export const SwapRow: FunctionComponent = ({ +export const SwapRow: FunctionComponent = ({ status, title, tokenConversion, diff --git a/packages/web/components/transactions/transaction-row.tsx b/packages/web/components/transactions/transaction-row.tsx index accbad8a72..b4d041f033 100644 --- a/packages/web/components/transactions/transaction-row.tsx +++ b/packages/web/components/transactions/transaction-row.tsx @@ -14,7 +14,7 @@ export type TransactionStatus = "pending" | "success" | "failed"; type Effect = "swap" | "deposit" | "withdraw"; -export interface TransactionRowTransaction { +export interface TransactionRow { isSelected?: boolean; status: TransactionStatus; /** At a high level- what this transaction does. */ @@ -41,7 +41,7 @@ export interface TransactionRowTransaction { onClick?: () => void; } -export const TransactionRow: FunctionComponent = ({ +export const TransactionRow: FunctionComponent = ({ isSelected = false, status, effect, @@ -127,7 +127,7 @@ export const TransactionRow: FunctionComponent = ({ /** UI for displaying one token being converted into another by this transaction. */ const TokenConversion: FunctionComponent< { status: TransactionStatus; effect: Effect } & NonNullable< - TransactionRowTransaction["tokenConversion"] + TransactionRow["tokenConversion"] > > = ({ status, tokenIn, tokenOut, effect }) => { const { t } = useTranslation(); @@ -199,7 +199,7 @@ const TokenConversion: FunctionComponent< export const TokenTransfer: FunctionComponent< { status: TransactionStatus; - } & NonNullable + } & NonNullable > = ({ status, direction, amount, value }) => (