chtx
March 21, 2024, 2:11pm
1
Hello,
After the most recent update of the desktop app this simple code stopped working:
.theme-dark {
--link-color: orange;
--link-color-hover: rgb(254, 204, 111);
--link-external-color: deepskyblue;
--link-external-color-hover: rgb(139, 222, 249);
}
To be more precise, the external links in the editor mode get the color from --link-color
instead of --link-external-color
. When clicked or hoovered, the external link color is correct in the editor mode. In the preview mode, everything is correct too.
I use the default theme.
I don’t know if that’s a bug or a breaking change. Anyway, I want my external links in a different color back. Please help.
Thank you.
1 Like
It’s a bug and has been reported here:
The --link-external-color variable broke for me in 1.5.11, others might be affected too.
Here’s my snippet:
body {
--link-external-color: #66b1fa;
}
Here’s the sandbox vault, with live preview on the left, reading view on the right, where it does still work.
[image]
They were able to reproduce it as you can see from the repro
tag, so the devs are aware.
Maybe some of the CSS here can help a bit until the issue is resolved in a future release:
Give this version a try with all the :hovers separated out:
body:is(.theme-dark, .theme-light) {
--link-color: #7593ce;
--link-color-hover: #ecddd3;
}
a.external-link,
.markdown-source-view.mod-cm6
:is(.cm-link, .cm-url, .cm-link .cm-underline, .cm-url .cm-underline) {
color: pink;
}
a.external-link:hover,
.markdown-source-view.mod-cm6
:is(.cm-link:hover, .cm-url:hover, .cm-link .cm-underline:hover, .cm-url .cm-underline:hover) {
color: #ecddd3;
}
[CleanShot …