diff options
| author | Adam Soltys <[email protected]> | 2026-09-04 18:42:49 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-09-04 18:42:49 -0700 |
| commit | 90641c1244e70179027cf99c5bdab6c6b43dd28c (patch) | |
| tree | 9d08deb72992579751f0fd23875bf0341d4fd836 /src/features/ark.js | |
| parent | 4431198900b2d1a5cfb73bd02ddfd1e377d9acb9 (diff) | |
| download | coinosv3-90641c1244e70179027cf99c5bdab6c6b43dd28c.tar.gz coinosv3-90641c1244e70179027cf99c5bdab6c6b43dd28c.zip | |
Spending-coins rows say what they mean: the exit chip reads "exit cost 3,688 sats" (unit included) instead of "exit 3,688", the renewal price moved off the row's right edge into a chip like its siblings — "renewal cost 117 sats" (or "renewal cost free") — and the expiry chip carries a word beside its hourglass ("⏳ expiry 21d"). The depth chip is gone: hop count is implementation detail nobody needed to weigh, and the exit cost already prices its consequence. depthOf and the depth strings retired with it
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
Diffstat (limited to 'src/features/ark.js')
| -rw-r--r-- | src/features/ark.js | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/src/features/ark.js b/src/features/ark.js index 4c65549..b65bce2 100644 --- a/src/features/ark.js +++ b/src/features/ark.js @@ -1885,7 +1885,6 @@ export function arkFeature(ctx) { let exitFee = 0; try { exitFee = estimateExitFeeSat(mgr); } catch {} const feeRate = Math.max(1, (wallet.feeRates && wallet.feeRates.halfHourFee) || 2); const afterFee = Math.ceil(530 * feeRate); - const depthOf = (v) => { try { return mgr._decoded(v).genesis.length; } catch { return null; } }; // relative and terse — "14d" / "13h" beside the hourglass — a date says // less than a countdown, and a coin past its height says so plainly // instead of the shifty "0h" (the server still honors it; the wallet's @@ -1971,7 +1970,6 @@ export function arkFeature(ctx) { }, t('arkCoinsSelectAll')), h('span', { class: 'small faint' }, t('arkCoinsSelectAll'))), ...spend.map((v) => { - const d = depthOf(v); const f = feeNowOf(v); const xf = exitFeeOf(v); return h('label', { class: 'coin' }, @@ -1980,22 +1978,20 @@ export function arkFeature(ctx) { render(); }), h('div', { class: 'col grow', style: 'gap:3px;min-width:0' }, - h('div', { class: 'row between', style: 'align-items:baseline;gap:8px' }, - h('span', {}, fmtAmount(v.amountSat), - h('span', { class: 'small faint' }, ' ' + unitLabel())), - h('span', { class: 'small ' + (f > 0 ? 'muted' : 'faint') }, - t('arkCoinsRowRenew', { fee: f > 0 ? fmtAmount(f) : t('arkDepthFree') }))), + h('span', {}, fmtAmount(v.amountSat), + h('span', { class: 'small faint' }, ' ' + unitLabel())), // little labeled chips instead of a dot-separated line: each - // fact wears its own pill, wrapping freely on narrow screens + // fact wears its own pill, wrapping freely on narrow screens — + // the renewal price rides here too, a chip like its siblings h('div', { class: 'coin-chips' }, h('span', { class: 'coin-chip' + (v.expiryHeight && tip && v.expiryHeight - tip <= 0 ? ' warn' : ''), title: t('arkCoinsChipExpTitle'), - }, '⏳ ' + expiresOf(v)), - h('span', { class: 'coin-chip', title: t('arkCoinsChipDepthTitle') }, - t('arkCoinsChipDepth', { d: d == null ? '—' : String(d) })), + }, '⏳ ' + t('arkCoinsChipExp', { d: expiresOf(v) })), h('span', { class: 'coin-chip', title: t('arkCoinsChipExitTitle') }, - t('arkCoinsChipExit', { fee: xf == null ? '—' : fmtAmount(xf) }))))); + t('arkCoinsChipExit', { fee: xf == null ? '—' : fmtAmount(xf) + ' ' + unitLabel() })), + h('span', { class: 'coin-chip', title: t('arkCoinsChipRenewTitle') }, + t('arkCoinsChipRenew', { fee: f > 0 ? fmtAmount(f) + ' ' + unitLabel() : t('arkDepthFree') }))))); })), h('p', { class: 'small faint', style: 'margin:4px 0 0' }, t('arkCoinsExpiryNote'))), h('div', { class: 'card col', style: 'gap:8px' }, |
