diff options
Diffstat (limited to 'lib/xesite_templates/src')
| -rw-r--r-- | lib/xesite_templates/src/lib.rs | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/lib/xesite_templates/src/lib.rs b/lib/xesite_templates/src/lib.rs index 4b920b8..32ec07f 100644 --- a/lib/xesite_templates/src/lib.rs +++ b/lib/xesite_templates/src/lib.rs @@ -29,11 +29,13 @@ pub fn slide(name: String, essential: bool) -> Markup { pub fn picture(path: String) -> Markup { html! { a href={"https://cdn.xeiaso.net/file/christine-static/" (path) ".jpg"} target="_blank" { - picture style="margin:0" { - source type="image/avif" srcset={"https://cdn.xeiaso.net/file/christine-static/" (path) ".avif"}; - source type="image/webp" srcset={"https://cdn.xeiaso.net/file/christine-static/" (path) ".webp"}; - img style="padding:0" loading="lazy" alt={"hero image " (path)} src={"https://cdn.xeiaso.net/file/christine-static/" (path) "-smol.png"}; - } + center { + picture style="margin:0" { + source type="image/avif" srcset={"https://cdn.xeiaso.net/file/christine-static/" (path) ".avif"}; + source type="image/webp" srcset={"https://cdn.xeiaso.net/file/christine-static/" (path) ".webp"}; + img style="padding:0" loading="lazy" alt={"hero image " (path)} src={"https://cdn.xeiaso.net/file/christine-static/" (path) "-smol.png"}; + } + } } } } @@ -59,6 +61,7 @@ pub fn hero(file: String, prompt: Option<String>, ai: Option<String>) -> Markup pub fn conv(name: String, mood: String, body: Markup) -> Markup { let name_lower = name.clone().to_lowercase(); + let name = name.replace("_", " "); html! { .conversation { |
