Files

66 lines
1.2 KiB
TypeScript

export const DURATION = {
fast: 0.15,
standard: 0.3,
reveal: 0.5,
slow: 0.8,
}
export const EASING = {
ease: [0.25, 0.46, 0.45, 0.94],
easeOut: [0.33, 1, 0.68, 1],
}
export const VARIANTS = {
// Scroll reveal: fade + slight upward translate
reveal: {
hidden: { opacity: 0, y: 20 },
visible: {
opacity: 1,
y: 0,
transition: { duration: DURATION.reveal, ease: EASING.easeOut },
},
},
// Hover lift: card elevation on hover
cardHover: {
rest: { y: 0 },
hover: {
y: -8,
transition: { duration: DURATION.fast },
},
},
// Stagger container for card grids
container: {
hidden: { opacity: 0 },
visible: {
opacity: 1,
transition: {
staggerChildren: 0.1,
delayChildren: 0.1,
},
},
},
// Child item for stagger
item: {
hidden: { opacity: 0, y: 20 },
visible: {
opacity: 1,
y: 0,
transition: { duration: DURATION.standard },
},
},
// Pulse: live indicator dot
pulse: {
scale: [1, 1.2, 1],
opacity: [0.6, 1, 0.6],
transition: {
duration: 2,
repeat: Infinity,
ease: 'easeInOut',
},
},
}