Heb er een PWA van gemaakt en layout gecorrigeerd
This commit is contained in:
+24
-5
@@ -1,5 +1,8 @@
|
||||
import type { Metadata } from "next";
|
||||
import { Geist, Geist_Mono } from "next/font/google";
|
||||
import { cookies } from "next/headers";
|
||||
import { getLocale, LOCALE_COOKIE } from "@/lib/i18n";
|
||||
import PwaRegister from "@/app/pwa-register";
|
||||
import "./globals.css";
|
||||
|
||||
const geistSans = Geist({
|
||||
@@ -13,17 +16,33 @@ const geistMono = Geist_Mono({
|
||||
});
|
||||
|
||||
export const metadata: Metadata = {
|
||||
title: "Create Next App",
|
||||
description: "Generated by create next app",
|
||||
title: "ADC BestelApp",
|
||||
description: "Bekijk artikelen uit SAP Business One.",
|
||||
applicationName: "ADC BestelApp",
|
||||
manifest: "/manifest.webmanifest",
|
||||
appleWebApp: {
|
||||
capable: true,
|
||||
title: "ADC BestelApp",
|
||||
statusBarStyle: "default",
|
||||
},
|
||||
icons: {
|
||||
icon: "/icon.svg",
|
||||
apple: "/icon.svg",
|
||||
},
|
||||
};
|
||||
|
||||
export default function RootLayout({ children }: LayoutProps<"/">) {
|
||||
export default async function RootLayout({ children }: LayoutProps<"/">) {
|
||||
const locale = getLocale((await cookies()).get(LOCALE_COOKIE)?.value);
|
||||
|
||||
return (
|
||||
<html
|
||||
lang="en"
|
||||
lang={locale === "yue" ? "yue" : locale}
|
||||
className={`${geistSans.variable} ${geistMono.variable} h-full antialiased`}
|
||||
>
|
||||
<body className="min-h-full flex flex-col">{children}</body>
|
||||
<body className="min-h-full flex flex-col">
|
||||
<PwaRegister />
|
||||
{children}
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user