i

Fieldset

Forms · researched

Groups related form controls under one legend.

molecule · Carbon: Form group · also called Form group, Legend

Carbon's "Form group" is a fieldset; GOV.UK and USWDS use "Form group" for the form-field wrapper, so the HTML name is used.

Each block is the real component from that system’s own package, in an isolated frame. They are live: hover, focus and press them. Frames are drawn on white so systems compare on one ground, and a font a system licenses only for its own site (GOV.UK’s Transport) falls back to what the system itself specifies.

Ant Design

absentAnt Design does not ship this component. Nothing is drawn in its place.

Checked: components directory listing (GitHub API), installed antd/es, Form docs. No Fieldset or legend component; only form styles mention legend for native elements.

Carbon

Form group native: yes @carbon/react 1.117.0
Variants
—
Sizes
—
States documented
—
Accessibility guidance
yes

FormGroup renders fieldset + legend (legendText required). Documented in the Form page.

1 corrected on re-read
  • urls: {"docs_url":"https://carbondesignsystem.com/components/form/usage/","code_url":"https://github.com/carbon-design-system/carbon/tree/main/packages/react/src/components/FormGroup"} → {"docs_url":"https://www.carbondesignsystem.com/building-blocks/core/components/form/guidelines","code_url":"https://github.com/carbon-design-system/carbon/tree/main/packages/react/src/components/FormGroup"} docs 200 after redirect to https://www.carbondesignsystem.com/building-blocks/core/components/form/guidelines; code URL 200

GOV.UK

Fieldset native: yes govuk-frontend 6.5.1
Variants
—
Sizes
xl, l, m, s
States documented
—
Accessibility guidance
no

Renders native fieldset and legend; legend can be styled as a page heading.

1 corrected on re-read
  • sizes: null → ["xl","l","m","s"] Legend classes govuk-fieldset__legend--xl/l/m/s in fixtures.json (docs silent)

Material Web

absentMaterial Web does not ship this component. Nothing is drawn in its place.

Checked docs/components (20 component pages), the repo top-level dirs, labs/, labs/gb/components and the installed 2.5.0 package. No fieldset or legend element; radio.md uses a role=radiogroup div by hand.

Primer

absentPrimer does not ship this component. Nothing is drawn in its place.

No standalone Fieldset component. CheckboxGroup and RadioGroup render a fieldset with legend internally (internal/components/CheckboxOrRadioGroup), but it is not exported or documented on its own. Checked: primer.style/product/components/ index, internal-components list, ui-patterns, packages/react/src tree (incl. deprecated/, experimental/, internal/).

Spectrum

Field group subset native: no
shipped, not drawn hereSpectrum documents this component, but it could not be drawn from the package used for the frames. The note below says why.
Variants
—
Sizes
—
States documented
error
Accessibility guidance
yes

Implementation: SWC 1st-gen sp-field-group and spectrum-css fieldgroup 7.2.0 only (layout of related radios or checkboxes, horizontal or vertical). It renders divs with role presentation, no fieldset or legend; the labelled-group job is done by S2/v3 Radio group and Checkbox group. Installed SWC 1.12.4 has field-group. Index disagreement (partial): it counted as ships; it is a layout wrapper, so 'subset' here.

2 corrected on re-read
  • states_documented: null → ["error"] Docs States section lists Invalid (negative help text)
  • a11y_documented: "unread" → "yes" SWC page has Accessibility section (include a label, help text, negative help text, no placeholder-as-label)

USWDS

Fieldset native: yes @uswds/uswds 3.14.0
Variants
—
Sizes
—
States documented
default
Accessibility guidance
no

Agrees with index. Style package for native fieldset; no component page. The Form page states fieldset and legend guidance (single legend required, grouping related controls).

Platform facts

Native elementfieldsetSpec: groups form controls with an optional caption from the first legend child. Attributes: disabled (disables descendant controls except those inside legend), form, name. MDN: implicit ARIA role group. APG Checkbox mixed example and radio group both use grouping with a visible label.
Baseline—
APG patternnone
ARIA role—
Shipped by4 of 7 systems

Anatomy

  1. fieldset — HTML fieldset.
  2. legend optional — Spec: fieldset content model is 'optionally, a legend element, followed by flow content'; the legend is the caption.

The seven states

default Container.
hover n/a — Not interactive.
focus n/a — Not focusable.
active n/a — Not interactive.
disabled disabled attribute disables the form controls inside (MDN, spec).
error n/a — Not defined; validity belongs to the controls.
loading n/a — Not defined by APG or HTML.

Every cell was read twice, the second time from raw sources by a separate pass. 4 of 35 fields changed on the second read — open any “corrected” note to see what it said before.