Text
Split Hover
Splits text into characters and animates stacked layers on hover for a seamless swap. Framework-agnostic Custom Element.
- lit
- gsap
Preview
Characters split into two stacked layers that swap on hover.
Attributes
Installation
pnpm dlx shadcn@latest add https://motion-kit-astro.vercel.app/r/split-hover.json Usage
---
import "@/components/motion-kit/split-hover-element.ts";
---
<motion-split-hover text="Hover me"></motion-split-hover> API Reference
| Attribute | Type | Default |
|---|---|---|
text The text content to display and animate. | string | "" |