-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sphinx-design stylesheet is not added to the document head #116
Comments
Thanks for opening your first issue here! Engagement like this is essential for open source projects! 🤗 |
You haven't added it to the extensions list |
Perhaps you looked at a commit where I had briefly removed it. But, that is not the case, especially since the html structure generated by sphinx-design was added as could be seen in the inspector. At any rate, this draft PR has the extension added but you can see in the preview of the docs that the style is not applied. If you inspect any of the large pictures on the homepage, you will see that they are in fact in sphinx-design grids, but have no styling because the style document is not linked. |
Heya, yeh I'm not sure why this is added: https://github.com/NCAR/tuv-x/blob/1a2e9b86054f418397f24f32a2e24d59572d0fa4/docs/source/conf.py#L79-L82 but this is not the way to add custom css, as you are overriding sphinx's internal logic, its with https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-html_css_files |
Oh, thank you for catching that. That fixes the issue. |
Describe the bug
context
When I added sphinx-design to my docs and built the site, I saw that sphinx-design classes and HTML layouts are applied to the page, but I the css styles are not loaded.
expectation
I expected styles to load.
bug
When I inspect the stylesheets loaded in the documents
head
, I don't see any reference to a style sheet made by sphinx design (which I think is of the formdesign-style.hash.min
. That stylesheet is located in_build/html/_sphinx_design_static
, but there is no reference to this in the document header.problem
This is a problem for people using sphinx-doc because sphinx-doc does not add any value when it's stylesheet is not added.
This occurs with Python 3.9.15 and these versions of installed sphinx packages
Reproduce the bug
You can reproduce this on a branch in my repository. Note that in
docs/source/index.rst
there are some directives to create a grid.After inspecting the head of that page, you will not find the style file.
List your environment
The text was updated successfully, but these errors were encountered: