'use client' import { WebsiteContent, FeatureContent } from '@/lib/content-types' import HeroEditor from './HeroEditor' interface ContentEditorTabsProps { activeTab: string content: WebsiteContent isRTL: boolean t: (key: string) => string updateHero: (field: any, value: string) => void updateFeature: (index: number, field: keyof FeatureContent, value: string) => void updateFAQ: (index: number, field: 'question' | 'answer', value: string | string[]) => void addFAQ: () => void removeFAQ: (index: number) => void updatePricing: (index: number, field: string, value: string | number | boolean) => void updateTrust: (key: 'item1' | 'item2' | 'item3', field: 'value' | 'label', value: string) => void updateTestimonial: (field: 'quote' | 'author' | 'role', value: string) => void } export default function ContentEditorTabs(props: ContentEditorTabsProps) { const { activeTab, content, isRTL, t } = props const dir = isRTL ? 'rtl' : 'ltr' if (activeTab === 'hero') { return } if (activeTab === 'features') { return (

{t('admin_tab_features')}

{content.features.map((feature, index) => (
props.updateFeature(index, 'icon', e.target.value)} className="w-full px-3 py-2 border border-slate-300 rounded-lg text-2xl text-center" />
props.updateFeature(index, 'title', e.target.value)} className="w-full px-3 py-2 border border-slate-300 rounded-lg focus:ring-2 focus:ring-primary-500 focus:border-primary-500" dir={dir} />