From 3e29acaa238c0ad9bf6bcc370899b4bdb84be836 Mon Sep 17 00:00:00 2001 From: prosolis <5590409+prosolis@users.noreply.github.com> Date: Tue, 26 May 2026 23:03:23 -0700 Subject: [PATCH] Fix feed settings panel failing to open MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit btoa() throws InvalidCharacterError on non-Latin1 input, so feed names with em-dashes ("The Guardian — World") killed render() before the dialog's hidden class was removed and nothing visibly happened on click. Use the loop index for the row id instead. --- internal/web/static/js/settings.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/web/static/js/settings.js b/internal/web/static/js/settings.js index ab46b84..5ccaf6a 100644 --- a/internal/web/static/js/settings.js +++ b/internal/web/static/js/settings.js @@ -69,7 +69,7 @@ list.innerHTML = '

No feeds configured.

'; } else { var lastChannel = null; - sources.forEach(function (src) { + sources.forEach(function (src, i) { if (src.channel !== lastChannel) { lastChannel = src.channel; var hdr = document.createElement("div"); @@ -77,7 +77,7 @@ hdr.textContent = src.channel || "other"; list.appendChild(hdr); } - var id = "pete-feed-" + btoa(src.name).replace(/=/g, ""); + var id = "pete-feed-" + i; var row = document.createElement("label"); row.setAttribute("for", id); row.className = "flex items-center justify-between gap-3 rounded-2xl px-3 py-2 hover:bg-[color:var(--ink)]/5 cursor-pointer";