Skip to content

Conversation

@erik-nieh
Copy link
Contributor

Rationale

Adds radio group component

Changes

  • Radio individual component
  • Radio Group component
  • refactors some utility methods

Testing

storybook, locally, unit tests

Screenshots

Screenshot from 2026-01-05 09-17-26

@erik-nieh erik-nieh requested a review from a team as a code owner January 5, 2026 14:19
Copy link
Collaborator

@tom-vx51 tom-vx51 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

couple minor comments

<Field className="group flex items-center gap-2">
<input
type="radio"
id={inputId}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

headless handles this as long as the input is wrapped with a Field; can omit

@erik-nieh erik-nieh requested a review from tom-vx51 January 6, 2026 16:20
@erik-nieh
Copy link
Contributor Author

@tom-vx51 I updated this for your comments but made a larger refactor to make better use of Headless UI (I previously used a native <input type="radio">, it might be worth another re-read.

!disabled && "cursor-pointer",
"appearance-none",
"border",
"border-content-text-tertiary",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tom-vx51 I just wanted to note this, there is some inconsistency in figma I was going to ask Sejal about. It lists this "text-tertiary" as the border color in this case for example, it doesn't fit neatly into your color refactor.

There are some others here too that combine something like [TAILWIND SELECTOR]-[DESIGN-SYSTEM-NAME] like ring-action-primary-primary.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah for borders specifically I ran into a similar case with Button - I updated it to use the defined colors. I think it's better that we're consistent, and easy enough to add/adjust colors in the future if we're not happy with how it all looks

Copy link
Collaborator

@tom-vx51 tom-vx51 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some linter errors, one small change to restrict enum types in radio

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

guessing these files were reformatted by your IDE. I think they should be eslint-compliant after gavin's PR so can probably just omit these changes

labelClassName?: string;
}

const textSizeStyles: Partial<Record<Size, string | null>> = {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's do something similar to this https://github.com/voxel51/design-system/blob/develop/src/components/Pill/Pill.tsx#L17 to ensure type safety

@tom-vx51 tom-vx51 merged commit fe93486 into develop Jan 6, 2026
1 check passed
@tom-vx51 tom-vx51 deleted the feat/radio-group branch January 6, 2026 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants