import { type Descriptor } from './descriptors';
import { type BoxModel } from '../state/modules/box-models';
import { Types as PropControllerTypes } from '@makeswift/prop-controllers';
import { type ControlMessage, type SendMessage, type InstanceType, ControlInstance } from '@makeswift/controls';
export type PropControllerMessage = ControlMessage;
export declare const TableFormFieldsMessageType: {
    readonly TABLE_FORM_LAYOUT_CHANGE: "TABLE_FORM_LAYOUT_CHANGE";
    readonly TABLE_FORM_FIELD_LAYOUT_CHANGE: "TABLE_FORM_FIELD_LAYOUT_CHANGE";
};
type TableLayoutTableFormFieldsMessage = {
    type: typeof TableFormFieldsMessageType.TABLE_FORM_LAYOUT_CHANGE;
    payload: {
        layout: BoxModel;
    };
};
type TableFieldLayoutTableFormFieldsMessage = {
    type: typeof TableFormFieldsMessageType.TABLE_FORM_FIELD_LAYOUT_CHANGE;
    payload: {
        layout: BoxModel;
        index: number;
    };
};
export type TableFormFieldsMessage = TableLayoutTableFormFieldsMessage | TableFieldLayoutTableFormFieldsMessage;
export declare class TableFormFieldsPropController extends ControlInstance<TableFormFieldsMessage> {
    recv: () => void;
    child(_key: string): ControlInstance | undefined;
    tableFormLayoutChange(payload: {
        layout: BoxModel;
    }): void;
    tableFormFieldLayoutChange(payload: {
        layout: BoxModel;
        index: number;
    }): void;
}
type DescriptorPropController<T extends Descriptor> = T extends {
    type: typeof PropControllerTypes.TableFormFields;
} ? TableFormFieldsPropController : InstanceType<T>;
export type DescriptorsPropControllers<T extends Record<string, Descriptor>> = {
    [K in keyof T]: undefined extends T[K] ? DescriptorPropController<Exclude<T[K], undefined>> : DescriptorPropController<T[K]>;
};
export type AnyPropController = ControlInstance<any> | TableFormFieldsPropController;
export declare function createPropController(descriptor: Descriptor, send: SendMessage<PropControllerMessage>): AnyPropController;
export {};
//# sourceMappingURL=instances.d.ts.map