add-shader-cursor-trail — скилл для Claude Code: шейдерный след
Добавляет в проект hero-эффект на WebGPU: белый мерцающий полутоновый след за курсором с хроматическими волнами и плёночным зерном. С откатом на статичный кадр.
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a claude-codeЧто делает add-shader-cursor-trail
Скилл ставит эффект как progressive enhancement: слой с шейдером ложится за контентом секции, а сама секция с картинкой, ссылками и контролами остаётся как была. Внутри шесть шейдерных узлов в фиксированном порядке, два невидимых драйвера и связки по ID. Порядок и ID менять нельзя, а вот прозрачность и режим наложения — можно.
Нужен пакет shaders, который ставится вашим же менеджером пакетов, и импорт с подпути под фреймворк: shaders/react, shaders/vue, shaders/svelte или shaders/solid. До реализации скилл просит прочитать references/implementation.md. Для React и Next.js есть готовые файлы в assets/react/: лёгкий гейт возможностей держится отдельно от тяжёлого модуля шейдера, поэтому неподходящий посетитель бандл даже не запросит.
Загрузка включается только при WebGPU, точном указателе с hover, обычных настройках движения и прозрачности, видимой вкладке, фокусе окна и попадании секции в вьюпорт. Секция ушла из вида — слой размонтируется, работа GPU прекращается. Без WebGPU или при reduced motion посетитель видит исходный кадр. Есть скрипт проверки: node scripts/verify-cursor-trail.mjs с тремя путями к файлам, для React-варианта. Утверждать, что визуал проверен в браузере, скилл запрещает, если вы этого правда не делали.
Какие задачи решает
- добавить полутоновый след за курсором в hero-секцию
- оживить фон страницы контактов интерактивным шейдером
- встроить эффект на WebGPU, не ломая семантику секции
- сделать честный откат на статичный кадр без WebGPU
- научить агента отличать подходящего посетителя от неподходящего до загрузки бандла
Примеры запросов агенту
- Добавь шейдерный след за курсором в hero-секцию на React
- Поставь
add-shader-cursor-trailи подключи его к блоку контактов, статичный фон оставь фолбэком - Проверь мою реализацию следом за курсором скриптом
verify-cursor-trail.mjs
Как установить add-shader-cursor-trail
1Через Skills CLI (Vercel)
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a claude-code2Вручную: положить файлы
~/.claude/skills/add-shader-cursor-trail/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/add-shader-cursor-trail/
1Через Skills CLI (Vercel)
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a codex2Вручную: положить файлы
.agents/skills/add-shader-cursor-trail/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a cursor2Вручную: положить файлы
.cursor/skills/add-shader-cursor-trail/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install MengTo/Skills add-shader-cursor-trail2Вручную: положить файлы
.github/skills/add-shader-cursor-trail/SKILL.md1Через Skills CLI (Vercel)
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a gemini-cli2Командой платформы
gemini skills install https://github.com/MengTo/Skills --path agent-skills/web-design/add-shader-cursor-trailВручную: положить файлы
.devin/skills/add-shader-cursor-trail/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add MengTo/Skills --skill add-shader-cursor-trail -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о add-shader-cursor-trail
Как установить add-shader-cursor-trail в Claude Code?
Выполните npx skills add MengTo/Skills --skill add-shader-cursor-trail -a claude-code. Файл скилла окажется по пути ~/.claude/skills/add-shader-cursor-trail/SKILL.md.
Что делает add-shader-cursor-trail?
Собирает в секции сайта шейдерный слой на WebGPU: след за курсором, полутоновую маску, хроматические волны и зерно. Контент секции при этом остаётся на месте, а слабые устройства получают статичный кадр.
Какие браузеры и устройства увидят эффект?
Только те, где есть WebGPU и точный указатель с hover, при обычных настройках движения и прозрачности. На тач-экранах, при reduced motion и forced colors слой скрыт.
Исходный текст
SKILL.md · MIT
--- name: add-shader-cursor-trail description: "Add the Shaders WebGPU mouse effect used for the Tidal Commons hero: a white twinkling halftone cursor trail driven by ChromaFlow, masked through a DotGrid, finished with chromatic ripples and film grain, and protected by static, touch, accessibility, SSR, and performance fallbacks. Use when a user asks for this shader mouse effect, a halftone cursor trail, an interactive WebGPU hero/contact background, or a reusable cursor-following shader layer in React, Next.js, Vue, Svelte, Solid, or plain web projects." --- # Add Shader Cursor Trail Implement the exact trail as progressive enhancement. Preserve the host section's semantic content, imagery, controls, and static first frame. ## Workflow 1. Inspect the framework, rendering mode, existing motion stack, layer order, reduced-motion rules, and package manager. Do not add another smooth-scroll engine or replace the section's content. 2. Install `shaders` with the existing package manager. Import from the matching framework subpath: `shaders/react`, `shaders/vue`, `shaders/svelte`, or `shaders/solid`. 3. Read [references/implementation.md](references/implementation.md) before implementation. Keep the six shader nodes, their order, both invisible drivers, and both ID linkages exact. 4. For React or Next.js, copy and adapt the files in `assets/react/`. Keep the lightweight capability gate separate from the heavy shader module so ineligible visitors do not request the shader bundle. 5. Place one full-bleed, `aria-hidden="true"` shader layer behind the section content. Keep links and controls above it. Do not set `pointer-events: none` on the canvas unless cursor tracking is verified to use global events. 6. Gate loading on WebGPU, a fine hover pointer, normal motion/transparency preferences, document visibility, window focus, and section intersection. Unmount when the section leaves view so GPU work stops. 7. Keep the original image or dark background as the complete fallback. Hide the layer for reduced motion, reduced transparency, coarse/no-hover pointers, and forced colors. 8. Adapt only presentation variables such as opacity and blend mode. Do not change the graph to decorative noise, add WebGL/Three.js, or hotlink Shaders preview assets. ## Validate Run the project's lint, typecheck/tests, and production build. For React implementations, also run: ```bash node /path/to/add-shader-cursor-trail/scripts/verify-cursor-trail.mjs \ path/to/CursorTrailShader.tsx \ path/to/CursorTrailGate.tsx \ path/to/cursor-trail.css ``` Verify the static section with JavaScript unavailable, keyboard access to content above the layer, touch behavior, reduced motion, unsupported WebGPU, focus/visibility cleanup, and absence of runtime requests to `previews.shaders.com` or `data.shaders.com`. Report the chosen blend mode, fallback, capability gates, production-build result, and any browser limitation. Do not claim WebGPU visual verification unless it was actually performed in a compatible browser.
© MengTo · MIT · MengTo/Skills