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.

Keyboard

Link keyboard
KeyAction
TabMoves focus to the link, and on to the next element.
EnterFollows the link.With href
Enter or SpacePresses it: it is a button with the link's look.With onPress

Screen reader

Role
link (an a), or button with onPress and no href.
Accessible name
Its text (children), or aria-label for non-text content such as a logo.
States announced
None. An external link, or one with target="_blank", adds "opens in a new tab" after its text (labels.newTab).

The "open in new" icon on an external link is decorative and hidden from assistive tech.

Focus

  • It is in the Tab order where it sits in the text.
  • Keyboard focus shows M3's focus indicator: a 3px secondary outline 2px outside the link. A standalone link also underlines while focused. Pointer presses show no ring.

Touch target

  • A standalone link, on a line of its own, has an invisible 48 × 48px touch target (TouchTarget) around its text, in an inline wrapper so the underline still reaches the text.
  • An inline or plain link is as tall as its line of text and has no extended target, as text links in running text usually do not; WCAG 2.5.8 exempts links inside a sentence. Give a plain link that stands alone (a logo, a photo tile) room of its own.

Motion

None. It has no animation: the underline appears and goes without a transition.

What you need to do

  • Links in text are underlined (inline, WCAG 1.4.1); standalone links underline on hover, focus and press. plain links never underline, so keep them for non-text content such as a logo or a photo tile, and name them with aria-label.
  • Write link text that says where it goes out of context; avoid "click here".
  • Use href to go somewhere and onPress to do something, so the element and its keys match. Translate "opens in a new tab" with labels.newTab.
  • In forced-colours mode links use the system link colour (LinkText) and are always underlined.