Specialized inputs
Not A Number
A phone field in its error state: the typed and the expected values sit side by side, so the missing digit shows and the input is never wiped.
React + Tailwind, shadcn-compatible: press “Copy for AI” and your Cursor or Claude Code agent installs it with the shadcn CLI.
What you can change
- the field name through label, the message through error, the typed value through defaultValue and the sample through example
- the normal focus color through accent
- the error colors through the --vibeui-phoneinput-006-error and --vibeui-phoneinput-006-error-soft variables
A link for your AI agent: preview, code and instructions.
Preview

Use it with AI
- 1. Copy the link.
- 2. Write to your agent in your own words and drop the link into the sentence.
- 3. The agent opens the link and installs the component from the registry.
put this on the home page as the hero:
https://vibeui.club/c/phoneinput-006?lang=en&theme=dark
Not sure where to paste it? Step-by-step guide
Show the full instructions
What the link says, spelled out. Use it when your agent cannot open links — paste this text instead.
Loading…
How to use
<Phoneinput006
label="Phone"
error="That does not look like a real number: ten digits are expected after +44."
defaultValue="+44 20 71"
example="+44 20 7123 4567"
/>A sample call. The agent installs the component itself from the registry via the “Copy for AI” link.
Settings
- Label
label· default: Phone- Error text
error· default: That does not look like a real number: after +44 there should be ten digits, but seven were typed.- Typed value
defaultValue· default: +44 20 71-23- Sample
example· default: +44 20 7123 4567- Accent
accent· default: theme colour- Background
background· default: theme colour
More in Specialized inputs
FAQ
- How do I add Not A Number with Cursor or Claude Code?
- Press “Copy for AI” on this page and paste it into your agent's chat. The instruction contains the shadcn CLI install command, the dependencies and what to keep, so the agent installs this exact component instead of recreating a lookalike.
- What does Not A Number depend on?
- No npm packages beyond React and Tailwind CSS.
- What can I change in Not A Number?
- Adapt: the field name through label, the message through error, the typed value through defaultValue and the sample through example; the normal focus color through accent; the error colors through the --vibeui-phoneinput-006-error and --vibeui-phoneinput-006-error-soft variables. Keep as installed: the local --vibeui-phoneinput-006-* palette — do not swap it for your theme tokens; keeping the typed value: clearing the field on error forces a full retype; the "typed / expected" comparison: a diagnosis without a sample never shows where the digit went missing.
- Is Not A Number free?
- Yes. The preview is open without an account; with a free account you can copy up to 20 components a month.
For developers
npx shadcn@latest add https://vibeui.club/r/pro/phoneinput-006.jsonThis command needs a signed link: sign in and open “Component source” below — it issues a working link valid for 30 minutes. All install options
Technical notes
The component is self-contained: one file, zero dependencies, the palette in the local --vibeui-phoneinput-006-* variables. Server component: useId is the only hook. The message shows the difference rather than a diagnosis: under the error text sits a two-row grid — "typed" and "expected" — aligned on the baseline, so the digits are compared by eye from top to bottom. Both samples are set in a monospace face. The state rests on aria-invalid on the field: the border, the caption (through :has() on the root) and the focus ring are coloured from it, there is no separate class. The typed value stays in the field — clearing the field on an error makes a person retype everything and leave the form.
Tags
- phone
- error
- validation
- compare
Component source
The same file your agent installs. Here in case you would rather copy it by hand.
Loading…