Skip to content

Commit

Permalink
add new networks (#36)
Browse files Browse the repository at this point in the history
* fix core svg paths

* new networks
# bob, kaia, kakarot,karura,soneium

* add changeset

* version
  • Loading branch information
0xa3k5 authored Oct 17, 2024
1 parent 9fffbd6 commit b708871
Show file tree
Hide file tree
Showing 46 changed files with 84,130 additions and 9,509 deletions.
4 changes: 2 additions & 2 deletions apps/figma-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
"@create-figma-plugin/ui": "^3.1.0",
"@create-figma-plugin/utilities": "^3.1.0",
"preact": ">=10",
"@web3icons/core": "3.7.1",
"@web3icons/common": "0.1.1"
"@web3icons/core": "3.8.0",
"@web3icons/common": "0.2.0"
},
"devDependencies": {
"@create-figma-plugin/build": "^3.1.0",
Expand Down
6 changes: 3 additions & 3 deletions apps/website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
"@types/react": "18.2.64",
"@types/react-dom": "18.2.21",
"@vercel/analytics": "^1.2.2",
"@web3icons/react": "3.7.1",
"@web3icons/common": "0.1.1",
"@web3icons/core": "3.7.1",
"@web3icons/react": "3.8.0",
"@web3icons/common": "0.2.0",
"@web3icons/core": "3.8.0",
"autoprefixer": "10.4.18",
"eslint": "8.57.0",
"eslint-config-next": "14.1.3",
Expand Down
12 changes: 6 additions & 6 deletions apps/website/src/hooks/useSvgContent.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,31 +31,31 @@ export const useSvgContent = ({
if (type === 'token') {
if (variant === 'mono') {
svgModule = await import(
`@web3icons/core/svgs/tokens/mono/${(metadata as ITokenMetadata).symbol.toUpperCase()}.svg`
`@web3icons/core/tokens/mono/${(metadata as ITokenMetadata).symbol.toUpperCase()}.svg`
)
} else if (variant === 'branded') {
svgModule = await import(
`@web3icons/core/svgs/tokens/branded/${(metadata as ITokenMetadata).symbol.toUpperCase()}.svg`
`@web3icons/core/tokens/branded/${(metadata as ITokenMetadata).symbol.toUpperCase()}.svg`
)
}
} else if (type === 'network') {
if (variant === 'mono') {
svgModule = await import(
`@web3icons/core/svgs/networks/mono/${metadata.id.toLowerCase()}.svg`
`@web3icons/core/networks/mono/${metadata.id.toLowerCase()}.svg`
)
} else if (variant === 'branded') {
svgModule = await import(
`@web3icons/core/svgs/networks/branded/${metadata.id.toLowerCase()}.svg`
`@web3icons/core/networks/branded/${metadata.id.toLowerCase()}.svg`
)
}
} else if (type === 'wallet') {
if (variant === 'mono') {
svgModule = await import(
`@web3icons/core/svgs/wallets/mono/${metadata.id.toLowerCase()}.svg`
`@web3icons/core/wallets/mono/${metadata.id.toLowerCase()}.svg`
)
} else if (variant === 'branded') {
svgModule = await import(
`@web3icons/core/svgs/wallets/branded/${metadata.id.toLowerCase()}.svg`
`@web3icons/core/wallets/branded/${metadata.id.toLowerCase()}.svg`
)
}
}
Expand Down
12 changes: 9 additions & 3 deletions docs/icons.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
jump to section:

- [wallets (38)](#wallets)
- [networks (123)](#networks)
- [tokens (1897)](#tokens)
- [networks (128)](#networks)
- [tokens (1898)](#tokens)

### Wallets

Expand Down Expand Up @@ -174,6 +174,11 @@ jump to section:
| kucoin | kucoin |||
| zeta | zeta chain |||
| zeta-chain | zeta chain |||
| bob | Bob |||
| klay-token | Kaia |||
| kakarot | Kakarot |||
| karura | Karura |||
| soneium | Soneium |||

### Tokens

Expand Down Expand Up @@ -2065,7 +2070,6 @@ jump to section:
| Pendle | pendle |||
| Jupiter Project | jup |||
| Artrade | atr |||
| BaseSwap | base |||
| BNB | bnb |||
| Sense | sense |||
| AMZCoin | amz |||
Expand All @@ -2076,3 +2080,5 @@ jump to section:
| OneArt | 1art |||
| 1inch | 1inch |||
| 2DAI.io | 2dai |||
| apefi | apefi |||
| SwapBased | base |||
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@
"private": false,
"author": "0xa3k5",
"scripts": {
"build": "turbo build",
"build:core": "turbo run build:core && bun run lint && bun run format",
"build:react": "turbo run build:react && bun run lint && bun run format",
"build": "turbo build && bun run post-build",
"build:core": "turbo run build:core && bun run post-build",
"build:react": "turbo run build:react && bun run post-build",
"post-build": "bun run generate-icons-md && bun run lint && bun run format",
"dev": "turbo dev",
"lint": "turbo lint",
"format": "prettier --write \"**/*.{ts,tsx,js,jsx,md,mdx,json}\" --log-level error",
Expand Down
6 changes: 6 additions & 0 deletions packages/common/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @web3icons/common

## 0.2.0

### Minor Changes

- 03c8c28: new networks: bob, soneium, kaia, kakarot, karura

## 0.1.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"svg crypto icons",
"coin icons"
],
"version": "0.1.1",
"version": "0.2.0",
"private": false,
"author": "0xa3k5",
"license": "MIT",
Expand Down
39 changes: 39 additions & 0 deletions packages/common/src/metadata/networks.json
Original file line number Diff line number Diff line change
Expand Up @@ -953,5 +953,44 @@
"shortName": "zeta",
"chainId": 7000,
"nativeCoinId": "zeta"
},
{
"id": "bob",
"name": "Bob",
"variants": ["branded", "mono"],
"shortName": "bob",
"chainId": 60808,
"nativeCoinId": "eth"
},
{
"id": "klay-token",
"name": "Kaia",
"variants": ["branded", "mono"],
"shortName": "kaia",
"chainId": 8217,
"nativeCoinId": "kaia"
},
{
"id": "kakarot",
"name": "Kakarot",
"variants": ["branded", "mono"],
"shortName": "kakarot",
"nativeCoinId": "eth"
},
{
"id": "karura",
"name": "Karura",
"variants": ["branded", "mono"],
"shortName": "karura",
"chainId": 686,
"nativeCoinId": "karura"
},
{
"id": "soneium",
"name": "Soneium",
"variants": ["branded", "mono"],
"shortName": "soneium",
"chainId": 1946,
"nativeCoinId": "eth"
}
]
39 changes: 39 additions & 0 deletions packages/common/src/metadata/networks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -956,4 +956,43 @@ export const networks: INetworkMetadata[] = [
chainId: 7000,
nativeCoinId: 'zeta',
},
{
id: 'bob',
name: 'Bob',
variants: ['branded', 'mono'],
shortName: 'bob',
chainId: 60808,
nativeCoinId: 'eth',
},
{
id: 'klay-token',
name: 'Kaia',
variants: ['branded', 'mono'],
shortName: 'kaia',
chainId: 8217,
nativeCoinId: 'kaia',
},
{
id: 'kakarot',
name: 'Kakarot',
variants: ['branded', 'mono'],
shortName: 'kakarot',
nativeCoinId: 'eth',
},
{
id: 'karura',
name: 'Karura',
variants: ['branded', 'mono'],
shortName: 'karura',
chainId: 686,
nativeCoinId: 'karura',
},
{
id: 'soneium',
name: 'Soneium',
variants: ['branded', 'mono'],
shortName: 'soneium',
chainId: 1946,
nativeCoinId: 'eth',
},
]
16 changes: 16 additions & 0 deletions packages/common/src/metadata/tokens.json
Original file line number Diff line number Diff line change
Expand Up @@ -18916,5 +18916,21 @@
"symbol": "2dai",
"marketCapRank": 2443,
"addresses": { "ethereum": "0xb44b653f147569d88a684cbf6549e1968e8b2a1d" }
},
{
"id": "apefi",
"name": "apefi",
"symbol": "apefi",
"marketCapRank": null,
"variants": ["branded", "mono"],
"addresses": {}
},
{
"id": "base",
"name": "SwapBased",
"symbol": "base",
"marketCapRank": null,
"variants": ["branded"],
"addresses": { "base": "0xd07379a755a8f11b57610154861d694b2a0f615a" }
}
]
8 changes: 0 additions & 8 deletions packages/common/src/metadata/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20178,14 +20178,6 @@ export const tokens: ITokenMetadata[] = [
solana: 'ATRLuHph8dxnPny4WSNW7fxkhbeivBrtWbY6BfB4xpLj',
},
},
{
id: 'base',
name: 'SwapBased',
variants: ['branded'],
symbol: 'base',
marketCapRank: null,
addresses: {},
},
{
id: 'binancecoin',
symbol: 'bnb',
Expand Down
6 changes: 6 additions & 0 deletions packages/core/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @web3icons/core

## 3.8.0

### Minor Changes

- 03c8c28: new networks: bob, soneium, kaia, kakarot, karura

## 3.7.1

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"svg crypto icons",
"coin icons"
],
"version": "3.7.1",
"version": "3.8.0",
"private": false,
"author": "0xa3k5",
"license": "MIT",
Expand Down
Loading

0 comments on commit b708871

Please sign in to comment.