@opentiny/vue-renderless
Version:
An enterprise-class UI component library, support both Vue.js 2 and Vue.js 3, as well as PC and mobile.
62 lines (57 loc) • 2.62 kB
TypeScript
import { ExtractPropTypes } from 'vue';
import { ResizeObserver } from '@opentiny/utils';
import { ISharedRenderlessParamHooks, ISharedRenderlessParamUtils } from './shared.type.js';
declare const asyncFlowchartProps: {
fetch: {
type: FunctionConstructor;
required: boolean;
};
tiny_mode: StringConstructor;
tiny_mode_root: BooleanConstructor;
tiny_template: (FunctionConstructor | ObjectConstructor)[];
tiny_renderless: FunctionConstructor;
tiny_theme: StringConstructor;
tiny_mcp_config: ObjectConstructor;
tiny_chart_theme: ObjectConstructor;
};
declare const observeContainerSize: ({ nextTick, vm, state }: {
nextTick: ISharedRenderlessParamHooks['nextTick'];
vm: ISharedRenderlessParamUtils['vm'];
state: IAsyncFlowchartState;
}) => () => void;
declare const unobserveContainerSize: (state: IAsyncFlowchartState) => () => void;
declare const fetchData: ({ Loading, props, state, vm, markRaw, api, nextTick }: {
Loading: any;
props: IAsyncFlowchartProps;
state: IAsyncFlowchartState;
vm: ISharedRenderlessParamUtils['vm'];
markRaw: ISharedRenderlessParamHooks['markRaw'];
api: IAsyncFlowchartApi;
nextTick: ISharedRenderlessParamHooks['nextTick'];
}) => () => void;
declare const handleClickNode: (emit: ISharedRenderlessParamUtils['emit']) => (afterNode: any, e: any) => void;
declare const handleClickLink: (emit: ISharedRenderlessParamUtils['emit']) => (afterLink: any, e: any) => void;
declare const handleClickBlank: (emit: ISharedRenderlessParamUtils['emit']) => (param: any, e: any) => void;
declare const handleClickGroup: (emit: ISharedRenderlessParamUtils['emit']) => (afterGroup: any, e: any) => void;
declare const refresh: (api: IAsyncFlowchartApi) => () => void;
interface IAsyncFlowchartState {
loading: boolean;
data: null;
config: null | {
nodeWrapperSize: number;
};
temporary?: typeof ResizeObserver;
}
type IAsyncFlowchartProps = ExtractPropTypes<typeof asyncFlowchartProps>;
interface IAsyncFlowchartApi {
state: IAsyncFlowchartState;
observeContainerSize: ReturnType<typeof observeContainerSize>;
unobserveContainerSize: ReturnType<typeof unobserveContainerSize>;
handleClickNode: ReturnType<typeof handleClickNode>;
handleClickLink: ReturnType<typeof handleClickLink>;
handleClickBlank: ReturnType<typeof handleClickBlank>;
handleClickGroup: ReturnType<typeof handleClickGroup>;
fetchData: ReturnType<typeof fetchData>;
refresh: ReturnType<typeof refresh>;
}
export { IAsyncFlowchartApi, IAsyncFlowchartProps, IAsyncFlowchartState };