diff --git a/components/layout/dynamic-content-manager/dynamic-content-manager.tsx b/components/layout/dynamic-content-manager/dynamic-content-manager.tsx index 8b98728c7..cc1bbbbec 100644 --- a/components/layout/dynamic-content-manager/dynamic-content-manager.tsx +++ b/components/layout/dynamic-content-manager/dynamic-content-manager.tsx @@ -1,25 +1,24 @@ 'use client'; +import { InfoCircledIcon } from '@radix-ui/react-icons'; + import BlurbSection from '@/components/modules/blurb-section/blurb-section'; import FilteredProductList from '@/components/modules/filtered-product-list/filtered-product-list'; import Hero from '@/components/modules/hero'; import ReusableSection from '@/components/modules/reusable-section/reusable-section'; import Slider from '@/components/modules/slider/slider'; import USPSection from '@/components/modules/usp-section/usp-section'; -import { InfoCircledIcon } from '@radix-ui/react-icons'; -import { Suspense } from 'react'; interface getContentComponentProps { _type: string; _key: number; disabled: boolean; } -const getContentComponent = ( - { _type, _key, disabled, ...rest }: getContentComponentProps, - index: number -) => { +const getContentComponent = ({ _type, _key, disabled, ...rest }: getContentComponentProps) => { let Component: any; + console.log(_key); + switch (_type) { case 'hero': Component = Hero; @@ -68,16 +67,7 @@ const getContentComponent = ( } return Component ? ( - index == 0 ? ( - - ) : ( - Loading...} - > - - - ) + ) : (
Something else
);