-
Notifications
You must be signed in to change notification settings - Fork 31k
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
Switch to using CSS #165185
Switch to using CSS #165185
Conversation
|
||
.monaco-workbench .part.editor > .content .gettingStartedContainer button:hover { | ||
background: var(--vscode-welcomePage-tileHoverBackground); | ||
outline-color: var(--vscode-contrastActiveBorder); |
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.
This is causing me trouble, not sure what the solution is. This color token is null in the dark, and light theme. Meaning that normally in the registerThemeingParticipant
it wouldn't be set at all, but here it seems to default to white causing a difference in styling. I tried playing around with it for awhile, but don't know a good fix to keep the current style we have now. Should we define this for the other theme types too? That feels unnecessary
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.
You can use var(--name, <fallback>
) like outline-color: var(--vscode-contrastActiveBorder, inherit)
or so. That is still extra styling but not visible
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.
Hmm. That didn't change anything. Maybe I need a set of fresh eyes as I can't find a difference besides that line
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.
🤔 I haven't tried it myself but that's how it should work... https://developer.mozilla.org/en-US/docs/Web/CSS/Using_CSS_custom_properties#custom_property_fallback_values.
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.
The fallback works, it's just there's no way to act like the rule just isn't there if the variable is not defined. I've fallen back to the focus border color which is what would normally be applied anyways if the value isn't set. Just something to be aware of.
My piece of #165169