Bug: Tx hash overflows success box on Limit Orders and Swap pages #54
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:implement
agent:implement
agent:open_issues
agent:ready
agent:research
agent:security_audit
agent:verify
architecture
backend
blocker:hybrid
blocker:launch
blocker:limit-orders
blocker:v2
block:log_only
block:security
bug
ci
contracts
correctness
deploy
dev
devops
docs
documentation
duplicate
e2e
enhancement
epic
feature
frontend
functional-completion
gas
good first issue
governance
help wanted
high-risk
hooks
hybrid
indexer
infra
infrastructure
integrators
invalid
launch-blocker
limit-orders
localnet
localterra
low priority
missing-implementation
needs-design
ops
performance
priority
high
priority
medium
product
qa
QA
question
ready
ready
research
scripts
security
security-hardening
smartcontracts
tech-debt
testing
ux
UX
v2
verification
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/cl8y-dex-terraclassic#54
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Current behavior: when a limit order is placed or swap completes, the success box shows the tx hash but the text overflows the container and gets cut off on the right. hash is not truncated or wrapped.
Expected behavior: tx hash should be truncated with ellipsis (e.g. 290F52E6...D819A) or wrapped to fit within the success box. should also be a clickable link to the block explorer.
Acceptance criteria:
tested on
671e72f.marked the checklist item screenshot evidence of fix as completed
marked the checklist item screenshot evidence of fix as incomplete
mentioned in issue #50
Pushed a fix on
main(b5751a9).Cause: Limit orders put the full tx hash in the success
messagestring instead of using thetxHashprop, soTxResultAlertnever applied truncation or explorer links. WhengetExplorerTxUrlreturned null, the alert also fell back to showing the full raw hash.Fix: Added
shortenTxHashForDisplay()interraExplorer.ts(reusesshortenAddress).TxResultAlertalways shows a middle-elided label withtitlefor the full hash; explorer links are unchanged when a URL exists. Limit orders now passtxHashseparately.TradesTableuses the same helper for consistent tx labels.Unit tests:
TxResultAlert,terraExplorer, and updatedTradesTabletests.Please verify swap + limit flows on desktop and mobile and add a screenshot for the AC. Leaving this issue open for QA.
cc @brouie
Verified on
38afbf8. Tx hash now truncates cleanly in success alerts on both Swap and Limit Orders pages. shortenTxHashForDisplay helper reuses existing shortenAddress. Full hash visible on hover via title attr. break-all prevents overflow. New test file TxResultAlert.test.tsx (3 tests passing). Frontend 214/214.