🎨 Use real theme style value replace var in preview mode https://github.com/siyuan-note/siyuan/issues/11458

This commit is contained in:
Daniel 2024-11-17 12:05:35 +08:00
parent 35d1c10633
commit 6dad90f821
No known key found for this signature in database
GPG key ID: 86211BA83DF03017

View file

@ -55,7 +55,7 @@ func fillThemeStyleVar(tree *parse.Tree) {
buf.WriteString(style)
buf.WriteString(": ")
value := themeStyles[name]
if strings.Contains(value, "-b3-") {
if strings.Contains(value, "var(") {
name = gulu.Str.SubStringBetween(value, "(", ")")
value = themeStyles[name]
}