Communitygithub.com

애니메이션 & 모션 스킬

접근성(prefers-reduced-motion)과 성능(jank 및 레이아웃 스래싱 방지)에 중점을 둔 CSS 애니메이션, 전환 및 스크롤 기반 효과를 다룹니다. 모션 추가, 호버 효과, 로딩 상태 또는 스크롤 기반 애니메이션이 필요할 때 사용하세요.

애니메이션 & 모션 스킬란 무엇인가요?

이 스킬은 접근성과 성능을 최우선으로 하는 CSS 애니메이션 및 전환에 대한 포괄적인 가이드입니다. 사용자 동작 선호도(prefers-reduced-motion)를 존중하는 'Reduced Motion First' 패턴을 필수로 강조하며, 성능 최적화를 위해 transform, opacity, filter 같은 컴포지터 전용 속성 사용을 권장하고 width, height 등 레이아웃을 유발하는 속성 애니메이션을 피하도록 안내합니다. 또한 키프레임 애니메이션, 로딩 스피너, 스켈레톤 로드, 진입 애니메이션(페이드/슬라이드/스케일), 뷰 전환 API, 스크롤 기반 애니메이션, 버튼 프레스, 토글 스위치, 체크박스 체크와 같은 마이크로 인터랙션 패턴을 접근성 친화적인 코드 예제와 함께 제공합니다. 특히 전정 기관 문제를 유발할 수 있는 패럴랙스, 깜빡임, 무한 애니메이션과 같은 위험한 패턴을 경고하고, 테스트 체크리스트와 시스템 설정 가이드를 포함하여 실무에서 바로 적용 가능하도록 구성되어 있습니다. Claude Code, Cursor, Codex와 같은 AI 에이전트가 웹 개발 시 모션 관련 코드를 생성할 때 참고하기에 적합합니다.

지원 대상~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/David-Li0406/meta-skill-evloving/tree/HEAD/skill-flow/data/skills-refined-36k/skillsmp/animation-motion

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

애니메이션 & 모션 스킬은(는) 무엇을 하나요?

이 스킬은 접근성(사용자 동작 선호도 존중)과 성능(jank 및 레이아웃 스래싱 방지)에 중점을 둔 CSS 애니메이션 및 전환을 다룹니다.

관련 스킬: CSS 전용 인터랙티브 패턴(자바스크립트 없는 탭, 아코디언, 토글)은 progressive-enhancement 스킬을 참조하세요.

철학

모션은 다음과 같아야 합니다:

  1. 목적이 있어야 - 주의를 안내하고, 관계를 보여주며, 피드백을 제공합니다.
  2. 존중해야 - prefers-reduced-motion 선호도를 존중합니다.
  3. 성능이 좋아야 - 가능하면 컴포지터 전용 속성을 사용합니다.
  4. 미묘해야 - 방해하거나 압도하지 않고 향상시킵니다.

Reduced Motion 우선

항상 reduced motion을 기본값으로 시작하고, 옵트아웃하지 않은 사용자에게만 모션을 추가하세요.

패턴

/* 기본: 모션 없음 (reduced motion 기본값) */
.element {
  transition: none;
}

/* 사용자가 reduced motion을 요청하지 않은 경우에만 모션 추가 */
@media (prefers-reduced-motion: no-preference) {
  .element {
    transition: transform 0.3s ease, opacity 0.3s ease;
  }
}

Reduced Motion 우선이 중요한 이유

접근 방식문제점
모션 우선, 이후 제거미디어 쿼리가 적용되기 전에 사용자가 모션 플래시를 봄
Reduced 우선, 이후 추가안전한 기본값, 모션은 점진적 향상

사용자 선호도 존중

prefers-reduced-motion 미디어 쿼리

/* 사용자가 reduced motion을 선호함 */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

세분화된 Reduced Motion

모든 모션을 제거하는 대신 대안을 제공하세요:

/* 선호도가 없는 사용자를 위한 전체 애니메이션 */
@media (prefers-reduced-motion: no-preference) {
  .card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }

  .card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
  }
}

/* Reduced motion을 위한 미묘한 대안 */
@media (prefers-reduced-motion: reduce) {
  .card {
    transition: box-shadow 0.15s ease;
  }

  .card:hover {
    box-shadow: var(--shadow-md);
  }
}

JavaScript 감지

const prefersReducedMotion = window.matchMedia(
  '(prefers-reduced-motion: reduce)'
).matches;

if (prefersReducedMotion) {
  // 즉시 전환 사용 또는 애니메이션 건너뛰기
  element.style.transition = 'none';
} else {
  // 전체 애니메이션
  element.animate(keyframes, options);
}

성능 안전 속성

컴포지터 전용 속성 (빠름)

다음 속성은 레이아웃이나 페인트를 유발하지 않고 애니메이션할 수 있습니다:

속성사용처
transform이동, 크기 조절, 회전
opacity페이드 인/아웃
filter블러, 밝기 (GPU 가속)
/* 좋음: 컴포지터 전용 */
.card:hover {
  transform: translateY(-4px) scale(1.02);
  opacity: 0.9;
}

애니메이션 피해야 할 속성

다음은 비용이 많이 드는 레이아웃 재계산을 유발합니다:

속성문제점
width, height레이아웃 재계산
top, left, right, bottom레이아웃 재계산
margin, padding레이아웃 재계산
border-width레이아웃 재계산
font-size레이아웃 + 텍스트 리플로우
/* 나쁨: 레이아웃 유발 */
.card:hover {
  margin-top: -4px;  /* 레이아웃 스래싱 */
  height: 110%;      /* 레이아웃 스래싱 */
}

/* 좋음: 대신 transform 사용 */
.card:hover {
  transform: translateY(-4px) scaleY(1.1);
}

컴포지터 레이어 승격

알려진 애니메이션에 대해서만 will-change를 드물게 사용하세요:

/* 애니메이션할 요소에만 사용 */
.animated-element {
  will-change: transform, opacity;
}

/* 애니메이션 완료 후 제거 */
.animated-element.animation-done {
  will-change: auto;
}

경고: 많은 요소에 will-change를 적용하지 마세요. 메모리를 소비합니다.


전환 패턴

디자인 토큰 통합

:root {
  /* 지속 시간 스케일 */
  --duration-instant: 0.1s;
  --duration-fast: 0.15s;
  --duration-normal: 0.3s;
  --duration-slow: 0.5s;

  /* 이징 함수 */
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

일반적인 전환

/* 호버 리프트 효과 */
@media (prefers-reduced-motion: no-preference) {
  .card {
    transition:
      transform var(--duration-fast) var(--ease-out),
      box-shadow var(--duration-fast) var(--ease-out);
  }

  .card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
  }
}

/* 포커스 링 */
@media (prefers-reduced-motion: no-preference) {
  button {
    transition: outline-offset var(--duration-instant) var(--ease-out);
  }

  button:focus-visible {
    outline: 2px solid var(--focus-color);
    outline-offset: 2px;
  }
}

/* 페이드 인 */
@media (prefers-reduced-motion: no-preference) {
  .fade-in {
    animation: fadeIn var(--duration-normal) var(--ease-out);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

애니메이션 패턴

키프레임 애니메이션

/* 주의를 위한 미묘한 펄스 */
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@media (prefers-reduced-motion: no-preference) {
  .notification-badge {
    animation: pulse 2s var(--ease-in-out) infinite;
  }
}

/* Reduced motion 대안: 애니메이션 없음 */
@media (prefers-reduced-motion: reduce) {
  .notification-badge {
    animation: none;
  }
}

로딩 스피너

/* Reduced motion을 존중하는 스피너 */
@keyframes spin {
  to { transform: rotate(360deg); }
}

.spinner {
  width: 24px;
  height: 24px;
  border: 2px solid var(--border-color);
  border-top-color: var(--primary-color);
  border-radius: 50%;
}

@media (prefers-reduced-motion: no-preference) {
  .spinner {
    animation: spin 1s linear infinite;
  }
}

@media (prefers-reduced-motion: reduce) {
  .spinner {
    /* 정적 표시기 또는 펄스 투명도 */
    animation: none;
    border-style: dotted;
  }
}

스켈레톤 로딩

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--surface-color) 25%,
    var(--background-alt) 50%,
    var(--surface-color) 75%
  );
  background-size: 200% 100%;
}

@media (prefers-reduced-motion: no-preference) {
  .skeleton {
    animation: shimmer 1.5s infinite;
  }
}

@media (prefers-reduced-motion: reduce) {
  .skeleton {
    animation: none;
    background: var(--background-alt);
  }
}

진입 애니메이션

페이드 앤 슬라이드

@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .animate-in {
    animation: fadeSlideUp var(--duration-normal) var(--ease-out) both;
  }

  /* 계층적 자식 */
  .animate-in > * {
    animation: fadeSlideUp var(--duration-normal) var(--ease-out) both;
  }

  .animate-in > *:nth-child(1) { animation-delay: 0ms; }
  .animate-in > *:nth-child(2) { animation-delay: 50ms; }
  .animate-in > *:nth-child(3) { animation-delay: 100ms; }
  .animate-in > *:nth-child(4) { animation-delay: 150ms; }
}

@media (prefers-reduced-motion: reduce) {
  .animate-in,
  .animate-in > * {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

스케일 인

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: no-preference) {
  dialog[open] {
    animation: scaleIn var(--duration-fast) var(--ease-out);
  }
}

뷰 전환 API

페이지 전환용 (점진적 향상):

/* 뷰 전환 활성화 */
@view-transition {
  navigation: auto;
}

/* 기본 크로스페이드 */
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: var(--duration-normal);
}

/* Reduced motion 존중 */
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation-duration: 0.01ms;
  }
}

/* 특정 요소의 명명된 전환 */
.hero-image {
  view-transition-name: hero;
}

::view-transition-old(hero),
::view-transition-new(hero) {
  animation-duration: var(--duration-slow);
}

스크롤 기반 애니메이션

최신 CSS 스크롤 기반 애니메이션 (점진적 향상):

/* 스크롤 시 페이드 인 */
@keyframes fadeInOnScroll {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: no-preference) {
  .scroll-reveal {
    animation: fadeInOnScroll linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-reveal {
    opacity: 1;
    transform: none;
  }
}

마이크로 인터랙션

버튼 프레스

@media (prefers-reduced-motion: no-preference) {
  button {
    transition: transform var(--duration-instant) var(--ease-out);
  }

  button:active {
    transform: scale(0.98);
  }
}

토글 스위치

.toggle-track {
  width: 44px;
  height: 24px;
  background: var(--surface-color);
  border-radius: 12px;
}

.toggle-thumb {
  width: 20px;
  height: 20px;
  background: white;
  border-radius: 50%;
  transform: translateX(2px);
}

@media (prefers-reduced-motion: no-preference) {
  .toggle-thumb {
    transition: transform var(--duration-fast) var(--ease-out);
  }
}

.toggle-input:checked + .toggle-track .toggle-thumb {
  transform: translateX(22px);
}

체크박스 체크

.checkbox-icon {
  stroke-dasharray: 24;
  stroke-dashoffset: 24;
}

@media (prefers-reduced-motion: no-preference) {
  .checkbox-icon {
    transition: stroke-dashoffset var(--duration-fast) var(--ease-out);
  }
}

.checkbox-input:checked + .checkbox-box .checkbox-icon {
  stroke-dashoffset: 0;
}

애니메이션 지속 시간 가이드라인

애니메이션 유형지속 시간이유
마이크로 인터랙션100-150ms즉각적인 피드백
단순 전환150-300ms눈에 띄지만 빠름
복잡한 애니메이션300-500ms따라갈 시간
페이지 전환300-500ms컨텍스트 전환
로딩 표시기1000-2000ms한 사이클 표시

100ms 규칙

사용자는 응답이 100ms 미만이면 작업을 즉시로 인식합니다. 다음에 사용하세요:

  • 버튼 활성 상태
  • 포커스 표시기
  • 토글 스위치

피해야 할 위험한 패턴

전정 기관 유발 요소

다음은 멀미나 발작을 일으킬 수 있습니다:

패턴문제점대안
패럴랙스 스크롤링전정 기관 문제정적 또는 미묘한 패럴랙스
자동 재생 비디오예상치 못한 움직임상호작용 시 재생
깜빡임 (>3Hz)발작 위험깜빡임 없음
큰 확대/축소전정 기관 문제페이드 전환
회전방향 감각 상실페이드 또는 슬라이드
/* 나쁨: 공격적인 패럴랙스 */
.parallax {
  transform: translateY(calc(var(--scroll) * 0.5));
}

/* 더 나음: 미묘하거나 reduced motion에서 비활성화 */
@media (prefers-reduced-motion: reduce) {
  .parallax {
    transform: none;
  }
}

무한 애니메이션

/* 나쁨: 지속적인 움직임 */
.attention-seeker {
  animation: bounce 1s infinite;
}

/* 더 나음: 제한된 반복 */
.attention-seeker {
  animation: bounce 1s 3; /* 3번만 */
}

/* 가장 좋음: 상호작용 시 트리거 */
.attention-seeker:hover {
  animation: bounce 0.5s;
}

테스트 체크리스트

브라우저 DevTools

  1. Chrome: Rendering > Emulate CSS media feature > prefers-reduced-motion: reduce
  2. Firefox: about:config > ui.prefersReducedMotion (0=no-preference, 1=reduce)
  3. Safari: Develop > Experimental Features > Reduced Motion

시스템 설정

  • macOS: 시스템 환경설정 > 손쉬운 사용 > 디스플레이 > 동작 줄이기
  • iOS: 설정 > 손쉬운 사용 > 동작 > 동작 줄이기
  • Windows: 설정 > 접근성 > 디스플레이 > 애니메이션 표시
  • Android: 설정 > 손쉬운 사용 > 애니메이션 제거

체크리스트

애니메이션이나 전환을 추가할 때:

  • prefers-reduced-motion을 존중함
  • Reduced motion에 의미 있는 대안이 있음 (단순 비활성화가 아님)
  • 컴포지터 속성(transform, opacity)만 애니메이션함
  • will-change는 드물게 사용하고 애니메이션 후 제거함
  • 지속 시간 토큰을 일관되게 사용함
  • 깜빡이는 콘텐츠 없음 (초당 3회 이상)
  • 무한 애니메이션은 목적이 있고 중단 가능함
  • 패럴랙스 및 큰 움직임은 선택적 향상 요소임
  • 로딩 상태가 애니메이션 없이도 작동함
  • 애니메이션이 방해보다는 향상시킴

관련 스킬

  • css-author - 네이티브 @import, @layer 캐스케이딩을 사용한 최신 CSS 구성
  • progressive-enhancement - HTML 우선 개발, CSS 전용 인터랙티브 패턴
  • performance - 성능 친화적인 HTML 페이지 작성
  • accessibility-checker - WCAG2AA 접근성 준수 확인

Individual skills in this repo

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

David-Li0406/meta-skill-evloving

Browser automation with persistent page state. Use when users ask to navigate websites, fill forms, take screenshots, extract web data, test web apps, or automate browser workflows. Trigger phrases include "go to [url]", "click on", "fill out the form", "take a screenshot", "scrape", "automate", "test the website", "log into", or any browser interaction request.

David-Li0406/meta-skill-evloving

Create technical diagrams using Mermaid syntax for architecture, sequences, ERDs, flowcharts, and state machines. Use for visualizing system design, data flows, and processes. Triggers: diagram, mermaid, architecture diagram, sequence diagram, flowchart, ERD, entity relationship, state diagram, C4 model, component diagram, visualize, draw.

David-Li0406/meta-skill-evloving

Comprehensive document creation, editing, and analysis with support for tracked changes, comments, formatting preservation, and text extraction. When Claude needs to work with professional documents (.docx files) for: (1) Creating new documents, (2) Modifying or editing content, (3) Working with tracked changes, (4) Adding comments, or any other document tasks

David-Li0406/meta-skill-evloving

Complete color manipulation and green screen effects system. PROACTIVELY activate for: (1) Green screen/chromakey removal, (2) Color grading with LUTs, (3) Color correction (levels, curves, white balance), (4) Colorkey/color removal effects, (5) Hue/saturation manipulation, (6) Color space conversions (BT.709, BT.2020, HDR), (7) Color isolation effects, (8) Teal and orange look, (9) Vintage/film looks, (10) Color keying for transparency. Provides: chromakey and colorkey filters, LUT application (lut3d), curves and levels adjustment, color balance, selective color manipulation, color space handling, HDR tone mapping, professional color grading chains.

David-Li0406/meta-skill-evloving

Convert files and office documents to Markdown. Supports PDF, DOCX, PPTX, XLSX, images (with OCR), audio (with transcription), HTML, CSV, JSON, XML, ZIP, YouTube URLs, EPubs and more.

David-Li0406/meta-skill-evloving

Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

David-Li0406/meta-skill-evloving

Build with OpenAI's stateless APIs - Chat Completions (GPT-5, GPT-4o), Embeddings, Images (DALL-E 3), Audio (Whisper + TTS), and Moderation. Includes Node.js SDK and fetch-based approaches for Cloudflare Workers. Use when: implementing chat completions with GPT-5/GPT-4o, streaming responses with SSE, using function calling/tools, creating structured outputs with JSON schemas, generating embeddings for RAG (text-embedding-3-small/large), generating images with DALL-E 3, editing images with GPT-Image-1, transcribing audio with Whisper, synthesizing speech with TTS (11 voices), moderating content (11 safety categories), or troubleshooting rate limits (429), invalid API keys (401), function calling failures, streaming parse errors, embeddings dimension mismatches, or token limit exceeded.

David-Li0406/meta-skill-evloving

Comprehensive PDF manipulation toolkit for extracting text and tables, creating new PDFs, merging/splitting documents, and handling forms. When Claude needs to fill in a PDF form or programmatically process, generate, or analyze PDF documents at scale.

David-Li0406/meta-skill-evloving

Presentation creation, editing, and analysis. When Claude needs to work with presentations (.pptx files) for: (1) Creating new presentations, (2) Modifying or editing content, (3) Working with layouts, (4) Adding comments or speaker notes, or any other presentation tasks

David-Li0406/meta-skill-evloving

Comprehensive spreadsheet creation, editing, and analysis with support for formulas, formatting, data analysis, and visualization. When Claude needs to work with spreadsheets (.xlsx, .xlsm, .csv, .tsv, etc) for: (1) Creating new spreadsheets with formulas and formatting, (2) Reading or analyzing data, (3) Modify existing spreadsheets while preserving formulas, (4) Data analysis and visualization in spreadsheets, or (5) Recalculating formulas

David-Li0406/meta-skill-evloving

Download YouTube videos with customizable quality and format options. Use this skill when the user asks to download, save, or grab YouTube videos. Supports various quality settings (best, 1080p, 720p, 480p, 360p), multiple formats (mp4, webm, mkv), and audio-only downloads as MP3.

David-Li0406/meta-skill-evloving

Best practices for Remotion - Video creation in React

David-Li0406/meta-skill-evloving

Provides bidirectional translation (Chinese/English), grammar checking, and sentence polishing. Supports specific tense constraints, context-aware tone adjustment, and natural expression optimization. Outputs direct text without formatting.

David-Li0406/meta-skill-evloving

指导如何通过自定义注解(如@Unicom)标识Dubbo接口,利用BeanDefinitionRegistryPostProcessor在启动时扫描并动态注册ReferenceBean,实现RPC调用的封装。

David-Li0406/meta-skill-evloving

生成Python脚本,利用FFmpeg将图片序列按3x3布局合并,或将合并图拆分。要求使用subprocess模块执行命令,并支持用户交互式输入路径。

David-Li0406/meta-skill-evloving

SOP for extracting and analyzing promotional activity details, handling time formatting, location mapping, payment logic, and step-by-step process validation.

David-Li0406/meta-skill-evloving

Specializes in creating TikTok short video scripts using an anthropomorphic 'Chef' perspective to explain wildlife food chains and survival environments, utilizing real field footage.

David-Li0406/meta-skill-evloving

针对TikTok平台,以拟人化视角(如动物作为厨师)创作系列短视频脚本。重点介绍野生动物、食物链及生态环境,要求使用野外实拍素材,风格幽默且具有教育意义。

David-Li0406/meta-skill-evloving

Generates KWL (Know, Want to know, Learned) charts for educational videos, specifically BrainPOP, using simple 7th-grade language and short, concise bullet points.

David-Li0406/meta-skill-evloving

Tracks complex, multi-session work using the Beads issue tracker and dependency graphs, and provides persistent memory that survives conversation compaction. Use when work spans multiple sessions, has complex dependencies, or needs persistent context across compaction cycles. Trigger with phrases like "create task for", "what's ready to work on", "show task", "track this work", "what's blocking", or "update status".

관련 스킬