/* eslint-disable @typescript-eslint/no-explicit-any */
import { KeyValue } from "../../../models/KeyValue";
import { Entity } from "../../models/Entity";

export interface CardField<T extends Entity> {
	name: keyof T;
	title: string;
	type?:
		| "input"
		| "number"
		| "password"
		| "select"
		| "multiline"
		| "paragraph"
		| "multiselect"
		| "checkbox";
	required?: boolean;
	nullable?: boolean;
	options?: KeyValue[];
	loadOptions?: (model: T) => Promise<KeyValue[]>;
	component?: React.ComponentType<any>;
	readOnly?: boolean;
	hideFromEditor?: boolean;
	group?: string;
}
