Files
plane/web/app/layout.tsx
Prateek Shourya 98fee2ac1d refactor: move web utils to packages (#3353)
* refactor: move web utils to packages

* fix: build and lint errors

* chore: update drag handle plugin

* chore: update table cell type to fix build errors

* fix: build errors

* chore: sync few changes

* feat: add pi base url to constants

* chore: update all util imports in ee folder

* chore: refactor web utils imports

* chore: update imports

* fix: build errors

* fix: build errors

* fix: update utils import

* chore: minor fixes related to duplicate assets imports

* chore: update duplicate assets service

* [WEB-4316] chore: new endpoints to download an asset (#7207)

* chore: new endpoints to download an asset

* chore: add exception handling

* [WEB-4323] refactor: Analytics refactor (#7213)

* chore: updated label for epics

* chore: improved export logic

* refactor: move csvConfig to export.ts and clean up export logic

* refactor: remove unused CSV export logic from WorkItemsInsightTable component

* refactor: streamline data handling in InsightTable component for improved rendering

* feat: add translation for "No. of {entity}" and update priority chart y-axis label to use new translation

* refactor: cleaned up some component and added utilitites

* feat: add "at_risk" translation to multiple languages in translations.json files

* refactor: update TrendPiece component to use new status variants for analytics

* fix: adjust TrendPiece component logic for on-track and off-track status

* refactor: use nullish coalescing operator for yAxis.dx in line and scatter charts

* feat: add "at_risk" translation to various languages in translations.json files

* feat: add "no_of" translation to various languages in translations.json files

* feat: update "at_risk" translation in Ukrainian, Vietnamese, and Chinese locales in translations.json files

* refactor: rename insightsFields to ANALYTICS_INSIGHTS_FIELDS and update analytics tab import to use getAnalyticsTabs function

* feat: update AnalyticsWrapper to use i18n for titles and add new translation for "no_of" in Russian

* fix: update yAxis labels and offsets in various charts to use new translation key and improve layout

* feat: define AnalyticsTab interface and refactor getAnalyticsTabs function for improved type safety

* fix: update AnalyticsTab interface to use TAnalyticsTabsBase for improved type safety

* fix: add whitespace-nowrap class to TableHead for improved header layout in DataTable component

* [WEB-4311]  fix: membership data handling and state reversal on error (#7205)

* [WEB-4231] Pie chart tooltip #7192

* fix: build errors

* fix: utils imports

* chore: fix build errors

* yarn lock file update

---------

Co-authored-by: Aaryan Khandelwal <65252264+aaryan610@users.noreply.github.com>
Co-authored-by: JayashTripathy <76092296+JayashTripathy@users.noreply.github.com>
Co-authored-by: sriram veeraghanta <veeraghanta.sriram@gmail.com>
2025-06-16 17:26:28 +05:30

113 lines
4.3 KiB
TypeScript

import { Metadata, Viewport } from "next";
import Script from "next/script";
// styles
import "@/styles/globals.css";
// plane imports
import { SITE_DESCRIPTION, SITE_NAME } from "@plane/constants";
import { cn } from "@plane/utils";
// plane web imports
import { DesktopAppProviderRoot } from "@/plane-web/components/desktop";
import { TrialBanner } from "@/plane-web/components/license";
// local
import { AppProvider } from "./provider";
export const metadata: Metadata = {
title: "Plane | Simple, extensible, open-source project management tool.",
description: SITE_DESCRIPTION,
metadataBase: new URL("https://app.plane.so"),
openGraph: {
title: "Plane | Simple, extensible, open-source project management tool.",
description: "Open-source project management tool to manage work items, cycles, and product roadmaps easily",
url: "https://app.plane.so/",
images: [
{
url: "/og-image.png",
width: 1200,
height: 630,
alt: "Plane - Modern project management",
},
],
},
keywords:
"software development, plan, ship, software, accelerate, code management, release management, project management, work item tracking, agile, scrum, kanban, collaboration",
twitter: {
site: "@planepowers",
card: "summary_large_image",
images: [
{
url: "/og-image.png",
width: 1200,
height: 630,
alt: "Plane - Modern project management",
},
],
},
};
export const viewport: Viewport = {
minimumScale: 1,
initialScale: 1,
maximumScale: 1,
userScalable: false,
width: "device-width",
viewportFit: "cover",
};
export default function RootLayout({ children }: { children: React.ReactNode }) {
const isSessionRecorderEnabled = parseInt(process.env.NEXT_PUBLIC_ENABLE_SESSION_RECORDER || "0");
return (
<html lang="en">
<head>
<meta name="theme-color" content="#fff" />
<link rel="icon" type="image/png" sizes="32x32" href="/favicon/favicon-32x32.png" />
<link rel="icon" type="image/png" sizes="16x16" href="/favicon/favicon-16x16.png" />
<link rel="manifest" href="/site.webmanifest.json" />
<link rel="shortcut icon" href="/favicon/favicon.ico" />
{/* Meta info for PWA */}
<meta name="application-name" content="Plane" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="default" />
<meta name="apple-mobile-web-app-title" content={SITE_NAME} />
<meta name="format-detection" content="telephone=no" />
<meta name="mobile-web-app-capable" content="yes" />
<link rel="apple-touch-icon" href="/icons/icon-512x512.png" />
<link rel="apple-touch-icon" sizes="152x152" href="/icons/icon-152x152.png" />
<link rel="apple-touch-icon" sizes="180x180" href="/icons/icon-180x180.png" />
<link rel="apple-touch-icon" sizes="512x512" href="/icons/icon-512x512.png" />
<link rel="manifest" href="/manifest.json" />
</head>
<body>
<div id="context-menu-portal" />
<div id="editor-portal" />
<AppProvider>
<DesktopAppProviderRoot />
<div
className={cn(
"h-screen w-full overflow-hidden bg-custom-background-100 relative flex flex-col",
"app-container"
)}
>
{/* free trial banner */}
<TrialBanner />
<main className="w-full h-full overflow-hidden relative">{children}</main>
</div>
</AppProvider>
</body>
{process.env.NEXT_PUBLIC_PLAUSIBLE_DOMAIN && (
<Script defer data-domain={process.env.NEXT_PUBLIC_PLAUSIBLE_DOMAIN} src="https://plausible.io/js/script.js" />
)}
{!!isSessionRecorderEnabled && process.env.NEXT_PUBLIC_SESSION_RECORDER_KEY && (
<Script id="clarity-tracking">
{`(function(c,l,a,r,i,t,y){
c[a]=c[a]||function(){(c[a].q=c[a].q||[]).push(arguments)};
t=l.createElement(r);t.async=1;t.src="https://www.clarity.ms/tag/"+i;
y=l.getElementsByTagName(r)[0];if(y){y.parentNode.insertBefore(t,y);}
})(window, document, "clarity", "script", "${process.env.NEXT_PUBLIC_SESSION_RECORDER_KEY}");`}
</Script>
)}
</html>
);
}