Make external link styling site-wide

This commit is contained in:
Gabriel Arazas 2022-10-24 13:32:06 +08:00
parent 8d6e0797b5
commit 0aaea2ff63

View File

@ -34,9 +34,20 @@ article {
h1, h2, h3 {
margin-bottom: 1rem;
}
}
main {
/* Select all links that are external. */
/*
Select all links that are external.
In this case, we'll just exclude all links that are...
- All internal anchors.
- All links that points to a relative path.
- All origin-relative URLs.
Also, all links that are explicitly marked as external are obviously
considered.
*/
a[href]:not(:where(
a[href^="#"],
a[href^="./"],
@ -48,9 +59,6 @@ article {
content: " [🡕]";
vertical-align: super;
}
}
}
/* Text formatting */
h1, h2, h3,
@ -230,6 +238,12 @@ aside {
width: 100%;
}
header, footer {
a[href]::after {
content: unset;
}
}
footer {
align-items: center;
display: flex;