Interface IDesignEditorDefinitionSetPrintArea
Provides properties to set up a print area. For details, you can refer to the SetPrintArea command.
{
"type": "design-editor",
"name": "editor",
"params": {
"initial": { ... },
"setPrintArea": {
"options": {
"preserveUserChanges": true,
"updateRevertData": false
},
"data": {
"designFile": "{{vars.designRoot + '/' + $['card-size']._.title}}"
}
}
}
}
Package: ui-framework
Properties
after
The next commands to be executed after this command completes.
Declaration
after?: string | string[]
Property Value
| Type | Description |
|---|---|
| string | string[] | The next commands to be executed after this command completes. |
autoCompile
If false, action will never execute automatically.
Declaration
autoCompile?: boolean
Property Value
| Type | Description |
|---|---|
| boolean | If |
data
The print area definition.
Declaration
data: CustomersCanvas
Property Value
| Type | Description |
|---|---|
| CustomersCanvas | The print area definition. |
executeOnce
If true, this command will be executed only once.
You can use it for initial command.
For example, we need to change surface depending on the option value.
We write for initial and for updateSurfaces the same productDefinition with $['option]._
And set executeOnce = true for initial. And initial will be executed only once.
Declaration
executeOnce?: boolean
Property Value
| Type | Description |
|---|---|
| boolean | If |
executeOnlyAfter
Current command will be executed in a next update only after all commands executed in this param.
The same example from executeOnce param.
We need to execute updateSurface on all next updates, exclude the first one.
And we set executeOnlyAfter = ['initial'] for updateSurface command.
Declaration
executeOnlyAfter?: string[]
Property Value
| Type | Description |
|---|---|
| string[] | Current command will be executed in a next update only after all commands executed in this param.
The same example from |
lock
Name of widgets that show preloader when command executed.
Declaration
lock?: string[]
Property Value
| Type | Description |
|---|---|
| string[] | Name of widgets that show preloader when command executed. |
message
The message for preloader.
Declaration
message?: string | string[]
Property Value
| Type | Description |
|---|---|
| string | string[] | The message for preloader. |
onExecuted
Functions that executed after command
Declaration
onExecuted?: Function | Function[]
Property Value
| Type | Description |
|---|---|
| Function | Function[] | Functions that executed after command |
options
Additional configuration parameters. For details, see the reference.
Declaration
options: ISetPrintAreaOptions
Property Value
| Type | Description |
|---|---|
| ISetPrintAreaOptions | Additional configuration parameters. For details, see the reference. |
showPreloader
If true, displays the preloader while executing this command.
Declaration
showPreloader?: boolean
Property Value
| Type | Description |
|---|---|
| boolean | If |
surfaceIndex
The index of a surface that should be modified (the current surface if omitted).
Declaration
surfaceIndex?: number
Property Value
| Type | Description |
|---|---|
| number | The index of a surface that should be modified (the current surface if omitted). |
timeout
The timeout for switching preloader messages.
Declaration
timeout?: number
Property Value
| Type | Description |
|---|---|
| number | The timeout for switching preloader messages. |