Skip to content

Commit a720cc8

Browse files
authored
Merge pull request #4589 from Liam-DeVoe/docs-dark-theme
Fix link preview appearance in dark mode
2 parents 87c03f6 + 14dbc3c commit a720cc8

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
/*
2+
See https://github.com/HypothesisWorks/hypothesis/issues/4588 and
3+
https://github.com/pradyunsg/furo/discussions/909. Once this is fixed in furo,
4+
we can remove this.
5+
*/
6+
7+
body[data-theme="dark"] .tooltip .tooltip-content {
8+
background-color: var(--color-background-primary);
9+
}
10+
11+
body[data-theme="dark"] .tooltip .arrow {
12+
background: var(--color-background-primary);
13+
}

hypothesis-python/docs/conf.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,12 @@ def process_signature(app, what, name, obj, options, signature, return_annotatio
220220
# remove "Hypothesis <version> documentation" from just below logo on the sidebar
221221
html_theme_options = {"sidebar_hide_name": True}
222222
html_static_path = ["_static"]
223-
html_css_files = ["better-signatures.css", "wrap-in-tables.css", "no-scroll.css"]
223+
html_css_files = [
224+
"better-signatures.css",
225+
"wrap-in-tables.css",
226+
"no-scroll.css",
227+
"dark-fix.css",
228+
]
224229
htmlhelp_basename = "Hypothesisdoc"
225230
html_favicon = "../../brand/favicon.ico"
226231
html_logo = "../../brand/dragonfly-rainbow-150w.svg"

tooling/src/hypothesistooling/scripts.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ def tool_path(name):
6464

6565

6666
def pip_tool(name, *args, **kwargs):
67+
args = [str(arg) for arg in args]
6768
print_command(name, args)
6869
r = subprocess.call([tool_path(name), *args], **kwargs)
6970

0 commit comments

Comments
 (0)