Skip to main content

sdk.boardapi

Home > @kittl/sdk > BoardAPI

BoardAPI interface

API for creating and managing artboards (design canvases) in the design.

Signature:

export interface BoardAPI 

Methods

Method

Description

cloneArtboard(params, opts)

Clones an existing artboard and creates a new one with the same properties and content.

This method creates an exact copy of an existing artboard, including all its design elements, group structures, and properties. The cloned artboard can be positioned relative to the original or at absolute coordinates. All objects within the artboard are also cloned with new IDs and updated positions to match the new artboard location.

createStandardBoard(params, opts)

Creates a new non-floating artboard at the specified position with the given dimensions.

This method creates a standard artboard that acts as a container for design elements. The artboard can be positioned relative to existing artboards or at absolute coordinates. If no title is provided, a default title will be generated based on the current artboard count.

updateArtboard(params, opts)

Updates properties of an existing artboard.

This method allows partial updates to any artboard property including nested artboard options. Only the specified properties in the parameters will be modified; all other properties remain unchanged.

updateArtboardBackground(params, opts)

Updates the background image properties of an existing artboard.

This method allows modification of the background image object name/source. The method preserves all existing artboard properties while only updating the specified background image attributes.