diff options
| author | Adam Soltys <[email protected]> | 2026-08-28 19:43:03 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-08-28 19:43:03 -0700 |
| commit | 30ca37f5acfcfb083f1b78cd91a1faa7ccbba6d4 (patch) | |
| tree | 565fe0291027e357ee6117d0be5391ee45b19774 /src/features | |
| parent | 560c52c91d66181744c120187506399065e92c44 (diff) | |
| download | coinosv3-30ca37f5acfcfb083f1b78cd91a1faa7ccbba6d4.tar.gz coinosv3-30ca37f5acfcfb083f1b78cd91a1faa7ccbba6d4.zip | |
The advisory names both prices: "renew for 2 sats to bring that down to about 1,060" — and stays silent when renewing wouldn't actually help; the toast learns to speak in one plain breath
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_019eA8JRq9Wr7z2fRQk99HLi
Diffstat (limited to 'src/features')
| -rw-r--r-- | src/features/ark.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/features/ark.js b/src/features/ark.js index be5bdd7..12362cc 100644 --- a/src/features/ark.js +++ b/src/features/ark.js @@ -1481,8 +1481,13 @@ export function arkFeature(ctx) { if (depth < EXIT_DEPTH_ADVISORY) return null; let exitFee = 0; try { exitFee = estimateExitFeeSat(ark); } catch {} let renewFee = 0; try { renewFee = ark.refreshFee(spend, ark._tipH || 0); } catch {} + // after a renewal everything is ONE coin, ONE hop: parent + its fee + // child + the claim, ~530 vB all in at today's rate + const feeRate = Math.max(1, (wallet.feeRates && wallet.feeRates.halfHourFee) || 2); + const afterFee = Math.ceil(530 * feeRate); + if (afterFee >= exitFee) return null; // renewing wouldn't help — stay quiet return h('div', { class: 'small muted', style: 'margin:10px 0 0;text-align:center' }, - t('arkDepthNotice', { fee: fmtAmount(exitFee), renew: renewFee > 0 ? fmtAmount(renewFee) + ' sats' : t('arkDepthFree') }), + t('arkDepthNotice', { fee: fmtAmount(exitFee), renew: renewFee > 0 ? fmtAmount(renewFee) + ' sats' : t('arkDepthFree'), after: fmtAmount(afterFee) }), ' ', h('button', { class: 'linklike small', disabled: !!ui.arkBusy, onClick: () => { // fire and let the round machinery carry it — rounds can be an hour out |
