/* eslint-disable import/prefer-default-export */
// eslint-disable-next-line import/no-extraneous-dependencies
import { lazy } from 'react';

export function getCard(type, pageType='') {
  switch (type) {
    case 'operator':
      return pageType === 'eeat' 
        ? lazy(() => import(`../components/atoms/cards/operator-card/template-five`)) 
        : lazy(() => import(`../components/atoms/cards/operator-card/template-one`));
    case 'game':
      return pageType === 'eeat' 
        ? lazy(() => import(`../components/atoms/cards/game-cards/template-six`)) 
        : lazy(() => import(`../components/atoms/cards/game-cards/template-one`));
    case 'payment_method':
      return lazy(() => import(`../components/atoms/cards/payment-method/template-one`));
    case 'software_provider':
      return lazy(() => import(`../components/atoms/cards/software-provider-card/index`));
    case 'article':
    case 'page':
      return lazy(() => import(`../components/atoms/cards/article-card/template-one`));
    case 'author':
      return lazy(() => import(`../components/atoms/cards/author/template-one`));
    default:
      return lazy(() => import(`../components/atoms/cards/article-card/template-one`));
  }
}
