Skip to content

Link

Pro

Navigation written as text: in a sentence, as a name, or on its own line. Underlined in text, routed like every library link, with new-tab handling. Not an M3 component (@windmorph/react-pro).

import { Link } from '@windmorph/react-pro';

Part of Windmorph Pro, paid components on the free core, not on sale yet. See the Pro guide for what it includes and to register interest.

Props

By name or description, across the 19 props below

Events

Text

Also accepts every <a> or <button> attribute.

Spec status

Not part of Material Design 3: a Windmorph Pro component, built on M3's colour roles, type scale, shapes and motion. Its variants and configurations each link to a live example.

  • Inline, in running text

    Built

    Variant · In text

  • Standalone

    Built

    Variant · Standalone

  • Plain, around a logo or photo

    Built

    Variant · Plain

  • Colour: primary or inherit (on colour)

    Built

    Configuration · Standalone

  • Size: inherit, sm, md, lg

    Built

    Configuration · Standalone

  • External, in a new tab

    Built

    Configuration · In text

  • Text that acts: onPress without href

    Built

    Use case · Button

Theming & tokens

The colour is primary; with color="inherit" it defaults to the surrounding text's (currentColor), for links on a coloured container. Set the tokens below on a link or an ancestor. Each link carries data-tokens="wm-link", so a value set on an outer link no longer leaks into a link nested inside it. A standalone link has a 48px touch target, in an inner wrapper so the underline still reaches the text.

Link tokens
VariableDefaultPaints
--wm-link-colorvar(--md-sys-color-primary)Varies with color.The text, underline and icon (the surrounding text’s with `color="inherit"`).
--wm-link-underline-thickness1pxThe underline’s thickness.
--wm-link-underline-offset0.2emThe gap between the text and its underline, in em so it follows the type.