Skip to content

Commit 71bcacb

Browse files
patrickhlaukekfranqueirombgower
committed
Restyle doclinks box (#4590)
Apply proposed styles from #1130 (comment) Closes #1130 Live preview: https://deploy-preview-4590--wcag2.netlify.app/guidelines/#text-alternatives --------- Co-authored-by: Kenneth G. Franqueiro <kfranqueiro@users.noreply.github.com> Co-authored-by: Mike Gower <mikegower@gmail.com> (cherry picked from commit a3fc8d8)
1 parent c073b16 commit 71bcacb

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

guidelines/guidelines.css

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,17 @@ dd.new, dd.proposed, dd.changed {
2929
}
3030
.doclinks {
3131
float: right;
32-
border: thin solid black;
33-
font-size: x-small;
32+
border: thin solid #aaa;
33+
background: #ecf2f7;
34+
font-size: small;
3435
display: block;
3536
width: 25%;
3637
hyphens: none;
38+
padding: 1em;
39+
display: flex;
40+
flex-direction: column;
41+
gap: 1em;
42+
margin: -0.5em 0 1em 2em;
3743
}
3844
.sc dt {
3945
display: list-item;

script/wcag.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ function linkUnderstanding() {
2525
var pathFrag = titleToPathFrag(heading);
2626
var el = document.createElement("div");
2727
el.setAttribute("class", "doclinks");
28-
el.innerHTML = "<a href=\"" + understandingBaseURI + pathFrag + ".html\">Understanding " + heading + "</a> <span class=\"screenreader\">|</span> <br /><a href=\"https://www.w3.org/WAI/WCAG" + version + "/quickref/#" + pathFrag + "\">How to Meet " + heading + "</a>";
28+
el.innerHTML = "<a href=\"" + understandingBaseURI + pathFrag + ".html\">Understanding " + heading +
29+
"</a> <span class=\"screenreader\">|</span> <a href=\"https://www.w3.org/WAI/WCAG" + version + "/quickref/#" + pathFrag + "\">How to Meet " + heading + "</a>";
2930
if (node.className = "sc") node.insertBefore(el, node.children[2]);
3031
if (node.className = "guideline") node.insertBefore(el, node.children[1]);
3132
})

0 commit comments

Comments
 (0)