Skip to main content
239

Search Lumen

Find components, APIs, guides, and recipes.

GitHub
Themes
React Native docs
Data displayReact Native

Attachment

Show a file with its name, metadata, and actions.

Public APILumenAttachmentReact Native

Native example

Use Attachment

Use a pressable attachment to open the file with the platform viewer.

Attachment rendered in the Expo web renderer Lumen playground

Captured exampleExpo web renderer

Open interactive preview
Open the Attachment demo
tsx
import { LumenAttachment, LumenIconButton } from '@santi020k/lumen-react-native'

export function ReportAttachment({ onOpen, onDownload }: { onOpen: () => void; onDownload: () => void }) {
  return (
    <LumenAttachment
      name="Quarterly-report-2026.pdf"
      meta="PDF · 2.4 MB"
      onPress={onOpen}
      trailing={
        <LumenIconButton label="Download Quarterly-report-2026.pdf" name="download" size="sm" onPress={onDownload} />
      }
    />
  )
}
React Native
A pressable PDF attachment with its size and a separate download action.

Reference

Public API

The primary shared and platform-specific options exposed by LumenAttachment.

APIValues or typeDefaultDescription
name / meta / busyfilename / size or type / upload staterequired / none / falseUse a pressable attachment to open the file with the platform viewer.

Native behavior

Design and accessibility

When to use it

Use a pressable attachment to open the file with the platform viewer.

Accessibility

Filename and metadata read as one element; busy state is exposed.

Shared component

Available on other platforms

Apple / SwiftUIAndroid / Compose Web
React Native docsNative primitives