Integrated the group names into the Footer.jsx
This commit is contained in:
parent
3f20e8eb42
commit
05509ddfda
@ -5,11 +5,13 @@ import {FontAwesomeIcon} from "@fortawesome/react-fontawesome";
|
||||
import {faHome, faVolumeHigh, faVolumeMute} from "@fortawesome/free-solid-svg-icons";
|
||||
import {MusicContext} from "@/common/contexts/MusicContext.jsx";
|
||||
import {useContext} from "react";
|
||||
import {GroupContext} from "@/common/contexts/GroupContext.jsx";
|
||||
|
||||
export const Footer = () => {
|
||||
const location = useLocation();
|
||||
|
||||
const {musicEnabled, setMusicEnabled} = useContext(MusicContext);
|
||||
const {groupName} = useContext(GroupContext);
|
||||
|
||||
const isLegalPage = location.pathname === "/imprint" || location.pathname === "/privacy" || location.pathname === "/end";
|
||||
const isIngame = location.pathname === "/game" || location.pathname === "/end" || location.pathname === "/create";
|
||||
@ -18,7 +20,8 @@ export const Footer = () => {
|
||||
<footer>
|
||||
<div className={"footer-left" + ((isIngame || location.pathname.startsWith("/join"))
|
||||
&& location.pathname !== "/end" ? " ingame" : "")}>
|
||||
<a title="BS2AB" href="https://www.bs2ab.de/" target="_blank" rel="noreferrer" className="glassy footer-info">
|
||||
<a title="BS2AB" href="https://www.bs2ab.de/" target="_blank" rel="noreferrer"
|
||||
className="glassy footer-info">
|
||||
<img src={Logo} alt="Logo"/>
|
||||
<h2>Erstellt in Zusammenarbeit mit BS2AB</h2>
|
||||
</a>
|
||||
@ -34,8 +37,11 @@ export const Footer = () => {
|
||||
|
||||
<div className={"glassy footer-legal" + ((isIngame || location.pathname.startsWith("/join"))
|
||||
&& location.pathname !== "/end" ? " ingame" : "")}>
|
||||
{groupName !== "" && <p>{groupName}</p>}
|
||||
{groupName === "" && <>
|
||||
<Link to={"/privacy"}>Datenschutz</Link>
|
||||
<Link to={"/imprint"}>Impressum</Link>
|
||||
</>}
|
||||
</div>
|
||||
</footer>
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user