Skip to content

Commit

Permalink
Activity details loading (#1519)
Browse files Browse the repository at this point in the history
  • Loading branch information
greg-schrammel authored Apr 30, 2024
1 parent 1f33946 commit 2e2915e
Show file tree
Hide file tree
Showing 9 changed files with 199 additions and 211 deletions.
20 changes: 3 additions & 17 deletions src/core/resources/transactions/consolidatedTransactions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ const CONSOLIDATED_TRANSACTIONS_TIMEOUT = 20000;
export type ConsolidatedTransactionsArgs = {
address: Address;
currency: SupportedCurrencyKey;
testnetMode: boolean;
userChainIds: number[];
};

Expand All @@ -37,12 +36,11 @@ export type ConsolidatedTransactionsArgs = {
export const consolidatedTransactionsQueryKey = ({
address,
currency,
testnetMode,
userChainIds,
}: ConsolidatedTransactionsArgs) =>
createQueryKey(
'consolidatedTransactions',
{ address, currency, testnetMode, userChainIds },
{ address, currency, userChainIds },
{ persisterVersion: 1 },
);

Expand All @@ -56,12 +54,7 @@ type ConsolidatedTransactionsQueryKey = ReturnType<
export async function fetchConsolidatedTransactions<
TSelectData = ConsolidatedTransactionsResult,
>(
{
address,
currency,
testnetMode,
userChainIds,
}: ConsolidatedTransactionsArgs,
{ address, currency, userChainIds }: ConsolidatedTransactionsArgs,
config: QueryConfig<
ConsolidatedTransactionsResult,
Error,
Expand All @@ -73,7 +66,6 @@ export async function fetchConsolidatedTransactions<
consolidatedTransactionsQueryKey({
address,
currency,
testnetMode,
userChainIds,
}),
consolidatedTransactionsQueryFunction,
Expand Down Expand Up @@ -153,12 +145,7 @@ async function parseConsolidatedTransactions(
export function useConsolidatedTransactions<
TSelectData = ConsolidatedTransactionsResult,
>(
{
address,
currency,
userChainIds,
testnetMode,
}: ConsolidatedTransactionsArgs,
{ address, currency, userChainIds }: ConsolidatedTransactionsArgs,
config: InfiniteQueryConfig<
ConsolidatedTransactionsResult,
Error,
Expand All @@ -169,7 +156,6 @@ export function useConsolidatedTransactions<
consolidatedTransactionsQueryKey({
address,
currency,
testnetMode,
userChainIds,
}),
consolidatedTransactionsQueryFunction,
Expand Down
Loading

0 comments on commit 2e2915e

Please sign in to comment.