'use client';

import Image from 'next/image';

type Props = {
	type?: number;
};

export default function Loading({ type = 1 }: Props) {
	return (
		<>
		{ type === 1 && (
			<div className='absolute h-full inset-0 flex items-center justify-center bg-black bg-opacity-30 z-50'>
				<Image src='/resources/loading.gif' alt='준비 중...' width={64} height={64} />
			</div>
		)}

		{ type === 2 && (
			<div className='w-full flex items-center justify-center my-4'>
				<Image src='/resources/loading.gif' alt='준비 중...' width={32} height={32} />
			</div>
		)}
		</>
	);
}