Inputs

Inputs are single-line fields for a typed value: a header that names the field, a shell with room at either end for a mark or an action, and a footer that reports what the value earned. The eight blocks here are one shell doing eight jobs, among them a search that narrows a list as you type, a masked password with its rules underneath, a phone number split from its dialling code, a card number, a URL with a chosen scheme, and a read-only link with a copy control.

The shape of the value decides the field, and that shape is rarely typed. Card digits regroup once the number names its issuer, 4-4-4-4 for most and 4-6-5 for Amex, and a phone number regroups when the country changes, so part of each of those fields is a chooser rather than a keyboard. Error state then belongs only to the segment that can be wrong: a dialling code is never invalid, and tinting it because the number beside it is points at the wrong thing.

24 blocks

Multi-purpose field

The field most of a form is made of: a value with a chooser and an action welded to it

Multi-purpose field, batch

Inviting several people at once, where one typo should not cost the rest

Multi-purpose field, pending

Inviting one person and seeing the invite wait

Search field

Narrowing a list you are already looking at

Search field, scopes

Narrowing by something other than the words typed

Search field, facets

Narrowing by one category, with the counts in sight

Password field

Setting a password, where the rules have to be visible while they are being broken

Password field, ring

Setting a password with less to read

Password field, suggest

Setting a password the person should not have to invent

Phone number field

A number that means nothing without the country in front of it

Phone number field, detect

A number typed in one go, with its country

Phone number field, code

Confirming a number with the code we texted

Currency field

An amount, where the unit is as editable as the number

Currency field, convert

Showing an amount in other currencies before choosing one

Currency field, limit

A spending limit against a cap, where the cap is the point

Card field

Taking a card, where the issuer decides the shape of the number

Card field, one line

Taking number, expiry and security code in one go

Card field, card face

Taking a card where seeing it helps

Web link field

A URL going in, with the scheme chosen rather than typed

Web link field, preview

A link whose destination is worth seeing before it is saved

Web link field, tidy

A pasted link that carries tracking it should not

Share link field

A generated link coming out: read-only, because the only thing to do with it is take it

Share link field, access

A share link whose audience and lifetime are part of the choice

Share link field, stretch

A share link where the copy is the moment

01

Using Inputs

Reach for it when

  • Any short value on one line: a name, an email, an amount, a search term
  • A value with a fixed prefix or unit the person picks instead of typing
  • Password creation, where the rules must stay visible while they are being broken
  • A generated value the person only needs to copy out

Reach for something else when

  • More than a line or two of prose: a text area that grows lets people see what they wrote
  • A value from a known list: a select or combobox, since free text people must spell exactly is a validation problem you created
  • A date or a time: a picker that understands months beats a field that has to parse them
02

Where it shows up

01

Checkout card entry

A payment form where the number regroups as the issuer becomes clear and a provider mark appears at the trailing edge, so the person can see the number was understood before they submit anything.

02

International sign-up

A registration form taking a phone number from anywhere. The dialling code is a segment the person picks, the digits regroup to the country chosen, and Verify sits inside the box holding the number.

03

Directory search

A field above a list of people that filters as characters are typed, with a clear control once there is something to clear and a filter box at the trailing edge for narrowing by attribute.

04

Share link handoff

A generated URL shown read-only on a muted surface with a copy control welded to its edge, and the expiry stated in the footer so nobody sends out a link that is already dead.

03

Questions

Can placeholder text replace a field label?

No. Placeholder text disappears the moment someone starts typing, which removes the only description of the field exactly when it is being filled in, and it leaves nothing to check against when a completed form is reviewed before submission. Keep a persistent label above the field, and use the placeholder for an example of the expected format if you use it at all.

Should a text input validate on every keystroke or when it loses focus?

All blocks
The Orvain Dispatch

Premium components, free in your inbox.

Join the Orvain Dispatch and get production-ready components, free to keep: React and Vue code plus the Figma frame, yours to ship.

Just components, never spam. You can unsubscribe anytime.