This commit is contained in:
2026-01-30 10:35:31 +01:00
parent ba08724a52
commit cea56ac58d
60 changed files with 1922 additions and 1305 deletions

View File

@@ -0,0 +1,38 @@
'use client';
import * as React from 'react';
import { FormState } from '../types';
import { FEATURE_OPTIONS } from '../constants';
import { Checkbox } from '../components/Checkbox';
import { RepeatableList } from '../components/RepeatableList';
interface FeaturesStepProps {
state: FormState;
updateState: (updates: Partial<FormState>) => void;
toggleItem: (list: string[], id: string) => string[];
}
export function FeaturesStep({ state, updateState, toggleItem }: FeaturesStepProps) {
return (
<div className="space-y-8">
<div className="grid grid-cols-1 md:grid-cols-2 gap-4">
{FEATURE_OPTIONS.map(opt => (
<Checkbox
key={opt.id} label={opt.label} desc={opt.desc}
checked={state.features.includes(opt.id)}
onChange={() => updateState({ features: toggleItem(state.features, opt.id) })}
/>
))}
</div>
<div className="space-y-4">
<p className="text-sm font-bold text-slate-900">Weitere inhaltliche Bereiche?</p>
<RepeatableList
items={state.otherFeatures}
onAdd={(v) => updateState({ otherFeatures: [...state.otherFeatures, v] })}
onRemove={(i) => updateState({ otherFeatures: state.otherFeatures.filter((_, idx) => idx !== i) })}
placeholder="z.B. Partner-Portal, Download-Center..."
/>
</div>
</div>
);
}