export const handleColumns = (columns: number) => {
  let classes: object = {}

  switch (columns) {
    case 1:
      classes = {
        default: 'grid-cols-1 gap-4',
      }
      break
    case 2:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-2',
      }
      break
    case 3:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-2',
        lg: 'lg:grid-cols-3',
      }
      break
    case 4:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-2',
        lg: 'lg:grid-cols-4',
      }
      break
    case 5:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-4',
        lg: 'lg:grid-cols-5',
      }
      break
    case 6:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-2',
        md: 'md:grid-cols-4',
        lg: 'lg:grid-cols-6',
      }
      break
    case 7:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-4',
        lg: 'lg:grid-cols-7',
      }
      break
    case 8:
      classes = {
        default: 'grid-cols-2',
        sm: 'sm:grid-cols-1 gap-4',
        md: 'md:grid-cols-4',
        lg: 'lg:grid-cols-8',
      }
      break
    default:
      classes = {
        default: 'grid-cols-1',
        sm: 'sm:grid-cols-2 gap-4',
        md: 'md:grid-cols-3',
        lg: 'lg:grid-cols-4',
      }
  }

  return classes
}
