Skip to content

Switch landing-page logo morph to spiral path#1396

Merged
jonfroehlich merged 1 commit into
masterfrom
landing-page-spiral-logo
Jun 24, 2026
Merged

Switch landing-page logo morph to spiral path#1396
jonfroehlich merged 1 commit into
masterfrom
landing-page-spiral-logo

Conversation

@jonfroehlich

Copy link
Copy Markdown
Member

Summary

Switches the scroll-driven Makeability Lab logo animation on the landing page from the default straight-line reverse-explosion trajectory to a spiral path — the scattered triangles now swirl inward around the logo centroid as they assemble.

Matches the "Spiral" option in the MorphPaths demo.

Changes

All in website/static/website/js/makelab-logo.js (JS only):

  • Import spiralPath from the makelab js CDN dist (already exported there — no library version change needed).
  • Add a SPIRAL_TURNS config constant (extra revolutions each triangle sweeps; higher = more swirl, default 1).
  • Call morpher.setPath(spiralPath({ turns: SPIRAL_TURNS })) once at morpher creation. pathFunction persists and every reset() / resetFromArt() re-prepares per-triangle path data, so this covers both the default scatter mode and the holiday-art easter egg.

Notes

  • prefers-reduced-motion behavior is unchanged — the logo stays pinned in its assembled end state with no scroll-driven morph.
  • The import remains pinned to @main/dist/makelab.logo.js (pre-existing). Happy to switch to a tagged release if preferred.
  • To tune the effect, adjust SPIRAL_TURNS (e.g. 2 for a more dramatic vortex, 0.5 for subtler).

Testing

Verified locally at http://localhost:8571/ — scrolling down assembles the logo via the inward spiral. Confirmed the served static JS reflects the change.

🤖 Generated with Claude Code

The scroll-driven Makeability Lab logo animation previously used the
default straight-line (reverse-explosion) trajectory. Switch it to the
spiral path so the scattered triangles swirl inward around the logo
centroid as they assemble.

- Import spiralPath from the makelab js CDN dist (already exported).
- Add SPIRAL_TURNS config constant (extra revolutions; higher = more swirl).
- Call morpher.setPath(spiralPath({ turns })) once at creation; pathFunction
  persists and each reset()/resetFromArt() re-prepares per-triangle path
  data, so this covers both the default scatter and holiday-art modes.

prefers-reduced-motion behavior is unchanged (logo stays pinned assembled).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jonfroehlich jonfroehlich merged commit b15c93e into master Jun 24, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant