import React from 'react'; import { CCMSConfig, PageListItem } from '../main'; /** * 页面流转步骤基类配置定义 * - type: 类型,对应各子类 */ export interface StepConfig { } /** * 页面步骤基类 - 入参格式 * - ref: 页面步骤示例 * - data: 各步骤数据 * - step: 当前步骤索引 * - config: 当前步骤配置文件 * - onSubmit: 页面步骤的提交事件 * - onView: 页面步骤的界面切换事件 */ export interface StepProps { ref: (instance: Step | null) => void; data: any[]; step: { [field: string]: any; }; config: C; onChange?: (data: any) => Promise; onSubmit: (data: any, unmountView?: boolean) => Promise; onMount: () => Promise; onUnmount: (reload?: boolean, data?: any) => Promise; checkPageAuth: (pageID: any) => Promise; loadPageURL: (pageID: any) => Promise; loadPageFrameURL: (pageID: any) => Promise; loadPageConfig: (pageID: any) => Promise; loadPageList: () => Promise>; baseRoute: string; loadDomain: (domain: string) => Promise; handlePageRedirect?: (path: string, replaceHistory: boolean) => void; handleFormValue?: (payload: object) => object; } /** * 页面步骤基类 */ export default class Step extends React.Component, S> { static defaultProps: { config: {}; }; /** * 步骤 根据mode不同,处理subLabel内容\ * @param config 子项config * @returns */ handleSubLabelContent(config: any): JSX.Element | undefined; stepPush: () => void; stepPop: (reload?: boolean, data?: any) => void; render(): JSX.Element; }