Skip to content

Commit 12e1b84

Browse files
authoredNov 25, 2022
Rollup merge of #104896 - notriddle:notriddle/tooltip, r=GuillaumeGomez
rustdoc: fix broken tooltip CSS text `#ffffff` on background `#fdffd3` fails the [WCAG color contrast checker], and seems like a mistake in 16b5590. Making the cursor a pointer is misleading, since clicking it doesn't do anything. [WCAG color contrast checker]: https://accessibleweb.com/color-contrast-checker/
2 parents c72db77 + 75e4de6 commit 12e1b84

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed
 

‎src/librustdoc/html/static/css/rustdoc.css

-1
Original file line numberDiff line numberDiff line change
@@ -1139,7 +1139,6 @@ pre.rust .doccomment {
11391139
.example-wrap .tooltip {
11401140
position: absolute;
11411141
display: block;
1142-
cursor: pointer;
11431142
left: -25px;
11441143
top: 5px;
11451144
}

‎src/librustdoc/html/static/css/themes/light.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
--test-arrow-hover-background-color: #4e8bca;
6565
--target-background-color: #fdffd3;
6666
--target-border-color: #ad7c37;
67-
--tooltip-background-color: #fdffd3;
67+
--tooltip-background-color: #000;
6868
--tooltip-color: #fff;
6969
--kbd-color: #000;
7070
--kbd-background: #fafbfc;

‎src/test/rustdoc-gui/codeblock-tooltip.goml

+1-1
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ call-function: ("check-colors", {
146146
})
147147
call-function: ("check-colors", {
148148
"theme": "light",
149-
"background": "rgb(253, 255, 211)",
149+
"background": "rgb(0, 0, 0)",
150150
"color": "rgb(255, 255, 255)",
151151
"border": "rgb(224, 224, 224)",
152152
})

0 commit comments

Comments
 (0)
Please sign in to comment.