Closed cyrilf closed 2 years ago
We could have the original approach as a fallback when window.activeColorTheme.kind
is not presented.
@antfu yes sure, I can update the PR and do that.
But before I do so, why wouldn't window.activeColorTheme.kind
be presented? (I never developed any vscode extension before)
I don't think the API exists when I made this plugin. So for who knows reason someone might still use an older version of VS Code - having the fallback just to be safe.
Alright, got it. PR updated :sparkles:
Thanks!
:bulb:
Issue
When using a theme that doesn't contain
dark | black | light
in its name, theauto
color detection was failing. (for example: 'Noctis Lux')Solution
Use the
window.activeColorTheme.kind
provided byvscode
~instead~ in priority of the regex matching on the theme's name.Related to #6