Skip to content

<MotionFragment>

Drop-in replacement for core’s <Fragment> with Framer Motion animations. Defaults to fadeIn.

Inherits all FragmentProps, plus:

NameTypeDefaultDescription
animation?AnimationPropfadeInA MotionPreset or a MotionConfig with separate enter/exit/stagger.

In overview mode, animations are skipped and fragments render in their final visible state.

Presets

PresetEffect
fadeInOpacity 0 → 1, 0.4s.
fadeOutOpacity 1 → 0.
slideUpY +30 → 0, spring.
slideDownY -30 → 0, spring.
slideLeftX +50 → 0, spring.
slideRightX -50 → 0, spring.
scaleInScale 0.8 → 1, spring.
scaleOutScale 1 → 0.8.
blurBlur 10px → 0.
typewriterAlias of fadeIn (placeholder).

Region presets: regionFadeIn, regionScaleIn, regionSlideUp.

createMotionPreset(preset)

import { createMotionPreset } from '@react-slides/plugin-motion'
export const flipIn = createMotionPreset({
hidden: { opacity: 0, rotateY: 90 },
visible: { opacity: 1, rotateY: 0 },
transition: { duration: 0.5 },
})