Token导航 LogoToken导航TokenDH.com
前端设计需要联网github未标认证来源可访问clear审计通过

page-transitions页面转换

Agent Skill

用于辅助前端页面、组件、样式和交互逻辑的开发与维护。它适合让 Agent 生成或审查 React、Next.js、Vue、Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

总安装

3,362

周安装

136

GitHub Stars

35

下载量

1,055
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:page-transitions(页面转换)
来源仓库:https://github.com/dylantarre/animation-principles
仓库路径:skills/page-transitions
安装命令:
npx skills add https://github.com/dylantarre/animation-principles --skill page-transitions
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/dylantarre/animation-principles --skill page-transitions

简介

page-transitions 用于辅助前端页面、组件、样式和交互逻辑的开发与维护。

  • 它适合让 Agent 生成或审查 React、Next.js、Vue、
  • Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。
  • 使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;
  • 涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

SKILL.md

Page Transition Animation

Apply Disney's 12 animation principles to route changes, view transitions, and navigation patterns.

Quick Reference

PrinciplePage Transition Implementation
Squash & StretchEntering page elastic effect
AnticipationExit animation before enter
StagingHero elements bridge views
Straight Ahead / Pose to PoseShared element vs crossfade
Follow Through / OverlappingContent settles after nav
Slow In / Slow OutAsymmetric enter/exit easing
ArcSlide transitions with curve
Secondary ActionBackground, nav state changes
Timing200-500ms total transition
ExaggerationReserved for emphasis moments
Solid DrawingConsistent spatial model
AppealSmooth, oriented navigation

Principle Applications

Squash & Stretch: Incoming pages can have subtle elastic settle. Modal sheets bounce slightly on full open. Pull-to-navigate stretches before triggering.

Anticipation: Current page begins exit before new page enters. Slight fade or scale prepares for change. Navigation indicator updates before page swaps.

Staging: Shared/hero elements maintain context across views. Common elements (nav, footer) stay stable. New content area receives transition focus.

Straight Ahead vs Pose to Pose: Shared element transitions morph continuously (straight ahead). Crossfades swap between discrete states (pose to pose). Choose based on content relationship.

Follow Through & Overlapping: Page content settles after initial position. Staggered content entry—header, then body, then footer. Images load with subtle fade after container.

Slow In / Slow Out: Exit: ease-in (accelerate away). Enter: ease-out (decelerate in). Combined: ease-in-out for shared elements. Never linear—feels broken.

Arc: Slide transitions can curve slightly. Stack navigation implies z-depth. Circular reveals expand from trigger point.

Secondary Action: Header updates title during transition. Bottom nav indicator moves. Background color shifts. Scroll position resets with transition.

Timing: Quick transitions: 200-300ms. Standard: 300-400ms. Complex: 400-500ms. Modal/sheet: 250-350ms. Back navigation often faster than forward.

Exaggeration: Save exaggeration for key moments—onboarding, achievement. Regular navigation should be smooth, not theatrical. Users navigate frequently.

Solid Drawing: Maintain consistent spatial metaphor. If pages stack, maintain z-order. If pages slide, direction should be consistent. Users build mental model from transitions.

Appeal: Transitions should feel helpful, not impressive. Fast, smooth, oriented. Users should understand where they came from and went to.

Transition Patterns

Crossfade (Default)

.page-exit {
    opacity: 1;
}
.page-exit-active {
    opacity: 0;
    transition: opacity 200ms ease-in;
}
.page-enter {
    opacity: 0;
}
.page-enter-active {
    opacity: 1;
    transition: opacity 200ms ease-out;
}

Slide (Hierarchical)

/* Forward navigation */
.page-enter {
    transform: translateX(100%);
}
.page-enter-active {
    transform: translateX(0);
    transition: transform 300ms ease-out;
}
.page-exit-active {
    transform: translateX(-30%);
    transition: transform 300ms ease-in;
}

/* Back navigation - reversed */
.page-enter {
    transform: translateX(-30%);
}
.page-exit-active {
    transform: translateX(100%);
}

Shared Element (Hero)

// View Transitions API
document.startViewTransition(() => {
    updateDOM();
});

// CSS for specific element
.hero-image {
    view-transition-name: hero;
}
::view-transition-old(hero),
::view-transition-new(hero) {
    animation-duration: 300ms;
}

Timing Reference

Transition TypeDurationExitEnter
Crossfade200-300msease-inease-out
Slide forward300-400msease-inease-out
Slide back250-350msease-inease-out
Modal open250-350msease-out
Modal close200-300msease-in
Shared element300-400msn/aease-in-out
Tab switch150-200msinstantease-out

Navigation Patterns

PatternTransitionDirection
Drill-down (list→detail)Slide left / shared elementRight = forward
Tab barFade / slideHorizontal
Bottom sheetSlide upVertical
ModalScale + fadeZ-axis
Back buttonReverse of forwardLeft = back

Performance

  1. Use transform and opacity only
  2. Hardware acceleration: will-change: transform
  3. Reduce motion: instant transitions
  4. Test on slow devices—transitions must not block
  5. View Transitions API: native performance

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

27.25%
按下载量换算287

Codex

24.52%
按下载量换算259

OpenCode

18.49%
按下载量换算195

Gemini CLI

12.21%
按下载量换算129

Antigravity

7.58%
按下载量换算80

windsurf

3.33%
按下载量换算35

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills