On this page

Pin input

When to use Pin input, when to use something else, and tokens.

Draft. Ported from the shadcn-vue Pin input and restyled with Beehexa tokens. Not yet approved; the API may still change.

Separate boxes for a short PIN, one character each.

When to use

  • A short PIN or code of fixed length.

When not to use

  • A code sent by SMS or email. Use Input OTP, which supports autofill.

Tokens

Part Tokens
Box 32 px square (size.control.default), 1 px color.border.bold on color.surface
Text font.code.default, centred
Focus the text-field focus: the edge turns color.border.focus with a 2 px inset ring of the same colour
Gap space.100