X Enterprises
Document

DocumentGrid

Card grid display of documents with thumbnail previews and action menus.

Document

The Document category provides a complete file management system — from drag-and-drop upload through grid/list browsing to in-browser preview. Components are composable: use XADocumentManager for a turnkey solution or assemble individual pieces for custom layouts.

Components

<XADocumentGrid />

Wraps documents in a flex card grid with thumbnail previews for images and file-type icons for other types.

<XADocumentGrid
  :documents="files"
  :loading="isLoading"
  size="md"
  :show-actions="true"
  :selectable="true"
  v-model:selected="selectedIds"
  @click="openDocument"
  @preview="openPreview"
  @delete="deleteDocument"
/>

Props

PropTypeDefaultDescription
documentsArrayrequiredArray of document objects
loadingBooleanfalseShow loading skeleton
size'sm' | 'md' | 'lg''md'Card size variant
showActionsBooleantrueShow action menu on items
selectableBooleanfalseEnable multi-select
selectedArray[]Selected document IDs (v-model:selected)
emptyIconString'i-lucide-files'Empty state icon
emptyTitleString'No documents'Empty state title
emptyDescriptionString'Upload files to get started.'Empty state description

Emits

click, preview, download, rename, delete, update:selected

AI Context

component: XADocumentGrid
package: "@xenterprises/nuxt-x-app"
auto-import: true
prefix: XA
category: Document
use-when: Displaying documents in a card grid layout with thumbnail previews. Use when you need custom layout control without the full XADocument orchestration.
document-object-shape: "{ id, name, size, type, url, thumbnailUrl?, createdAt?, uploadedAt? }"
Copyright © 2026