import type { IUserProfileGallery } from 'src/types/user';
import Box from '@mui/material/Box';
import Card from '@mui/material/Card';
import IconButton from '@mui/material/IconButton';
import Typography from '@mui/material/Typography';
import ListItemText from '@mui/material/ListItemText';
import { fDate } from 'src/utils/format-time';
import { Image } from 'src/components/image';
import { Iconify } from 'src/components/iconify';
import { Lightbox, useLightBox } from 'src/components/lightbox';
// ----------------------------------------------------------------------
type Props = {
gallery: IUserProfileGallery[];
};
export function ProfileGallery({ gallery }: Props) {
const slides = gallery.map((slide) => ({ src: slide.imageUrl }));
const lightbox = useLightBox(slides);
return (
<>
Gallery
{gallery.map((image) => (
lightbox.onOpen(image.imageUrl)}
slotProps={{
overlay: {
sx: (theme) => ({
backgroundImage: `linear-gradient(to bottom, transparent 0%, ${theme.vars.palette.common.black} 75%)`,
}),
},
}}
/>
))}
>
);
}