diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/features/ark.js | 15 | ||||
| -rw-r--r-- | src/i18n.js | 1 |
2 files changed, 12 insertions, 4 deletions
diff --git a/src/features/ark.js b/src/features/ark.js index 8026ed9..c02b9f9 100644 --- a/src/features/ark.js +++ b/src/features/ark.js @@ -2258,8 +2258,12 @@ export function arkFeature(ctx) { }; // The server prices a renewal by how much lifetime each coin still // carries (its ppm bracket) — waiting IS cheaper, and inside the final - // bracket it's free, where the wallet renews on its own anyway. + // bracket the share is zero, where the wallet renews on its own anyway. + // A flat base fee (the round's on-chain cost, which coinos stopped + // absorbing in October 2026) rides on top of every bracket. const table = (((mgr && mgr.info) || {}).refreshFees || {}).ppmExpiryTable || []; + const baseSat = (((mgr && mgr.info) || {}).refreshFees || {}).baseFeeSat || 0; + const baseCost = fmtSats(baseSat) + ' sats'; const roundMins = Math.max(1, Math.round((((mgr && mgr.info) || {}).roundIntervalSecs || 120) / 60)); const roundEvery = roundMins === 1 ? t('arkCoinsRoundEveryOne') : t('arkCoinsRoundEvery', { n: roundMins }); const ppmFor = (blocks) => (table.filter((e) => e.thresholdBlocks <= blocks).pop()?.ppm) ?? 0; @@ -2286,8 +2290,9 @@ export function arkFeature(ctx) { : i === 0 ? t('arkCoinsSchedOver', { span: span(e.thresholdBlocks) }) : t('arkCoinsSchedBetween', { a: span(e.thresholdBlocks), b: span(arr[i - 1].thresholdBlocks) }), - cost: e.ppm === 0 ? t('arkDepthFree') : (e.ppm / 10000).toLocaleString(undefined, { maximumFractionDigits: 3 }) + '%', - free: e.ppm === 0, + cost: e.ppm === 0 ? (baseSat ? baseCost : t('arkDepthFree')) + : (e.ppm / 10000).toLocaleString(undefined, { maximumFractionDigits: 3 }) + '%' + (baseSat ? ' + ' + baseCost : ''), + free: e.ppm === 0 && !baseSat, })); // Which coins ride the renewal: all by default (the one-button behavior), // any subset by unticking. Selection is per-visit; ids that vanished @@ -2450,7 +2455,9 @@ export function arkFeature(ctx) { h('h4', { style: 'margin:0' }, t('arkCoinsRenewTitle')), // the round cadence comes from the server (it has been an hour and // is two minutes as of September 2026) — never a number baked in here - h('p', { class: 'small muted', style: 'margin:0' }, t('arkCoinsRenewDesc', { every: roundEvery })), + h('p', { class: 'small muted', style: 'margin:0' }, baseSat + ? t('arkCoinsRenewDescBase', { every: roundEvery, base: baseCost }) + : t('arkCoinsRenewDesc', { every: roundEvery })), schedule.length ? h('div', { class: 'col', style: 'gap:2px;margin:2px 0' }, ...schedule.map((r) => h('div', { class: 'row between' }, h('span', { class: 'small muted' }, r.label), diff --git a/src/i18n.js b/src/i18n.js index 61a97dd..d0a069e 100644 --- a/src/i18n.js +++ b/src/i18n.js @@ -605,6 +605,7 @@ const STR = { arkCoinsExitDesc: 'If the server vanished today, publishing every transaction in each coin’s history would cost about {fee} sats in mining fees. After a renewal it would be one fresh coin, one hop: about {after} sats.', arkCoinsRenewTitle: 'Renewal', arkCoinsRenewDesc: 'Your wallet renews coins automatically once they are close to expiring and renewal is free. Renewing early is an option if you would rather pay a small fee now to keep your exit cost low should the coinos server ever stop responding when you want to bring your funds on-chain. A renewal replaces your coins with a single fresh one in the next round ({every}), which flattens their history. The fee depends on how close the coin is to expiry. The closer, the cheaper:', + arkCoinsRenewDescBase: 'Your wallet renews coins automatically once they are close to expiring, when renewal is cheapest. Renewing early is an option if you would rather pay a little more now to keep your exit cost low should the coinos server ever stop responding when you want to bring your funds on-chain. A renewal replaces your coins with a single fresh one in the next round ({every}), which flattens their history. Every renewal costs a flat {base} toward the round’s on-chain fee, plus a share that depends on how close the coin is to expiry. The closer, the cheaper:', arkCoinsRoundEvery: 'rounds run every {n} minutes', arkCoinsRoundEveryOne: 'rounds run every minute', arkCoinsRenewNowFee: 'Renew now for {fee}', |
