EntityPill
Examples
Loading examples…
API
From COMPONENTS.md.
Compact entity identifier — LetterStamp + label. Renders as <button>, <a>, or <span>.
import { EntityPill } from 'achery-ui'
<EntityPill label="Acme Corp" letter="A" tone="moss" />
<EntityPill label="Open" glyph="flask" tone="rust" href="/entities/1" />
<EntityPill label="Click me" letter="C" tone="ochre" onClick={handleClick} />
<EntityPill label="Small" letter="S" tone="neutral" size="sm" />
| Prop | Type | Default | Notes |
|---|---|---|---|
label |
string |
— | Visible text |
letter |
string |
— | Single char for stamp. Mutually exclusive with glyph |
glyph |
GlyphName |
— | Glyph for stamp. Mutually exclusive with letter |
tone |
'moss' | 'rust' | 'ochre' | 'plum' | 'copper' | 'neutral' |
'neutral' |
Stamp fill + border colour |
colour |
string |
— | Hex escape hatch for stamp background |
size |
'sm' | 'md' |
'md' |
sm = 22px height; md = 28px |
onClick |
() => void |
— | Makes pill a <button> |
href |
string |
— | Makes pill an <a> |
className |
string |
— |