You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/plugins/interact.md
+15-8Lines changed: 15 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -71,7 +71,7 @@ Array of map layer configurations that are selectable. Each entry specifies whic
71
71
72
72
```js
73
73
layers: [
74
-
{ layerId:'my-polygons', idProperty:'id' },
74
+
{ layerId:'my-polygons', idProperty:'guid' },
75
75
{ layerId:'my-lines' }
76
76
]
77
77
```
@@ -90,11 +90,11 @@ layers: [
90
90
91
91
What to use as `layerId` depends on how your data is added to the map — these are the layers the plugin will enable for feature selection:
92
92
93
-
-**MapLibre directly** — use the layer IDs defined in your style or added via `map.addLayer()`
93
+
-**Map provider directly** — use the layer IDs defined in your style or added via your map provider's layer API
94
94
-**Datasets plugin** — use the dataset ID, or the sublayer ID for datasets with sublayers
95
-
-**Draw plugin** — uses generated layer IDs such as `fill-inactive.cold` and `stroke-inactive.cold`
95
+
-**Draw plugin** — uses generated layer IDs; inspect the map at runtime to find them (e.g. `fill-inactive.cold`, `stroke-inactive.cold` when using MapLibre)
96
96
97
-
If you're unsure of the layer IDs available at runtime, set `debug: true` in the map config — this lets you query the map and inspect layer names in the browser console.
97
+
If you're unsure of the layer IDs available at runtime, set `debug: true` in the interact plugin options — this lets you query the map and inspect layer names in the browser console.
98
98
99
99
---
100
100
@@ -118,7 +118,7 @@ When `true`, only features that touch or overlap the existing selection can be a
118
118
**Type:**`boolean`
119
119
**Default:**`false`
120
120
121
-
When `true`, clicking outside any selectable layer clears the current selection.
121
+
When `true`, clicking outside any selectable feature clears the current selection.
122
122
123
123
---
124
124
@@ -265,12 +265,15 @@ Emitted when the user confirms their selection (clicks "Done").
0 commit comments