We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6a06973 commit 5ace334Copy full SHA for 5ace334
docs/concepts/controls.md
@@ -8,13 +8,19 @@ Controls are user interface elements that you can add to your map:
8
9
> See [Controls API](../../api/controls/)
10
11
+```python {marimo}
12
+import micropip
13
+await micropip.install("openlayers")
14
+```
15
+
16
```python {marimo display_code=True}
17
import openlayers as ol
-from openlayers.basemaps import CartoBasemapLayer
18
19
m = ol.MapWidget(
- layers=[CartoBasemapLayer()],
- controls=[ol.OverviewMapControl(collapsed=False)]
20
+ controls=[
21
+ ol.ZoomToExtentControl(),
22
+ ol.ScaleLineControl()
23
+ ]
24
)
25
m
26
```
0 commit comments