import { DslDefinition } from '@oinone/kunlun-dsl';
import { ActiveRecord, PushActiveRecordsPredict, RuntimeContext, RuntimeViewAction, UpdateActiveRecordsByEntityPredict } from '@oinone/kunlun-engine';
import { ActionContextType, ViewMode, ViewType } from '@oinone/kunlun-meta';
import { ReturnPromise } from '@oinone/kunlun-shared';
import { MetadataViewWidget } from '../../../basic';
import { ClickResult, PopupSubmitParameters } from '../../../typing';
import { ViewActionWidget } from '../ViewActionWidget';
import { PopupLoadDataResult } from './typing';
import { PopupDslDefinition } from './util';
export declare abstract class PopupActionWidget extends ViewActionWidget {
    protected metadataSubviewWidget: MetadataViewWidget | undefined;
    protected subviewRuntimeContext: RuntimeContext | undefined;
    protected popupViewDslNode: DslDefinition | undefined;
    protected currentViewDslNode: DslDefinition | null | undefined;
    protected popupDslDefinition: PopupDslDefinition | null | undefined;
    protected defaultSubviewType: ViewType;
    protected get viewMode(): ViewMode;
    protected get subviewType(): ViewType;
    protected get subviewModel(): string;
    protected get subviewModelName(): string;
    protected get subviewModule(): string | undefined;
    protected get subviewModuleName(): string;
    protected currentOpenerDataSource: ActiveRecord[] | undefined;
    protected get openerDataSource(): ActiveRecord[] | undefined;
    protected currentOpenerActiveRecords: ActiveRecord[] | undefined;
    get openerActiveRecords(): ActiveRecord[] | undefined;
    initialize(props: any): this;
    onSubmit(parameters: PopupSubmitParameters): boolean;
    protected updateDataSourceByEntityForSubmit(parameters: PopupSubmitParameters, predict?: UpdateActiveRecordsByEntityPredict): void;
    protected pushDataSourceForSubmit(parameters: PopupSubmitParameters, predict?: PushActiveRecordsPredict): void;
    onCancel(parameters: PopupSubmitParameters): boolean;
    protected clickAction(...args: unknown[]): Promise<ClickResult>;
    protected generatorPopupWidget(): Promise<void>;
    protected generatorPopupDslDefinition(): Promise<PopupDslDefinition | undefined>;
    protected createMetadataSubviewWidget(): MetadataViewWidget;
    protected initSubview(popupDslDefinition: PopupDslDefinition, data: ActiveRecord[]): void;
    protected computeViewMode(action: RuntimeViewAction): ViewMode;
    protected getViewLayout(): ReturnPromise<DslDefinition | undefined>;
    protected getViewDsl(): ReturnPromise<DslDefinition | undefined>;
    protected getViewTemplate(): ReturnPromise<DslDefinition | undefined>;
    protected initSubviewAfterProperties(): void;
    protected abstract createPopupWidget(data: ActiveRecord[], isFetchData: boolean): void;
    protected createPopupDslDefinition(): DslDefinition | undefined;
    /**
     * 加载
     * @protected
     */
    protected loadOpenerData(): void;
    /**
     * 加载弹窗数据
     * @protected
     */
    protected loadData(): ReturnPromise<PopupLoadDataResult>;
    /**
     * 是否通过弹窗中的组件自动获取数据
     * @param records loadData返回值
     * @return true 自动获取 false 填充loadData返回值 undefined 根据action自动判断
     * @protected
     */
    protected isFetchData(records: ActiveRecord[]): boolean | undefined;
    protected isNotNeedFetchData(records: ActiveRecord[], contextType: ActionContextType): boolean;
    executeExpression<T>(expression: string, errorValue?: T): string | T | undefined;
}
