Skip to content

Commit 5ac6623

Browse files
committed
Try to improve visited link contrast
Tested link/text/background contrast using: https://contrast-triangle.com/ For unvisited links it was fine. For visited links it was too low. Bumped visited link to a lighter color. However it is only 20 points away from unvisited link color now. (Even before visited/unvisited were not distinguishable.) So tried to make visited/unvisited links different in some way. Can't set text-decoration-style to dotted because people are privacy invading jerks. Other things I attempted (adding an ::after item to visited links) and other ignored properties on hover didn't work. So I settled for making the underline-color on visited links darkgrey. Also use underline shortcut rather than separate props.
1 parent 0ff8894 commit 5ac6623

File tree

2 files changed

+20
-6
lines changed

2 files changed

+20
-6
lines changed

doc/_static/style.css

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -178,11 +178,18 @@ div[class^=highlight-], div[class^=highlight-] * { width:
178178

179179
:link { color: rgb(220,0,0); text-decoration: none;}
180180
:link:hover {
181-
text-decoration: underline;
181+
text-decoration: underline solid .3ex;
182182
text-underline-position: under;
183-
text-decoration-thickness: .3ex;
184183
}
185-
:visited { color: rgb(187,0,0); text-decoration: none;}
184+
:visited { color: rgb(200,0,0); text-decoration: none;}
185+
:visited:hover {
186+
/* would like to change from solid line to dashed, but
187+
because of privacy abusing people I can't change that
188+
value. So settle for darkgrey underline.
189+
*/
190+
text-decoration-color: darkgrey;
191+
}
192+
186193
a.toc-backref { color: #000000; }
187194

188195
.header h1 { margin-left: 1em; }

website/www/_static/style.css

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -178,11 +178,18 @@ div[class^=highlight-], div[class^=highlight-] * { width:
178178

179179
:link { color: rgb(220,0,0); text-decoration: none;}
180180
:link:hover {
181-
text-decoration: underline;
181+
text-decoration: underline solid .3ex;
182182
text-underline-position: under;
183-
text-decoration-thickness: .3ex;
184183
}
185-
:visited { color: rgb(187,0,0); text-decoration: none;}
184+
:visited { color: rgb(200,0,0); text-decoration: none;}
185+
:visited:hover {
186+
/* would like to change from solid line to dashed, but
187+
because of privacy abusing people I can't change that
188+
value. So settle for darkgrey underline.
189+
*/
190+
text-decoration-color: darkgrey;
191+
}
192+
186193
a.toc-backref { color: #000000; }
187194

188195
.header h1 { margin-left: 1em; }

0 commit comments

Comments
 (0)