Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
frontend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vicotor
frontend
Commits
32f12eee
Commit
32f12eee
authored
Nov 18, 2022
by
tom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change goerli envs and add logo
parent
2dc65c83
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
94 additions
and
34 deletions
+94
-34
.gitignore
.gitignore
+1
-0
tasks.json
.vscode/tasks.json
+20
-0
.env.goerli
configs/envs/.env.goerli
+3
-2
goerli.svg
icons/networks/logos/goerli.svg
+3
-0
featuredNetworks.ts
lib/networks/featuredNetworks.ts
+63
-31
package.json
package.json
+1
-0
networks.ts
types/networks.ts
+1
-1
NetworkLogo.tsx
ui/snippets/networkMenu/NetworkLogo.tsx
+2
-0
No files found.
.gitignore
View file @
32f12eee
...
@@ -29,6 +29,7 @@ yarn-error.log*
...
@@ -29,6 +29,7 @@ yarn-error.log*
# local env files
# local env files
.env*.local
.env*.local
/configs/envs/.env.secrets
/configs/envs/.env.secrets
/configs/envs/.samples
# vercel
# vercel
.vercel
.vercel
...
...
.vscode/tasks.json
View file @
32f12eee
...
@@ -43,6 +43,26 @@
...
@@ -43,6 +43,26 @@
"instanceLimit"
:
1
"instanceLimit"
:
1
}
}
},
},
{
"type"
:
"npm"
,
"script"
:
"dev:goerli"
,
"problemMatcher"
:
[],
"label"
:
"dev server: goerli"
,
"detail"
:
"start local dev server for Goerli network"
,
"presentation"
:
{
"reveal"
:
"silent"
,
"panel"
:
"new"
,
"close"
:
true
,
"revealProblems"
:
"onProblem"
,
},
"icon"
:
{
"color"
:
"terminal.ansiMagenta"
,
"id"
:
"server-process"
},
"runOptions"
:
{
"instanceLimit"
:
1
}
},
{
{
"type"
:
"typescript"
,
"type"
:
"typescript"
,
"label"
:
"tsc build"
,
"label"
:
"tsc build"
,
...
...
configs/envs/.env.goerli
View file @
32f12eee
# ui config
# ui config
NEXT_PUBLIC_FEATURED_NETWORKS=[{'title':'
Gnosis Chain','url':'https://blockscout.com/xdai/mainnet','group':'mainnets','type':'xdai_mainnet'},{'title':'Optimism on Gnosis Chain','url':'https://blockscout.com/xdai/optimism','group':'mainnets','icon':'https://www.fillmurray.com/60/60','type':'xdai_optimism'},{'title':'Arbitrum on xDai','url':'https://blockscout.com/xdai/aox','group':'mainnets'},{'title':'Ethereum','url':'https://blockscout.com/eth/mainnet','group':'mainnets','type':'eth_mainnet'},{'title':'Ethereum Classic','url':'https://blockscout.com/etx/mainnet','group':'mainnets','type':'etc_mainnet'},{'title':'POA','url':'https://blockscout.com/poa/core','group':'mainnets','type':'poa_core'},{'title':'RSK','url':'https://blockscout.com/rsk/mainnet','group':'mainnets','type':'rsk_mainnet'},{'title':'Gnosis Chain Testnet','url':'https://blockscout.com/xdai/testnet','group':'testnets','type':'xdai_testnet'},{'title':'POA Sokol','url':'https://blockscout.com/poa/sokol','group':'testnets','type':'poa_sokol'},{'title':'ARTIS Σ1','url':'https://blockscout.com/artis/sigma1','group':'other','type':'artis_sigma1'},{'title':'LUKSO L14','url':'https://blockscout.com/lukso/l14','group':'other','type':'lukso_l14'},{'title':'Astar','url':'https://blockscout.com/astar','group':'other','type':'astar
'}]
NEXT_PUBLIC_FEATURED_NETWORKS=[{'title':'
Ethereum','url':'https://blockscout.com/eth/mainnet','group':'mainnets','type':'eth_mainnet'},{'title':'Ethereum Classic','url':'https://blockscout.com/etx/mainnet','group':'mainnets','type':'etc_mainnet'},{'title':'Gnosis Chain','url':'https://blockscout.com/xdai/mainnet','group':'mainnets','type':'xdai_mainnet'},{'title':'Astar (EVM)','url':'https://blockscout.com/astar','group':'mainnets','type':'astar'},{'title':'Shiden (EVM)','url':'https://blockscout.com/shiden','group':'mainnets','type':'astar'},{'title':'Klaytn Mainnet (Cypress)','url':'https://klaytn-mainnet.aws-k8s.blockscout.com/','group':'mainnets','type':'klaytn'},{'title':'Goerli','url':'https://blockscout.com/eth/goerli/','group':'testnets','type':'goerli'},{'title':'Optimism Goerli','url':'https://blockscout.com/optimism/goerli/','group':'testnets','type':'optimism_goerli'},{'title':'Optimism Bedrock Alpha','url':'https://blockscout.com/optimism/bedrock-alpha','group':'testnets','type':'optimism_bedrock_alpha'},{'title':'Gnosis Chiado','url':'https://blockscout.com/gnosis/chiado/','group':'testnets','type':'gnosis_chiado'},{'title':'Shibuya (EVM)','url':'https://blockscout.com/shibuya','group':'testnets','type':'shibuya'},{'title':'Optimism Opcraft','url':'https://blockscout.com/optimism/opcraft','group':'other','type':'optimism_opcraft'},{'title':'Optimism on Gnosis Chain','url':'https://blockscout.com/xdai/optimism','group':'other','type':'optimism_gnosis'},{'title':'ARTIS-Σ1','url':'https://blockscout.com/artis/sigma1','group':'other','type':'artis_sigma1'},{'title':'LUKSO L14','url':'https://blockscout.com/lukso/l14','group':'other','type':'lukso_l14'},{'title':'POA','url':'https://blockscout.com/poa/core','group':'other','type':'poa_core'},{'title':'POA Sokol','url':'https://blockscout.com/poa/sokol','group':'other','type':'poa_sokol
'}]
NEXT_PUBLIC_NETWORK_EXPLORERS=[{'title':'Anyblock','baseUrl':'https://explorer.anyblock.tools','paths':{'tx':'/ethereum/ethereum/goerli/transaction'}},{'title':'Etherscan','baseUrl':'https://goerli.etherscan.io/','paths':{'tx':'/tx'}}]
NEXT_PUBLIC_NETWORK_EXPLORERS=[{'title':'Anyblock','baseUrl':'https://explorer.anyblock.tools','paths':{'tx':'/ethereum/ethereum/goerli/transaction'}},{'title':'Etherscan','baseUrl':'https://goerli.etherscan.io/','paths':{'tx':'/tx'}}]
# network config
# network config
NEXT_PUBLIC_NETWORK_NAME=Goerli
NEXT_PUBLIC_NETWORK_NAME=Ethereum
NEXT_PUBLIC_NETWORK_SHORT_NAME=Goerli
NEXT_PUBLIC_NETWORK_ASSETS_PATHNAME=ethereum
NEXT_PUBLIC_NETWORK_ASSETS_PATHNAME=ethereum
NEXT_PUBLIC_NETWORK_TYPE=goerli
NEXT_PUBLIC_NETWORK_TYPE=goerli
NEXT_PUBLIC_NETWORK_ID=420
NEXT_PUBLIC_NETWORK_ID=420
...
...
icons/networks/logos/goerli.svg
0 → 100644
View file @
32f12eee
<svg
xmlns=
"http://www.w3.org/2000/svg"
viewBox=
"0 0 30 20"
>
<path
data-name=
"-e-logo_top"
d=
"M13.82 10.054h-6.9v2.731h3.191l-.011 3.432a1.456 1.456 0 0 1-.43.319 4 4 0 0 1-.655.267 5.306 5.306 0 0 1-.795.182 5.647 5.647 0 0 1-.861.065 3.012 3.012 0 0 1-2.715-1.424 7.745 7.745 0 0 1-.9-4.063v-2.6a9.439 9.439 0 0 1 .265-2.36 5.76 5.76 0 0 1 .715-1.71 3.229 3.229 0 0 1 1.059-1.047 2.57 2.57 0 0 1 1.324-.357 2.922 2.922 0 0 1 2.191.735 3.762 3.762 0 0 1 .894 2.191h3.628a8.468 8.468 0 0 0-.616-2.458A5.315 5.315 0 0 0 11.9 2.1 5.626 5.626 0 0 0 9.854.936a9.017 9.017 0 0 0-2.84-.4 6.711 6.711 0 0 0-2.774.572 6.354 6.354 0 0 0-2.225 1.664A7.926 7.926 0 0 0 .532 5.431 10.952 10.952 0 0 0 0 8.988v2.575a11.473 11.473 0 0 0 .51 3.556 7.5 7.5 0 0 0 1.45 2.646 6.25 6.25 0 0 0 2.264 1.651 7.406 7.406 0 0 0 2.966.572 11.15 11.15 0 0 0 2.278-.221 10.5 10.5 0 0 0 1.913-.579 7.641 7.641 0 0 0 1.477-.8 5.159 5.159 0 0 0 .98-.871zm2.661 2.783a8.686 8.686 0 0 0 .451 2.854 6.513 6.513 0 0 0 1.317 2.269 5.984 5.984 0 0 0 2.132 1.5 7.277 7.277 0 0 0 2.88.54 7.194 7.194 0 0 0 2.86-.54 5.934 5.934 0 0 0 2.119-1.5 6.6 6.6 0 0 0 1.311-2.269 8.713 8.713 0 0 0 .45-2.854v-.274a8.673 8.673 0 0 0-.45-2.841 6.532 6.532 0 0 0-1.318-2.269 6.078 6.078 0 0 0-2.125-1.508 7.813 7.813 0 0 0-5.74 0 6.082 6.082 0 0 0-2.119 1.508 6.515 6.515 0 0 0-1.317 2.269 8.647 8.647 0 0 0-.451 2.841v.273zm3.681-.273a7.394 7.394 0 0 1 .173-1.625 4.223 4.223 0 0 1 .542-1.352 2.633 2.633 0 0 1 2.357-1.261 2.777 2.777 0 0 1 1.417.338 2.693 2.693 0 0 1 .947.923 4.31 4.31 0 0 1 .536 1.352 7.394 7.394 0 0 1 .173 1.625v.273a7.606 7.606 0 0 1-.173 1.658 4.227 4.227 0 0 1-.536 1.352 2.621 2.621 0 0 1-2.337 1.255 2.818 2.818 0 0 1-1.424-.338 2.758 2.758 0 0 1-.96-.917 4.143 4.143 0 0 1-.542-1.352 7.606 7.606 0 0 1-.173-1.658v-.274zm-1.747-10.3a1.492 1.492 0 0 0 .37.514 1.761 1.761 0 0 0 .57.338 2.207 2.207 0 0 0 1.456 0 1.761 1.761 0 0 0 .57-.338 1.492 1.492 0 0 0 .37-.514 1.593 1.593 0 0 0 0-1.274 1.562 1.562 0 0 0-.37-.52 1.7 1.7 0 0 0-.57-.344 2.206 2.206 0 0 0-1.456 0 1.7 1.7 0 0 0-.57.345 1.562 1.562 0 0 0-.37.52 1.593 1.593 0 0 0 0 1.274zm6.356.013a1.558 1.558 0 0 0 .37.52 1.7 1.7 0 0 0 .57.345 2.207 2.207 0 0 0 1.456 0 1.7 1.7 0 0 0 .57-.345 1.558 1.558 0 0 0 .37-.52 1.593 1.593 0 0 0 .133-.65 1.562 1.562 0 0 0-.133-.637 1.492 1.492 0 0 0-.37-.514 1.762 1.762 0 0 0-.57-.338 2.206 2.206 0 0 0-1.456 0 1.762 1.762 0 0 0-.57.338 1.492 1.492 0 0 0-.37.514 1.546 1.546 0 0 0-.133.637 1.576 1.576 0 0 0 .133.651z"
fill=
"currentColor"
fill-rule=
"evenodd"
/>
</svg>
lib/networks/featuredNetworks.ts
View file @
32f12eee
...
@@ -28,61 +28,87 @@ const ICONS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
...
@@ -28,61 +28,87 @@ const ICONS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
// for easy .env.example update
// for easy .env.example update
// const FEATURED_NETWORKS = JSON.stringify([
// const FEATURED_NETWORKS = JSON.stringify([
// {
// {
// title: 'Ethereum',
// url: 'https://blockscout.com/eth/mainnet',
// group: 'mainnets',
// type: 'eth_mainnet',
// },
// {
// title: 'Ethereum Classic',
// url: 'https://blockscout.com/etx/mainnet',
// group: 'mainnets',
// type: 'etc_mainnet',
// },
// {
// title: 'Gnosis Chain',
// title: 'Gnosis Chain',
// url: 'https://blockscout.com/xdai/mainnet',
// url: 'https://blockscout.com/xdai/mainnet',
// group: 'mainnets',
// group: 'mainnets',
// type: 'xdai_mainnet',
// type: 'xdai_mainnet',
// },
// },
// {
// {
// title: '
Optimism on Gnosis Chain
',
// title: '
Astar (EVM)
',
// url: 'https://blockscout.com/
xdai/optimism
',
// url: 'https://blockscout.com/
astar
',
// group: 'mainnets',
// group: 'mainnets',
// icon: 'https://www.fillmurray.com/60/60',
// type: 'astar',
// type: 'xdai_optimism',
// },
// },
// {
// {
// title: '
Arbitrum on xDai
',
// title: '
Shiden (EVM)
',
// url: 'https://blockscout.com/
xdai/aox
',
// url: 'https://blockscout.com/
shiden
',
// group: 'mainnets',
// group: 'mainnets',
// type: 'astar',
// },
// },
// {
// {
// title: '
Ethereum
',
// title: '
Klaytn Mainnet (Cypress)
',
// url: 'https://
blockscout.com/eth/mainnet
',
// url: 'https://
klaytn-mainnet.aws-k8s.blockscout.com/
',
// group: 'mainnets',
// group: 'mainnets',
// type: '
eth_mainnet
',
// type: '
klaytn
',
// },
// },
// {
// {
// title: '
Ethereum Classic
',
// title: '
Goerli
',
// url: 'https://blockscout.com/et
x/mainnet
',
// url: 'https://blockscout.com/et
h/goerli/
',
// group: '
main
nets',
// group: '
test
nets',
// type: '
etc_mainnet
',
// type: '
goerli
',
// },
// },
// {
// {
// title: '
POA
',
// title: '
Optimism Goerli
',
// url: 'https://blockscout.com/
poa/core
',
// url: 'https://blockscout.com/
optimism/goerli/
',
// group: '
main
nets',
// group: '
test
nets',
// type: '
poa_core
',
// type: '
optimism_goerli
',
// },
// },
// {
// {
// title: '
RSK
',
// title: '
Optimism Bedrock Alpha
',
// url: 'https://blockscout.com/
rsk/mainnet
',
// url: 'https://blockscout.com/
optimism/bedrock-alpha
',
// group: '
main
nets',
// group: '
test
nets',
// type: '
rsk_mainnet
',
// type: '
optimism_bedrock_alpha
',
// },
// },
// {
// {
// title: 'Gnosis Ch
ain Testnet
',
// title: 'Gnosis Ch
iado
',
// url: 'https://blockscout.com/
xdai/testnet
',
// url: 'https://blockscout.com/
gnosis/chiado/
',
// group: 'testnets',
// group: 'testnets',
// type: '
xdai_testnet
',
// type: '
gnosis_chiado
',
// },
// },
// {
// {
// title: '
POA Sokol
',
// title: '
Shibuya (EVM)
',
// url: 'https://blockscout.com/
poa/sokol
',
// url: 'https://blockscout.com/
shibuya
',
// group: 'testnets',
// group: 'testnets',
// type: 'poa_sokol',
// type: 'shibuya',
// },
// {
// title: 'Optimism Opcraft',
// url: 'https://blockscout.com/optimism/opcraft',
// group: 'other',
// type: 'optimism_opcraft',
// },
// {
// title: 'Optimism on Gnosis Chain',
// url: 'https://blockscout.com/xdai/optimism',
// group: 'other',
// type: 'optimism_gnosis',
// },
// },
// {
// {
// title: 'ARTIS
Σ1',
// title: 'ARTIS
-
Σ1',
// url: 'https://blockscout.com/artis/sigma1',
// url: 'https://blockscout.com/artis/sigma1',
// group: 'other',
// group: 'other',
// type: 'artis_sigma1',
// type: 'artis_sigma1',
...
@@ -94,10 +120,16 @@ const ICONS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
...
@@ -94,10 +120,16 @@ const ICONS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
// type: 'lukso_l14',
// type: 'lukso_l14',
// },
// },
// {
// {
// title: '
Astar
',
// title: '
POA
',
// url: 'https://blockscout.com/
astar
',
// url: 'https://blockscout.com/
poa/core
',
// group: 'other',
// group: 'other',
// type: 'astar',
// type: 'poa_core',
// },
// {
// title: 'POA Sokol',
// url: 'https://blockscout.com/poa/sokol',
// group: 'other',
// type: 'poa_sokol',
// },
// },
// ]).replaceAll('"', '\'');
// ]).replaceAll('"', '\'');
...
...
package.json
View file @
32f12eee
...
@@ -10,6 +10,7 @@
...
@@ -10,6 +10,7 @@
"scripts"
:
{
"scripts"
:
{
"dev"
:
"next dev"
,
"dev"
:
"next dev"
,
"dev:poa_core"
:
"./node_modules/.bin/dotenv -e ./configs/envs/.env.poa_core -e ./configs/envs/.env.common -e ./configs/envs/.env.secrets next dev | ./node_modules/.bin/pino-pretty"
,
"dev:poa_core"
:
"./node_modules/.bin/dotenv -e ./configs/envs/.env.poa_core -e ./configs/envs/.env.common -e ./configs/envs/.env.secrets next dev | ./node_modules/.bin/pino-pretty"
,
"dev:goerli"
:
"./node_modules/.bin/dotenv -e ./configs/envs/.env.goerli -e ./configs/envs/.env.common -e ./configs/envs/.env.secrets next dev | ./node_modules/.bin/pino-pretty"
,
"build"
:
"next build"
,
"build"
:
"next build"
,
"build:vercel"
:
"./node_modules/.bin/dotenv -e ./configs/envs/.env.poa_core -e ./configs/envs/.env.common next build"
,
"build:vercel"
:
"./node_modules/.bin/dotenv -e ./configs/envs/.env.poa_core -e ./configs/envs/.env.common next build"
,
"build:docker"
:
"docker build --build-arg GIT_COMMIT_SHA=$(git rev-parse HEAD) -t blockscout ./"
,
"build:docker"
:
"docker build --build-arg GIT_COMMIT_SHA=$(git rev-parse HEAD) -t blockscout ./"
,
...
...
types/networks.ts
View file @
32f12eee
...
@@ -3,7 +3,7 @@ import type { FunctionComponent, SVGAttributes } from 'react';
...
@@ -3,7 +3,7 @@ import type { FunctionComponent, SVGAttributes } from 'react';
export
type
NetworkGroup
=
'
mainnets
'
|
'
testnets
'
|
'
other
'
;
export
type
NetworkGroup
=
'
mainnets
'
|
'
testnets
'
|
'
other
'
;
export
type
PreDefinedNetwork
=
'
xdai_mainnet
'
|
'
xdai_optimism
'
|
'
xdai_aox
'
|
'
eth_mainnet
'
|
'
etc_mainnet
'
|
'
poa_core
'
|
export
type
PreDefinedNetwork
=
'
xdai_mainnet
'
|
'
xdai_optimism
'
|
'
xdai_aox
'
|
'
eth_mainnet
'
|
'
etc_mainnet
'
|
'
poa_core
'
|
'
rsk_mainnet
'
|
'
xdai_testnet
'
|
'
poa_sokol
'
|
'
artis_sigma1
'
|
'
lukso_l14
'
|
'
astar
'
|
'
shiden
'
|
'
shibuya
'
;
'
rsk_mainnet
'
|
'
xdai_testnet
'
|
'
poa_sokol
'
|
'
artis_sigma1
'
|
'
lukso_l14
'
|
'
astar
'
|
'
shiden
'
|
'
shibuya
'
|
'
goerli
'
;
export
interface
FeaturedNetwork
{
export
interface
FeaturedNetwork
{
title
:
string
;
title
:
string
;
...
...
ui/snippets/networkMenu/NetworkLogo.tsx
View file @
32f12eee
...
@@ -11,6 +11,7 @@ import astarLogo from 'icons/networks/logos/astar.svg';
...
@@ -11,6 +11,7 @@ import astarLogo from 'icons/networks/logos/astar.svg';
import
etcLogo
from
'
icons/networks/logos/etc.svg
'
;
import
etcLogo
from
'
icons/networks/logos/etc.svg
'
;
import
ethLogo
from
'
icons/networks/logos/eth.svg
'
;
import
ethLogo
from
'
icons/networks/logos/eth.svg
'
;
import
gnosisLogo
from
'
icons/networks/logos/gnosis.svg
'
;
import
gnosisLogo
from
'
icons/networks/logos/gnosis.svg
'
;
import
goerliIcon
from
'
icons/networks/logos/goerli.svg
'
;
import
luksoLogo
from
'
icons/networks/logos/lukso.svg
'
;
import
luksoLogo
from
'
icons/networks/logos/lukso.svg
'
;
import
poaLogo
from
'
icons/networks/logos/poa.svg
'
;
import
poaLogo
from
'
icons/networks/logos/poa.svg
'
;
import
rskLogo
from
'
icons/networks/logos/rsk.svg
'
;
import
rskLogo
from
'
icons/networks/logos/rsk.svg
'
;
...
@@ -34,6 +35,7 @@ const LOGOS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
...
@@ -34,6 +35,7 @@ const LOGOS: Partial<Record<PreDefinedNetwork, React.FunctionComponent<React.SVG
astar
:
astarLogo
,
astar
:
astarLogo
,
shiden
:
shidenLogo
,
shiden
:
shidenLogo
,
shibuya
:
shibuyaLogo
,
shibuya
:
shibuyaLogo
,
goerli
:
goerliIcon
,
};
};
interface
Props
{
interface
Props
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment