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
4a98a541
Commit
4a98a541
authored
Aug 16, 2025
by
adadachao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mars up
parent
5f396d14
Changes
22
Show whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
67 additions
and
59 deletions
+67
-59
chain.ts
configs/app/chain.ts
+2
-1
.env.base
configs/envs/.env.base
+2
-2
.env.localhost
configs/envs/.env.localhost
+2
-2
units.ts
lib/units.ts
+1
-1
NovesTranslate.ts
stubs/noves/NovesTranslate.ts
+3
-3
stats.ts
stubs/stats.ts
+4
-4
zkEvmL2.ts
stubs/zkEvmL2.ts
+2
-2
ContractDetailsAlertProxyPattern.tsx
...ress/contract/alerts/ContractDetailsAlertProxyPattern.tsx
+22
-15
ContractDetailsAlertVerificationSource.tsx
...ontract/alerts/ContractDetailsAlertVerificationSource.tsx
+1
-8
ContractDetailsInfo.tsx
ui/address/contract/info/ContractDetailsInfo.tsx
+2
-2
EthRpcApi.tsx
ui/apiDocs/EthRpcApi.tsx
+2
-3
RpcApi.tsx
ui/apiDocs/RpcApi.tsx
+2
-2
ApiDocs.tsx
ui/pages/ApiDocs.tsx
+1
-1
CopyToClipboard.tsx
ui/shared/CopyToClipboard.tsx
+2
-2
ChartWidget.pw.tsx
ui/shared/chart/ChartWidget.pw.tsx
+1
-1
AddressEntity.tsx
ui/shared/entities/address/AddressEntity.tsx
+1
-1
AddressEntityContentProxy.tsx
ui/shared/entities/address/AddressEntityContentProxy.tsx
+3
-3
CodeEditor.tsx
ui/shared/monaco/CodeEditor.tsx
+5
-1
useQueryWithPages.ts
ui/shared/pagination/useQueryWithPages.ts
+1
-1
ChartWidgetContainer.tsx
ui/stats/ChartWidgetContainer.tsx
+4
-0
NumberWidgetsList.tsx
ui/stats/NumberWidgetsList.tsx
+1
-1
generateFlowViewData.test.ts
ui/tx/assetFlows/utils/generateFlowViewData.test.ts
+3
-3
No files found.
configs/app/chain.ts
View file @
4a98a541
...
@@ -46,7 +46,8 @@ const chain = Object.freeze({
...
@@ -46,7 +46,8 @@ const chain = Object.freeze({
symbol
:
getEnvValue
(
'
NEXT_PUBLIC_NETWORK_SECONDARY_COIN_SYMBOL
'
),
symbol
:
getEnvValue
(
'
NEXT_PUBLIC_NETWORK_SECONDARY_COIN_SYMBOL
'
),
},
},
hasMultipleGasCurrencies
:
getEnvValue
(
'
NEXT_PUBLIC_NETWORK_MULTIPLE_GAS_CURRENCIES
'
)
===
'
true
'
,
hasMultipleGasCurrencies
:
getEnvValue
(
'
NEXT_PUBLIC_NETWORK_MULTIPLE_GAS_CURRENCIES
'
)
===
'
true
'
,
tokenStandard
:
getEnvValue
(
'
NEXT_PUBLIC_NETWORK_TOKEN_STANDARD_NAME
'
)
||
'
ERC
'
,
// tokenStandard: getEnvValue('NEXT_PUBLIC_NETWORK_TOKEN_STANDARD_NAME') || 'MRC',
tokenStandard
:
'
MRC
'
,
rpcUrls
,
rpcUrls
,
isTestnet
:
getEnvValue
(
'
NEXT_PUBLIC_IS_TESTNET
'
)
===
'
true
'
,
isTestnet
:
getEnvValue
(
'
NEXT_PUBLIC_IS_TESTNET
'
)
===
'
true
'
,
verificationType
,
verificationType
,
...
...
configs/envs/.env.base
View file @
4a98a541
...
@@ -11,8 +11,8 @@ NEXT_PUBLIC_API_WEBSOCKET_PROTOCOL=wss
...
@@ -11,8 +11,8 @@ NEXT_PUBLIC_API_WEBSOCKET_PROTOCOL=wss
# Instance ENVs
# Instance ENVs
NEXT_PUBLIC_ADMIN_SERVICE_API_HOST=https://admin-rs.services.blockscout.com
NEXT_PUBLIC_ADMIN_SERVICE_API_HOST=https://admin-rs.services.blockscout.com
NEXT_PUBLIC_API_BASE_PATH=
https://scan.mova.bitheart.org
/
NEXT_PUBLIC_API_BASE_PATH=/
NEXT_PUBLIC_API_HOST=scan.m
ova.bitheart.org
NEXT_PUBLIC_API_HOST=scan.m
ars.movachain.com
NEXT_PUBLIC_API_SPEC_URL=https://raw.githubusercontent.com/blockscout/blockscout-api-v2-swagger/main/swagger.yaml
NEXT_PUBLIC_API_SPEC_URL=https://raw.githubusercontent.com/blockscout/blockscout-api-v2-swagger/main/swagger.yaml
NEXT_PUBLIC_CONTRACT_CODE_IDES=[{'title':'Remix IDE','url':'https://remix.ethereum.org/?address={hash}&blockscout={domain}','icon_url':'https://raw.githubusercontent.com/blockscout/frontend-configs/main/configs/ide-icons/remix.png'}]
NEXT_PUBLIC_CONTRACT_CODE_IDES=[{'title':'Remix IDE','url':'https://remix.ethereum.org/?address={hash}&blockscout={domain}','icon_url':'https://raw.githubusercontent.com/blockscout/frontend-configs/main/configs/ide-icons/remix.png'}]
NEXT_PUBLIC_CONTRACT_INFO_API_HOST=https://contracts-info.services.blockscout.com
NEXT_PUBLIC_CONTRACT_INFO_API_HOST=https://contracts-info.services.blockscout.com
...
...
configs/envs/.env.localhost
View file @
4a98a541
...
@@ -17,8 +17,8 @@ NEXT_PUBLIC_NETWORK_CURRENCY_DECIMALS=18
...
@@ -17,8 +17,8 @@ NEXT_PUBLIC_NETWORK_CURRENCY_DECIMALS=18
NEXT_PUBLIC_NETWORK_VERIFICATION_TYPE=validation
NEXT_PUBLIC_NETWORK_VERIFICATION_TYPE=validation
NEXT_PUBLIC_NETWORK_RPC_URL=https://rpc.mova.bitheart.org
NEXT_PUBLIC_NETWORK_RPC_URL=https://rpc.mova.bitheart.org
# api configuration
# api configuration
NEXT_PUBLIC_API_BASE_PATH=
https://scan.mova.bitheart.org/
NEXT_PUBLIC_API_BASE_PATH=
NEXT_PUBLIC_API_HOST=
localhost
NEXT_PUBLIC_API_HOST=
scan.mars.movachain.com
NEXT_PUBLIC_API_PROTOCOL=http
NEXT_PUBLIC_API_PROTOCOL=http
NEXT_PUBLIC_API_PORT=3001
NEXT_PUBLIC_API_PORT=3001
...
...
lib/units.ts
View file @
4a98a541
...
@@ -7,5 +7,5 @@ const weiName = config.chain.currency.weiName || 'wei';
...
@@ -7,5 +7,5 @@ const weiName = config.chain.currency.weiName || 'wei';
export
const
currencyUnits
:
Record
<
Unit
,
string
>
=
{
export
const
currencyUnits
:
Record
<
Unit
,
string
>
=
{
wei
:
weiName
,
wei
:
weiName
,
gwei
:
`G
${
weiName
}
`
,
gwei
:
`G
${
weiName
}
`
,
ether
:
config
.
chain
.
currency
.
symbol
||
'
ETH
'
,
ether
:
config
.
chain
.
currency
.
symbol
||
'
MARS
'
,
};
};
stubs/noves/NovesTranslate.ts
View file @
4a98a541
import
type
{
NovesResponseData
,
NovesClassificationData
,
NovesRawTransactionData
}
from
'
types/api/noves
'
;
import
type
{
NovesResponseData
,
NovesClassificationData
,
NovesRawTransactionData
}
from
'
types/api/noves
'
;
const
NOVES_TRANSLATE_CLASSIFIED
:
NovesClassificationData
=
{
const
NOVES_TRANSLATE_CLASSIFIED
:
NovesClassificationData
=
{
description
:
'
Sent 0.04
ETH
'
,
description
:
'
Sent 0.04
MARS
'
,
received
:
[
{
received
:
[
{
action
:
'
Sent Token
'
,
action
:
'
Sent Token
'
,
actionFormatted
:
'
Sent Token
'
,
actionFormatted
:
'
Sent Token
'
,
...
@@ -10,8 +10,8 @@ const NOVES_TRANSLATE_CLASSIFIED: NovesClassificationData = {
...
@@ -10,8 +10,8 @@ const NOVES_TRANSLATE_CLASSIFIED: NovesClassificationData = {
to
:
{
name
:
''
,
address
:
'
0xa0393A76b132526a70450273CafeceB45eea6dEE
'
},
to
:
{
name
:
''
,
address
:
'
0xa0393A76b132526a70450273CafeceB45eea6dEE
'
},
token
:
{
token
:
{
address
:
''
,
address
:
''
,
name
:
'
ETH
'
,
name
:
'
MARS
'
,
symbol
:
'
ETH
'
,
symbol
:
'
MARS
'
,
decimals
:
18
,
decimals
:
18
,
},
},
}
],
}
],
...
...
stubs/stats.ts
View file @
4a98a541
...
@@ -45,8 +45,8 @@ export const HOMEPAGE_STATS: HomeStats = {
...
@@ -45,8 +45,8 @@ export const HOMEPAGE_STATS: HomeStats = {
const
STATS_CHART_INFO
:
stats
.
LineChartInfo
=
{
const
STATS_CHART_INFO
:
stats
.
LineChartInfo
=
{
id
:
'
chart_0
'
,
id
:
'
chart_0
'
,
title
:
'
Average transaction fee
'
,
title
:
'
Average transaction fee
'
,
description
:
'
The average amount in
ETH
spent per transaction
'
,
description
:
'
The average amount in
MARS
spent per transaction
'
,
units
:
'
ETH
'
,
units
:
'
MARS
'
,
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
};
};
...
@@ -59,7 +59,7 @@ export const STATS_CHARTS_SECTION: stats.LineChartSection = {
...
@@ -59,7 +59,7 @@ export const STATS_CHARTS_SECTION: stats.LineChartSection = {
id
:
'
chart_1
'
,
id
:
'
chart_1
'
,
title
:
'
Transactions fees
'
,
title
:
'
Transactions fees
'
,
description
:
'
Amount of tokens paid as fees
'
,
description
:
'
Amount of tokens paid as fees
'
,
units
:
'
ETH
'
,
units
:
'
MARS
'
,
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
},
},
{
{
...
@@ -86,7 +86,7 @@ export const STATS_CHARTS_SECTION_GAS: stats.LineChartSection = {
...
@@ -86,7 +86,7 @@ export const STATS_CHARTS_SECTION_GAS: stats.LineChartSection = {
id
:
'
averageGasPrice
'
,
id
:
'
averageGasPrice
'
,
title
:
'
Average gas price
'
,
title
:
'
Average gas price
'
,
description
:
'
Average gas price
'
,
description
:
'
Average gas price
'
,
units
:
'
ETH
'
,
units
:
'
MARS
'
,
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
resolutions
:
[
'
DAY
'
,
'
MONTH
'
],
}
],
}
],
};
};
...
...
stubs/zkEvmL2.ts
View file @
4a98a541
...
@@ -7,7 +7,7 @@ export const ZKEVM_DEPOSITS_ITEM: ZkEvmL2DepositsItem = {
...
@@ -7,7 +7,7 @@ export const ZKEVM_DEPOSITS_ITEM: ZkEvmL2DepositsItem = {
index
:
181920
,
index
:
181920
,
l1_transaction_hash
:
'
0xa74edfa5824a07a5f95ca1145140ed589df7f05bb17796bf18090b14c4566b5d
'
,
l1_transaction_hash
:
'
0xa74edfa5824a07a5f95ca1145140ed589df7f05bb17796bf18090b14c4566b5d
'
,
l2_transaction_hash
:
'
0x436d1c7ada270466ca0facdb96ecc22934d68d13b8a08f541b8df11b222967b5
'
,
l2_transaction_hash
:
'
0x436d1c7ada270466ca0facdb96ecc22934d68d13b8a08f541b8df11b222967b5
'
,
symbol
:
'
ETH
'
,
symbol
:
'
MARS
'
,
timestamp
:
'
2023-06-01T14:46:48.000000Z
'
,
timestamp
:
'
2023-06-01T14:46:48.000000Z
'
,
value
:
'
0.13040262
'
,
value
:
'
0.13040262
'
,
};
};
...
@@ -17,7 +17,7 @@ export const ZKEVM_WITHDRAWALS_ITEM: ZkEvmL2WithdrawalsItem = {
...
@@ -17,7 +17,7 @@ export const ZKEVM_WITHDRAWALS_ITEM: ZkEvmL2WithdrawalsItem = {
index
:
47003
,
index
:
47003
,
l1_transaction_hash
:
'
0x230cf46dabea287ac7d0ba83b8ea120bb83c1de58a81d34f44788f0459096c52
'
,
l1_transaction_hash
:
'
0x230cf46dabea287ac7d0ba83b8ea120bb83c1de58a81d34f44788f0459096c52
'
,
l2_transaction_hash
:
'
0x519d9f025ec47f08a48d708964d177189d2246ddf988686c481f5debcf097e34
'
,
l2_transaction_hash
:
'
0x519d9f025ec47f08a48d708964d177189d2246ddf988686c481f5debcf097e34
'
,
symbol
:
'
ETH
'
,
symbol
:
'
MARS
'
,
timestamp
:
'
2024-04-17T08:51:58.000000Z
'
,
timestamp
:
'
2024-04-17T08:51:58.000000Z
'
,
value
:
'
110.35
'
,
value
:
'
110.35
'
,
};
};
...
...
ui/address/contract/alerts/ContractDetailsAlertProxyPattern.tsx
View file @
4a98a541
...
@@ -16,39 +16,46 @@ const PROXY_TYPES: Partial<Record<NonNullable<SmartContractProxyType>, {
...
@@ -16,39 +16,46 @@ const PROXY_TYPES: Partial<Record<NonNullable<SmartContractProxyType>, {
description
?:
string
;
description
?:
string
;
}
>>
=
{
}
>>
=
{
eip1167
:
{
eip1167
:
{
name
:
'
EIP-1167
'
,
name
:
'
MRC-1167
'
,
link
:
'
https://eips.ethereum.org/EIPS/eip-1167
'
,
// link: 'https://eips.ethereum.org/EIPS/eip-1167',
link
:
''
,
description
:
'
Minimal proxy
'
,
description
:
'
Minimal proxy
'
,
},
},
eip1967
:
{
eip1967
:
{
name
:
'
EIP-1967
'
,
name
:
'
MRC-1967
'
,
link
:
'
https://eips.ethereum.org/EIPS/eip-1967
'
,
// link: 'https://eips.ethereum.org/EIPS/eip-1967',
link
:
''
,
description
:
'
Proxy storage slots
'
,
description
:
'
Proxy storage slots
'
,
},
},
eip1822
:
{
eip1822
:
{
name
:
'
EIP-1822
'
,
name
:
'
MRC-1822
'
,
link
:
'
https://eips.ethereum.org/EIPS/eip-1822
'
,
// link: 'https://eips.ethereum.org/EIPS/eip-1822',
link
:
''
,
description
:
'
Universal upgradeable proxy standard (UUPS)
'
,
description
:
'
Universal upgradeable proxy standard (UUPS)
'
,
},
},
eip2535
:
{
eip2535
:
{
name
:
'
EIP-2535
'
,
name
:
'
MRC-2535
'
,
link
:
'
https://eips.ethereum.org/EIPS/eip-2535
'
,
// link: 'https://eips.ethereum.org/EIPS/eip-2535',
link
:
''
,
description
:
'
Diamond proxy
'
,
description
:
'
Diamond proxy
'
,
},
},
eip930
:
{
eip930
:
{
name
:
'
ERC-930
'
,
name
:
'
MRC-930
'
,
link
:
'
https://github.com/ethereum/EIPs/issues/930
'
,
// link: 'https://github.com/ethereum/EIPs/issues/930',
link
:
''
,
description
:
'
Eternal storage
'
,
description
:
'
Eternal storage
'
,
},
},
erc7760
:
{
erc7760
:
{
name
:
'
ERC-7760
'
,
name
:
'
MRC-7760
'
,
link
:
'
https://eips.ethereum.org/EIPS/eip-7760
'
,
// link: 'https://eips.ethereum.org/EIPS/eip-7760',
link
:
''
,
description
:
'
Minimal Upgradeable Proxies
'
,
description
:
'
Minimal Upgradeable Proxies
'
,
},
},
resolved_delegate_proxy
:
{
resolved_delegate_proxy
:
{
name
:
'
ResolvedDelegateProxy
'
,
name
:
'
ResolvedDelegateProxy
'
,
// eslint-disable-next-line max-len
// eslint-disable-next-line max-len
link
:
'
https://github.com/ethereum-optimism/optimism/blob/9580179013a04b15e6213ae8aa8d43c3f559ed9a/packages/contracts-bedrock/src/legacy/ResolvedDelegateProxy.sol
'
,
// link: 'https://github.com/ethereum-optimism/optimism/blob/9580179013a04b15e6213ae8aa8d43c3f559ed9a/packages/contracts-bedrock/src/legacy/ResolvedDelegateProxy.sol',
link
:
''
,
description
:
'
OP stack: legacy proxy contract that makes use of the AddressManager to resolve the implementation address
'
,
description
:
'
OP stack: legacy proxy contract that makes use of the AddressManager to resolve the implementation address
'
,
},
},
clone_with_immutable_arguments
:
{
clone_with_immutable_arguments
:
{
...
@@ -85,12 +92,12 @@ const ContractCodeProxyPattern = ({ type, isLoading }: Props) => {
...
@@ -85,12 +92,12 @@ const ContractCodeProxyPattern = ({ type, isLoading }: Props) => {
<
Alert
status=
"warning"
whiteSpace=
"pre-wrap"
loading=
{
isLoading
}
>
<
Alert
status=
"warning"
whiteSpace=
"pre-wrap"
loading=
{
isLoading
}
>
{
proxyInfo
.
link
?
(
{
proxyInfo
.
link
?
(
<>
<>
This proxy smart-contract is detected via
<
Link
href=
{
proxyInfo
.
link
}
external
>
{
proxyInfo
.
name
}
</
Link
>
This proxy smart-contract is detected via
<
Link
href=
{
proxyInfo
.
link
}
external
>
{
proxyInfo
.
name
?.
replace
(
/ERC/g
,
'
MRC
'
)
}
</
Link
>
{
proxyInfo
.
description
&&
` - ${ proxyInfo.description }`
}
{
proxyInfo
.
description
&&
` - ${ proxyInfo.description }`
}
</>
</>
)
:
(
)
:
(
<>
<>
This proxy smart-contract is detected via
{
proxyInfo
.
name
}
This proxy smart-contract is detected via
{
proxyInfo
.
name
?.
replace
(
/ERC/g
,
'
MRC
'
)
}
{
proxyInfo
.
description
&&
` - ${ proxyInfo.description }`
}
{
proxyInfo
.
description
&&
` - ${ proxyInfo.description }`
}
</>
</>
)
}
)
}
...
...
ui/address/contract/alerts/ContractDetailsAlertVerificationSource.tsx
View file @
4a98a541
...
@@ -13,14 +13,7 @@ const ContractDetailsAlertVerificationSource = ({ data }: Props) => {
...
@@ -13,14 +13,7 @@ const ContractDetailsAlertVerificationSource = ({ data }: Props) => {
if
(
data
?.
is_verified
&&
data
?.
is_verified_via_eth_bytecode_db
)
{
if
(
data
?.
is_verified
&&
data
?.
is_verified_via_eth_bytecode_db
)
{
return
(
return
(
<
Alert
status=
"warning"
whiteSpace=
"pre-wrap"
>
<
Alert
status=
"warning"
whiteSpace=
"pre-wrap"
>
<
span
>
This contract has been
{
data
.
is_partially_verified
?
'
partially
'
:
''
}
verified using
</
span
>
<
span
>
This contract has been
{
data
.
is_partially_verified
?
'
partially
'
:
''
}
verified using MovaChain Bytecode Database
</
span
>
<
Link
href=
"https://docs.blockscout.com/about/features/ethereum-bytecode-database-microservice"
textStyle=
"md"
external
>
Blockscout Bytecode Database
</
Link
>
</
Alert
>
</
Alert
>
);
);
}
}
...
...
ui/address/contract/info/ContractDetailsInfo.tsx
View file @
4a98a541
...
@@ -24,7 +24,7 @@ interface Props {
...
@@ -24,7 +24,7 @@ interface Props {
const
ContractDetailsInfo
=
({
data
,
isLoading
,
addressHash
}:
Props
)
=>
{
const
ContractDetailsInfo
=
({
data
,
isLoading
,
addressHash
}:
Props
)
=>
{
const
contractNameWithCertifiedIcon
=
data
?
(
const
contractNameWithCertifiedIcon
=
data
?
(
<
Flex
alignItems=
"center"
>
<
Flex
alignItems=
"center"
>
{
data
.
name
}
{
data
.
name
?.
replace
(
/ERC/g
,
'
MRC
'
)
}
{
data
.
certified
&&
<
ContractCertifiedLabel
iconSize=
{
5
}
boxSize=
{
5
}
ml=
{
2
}
/>
}
{
data
.
certified
&&
<
ContractCertifiedLabel
iconSize=
{
5
}
boxSize=
{
5
}
ml=
{
2
}
/>
}
</
Flex
>
</
Flex
>
)
:
null
;
)
:
null
;
...
@@ -148,7 +148,7 @@ const ContractDetailsInfo = ({ data, isLoading, addressHash }: Props) => {
...
@@ -148,7 +148,7 @@ const ContractDetailsInfo = ({ data, isLoading, addressHash }: Props) => {
wordBreak=
"break-word"
wordBreak=
"break-word"
isLoading=
{
isLoading
}
isLoading=
{
isLoading
}
>
>
{
data
.
file_path
}
{
data
.
file_path
?.
replace
(
/ERC/g
,
'
MRC
'
)
}
</
ContractDetailsInfoItem
>
</
ContractDetailsInfoItem
>
)
}
)
}
{
sourceCodeLink
&&
(
{
sourceCodeLink
&&
(
...
...
ui/apiDocs/EthRpcApi.tsx
View file @
4a98a541
...
@@ -8,10 +8,9 @@ const EthRpcApi = () => {
...
@@ -8,10 +8,9 @@ const EthRpcApi = () => {
<
Box
>
<
Box
>
<
Text
>
<
Text
>
In addition to the custom RPC endpoints documented here,
In addition to the custom RPC endpoints documented here,
the Blockscout ETH RPC API supports 3 methods in the exact format specified for Ethereum nodes,
the Mova chain RPC API supports 3 methods in the exact format specified for Mova chain nodes, see the JSON-RPC Specification for more details.
ee the Ethereum JSON-RPC Specification for more details.
</
Text
>
</
Text
>
<
Link
href=
"https://docs.
blockscout.com/for-users/api/eth-rpc
"
external
mt=
{
6
}
>
View examples
</
Link
>
<
Link
href=
"https://docs.
movachain.com/json-rpc-api
"
external
mt=
{
6
}
>
View examples
</
Link
>
</
Box
>
</
Box
>
);
);
};
};
...
...
ui/apiDocs/RpcApi.tsx
View file @
4a98a541
...
@@ -7,10 +7,10 @@ const RpcApi = () => {
...
@@ -7,10 +7,10 @@ const RpcApi = () => {
return
(
return
(
<
Box
>
<
Box
>
<
Text
>
<
Text
>
This API is provided for developers transitioning applications
from Etherscan to BlockScout
and applications requiring general API and data support.
This API is provided for developers transitioning applications and applications requiring general API and data support.
It supports GET and POST requests.
It supports GET and POST requests.
</
Text
>
</
Text
>
<
Link
href=
"https://docs.
blockscout.com/for-users/api/
rpc-endpoints"
external
mt=
{
6
}
>
View modules
</
Link
>
<
Link
href=
"https://docs.
movachain.com/mova-
rpc-endpoints"
external
mt=
{
6
}
>
View modules
</
Link
>
</
Box
>
</
Box
>
);
);
};
};
...
...
ui/pages/ApiDocs.tsx
View file @
4a98a541
...
@@ -18,7 +18,7 @@ const ApiDocs = () => {
...
@@ -18,7 +18,7 @@ const ApiDocs = () => {
const
tabs
:
Array
<
TabItemRegular
>
=
[
const
tabs
:
Array
<
TabItemRegular
>
=
[
{
id
:
'
rest_api
'
,
title
:
'
REST API
'
,
component
:
<
RestApi
/>,
count
:
REST_API_SECTIONS
.
length
},
{
id
:
'
rest_api
'
,
title
:
'
REST API
'
,
component
:
<
RestApi
/>,
count
:
REST_API_SECTIONS
.
length
},
{
id
:
'
eth_rpc_api
'
,
title
:
'
ETH
RPC API
'
,
component
:
<
EthRpcApi
/>
},
{
id
:
'
eth_rpc_api
'
,
title
:
'
MARS
RPC API
'
,
component
:
<
EthRpcApi
/>
},
{
id
:
'
rpc_api
'
,
title
:
'
RPC API endpoints
'
,
component
:
<
RpcApi
/>
},
{
id
:
'
rpc_api
'
,
title
:
'
RPC API endpoints
'
,
component
:
<
RpcApi
/>
},
{
id
:
'
graphql_api
'
,
title
:
'
GraphQL API
'
,
component
:
<
GraphQL
/>
},
{
id
:
'
graphql_api
'
,
title
:
'
GraphQL API
'
,
component
:
<
GraphQL
/>
},
].
filter
(({
id
})
=>
feature
.
isEnabled
&&
feature
.
tabs
.
includes
(
id
));
].
filter
(({
id
})
=>
feature
.
isEnabled
&&
feature
.
tabs
.
includes
(
id
));
...
...
ui/shared/CopyToClipboard.tsx
View file @
4a98a541
...
@@ -18,8 +18,8 @@ export interface Props extends Omit<IconButtonProps, 'type' | 'loading'> {
...
@@ -18,8 +18,8 @@ export interface Props extends Omit<IconButtonProps, 'type' | 'loading'> {
const
CopyToClipboard
=
(
props
:
Props
)
=>
{
const
CopyToClipboard
=
(
props
:
Props
)
=>
{
const
{
text
,
type
=
'
text
'
,
isLoading
,
onClick
,
boxSize
=
5
,
noTooltip
,
tooltipInteractive
,
...
rest
}
=
props
;
const
{
text
,
type
=
'
text
'
,
isLoading
,
onClick
,
boxSize
=
5
,
noTooltip
,
tooltipInteractive
,
...
rest
}
=
props
;
const
newText
=
text
.
replace
(
/ERC/g
,
'
MRC
'
);
const
{
hasCopied
,
copy
,
disclosure
}
=
useClipboard
(
t
ext
);
const
{
hasCopied
,
copy
,
disclosure
}
=
useClipboard
(
newT
ext
);
const
handleClick
=
React
.
useCallback
((
event
:
React
.
MouseEvent
<
HTMLButtonElement
,
MouseEvent
>
)
=>
{
const
handleClick
=
React
.
useCallback
((
event
:
React
.
MouseEvent
<
HTMLButtonElement
,
MouseEvent
>
)
=>
{
event
.
stopPropagation
();
event
.
stopPropagation
();
...
...
ui/shared/chart/ChartWidget.pw.tsx
View file @
4a98a541
...
@@ -25,7 +25,7 @@ const props: Props = {
...
@@ -25,7 +25,7 @@ const props: Props = {
],
],
title
:
'
Native coin circulating supply
'
,
title
:
'
Native coin circulating supply
'
,
description
:
'
Amount of token circulating supply for the period
'
,
description
:
'
Amount of token circulating supply for the period
'
,
units
:
'
ETH
'
,
units
:
'
MARS
'
,
isLoading
:
false
,
isLoading
:
false
,
isError
:
false
,
isError
:
false
,
noAnimation
:
true
,
noAnimation
:
true
,
...
...
ui/shared/entities/address/AddressEntity.tsx
View file @
4a98a541
...
@@ -139,7 +139,7 @@ const Content = chakra((props: ContentProps) => {
...
@@ -139,7 +139,7 @@ const Content = chakra((props: ContentProps) => {
const
label
=
(
const
label
=
(
<
VStack
gap=
{
0
}
py=
{
1
}
color=
"inherit"
>
<
VStack
gap=
{
0
}
py=
{
1
}
color=
"inherit"
>
<
Box
fontWeight=
{
600
}
whiteSpace=
"pre-wrap"
wordBreak=
"break-word"
>
{
nameText
}
</
Box
>
<
Box
fontWeight=
{
600
}
whiteSpace=
"pre-wrap"
wordBreak=
"break-word"
>
{
nameText
?.
replace
(
/ERC/g
,
'
MRC
'
)
}
</
Box
>
<
Box
whiteSpace=
"pre-wrap"
wordBreak=
"break-word"
>
<
Box
whiteSpace=
"pre-wrap"
wordBreak=
"break-word"
>
{
displayedAddress
}
{
displayedAddress
}
</
Box
>
</
Box
>
...
...
ui/shared/entities/address/AddressEntityContentProxy.tsx
View file @
4a98a541
...
@@ -23,7 +23,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
...
@@ -23,7 +23,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
<>
<>
<
Box
fontWeight=
{
600
}
>
<
Box
fontWeight=
{
600
}
>
Proxy contract
Proxy contract
{
props
.
address
.
name
?
` (${ props.address.name })`
:
''
}
{
props
.
address
.
name
?
` (${ props.address.name
.replace(/ERC/g, 'MRC')
})`
:
''
}
</
Box
>
</
Box
>
<
AddressEntity
<
AddressEntity
address=
{
{
hash
:
props
.
address
.
hash
,
filecoin
:
props
.
address
.
filecoin
}
}
address=
{
{
hash
:
props
.
address
.
hash
,
filecoin
:
props
.
address
.
filecoin
}
}
...
@@ -35,7 +35,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
...
@@ -35,7 +35,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
/>
/>
<
Box
fontWeight=
{
600
}
mt=
{
2
}
>
<
Box
fontWeight=
{
600
}
mt=
{
2
}
>
Implementation
{
implementations
.
length
>
1
?
'
s
'
:
''
}
Implementation
{
implementations
.
length
>
1
?
'
s
'
:
''
}
{
implementationName
?
` (${ implementationName })`
:
''
}
{
implementationName
?
` (${ implementationName
.replace(/ERC/g, 'MRC')
})`
:
''
}
</
Box
>
</
Box
>
<
Flex
flexWrap=
"wrap"
columnGap=
{
3
}
>
<
Flex
flexWrap=
"wrap"
columnGap=
{
3
}
>
{
implementations
.
map
((
item
)
=>
(
{
implementations
.
map
((
item
)
=>
(
...
@@ -61,7 +61,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
...
@@ -61,7 +61,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
<
EntityBase
.
Content
<
EntityBase
.
Content
{
...
props
}
{
...
props
}
truncation=
{
nameTag
||
implementationName
||
props
.
address
.
name
?
'
tail
'
:
props
.
truncation
}
truncation=
{
nameTag
||
implementationName
||
props
.
address
.
name
?
'
tail
'
:
props
.
truncation
}
text=
{
nameTag
||
implementationName
||
props
.
address
.
name
||
props
.
altHash
||
props
.
address
.
hash
}
text=
{
(
nameTag
||
implementationName
||
props
.
address
.
name
)?.
replace
(
/ERC/g
,
'
MRC
'
)
||
props
.
altHash
||
props
.
address
.
hash
}
noTooltip
noTooltip
/>
/>
</
Box
>
</
Box
>
...
...
ui/shared/monaco/CodeEditor.tsx
View file @
4a98a541
...
@@ -48,6 +48,10 @@ interface Props {
...
@@ -48,6 +48,10 @@ interface Props {
}
}
const
CodeEditor
=
({
data
,
remappings
,
libraries
,
language
,
mainFile
,
contractName
}:
Props
)
=>
{
const
CodeEditor
=
({
data
,
remappings
,
libraries
,
language
,
mainFile
,
contractName
}:
Props
)
=>
{
data
.
forEach
((
item
)
=>
{
item
.
file_path
=
item
.
file_path
.
replace
(
/ERC/g
,
'
MRC
'
);
item
.
source_code
=
item
.
source_code
.
replace
(
/ERC/g
,
'
MRC
'
);
});
const
[
instance
,
setInstance
]
=
React
.
useState
<
Monaco
|
undefined
>
();
const
[
instance
,
setInstance
]
=
React
.
useState
<
Monaco
|
undefined
>
();
const
[
editor
,
setEditor
]
=
React
.
useState
<
monaco
.
editor
.
IStandaloneCodeEditor
|
undefined
>
();
const
[
editor
,
setEditor
]
=
React
.
useState
<
monaco
.
editor
.
IStandaloneCodeEditor
|
undefined
>
();
const
[
index
,
setIndex
]
=
React
.
useState
(
0
);
const
[
index
,
setIndex
]
=
React
.
useState
(
0
);
...
@@ -302,7 +306,7 @@ const CodeEditor = ({ data, remappings, libraries, language, mainFile, contractN
...
@@ -302,7 +306,7 @@ const CodeEditor = ({ data, remappings, libraries, language, mainFile, contractN
<
Box
flexGrow=
{
1
}
>
<
Box
flexGrow=
{
1
}
>
<
CodeEditorTabs
<
CodeEditorTabs
tabs=
{
tabs
}
tabs=
{
tabs
}
activeTab=
{
data
[
index
].
file_path
}
activeTab=
{
data
[
index
]
?
.
file_path
}
mainFile=
{
mainFile
}
mainFile=
{
mainFile
}
onTabSelect=
{
handleTabSelect
}
onTabSelect=
{
handleTabSelect
}
onTabClose=
{
handleTabClose
}
onTabClose=
{
handleTabClose
}
...
...
ui/shared/pagination/useQueryWithPages.ts
View file @
4a98a541
...
@@ -185,7 +185,7 @@ export default function useQueryWithPages<Resource extends PaginatedResourceName
...
@@ -185,7 +185,7 @@ export default function useQueryWithPages<Resource extends PaginatedResourceName
Object
.
entries
(
newFilters
).
forEach
(([
key
,
value
])
=>
{
Object
.
entries
(
newFilters
).
forEach
(([
key
,
value
])
=>
{
const
isValidValue
=
typeof
value
===
'
boolean
'
||
(
value
&&
value
.
length
);
const
isValidValue
=
typeof
value
===
'
boolean
'
||
(
value
&&
value
.
length
);
if
(
isValidValue
)
{
if
(
isValidValue
)
{
newQuery
[
key
]
=
Array
.
isArray
(
value
)
?
value
.
join
(
'
,
'
)
:
(
String
(
value
)
||
''
);
newQuery
[
key
]
=
Array
.
isArray
(
value
)
?
value
.
join
(
'
,
'
)
.
replace
(
/ERC/g
,
'
MRC
'
)
:
(
String
(
value
).
replace
(
/ERC/g
,
'
MRC
'
)
||
''
);
}
}
});
});
}
}
...
...
ui/stats/ChartWidgetContainer.tsx
View file @
4a98a541
...
@@ -34,6 +34,10 @@ const ChartWidgetContainer = ({
...
@@ -34,6 +34,10 @@ const ChartWidgetContainer = ({
href
,
href
,
}:
Props
)
=>
{
}:
Props
)
=>
{
const
{
items
,
lineQuery
}
=
useChartQuery
(
id
,
Resolution
.
DAY
,
interval
,
!
isPlaceholderData
);
const
{
items
,
lineQuery
}
=
useChartQuery
(
id
,
Resolution
.
DAY
,
interval
,
!
isPlaceholderData
);
// title 替换掉字符串中ETH
title
=
title
.
replace
(
'
ETH
'
,
'
MARS
'
);
description
=
description
.
replace
(
'
ETH
'
,
'
MARS
'
);
units
=
units
?.
replace
(
'
ETH
'
,
'
MARS
'
);
useEffect
(()
=>
{
useEffect
(()
=>
{
if
(
lineQuery
.
isError
)
{
if
(
lineQuery
.
isError
)
{
...
...
ui/stats/NumberWidgetsList.tsx
View file @
4a98a541
...
@@ -32,7 +32,7 @@ const NumberWidgetsList = () => {
...
@@ -32,7 +32,7 @@ const NumberWidgetsList = () => {
if
(
units
&&
UNITS_WITHOUT_SPACE
.
includes
(
units
))
{
if
(
units
&&
UNITS_WITHOUT_SPACE
.
includes
(
units
))
{
unitsStr
=
units
;
unitsStr
=
units
;
}
else
if
(
units
)
{
}
else
if
(
units
)
{
unitsStr
=
'
'
+
units
;
unitsStr
=
units
===
'
ETH
'
?
'
MARS
'
:
'
'
+
units
;
}
}
return
(
return
(
...
...
ui/tx/assetFlows/utils/generateFlowViewData.test.ts
View file @
4a98a541
...
@@ -31,10 +31,10 @@ it('creates asset flows items', async() => {
...
@@ -31,10 +31,10 @@ it('creates asset flows items', async() => {
amount
:
'
0.000395521502109448
'
,
amount
:
'
0.000395521502109448
'
,
flowDirection
:
'
toRight
'
,
flowDirection
:
'
toRight
'
,
token
:
{
token
:
{
address
:
'
ETH
'
,
address
:
'
MARS
'
,
decimals
:
18
,
decimals
:
18
,
name
:
'
ETH
'
,
name
:
'
MARS
'
,
symbol
:
'
ETH
'
,
symbol
:
'
MARS
'
,
},
},
},
},
rightActor
:
{
rightActor
:
{
...
...
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