import * as React from 'react'; import { ContextMenuRendererComponent, IGraphicalContextData, IPoint, IShapesDeclarations } from '../declarations'; import { IEditorAction } from '../editor-state/editor-action'; import { IEditorEvent } from '../editor-state/editor-events'; import { IPersistedHistoryEvent } from '../history/history-event'; export interface IRootPropTypes { contextMenuRenderer: ContextMenuRendererComponent; author: string; shapesDeclarations: IShapesDeclarations; initialGraphicalContextData: IGraphicalContextData; history: IPersistedHistoryEvent[]; width: string; height: string; children: React.ReactElement | Array>; pushEvent(ev: IPersistedHistoryEvent): any; updateEvent(id: string, newEv: IPersistedHistoryEvent): any; deleteEvent(id: string): any; getNewHistoryEventId(): string; onViewportPositionChange(pos: IPoint): void; } export default class RootComponent extends React.Component { constructor(props: any, context: any); getEditorState: () => any; componentWillReceiveProps(nextProps: IRootPropTypes): void; performHistoryAction(action: IEditorAction): any; onEditorEvent: (ev: IEditorEvent) => void; getViewportPosition(): IPoint; getPNGBlob(cb: ((data: Blob) => void)): void; render(): JSX.Element; protected onContextMenu: (e: React.MouseEvent) => void; }