Skip to main content
PROYECTOVIVIANA

Link

The props declared for Link, generated from the types @proyecto-viviana/ui ships.

Import

import { Link } from "@proyecto-viviana/ui";

Props

Props for Link in @proyecto-viviana/ui
PropTypeDefaultDescription
variant'primary' | 'secondary''primary'The visual style of the link.
staticColor'white' | 'black' | 'auto'—The static color style to apply when the link appears over a color background.
isStandalonefalse | true—Whether the link is on its own vs inside a longer string of text.
isQuietfalse | true—Whether the link should be displayed with a quiet style.
stylesStyleString—Spectrum-defined generated classes.
UNSAFE_classNamestring | UnsafeClassName—Additional CSS class name. Use only as a last resort.
UNSAFE_styleJSX.CSSProperties—Additional inline styles. Use only as a last resort.
childrennumber | boolean | RenderedElement | ArrayElement | (string & {}) | Node | JSX.ArrayElement—The content of the link.
refHTMLElement | ((el: HTMLElement) => void) | { current?: HTMLElement | null | undefined; }—Ref for the underlying link element.
slotstring | false—A slot name for the component. HTML `slot` may be `false` to omit. solidaria-components
idstring—The unique identifier for the element. solidaria-components
onBlur(e: FocusEvent) => void—Handler that is called when the element loses focus. solidaria
onFocus(e: FocusEvent) => void—Handler that is called when the element receives focus. solidaria
onKeyDown(e: KeyboardEvent) => void—Handler that is called when a key is pressed. solidaria
onKeyUp(e: KeyboardEvent) => void—Handler that is called when a key is released. solidaria
aria-currentfalse | true | 'page' | 'step' | 'location' | 'date' | 'time' | 'true' | 'false'—Indicates the current "page" or state within a set of related elements. solidaria
aria-describedbystring—Identifies the element (or elements) that describes the object. solidaria
aria-detailsstring—Identifies the element (or elements) that provide a detailed description. solidaria
aria-labelstring—Defines a string value that labels the current element. solidaria
aria-labelledbystring—Identifies the element (or elements) that labels the current element. solidaria
hrefstring—The URL to link to. solidaria
targetstring—The target window for the link. solidaria
relstring—The relationship between the linked resource and the current page. solidaria
onPress(e: PressEvent) => void—Handler that is called when the press is released over the target. solidaria
onPressStart(e: PressEvent) => void—Handler that is called when a press interaction starts. solidaria
onPressEnd(e: PressEvent) => void—Handler that is called when a press interaction ends. solidaria
onPressUp(e: PressEvent) => void—Handler that is called when a press is released over the target. solidaria
onPressChange(isPressed: boolean) => void—Handler that is called when the press state changes. solidaria
autoFocusfalse | true—Whether to autofocus the element. solidaria
routerOptionsRecord<string, unknown>—Additional options forwarded to client-side router navigation handlers. solidaria
hrefLangstring—Hints the language of the linked resource. solidaria
downloadstring | boolean—Instructs the browser to download the URL instead of navigating to it. solidaria
pingstring—Space-separated list of URLs to ping when following the link. solidaria
referrerPolicy'' | 'no-referrer' | 'no-referrer-when-downgrade' | 'origin' | 'origin-when-cross-origin' | 'same-origin' | 'strict-origin' | 'strict-origin-when-cross-origin' | 'unsafe-url'—Referrer policy for fetches initiated by this link. solidaria
onFocusChange(isFocused: boolean) => void—Handler that is called when the element's focus status changes. solidaria

Declared in packages/viviana-ui/src/link/index.tsx.

Props marked solidaria or solidaria-components come from the headless layer underneath and behave the same in both registers. Components that wrap a DOM element also accept that element's standard attributes, which are left out here on purpose — listing them would bury the props that are actually ours.