DocMosaicdocs
Primitives

Editor.PageThumbnail

One thumbnail in the Editor.Pages list.

One thumbnail in the Editor.Pages list.

Usage

import { Editor } from '@docmosaic/react';

<Editor.Root>
    <Editor.PageThumbnail />
</Editor.Root>;

API Reference

PropTypeDefaultDescription
page *Page-

The page data

index *number-

The page index

isSelected *boolean-

Whether this page is currently selected

sections *Section[]-

The sections (images) on this page

pageSize *enum-

The page size (A4, etc.)

orientation *enum-

The page orientation

onSelect *() => void-

Callback when the page is selected

onDelete *() => void-

Callback when the page is deleted

dragHandlers *{ onDragStart: (e: DragEvent<Element>) => void; onDragEnd: () => void; onDragOver: (e: DragEvent<Element>) => void; }-

Drag and drop handlers

dropIndicators{ isDragOver: boolean; dropPosition: "top" | "bottom" | null; } | undefined-

Visual indicators for drag and drop

readOnlyboolean | undefined-

When true, the per-page delete button is hidden and the thumbnail is not draggable (so it cannot be reordered). The thumbnail still stays selectable. Defaults to false.

  • Root - the orchestrator