Skip to content

Commit f1391e8

Browse files
authored
feat: add soneium chain (#1611)
* feat: add soneium chain * chore: update @guildxyz/types
1 parent d7a2f08 commit f1391e8

File tree

7 files changed

+20
-5
lines changed

7 files changed

+20
-5
lines changed

‎package-lock.json‎

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
"@emotion/styled": "^11.11.0",
3131
"@fuels/connectors": "^0.36.0",
3232
"@fuels/react": "^0.36.0",
33-
"@guildxyz/types": "^1.10.48",
33+
"@guildxyz/types": "^1.10.49",
3434
"@hcaptcha/react-hcaptcha": "^1.4.4",
3535
"@hookform/resolvers": "^3.3.4",
3636
"@lexical/code": "^0.12.0",

‎public/networkLogos/soneium.webp‎

13.5 KB
Loading

‎src/components/[guild]/collect/hooks/useGuildFee.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ const chainsWithOverrides = [
1616
"ZERO",
1717
"MANTLE",
1818
"XDC",
19+
"SONEIUM",
1920
]
2021

2122
const useGuildFee = (

‎src/hooks/useTokens.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ const TokenApiURLs: Record<Chain, string[]> = {
103103
XDC: [
104104
"https://raw.githubusercontent.com/XSwapProtocol/xdc-token-list/refs/heads/master/mainnet.tokenlist.json",
105105
],
106+
SONEIUM: [],
106107
}
107108

108109
const fetchTokens = async ([_, chain]) =>

‎src/wagmiConfig/chains.ts‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ import {
6767
sei,
6868
sepolia,
6969
shimmer,
70+
soneium,
7071
sonic,
7172
sophon,
7273
taiko,
@@ -787,6 +788,14 @@ const CHAIN_CONFIG: Record<Chain, GuildChain> = {
787788
dark: "/networkLogos/xdc.svg",
788789
},
789790
},
791+
SONEIUM: {
792+
...generateChainConfig(soneium, ETH_ICON),
793+
iconUrl: "/networkLogos/soneium.webp",
794+
blockExplorerIconUrl: {
795+
light: "/networkLogos/soneium.webp",
796+
dark: "/networkLogos/soneium.webp",
797+
},
798+
},
790799
}
791800

792801
enum Chains {
@@ -865,6 +874,7 @@ enum Chains {
865874
SOPHON = sophon.id,
866875
ZERO = zero.id,
867876
XDC = xdc.id,
877+
SONEIUM = soneium.id,
868878
}
869879

870880
export type Chain = keyof typeof Chains

‎src/wagmiConfig/index.ts‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ import {
7373
sei,
7474
sepolia,
7575
shimmer,
76+
soneium,
7677
sonic,
7778
sophon,
7879
taiko,
@@ -206,6 +207,7 @@ export const wagmiConfig = IS_TEST
206207
sophon,
207208
zero,
208209
xdc,
210+
soneium,
209211
],
210212
transports: {
211213
[mainnet.id]: http(),
@@ -279,6 +281,7 @@ export const wagmiConfig = IS_TEST
279281
[sophon.id]: http(),
280282
[zero.id]: http(),
281283
[xdc.id]: http(),
284+
[soneium.id]: http(),
282285
},
283286
ssr: true,
284287
connectors: [

0 commit comments

Comments
 (0)