scverse-doc 0.2.2__tar.gz → 0.2.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/CHANGELOG.md +16 -1
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/PKG-INFO +1 -1
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/autodoc/templates/autosummary/class.rst +5 -2
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/config.py +50 -27
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/static/styles/scverse.css +2 -1
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.codecov.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.cruft.json +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.editorconfig +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/dependabot.yml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/autofix.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/build.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/pr.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/release.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/sync.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.github/workflows/test.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.gitignore +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.pre-commit-config.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.readthedocs.yaml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.vscode/extensions.json +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.vscode/launch.json +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/.vscode/settings.json +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/LICENSE +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/README.md +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/biome.jsonc +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/pyproject.toml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/scripts/check_changelog.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/scripts/sync_brand_tokens.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/__init__.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/_accents.json +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/_color.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/autodoc/__init__.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/autodoc/templates/autosummary/module.rst +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/napoleon.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/py.typed +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/registry.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/release_notes.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/source.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/__init__.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/scverse-ecosystem.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/scverse-footer.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/scverse-sidebar-nav.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/sidebar-versions.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/toggle-primary-sidebar.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/toggle-secondary-sidebar.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/layout.html +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/static/_tokens.css +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/static/scripts/readthedocs-integration.js +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/static/scverse-fa.svg +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/theme.toml +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/typed_fields.py +0 -0
- {scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/xref_overrides.py +0 -0
|
@@ -12,6 +12,19 @@ and this project adheres to [Semantic Versioning][].
|
|
|
12
12
|
|
|
13
13
|
### Fixed
|
|
14
14
|
|
|
15
|
+
- header shadow now only extends downward (#70)
|
|
16
|
+
- the autosummary class template now correctly handles classes referenced through aliased modules (#71)
|
|
17
|
+
|
|
18
|
+
## [0.2.3]
|
|
19
|
+
|
|
20
|
+
### Added
|
|
21
|
+
|
|
22
|
+
- `scverse_doc.config.DEFAULTS` is now a class (#69)
|
|
23
|
+
|
|
24
|
+
## [0.2.2]
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
|
|
15
28
|
- run the private-base-skipping code on the real class names in more cases (#66)
|
|
16
29
|
- make logo and search button fill sidebar (#67)
|
|
17
30
|
|
|
@@ -46,7 +59,9 @@ and this project adheres to [Semantic Versioning][].
|
|
|
46
59
|
- Read the Docs integration: version selector and search, both with dark mode
|
|
47
60
|
- Autodoc, prose, and confval rendering extensions (from scverse-misc)
|
|
48
61
|
|
|
49
|
-
[Unreleased]: https://github.com/scverse/scverse-doc/compare/v0.2.
|
|
62
|
+
[Unreleased]: https://github.com/scverse/scverse-doc/compare/v0.2.3...main
|
|
63
|
+
[0.2.3]: https://github.com/scverse/scverse-doc/releases/tag/v0.2.3
|
|
64
|
+
[0.2.2]: https://github.com/scverse/scverse-doc/releases/tag/v0.2.2
|
|
50
65
|
[0.2.1]: https://github.com/scverse/scverse-doc/releases/tag/v0.2.1
|
|
51
66
|
[0.2.0]: https://github.com/scverse/scverse-doc/releases/tag/v0.2.0
|
|
52
67
|
[0.1.1]: https://github.com/scverse/scverse-doc/releases/tag/v0.1.1
|
{scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/autodoc/templates/autosummary/class.rst
RENAMED
|
@@ -7,6 +7,9 @@
|
|
|
7
7
|
.. autoclass:: {{ fullname }}
|
|
8
8
|
|
|
9
9
|
{% set methods = methods | select("ne", "__init__") | list %}
|
|
10
|
+
{#- Inside autoclass, names resolve against the class’s real module, so prefix the class name:
|
|
11
|
+
`objname` can go through a module alias, and bare members break autosummary’s instance attribute fallback. #}
|
|
12
|
+
{% set clsname = fullname.split(".") | last %}
|
|
10
13
|
|
|
11
14
|
{% block attributes %}
|
|
12
15
|
{% for item in attributes %}
|
|
@@ -16,7 +19,7 @@
|
|
|
16
19
|
|
|
17
20
|
.. autosummary::
|
|
18
21
|
{% endif %}
|
|
19
|
-
~{{ [
|
|
22
|
+
~{{ [clsname, item] | join(".") }}
|
|
20
23
|
{%- endfor %}
|
|
21
24
|
{% endblock %}
|
|
22
25
|
|
|
@@ -28,7 +31,7 @@
|
|
|
28
31
|
|
|
29
32
|
.. autosummary::
|
|
30
33
|
{% endif %}
|
|
31
|
-
~{{ [
|
|
34
|
+
~{{ [clsname, item] | join(".") }}
|
|
32
35
|
{% endfor %}
|
|
33
36
|
{% endblock %}
|
|
34
37
|
|
|
@@ -7,7 +7,8 @@ and fills in :data:`DEFAULTS`. Anything set in `conf.py` always wins.
|
|
|
7
7
|
|
|
8
8
|
from __future__ import annotations
|
|
9
9
|
|
|
10
|
-
from
|
|
10
|
+
from dataclasses import dataclass, field, fields
|
|
11
|
+
from typing import TYPE_CHECKING, Final
|
|
11
12
|
|
|
12
13
|
from sphinx.util.typing import ExtensionMetadata
|
|
13
14
|
|
|
@@ -15,11 +16,11 @@ if TYPE_CHECKING:
|
|
|
15
16
|
from sphinx.application import Sphinx
|
|
16
17
|
from sphinx.config import Config
|
|
17
18
|
|
|
18
|
-
__all__ = ["DEFAULTS", "EXTENSIONS", "MYST_ENABLE_EXTENSIONS", "setup"]
|
|
19
|
+
__all__ = ["DEFAULTS", "EXTENSIONS", "Defaults", "MYST_ENABLE_EXTENSIONS", "setup"]
|
|
19
20
|
|
|
20
21
|
#: Extensions set up alongside this one,
|
|
21
22
|
#: so packages list only ``scverse_doc``.
|
|
22
|
-
EXTENSIONS = (
|
|
23
|
+
EXTENSIONS: Final = (
|
|
23
24
|
"myst_nb",
|
|
24
25
|
"sphinx.ext.autodoc",
|
|
25
26
|
"sphinx.ext.autosummary",
|
|
@@ -31,7 +32,7 @@ EXTENSIONS = (
|
|
|
31
32
|
)
|
|
32
33
|
|
|
33
34
|
#: The MyST syntax extensions, i.e. the ``myst_enable_extensions`` entry of :data:`~scverse_doc.config.DEFAULTS`.
|
|
34
|
-
MYST_ENABLE_EXTENSIONS = (
|
|
35
|
+
MYST_ENABLE_EXTENSIONS: Final = (
|
|
35
36
|
"amsmath",
|
|
36
37
|
"colon_fence",
|
|
37
38
|
"deflist",
|
|
@@ -40,28 +41,48 @@ MYST_ENABLE_EXTENSIONS = (
|
|
|
40
41
|
"html_admonition",
|
|
41
42
|
)
|
|
42
43
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
"
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
"
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
44
|
+
|
|
45
|
+
@dataclass(frozen=True)
|
|
46
|
+
class Defaults:
|
|
47
|
+
"""Sphinx config values applied unless `conf.py` sets them."""
|
|
48
|
+
|
|
49
|
+
autosummary_generate: bool = True
|
|
50
|
+
autodoc_member_order: str = "groupwise"
|
|
51
|
+
napoleon_google_docstring: bool = False
|
|
52
|
+
napoleon_numpy_docstring: bool = True
|
|
53
|
+
napoleon_include_init_with_doc: bool = False
|
|
54
|
+
napoleon_use_param: bool = True
|
|
55
|
+
napoleon_use_rtype: bool = True
|
|
56
|
+
default_role: str = "literal"
|
|
57
|
+
myst_enable_extensions: list[str] = field(default_factory=list(MYST_ENABLE_EXTENSIONS).copy)
|
|
58
|
+
myst_heading_anchors: int = 6
|
|
59
|
+
source_suffix: dict[str, str] = field(
|
|
60
|
+
default_factory={".rst": "restructuredtext", ".md": "myst-nb", ".ipynb": "myst-nb"}.copy
|
|
61
|
+
)
|
|
56
62
|
# Off: tutorials needing a GPU or a large download must not gate a docs build.
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
63
|
+
nb_execution_mode: str = "off"
|
|
64
|
+
nb_output_stderr: str = "remove"
|
|
65
|
+
nb_merge_streams: bool = True
|
|
60
66
|
# One unreachable host must not stall the build.
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
67
|
+
intersphinx_timeout: int = 10
|
|
68
|
+
exclude_patterns: list[str] = field(
|
|
69
|
+
default_factory=["_build", "Thumbs.db", ".DS_Store", "**.ipynb_checkpoints"].copy
|
|
70
|
+
)
|
|
71
|
+
nitpicky: bool = True
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
#: Sphinx config values applied unless `conf.py` sets them.
|
|
75
|
+
#:
|
|
76
|
+
#: A frozen :func:`~dataclasses.dataclass` instance:
|
|
77
|
+
#: use :func:`dataclasses.asdict` to get a :class:`dict`.
|
|
78
|
+
#: Access them by name to create variations of their values, e.g.
|
|
79
|
+
#:
|
|
80
|
+
#: .. code-block:: python
|
|
81
|
+
#:
|
|
82
|
+
#: from scverse_doc.config import DEFAULTS
|
|
83
|
+
#:
|
|
84
|
+
#: exclude_patterns = [*DEFAULTS.exclude_patterns, ...]
|
|
85
|
+
DEFAULTS: Final = Defaults()
|
|
65
86
|
|
|
66
87
|
|
|
67
88
|
def _is_set_by_user(config: Config, name: str) -> bool:
|
|
@@ -71,10 +92,12 @@ def _is_set_by_user(config: Config, name: str) -> bool:
|
|
|
71
92
|
|
|
72
93
|
def _apply_defaults(config: Config) -> None:
|
|
73
94
|
"""Fill in the values `conf.py` did not set."""
|
|
74
|
-
|
|
75
|
-
|
|
95
|
+
# A fresh instance, so builds don’t share (and mutate) the same lists and dicts.
|
|
96
|
+
defaults = Defaults()
|
|
97
|
+
for f in fields(defaults):
|
|
98
|
+
if _is_set_by_user(config, f.name):
|
|
76
99
|
continue
|
|
77
|
-
setattr(config, name,
|
|
100
|
+
setattr(config, f.name, getattr(defaults, f.name))
|
|
78
101
|
|
|
79
102
|
|
|
80
103
|
def _configure(app: Sphinx, config: Config) -> None:
|
{scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/static/styles/scverse.css
RENAMED
|
@@ -94,7 +94,8 @@ html:not(:has(.bd-header__inner)) {
|
|
|
94
94
|
/* Span the article container’s padding, so content doesn’t peek out beside it */
|
|
95
95
|
margin: -1rem -1rem 0;
|
|
96
96
|
padding-inline: 1rem;
|
|
97
|
-
|
|
97
|
+
/* pydata’s navbar shadow, horizontally shrunk so it only extends downwards */
|
|
98
|
+
box-shadow: -0.125rem 0.25rem 0.25rem -0.125rem var(--pst-color-shadow);
|
|
98
99
|
}
|
|
99
100
|
/* Where supported, only once the page is scrolled */
|
|
100
101
|
@supports (animation-timeline: scroll()) {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/autodoc/templates/autosummary/module.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scverse_doc-0.2.2 → scverse_doc-0.2.4}/src/scverse_doc/theme/scverse/components/scverse-footer.html
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|