Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/api-reference/map/map.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,4 +128,10 @@ Mapbox provides a `setStyle` method which works, but we recommend using ours ins
map.setStyle(style: string) => void
```

- `style` is a mapbox style url like "mapbox://styles/mapbox/satellite-streets-v12"
- `style` is a mapbox style url like "mapbox://styles/mapbox/satellite-streets-v12"

and you can use the below to revert to the default Smplrspace style:

```ts
map.setDefaultStyle() => void
```
10 changes: 7 additions & 3 deletions docs/api-reference/space/custom-ux.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,17 @@ space.startViewer({

### Update render options dynamically

Render options are described in details in [Render options](#render-options). They can be set when the viewer starts, but if you need to update them dynamically, you should use the method below:
Render options are described in details in [Render options](#render-options). They can be set when the viewer starts, but if you need to update them dynamically, you should use the methods below:

```ts
space.updateRenderOptions(options: SpaceRenderOptions) => void
space.resetRenderOptionsToDefault() => void
space.resetRenderOptionsToInitial() => void
```

- `options` is an object of the [`SpaceRenderOptions`](#render-options) interface, which is deeply merged with the current options used by the viewer. To "unset" an optional value, you can pass `undefined` explicitely.
- `updateRenderOptions` is used to update specific values, while keeping the others unchanged.
- `options` is an object of the [`SpaceRenderOptions`](#render-options) interface, which is deeply merged with the current options used by the viewer. To "unset" an optional value, you can pass `undefined` explicitely.
- `resetRenderOptionsToDefault` reverts all values to the Smplrspace defaults.
- `resetRenderOptionsToInitial` reverts all values to the ones applied when calling `startViewer`.

### Switch between 2D and 3D

Expand Down