Skip to content
WunderUI
All effectsForms

Ink Bar

The bar travels and resizes to the label it lands on.

Pure CSSFormsPro

Meant for

TabsSegmentNavbar

Usage

On a Tabs

Click the tabs. Width and position change together, which is what makes the underline feel attached to the word rather than sliding past it — both as one transform (translateX and scaleX on a 1px bar), so nothing re-lays out. In a product it is a 250 ms transition: set --wm-x and --wm-w to the active trigger's left edge and width, and clicking through the tabs fast retargets it from wherever it is. The Tabs' own line indicator is hidden and the bar takes its place.

The class is wm wm-ink-bar — the first half is the marker the trigger and reduced-motion rules hook into, the second is the effect.