-
Notifications
You must be signed in to change notification settings - Fork 28.4k
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
feature: allow unsetting color theme values in settings #213512
feature: allow unsetting color theme values in settings #213512
Conversation
The PR would allow to set colors to Although in the code we check for undefined, but we have never tested how the UI would look like if certain CSS rules are not present. So in essence, this PR opens a fleabag of new configuration possibilities we have not tested. Therefore I think we should not go in the suggested direction. Instead we should look at case-by-case where we want to allow that colors can be unset. Note: it's already possible to set a color to transparent. |
Thanks for the feedback! I agree it would not be good to set colors to null, potentially causing unexpected/undefined behaviour. What do you think about instead of setting it to null, removing the property from E.g. with this color theme: {
"$schema": "vscode://schemas/color-theme",
"type": "dark",
"colors": {
"activityBar.activeBackground": "#1f2727",
"activityBar.activeBorder": "#00000000"
}
} and these settings: {
"workbench.colorCustomizations": {
"activityBar.activeBackground": null
}
} the resulting colorMap would be {
"activityBar.activeBorder": "#00000000"
} the same as if the color hasn't been defined in the color theme in the first place. Thanks again! |
Yes, using |
Due to the PR being closed, I made some changes here: https://github.com/SimonSiefke/vscode/pull/14/files. What do you think? |
I simplified the PR by allowing |
Thanks @SimonSiefke ! |
fixes #128062, fixes #170576.
unset-color.mp4