fix: icons

This commit is contained in:
2026-03-13 11:53:41 +08:00
parent 9e8d4e6388
commit 97923c8d35
6 changed files with 20 additions and 14 deletions
+1 -1
View File
@@ -35,7 +35,7 @@ const marked = new Marked()
// :[blah] becomes <i class="icon icon-blah"></i>
renderer(token) {
if (!token.meta.name) {
const style = globalIconPrefix ? `style="--icon-src: url('${globalIconPrefix}${token.text}.png')"` : '';
const style = globalIconPrefix ? `style="--icon-src: url('${globalIconPrefix}/${token.text}.png')"` : '';
return `<icon ${style} class="icon-${token.text}"></icon>`;
}
return false;