Sophic Interface Systems
Components

Field

A labeled control with optional help text and errors.

Choose a unique username for your account.

States

Rest, filled, error, success, and disabled. Fill encodes availability; edge encodes interaction. Hover only strengthens the edge — never the fill. Focus, error, and success share 1px edge + 3px halo geometry. Disabled is the only state that changes fill.

Looks good.

Email
Own account€3,250.40

You can change this later.

Examples

Textarea

Select

Controls lose their own border inside a field — the card carries the frame.

Checkbox

Horizontal orientation puts the control beside the label. Wrap label and description in FieldContent.

A short monthly email. No marketing.

Radio Group

Each option is its own horizontal field inside a FieldSet.

Statement frequency

Bundled with performance notes.

Choice card

Wrap the field in its own FieldLabel to make the whole card clickable.

Validation error

Mark the wrapper with data-invalid and the control with aria-invalid. Help text and the error stack below the card — description first, then the message.

In a dialog

The same Field card inside a dialog — rest and invalid.

Locked

data-locked uses the same muted fill as disabled, but the field can be unlocked. Put the value in FieldLockedValue with onUnlock (default label Change). The unlock control keeps cursor-pointer; the card does not use not-allowed.

<Field data-locked>
  <FieldTitle>Email</FieldTitle>
  <FieldLockedValue onUnlock={() => goTo("email")}>
    [email protected]
  </FieldLockedValue>
</Field>

Read-only

A value the person can see but not change here, such as the only account an order can use. FieldReadOnly renders static text inside a hairline outline (not an <input>), so it never takes focus or reads as an editable text box. end holds muted supporting content, such as a balance. There is nothing to unlock: use FieldLockedValue when the value can change elsewhere in the flow.

<Field aria-labelledby="account-label">
  <FieldLabel id="account-label">Account</FieldLabel>
  <FieldReadOnly end="€3,250.40">Own account</FieldReadOnly>
</Field>

Disabled

Disable the control (or set data-disabled on the Field). Same muted fill as locked, but permanently non-interactive — cursor: not-allowed, and any unlock control is hidden. Not an opacity fade.

Success

Mark the wrapper with data-success and put the message in FieldDescription below the card (same slot as help; error replaces it when both would show).

Field group

Stack related fields with FieldGroup. Each field keeps its own card.

We'll send updates to this address.

Experimental condensed

variant="experimental-condensed" tightens padding around the card and the control metrics inside it.

Default

Choose a unique username for your account.

experimental-condensed

Choose a unique username for your account.

Playground

<Field className="max-w-sm"> <FieldLabel htmlFor="username">Username</FieldLabel> <Input id="username" placeholder="sophic" /> <FieldDescription>Choose a unique username for your account.</FieldDescription></Field>

Usage

import {
  Field,
  FieldDescription,
  FieldError,
  FieldLabel,
  FieldLockedValue,
  FieldReadOnly,
} from "@sophic/portal-ui/components/ui/field";
<Field>
  <FieldLabel htmlFor="username">Username</FieldLabel>
  <Input id="username" />
  <FieldDescription>Choose a unique username.</FieldDescription>
  <FieldError errors={[fieldState.error]} />
</Field>

A FieldLabel written as a direct child of a stacked Field renders above the card. There is no in-card label. Help text and errors written as direct children of Field render below the card — not inside the input container. Nested helpers (for example inside FieldContent on a checkbox row) stay with their row.

The module also exports FieldGroup, FieldSet, FieldLegend, FieldContent, FieldTitle, FieldLockedValue, FieldReadOnly, and FieldSeparator for composing larger form sections. This is the required wrapper for form controls in app code.

See Field Composition for how controls align inside a Field and the live showcase.

Shape: pills press, 12px holds a value

ShapeControlsWhy
Pill (fully round)Buttons, the segmented control, in-field chips (currency picker, Max), trailing icon buttons (clear, reveal)You press or toggle them
12px (--field-radius)Every field card (text, password, textarea, select, combobox, date picker, number, currency), radio and checkbox choice cardsThey hold a value or contain text

A dropdown that is the field itself (Order type) takes the field corner. A dropdown inside a field (the currency picker) is a chip, so it's a pill.

Submit buttons

Keep the submit button enabled. Validate on submit, then live: the first press shows every error under its field, and each clears as it's fixed. Disable it only while the request is in flight (loading). Never disable it because the form is empty or invalid: a disabled button gives no reason, can't be focused, and sticks when autofill skips the change event.

Props

Every subcomponent also accepts its native element's attributes — <div> for Field, <fieldset> for FieldSet, <legend> for FieldLegend, and so on.

Field

Prop

Type

Default

FieldLegend

Prop

Type

Default

FieldError

Renders nothing when there are no errors, a single message for one error, and a list for several.

Prop

Type

Default

FieldLockedValue

Use inside Field data-locked. Omit onUnlock (or put the Field in data-disabled) when the value must stay permanent.

Prop

Type

Default

FieldReadOnly

Use inside a plain Field (not data-locked or data-disabled) with a FieldLabel pointing at its id.

Prop

Type

Default

The rest

FieldGroup, FieldSet, FieldContent, FieldTitle, and FieldDescription have no props of their own. FieldLabel forwards to Label and takes htmlFor. FieldSeparator renders its children as text inside the divider line.

Tokens

Field reads --field-* from the Base System (with fallbacks so apps without those tokens keep the previous look). Nested controls switch to --field-control-* inside the card.

Changelog

  • 25 November 2026: New FieldReadOnly for a value the person can see but not change, in normal ink with optional muted end content. Full notes
  • 23 November 2026: A Select trigger takes the card's inline padding, so its menu matches the field's width and left edge. Full notes
  • 9 October 2026: Labels above an input keep the 1.4 line height (about 20px), set on --field-label-leading so the portal and docs match. A brief switch to line height 1 left the label on the input. Full notes
  • 9 October 2026 — Hover deepens the fill; focus edge is lighter. Full notes
  • 8 October 2026: FieldDescription persistent keeps context such as an available balance under the box when an error shows.
  • 8 October 2026 — Labels sit above the box, 14px medium, ink on focus; 12px corners and 14px / 10px padding; no in-card label option. Full notes
  • 8 October 2026 — Help text and errors align with the card edge, 6px above and 10px below (none extra inside FieldGroup); invalid labels turn red. Full notes
  • 3 October 2026 — Dark rest fill is a 4% white lift over the parent; disabled sinks; locked keeps rest fill with muted value text. Full notes
  • 3 October 2026 — Control edges use --control-border, a step above layout --outer-border. Full notes
  • 3 October 2026 — Padding is --spacing × --density; height is the line-box plus padding. Full notes
  • 3 October 2026 — Choice radios and checkboxes sit on the label line with a 12px gap. Full notes
  • 3 October 2026 — Choice cards zero nested Field chrome so one surface owns fill, hover, and focus. Full notes
  • 3 October 2026 — Dark checked choice cards use fill and the control, not a white ring. Full notes
  • 1 October 2026 — Fill vs edge: hover is edge-only; focus / error / success share 1px + 3px halo; disabled is the only permanent fill change. Locked (data-locked + FieldLockedValue) shares that fill but can unlock. Full notes
  • 14 September 2026 — Rest, hover, focus, filled, and error match the Base System input states (brand focus rim, muted label, error below). Full notes
  • 18 August 2026 — Styles live in a CSS module; look and tokens unchanged. Full notes
  • 29 July 2026 — Field hairline tracks Card’s --card-ring (radius stays 16px). Full notes

On this page