Skip to content

Commit a4c5c7b

Browse files
authored
Merge pull request #26 from apriljunge/fix-wrong-text-highlighting
Behebt Fehler der Textunterstreichung
2 parents 4100091 + eeff243 commit a4c5c7b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/vegarando.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ function highlight(elem, good, text) {
3333
findAndReplaceDOMText(elem, {
3434
find: reg,
3535
wrap: "span",
36-
wrapClass: `highlight-${good ? "good" : "bad"}`
36+
wrapClass: `highlight-${good ? "good" : "bad"}`,
37+
forceContext: true
3738
})
3839
}
3940

0 commit comments

Comments
 (0)