From a86bd1fed7e3af493bf62416d17dd6de2bcb91d1 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Wed, 21 Oct 2026 00:37:12 +0200 Subject: [PATCH 1/3] fix: copy usdt transaction id on tap --- .../wallets/usdt/UsdtActivityDetail.kt | 23 +++++++++++++++++-- changelog.d/next/1633.fixed.md | 1 + 2 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 changelog.d/next/1633.fixed.md diff --git a/app/src/main/java/to/bitkit/ui/screens/wallets/usdt/UsdtActivityDetail.kt b/app/src/main/java/to/bitkit/ui/screens/wallets/usdt/UsdtActivityDetail.kt index 1aedaf3cc5..5464b5a1cc 100644 --- a/app/src/main/java/to/bitkit/ui/screens/wallets/usdt/UsdtActivityDetail.kt +++ b/app/src/main/java/to/bitkit/ui/screens/wallets/usdt/UsdtActivityDetail.kt @@ -40,8 +40,10 @@ import com.synonym.bitkitcore.usdtFormatAmount import to.bitkit.R import to.bitkit.env.Env import to.bitkit.ext.UiDateStyle +import to.bitkit.ext.ellipsisMiddle import to.bitkit.ext.uiDateStyleFor import to.bitkit.models.PubkyPublicKeyFormat +import to.bitkit.models.Toast import to.bitkit.ui.appViewModel import to.bitkit.ui.components.BodyMSB import to.bitkit.ui.components.BodyS @@ -61,7 +63,9 @@ import to.bitkit.ui.screens.wallets.activity.components.AmountViewContent import to.bitkit.ui.screens.wallets.activity.components.CircularIcon import to.bitkit.ui.settingsViewModel import to.bitkit.ui.shared.UiConstants +import to.bitkit.ui.shared.modifiers.clickableAlpha import to.bitkit.ui.theme.Colors +import to.bitkit.ui.utils.copyToClipboard import to.bitkit.ui.utils.uiDateText @Composable @@ -240,8 +244,23 @@ internal val UsdtTransfer.detailTitleResource: Int get() = when { @Composable private fun UsdtTechnicalDetails(transfer: UsdtTransfer, hideBalance: Boolean, walletAddress: String) { transfer.txHash?.let { hash -> - UsdtDetailField(caption = stringResource(R.string.wallet__activity_tx_id)) { - SelectionContainer { BodySSB(hash, style = UsdtDetailStyles.Body) } + val app = appViewModel + val copiedText = stringResource(R.string.common__copied) + UsdtDetailField( + caption = stringResource(R.string.wallet__activity_tx_id), + modifier = Modifier + .clickableAlpha( + onClick = copyToClipboard(hash) { + app?.toast( + type = Toast.ToastType.SUCCESS, + title = copiedText, + description = it.ellipsisMiddle(40), + ) + } + ) + .testTag("UsdtActivityTxId") + ) { + BodySSB(hash, style = UsdtDetailStyles.Body) } } val sender = transfer.sender ?: walletAddress.takeIf { !transfer.isIncoming && it.isNotEmpty() } diff --git a/changelog.d/next/1633.fixed.md b/changelog.d/next/1633.fixed.md new file mode 100644 index 0000000000..28ccf7312f --- /dev/null +++ b/changelog.d/next/1633.fixed.md @@ -0,0 +1 @@ +Tapping the transaction ID in USDT activity details now copies it. From a8fc402d6bf3be7554fb78868633a8c8ca46fcce Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Wed, 21 Oct 2026 02:35:32 +0200 Subject: [PATCH 2/3] test: cover usdt transaction id copy in the details journey --- journeys/usdt-send-review-and-details.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/journeys/usdt-send-review-and-details.xml b/journeys/usdt-send-review-and-details.xml index 64186accf5..db1194d2ea 100644 --- a/journeys/usdt-send-review-and-details.xml +++ b/journeys/usdt-send-review-and-details.xml @@ -12,6 +12,7 @@ Using the local quote fixture, prepare a 5 USDT bridge with 2 USDT received and a small network fee. Try to proceed and verify the fee-over-half-value warning appears before payment authentication. Cancel without paying. Using the local payment fixture, show a submitted direct payment as Pending, then change it to Confirmed. Verify completion feedback and the success screen are shown. Repeat with a cross-network payment: Bridging remains submitted until delivery is Confirmed, then shows successful completion without presenting it as still pending. Do not submit a real payment for this check. Open an existing sent USDT activity. Verify the heading is Sent USDT, the signed amount includes the actual fee, and summary rows show Status/Network, Date/Time and Payment/Fee with teal icons. Open Details and verify transaction ID, known sender, recipient and source/destination networks; Open Block Explorer stays at the bottom. + Tap the transaction ID (testTag "UsdtActivityTxId") and verify from a screenshot that a "Copied To Clipboard" toast appears with the hash, and that the clipboard holds the full transaction hash Open an existing received activity. Verify Received USDT and a positive amount. Verify Details shows the verified sender when available and does not invent one for older unknown records. Check pending, failed and transferring rows use their matching icons, and transferring shows its destination. Prepare a contact payment that accepts multiple payment methods. Open the payment-source button and verify the balance menu shows Savings, Spending, any paired hardware wallet and USDT. Unsupported methods are disabled and shown at 30% opacity. Verify the menu has 24px outer padding, 24px asset icons, 13/18 uppercase labels and 17/22 balances, with no extra transfer icon next to Spending. Select a supported method and verify its label, available balance and payable amount update. Cancel without paying. From d5e527f40e97615fd2a2c2f207c45b5464947c9f Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Wed, 21 Oct 2026 02:36:49 +0200 Subject: [PATCH 3/3] test: cover usdt transaction id copy on the bridge fixture journey --- journeys/usdt-bridge-details.xml | 1 + journeys/usdt-send-review-and-details.xml | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/journeys/usdt-bridge-details.xml b/journeys/usdt-bridge-details.xml index 17557d9cf4..f153e2ccb5 100644 --- a/journeys/usdt-bridge-details.xml +++ b/journeys/usdt-bridge-details.xml @@ -11,6 +11,7 @@ While Cross-Network Deposits is open, inject a confirmed incoming USDT transfer through the isolated fixture. Verify no received sheet interrupts deposit details or refund review. Return to the USDT wallet and verify the received celebration appears once after any active sheet is dismissed. Dismiss it and revisit deposit details, then return to the wallet; verify the same receipt does not appear again. Open the outgoing delivering USDT activity. Verify the Delivering USDT title, outgoing amount, teal up arrow, yellow Delivering status and actual receiving network. Tap Details (id "UsdtActivityDetails"). Verify the source transaction, sender and recipient addresses, sender and recipient networks, Orchestra provider and bridge reference. Verify Open Block Explorer (id "UsdtActivityExplorer") and Hide details remain reachable. + Tap the transaction ID (id "UsdtActivityTxId"). Verify from a screenshot that a "Copied To Clipboard" toast appears with the hash, and verify the clipboard holds the full source transaction hash. For a delayed, failed, refunding, refunded or support-needed bridge fixture, verify Contact Support (id "UsdtContactSupport") and Copy Details (id "UsdtCopyDetails") appear side by side as small 40-point buttons, matching the Request refund / Hide details row. Verify both remain reachable and their labels are not clipped, without submitting either action. Return to the USDT activity list. Verify Pending uses a yellow hourglass and 16% yellow circle, Failed uses a red x-circle and 16% red circle, and Transferring uses the teal transfer arrows. Sent and Received remain teal. Open USDT Receive and inject one confirmed incoming USDT transfer through the isolated fixture. Verify Receive is replaced by one received celebration. Dismiss it and verify the same transfer is not celebrated again; a different subsequent transfer must still be shown. diff --git a/journeys/usdt-send-review-and-details.xml b/journeys/usdt-send-review-and-details.xml index db1194d2ea..64186accf5 100644 --- a/journeys/usdt-send-review-and-details.xml +++ b/journeys/usdt-send-review-and-details.xml @@ -12,7 +12,6 @@ Using the local quote fixture, prepare a 5 USDT bridge with 2 USDT received and a small network fee. Try to proceed and verify the fee-over-half-value warning appears before payment authentication. Cancel without paying. Using the local payment fixture, show a submitted direct payment as Pending, then change it to Confirmed. Verify completion feedback and the success screen are shown. Repeat with a cross-network payment: Bridging remains submitted until delivery is Confirmed, then shows successful completion without presenting it as still pending. Do not submit a real payment for this check. Open an existing sent USDT activity. Verify the heading is Sent USDT, the signed amount includes the actual fee, and summary rows show Status/Network, Date/Time and Payment/Fee with teal icons. Open Details and verify transaction ID, known sender, recipient and source/destination networks; Open Block Explorer stays at the bottom. - Tap the transaction ID (testTag "UsdtActivityTxId") and verify from a screenshot that a "Copied To Clipboard" toast appears with the hash, and that the clipboard holds the full transaction hash Open an existing received activity. Verify Received USDT and a positive amount. Verify Details shows the verified sender when available and does not invent one for older unknown records. Check pending, failed and transferring rows use their matching icons, and transferring shows its destination. Prepare a contact payment that accepts multiple payment methods. Open the payment-source button and verify the balance menu shows Savings, Spending, any paired hardware wallet and USDT. Unsupported methods are disabled and shown at 30% opacity. Verify the menu has 24px outer padding, 24px asset icons, 13/18 uppercase labels and 17/22 balances, with no extra transfer icon next to Spending. Select a supported method and verify its label, available balance and payable amount update. Cancel without paying.