From 39d610d451dc71e92949eaf4761709ed43e73aa6 Mon Sep 17 00:00:00 2001 From: fabiolalombardim Date: Fri, 20 Oct 2023 19:45:56 +0200 Subject: [PATCH] footer --- src/modules/common/Footer.tsx | 147 +++++++++++++++++++++++++++++----- 1 file changed, 129 insertions(+), 18 deletions(-) diff --git a/src/modules/common/Footer.tsx b/src/modules/common/Footer.tsx index 665e6238..45556bdc 100644 --- a/src/modules/common/Footer.tsx +++ b/src/modules/common/Footer.tsx @@ -1,5 +1,5 @@ import React from "react" -import { Grid, Typography, styled } from "@material-ui/core" +import { Grid, Typography, styled, useMediaQuery, useTheme } from "@material-ui/core" import HomeButton from "assets/logos/footer_logo.svg" import Documentation from "assets/logos/footer_documentation.svg" import Help from "assets/logos/footer_help.svg" @@ -9,6 +9,7 @@ import Github from "assets/logos/footer_github.svg" import Discord from "assets/logos/footer_discord.svg" import Youtube from "assets/logos/footer_youtube.svg" import dOrg from "assets/logos/footer_dorg.svg" +import { useTezos } from "services/beacon/hooks/useTezos" const Footer = styled(Grid)(({ theme }) => ({ width: "100%", @@ -16,7 +17,12 @@ const Footer = styled(Grid)(({ theme }) => ({ backgroundColor: "#24282d", paddingTop: 40, paddingBottom: 40, - marginTop: 32 + marginTop: 32, + [theme.breakpoints.down("sm")]: { + height: "auto", + paddingTop: 30, + paddingBottom: 30 + } })) const LogoItem = styled("img")({ @@ -24,6 +30,11 @@ const LogoItem = styled("img")({ cursor: "pointer" }) +const HomebaseLogoItem = styled("img")({ + opacity: 0.65, + cursor: "default" +}) + const ItemText = styled(Typography)({ fontSize: 15, opacity: 0.65, @@ -36,6 +47,12 @@ const DesignedByText = styled(Typography)({ fontWeight: 300 }) +const BottomContainer = styled(Grid)(({ theme }) => ({ + [theme.breakpoints.down("sm")]: { + gap: 12 + } +})) + const Container = styled(Grid)(({ theme }) => ({ margin: "auto", width: 1000, @@ -53,44 +70,138 @@ const Container = styled(Grid)(({ theme }) => ({ })) export const ExplorerFooter: React.FC = () => { + const theme = useTheme() + const isMobileSmall = useMediaQuery(theme.breakpoints.down("sm")) + const { network } = useTezos() + + const goToFAQ = () => { + window.open("https://faq.tezos-homebase.io/homebase-faq/", "_blank") + } + + const goToExplorer = () => { + return network === "ghostnet" + ? window.open("https://ghostnet.tzkt.io/", "_blank") + : window.open("https://tzkt.io/", "_blank") + } + + const goToTezos = () => { + window.open("https://tezos.com/", "_blank") + } + + const goToGithub = () => { + window.open("https://github.com/dOrgTech/homebase-app", "_blank") + } + + const goToDiscord = () => { + window.open("https://discord.com/invite/yXaPy6s5Nr", "_blank") + } + + const goToYoutube = () => { + window.open("https://www.youtube.com/@Tezos", "_blank") + } + + const goTodOrg = () => { + window.open("https://www.dorg.tech/", "_blank") + } + return ( )