Overview
.link styles standalone action links (pill padding, hover surface). Add .link--inline inside body copy for underlined text links. .breadcrumb wraps an <ol class="breadcrumb__list">: each ancestor is a .breadcrumb__link followed by a .breadcrumb__separator chevron.
| Part | Class | Role |
|---|---|---|
| Link | .link | Action link (anchor; can pair with .link__label) |
| Inline | .link--inline | Underlined link in paragraphs |
| Icon | .link__icon | 20px mask icon beside label |
| Label | .link__label | Visible link text |
| Breadcrumb | .breadcrumb | Navigation landmark wrapper |
| List | .breadcrumb__list | Ordered trail (<ol>) |
| Segment | .breadcrumb__link | Ancestor link + separator icon |
| Current | .breadcrumb__current | Current page label (no link) |
Prerequisites
- PimentCSS installed, Installation.
- Icons, optional
link__iconslot with your library (this doc uses Phosphor viaph()). - Typography, inline links sit in Typography body utilities (
.body-medium).
Link states
Each state is an <a href="…"> except disabled (non-focusable <span>). Doc-only .link--hover shows the spec surface; live pages use :hover and :focus-visible. The default cell shows optional link-04 and an outbound trail icon.
Structure
Use a real href on anchors. For disabled links, prefer removing the anchor or use aria-disabled="true" with tabindex="-1" on a span styled as .link--disabled.
<a href="/docs/colors" class="link"><span class="link__label">View colors</span></a>
Inline link
Inside paragraphs, add .link--inline for underline and the same action color tokens.
Read the installation guide before you customize tokens.
Link with icons
Optional pattern: link-04 before the label, outbound arrow after (16px). Use when the design calls for both link affordance and an external destination cue.
The trail arrow uses an inline SVG (ICON.linkForwardTrail()) for a clearer external-link cue at 16px.
Breadcrumb
Each ancestor is a .breadcrumb__link ending with .breadcrumb__separator. The last item is .breadcrumb__current with aria-current="page".
<nav class="breadcrumb" aria-label="Breadcrumb">
<ol class="breadcrumb__list">
<li class="breadcrumb__item"><a href="/docs" class="breadcrumb__link">
<span>Home</span>
<i class="ph ph-caret-right breadcrumb__separator" style="font-size:20px" aria-hidden="true"></i>
</a></li>
<li class="breadcrumb__item"><span class="breadcrumb__current" aria-current="page">Current page</span></li>
</ol>
</nav>
Class reference
| Class | Description |
|---|---|
.link | Action link: flex row, action color, hover surface |
.link--inline | Underlined variant for body text |
.link--hover | Doc-only hover preview |
.link--disabled | Disabled look (pair with aria-disabled) |
.link__icon | 20px icon slot |
.link__label | Link text |
.breadcrumb | Breadcrumb nav wrapper |
.breadcrumb__list | Ordered list, flex wrap |
.breadcrumb__item | List item, inline flex |
.breadcrumb__link | Ancestor link + separator icon |
.breadcrumb__separator | Chevron between segments |
.breadcrumb__current | Current page label |
Customize (Sass)
-
Link and breadcrumb spacing
Override gap, padding, and icon size before importing components.@use "pimentcss-design-system" with ( $link-gap: 0.5rem, $link-padding: 0.25rem, $link-icon-size: 1.25rem, $breadcrumb-gap: 0.25rem ); -
Rebuild CSS
Run after editing _link.scss or _breadcrumb.scss.npm run build:css
Accessibility (RGAA / WCAG)
Links and breadcrumbs
- Link purpose, link text describes the destination; avoid generic labels like "click here".
- Decorative icons,
aria-hidden="true"on icons beside visible link text. - Focus, do not remove
:focus-visible; contrast meets AA on action tokens. - Disabled, do not leave a focusable
hrefon disabled items; usearia-disabledand remove from tab order. - Breadcrumb nav,
aria-label="Breadcrumb"on<nav>; use<ol>for order. - Current page,
aria-current="page"on the last item only; ancestors stay links. - Separators, decorative chevrons use
aria-hidden="true".