"use client"; import { projects6 } from "@/data/projects"; import Image from "next/image"; import React, { useEffect } from "react"; import { Gallery, Item } from "react-photoswipe-gallery"; export default function Projects1() { const initIsotop = async () => { const Isotope = (await import("isotope-layout")).default; const imagesloaded = (await import("imagesloaded")).default; // Initialize Isotope in the mounted hook document.querySelectorAll(".isotope").forEach((elm, i) => { const isotope = new Isotope(".isotope" + i, { itemSelector: ".item", layoutMode: "masonry", // or 'fitRows', depending on your layout needs }); imagesloaded(".isotope" + i).on("progress", function (instance, image) { // Trigger Isotope layout isotope.layout(); }); }); }; useEffect(() => { ///////////////////////////////////////////////////// // Magnate Animation setTimeout(() => { initIsotop(); }, 100); }, []); return (
{projects6.map((project, i) => (
{project.category}

{project.title}

{project.description}

See Project
{project.images.map((image, index) => (
{({ ref, open }) => (
${image.title}`} > image
)}
))}
))} {/* /.project */}
{/* /.projects-tiles */}
{/* /column */}
{/* /.row */}
{/* /.container */}
); }