import { EventEmitter } from '../../stencil-public-runtime'; import { ExtensionSuffixType } from "../../type/file-types"; import { MdsFilePreviewEventDetail } from './meta/event-detail'; import { TypographyTruncateType } from "../../type/text"; import { ThemeFullVariantAvatarType } from "../../type/variant"; /** * @part card - The preview of the file: its thumbnail or format icon, its name and its details * @category content */ export declare class MdsFilePreview { host: HTMLMdsFilePreviewElement; private t; private km; private card?; /** * Enables the cross icon to perform cancel/delete action on element */ readonly deletable?: boolean; /** * Turns the card into a button that asks for the download: a tab stop that the pointer, Enter * and Space activate, emitting `mdsFileDownload`. Without it the card is not interactive */ readonly downloadable?: boolean; /** * Overrides the default filetype description */ readonly description?: string; /** * The filename shown as component title, is used to auto assign one of the filetype known in the filetype dictionary */ readonly filename: string; /** * The filesize shown, if you pass a string you can write whathever you want, if you pass a number it expect filesize in bytes, the component will format it automatically. * @example '2.4 MB' */ readonly filesize?: string; /** * Sets a feedback message related to the component */ readonly message?: string; /** * Truncates the filename shown */ readonly truncate?: TypographyTruncateType; /** * The image preview src if available of a file, useful if you have a logo to display, or a smaller version of a bigger image */ readonly src?: string; /** * Overrides the automatic filetype recongition by forcing the suffix to one of the available formats choosen */ readonly suffix?: ExtensionSuffixType; /** * The name of the icon or a base64 string to render it as an svg */ icon: string; /** * The variant of the component, is shown only if the message attribute is defined */ variant?: ThemeFullVariantAvatarType; /** * The kind of file, recognised from the extension of `filename` or from `suffix`: it selects * the colours of the icon. The component writes it on load and whenever `filename` changes, * set `suffix` to choose it */ format?: string; /** * Emits when the component is clicked, returning file infos */ downloadedEvent: EventEmitter; /** * Emits when the component is removed, returning file infos */ deletedEvent: EventEmitter; private getDefaultKeyDescription; private onClickDeletedEvent; private onClickDownloadEvent; componentWillLoad(): void; private cardRef; private attachCardKeyboard; connectedCallback(): void; disconnectedCallback(): void; handleFilename(newValue: string): void; render(): any; }