diff --git a/src/components/layout/Footer.tsx b/src/components/layout/Footer.tsx new file mode 100644 index 0000000..d83b0df --- /dev/null +++ b/src/components/layout/Footer.tsx @@ -0,0 +1,22 @@ +import { Shield } from "lucide-react"; + +export function Footer() { + return ( + + ); +} diff --git a/src/components/layout/Navbar.tsx b/src/components/layout/Navbar.tsx new file mode 100644 index 0000000..c0604ed --- /dev/null +++ b/src/components/layout/Navbar.tsx @@ -0,0 +1,44 @@ +import { Link, useNavigate } from "react-router-dom"; +import { Shield, LogOut, LayoutDashboard } from "lucide-react"; +import { useAuthStore } from "../../store/auth"; +import { Button } from "../ui/Button"; + +export function Navbar() { + const { isLoggedIn, logout } = useAuthStore(); + const navigate = useNavigate(); + const loggedIn = isLoggedIn(); + + return ( + + + + + + + + Aura Store + + + + {loggedIn ? ( + <> + + + Кабинет + + + { logout(); navigate("/"); }}> + + + > + ) : ( + <> + Войти + Подключиться + > + )} + + + + ); +} diff --git a/src/components/layout/Sidebar.tsx b/src/components/layout/Sidebar.tsx new file mode 100644 index 0000000..d32a9c3 --- /dev/null +++ b/src/components/layout/Sidebar.tsx @@ -0,0 +1,32 @@ +import { NavLink } from "react-router-dom"; +import { LayoutDashboard, Key, Smartphone, CreditCard, Globe, User } from "lucide-react"; + +const links = [ + { to: "/dashboard", icon: LayoutDashboard, label: "Обзор" }, + { to: "/dashboard/keys", icon: Key, label: "Мои ключи" }, + { to: "/dashboard/devices", icon: Smartphone, label: "Устройства" }, + { to: "/dashboard/payments", icon: CreditCard, label: "Платежи" }, + { to: "/dashboard/servers", icon: Globe, label: "Серверы" }, + { to: "/profile", icon: User, label: "Профиль" }, +]; + +export function Sidebar() { + return ( + + ); +}