Skip to main content

Interface: CanvasProps

Props for Canvas component.

See

Canvas

Properties

PropertyTypeDescription

children?

ReactNode

Canvas widgets to display alongside the diagram cells.

Non-widget child elements will be ignored with an console-emitted warning.

elementTemplateResolver?

TypedElementResolver

Custom provider to render diagram elements.

Default is to render elements with StandardTemplate.

linkRouter?

LinkRouter

Custom provider to route (layout) diagram links on the diagram.

Default is an DefaultLinkRouter instance.

linkTemplateResolver?

LinkTemplateResolver

Custom provider to render diagram links of a specific type.

Default is to render links with DefaultLinkTemplate which uses DefaultLinkPathTemplate for the link itself.

showScrollbars?

boolean

Whether to show scrollbars for the canvas viewport.

Default

false

watermarkSvg?

string

SVG image source to display as a watermark in the top-right corner of the canvas.

Default is no watermark.

watermarkUrl?

string

Link URL to open on a click on the watermark image.

Only applicable if watermarkSvg is set.

Default is no link on the watermark.

zoomOptions?

ZoomOptions

Options for the scale-affecting operations on the canvas.