Skip to content

Commit

Permalink
Remove unused footer
Browse files Browse the repository at this point in the history
Signed-off-by: Kipruto <[email protected]>
  • Loading branch information
kelvinkipruto committed Aug 30, 2024
1 parent 7f06ec6 commit 4d7b5fb
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 398 deletions.
136 changes: 0 additions & 136 deletions apps/climatemappedafrica/src/components/Footer/index.js

This file was deleted.

64 changes: 0 additions & 64 deletions apps/climatemappedafrica/src/components/Footer/index.stories.js

This file was deleted.

128 changes: 0 additions & 128 deletions apps/climatemappedafrica/src/components/Footer/useStyles.js

This file was deleted.

8 changes: 0 additions & 8 deletions apps/climatemappedafrica/src/components/Page/Base.js
Original file line number Diff line number Diff line change
@@ -1,27 +1,20 @@
import { useMediaQuery } from "@mui/material";
import { useTheme } from "@mui/material/styles";
import { NextSeo } from "next-seo";
import PropTypes from "prop-types";
import React from "react";

import Footer from "@/climatemappedafrica/components/Footer";
import Navigation from "@/climatemappedafrica/components/Navigation";
import { navigationArgs } from "@/climatemappedafrica/config";
import getFooterMenu from "@/climatemappedafrica/functions/menus/getFooterMenu";
import getNavigationMenu from "@/climatemappedafrica/functions/menus/getNavigationMenu";

/**
* Base page that can be used to build all other pages.
*/
function BasePage({ children, menus, variant, post, ...props }) {
const seo = {};
const footerProps = getFooterMenu(menus?.footerMenu || []);
const navigation = getNavigationMenu(menus?.primaryMenu || []);
const { menuProps, socialLinks } = navigation;
const { desktopLogoProps, mobileLogoProps, drawerLogoProps } = navigationArgs;
const theme = useTheme();

const isDesktop = useMediaQuery(theme.breakpoints.up("lg"));
const navigationProps = {
...props,
...menus,
Expand Down Expand Up @@ -60,7 +53,6 @@ function BasePage({ children, menus, variant, post, ...props }) {
noindex={seo?.metaRobotsNoindex !== "index"}
/>
{children}
{!(variant === "explore" && isDesktop) && <Footer {...footerProps} />}
</>
);
}
Expand Down
Loading

0 comments on commit 4d7b5fb

Please sign in to comment.