Interface: IDefaultItemsConfig
The configuration of new design elements that the user will add to the product.
Remarks
For details, see the Toolbox https://customerscanvas.com/dev/editors/iframe-api/editor-configuration/toolbox.html|Toolbox topic.
Example
var configuration = {
defaultItemsConfig: {
text: {
font: {
postScriptName: "Impact",
size: 33,
fauxBold: true,
fauxItalic: true,
},
color: "rgb(0,255,255)",
verticalAlignment: "center",
isVertical: true,
tracking: 27,
leading: 125,
},
line: {
width: 3,
color: "rgb(255,0,0)",
linePermissions: {
allowChangeLineWidth: false,
},
},
image: {
manipulationPermissions: {
allowMoveHorizontal: false,
allowMoveVertical: false,
resizeGrips: {
edge: true,
corner: ["Arbitrary"],
},
},
themeBinding: {
img: "main",
},
},
},
};
var editor = await CustomersCanvas.IframeApi.loadEditor(
iframe,
productDefinition,
configuration,
);
Properties
image?
optionalimage?:IGalleryItemConfig
Default parameters of images, which users add to the canvas.
shape?
optionalshape?:IShapeItemData
Default parameters of custom shapes, which users add to the canvas.
barcode?
optionalbarcode?:IBarcodeItemData
Default parameters of barcodes, which users add to the canvas.
text?
optionaltext?:ITextItemData
Default parameters of text, which users add to the canvas.
richText?
optionalrichText?:IRichTextData
Default parameters of rich formatted text elements, which users add to the canvas.
archedText?
optionalarchedText?:IArchedTextItemData
Default parameters of arched text elements, which users add to the canvas.
line?
optionalline?:ILineItemData
Default parameters of lines, which users add to the canvas.
rectangle?
optionalrectangle?:IRectangleItemData
Default parameters of rectangles, which users add to the canvas.
ellipse?
optionalellipse?:IEllipseItemData
Default parameters of ellipses, which users add to the canvas.
placeholder?
optionalplaceholder?:IPlaceholderItemData
Default parameters of image placeholders, which users add to the canvas.
group?
optionalgroup?:IGroupItemData
Default parameters of groups, which users add to the canvas.
clipart?
optionalclipart?:IClipartItemData
Default parameters of clipart, which users add to the canvas.