import { Action } from '@embedpdf/core'; import { PageAnalysisState, PageLayout, TableStructureElement } from './types'; export declare const INIT_LAYOUT_STATE = "LAYOUT_ANALYSIS/INIT_STATE"; export declare const CLEANUP_LAYOUT_STATE = "LAYOUT_ANALYSIS/CLEANUP_STATE"; export declare const SET_PAGE_STATUS = "LAYOUT_ANALYSIS/SET_PAGE_STATUS"; export declare const SET_PAGE_LAYOUT = "LAYOUT_ANALYSIS/SET_PAGE_LAYOUT"; export declare const SET_PAGE_ERROR = "LAYOUT_ANALYSIS/SET_PAGE_ERROR"; export declare const SET_LAYOUT_OVERLAY_VISIBLE = "LAYOUT_ANALYSIS/SET_LAYOUT_OVERLAY_VISIBLE"; export declare const SET_TABLE_STRUCTURE_OVERLAY_VISIBLE = "LAYOUT_ANALYSIS/SET_TABLE_STRUCTURE_OVERLAY_VISIBLE"; export declare const SET_LAYOUT_THRESHOLD = "LAYOUT_ANALYSIS/SET_LAYOUT_THRESHOLD"; export declare const SET_TABLE_STRUCTURE_THRESHOLD = "LAYOUT_ANALYSIS/SET_TABLE_STRUCTURE_THRESHOLD"; export declare const SELECT_BLOCK = "LAYOUT_ANALYSIS/SELECT_BLOCK"; export declare const SET_TABLE_STRUCTURE_ENABLED = "LAYOUT_ANALYSIS/SET_TABLE_STRUCTURE_ENABLED"; export declare const SET_PAGE_TABLE_STRUCTURES = "LAYOUT_ANALYSIS/SET_PAGE_TABLE_STRUCTURES"; export declare const CLEAR_PAGE_RESULTS = "LAYOUT_ANALYSIS/CLEAR_PAGE_RESULTS"; export declare const CLEAR_ALL_RESULTS = "LAYOUT_ANALYSIS/CLEAR_ALL_RESULTS"; export interface InitLayoutStateAction extends Action { type: typeof INIT_LAYOUT_STATE; payload: { documentId: string; }; } export interface CleanupLayoutStateAction extends Action { type: typeof CLEANUP_LAYOUT_STATE; payload: string; } export interface SetPageStatusAction extends Action { type: typeof SET_PAGE_STATUS; payload: { documentId: string; pageIndex: number; status: PageAnalysisState['status']; }; } export interface SetPageLayoutAction extends Action { type: typeof SET_PAGE_LAYOUT; payload: { documentId: string; pageIndex: number; layout: PageLayout; }; } export interface SetPageErrorAction extends Action { type: typeof SET_PAGE_ERROR; payload: { documentId: string; pageIndex: number; error: string; }; } export interface SetLayoutOverlayVisibleAction extends Action { type: typeof SET_LAYOUT_OVERLAY_VISIBLE; payload: boolean; } export interface SetTableStructureOverlayVisibleAction extends Action { type: typeof SET_TABLE_STRUCTURE_OVERLAY_VISIBLE; payload: boolean; } export interface SetLayoutThresholdAction extends Action { type: typeof SET_LAYOUT_THRESHOLD; payload: number; } export interface SetTableStructureThresholdAction extends Action { type: typeof SET_TABLE_STRUCTURE_THRESHOLD; payload: number; } export interface SelectBlockAction extends Action { type: typeof SELECT_BLOCK; payload: string | null; } export interface SetTableStructureEnabledAction extends Action { type: typeof SET_TABLE_STRUCTURE_ENABLED; payload: boolean; } export interface SetPageTableStructuresAction extends Action { type: typeof SET_PAGE_TABLE_STRUCTURES; payload: { documentId: string; pageIndex: number; tableStructures: Map; }; } export interface ClearPageResultsAction extends Action { type: typeof CLEAR_PAGE_RESULTS; payload: { documentId: string; pageIndex: number; }; } export interface ClearAllResultsAction extends Action { type: typeof CLEAR_ALL_RESULTS; payload: { documentId: string; }; } export type LayoutAnalysisAction = InitLayoutStateAction | CleanupLayoutStateAction | SetPageStatusAction | SetPageLayoutAction | SetPageErrorAction | SetLayoutOverlayVisibleAction | SetTableStructureOverlayVisibleAction | SetLayoutThresholdAction | SetTableStructureThresholdAction | SelectBlockAction | SetTableStructureEnabledAction | SetPageTableStructuresAction | ClearPageResultsAction | ClearAllResultsAction; export declare function initLayoutState(documentId: string): InitLayoutStateAction; export declare function cleanupLayoutState(documentId: string): CleanupLayoutStateAction; export declare function setPageStatus(documentId: string, pageIndex: number, status: PageAnalysisState['status']): SetPageStatusAction; export declare function setPageLayout(documentId: string, pageIndex: number, layout: PageLayout): SetPageLayoutAction; export declare function setPageError(documentId: string, pageIndex: number, error: string): SetPageErrorAction; export declare function setLayoutOverlayVisible(visible: boolean): SetLayoutOverlayVisibleAction; export declare function setTableStructureOverlayVisible(visible: boolean): SetTableStructureOverlayVisibleAction; export declare function setLayoutThreshold(threshold: number): SetLayoutThresholdAction; export declare function setTableStructureThreshold(threshold: number): SetTableStructureThresholdAction; export declare function selectBlock(blockId: string | null): SelectBlockAction; export declare function setTableStructureEnabled(enabled: boolean): SetTableStructureEnabledAction; export declare function setPageTableStructures(documentId: string, pageIndex: number, tableStructures: Map): SetPageTableStructuresAction; export declare function clearPageResults(documentId: string, pageIndex: number): ClearPageResultsAction; export declare function clearAllResults(documentId: string): ClearAllResultsAction;