This repository has been archived on 2026-07-15. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
drive/frontend/src/app/layout.tsx
Elijah cf43dd0e5a
All checks were successful
Automated Container Build / build-and-push (push) Successful in 35s
feat: change tab title, add favicon, and fix pinned folder live refresh
2026-05-23 10:39:30 -07:00

50 lines
1.5 KiB
TypeScript

import type { Metadata } from 'next';
import './globals.css';
export const metadata: Metadata = {
title: "Eli's Drive",
description: 'A high-performance, self-hosted file storage and management platform.',
icons: {
icon: '/favicon.svg',
},
};
export default function RootLayout({
children,
}: {
children: React.ReactNode;
}) {
return (
<html lang="en" data-theme="dark" suppressHydrationWarning>
<head>
<script
dangerouslySetInnerHTML={{
__html: `
(function() {
try {
var theme = localStorage.getItem('theme');
if (theme === 'light') {
document.documentElement.setAttribute('data-theme', 'light');
document.documentElement.style.setProperty('color-scheme', 'light');
document.documentElement.classList.remove('dark');
} else {
document.documentElement.classList.add('dark');
}
} catch (e) {}
})();
`,
}}
/>
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossOrigin="anonymous" />
<link
href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap"
rel="stylesheet"
/>
</head>
<body className="antialiased">
{children}
</body>
</html>
);
}