mirror of
https://github.com/luxfi/explore.git
synced 2026-09-24 00:28:18 +00:00
couple more robust places
This commit is contained in:
+1
-25
@@ -1,6 +1,6 @@
|
||||
import type { Transaction } from 'types/api/transaction';
|
||||
|
||||
import type { UserTags, AddressImplementation, AddressParam } from './addressParams';
|
||||
import type { UserTags, AddressImplementation, AddressParam, AddressFilecoinParams } from './addressParams';
|
||||
import type { Block, EpochRewardsType } from './block';
|
||||
import type { InternalTransaction } from './internalTransaction';
|
||||
import type { MudWorldSchema, MudWorldTable } from './mudWorlds';
|
||||
@@ -270,27 +270,3 @@ export type AddressEpochRewardsItem = {
|
||||
epoch_number: number;
|
||||
associated_account: AddressParam;
|
||||
}
|
||||
|
||||
export type AddressFilecoinParams = {
|
||||
actor_type?: FilecoinActorType;
|
||||
id?: string | null;
|
||||
robust?: string | null;
|
||||
}
|
||||
|
||||
export type FilecoinActorType =
|
||||
'account' |
|
||||
'cron' |
|
||||
'datacap' |
|
||||
'eam' |
|
||||
'ethaccount' |
|
||||
'evm' |
|
||||
'init' |
|
||||
'market' |
|
||||
'miner' |
|
||||
'multisig' |
|
||||
'paych' |
|
||||
'placeholder' |
|
||||
'power' |
|
||||
'reward' |
|
||||
'system' |
|
||||
'verifreg';
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import type { AddressFilecoinParams } from './address';
|
||||
import type { AddressMetadataTagApi } from './addressMetadata';
|
||||
|
||||
export interface AddressImplementation {
|
||||
@@ -17,6 +16,30 @@ export interface WatchlistName {
|
||||
display_name: string;
|
||||
}
|
||||
|
||||
export type AddressFilecoinParams = {
|
||||
actor_type?: FilecoinActorType;
|
||||
id?: string | null;
|
||||
robust?: string | null;
|
||||
}
|
||||
|
||||
export type FilecoinActorType =
|
||||
'account' |
|
||||
'cron' |
|
||||
'datacap' |
|
||||
'eam' |
|
||||
'ethaccount' |
|
||||
'evm' |
|
||||
'init' |
|
||||
'market' |
|
||||
'miner' |
|
||||
'multisig' |
|
||||
'paych' |
|
||||
'placeholder' |
|
||||
'power' |
|
||||
'reward' |
|
||||
'system' |
|
||||
'verifreg';
|
||||
|
||||
export interface UserTags {
|
||||
private_tags: Array<AddressTag> | null;
|
||||
watchlist_names: Array<WatchlistName> | null;
|
||||
|
||||
@@ -17,7 +17,6 @@ import DetailsSponsoredItem from 'ui/shared/DetailsSponsoredItem';
|
||||
import AddressEntity from 'ui/shared/entities/address/AddressEntity';
|
||||
import BlockEntity from 'ui/shared/entities/block/BlockEntity';
|
||||
import TxEntity from 'ui/shared/entities/tx/TxEntity';
|
||||
import HashStringShortenDynamic from 'ui/shared/HashStringShortenDynamic';
|
||||
|
||||
import AddressBalance from './details/AddressBalance';
|
||||
import AddressImplementations from './details/AddressImplementations';
|
||||
@@ -134,10 +133,11 @@ const AddressDetails = ({ addressQuery, scrollRef }: Props) => {
|
||||
Ethereum Address
|
||||
</DetailsInfoItem.Label>
|
||||
<DetailsInfoItem.Value flexWrap="nowrap">
|
||||
<Box overflow="hidden">
|
||||
<HashStringShortenDynamic hash={ data.hash }/>
|
||||
</Box>
|
||||
<CopyToClipboard text={ data.hash }/>
|
||||
<AddressEntity
|
||||
address={{ hash: data.hash }}
|
||||
noIcon
|
||||
noLink
|
||||
/>
|
||||
</DetailsInfoItem.Value>
|
||||
</>
|
||||
) }
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Tag } from '@chakra-ui/react';
|
||||
import React from 'react';
|
||||
|
||||
import type { FilecoinActorType } from 'types/api/address';
|
||||
import type { FilecoinActorType } from 'types/api/addressParams';
|
||||
|
||||
const ACTOR_TYPES: Record<FilecoinActorType, string> = {
|
||||
account: 'Account',
|
||||
|
||||
@@ -349,7 +349,6 @@ const AddressPageContent = () => {
|
||||
address={{
|
||||
...addressQuery.data,
|
||||
hash: checkSummedHash,
|
||||
filecoin: addressQuery.data?.filecoin,
|
||||
name: '',
|
||||
ens_domain_name: '',
|
||||
implementations: null,
|
||||
|
||||
@@ -99,7 +99,7 @@ const Content = chakra((props: ContentProps) => {
|
||||
const label = (
|
||||
<VStack gap={ 0 } py={ 1 } color="inherit">
|
||||
<Box fontWeight={ 600 } whiteSpace="pre-wrap" wordBreak="break-word">{ nameText }</Box>
|
||||
<Box whiteSpace="pre-wrap" wordBreak="break-word">{ props.address.hash }</Box>
|
||||
<Box whiteSpace="pre-wrap" wordBreak="break-word">{ props.address.filecoin?.robust ?? props.address.hash }</Box>
|
||||
</VStack>
|
||||
);
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@ const AddressEntityContentProxy = (props: ContentProps) => {
|
||||
Proxy contract
|
||||
{ props.address.name ? ` (${ props.address.name })` : '' }
|
||||
</Box>
|
||||
<AddressEntity address={{ hash: props.address.hash }} noLink noIcon noHighlight justifyContent="center"/>
|
||||
<AddressEntity address={{ hash: props.address.hash, filecoin: props.address.filecoin }} noLink noIcon noHighlight justifyContent="center"/>
|
||||
<Box fontWeight={ 600 } mt={ 2 }>
|
||||
Implementation{ implementations.length > 1 ? 's' : '' }
|
||||
{ implementationName ? ` (${ implementationName })` : '' }
|
||||
|
||||
Reference in New Issue
Block a user