From 14bc273d98e4d74f23cc50f0e787093560aba459 Mon Sep 17 00:00:00 2001 From: mplorentz Date: Thu, 27 Aug 2026 15:01:13 -0400 Subject: [PATCH 1/3] update digest footer --- src/emails/digest.mjml | 8 +++----- src/mailer.ts | 1 + 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/emails/digest.mjml b/src/emails/digest.mjml index 53f08cc..5d6525d 100644 --- a/src/emails/digest.mjml +++ b/src/emails/digest.mjml @@ -19,6 +19,7 @@ .event-stats { margin-top: 8px; color: #64748b; font-size: 13px; } .stat-item { display: inline-flex; align-items: center; margin-right: 12px; } .footer { font-family: Inter, Helvetica, Arial, sans-serif; color: #94a3b8; font-size: 12px; line-height: 1.5; } + .footer a { color: #7161FF; text-decoration: underline; } .logo { max-width: 48px; max-height: 48px; } a { text-decoration: none; } @@ -57,7 +58,7 @@ at {{Timestamp}}
{{{Content}}}
@@ -81,11 +82,8 @@ You're receiving this email because you subscribed to {{brandName}} notifications. - We'll send you updates based on your subscription preferences. + You can manage your subscriptions here or unsubscribe. - - Unsubscribe - diff --git a/src/mailer.ts b/src/mailer.ts index 55889a8..a67b24d 100644 --- a/src/mailer.ts +++ b/src/mailer.ts @@ -86,6 +86,7 @@ export const sendDigest = async (sub: Subscription, variables: Record { From cf335649c03da8f355747140a2b92e7334bbffa8 Mon Sep 17 00:00:00 2001 From: mplorentz Date: Thu, 27 Aug 2026 15:18:52 -0400 Subject: [PATCH 2/3] Wait longer for profile photoes. --- src/digest.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/digest.ts b/src/digest.ts index d18c515..334a2c8 100644 --- a/src/digest.ts +++ b/src/digest.ts @@ -104,6 +104,7 @@ export class Digest { for (const pk of pubkeys) { try { await loadProfile(pk) + await waitForProfile(pk) } catch { // pass } @@ -175,4 +176,18 @@ const getFormatter = () => { timeStyle: 'short', timeZone: 'UTC', }) +} + +// Poll until the profile lands in the repository or hits a timeout. The load +// promise can resolve before sharedLoad writes the event to the store, so only +// the profile's presence here guarantees its avatar/name. +const waitForProfile = async (pubkey: string, timeoutMs = 5000) => { + const deadline = Date.now() + timeoutMs + + while (Date.now() < deadline) { + if (profilesByPubkey.get().get(pubkey)) { + return + } + await new Promise(r => setTimeout(r, 200)) + } } \ No newline at end of file From 3a0aff2f30466e5750f47f4f0f5a6d72ac79392b Mon Sep 17 00:00:00 2001 From: mplorentz Date: Thu, 27 Aug 2026 15:23:18 -0400 Subject: [PATCH 3/3] Update confirmation page --- script/render-preview.mjs | 1 + src/pages/confirm-success.html | 54 +++++++++++++++++++++++++--------- 2 files changed, 41 insertions(+), 14 deletions(-) diff --git a/script/render-preview.mjs b/script/render-preview.mjs index 1e88abc..c74d6ea 100644 --- a/script/render-preview.mjs +++ b/script/render-preview.mjs @@ -39,6 +39,7 @@ const sample = { }, ], unsubscribeUrl: 'https://app.flotilla.social/unsubscribe?token=abc123', + settingsUrl: 'https://app.flotilla.social/settings/alerts', } const source = readFileSync(templatePath, 'utf8') diff --git a/src/pages/confirm-success.html b/src/pages/confirm-success.html index ce4c7e2..844237e 100644 --- a/src/pages/confirm-success.html +++ b/src/pages/confirm-success.html @@ -1,36 +1,62 @@ - Confirmation Successful + + + Email Confirmed
-

Email Alert Confirmed

-
- Your alert has been successfully confirmed. You will now receive notifications. -
+ {{#brandLogo}}{{/brandLogo}} +
{{brandName}}
+

Email confirmed

+

+ Your email has been successfully confirmed. You will start receiving notifications shortly. + Visit {{brandName}} to manage your notification settings. +

- + \ No newline at end of file