fix(splitview): add missing is-focused class#2932
fix(splitview): add missing is-focused class#2932marissahuysentruyt merged 1 commit intospectrum-twofrom
Conversation
|
|
🚀 Deployed on https://pr-2932--spectrum-css.netlify.app |
File metricsSummaryTotal size: 1.43 MB* 🎉 No changes detected in any packages * Size is the sum of all main files for packages in the library.* An ASCII character in UTF-8 is 8 bits or 1 byte. |
4cb17f5 to
b2c42c4
Compare
c68f4e3 to
d2272ea
Compare
b2c42c4 to
dbecd0b
Compare
| { | ||
| testHeading: "Focused", | ||
| isFocused: true, | ||
| testHeading: "Resizable/collapsible", |
There was a problem hiding this comment.
Resizable and collapsible are technically two different things in SWC, where collapsible can in fact collapse all of one of the panes and resizable maintains to min-width for the panes. However, the collapsible variant will also need the gripper (which is only added in isResizable splitviews right now.)
There was a problem hiding this comment.
We could definitely come back to make sure the active WHCM color is what we want, and clean up the args for this component (i.e. isCollapsible should also add the gripper, not just isResizable). I didn't want to get into too much of that with this PR quite yet, but I can make a ticket sort of like an "S2 migration."
| [`${rootClass}-splitter`]: true, | ||
| ["is-draggable"]: isResizable, | ||
| "is-focused": isFocused, | ||
| ["is-active"]: isActive, |
There was a problem hiding this comment.
We have styles for the active gripper, so adding the isActive arg here to capture in the tests.
castastrophe
left a comment
There was a problem hiding this comment.
This is a great update that improves test coverage. I'm cool if you want to move this forward.
dbecd0b to
0b8e719
Compare
📚 Branch previewPR #2932 has been deployed to Azure Blob Storage: https://spectrumcss.z13.web.core.windows.net/pr-2932/index.html. |
- fixes orientation of top & bottom test cases to be vertical - adds isActive to template for testing and adds isActive to test cases to accurately update baselines for VRTs
0b8e719 to
9410aa0
Compare
Description
Several eons ago, we noticed that the argTypes for the Split view template needed to be adjusted to showcase the Horizontally Focused story appropriately. In a similar vein, I noticed that our active styles for the collapsible and resizable variants weren't captured in the testing grid. This PR updates all of that.
Jira/Specs
CSS-856
How and where has this been tested?
Please tag yourself on the tests you've marked complete to confirm the tests have been run by someone other than the author.
Validation steps
is-focus-visibleclass/state on the.spectrum-SplitView-splitter .is-draggableelement. (@cdransf)gray-800for the splitter and the gripper elements. (@cdransf)focus-indicator-colorfor the splitter and the gripper elements. (@cdransf)Regression testing
Validate:
Screenshots
To-do list