fix: show the RSS icon and the W3C badges on one line at the same height
- move the RSS icon inside the badges paragraph - scale every footer icon to 32 px high - lay the badges out in a flex row
This commit is contained in:
parent
8270863f9f
commit
1b81184187
5 changed files with 11 additions and 10 deletions
2
build.py
2
build.py
|
|
@ -322,9 +322,9 @@ def build():
|
||||||
ctx["content"] = render(p["body"].strip("\n") + "\n", ctx, name)
|
ctx["content"] = render(p["body"].strip("\n") + "\n", ctx, name)
|
||||||
lead = p.get("lead", "back")
|
lead = p.get("lead", "back")
|
||||||
ctx["lead"] = render(tpl["lead-" + lead], ctx, f"templates/lead-{lead}.html")
|
ctx["lead"] = render(tpl["lead-" + lead], ctx, f"templates/lead-{lead}.html")
|
||||||
|
ctx["feed"] = render(tpl["feed"], ctx, "templates/feed.html")
|
||||||
ctx["badges"] = render(tpl["badges"], dict(ctx, doc_q=ctx["doc_url"].replace(":", "%3A").replace("/", "%2F")),
|
ctx["badges"] = render(tpl["badges"], dict(ctx, doc_q=ctx["doc_url"].replace(":", "%3A").replace("/", "%2F")),
|
||||||
"templates/badges.html")
|
"templates/badges.html")
|
||||||
ctx["feed"] = render(tpl["feed"], ctx, "templates/feed.html")
|
|
||||||
ctx["header"] = render(tpl["header"], ctx, "templates/header.html")
|
ctx["header"] = render(tpl["header"], ctx, "templates/header.html")
|
||||||
ctx["footer"] = render(tpl["footer"], ctx, "templates/footer.html")
|
ctx["footer"] = render(tpl["footer"], ctx, "templates/footer.html")
|
||||||
rel = p["path"].lstrip("/")
|
rel = p["path"].lstrip("/")
|
||||||
|
|
|
||||||
|
|
@ -106,8 +106,11 @@ code {
|
||||||
height: auto;
|
height: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
svg {
|
.badges {
|
||||||
vertical-align: middle;
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
align-items: center;
|
||||||
|
gap: .5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media print {
|
@media print {
|
||||||
|
|
@ -119,7 +122,7 @@ svg {
|
||||||
--link: #000;
|
--link: #000;
|
||||||
}
|
}
|
||||||
|
|
||||||
header, .badges, .feed {
|
header, .badges {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
<p class="badges">
|
<p class="badges">
|
||||||
<a href="https://validator.w3.org/nu/?doc={{doc_q}}"><img src="/badges/w3c-html5.png" alt="Valid HTML5" width="63" height="64"></a>
|
{{feed}}
|
||||||
<a href="https://jigsaw.w3.org/css-validator/validator?uri={{doc_q}}&profile=css3svg"><img src="/badges/w3c-css.png" alt="Valid CSS" width="88" height="31"></a>
|
<a href="https://validator.w3.org/nu/?doc={{doc_q}}"><img src="/badges/w3c-html5.png" alt="Valid HTML5" width="31" height="32"></a>
|
||||||
|
<a href="https://jigsaw.w3.org/css-validator/validator?uri={{doc_q}}&profile=css3svg"><img src="/badges/w3c-css.png" alt="Valid CSS" width="91" height="32"></a>
|
||||||
</p>
|
</p>
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1 @@
|
||||||
<p class="feed">
|
<a href="{{url_news}}feed.xml" title="RSS"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="32" height="32" role="img" aria-label="RSS"><rect width="32" height="32" rx="6" fill="#D9480F"/><circle cx="9" cy="23" r="3" fill="#fff"/><path d="M6 14a12 12 0 0 1 12 12M6 6a20 20 0 0 1 20 20" fill="none" stroke="#fff" stroke-width="3"/></svg></a>
|
||||||
<a href="{{url_news}}feed.xml" title="RSS"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" width="28" height="28" role="img" aria-label="RSS"><rect width="32" height="32" rx="6" fill="#D9480F"/><circle cx="9" cy="23" r="3" fill="#fff"/><path d="M6 14a12 12 0 0 1 12 12M6 6a20 20 0 0 1 20 20" fill="none" stroke="#fff" stroke-width="3"/></svg></a>
|
|
||||||
</p>
|
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,5 @@
|
||||||
<p>
|
<p>
|
||||||
{{nojs}}
|
{{nojs}}
|
||||||
</p>
|
</p>
|
||||||
{{feed}}
|
|
||||||
{{badges}}
|
{{badges}}
|
||||||
</footer>
|
</footer>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue