import { FieldConfig } from './field'; export interface AutoFieldsConfig { ignoreKeys?: Array; ignorePatterns?: Array; } export interface AutoFieldsComponent { config: AutoFieldsConfig; /** * Use the provided data to guess what types of field to use * to edit the data. * * @param key Key to use in the configuration. * @param data Data to use for guessing field configurations. */ guessField(key: string, data: any): FieldConfig; /** * Use the provided data to guess what types of fields to use * to edit the data. * * @param data Data to use for guessing field configurations. */ guessFields(data: any): Array; } export interface AutoFieldsConstructor { new (config: AutoFieldsConfig): AutoFieldsComponent; } export declare class AutoFields implements AutoFieldsComponent { config: AutoFieldsConfig; constructor(config?: AutoFieldsConfig); protected deepGuess(data: any, keyBase?: Array): Array; protected deepGuessArray(data: Array, keyBase?: Array): Array; protected deepGuessObject(data: Record, keyBase?: Array): FieldConfig[]; protected deepGuessSimple(data: any, keyBase?: Array): FieldConfig; guessField(key: string, data: any): FieldConfig; guessFields(data: any): Array; /** * Guess the type of field to use based on the key and value. * * @param key Key to guess the type of field. * @param data Data to use for guessing field type. */ guessType(key: string, data: any): string; protected isIgnoredKey(key: string): boolean; } /** * From the key guess the label of the field. * * ex: key.subKey => Key SubKey */ export declare function guessLabel(key: string): string;