Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔥 Update to new Starknet Sepolia testnet #45

Merged
merged 3 commits into from
Oct 14, 2024
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
11 changes: 0 additions & 11 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,6 @@ const withPWA = require("next-pwa");

/** @type {import('next').NextConfig} */
module.exports = withPWA({
pwa: {
disable:
process.env.NODE_ENV === "development" ||
process.env.NODE_ENV === "preview" ||
process.env.NODE_ENV === "production",
// delete two lines above to enable PWA in production deployment
// add your own icons to public/manifest.json
// to re-generate manifest.json, you can visit https://tomitm.github.io/appmanifest/
dest: "public",
register: true,
},
images: {
domains: ['raw.githubusercontent.com'],
},
Expand Down
22 changes: 11 additions & 11 deletions src/assets/default.tokenlist.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,32 +15,32 @@
"address": "",
"symbol": "ETH",
"decimals": 18,
"chainId": 1802203764,
"chainId": 920637907288165,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/0d9233eef112388ef7e261cb88413894fd832679/assets/tokensets/coin-icons/eth.svg",
"isNative": true
},
{
"name": "Wrapped Ethereum",
"address": "0x761612F0C8bdf8cF10e6F10045E2Ca7cbffBa8A3",
"address": "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512",
"symbol": "WETH",
"decimals": 18,
"chainId": 1802203764,
"chainId": 920637907288165,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/0d9233eef112388ef7e261cb88413894fd832679/assets/tokensets/coin-icons/eth.svg"
},
{
"name": "USD Coin",
"address": "0x3Ec72F6efE03e1f6E3e5Ac459d1fA8c86C7198Ae",
"symbol": "USDC",
"decimals": 18,
"chainId": 1802203764,
"address": "0x1B4C0bc8703D3af59322849bE01559fdb920c904",
"symbol": "kUSDC",
"decimals": 6,
"chainId": 920637907288165,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/0d9233eef112388ef7e261cb88413894fd832679/assets/tokensets/coin-icons/usdc.svg"
},
{
"name": "Tether USD",
"address": "0xb0537C06a5DE57a17376b2Bb57641646028965e6",
"symbol": "USDT",
"decimals": 18,
"chainId": 1802203764,
"address": "0x2BF1004D9e80ca087BD1e089d75bc8c471995aC1",
"symbol": "kUSDT",
"decimals": 6,
"chainId": 920637907288165,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/0d9233eef112388ef7e261cb88413894fd832679/assets/tokensets/coin-icons/usdt.svg"
}
]
Expand Down
3 changes: 2 additions & 1 deletion src/components/layout/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@ const Layout = ({ children }: LayoutProps) => {
// Once user is connected, fetch is balance
useEffect(() => {
// Fetch balance when user connect
if (!init && pools.length === 0 && tokens.length > 0 && isConnected && walletProvider) {
if (!init && tokens.length > 0 && isConnected && walletProvider) {
getTokenBalanceForAll(tokens, walletProvider);

getTokenAllowanceForAll(tokens, walletProvider);
}
if (!init && pools.length > 0 && isConnected && walletProvider) {
Expand Down
6 changes: 3 additions & 3 deletions src/components/wallet/web3-modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ const projectId = process.env.NEXT_PUBLIC_WALLET_CONNECT_PROJECT_ID || "";

// 2. Set chains
export const kakarotSepolia = {
chainId: 1802203764,
chainId: 920637907288165,
name: "Kakarot Sepolia",
currency: "ETH",
explorerUrl: "https://sepolia.kakarotscan.org",
rpcUrl: "https://sepolia-rpc-priority.kakarot.org",
explorerUrl: "https://blockscout-kkrt-sepolia.karnot.xyz/",
rpcUrl: "https://sepolia-rpc.kakarot.org/",
};

// 3. Create a metadata object
Expand Down
1 change: 0 additions & 1 deletion src/context/WalletProvider/manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@ const useWalletManager = (): WalletState => {
// Need to init token list before call
const getTokenBalanceForAll = React.useCallback(
async (tokensToGetBalance: TokenState[], callerAccount: Eip1193Provider) => {
console.log("coucou");
tokensToGetBalance.forEach((token: TokenState) => {
getTokenBalance(token, callerAccount);
});
Expand Down
6 changes: 3 additions & 3 deletions src/contracts/addresses.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Addresses on the kakarot testnet (TODO add testnet/mainnet environments)
export const KAKASWAP_ROUTER = "0x7c51B6E67a3a7deD9E61F555e1f9FFb9BdE7ae4d";
export const KAKASWAP_FACTORY = "0xe4CEb28E1e3a6192542A778f1c7277b7267C00B8";
export const WETH_ADDRESS = "0x761612F0C8bdf8cF10e6F10045E2Ca7cbffBa8A3";
export const KAKASWAP_ROUTER = "0x85db84922b6B33E69FdA103828Dc777E818C9B28";
export const KAKASWAP_FACTORY = "0x9447104d4c65B1aB700e9401B6934F7a92f6c032";
export const WETH_ADDRESS = "0xe7f1725e7734ce288f8367e1bb143e90bb3f0512";
Loading