Skip to content

Commit

Permalink
maint: updated banner with new tonwhall link (#855)
Browse files Browse the repository at this point in the history
* maint: updated banner with new tonwhall link

* fix: update hover color
  • Loading branch information
nicoalee authored Nov 20, 2024
1 parent 92d3826 commit a53c43c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions compose/neurosynth-frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import Navbar from "components/Navbar/Navbar";
import useGetToken from "./hooks/useGetToken";
import BaseNavigation from "pages/BaseNavigation/BaseNavigation";
import { useLocation } from "react-router-dom";
import Downbanner from "components/Downbanner";
import Banner from "components/Downbanner";

const queryClient = new QueryClient({
defaultOptions: {
Expand Down Expand Up @@ -71,7 +71,7 @@ function App() {
</IconButton>
)}
>
<Downbanner />
<Banner />
<Navbar />
<BaseNavigation />
</SnackbarProvider>
Expand Down
16 changes: 8 additions & 8 deletions compose/neurosynth-frontend/src/components/Downbanner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import { Box, IconButton, Link } from "@mui/material";
import BaseNavigationStyles from "pages/BaseNavigation/BaseNavigation.styles";
import { useState } from "react";

const localStorageDownBannerKey = "hide-downbanner-nov-6-2024";
const localStorageBannerKey = "hide-banner-nov-20-2024";

const Downbanner: React.FC = () => {
const shouldHide = !!localStorage.getItem(localStorageDownBannerKey);
const Banner: React.FC = () => {
const shouldHide = !!localStorage.getItem(localStorageBannerKey);
const [hideBanner, setHideBanner] = useState(shouldHide);

if (hideBanner) return <></>;
Expand All @@ -34,25 +34,25 @@ const Downbanner: React.FC = () => {
>
<Box display="flex" alignItems="center">
<EmojiPeopleIcon sx={{ mr: "1rem" }} />
Join us next Wednesday, November 13th at 19:00 ET for the inaugural
Join us next Wednesday, December 4th 2024 at 10:00 ET for the
Neurosynth Compose Virtual Town Hall!{" "}
<Link
color="primary.contrastText"
sx={{ marginLeft: "4px" }}
href="https://smmo1.mjt.lu/lnk/AUUAAFUYj_MAAAAYAkQAAMQWKMIAAAABy9QAAd5pACejZgBnKVfVT2hXpDCyQC6H3aykCv_XyAAbJus/1/mr5Wo-0t0LWaATWN2bFHLA/aHR0cHM6Ly90YWxseS5zby9yLzN5cWIwNA"
href="https://tally.so/r/nWePVR"
target="_blank"
>
Click here to register
</Link>
</Box>
<IconButton
onClick={() => {
localStorage.setItem(localStorageDownBannerKey, "true");
localStorage.setItem(localStorageBannerKey, "true");
setHideBanner(true);
}}
sx={{
padding: 0,
":hover": { backgroundColor: "secondary.light" },
":hover": { backgroundColor: "gray" },
}}
>
<Cancel />
Expand All @@ -62,4 +62,4 @@ const Downbanner: React.FC = () => {
);
};

export default Downbanner;
export default Banner;

0 comments on commit a53c43c

Please sign in to comment.