You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
78 lines
2.1 KiB
78 lines
2.1 KiB
import type { Metadata } from "next";
|
|
import { Amiri } from "next/font/google";
|
|
import localFont from "next/font/local";
|
|
import dynamic from "next/dynamic";
|
|
import Providers from "./providers";
|
|
import "./globals.css";
|
|
|
|
const DevClickToComponent = dynamic(
|
|
() => import("@/components/dev/dev-click-to-component"),
|
|
{ ssr: false }
|
|
);
|
|
|
|
|
|
const faminela = localFont({
|
|
src: "../../public/fonts/Faminela/Faminela.otf",
|
|
variable: "--font-faminela-local",
|
|
display: "swap",
|
|
preload: true,
|
|
fallback: ["Arial", "sans-serif"],
|
|
});
|
|
|
|
const amiri = Amiri({
|
|
weight: ["400", "700"],
|
|
subsets: ["arabic"],
|
|
variable: "--font-amiri",
|
|
display: "swap",
|
|
preload: true,
|
|
fallback: ["Arial", "sans-serif"],
|
|
});
|
|
|
|
export const metadata: Metadata = {
|
|
title: "ازدواج حبیب",
|
|
description: "سامانه ازدواج اسلامی حبیب",
|
|
viewport: {
|
|
width: "device-width",
|
|
initialScale: 1,
|
|
maximumScale: 1,
|
|
},
|
|
themeColor: "#ffffff",
|
|
};
|
|
|
|
export default function RootLayout({
|
|
children,
|
|
}: Readonly<{
|
|
children: React.ReactNode;
|
|
}>) {
|
|
return (
|
|
<html lang="en">
|
|
<head>
|
|
<link rel="preconnect" href="https://habibapp.com" />
|
|
<link rel="dns-prefetch" href="https://habibapp.com" />
|
|
<script
|
|
dangerouslySetInnerHTML={{
|
|
__html: `
|
|
if (typeof window !== 'undefined') {
|
|
window.onFlutterResponse = window.onFlutterResponse || function() {};
|
|
|
|
// Performance monitoring
|
|
window.addEventListener('load', function() {
|
|
var perfData = performance.getEntriesByType('navigation')[0];
|
|
console.log('⏱️ Load time:', Math.round(perfData.loadEventEnd - perfData.fetchStart), 'ms');
|
|
});
|
|
}
|
|
`,
|
|
}}
|
|
/>
|
|
</head>
|
|
<body className={`${faminela.variable} ${amiri.variable}`}>
|
|
<Providers>
|
|
<div className="app-shell">{children}</div>
|
|
</Providers>
|
|
{process.env.NODE_ENV === "development" ? (
|
|
<DevClickToComponent />
|
|
) : null}
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|