import { CellProps } from '../../basic-components/cell/cell-types';
import { AdvanceResearchProviderProps } from '../../context/AdvanceResearchContext';
import { DataObj, DataStructure, DataTable } from '../../types/data-structures';
import { ObjectProtocolHandler, UploadRequest } from '../../types/generic';
import { onContextMenuType } from '../../types/global';
import { BooleanValue, YesNo } from '../../types/legacy';
export interface InputPanelProps extends AdvanceResearchProviderProps {
    /**
     * Data table with input panel data
     */
    data: DataTable;
    /**
     * Id applied to the DOM
     * @default autogenerated id
     */
    id?: string;
    /**
     * Force all shapes to editable false
     */
    ReadOnly?: BooleanValue;
    /**
     * Force the render of submit button
     * @default false
     */
    SubmitButton?: YesNo;
    /**
     * Force the render of reset button
     * @default false
     */
    FieldReset?: YesNo;
    /**
     * Position of the command bar (submit button and other commands)
     * @default 'bottom'
     */
    ShowButtons?: "TOP" | "BOTTOM" | "LEFT" | "RIGHT" | "";
    /**
     * Force the submit callback when CHK and SWT change value
     * @default false
     */
    UpdateOnClick?: YesNo;
    /**
     * TODO: todo
     * @default "No"
     */
    AutoSkip?: YesNo;
    /**
     * Automatically put the focus at first editable field
     * @default false
     */
    AutoFocus?: YesNo;
    /**
     * Layout position for cell and label
     */
    Position?: "COLUMNS" | "INLINE" | "STRETCHED" | "UPINLINE" | "UPCOLUMNS" | "WATERMARK";
    /**
     * Decimal separator
     * @default '.''
     */
    decimalSeparator?: string;
    /**
     * Callback to handle submit
     */
    onSubmit: InputPanelSubmitHandler;
    /**
     * Callback to handle check
     */
    onCheck?: InputPanelSubmitHandler;
    /**
     * Callback to handle check
     */
    onCheckObj?: InputPanelCheckObjHandler;
    /**
     * Callback to retrieve ACP and CMB options
     */
    optionsHandler: InputPanelOptionsHandler;
    /**
     * onContextMenu function on appbar components
     */
    onContextMenu?: onContextMenuType;
    /**
     * onButtonClick function when button cell was clicked
     */
    onButtonClick?: InputPanelButtonClickHandler;
    /**
     * Callback to handle upload requests
     */
    onUploadRequest?: UploadRequest;
    /**
     * Callback called when the InputPanel is unmounted or if is necessary to save the state - sends the state as string
     */
    onSaveTemporaryComponentState?: (state: string) => void;
    /**
     * Callback called when the InputPanel is mounted - receives the state as string
     */
    onMountComponent?: () => string;
    /**
     * Callback to handle object protocol actions triggered from the InputPanel
     */
    onObjectProtocol?: ObjectProtocolHandler;
}
export interface InputPanelSubmitEvent {
    value: InputPanelSubmitValue;
    cell?: string;
}
export interface InputPanelSubmitValue {
    before: DataTable;
    after: DataTable;
}
export type InputPanelSubmitHandler = (ev: Readonly<InputPanelSubmitEvent>) => void;
export type InputPanelOptionsHandler = (fun: string | undefined, inputValue: string | undefined, currentState: DataTable, cellId: string) => Promise<DataStructure>;
export type InputPanelButtonClickHandler = (event: {
    fun: string;
    cellId: string;
    currentState: DataTable;
}) => void;
export interface InputPanelState {
    [cellId: string]: CellProps;
}
export interface InputPanelHandle {
    setState: (newState: InputPanelState) => void;
}
export type InputPanelCheckObjHandler = (event: {
    obj: DataObj;
    fun?: string;
    cellId?: string;
}) => Promise<{
    valid: boolean;
}>;
export type InputPanelCommandSubmitEventDetail = {
    id: string;
};
export declare const INPUT_PANEL_COMMAND_SUBMIT_EVENT_NAME = "command-submit";
//# sourceMappingURL=input-panel-types.d.ts.map