feat(layout): login, uygulama kabuğu, alt menü, hızlı ekle ve dashboard
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
import { SidebarTrigger } from "@/components/ui/sidebar";
|
||||
import type { SessionUser } from "@/features/auth/types";
|
||||
import type { HouseholdSummary } from "@/features/households/types";
|
||||
import { tr } from "@/i18n/tr";
|
||||
import { HouseholdSwitcher } from "./household-switcher";
|
||||
import { QuickAddButton } from "./quick-add";
|
||||
import { ThemeToggle } from "./theme-toggle";
|
||||
import { UserMenu } from "./user-menu";
|
||||
|
||||
/** Üst bar: menü düğmesi (masaüstü), hane seçici, hızlı ekle, tema ve kullanıcı menüsü. */
|
||||
export function AppHeader({
|
||||
user,
|
||||
households,
|
||||
version,
|
||||
}: {
|
||||
user: SessionUser;
|
||||
households: HouseholdSummary[];
|
||||
version: string;
|
||||
}) {
|
||||
return (
|
||||
<header className="sticky top-0 z-30 flex h-14 items-center gap-2 border-b bg-background/95 px-3 backdrop-blur supports-backdrop-filter:bg-background/80 md:px-4">
|
||||
<SidebarTrigger className="hidden md:inline-flex" aria-label={tr.nav.toggleSidebar} />
|
||||
<HouseholdSwitcher households={households} />
|
||||
<div className="ml-auto flex items-center gap-1">
|
||||
<QuickAddButton className="hidden md:inline-flex" />
|
||||
<ThemeToggle />
|
||||
<UserMenu user={user} version={version} />
|
||||
</div>
|
||||
</header>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user