Skip to content

Attachment

Attachment displays uploaded or linked file cards with file details and action buttons.

Usage

AttachmentExample.tsx
import { Attachment } from '@masumdev/rn-ui';
export function AttachmentExample() {
return (
<Attachment
fileName="document.pdf"
fileSize="2.4 MB"
fileType="pdf"
onRemove={() => console.log('Remove file')}
/>
);
}

Props API

PropTypeDefaultDescription
fileNamestringName of the attached file.
fileSizestringHuman readable file size string.
fileTypestringFile extension format badge.
onRemove() => voidCallback when remove action button is pressed.