Ask Rift AI
Theme: Smoke
Layout: Contained
Background: Field
Search or ask anythingAsk Rift AI
Theme: Smoke
Layout: Contained
Background: Field
Colour mode: System

Inspector input

A short text setting in one row

The name sits on the left as the field’s real label, so clicking it focuses the field, and the typed value is right-aligned in the rest of the bar. Unrecognised props reach the underlying input, so placeholder, maxLength and form registration all work.

Sizes

The size prop matches Button’s: default is 40px tall and compact is 32px.

Default
Compact

Placeholder

An empty field shows its placeholder in the tertiary text colour, right-aligned where the value will appear.

Disabled

Default
Compact

When to use it

Use the inspector input for a short value in a panel of many settings, usually inside an inspector section. For a form field, or any value that needs helper text, an error message or room to read what was typed, use Input instead.

Props

Read from the same JSDoc that ships in the package's types. A required prop is marked with an asterisk.

InspectorInput props
PropTypeDefaultDescription
label*
string
The setting's name, drawn inside the bar on the left, as the field's real <label>.
value
string
Current value.
type
"search" | "text" | "tel" | "url" | "email"
'text'
Input type: a curated subset of the single-line text types.
size
"default" | "compact"
'default'
Component size, matching Button: `default` is 40px tall, `compact` 32px (not the native character-width `size` attribute).
onValueChange
((value: string) => void)
Convenience callback receiving the value directly. Fires alongside `onChange`, which keeps the standard React event signature so form libraries work unmodified.
className
string
''
Additional CSS classes, applied to the bar rather than the <input>.

Tested keys

An automated test presses every row below, in a left-to-right and a right-to-left layout.

Inspector input follows the WAI-ARIA text field pattern.

Keys the Inspector input is tested against
KeyWhat it does
Typing
Enters text in the named field.
tsx
// From the npm package
import { InspectorInput } from 'rift-ds/components/InspectorInput/InspectorInput';

// Or as source you own, via the shadcn CLI
npx shadcn@latest add https://rift-ds.com/r/inspector-input.json

0.4 kB gzipped, with everything it imports. Peer dependencies are not counted.

For agents: the props, their allowed values and defaults, and the tested keys, as markdown or as a JSON schema.