From 7a8b2c7619a4f60d8c485d7c9888878c2a758a51 Mon Sep 17 00:00:00 2001 From: trilium-share-gruvbox Date: Fri, 28 Aug 2026 22:09:28 +0200 Subject: [PATCH] =?UTF-8?q?Link=20styling:=20remove=20arrow=20markers=20on?= =?UTF-8?q?=20internal=20links,=20keep=20=E2=86=97=20only=20on=20external-?= =?UTF-8?q?domain=20links,=20inline=20text=20links=20colour-only,=20prev/n?= =?UTF-8?q?ext=20as=20buttons?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- theme/blog_share_theme.css | 49 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/theme/blog_share_theme.css b/theme/blog_share_theme.css index 282f161..a4b560a 100644 --- a/theme/blog_share_theme.css +++ b/theme/blog_share_theme.css @@ -1546,4 +1546,53 @@ html.theme-light pre::-webkit-scrollbar-track, html.theme-light pre.code-processed .code-wrap::-webkit-scrollbar-track, html.theme-light .hljs-ln-code::-webkit-scrollbar-track { background: #ebdbb2; +} + +/* ---------- Link icons / markers: internal links without arrow, external links keep a marker ---------- */ +#content a::after, +#content a::before, +#content-footer .navigation a::after, +#content-footer .navigation a::before, +a.next::after, +a.previous::before { + content: none !important; +} + +#content a[href^="http://"]:not([href^="https://YOUR-INSTANCE.example.com"])::after, +#content a[href^="https://"]:not([href^="https://YOUR-INSTANCE.example.com"])::after { + content: " ↗" !important; + display: inline-block; + margin-left: 3px; + font-size: 0.85em; + color: var(--text-link); +} + +/* inline text links (in paragraphs/lists): colour only */ +#content p a:not([class]), +#content li a:not([class]) { + color: var(--text-link); + text-decoration: none; + background: transparent; + border: 0; + padding: 0; + border-radius: 0; +} + +#content p a:not([class]):hover, +#content li a:not([class]):hover { + color: var(--text-heading); + background: transparent; +} + +/* action links as buttons (pagination / prev-next already boxed, blog-pn gets a box) */ +.blog-pn { + padding: 6px 14px; + border: 1px solid var(--background-highlight); + border-radius: 8px; + background: var(--background-secondary); +} + +.blog-pn:hover { + background: var(--background-highlight); + border-color: var(--text-link); } \ No newline at end of file