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's curved ribbon wings show at every screen size, not only on wide screens
Eric Brownroutfe9972dffde8
diff --git a/site/public/marketing/ribbon-geometry.mjs b/site/public/marketing/ribbon-geometry.mjsindex f71b11af..b851aee1 100644--- a/site/public/marketing/ribbon-geometry.mjs+++ b/site/public/marketing/ribbon-geometry.mjs@@ -1,19 +1,14 @@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}+ // Curved wings at every width; the art keeps its 1728px height cap and scales down below it+ const art=Math.min(width,1728)+ return {width,height:art*.4256,gap:(width-appWidth)/2,baselineGap:(art-appWidth)/2,+ attachment:appWidth/art,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 originalconst 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=>{diff --git a/site/scripts/ribbon-geometry.test.mjs b/site/scripts/ribbon-geometry.test.mjsindex cc550d3c..e92801f3 100644--- a/site/scripts/ribbon-geometry.test.mjs+++ b/site/scripts/ribbon-geometry.test.mjs@@ -15,7 +15,6 @@ for(const width of [375,760,1280,1728,1729,2560,3840]){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=Infinityfor(let step=0;step<=40;step++){const progress=g.covered+(1-g.covered)*step/40@@ -24,13 +23,11 @@ for(const width of [375,760,1280,1728,1729,2560,3840]){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]))- }+ 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]))}}}@@ -44,4 +41,6 @@ for(const width of [375,760,1280,1728,1729,2560,3840]){// 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.')+// Laptops get the same curved wings, not the old straight art.+for(const width of [1280,1512])assert(ribbonPath('M0 0 800 325',ribbonGeometry(width,Math.min(width*.76,1200))).includes(' C'),'curved at laptop widths')+console.log('Curved geometry at every width, all band edges, monotonic entry and exact cubic trimming passed at phone, laptop and wide widths.')