Files
audio-ui/app/layout.tsx

41 lines
1.2 KiB
TypeScript
Raw Normal View History

import type { Metadata } from 'next';
import './globals.css';
export const metadata: Metadata = {
title: 'Audio UI - Browser Audio Editor',
description: 'Professional audio editing in your browser. Multi-track editing, effects, recording, and more.',
keywords: ['audio editor', 'waveform editor', 'web audio', 'daw', 'music production', 'audio effects'],
};
export default function RootLayout({
children,
}: {
children: React.ReactNode;
}) {
return (
<html lang="en" suppressHydrationWarning>
<head>
<script
dangerouslySetInnerHTML={{
__html: `
(function() {
try {
const theme = localStorage.getItem('theme');
const prefersDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
const shouldBeDark = theme === 'dark' || (!theme && prefersDark);
if (shouldBeDark) {
document.documentElement.classList.add('dark');
}
} catch (e) {}
})();
`,
}}
/>
</head>
<body className="min-h-screen antialiased">
{children}
</body>
</html>
);
}