Skip to content
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

Calling on all plugins to use a unified preference key to set theme colors. #157

Closed
volatile-static opened this issue Oct 3, 2023 · 0 comments

Comments

@volatile-static
Copy link

I am the owner of the plugin Chartero, which has a separate iframe window. When the user needs to switch themes, they have to click two buttons(one for night and the other for Chartero), which is very inconvenient. I hope that users can change the entire interface, including all plug-in windows, by clicking a single button.
I think my plugin could use the following command to listen the switch event and change theme of itself:

Zotero.Prefs.registerObserver('night.current_theme', () => iframe.contentWindow.postMessage('switch theme');

If this is feasible, I hope other plugins can also use this option. Looking forward to hearing your suggestions on this.

@volatile-static volatile-static closed this as not planned Won't fix, can't repro, duplicate, stale Jan 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant