()
| 10 | import { getIconByName } from '@utils/getIconFromName'; |
| 11 | |
| 12 | const ProblemsComponents: React.FC = () => { |
| 13 | const { label, heading, problemsList } = ProblemsConfig; |
| 14 | |
| 15 | return ( |
| 16 | <section className='relative bg-cards-bg text-neutral-content rounded-xl p-8 md:p-12 max-w-xs md:max-w-3xl mx-auto text-center text-lg' id='problems'> |
| 17 | <div className='flex flex-col text-center w-full mb-10'> |
| 18 | <Label text={label} /> |
| 19 | <h2 className="font-bold text-3xl lg:text-5xl tracking-tight mb-2 max-w-2xl mx-auto">{heading}</h2> |
| 20 | </div> |
| 21 | <div className='leading-relaxed space-y-4 md:space-y-6'> |
| 22 | <div className="text-neutral-content/80 space-y-1"> |
| 23 | <div className="grid grid-cols-1 md:grid-cols-2 gap-4"> |
| 24 | {problemsList.map((problem: { title?: string, description: string, icon: string }, index: number) => { |
| 25 | const IconComponent = getIconByName(problem.icon) as React.ComponentType<IconProps>; |
| 26 | return ( |
| 27 | <InfoCard |
| 28 | key={index} |
| 29 | icon={IconComponent} |
| 30 | title={problem.title} |
| 31 | description={problem.description} |
| 32 | iconColor="#C91313" |
| 33 | hoverScale={1.05} |
| 34 | /> |
| 35 | ); |
| 36 | })} |
| 37 | </div> |
| 38 | </div> |
| 39 | </div> |
| 40 | |
| 41 | |
| 42 | </section> |
| 43 | ); |
| 44 | }; |
| 45 | |
| 46 | export default ProblemsComponents; |
nothing calls this directly
no test coverage detected