summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/generate_html.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/generate_html.rs b/src/generate_html.rs
index 129e2dd..62a33b6 100644
--- a/src/generate_html.rs
+++ b/src/generate_html.rs
@@ -158,6 +158,7 @@ pub fn document_to_html(document: &MarkdownDocument, page: &Page, website: &Webs
Some(stripped) => format!("{root}{stripped}"),
None => path.to_string(),
};
+ let label = sanitize_text(label);
match extension.to_lowercase().as_str() {
"jpg"|"jpeg"|"png"|"webp"|"gif"|"tiff" => html!(
"<figure><a href='{path}'><img src='{path}' alt='{label}' title='{label}'></a></figure>"),