Skip to content
caliper ui pro docs

Mention input

A text field that turns @people and #channels into mentions.

Pro

When to use

  • Notes and comments that refer to teammates or channels.
  • You want the typed mentions returned as structured data.

When not to use

  • The text has no references; use a textarea.

Installation

terminal
pnpm dlx shadcn@latest add @caliper/mention-input

Adds its 3 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.

API reference

MentionInput

10 props
PropTypeDefault
label *string—
valuestring—
defaultValuestring""
options *readonly MentionOption[]—
onValueChange((value: string, mentions: MentionOption[]) => void)—
placeholderstring"Write a note, @someone or #channel"
disabledboolean—
namestring—
idstring—
classNamestring—

Keyboard

↓
Moves to the next item or value.
↑
Moves to the previous item or value.
Enter
Activates the focused control.
Escape
Closes or cancels, then returns focus to where it came from.
Backspace
Removes the previous character or item.

Accessibility

It exposes combobox, listbox and option semantics, with aria-expanded, aria-controls, aria-autocomplete, aria-activedescendant, aria-label and aria-selected kept in step with state.

Notes for AI

Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.

/docs/components/mention-input.md

The index of every part is at /llms.txt.

More in Tags and mentions