sunpy-sphinx-theme 2.2.2__tar.gz → 2.3.0__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.
Files changed (39) hide show
  1. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/.readthedocs.yaml +1 -1
  2. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/PKG-INFO +2 -2
  3. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/_typos.toml +1 -0
  4. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/pyproject.toml +1 -1
  5. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/ruff.toml +1 -0
  6. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/__init__.py +29 -0
  7. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/sunpy_style.css +12 -0
  8. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/theme.toml +1 -0
  9. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/PKG-INFO +2 -2
  10. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/SOURCES.txt +2 -0
  11. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/requires.txt +1 -1
  12. sunpy_sphinx_theme-2.3.0/src/sunpy_sphinx_theme.egg-info/scm_file_list.json +59 -0
  13. sunpy_sphinx_theme-2.3.0/src/sunpy_sphinx_theme.egg-info/scm_version.json +8 -0
  14. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/.editorconfig +0 -0
  15. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/.rtd-environment.yml +0 -0
  16. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/.stylelintrc.json +0 -0
  17. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/LICENSE.md +0 -0
  18. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/MANIFEST.in +0 -0
  19. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/README.md +0 -0
  20. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/setup.cfg +0 -0
  21. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/cards.py +0 -0
  22. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/conf.py +0 -0
  23. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/built-with.html +0 -0
  24. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/footer-links.html +0 -0
  25. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/navbar-logo.html +0 -0
  26. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/navbar_center.html +0 -0
  27. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/navbar_start.html +0 -0
  28. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/components/sst-sidebar-nav.html +0 -0
  29. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/sections/header.html +0 -0
  30. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/css/rtd_enhanced_search.css +0 -0
  31. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/css/sunpy_cards.css +0 -0
  32. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/img/favicon-32.ico +0 -0
  33. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/img/sunpy_icon.svg +0 -0
  34. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/img/sunpy_icon_128x128.png +0 -0
  35. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/js/rtd_enhanced_search.js +0 -0
  36. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme/theme/sunpy/static/js/submenu-concertina-toggle.js +0 -0
  37. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/dependency_links.txt +0 -0
  38. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/entry_points.txt +0 -0
  39. {sunpy_sphinx_theme-2.2.2 → sunpy_sphinx_theme-2.3.0}/src/sunpy_sphinx_theme.egg-info/top_level.txt +0 -0
@@ -2,7 +2,7 @@ version: 2
2
2
  build:
3
3
  os: ubuntu-lts-latest
4
4
  tools:
5
- python: "mambaforge-latest"
5
+ python: "miniforge3-latest"
6
6
  jobs:
7
7
  post_checkout:
8
8
  - git fetch --unshallow || true
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sunpy-sphinx-theme
3
- Version: 2.2.2
3
+ Version: 2.3.0
4
4
  Summary: The sphinx theme for the SunPy website and documentation.
5
5
  Author: The SunPy Developers
6
6
  License: BSD 2-Clause License
@@ -39,7 +39,7 @@ Classifier: Operating System :: OS Independent
39
39
  Requires-Python: >=3.9
40
40
  Description-Content-Type: text/markdown
41
41
  License-File: LICENSE.md
42
- Requires-Dist: pydata-sphinx-theme<0.19,>=0.17
42
+ Requires-Dist: pydata-sphinx-theme<0.23,>=0.22.0rc0
43
43
  Requires-Dist: sphinxext-opengraph>=0.13
44
44
  Requires-Dist: sphinx>=7.3.0
45
45
  Provides-Extra: docs
@@ -21,4 +21,5 @@ default.extend-ignore-identifiers-re = [
21
21
  "ot",
22
22
  # Coords,
23
23
  "pn",
24
+ "CPY",
24
25
  ]
@@ -22,7 +22,7 @@ classifiers = [
22
22
  ]
23
23
  requires-python = ">=3.9"
24
24
  dependencies = [
25
- "pydata-sphinx-theme>=0.17,<0.19",
25
+ "pydata-sphinx-theme>=0.22.0rc0,<0.23",
26
26
  "sphinxext-opengraph>=0.13",
27
27
  "sphinx>=7.3.0"
28
28
  ]
@@ -31,6 +31,7 @@ lint.extend-ignore = [
31
31
  "PLR2004", # Magic value used in comparison
32
32
  "TD002", # Missing author in TODO
33
33
  "TD003", # Missing issue link on the line following this TODO
34
+ "CPY001", # Copyright in each file
34
35
  ]
35
36
 
36
37
  [lint.per-file-ignores]
@@ -122,6 +122,28 @@ def update_html_context(app: Sphinx, pagename: str, templatename: str, context,
122
122
  context["sst_pathto"] = partial(sst_pathto, context)
123
123
 
124
124
 
125
+ def _get_sphinx_gallery_thumbnail(doctree):
126
+ """
127
+ Return the generated Sphinx-Gallery thumbnail for an example page.
128
+ """
129
+ source = doctree.get("source")
130
+ if not source:
131
+ return None
132
+
133
+ source_path = Path(source)
134
+ thumbnail_dir = source_path.parent / "images" / "thumb"
135
+ if not thumbnail_dir.is_dir():
136
+ return None
137
+
138
+ # Reuse the thumbnail Sphinx-Gallery already picked for this page.
139
+ thumbnails = sorted(thumbnail_dir.glob(f"sphx_glr_{source_path.stem}_thumb.*"))
140
+ for thumbnail in thumbnails:
141
+ if thumbnail.suffix.lower() in SPHINX_GALLERY_IMAGE_EXTENSIONS:
142
+ return thumbnail
143
+
144
+ return None
145
+
146
+
125
147
  def update_opengraph_context(app: Sphinx, pagename: str, templatename: str, context, doctree) -> None: # NOQA: ARG001
126
148
  """
127
149
  Add Sphinx-Gallery images to the Open Graph metadata context.
@@ -133,6 +155,13 @@ def update_opengraph_context(app: Sphinx, pagename: str, templatename: str, cont
133
155
  if "og:image" in metadata:
134
156
  return
135
157
 
158
+ # Prefer the user defined generated gallery thumbnail when one exists.
159
+ if thumbnail := _get_sphinx_gallery_thumbnail(doctree):
160
+ metadata["og:image"] = posixpath.join(app.builder.imagedir, thumbnail.name)
161
+ context["meta"] = metadata
162
+ return
163
+
164
+ # Fall back to the first gallery image
136
165
  for node in doctree.findall():
137
166
  if node.__class__.__name__ != "imgsgnode" or not node.get("uri"):
138
167
  continue
@@ -74,6 +74,7 @@ html[data-theme="light"] {
74
74
  --pst-color-inline-code: #912583;
75
75
  --pst-color-link-hover: var(--sst-accent-color-muted);
76
76
  --pst-color-link: var(--sst-accent-color-bright);
77
+ --pst-color-link-higher-contrast: var(--sst-accent-color-bright);
77
78
  --pst-color-on-background: #fff;
78
79
  --pst-color-on-surface: #222832;
79
80
  --pst-color-primary-bg: #d0ecf1;
@@ -109,6 +110,7 @@ html[data-theme="dark"] {
109
110
  --pst-color-inline-code: #f3c7ee;
110
111
  --pst-color-link-hover: var(--pst-color-secondary);
111
112
  --pst-color-link: var(--sst-accent-color-bright);
113
+ --pst-color-link-higher-contrast: var(--sst-accent-color-bright);
112
114
  --pst-color-on-background: #222832;
113
115
  --pst-color-on-surface: #f3f4f5;
114
116
  --pst-color-primary-bg: #042c33;
@@ -197,6 +199,11 @@ div.math {
197
199
  margin-bottom: -3px;
198
200
  }
199
201
 
202
+ .bd-header .bd-header__inner {
203
+ padding-top: 0;
204
+ padding-bottom: 0;
205
+ }
206
+
200
207
  .bd-header .navbar-nav li.nav-item {
201
208
  padding-left: 0.6rem;
202
209
  }
@@ -231,6 +238,7 @@ div.math {
231
238
  /* Change the top navbar toggles and icons in the header to be light */
232
239
  .bd-header button.sidebar-toggle,
233
240
  html .navbar-header-items__end .pst-navbar-icon,
241
+ html .navbar-header-items__end .pst-navbar-icon:active,
234
242
  html .navbar-header-items__end .pst-navbar-icon:visited {
235
243
  color: var(--sst-header-text);
236
244
  }
@@ -285,6 +293,10 @@ html[data-theme="light"] .bd-sidebar-primary .theme-switch-button span {
285
293
  border: none;
286
294
  }
287
295
 
296
+ .bd-header ul.navbar-nav .dropdown button:hover {
297
+ color: var(--sst-accent-color-bright);
298
+ }
299
+
288
300
  /* Required to center the items in the bottom bar */
289
301
  .bd-header .navbar-header-items__start {
290
302
  width: auto;
@@ -11,6 +11,7 @@ navbar_center = "components/navbar_center.html"
11
11
  footer_start = "copyright.html"
12
12
  footer_center = "components/footer-links.html"
13
13
  footer_end = "components/built-with.html"
14
+ templates_skip_empty_check = ["components/sst-sidebar-nav.html", "navbar-nav.html"]
14
15
 
15
16
  sst_site_root = "https://sunpy.org"
16
17
  sst_is_root = false
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sunpy-sphinx-theme
3
- Version: 2.2.2
3
+ Version: 2.3.0
4
4
  Summary: The sphinx theme for the SunPy website and documentation.
5
5
  Author: The SunPy Developers
6
6
  License: BSD 2-Clause License
@@ -39,7 +39,7 @@ Classifier: Operating System :: OS Independent
39
39
  Requires-Python: >=3.9
40
40
  Description-Content-Type: text/markdown
41
41
  License-File: LICENSE.md
42
- Requires-Dist: pydata-sphinx-theme<0.19,>=0.17
42
+ Requires-Dist: pydata-sphinx-theme<0.23,>=0.22.0rc0
43
43
  Requires-Dist: sphinxext-opengraph>=0.13
44
44
  Requires-Dist: sphinx>=7.3.0
45
45
  Provides-Extra: docs
@@ -16,6 +16,8 @@ src/sunpy_sphinx_theme.egg-info/SOURCES.txt
16
16
  src/sunpy_sphinx_theme.egg-info/dependency_links.txt
17
17
  src/sunpy_sphinx_theme.egg-info/entry_points.txt
18
18
  src/sunpy_sphinx_theme.egg-info/requires.txt
19
+ src/sunpy_sphinx_theme.egg-info/scm_file_list.json
20
+ src/sunpy_sphinx_theme.egg-info/scm_version.json
19
21
  src/sunpy_sphinx_theme.egg-info/top_level.txt
20
22
  src/sunpy_sphinx_theme/theme/sunpy/theme.toml
21
23
  src/sunpy_sphinx_theme/theme/sunpy/components/built-with.html
@@ -1,4 +1,4 @@
1
- pydata-sphinx-theme<0.19,>=0.17
1
+ pydata-sphinx-theme<0.23,>=0.22.0rc0
2
2
  sphinxext-opengraph>=0.13
3
3
  sphinx>=7.3.0
4
4
 
@@ -0,0 +1,59 @@
1
+ {
2
+ "files": [
3
+ ".circleci/config.yml",
4
+ ".editorconfig",
5
+ ".github/dependabot.yml",
6
+ ".github/workflows/pythonpublish.yml",
7
+ ".gitignore",
8
+ ".pre-commit-config.yaml",
9
+ ".readthedocs.yaml",
10
+ ".rtd-environment.yml",
11
+ ".stylelintrc.json",
12
+ "LICENSE.md",
13
+ "MANIFEST.in",
14
+ "README.md",
15
+ "_typos.toml",
16
+ "docs/_static/img/Stuart-Mumford.png",
17
+ "docs/cards.rst",
18
+ "docs/code_ref/animals.rst",
19
+ "docs/code_ref/index.rst",
20
+ "docs/code_ref/timerange.rst",
21
+ "docs/colors.rst",
22
+ "docs/conf.py",
23
+ "docs/customizing.rst",
24
+ "docs/index.rst",
25
+ "docs/subsections.rst",
26
+ "docs/subsections_toc.rst",
27
+ "docs/test_package/__init__.py",
28
+ "docs/test_package/animals.py",
29
+ "docs/test_package/timerange.py",
30
+ "docs/web-components.rst",
31
+ "examples/README.txt",
32
+ "examples/example_template.py",
33
+ "examples/section/README.txt",
34
+ "examples/section/example_template_subsection.py",
35
+ "pyproject.toml",
36
+ "ruff.toml",
37
+ "src/sunpy_sphinx_theme/__init__.py",
38
+ "src/sunpy_sphinx_theme/cards.py",
39
+ "src/sunpy_sphinx_theme/conf.py",
40
+ "src/sunpy_sphinx_theme/theme/sunpy/components/built-with.html",
41
+ "src/sunpy_sphinx_theme/theme/sunpy/components/footer-links.html",
42
+ "src/sunpy_sphinx_theme/theme/sunpy/components/navbar-logo.html",
43
+ "src/sunpy_sphinx_theme/theme/sunpy/components/navbar_center.html",
44
+ "src/sunpy_sphinx_theme/theme/sunpy/components/navbar_start.html",
45
+ "src/sunpy_sphinx_theme/theme/sunpy/components/sst-sidebar-nav.html",
46
+ "src/sunpy_sphinx_theme/theme/sunpy/sections/header.html",
47
+ "src/sunpy_sphinx_theme/theme/sunpy/static/css/rtd_enhanced_search.css",
48
+ "src/sunpy_sphinx_theme/theme/sunpy/static/css/sunpy_cards.css",
49
+ "src/sunpy_sphinx_theme/theme/sunpy/static/img/favicon-32.ico",
50
+ "src/sunpy_sphinx_theme/theme/sunpy/static/img/sunpy_icon.svg",
51
+ "src/sunpy_sphinx_theme/theme/sunpy/static/img/sunpy_icon_128x128.png",
52
+ "src/sunpy_sphinx_theme/theme/sunpy/static/js/rtd_enhanced_search.js",
53
+ "src/sunpy_sphinx_theme/theme/sunpy/static/js/submenu-concertina-toggle.js",
54
+ "src/sunpy_sphinx_theme/theme/sunpy/static/sunpy_style.css",
55
+ "src/sunpy_sphinx_theme/theme/sunpy/theme.toml",
56
+ "tools/rebuild_all_rtd.py",
57
+ "tox.ini"
58
+ ]
59
+ }
@@ -0,0 +1,8 @@
1
+ {
2
+ "tag": "2.3.0",
3
+ "distance": 0,
4
+ "node": "g802a2218a32a8e8e4065daa33dcf2714523d779b",
5
+ "dirty": false,
6
+ "branch": "HEAD",
7
+ "node_date": "2026-09-21"
8
+ }