simov / markdown-viewer

Markdown Viewer / Browser Extension
MIT License
1.01k stars 131 forks source link

Getting Github Markdown CSS working #238

Closed jbytes1027 closed 1 month ago

jbytes1027 commented 1 month ago

I'm trying to customize github-markdown-css but I can't get it working. Nothing happens when linking the stylesheet to the markdown file via <link rel="stylesheet" type="text/css" href="github-markdown.css">. I know it's loading because I can see the styles are loaded in dev tools and other css themes like awsm work with this method. What am I missing?

simov commented 1 month ago

This is an edge case that I did not think about. Both the regular github and github-dark themes are applied a bit differently than the rest of the themes. Essentially they are using different parent (top) classes in order to be applied. I will have to take a look and see if that can be standardized somehow.

jbytes1027 commented 1 month ago

Replacing the non-standard .markdown-body with body works for me.