From eca472c893fd128fa863b5d92835b6d9e71b445f Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 19 Oct 2026 12:21:40 -0700 Subject: Add timestamp comments, reactions and zaps with audio waveform seeking --- src/lnurl.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/lnurl.js') diff --git a/src/lnurl.js b/src/lnurl.js index 7b1a798..592d143 100644 --- a/src/lnurl.js +++ b/src/lnurl.js @@ -1,3 +1,4 @@ +import { momentTags } from './media-timeline.js'; // LNURL-pay + NIP-57 ("lightning zap") logic — no DOM, so it stays testable. // // The wallet already pays bolt11 invoices over a Boltz submarine swap; this @@ -123,13 +124,14 @@ export async function fetchPayParams(url) { } // A signed kind-9734 zap request (NIP-57). signFn(partial) → finalized event. -export function buildZapRequest({ amountMsat, relays, lnurlBech32, recipientPk, eventId, comment, signFn }) { +export function buildZapRequest({ amountMsat, relays, lnurlBech32, recipientPk, eventId, comment, signFn, moment }) { const tags = [['relays', ...relays], ['amount', String(amountMsat)], ['p', recipientPk]]; if (lnurlBech32) tags.push(['lnurl', lnurlBech32]); if (eventId) tags.push(['e', eventId]); // a live stream's address too, so its chat and zap.stream count the zap const addr = zapAddrOf(eventId); if (addr) tags.push(['a', addr]); + tags.push(...momentTags(moment)); return signFn({ kind: 9734, content: comment || '', tags }); } -- cgit v1.2.3