vimium-c
vimium-c copied to clipboard
`Auto switch between light and dark mode` does not seem to be working
Describe the bug
First of all, thanks for developing this fantastic extension.
I've enabled Auto switch between light and dark mode
under Miscellaneous Options, but it does not seem to be working as I would expect. I've used custom CSS to style the vomnibar, with a "normal" mode (light mode), and a dark mode using the .has-dark
selector. If my system is in light mode, and the vomnibar is in light mode, I would expect the vomnibar (and the rest of Vimium-C's UI) to automatically switch to dark mode when my system switches to dark mode. However, when my system switches to dark mode, the vomnibar remains in light mode, and I have to manually click the moon icon in the vomnibar toolbar to push the vomnibar into dark mode.
To Reproduce
Steps to reproduce the behavior:
- Use vomnibar in light mode while system is in light mode.
- Switch system to dark mode.
Expected result:
Vimium-C's UI (including the vomnibar) automatically switches to dark mode.
Observed result:
Vimium-C's UI (including the vomnibar) remains in light mode.
Browser, OS and Vimium C versions
- Browser: Brave 1.59.120 Chromium: 118.0.5993.88 (Official Build) (x86_64)
- Vimium C version: 1.99.99
- OS: macOS Monterey 12.7
Um, I have to agree that it's somehow weird, but, in fact in this issue Vomnibar works "as intended" :
- If you have clicked the moon/sun icon at the top-right corner of Vomnibar, then Vomnibar will remember your choice and ignore whatever your current system-level light/dark them is.
Up to now, you may only reset Vomnibar's overridden them by reloading imium C or just restarting your Chrome. Sorry for the inconvenience.
This is how to restart Vimum C itself:
Vimium C v2.0 is being developed, and I'll change this logic then.
Hi Dahan, thanks for your reply. Just to be thorough: this issue is not only affecting the vomnibar UI, but the Vimium-C UI as a whole; I've also styled the link hints and HUD with a light mode and a dark mode, and when my system switches from light to dark or vice versa, the Vimium-C UI does not switch with it. I tried restarting Vimium-C as you suggested, but it did not fix the issue.
The only way I've found to get the Vimium-C UI to switch to match my system's light/dark mode is to open the Vimium-C Options page. When I open that page, it seems to push the Vimium-C UI into my system's current mode.
I hope this information is helpful for the development of version 2.0.
- If you have clicked the moon/sun icon at the top-right corner of Vomnibar, then Vomnibar will remember your choice and ignore whatever your current system-level light/dark them is.
But why, what would be the case of it? System switched to light, web-sites switched to light, Vimium-C help page (?) switched to light, but Vomnibar keeps dirty dark?
Could an option be made to have themes synced across all UI?
For now, there is workaround : G+n hotkey, but it is very annoying and frustrating (unexpected for experienced and new users).
@davidmickelsen Sorry for this later response.
@davidmickelsen @anatoly-yakubov-betpawa You may try Vimium C v2.11.2, and now Vomnibar toggles light/dark mode on all UI components of Vimium C:
- if the button is clicked without CtrlKey or MetaKey, then toggle light/dark on a current tab
- if with Ctrl or Meta being pressed, toggle on all current tabs and future tabs
- until Vimium C notices system color theme changes, or your browser restarts.
Vimium C should succeed in following system-level color theme changes, but it takes up to 1 minute to get it.
- This is limited by some browsers especially including Chrome
- There're some ways to bypass it, while they're so expensive that I prefer querying color themes every 1 minute.