UNPKG

phx-react

Version:

PHX REACT

51 lines (50 loc) 1.42 kB
import { ExcalidrawElement, NonDeleted } from '@excalidraw/excalidraw/types/element/types'; import { AppState, BinaryFiles } from '@excalidraw/excalidraw/types/types'; import * as React from 'react'; type ImageType = 'svg' | 'canvas'; type Props = { /** * Configures the export setting for SVG/Canvas */ appState: AppState; /** * The css class applied to image to be rendered */ className?: string; /** * The Excalidraw elements to be rendered as an image */ elements: Array<NonDeleted<ExcalidrawElement>>; /** * The Excalidraw elements to be rendered as an image */ files: BinaryFiles; /** * The height of the image to be rendered */ height?: number | null; /** * The ref object to be used to render the image */ imageContainerRef: { current: null | HTMLDivElement; }; /** * The type of image to be rendered */ imageType?: ImageType; /** * The css class applied to the root element of this component */ rootClassName?: string | null; /** * The width of the image to be rendered */ width?: number | null; }; /** * @explorer-desc * A component for rendering Excalidraw elements as a static image */ export default function ExcalidrawImage({ appState, elements, files, imageContainerRef, rootClassName, }: Props): React.JSX.Element; export {};