Sora UI

Hover Link

Five CSS-only link hover presets — underline wipes and block highlights — with an optional arrow that slides in on hover. No motion library required.

Loading...

All five presets stacked — the first link has no arrow, the rest slide one in on hover.

Installation

npx shadcn@latest add @soralabs/hover-link

File Structure

hover-link.tsx

Usage

Underline wipes

underline-left, underline-right, and underline-center draw a 1px rule in from that origin on hover.

Block highlights

highlight-rise grows a white block up from the baseline; highlight-wipe wipes it across from the left. Both use mix-blend-difference, so the copy inverts as the block passes over it — no color props needed.

Without the arrow

The arrow is on by default. Set withArrow={false} for plain copy links.

Props

PropTypeDefault
variant?
"underline-left" | "underline-right" | "underline-center" | "highlight-rise" | "highlight-wipe"
"underline-left"
withArrow?
boolean
true
href?
string
-
className?
string
-

When to Use

Use it for inline editorial links, footer or nav lists, and call-to-action rows where a hover state should feel deliberate without extra JavaScript. All five presets are pure CSS transitions.

Avoid it for multi-line paragraph links: the underline spans the whole anchor box, so a wrapped link looks like a block rather than per-line underlines.

Accessibility

Renders a standard <a> with the arrow marked aria-hidden. Focus is handled with focus-visible ring tokens, so keyboard users see the same affordance as hover. When target="_blank" is set, rel="noopener noreferrer" is added automatically unless you pass your own. Under prefers-reduced-motion: reduce the transitions are dropped and the hover state appears instantly.

Credits

Inspired by Skiper UI. Reimplemented for CSS transitions.

Built by Axyl. A motion-first component registry for React.

Last updated: 10/25/2026

On this page

Help keep SoraLabs moving.

Every contribution helps us build and maintain open-source tools for the community.

Sponsor on GitHub