Add side drawer to display feature guide

This commit is contained in:
Nilay Majorwar
2022-02-22 02:17:55 +05:30
parent 1d8413cc7d
commit 9dcfad555d
10 changed files with 274 additions and 14 deletions
+8 -2
View File
@@ -1,5 +1,5 @@
import React from "react";
import { NextPage } from "next";
import { NextPageWithLayout } from "./_app";
import Head from "next/head";
import logoImg from "../ui/assets/logo.png";
import Image from "next/image";
@@ -8,6 +8,7 @@ import Link from "next/link";
import { useDarkMode } from "../ui/providers/dark-mode-provider";
import LANGUAGES from "./languages.json";
import { GitHubIcon } from "../ui/custom-icons";
import { Providers } from "../ui/providers";
const REPO_URL = "https://github.com/nilaymaj/esolang-park";
const WIKI_URL = REPO_URL + "/wiki";
@@ -50,7 +51,7 @@ const styles = {
},
};
const Index: NextPage = () => {
const Index: NextPageWithLayout = () => {
const DarkMode = useDarkMode();
const backgroundColor = DarkMode.isDark ? Colors.DARK_GRAY3 : Colors.WHITE;
@@ -113,4 +114,9 @@ const Index: NextPage = () => {
);
};
// Feature guide should not be shown on the home page
Index.getLayout = function getLayout(page: React.ReactNode) {
return <Providers omitFeatureGuide={true}>{page}</Providers>;
};
export default Index;