Skip to main content

sdk.illustrationapi

Home > @kittl/sdk > IllustrationAPI

IllustrationAPI interface

API for adding and updating illustrations in the design.

Signature:

export interface IllustrationAPI 

Methods

Method

Description

addIllustration(params, opts)

Adds a new illustration to the design canvas.

This method creates a new illustration object by first retrieving the image dimensions from the provided source URL, then adding the illustration to the design state with the specified parameters and calculated dimensions.

updateIllustration(params, opts)

Updates an existing illustration on the design canvas.

This method modifies the properties of an existing illustration object without changing its source image or recalculating dimensions.