Skip to content

Commit

Permalink
Set up quantinuum docs theme.
Browse files Browse the repository at this point in the history
  • Loading branch information
aidanCQ committed Jul 5, 2024
1 parent defd2bb commit ca42e3a
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 121 deletions.
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[submodule "hugr-py/docs/quantinuum-sphinx"]
path = hugr-py/docs/quantinuum-sphinx
url = https://github.com/CQCL/quantinuum-sphinx.git
branch = dist
38 changes: 0 additions & 38 deletions hugr-py/docs/_static/custom.css

This file was deleted.

13 changes: 13 additions & 0 deletions hugr-py/docs/_static/nav-config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
const navConfig = {
"navTextLinks": [

],
"navProductName": 'Hugr',
"navIconLinks": [
{
"title": 'Github',
"href": "https://github.com/CQCL/hugr/",
"iconImageURL": "/_static/assets/github.svg",
},
],
}
27 changes: 4 additions & 23 deletions hugr-py/docs/api-docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,36 +16,17 @@
"sphinx_multiversion",
]

html_theme = "sphinx_book_theme"

html_theme = "furo"
html_title = "HUGR python package API documentation."
html_theme_options = {}

html_theme_options = {
"repository_url": "https://github.com/CQCL/hugr",
"use_repository_button": True,
"navigation_with_keys": True,
"logo": {
"image_light": "_static/Quantinuum_logo_black.png",
"image_dark": "_static/Quantinuum_logo_white.png",
},
}

html_static_path = ["../_static"]
html_css_files = ["custom.css"]
templates_path = ["_templates", "../quantinuum-sphinx/_templates"]
html_static_path = ['../_static', '../quantinuum-sphinx/_static']

autosummary_generate = True

templates_path = ["_templates"]
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "conftest.py"]
html_sidebars = {
"**": [
"navbar-logo.html",
"icon-links.html",
"search-button-field.html",
"sbt-sidebar-nav.html",
"versioning.html",
],
}

smv_branch_whitelist = "main"
smv_tag_whitelist = r"^hugr-py-.*$"
Expand Down
1 change: 1 addition & 0 deletions hugr-py/docs/quantinuum-sphinx
Submodule quantinuum-sphinx added at 544cf6
86 changes: 27 additions & 59 deletions hugr-py/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion hugr-py/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ optional = true

[tool.poetry.group.docs.dependencies]
sphinx = "^7.2.6"
sphinx-book-theme = "^1.1.2"
sphinx-multiversion = "^0.2.4"
furo = "^2024.5.6"

[build-system]
requires = ["poetry-core"]
Expand Down

0 comments on commit ca42e3a

Please sign in to comment.