diff --git a/site/SiteAbout.tsx b/site/SiteAbout.tsx new file mode 100644 index 00000000000..768a09c84db --- /dev/null +++ b/site/SiteAbout.tsx @@ -0,0 +1,22 @@ +import * as React from "react" + +export const ABOUT_LINKS = [ + { title: "About Us", href: "/about" }, + { title: "Organization", href: "/organization" }, + { title: "Funding", href: "/funding" }, + { title: "Team", href: "/team" }, + { title: "Jobs", href: "/jobs" }, + { title: "FAQs", href: "/faqs" }, +] + +export function SiteAbout() { + return ( + + ) +} diff --git a/site/SiteMobileMenu.tsx b/site/SiteMobileMenu.tsx index 09fd1d1b94f..3baaa940574 100644 --- a/site/SiteMobileMenu.tsx +++ b/site/SiteMobileMenu.tsx @@ -3,6 +3,7 @@ import { CategoryWithEntries } from "@ourworldindata/utils" import classnames from "classnames" import { SiteNavigationToggle } from "./SiteNavigationToggle.js" import { Menu } from "./SiteNavigation.js" +import { SiteAbout } from "./SiteAbout.js" import { SiteResources } from "./SiteResources.js" import { SiteMobileCategory } from "./SiteMobileCategory.js" @@ -68,9 +69,20 @@ export const SiteMobileMenu = ({
  • - + + toggleMenu( + menu === Menu.About ? Menu.Topics : Menu.About + ) + } + dropdown={} + withCaret={true} + className="SiteNavigationToggle--lvl1" + > About - +
  • diff --git a/site/SiteNavigation.tsx b/site/SiteNavigation.tsx index f95d4ef8682..1d19b2acbc1 100644 --- a/site/SiteNavigation.tsx +++ b/site/SiteNavigation.tsx @@ -16,6 +16,7 @@ import { OwidGdocType, getOwidGdocFromJSON, } from "@ourworldindata/utils" +import { SiteAbout } from "./SiteAbout.js" import { SiteResources } from "./SiteResources.js" import { SiteSearchNavigation } from "./SiteSearchNavigation.js" import { SiteMobileMenu } from "./SiteMobileMenu.js" @@ -174,8 +175,16 @@ export const SiteNavigation = ({ Resources
  • -
  • - About +
  • + toggleMenu(Menu.About)} + dropdown={} + withCaret={true} + > + About +
  • diff --git a/site/gdocs/pages/AboutPage.tsx b/site/gdocs/pages/AboutPage.tsx index f81a7371518..9b7c30336ef 100644 --- a/site/gdocs/pages/AboutPage.tsx +++ b/site/gdocs/pages/AboutPage.tsx @@ -3,18 +3,10 @@ import { isEmpty } from "lodash" import * as React from "react" import { OwidGdocAboutInterface } from "@ourworldindata/types" +import { ABOUT_LINKS } from "../../SiteAbout.js" import { ArticleBlocks } from "../components/ArticleBlocks.js" import Footnotes from "../components/Footnotes.js" -const NAV_LINKS = [ - { title: "About Us", href: "/about" }, - { title: "Organization", href: "/organization" }, - { title: "Funding", href: "/funding" }, - { title: "Team", href: "/team" }, - { title: "Jobs", href: "/jobs" }, - { title: "FAQs", href: "/faqs" }, -] - export default function AboutPage({ content, slug }: OwidGdocAboutInterface) { return (
    @@ -39,21 +31,22 @@ function AboutNav({ slug }: { slug: string }) { return ( )