Skip to content

Commit 2e8cb60

Browse files
authored
Merge pull request #103 from smplrspace/next
v2.41.0
2 parents 31aa742 + 6f69b89 commit 2e8cb60

File tree

3 files changed

+22
-2
lines changed

3 files changed

+22
-2
lines changed

docs/api-reference/space/custom-ux.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ space.startViewer({
121121
hideNavigationButtons?: boolean
122122
hideLevelPicker?: boolean
123123
hideControls?: boolean
124+
smallControls?: boolean
125+
darkControls?: boolean
124126
controlsPosition?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right' | 'center-left' | 'center-right'
125127
legendPosition?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right'
126128
}) => void
@@ -135,11 +137,25 @@ space.startViewer({
135137
- `disableCameraRotation` - _optional_ - set this to true to force a top view of the scene. It essentially gets the interactivity to match the 2D mode, but in 3D mode. _Default value: false_
136138
- `autoRotate` - _optional_ - set this to true to have the viewer spin around the space automatically. You can also start, set the rotation speed, and stop the rotation as described [below](#auto-rotate-the-viewer). _Default value: false_
137139
- `hideNavigationButtons` - _optional_ - set this to true if you want the user to control the camera but want to remove the navigation buttons. Mouse, touch and keyboard inputs will work while the buttons are hidden. _Default value: false_
138-
- `hideLevelPicker` - _optional_ - set this to true if you want to remove the level picker from the viewer. Levels can still be controlled programmatically, so you could use your own buttons or logic. _Default value: false_
139-
- `hideControls` - _optional_ - set this to true if you want to remove *all* control buttons from the viewer. _Default value: false_
140+
- `hideLevelPicker` - _optional_ - set this to true to remove the level picker from the viewer. Levels can still be controlled programmatically, so you could use your own buttons or logic. _Default value: false_
141+
- `hideControls` - _optional_ - set this to true to remove *all* control buttons from the viewer. _Default value: false_
142+
- `smallControls` - _optional_ - set this to true to reduce the size of the control buttons from 32px to 24px. This is useful for smaller viewers. _Default value: false_
143+
- `darkControls` - _optional_ - set this to true to change the control buttons to their dark style. This is useful when you set a dark background color`. _Default value: false_
140144
- `controlsPosition` - _optional_ - lets you choose where the control buttons are rendered. _Default value: 'bottom-left'_
141145
- `legendPosition` - _optional_ - lets you choose where the legend (if any is configured in the data layers) is rendered. _Default value: 'top-left'_
142146

147+
### CSS overrides
148+
149+
For greater alignment of the viewer to your product experience, you can also apply custom CSS styles to our components.
150+
151+
The usual candidates here are the control buttons. The viewer options already let you position them with `controlsPosition`, hide them with `hideControls`, `hideNavigationButtons`, or `hideLevelPicker`, makes them smaller with `smallControls`, make them darker with `darkControls`. We have also applied CSS class names at each level of the controls so you have an easy way to target them for further customization. Try selecting the following classes to apply your styles:
152+
153+
- `smplr_control_button_container`
154+
- `smplr_control_button_divider`
155+
- `smplr_control_button`
156+
157+
🚫 Please note that attempting to modify the "Powered by Smplrspace" element is against the Terms of use, and could result in account termination. You can [get in touch with us](mailto:hello@smplrspace.com) to enquire about white label options.
158+
143159
## Viewer controls
144160

145161
### Update render options dynamically

docs/api-reference/space/data-layers.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ As detailed above, the `tooltipTemplate` option is powered by [Handlebars](https
7575
- `fallback` - lets you use fallback default values as `{{fallback [my field] 'default value'}}`. We use `'-'` as a default value for all fields.
7676
- `formatDate` - lets you format dates using [Moment.js](https://momentjs.com/docs/#/displaying/format/) as `{{formatDate [my field] 'DMMMYY'}}`.
7777
- `formatNumber` - lets you format numbers using [Numeral.js](https://numeraljs.com/#format) as `{{formatNumber [my field] '0,0.00'}}`.
78+
- `ifEquals` - lets you compare 2 values in an if statement. For example to show some text only when a field equals a certain value: `{{#ifEquals [status] "active"}}Status is active{{else}} Status is not active{{/ifEquals}}`.
7879
7980
## Types of layers
8081

docs/guides/sid.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ rpt_ report
3131
rpg_ report page
3232
ds_ data source
3333
eqmt_ equipment
34+
wlk_ walkthrough
35+
pic_ picture
36+
pano_ panorama (360° picture)
3437
```
3538

3639
That's it, pretty short list ;). More will come soon.

0 commit comments

Comments
 (0)