fix(Card): restore the border on the selected state#2765
Open
mnoleto wants to merge 3 commits into
Open
Conversation
The selected and selected+hover states drew their border with an undefined token (color-interactive-default), which invalidated the whole box-shadow and left the card with no border. Use color-line-strong (the value from the design) so the selected border is visible again. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: 919f1d3 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Contributor
|
can you please add a test case for it? |
✅ Deploy Preview for fondue-components ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Adds a Playwright component test verifying the selected and selected+hover states render a border (inset box-shadow on the overlay) in the color-line-strong token, and that a non-selected card has none. Catches the regression where an undefined token removed the border. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Locator is not exported from @playwright/experimental-ct-react; import it from @playwright/test (type-only) so the test type-checks. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
Author
Done! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Selected card lost its border
When you select a card, it's supposed to get a border to show it's selected — and the same when you hover a card that's already selected. Right now that border isn't there at all: selecting a card (or hovering a selected one) leaves it with no border, so there's no clear indication that it's the selected one.
This brings the selected border back, using the color-line-strong value from the design.