ZUI

Search documentation

Find a page or a heading.

File Type Icon

A lucide icon chosen for a file's type from its extension, decorative unless paired with the visible file name or given an aria-label.

tsx

Installation

bash

Usage

tsx
tsx

It is decorative, so pair it with the visible file name, or give it an aria-label where it stands alone.

API reference

FileTypeIcon

Renders the lucide icon its name maps to by extension (a generic file icon when none matches) and takes every prop a lucide icon takes, plus:

Every glyph is a static lucide-react icon, FileText included even where an animated twin is vendored elsewhere, so every file type takes the same props. It sets data-slot="file-type-icon".