Communitygithub.com

ComeOnOliver/skillshub

审查功能特性,并通过有目的性的动画、微交互和动效来增强其可用性与愉悦感。

skillshub 是什么?

该技能专注于为UI功能和交互场景注入战略性动画与微交互,旨在提升用户理解、提供即时反馈并创造愉悦体验。它要求在执行前强制收集目标受众、品牌调性及性能限制等上下文信息,并建议集成前端设计技能以避免反模式。技能涵盖入场动画、微交互(按钮、表单、开关)、状态过渡、导航动效及惊喜时刻,并为每种场景提供了详细的技术实现建议,包括CSS easing曲线(推荐自然减速曲线,避免弹跳弹性效果)、JavaScript动画库(Framer Motion、GSAP)、性能优化策略(GPU加速属性)及无障碍支持(`prefers-reduced-motion`)。其核心原则是“有目的的动画”——每个动效都必须服务于清晰的功能目标,防止动画疲劳,并确保不会阻碍用户操作。

兼容平台~Claude Code~Codex CLI✓Cursor
npx skills add https://github.com/ComeOnOliver/skillshub/tree/HEAD/skills/aiskillstore/marketplace/pbakaus/animate

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

分析功能特性,并策略性地添加动画和微交互,以增强理解、提供反馈并创造愉悦感。

强制准备阶段

上下文收集(请先执行此项)

如果没有必要的上下文,您无法完成出色的工作。这些上下文包括目标受众(关键)、期望的用例(关键)、品牌个性/基调(活泼 vs 严肃、精力充沛 vs 沉稳)以及性能限制。

请尝试从当前对话或代码库中收集这些信息。

  1. 如果您找不到确切信息,并且必须根据现有设计和功能进行推断,则必须停止并{{ask_instruction}}以确认您的推断是否正确。
  2. 否则,如果您无法完全推断,或者您的信心水平为中等或更低,则必须首先{{ask_instruction}}提出澄清性问题以完善您的上下文。

在获得答案之前,不要继续。猜测会导致不恰当或过度的动画。

使用前端设计技能

请使用前端设计技能来获取设计原则和反模式。不要继续,直到它执行完毕并且您了解了所有的“应该做”和“不应该做”。


评估动画机会

分析在哪些地方使用动效可以改善体验:

  1. 识别静态区域:

    • 缺少反馈:没有视觉确认的操作(按钮点击、表单提交等)
    • 突兀的过渡:感觉突然的即时状态变化(显示/隐藏、页面加载、路由变化)
    • 不明确的关系:不明显的空间或层级关系
    • 缺乏愉悦感:功能健全但缺乏乐趣的交互
    • 错失引导:有机会引导注意力或解释行为的地方
  2. 理解上下文:

    • 个性是什么?(活泼 vs 严肃,精力充沛 vs 沉稳)
    • 性能预算如何?(移动端优先?复杂的页面?)
    • 受众是谁?(对动效敏感的用户?追求速度的高级用户?)
    • 什么最重要?(一个英雄动画 vs 多个微交互?)

如果以上任何一点从代码库中不明确,请{{ask_instruction}}

关键:尊重 prefers-reduced-motion。始终为有需要的用户提供非动画替代方案。

规划动画策略

创建一个有目的的动画计划:

  • 英雄时刻:什么是唯一的标志性动画?(页面加载?英雄区域?关键交互?)
  • 反馈层:哪些交互需要确认?
  • 过渡层:哪些状态变化需要平滑处理?
  • 愉悦层:我们可以在哪里带来惊喜和愉悦?

重要:一个精心编排的体验胜过分散在各处的动画。专注于高影响力的时刻。

实现动画

按类别系统地添加动效:

入场动画

  • 页面加载编排:交错显示元素(100-150ms延迟),淡入+滑动组合
  • 英雄区域:为主要内容设置戏剧性的入场效果(缩放、视差或创意效果)
  • 内容揭示:使用交叉观察器触发的滚动动画
  • 模态框/抽屉入场:平滑的滑动+淡入,背景淡入,焦点管理

微交互

  • 按钮反馈:
    • 悬停:细微缩放(1.02-1.05)、颜色变化、阴影增加
    • 点击:快速缩小再放大(0.95 → 1)、涟漪效果
    • 加载中:旋转器或脉动状态
  • 表单交互:
    • 输入框聚焦:边框颜色过渡、轻微缩放或发光
    • 验证:出错时抖动、成功时打勾标记、平滑的颜色过渡
  • 开关:平滑滑动+颜色过渡(200-300ms)
  • 复选框/单选框:勾选标记动画、涟漪效果
  • 点赞/收藏:缩放+旋转、粒子效果、颜色过渡

状态过渡

  • 显示/隐藏:淡入+滑动(非即时),合适的时间(200-300ms)
  • 展开/折叠:高度过渡配合溢出处理,图标旋转
  • 加载状态:骨架屏淡入、旋转器动画、进度条
  • 成功/错误:颜色过渡、图标动画、轻微缩放脉冲
  • 启用/禁用:透明度过渡、光标变化

导航与流程

  • 页面过渡:路由间的交叉淡入、共享元素过渡
  • 标签切换:指示器滑动、内容淡入/滑动
  • 轮播/滑块:平滑变换、吸附点、动量
  • 滚动效果:视差层、带状态变化的固定头部、滚动进度指示器

反馈与引导

  • 悬停提示:工具提示淡入、光标变化、元素高亮
  • 拖放:抬起效果(阴影+缩放)、放置区域高亮、平滑重新定位
  • 复制/粘贴:粘贴时短暂高亮闪烁、“已复制”确认
  • 焦点流程:高亮显示表单或工作流中的路径

愉悦时刻

  • 空状态:插图的微妙浮动动画
  • 完成的操作:五彩纸屑、勾标记的华丽效果、成功庆祝
  • 彩蛋:供发现的隐藏交互
  • 情境动画:天气效果、时间主题、季节性装饰

技术实现

对每种动画使用合适的技术:

时间与缓动

按目的划分的持续时间:

  • 100-150ms:即时反馈(按钮按下、开关切换)
  • 200-300ms:状态变化(悬停、菜单打开)
  • 300-500ms:布局变化(手风琴、模态框)
  • 500-800ms:入场动画(页面加载)

缓动曲线(使用这些,不要使用 CSS 默认值):

/* 推荐——自然减速 */
--ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);    /* 平滑,精致 */
--ease-out-quint: cubic-bezier(0.22, 1, 0.36, 1);   /* 稍快 */
--ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);     /* 自信,果断 */

/* 避免——感觉过时且俗气 */
/* bounce: cubic-bezier(0.34, 1.56, 0.64, 1); */
/* elastic: cubic-bezier(0.68, -0.6, 0.32, 1.6); */

退出动画比入场动画更快。 使用入场时长大致的75%。

CSS 动画

/* 优先用于简单、声明式的动画 */
- 对状态变化使用过渡(transition)
- 对复杂序列使用 @keyframes
- 仅使用 transform + opacity(GPU 加速)

JavaScript 动画

/* 用于复杂的、交互式的动画 */
- Web Animations API 用于程序化控制
- 用于 React 的 Framer Motion
- 用于复杂序列的 GSAP

性能

  • GPU 加速:使用 transform 和 opacity,避免布局属性
  • will-change:仅在已知的高开销动画中适量使用
  • 减少绘制:最小化重绘,在适当的地方使用 contain
  • 监控 FPS:确保在目标设备上达到 60fps

无障碍

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

绝对不要:

  • 使用弹跳或弹性缓动曲线——它们感觉过时,并且会把注意力吸引到动画本身上
  • 动画化布局属性 (width, height, top, left)——应使用 transform
  • 将反馈动画的持续时间设置超过 500ms——会感觉卡顿
  • 毫无目的地制作动画——每个动画都需要一个理由
  • 忽略 prefers-reduced-motion——这是无障碍违规
  • 对一切内容进行动画化——动画疲劳会让界面感觉令人疲惫
  • 在动画期间阻塞交互,除非是有意为之

验证质量

彻底测试动画:

  • 60fps 流畅运行:在目标设备上无卡顿
  • 感觉自然:缓动曲线感觉有机,不生硬
  • 时机恰当:既不太快(突兀)也不太慢(卡顿)
  • 减少动效模式有效:动画被适当禁用或简化
  • 不阻塞:用户可以在动画期间/之后进行交互
  • 增加价值:使界面更清晰或更令人愉悦

记住:动效应增强理解并提供反馈,而不仅仅是添加装饰。有目的地制作动画,尊重性能限制,并始终考虑无障碍。伟大的动画是无形的——它只是让一切感觉恰到好处。

Individual skills in this repo

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

ComeOnOliver/skillshub

Create stunning, animation-rich HTML presentations from scratch or by converting PowerPoint files. Use when the user wants to build a presentation, convert a PPT/PPTX to web, or create slides for a talk/pitch. Helps non-designers discover their aesthetic through visual exploration rather than abstract choices.

ComeOnOliver/skillshub

Next.js 16+ 和 Turbopack — 增量打包、文件系统缓存、开发速度,以及何时使用 Turbopack 与 webpack。

ComeOnOliver/skillshub

SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS/macOS UI best practices.

ComeOnOliver/skillshub

See, Understand, Act on video and audio. See- ingest from local files, URLs, RTSP/live feeds, or live record desktop; return realtime context and playable stream links. Understand- extract frames, build visual/semantic/temporal indexes, and search moments with timestamps and auto-clips. Act- transcode and normalize (codec, fps, resolution, aspect ratio), perform timeline edits (subtitles, text/image overlays, branding, audio overlays, dubbing, translation), generate media assets (image, audio, video), and create real time alerts for events from live streams or desktop capture.

ComeOnOliver/skillshub

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

ComeOnOliver/skillshub

Next.js 15 애플리케이션을 위한 프론트엔드 개발 가이드라인. React 19, TypeScript, Shadcn/ui, Tailwind CSS를 사용한 모던 패턴. Server Components, Client Components, App Router, 파일 구조, Shadcn/ui 컴포넌트, 성능 최적화, TypeScript 모범 사례 포함. 컴포넌트, 페이지, 기능 생성, 데이터 페칭, 스타일링, 라우팅, 프론트엔드 코드 작업 시 사용.

ComeOnOliver/skillshub

Provides Tamagui patterns for config v4, compiler optimization, styled context, and cross-platform styling. Must use when working with Tamagui projects (tamagui.config.ts, @tamagui imports).

ComeOnOliver/skillshub

Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.

ComeOnOliver/skillshub

Create high-converting, visually distinctive landing pages. Use when building marketing pages, product launches, SaaS homepages, or any single-page conversion-focused website. Guides section-by-section composition with anti-AI-slop principles.

ComeOnOliver/skillshub

Auto-loaded context for Portfolio Buddy 2 development. Use for ANY task involving: React 19 development, TypeScript, portfolio analysis features, metrics calculations, trading strategy comparison, or working with the Portfolio Buddy 2 codebase. Contains tech stack, known issues, and architectural constraints.

ComeOnOliver/skillshub

Next.js development tooling via MCP. Inspect routes, components, build info, and debug Next.js apps. Use when working on Next.js applications, debugging routing, or inspecting app structure. NOT for general React or non-Next.js projects.

ComeOnOliver/skillshub

Implement UI using Shadcn MCP (atoms/theme) and 21st.dev MCP (complex sections). Use when adding buttons, layouts, or generating landing pages.

ComeOnOliver/skillshub

A conceptual skill for building an API client in Next.js that handles JWT tokens

ComeOnOliver/skillshub

Best practices and patterns for Next.js App Router, Server Actions, and Routing in this project.

ComeOnOliver/skillshub

The Design System, Theme, and UX rules for the Physical AI Hub.

ComeOnOliver/skillshub

Comprehensive frontend development skill for building modern, performant web applications using ReactJS, NextJS, TypeScript, Tailwind CSS. Includes component scaffolding, performance optimization, bundle analysis, and UI best practices. Use when developing frontend features, optimizing performance, implementing UI/UX designs, managing state, or reviewing frontend code.

ComeOnOliver/skillshub

This document captures learnings from fixing keyboard navigation issues when floating components (Select, DropdownMenu, Popover) have CSS open/close animations.

ComeOnOliver/skillshub

Build Next.js 16 applications with correct patterns and distinctive design. Use when creating pages, layouts, dynamic routes, upgrading from Next.js 15, or implementing proxy.ts. Covers breaking changes (async params/searchParams, Turbopack, cacheComponents) and frontend aesthetics. NOT when building non-React or backend-only applications.

ComeOnOliver/skillshub

Comprehensive Framer Motion animation library for React. Covers motion components, variants, gestures, page transitions, and scroll animations. Use when adding animations to React/Next.js applications.

ComeOnOliver/skillshub

Build interfaces that resonate, not just render. This skill enforces bold, intentional

相关技能