annotation
Events
add
- Description:
Triggered when or more multiple annotations have been added.
- Source:
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
annotation |
geo.annotation |
<optional> |
The annotation that was added. |
annotations |
geo.annotation |
<optional> |
The annotations that were added. |
Type:
add_before
- Description:
Triggered when one or multiple annotations are about to be added.
- Source:
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
annotation |
geo.annotation |
<optional> |
The annotation that will be added. |
annotations |
Array.<geo.annotation> |
<optional> |
The annotations that will be added. |
Type:
boolean
- Description:
Triggered when an annotation can be combined via a boolean operation (union, intersect, difference, xor).
- Source:
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
annotation |
geo.annotation | The annotation that is being operated on. |
|
operation |
string | The operation being performed. |
|
cancel |
boolean |
<optional> |
If the handle sets this to false, don't apply the operation to the annotation layer. |
Type:
coordinates
- Description:
Triggered when an annotation's coordinates have been updated.
- Source:
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that was altered. |
Type:
cursor_action
- Description:
Triggered when an annotation is in cursor mode and an action occurs.
- Source:
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
annotation |
geo.annotation | The annotation that is being operated on. |
|
operation |
string | The operation being performed. |
|
cancel |
boolean |
<optional> |
If the handle sets this to false, don't apply the operation to the annotation layer. |
event |
object | The triggering event. |
Type:
cursor_click
- Description:
Triggered when an annotation is in cursor mode and the mouse is clicked.
- Source:
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
annotation |
geo.annotation | The annotation that is being operated on. |
|
operation |
string | The operation being performed. |
|
cancel |
boolean |
<optional> |
If the handle sets this to false, don't apply the operation to the annotation layer. |
event |
object | The triggering event. |
Type:
edit_action
- Description:
Triggered when an action is performed on an annotation's edit handle.
- Source:
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that has an edit handle selected or unselected. |
handle |
object | Information on the edit handle. |
action |
boolean | The edit action, typically one of
|
Type:
mode
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
mode |
string |
<nullable> |
The new annotation mode. This is one of the values
from |
oldMode |
string |
<nullable> |
The annotation mode before this change. This is
one of the values from |
oldState |
string |
<nullable> |
If there was an active annotation before the
mode change, this is the annotation state before the change. This is
one of the values from |
oldCoordinates |
string |
<nullable> |
If there was an active annotation before the mode change, these are the annotation's coordinates before the change. This will be an empty list if an annotation in create state had not been started and a non-empty list if it is partially created. |
reason |
string |
<nullable> |
An optional string that was passed to the mode change method. |
Type:
remove
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that was removed. |
Type:
select_edit_handle
- Description:
Triggered when an annotation's edit handle is selected or released.
- Source:
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that has an edit handle selected or unselected. |
handle |
object | Information on the edit handle. |
enable |
boolean | Truthy if the handle was enabled, falsy if disabled. |
Type:
state
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that changed. |
Type:
update
- Description:
Triggered when an annotation has been altered. This is currently only triggered when updating existing annotations via the geojson function.
- Source:
Properties:
Name | Type | Description |
---|---|---|
annotation |
geo.annotation | The annotation that was altered. |