Duration scale
RequiredSix named timings from instant to ambient.
Utilities & motion
Shared timing, easing, offsets, reveal recipes, and subtle hover behavior for Framer Motion.
motionDurationmotionOffsetmotionEasestaggerDelayfadeUpMotioninViewFadeUpMotionsubtleHoverMotionborderHoverMotionConfigure the production component, inspect it at responsive widths, copy synchronized JSX, and share the exact state from one workspace.
Motion contract applied
Delay 0s, offset 20px, duration 0.5s.
This JSX stays synchronized with the controls and uses only public package APIs.
'use client';
import { motion } from 'framer-motion';
import { fadeUpMotion } from '@ai-created/ui';
export function Example() {
return (
<motion.section {...fadeUpMotion(0, 20, 0.5)}>
Motion follows shared timing and distance conventions.
</motion.section>
);
}
import { fadeUpMotion, inViewFadeUpMotion, staggerDelay } from '@ai-created/ui';Replace the version placeholder with the release tag your product has reviewed.
npm install --install-links "git+https://github.com/TheMarco/ai-created-ui.git#vX.Y.Z"@import '@ai-created/ui/styles/tokens.css';
@tailwind base;
@tailwind components;
@tailwind utilities;module.exports = {
presets: [require('@ai-created/ui/tailwind-preset')],
content: [
'./src/**/*.{js,ts,jsx,tsx,mdx}',
'./node_modules/@ai-created/ui/src/**/*.{js,ts,jsx,tsx}',
],
};Named regions define what belongs to the component, what remains optional, and where semantic responsibility lives.
Six named timings from instant to ambient.
Reveal and hover travel distances.
Standard cubic bezier and named Framer easings.
Serializable Framer Motion prop objects for mount and in-view entrance.
Serializable lift and border-emphasis prop objects.
The Figma-equivalent asset model, auto-layout, resizing, properties, slots, content bounds, localization, and governance contract.
Asset kind
helper
Design library name
Code-only asset
Maturity
stable
Last reviewed
2026-08-29
Canvas applicability
Functions and timing constants have no reusable Figma component geometry. Document approved motion tokens and prototype examples instead.
| Property | Type | Default | Code mapping | Options or notes |
|---|---|---|---|---|
| Delay | number | 0 | fadeUpMotion or inViewFadeUpMotion delay argument | No additional constraint |
| Vertical offset | number | 20 | y argument or motionOffset token | No additional constraint |
| Duration | number | 0.5 | duration argument or motionDuration token | No additional constraint |
| Hover distance | number | 2 | subtleHoverMotion or borderHoverMotion distance argument | No additional constraint |
Approved timing constants.
motionDurationApproved translation distances.
motionOffsetApproved easing curves.
motionEaseConsumer-owned Framer Motion element receiving helper output.
Spread returned props onto motion.*Overflow: Remove competing transforms and ambient loops.
Motion should clarify hierarchy without becoming decoration.
Overflow: Reduce step or animate groups rather than every row.
Content must remain promptly available.
No intrinsic geometry; the receiving element owns responsive behavior.
Not applicable to helper
Accountable owner
Design systems motion foundations owner
Canonical source: src/lib/motion.ts
These measurements and semantic tokens define the supported visual contract. Local overrides should preserve the same hierarchy and interaction cues.
Durations
150 / 200 / 300 / 500 / 600 / 1500ms
Reveal offsets
16 / 20 / 30px
Hover offsets
2 / 4px
Default stagger
100ms per item
--motion-fastCSS equivalent of 200ms interactions.
--motion-baseCSS equivalent of 300ms transitions.
--motion-slowCSS equivalent of 500ms reveals/cross-fades.
--color-border-strongDefault borderHoverMotion emphasis.
A component is not complete until its passive, interactive, disabled, and exceptional states remain understandable in both themes.
Semantics, accessible naming, keyboard behavior, focus and announcements are implementation requirements, not optional documentation.
No component-specific keyboard behavior. Native document behavior remains unchanged.
Use the public package API and preserve the controlled-state, native-attribute, and ref contracts described below.
import { fadeUpMotion, inViewFadeUpMotion, staggerDelay } from '@ai-created/ui';Server Component compatible
<motion.article {...inViewFadeUpMotion(staggerDelay(index))}>...</motion.article>These props and helpers are compatibility contracts. Changes require migration guidance and release notes.
| Prop | Type | Default | Contract |
|---|---|---|---|
| motionDuration | readonly timing object | shared values | Instant, fast, base, reveal, section, and ambient durations. |
| motionOffset | readonly offset object | shared values | Small, medium, large, and hover distances. |
| motionEase | readonly easing object | shared values | Standard, in-out, and out easing. |
| staggerDelay | (index, step?, base?) => number | step 0.1, base 0 | Calculates a list-item delay. |
| fadeUpMotion | (delay?, y?, duration?) => MotionProps | shared reveal values | Returns mount animation props. |
| inViewFadeUpMotion | (delay?, y?, duration?) => MotionProps | shared reveal values | Returns one-time viewport reveal props. |
| subtleHoverMotion | (distance?) => MotionProps | 2px | Returns subtle hover lift props. |
| borderHoverMotion | (distance?, borderColor?) => MotionProps | 4px, border-strong | Returns lift plus border emphasis. |
These rules keep the component recognizable across products without preventing deliberate composition.
The component should be verified as rendered UI, an interaction model, an accessibility surface, and a theme-aware visual artifact.