Skip to content

Add RadioButtonField and RadioGroupField for CommandForm#85

Merged
einari merged 2 commits into
mainfrom
copilot/add-radio-button-support
May 22, 2026
Merged

Add RadioButtonField and RadioGroupField for CommandForm#85
einari merged 2 commits into
mainfrom
copilot/add-radio-button-support

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 22, 2026

Adds PrimeReact-based radio button support to the CommandForm field set, matching the pattern established by existing fields.

Added

  • RadioButtonField: single PrimeReact RadioButton bound to a specific buttonValue; multiple instances on the same command property form a natural radio group (#issue)
  • RadioGroupField: renders a full radio button group from an options array with optionLabel/optionValue props (mirrors DropdownField API); supports 'vertical' (default) and 'horizontal' layouts (#issue)
  • Storybook stories for both fields, including entries in the AllFields showcase (#issue)
  • Documentation pages for RadioButtonField and RadioGroupField with props tables and usage examples (#issue)
// Single buttons sharing a property form a group
<RadioButtonField<MyCommand> value={c => c.size} buttonValue="small" label="Small" />
<RadioButtonField<MyCommand> value={c => c.size} buttonValue="large" label="Large" />

// Or use RadioGroupField with an options array
<RadioGroupField<MyCommand>
    value={c => c.size}
    options={sizeOptions}
    optionLabel="label"
    optionValue="id"
    layout="horizontal"
/>

Copilot AI linked an issue May 22, 2026 that may be closed by this pull request
Copilot AI changed the title [WIP] Add radio button and group support for command fields Add RadioButtonField and RadioGroupField for CommandForm May 22, 2026
Copilot finished work on behalf of einari May 22, 2026 06:56
Copilot AI requested a review from einari May 22, 2026 06:56
@einari einari marked this pull request as ready for review May 22, 2026 07:02
@einari einari added the minor label May 22, 2026
@einari einari merged commit 6cb9afe into main May 22, 2026
3 checks passed
@einari einari deleted the copilot/add-radio-button-support branch May 22, 2026 07:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Radio button / group support for Command Fields

2 participants