UNPKG

matrix-react-sdk

Version:
41 lines (40 loc) 1.3 kB
import React from "react"; import { IBodyProps } from "./IBodyProps"; import RoomContext from "../../../contexts/RoomContext"; export declare let DOWNLOAD_ICON_URL: string; /** * Get the current CSS style for a DOMElement. * @param {HTMLElement} element The element to get the current style of. * @return {string} The CSS style encoded as a string. */ export declare function computedStyle(element: HTMLElement | null): string; interface IProps extends IBodyProps { showGenericPlaceholder: boolean; } interface IState { decryptedBlob?: Blob; } export default class MFileBody extends React.Component<IProps, IState> { static contextType: React.Context<import("../../structures/RoomView").IRoomState & { threadId?: string; }>; context: React.ContextType<typeof RoomContext>; state: IState; static defaultProps: { showGenericPlaceholder: boolean; }; private iframe; private dummyLink; private userDidClick; private fileDownloader; private getContentUrl; private get content(); private get fileName(); private get linkText(); private downloadFile; componentDidUpdate(prevProps: IProps, prevState: IState): void; private decryptFile; private onPlaceholderClick; render(): React.ReactNode; } export {};