blueswen / mkdocs-swagger-ui-tag

A MkDocs plugin supports adding Swagger UI to the page.
https://blueswen.github.io/mkdocs-swagger-ui-tag/
MIT License
75 stars 7 forks source link

Dark theme toggle is dependent on slate theme #10

Closed daenney closed 1 year ago

daenney commented 1 year ago

The Materials theme has the ability to let you define your own colour palette and use that. However, this plugin hardcodes slate as the palette name it checks against in order to toggle dark mode which breaks with any custom, dark, palette.

It would be great if there was some way to indicate to the plugin which palette name it should look for and under which condition to activate the dark mode (as a palette could have a light theme too).

blueswen commented 1 year ago

@daenney The new version v0.6.1 can use a customized dark mode scheme name with the plugin option dark_scheme_name. I hope this fits your requirements.

daenney commented 1 year ago

Ah lovely, thank you!