Fix links kinda
This commit is contained in:
parent
c6b2f65171
commit
f4e63d6a5f
1 changed files with 1 additions and 2 deletions
|
@ -167,11 +167,10 @@ function highlighter(json, full = true, linkParent = false) {
|
||||||
var word = splitContent[y]
|
var word = splitContent[y]
|
||||||
|
|
||||||
if (reg.test(word)) {
|
if (reg.test(word)) {
|
||||||
|
splitContent[y] = `<span ${style} ${classes}>${splitContent[y]}</span>`
|
||||||
|
|
||||||
if (link && !linkParent) {
|
if (link && !linkParent) {
|
||||||
splitContent[y] = `<a href="${link}">${splitContent[y]}</a>`
|
splitContent[y] = `<a href="${link}">${splitContent[y]}</a>`
|
||||||
} else {
|
|
||||||
splitContent[y] = `<span ${style} ${classes}>${splitContent[y]}</span>`
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue