chore: usage of goerli removed
This commit is contained in:
parent
b279bcedc2
commit
f6055946d4
|
@ -30,7 +30,7 @@ inline const auto Websocket = u"wss/p2p/waku"_qs;
|
|||
namespace General
|
||||
{
|
||||
inline const auto DefaultNetworkName = u"mainnet_rpc"_qs;
|
||||
//const DEFAULT_NETWORKS_IDS* = @["mainnet_rpc", "testnet_rpc", "rinkeby_rpc", "goerli_rpc", "xdai_rpc", "poa_rpc" ]
|
||||
//const DEFAULT_NETWORKS_IDS* = @["mainnet_rpc", "testnet_rpc", "rinkeby_rpc", "xdai_rpc", "poa_rpc" ]
|
||||
|
||||
inline const auto ZeroAddress = u"0x0000000000000000000000000000000000000000"_qs;
|
||||
|
||||
|
|
|
@ -14,21 +14,6 @@
|
|||
"layer": 1,
|
||||
"enabled": true
|
||||
},
|
||||
{
|
||||
"chainId": 5,
|
||||
"chainName": "Goerli",
|
||||
"rpcUrl": "https://goerli.infura.io/v3/%INFURA_TOKEN_RESOLVED%",
|
||||
"blockExplorerUrl": "https://goerli.etherscan.io/",
|
||||
"iconUrl": "network/Network=Testnet",
|
||||
"chainColor": "#939BA1",
|
||||
"shortName": "goeEth",
|
||||
"nativeCurrencyName": "Ether",
|
||||
"nativeCurrencySymbol": "ETH",
|
||||
"nativeCurrencyDecimals": 18,
|
||||
"isTest": true,
|
||||
"layer": 1,
|
||||
"enabled": true
|
||||
},
|
||||
{
|
||||
"chainId": 10,
|
||||
"chainName": "Optimism",
|
||||
|
@ -44,21 +29,6 @@
|
|||
"layer": 2,
|
||||
"enabled": true
|
||||
},
|
||||
{
|
||||
"chainId": 420,
|
||||
"chainName": "Optimism Goerli Testnet",
|
||||
"rpcUrl": "https://optimism-goerli.infura.io/v3/%INFURA_TOKEN_RESOLVED%",
|
||||
"blockExplorerUrl": "https://goerli-optimism.etherscan.io/",
|
||||
"iconUrl": "network/Network=Testnet",
|
||||
"chainColor": "#939BA1",
|
||||
"shortName": "goerOpt",
|
||||
"nativeCurrencyName": "Ether",
|
||||
"nativeCurrencySymbol": "ETH",
|
||||
"nativeCurrencyDecimals": 18,
|
||||
"isTest": true,
|
||||
"layer": 2,
|
||||
"enabled": false
|
||||
},
|
||||
{
|
||||
"chainId": 42161,
|
||||
"chainName": "Arbitrum",
|
||||
|
@ -73,20 +43,5 @@
|
|||
"isTest": false,
|
||||
"layer": 2,
|
||||
"enabled": true
|
||||
},
|
||||
{
|
||||
"chainId": 421613,
|
||||
"chainName": "Arbitrum Goerli",
|
||||
"rpcUrl": "https://arbitrum-goerli.infura.io/v3/%INFURA_TOKEN_RESOLVED%",
|
||||
"blockExplorerUrl": "https://goerli.arbiscan.io/",
|
||||
"iconUrl": "network/Network=Testnet",
|
||||
"chainColor": "#939BA1",
|
||||
"shortName": "rinArb",
|
||||
"nativeCurrencyName": "Ether",
|
||||
"nativeCurrencySymbol": "ETH",
|
||||
"nativeCurrencyDecimals": 18,
|
||||
"isTest": true,
|
||||
"layer": 2,
|
||||
"enabled": false
|
||||
}
|
||||
]
|
||||
|
|
|
@ -34,7 +34,7 @@ proc delete*(self: Controller) =
|
|||
|
||||
proc init*(self: Controller) =
|
||||
self.events.on(SIGNAL_WALLET_ACCOUNT_NETWORK_ENABLED_UPDATED) do(e: Args):
|
||||
self.delegate.refreshNetworks()
|
||||
self.delegate.refreshNetworks()
|
||||
|
||||
self.events.on(SIGNAL_WALLET_ACCOUNT_CHAIN_ID_FOR_URL_FETCHED) do(e: Args):
|
||||
let args = ChainIdForUrlArgs(e)
|
||||
|
@ -58,12 +58,6 @@ proc areTestNetworksEnabled*(self: Controller): bool =
|
|||
proc toggleTestNetworksEnabled*(self: Controller) =
|
||||
self.walletAccountService.toggleTestNetworksEnabled()
|
||||
|
||||
proc isGoerliEnabled*(self: Controller): bool =
|
||||
return self.walletAccountService.isGoerliEnabled()
|
||||
|
||||
proc toggleIsGoerliEnabled*(self: Controller) =
|
||||
self.walletAccountService.toggleIsGoerliEnabled()
|
||||
|
||||
proc updateNetworkEndPointValues*(self: Controller, chainId: int, testNetwork: bool, newMainRpcInput, newFailoverRpcUrl: string, revertToDefault: bool) =
|
||||
self.networkService.updateNetworkEndPointValues(chainId, testNetwork, newMainRpcInput, newFailoverRpcUrl, revertToDefault)
|
||||
|
||||
|
|
|
@ -29,9 +29,6 @@ method viewDidLoad*(self: AccessInterface) {.base.} =
|
|||
method toggleTestNetworksEnabled*(self: AccessInterface) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
method toggleIsGoerliEnabled*(self: AccessInterface) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
method setNetworksState*(self: AccessInterface, chainIds: seq[int], enable: bool) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
|
|
|
@ -66,10 +66,6 @@ method toggleTestNetworksEnabled*(self: Module) =
|
|||
self.controller.toggleTestNetworksEnabled()
|
||||
self.refreshNetworks()
|
||||
|
||||
method toggleIsGoerliEnabled*(self: Module) =
|
||||
self.controller.toggleIsGoerliEnabled()
|
||||
self.refreshNetworks()
|
||||
|
||||
method setNetworksState*(self: Module, chainIds: seq[int], enabled: bool) =
|
||||
self.controller.setNetworksState(chainIds, enabled)
|
||||
|
||||
|
|
|
@ -10,7 +10,6 @@ QtObject:
|
|||
combinedNetworks: CombinedModel
|
||||
areTestNetworksEnabled: bool
|
||||
enabledChainIds: string
|
||||
isGoerliEnabled: bool
|
||||
|
||||
proc setup(self: View) =
|
||||
self.QObject.setup
|
||||
|
@ -63,20 +62,6 @@ QtObject:
|
|||
read = getEnabledChainIds
|
||||
notify = enabledChainIdsChanged
|
||||
|
||||
proc isGoerliEnabledChanged*(self: View) {.signal.}
|
||||
proc getIsGoerliEnabled(self: View): bool {.slot.} =
|
||||
return self.isGoerliEnabled
|
||||
QtProperty[bool] isGoerliEnabled:
|
||||
read = getIsGoerliEnabled
|
||||
notify = isGoerliEnabledChanged
|
||||
|
||||
proc setIsGoerliEnabled*(self: View, IsGoerliEnabled: bool) =
|
||||
self.isGoerliEnabled = IsGoerliEnabled
|
||||
self.isGoerliEnabledChanged()
|
||||
|
||||
proc toggleIsGoerliEnabled*(self: View) {.slot.} =
|
||||
self.delegate.toggleIsGoerliEnabled()
|
||||
|
||||
proc refreshModel*(self: View) =
|
||||
self.flatNetworks.refreshModel()
|
||||
self.combinedNetworks.modelUpdated()
|
||||
|
@ -93,7 +78,7 @@ QtObject:
|
|||
|
||||
proc enableNetwork*(self: View, chainId: int) {.slot.} =
|
||||
self.delegate.setNetworksState(@[chainId], enable = true)
|
||||
|
||||
|
||||
proc getBlockExplorerURL*(self: View, chainId: int): string {.slot.} =
|
||||
return self.flatNetworks.getBlockExplorerURL(chainId)
|
||||
|
||||
|
|
|
@ -4,7 +4,6 @@ const
|
|||
ERC721_TRANSACTION_TYPE* = "erc721"
|
||||
|
||||
SNT_CONTRACT_ADDRESS* = "0x744d70fdbe2ba4cf95131626614a1763df805b9e"
|
||||
STT_CONTRACT_ADDRESS_GOERLI* = "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"
|
||||
STT_CONTRACT_ADDRESS_SEPOLIA* = "0xE452027cdEF746c7Cd3DB31CB700428b16cD8E51"
|
||||
|
||||
SIGNATURE_LEN* = 130
|
||||
|
|
|
@ -9,13 +9,10 @@ type
|
|||
raribleMainnetApiKey*: string
|
||||
raribleTestnetApiKey*: string
|
||||
alchemyEthereumMainnetToken*: string
|
||||
alchemyEthereumGoerliToken*: string
|
||||
alchemyEthereumSepoliaToken*: string
|
||||
alchemyArbitrumMainnetToken*: string
|
||||
alchemyArbitrumGoerliToken*: string
|
||||
alchemyArbitrumSepoliaToken*: string
|
||||
alchemyOptimismMainnetToken*: string
|
||||
alchemyOptimismGoerliToken*: string
|
||||
alchemyOptimismSepoliaToken*: string
|
||||
statusProxyStageName*: string
|
||||
statusProxyMarketUser*: string
|
||||
|
@ -32,13 +29,10 @@ proc toJson*(self: WalletSecretsConfig): JsonNode =
|
|||
"raribleMainnetApiKey": self.raribleMainnetApiKey,
|
||||
"raribleTestnetApiKey": self.raribleTestnetApiKey,
|
||||
"alchemyEthereumMainnetToken": self.alchemyEthereumMainnetToken,
|
||||
"alchemyEthereumGoerliToken": self.alchemyEthereumGoerliToken,
|
||||
"alchemyEthereumSepoliaToken": self.alchemyEthereumSepoliaToken,
|
||||
"alchemyArbitrumMainnetToken": self.alchemyArbitrumMainnetToken,
|
||||
"alchemyArbitrumGoerliToken": self.alchemyArbitrumGoerliToken,
|
||||
"alchemyArbitrumSepoliaToken": self.alchemyArbitrumSepoliaToken,
|
||||
"alchemyOptimismMainnetToken": self.alchemyOptimismMainnetToken,
|
||||
"alchemyOptimismGoerliToken": self.alchemyOptimismGoerliToken,
|
||||
"alchemyOptimismSepoliaToken": self.alchemyOptimismSepoliaToken,
|
||||
"statusProxyStageName": self.statusProxyStageName,
|
||||
"statusProxyMarketUser": self.statusProxyMarketUser,
|
||||
|
|
|
@ -165,13 +165,10 @@ QtObject:
|
|||
raribleMainnetApiKey: RARIBLE_MAINNET_API_KEY_RESOLVED,
|
||||
raribleTestnetApiKey: RARIBLE_TESTNET_API_KEY_RESOLVED,
|
||||
alchemyEthereumMainnetToken: ALCHEMY_ETHEREUM_MAINNET_TOKEN_RESOLVED,
|
||||
alchemyEthereumGoerliToken: ALCHEMY_ETHEREUM_GOERLI_TOKEN_RESOLVED,
|
||||
alchemyEthereumSepoliaToken: ALCHEMY_ETHEREUM_SEPOLIA_TOKEN_RESOLVED,
|
||||
alchemyArbitrumMainnetToken: ALCHEMY_ARBITRUM_MAINNET_TOKEN_RESOLVED,
|
||||
alchemyArbitrumGoerliToken: ALCHEMY_ARBITRUM_GOERLI_TOKEN_RESOLVED,
|
||||
alchemyArbitrumSepoliaToken: ALCHEMY_ARBITRUM_SEPOLIA_TOKEN_RESOLVED,
|
||||
alchemyOptimismMainnetToken: ALCHEMY_OPTIMISM_MAINNET_TOKEN_RESOLVED,
|
||||
alchemyOptimismGoerliToken: ALCHEMY_OPTIMISM_GOERLI_TOKEN_RESOLVED,
|
||||
alchemyOptimismSepoliaToken: ALCHEMY_OPTIMISM_SEPOLIA_TOKEN_RESOLVED,
|
||||
statusProxyStageName: STATUS_PROXY_STAGE_NAME_RESOLVED,
|
||||
statusProxyMarketUser: STATUS_PROXY_USER_RESOLVED,
|
||||
|
|
|
@ -140,8 +140,6 @@ proc getAppNetwork*(self: Service): NetworkItem =
|
|||
var networkId = Mainnet
|
||||
if self.settingsService.areTestNetworksEnabled():
|
||||
networkId = Sepolia
|
||||
if self.settingsService.isGoerliEnabled():
|
||||
networkId = Goerli
|
||||
let network = self.getNetworkByChainId(networkId)
|
||||
if network.isNil:
|
||||
# we should not be here ever
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
const Mainnet = 1
|
||||
const Ropsten = 3
|
||||
const Rinkeby = 4
|
||||
const Goerli = 5
|
||||
const Sepolia = 11155111
|
||||
const Optimism = 10
|
||||
const Poa = 99
|
||||
|
@ -10,7 +9,7 @@ const XDai = 100
|
|||
const NETWORK_LAYER_1 = 1
|
||||
const NETWORK_LAYER_2 = 2
|
||||
|
||||
export Mainnet, Ropsten, Rinkeby, Goerli, Optimism, Poa, XDai, Sepolia
|
||||
export Mainnet, Ropsten, Rinkeby, Optimism, Poa, XDai, Sepolia
|
||||
export NETWORK_LAYER_1, NETWORK_LAYER_2
|
||||
|
||||
type
|
||||
|
@ -18,7 +17,6 @@ type
|
|||
Mainnet = "mainnet_rpc",
|
||||
Testnet = "testnet_rpc",
|
||||
Rinkeby = "rinkeby_rpc",
|
||||
Goerli = "goerli_rpc",
|
||||
Sepolia = "sepolia_rpc",
|
||||
XDai = "xdai_rpc",
|
||||
Poa = "poa_rpc",
|
||||
|
@ -32,8 +30,6 @@ proc toNetworkType*(networkName: string): NetworkType =
|
|||
result = NetworkType.Testnet
|
||||
of "rinkeby_rpc":
|
||||
result = NetworkType.Rinkeby
|
||||
of "goerli_rpc":
|
||||
result = NetworkType.Goerli
|
||||
of "sepolia_rpc":
|
||||
result = NetworkType.Sepolia
|
||||
of "xdai_rpc":
|
||||
|
@ -48,7 +44,6 @@ proc toChainId*(self: NetworkType): int =
|
|||
of NetworkType.Mainnet: result = Mainnet
|
||||
of NetworkType.Testnet: result = Ropsten
|
||||
of NetworkType.Rinkeby: result = Rinkeby
|
||||
of NetworkType.Goerli: result = Goerli
|
||||
of NetworkType.Sepolia: result = Sepolia
|
||||
of NetworkType.XDai: result = XDai
|
||||
of NetworkType.Poa: result = 99
|
||||
|
|
|
@ -19,7 +19,7 @@ type
|
|||
OnlyIfDifferent
|
||||
|
||||
proc isValidChainId(chainId: int): bool =
|
||||
return chainId == Mainnet or chainId == Goerli or chainId == Sepolia
|
||||
return chainId == Mainnet or chainId == Sepolia
|
||||
|
||||
proc checkForEnsNameAndUpdate(chainId: int, savedAddress: var SavedAddressDto, updateCriteria: UpdateCriteria): RpcResponse[JsonNode] {.raises: [RpcException].} =
|
||||
if savedAddress.isTest and chainId == Mainnet or
|
||||
|
|
|
@ -44,7 +44,6 @@ const KEY_GIF_API_KEY* = "gifs/api-key"
|
|||
const KEY_DISPLAY_NAME* = "display-name"
|
||||
const KEY_BIO* = "bio"
|
||||
const KEY_TEST_NETWORKS_ENABLED* = "test-networks-enabled?"
|
||||
const KEY_IS_GOERLI_ENABLED* = "is-goerli-enabled?"
|
||||
const KEY_TOKEN_GROUP_BY_COMMUNITY* = "token-group-by-community?"
|
||||
const KEY_SHOW_COMMUNITY_ASSET_WHEN_SENDING_TOKENS* = "show-community-asset-when-sending-tokens?"
|
||||
const KEY_DISPLAY_ASSETS_BELOW_BALANCE* = "display-assets-below-balance?"
|
||||
|
@ -156,7 +155,6 @@ type
|
|||
notificationsVolume*: int
|
||||
notificationsMessagePreview*: int
|
||||
profileMigrationNeeded*: bool
|
||||
isGoerliEnabled*: bool
|
||||
tokenGroupByCommunity*: bool
|
||||
showCommunityAssetWhenSendingTokens*: bool
|
||||
displayAssetsBelowBalance*: bool
|
||||
|
@ -216,7 +214,6 @@ proc toSettingsDto*(jsonObj: JsonNode): SettingsDto =
|
|||
discard jsonObj.getProp(KEY_GIF_RECENTS, result.gifRecents)
|
||||
discard jsonObj.getProp(KEY_GIF_FAVORITES, result.gifFavorites)
|
||||
discard jsonObj.getProp(KEY_TEST_NETWORKS_ENABLED, result.testNetworksEnabled)
|
||||
discard jsonObj.getProp(KEY_IS_GOERLI_ENABLED, result.isGoerliEnabled)
|
||||
discard jsonObj.getProp(KEY_TOKEN_GROUP_BY_COMMUNITY, result.tokenGroupByCommunity)
|
||||
discard jsonObj.getProp(KEY_SHOW_COMMUNITY_ASSET_WHEN_SENDING_TOKENS, result.showCommunityAssetWhenSendingTokens)
|
||||
discard jsonObj.getProp(KEY_DISPLAY_ASSETS_BELOW_BALANCE, result.displayAssetsBelowBalance)
|
||||
|
|
|
@ -474,16 +474,6 @@ QtObject:
|
|||
return true
|
||||
return false
|
||||
|
||||
proc isGoerliEnabled*(self: Service): bool =
|
||||
return self.settings.isGoerliEnabled
|
||||
|
||||
proc toggleIsGoerliEnabled*(self: Service): bool =
|
||||
let newValue = not self.settings.isGoerliEnabled
|
||||
if(self.saveSetting(KEY_IS_GOERLI_ENABLED, newValue)):
|
||||
self.settings.isGoerliEnabled = newValue
|
||||
return true
|
||||
return false
|
||||
|
||||
proc tokenGroupByCommunity*(self: Service): bool =
|
||||
return self.settings.tokenGroupByCommunity
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ const SIGNAL_TOKENS_MARKET_VALUES_UPDATED* = "tokensMarketValuesUpdated"
|
|||
const SIGNAL_TOKENS_PRICES_UPDATED* = "tokensPricesValuesUpdated"
|
||||
const SIGNAL_TOKEN_PREFERENCES_UPDATED* = "tokenPreferencesUpdated"
|
||||
|
||||
type
|
||||
type
|
||||
ResultArgs* = ref object of Args
|
||||
success*: bool
|
||||
|
||||
|
@ -265,7 +265,7 @@ QtObject:
|
|||
# Callback to process the response of getSupportedTokensList call
|
||||
proc supportedTokensListRetrieved(self: Service, response: string) {.slot.} =
|
||||
# this is emited so that the models can know that the seq it depends on has been updated
|
||||
defer:
|
||||
defer:
|
||||
self.fetchTokenPreferences()
|
||||
self.events.emit(SIGNAL_TOKENS_LIST_UPDATED, Args())
|
||||
try:
|
||||
|
@ -278,7 +278,7 @@ QtObject:
|
|||
|
||||
if not errorString.isEmptyOrWhitespace:
|
||||
raise newException(Exception, "Error getting supported tokens list: " & errorString)
|
||||
|
||||
|
||||
if tokensResult.isNil or tokensResult.kind == JNull:
|
||||
raise newException(Exception, "Error in response of getting supported tokens list")
|
||||
|
||||
|
@ -372,7 +372,7 @@ QtObject:
|
|||
var data = WalletSignal(e)
|
||||
case data.eventType:
|
||||
of "wallet-tick-reload":
|
||||
self.rebuildMarketData()
|
||||
self.rebuildMarketData()
|
||||
# update and populate internal list and then emit signal when new custom token detected?
|
||||
|
||||
proc getCurrency*(self: Service): string =
|
||||
|
@ -449,10 +449,7 @@ QtObject:
|
|||
proc getStatusTokenKey*(self: Service): string =
|
||||
var token: TokenBySymbolItem
|
||||
if self.settingsService.areTestNetworksEnabled():
|
||||
if self.settingsService.isGoerliEnabled():
|
||||
token = self.getTokenBySymbolByContractAddr(STT_CONTRACT_ADDRESS_GOERLI)
|
||||
else:
|
||||
token = self.getTokenBySymbolByContractAddr(STT_CONTRACT_ADDRESS_SEPOLIA)
|
||||
token = self.getTokenBySymbolByContractAddr(STT_CONTRACT_ADDRESS_SEPOLIA)
|
||||
else:
|
||||
token = self.getTokenBySymbolByContractAddr(SNT_CONTRACT_ADDRESS)
|
||||
if token != nil:
|
||||
|
|
|
@ -544,14 +544,6 @@ proc toggleTestNetworksEnabled*(self: Service) =
|
|||
self.checkRecentHistory(addresses)
|
||||
self.events.emit(SIGNAL_WALLET_ACCOUNT_NETWORK_ENABLED_UPDATED, Args())
|
||||
|
||||
proc toggleIsGoerliEnabled*(self: Service) =
|
||||
discard self.settingsService.toggleIsGoerliEnabled()
|
||||
self.networkService.resetNetworks()
|
||||
let addresses = self.getWalletAddresses()
|
||||
self.buildAllTokens(addresses, store = true)
|
||||
self.checkRecentHistory(addresses)
|
||||
self.events.emit(SIGNAL_WALLET_ACCOUNT_NETWORK_ENABLED_UPDATED, Args())
|
||||
|
||||
proc updateWalletAccount*(self: Service, address: string, accountName: string, colorId: string, emoji: string): bool =
|
||||
try:
|
||||
var account = self.getAccountByAddress(address)
|
||||
|
@ -749,9 +741,6 @@ proc getCurrencyFormat*(self: Service, symbol: string): CurrencyFormatDto =
|
|||
proc areTestNetworksEnabled*(self: Service): bool =
|
||||
return self.settingsService.areTestNetworksEnabled()
|
||||
|
||||
proc isGoerliEnabled*(self: Service): bool =
|
||||
return self.settingsService.isGoerliEnabled()
|
||||
|
||||
proc hasPairedDevices*(self: Service): bool =
|
||||
return hasPairedDevices()
|
||||
|
||||
|
|
|
@ -46,13 +46,10 @@ let
|
|||
INFURA_TOKEN_RESOLVED* = desktopConfig.infuraToken
|
||||
INFURA_TOKEN_SECRET_RESOLVED* = desktopConfig.infuraTokenSecret
|
||||
ALCHEMY_ETHEREUM_MAINNET_TOKEN_RESOLVED* = desktopConfig.alchemyEthereumMainnetToken
|
||||
ALCHEMY_ETHEREUM_GOERLI_TOKEN_RESOLVED* = desktopConfig.alchemyEthereumGoerliToken
|
||||
ALCHEMY_ETHEREUM_SEPOLIA_TOKEN_RESOLVED* = desktopConfig.alchemyEthereumSepoliaToken
|
||||
ALCHEMY_ARBITRUM_MAINNET_TOKEN_RESOLVED* = desktopConfig.alchemyArbitrumMainnetToken
|
||||
ALCHEMY_ARBITRUM_GOERLI_TOKEN_RESOLVED* = desktopConfig.alchemyArbitrumGoerliToken
|
||||
ALCHEMY_ARBITRUM_SEPOLIA_TOKEN_RESOLVED* = desktopConfig.alchemyArbitrumSepoliaToken
|
||||
ALCHEMY_OPTIMISM_MAINNET_TOKEN_RESOLVED* = desktopConfig.alchemyOptimismMainnetToken
|
||||
ALCHEMY_OPTIMISM_GOERLI_TOKEN_RESOLVED* = desktopConfig.alchemyOptimismGoerliToken
|
||||
ALCHEMY_OPTIMISM_SEPOLIA_TOKEN_RESOLVED* = desktopConfig.alchemyOptimismSepoliaToken
|
||||
OPENSEA_API_KEY_RESOLVED* = desktopConfig.openseaApiKey
|
||||
RARIBLE_MAINNET_API_KEY_RESOLVED* = desktopConfig.raribleMainnetApiKey
|
||||
|
|
|
@ -19,13 +19,10 @@ const BASE_NAME_OPENSEA_API_KEY = "OPENSEA_API_KEY"
|
|||
const BASE_NAME_RARIBLE_MAINNET_API_KEY = "RARIBLE_MAINNET_API_KEY"
|
||||
const BASE_NAME_RARIBLE_TESTNET_API_KEY = "RARIBLE_TESTNET_API_KEY"
|
||||
const BASE_NAME_ALCHEMY_ETHEREUM_MAINNET_TOKEN = "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_ETHEREUM_GOERLI_TOKEN = "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_ETHEREUM_SEPOLIA_TOKEN = "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_ARBITRUM_MAINNET_TOKEN = "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_ARBITRUM_GOERLI_TOKEN = "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_ARBITRUM_SEPOLIA_TOKEN = "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_OPTIMISM_MAINNET_TOKEN = "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_OPTIMISM_GOERLI_TOKEN = "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
||||
const BASE_NAME_ALCHEMY_OPTIMISM_SEPOLIA_TOKEN = "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"
|
||||
const BASE_NAME_TENOR_API_KEY = "TENOR_API_KEY"
|
||||
const BASE_NAME_STATUS_PROXY_STAGE_NAME = "PROXY_STAGE_NAME"
|
||||
|
@ -56,13 +53,10 @@ const BUILD_OPENSEA_API_KEY = getEnv(BUILD_TIME_PREFIX & BASE_NAME_OPENSEA_API_K
|
|||
const BUILD_RARIBLE_MAINNET_API_KEY = getEnv(BUILD_TIME_PREFIX & BASE_NAME_RARIBLE_MAINNET_API_KEY)
|
||||
const BUILD_RARIBLE_TESTNET_API_KEY = getEnv(BUILD_TIME_PREFIX & BASE_NAME_RARIBLE_TESTNET_API_KEY)
|
||||
const BUILD_ALCHEMY_ETHEREUM_MAINNET_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ETHEREUM_MAINNET_TOKEN)
|
||||
const BUILD_ALCHEMY_ETHEREUM_GOERLI_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ETHEREUM_GOERLI_TOKEN)
|
||||
const BUILD_ALCHEMY_ETHEREUM_SEPOLIA_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ETHEREUM_SEPOLIA_TOKEN)
|
||||
const BUILD_ALCHEMY_ARBITRUM_MAINNET_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ARBITRUM_MAINNET_TOKEN)
|
||||
const BUILD_ALCHEMY_ARBITRUM_GOERLI_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ARBITRUM_GOERLI_TOKEN)
|
||||
const BUILD_ALCHEMY_ARBITRUM_SEPOLIA_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_ARBITRUM_SEPOLIA_TOKEN)
|
||||
const BUILD_ALCHEMY_OPTIMISM_MAINNET_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_OPTIMISM_MAINNET_TOKEN)
|
||||
const BUILD_ALCHEMY_OPTIMISM_GOERLI_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_OPTIMISM_GOERLI_TOKEN)
|
||||
const BUILD_ALCHEMY_OPTIMISM_SEPOLIA_TOKEN = getEnv(BUILD_TIME_PREFIX & BASE_NAME_ALCHEMY_OPTIMISM_SEPOLIA_TOKEN)
|
||||
|
||||
const
|
||||
|
@ -155,11 +149,6 @@ type StatusDesktopConfig = object
|
|||
desc: "Sets alchemy ethereum mainnet token"
|
||||
name: $BASE_NAME_ALCHEMY_ETHEREUM_MAINNET_TOKEN
|
||||
abbr: "alchemy-ethereum-mainnet-token" .}: string
|
||||
alchemyEthereumGoerliToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_ETHEREUM_GOERLI_TOKEN
|
||||
desc: "Sets alchemy ethereum goerli token"
|
||||
name: $BASE_NAME_ALCHEMY_ETHEREUM_GOERLI_TOKEN
|
||||
abbr: "alchemy-ethereum-goerli-token" .}: string
|
||||
alchemyEthereumSepoliaToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
|
||||
desc: "Sets alchemy ethereum sepolia token"
|
||||
|
@ -170,11 +159,6 @@ type StatusDesktopConfig = object
|
|||
desc: "Sets alchemy arbitrum mainnet token"
|
||||
name: $BASE_NAME_ALCHEMY_ARBITRUM_MAINNET_TOKEN
|
||||
abbr: "alchemy-arbitrum-mainnet-token" .}: string
|
||||
alchemyArbitrumGoerliToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_ARBITRUM_GOERLI_TOKEN
|
||||
desc: "Sets alchemy arbitrum goerli token"
|
||||
name: $BASE_NAME_ALCHEMY_ARBITRUM_GOERLI_TOKEN
|
||||
abbr: "alchemy-arbitrum-goerli-token" .}: string
|
||||
alchemyArbitrumSepoliaToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_ARBITRUM_SEPOLIA_TOKEN
|
||||
desc: "Sets alchemy arbitrum sepolia token"
|
||||
|
@ -185,11 +169,6 @@ type StatusDesktopConfig = object
|
|||
desc: "Sets alchemy optimism mainnet token"
|
||||
name: $BASE_NAME_ALCHEMY_OPTIMISM_MAINNET_TOKEN
|
||||
abbr: "alchemy-optimism-mainnet-token" .}: string
|
||||
alchemyOptimismGoerliToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_OPTIMISM_GOERLI_TOKEN
|
||||
desc: "Sets alchemy optimism goerli token"
|
||||
name: $BASE_NAME_ALCHEMY_OPTIMISM_GOERLI_TOKEN
|
||||
abbr: "alchemy-optimism-goerli-token" .}: string
|
||||
alchemyOptimismSepoliaToken* {.
|
||||
defaultValue: BUILD_ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
|
||||
desc: "Sets alchemy optimism sepolia token"
|
||||
|
|
|
@ -111,7 +111,7 @@ SplitView {
|
|||
function requestMockedFees(contractKeysAndAmounts) {
|
||||
if (!loader.item)
|
||||
return
|
||||
|
||||
|
||||
const view = loader.item
|
||||
view.feesAvailable = false
|
||||
view.totalFeeText = ""
|
||||
|
@ -234,7 +234,7 @@ SplitView {
|
|||
},
|
||||
ExpressionRole {
|
||||
name: "chainName"
|
||||
expression: model.index ? "Ethereum Mainnet" : "Goerli"
|
||||
expression: model.index ? "Ethereum Mainnet" : "Sepolia"
|
||||
},
|
||||
ExpressionRole {
|
||||
readonly property string icon1: "network/Network=Ethereum"
|
||||
|
|
|
@ -21,8 +21,7 @@ SplitView {
|
|||
nativeCurrencyDecimals: 18,
|
||||
layer: 1,
|
||||
chainName: "Mainnet",
|
||||
rpcURL: "https://eth-archival.rpc.grove.city/v1/7178a5d77466455882b2fb60",
|
||||
fallbackURL: "https://eth-archival.rpc.grove.city/v1/7178a5d77466455882b2fb60",
|
||||
rpcURL: "https://mainnet.infura.io/v3/",
|
||||
blockExplorerURL: "https://etherscan.io/",
|
||||
iconURL: "network/Network=Ethereum",
|
||||
nativeCurrencyName: "Ether",
|
||||
|
@ -38,9 +37,8 @@ SplitView {
|
|||
nativeCurrencyDecimals: 18,
|
||||
layer: 1,
|
||||
chainName: "Mainnet",
|
||||
rpcURL: "https://goerli-archival.rpc.grove.city/v1/7178a5d77466455882b2fb60",
|
||||
fallbackURL: "https://eth-archival.rpc.grove.city/v1/7178a5d77466455882b2fb60",
|
||||
blockExplorerURL: "https://goerli.etherscan.io/",
|
||||
rpcURL: "https://sepolia.infura.io/v3/",
|
||||
blockExplorerURL: "https://sepolia.etherscan.io/",
|
||||
iconURL: "network/Network=Ethereum",
|
||||
nativeCurrencyName: "Ether",
|
||||
nativeCurrencySymbol: "ETH",
|
||||
|
|
|
@ -116,7 +116,7 @@ SplitView {
|
|||
},
|
||||
ExpressionRole {
|
||||
name: "chainName"
|
||||
expression: model.index ? "Ethereum Mainnet" : "Goerli"
|
||||
expression: model.index ? "Ethereum Mainnet" : "Sepolia"
|
||||
},
|
||||
ExpressionRole {
|
||||
name: "decimals"
|
||||
|
|
|
@ -29,7 +29,7 @@ SplitView {
|
|||
Layout.fillHeight: true
|
||||
|
||||
model: NetworksModel.flatNetworks
|
||||
selection: [420]
|
||||
selection: [11155420]
|
||||
showIndicator: true
|
||||
multiSelection: false
|
||||
}
|
||||
|
@ -49,7 +49,7 @@ SplitView {
|
|||
showIndicator: true
|
||||
multiSelection: true
|
||||
|
||||
selection: [1, 420]
|
||||
selection: [1, 11155420]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -105,4 +105,4 @@ SplitView {
|
|||
}
|
||||
}
|
||||
|
||||
// category: Views
|
||||
// category: Views
|
||||
|
|
|
@ -44,7 +44,7 @@ SplitView {
|
|||
account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240",
|
||||
},
|
||||
{
|
||||
chainId: "420",
|
||||
chainId: "11155420",
|
||||
balance: "559133758939097000",
|
||||
account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240"
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ SplitView {
|
|||
communityId: "",
|
||||
balances: [
|
||||
{
|
||||
chainId: "420",
|
||||
chainId: "11155420",
|
||||
balance: "1142155111",
|
||||
account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240"
|
||||
},
|
||||
|
@ -109,7 +109,7 @@ SplitView {
|
|||
|
||||
property ListModel toModel: ListModel {
|
||||
ListElement {
|
||||
chainId: 420
|
||||
chainId: 11155420
|
||||
amountOut: "3003845308235848343"
|
||||
}
|
||||
ListElement {
|
||||
|
|
|
@ -49,7 +49,7 @@ SplitView {
|
|||
|
||||
balances: [
|
||||
ListElement {
|
||||
chainId: 420
|
||||
chainId: 11155420
|
||||
balance: "1013151281976507736"
|
||||
account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240"
|
||||
},
|
||||
|
|
|
@ -52,7 +52,7 @@ SplitView {
|
|||
{ chainId: 1, balanceAsString: "1234.50", iconUrl: "network/Network=Ethereum" },
|
||||
{ chainId: 42161, balanceAsString: "55.91", iconUrl: "network/Network=Arbitrum" },
|
||||
{ chainId: 10, balanceAsString: "45.12", iconUrl: "network/Network=Optimism" },
|
||||
{ chainId: 420, balanceAsString: "1.23", iconUrl: "network/Network=Testnet" }
|
||||
{ chainId: 11155420, balanceAsString: "1.23", iconUrl: "network/Network=Testnet" }
|
||||
]
|
||||
Component.onCompleted: append(data)
|
||||
}
|
||||
|
|
|
@ -232,7 +232,7 @@ Item {
|
|||
compare(selectedAssetButton.subname, modelDataToTest.symbol)
|
||||
|
||||
//switch to a network that has no tokens and ensure its reset
|
||||
controlUnderTest.buyCryptoInputParamsForm.selectedNetworkChainId = 421613
|
||||
controlUnderTest.buyCryptoInputParamsForm.selectedNetworkChainId = 421614
|
||||
|
||||
waitForRendering(selectParamsPanel)
|
||||
|
||||
|
|
|
@ -216,7 +216,7 @@ Item {
|
|||
}
|
||||
// Used by tst_balanceCheck
|
||||
ListElement {
|
||||
chainId: 421613
|
||||
chainId: 421614
|
||||
layer: 2
|
||||
}
|
||||
}
|
||||
|
@ -378,7 +378,7 @@ Item {
|
|||
},
|
||||
{
|
||||
tag: "check_l2_doesnt_have_enough_funds_on_l1",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
// Override the l1 additional fees
|
||||
l1GasFee: 1000000000.0,
|
||||
|
||||
|
@ -389,7 +389,7 @@ Item {
|
|||
},
|
||||
{
|
||||
tag: "check_l2_doesnt_have_enough_funds_on_l2",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
// Override the l2 to a higher value
|
||||
maxFeePerGasM: 1000000.0, /*GWEI*/
|
||||
// Override the l1 additional fees
|
||||
|
|
|
@ -34,7 +34,7 @@ Item {
|
|||
|
||||
QtObject {
|
||||
id: d
|
||||
readonly property int goOptChainId: 420
|
||||
readonly property int goOptChainId: 11155420
|
||||
|
||||
readonly property SwapModalAdaptor adaptor: SwapModalAdaptor {
|
||||
swapStore: SwapStore {
|
||||
|
|
|
@ -6,9 +6,9 @@ ListModel {
|
|||
tokensKey: "DAI",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 10, balance: "559133758939097000" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "0" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "0" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155111, balance: "0" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155111, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 42161, balance: "45123456789123456789" },
|
||||
]
|
||||
|
@ -17,21 +17,21 @@ ListModel {
|
|||
tokensKey: "ETH",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 1, balance: "122082928968121891" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "1013151281976507736" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 421613, balance: "473057568699284613" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "1013151281976507736" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 421614, balance: "473057568699284613" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155111, balance: "307400931315122839" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "122082928968121891" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 421613, balance: "0" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "122082928968121891" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 421614, balance: "0" },
|
||||
]
|
||||
},
|
||||
{
|
||||
tokensKey: "STT",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 1, balance: "45123456789123456789" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "999999999998998500000000000016777216" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "999999999998998500000000000016777216" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 10, balance: "1077000000000000000000" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "122082928968121891" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 421613, balance: "222000000000000000" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "122082928968121891" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 421614, balance: "222000000000000000" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155111, balance: "559133758939097000" }
|
||||
]
|
||||
},
|
||||
|
@ -39,9 +39,9 @@ ListModel {
|
|||
tokensKey: "aave",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 10, balance: "559133758939097000" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "0" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "0" },
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155111, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155111, balance: "123456789123456789" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 42161, balance: "45123456789123456789" },
|
||||
]
|
||||
|
@ -49,27 +49,27 @@ ListModel {
|
|||
{
|
||||
tokensKey: "0x6b175474e89094c44da98b954eedeac495271e0f",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "100" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "1" }
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "100" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "1" }
|
||||
]
|
||||
},
|
||||
{
|
||||
tokensKey: "0x6b175474e89094c44da98b954eedeac495271p0f",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "20" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 420, balance: "10" }
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "20" },
|
||||
{ account: "0x7F47C2e98a4BBf5487E6fb082eC2D9Ab0E6d8881", chainId: 11155420, balance: "10" }
|
||||
]
|
||||
},
|
||||
{
|
||||
tokensKey: "0x6b175474e89094c44da98b954eedeac495271d0f",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "1" }
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "1" }
|
||||
]
|
||||
},
|
||||
{
|
||||
tokensKey: "0x6b175474e89094c44da98b954eedeac495271a0f",
|
||||
balances: [
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 420, balance: "1" }
|
||||
{ account: "0x7F47C2e18a4BBf5487E6fb082eC2D9Ab0E6d7240", chainId: 11155420, balance: "1" }
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
|
@ -115,7 +115,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "34545656768",
|
||||
chainId: 420,
|
||||
chainId: 11155420,
|
||||
userHas: 1,
|
||||
name: "Kitty 1",
|
||||
collectionUid: "KT",
|
||||
|
@ -161,7 +161,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "123456",
|
||||
chainId: 420,
|
||||
chainId: 11155420,
|
||||
userHas: 0,
|
||||
name: "Kitty 2",
|
||||
collectionUid: "KT",
|
||||
|
@ -210,7 +210,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "12345645459537432",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
userHas: 0,
|
||||
name: "Big Kitty",
|
||||
collectionUid: "KT",
|
||||
|
@ -261,7 +261,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "pp21",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
userHas: 0,
|
||||
name: "pepepunk#21",
|
||||
collectionUid: "pepepunks",
|
||||
|
@ -299,7 +299,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "lp#666a",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
userHas: 0,
|
||||
name: "Lonely Panda #666",
|
||||
collectionUid: "lpan_collection",
|
||||
|
@ -337,7 +337,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "invalid#123",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
userHas: 0,
|
||||
name: "",
|
||||
collectionUid: "",
|
||||
|
@ -401,7 +401,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "691",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
name: "KILLABEAR #691",
|
||||
collectionUid: "",
|
||||
collectionName: "",
|
||||
|
@ -429,7 +429,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "8876",
|
||||
chainId: 421613,
|
||||
chainId: 421614,
|
||||
name: "KILLABEAR #2385",
|
||||
collectionUid: "",
|
||||
collectionName: "",
|
||||
|
@ -541,7 +541,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "lb#666",
|
||||
chainId: 420,
|
||||
chainId: 11155420,
|
||||
name: "Lonely Bear #666",
|
||||
collectionUid: "",
|
||||
collectionName: "",
|
||||
|
@ -574,7 +574,7 @@ ListModel {
|
|||
},
|
||||
{
|
||||
uid: "lb#777",
|
||||
chainId: 420,
|
||||
chainId: 11155420,
|
||||
name: "Lonely Turtle #777",
|
||||
collectionUid: "",
|
||||
collectionName: "",
|
||||
|
|
|
@ -46,7 +46,7 @@ QtObject {
|
|||
return "Hermez"
|
||||
|
||||
if(chainId === root.testnetNet)
|
||||
return "Goerli"
|
||||
return "Sepolia"
|
||||
|
||||
if(chainId === root.customNet)
|
||||
return "Custom"
|
||||
|
@ -97,12 +97,12 @@ QtObject {
|
|||
isRouteEnabled: true,
|
||||
},
|
||||
{
|
||||
chainId: 420,
|
||||
chainName: "Optimism Goerli Testnet",
|
||||
blockExplorerURL: "https://goerli-optimism.etherscan.io/",
|
||||
chainId: 11155420,
|
||||
chainName: "Optimism Sepolia",
|
||||
blockExplorerURL: "https://sepolia-optimism.etherscan.io/",
|
||||
iconUrl: "network/Network=Optimism",
|
||||
chainColor: "#939BA1",
|
||||
shortName: "goOpt",
|
||||
shortName: "oeth",
|
||||
nativeCurrencyName: "Ether",
|
||||
nativeCurrencySymbol: "ETH",
|
||||
nativeCurrencyDecimals: 18,
|
||||
|
@ -125,12 +125,12 @@ QtObject {
|
|||
isRouteEnabled: true,
|
||||
},
|
||||
{
|
||||
chainId: 421613,
|
||||
chainName: "Arbitrum Goerli",
|
||||
blockExplorerURL: "https://goerli.arbiscan.io/",
|
||||
chainId: 421614,
|
||||
chainName: "Arbitrum Sepolia",
|
||||
blockExplorerURL: "https://sepolia-explorer.arbitrum.io/",
|
||||
iconUrl: "network/Network=Arbitrum",
|
||||
chainColor: "#939BA1",
|
||||
shortName: "goArb",
|
||||
shortName: "arb1",
|
||||
nativeCurrencyName: "Ether",
|
||||
nativeCurrencySymbol: "ETH",
|
||||
nativeCurrencyDecimals: 18,
|
||||
|
|
|
@ -49,8 +49,8 @@ ListModel {
|
|||
supportsRecurrentPurchase: true,
|
||||
supportedAssets:[
|
||||
{ key: "111551110x0000000000000000000000000000000000000000", chainId: 11155111, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ key: "4200x0000000000000000000000000000000000000000", chainId: 420, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ key: "4200xf2edf1c091f683e3fb452497d9a98a49cba84669", chainId: 420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84669"},
|
||||
{ key: "4200x0000000000000000000000000000000000000000", chainId: 11155420, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ key: "4200xf2edf1c091f683e3fb452497d9a98a49cba84669", chainId: 11155420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84669"},
|
||||
],
|
||||
urlsNeedParameters: true
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@ QtObject {
|
|||
|
||||
property ListModel toModel: ListModel {
|
||||
ListElement {
|
||||
chainId: 420
|
||||
chainId: 11155420
|
||||
chainName: "Optimism"
|
||||
iconUrl: "network/Network=Optimism"
|
||||
amountOut: "3003845308235848343"
|
||||
|
|
|
@ -18,9 +18,9 @@ ListModel {
|
|||
{ chainId: 1, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 5, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 10, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 420, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 11155420, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 42161, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 421613, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 421614, address: "0x0000000000000000000000000000000000000000"},
|
||||
{ chainId: 11155111, address: "0x0000000000000000000000000000000000000000"},
|
||||
],
|
||||
decimals: 18,
|
||||
|
@ -48,8 +48,8 @@ ListModel {
|
|||
sources: ";" + status + ";",
|
||||
addressPerChain: [
|
||||
{chainId: 5, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 420, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 421613, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 11155420, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 421614, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 11155111, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
{ chainId: 10, address: "0x3d6afaa395c31fcd391fe3d562e75fe9e8ec7e6a"},
|
||||
],
|
||||
|
@ -82,8 +82,8 @@ ListModel {
|
|||
{ chainId: 42161, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
{ chainId: 5, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84666"},
|
||||
{ chainId: 11155111, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
{ chainId: 420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84669"},
|
||||
{ chainId: 421613, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84666"},
|
||||
{ chainId: 11155420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84669"},
|
||||
{ chainId: 421614, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84666"},
|
||||
],
|
||||
decimals: 18,
|
||||
type: 1,
|
||||
|
@ -112,7 +112,7 @@ ListModel {
|
|||
sources: ";" + uniswap + ";" + status + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 11155111, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
{ chainId: 421613, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
{ chainId: 421614, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
],
|
||||
decimals: 18,
|
||||
type: 1,
|
||||
|
@ -169,8 +169,8 @@ ListModel {
|
|||
communityId: "",
|
||||
sources: ";" + uniswap + ";" + status + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84666"},
|
||||
{ chainId: 421613, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
{ chainId: 11155420, address: "0xf2edf1c091f683e3fb452497d9a98a49cba84666"},
|
||||
{ chainId: 421614, address: "0xda10009cbd5d07dd0cecc66161fc93d7c9000da1"},
|
||||
],
|
||||
decimals: 18,
|
||||
type: 1,
|
||||
|
@ -197,7 +197,7 @@ ListModel {
|
|||
symbol: "ZRX",
|
||||
sources: ";" + custom + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 420, address: "0x6b175474e89094c44da98b954eedeac495271e0f"}
|
||||
{ chainId: 11155420, address: "0x6b175474e89094c44da98b954eedeac495271e0f"}
|
||||
],
|
||||
decimals: 0,
|
||||
type: 1,
|
||||
|
@ -223,7 +223,7 @@ ListModel {
|
|||
symbol: "OMG",
|
||||
sources: ";" + custom + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 420, address: "0x6b175474e89094c44da98b954eedeac495271p0f"}
|
||||
{ chainId: 11155420, address: "0x6b175474e89094c44da98b954eedeac495271p0f"}
|
||||
],
|
||||
decimals: 0,
|
||||
type: 1,
|
||||
|
@ -249,7 +249,7 @@ ListModel {
|
|||
symbol: "MET",
|
||||
sources: ";" + custom + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 420, address: "0x6b175474e89094c44da98b954eedeac495271d0f"},
|
||||
{ chainId: 11155420, address: "0x6b175474e89094c44da98b954eedeac495271d0f"},
|
||||
{ chainId: 10, address: "0x6b175474e89094c44da98b954eedeac495271d0f"}
|
||||
],
|
||||
decimals: 0,
|
||||
|
@ -276,7 +276,7 @@ ListModel {
|
|||
symbol: "AST",
|
||||
sources: ";" + custom + ";",
|
||||
addressPerChain: [
|
||||
{ chainId: 420, address: "0x6b175474e89094c44da98b954eedeac495271a0f"}
|
||||
{ chainId: 11155420, address: "0x6b175474e89094c44da98b954eedeac495271a0f"}
|
||||
],
|
||||
decimals: 0,
|
||||
type: 1,
|
||||
|
|
|
@ -28,7 +28,6 @@ StatusMenu {
|
|||
colorId: "",
|
||||
})
|
||||
property bool areTestNetworksEnabled: false
|
||||
property bool isGoerliEnabled: false
|
||||
|
||||
signal copyToClipboard(string address)
|
||||
|
||||
|
@ -42,7 +41,7 @@ StatusMenu {
|
|||
text: qsTr("View on Etherscan")
|
||||
icon.name: "link"
|
||||
onTriggered: {
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet, root.areTestNetworksEnabled, root.isGoerliEnabled, root.selectedAccount.address?? "")
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet, root.areTestNetworksEnabled, root.selectedAccount.address?? "")
|
||||
Global.openLink(link)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -43,8 +43,6 @@ QtObject {
|
|||
|
||||
readonly property bool refreshTokenEnabled: localAppSettings.refreshTokenEnabled ?? false
|
||||
|
||||
readonly property bool isGoerliEnabled: networksModuleInst.isGoerliEnabled
|
||||
|
||||
function logDir() {
|
||||
if(!root.advancedModule)
|
||||
return ""
|
||||
|
@ -202,9 +200,4 @@ QtObject {
|
|||
|
||||
localAppSettings.scrollDeceleration = value
|
||||
}
|
||||
|
||||
function toggleIsGoerliEnabled(){
|
||||
networksModule.toggleIsGoerliEnabled()
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,7 +18,6 @@ QtObject {
|
|||
property var accountSensitiveSettings: Global.appIsReady? localAccountSensitiveSettings : null
|
||||
|
||||
readonly property bool areTestNetworksEnabled: networksModuleInst.areTestNetworksEnabled
|
||||
readonly property bool isGoerliEnabled: networksModuleInst.isGoerliEnabled
|
||||
|
||||
readonly property var combinedNetworks: networksModuleInst.combinedNetworks
|
||||
|
||||
|
|
|
@ -441,15 +441,6 @@ SettingsContentBase {
|
|||
}
|
||||
}
|
||||
|
||||
StatusSettingsLineButton {
|
||||
anchors.leftMargin: 0
|
||||
anchors.rightMargin: 0
|
||||
text: qsTr("Enable Goerli as Test Network")
|
||||
isSwitch: true
|
||||
switchChecked: root.advancedStore.isGoerliEnabled
|
||||
onClicked: Global.openPopup(enableSepoliaConfirmationDialogComponent)
|
||||
}
|
||||
|
||||
StatusSettingsLineButton {
|
||||
anchors.leftMargin: 0
|
||||
anchors.rightMargin: 0
|
||||
|
@ -505,26 +496,6 @@ SettingsContentBase {
|
|||
}
|
||||
}
|
||||
|
||||
Component {
|
||||
id: enableSepoliaConfirmationDialogComponent
|
||||
ConfirmationDialog {
|
||||
property bool mode: false
|
||||
|
||||
id: confirmDialog
|
||||
destroyOnClose: true
|
||||
showCancelButton: true
|
||||
confirmationText: qsTr("Are you sure you want to toggle sepolia? The app will be restarted.")
|
||||
onConfirmButtonClicked: {
|
||||
root.advancedStore.toggleIsGoerliEnabled()
|
||||
close()
|
||||
SystemUtils.restartApplication()
|
||||
}
|
||||
onCancelButtonClicked: {
|
||||
close()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Component {
|
||||
id: enableDeveloperFeaturesConfirmationDialogComponent
|
||||
ConfirmationDialog {
|
||||
|
|
|
@ -293,7 +293,6 @@ ColumnLayout {
|
|||
id: addressMenu
|
||||
selectedAccount: root.account
|
||||
areTestNetworksEnabled: root.walletStore.areTestNetworksEnabled
|
||||
isGoerliEnabled: root.walletStore.isGoerliEnabled
|
||||
onCopyToClipboard: ClipboardUtils.setText(address)
|
||||
}
|
||||
|
||||
|
|
|
@ -27,7 +27,6 @@ StatusListItem {
|
|||
property string ens
|
||||
property string colorId
|
||||
property bool areTestNetworksEnabled: false
|
||||
property bool isGoerliEnabled: false
|
||||
|
||||
property int usage: SavedAddressesDelegate.Usage.Delegate
|
||||
property bool showButtons: sensor.containsMouse
|
||||
|
@ -212,7 +211,7 @@ StatusListItem {
|
|||
text: qsTr("View on Etherscan")
|
||||
icon.name: "link"
|
||||
onTriggered: {
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet, root.areTestNetworksEnabled, root.isGoerliEnabled, d.visibleAddress ? d.visibleAddress : root.ens)
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet, root.areTestNetworksEnabled, d.visibleAddress ? d.visibleAddress : root.ens)
|
||||
Global.openLink(link)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,10 +28,10 @@ StatusFlatButton {
|
|||
onClicked: moreMenu.popup(-moreMenu.width + width, height + 4)
|
||||
|
||||
function getExplorerName() {
|
||||
if (root.networkShortName === Constants.networkShortChainNames.arbitrum || root.networkShortName === Constants.networkShortChainNames.arbitrum_goerli) {
|
||||
if (root.networkShortName === Constants.networkShortChainNames.arbitrum) {
|
||||
return qsTr("Arbiscan")
|
||||
}
|
||||
if (root.networkShortName === Constants.networkShortChainNames.optimism || root.networkShortName === Constants.networkShortChainNames.optimism_goerli) {
|
||||
if (root.networkShortName === Constants.networkShortChainNames.optimism) {
|
||||
return qsTr("Optimistic")
|
||||
}
|
||||
return qsTr("Etherscan")
|
||||
|
|
|
@ -19,7 +19,6 @@ ColumnLayout {
|
|||
property string tokenAddress
|
||||
property bool strikethrough: false
|
||||
property bool areTestNetworksEnabled: false
|
||||
property bool isGoerliEnabled: false
|
||||
|
||||
spacing: Theme.padding
|
||||
|
||||
|
@ -106,11 +105,7 @@ ColumnLayout {
|
|||
onClicked: {
|
||||
let link = Constants.networkExplorerLinks.etherscan
|
||||
if (areTestNetworksEnabled) {
|
||||
if (root.isGoerliEnabled) {
|
||||
link = Constants.networkExplorerLinks.goerliEtherscan
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
}
|
||||
Global.openLink("%1/nft/%2/%3".arg(link).arg(root.tokenAddress).arg(root.tokenId))
|
||||
}
|
||||
|
|
|
@ -157,7 +157,6 @@ StatusModal {
|
|||
statusListItemTitle.font.bold: Font.Bold
|
||||
|
||||
areTestNetworksEnabled: WalletStore.RootStore.areTestNetworksEnabled
|
||||
isGoerliEnabled: WalletStore.RootStore.isGoerliEnabled
|
||||
|
||||
onAboutToOpenPopup: {
|
||||
root.close()
|
||||
|
|
|
@ -36,7 +36,6 @@ StatusMenu {
|
|||
property ProfileStores.ContactsStore contactsStore
|
||||
property NetworkConnectionStore networkConnectionStore
|
||||
property bool areTestNetworksEnabled: false
|
||||
property bool isGoerliEnabled: false
|
||||
|
||||
signal openSendModal(address: string)
|
||||
|
||||
|
@ -216,8 +215,7 @@ StatusMenu {
|
|||
text: d.getViewText(qsTr("Etherscan"))
|
||||
icon.name: "link"
|
||||
onTriggered: {
|
||||
let url = Utils.getEtherscanUrl(d.chains.mainnet, root.areTestNetworksEnabled, !root.isGoerliEnabled,
|
||||
d.cleanSelectedAddress, d.isAddress)
|
||||
let url = Utils.getEtherscanUrl(d.chains.mainnet, root.areTestNetworksEnabled, d.cleanSelectedAddress, d.isAddress)
|
||||
Global.openLink(url)
|
||||
}
|
||||
}
|
||||
|
@ -227,8 +225,7 @@ StatusMenu {
|
|||
text: d.getViewText(qsTr("Arbiscan"))
|
||||
icon.name: "link"
|
||||
onTriggered: {
|
||||
let url = Utils.getEtherscanUrl(d.chains.arbitrum, root.areTestNetworksEnabled, !root.isGoerliEnabled,
|
||||
d.cleanSelectedAddress, d.isAddress)
|
||||
let url = Utils.getEtherscanUrl(d.chains.arbitrum, root.areTestNetworksEnabled, d.cleanSelectedAddress, d.isAddress)
|
||||
Global.openLink(url)
|
||||
}
|
||||
}
|
||||
|
@ -238,8 +235,7 @@ StatusMenu {
|
|||
text: d.getViewText(qsTr("Optimism Explorer"))
|
||||
icon.name: "link"
|
||||
onTriggered: {
|
||||
let url = Utils.getEtherscanUrl(d.chains.optimism, root.areTestNetworksEnabled, !root.isGoerliEnabled,
|
||||
d.cleanSelectedAddress, d.isAddress)
|
||||
let url = Utils.getEtherscanUrl(d.chains.optimism, root.areTestNetworksEnabled, d.cleanSelectedAddress, d.isAddress)
|
||||
Global.openLink(url)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,7 +54,6 @@ QtObject {
|
|||
property CollectiblesStore collectiblesStore: CollectiblesStore {}
|
||||
|
||||
readonly property bool areTestNetworksEnabled: networksModule.areTestNetworksEnabled
|
||||
readonly property bool isGoerliEnabled: profileSectionModule.walletModule.networksModule.isGoerliEnabled
|
||||
|
||||
property var savedAddresses: SortFilterProxyModel {
|
||||
sourceModel: walletSectionSavedAddresses.model
|
||||
|
@ -405,30 +404,18 @@ QtObject {
|
|||
let link = Constants.networkExplorerLinks.etherscan
|
||||
if (networkShortName === Constants.networkShortChainNames.mainnet) {
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliEtherscan
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
}
|
||||
}
|
||||
if (networkShortName === Constants.networkShortChainNames.arbitrum) {
|
||||
link = Constants.networkExplorerLinks.arbiscan
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaArbiscan
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliArbiscan
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaArbiscan
|
||||
}
|
||||
} else if (networkShortName === Constants.networkShortChainNames.optimism) {
|
||||
link = Constants.networkExplorerLinks.optimism
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaOptimism
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliOptimism
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaOptimism
|
||||
}
|
||||
}
|
||||
return link
|
||||
|
@ -458,30 +445,18 @@ QtObject {
|
|||
let networkName = Constants.openseaExplorerLinks.ethereum
|
||||
if (networkShortName === Constants.networkShortChainNames.mainnet) {
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaEthereum
|
||||
} else {
|
||||
networkName = Constants.openseaExplorerLinks.goerliEthereum
|
||||
}
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaEthereum
|
||||
}
|
||||
}
|
||||
if (networkShortName === Constants.networkShortChainNames.arbitrum) {
|
||||
networkName = Constants.openseaExplorerLinks.arbitrum
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaArbitrum
|
||||
} else {
|
||||
networkName = Constants.openseaExplorerLinks.goerliArbitrum
|
||||
}
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaArbitrum
|
||||
}
|
||||
} else if (networkShortName === Constants.networkShortChainNames.optimism) {
|
||||
networkName = Constants.openseaExplorerLinks.optimism
|
||||
if (root.areTestNetworksEnabled) {
|
||||
if (!root.isGoerliEnabled) {
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaOptimism
|
||||
} else {
|
||||
networkName = Constants.openseaExplorerLinks.goerliOptimism
|
||||
}
|
||||
networkName = Constants.openseaExplorerLinks.sepoliaOptimism
|
||||
}
|
||||
}
|
||||
return networkName
|
||||
|
|
|
@ -149,7 +149,6 @@ ColumnLayout {
|
|||
colorId: model.colorId
|
||||
networkConnectionStore: root.networkConnectionStore
|
||||
areTestNetworksEnabled: RootStore.areTestNetworksEnabled
|
||||
isGoerliEnabled: RootStore.isGoerliEnabled
|
||||
onOpenSendModal: root.sendModal.open(recipient);
|
||||
|
||||
states: [
|
||||
|
|
|
@ -219,7 +219,6 @@ Item {
|
|||
tokenId: d.isTransactionValid ? transaction.tokenID : ""
|
||||
tokenAddress: d.isTransactionValid ? transaction.tokenAddress : ""
|
||||
areTestNetworksEnabled: WalletStores.RootStore.areTestNetworksEnabled
|
||||
isGoerliEnabled: WalletStores.RootStore.isGoerliEnabled
|
||||
}
|
||||
|
||||
Column {
|
||||
|
@ -819,7 +818,6 @@ Item {
|
|||
id: addressMenu
|
||||
|
||||
areTestNetworksEnabled: WalletStores.RootStore.areTestNetworksEnabled
|
||||
isGoerliEnabled: WalletStores.RootStore.isGoerliEnabled
|
||||
contactsStore: root.contactsStore
|
||||
networkConnectionStore: root.networkConnectionStore
|
||||
onOpenSendModal: (address) => root.sendModal.open(address)
|
||||
|
|
|
@ -144,7 +144,6 @@ Rectangle {
|
|||
onClicked: {
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet,
|
||||
WalletStore.RootStore.areTestNetworksEnabled,
|
||||
WalletStore.RootStore.isGoerliEnabled,
|
||||
model.account.address)
|
||||
Global.openLink(link)
|
||||
}
|
||||
|
|
|
@ -189,7 +189,6 @@ Item {
|
|||
onClicked: {
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet,
|
||||
WalletStore.RootStore.areTestNetworksEnabled,
|
||||
WalletStore.RootStore.isGoerliEnabled,
|
||||
root.sharedKeycardModule.keyPairHelper.observedAccount.address)
|
||||
Global.openLink(link)
|
||||
}
|
||||
|
|
|
@ -156,7 +156,6 @@ Item {
|
|||
onTriggered: {
|
||||
let link = Utils.getUrlForAddressOnNetwork(Constants.networkShortChainNames.mainnet,
|
||||
root.walletStore.areTestNetworksEnabled,
|
||||
root.walletStore.isGoerliEnabled,
|
||||
contextMenu.accountAddress);
|
||||
Global.openLinkWithConfirmation(link, StatusQUtils.StringUtils.extractDomainFromLink(link));
|
||||
}
|
||||
|
|
|
@ -900,9 +900,6 @@ QtObject {
|
|||
readonly property string mainnet: "eth"
|
||||
readonly property string arbitrum: "arb1"
|
||||
readonly property string optimism: "oeth"
|
||||
|
||||
readonly property string optimism_goerli: "goOpt"
|
||||
readonly property string arbitrum_goerli: "goArb"
|
||||
}
|
||||
|
||||
readonly property QtObject networkExplorerLinks: QtObject {
|
||||
|
@ -910,10 +907,6 @@ QtObject {
|
|||
readonly property string arbiscan: "https://arbiscan.io"
|
||||
readonly property string optimism: "https://optimistic.etherscan.io"
|
||||
|
||||
readonly property string goerliEtherscan: "https://goerli.etherscan.io"
|
||||
readonly property string goerliArbiscan: "https://goerli.arbiscan.io"
|
||||
readonly property string goerliOptimism: "https://goerli-optimism.etherscan.io"
|
||||
|
||||
readonly property string sepoliaEtherscan: "https://sepolia.etherscan.io/"
|
||||
readonly property string sepoliaArbiscan: "https://sepolia.arbiscan.io/"
|
||||
readonly property string sepoliaOptimism: "https://sepolia-optimism.etherscan.io/"
|
||||
|
@ -930,10 +923,6 @@ QtObject {
|
|||
readonly property string arbitrum: "arbitrum"
|
||||
readonly property string optimism: "optimism"
|
||||
|
||||
readonly property string goerliEthereum: "goerli"
|
||||
readonly property string goerliArbitrum: "arbitrum-goerli"
|
||||
readonly property string goerliOptimism: "optimism-goerli"
|
||||
|
||||
readonly property string sepoliaEthereum: "sepolia"
|
||||
readonly property string sepoliaArbitrum: "arbitrum-sepolia"
|
||||
readonly property string sepoliaOptimism: "optimism-sepolia"
|
||||
|
|
|
@ -609,36 +609,24 @@ QtObject {
|
|||
Theme.palette.warningColor1
|
||||
}
|
||||
|
||||
function getEtherscanUrl(networkShortName, testnetMode, sepoliaEnabled, addressOrTx, isAddressNotTx) {
|
||||
function getEtherscanUrl(networkShortName, testnetMode, addressOrTx, isAddressNotTx) {
|
||||
const type = isAddressNotTx
|
||||
? Constants.networkExplorerLinks.addressPath
|
||||
: Constants.networkExplorerLinks.txPath
|
||||
let link = Constants.networkExplorerLinks.etherscan
|
||||
if (testnetMode) {
|
||||
if (sepoliaEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliEtherscan
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaEtherscan
|
||||
}
|
||||
|
||||
if (networkShortName === Constants.networkShortChainNames.arbitrum) {
|
||||
link = Constants.networkExplorerLinks.arbiscan
|
||||
if (testnetMode) {
|
||||
if (sepoliaEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaArbiscan
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliArbiscan
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaArbiscan
|
||||
}
|
||||
} else if (networkShortName === Constants.networkShortChainNames.optimism) {
|
||||
link = Constants.networkExplorerLinks.optimism
|
||||
if (testnetMode) {
|
||||
if (sepoliaEnabled) {
|
||||
link = Constants.networkExplorerLinks.sepoliaOptimism
|
||||
} else {
|
||||
link = Constants.networkExplorerLinks.goerliOptimism
|
||||
}
|
||||
link = Constants.networkExplorerLinks.sepoliaOptimism
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -646,13 +634,13 @@ QtObject {
|
|||
}
|
||||
|
||||
// Etherscan URL for an address
|
||||
function getUrlForAddressOnNetwork(networkShortName, testnetMode, sepoliaEnabled, address) {
|
||||
return getEtherscanUrl(networkShortName, testnetMode, sepoliaEnabled, address, true /* is address */)
|
||||
function getUrlForAddressOnNetwork(networkShortName, testnetMode, address) {
|
||||
return getEtherscanUrl(networkShortName, testnetMode, address, true /* is address */)
|
||||
}
|
||||
|
||||
// Etherscan URL for a transaction
|
||||
function getUrlForTxOnNetwork(networkShortName, testnetMode, sepoliaEnabled, tx) {
|
||||
return getEtherscanUrl(networkShortName, testnetMode, sepoliaEnabled, tx, false /* is TX */)
|
||||
function getUrlForTxOnNetwork(networkShortName, testnetMode, tx) {
|
||||
return getEtherscanUrl(networkShortName, testnetMode, tx, false /* is TX */)
|
||||
}
|
||||
|
||||
// Leave this function at the bottom of the file as QT Creator messes up the code color after this
|
||||
|
|
Loading…
Reference in New Issue