Private AI meeting notes that stay on your computer. No meeting bot. Free and open source for Mac, Windows and Linux. An alternative to Granola, Otter and Fireflies.
TypeScript ai-meeting-assistantai-notetakerelectrongranola-alternativelinuxllama-cpplocal-ailocal-firstmacosmcpmeeting-minutesmeeting-notesoffline-firstopen-sourceprivacyspeech-to-texttranscriptionwhisperwhisper-cppwindows
Site: the hero gets curved wings, a gradient headline, a steadier entry, crisper window edges and quieter step numbers
Eric Brownrout68194575a089
diff --git a/site/content/home.html b/site/content/home.htmlindex d31ae9c3..e64e2b28 100644--- a/site/content/home.html+++ b/site/content/home.html@@ -12,7 +12,7 @@}}})();-</script><link href="/marketing/site.css" rel="stylesheet"/><meta content="Yogurt" property="og:site_name"/><meta content="website" property="og:type"/><meta content="https://yogurt.so/" property="og:url"/><meta content="Yogurt · AI meeting notes that stay on your computer" property="og:title"/><meta content="Yogurt takes meeting notes with AI that runs locally on Mac, Windows and Linux. No bot joins the call. Free and open source." property="og:description"/><meta content="https://yogurt.so/marketing/assets/og-image.png" property="og:image"/><meta content="1200" property="og:image:width"/><meta content="630" property="og:image:height"/><meta content="Yogurt logo, Private AI meeting notes, and the app’s meeting summary." property="og:image:alt"/><meta content="summary_large_image" name="twitter:card"/><meta content="Yogurt · AI meeting notes that stay on your computer" name="twitter:title"/><meta content="Yogurt takes meeting notes with AI that runs locally on Mac, Windows and Linux. No bot joins the call. Free and open source." name="twitter:description"/><meta content="https://yogurt.so/marketing/assets/og-image.png" name="twitter:image"/><meta content="Yogurt logo, Private AI meeting notes, and the app’s meeting summary." name="twitter:image:alt"/><script>window.va=window.va||function(){(window.vaq=window.vaq||[]).push(arguments)};</script><script defer src="/_vercel/insights/script.js"></script></head>+</script><link href="/marketing/site.css" rel="stylesheet"/><link href="/marketing/headline.css" rel="stylesheet"/><meta content="Yogurt" property="og:site_name"/><meta content="website" property="og:type"/><meta content="https://yogurt.so/" property="og:url"/><meta content="Yogurt · AI meeting notes that stay on your computer" property="og:title"/><meta content="Yogurt takes meeting notes with AI that runs locally on Mac, Windows and Linux. No bot joins the call. Free and open source." property="og:description"/><meta content="https://yogurt.so/marketing/assets/og-image.png" property="og:image"/><meta content="1200" property="og:image:width"/><meta content="630" property="og:image:height"/><meta content="Yogurt logo, Private AI meeting notes, and the app’s meeting summary." property="og:image:alt"/><meta content="summary_large_image" name="twitter:card"/><meta content="Yogurt · AI meeting notes that stay on your computer" name="twitter:title"/><meta content="Yogurt takes meeting notes with AI that runs locally on Mac, Windows and Linux. No bot joins the call. Free and open source." name="twitter:description"/><meta content="https://yogurt.so/marketing/assets/og-image.png" name="twitter:image"/><meta content="Yogurt logo, Private AI meeting notes, and the app’s meeting summary." name="twitter:image:alt"/><script>window.va=window.va||function(){(window.vaq=window.vaq||[]).push(arguments)};</script><script defer src="/_vercel/insights/script.js"></script></head><body id="top" tabindex="-1" data-background="ribbon" data-demo="transcript" data-letter="plain" data-motion="flow" data-source="sample"><a class="skip" href="#main">Skip to content</a><header class="site-header"><a aria-label="Yogurt home" class="wordmark" href="#main"><img alt="yogurt" height="30" src="/marketing/assets/wordmark.svg" width="108"/></a><nav aria-label="Main navigation"><button class="theme-toggle" type="button" aria-label="Switch to dark mode" aria-pressed="false" hidden><svg class="theme-moon" aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.7" stroke-linecap="round" stroke-linejoin="round"><path d="M20.9 13A9 9 0 0 1 11 3.1 9 9 0 1 0 20.9 13Z"/></svg><svg class="theme-sun" aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.7" stroke-linecap="round"><circle cx="12" cy="12" r="4"/><path d="M12 2v2m0 16v2M2 12h2m16 0h2M4.9 4.9l1.4 1.4m11.4 11.4 1.4 1.4M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4"/></svg></button><a href="#how-it-works">How it works</a><a href="#privacy">Privacy</a><a href="https://github.com/FrigadeHQ/yogurt" rel="noopener noreferrer" target="_blank">GitHub <span aria-hidden="true">↗</span></a><a data-download class="button secondary nav-download" href="https://github.com/FrigadeHQ/yogurt/releases/latest/download/Yogurt-mac-arm64.dmg">Download</a></nav></header><main id="main" tabindex="-1"><section aria-labelledby="headline" class="hero"><div class="hero-copy"><span aria-label="Frigade, the team behind Yogurt, is backed by Y Combinator" class="yc-pill" role="img"><span aria-hidden="true" class="yc-mark"><svg viewBox="0 0 10 12" fill="none"><path d="M2 2 5 6.5 8 2M5 6.5V10" stroke="currentColor" stroke-width="1.5" stroke-linecap="square"/></svg></span>Backed by Y Combinator</span><h1 aria-label="Take note." id="headline"><span aria-hidden="true" class="headline-visual">Take <span class="headline-word plain-word">note.</span></span></h1><p><span>Private AI meeting notes.</span> <span>Free and open source.</span> <span class="hero-wrap">Because your business should never be anyone else’s.</span></p><div class="hero-actions"><a class="button primary" href="https://github.com/FrigadeHQ/yogurt/releases/latest/download/Yogurt-mac-arm64.dmg" data-download id="download"><svg aria-hidden="true" fill="currentColor" viewbox="0 0 24 24"><path d="M17.1 12.3c0-2.6 2.2-3.9 2.3-4-1.3-1.9-3.2-2.1-3.9-2.1-1.7-.2-3.3 1-4.2 1-.9 0-2.2-1-3.6-.9-1.9 0-3.6 1.1-4.6 2.7-2 3.4-.5 8.4 1.4 11.1.9 1.3 2 2.7 3.4 2.6 1.3 0 1.9-.8 3.5-.8s2.1.8 3.5.8c1.5 0 2.4-1.3 3.3-2.6 1.1-1.5 1.5-3 1.5-3.1-.1 0-2.6-1-2.6-3.7ZM14.4 4.5c.8-1 1.4-2.3 1.2-3.5-1.2.1-2.6.8-3.4 1.7-.7.8-1.4 2.2-1.2 3.4 1.3.1 2.6-.7 3.4-1.6Z"></path></svg><span data-download-label>Download for Mac</span></a><a data-stars-button class="button secondary" href="https://github.com/FrigadeHQ/yogurt" aria-label="View Yogurt on GitHub, 825 stars" rel="noopener" target="_blank"><span class="stars-label"><span aria-hidden="true">★</span> <span class="stars-count" data-star-count="825">825</span> on GitHub</span></a><span class="download-requirements"><span class="download-alternatives">Also for <a aria-label="Download for Windows" href="https://github.com/FrigadeHQ/yogurt/releases/latest/download/Yogurt-windows-x64.exe">Windows</a> and <a aria-label="Download for Linux" href="https://github.com/FrigadeHQ/yogurt/releases/latest/download/Yogurt-linux-x86_64.AppImage">Linux</a></span></span></div></div>diff --git a/site/package.json b/site/package.jsonindex 620070fd..eaf06f41 100644--- a/site/package.json+++ b/site/package.json@@ -9,7 +9,7 @@"site:bundle": "node scripts/bundle.mjs","site:stars": "node scripts/stars-snapshot.mjs","site:stills": "node scripts/stills.mjs",- "test": "node renderer/timeline.test.mjs && node scripts/theme.test.mjs && node scripts/stars.test.mjs"+ "test": "node renderer/timeline.test.mjs && node scripts/ribbon-geometry.test.mjs && node scripts/hero-entry.test.mjs && node scripts/headline.test.mjs && node scripts/theme.test.mjs && node scripts/stars.test.mjs"},"dependencies": {"next": "16.4.1",diff --git a/site/public/marketing/headline.css b/site/public/marketing/headline.cssnew file mode 100644index 00000000..801a428c--- /dev/null+++ b/site/public/marketing/headline.css@@ -0,0 +1,34 @@+/* Saturated purple in both themes; the action sweep preserves white text contrast. */+:root{+ --ai-base:#6F00FF;+ --ai-highlight:#8B5CF6;+ --ai-action-highlight:color-mix(in srgb,var(--ai-base) 20%,var(--ai-highlight));+ --ai-text-base:var(--ai-base);+ --download-gradient-strength:1;+}+:root[data-theme=dark]{+ --ai-text-base:color-mix(in srgb,var(--ai-base) 40%,var(--ai-highlight));+}+:root[data-theme] .hero h1 .headline-word{color:var(--ai-text-base)}+@supports (background-clip:text){+ :root[data-theme] .hero h1 .headline-word{+ /* Paint glyph overhang without changing the headline's spacing. */+ padding-inline:.1em;margin-inline:-.1em;+ background-image:linear-gradient(110deg in srgb,var(--ai-text-base),var(--ai-action-highlight) 50%,var(--ai-text-base));+ background-size:200% 100%;background-position:0% 50%;background-repeat:no-repeat;+ background-clip:text;-webkit-background-clip:text;-webkit-text-fill-color:transparent;+ }+}+.hero-actions .button.primary{+ /* 0 is flat brand purple; 1 is the full contrast-safe sweep. */+ --download-highlight:color-mix(in srgb,var(--ai-base) calc(100% - 80% * var(--download-gradient-strength)),var(--ai-highlight));+ background-color:var(--ai-base);+ background-image:linear-gradient(110deg in srgb,var(--ai-base),var(--download-highlight) 50%,var(--ai-base));+ background-size:200% 100%;background-position:0% 50%;background-repeat:no-repeat;+}+@media(hover:hover) and (pointer:fine){+ .hero-actions .button.primary:hover{background:var(--purple-dark)}+}+@media(forced-colors:active){+ :root[data-theme] .hero h1 .headline-word{background:none;-webkit-text-fill-color:currentColor;color:CanvasText!important}+}diff --git a/site/public/marketing/hero-entry.mjs b/site/public/marketing/hero-entry.mjsindex 7c4cd3d1..5464a52e 100644--- a/site/public/marketing/hero-entry.mjs+++ b/site/public/marketing/hero-entry.mjs@@ -1,26 +1,45 @@+import {ribbonGeometry,ribbonPath} from './ribbon-geometry.mjs';const reduceMotion=matchMedia('(prefers-reduced-motion: reduce)');const state=document.documentElement.dataset;+if(new URLSearchParams(location.search).get('static')==='1')state.heroStatic='true';const animations=[],restore=[];let completed=false,frame;--// The outer endpoints travel along their original rays. The vanishing point,-// stripe angles and spacing never transform. p=1 restores the exact source d.-export function growPath(original,p){- if(p>=1) return original;- const points=original.match(/-?\d*\.?\d+/g).map(Number);- const outer=y=>`${800*(1-p)} ${325+(y-325)*p}`;- return original.endsWith('Z')?`M${outer(points[1])} 800 325 ${outer(points[5])}Z`:`M${outer(points[1])} 800 325`;+const svg=document.querySelector('.signal-wings'),product=document.querySelector('.product-window');+const geometry=[...svg.querySelectorAll('defs path')].map(path=>({path,d:path.getAttribute('d'),progress:1}));+const mirrors=[...svg.querySelectorAll('use[transform]')],materials=[];+let shape,coveredLength;+function paintRibbons(){+ geometry.forEach(({path,d,progress})=>path.setAttribute('d',ribbonPath(d,shape,progress)));}+function layoutRibbons(){+ const windowBounds=product.getBoundingClientRect(),ribbonBounds=svg.getBoundingClientRect();+ shape=ribbonGeometry(ribbonBounds.width,windowBounds.width);+ svg.setAttribute('viewBox',`0 0 ${shape.width} ${shape.height}`);+ mirrors.forEach(use=>use.setAttribute('transform',`translate(${shape.width} 0) scale(-1 1)`));+ const gradient=svg.querySelector('#ribbon-purple');+ gradient.setAttribute('x2',shape.width/2);gradient.setAttribute('y2',shape.height/2);+ svg.querySelector('.signal-reflection').setAttribute('height',shape.height);+ materials.forEach(({material,ys})=>{+ material.setAttribute('y1',Math.min(...ys)*shape.height/650);+ material.setAttribute('y2',Math.max(...ys)*shape.height/650);+ });+ // Start inside the opaque window, including when a resize changes the curve during entry.+ coveredLength=Math.max(0,Math.min(1,(windowBounds.width-4)/ribbonBounds.width,(windowBounds.height-4)/ribbonBounds.height));+ paintRibbons();+}+const resize=new ResizeObserver(layoutRibbons);+resize.observe(svg);resize.observe(product);layoutRibbons();function complete(){if(completed) return;completed=true;cancelAnimationFrame(frame);restore.forEach(reset=>reset());+ geometry.forEach(part=>part.progress=1);materials.length=0;paintRibbons();state.ribbonPaint='ready';state.heroEntry='complete';window.dispatchEvent(new Event('hero-entry-complete'));}-if(reduceMotion.matches) complete();+if(reduceMotion.matches||state.heroStatic==='true') complete();else{state.heroEntry='running';const copyEase='cubic-bezier(.23,1,.32,1)';@@ -29,7 +48,6 @@ else{{opacity:0,transform:'translateY(12px)'},{opacity:1,transform:'translateY(0)'},],{duration:500,delay,easing:copyEase,fill:'backwards'}));}- const product=document.querySelector('.product-window');const desktop=matchMedia('(min-width:761px)');if(desktop.matches && product.dataset.live!=='true') {await new Promise(resolve=>{@@ -40,39 +58,37 @@ else{}if(reduceMotion.matches) complete();else {- const windowDelay=Math.max(0,270-Number(animations[0].currentTime||0));- // The live app is already dark and mounted; reveal only the whole window.- animations.push(product.animate([{opacity:0,transform:'translateY(20px)'},{opacity:1,transform:'translateY(0)'}],+ const windowDelay=Math.max(0,270-Number(animations[0].currentTime||0)),fadeDuration=300;+ // The window becomes opaque before it settles, hiding the wings' starting points.+ animations.push(product.animate([{opacity:0},{opacity:1}],+ {duration:fadeDuration,delay:windowDelay,easing:'cubic-bezier(.16,1,.3,1)',fill:'backwards'}));+ animations.push(product.animate([{transform:'translateY(20px)'},{transform:'translateY(0)'}],{duration:600,delay:windowDelay,easing:'cubic-bezier(.16,1,.3,1)',fill:'backwards'}));const background='ribbon';if(background==='ribbon'){- const svg=document.querySelector('.signal-wings');const surface=svg.querySelector('#ribbon-surface');- const windowBounds=document.querySelector('.product-window').getBoundingClientRect();- const ribbonBounds=svg.getBoundingClientRect();- // Start 2px inside the opaque window, not at the distant vanishing point.- // Both width and height coverage matter at narrow responsive sizes.- const coveredLength=Math.max(0,Math.min(1,(windowBounds.width-4)/ribbonBounds.width,(windowBounds.height-4)/ribbonBounds.height));- const ribbonStart=windowDelay+600,bandDuration=350,bandStagger=55;+ const ribbonStart=windowDelay+fadeDuration,bandDuration=350,bandStagger=55;const bands=[...svg.querySelectorAll('[data-ribbon-band]')].map((band,index)=>{const paths=[...band.querySelectorAll('path')];const seam=svg.querySelector(`#ribbon-seam-${index+1}`);if(seam) paths.push(seam);- const geometry=paths.map(path=>({path,d:path.getAttribute('d')}));+ const bandGeometry=geometry.filter(part=>paths.includes(part.path));// Keep the original material in fixed SVG coordinates as the path grows.// Object-bounding-box gradients would otherwise travel with the end cap.const material=surface.cloneNode(true),paint=paths[1];const ys=[index*130,(index+1)*130,325];material.id=`ribbon-entry-surface-${index}`;material.setAttribute('gradientUnits','userSpaceOnUse');- material.setAttribute('y1',Math.min(...ys));- material.setAttribute('y2',Math.max(...ys));+ material.setAttribute('y1',Math.min(...ys)*shape.height/650);+ material.setAttribute('y2',Math.max(...ys)*shape.height/650);+ materials.push({material,ys});surface.after(material);paint.setAttribute('fill',`url(#${material.id})`);- restore.push(()=>{geometry.forEach(({path,d})=>path.setAttribute('d',d));paint.setAttribute('fill','url(#ribbon-surface)');material.remove()});- geometry.forEach(({path,d})=>path.setAttribute('d',growPath(d,coveredLength)));- return geometry;+ restore.push(()=>{paint.setAttribute('fill','url(#ribbon-surface)');material.remove()});+ bandGeometry.forEach(part=>part.progress=coveredLength);+ return bandGeometry;});+ paintRibbons();// A seekable clock drives d attributes, not a transform or clipping wipe.// It starts only after the live window has painted.const clock=svg.animate([],{duration:ribbonStart+4*bandStagger+bandDuration,fill:'backwards'});@@ -84,8 +100,9 @@ else{const progress=Math.max(0,Math.min(1,(time-ribbonStart-index*bandStagger)/bandDuration));// A short ease-out carries the visible end cap to the page edge.const length=coveredLength+(1-coveredLength)*(1-(1-progress)**3);- geometry.forEach(({path,d})=>path.setAttribute('d',growPath(d,length)));+ geometry.forEach(part=>part.progress=length);});+ paintRibbons();if(!completed) frame=requestAnimationFrame(draw);}frame=requestAnimationFrame(draw);diff --git a/site/public/marketing/hero-transcript.mjs b/site/public/marketing/hero-transcript.mjsindex 5ab9276c..83987a76 100644--- a/site/public/marketing/hero-transcript.mjs+++ b/site/public/marketing/hero-transcript.mjs@@ -1,7 +1,7 @@import {onVoiceFrame} from './clock.mjs';const demo=document.querySelector('#product-demo'),reduce=matchMedia('(prefers-reduced-motion: reduce)'),desktop=matchMedia('(min-width:761px)');let cycleDuration=Infinity;-let frame,ready=false,visible=false,started=false,startPhase,lastSent=-1,last={phase:0,bands:[0,0,0]},override;+let frame,ready=false,visible=false,started=false,startPhase,lastSent=-1,last={phase:0,bands:[0,0,0]},override=new URLSearchParams(location.search).get('static')==='1'?8:undefined;const eligible=()=>desktop.matches&&!reduce.matches;const send=data=>frame?.contentWindow?.postMessage(data,location.origin);function render(value){@@ -39,6 +39,6 @@ function mode(){}reduce.addEventListener('change',mode);desktop.addEventListener('change',mode);document.addEventListener('visibilitychange',()=>render(last));-// Deterministic browser export drives the same fixture, without a production query switch.+// Deterministic browser export can seek the same fixture independently of the static preview.window.addEventListener('hero-capture',event=>{if(Number.isFinite(event.detail)){override=event.detail;render(last)}});onVoiceFrame(render);load();diff --git a/site/public/marketing/ribbon-geometry.mjs b/site/public/marketing/ribbon-geometry.mjsnew file mode 100644index 00000000..f71b11af--- /dev/null+++ b/site/public/marketing/ribbon-geometry.mjs@@ -0,0 +1,33 @@+export function ribbonGeometry(width,appWidth){+ const curved=width>1728+ return {curved,width:curved?width:1600,height:curved?1728*.4256:650,+ gap:(width-appWidth)/2,baselineGap:(1728-appWidth)/2,+ attachment:appWidth/Math.min(width,1728),covered:appWidth/width}+}++const mix=(a,b,t)=>a.map((value,i)=>value+(b[i]-value)*t)++export function ribbonPath(original,g,progress=1){+ if(!g.curved&&progress>=1)return original+ const points=original.match(/-?\d*\.?\d+/g).map(Number)+ if(!g.curved){+ const outer=y=>`${800*(1-progress)} ${325+(y-325)*progress}`+ return original.endsWith('Z')?`M${outer(points[1])} 800 325 ${outer(points[5])}Z`:`M${outer(points[1])} 800 325`+ }+ // Keep the remaining part of the exact cubic, so the edge grows without changing shape.+ const t=Math.max(0,Math.min(1,(1-progress)/(1-g.covered)))+ const edge=value=>{+ const y=value/650*g.height,anchor=g.height/2+(y-g.height/2)*g.attachment+ const p0=[0,y],p1=[g.gap*.55,y],p2=[g.gap-g.baselineGap*.5,anchor-(anchor-y)*.5],p3=[g.gap,anchor]+ const a=mix(p0,p1,t),b=mix(p1,p2,t),c=mix(p2,p3,t)+ const d=mix(a,b,t),e=mix(b,c,t)+ return [mix(d,e,t),e,c,p3]+ }+ const top=edge(points[1]),point=p=>p.join(' ')+ let path=`M${point(top[0])} C${top.slice(1).map(point).join(' ')} L${g.width/2} ${g.height/2}`+ if(original.endsWith('Z')){+ const bottom=edge(points[5])+ path+=` L${point(bottom[3])} C${bottom.slice(0,3).reverse().map(point).join(' ')}Z`+ }+ return path+}diff --git a/site/public/marketing/ribbons.mjs b/site/public/marketing/ribbons.mjsindex 234db348..db580bc1 100644--- a/site/public/marketing/ribbons.mjs+++ b/site/public/marketing/ribbons.mjs@@ -8,21 +8,21 @@ function animate(element,frames,name){animation.id='ribbon-life-'+name;animation.pause();animations.push(animation);}function start(){- const palettes=[- ['#ribbon-purple stop:nth-child(1)','color-mix(in srgb,var(--ribbon-warm) 75%,white)','color-mix(in srgb,var(--ribbon-cool) 75%,white)'],- ['#ribbon-purple stop:nth-child(2)','var(--ribbon-warm)','var(--ribbon-cool)'],- ['#ribbon-purple stop:nth-child(3)','color-mix(in srgb,var(--brand-soft) 72%,var(--ribbon-warm))','color-mix(in srgb,var(--brand-soft) 72%,var(--ribbon-cool))'],- ['#ribbon-surface stop:last-child','color-mix(in srgb,var(--brand-deep) 80%,var(--ribbon-warm))','color-mix(in srgb,var(--brand-deep) 80%,var(--ribbon-cool))'],- ['#ribbon-glint stop:nth-child(2)','color-mix(in srgb,var(--brand-tint) 92%,var(--ribbon-warm))','color-mix(in srgb,var(--brand-tint) 92%,var(--ribbon-cool))'],+ const base='var(--ai-base)',highlight='var(--ai-highlight)';+ const sweeps=[+ [base,base,highlight,base,base],+ [base,highlight,base,highlight,base],+ [highlight,base,base,base,highlight],];- palettes.forEach(([selector,warm,cool],index)=>{- const stop=svg.querySelector(selector),base=getComputedStyle(stop).stopColor;- animate(stop,[base,warm,base,cool,base].map(stopColor=>({stopColor})),'color-'+index);- });+ sweeps.forEach((colors,index)=>animate(svg.querySelector(`#ribbon-purple stop:nth-child(${index+1})`),colors.map(stopColor=>({stopColor})),'color-'+index));+ const drift=[0,50,100,50,0].map(position=>({backgroundPosition:`${position}% 50%`}));+ const headline=document.querySelector('.headline-word');+ if(headline&&CSS.supports('background-clip','text'))animate(headline,drift,'headline');+ document.querySelectorAll('.hero-actions .button.primary').forEach((button,index)=>animate(button,drift,'download-'+index));animate(svg.parentElement,['0px','var(--ribbon-sway)','0px','calc(-1 * var(--ribbon-sway))','0px'].map(y=>({transform:`translateY(${y})`})),'sway');}function sync(){- if(document.documentElement.dataset.heroEntry!=='complete')return;+ if(document.documentElement.dataset.heroEntry!=='complete'||document.documentElement.dataset.heroStatic==='true')return;if(!animations.length&&!reduce.matches)start();const running=visible&&!document.hidden&&!reduce.matches;svg.dataset.running=String(running);diff --git a/site/public/marketing/site.css b/site/public/marketing/site.cssindex 91ee30f4..03c05be0 100644--- a/site/public/marketing/site.css+++ b/site/public/marketing/site.css@@ -664,7 +664,7 @@ body[data-letter=plain] .plain-word{display:inline}.answer-word{font-size:47px}}@media (prefers-reduced-motion:reduce){.step[data-active=true] .process-art *{animation:none!important}.roster-person small,.person-orb,.person-signal>*{transition:none}}-[id^=ribbon-entry-surface-] stop:last-child{stop-color:var(--brand-deep)}+[id^=ribbon-entry-surface-] stop:last-child{stop-color:var(--ai-base)}.signal-wings{visibility:hidden}html[data-ribbon-paint=ready] .signal-wings{visibility:visible}html[data-hero-entry=pending] :is(.yc-pill,.hero-copy h1,.hero-copy p,.hero-actions,.product-window){visibility:hidden}@@ -800,13 +800,13 @@ body[data-demo=transcript] .demo-transcript-control>[data-demo-icon=wave]{displa@media (max-width:360px){.listen-art{padding-inline:17px}.transcript-turn p{font-size:12px}}@media (prefers-reduced-motion:reduce){.process-art *,.roster-asset *{transition:none!important;animation:none!important}}-#ribbon-purple stop:nth-child(1){stop-color:color-mix(in srgb,var(--brand) 75%,white)}-#ribbon-purple stop:nth-child(2){stop-color:var(--brand)}-#ribbon-purple stop:nth-child(3){stop-color:var(--brand-soft)}-#ribbon-surface stop:last-child{stop-color:var(--brand-deep)}-#ribbon-glint stop:nth-child(2){stop-color:var(--brand-tint)}-[data-ribbon-band] path[stroke]{stroke:var(--brand-rim)}-#wing>path[stroke]{stroke:var(--brand-tint)}+#ribbon-purple stop:nth-child(1),#ribbon-purple stop:nth-child(2){stop-color:var(--ai-base)}+#ribbon-purple stop:nth-child(3){stop-color:var(--ai-highlight)}+#ribbon-surface stop,[id^=ribbon-entry-surface-] stop{stop-color:var(--ai-highlight)}+#ribbon-surface stop:last-child{stop-color:var(--ai-base)}+#ribbon-glint stop{stop-color:var(--ai-highlight)}+[data-ribbon-band] path[stroke]{stroke:var(--ai-highlight)}+#wing>path[stroke]{stroke:var(--ai-highlight)}.file-peek{border-color:#E6E6E8;border-radius:10px;background:linear-gradient(145deg,#FFFFFF,#F6F6F6 70%,#E6E6E8);box-shadow:inset 0 1px 0 #fff,0 2px 3px #17171A0c,0 9px 18px -9px #17171A24;padding:14px 12px}.file-peek>svg{display:inline-block;vertical-align:middle;padding:4px;width:23px;height:23px;border-radius:6px;background:#F3F3F3;color:#606066;box-shadow:inset 0 1px 0 #fff;border:1px solid #E6E6E8;stroke-width:1.7}.file-peek>span{display:inline-block;margin:0 0 0 5px;vertical-align:middle;font-size:10px;font-weight:550;color:#54545A;letter-spacing:-.15px}@@ -825,8 +825,10 @@ body[data-demo=transcript] .demo-transcript-control>[data-demo-icon=wave]{displa.file-peek>span{font-size:9px;margin-left:3px}.file-excerpt{font-size:10px}}@media (min-width:761px){body[data-background=ribbon] .hero-copy{padding-bottom:82px}}-.product-stage>.backdrop.ribbon{top:50%;height:calc(100% + 60px);translate:0 -50%}-@media (max-width:760px){.product-stage>.backdrop.ribbon{height:100%}}+/* Explicit width keeps the mirror at the page edge while height caps at the 1728px composition. */+.product-stage>.backdrop.ribbon{top:50%;width:100%;height:auto;aspect-ratio:1000/425.6;max-height:735.4368px;translate:0 -50%}+@media (max-width:760px){.product-stage>.backdrop.ribbon{height:100%;aspect-ratio:auto;max-height:none}}+html[data-hero-static=true] .signal-reflection{animation:none}.person-orb.orb-a,.person-orb.orb-b{background:linear-gradient(145deg,#FFFFFF,#ECECEE);border-color:#E6E6E8;color:#606066;box-shadow:inset 0 1px 0 #fff,0 2px 3px #17171A0a}.person-orb.you-orb{background:linear-gradient(145deg,color-mix(in srgb,var(--brand) 83%,white),var(--brand-dark));border-color:var(--brand-dark);color:white;box-shadow:inset 0 1px 0 #ffffff45,0 2px 3px #29202c14}.person-orb{font-size:14px;font-weight:560;letter-spacing:-.35px}@@ -1018,9 +1020,6 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au--brand:var(--purple-base);--violet:var(--purple-base);--brand-dark:var(--purple-dark);--brand-deep:var(--purple-deep);--brand-soft:var(--purple-soft);--brand-tint:var(--purple-tint);--brand-line:var(--purple-line);--brand-rim:var(--purple-rim);--face-start:var(--purple-base);--face-mid:color-mix(in srgb,var(--purple-base) 55%,var(--purple-dark));--face-end:var(--purple-dark);--field-end:var(--purple-dark);}-/* Preserve the rendered ribbon paint exactly, including its existing tint and alpha. */-.signal-wings{--brand:#6F00FF;--brand-dark:#6200e0;--brand-deep:#5300bf;--brand-soft:#b47aff;--brand-tint:#f3ebff;--brand-rim:#c599ff}-@@ -1086,8 +1085,8 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au.hero-actions>.download-requirements{position:absolute;top:calc(100% + 12px);left:50%;transform:translateX(-50%);width:max-content;max-width:calc(100vw - 32px);text-align:center}.site-footer .download-requirements{display:flex;flex-wrap:wrap;align-items:baseline;gap:0;margin-top:8px;font-size:11px;line-height:18px;color:#fff;opacity:.9}-/* The material drifts within violet; its static grain is baked once, not filtered per frame. */-.signal-wings{overflow:visible;--ribbon-warm:color-mix(in srgb,var(--brand) 70%,#ec45bc);--ribbon-cool:color-mix(in srgb,var(--brand) 65%,#3153ff)}+/* Static grain is baked once, not filtered per frame. */+.signal-wings{overflow:visible}.signal-reflection{animation:none}.backdrop.ribbon{--ribbon-sway:6px}@@ -1123,7 +1122,7 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au.hero-copy{padding-top:40px}.hero h1{margin-bottom:24px}.hero-actions{margin-top:28px}-@media(min-width:761px){body[data-background=ribbon] .hero-copy{padding-bottom:70px}}+body[data-background=ribbon] .hero-copy{padding-bottom:70px}@media(max-width:760px){.yc-pill{margin-bottom:28px}.hero-copy{padding-top:32px}.hero h1{margin-bottom:20px}.hero-actions{margin-top:24px}}.hero-copy p>span{white-space:nowrap}@@ -1145,7 +1144,7 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au/* Short laptop viewports keep the live transcript in the first screen. */@media(min-width:761px) and (max-height:820px){- body[data-background=ribbon] .hero-copy{padding-top:20px;padding-bottom:46px}+ body[data-background=ribbon] .hero-copy{padding-top:20px}}/* Only the liquid surface moves; the number and reserved circle box stay fixed. */@@ -1171,6 +1170,13 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au/* App palette; light rules and the violet brand surfaces remain unchanged. */:root[data-theme=dark]{color-scheme:dark;--bg:#1B1B1D;--float:#29292B;--ink:#E7E6EB;--muted:#A7A4AD;--line:#343436;--accent:#B780FF;--surface:#202021;--paper:var(--ink);--border:var(--line)}:root[data-theme=dark] body{background:var(--bg)}+/* Defined window edges; the app's own materials stay untouched. */+:root[data-theme=dark] .product-stage>.product-window.demo-window{border-color:rgb(255 255 255 / 14%)}+:root[data-theme=dark] .product-stage>.product-window.demo-window::after{+ content:"";position:absolute;inset:0;z-index:2;border-radius:inherit;pointer-events:none;+ box-shadow:inset 0 1px 0 rgb(255 255 255 / 12%);+}+:root[data-theme=light] .product-stage>.product-window.demo-window{border:1px solid #5A5A5E}:root[data-theme=dark] ::selection{background:#7040AF;color:#fff}:root[data-theme=dark] :is(a,button,summary):focus-visible{outline-color:var(--accent)}:root[data-theme=dark] .faq-list details:has(summary:focus-visible){outline-color:var(--accent)}@@ -1181,7 +1187,7 @@ body[data-demo=transcript] .hero-listening-widget{top:-52px;right:22px;bottom:au:root[data-theme=dark] .button.secondary{background:var(--float);border-color:var(--line);color:var(--ink);box-shadow:0 1px 2px #0003}:root[data-theme=dark] .button.secondary:is(:hover,:active){background:#333335;border-color:#606066;color:var(--ink)}:root[data-theme=dark] .skip{color:#fff}-:root[data-theme=dark] .step-outline{fill:var(--float);stroke:var(--muted)}+:root[data-theme=dark] .step-outline{fill:var(--float);stroke:var(--line)}:root[data-theme=dark] .step-digit{fill:var(--muted)}:root[data-theme=dark] :is(.roster-sheet,.file-peek){background:var(--float);border-color:var(--line);box-shadow:0 12px 24px -12px #0006}:root[data-theme=dark] :is(.roster-top b,.file-peek>svg,.person-orb.orb-a,.person-orb.orb-b){background:#333335;color:var(--ink);border-color:var(--line);box-shadow:none}diff --git a/site/scripts/headline.test.mjs b/site/scripts/headline.test.mjsnew file mode 100644index 00000000..21ec7be8--- /dev/null+++ b/site/scripts/headline.test.mjs@@ -0,0 +1,70 @@+import assert from 'node:assert/strict'+import {readFileSync} from 'node:fs'+import vm from 'node:vm'++const script=readFileSync(new URL('../public/marketing/ribbons.mjs',import.meta.url),'utf8')+for(const mode of ['normal','reduced','static','unsupported']){+ const animations=[],listeners={},media={matches:mode==='reduced',addEventListener:(_type,fn)=>listeners.motion=fn}+ let tick+ const node=name=>({name,dataset:{},animate(frames,options){+ const animation={name,frames,options,currentTime:0,pause(){this.paused=true},play(){this.paused=false}}+ animations.push(animation);return animation+ }})+ const headline=node('headline'),button=node('download'),svg={...node('svg'),parentElement:node('sway'),querySelector:node}+ const document={documentElement:{dataset:{heroEntry:'complete',heroStatic:mode==='static'?'true':undefined}},hidden:false,+ querySelector:selector=>selector==='.signal-wings'?svg:headline,querySelectorAll:()=>[button],addEventListener:(_type,fn)=>listeners.visibility=fn}+ vm.runInNewContext(script,{+ document,window:{addEventListener(){}},matchMedia:()=>media,CSS:{supports:()=>mode!=='unsupported'},+ IntersectionObserver:class{constructor(callback){this.callback=callback}observe(){this.callback([{isIntersecting:true}])}},+ setInterval:fn=>{tick=fn;return 1},clearInterval:()=>{tick=undefined},+ })+ if(mode==='static'||mode==='reduced'){assert.equal(animations.length,0);continue}+ const text=animations.find(animation=>animation.name==='headline'),download=animations.find(animation=>animation.name==='download'),sway=animations.at(-1)+ if(mode==='unsupported')assert.equal(text,undefined)+ for(const animation of [download,text].filter(Boolean)){+ assert.equal(animation.options.duration,24000)+ assert.equal(animation.options.iterations,Infinity)+ assert.deepEqual(Array.from(animation.frames,frame=>frame.backgroundPosition),['0% 50%','50% 50%','100% 50%','50% 50%','0% 50%'])+ }+ const stops=animations.slice(0,3)+ assert(stops.every(animation=>animation.frames.every(frame=>['var(--ai-base)','var(--ai-highlight)'].includes(frame.stopColor))))+ assert.deepEqual([0,1,2,3,4].map(phase=>stops.findIndex(animation=>animation.frames[phase].stopColor==='var(--ai-highlight)')),[2,1,0,1,2])+ sway.currentTime=6000;tick();assert(animations.every(animation=>animation.currentTime===6000))+ document.hidden=true;listeners.visibility();assert(sway.paused);assert.equal(tick,undefined)+ document.hidden=false;listeners.visibility();assert(!sway.paused)+ media.matches=true;listeners.motion();assert(animations.every(animation=>animation.currentTime===0));assert(sway.paused)+}++const css=readFileSync(new URL('../public/marketing/headline.css',import.meta.url),'utf8')+const html=readFileSync(new URL('../content/home.html',import.meta.url),'utf8')+assert(html.includes('href="/marketing/headline.css"'))+assert(css.includes('--ai-base:#6F00FF'))+assert(css.includes('--ai-highlight:#8B5CF6'))+assert.equal((css.match(/--ai-highlight:/g)||[]).length,1,'both themes share the saturated highlight')+assert(css.includes('--download-gradient-strength:1'))+assert(css.includes('calc(100% - 80% * var(--download-gradient-strength))'))+assert(css.includes('--ai-action-highlight:color-mix(in srgb,var(--ai-base) 20%,var(--ai-highlight))'))+assert(css.includes('--ai-text-base:color-mix(in srgb,var(--ai-base) 40%,var(--ai-highlight))'))+assert.equal((css.match(/linear-gradient\(110deg in srgb/g)||[]).length,2)+assert(css.includes('.hero-actions .button.primary:hover{background:var(--purple-dark)}'))+const rgb=hex=>hex.match(/[\da-f]{2}/gi).map(value=>parseInt(value,16))+const mix=(a,b,p)=>a.map((value,i)=>value*p+b[i]*(1-p))+const luminance=channels=>channels.map(value=>value/255).map(value=>value<=.04045?value/12.92:((value+.055)/1.055)**2.4).reduce((sum,value,i)=>sum+value*[.2126,.7152,.0722][i],0)+const base=rgb('6F00FF'),white=rgb('FFFFFF')+const contrast=(a,b)=>(Math.max(luminance(a),luminance(b))+.05)/(Math.min(luminance(a),luminance(b))+.05)+for(const theme of ['light','dark']){+ const highlight=rgb('8B5CF6')+ const textBase=theme==='light'?base:mix(base,highlight,.4),bg=theme==='light'?white:rgb('1B1B1D')+ let buttonMinimum=Infinity,textMinimum=Infinity+ for(let strength=0;strength<=100;strength++)for(let position=0;position<=100;position++){+ const peak=mix(base,highlight,1-.8*strength/100)+ if(strength===0)assert.deepEqual(peak,base)+ buttonMinimum=Math.min(buttonMinimum,contrast(white,mix(base,peak,position/100)))+ textMinimum=Math.min(textMinimum,contrast(bg,mix(textBase,mix(base,highlight,.2),position/100)))+ }+ assert(buttonMinimum>=4.5,'white button text meets contrast across the full sweep and strength range')+ assert(textMinimum>=3,'headline meets large-text contrast across the full sweep')+ console.log(`${theme}: button minimum ${buttonMinimum.toFixed(2)}:1; headline minimum ${textMinimum.toFixed(2)}:1`)+}+assert(contrast(white,rgb('6200E0'))>=4.5,'unchanged hover remains readable')+console.log('Headline and download share the ribbon clock and palette; strength, static/reduced motion and hidden-page pause passed.')diff --git a/site/scripts/hero-entry.test.mjs b/site/scripts/hero-entry.test.mjsnew file mode 100644index 00000000..71705297--- /dev/null+++ b/site/scripts/hero-entry.test.mjs@@ -0,0 +1,97 @@+import assert from 'node:assert/strict'+import {readFileSync} from 'node:fs'+import vm from 'node:vm'+import {ribbonGeometry,ribbonPath} from '../public/marketing/ribbon-geometry.mjs'++const entry=readFileSync(new URL('../public/marketing/hero-entry.mjs',import.meta.url),'utf8').replace(/^import .*\n/,'')+const ribbons=readFileSync(new URL('../public/marketing/ribbons.mjs',import.meta.url),'utf8')+for(const width of [1280,1728,2560])for(const [search,reduced] of [['?static=1',false],['?static=1',true],['?static=0',true],['',true]]){+ const dataset={heroEntry:'pending'},events=[]+ let viewport=width,onResize+ const node=attributes=>({attributes,getAttribute(name){return this.attributes[name]},setAttribute(name,value){this.attributes[name]=value}})+ const path=node({d:'M0 0 800 325 0 130Z'}),mirror=node({}),gradient=node({}),reflection=node({})+ const product={getBoundingClientRect:()=>({width:Math.min(viewport*.76,1200),height:Math.min(viewport*.76,1200)*.608})}+ const svg={...node({}),getBoundingClientRect:()=>({width:viewport,height:Math.min(viewport,1728)*.4256}),+ querySelectorAll:selector=>selector==='defs path'?[path]:[mirror],querySelector:selector=>selector==='#ribbon-purple'?gradient:reflection}+ const context=vm.createContext({+ URLSearchParams,Event,location:{search},ribbonGeometry,ribbonPath,+ matchMedia:()=>({matches:reduced,addEventListener(){}}),+ document:{documentElement:{dataset},querySelector:selector=>selector==='.signal-wings'?svg:product},+ window:{dispatchEvent:event=>events.push(event.type)},cancelAnimationFrame(){},+ ResizeObserver:class{constructor(callback){onResize=callback}observe(){}},+ })+ await vm.runInContext(`(async()=>{${entry}})()`,context)+ assert.equal(dataset.heroEntry,'complete')+ assert.equal(dataset.ribbonPaint,'ready')+ assert.equal(dataset.heroStatic,search==='?static=1'?'true':undefined)+ assert.deepEqual(events,['hero-entry-complete'])+ for(viewport of [2560,1728,1280]){+ onResize()+ const g=ribbonGeometry(viewport,Math.min(viewport*.76,1200))+ assert.equal(path.attributes.d,ribbonPath('M0 0 800 325 0 130Z',g))+ assert.equal(svg.attributes.viewBox,`0 0 ${g.width} ${g.height}`)+ assert.equal(mirror.attributes.transform,`translate(${g.width} 0) scale(-1 1)`)+ }+}++// Static captures must not restart the decorative motion after entry completes.+vm.runInNewContext(ribbons,{+ document:{documentElement:{dataset:{heroEntry:'complete',heroStatic:'true'}},querySelector:()=>({}),addEventListener(){}},+ matchMedia:()=>({matches:false,addEventListener(){}}),+ window:{addEventListener(){}},+ IntersectionObserver:class{constructor(callback){callback([{isIntersecting:true}])}observe(){}},+})+console.log('Static preview and reduced motion settle entry without starting ribbon animations.')++// Exercise the real entry clock and cleanup without a browser or native app.+for(const width of [1280,1728,2560]){+ const dataset={heroEntry:'pending'},animations=[],listeners=[],events=[],materials=[]+ let draw,onResize,viewport=width+ const node=attributes=>({attributes,getAttribute(name){return this.attributes[name]},setAttribute(name,value){this.attributes[name]=value},+ after(){},remove(){this.removed=true},cloneNode(){const copy=node({...this.attributes});materials.push(copy);return copy},+ animate(frames,options){let finish;const animation={frames,currentTime:0,options,finished:new Promise(resolve=>finish=resolve),finish:()=>finish(),cancel(){}};animations.push(animation);return animation}})+ const bands=Array.from({length:5},(_,i)=>{+ const d=`M0 ${i*130} 800 325 0 ${(i+1)*130}Z`+ const paths=[node({d}),node({d,fill:'url(#ribbon-surface)'})]+ return {paths,querySelectorAll:()=>paths}+ })+ const seams=Array.from({length:4},(_,i)=>node({d:`M0 ${(i+1)*130} 800 325`}))+ const paths=[...bands.flatMap(band=>band.paths),...seams],originals=paths.map(path=>path.attributes.d)+ const product={...node({}),dataset:{live:'true'},getBoundingClientRect:()=>({width:Math.min(viewport*.76,1200),height:Math.min(viewport*.76,1200)*.608})}+ const svg={...node({}),getBoundingClientRect:()=>({width:viewport,height:Math.min(viewport,1728)*.4256}),+ querySelectorAll:selector=>selector==='defs path'?paths:selector==='[data-ribbon-band]'?bands:[],+ querySelector:selector=>selector.startsWith('#ribbon-seam-')?seams[Number(selector.at(-1))-1]:node({})}+ const reduced={matches:false,addEventListener:(_name,callback)=>listeners.push(callback)}+ await vm.runInNewContext(`(async()=>{${entry}})()`,{+ URLSearchParams,Event,location:{search:''},ribbonGeometry,ribbonPath,+ matchMedia:query=>query.includes('reduce')?reduced:{matches:true},+ document:{documentElement:{dataset},querySelector:selector=>selector==='.signal-wings'?svg:selector==='.product-window'?product:node({})},+ window:{dispatchEvent:event=>events.push(event.type)},+ ResizeObserver:class{constructor(callback){onResize=callback}observe(){}},+ requestAnimationFrame:callback=>{draw=callback;return 1},cancelAnimationFrame(){draw=null},+ })+ const clock=animations.at(-1)+ const fade=animations.find(animation=>animation.frames[0]?.opacity===0&&!('transform' in animation.frames[0]))+ const movement=animations.find(animation=>animation.frames[0]?.transform==='translateY(20px)')+ assert.equal(fade.options.duration,300)+ assert.equal(movement.options.duration,600,'the window keeps its original settling motion')+ assert.equal(fade.options.delay,270)+ assert.equal(clock.options.duration,570+4*55+350,'keep the draw duration and band stagger')+ clock.currentTime=569;draw();assert.equal(dataset.ribbonPaint,'waiting')+ clock.currentTime=fade.options.delay+fade.options.duration;draw();assert.equal(dataset.ribbonPaint,'ready')+ clock.currentTime=700;draw()+ assert.notEqual(paths[0].attributes.d,ribbonPath(originals[0],ribbonGeometry(viewport,Math.min(viewport*.76,1200))))+ viewport=width===2560?1280:2560;onResize();draw()+ if(width===2560){+ reduced.matches=true;listeners.forEach(callback=>callback({matches:true}))+ }else{+ clock.currentTime=1140;draw();animations.forEach(animation=>animation.finish())+ await new Promise(resolve=>setImmediate(resolve))+ }+ assert.equal(dataset.heroEntry,'complete')+ assert.deepEqual(events,['hero-entry-complete'])+ paths.forEach((path,i)=>assert.equal(path.attributes.d,ribbonPath(originals[i],ribbonGeometry(viewport,Math.min(viewport*.76,1200)))))+ assert(materials.every(material=>material.removed),'temporary entry gradients are removed')+ bands.forEach(band=>assert.equal(band.paths[1].attributes.fill,'url(#ribbon-surface)'))+}+console.log('Entry clock, live resize, reduced-motion interruption and final curved geometry cleanup passed.')diff --git a/site/scripts/ribbon-geometry.test.mjs b/site/scripts/ribbon-geometry.test.mjsnew file mode 100644index 00000000..cc550d3c--- /dev/null+++ b/site/scripts/ribbon-geometry.test.mjs@@ -0,0 +1,47 @@+import assert from 'node:assert/strict'+import {readFileSync} from 'node:fs'+import {ribbonGeometry,ribbonPath} from '../public/marketing/ribbon-geometry.mjs'++const html=readFileSync(new URL('../content/home.html',import.meta.url),'utf8')+const originals=[...html.matchAll(/d="(M0 [\d.]+ 800 325(?: 0 [\d.]+Z)?)"/g)].map(match=>match[1])+assert(originals.length>50,'exercise the real fills, seams and fine stripes')+const numbers=path=>path.match(/-?\d*\.?\d+(?:e[+-]?\d+)?/g).map(Number)+const near=(a,b)=>assert(Math.abs(a-b)<1e-8,`${a} differs from ${b}`)+const cubic=(points,t)=>[0,1].map(axis=>(1-t)**3*points[0][axis]+3*(1-t)**2*t*points[1][axis]+3*(1-t)*t*t*points[2][axis]+t**3*points[3][axis])+const curve=values=>Array.from({length:4},(_,i)=>values.slice(i*2,i*2+2))++for(const width of [375,760,1280,1728,1729,2560,3840]){+ const appWidth=width<=760?width-40:Math.min(width*.76,1200)+ const g=ribbonGeometry(width,appWidth)+ for(const original of originals){+ const full=ribbonPath(original,g),fullPoints=numbers(full)+ if(width<=1728)assert.equal(full,original,'preserve the approved laptop SVG exactly')+ let lastX=Infinity+ for(let step=0;step<=40;step++){+ const progress=g.covered+(1-g.covered)*step/40+ const path=ribbonPath(original,g,progress),points=numbers(path)+ assert.equal(path.endsWith('Z'),original.endsWith('Z'))+ assert(points.every(Number.isFinite))+ assert(points[0]<=lastX+1e-8,'end cap moves outward without reversing')+ lastX=points[0]+ if(g.curved){+ near(points[6],fullPoints[6]);near(points[7],fullPoints[7])+ const t=(1-progress)/(1-g.covered)+ for(const u of [0,.25,.5,.75,1]){+ const actual=cubic(curve(points),u),expected=cubic(curve(fullPoints),t+(1-t)*u)+ actual.forEach((value,i)=>near(value,expected[i]))+ }+ }+ }+ }+ if(width>=1000){+ const artHeight=Math.min(width,1728)*.4256,appHeight=appWidth*.608+ near(artHeight*appWidth/Math.min(width,1728),appHeight*.7)+ assert((artHeight-appHeight)/2+6<38,'top tip and sway stay below the platform line')+ assert((artHeight-appHeight)/2+6<92,'bottom tip and sway fit before the next section')+ }+}+// Approved C control points at 2560px, copied from the reviewed comparison geometry.+const approved=[0,0,374,0,548,56.1792,680,112.3584,1280,367.7184]+numbers(ribbonPath('M0 0 800 325',ribbonGeometry(2560,1200))).forEach((value,i)=>near(value,approved[i]))+console.log('Approved C geometry, all band edges, monotonic entry and exact cubic trimming passed at phone, laptop and wide widths.')diff --git a/site/scripts/theme.test.mjs b/site/scripts/theme.test.mjsindex f019d1e1..6998f9f2 100644--- a/site/scripts/theme.test.mjs+++ b/site/scripts/theme.test.mjs@@ -7,7 +7,7 @@ const bootstrap=html.match(/<script>\s*(\(function\(\)[\s\S]*?)<\/script>/)[1];const script=readFileSync(new URL('../public/marketing/theme.mjs',import.meta.url),'utf8').replace('export function','function');assert.ok(html.indexOf(bootstrap)<html.indexOf('href="/marketing/site.css"'));-function page(saved,{blocked=false}={}){+function page(saved,{blocked=false,search=''}={}){const classes=new Set();const root={dataset:{theme:'light'},classList:{add:v=>classes.add(v),remove:v=>classes.delete(v)}};const toggle={hidden:true,setAttribute(k,v){this[k]=v},addEventListener(k,fn){this[k]=fn}};@@ -15,6 +15,7 @@ function page(saved,{blocked=false}={}){const frames=[false,true].map(hero=>({classList:{contains:()=>hero},contentDocument:{documentElement:{dataset:{},style:{}}}}));const storage=new Map(saved===undefined?[]:[['yogurt-theme',saved]]);const context=vm.createContext({+ URLSearchParams,location:{search},document:{documentElement:root,querySelector:s=>s==='.theme-toggle'?toggle:meta,getElementById:id=>id==='theme-icon'?icon:fallback,querySelectorAll:()=>frames},localStorage:{getItem(k){if(blocked)throw Error('denied');return storage.get(k)},setItem(k,v){if(blocked)throw Error('denied');storage.set(k,v)}},@@ -58,12 +59,21 @@ assert.doesNotThrow(()=>blocked.toggle.click());assert.equal(blocked.root.dataset.theme,'dark');assert.equal(blocked.toggle['aria-pressed'],'true');+for(const saved of ['light','dark']){+ const p=page(saved,{search:'?edge=light&static=1'});+ assert.equal(p.root.dataset.heroEdge,undefined,'the hero edge has no URL switch');+}+function luminance(hex){const channels=hex.match(/[\da-f]{2}/gi).map(v=>parseInt(v,16)/255).map(v=>v<=.04045?v/12.92:((v+.055)/1.055)**2.4);return channels.reduce((sum,v,i)=>sum+v*[.2126,.7152,.0722][i],0);}const contrast=(a,b)=>{const x=luminance(a),y=luminance(b);return (Math.max(x,y)+.05)/(Math.min(x,y)+.05)};const css=readFileSync(new URL('../public/marketing/site.css',import.meta.url),'utf8');+assert(!/data-hero-edge/.test(css),'no hero edge comparison rules remain');+assert(css.includes(':root[data-theme=light] .product-stage>.product-window.demo-window{border:1px solid #5A5A5E}'),'light mode gives the demo window a mid-grey border');+assert(css.includes(':root[data-theme=dark] .product-stage>.product-window.demo-window::after{'),'dark inner highlight remains the default');+assert(css.includes(':root[data-theme=dark] .step-outline{fill:var(--float);stroke:var(--line)}'),'step outlines use the quiet neutral border');assert.ok(css.includes('.site-header nav>a:nth-of-type(2)'), 'The new button must not change which mobile nav link is hidden');const dark=css.match(/:root\[data-theme=dark\]\{color-scheme:dark;([^}]+)\}/)[1];const tokens=Object.fromEntries([...dark.matchAll(/--([\w-]+):(#[\da-f]+)/gi)].map(([,key,value])=>[key,value]));