Kinetic UI
Back to Introduction
SVG Animations

Morphing Divider

An organically morphing SVG wave divider to seamlessly transition between page sections.

Quick Actions
CLI Installation
npx kinetic-ui-cli@latest add morphing-divider
Morphing Divider

Dark Section

Notice how the divider fluidly animates its path to create an organic connection to the next section.

Light Section

The morphing divider bridges the gap seamlessly.

Installation

npx kinetic-ui-cli@latest add morphing-divider

How It Works

Instead of a static SVG divider, we supply an array of different SVG path data strings that share the same anchor points (e.g., corners are pinned to the bottom left/right).

We use a simple setInterval to cycle through the paths, and Framer Motion handles the complex path tweening/interpolation automatically using the animate={{ d: currentPath }} property.

Usage Guide

1. Import the Component

Import the component into your React or Next.js page:

import { MorphingDivider } from "@/components/creative/morphing-divider";

2. Implementation Example

Render the component and customize its behavior by passing props:

import { MorphingDivider } from "@/components/creative/morphing-divider";

export default function Example() {
  return (
    <div className="w-full flex items-center justify-center p-8">
      <MorphingDivider
        fill="example"
      />
    </div>
  );
}
Performance Notes
  • Uses CSS hardware acceleration via GPU transform-binds.
  • Damped interpolation minimizes paint-redraw flashes.
  • Tree-shakable import: only compiles elements requested.
Accessibility Notes
  • Full keyboard focus-ring navigation support (`Tab`/`Shift+Tab`).
  • ARIA roles mapped correctly for assistive screen readers.
  • Respects `prefers-reduced-motion` system toggles.