import type { Metadata } from "next";
import { Inter } from "next/font/google";
import "./globals.css";
import { TrpcContextProvider } from "@/components/providers/TrpcContextProvider";
import { SessionProvider } from "@/components/providers/SessionProvider";
import { JotaiProvider } from '@/components/providers/JotaiProvider'

const inter = Inter({ subsets: ["latin"] });

export const metadata: Metadata = {
  title: "Coco Apps",
  description: "Cocorobo's Apps Platform",
};

export default function RootLayout({
  children,
}: Readonly<{
  children: React.ReactNode;
}>) {
  // const [theme] = useState("cupcake")
  const theme = "cupcake"
  return (
    <html lang="en" data-theme={theme}>
      <body className={inter.className}>
        <SessionProvider>
          <JotaiProvider>
            <TrpcContextProvider>
              {children}
            </TrpcContextProvider>
          </JotaiProvider>
        </SessionProvider>
      </body>
    </html>
  );
}
