Skip to content
PixiKit

Expand Frame

A framed image or video that opens up to full bleed as you scroll: the title lifts away, the media eases back from its zoom, and overlay content fades in once it fills the stage.

pixikit.com/docs/effects/expand-frame

Customize

Media type
Start width42%
Start height58%
Start radius24px
End radius0px
Media zoom1.35
Scroll distance1.2
Hold distance0.35
Smoothing0.10s
Overlay scrim0.45
Use window scroll
Enabled

Props

20
NameTypeDefaultDescription
srcstring""Image or video address shown inside the frame.
mediaType"image" | "video""image"Whether the source is an image or a looping muted video.
posterstring""Poster frame used while a video loads.
altstring""Alt text for the image.
titlestring""Headline held over the frame that lifts away as the media takes over.
scrollHintstring""Small cue under the resting frame that fades away as soon as the scroll begins.
startWidthnumber42Frame width before expanding, as a percent of the stage.
startHeightnumber58Frame height before expanding, as a percent of the stage.
startRadiusnumber24Corner radius of the resting frame, in pixels.
endRadiusnumber0Corner radius once fully expanded, in pixels.
mediaZoomnumber1.35How far the media is zoomed in at rest; it eases back to 1 as the frame opens up.
scrollDistancenumber1.2Scroll length of the expansion, in multiples of the stage height.
holdDistancenumber0.35Extra scroll the frame stays pinned at full bleed before releasing.
smoothingnumber0.1Follow time in seconds; 0 locks the frame exactly to the scrollbar.
overlayScrimnumber0.45Strength of the gradient scrim that fades in to keep overlay content readable.
useWindowScrollbooleanfalseDrive the expansion from the page scroll instead of the component's own scroller.
enabledbooleantrueEnable or disable the expansion.
childrenReactNodeNoneContent that fades in over the media once it reaches full bleed.
classNamestringNone
styleCSSPropertiesNone

More interaction effects in Pro

View all

Related