diff options
| author | Adam Soltys <[email protected]> | 2026-06-16 01:41:50 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-06-16 01:41:50 -0700 |
| commit | 833cfd2459aa8d668b787a421414dd5376bb7882 (patch) | |
| tree | 32af3ff1ee23ffe7482112084a8bd04ab8cc3c8a | |
| parent | 1cb481d2c906b983b325c97cd2629b253ebe7db4 (diff) | |
| download | coinosv3-833cfd2459aa8d668b787a421414dd5376bb7882.tar.gz coinosv3-833cfd2459aa8d668b787a421414dd5376bb7882.zip | |
Tidy tx details layout on mobile
Fix the key/value rows wrapping awkwardly on narrow screens (right-align +
wrap-safe values, fixed-width key). Drop the redundant "When: Unconfirmed…"
line; pending now shows a single "Status: Pending (in mempool)". Confirmed txs
show Status / Block / Date.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
| -rw-r--r-- | src/app.js | 9 | ||||
| -rw-r--r-- | src/style.css | 6 |
2 files changed, 7 insertions, 8 deletions
@@ -1048,9 +1048,6 @@ function historyTab() { function txDetailView(t) { const incoming = t.net >= 0; - const when = t.confirmed && t.blockTime - ? new Date(t.blockTime * 1000).toLocaleString() + ' · ' + timeAgo(t.blockTime) - : 'Unconfirmed — waiting to be mined'; const line = (k, v) => h('div', { class: 'line' }, h('span', { class: 'k' }, k), h('span', { class: 'v' }, v)); return h( 'div', @@ -1064,8 +1061,9 @@ function txDetailView(t) { ' ', unitTag('unit') ), h('div', { class: 'summary col', style: 'gap:0' }, - line('Status', t.confirmed ? `Confirmed (block ${t.blockHeight || '—'})` : 'In mempool'), - line('When', when), + line('Status', t.confirmed ? 'Confirmed' : 'Pending (in mempool)'), + t.confirmed ? line('Block', String(t.blockHeight || '—')) : null, + t.confirmed && t.blockTime ? line('Date', new Date(t.blockTime * 1000).toLocaleString()) : null, !incoming && t.fee ? line('Network fee', fmtAmount(t.fee) + ' ' + unitLabel()) : null ), h('div', { class: 'col gap6' }, @@ -1128,3 +1126,4 @@ if (!restoreSession()) render(); + diff --git a/src/style.css b/src/style.css index ed1d542..dce2d88 100644 --- a/src/style.css +++ b/src/style.css @@ -185,9 +185,9 @@ textarea { resize: vertical; min-height: 84px; font-family: var(--mono); font-si /* ---- review / summary ---- */ .summary { background: #f7f8fa; border: 1px solid var(--line); border-radius: 12px; padding: 14px; } -.summary .line { display: flex; justify-content: space-between; padding: 4px 0; font-size: 14px; } -.summary .line .k { color: var(--muted); } -.summary .line .v { font-family: var(--mono); } +.summary .line { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; font-size: 14px; align-items: baseline; } +.summary .line .k { color: var(--muted); flex: none; } +.summary .line .v { font-family: var(--mono); text-align: right; min-width: 0; word-break: break-word; } /* ---- misc ---- */ .notice { border-radius: 11px; padding: 11px 13px; font-size: 14px; } |
