Closed anhtumai closed 9 months ago
@joeyespo This is ready for review
At the time this PR is created, GitHub uses dark-color-mode
, data-light-theme
, and data-dark-theme
parameters in html tag to specify the theme of the website. This feature is not in any documentation, as far as I know.
In dark mode, these values are data-color-mode
: dark
, data-light-theme
: light
, and data-dark-theme
: dark
In light mode, these values are data-color-mode
: light
, data-light-theme
: light
, and data-dark-theme
: dark
I checked the HTML content of the GitHub website and saw that its styling depends on these parameters.
Therefore, even if we don't need dark mode, adding these parameters above to the html tag in our generated HTML file will make the output website prettier and more like GitHub.
theme
optional argument to the CLI parser, which can either be "light" or "dark" theme
option to export
and render_template
functiondata-color-mode
, data-dark-theme
, data-light-theme
to base.html
Any updates on this getting pulled anytime soon?
After fiddling around over an hour with the standard installation, I
pip install git+https://github.com/anhtumai/grip.git@358-add-dark-theme
grip --theme=dark /path/to/my/readme.md
and was so happy to have it working… I hope your pull request gets merged soon!Looks good! Thank you for the PR, @anhtumai!
I'll comment back here once a new release is out.
oh my gosh finally!!
Theme is option to view mark down file, in light mode or dark mode. Fix https://github.com/joeyespo/grip/issues/358