general-assistant
Version:
General Assistant components
45 lines (44 loc) • 1.66 kB
TypeScript
import { TAppOptionRequestReturn, RequestCommonConfig, TMediaType } from '../../types/AssistantAi';
import { type Options } from 'html2canvas';
export declare function RandomString(length?: number): string;
export declare function isJSON(str: any): boolean;
export declare function ASYNC_loadCompFromRemote(obj: {
[key: string]: any;
}): Promise<{
[key: string]: any;
}>;
export declare function SYNC_loadCompFromRemote({ cardId, cardFileUrl }: {
cardId: string;
cardFileUrl: string;
}): Promise<unknown>;
export declare function copyToClipboard(text: any): Promise<unknown>;
interface TSendRequestWithConfigOption {
commonOpt?: RequestCommonConfig;
parameter: TAppOptionRequestReturn;
isFecth: boolean;
controller: any;
onResponse: (data: any) => any;
onCatch: (err: any) => any;
onFinally: () => any;
}
export declare function sendRequestWithConfig(args: TSendRequestWithConfigOption): any;
export declare function getMedia(): Promise<unknown>;
export declare function blobToFile(mtype: TMediaType, chunks: Blob[]): Promise<unknown>;
export declare function showToast(text: string): void;
export declare const FileIcon: {
code: string[];
wendang: string[];
baobiao: string[];
yasuo: string[];
img: string[];
yingyin: string[];
};
export declare function getFileName(_u: string): string;
export declare function getFileTypeIcon(_t: string, _n: string): {
suf: string;
color: string;
icon: string;
};
export declare function getFileGeneralSize(_bytes: number): string;
export declare function getSnapshot(node: HTMLElement, options?: Partial<Options>): Promise<unknown>;
export {};