Remove header and footer
This commit is contained in:
parent
31c019ff31
commit
b607bfa385
1 changed files with 2 additions and 13 deletions
|
|
@ -1,22 +1,11 @@
|
||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
import Layout from "@/components/Layout";
|
|
||||||
import CrapsGame from "@/components/CrapsGame";
|
import CrapsGame from "@/components/CrapsGame";
|
||||||
|
|
||||||
const CrapsGamePage = () => {
|
const CrapsGamePage = () => {
|
||||||
const [showBackLink, setShowBackLink] = useState(false);
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
// Check if user came from games page
|
|
||||||
const referrer = document.referrer;
|
|
||||||
if (referrer.includes('/themes/games') && !referrer.includes('/themes/games/craps-game')) {
|
|
||||||
setShowBackLink(true);
|
|
||||||
}
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Layout showBackToGames={showBackLink}>
|
<div className="min-h-screen bg-background">
|
||||||
<CrapsGame showSocialShare={true} />
|
<CrapsGame showSocialShare={true} />
|
||||||
</Layout>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue