spectrum-css icon indicating copy to clipboard operation
spectrum-css copied to clipboard

fix(rating): address inconsistent hover behavior

Open cdransf opened this issue 1 year ago • 4 comments

Description

Provides more granular control over the hover behavior of child stars within the rating component to prevent hovering in space adjacent to the component from highlighting all stars.

CSS-735

How and where has this been tested?

Verified in local Storybook story for rating component.

Validation steps

  1. Fetch the branch and run it locally or open the Storybook URL for the PR.
  2. Navigate to the rating component.
  3. Verify that hovering over rating stars is now more controlled and that hovering between stars doesn't result or all/no stars being displayed as active.
  4. Verify that changing the selected star works as expected with the hover behavior.

Regression testing

Validate:

  1. The documentation pages for at least two other components are still loading, including:
  • [ ] The pages render correctly, are accessible, and are responsive.
  1. If components have been modified, VRTs have been run on this branch:
  • [ ] VRTs have been run and looked at.
  • [ ] Any VRT changes have been accepted (by reviewer and/or PR author), or there are no changes.

Screenshots

Kapture 2024-10-02 at 11 07 46

To-do list

  • [x] I have read the contribution guidelines.
  • [x] I have updated relevant storybook stories and templates.
  • [ ] I have tested these changes in Windows High Contrast mode.
  • [ ] If my change impacts other components, I have tested to make sure they don't break.
  • [ ] If my change impacts documentation, I have updated the documentation accordingly.
  • [ ] ✨ This pull request is ready to merge. ✨

cdransf avatar Oct 02 '24 19:10 cdransf

🦋 Changeset detected

Latest commit: eaf9568281f96e65ffdfc6648b65875bf4924044

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@spectrum-css/rating Major

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

changeset-bot[bot] avatar Oct 02 '24 19:10 changeset-bot[bot]

🚀 Deployed on https://pr-3196--spectrum-css.netlify.app

github-actions[bot] avatar Oct 02 '24 19:10 github-actions[bot]

File metrics

Summary

Total size: 4.27 MB* Total change (Δ): 🔴 ⬆ 0.61 KB (0.01%)

Table reports on changes to a package's main file. Other changes can be found in the collapsed Details section below.

Package Size Δ
rating 9.99 KB 🔴 ⬆ 0.20 KB

Details

rating

Filename Head Compared to base
index-base.css 9.21 KB 🔴 ⬆ 0.20 KB (2.20%)
index-theme.css 1.39 KB -
index-vars.css 9.99 KB 🔴 ⬆ 0.20 KB (2.02%)
index.css 9.99 KB 🔴 ⬆ 0.20 KB (2.02%)
themes/express.css 1.02 KB -
themes/spectrum.css 1.01 KB -
* Size determined by adding together the size of the main file for all packages in the library.
* Results are not gzipped or minified.
* An ASCII character in UTF-8 is 8 bits or 1 byte.

github-actions[bot] avatar Oct 02 '24 19:10 github-actions[bot]

Marking this as blocked for now until we get S2 Foundations merged into main. Once we do, we'll come back to this, get it rebased against the new main stuff, and then look to get it merged in.

pfulton avatar Oct 22 '24 15:10 pfulton

Closing this — going to see if we can lift the hover logic into the S2 migration. https://github.com/adobe/spectrum-css/pull/3627

cdransf avatar Mar 17 '25 20:03 cdransf