Files
9router/src/app/layout.js
T
decolua bee8dad946 feat(db): migrate from lowdb to SQLite with repos pattern
- Add modular DB layer (adapters, migrations, repos, helpers)
- Replace localDb/usageDb/requestDetailsDb monoliths with repos
- Add Tailscale tunnel integration & status check API
- Add /api/cli-tools/all-statuses aggregated endpoint
- Add settingsStore (Zustand) and mitm/dbReader
- Add DB unit tests (benchmark, concurrent, migration, vs-lowdb)
2026-05-09 17:48:20 +07:00

63 lines
2.2 KiB
JavaScript

import { Inter } from "next/font/google";
import "./globals.css";
import { ThemeProvider } from "@/shared/components/ThemeProvider";
import "@/lib/initCloudSync"; // Auto-initialize cloud sync
import "@/lib/network/initOutboundProxy"; // Auto-initialize outbound proxy env
import { initConsoleLogCapture } from "@/lib/consoleLogBuffer";
import { RuntimeI18nProvider } from "@/i18n/RuntimeI18nProvider";
// Hook console immediately at module load time (server-side only, runs once)
initConsoleLogCapture();
const inter = Inter({
subsets: ["latin"],
variable: "--font-inter",
});
export const metadata = {
title: "9Router - AI Infrastructure Management",
description: "One endpoint for all your AI providers. Manage keys, monitor usage, and scale effortlessly.",
icons: {
icon: "/favicon.svg",
},
};
export const viewport = {
themeColor: "#0a0a0a",
};
export default function RootLayout({ children }) {
return (
<html lang="en" suppressHydrationWarning>
<head>
<link rel="preconnect" href="https://fonts.gstatic.com" crossOrigin="anonymous" />
{/* Non-blocking icon font: preload + inject stylesheet via script */}
<link
rel="preload"
as="style"
href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=swap"
/>
<script
dangerouslySetInnerHTML={{
__html: `(function(){var l=document.createElement('link');l.rel='stylesheet';l.href='https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=swap';document.head.appendChild(l);})();`,
}}
/>
<noscript>
{/* eslint-disable-next-line @next/next/no-page-custom-font */}
<link
href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200&display=swap"
rel="stylesheet"
/>
</noscript>
</head>
<body className={`${inter.variable} font-sans antialiased`}>
<ThemeProvider>
<RuntimeI18nProvider>
{children}
</RuntimeI18nProvider>
</ThemeProvider>
</body>
</html>
);
}