lms/bootstrap/ssr/assets/navbar-0cDlwmNd.js
2025-12-15 12:26:23 +01:00

73 lines
2.9 KiB
JavaScript

import { jsx, jsxs } from "react/jsx-runtime";
import { A as AppLogo } from "./app-logo-DWyi5bLn.js";
import { A as Appearance } from "./appearance-BJIqrZL5.js";
import { N as Notification } from "./notification-Bg6IzWOo.js";
import { P as ProfileToggle } from "./profile-toggle-DX74bufz.js";
import { B as Button } from "./button-CdJZJLGw.js";
import { u as useSidebar } from "./sidebar-C1tqSfnl.js";
import { u as useScreen } from "./use-screen-B7SDA5zE.js";
import { usePage, Link } from "@inertiajs/react";
import { Expand, Minimize, Menu } from "lucide-react";
import "./utils-DLCPGU0v.js";
import "clsx";
import "tailwind-merge";
import "./dropdown-menu-msun3TP8.js";
import "react";
import "@radix-ui/react-dropdown-menu";
import "./popover-Cv6Hz_y0.js";
import "@radix-ui/react-popover";
import "date-fns";
import "./scroll-area-CDdrLubh.js";
import "@radix-ui/react-scroll-area";
import "./avatar-C8iCpF5R.js";
import "@radix-ui/react-avatar";
import "nanoid";
import "@radix-ui/react-slot";
import "class-variance-authority";
import "./separator-CSqU-rrB.js";
import "@radix-ui/react-separator";
import "./sheet-BOQ-e9_C.js";
import "@radix-ui/react-dialog";
import "./tooltip-BYKuzaoQ.js";
import "@radix-ui/react-tooltip";
const Navbar = () => {
const { screen } = useScreen();
const { open, toggleSidebar } = useSidebar();
const { props } = usePage();
const { translate } = props;
const { button } = translate;
props.auth.user;
return /* @__PURE__ */ jsx("header", { className: "bg-primary dark:bg-primary-dark text-primary-foreground dark:text-primary sticky top-0 z-50 h-[60px]", children: /* @__PURE__ */ jsxs("div", { className: "flex h-full items-center justify-between gap-3 px-4 md:px-8", children: [
/* @__PURE__ */ jsx(Link, { href: "/", children: /* @__PURE__ */ jsx(AppLogo, { theme: "light" }) }),
/* @__PURE__ */ jsx("p", { className: "hidden font-semibold sm:block", children: props.course.title }),
/* @__PURE__ */ jsxs("div", { className: "mr-0 flex items-center gap-2", children: [
/* @__PURE__ */ jsx(Appearance, {}),
/* @__PURE__ */ jsx(Notification, {}),
screen > 768 && /* @__PURE__ */ jsx(
Button,
{
size: "icon",
variant: "secondary",
onClick: () => toggleSidebar(),
className: "border-secondary-light text-secondary-foreground hover:text-secondary-foreground rounded-full",
children: open ? /* @__PURE__ */ jsx(Expand, {}) : /* @__PURE__ */ jsx(Minimize, {})
}
),
/* @__PURE__ */ jsx(ProfileToggle, {}),
screen < 768 && /* @__PURE__ */ jsx(
Button,
{
size: "icon",
variant: "secondary",
onClick: () => toggleSidebar(),
className: "border-secondary-light text-secondary-foreground hover:text-secondary-foreground rounded-full",
children: /* @__PURE__ */ jsx(Menu, {})
}
)
] })
] }) });
};
export {
Navbar as default
};