From e868460001f12976743fb4729da473edebe02763 Mon Sep 17 00:00:00 2001 From: EREN Date: Wed, 13 Nov 2024 12:50:33 +0700 Subject: [PATCH 1/2] add unichain --- src/components/VaultIdentity/styles.ts | 3 +++ src/config/boost/unichain.json | 1 + src/config/config.tsx | 15 +++++++++++++++ src/config/migrators/unichain.tsx | 3 +++ src/config/minters/unichain.tsx | 3 +++ src/config/vault/unichain.json | 1 + src/features/data/apis/config-types.ts | 1 + .../components/ChainHolding/styles.tsx | 3 +++ src/images/networks/unichain.svg | 4 ++++ 9 files changed, 34 insertions(+) create mode 100644 src/config/boost/unichain.json create mode 100644 src/config/migrators/unichain.tsx create mode 100644 src/config/minters/unichain.tsx create mode 100644 src/config/vault/unichain.json create mode 100644 src/images/networks/unichain.svg diff --git a/src/components/VaultIdentity/styles.ts b/src/components/VaultIdentity/styles.ts index 3edd04c3a5..6985f8c035 100644 --- a/src/components/VaultIdentity/styles.ts +++ b/src/components/VaultIdentity/styles.ts @@ -130,4 +130,7 @@ export const styles = (theme: Theme) => ({ 'vaultNetwork-scroll': { backgroundColor: '#ffe6c8', }, + 'vaultNetwork-unichain': { + backgroundColor: '#F50FB4', + }, }); diff --git a/src/config/boost/unichain.json b/src/config/boost/unichain.json new file mode 100644 index 0000000000..fe51488c70 --- /dev/null +++ b/src/config/boost/unichain.json @@ -0,0 +1 @@ +[] diff --git a/src/config/config.tsx b/src/config/config.tsx index c1931a557e..e0d1cf8df0 100644 --- a/src/config/config.tsx +++ b/src/config/config.tsx @@ -772,6 +772,21 @@ export const config = { }, stableCoins: ['USDT', 'USDC', 'loreUSD'], }, + unichain: { + name: 'Unichain', + chainId: 1313161554, + rpc: ['https://mainnet.unichain.org/'], + explorerUrl: 'https://mainnet.uniscan.xyz/', + multicallAddress: '0x0000000000000000000000000000000000000000', + multicall3Address: '0x0000000000000000000000000000000000000000', + appMulticallContractAddress: '0x0000000000000000000000000000000000000000', + providerName: 'Unichain', + native: { symbol: 'ETH', oracleId: 'WETH', decimals: 18 }, + gas: { + type: 'standard', + }, + stableCoins: [], + }, aurora: { name: 'Aurora', chainId: 1313161554, diff --git a/src/config/migrators/unichain.tsx b/src/config/migrators/unichain.tsx new file mode 100644 index 0000000000..ec89c124a7 --- /dev/null +++ b/src/config/migrators/unichain.tsx @@ -0,0 +1,3 @@ +import type { MigrationConfig } from '../../features/data/reducers/wallet/migration'; + +export const migrators = [] as const satisfies ReadonlyArray; diff --git a/src/config/minters/unichain.tsx b/src/config/minters/unichain.tsx new file mode 100644 index 0000000000..6fbb7ceb40 --- /dev/null +++ b/src/config/minters/unichain.tsx @@ -0,0 +1,3 @@ +import type { MinterConfig } from '../../features/data/apis/config-types'; + +export const minters: MinterConfig[] = []; diff --git a/src/config/vault/unichain.json b/src/config/vault/unichain.json new file mode 100644 index 0000000000..fe51488c70 --- /dev/null +++ b/src/config/vault/unichain.json @@ -0,0 +1 @@ +[] diff --git a/src/features/data/apis/config-types.ts b/src/features/data/apis/config-types.ts index d093d31ceb..47180a29c6 100644 --- a/src/features/data/apis/config-types.ts +++ b/src/features/data/apis/config-types.ts @@ -190,6 +190,7 @@ type ChainId = | 'sei' | 'rootstock' | 'scroll' + | 'unichain' | 'aurora' | 'emerald' | 'celo' diff --git a/src/features/treasury/components/DaoHoldings/components/ChainHolding/styles.tsx b/src/features/treasury/components/DaoHoldings/components/ChainHolding/styles.tsx index 8cdd1c902c..574a552e77 100644 --- a/src/features/treasury/components/DaoHoldings/components/ChainHolding/styles.tsx +++ b/src/features/treasury/components/DaoHoldings/components/ChainHolding/styles.tsx @@ -138,6 +138,9 @@ export const styles = (theme: Theme) => ({ 'headerNetwork-scroll': { backgroundColor: 'rgb(201, 203, 206)', }, + 'headerNetwork-unichain': { + backgroundColor: 'rgb(245, 15, 180,0.4)', + }, 'headerMM-system9': { backgroundColor: 'rgba(243, 243, 200, 0.5)', }, diff --git a/src/images/networks/unichain.svg b/src/images/networks/unichain.svg new file mode 100644 index 0000000000..e24b26cd53 --- /dev/null +++ b/src/images/networks/unichain.svg @@ -0,0 +1,4 @@ + + + + From ba11d6251d2e24ef53c199aef193a6544e0a5224 Mon Sep 17 00:00:00 2001 From: EREN Date: Thu, 14 Nov 2024 12:16:59 +0700 Subject: [PATCH 2/2] add new badge and update chainId --- src/config/config.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/config/config.tsx b/src/config/config.tsx index e0d1cf8df0..5c453b3390 100644 --- a/src/config/config.tsx +++ b/src/config/config.tsx @@ -774,7 +774,8 @@ export const config = { }, unichain: { name: 'Unichain', - chainId: 1313161554, + new: true, + chainId: 1301, rpc: ['https://mainnet.unichain.org/'], explorerUrl: 'https://mainnet.uniscan.xyz/', multicallAddress: '0x0000000000000000000000000000000000000000',