joeyespo / grip

Preview GitHub README.md files locally before committing them.
MIT License
6.42k stars 422 forks source link

v4.5.2 style variables are not set #348

Closed theherk closed 2 years ago

theherk commented 2 years ago

Color variables are not set. So everything in the preview ends up as black text on white, with no borders or other formatting. Inspector tells me --color-border-default and --color-border-muted are both unset, and sure enough setting them causes more formatting. I imaging this is the case for many variables, which is why the formatting is missing. Can you look into this?

Going and setting these manually in the style editor is a bit of a pain, but it is a workaround. For anybody wondering, in Firefox you can open the style editor, then in github-???.css, add these variables to :root like:

:root {
 --border-width: 1px;
 --border-style: solid;
 --font-size-small: 12px;
 --font-weight-semibold: 500;
 --size-2: 20px;
 --color-border-default: #aaaaaa;
 --color-border-muted: #cccccc;
}

This should allow the preview to look a bit better.

joeyespo commented 2 years ago

Hi, @theherk!

Version 4.6.0 has just been released with a fix to the issue about missing styles.

Try upgrading now with pip install --upgrade grip and hard-refreshing the page with a fresh run.

Thanks for the temporary workaround here 😃 Feel free to reopen the issue if there's still a problem.

theherk commented 2 years ago

Yes indeed; verified. It looks lovely. Nice work.