---
title: "setViewerSettings | Customer's Canvas On-Premises"
canonical: "https://customerscanvas.com/docs/on-premises/ui-framework/widgets/design-editor-commands/set-viewer-settings/"
---

# setViewerSettings

> Defines the canvas zoom.

## Params

- `zoom` - a zoom value.
- `zoomMode` - defines how the product will fit the canvas, one of `"none"`, `"bestFit"`, `"bestFitShrinkOnly"`, `"fitToWidth"`, `"fitToHeight"`, `"zoomControl"`, `"fitToWidthShrinkOnly"`, or `"fitToHeightShrinkOnly"`.
- `scrollPosition` - the X and Y coordinates of the visible area.

For the complete list of parameters, you can refer to [IDesignEditorDefinitionSetViewerSettings](https://customerscanvas.com/docs/on-premises/ui-framework/widgets/reference/au-widget-design-editor.IAuWidgetDesignEditor.md#idesigneditordefinitionsetviewersettings).

## Example

```json
{
  "type": "design-editor",
  "name": "editor",
  "params": {
    "initial": { ... },
    "setViewerSettings": {
      "zoom": 0.1,
      "zoomMode": 'bestFit',
      "scrollPosition": {x: 0, y: 0}
    }
  }
}
```
