For AI agents: the complete documentation index is available at https://wallarm.github.io/design-system/llms.txt, the full documentation bundle is available at https://wallarm.github.io/design-system/llms-full.txt, and this page is available as Markdown at https://wallarm.github.io/design-system/components/attribute.md.

Attribute

Pairs one field's label with its value on a detail page — reach for Table when the same fields repeat across many objects, and Field when the value is being collected rather than read. The value slot takes whichever display component fits the data and hosts InlineEdit when the field is editable in place, while AttributeActions hangs a per-value menu off it.

Source · Storybook

Usage

import { Attribute, AttributeLabel, AttributeValue } from '@wallarm-org/design-system/Attribute';
import { Text } from '@wallarm-org/design-system/Text';

Examples

With description

AttributeLabelDescription adds a line that stays under the label, for a field whose name does not explain itself.

With info

AttributeLabelInfo puts the same explanation behind a hover tooltip instead, and reads correctly on either side of the label text.

The label row takes inline content of its own, here a Link out to whatever explains the field — the value slot stays reserved for the data.

Empty

Four ways a missing value can read: composed by hand, isEmpty on its own — which swaps the value for an em dash and ignores whatever children it had — and isEmpty alongside an AttributeEmptyDescription, which appears only in that state and can carry the link out to the fix.

Loading

loading skeletons both slots and ignores the children, so a panel can be laid out before its data lands; it wins over isEmpty.

Composition

The display components sanctioned inside a value — Badge, FormatDateTime, OverflowList of Tags, Ip and IpList, Link, InlineCodeSnippet, Code — each formatting the data itself rather than receiving a pre-built string.

With actions

AttributeActions turns the value into a DropdownMenu trigger: the row picks up a hover surface and the menu carries the actions that belong to that one value.

Horizontal

orientation='horizontal' sets the label beside the value in a cell clamped between 100 and 256px, so values line up down a panel.

Horizontal truncation

Horizontal cells clip with an ellipsis rather than wrapping — the label at its set width, 100px unless you widen it, and the value once its own content overruns.

Horizontal composition

The same value components in the horizontal layout, where a wide one such as IpList type='horizontal' needs its row to span both columns.

Horizontal loading

The horizontal skeleton is a 16px line against the vertical 24px, matching the single-line row it stands in for.

Horizontal empty

The same four cases side by side, with width={160} on the label so the descriptions have somewhere to sit.

Horizontal with actions

By default the value keeps its own interactivity: a link, or a snippet's copy button, still does its own job, and the menu opens from the space around it.

Horizontal with actions menu only

disableNestedInteractive renders the value inert, so a click anywhere on the row opens the menu — for values with nothing worth clicking of their own.

With inline edit

Attribute > AttributeValue > InlineEdit is the sanctioned nesting for an editable field — the value slot supplies the overflow room the editor needs, so never add your own.

Horizontal with inline edit

The same editor in a horizontal row, where it takes the width of the value cell rather than the panel.

Mixed

A plain value, an actions target and an inline editor stacked in one column: the text has to start at the same place in all three, which is what the value slot's 7px pull is for — it moves the hover box left, not the text.

Horizontal mixed

The same three hosts horizontally, where the label cell fixes the start of every value and the pull has to fit inside the 12px gap between the two cells.

Props

PropTypeDefaultDescription
loadingboolean | undefinedfalseShow skeleton placeholders instead of children
isEmptyboolean | undefinedfalseWhen true, AttributeValue renders the em-dash placeholder instead of its children, and any AttributeEmptyDescription inside the tree renders (it returns null otherwise). Ignored while loading is true (skeleton wins).
orientationAttributeOrientation | undefinedverticalLayout direction of the label and value. - vertical (default): label above value - horizontal: label on the left, value on the right
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined
data-testidstring | undefined

AttributeActions

PropTypeDefaultDescription
openboolean | undefined
defaultOpenboolean | undefined
onOpenChange((open: boolean) => void) | undefined
modalboolean | undefined
anchorPoint{ x: number; y: number; } | undefinedVirtual anchor point for positioning without a trigger element
positioningPositioningOptions | undefinedOverride default positioning config
highlightedValuestring | null | undefinedProgrammatically control which item is highlighted
onHighlightChange((details: HighlightChangeDetails) => void) | undefinedCallback when the highlighted item changes (e.g. on mouse hover)
closeOnSelectboolean | undefinedWhether selecting an item closes the menu (default true)
onRequestDismiss((event: LayerDismissEvent) => void) | undefinedCalled when another layer asks this menu to dismiss — e.g. a layer below it in the stack is removed. Call event.preventDefault() to keep the menu open.
idsElementIds | undefinedOverride the trigger element's id. Pass the same id to another compound component's ids.trigger (e.g. Tooltip, Popover) to compose their triggers on one element via nested asChild without an extra wrapper node — otherwise the outer trigger's id wins and the other component can't find its own anchor.
data-testidstring | undefined

AttributeActionsContent

PropTypeDefaultDescription
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeActionsItem

PropTypeDefaultDescription
insetboolean | undefined
disabledboolean | undefined
onSelect(() => void) | undefined
valuestring | undefinedExplicit value for programmatic highlighting via highlightedValue
titlestring | undefined
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
tabIndexnumber | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined
variant{ default: string; brand: string; destructive: string; }
data-testidstring | undefined

AttributeActionsTarget

PropTypeDefaultDescription
disableNestedInteractiveboolean | undefinedfalseWhen true, descendants are rendered inert — they cannot be clicked, focused, or read by assistive tech as actionable. Any interaction with the target (mouse or keyboard) opens the AttributeActions dropdown. Default false — descendants keep their own behavior; clicking them does not open the dropdown. The dropdown opens only when the surrounding target area is clicked.
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeEmptyDescription

PropTypeDefaultDescription
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeLabel

PropTypeDefaultDescription
widthnumber | undefinedMIN_LABEL_WIDTHWidth of the label cell in horizontal orientation, in pixels. Defaults to MIN_LABEL_WIDTH. Clamped to [MIN_LABEL_WIDTH, MAX_LABEL_WIDTH]. Ignored in vertical orientation.
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeLabelDescription

PropTypeDefaultDescription
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeLabelInfo

PropTypeDefaultDescription
titlestring | undefined
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

AttributeValue

PropTypeDefaultDescription
defaultCheckedboolean | undefined
defaultValuestring | number | readonly string[] | undefined
autoFocusboolean | undefined
idstring | undefined
tabIndexnumber | undefined
titlestring | undefined
relstring | undefined
onChangeChangeEventHandler<T, Element> | undefined

Explorer