Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| f328789529 | |||
| bb968cb42f | |||
| 89162110a5 | |||
| dbe10fd339 |
@@ -1,14 +1,15 @@
|
||||
import type { Metadata } from "next";
|
||||
import { Inter } from "next/font/google";
|
||||
import "./styles/variables.css";
|
||||
import "./styles/base.css";
|
||||
import { DM_Sans } from "next/font/google";
|
||||
|
||||
const inter = Inter({
|
||||
variable: "--font-inter", subsets: ["latin"],
|
||||
const dmSans = DM_Sans({
|
||||
variable: "--font-dm-sans", subsets: ["latin"],
|
||||
});
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: "Axis - Personal Growth Platform", description: "Map your growth across mind, body, spirit, and vocation. Track your progress and achieve true life balance."};
|
||||
title: "Axis - Personal Growth Platform", description: "Track your mind, body, spirit, and vocation in one unified system. Transform scattered self-improvement into structured, measurable progress."
|
||||
};
|
||||
|
||||
export default function RootLayout({
|
||||
children,
|
||||
@@ -17,29 +18,23 @@ export default function RootLayout({
|
||||
}) {
|
||||
return (
|
||||
<html lang="en" suppressHydrationWarning>
|
||||
<body className={`${inter.variable}`}>
|
||||
{children}
|
||||
<script
|
||||
id="lenis-script"
|
||||
dangerouslySetInnerHTML={{
|
||||
__html: `
|
||||
const html = document.documentElement;
|
||||
const body = document.body;
|
||||
let lenis;
|
||||
const initLenis = () => {
|
||||
import('https://cdn.jsdelivr.net/gh/darkroomengineering/lenis@latest/bundled/lenis.js').then(() => {
|
||||
lenis = new window.Lenis();
|
||||
function raf(time) {
|
||||
lenis.raf(time);
|
||||
requestAnimationFrame(raf);
|
||||
}
|
||||
requestAnimationFrame(raf);
|
||||
});
|
||||
};
|
||||
initLenis();
|
||||
`,
|
||||
}}
|
||||
/>
|
||||
<body className={`${dmSans.variable} antialiased`}>
|
||||
<ServiceWrapper>
|
||||
<Tag />
|
||||
{children}
|
||||
</ServiceWrapper>
|
||||
<script>
|
||||
{`
|
||||
(function() {
|
||||
try {
|
||||
const theme = localStorage.getItem('theme') || 'light';
|
||||
if (theme === 'dark') {
|
||||
document.documentElement.classList.add('dark');
|
||||
}
|
||||
} catch (e) {}
|
||||
})();
|
||||
`}
|
||||
</script>
|
||||
|
||||
<script
|
||||
dangerouslySetInnerHTML={{
|
||||
@@ -1410,4 +1405,12 @@ export default function RootLayout({
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
}
|
||||
|
||||
function ServiceWrapper({ children }: { children: React.ReactNode }) {
|
||||
return <>{children}</>;
|
||||
}
|
||||
|
||||
function Tag() {
|
||||
return null;
|
||||
}
|
||||
Reference in New Issue
Block a user