feat: add placeholder support to EntityForm FieldDef

This commit is contained in:
2026-03-01 11:18:53 +01:00
parent e05e9d5975
commit 3c259a1862

View File

@@ -14,6 +14,7 @@ export interface FieldDef {
required?: boolean
type?: 'text' | 'select' | 'number'
options?: { value: string | number; label: string }[]
placeholder?: string
}
interface Props {
@@ -67,6 +68,7 @@ export default function EntityForm({ open, title, fields, initialValues, onClose
value={values[f.name] ?? ''}
onChange={(e) => handleChange(f.name, e.target.value)}
size="small"
placeholder={f.placeholder}
/>
)
)}