import { FormItem } from './types/formItem'; import type { TextResultType, NumberResultType, LinkResultType, SingleSelectResultType, MultiSelectResultType, ObjectResultType, AttachmentResultType } from './types/resultType'; import type { ExecuteContext, TextExecuteResult, NumberExecuteResult, LinkExecuteResult, SingleSelectExecuteResult, MultiSelectExecuteResult, AttachmentExecuteResult, ObjectExecuteResult, ExecuteFailResult } from './types/execute'; import { type Authorization } from './types/auth'; interface FieldOptions { disableAutoUpdate?: boolean; } interface TextFieldDecorator { resultType: TextResultType; executeType: TextExecuteResult; } interface NumberFieldDecorator { resultType: NumberResultType; executeType: NumberExecuteResult; } interface LinkFieldDecorator { resultType: LinkResultType; executeType: LinkExecuteResult; } interface SingleSelectFieldDecorator { resultType: SingleSelectResultType; executeType: SingleSelectExecuteResult; } interface MultiSelectFieldDecorator { resultType: MultiSelectResultType; executeType: MultiSelectExecuteResult; } interface AttachmentFieldDecorator { resultType: AttachmentResultType; executeType: AttachmentExecuteResult; } interface ObjectFieldDecorator { resultType: ObjectResultType; executeType: ObjectExecuteResult; } type IDecoratorType = TextFieldDecorator | NumberFieldDecorator | LinkFieldDecorator | SingleSelectFieldDecorator | MultiSelectFieldDecorator | AttachmentFieldDecorator | ObjectFieldDecorator; interface BaseFieldDecorator { id?: string; name?: string; authorizations?: Authorization; formItems: FormItem[]; errorMessages?: Record; options?: FieldOptions; resultType: T['resultType']; execute: (context: ExecuteContext, formData: any) => Promise; i18nMap?: { [key: string]: object; }; } type FieldDecorator = BaseFieldDecorator | BaseFieldDecorator | BaseFieldDecorator | BaseFieldDecorator | BaseFieldDecorator | BaseFieldDecorator | BaseFieldDecorator; export declare class FieldDecoratorKit { private decorator?; private domainList?; setDecorator(decorator: FieldDecorator): void; getDecorator(): FieldDecorator | undefined; setDomainList(domainList: string[]): void; getDomainList(): string[] | undefined; t(key: string): string; } export declare const fieldDecoratorKit: FieldDecoratorKit; export declare const getManifestByFieldDecorator: (fieldDecorator: FieldDecoratorKit) => any; export declare const getAuthertications: (manifest: any) => Authorization | null; export declare const getAuthenticationHeader: (manifest: any, authId: string, config: string | Record) => Record; export {};