Creates a bubble markup on a Bubble that is a photo.
Markups are user generated overlay elements that is displayed on top of a Bubble (attached to a Task). These can be
drawings, cloud, text, measurements, arrows.
The data
field of a Markup follows the GeoJson format.
Schema looks like:
{
"type": "Feature",
"properties": {
"style": "See below: property.style",
"color": "#FF0000",
"opacity": 1,
"width": 16
},
"geometry": {
"type": "See below: geometry.type",
"coordinates": [
[
136,
95
],
[
277,
17
]
]
}
}
Properties.style can be one of these: "arrow", "drawing", "measurement", "text"
Geometry.type is one of these: "Polygon","LineString"
Here is an example of an Arrow
:
{
"type": "Feature",
"properties": {
"style": "arrow",
"color": "#FF0000",
"opacity": 1,
"width": 16
},
"geometry": {
"type": "LineString",
"coordinates": [
[
136,
95
],
[
277,
17
]
]
}
}
Here is an example of a Drawing
:
{
"type": "Feature",
"properties": {
"style": "drawing",
"color": "#0000FF",
"opacity": 1,
"width": 16
},
"geometry": {
"type": "LineString",
"coordinates": [
[
639,
406
],
[
639,
392
]
]
}
}
Here is an example of a Measurement
:
{
"type": "Feature",
"properties": {
"style": "measurement",
"color": "#FF7F00",
"opacity": 1,
"width": 16,
"description": "1 centimeter",
"fontSize": 48
},
"geometry": {
"type": "LineString",
"coordinates": [
[
217,
620
],
[
359,
622
]
]
}
}
Here is an example of a Text
:
{
"type": "Feature",
"properties": {
"style": "text",
"color": "#FF0000",
"description": "Sample",
"fontSize": 48
},
"geometry": {
"type": "Polygon",
"coordinates": [
[
760,
144
],
[
936,
144
],
[
936,
239
],
[
760,
239
]
]
}
}
One way to see how Fieldwire is constructing these Bubble Markup data
is to examine the XHR tab of a browser developer
console and when you use the Bubble Markup tools, see what the body it is being POSTed to Fieldwire.