Skip to content

Commit

Permalink
feat: added scroll chain support
Browse files Browse the repository at this point in the history
  • Loading branch information
Argeare5 committed Feb 2, 2024
1 parent a1f9757 commit 4d5156c
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
},
"dependencies": {
"@bgd-labs/aave-address-book": "^2.18.0",
"@bgd-labs/aave-governance-ui-helpers": "^2.0.0",
"@bgd-labs/aave-governance-ui-helpers": "^2.1.0",
"@bgd-labs/frontend-web3-utils": "^1.1.0",
"@emotion/cache": "^11.11.0",
"@emotion/react": "^11.11.3",
Expand Down
9 changes: 9 additions & 0 deletions public/images/networks/scroll.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/ui/components/NetworkIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import {
optimism,
polygon,
polygonMumbai,
scroll,
sepolia,
} from 'viem/chains';

Expand Down Expand Up @@ -59,6 +60,8 @@ const getIconNetworkName = (chainId: number) => {
return 'optimism';
case gnosis.id:
return 'gnosis';
case scroll.id:
return 'scroll';
default:
return 'ethereum';
}
Expand Down
6 changes: 6 additions & 0 deletions src/utils/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import {
optimism,
polygon,
polygonMumbai,
scroll,
sepolia,
} from 'viem/chains';

Expand Down Expand Up @@ -74,6 +75,10 @@ export const initialRpcUrls: Record<number, string[]> = {
'https://gnosis.blockpi.network/v1/rpc/public',
'https://gnosis-mainnet.public.blastapi.io',
],
[scroll.id]: [
'https://scroll.blockpi.network/v1/rpc/public',
'https://scroll-mainnet.public.blastapi.io',
],
// testnets
[goerli.id]: [
'https://ethereum-goerli.publicnode.com',
Expand Down Expand Up @@ -124,6 +129,7 @@ export const CHAINS: Record<number, Chain> = {
[metis.id]: setChain(metis),
[optimism.id]: setChain(optimism),
[gnosis.id]: setChain(gnosis),
[scroll.id]: setChain(scroll),
// testnets
[goerli.id]: setChain(goerli),
[sepolia.id]: setChain(sepolia),
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1306,10 +1306,10 @@
resolved "https://registry.yarnpkg.com/@bgd-labs/aave-address-book/-/aave-address-book-2.18.0.tgz#f0e62da3935246c70d0f6dd07d394448dd505852"
integrity sha512-REfTbwYLnazYALXOC1eiuBELirYypk3vXPv2Ale5ZnyD+uQhemc7ya6y75iKGm3BuYC6jLIsGwSHczX8D10UEQ==

"@bgd-labs/aave-governance-ui-helpers@^2.0.0":
version "2.0.0"
resolved "https://registry.yarnpkg.com/@bgd-labs/aave-governance-ui-helpers/-/aave-governance-ui-helpers-2.0.0.tgz#494e3556a2ea88b3c48d1bb8ca7c2849d665e53e"
integrity sha512-IqlAeoFdnR6A83vfEjgBpTsLLOqJ329aRMNuIYVrRGMsVq6JwUpxUW1xkIADte8FRCOUZAaKHTXWGJUcGB6urQ==
"@bgd-labs/aave-governance-ui-helpers@^2.1.0":
version "2.1.0"
resolved "https://registry.yarnpkg.com/@bgd-labs/aave-governance-ui-helpers/-/aave-governance-ui-helpers-2.1.0.tgz#148072db0d6a4ec0f0e1c2a49066b5d2bdf83b57"
integrity sha512-alQZdQkMnO4rUjA8iqnlANGK5y0+5npeaWcr/ZQzAiOwxPhGOtaJrRFseFyl46Pq0gC7NPhxgJkV0goGfs7tUw==
dependencies:
"@bgd-labs/js-utils" "1.1.1"
dayjs "^1.11.10"
Expand Down

1 comment on commit 4d5156c

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This commit was deployed on ipfs

Please sign in to comment.