Upgrade Notes
- 5 minutes to read
We actively develop the Customer's Canvas API and realize that critical changes may be unacceptable and complicate the update process. When some API elements become inconsistent and inconvenient, we first declare them deprecated, and they work in parallel with the new functionality for a while. In further major releases, we delete such deprecated elements.
Design Editor 6 Upgrade Notes
When upgrading Design Editor 5 to 6, you will face breaking changes in configuration parameters, markers, and the Web API.
- Bleed and Slug
- Changed configuration parameters
- Removed parameters
- Removed markers
- Renamed parameters in the Web API 6
Bleed Zone and Print Area Size
Starting from version 5.33, we have changed the way we define the bleed zone and print area size. Earlier, if you wanted to create a 3.5x2" business card with 1/8" bleed, you created a 3.75x2.25" design and put a safety line inside it. But now, when you create a 3.5x2" design, the bleed zone will expand outside the design.
After upgrading to version 6, you may run into a problem when the size of the product is not what you expect, and unnecessary safety lines may also appear. If you encounter this, you can either rework the design and change the Bleed and Slug settings, or enable the old behavior. In the latter case, set LegacyIdmlBleedParsingEnabled
to True
in Aurigma.DesignAtoms.config.
For more details, refer to Importing the bleed zone from InDesign.
Changed Parameters in Configuration Files
clientConfig.json
Parameter Name | Old Value | New Value |
---|---|---|
watermark.text.fontSettings | "ArialMT" | "Roboto-Regular" |
AppSettings.config
Parameter Name | Old Value | New Value |
---|---|---|
FontSubstitutionEnabled | "True" | "False" |
SubstitutionFontPostScriptName | "ArialMT" | "Roboto-Regular" |
DefaultFontPostScriptName | "ArialMT" | "Roboto-Regular" |
Removed Configuration Parameters
AppSettings.config
Parameter Name | An Alternative |
---|---|
ParagraphTextEnabled | Not applicable |
clientConfig.json
Parameter Name | An Alternative |
---|---|
arbitraryResizeForImageItemEnabled | IResizeGripsPermissions |
defaultAssetSelectWidget | Not applicable |
newImageName | defaultItemsConfig.image.name |
canvas.snapLines.enabled | canvas.snapLines.{type}.enabled |
canvas.snapLines.color | canvas.snapLines.{type}.color |
canvas.snapLines.tolerance | canvas.snapLines.{type}.tolerance |
canvas.ZoomStep | canvas.zoom |
widgets.BottomToolbar.snapLinesCheckboxEnabled | widgets.BottomToolbar.snapLines{type}CheckboxEnabled |
widgets.ColorPicker.defaultColorSpace | widgets.ColorPicker.colorSpace |
widgets.ColorPicker.availableColorSpaces | Not applicable |
widgets.ColorPicker.palette | IPaletteSection |
Removed Markers
Marker Name | An Alternative |
---|---|
<DPH> | Dynamic Image API |
Renamed parameters in the Web API 6
Endpoints
POST ~/api/Preview/GeneratePreview
POST ~/api/HiRes/GenerateHiRes
Parameters in the request payload
Old Parameter | New Parameter |
---|---|
previewOptions.width |
previewOptions.maxWidth |
previewOptions.height |
previewOptions.maxHeight |
Attributes in the response object
Old Attribute | New Attribute |
---|---|
ProofImageUrls |
proofImageUrls |
StateId |
stateId |
HiResUrls |
hiResUrls |
Design Editor 5 Upgrade Notes
When upgrading Design Editor 4 to 5, you will face breaking changes in configuration parameters, markers, and the API.
- Changed configuration parameters
- Removed parameters
- Removed markers
- Changes in the ObjectModel
- Changes in the Web API 5
- Migrating Applications from DE 4 to 5
Changed Configuration Parameters
clientConfig.json
Parameter Name | Old Value | New Value |
---|---|---|
defaultAssetSelectWidget | "GalleryDialog" | "AssetManager" |
spellCheckEnabled | false | true |
canvas.shadowEnabled | true | false |
canvas.qualityChangeContainersEnabled | false | true |
canvas.violationWarningButtonsEnabled | false | true |
rendering.hiResOutputColorSpace | "rgb" | "cmyk" |
rendering.hiResOutputInStringPlaceholderHintsEnabled | true | false |
rendering.proofImageFileFormat | "png" | "jpeg" |
rendering.proofImageCropSafetyLine | "bleed" | "" |
rendering.proofImageSafetyLinesEnabled | false | true |
rendering.proofImageInStringPlaceholderHintsEnabled | true | false |
violationWarningsSettings.qualityMeter.qualityLevels.bad | 100 | 50 |
violationWarningsSettings.shapeViolationsEnabled | false | true |
violationWarningsSettings.textCropViolationWarningEnabled | false | true |
widgets.BottomToolbar.fullWindowButtonEnabled | true | false |
widgets.BottomToolbar.rotateButtonEnabled | false | true |
widgets.BottomToolbar.surfaceSwitch.showThumbnails | true | false |
widgets.ColorPicker.defaultColorSpace | "rgb" | "cmyk" |
widgets.common.fontSize.max | 100 | 1296 |
widgets.common.leading.max | 100 | 1296 |
widgets.common.tracking.min | -150 | -300 |
widgets.ObjectInspector.aboveCanvasOnSmallScreenEnabled | false | true |
widgets.ObjectInspector.inStringPlaceholderMode | "Single" | "Multiple" |
widgets.ObjectInspector.position | "Left" | "Right" |
widgets.QrCodeDialog.defaultType | "QrVCard" | "QrUrl" |
widgets.TopToolbar.alignButtonsEnabled | false | true |
widgets.TopToolbar.deleteButtonEnabled | true | false |
widgets.TopToolbar.displayAlignButtonsAsDropdown | false | true |
widgets.TopToolbar.displayZOrderButtonsAsDropdown | false | true |
AppSettings.config
Parameter Name | Old Value | New Value |
---|---|---|
DesignFolder | "\ProductTemplates\designs" | "..\assets\designs" |
MockupFolder | "\ProductTemplates\mockups" | "..\assets\mockups" |
WatermarkFolder | "\ProductTemplates\watermarks" | "..\assets\helpers" |
DesignImagesFolder | "\ProductTemplates\designImages" | "..\assets\helpers" |
PublicGalleryFolder | "\PublicGalleryFolder" | "..\assets\images" |
UserDataFolder | "\UserDataFolder" | "..\userdata" |
LoadFontListAsPostScriptNames | "False" | "True" |
Hinting | "Enabled" | "Auto" |
SepiaAlgorithm | "Standard" | "MoreBrown" |
SecureModeEnabled | "False" | "True" |
Aurigma.DesignAtoms.config
VectorObjects.config is renamed to Aurigma.DesignAtoms.config and receives the following changes.
Parameter Name | Old Value | New Value |
---|---|---|
FontDirectory | "\Fonts" | "..\assets\fonts" |
ColorProfilesDirectory | "" | "..\assets\ColorProfiles" |
Removed Parameters
clientConfig.json
Parameter Name | Recommended Replacement |
---|---|
defaultItemsConfig.<item>.showDeleteButton | IItemToolbarPermissionsConfig |
defaultItemsConfig.<item>.showEditButton | IItemToolbarPermissionsConfig |
defaultItemsConfig.<item>. | IResizeGripsPermissions |
defaultItemsConfig.<item>. | IResizeGripsPermissions |
rendering.proofImageWatermarkEnabled | IWatermarkConfig |
rendering.proofImageWatermarkFontPostScriptName | IWatermarkConfig |
rendering.proofImageWatermarkFontSize | IWatermarkConfig |
rendering.proofImageWatermarkText | IWatermarkConfig |
widgets.BottomToolbar.surfaceSwitchEnabled | ISurfaceSwitchConfig |
widgets.GalleryDialog.defaultTab | ITabDescriptor |
widgets.GalleryDialog.downloadPsdAsImage | ITabDescriptor |
widgets.GalleryDialog.publicTabEnabled | ITabDescriptor |
widgets.GalleryDialog.userTabEnabled | ITabDescriptor |
widgets.GalleryDialog.publicFolderName | ITabDescriptor |
widgets.GalleryDialog.socialNetworkAppIds | ITabDescriptor |
widgets.LeftToolbar | IToolboxConfig |
widgets.ObjectInspector.qualityMeterEnabled | IQualityMeterConfig |
widgets.ObjectInspector. | IViolationWarningsSettingsConfig |
widgets.ObjectInspector. | IViolationWarningsSettingsConfig |
widgets.Toolbox. | IObjectInspectorConfig |
widgets.TopToolbar.zOrderButtonsEnabled | IZOrderConfig |
Removed Markers
Marker Name | Recommended Replacement |
---|---|
<FRT> | <RT> |
<IAPSF> | <IASF> |
<MAAR> | <MRE> |
<MAPR> | <MRC> |
<PSED> | <PAEC> |
<TACS> | <TACBIU> |
Changes in the ObjectModel
Removed Member | Recommended Replacement |
---|---|
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
Customerscanvas.IframeApi. | Customerscanvas.IframeApi. |
New syntax
setMockup(mockup: IMockupTemplate, previewMockups?: IMockupTemplate[], options?: {
updateRevertData?: boolean;
}): Promise<Product>;
Changes in the Web API 5
Old Endpoint | New Endpoint |
---|---|
~/api/users/{userId}/{stateId} | ~/api/users/{userId}/states/{stateId} |
Migrating Applications from DE 4 to 5
Removing the Eval Function
In Customer's Canvas 4, you could access the Design Editor and its object model through the spEditor
object in the eval
function. Although you can still use this way, which is not recommended, the code executed in this function is likely to stop working because of changes in the IFrame API. In the current implementation, you have full access to the object model right through the IFrame API.
Let's see in what use cases you could use eval
and how you can replace this function now.
Getting the User ID
Since the userId
property has been removed from the object model in version 5, the following call returns undefined
.
let editor = await CustomersCanvas.IframeApi.loadEditor(iframe, product, config);
console.log(await editor.eval("spEditor.model.product.userId"));
Instead, you can get the user ID from the runtime configuration as follows:
let editor = await CustomersCanvas.IframeApi.loadEditor(iframe, product, config);
console.log(await editor.configuration.getUserId());
Getting the Product Model
Instead of using the spEditor.model
:
let productModel = await editor.eval(() => {
return spEditor.model.product;
});
You can now obtain a product model as follows:
let product = await editor.getProduct();
let productModel = await product.getProductModel();
Note that despite the previous way, the model obtained through getProductModel
represents only a snapshop of the product loaded into the editor. If you change the model, you need to apply these changes to the product by using the setProductModel
method.
product.setProductModel(newProductModel);
Working with Design Elements
Instead of using the spEditor.productHandler
object:
let item = spEditor.productHandler.getAllItems().find(x => x.name === "Logo");
For example, you can find an element by its name as follows:
let item = await product.getItemByName("Logo");
Changing the setMockup Calls
In Design Editor 5, you can set a mockup to a surface only through the IMockupTemplate
interface. You can use the setMockup
method as follows:
let newProduct = await product.currentSurface.setMockup(
{
up: "stamp",
down: "envelope"
},
previewMockups: [{ down: "envelope" }]
);
Changing Endpoints of the StateFiles Controller
If your application uses the Web API for manipulating state files through the deprecated endpoint:
~/api/users/{userId}/{stateId}
Then you must replace it with the new endpoint:
~/api/users/{userId}/states/{stateId}