Find the savings hiding in your stack.
\nPick the check that fits your role. Answer a few quick questions and get your score, your biggest opportunities, and a clear next step \u2014 no guesswork.
\n/* ============================================================ NICKLPASS ASSESSMENTS — hosted app (single file) Upload to Webflow Assets as: nicklpass-assessments.js.txt Set your Web3Forms key in WEB3FORMS_ACCESS_KEY below. Each page:
(subpages only) ============================================================ */ (function(){ var NP_MARKUP = "\nPick the check that fits your role. Answer a few quick questions and get your score, your biggest opportunities, and a clear next step \u2014 no guesswork.
\nWe use your details only to send occasional insights and to talk about your stack. No spam \u2014 opt out anytime.
\nEvery answer earns points by how much risk or waste it signals: A = 0, B = 2, C = 4, D = 5. With 20 questions, the maximum is 100. A higher score means more recoverable spend and more risk sitting in your stack.
\nNote: figures are drawn from the published benchmark reports above, not a live scrape \u2014 confirm against the latest editions before publishing. Use the score to prioritize, then let Nicklpass measure your real numbers.
\n${m.tag}
Start the check → 20 questions · ~5 min`; c.onclick=function(){ if(npHosted()) npGoMagnet(m.id); else openMagnet(i); }; grid.appendChild(c); }); /* ================= NAV ================= */ (function(){ var el=$('homeLink'); if(el) el.onclick=function(){ if(npHosted()) window.location.href=NP_BASE; else goHome(); }; })(); (function(){ var el=$('fback'); if(el) el.onclick=function(){ if(window.NICKLPASS_MAGNET && npHosted()) window.location.href=NP_BASE; else goHome(); }; })(); function goHome(){ var f=$('funnel'); if(f) f.classList.remove('active'); var l=$('landing'); if(l) l.style.display=''; window.scrollTo({top:0,behavior:'smooth'}); } function showStage(s){ ['pw','quiz','result'].forEach(function(x){ var el=$(x); if(el) el.classList.toggle('hidden',x!==s); }); window.scrollTo({top:0,behavior:'smooth'}); } /* Startup diagnostic — prints the name of anything Webflow failed to render */ (function(){ var ids=['homeLink','fback','landing','lmGrid','funnel','pw','quiz','result','pwStart','pwEmail','pwCat','pwTitle','qOpts','scoreVal']; var missing=ids.filter(function(id){ return !$(id); }); if(missing.length) console.warn('[Nicklpass] These elements are missing from the page (check the HTML Embed paste): '+missing.join(', ')); else console.log('[Nicklpass] All elements present — ready.'); })(); /* ================= AUTO-OPEN FROM PAGE CONFIG ================= Subpages set: window.NICKLPASS_MAGNET = "procurement"; (slug or id) When absent (the /assessments landing page), the full grid shows. */ function npAutoOpen(){ if(!window.NICKLPASS_MAGNET) return; var id = SLUG2ID[window.NICKLPASS_MAGNET] || window.NICKLPASS_MAGNET; var i = M.findIndex(function(x){ return x.id===id; }); if(i>=0) openMagnet(i); else console.warn('[Nicklpass] Unknown NICKLPASS_MAGNET value: "'+window.NICKLPASS_MAGNET+'"'); } /* ================= OPEN MAGNET (paywall first) ================= */ function openMagnet(i){ cur=M[i]; idx=0; answers=[]; flat=[]; cur.sections.forEach(sec=>sec.q.forEach(q=>flat.push({sec:sec.t,q:q.q,o:q.o}))); var _l=$('landing'); if(_l) _l.style.display='none'; var _f=$('funnel'); if(_f) _f.classList.add('active'); document.getElementById('pwCat').textContent=cur.cat; document.getElementById('pwTitle').textContent=cur.title; document.getElementById('pwTag').textContent=cur.tag; document.getElementById('pwCtxLabel').textContent=cur.ctx.label+" (optional)"; const ctx=document.getElementById('pwCtx'); ctx.value=''; ctx.placeholder=cur.ctx.ph; document.getElementById('pwEmail').value=''; document.getElementById('pwName').value=''; document.getElementById('pwCompany').value=''; document.getElementById('pwErr').style.display='none'; document.getElementById('pwResearch').innerHTML='Built from: '+cur.research.join(' · '); showStage('pw'); } /* ================= PAYWALL SUBMIT ================= */ (function(){ var _b=$('pwStart'); if(_b) _b.onclick=()=>{ const email=document.getElementById('pwEmail').value.trim(); const ok=/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(email); const err=document.getElementById('pwErr'); if(!ok){err.style.display='block';return;} err.style.display='none'; captureLead(email); idx=0; answers=[]; renderQ(); showStage('quiz'); }; })(); function captureLead(email){ leadInfo={ assessment:cur.title, category:cur.cat, email:email, name:document.getElementById('pwName').value.trim(), company:document.getElementById('pwCompany').value.trim(), ctxLabel:cur.ctx.label, ctxValue:document.getElementById('pwCtx').value.trim() }; // EMAIL 1 — a new lead just unlocked an assessment var p={}; p.subject="New assessment lead: "+cur.title; p["Lead type"]="Unlocked assessment"; p["Assessment"]=cur.title; p["Category"]=cur.cat; p["Name"]=leadInfo.name||"(not provided)"; p["Email"]=email; p["Company"]=leadInfo.company||"(not provided)"; p[cur.ctx.label]=leadInfo.ctxValue||"(not provided)"; p["Time"]=new Date().toLocaleString(); sendMail(p); } /* ================= QUESTIONS ================= */ function renderQ(){ const item=flat[idx], total=flat.length; document.getElementById('progFill').style.width=(idx/total*100)+'%'; document.getElementById('progLeft').textContent=`Question ${idx+1} of ${total}`; document.getElementById('progRight').textContent=item.sec; document.getElementById('sectLabel').textContent=item.sec; document.getElementById('qText').textContent=item.q; const wrap=document.getElementById('qOpts'); wrap.innerHTML=''; const letters=['A','B','C','D']; item.o.forEach((opt,i)=>{ const b=document.createElement('button'); b.className='opt'; b.innerHTML=`${letters[i]}${opt}`; b.onclick=()=>pick(i); wrap.appendChild(b); }); } function pick(optIdx){ answers[idx]={optIdx:optIdx, pts:PTS[optIdx]}; if(idx