From 02521fb50975155400783fa5f5ea453715804fe0 Mon Sep 17 00:00:00 2001 From: Aditya Thakral Date: Sun, 22 Aug 2021 23:39:10 -0400 Subject: [PATCH] Create code of conduct --- pages/about/code-of-conduct.mdx | 1 - pages/about/code-of-conduct.tsx | 14 ++++++++++++++ pages/about/code-of-conduct/[section].tsx | 16 ++++++++++++++++ public/images/code-of-conduct.svg | 9 +++++++++ 4 files changed, 39 insertions(+), 1 deletion(-) delete mode 100644 pages/about/code-of-conduct.mdx create mode 100644 pages/about/code-of-conduct.tsx create mode 100644 pages/about/code-of-conduct/[section].tsx create mode 100644 public/images/code-of-conduct.svg diff --git a/pages/about/code-of-conduct.mdx b/pages/about/code-of-conduct.mdx deleted file mode 100644 index 529e4fdb..00000000 --- a/pages/about/code-of-conduct.mdx +++ /dev/null @@ -1 +0,0 @@ -# Code of Conduct page diff --git a/pages/about/code-of-conduct.tsx b/pages/about/code-of-conduct.tsx new file mode 100644 index 00000000..a68d5dc4 --- /dev/null +++ b/pages/about/code-of-conduct.tsx @@ -0,0 +1,14 @@ +import path from "path"; + +import { createReadAllPage } from "@/components/OrganizedContent/ReadAll"; +import { createReadAllGetStaticProps } from "@/components/OrganizedContent/static"; + +export const CODE_OF_CONDUCT_PAGE = path.join("about", "code-of-conduct"); + +export default createReadAllPage({ + title: "Code of Conduct", + image: "images/code-of-conduct.svg", + pagePath: CODE_OF_CONDUCT_PAGE, +}); + +export const getStaticProps = createReadAllGetStaticProps(CODE_OF_CONDUCT_PAGE); diff --git a/pages/about/code-of-conduct/[section].tsx b/pages/about/code-of-conduct/[section].tsx new file mode 100644 index 00000000..0aa7c957 --- /dev/null +++ b/pages/about/code-of-conduct/[section].tsx @@ -0,0 +1,16 @@ +import { createSectionPage } from "@/components/OrganizedContent/Section"; +import { + createSectionGetStaticPaths, + createSectionGetStaticProps, +} from "@/components/OrganizedContent/static"; + +import { CODE_OF_CONDUCT_PAGE } from "../code-of-conduct"; + +export default createSectionPage({ + title: "Code of Conduct", + image: "images/code-of-conduct.svg", + pagePath: CODE_OF_CONDUCT_PAGE, +}); + +export const getStaticProps = createSectionGetStaticProps(CODE_OF_CONDUCT_PAGE); +export const getStaticPaths = createSectionGetStaticPaths(CODE_OF_CONDUCT_PAGE); diff --git a/public/images/code-of-conduct.svg b/public/images/code-of-conduct.svg new file mode 100644 index 00000000..73307da7 --- /dev/null +++ b/public/images/code-of-conduct.svg @@ -0,0 +1,9 @@ + + + + + + + + +