summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Bridle <bridle.benjamin@gmail.com>2025-01-08 14:15:41 +1300
committerBen Bridle <bridle.benjamin@gmail.com>2025-01-08 14:15:41 +1300
commitec6ef10964fd605d7a911fee47bc3cc0a031bdaa (patch)
tree8d98fdafce4cdb1b6893109195387505e0e38bf2
parente95af5c04968d21147aa622173b1133d9c33f12f (diff)
downloadtoaster-ec6ef10964fd605d7a911fee47bc3cc0a031bdaa.zip
Wrap table sections with <tbody>
Each section of a table is now wrapped with <tbody>, instead of just the entire table.
-rw-r--r--src/generate_html.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/generate_html.rs b/src/generate_html.rs
index 05456d0..84c3bdb 100644
--- a/src/generate_html.rs
+++ b/src/generate_html.rs
@@ -125,8 +125,8 @@ pub fn document_to_html(document: &MarkdownDocument, page: &Page, website: &Webs
tag!("th", column.name);
})
);
- wrap!("tbody", for section in &table.sections {
- for row in section {
+ for section in &table.sections {
+ wrap!("tbody", for row in section {
wrap!("tr", for (column, cell) in std::iter::zip(&table.columns, row) {
let text_raw = line_to_html!(cell);
let text = match text_raw.as_str() {
@@ -148,8 +148,8 @@ pub fn document_to_html(document: &MarkdownDocument, page: &Page, website: &Webs
};
html!("<td class='{}'>{}</td>", class, text);
})
- }
- });
+ })
+ };
})
}
}