Skip to content

Commit aee4985

Browse files
author
Stephan Wald
committed
auto-claude: Merge auto-claude/004-add-external-link-icon-to-resource-links
2 parents f1fc467 + f7b81a3 commit aee4985

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

src/css/custom.css

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,23 @@
2828
--ifm-color-primary-lightest: #4fddbf;
2929
--docusaurus-highlighted-code-line-bg: rgba(0, 0, 0, 0.3);
3030
}
31+
32+
/* External link icon - targets links starting with http:// or https:// */
33+
a[href^="http://"]::after,
34+
a[href^="https://"]::after {
35+
content: "";
36+
display: inline-block;
37+
width: 0.875em;
38+
height: 0.875em;
39+
margin-left: 0.25em;
40+
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="%23525252"><path d="M14 2.5a.5.5 0 0 0-.5-.5h-6a.5.5 0 0 0 0 1h4.793L2.146 13.146a.5.5 0 0 0 .708.708L13 3.707V8.5a.5.5 0 0 0 1 0z"/></svg>');
41+
background-repeat: no-repeat;
42+
background-size: contain;
43+
vertical-align: text-bottom;
44+
}
45+
46+
/* Dark mode external link icon - lighter color for better contrast */
47+
[data-theme='dark'] a[href^="http://"]::after,
48+
[data-theme='dark'] a[href^="https://"]::after {
49+
background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="%23b4b4b4"><path d="M14 2.5a.5.5 0 0 0-.5-.5h-6a.5.5 0 0 0 0 1h4.793L2.146 13.146a.5.5 0 0 0 .708.708L13 3.707V8.5a.5.5 0 0 0 1 0z"/></svg>');
50+
}

0 commit comments

Comments
 (0)