Skip to content

Commit a676ede

Browse files
committed
Create layouts for landing and content pages
1 parent db0d4b5 commit a676ede

File tree

4 files changed

+36
-0
lines changed

4 files changed

+36
-0
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import { HiveInnerLayout } from '../../components/hive-layout/hive-inner-layout';
2+
import '@theguild/components/style.css';
3+
4+
export default function RootLayout({ children }: { children: React.ReactNode }) {
5+
return <HiveInnerLayout isLanding={false}>{children}</HiveInnerLayout>;
6+
}
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import { HiveInnerLayout } from '../../components/hive-layout/hive-inner-layout';
2+
import '@theguild/components/style.css';
3+
4+
export default function RootLayout({ children }: { children: React.ReactNode }) {
5+
return <HiveInnerLayout isLanding>{children}</HiveInnerLayout>;
6+
}

website/src/app/layout.tsx

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import localFont from 'next/font/local';
2+
import { PRODUCTS } from '@theguild/components';
3+
import { getDefaultMetadata } from '@theguild/components/server';
4+
import { HiveOuterLayout } from '../components/hive-layout/hive-outer-layout';
5+
import '@theguild/components/style.css';
6+
7+
export const metadata = getDefaultMetadata({
8+
productName: PRODUCTS.MESH.name,
9+
websiteName: PRODUCTS.MESH.name,
10+
description: 'A fully-featured GraphQL gateway framework',
11+
});
12+
13+
const neueMontreal = localFont({
14+
src: [
15+
{ path: '../fonts/PPNeueMontreal-Regular.woff2', weight: '400' },
16+
{ path: '../fonts/PPNeueMontreal-Medium.woff2', weight: '500' },
17+
{ path: '../fonts/PPNeueMontreal-Medium.woff2', weight: '600' },
18+
],
19+
});
20+
21+
export default function RootLayout({ children }: { children: React.ReactNode }) {
22+
return <HiveOuterLayout font={neueMontreal}>{children}</HiveOuterLayout>;
23+
}

website/src/components/hive-layout/hive-outer-layout.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export interface HiveOuterLayoutProps {
77
font: NextFont;
88
}
99

10+
// We'll promote this to Components if the reviewers (probably Dima) like the idea.
1011
export function HiveOuterLayout({ children, font }: HiveOuterLayoutProps) {
1112
return (
1213
<html

0 commit comments

Comments
 (0)