Implementing highlighting.
h3rald h3rald@h3rald.com
Sat, 17 Feb 2024 20:53:18 +0000
2 files changed,
2 insertions(+),
1 deletions(-)
M
assets/styles/chroma.css
→
assets/styles/chroma.css
@@ -6,6 +6,7 @@
.chroma { color: #e6edf3; background-color: #0d1117; + white-space: pre-wrap; } .chroma .err {
M
rules.min
→
rules.min
@@ -108,7 +108,7 @@ "echo \"$#\" | chroma --html --html-only" :cmd
text "<pre>\s*<code[^>]*>([\s\S]+?)</code></pre>" ( :match match 1 get escape :code - cmd (code) =% run /output puts ;:out + cmd (code) =% run /output ;:out ;"<code class=\"chroma\">$#</code>" (out) =% ) replace-apply @result