mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-06-22 21:28:12 +02:00
- Updated .env.example to include new environment variables for Google authentication and global announcement settings. - Integrated Google sign-in functionality in SignInButton and HeroSection components, allowing users to log in with their Google accounts. - Added GlobalAnnouncement component to display maintenance notices or announcements on the homepage layout. - Enhanced styling for Google sign-in buttons to improve user experience.
25 lines
833 B
TypeScript
25 lines
833 B
TypeScript
"use client";
|
|
|
|
import { usePathname } from "next/navigation";
|
|
import { FooterNew } from "@/components/homepage/footer-new";
|
|
import { GlobalAnnouncement } from "@/components/homepage/global-announcement";
|
|
import { Navbar } from "@/components/homepage/navbar";
|
|
|
|
export default function HomePageLayout({ children }: { children: React.ReactNode }) {
|
|
const pathname = usePathname();
|
|
const isAuthPage = pathname === "/login" || pathname === "/register";
|
|
const isFreeModelChat = /^\/free\/[^/]+$/.test(pathname);
|
|
|
|
if (isFreeModelChat) {
|
|
return <>{children}</>;
|
|
}
|
|
|
|
return (
|
|
<main className="min-h-screen bg-linear-to-b from-gray-50 to-gray-100 text-gray-900 dark:from-black dark:to-gray-900 dark:text-white overflow-x-hidden">
|
|
<GlobalAnnouncement />
|
|
<Navbar />
|
|
{children}
|
|
{!isAuthPage && <FooterNew />}
|
|
</main>
|
|
);
|
|
}
|