Interface ISurfaceFromState
A structure holding settings to create a surface from a state file.
Package: @aurigma/design-editor-iframe
Examples
const productDefinition = {
surfaces: [{
// Initialize a surface through a state file.
stateId: "ed867273-5679-4927-b718-a53e92d6802c",
// Select a surface index in the state file.
surface: 2,
// Apply a background mockup to the surface.
mockup: {
down: "tshirt"
},
// Specify the design location relative to the mockup.
location: { x: 120, y: 0 }
}]
};
Properties
location
Coordinates of the design relative to the upper-left corner of the mockup, in points.
Declaration
location?: PointF;
Property Value
| Type | Description |
|---|---|
| PointF | Coordinates of the design relative to the upper-left corner of the mockup, in points. |
stateId
The name of a state file.
Declaration
stateId: string;
Property Value
| Type | Description |
|---|---|
| string | The name of a state file. |
surface
A surface index in the state file. The default value is 0 that stands for the first surface.
Declaration
surface?: number;
Property Value
| Type | Description |
|---|---|
| number | A surface index in the state file. The default value is |