← back to Wallco Ai
PDP gallery: drop inline onerror (broke inside server template literal — \' collapsed to '' → JS parse error → empty gallery); clean /designs/room src + dark bg placeholder
25bdcd2529045fb648d9fb1caf92c2381c51a8d9 · 2026-05-29 22:52:37 -0700 · Steve Abrams
Files touched
Diff
commit 25bdcd2529045fb648d9fb1caf92c2381c51a8d9
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Fri May 29 22:52:37 2026 -0700
PDP gallery: drop inline onerror (broke inside server template literal — \' collapsed to '' → JS parse error → empty gallery); clean /designs/room src + dark bg placeholder
---
server.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server.js b/server.js
index b4f61d0..e77653a 100644
--- a/server.js
+++ b/server.js
@@ -17551,7 +17551,7 @@ ${FOOTER}
: '';
return '<figure style="margin:0;background:var(--paper,#faf8f2);border:1px solid var(--rule,#e5e5e0);position:relative;' + dim + '">' +
'<a href="/designs/room/design_' + r.design_id + '_' + r.room_type + '.png" target="_blank" style="display:block;aspect-ratio:1/1;overflow:hidden;background:#000;" rel="noopener noreferrer">' +
- '<img src="/designs/room/design_' + r.design_id + '_' + r.room_type + '.png" onerror="this.onerror=null;this.src=\'' + r.image_path + '\'" alt="Room with this pattern — ' + tag + '" loading="lazy" style="width:100%;height:100%;object-fit:cover;display:block;" />' +
+ '<img src="/designs/room/design_' + r.design_id + '_' + r.room_type + '.png" alt="Room with this pattern — ' + tag + '" loading="lazy" style="width:100%;height:100%;object-fit:cover;display:block;background:#1a1816;" />' +
'</a>' +
adminCtrls +
'<figcaption style="padding:8px 10px 10px;font:11px/1.4 ui-sans-serif,system-ui,sans-serif;color:var(--ink-faint,#6e6e68);display:flex;justify-content:space-between;gap:8px;">' +
← be7e221 PDP Generated-rooms gallery: tile src uses /designs/room/des
·
back to Wallco Ai
·
/api/rooms: for non-admin, dedup by room_type + drop rooms w df69588 →