graphic-gif
БесплатноЗапускает вложенные скриптыНе проверенCreates animated looping GIFs from CSS animations (default) or AI image-to-video. 800×800px default, 6 animation types, 4 style presets. Trigger when user…
от Varnan-Tech★ 724 звезды на GitHubОб этом скилле
graphic-gif
Generates an animated looping GIF from CSS animations or an AI image-to-video API. Output: animation.gif.
Unlike every other graphic- skill that outputs a static PNG or PDF, this skill outputs an animated .gif. Uses CSS @keyframes animations captured frame-by-frame via Playwright and the Web Animations API (Option A, default), or an AI image-to-video pipeline via Kling (Option B).
Critical Rules (read before every generation)
- Default is css-animated. Never use
ai-generatedunless explicitly requested. - Canvas is 800×800px square. All
clamp()values computed at 800px (1vw = 8px). - Single self-contained HTML. All CSS inline in
<style>. Font CDN<link>only external dependency. - Never dump HTML in chat. Save to file, show summary only.
- Frame capture uses Web Animations API seeking. NOT
setTimeoutloops, NOTanimation-delaytricks. - Exact frame count:
Math.floor(duration_seconds * fps)frames. The frame att=duration_msMUST NOT be captured — it duplicatest=0and causes a visible stutter at the loop point. - No placeholder boxes. CSS-generated visuals only. No "image goes here" elements.
- Simpler palettes = smaller files. Use:
clean-slate,terminal,electric-burst,brutalist. - No animation-delay for stagger. Bake stagger into
@keyframespercentages — frame seeking handles timing. - Commit to design direction before writing CSS. Tone, signature element, motion style, unforgettable detail — all decided before first line of code.
Step 1: Intake
Required: prompt (content description AND motion brief)
Optional with defaults:
| Parameter | Default | Options |
|---|---|---|
| animation_type | css-animated | css-animated / ai-generated |
| duration | 3.0 | seconds |
| fps | 12 | frames per second |
| loop | true | true / false |
| style | clean-slate | clean-slate / terminal / electric-burst / brutalist |
| dimensions | 800x800 | WxH in pixels |
| optimization | balanced | quality / balanced / filesize |
If prompt is missing or lacks motion description, ask exactly:
"What should the GIF show? Describe the content AND the motion (e.g., 'Stats count up: 73% of buyers read 3+ pieces of content before purchase. Typewriter effect, one character at a time. Style: terminal. 3 seconds, 12fps.')
Key settings (all optional, defaults shown):
- animation_type: css-animated (default) or ai-generated
- duration: 3.0 seconds
- fps: 12
- loop: true
- style: clean-slate (options: clean-slate / terminal / electric-burst / brutalist)
- dimensions: 800x800
- optimization: balanced (options: quality / balanced / filesize)"
If all required info is present → skip directly to Step 2.
Step 2: Internal Architecture (never shown to user)
For css-animated:
- Choose animation type from:
fade-in,slide-in,typewriter,counter,pulse,loop-scroll - Read
references/animation-library.md— find the chosen type's full HTML/CSS spec - Read
references/style-presets.md— load the chosen style's CSS token block - Calculate frame count:
Math.floor(duration_seconds * fps)— write this number down - Commit to design direction:
| Decision | Derive from |
|---|---|
| Tone | Emotional register for audience (mechanical / warm / electric / professional) |
| Signature element | ONE visual device used consistently (cursor blink, ghost number, scan-line overlay, accent border) |
| Motion style | Ease curve philosophy for this type (spring / linear / step / ease-in-out) |
| Unforgettable detail | The ONE thing a viewer will remember about this GIF |
For ai-generated:
- Generate base still frame HTML (poster-style layout for the canvas)
- Export as PNG using screenshot
- Call Kling API:
POST https://api.klingai.com/v1/videos/image2videowithimage_urlandpromptdescribing the motion - Poll for job completion
- Download video → convert to GIF with ffmpeg:
# Two-pass palette for best color quality ffmpeg -i input.mp4 -vf "fps=12,scale=800:800:flags=lanczos,palettegen=stats_mode=diff" palette.png ffmpeg -i input.mp4 -i palette.png -vf "fps=12,scale=800:800:flags=lanczos,paletteuse=dither=bayer:bayer_scale=5" output.gif
Step 3: HTML Generation (css-animated path)
Read references/animation-library.md and references/style-presets.md before generating.
Canvas base — required on every GIF:
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body {
width: 800px;
height: 800px;
overflow: hidden;
background: var(--bg);
font-family: var(--font-body);
}
.canvas {
width: 800px;
height: 800px;
position: relative;
overflow: hidden;
display: flex;
align-items: center;
justify-content: center;
}
Animation rules:
animation-fill-mode: forwards(orboth) on ALL animated elements- Timing functions per type:
typewriter→steps(N, end)where N =
Установить graphic-gif в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл graphic-gif?
Creates animated looping GIFs from CSS animations (default) or AI image-to-video. 800×800px default, 6 animation types, 4 style presets. Trigger when user says "create an animated gif", "make a looping gif", "animated banner", "CSS animation gif", "social media animation", "make this loop", "animated graphic", or "motion graphic".
Как установить скилл graphic-gif?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл graphic-gif запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
frontend-design
Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
от Anthropicwebapp-testing
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
от Anthropicbrand-guidelines
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
от Anthropicweb-artifacts-builder
Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…
от Anthropic