Skip to content

Commit

Permalink
Add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Sana Malik committed Jan 30, 2025
1 parent 56e6602 commit 07ceb2c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/@react-spectrum/labeledvalue/docs/LabeledValue.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,14 @@ By default, the list is displayed as a conjunction (an "and"-based grouping of i
<LabeledValue label="Interests" value={['Travel', 'Hiking', 'Snorkeling', 'Camping']} formatOptions={{type: 'unit'}} />
```

### Components

The value can be a component and will be rendered as provided. Components cannot be editable.

```tsx example
<LabeledValue label="Website" value={<Link href="https://www.adobe.com/">Adobe.com</Link>} />
```

## Labeling

A visual label must be provided to the `LabeledValue` using the `label` prop.
Expand Down

0 comments on commit 07ceb2c

Please sign in to comment.