Fix bug in number of spaces in rainbows
This commit is contained in:
parent
87b394abec
commit
ae3e7e2ad9
@ -70,6 +70,7 @@ func (r *RainbowRenderer) RenderNode(w io.Writer, node *blackfriday.Node, enteri
|
|||||||
runes := graphemes.Runes()
|
runes := graphemes.Runes()
|
||||||
if len(runes) == 1 && unicode.IsSpace(runes[0]) {
|
if len(runes) == 1 && unicode.IsSpace(runes[0]) {
|
||||||
buf.WriteRune(runes[0])
|
buf.WriteRune(runes[0])
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
_, _ = fmt.Fprintf(&buf, "<font color=\"%s\">%s</font>", r.ColorID, graphemes.Str())
|
_, _ = fmt.Fprintf(&buf, "<font color=\"%s\">%s</font>", r.ColorID, graphemes.Str())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user