From c1af03186ca5efdb174ab44472081d1d539a85de Mon Sep 17 00:00:00 2001 From: Nicholas Barnett Date: Tue, 21 Jan 2025 14:38:44 -0600 Subject: [PATCH] feat: updated the text --- src/app/_components/NavBar/NetworkLabel.tsx | 20 ++------------------ src/app/txid/[txId]/TxAlerts.tsx | 10 ++++------ src/app/txid/[txId]/TxPage.tsx | 2 +- 3 files changed, 7 insertions(+), 25 deletions(-) diff --git a/src/app/_components/NavBar/NetworkLabel.tsx b/src/app/_components/NavBar/NetworkLabel.tsx index f26f4bba4..67f7f584b 100644 --- a/src/app/_components/NavBar/NetworkLabel.tsx +++ b/src/app/_components/NavBar/NetworkLabel.tsx @@ -1,5 +1,4 @@ -import { Badge, Spinner } from '@chakra-ui/react'; -import { Flex, Icon, Stack } from '@chakra-ui/react'; +import { Badge, Flex, Icon, Spinner, Stack } from '@chakra-ui/react'; import { Check, Trash } from '@phosphor-icons/react'; import { FC, useMemo } from 'react'; @@ -77,7 +76,7 @@ export const NetworkLabel: FC<{ network: Network }> = ({ network }) => { > {network.label} - {network.isSubnet ? ( + {network.isSubnet && ( = ({ network }) => { > subnet - ) : ( - - Nakamoto 3.0 - )} result.message) || [] // )?.filter((message: string) => !!message); - const failedMessage = + const reasonForFailure = tx.tx_status === 'abort_by_response' ? 'This transaction did not succeed because the transaction was aborted during its execution' : 'This transaction would have succeeded, but was rolled back by a supplied post-condition'; + const failedMessage = `${reasonForFailure}. A failed transaction is included in a block (mining fees are paid to the miner and are non-refundable), but failed because it violated the rules of the Stacks protocol or of the smart contract it interacted with. See the error code and/or the contract to learn more about the specific cause of failure.`; + const longPendingMessage = - 'Transactions that cannot be confirmed within 256 blocks are eventually canceled automatically'; + 'A dropped transaction is a transaction that cannot be mined. Dropped transactions do not incur mining fees and will expire after 256 tenures (~42 hours). While these transactions do not become part of chain history, some indexers may still show data for these transactions for a period of time after expiration.'; const nonCanonicalMessage = 'This transaction is in a non-canonical fork. It is not in the canonical Stacks chain'; diff --git a/src/app/txid/[txId]/TxPage.tsx b/src/app/txid/[txId]/TxPage.tsx index 7c5db9236..f7be2d1e2 100644 --- a/src/app/txid/[txId]/TxPage.tsx +++ b/src/app/txid/[txId]/TxPage.tsx @@ -40,7 +40,7 @@ const txStatusIconMap: Record = { const txStatusLabelMap = { pending: 'In mempool', success: 'Confirmed', - success_anchor_block: 'Confirmed in anchor block', + success_anchor_block: 'Confirmed in block', success_microblock: 'Included in microblock', non_canonical: 'Non-canonical (orphaned)', failed: 'Failed',