@aurigma/ui-framework
Version:
A platform which allows building print product personalization editors based on Aurigma's Customer's Canvas.
52 lines (34 loc) • 1.35 kB
Markdown
A command that replaces product pages.
Here, we replace the first page of the loaded product with the third page of a state file.
```
{
"type": "design-editor",
"name": "editor",
"params": {
"initial": { ... },
"updateSurfaces": [{
"definition": "{{ $['options']._.props.id }}",
"surfaces": [0],
"newProductSurfaces": [2],
"replaceAll": true
}]
}
}
```
* [DesignEditorWidgetCommand](designeditorwidgetcommand.md)
↳ **UpdateSurfacesCommand**
* [execute](updatesurfacescommand.md
▸ **execute**(`params`: [IUpdateSurfacesCommandDefinition](../interfaces/iupdatesurfacescommanddefinition.md)[] | [IUpdateSurfacesCommandDefinition](../interfaces/iupdatesurfacescommanddefinition.md)): *Promise‹void›*
*Overrides [DesignEditorWidgetCommand](designeditorwidgetcommand.md).[execute](designeditorwidgetcommand.md
Executes this command.
**Parameters:**
Name | Type | Description |
------ | ------ | ------ |
`params` | [IUpdateSurfacesCommandDefinition](../interfaces/iupdatesurfacescommanddefinition.md)[] &
**Returns:** *Promise‹void›*