import { CustomFieldData, CustomFieldSpace } from "@etsoo/appscript";
import { CustomFieldReactCollection, ICustomFieldReact } from "@etsoo/react";
import { IdType, ListType2 } from "@etsoo/shared";
import { GridSize } from "@mui/material/Grid";
import { TypographyProps } from "@mui/material/Typography";
/**
 * Custom field utilities
 */
export declare namespace CustomFieldUtils {
    /**
     * Custom field creators
     */
    const customFieldCreators: Record<string, ICustomFieldReact<any> | undefined>;
    /**
     * Create layout
     * @param fields Fields
     * @param collections Ref collections
     * @param getValue Get default value callback
     * @param onChange Callback for value change
     * @param globalCallback Global label callback, can be repeated
     * @param fieldCalback Field callback
     * @returns
     */
    function create<D extends CustomFieldData = CustomFieldData>(fields: D[], collections: CustomFieldReactCollection<D>, getValue: (field: D) => unknown, onChange: (name: string, value: unknown) => void, globalCallback?: (input: string) => string, fieldCalback?: (field: D) => void): import("react/jsx-runtime").JSX.Element[];
    /**
     * Create multiline label
     * @param label Original label
     * @param props Properties
     * @returns Result
     */
    function createMultilineLabel(label?: string, props?: TypographyProps): import("react/jsx-runtime").JSX.Element[] | undefined;
    /**
     * Transform custom field space
     * @param space Space
     * @returns Result
     */
    function transformSpace(space?: CustomFieldSpace): {
        xs?: GridSize | null | undefined;
        sm?: GridSize | null | undefined;
        md?: GridSize | null | undefined;
        lg?: GridSize | null | undefined;
        xl?: GridSize | null | undefined;
    };
    /**
     * Update ref options
     * @param fields Fields
     * @param callback Callback
     */
    function updateOptions(fields: CustomFieldData[], callback: (key: string, ids: IdType[]) => ListType2[]): void;
    /**
     * Update properties
     * @param input Input object
     * @param globalCallback Global callback
     */
    function updateProperties(input: object, globalCallback: (input: string) => string): void;
    /**
     * Update values for all fields
     * @param collections Field component collections
     * @param value New value
     */
    function updateValues<D extends CustomFieldData = CustomFieldData>(collections: CustomFieldReactCollection<D>, value: Record<string, unknown>): void;
}
