Files
tom goriunovandGitHub ebbee2ba57 Multichain explorer v2 (#3259)
* Support redirect to a correct view from search

* show domains on address page

* migrate to new API version to display address domains

* another api update

* new design for chain widget on home page + tests

* chain widget styles for mobile devices

* ecosystems page

* update types

* add ecosystems to navigation

* address portfolio: pt.1

* portfolio tokens list

* filter portfolio by chain

* skip redirect when navigating to search result by clicking on "show all results" link

* net worth block design

* add filter input to chain select and fix tokens table

* calculate address portfolio

* adjust card logic

* support custom token types in multichain explorer

* handle case when new worth is 0

* add text filter to tokens list

* fixes

* demo envs

* portfolio tests

* ecosystems test

* change signature for getTokenTypes function

* fix adding token to the wallet from the list

* lazy load all address domains

* show contract creator and implementations info

* fix tests

* add poor reputation tokens toggle

* tweaks

* dim celo native tokens

* disable env validator

* fix tests

* remove tokens with 0 usd value from top tokens

* fixes

* preserve selected chain when switching tabs on address page

* add hints to stats widgets on home page

* update envs for demo

* fix portfolio cards and home page

* update styles for contract creator and implementations

* fix select issues

* add chains from cluster to network menu

* hide csv export link on empty logs page

* update screenshots

* rollback select fix

* update cut length calculation for portfolio cards

* fix chain select

* update screenshots

* fix tests

* more fixes

* add sorting to ecosystems table

* fix test

* fixes

* fix loading state in ecosystems page

* review fixes

* fix tests
2026-02-25 10:45:09 +01:00

79 lines
2.3 KiB
TypeScript

import type * as multichain from '@blockscout/multichain-aggregator-types';
import { chainA, chainB, chainC, chainD, chainE } from './chains';
export const domainProtocols: Array<multichain.ProtocolInfo> = [
{
id: 'goose',
short_name: 'GOOSE',
title: 'Goose Name Service',
description: 'The Goose Name Service is a decentralized naming system for the Goose blockchain.',
deployment_blockscout_base_url: 'https://blockscout.com',
tld_list: [ 'goose' ],
icon_url: 'https://goose.com/icon.jpg',
docs_url: 'https://goose.com/docs',
},
{
id: 'duck',
short_name: 'DUCK',
title: 'Duck Name Service',
description: 'The Duck Name Service is a decentralized naming system for the Duck blockchain.',
deployment_blockscout_base_url: 'https://blockscout.com',
tld_list: [ 'duck', 'quack' ],
icon_url: 'https://duck.com/icon.jpg',
docs_url: 'https://duck.com/docs',
},
];
export const addressA: multichain.GetAddressResponse = {
hash: '0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045',
chain_infos: {
[chainA.id]: {
coin_balance: '33298149965862412288',
is_contract: false,
is_verified: false,
contract_name: undefined,
},
[chainB.id]: {
coin_balance: '1836931848855642237',
is_contract: true,
is_verified: false,
contract_name: undefined,
},
[chainC.id]: {
coin_balance: '0',
is_contract: true,
is_verified: true,
contract_name: 'Test Contract',
},
[chainD.id]: {
coin_balance: '0',
is_contract: false,
is_verified: false,
contract_name: undefined,
},
[chainE.id]: {
coin_balance: '0',
is_contract: false,
is_verified: false,
contract_name: undefined,
},
},
has_tokens: true,
has_interop_message_transfers: false,
coin_balance: '35135081814718054525',
exchange_rate: '123.455',
domains: [
{ name: 'ga-ga-ga.goose', protocol: domainProtocols[0] },
{ name: 'quack-quack.duck', protocol: domainProtocols[1] },
],
};
export const addressDomainsA: multichain.LookupAddressDomainsResponse = {
items: [
{ name: 'ga-ga-ga.goose', protocol: domainProtocols[0] },
{ name: 'quack-quack.duck', protocol: domainProtocols[1] },
],
next_page_params: undefined,
};