Edit Viewer
retab-ui/edit-viewer-blockFreeBlock
Detected form fields beside a PDF source document, linked by their bbox — hover or select a field to highlight its region on the page; Preview stamps values over the source, and Filled renders a supplied output file.
Install it
npx shadcn@latest add https://ui.retab.com/r/edit-viewer-block.jsonSource
1"use client";23import { EditViewer } from "@/components/viewers/edit/edit-viewer";4import type { FormField } from "@/components/viewers/lib/edit-types";5import editSample from "@/components/viewers/sample-data/edit.json";67const ORIGINAL_PDF_URL = "/samples/fidelity-edit/fidelity_original.pdf";89// A template-fill of the Fidelity "Bank Wire Authorization" form: 29 detected10// form fields across 3 pages, each with a normalized bbox and an inferred value.11const EDIT_FIELDS = editSample as FormField[];1213/**14 * Edit viewer block — detected fields beside the source document, linked by15 * their bbox. `EditViewer` owns edit-specific modes, field visuals, search,16 * filters, and page grouping while segmented-document owns hover,17 * selection, and scroll-to-field behavior.18 */19export function EditViewerBlock() {20 return (21 <div className="bg-background flex h-full min-h-[680px] flex-col">22 <EditViewer23 result={{ fields: EDIT_FIELDS }}24 sourceDocument={{25 src: ORIGINAL_PDF_URL,26 mimeType: "application/pdf",27 filename: "fidelity-bank-wire-authorization.pdf",28 }}29 />30 </div>31 );32}
What it pulls in
npm packages
Other registry items
Files it writes
More from retab-ui
All 130 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Classify Consensusclassify-consensus-viewer-block | retab-ui | Blocks | Free | 1 dep · 4 files | |
| CSV Sourcescsv-sources-block | retab-ui | Blocks | Free | no deps · 2 files | |
| DOCX Sourcesdocx-sources-block | retab-ui | Blocks | Free | no deps · 2 files | |
| Avatar Image Slotdropzone-avatar-image-slot | retab-ui | Blocks | Free | 1 dep · 2 files | |
| Dropzonedropzone-block | retab-ui | Blocks | Free | 1 dep · 26 files | |
| Comparison Pairdropzone-comparison-pair-upload | retab-ui | Blocks | Free | 1 dep · 2 files | |
| Controlled Queuedropzone-controlled-queue | retab-ui | Blocks | Free | 1 dep · 2 files | |
| Custom Thumbnail Griddropzone-custom-thumbnail-grid | retab-ui | Blocks | Free | 1 dep · 2 files |
