TypeScript 98.3%
CSS 0.9%
Shell 0.7%
1import type { Metadata, Viewport } from "next";2import { Inter } from "next/font/google";3import "./globals.css";45const inter = Inter({6 subsets: ["latin"],7 display: "swap",8 variable: "--font-inter",9});1011export const metadata: Metadata = {12 title: { default: "Immbot AI — UQO", template: "%s · Immbot AI" },13 description:14 "Environnement d'apprentissage intelligent pour les cours d'évaluation immobilière IMM1003 et IMM1033 de l'Université du Québec en Outaouais.",15 icons: { icon: "/icon.svg" },16};1718export const viewport: Viewport = {19 width: "device-width",20 initialScale: 1,21 viewportFit: "cover",22 themeColor: [23 { media: "(prefers-color-scheme: light)", color: "#ffffff" },24 { media: "(prefers-color-scheme: dark)", color: "#0b1320" },25 ],26};2728// Thème CLAIR par défaut ; sombre uniquement si choisi explicitement.29const themeScript = `30(function() {31 try {32 var t = localStorage.getItem("immbot-theme") || "light";33 var dark = t === "dark" || (t === "system" && window.matchMedia("(prefers-color-scheme: dark)").matches);34 if (dark) document.documentElement.classList.add("dark");35 } catch (e) {}36})();`;3738export default function RootLayout({ children }: { children: React.ReactNode }) {39 return (40 <html lang="fr-CA" suppressHydrationWarning className={inter.variable}>41 <head>42 <script dangerouslySetInnerHTML={{ __html: themeScript }} />43 </head>44 <body className="min-h-dvh">{children}</body>45 </html>46 );47}48