Skip to content

feat: align radio layout and add unchecked hover state#676

Draft
isaquebock wants to merge 1 commit into
devfrom
feat/radio-hover-unchecked
Draft

feat: align radio layout and add unchecked hover state#676
isaquebock wants to merge 1 commit into
devfrom
feat/radio-hover-unchecked

Conversation

@isaquebock

Copy link
Copy Markdown
Contributor

Summary

  • RadioButton: when unchecked, hovering swaps the border to var(--primary) (mirroring the checked affordance) and hides the toggle ghost overlay so the colour stays clean.
  • RadioButton: drop the redundant data-[checked]:before:hidden override; the inner dot keeps relying on the after pseudo so the checked-disabled state continues to render correctly.
  • FieldRadio and FieldRadioBlock: render the <RadioButton> before the label/description block so the indicator sits on the leading edge — matches the Checkbox-driven fields and the Figma layout.

Test plan

  • pnpm webkit:lint && pnpm webkit:type-check
  • pnpm --filter storybook build
  • Storybook → Components / Inputs / RadioButton: hover an unchecked radio and confirm the border turns orange without the ghost overlay; checked and checked-disabled visuals unchanged.
  • Storybook → Components / Inputs / FieldRadio + FieldRadioBlock: indicator now leads the label; vertical alignment with the title remains correct.

- RadioButton: on hover (when not checked) the border switches to
  `var(--primary)` to mirror the checked affordance, and the ghost-overlay
  is hidden so the color isn't muddied
- RadioButton: keep the inner dot via `data-[checked]:after`; drop the
  pseudo `before` override that hid it
- FieldRadio + FieldRadioBlock: render the control before the label/description
  block so the indicator stays on the leading edge, matching Checkbox-driven
  fields and the Figma layout
@isaquebock isaquebock requested a review from a team as a code owner June 26, 2026 00:11
@isaquebock isaquebock marked this pull request as draft June 26, 2026 00:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant