Communitygithub.com

portfolio-motion

Motion and 3D playbook for developer portfolios, distilled from building and comparing five versions. Gives the motion levels (calme, vivant, spectaculaire), the performance and accessibility budget, the recipes that worked (3D agent network hero, pinned horizontal projects, timeline that draws, scramble titles, counters, magnetic buttons, tilt cards, custom cursor), where to find more in frontend-atlas / cinematic-ui / awwwards-3d, and how to ship a build that opens by double-click. Use when adding animation, 3D, scroll effects or WebGL to a portfolio, or when an animated site breaks when opened from the file explorer.

¿Qué es portfolio-motion?

portfolio-motion is a Claude Code agent skill that motion and 3D playbook for developer portfolios, distilled from building and comparing five versions. Gives the motion levels (calme, vivant, spectaculaire), the performance and accessibility budget, the recipes that worked (3D agent network hero, pinned horizontal projects, timeline that draws, scramble titles, counters, magnetic buttons, tilt cards, custom cursor), where to find more in frontend-atlas / cinematic-ui / awwwards-3d, and how to ship a build that opens by double-click. Use when adding animation, 3D, scroll effects or WebGL to a portfolio, or when an animated site breaks when opened from the file explorer.

Compatible con✓Claude Code~Codex CLI✓Cursor
npx skills add https://github.com/anas34b/portfolio-skills-kit/tree/HEAD/skills/portfolio-motion

Preguntar en tu IA favorita

Abre un nuevo chat con esta habilidad de agente ya precargada.

Documentación

Portfolio Motion

Pick the level first

LevelWhat movesLibrariesBudget (gzip JS)When
CalmeSection fades, hover and press statesnone< 5 KBRecruiter-first, corporate targets
Vivant+ split headline, counters, marquee with pause, magnetic main button, staggered listsGSAP (+ ScrollTrigger) or one-shot-site effects.js< 60 KBMost portfolios
Spectaculaire+ one 3D or WebGL hero, one pinned scroll scene, custom cursor, scroll progressthree.js (lazy chunk), GSAP, optional Lenis< 300 KB, three.js loaded after first paintCreative devs, AI / 3D / front-end roles

Ask the person. "Futuriste, animé" means Spectaculaire. Never mix two heavy scenes on one page.

Non-negotiable

  • Animate transform, opacity, clip-path only. Never width, height, top, left.
  • Hover effects only under @media (hover: hover) and (pointer: fine).
  • prefers-reduced-motion: reduce → no movement, no parallax, 3D renders one still frame, content visible.
  • 3D: WebGL check, poster or plain background fallback, pixelRatio capped at 1.5 on phones / 2 elsewhere, render loop paused off screen and in hidden tabs. one-shot-site addons/hero3d.js already does all of this.
  • Text over a canvas needs a scrim (gradient) so contrast holds whatever the scene draws.
  • Pinned scenes: use pinType: 'transform' if the audit reports layout shift on the pinned element.
  • Hero headline readable within ~1 s; a showpiece may go to 2 s, never more.
  • Loops beside text need a pause button (WCAG 2.2.2). The marquee in effects.js adds one.
  • Phone: no horizontal pinned scroll, stack the cards; keep one sticky action bar at the thumb.

Recipes that worked (files in recipes/ next to this SKILL.md)

  • recipes/agent-network.js — 3D agent-network hero, build for one-shot-site initHero3d
  • recipes/a-3d.js — hero A: glass + bloom + Lenis (awwwards-3d glass-product ported to npm)
  • recipes/b-particles.js — hero B: name in particles → sphere, mouse repulsion (frontend-atlas 6.1 ported to vanilla)
  • recipes/c-type.js — hero C: type-fx tunnel + split-flap + grain (cinematic-ui; needs cinematic-ui/kit/type-fx.js)
  • recipes/common.css — shared hero layout and scrim
  • recipes/scene-particles.js — V6 hero: name → sphere → orbit rings, one shader, mouse repulsion
  • recipes/scene-glass.js — V6 contact: glass knot + bloom, lazy-loaded near the section
  • recipes/file-build.mjs — double-click build post-processor
EffectFile / sourceNotes
3D agent network hero (core + agents on 3 orbits + travelling packets + dust)recipes/agent-network.js, passed to one-shot-site initHero3dFollows the pointer, recedes on scroll via window.__heroScroll
Split headline, counters, drawn SVG lines, marquee, magnetic, tiltone-shot-site addons/effects.js (data-split, data-count, data-draw, data-marquee, data-magnetic, data-tilt)Pick 3–4, not all
Pinned horizontal projects with counter "1 / 3"main.js → ScrollTrigger pin + containerAnimationDesktop ≥ 900 px only
Timeline line that draws while reading, dots light upmain.js → scaleY scrub + toggleClass
Section titles that decode like a terminalmain.js → scramble()Keep aria-label = real text
Custom cursor dot + ringgsap.quickToFine pointer only
Pointer light on cardsCSS radial-gradient at --mx/--my
Reading progress bar, film grain overlayCSS + one ScrollTriggerGrain at 4–6 % opacity

Where to get more

  • frontend-atlas → references/INDEX.md: 457 anchored recipes. For portfolios start with text-effects.md, interactions.md (cursor, magnetic), scroll-gsap.md (pin, horizontal, stacked cards), webgl-shaders-3d.md (particles, fluid, shader backgrounds), page-transitions.md. Many examples are React: port to vanilla (same GSAP calls, querySelector instead of refs).
  • cinematic-ui → kit/type-fx.js: typeFx(el, 'tunnel' | 'glitch' | 'split-flap' | 'read-fill' | 'blur-resolve' | 'slit-scan' | …), drive fx.p (0–1) with a ScrollTrigger or a tween and fx.t for continuous effects. kit/grade.js for grain and halation.
  • awwwards-3d → docs/templates/*.html (minimal, coin-scroll, room-walkthrough, glass-product), references/PATTERNS.md, SHADERS.md, POST_PROCESSING.md. Replace unpkg imports with npm packages.
  • auteur → reference/scroll-cinema.md for wipe / curtain / shutter transitions and displacement.

Verify motion, do not guess

npm run build
node <one-shot-site>/scripts/film.mjs dist            # strips + timeline: layout-shift, slow-headline, loops
node <one-shot-site>/scripts/film.mjs dist --reduced  # must be "All clear"
node <frontend-atlas>/scripts/motion-audit.mjs <url>  # CLS, frame pacing, reveals that never fire

Headless Chrome on WSL/Linux without system libs: install playwright-core, run npx playwright-core install chromium-headless-shell, extract libnspr4 libnss3 libasound2t64 with apt-get download + dpkg-deb -x into a folder, and point CHROME_PATH at a wrapper that sets LD_LIBRARY_PATH (see tools/portfolio-kit/chrome-wsl.sh).

Pitfalls found in V6

  • document.fonts.load() rejects on file://: always .catch(() => {}) before sampling text into particles.
  • three.js does not parse oklch(): convert CSS colours by painting one canvas pixel and reading it back.
  • Type-fx layers (tunnel) are decoration: mark the stage aria-hidden and inert, or axe reports contrast on them.

Shipping a build that opens by double-click

file:// blocks ES modules, crossorigin font preloads and lazy chunks. Most people open index.html from the explorer first and conclude the site is broken. Ship both:

  • dist/ — normal Vite build for hosting.
  • dist-file/ — FILE_BUILD=1 BASE=./ vite build --outDir dist-file with rolldownOptions.output = { format: 'iife', codeSplitting: false }, then tools/portfolio-kit/file-build.mjs (copied by the kit installer): removes font preloads, swaps type="module" for defer, injects the CSS with fonts inlined as base64. Test it with a file:// URL in headless Chrome; zero console errors except {{URL}} before deploy.

Individual skills in this repo

This repo contains 4 individual skills — each has its own dedicated page.

portfolio-brief

Lets the person design their own portfolio by choosing, not by accepting AI defaults - art direction (30), mood and font pairing (6 moods, 24 tested pairs), colour from their subject with contrast checked, light/dark, motion level, hero (11 kinds), 3 to 5 effects from 213 recipes, and sections. Shows real mockups of their first screen to decide, then writes brief.json and DESIGN.md that every later step must follow. Use before building any portfolio, when someone says "je veux choisir les couleurs / les animations", "propose-moi des options", "personnalise", or when a site risks looking generated.

portfolio-content

Turns a raw CV (pasted text, PDF export, LinkedIn dump) into clean, verifiable portfolio content - facts, roles, dates, places, numbers, projects with stack, skills, education - and French or English copy that sounds like a person, not a generator. Fixes spelling and mixed-up dates and places from PDF exports, removes empty adjectives, and lists every missing link as TODO instead of inventing it. Use when starting a portfolio from a CV, rewriting the "about" or hero line, or when the copy sounds generic.

portfolio-styles

Catalogue of six tested portfolio styles, each with a working reference site in the kit - V1 classic template (React, light, illustration, multi-page), V2 dark bento (single HTML file, no build), V3 editorial quiet (light, one brand colour, typographic), V4 combined (dark/light switch, sprint board hero, bento projects), V5 immersive 3D (three.js scene, pinned scroll, cursor), V6 everything combined (particle name, split-flap role, sprint board, type tunnel, glass contact, light/dark). Use when someone wants a portfolio "like V1/V2/V3/V4/V5", wants a simple or non-3D site, asks for "sobre", "clair", "sans 3D", "un seul fichier", "classique", "sombre", or wants to compare styles before choosing, or wants "tout" / "la bombe".

portfolio-ux

The ergonomics and accessibility rules every portfolio built with this kit must pass, whatever style, colours or animations the person chose - consolidated from one-shot-site (checks), ui-ux-pro-max (120 UX guidelines), frontend-atlas (performance-a11y) and what failed in our own builds. Gives the rules, how to verify each one with a script, and the fix. Use when building, reviewing or before shipping a portfolio, or when a design choice might hurt readability, navigation, touch, keyboard or motion sensitivity.

Skills relacionados