-
-
Notifications
You must be signed in to change notification settings - Fork 366
Open
Labels
component: fieldChanges related to the field component.Changes related to the field component.
Description
Feature request
Summary
Mentioned here #3807 (comment)
<Field.Root> is currently responsible for creating a validation boundary.
However, it might be more conceptually intuitive to ensure <Field.Root> only labels one single focusable control, instead of a groups of (identical) controls.
That is:
<Fieldset.Root> {/* validation boundary for a radio group */}
<Fieldset.Legend />
<Field.Root /> {/* each radio goes in here /*}
<Field.Root />
<Field.Root />
</Fieldset.Root>Where Fieldset.Root can be a validation boundary.
The main issue here seems to be that validation boundaries aren't valid for groups of controls that aren't identical (like a Checkbox Group or especially a Radio Group).
Currently for Checkbox Group and Radio Group, the validation boundary needs to be created by <Field.Root> and labels need to be placed inside <Field.Item>:
<Field.Root> {/* validation boundary for a radio group */}
<Fieldset.Root>
<Fieldset.Legend />
<Field.Item /> {/* each radio goes in here for labeling /*}
<Field.Item />
<Field.Item />
</Fieldset.Root>
</Field.Root>Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
component: fieldChanges related to the field component.Changes related to the field component.