-
Notifications
You must be signed in to change notification settings - Fork 405
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adapt Tracks to High Contrast Mode. #5252
base: main
Are you sure you want to change the base?
Conversation
This patch makes the selected track use system colors for selected and hovered style. It also switches from using a box-shadow to a before pseudo element to draw the left selected indicator so it's easier to handle. We also add a few CSS variables simplify computation.
src/components/timeline/Track.css
Outdated
/* We use a colored pseudo element the track row instead of using border, so | ||
* that when we select adjacent tracks, we see just one line, without any | ||
* border on top of it. */ | ||
.timelineTrackRow::before { | ||
width: var(--selected-left-border-width); | ||
content: ""; | ||
} | ||
|
||
.timelineTrackRow.selected::before { | ||
background-color: var(--selected-left-border-color); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me know if I should revert this and only tweak the color for HCM. I'm not sure I understand the original issue with border (except that then the top gray border doesn't seem to go all the way to the left ?)
d3ee54b
to
583f389
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5252 +/- ##
=======================================
Coverage 88.62% 88.62%
=======================================
Files 308 308
Lines 28096 28096
Branches 7619 7619
=======================================
Hits 24899 24899
Misses 2983 2983
Partials 214 214 ☔ View full report in Codecov by Sentry. |
This patch makes the selected track use system colors for selected and hovered style.
It also switches from using a box-shadow to a before pseudo element to draw the left selected indicator so it's easier to handle.
We also add a few CSS variables simplify computation.
Here Screenshots track is hovered, GPU Process is selected