You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[ENHANCEMENT] Show library documentation with a light or dark theme depending on the active color theme #88
Is your enhancement request related to a problem? Please describe.
Currently, the library documentation is shown as black text on a white background regardless of the active color theme. With a dark color theme the contrast between the code and the documentation is unpleasant.
Describe the solution you'd like
If a dark (light) theme is selected the documentation should be shown with a dark (light) theme.
Describe alternatives you've considered
I opened an issue in the RF repo to add a stylesheet parameter to libdoc to be able to specify the stylesheet used when generating the documentation in HTML format.
Additional context
The RF LS extension already offers this functionality:
The theme of the documentation is sadly dependent on the OS theme, if you switch the windows color theme to dark mode, you will get a dark documentation and otherwise.
This is handled in the CSS of the library, which I can't change at the moment.
But I'm working on it.
Yeah, you are right. I checked the code of the LS extension. They just replace "prefers-color-scheme: dark" based on vscode.window.activeColorTheme.kind. It is a quick way to achieve the desired result, but I think that supporting both the OS-level and the VS Code-level color theme settings in the CSS would provide more flexibility. Here are some implementations that one could consider.
Activity
d-biehl commentedon Oct 6, 2022
The theme of the documentation is sadly dependent on the OS theme, if you switch the windows color theme to dark mode, you will get a dark documentation and otherwise.
This is handled in the CSS of the library, which I can't change at the moment.
But I'm working on it.
mardukbp commentedon Oct 7, 2022
Yeah, you are right. I checked the code of the LS extension. They just replace "prefers-color-scheme: dark" based on
vscode.window.activeColorTheme.kind. It is a quick way to achieve the desired result, but I think that supporting both the OS-level and the VS Code-level color theme settings in the CSS would provide more flexibility. Here are some implementations that one could consider.d-biehl commentedon Oct 9, 2022
Waiting for implemention of robotframework/robotframework#4497