Skip to content

[WEB-8227] - Align Checkbox with Figma states and lock production readiness#230

Open
codingwolf-at wants to merge 5 commits into
mainfrom
WEB-8227/checkbox-design-docs
Open

[WEB-8227] - Align Checkbox with Figma states and lock production readiness#230
codingwolf-at wants to merge 5 commits into
mainfrom
WEB-8227/checkbox-design-docs

Conversation

@codingwolf-at

@codingwolf-at codingwolf-at commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Description

  • Match Figma interaction and disabled chrome: box-level hover for unchecked / checked / indeterminate, disabled border + fill via --txt-disabled (#71777A) with white check/dash, label/icon disabled tint, and text-body-xs-regular typography.
  • Fix labeled-row layout shift on toggle (align-top on CheckboxLabel) and cover it with geometry regression stories.
  • Production-readiness cleanup: move sizing default to the ready-made (AGENTS rule 13), delete the CheckboxFieldControl passthrough, and expand Storybook coverage (hover canary, disabled canary, label-click, Sizing, disabled indeterminate).

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Improvement (change that would cause existing functionality to not work as expected)
  • Code refactoring
  • Performance improvements
  • Documentation update

snapshot

Screenshot 2026-07-15 at 5 23 08 PM Screenshot 2026-07-15 at 5 23 30 PM

Figma URL

- Introduced `LabeledRowDoesNotShiftOnToggle` story to validate that the labeled checkbox's geometry remains consistent when toggled.
- Enhanced the `States` story by adding hover states for unchecked, checked, and indeterminate checkboxes, ensuring visual feedback aligns with design specifications.
- Updated checkbox variants to include hover effects and improved alignment handling for better user experience.
- Adjusted styles in `variants.ts` and `checkbox-box.ts` to support new hover interactions and maintain consistent appearance across states.
@github-actions

Copy link
Copy Markdown

📚 Storybook preview: https://pr-230-propel-storybook.vamsi-906.workers.dev

- Added a new `Disabled indeterminate` checkbox state to the stories for better representation of checkbox states.
- Introduced `LabelClickToggles` story to demonstrate interaction testing for label clicks toggling the checkbox state.
- Updated `CheckboxProps` to set a default `sizing` of `"hug"` for better layout handling.
- Refactored `CheckboxField` and `CheckboxGroupFieldOption` to utilize the `Checkbox` component directly, simplifying the structure.
- Removed the `CheckboxFieldControl` component to streamline the checkbox field implementation.
- Enhanced documentation and comments for clarity on component usage and behavior.
@codingwolf-at codingwolf-at changed the title Add new checkbox stories and enhance hover states [WIP] [WEB-8227] - Align Checkbox with Figma states and lock production readiness Jul 15, 2026
@makeplane

makeplane Bot commented Jul 15, 2026

Copy link
Copy Markdown

Linked to Plane Work Item(s)

This comment was auto-generated by Plane

…cessibility

- Removed assertions for hover states in the `StatesCssCanary` story, clarifying that these are demonstrated in the `States` documentation instead.
- Updated the `Labeled` story to include accessibility configuration, disabling color contrast checks for disabled controls to align with WCAG guidelines.
- Enhanced comments for better understanding of hover interactions and accessibility considerations.
@anmolsinghbhatia

Copy link
Copy Markdown

Figma uses a 14px fill inset inside the 16px checkbox. This clips filled states to the padding box:

"inline-flex size-4 shrink-0 items-center justify-center rounded-sm border-sm border-icon-tertiary align-top bg-clip-padding [--node-size:0.75rem]",

@codingwolf-at

Copy link
Copy Markdown
Contributor Author

Figma uses a 14px fill inset inside the 16px checkbox. This clips filled states to the padding box:

"inline-flex size-4 shrink-0 items-center justify-center rounded-sm border-sm border-icon-tertiary align-top bg-clip-padding [--node-size:0.75rem]",

bg-clip-padding alone only inset the checked fill. The unchecked stroke was still on the 16px outer edge, so resting looked larger than filled/Figma.

What we shipped:

  • Transparent border-sm → 1px gutter (16 → 14)
  • Resting/invalid/disabled stroke → inset box-shadow on the padding edge
  • Checked/indeterminate → bg-clip-padding fill + shadow-none

Same 14px chrome in every state, 16px hit target unchanged.

- Updated the visual design of the checkbox box to align with Figma specifications, including changes to border and shadow styles.
- Enhanced comments to provide clearer explanations of the checkbox's appearance and behavior in various states (checked, indeterminate, disabled).
- Adjusted class names to ensure proper styling and interaction feedback, particularly for error states and hover effects.
- Enhanced comments to better explain the distinction between box-shadow and border-color for invalid states in the Checkbox component.
- Adjusted assertions in the `InvalidInteraction` stories to reflect the correct styling behavior of danger strokes and their relationship to checked and unchecked states.
- Improved overall clarity in the documentation of checkbox interactions, particularly regarding visual feedback for invalid states.
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.

2 participants