mirror of https://github.com/status-im/NimYAML.git
server output fix
This commit is contained in:
parent
2b0e20abd0
commit
a053947f53
|
@ -5,7 +5,7 @@
|
||||||
# distribution, for details about the copyright.
|
# distribution, for details about the copyright.
|
||||||
|
|
||||||
import jester, asyncdispatch, json, streams, strutils
|
import jester, asyncdispatch, json, streams, strutils
|
||||||
import packages.docutils.rstgen, packages.docutils.highlite, options
|
import packages/docutils/rstgen, packages/docutils/highlite, options
|
||||||
import ../yaml
|
import ../yaml
|
||||||
|
|
||||||
routes:
|
routes:
|
||||||
|
@ -57,7 +57,7 @@ routes:
|
||||||
of gtNone, gtWhitespace:
|
of gtNone, gtWhitespace:
|
||||||
highlighted.add(substr(output.data, g.start, g.length + g.start - 1))
|
highlighted.add(substr(output.data, g.start, g.length + g.start - 1))
|
||||||
else:
|
else:
|
||||||
highlighted.addf("<span class=\"$2\">$1</span>", "\\span$2{$1}",
|
highlighted.addf("<span class=\"$2\">$1</span>",
|
||||||
esc(outHtml, substr(output.data, g.start, g.length+g.start-1)),
|
esc(outHtml, substr(output.data, g.start, g.length+g.start-1)),
|
||||||
tokenClassToStr[g.kind])
|
tokenClassToStr[g.kind])
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue