import { ReactNode } from "react"; import XBaseDisplay, { XBaseDisplayProps } from "../base/XBaseDisplay"; export interface XFileViewerProps extends XBaseDisplayProps { /** * 文件路径URL */ url?: string; /** * 显示类型 */ type?: 'docx' | 'pdf'; /** * 内容为空的显示 */ emptyContent?: string | ReactNode; } /** * 预览mp4、mp3、docx文件 * @name 文件预览组件 * @groupName */ export default class XFileViewer extends XBaseDisplay { static ComponentName: string; static defaultProps: { url: string; type: string; emptyContent: string; styleType: string; hasBox: boolean; showBorder: any; overflow: string; boxStyle: {}; width: string; height: string; visible: boolean; grid: number[]; gridSpan: number[]; parent: string; pureRender: boolean; dataSourceUrl: string; filterData: {}; mustHasFilter: boolean; }; constructor(props: any); useStateUrl: boolean; GetUrl(): any; /** * 设置文件 * @param url 文件地址 * @param type 文件类型 */ SetFile(url: any, type: any): void; renderDisplay(): any; }