Blenra LogoBlenra
Optimized for: Gemini / ChatGPT / Claude
#React

Expert AI Prompt for LayoutID Morphing on Scroll Trigger

Customize the variables below to instantly engineer your prompt.

Required Variables

layoutid-morphing-scroll-trigger-framer-motion.txt
Act as a Framer Motion Layout Animation Specialist. Design a React component architecture that leverages the powerful `layoutId` prop to seamlessly morph between two radically different component states and DOM positions ([START_ELEMENT] and [END_ELEMENT]) when a specific vertical [TRIGGER_THRESHOLD] of scroll is breached. Utilize the Intersection Observer API (or Framer's `onViewportEnter`/`onViewportLeave`) to toggle a boolean React state variable that instantly triggers the shared layout projection animation. Ensure the transition is visually seamless despite traversing different DOM hierarchies. Construct robust logic to handle the 'reverse' morphing flawlessly when the user scrolls back up past the threshold. Include explicit documentation within the code on how to mitigate layout shifts (CLS) and CSS overflow clipping issues during the exact moment of the morph.

Example Text Output

"The AI will provide code that transforms a small thumbnail into a full-width header or card as the user reaches a specific scroll depth, using Framer Motion's layout projection."

More Web Components Prompts

View all →

Frequently Asked Questions

What is the "Expert AI Prompt for LayoutID Morphing on Scroll Trigger" prompt used for?

The AI will provide code that transforms a small thumbnail into a full-width header or card as the user reaches a specific scroll depth, using Framer Motion's layout projection.

Which AI tools work with this prompt?

This prompt is optimized for Gemini / ChatGPT / Claude, but works great with ChatGPT, Claude, Gemini, and other large language models. Simply copy it and paste it into your preferred AI tool.

How do I customize this prompt?

Use the variable fields above to fill in your specific details. The prompt will auto-update as you type, ready to copy instantly.

Is this prompt free?

Yes! All prompts on Blenra are free to copy and use immediately. No account required.