From 1e0ee7eb3b892f6eaa826b5554e93aa40655d95f Mon Sep 17 00:00:00 2001 From: Mark Boas Date: Tue, 4 Aug 2026 17:27:44 +0200 Subject: [PATCH 1/2] Copy to clipboard: stop replacing apostrophes with backticks setupPopover sanitised the selection with replaceAll("'", "`") before putting it on the clipboard. That escaping is inherited from js/share-this-clipboard.js, where it is required because the text is interpolated into an inline onclick handler; here the text only ever reaches clipboard.writeText() and textContent, both of which take arbitrary strings. The substitution has no purpose in this path and corrupts every quotation containing an apostrophe. --- js/hyperaudio-lite.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/hyperaudio-lite.js b/js/hyperaudio-lite.js index c86b2a3..1de7199 100644 --- a/js/hyperaudio-lite.js +++ b/js/hyperaudio-lite.js @@ -478,7 +478,7 @@ class HyperaudioLite { const popover = document.getElementById('popover'); if (selection.toString().length > 0) { - this.selectionText = selection.toString().replaceAll("'", "`"); + this.selectionText = selection.toString(); const range = selection.getRangeAt(0); const rect = range.getBoundingClientRect(); From 13861c66ebf8b57e11cc7bd35557a0b436fc1a44 Mon Sep 17 00:00:00 2001 From: Mark Boas Date: Tue, 4 Aug 2026 17:35:36 +0200 Subject: [PATCH 2/2] Regenerate the ESM twin (npm run build) --- js/hyperaudio-lite.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/hyperaudio-lite.mjs b/js/hyperaudio-lite.mjs index 82f9f7c..8540d6f 100644 --- a/js/hyperaudio-lite.mjs +++ b/js/hyperaudio-lite.mjs @@ -478,7 +478,7 @@ class HyperaudioLite { const popover = document.getElementById('popover'); if (selection.toString().length > 0) { - this.selectionText = selection.toString().replaceAll("'", "`"); + this.selectionText = selection.toString(); const range = selection.getRangeAt(0); const rect = range.getBoundingClientRect();