Interface Editor.IViolationWarningData
A structure containing details about design elements that have preflight problems.
Package: @aurigma/design-editor-iframe
Examples
const renderingResult = await editor.finishProductDesign()
// If an error occurred while completing product customization.
.catch(error => console.error("Completing product customization failed with exception: ", error));
// If product customization is completed successfully, get the promise properties.
stateId = renderingResult.stateId;
userId = renderingResult.userId;
returnToEditUrl = renderingResult.returnToEditUrl;
preflightProblems = renderingResult.violationWarningData;
console.log("User " + userId + " successfully saved state " + stateId);
if (preflightProblems.length > 0) {
console.log("The preflight check found some problems.");
}
Properties
bleedViolationState
A state of the bleed zone violation check. If Warning, the design element goes out of the bleed zone.
Declaration
bleedViolationState?: ViolationState.Warning | ViolationState.Good | ViolationState.None;
Property Value
| Type | Description |
|---|---|
| ViolationState.Warning | ViolationState.Good | ViolationState.None | A state of the bleed zone violation check. If |
dpiValue
A resolution of images or image placeholders that have the Warning or Bad states of the resolution check.
Declaration
dpiValue?: number;
Property Value
| Type | Description |
|---|---|
| number | A resolution of images or image placeholders that have the |
fontSizeViolationState
A state of the font size violation check. The state depends on container configuration: - If font size is smaller than required and configuration has severity: "warning", will be Warning - If font size is smaller than required and configuration has severity: "error", will be Bad
Declaration
fontSizeViolationState?: ViolationState;
Property Value
| Type | Description |
|---|---|
| ViolationState | A state of the font size violation check. The state depends on container configuration: - If font size is smaller than required and configuration has |
name
A name of the design element.
Declaration
name: string;
Property Value
| Type | Description |
|---|---|
| string | A name of the design element. |
qualityViolationState
A state of the resolution check of images and image placeholders. This value is either Good, Warning, or Bad.
Declaration
qualityViolationState?: ViolationState;
Property Value
| Type | Description |
|---|---|
| ViolationState | A state of the resolution check of images and image placeholders. This value is either |
rasterElementsViolationState
A state of the raster elements violation check. The state depends on container configuration: - If element contains raster images and configuration has severity: "warning", will be Warning - If element contains raster images and configuration has severity: "error", will be Bad
Declaration
rasterElementsViolationState?: ViolationState;
Property Value
| Type | Description |
|---|---|
| ViolationState | A state of the raster elements violation check. The state depends on container configuration: - If element contains raster images and configuration has |
regionViolationState
A state of the out-of-region check. If Warning, the design element goes out of the region.
Declaration
regionViolationState?: ViolationState.Warning | ViolationState.Good | ViolationState.None;
Property Value
| Type | Description |
|---|---|
| ViolationState.Warning | ViolationState.Good | ViolationState.None | A state of the out-of-region check. If |
safetyLineViolationState
A state of the safety zone violation check. If Warning, the design element goes out of the safety lines.
Declaration
safetyLineViolationState?: ViolationState.Warning | ViolationState.Good | ViolationState.None;
Property Value
| Type | Description |
|---|---|
| ViolationState.Warning | ViolationState.Good | ViolationState.None | A state of the safety zone violation check. If |
shapeViolationState
A state of SVG and PDF upload check. Such graphics should appear on the canvas without any losses after uploading in the Shape mode.
Declaration
shapeViolationState?: ViolationState.Warning | ViolationState.Good | ViolationState.None;
Property Value
| Type | Description |
|---|---|
| ViolationState.Warning | ViolationState.Good | ViolationState.None | A state of SVG and PDF upload check. Such graphics should appear on the canvas without any losses after uploading in the |
surfaceIndex
An index of the surface containing the design element.
Declaration
surfaceIndex: number;
Property Value
| Type | Description |
|---|---|
| number | An index of the surface containing the design element. |
surfaceName
A name of the surface containing the design element.
Declaration
surfaceName: string;
Property Value
| Type | Description |
|---|---|
| string | A name of the surface containing the design element. |
textCropViolationState
A state of the text clipping check.
Declaration
textCropViolationState?: ViolationState.Warning | ViolationState.Good | ViolationState.None;
Property Value
| Type | Description |
|---|---|
| ViolationState.Warning | ViolationState.Good | ViolationState.None | A state of the text clipping check. |
type
A type of the design element, for example, PlainTextItem or ImageItem.
Declaration
type: string;
Property Value
| Type | Description |
|---|---|
| string | A type of the design element, for example, |