From b9f8ec30e6681c623162bb36e44df16934740b32 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sat, 19 Sep 2026 22:36:55 -0700 Subject: Zaps: the sound can be switched off — from the held bolt or Settings → Nostr. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A prefs flag (zapSound, absent = on) synced with the zap amount. The strike and the tally are unchanged; only the clip stays quiet, and the clip chunk is not even fetched while it's off. Co-Authored-By: Claude Fable 5.1 --- src/features/zaps.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/features/zaps.js') diff --git a/src/features/zaps.js b/src/features/zaps.js index 54c8f58..d6b2271 100644 --- a/src/features/zaps.js +++ b/src/features/zaps.js @@ -476,7 +476,11 @@ export function zapsFeature(ctx) { style: 'text-align:right', onInput: (e) => { const n = parseInt(e.target.value, 10); if (n > 0) ctx.setZapDefaultSat(n); } }), h('span', { class: 'small muted', style: 'align-self:center;padding:0 6px' }, 'sats'))), - h('div', { class: 'small faint' }, t('zapDefaultHint')))]; + h('div', { class: 'small faint' }, t('zapDefaultHint')), + ctx.setZapSound ? h('label', { class: 'row gap6', style: 'align-items:center;cursor:pointer;margin-top:4px' }, + h('input', { type: 'checkbox', checked: ctx.zapSound(), style: 'width:18px;height:18px;accent-color:var(--accent);margin:0', + onChange: (e) => { ctx.setZapSound(e.target.checked); } }), + h('span', { class: 'small' }, t('zapSoundToggle'))) : null)]; }, }; } -- cgit v1.2.3