FieldComponentMap
FieldComponentMap<
F,TFieldMeta> ={ [K in AdminField["type"]]: { cell: ApplyComponent<F, CellComponentProps<Extract<AdminField<TFieldMeta>, { type: K }>>>; input: ApplyComponent<F, InputComponentProps<TFieldMeta, Extract<AdminField<TFieldMeta>, { type: K }>>> } }
Defined in: packages/core/src/framework.ts:32
Maps every field type in the AdminField union to the framework’s input component type
for that field.
Keyed by AdminField['type'] — as new field types are added to the union, TypeScript
automatically requires a matching component slot in this map.
Each slot resolves to ApplyComponent<F, InputComponentProps<MatchingFieldDef>>, which
means the component must accept the input props for that specific field type. This gives
the component full autocomplete for field-specific properties (e.g. fieldDef.max
on the text slot).
Type Parameters
Section titled “Type Parameters”F extends ComponentHKT
TFieldMeta
Section titled “TFieldMeta”TFieldMeta extends BaseFieldMeta = BaseFieldMeta
- CellComponentProps for the data table cell props
- ComponentHKT for how framework packages define their HKT
- ApplyComponent for how the HKT resolves to a concrete component type