Merge branch 'homepage-refactoring' into 'dev'
Homepage Refactoring - Pt .3 See merge request rheinsw/website!28
This commit is contained in:
@@ -6,9 +6,10 @@ import Footer from "@/components/Footer/Footer";
|
||||
import {ThemeProvider} from "@/components/provider/ThemeProvider";
|
||||
import React from "react";
|
||||
import {cookies} from "next/headers";
|
||||
import {themeColors} from "@/components/Helper/ThemeColors";
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: "Rhein Software",
|
||||
title: "Kontakt | Rhein Software",
|
||||
description: "Rhein Software Development",
|
||||
};
|
||||
|
||||
@@ -19,11 +20,12 @@ export default async function RootLayout({
|
||||
}>) {
|
||||
const cookieStore = await cookies();
|
||||
const theme = cookieStore.get("theme")?.value === "dark" ? "dark" : "light";
|
||||
const bgColor = themeColors[theme].primaryBg;
|
||||
|
||||
return (
|
||||
<html lang="de" data-theme={theme}>
|
||||
<head/>
|
||||
<body className="antialiased" style={{backgroundColor: "var(--primary-bg)"}}>
|
||||
<body className="antialiased" style={{backgroundColor: bgColor}}>
|
||||
<ThemeProvider>
|
||||
<Nav/>
|
||||
{children}
|
||||
|
||||
Reference in New Issue
Block a user