move emojis into locales, to be able to run maudfmt

This commit is contained in:
2025-08-03 12:20:12 +02:00
parent 811d29b9ec
commit b90590d3b5
5 changed files with 118 additions and 133 deletions

View File

@@ -47,103 +47,91 @@ impl Page {
}
pub fn content(self, content: Markup) -> Markup {
rust_i18n::set_locale(self.lang.to_locale());
html! {
(DOCTYPE)
html lang=(self.lang) {
head {
meta charset="utf-8";
meta name="viewport" content="width=device-width, initial-scale=1.0";
link rel="stylesheet" href="/static/pico.min.css";
link rel="stylesheet" href="/static/style.css";
title { "Digital Shadows" }
}
body {
header.container {
nav {
ul {
li {
a href="/" {
strong { "Digital Shadows" }
}
}
}
ul {
li {
a href="/" {
span role="img" aria-label="home" { "🏠" }
}
}
li {
a href="/game" {
span role="img" aria-label="camera" { "📸" }
}
}
li {
span id="theme_switcher" {}
}
li {
button id="lang-toggle" lang=(self.lang.next_language()) {
(self.lang.next_language())
}
}
}
}
head {
meta charset="utf-8";
meta name="viewport" content="width=device-width, initial-scale=1.0";
link rel="stylesheet" href="/static/pico.min.css";
link rel="stylesheet" href="/static/style.css";
title { "Digital Shadows" }
}
body {
header.container {
nav {
ul {
li {
a href="/" {
strong { "Digital Shadows" }
}
}
}
ul {
li {
a href="/" {
span role="img" aria-label="home" { (t!("icon_home")) }
}
}
li {
a href="/game" {
span role="img" aria-label="camera" { (t!("icon_home")) }
}
}
li {
span id="theme_switcher" {}
}
main.container {
@if let Some(found_camera) = &self.found_camera {
article class="succ w-full" {
header {
"Camera "
(found_camera)
" found"
}
"✨ You are a star ✨ Star dust sprinkle, sprinkle. "
a href="#ranking" {
"See your ranking"
}
footer {
"Rear Exit Cam"
li {
button id="lang-toggle" lang=(self.lang.next_language()) {
(self.lang.next_language())
}
}
}
}
}
@if self.new_name {
article class="name w-full" {
header {
"New name!"
main.container {
@if let Some(found_camera) = &self.found_camera {
article class="succ w-full" {
header { (t!("found_camera", name = found_camera)) }
(t!("found_camera_body"))
a href="#ranking" { "See your ranking" }
footer { (found_camera) }
}
"Welcome"
}
@if self.new_name {
article class="name w-full" {
header { "New name!" }
"Welcome"
}
}
@if let Some(err) = &self.err {
article class="error w-full" {
header { (err.0) }
(err.1)
footer { (err.2) }
}
}
section { (content) }
}
@if let Some(err) = &self.err {
article class="error w-full" {
header {
(err.0)
}
(err.1)
footer {
(err.2)
footer.container {
small {
"Footer "
mark { "to be completed" }
a href="#" { "with links" }
""
a target="_blank" href="https://www.digidow.eu/impressum/" {
"Impressum"
}
}
}
section { (content) }
script src="/static/theme.js" {}
}
footer.container {
small {
"Footer "
mark { "to be completed" }
a href="#" { "with links" }
""
a target="_blank" href="https://www.digidow.eu/impressum/" { "Impressum" }
}
}
script src="/static/theme.js" {}
}
}
}
}