nienow / sn-excalidraw

Standard Notes Extension that uses the Excalidraw Editor
https://nienow.github.io/sn-excalidraw/demo.html
MIT License
5 stars 4 forks source link

Notes always open in dark mode #34

Open phipsgabler opened 1 week ago

phipsgabler commented 1 week ago

I.e., every time I open an Excalidraw note, it starts in dark mode, no matter what my theme is or what I previously selected. When I toggle light mode, open another note, and then go back to the note in which I chose the light mode, it starts in dark mode again.

I use the default light theme for Standard Notes, which is light. The behaviour of the extension should be to correctly detect a dark theme (which it currently doesn't seem to do), and at least remember the choice of mode per note.

nienow commented 3 days ago

There isn't a good way to tell which theme standard notes is using. They only way to do it would be to delay rendering until CSS is received, and then check the variables. And even then, the user might be using a theme that is in between dark and light, and I didn't want to guess what they want.

However, the latest version is supposed to be saving the user's preference, when they click Light Mode or Dark Mode, and use that for next time. If you see the button on the bottom of the main screen, you have the new version:

image

Otherwise, if you are selecting light mode in the menu, you are on an older version, and it doesn't save your preference. Try uninstalling and reinstalling the extension if you are on an older version.