diff --git a/next.config.mjs b/next.config.mjs index bb1bbf8..cf09ada 100644 --- a/next.config.mjs +++ b/next.config.mjs @@ -6,14 +6,14 @@ const nextConfig = { exclude: ['error', 'warn'], }, }, - async rewrites() { - return [ - { - source: '/rpc-api', - destination: 'https://rpc.nethermind.io/mainnet-juno?apikey=t1HPjhplOyEQpxqVMhpwLGuwmOlbXN0XivWUiPAxIBs0kHVK', - }, - ] - }, + // async rewrites() { + // return [ + // { + // source: '/rpc-api', + // destination: 'https://rpc.nethermind.io/mainnet-juno?apikey=t1HPjhplOyEQpxqVMhpwLGuwmOlbXN0XivWUiPAxIBs0kHVK', + // }, + // ] + // }, }; export default nextConfig; diff --git a/src/app/strategy/page.tsx b/src/app/strategy/page.tsx index 93ba38d..c24343a 100644 --- a/src/app/strategy/page.tsx +++ b/src/app/strategy/page.tsx @@ -43,6 +43,8 @@ export default function Strategy() { mixpanel.track('Strategy page open', {name: searchParams.get('name')}) }, []) + const colSpan1: any = {base: '5', md: '3'} + const colSpan2: any = {base: '5', md: '2'} return ( @@ -51,7 +53,7 @@ export default function Strategy() { {strategy && - + @@ -79,7 +81,7 @@ export default function Strategy() { - + diff --git a/src/app/template.tsx b/src/app/template.tsx index 14d4a08..bb7168d 100644 --- a/src/app/template.tsx +++ b/src/app/template.tsx @@ -98,7 +98,7 @@ export default function Template({ children }: { children: React.ReactNode }) { const chains = [sepolia]; const provider = jsonRpcProvider({ rpc: (chain) => { - let args: RpcProviderOptions = {nodeUrl: 'http://localhost:3000/rpc-api', chainId: constants.StarknetChainId.SN_MAIN }; + let args: RpcProviderOptions = {nodeUrl: 'https://rpc.nethermind.io/mainnet-juno?apikey=t1HPjhplOyEQpxqVMhpwLGuwmOlbXN0XivWUiPAxIBs0kHVK', chainId: constants.StarknetChainId.SN_MAIN }; return args; } }); diff --git a/src/components/Deposit.tsx b/src/components/Deposit.tsx index 5a11277..4806ad7 100644 --- a/src/components/Deposit.tsx +++ b/src/components/Deposit.tsx @@ -36,8 +36,8 @@ export default function Deposit(props: DepositProps) { console.log('hookkkAmount', amount.toEtherStr(), calls) }, [amount, calls]) - function getBalanceComponent(token: TokenInfo) { - const { balance, isLoading, isError} = useERC20Balance(token); + function BalanceComponent(props: {token: TokenInfo}) { + const { balance, isLoading, isError} = useERC20Balance(props.token); return Available balance: - {balance.toEtherToFixedDecimals(token.displayDecimals)} + {balance.toEtherToFixedDecimals(props.token.displayDecimals)} } @@ -77,7 +77,7 @@ export default function Deposit(props: DepositProps) { - {getBalanceComponent(selectedMarket)} + diff --git a/src/strategies/simple.stable.strat.ts b/src/strategies/simple.stable.strat.ts index 15d1345..d809ba2 100644 --- a/src/strategies/simple.stable.strat.ts +++ b/src/strategies/simple.stable.strat.ts @@ -27,7 +27,7 @@ export class SimpleStableStrategy extends IStrategy { constructor() { const rewardTokens = [{logo: CONSTANTS.LOGOS.STRK}, {logo: CONSTANTS.LOGOS.USDC}, {logo: CONSTANTS.LOGOS.USDT}]; - super('SSStrt', "Loop stable-coins to maximize yield", rewardTokens); + super('SSStrt', "Loop stable-coins to maximize yield", rewardTokens, []); this.steps = [{ name: "Deposit to best pool",