Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions apps/api/src/api/services/quote/core/squidrouter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,6 @@ export function getTokenDetailsForEvmDestination(
});
}

console.log("Getting token details for:", finalOutputCurrency, "on network:", network);

const tokenDetails = getOnChainTokenDetails(network, finalOutputCurrency);

if (!tokenDetails || !isEvmTokenDetails(tokenDetails)) {
Expand Down
1 change: 0 additions & 1 deletion apps/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@
"react-hook-form": "^7.65.0",
"react-i18next": "^15.4.1",
"react-toastify": "^11.0.5",
"react-window": "^2.2.5",
"stellar-sdk": "catalog:",
"tailwind-merge": "^3.1.0",
"tailwindcss": "^4.0.3",
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/constants/animations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ export const easings = {
* Duration guidelines for different interaction types
*/
export const durations = {
micro: 0.1, // 100ms - micro-interactions (hover states)
fast: 0.15, // 150ms - tooltips, dropdowns
micro: 0.1, // 100ms - micro-interactions (hover states)
normal: 0.2, // 200ms - standard UI animations
slow: 0.3 // 300ms - modals, drawers, complex transitions
};
Expand Down
12 changes: 5 additions & 7 deletions apps/frontend/src/hooks/useOnchainTokenBalances.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,17 @@ import {
} from "@vortexfi/shared";
import Big from "big.js";
import { useEffect, useMemo, useState } from "react";
import { Abi, hexToBigInt } from "viem";

// Global cache to persist balances across hook instances and app lifecycle
const globalBalanceCache = new Map<string, Map<string, string>>();

import { useBalance, useReadContracts } from "wagmi";
import { hexToBigInt } from "viem";
import { useBalance } from "wagmi";
import { useNetwork } from "../contexts/network";
import { useAssetHubNode } from "../contexts/polkadotNode";
import erc20ABI from "../contracts/ERC20";
import { multiplyByPowerOfTen } from "../helpers/contracts";
import { getEvmTokensForNetwork } from "../services/tokens";
import { useVortexAccount } from "./useVortexAccount";

// Global cache to persist balances across hook instances and app lifecycle
const globalBalanceCache = new Map<string, Map<string, string>>();

interface AlchemyTokenBalancesResponse {
data: {
tokens: {
Expand Down
3 changes: 2 additions & 1 deletion apps/frontend/src/hooks/useOnchainTokenBalancesSorted.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ export const useOnchainTokenBalancesSorted = (tokens: OnChainTokenDetails[]): On
return bBalance - aBalance;
}

return 1;
// Tie-breaker: sort by symbol alphabetically
return a.assetSymbol.localeCompare(b.assetSymbol);
});
}, [tokenBalances]);
};
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@
"dependencies": {
"big.js": "^7.0.1",
"husky": "^9.1.7",
"lint-staged": "^16.1.0",
"react-window": "^2.2.5"
"lint-staged": "^16.1.0"
},
"devDependencies": {
"@biomejs/biome": "2.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/shared/.prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
./packages/shared/src/tokens/index.ts
src/tokens/index.ts
5 changes: 3 additions & 2 deletions packages/shared/src/tokens/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ export * from "./constants/misc";
// Constants
// Configurations
export * from "./evm/config";
// Dynamic tokens - must be exported AFTER all dependencies (config, pendulum/config, etc.)
export * from "./evm/dynamicEvmTokens";
export * from "./moonbeam/config";
export * from "./pendulum/config";
export * from "./stellar/config";
Expand All @@ -26,3 +24,6 @@ export * from "./utils/helpers";
export * from "./utils/normalization";
// Utils
export * from "./utils/typeGuards";
// Dynamic tokens - must be exported AFTER all dependencies (config, pendulum/config, etc.)
export * from "./evm/dynamicEvmTokens";
/* prettier-ignore-end */
2 changes: 1 addition & 1 deletion packages/shared/src/tokens/types/evm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,5 @@ export interface EvmTokenDetails extends BaseTokenDetails {

export interface EvmTokenDetailsWithBalance extends EvmTokenDetails {
balance: string;
balanceUsd?: string;
balanceUsd: string;
}
2 changes: 1 addition & 1 deletion packages/shared/src/tokens/utils/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { getEvmTokenConfig } from "../evm/dynamicEvmTokens";
import { moonbeamTokenConfig } from "../moonbeam/config";
import { stellarTokenConfig } from "../stellar/config";
import { AssetHubToken, FiatToken, OnChainToken, RampCurrency } from "../types/base";
import { EvmToken, EvmTokenDetails } from "../types/evm";
import { EvmTokenDetails } from "../types/evm";
import { MoonbeamTokenDetails } from "../types/moonbeam";
import { PendulumTokenDetails } from "../types/pendulum";
import { StellarTokenDetails } from "../types/stellar";
Expand Down