Field & Input Group

Fields, labels, descriptions, errors and input groups with addons — native inputs styled by the system.

Available in
  • Angular: available
  • Vue: available
  • React: available
  • React Native: available

Usage

Shown to people you share notes with.

https://
GB
Notify me about

Import

ts
import {
  SoneFieldContentDirective,
  SoneFieldDescriptionDirective,
  SoneFieldDirective,
  SoneFieldErrorDirective,
  SoneFieldGroupDirective,
  SoneFieldLabelDirective,
  SoneFieldLabelOptionalDirective,
  SoneFieldLegendDirective,
  SoneFieldSeparatorContentDirective,
  SoneFieldSeparatorDirective,
  SoneFieldSetDirective,
  SoneFieldTitleDirective,
  SoneInputGroupAddonDirective,
  SoneInputGroupControlDirective,
  SoneInputGroupDirective,
  SoneInputGroupTextDirective,
  SoneLabelDirective,
} from "@surface-one/angular/input";

API reference

SoneFieldContentDirectiveDirective

Selector
[soneFieldContent]

SoneFieldDescriptionDirectiveDirective

Selector
[soneFieldDescription]

SoneFieldDirectiveDirective

Selector
[soneField]
Inputs
NameType Default
orientationFieldOrientation"vertical"
invalidbooleanfalse
disabledbooleanfalse

SoneFieldErrorDirectiveDirective

Selector
[soneFieldError]

SoneFieldGroupDirectiveDirective

Selector
[soneFieldGroup]
Inputs
NameType Default
variant"default" | "choices""default"

SoneFieldLabelDirectiveDirective

Selector
[soneFieldLabel]

SoneFieldLabelOptionalDirectiveDirective

`[soneFieldLabelOptional]` — the quiet "Optional" marker inside a field label: `<label soneFieldLabel>Notes <span soneFieldLabelOptional>Optional</span></label>`.

Selector
[soneFieldLabelOptional]

SoneFieldLegendDirectiveDirective

Selector
legend[soneFieldLegend]
Inputs
NameType Default
variant"legend" | "label""legend"

SoneFieldSeparatorContentDirectiveDirective

Selector
[soneFieldSeparatorContent]

SoneFieldSeparatorDirectiveDirective

Selector
[soneFieldSeparator]

SoneFieldSetDirectiveDirective

Selector
fieldset[soneFieldSet]

SoneFieldTitleDirectiveDirective

Selector
[soneFieldTitle]

SoneInputGroupAddonDirectiveDirective

Selector
[soneInputGroupAddon]
Inputs
NameType Default
alignInputGroupAddonAlign"inline-start"

SoneInputGroupControlDirectiveDirective

Selector
input[soneInputGroupInput], textarea[soneInputGroupTextarea]

SoneInputGroupDirectiveDirective

Selector
[soneInputGroup]
Inputs
NameType Default
invalidbooleanfalse
disabledbooleanfalse
fill

Take the free space of a flex row (`flex: 1`, may shrink) — a search box beside buttons.

booleanfalse
variant

`filled`: a grey fill instead of a border (the focus ring stays). A filled field has no 3:1 boundary of its own, so keep it to search boxes that a leading search glyph and a placeholder identify.

InputGroupVariant"default"

SoneInputGroupTextDirectiveDirective

Selector
[soneInputGroupText]

SoneLabelDirectiveDirective

Selector
label[soneLabel], span[soneLabel]