feat: add minimal footer to protected layout
All checks were successful
Build MIPS Binary / build (push) Successful in 5m23s

This commit is contained in:
spinline
2026-02-12 22:23:20 +03:00
parent 155dd07193
commit e5a68fb630
3 changed files with 37 additions and 2 deletions

View File

@@ -0,0 +1,30 @@
use leptos::prelude::*;
use crate::components::ui::separator::Separator;
#[component]
pub fn Footer() -> impl IntoView {
let year = chrono::Local::now().format("%Y").to_string();
view! {
<footer class="mt-auto px-4 py-6 md:px-8">
<Separator class="mb-6 opacity-50" />
<div class="flex flex-col items-center justify-between gap-4 md:flex-row">
<p class="text-center text-sm leading-loose text-muted-foreground md:text-left">
{format!("© {} VibeTorrent. Tüm hakları saklıdır.", year)}
</p>
<div class="flex items-center gap-4 text-sm font-medium text-muted-foreground">
<a
href="https://git.karatatar.com/admin/vibetorrent"
target="_blank"
rel="noreferrer"
class="underline underline-offset-4 hover:text-foreground transition-colors"
>
"Gitea"
</a>
<span class="size-1 rounded-full bg-muted-foreground/30" />
<span class="text-[10px] tracking-widest uppercase opacity-70">"v3.0.0-beta"</span>
</div>
</div>
</footer>
}
}

View File

@@ -1,3 +1,4 @@
pub mod sidebar;
pub mod toolbar;
pub mod footer;
pub mod protected;

View File

@@ -1,6 +1,7 @@
use leptos::prelude::*;
use crate::components::layout::sidebar::Sidebar;
use crate::components::layout::toolbar::Toolbar;
use crate::components::layout::footer::Footer;
use crate::components::ui::sidenav::{SidenavWrapper, Sidenav, SidenavInset};
#[component]
@@ -18,8 +19,11 @@ pub fn Protected(children: Children) -> impl IntoView {
<Toolbar />
// Ana İçerik
<main class="flex-1 overflow-hidden relative bg-background">
<main class="flex-1 overflow-y-auto relative bg-background flex flex-col">
<div class="flex-1">
{children()}
</div>
<Footer />
</main>
</SidenavInset>
</SidenavWrapper>