-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathconf.py
More file actions
81 lines (60 loc) · 2.21 KB
/
conf.py
File metadata and controls
81 lines (60 loc) · 2.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# Configuration file for the Sphinx documentation builder.
# https://www.sphinx-doc.org/en/master/usage/configuration.html
from datetime import date
import setuptools_scm
# -- Project information ------------------------------------------------------
project = "docstub"
version = setuptools_scm.get_version(search_parent_directories=True)
version = f"v{version}"
version = version.replace("+", "<wbr>+") # Insert wrapping hint for long dev version
copyright = f"{date.today().year} docstub contributors."
templates_path = ["templates"]
# -- Extension configuration --------------------------------------------------
extensions = [
"sphinx.ext.intersphinx",
"sphinx_copybutton",
# https://numpydoc.readthedocs.io/
"myst_parser",
]
intersphinx_mapping = {
"python": ("https://docs.python.org/3/", None),
"typing": ("https://typing.python.org/en/latest/", None),
}
myst_enable_extensions = [
# Enable fieldlist to allow for Field Lists like in rST (e.g., :orphan:)
"fieldlist",
# Enable fencing directives with `:::`
"colon_fence",
]
myst_heading_anchors = 3
# -- HTML output --------------------------------------------------------------
html_theme = "furo"
html_static_path = ["static"]
html_css_files = ["furo_overrides.css"]
html_title = "docstub docs"
html_theme_options = {
"light_css_variables": {
# Make font less harsh on light theme
"color-foreground-primary": "#363636",
"color-announcement-background": "var(--color-admonition-title-background--important)",
"color-announcement-text": "var(--color-content-foreground)",
"admonition-font-size": "var(--font-size--normal)",
},
"dark_css_variables": {
"color-announcement-background": "var(--color-admonition-title-background--important)",
},
"announcement": "<b>🧪 In early development!</b> API and behavior may break between releases.",
}
html_sidebars = {
"**": [
"sidebar/brand.html",
"version.html",
"sidebar/search.html",
"sidebar/scroll-start.html",
"sidebar/navigation.html",
"external-links.html",
"ethical-ads.html",
"sidebar/scroll-end.html",
"sidebar/variant-selector.html",
]
}