import clsx from 'clsx'; import NextImage, { ImageProps as NextImageProps } from 'next/image'; import { useState } from 'react'; import clsxm from '~/libs/clsxm'; type ImageProps = { rounded?: string; classNames?: { wrapper: string } } & NextImageProps; const Image = (props: ImageProps) => { const { alt, src, className, classNames, rounded, ...rest } = props; const [isLoading, setLoading] = useState(true); return (
setLoading(false)} {...rest} />
); }; export default Image;