fixup! 1f90bc1f72e8c6ed85c6ebcbf6bef9a319c7bee3

This commit is contained in:
Noah Hellman 2022-12-02 08:16:47 +01:00
parent 60372cda33
commit 21099a301f

View file

@ -77,7 +77,13 @@ impl<'s, I: Iterator<Item = Event<'s>>, W: std::fmt::Write> Writer<I, W> {
Container::TableCell => self.out.write_str("<td>")?,
Container::DescriptionTerm => self.out.write_str("<dt>")?,
Container::RawBlock { .. } => todo!(),
Container::CodeBlock { .. } => todo!(),
Container::CodeBlock { language } => {
if let Some(l) = language {
write!(self.out, r#"<pre><code class="language-{}">"#, l)?;
} else {
self.out.write_str("<pre><code>")?;
}
}
Container::Subscript => self.out.write_str("<sub>")?,
Container::Superscript => self.out.write_str("<sup>")?,
Container::Insert => self.out.write_str("<ins>")?,