backend-lehrer (11 files): - llm_gateway/routes/schools.py (867 → 5), recording_api.py (848 → 6) - messenger_api.py (840 → 5), print_generator.py (824 → 5) - unit_analytics_api.py (751 → 5), classroom/routes/context.py (726 → 4) - llm_gateway/routes/edu_search_seeds.py (710 → 4) klausur-service (12 files): - ocr_labeling_api.py (845 → 4), metrics_db.py (833 → 4) - legal_corpus_api.py (790 → 4), page_crop.py (758 → 3) - mail/ai_service.py (747 → 4), github_crawler.py (767 → 3) - trocr_service.py (730 → 4), full_compliance_pipeline.py (723 → 4) - dsfa_rag_api.py (715 → 4), ocr_pipeline_auto.py (705 → 4) website (6 pages): - audit-checklist (867 → 8), content (806 → 6) - screen-flow (790 → 4), scraper (789 → 5) - zeugnisse (776 → 5), modules (745 → 4) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
107 lines
4.3 KiB
TypeScript
107 lines
4.3 KiB
TypeScript
'use client'
|
|
|
|
import { WebsiteContent, HeroContent } from '@/lib/content-types'
|
|
|
|
interface HeroEditorProps {
|
|
content: WebsiteContent
|
|
isRTL: boolean
|
|
t: (key: string) => string
|
|
updateHero: (field: keyof HeroContent, value: string) => void
|
|
}
|
|
|
|
export default function HeroEditor({ content, isRTL, t, updateHero }: HeroEditorProps) {
|
|
const dir = isRTL ? 'rtl' : 'ltr'
|
|
|
|
return (
|
|
<div className="space-y-6">
|
|
<h2 className="text-xl font-semibold text-slate-900">{t('admin_tab_hero')} Section</h2>
|
|
<div className="grid gap-4">
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">Badge</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.badge}
|
|
onChange={(e) => updateHero('badge', 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}
|
|
/>
|
|
</div>
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">Titel (vor Highlight)</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.title}
|
|
onChange={(e) => updateHero('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}
|
|
/>
|
|
</div>
|
|
<div className="grid grid-cols-2 gap-4">
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">Highlight 1</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.titleHighlight1}
|
|
onChange={(e) => updateHero('titleHighlight1', 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}
|
|
/>
|
|
</div>
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">Highlight 2</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.titleHighlight2}
|
|
onChange={(e) => updateHero('titleHighlight2', 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}
|
|
/>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">Untertitel</label>
|
|
<textarea
|
|
value={content.hero.subtitle}
|
|
onChange={(e) => updateHero('subtitle', e.target.value)}
|
|
rows={3}
|
|
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}
|
|
/>
|
|
</div>
|
|
<div className="grid grid-cols-3 gap-4">
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">CTA Primaer</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.ctaPrimary}
|
|
onChange={(e) => updateHero('ctaPrimary', 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}
|
|
/>
|
|
</div>
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">CTA Sekundaer</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.ctaSecondary}
|
|
onChange={(e) => updateHero('ctaSecondary', 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}
|
|
/>
|
|
</div>
|
|
<div>
|
|
<label className="block text-sm font-medium text-slate-700 mb-1">CTA Hinweis</label>
|
|
<input
|
|
type="text"
|
|
value={content.hero.ctaHint}
|
|
onChange={(e) => updateHero('ctaHint', 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}
|
|
/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|