all repos — h3rald @ 4d70af2b7ba8984efcc31c0a2782ce512818eb4a

The sources of https://h3rald.com

Implementing highlighting.
h3rald h3rald@h3rald.com
Sat, 17 Feb 2024 20:53:18 +0000
commit

4d70af2b7ba8984efcc31c0a2782ce512818eb4a

parent

c88d4d815569086d4562bf71e172eb5a61bc2dff

2 files changed, 2 insertions(+), 1 deletions(-)

jump to
M assets/styles/chroma.cssassets/styles/chroma.css

@@ -6,6 +6,7 @@

.chroma { color: #e6edf3; background-color: #0d1117; + white-space: pre-wrap; } .chroma .err {
M rules.minrules.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