Skip to content

Commit ee8259b

Browse files
Amos N.claude
andcommitted
Fix syntax error in web client modal subtitles
`\'` inside a TS template literal collapses to `'` at compile time, so two strings like '<p>...you\'ll...</p>' served as JS were ending the single-quoted string at the apostrophe, leaving `ll recognise...` as raw tokens. Browser console: "Uncaught SyntaxError: Unexpected identifier 'll'" at the first occurrence (line 1154 of the served HTML). That hard-failed the entire script, which is why the pair-URL popup never appeared. Rephrase the two affected strings to drop the apostrophe rather than double-escape — escapes are easy to regress on the next edit. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 1f49d20 commit ee8259b

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "loopsy",
3-
"version": "1.0.30",
3+
"version": "1.0.31",
44
"private": true,
55
"description": "Control your terminal from your phone. Self-hosted on Cloudflare Workers.",
66
"scripts": {

packages/relay/src/web-client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1138,7 +1138,7 @@ export const WEB_CLIENT_HTML = /* html */ `<!doctype html>
11381138
card.className = 'modal-card';
11391139
card.innerHTML = '<div class="modal-icon"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/><path d="M18.5 2.5a2.12 2.12 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5Z"/></svg></div>'
11401140
+ '<h2 class="modal-title">' + title + '</h2>'
1141-
+ '<p class="modal-subtitle">Pick a name you\'ll recognise on the home list.</p>';
1141+
+ '<p class="modal-subtitle">Pick a name to spot it on the home list.</p>';
11421142
const inp = document.createElement('input');
11431143
inp.className = 'modal-input'; inp.type = 'text';
11441144
inp.placeholder = 'e.g. fix logging bug';
@@ -1513,7 +1513,7 @@ export const WEB_CLIENT_HTML = /* html */ `<!doctype html>
15131513
card.className = 'modal-card';
15141514
card.innerHTML = '<div class="modal-icon"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="11" width="18" height="11" rx="2"/><path d="M7 11V7a5 5 0 0 1 10 0v4"/></svg></div>'
15151515
+ '<h2 class="modal-title">Enable auto-approve</h2>'
1516-
+ '<p class="modal-subtitle">Auto-approve runs ' + agent + ' with permission prompts skipped. Enter your laptop\'s macOS password. You\'ll only be asked once per pairing.</p>';
1516+
+ '<p class="modal-subtitle">Auto-approve runs ' + agent + ' with permission prompts skipped. Enter the macOS password for your laptop. Asked once per pairing.</p>';
15171517
15181518
const pwWrap = document.createElement('div');
15191519
pwWrap.className = 'pw-wrap';

0 commit comments

Comments
 (0)