diff --git a/src/components/inc/GalleryTabs.tsx b/src/components/inc/GalleryTabs.tsx index 4feffb7..3d7ecbf 100644 --- a/src/components/inc/GalleryTabs.tsx +++ b/src/components/inc/GalleryTabs.tsx @@ -45,9 +45,9 @@ const GalleryTabs = () => { useState("cloud"); return ( - + - + {galleryTabs.map(({ value, name }) => { return ( @@ -66,47 +66,26 @@ const GalleryTabs = () => { - + hey ); }; -const GalleryContent = ({ tags }: { tags: string[] }) => { +const GalleryContent = () => { const [loading, setLoading] = useState(true); const getPhotos = useStore((state) => state.getPhotos); const [images, setImages] = useLocalStorage( "gallery content", undefined ); - - React.useEffect(() => { - getPhotos(10) - .then((data) => { - setLoading(false); - setImages(data); - }) - .catch(() => { - console.log("you need mobile data to get new images"); - }); - }, [tags]); return ( - {loading - ? Array.from({ length: 10 }).map((_, i) => { - return ; - }) - : images!.map((image, i) => { - return ( - - ); - })} + {Array.from({ length: 10 }).map((_, i) => { + return ; + })} );