Files
athome/src/layout/footer.rs
Tuan-Dat Tran 74f68eff5b chore(dioxus): Upgraded to dioxus 0.6.0
Signed-off-by: Tuan-Dat Tran <tuan-dat.tran@tudattr.dev>
2024-12-11 23:28:12 +01:00

40 lines
1.3 KiB
Rust

use dioxus::prelude::*;
use dioxus_i18n::t;
pub fn Footer() -> Element {
rsx! {
div {
class: "container mx-auto pb-4",
footer {
class:"bg-white rounded-lg shadow dark:bg-gray-800",
div {
class:"w-full mx-auto p-4 flex items-center justify-between",
span {
class:"text-sm text-gray-500 sm:text-center dark:text-gray-400",
{ t!("footer_year") },
a { href: "#", class: "hover:underline", { t!("footer_name") }},
{ t!("footer_rights") }
}
ul {
class:"flex flex-wrap items-center mt-3 text-sm font-medium text-gray-500 dark:text-gray-400 sm:mt-0",
li {
Link { to:"mailto:tuan-dat.tran@tudattr.dev", class:"hover:underline", { t!("footer_contact") } }
},
}
}
}
}
}
}
#[component]
fn Logo(src: String, alt: String) -> Element {
rsx! {
img {
class: "h-auto max-w-40 transition-all duration-300 rounded-lg cursor-pointer filter grayscale hover:grayscale-0",
src: "{src}",
alt: "{alt}"
}
}
}