diff --git a/mocks/txs/internalTxs.ts b/mocks/txs/internalTxs.ts index 23fc4bf027..7917e08517 100644 --- a/mocks/txs/internalTxs.ts +++ b/mocks/txs/internalTxs.ts @@ -1,7 +1,7 @@ import type { InternalTransaction, InternalTransactionsResponse } from 'types/api/internalTransaction'; export const base: InternalTransaction = { - block: 29611822, + block_number: 29611822, created_contract: null, error: null, from: { diff --git a/mocks/txs/tx.ts b/mocks/txs/tx.ts index bae57c630e..18c6446e85 100644 --- a/mocks/txs/tx.ts +++ b/mocks/txs/tx.ts @@ -8,7 +8,7 @@ import * as decodedInputDataMock from 'mocks/txs/decodedInputData'; export const base: Transaction = { base_fee_per_gas: '10000000000', - block: 29611750, + block_number: 29611750, confirmation_duration: [ 0, 6364, @@ -61,14 +61,14 @@ export const base: Transaction = { token_transfers: [], token_transfers_overflow: false, tx_burnt_fee: '461030000000000', - tx_tag: null, - tx_types: [ + transaction_tag: null, + transaction_types: [ 'contract_call', ], type: 2, value: '42000000000000000000', actions: [], - has_error_in_internal_txs: false, + has_error_in_internal_transactions: false, }; export const withWatchListNames: Transaction = { @@ -102,7 +102,7 @@ export const withContractCreation: Transaction = { watchlist_names: [], ens_domain_name: null, }, - tx_types: [ + transaction_types: [ 'contract_creation', ], }; @@ -132,7 +132,7 @@ export const withTokenTransfer: Transaction = { tokenTransferMock.erc404B, ], token_transfers_overflow: true, - tx_types: [ + transaction_types: [ 'token_transfer', ], }; @@ -182,7 +182,7 @@ export const withRawRevertReason: Transaction = { export const pending: Transaction = { ...base, base_fee_per_gas: null, - block: null, + block_number: null, confirmation_duration: [], confirmations: 0, decoded_input: null, @@ -197,7 +197,7 @@ export const pending: Transaction = { status: null, timestamp: null, tx_burnt_fee: null, - tx_tag: null, + transaction_tag: null, type: null, value: '0', }; @@ -373,7 +373,7 @@ export const withBlob = { ], burnt_blob_fee: '2820464441688064', max_fee_per_blob_gas: '60000000000', - tx_types: [ 'blob_transaction' as const ], + transaction_types: [ 'blob_transaction' as const ], type: 3, }; diff --git a/stubs/internalTx.ts b/stubs/internalTx.ts index 15f0785da9..f0e24bd1f1 100644 --- a/stubs/internalTx.ts +++ b/stubs/internalTx.ts @@ -4,7 +4,7 @@ import { ADDRESS_PARAMS } from './addressParams'; import { TX_HASH } from './tx'; export const INTERNAL_TX: InternalTransaction = { - block: 9006105, + block_number: 9006105, created_contract: null, error: null, from: ADDRESS_PARAMS, diff --git a/stubs/tx.ts b/stubs/tx.ts index 2e80408689..370712b220 100644 --- a/stubs/tx.ts +++ b/stubs/tx.ts @@ -12,7 +12,7 @@ export const TX: Transaction = { value: '2100000000000000', }, gas_limit: '21000', - block: 9004925, + block_number: 9004925, status: 'ok', method: 'placeholder', confirmations: 71, @@ -28,14 +28,14 @@ export const TX: Transaction = { base_fee_per_gas: '24', from: ADDRESS_PARAMS, token_transfers: null, - tx_types: [ + transaction_types: [ 'coin_transfer', ], gas_used: '21000', created_contract: null, position: 0, nonce: 295929, - has_error_in_internal_txs: false, + has_error_in_internal_transactions: false, actions: [], decoded_input: null, token_transfers_overflow: false, @@ -47,7 +47,7 @@ export const TX: Transaction = { 0, 14545, ], - tx_tag: null, + transaction_tag: null, }; export const TX_ZKEVM_L2: Transaction = { diff --git a/types/api/internalTransaction.ts b/types/api/internalTransaction.ts index 1eae8f45e8..d953f2cd82 100644 --- a/types/api/internalTransaction.ts +++ b/types/api/internalTransaction.ts @@ -19,7 +19,7 @@ export type InternalTransaction = ( from: AddressParam; value: string; index: number; - block: number; + block_number: number; timestamp: string; gas_limit: string; }; diff --git a/types/api/transaction.ts b/types/api/transaction.ts index c024c045e7..dfefc37e35 100644 --- a/types/api/transaction.ts +++ b/types/api/transaction.ts @@ -30,7 +30,7 @@ export type Transaction = { result: string; confirmations: number; status: 'ok' | 'error' | null | undefined; - block: number | null; + block_number: number | null; timestamp: string | null; confirmation_duration: Array | null; from: AddressParam; @@ -54,14 +54,14 @@ export type Transaction = { token_transfers_overflow: boolean; exchange_rate: string | null; method: string | null; - tx_types: Array; - tx_tag: string | null; + transaction_types: Array; + transaction_tag: string | null; actions: Array; l1_fee?: string; l1_fee_scalar?: string; l1_gas_price?: string; l1_gas_used?: string; - has_error_in_internal_txs: boolean | null; + has_error_in_internal_transactions: boolean | null; // optimism fields op_withdrawals?: Array; // SUAVE fields diff --git a/ui/address/internals/AddressIntTxsListItem.tsx b/ui/address/internals/AddressIntTxsListItem.tsx index 2e38defecb..df13c6dbee 100644 --- a/ui/address/internals/AddressIntTxsListItem.tsx +++ b/ui/address/internals/AddressIntTxsListItem.tsx @@ -26,7 +26,7 @@ const TxInternalsListItem = ({ error, created_contract: createdContract, transaction_hash: txnHash, - block, + block_number: blockNumber, timestamp, currentAddress, isLoading, @@ -59,7 +59,7 @@ const TxInternalsListItem = ({ Block { - + diff --git a/ui/home/LatestTxsItemMobile.tsx b/ui/home/LatestTxsItemMobile.tsx index a76e6de4b8..c5b852a776 100644 --- a/ui/home/LatestTxsItemMobile.tsx +++ b/ui/home/LatestTxsItemMobile.tsx @@ -40,7 +40,7 @@ const LatestTxsItem = ({ tx, isLoading }: Props) => { > - + diff --git a/ui/pages/Transaction.tsx b/ui/pages/Transaction.tsx index b9086c2fa9..28d64ca3fd 100644 --- a/ui/pages/Transaction.tsx +++ b/ui/pages/Transaction.tsx @@ -77,7 +77,7 @@ const TransactionPageContent = () => { const tags = ( ); @@ -94,7 +94,7 @@ const TransactionPageContent = () => { }; }, [ appProps.referrer ]); - const titleSecondRow = ; + const titleSecondRow = ; const content = (() => { if (isPlaceholderData && !showDegradedView) { diff --git a/ui/shared/AccountActionsMenu/items/PrivateTagMenuItem.tsx b/ui/shared/AccountActionsMenu/items/PrivateTagMenuItem.tsx index c92dbcceda..2d72b6a172 100644 --- a/ui/shared/AccountActionsMenu/items/PrivateTagMenuItem.tsx +++ b/ui/shared/AccountActionsMenu/items/PrivateTagMenuItem.tsx @@ -38,7 +38,7 @@ const PrivateTagMenuItem = ({ className, hash, entityType = 'address', type }: P queryData && ( ('private_tags' in queryData && queryData.private_tags?.length) || - ('tx_tag' in queryData && queryData.tx_tag) + ('transaction_tag' in queryData && queryData.transaction_tag) ) ) { return null; diff --git a/ui/tx/TxDetailsDegraded.tsx b/ui/tx/TxDetailsDegraded.tsx index e1bace40d9..316f90dade 100644 --- a/ui/tx/TxDetailsDegraded.tsx +++ b/ui/tx/TxDetailsDegraded.tsx @@ -81,7 +81,7 @@ const TxDetailsDegraded = ({ hash, txQuery }: Props) => { timestamp: block?.timestamp ? dayjs.unix(Number(block.timestamp)).format() : null, confirmation_duration: null, status, - block: tx.blockNumber ? Number(tx.blockNumber) : null, + block_number: tx.blockNumber ? Number(tx.blockNumber) : null, value: tx.value.toString(), gas_price: gasPrice?.toString() ?? null, base_fee_per_gas: block?.baseFeePerGas?.toString() ?? null, @@ -106,13 +106,13 @@ const TxDetailsDegraded = ({ hash, txQuery }: Props) => { tx_burnt_fee: null, revert_reason: null, decoded_input: null, - has_error_in_internal_txs: null, + has_error_in_internal_transactions: null, token_transfers: null, token_transfers_overflow: false, exchange_rate: null, method: null, - tx_types: [], - tx_tag: null, + transaction_types: [], + transaction_tag: null, actions: [], }; }, diff --git a/ui/tx/details/TxInfo.tsx b/ui/tx/details/TxInfo.tsx index 18ee2373a6..cacf39a116 100644 --- a/ui/tx/details/TxInfo.tsx +++ b/ui/tx/details/TxInfo.tsx @@ -282,11 +282,11 @@ const TxInfo = ({ data, isLoading, socketStatus }: Props) => { Block - { data.block === null ? + { data.block_number === null ? Pending : ( ) } diff --git a/ui/txs/TxsListItem.tsx b/ui/txs/TxsListItem.tsx index fa572c6e74..5483c22011 100644 --- a/ui/txs/TxsListItem.tsx +++ b/ui/txs/TxsListItem.tsx @@ -39,9 +39,14 @@ const TxsListItem = ({ tx, isLoading, showBlockInfo, currentAddress, enableTimeI - { tx.translation ? - : - + { tx.translation ? ( + + ) : + } @@ -55,7 +60,7 @@ const TxsListItem = ({ tx, isLoading, showBlockInfo, currentAddress, enableTimeI truncation="constant_long" fontWeight="700" icon={{ - name: tx.tx_types.includes('blob_transaction') ? 'blob' : undefined, + name: tx.transaction_types.includes('blob_transaction') ? 'blob' : undefined, }} /> ) } - { showBlockInfo && tx.block !== null && ( + { showBlockInfo && tx.block_number !== null && ( Block diff --git a/ui/txs/TxsTableItem.tsx b/ui/txs/TxsTableItem.tsx index 68eca58c6e..0d95b76abb 100644 --- a/ui/txs/TxsTableItem.tsx +++ b/ui/txs/TxsTableItem.tsx @@ -67,9 +67,14 @@ const TxsTableItem = ({ tx, showBlockInfo, currentAddress, enableTimeIncrement, - { tx.translation ? - : - + { tx.translation ? ( + + ) : + } @@ -84,10 +89,10 @@ const TxsTableItem = ({ tx, showBlockInfo, currentAddress, enableTimeIncrement, { showBlockInfo && ( - { tx.block && ( + { tx.block_number && (