@aurigma/ui-framework
Version:
A platform which allows building print product personalization editors based on Aurigma's Customer's Canvas.
96 lines (63 loc) • 1.93 kB
Markdown
A command that defines the canvas zoom.
A command that defines the canvas zoom.
For details, you can refer to the [IDesignEditorDefinitionSetViewerSettings](../interfaces/idesigneditordefinitionsetviewersettings.md).
```
{
"type": "design-editor",
"name": "editor",
"params": {
"initial": { ... },
"setViewerSettings": {
"zoom": 0.1,
"zoomMode": 'bestFit',
"scrollPosition": {x: 0, y: 0}
}
}
}
```
For details, you can refer to the [ICanvasDefinitionSetViewerSettings](../interfaces/icanvasdefinitionsetviewersettings.md).
```
{
"type": "canvas",
"name": "editor",
"params": {
"initial": { ... },
"setViewerSettings": {
"zoom": 0.1,
"zoomMode": 'bestFit',
"scrollPosition": {x: 0, y: 0}
}
}
}
```
* [DesignEditorWidgetCommand](designeditorwidgetcommand.md)
* [CanvasWidgetCommand](canvaswidgetcommand.md)
↳ **SetViewerSettings**
* IDesignAtomsCommand
* [Name](setviewersettings.md
* [name](setviewersettings.md
* [execute](setviewersettings.md
▪ **Name**: *"setViewerSettings"* = "setViewerSettings"
• **get name**(): *string*
**Returns:** *string*
▸ **execute**(`params`: [IDesignEditorDefinitionSetViewerSettings](../interfaces/idesigneditordefinitionsetviewersettings.md)): *Promise‹void›*
*Overrides [DesignEditorWidgetCommand](designeditorwidgetcommand.md).[execute](designeditorwidgetcommand.md
Executes this command.
**Parameters:**
Name | Type | Description |
------ | ------ | ------ |
`params` | [IDesignEditorDefinitionSetViewerSettings](../interfaces/idesigneditordefinitionsetviewersettings.md) | Parameters for the command. |
**Returns:** *Promise‹void›*