pyproject: Re-enable rtd-theme.

This commit is contained in:
Laurens Valk
2026-08-24 17:28:00 +02:00
parent 37664889c6
commit bc70549edd
5 changed files with 52 additions and 29 deletions
+12 -25
View File
@@ -154,8 +154,18 @@ add_module_names = False # Hide module name
# -- Options for HTML output ----------------------------------------------
# Bare default theme for now; a new theme will be chosen later.
html_theme = "alabaster"
# The theme to use for HTML and HTML Help pages. Since sphinx-rtd-theme 1.2
# themes are registered via entry points, so setting html_theme is all that
# is needed (no extensions entry or html_theme_path).
html_theme = "sphinx_rtd_theme"
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
html_theme_options = {
# Hide the next/previous buttons at the bottom of each page.
"prev_next_buttons_location": None,
}
html_show_sourcelink = False
html_copy_source = False
@@ -164,34 +174,11 @@ html_context = {
"disclaimer": _DISCLAIMER,
}
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
# html_theme = 'alabaster'
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
# html_theme_options = {}
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ["../common/_static"]
# Custom sidebar templates, must be a dictionary that maps document names
# to template names.
#
# This is required for the alabaster theme
# refs: http://alabaster.readthedocs.io/en/latest/installation.html#sidebars
html_sidebars = {
"**": [
"relations.html", # needs 'show_related': True theme option to display
"searchbox.html",
]
}
# Don't hyperlink to larger images for scaled images.
html_scaled_image_link = False
+2 -2
View File
@@ -8,7 +8,7 @@ import sys
# General information about the project.
project = "pybricks"
copyright = "2018-2023 The Pybricks Authors"
copyright = "2018-2026 The Pybricks Authors"
author = ""
_DISCLAIMER = "LEGO, the LEGO logo, MINDSTORMS and the MINDSTORMS EV3 logo are\
@@ -27,7 +27,7 @@ if os.environ.get("READTHEDOCS", None) == "True":
# HACK: this allows Number type alias to be imported by Sphinx
os.environ["SPHINX_BUILD"] = "True"
html_css_files = ["css/blocks.css"]
html_css_files = ["css/theme_overrides.css", "css/blocks.css"]
# Additional configuration of the IDE docs
if tags.has("ide"): # noqa F821
+1 -1
View File
@@ -1,6 +1,6 @@
MIT License
Copyright (c) 2018-2023 The Pybricks Authors
Copyright (c) 2018-2026 The Pybricks Authors
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Generated
+36 -1
View File
@@ -555,6 +555,26 @@ sphinxcontrib-jsmath = ">=1.0.1"
sphinxcontrib-qthelp = ">=1.0.6"
sphinxcontrib-serializinghtml = ">=1.1.9"
[[package]]
name = "sphinx-rtd-theme"
version = "3.1.0"
description = "Read the Docs theme for Sphinx"
optional = false
python-versions = ">=3.8"
groups = ["doc"]
files = [
{file = "sphinx_rtd_theme-3.1.0-py2.py3-none-any.whl", hash = "sha256:1785824ae8e6632060490f67cf3a72d404a85d2d9fc26bce3619944de5682b89"},
{file = "sphinx_rtd_theme-3.1.0.tar.gz", hash = "sha256:b44276f2c276e909239a4f6c955aa667aaafeb78597923b1c60babc76db78e4c"},
]
[package.dependencies]
docutils = ">0.18,<0.23"
sphinx = ">=6,<10"
sphinxcontrib-jquery = ">=4,<5"
[package.extras]
dev = ["bump2version", "transifex-client", "twine", "wheel"]
[[package]]
name = "sphinxcontrib-applehelp"
version = "2.0.0"
@@ -606,6 +626,21 @@ lint = ["mypy", "ruff (==0.5.5)", "types-docutils"]
standalone = ["Sphinx (>=5)"]
test = ["html5lib", "pytest"]
[[package]]
name = "sphinxcontrib-jquery"
version = "4.1"
description = "Extension to include jQuery on newer Sphinx releases"
optional = false
python-versions = ">=2.7"
groups = ["doc"]
files = [
{file = "sphinxcontrib-jquery-4.1.tar.gz", hash = "sha256:1620739f04e36a2c779f1a131a2dfd49b2fd07351bf1968ced074365933abc7a"},
{file = "sphinxcontrib_jquery-4.1-py2.py3-none-any.whl", hash = "sha256:f936030d7d0147dd026a4f2b5a57343d233f1fc7b363f68b3d4f1cb0993878ae"},
]
[package.dependencies]
Sphinx = ">=1.8"
[[package]]
name = "sphinxcontrib-jsmath"
version = "1.0.1"
@@ -688,4 +723,4 @@ zstd = ["backports-zstd (>=1.0.0) ; python_version < \"3.14\""]
[metadata]
lock-version = "2.1"
python-versions = "^3.12"
content-hash = "d4471353fbbab0a8c5f8b38c4fde018430930a2bd51d8175d1c5d6c57f1f5b19"
content-hash = "5ad394afcc567b0de5304f60db959b10b2021168a2244b359dd05d84fd0552d9"
+1
View File
@@ -30,6 +30,7 @@ python = "^3.12"
[tool.poetry.group.doc.dependencies]
sphinx = "^9.1.0"
sphinx-rtd-theme = "^3.1.0"
[tool.poetry.group.lint.dependencies]