Overview
MCP Server
Custom Shadcn Number Field for React and Tailwind CSS. A numeric input element with increment and decrement buttons, and a scrub area.
import {
NumberField,
NumberFieldDecrement,
NumberFieldGroup,
NumberFieldIncrement,
NumberFieldInput,
NumberFieldScrubArea,
} fromBrowse 6 production-ready Shadcn Number Field components for dashboards, forms, and product UI. These examples follow the Radix UI implementation with accessible primitives from the Radix stack and stay fully compatible with Shadcn Create so radius, color, and typography match your configured theme.
Browse all 6 Shadcn Number Field components for copy-ready layouts, dashboards, and forms built with Tailwind CSS in the ReUI library.
<NumberField defaultValue={0}>
<NumberFieldScrubArea label="Quantity" />
<NumberFieldGroup>
<NumberFieldDecrement />
<NumberFieldInput />
<NumberFieldIncrement />
</NumberFieldGroup>
</NumberField>Hand your agent this brief or the ReUI MCP, not a screenshot. Free to install.
When to use
When not to use
Agent notes
onValueChange receives null when the input is cleared, so type a controlled value as a number or nullaria-invalid on NumberFieldGroup to turn its border destructive; a shadcn Field marked invalid only recolors texthtmlFor at the id passed to NumberField, which Base UI sets on the inputThird-party API docs
https://reui.io/docs/components/radix/number-field.mdget_component("number-field")npx shadcn@latest add @reui/number-fieldimport {
NumberField,
NumberFieldDecrement,
NumberFieldGroup,
NumberFieldIncrement,
NumberFieldInput,
NumberFieldScrubArea,
} from "@/components/reui/number-field"
export function Pattern() {
return (
<div className="w-full max-w-48">
<NumberField defaultValue={5} min={0} max={100}>
<NumberFieldScrubArea label="Amount" />
<NumberFieldGroup>
<NumberFieldDecrement />
<NumberFieldInput />
<NumberFieldIncrement />
</NumberFieldGroup>
</NumberField>
</div>
)
}