← back to 1970swallpaper
Revert "rails: tag-aware via shared rail-match helper + editorial LABELS (rescue flat grid)"
0d007e47a04487987016bd6f0f5d410ac83b0936 · 2026-05-26 10:48:51 -0700 · SteveStudio2
This reverts commit 0955fdc905be37d92d4d2a460e88acec785cb633.
Files touched
M package-lock.jsonM public/index.htmlM server.jsM site.config.json
Diff
commit 0d007e47a04487987016bd6f0f5d410ac83b0936
Author: SteveStudio2 <steve@designerwallcoverings.com>
Date: Tue May 26 10:48:51 2026 -0700
Revert "rails: tag-aware via shared rail-match helper + editorial LABELS (rescue flat grid)"
This reverts commit 0955fdc905be37d92d4d2a460e88acec785cb633.
---
package-lock.json | 13 -------------
public/index.html | 2 +-
server.js | 11 ++++++++---
site.config.json | 10 +++++-----
4 files changed, 14 insertions(+), 22 deletions(-)
diff --git a/package-lock.json b/package-lock.json
index 781a4e9..78d8151 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -8,7 +8,6 @@
"name": "the-1970s-wallpaper",
"version": "0.1.0",
"dependencies": {
- "dotenv": "^17.4.2",
"express": "^4.21.0",
"helmet": "^8.1.0"
}
@@ -173,18 +172,6 @@
"npm": "1.2.8000 || >= 1.4.16"
}
},
- "node_modules/dotenv": {
- "version": "17.4.2",
- "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-17.4.2.tgz",
- "integrity": "sha512-nI4U3TottKAcAD9LLud4Cb7b2QztQMUEfHbvhTH09bqXTxnSie8WnjPALV/WMCrJZ6UV/qHJ6L03OqO3LcdYZw==",
- "license": "BSD-2-Clause",
- "engines": {
- "node": ">=12"
- },
- "funding": {
- "url": "https://dotenvx.com"
- }
- },
"node_modules/dunder-proto": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz",
diff --git a/public/index.html b/public/index.html
index 6a5e7da..f582ea8 100644
--- a/public/index.html
+++ b/public/index.html
@@ -509,7 +509,7 @@ const TOUCH = window.matchMedia('(hover: none)').matches;
document.documentElement.dataset.view = state.view;
} catch(e){}
})();
-const LABELS = {"all":"All","geometric":"Geometric & Op-Art","burnt orange":"Burnt Orange & Harvest Tones","retro":"Retro Classics","mid-century modern":"Mid-Century Modern","botanical":"Botanical & Organic","avocado":"Avocado Green"};
+const LABELS = {"all":"All","geometric":"Geometric & Op-Art"};
function escAttr(s) { return String(s == null ? '' : s).replace(/[&<>"']/g, c => ({ '&':'&','<':'<','>':'>','"':'"',"'":''' }[c])); }
// Image-URL allowlist: only DW Shopify CDN + designerwallcoverings.com (defends against XSS via crafted products.json)
diff --git a/server.js b/server.js
index 81fb289..de9a210 100644
--- a/server.js
+++ b/server.js
@@ -21,7 +21,6 @@ if (ADMIN_ENABLED) {
try { catalog = require('../_shared/admin-catalog'); }
catch (e) { console.error(`[${__SITE}] admin-catalog unavailable (${e.message}) — falling back to static JSON`); }
}
-const { buildRails, railFacets } = require('../_shared/rail-match');
const siteCfg = JSON.parse(fs.readFileSync(path.join(__dirname, 'site.config.json'), 'utf8'));
const SITE_SLUG = siteCfg.slug || __SITE;
const SITE_RAILS = Array.isArray(siteCfg.rails) ? siteCfg.rails : [];
@@ -186,13 +185,19 @@ app.get('/api/products', (req, res) => {
});
app.get('/api/sliders', (req, res) => {
- res.json({ rails: buildRails(PRODUCTS_NICHE, SITE_RAILS) });
+ const out = [];
+ for (const a of SITE_RAILS) {
+ const items = PRODUCTS_NICHE.filter(p => p.aesthetic === a).slice(0, 12);
+ if (items.length >= 4) out.push({ aesthetic: a, items });
+ }
+ res.json({ rails: out });
});
app.get('/api/facets', (req, res) => {
- const aesthetics = railFacets(PRODUCTS_NICHE, SITE_RAILS);
+ const aesthetics = {};
const vendors = {};
for (const p of PRODUCTS_NICHE) {
+ aesthetics[p.aesthetic] = (aesthetics[p.aesthetic] || 0) + 1;
vendors[p.vendor] = (vendors[p.vendor] || 0) + 1;
}
res.json({ aesthetics, vendors, total: PRODUCTS_NICHE.length });
diff --git a/site.config.json b/site.config.json
index b7e4571..2ddaafa 100644
--- a/site.config.json
+++ b/site.config.json
@@ -10,11 +10,11 @@
"accent": "#d4a047"
},
"rails": [
+ "earth-tone",
+ "disco",
+ "flower-power",
"geometric",
- "burnt orange",
- "retro",
- "mid-century modern",
- "botanical",
- "avocado"
+ "organic",
+ "novelty"
]
}
← 0955fdc rails: tag-aware via shared rail-match helper + editorial LA
·
back to 1970swallpaper
·
sku-redact: wire shared vendor-id display scrubber ed8167b →