motion-wrapper
remotionui/motion-wrapperFreeUtility
Inline wrapper for enter/exit animations (avoids AbsoluteFill overlap)
Install it
npx shadcn@latest add https://remotionui.com/r/motion-wrapper.jsonSource
1import type { CSSProperties, ReactNode } from "react";23export type MotionWrapperProps = {4 children: ReactNode;5 style?: CSSProperties;6 className?: string;7 /**8 * Fill the parent's width instead of shrink-wrapping the child. Needed when9 * the child sizes itself from its container — a bar, a justified headline —10 * because an inline-block parent collapses to the content width.11 */12 block?: boolean;13};1415/**16 * Inline wrapper for enter/exit animations.17 * Use this instead of AbsoluteFill so siblings stack in flex/grid layout.18 * @see skills/remotion/remotion-create/video-layout.md19 */20export const MotionWrapper: React.FC<MotionWrapperProps> = ({21 children,22 style,23 className,24 block = false,25}) => (26 <div27 className={className}28 style={{29 display: block ? "block" : "inline-block",30 ...(block ? { width: "100%" } : {}),31 verticalAlign: "top",32 ...style,33 }}34 >35 {children}36 </div>37);
More from remotionui
All 127 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| ai-composer-utilsai-composer-utils | remotionui | Utilities | Free | no deps | |
| audio-viz-utilsaudio-viz-utils | remotionui | Utilities | Free | no deps | |
| caption-utilscaption-utils | remotionui | Utilities | Free | no deps | |
| chart-utilschart-utils | remotionui | Utilities | Free | no deps | |
| code-syntaxcode-syntax | remotionui | Utilities | Free | no deps | |
| layoutlayout | remotionui | Utilities | Free | no deps | |
| map-utilsmap-utils | remotionui | Utilities | Free | no deps | |
| media-utilsmedia-utils | remotionui | Utilities | Free | no deps |
