Theme
Install with your agentnpx shadcn@4.23.1 add @goop/trail-link

Link

Free

A text link to another page or place, in running text or on its own, for React and Tailwind CSS. Free, MIT.

Switch every look and size, the inline link’s arrow, an icon before or after, long words; press it (or Enter) and the count goes up instead of leaving the page. The link goes nowhere: its press is counted and stopped.

When to use

  • A text link to another page or place, in running text or on its own.

When not to use

  • For an action that stays on the page use Button.

Installation

Paste the prompt below into your coding agent. It reads Goop's install steps, installs the part and its tokens once, then reuses this same Link on every screen instead of drawing a new one: the same height, the same focus ring, the same spacing.

Terminal
npx shadcn@4.23.1 add @goop/trail-link
PROMPT
Add the Goop Link to this project. The install steps are at https://goop.so/docs/install.md

Usage

TSX
import { Link, LinkIcon, LinkLabel, LinkIconSlot } from '@/components/ui/goop/link';

<p>
  New here?{' '}
  <Link variant="inline" href="/docs" arrow="up-right">
    Read the docs
  </Link>
</p>
  • Fits: account, record (their recipes).
  • height, width, padding, gap, corner, border, background, shadow, text, motion: add no class for these.

API reference

Options
OptionTypeWhat it does
variantdefault | ghost | inline | accent | nav | plain | outline | crumb | primary | muted | cell | meta = default
sizesm | md | lg = md
asChild?boolean = falseRender the link's look on your one child element (a router's anchor).
mark?ReactNodeThe crumb's leading icon, yours, in a 16 px box before the words.
arrow?'up-right' | 'right' = 'up-right'The inline link's arrow: up-right, or right for a single 12 px link to a page of the app.
href?string
Parts
PartWhat it is
LinkIconAn icon inside a Link, before its words, or after them with edge set to end; icon: IconName — A pack icon name; edge?: 'start' | 'end' = 'start' — Before the words (a back chevron) or after them (an arrow); box?: { w: number; h: number } — The glyph's box in CSS px, { w, h }: 14 by 14 (16 by 16 at the end) unless given
LinkLabelThe nav row's words, as the row's own box holds them (variant="nav")
LinkIconSlotThe nav row's icon slot
  • Class recipes (cva): linkVariants (Link)
  • data-slot values (to select a part by): link, link-icon, link-label

Keyboard

KeyWhat it does
EnterFollow

Accessibility

  • The part itself answers the keys above.
  • hover, active, focus-visible: the browser's own (:hover, :active, :focus-visible): write nothing

Its states are drawn from attributes and props, so assistive technology and your agent read the same thing:

StateDrawn by
expandedthe attribute data-state=open
openthe attribute data-state=open
currentthe attribute aria-current=page
disabledthe attribute aria-disabled

Motion

  • The part sets its own motion: add no transition or animation of your own.
  • How the theme moves, and how to move your own parts the same way: Motion.

Notes for AI

Give your coding agent this page as text instead of screenshots: the parts, the options, the states and the keys. An agent that reads the real part builds the real part, not a lookalike.

goop.so/themes/trail/components/link.md · the page as Markdown
Theme
Install with your agentnpx shadcn@4.23.1 add @goop/trail-link

Where would you like to start?

Free · now

The Goop plugin

A design system for your AI coding agent, so screen ten matches screen one.

/plugin marketplace add goop-so/skillsthen /plugin install goop@goopCodex, Cursor, ChatGPT, the Claude app and more: Connect Goop
FreePro

The components

Every part live, with its props, its keys and what an agent sees. Whole page and app templates, working with sample data.