[object Object]

← back to Rentv

polish(services): trade chips — specialty trades lead, General buckets trail muted

47c3761d97849cb14e1e3b7afa8bc9ce100056ad · 2026-08-06 17:35:54 -0700 · Steve

Cody #3: General Building (~91% of contractors) was swamping the trade-filter row and
defeating its purpose. Now the specialty trades (Electrical/Plumbing/HVAC/Roofing/etc.)
lead; General Building + General Engineering trail with a muted dashed style. Client-only, $0.

Files touched

Diff

commit 47c3761d97849cb14e1e3b7afa8bc9ce100056ad
Author: Steve <steve@designerwallcoverings.com>
Date:   Thu Aug 6 17:35:54 2026 -0700

    polish(services): trade chips — specialty trades lead, General buckets trail muted
    
    Cody #3: General Building (~91% of contractors) was swamping the trade-filter row and
    defeating its purpose. Now the specialty trades (Electrical/Plumbing/HVAC/Roofing/etc.)
    lead; General Building + General Engineering trail with a muted dashed style. Client-only, $0.
---
 public/services.html | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/public/services.html b/public/services.html
index a21f66ff..bd2c2628 100644
--- a/public/services.html
+++ b/public/services.html
@@ -60,6 +60,8 @@
   .chip{font:700 12px 'Inter';border:1px solid var(--line);background:#fff;border-radius:20px;padding:5px 11px;cursor:pointer;color:var(--sub);white-space:nowrap}
   .chip:hover{border-color:var(--red);color:var(--red)}
   .chip.on{background:var(--red);border-color:var(--red);color:#fff}
+  .chip.gen{background:var(--wash);color:#8a9199;border-style:dashed}
+  .chip.gen.on{background:var(--red);border-color:var(--red);color:#fff;border-style:solid}
 
   .ctlbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:12px 2px 2px;flex-wrap:wrap}
   .meta{color:var(--sub);font-size:12.5px;font-weight:600;min-height:18px}
@@ -326,9 +328,13 @@ async function loadTrades(){
 function renderTrades(){
   if(cat!=='construction'||!TRADES.length){ $('tchips').style.display='none'; $('tchips').innerHTML=''; return; }
   $('tchips').style.display='flex';
+  // Specialty trades (what a deal team narrows TO) lead; the broad General buckets trail, muted —
+  // otherwise General Building (~91% of contractors) swamps the row and defeats the filter (Cody #3).
+  const GENERAL=new Set(['general-building','general-engineering']);
+  const spec=TRADES.filter(t=>!GENERAL.has(t.key)), gen=TRADES.filter(t=>GENERAL.has(t.key));
+  const chip=(t,cls)=>`<button class="chip${cls||''}${trade===t.key?' on':''}" data-trade="${esc(t.key)}">${esc(t.label)} <span style="opacity:.55">${t.count.toLocaleString()}</span></button>`;
   const all=`<button class="chip${trade?'':' on'}" data-trade="">All trades</button>`;
-  const chips=TRADES.map(t=>`<button class="chip${trade===t.key?' on':''}" data-trade="${esc(t.key)}">${esc(t.label)} <span style="opacity:.6">${t.count.toLocaleString()}</span></button>`).join('');
-  $('tchips').innerHTML=all+chips;
+  $('tchips').innerHTML=all+spec.map(t=>chip(t)).join('')+gen.map(t=>chip(t,' gen')).join('');
   document.querySelectorAll('#tchips .chip').forEach(b=>b.onclick=()=>{ trade=b.dataset.trade; offset=0; renderTrades(); sync(); load(true); });
 }
 function syncTrades(){ if(cat==='construction'){ if(TRADES.length)renderTrades(); else loadTrades(); } else { $('tchips').style.display='none'; } }

← 47cb4fdb feat(services): contractor trade filter (CSLB class) for Con  ·  back to Rentv  ·  auto-data-snapshot: 2026-08-06T17:35:56 (7 data files) — dat f2f651fd →