UNPKG

document-scanner-vue

Version:

Vue 3 Document Scanner with OpenCV.js - Mobile optimized with camera/gallery support

67 lines 2.9 kB
import { Ref } from 'vue'; import { Page, PageUpdate } from '../types'; export declare function usePageManager(): { pages: import("vue").ComputedRef<readonly { readonly id: string; readonly originalFile: { readonly lastModified: number; readonly name: string; readonly webkitRelativePath: string; readonly size: number; readonly type: string; readonly arrayBuffer: () => Promise<ArrayBuffer>; readonly bytes: () => Promise<Uint8Array>; readonly slice: (start?: number, end?: number, contentType?: string) => Blob; readonly stream: () => ReadableStream<Uint8Array>; readonly text: () => Promise<string>; }; readonly originalFileName: string; readonly originalImageDataURL: string; readonly originalWidth: number; readonly originalHeight: number; readonly corners: readonly [{ readonly x: number; readonly y: number; }, { readonly x: number; readonly y: number; }, { readonly x: number; readonly y: number; }, { readonly x: number; readonly y: number; }] | null; readonly currentRotation: 0 | 90 | 180 | 270; readonly processedImageDataURL?: string | null | undefined; readonly processedWidth?: number | null | undefined; readonly processedHeight?: number | null | undefined; readonly timestampProcessed?: number | null | undefined; readonly mode: "edit" | "preview"; readonly timestampAdded: number; readonly outputFormat?: { readonly name: string; readonly ratio: number; readonly dimensions: string; readonly category: "standard" | "custom"; } | null | undefined; readonly detectedRatio?: number | null | undefined; readonly detectedConfidence?: number | null | undefined; }[]>; activePageId: Readonly<Ref<string | null, string | null>>; currentPage: import("vue").ComputedRef<Page | null>; pageCountDisplay: import("vue").ComputedRef<string>; totalPages: import("vue").ComputedRef<number>; addFilesAsPages: (files: File[]) => Promise<string[]>; addFileAsPageWithProgress: (file: File, progressCallback: (status: string, progress: number) => void) => Promise<string>; selectPage: (pageId: string | null) => void; updatePageData: (pageId: string, data: PageUpdate) => void; deletePage: (pageId: string) => void; getPageById: (pageId: string) => Page | undefined; clearAllPages: () => void; reorderPages: (fromIndex: number, toIndex: number) => void; moveToNextPage: () => void; moveToPrevPage: () => void; cleanupAllObjectURLs: () => void; }; //# sourceMappingURL=usePageManager.d.ts.map