diff --git a/src/components/modules/PictureCarousel.tsx b/src/components/modules/PictureCarousel.tsx index b67d1c5..ffd8285 100644 --- a/src/components/modules/PictureCarousel.tsx +++ b/src/components/modules/PictureCarousel.tsx @@ -6,7 +6,11 @@ const images = [ "https://storage.alexav.gg/content/2f36c1dd-eaf8-4fd3-a3cd-1d25fe8f5a07.jpg", ]; -export default function PictureCarousel() { +export default function PictureCarousel({ + onClick, +}: { + onClick: (url: string) => void; +}) { return (
@@ -15,6 +19,7 @@ export default function PictureCarousel() { return ( onClick(v)} src={v} className="inline w-[200px] max-h-[100px] object-cover" /> diff --git a/src/pages/App.tsx b/src/pages/App.tsx index aac5627..010d346 100644 --- a/src/pages/App.tsx +++ b/src/pages/App.tsx @@ -10,9 +10,22 @@ import MusicComponent from "../components/info/MusicComponent"; export default function App() { const [tab, setTab] = useState("home"); + const [overlayImage, setOverlayImage] = useState(null); return ( + {overlayImage && ( +
+
+ setOverlayImage(null)} + className="w-[400px]" + src={overlayImage} + /> +
+
+ )} +
@@ -164,7 +177,9 @@ export default function App() {
{tab === "fantasy" && } - {tab === "pictures" && } + {tab === "pictures" && ( + setOverlayImage(url)} /> + )} {tab === "scores" && }