UNPKG

@types/react-file-icon

Version:
166 lines (156 loc) 2.96 kB
# Installation > `npm install --save @types/react-file-icon` # Summary This package contains type definitions for react-file-icon (https://github.com/pixelunion/react-file-icon#readme). # Details Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-file-icon. ## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-file-icon/index.d.ts) ````ts import * as React from "react"; export type IconType = | "3d" | "acrobat" | "audio" | "binary" | "code" | "compressed" | "document" | "drive" | "font" | "image" | "presentation" | "settings" | "spreadsheet" | "vector" | "video"; export interface FileIconProps { color?: string | undefined; extension?: string | undefined; fold?: boolean | undefined; foldColor?: string | undefined; glyphColor?: string | undefined; gradientColor?: string | undefined; gradientOpacity?: number | undefined; labelColor?: string | undefined; labelTextColor?: string | undefined; labelTextStyle?: object | undefined; labelUppercase?: boolean | undefined; radius?: number | undefined; type?: IconType | undefined; } export type DefaultExtensionType = | "3dm" | "3ds" | "3g2" | "3gp" | "7zip" | "aac" | "aep" | "ai" | "aif" | "aiff" | "asf" | "asp" | "aspx" | "avi" | "bin" | "bmp" | "c" | "cpp" | "cs" | "css" | "csv" | "cue" | "dll" | "dmg" | "doc" | "docx" | "dwg" | "dxf" | "eot" | "eps" | "exe" | "flac" | "flv" | "fnt" | "fodp" | "fods" | "fodt" | "fon" | "gif" | "gz" | "htm" | "html" | "indd" | "ini" | "java" | "jpeg" | "jpg" | "js" | "json" | "jsx" | "m4a" | "m4v" | "max" | "md" | "mid" | "mkv" | "mov" | "mp3" | "mp4" | "mpeg" | "mpg" | "obj" | "odp" | "ods" | "odt" | "ogg" | "ogv" | "otf" | "pdf" | "php" | "pkg" | "plist" | "png" | "ppt" | "pptx" | "pr" | "ps" | "psd" | "py" | "rar" | "rb" | "rm" | "rtf" | "scss" | "sitx" | "svg" | "swf" | "sys" | "tar" | "tex" | "tif" | "tiff" | "ts" | "ttf" | "txt" | "wav" | "webm" | "wmv" | "woff" | "wpd" | "wps" | "xlr" | "xls" | "xlsx" | "yml" | "zip" | "zipx"; export const defaultStyles: Record<DefaultExtensionType, Partial<FileIconProps>>; export const FileIcon: React.FunctionComponent<FileIconProps>; ```` ### Additional Details * Last updated: Tue, 07 Nov 2023 09:09:39 GMT * Dependencies: [@types/react](https://npmjs.com/package/@types/react) # Credits These definitions were written by [njuro](https://github.com/njuro).