diff --git a/Dockerfile b/Dockerfile index 096adf664..e1e76012b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:12-alpine +FROM node:16.16.0-alpine RUN apk add --update bash diff --git a/client/pages/banned.tsx b/client/app/banned/page.tsx similarity index 65% rename from client/pages/banned.tsx rename to client/app/banned/page.tsx index 00ad00dae..9ddfc4a31 100644 --- a/client/pages/banned.tsx +++ b/client/app/banned/page.tsx @@ -1,15 +1,16 @@ -import getConfig from "next/config"; +"use client" + import React from "react"; -import AppWrapper from "../components/AppWrapper"; -import { H2, H4, Span } from "../components/Text"; -import Footer from "../components/Footer"; -import ALink from "../components/ALink"; -import { Col } from "../components/Layout"; +import AppWrapper from "../../components/AppWrapper"; +import { H2, H4, Span } from "../../components/Text"; +import Footer from "../../components/Footer"; +import ALink from "../../components/ALink"; +import { Col } from "../../components/Layout"; -const { publicRuntimeConfig } = getConfig(); +import { publicRuntimeConfig } from '../../../next.config'; -const BannedPage = () => { +export default function BannedPage() { return ( @@ -33,5 +34,3 @@ const BannedPage = () => { ); }; - -export default BannedPage; diff --git a/client/app/layout.tsx b/client/app/layout.tsx new file mode 100644 index 000000000..3473d7398 --- /dev/null +++ b/client/app/layout.tsx @@ -0,0 +1,72 @@ +import React from "react"; +import { publicRuntimeConfig } from '../../next.config'; +import type { Metadata } from 'next'; +import { Providers } from "../store/provider"; +import Head from "next/head"; +import { Colors } from "../consts"; +interface Props { + children: React.ReactNode; +} + +export const metadata: Metadata = { + title: `${publicRuntimeConfig.SITE_NAME} | Modern Open Source URL shortener.`, + description: `${publicRuntimeConfig.SITE_NAME} is a free and open source URL shortener with custom domains and stats.`, + openGraph: { + type: 'website', + url: `https://${publicRuntimeConfig.DEFAULT_DOMAIN}`, + title: `${publicRuntimeConfig.SITE_NAME} | Modern Open Source URL shortener.`, + description: `${publicRuntimeConfig.SITE_NAME} is a free and open source URL shortener with custom domains and stats.`, + images: [ + { + url: `https://${publicRuntimeConfig.DEFAULT_DOMAIN}/images/card.png`, + width: 1200, + height: 630, + alt: `${publicRuntimeConfig.SITE_NAME} | Modern Open Source URL shortener.`, + }, + ], + }, +} + +export default function RootLayout({ children }: { children: React.ReactNode }) { + return ( + + + + + + + + + + +