Skip to content

feat(F0Box): address hoverBackground review feedback#3739

Draft
Copilot wants to merge 3 commits intofeat/f0box-hover-backgroundfrom
copilot/sub-pr-3738
Draft

feat(F0Box): address hoverBackground review feedback#3739
Copilot wants to merge 3 commits intofeat/f0box-hover-backgroundfrom
copilot/sub-pr-3738

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 24, 2026

Three issues with the initial hoverBackground implementation flagged in review: missing public type export, transition-colors duplicated across every variant value, and the prop not usable via responsive breakpoint overrides.

Changes

  • index.tsx — re-export HoverBackgroundToken alongside the other token types (alphabetically after GapToken)
  • background.ts — strip transition-colors from each variant string; it was repeated 6× with no single source of truth
  • F0Box.tsx — apply transition-colors once via hoverBackground && "transition-colors" in the cn() call
  • responsive.ts — add hoverBackground?: HoverBackgroundToken to ResponsiveStyleProps
  • responsive-safelist.ts — add {sm,md,lg,xl}:hover:bg-f1-background-*-hover entries for Tailwind JIT

Responsive usage now supported

<F0Box sm={{ hoverBackground: "default" }} md={{ hoverBackground: "selected" }}>
  Hover me
</F0Box>

⚡ Quickly spin up Copilot coding agent tasks from anywhere on your macOS or Windows machine with Raycast.

AngelMsaa and others added 2 commits March 24, 2026 10:52
Add a new `hoverBackground` prop to F0Box that exposes the 6 hover
background tokens defined in @factorialco/f0-core but previously
missing from the component API:

- default (bg hover)
- secondary (bg secondary hover)
- accent-bold (bg accent bold hover)
- promote (bg promote hover)
- selected (bg selected hover)
- selected-bold (bg selected bold hover)

Each value applies the corresponding `hover:bg-f1-background-*-hover`
Tailwind class along with `transition-colors` for smooth state changes.
Copilot AI requested review from Copilot and removed request for Copilot March 24, 2026 10:56
Copilot AI changed the title [WIP] Add hoverBackground prop to F0Box with semantic tokens feat(F0Box): address hoverBackground review feedback Mar 24, 2026
Copilot AI requested a review from AngelMsaa March 24, 2026 10:58
@AngelMsaa AngelMsaa force-pushed the feat/f0box-hover-background branch from 5eb9059 to 0591663 Compare March 24, 2026 16:12
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