mirror of
https://github.com/deesiigneer/pyspapi.git
synced 2026-04-20 12:35:26 +00:00
version dropdown fix
This commit is contained in:
8
docs/_static/custom.css
vendored
8
docs/_static/custom.css
vendored
@@ -1,13 +1,13 @@
|
|||||||
/* Background of stable should be green */
|
/* Background of stable should be green */
|
||||||
#version_switcher a[data-version-name*="stable"] {
|
.version-switcher__container a[data-version-name*="stable"] {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
#version_switcher a[data-version-name*="stable"] span {
|
.version-switcher__container a[data-version-name*="stable"] span {
|
||||||
color: var(--pst-color-success);
|
color: var(--pst-color-success);
|
||||||
}
|
}
|
||||||
|
|
||||||
#version_switcher a[data-version-name*="stable"] span:before {
|
.version-switcher__container a[data-version-name*="stable"] span:before {
|
||||||
content: "";
|
content: "";
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -16,4 +16,4 @@
|
|||||||
top: 0;
|
top: 0;
|
||||||
background-color: var(--pst-color-success);
|
background-color: var(--pst-color-success);
|
||||||
opacity: 0.1;
|
opacity: 0.1;
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
from re import search, MULTILINE
|
from re import search, MULTILINE
|
||||||
|
import os
|
||||||
|
|
||||||
project = 'pyspapi'
|
project = 'pyspapi'
|
||||||
copyright = '2022, deesiigneer'
|
copyright = '2022, deesiigneer'
|
||||||
@@ -28,6 +29,10 @@ intersphinx_mapping = {
|
|||||||
'python': ('https://docs.python.org/3/', None),
|
'python': ('https://docs.python.org/3/', None),
|
||||||
'sphinx': ('https://www.sphinx-doc.org/en/master/', None),
|
'sphinx': ('https://www.sphinx-doc.org/en/master/', None),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
version_match = os.environ.get("READTHEDOCS_VERSION")
|
||||||
|
json_url = f"https://pyspapi.readthedocs.io/ru/{version_match}/_static/switcher.json"
|
||||||
|
|
||||||
intersphinx_disabled_domains = ['std']
|
intersphinx_disabled_domains = ['std']
|
||||||
language = None
|
language = None
|
||||||
locale_dirs = ["locale/"]
|
locale_dirs = ["locale/"]
|
||||||
@@ -67,8 +72,8 @@ html_theme_options = {
|
|||||||
"show_toc_level": 1,
|
"show_toc_level": 1,
|
||||||
"navbar_start": ["navbar-logo", "version-switcher"],
|
"navbar_start": ["navbar-logo", "version-switcher"],
|
||||||
"switcher": {
|
"switcher": {
|
||||||
"json_url": "https://pyspapi.readthedocs.io/en/latest/_static/switcher.json",
|
"json_url": json_url,
|
||||||
"version_match": "latest"
|
"version_match": version_match
|
||||||
},
|
},
|
||||||
"navigation_with_keys": True,
|
"navigation_with_keys": True,
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user