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: articles/azure-maps/map-add-custom-html.md
+6
Original file line number
Diff line number
Diff line change
@@ -25,6 +25,7 @@ This article shows you how to add a custom HTML such as an image file to the map
25
25
26
26
The HtmlMarker class has a default style. You can customize the marker by setting the color and text options of the marker. The default style of the HtmlMarker class is an SVG template that has a color and text placeholder. Set the color and text properties in the HtmlMarker options for a quick customization.
27
27
28
+
<br/>
28
29
29
30
<iframeheight='500'scrolling='no'title='Add an HTML Marker to a map'src='//codepen.io/azuremaps/embed/MVoeVw/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/MVoeVw/'>Add an HTML Marker to a map</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
30
31
</iframe>
@@ -37,6 +38,7 @@ The second block of code adds a [HtmlMarker](https://docs.microsoft.com/javascri
37
38
38
39
The default `htmlContent` of an Html marker is an SVG template with place folders `{color}` and `{text}` in it. You can create custom SVG strings and add these same placeholders into your SVG such that setting the `color` and `text` options of the marker update these placeholders in your SVG.
39
40
41
+
<br/>
40
42
41
43
<iframeheight='500'scrolling='no'title='HTML Marker with Custom SVG Template'src='//codepen.io/azuremaps/embed/LXqMWx/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/LXqMWx/'>HTML Marker with Custom SVG Template</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
42
44
</iframe>
@@ -45,6 +47,7 @@ The default `htmlContent` of an Html marker is an SVG template with place folder
45
47
46
48
One of the benefits of HTML markers is that there are many great customizations that can be achieved using CSS. In this sample, the content of the HtmlMarker consists of HTML and CSS that create an animated pin that drops into place and pulses.
47
49
50
+
<br/>
48
51
49
52
<iframeheight='500'scrolling='no'title='HTML DataSource'src='//codepen.io/azuremaps/embed/qJVgMx/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/qJVgMx/'>HTML DataSource</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
50
53
</iframe>
@@ -53,6 +56,7 @@ One of the benefits of HTML markers is that there are many great customizations
53
56
54
57
This sample shows how to make an HTML marker draggable. HTML markers support `drag`, `dragstart` and `dragend` events.
55
58
59
+
<br/>
56
60
57
61
<iframeheight='500'scrolling='no'title='Draggable HTML Marker'src='//codepen.io/azuremaps/embed/wQZoEV/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/wQZoEV/'>Draggable HTML Marker</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
58
62
</iframe>
@@ -63,12 +67,14 @@ These samples show how to add mouse events to an HTML marker by adding standard
63
67
64
68
If the `htmlContent` of the marker is a DOM element (div, img...), you can add events directly to them.
65
69
70
+
<br/>
66
71
67
72
<iframeheight='500'scrolling='no'title='Adding Mouse Events to HTML Markers'src='//codepen.io/azuremaps/embed/RqOKRz/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/RqOKRz/'>Adding Mouse Events to HTML Markers</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
68
73
</iframe>
69
74
70
75
If the `htmlContent` is a string (i.e the like the default), you can create a DOM element and add the string as innerHTML to it, then add the DOM element as the htmlContent. If the `htmlContent` is a templated string, you will need to find/replace `{text}` and `{color}` values in the string first.
71
76
77
+
<br/>
72
78
73
79
<iframeheight='500'scrolling='no'title='Adding Mouse Events to default HTML Marker'src='//codepen.io/azuremaps/embed/ZmZLBa/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/ZmZLBa/'>Adding Mouse Events to default HTML Marker</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-heat-map-layer.md
+2
Original file line number
Diff line number
Diff line change
@@ -26,6 +26,7 @@ Heat maps, also known as point density maps, are a type of data visualization us
26
26
27
27
To render a data source of points as a heat map simple pass your data source into an instance of the HeatMapLayer class and add it to the map as shown here.
28
28
29
+
<br/>
29
30
30
31
<iframeheight='500'scrolling='no'title='Simple Heat Map Layer'src='//codepen.io/azuremaps/embed/gQqdQB/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/gQqdQB/'>Simple Heat Map Layer</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
31
32
</iframe>
@@ -50,6 +51,7 @@ The previous example customized the heat map by setting the radius and opacity o
50
51
51
52
Here is a tool to test out the different heat map layer options.
52
53
54
+
<br/>
53
55
54
56
<iframeheight='700'scrolling='no'title='Heat Map Layer Options'src='//codepen.io/azuremaps/embed/WYPaXr/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/WYPaXr/'>Heat Map Layer Options</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-image-layer.md
+3
Original file line number
Diff line number
Diff line change
@@ -28,6 +28,7 @@ This article shows you how you can overlay an image to fixed set of coordinates
28
28
29
29
This sample shows how to overlay an image of a [map of Newark New Jersey from 1922]((https://www.lib.utexas.edu/maps/historical/newark_nj_1922.jpg)) on the map.
30
30
31
+
<br/>
31
32
32
33
<iframeheight='500'scrolling='no'title='Simple Image Layer'src='//codepen.io/azuremaps/embed/eQodRo/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/eQodRo/'>Simple Image Layer</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
33
34
</iframe>
@@ -40,6 +41,7 @@ In the second block of code, an [ImageLayer](https://docs.microsoft.com/javascri
40
41
41
42
This sample shows how to overlay KML Ground Overlay information as an image layer on the map. KML ground overlays provide north, south, east, and west coordinates and a counter-clockwise rotation, where as the image layer expects coordinates for each corner of the image. The KML ground overlay in this sample is of the Chartres cathedral and sourced from [Wikimedia](https://commons.wikimedia.org/wiki/File:Chartres.svg/overlay.kml).
42
43
44
+
<br/>
43
45
44
46
<iframeheight='500'scrolling='no'title='KML Ground Overlay as Image Layer'src='//codepen.io/azuremaps/embed/EOJgpj/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/EOJgpj/'>KML Ground Overlay as Image Layer</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
45
47
</iframe>
@@ -51,6 +53,7 @@ The above code uses the static `getCoordinatesFromEdges` function of the [ImageL
51
53
52
54
The Image layer has many styling options. Here is a tool to try them out.
53
55
56
+
<br/>
54
57
55
58
<iframeheight='700'scrolling='no'title='Image Layer Options'src='//codepen.io/azuremaps/embed/RqOGzx/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/RqOGzx/'>Image Layer Options</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-pin.md
+3-1
Original file line number
Diff line number
Diff line change
@@ -33,8 +33,9 @@ A [symbol layer](https://docs.microsoft.com/javascript/api/azure-maps-control/at
33
33
34
34
## Add a custom icon to a symbol layer
35
35
36
-
Symbol layers are rendered using WebGL. As such all resources, such as icon images, must be loaded into the WebGL context. This sample shows how to add a custom symbol icon to the map resources and then use it to render point data with a custom symbol on the map.
36
+
Symbol layers are rendered using WebGL. As such all resources, such as icon images, must be loaded into the WebGL context. This sample shows how to add a custom symbol icon to the map resources and then use it to render point data with a custom symbol on the map. The `textField` property of the symbol layer requires an expression to be specified. In this case we want to render the temperature property of the point feature as the text value. This can be achieved with this expression: `['get', 'temperature']`.
37
37
38
+
<br/>
38
39
39
40
<iframeheight='500'scrolling='no'title='Custom Symbol Image Icon'src='//codepen.io/azuremaps/embed/WYWRWZ/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/WYWRWZ/'>Custom Symbol Image Icon</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
40
41
</iframe>
@@ -43,6 +44,7 @@ Symbol layers are rendered using WebGL. As such all resources, such as icon imag
43
44
44
45
The symbol layer has many styling options available. Here is a tool to test out these various styling options.
45
46
47
+
<br/>
46
48
47
49
<iframeheight='700'scrolling='no'title='Symbol Layer Options'src='//codepen.io/azuremaps/embed/PxVXje/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/PxVXje/'>Symbol Layer Options</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-popup.md
+1
Original file line number
Diff line number
Diff line change
@@ -36,6 +36,7 @@ The last block of code creates a function that is triggered by the `mouseover` e
36
36
37
37
When you have a lot of points and only want to show one popup at a time, the best approach is to create one popup and reuse it rather than creating a popup for each point feature. By doing this, the number of DOM elements created by the application is greatly reduced which can provide better performance. This sample creates 3 point features. If you click on any of them, a popup will be displayed with the content for that point feature.
38
38
39
+
<br/>
39
40
40
41
<iframeheight='500'scrolling='no'title='Reusing Popup with Multiple Pins'src='//codepen.io/azuremaps/embed/rQbjvK/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/rQbjvK/'>Reusing Popup with Multiple Pins</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-shape.md
+3-1
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,7 @@ A [LineLayer](https://docs.microsoft.com/javascript/api/azure-maps-control/atlas
32
32
33
33
The Line layer several styling options. Here is a tool to try them out.
34
34
35
+
<br/>
35
36
36
37
<iframeheight='700'scrolling='no'title='Line Layer Options'src='//codepen.io/azuremaps/embed/GwLrgb/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/GwLrgb/'>Line Layer Options</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
37
38
</iframe>
@@ -83,6 +84,7 @@ The last block of code adds the polygon and line layers to the map. The data sou
83
84
84
85
The Polygon layer only has a few styling options. Here is a tool to try them out.
85
86
87
+
<br/>
86
88
87
89
<iframeheight='700'scrolling='no'title='LXvxpg'src='//codepen.io/azuremaps/embed/LXvxpg/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/LXvxpg/'>LXvxpg</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
88
90
</iframe>
@@ -92,7 +94,7 @@ The Polygon layer only has a few styling options. Here is a tool to try them out
92
94
A Shape class wraps a [Geometry](https://docs.microsoft.com/javascript/api/azure-maps-control/atlas.data.geometry?view=azure-iot-typescript-latest) or [Feature](https://docs.microsoft.com/javascript/api/azure-maps-control/atlas.data.feature?view=azure-iot-typescript-latest) and makes it easy to update and maintain them.
93
95
`new Shape(data: Feature<data.Geometry, any>)` constructs a shape object and initializes it with the specified feature.
94
96
95
-
<br>
97
+
<br/>
96
98
97
99
<iframeheight='500'scrolling='no'title='Update shape properties'src='//codepen.io/azuremaps/embed/ZqMeQY/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/ZqMeQY/'>Update shape properties</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
Copy file name to clipboardexpand all lines: articles/azure-maps/map-add-tile-layer.md
+2
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,7 @@ The tile URL passed into a Tile layer must be an http/https URL to a TileJSON re
37
37
38
38
This sample shows how to create a tile layer that points to a set of tiles that use the x, y, zoom tiling system. The source of this tile layer is a weather radar overlay from the [Iowa Environmental Mesonet of Iowa State University](http://mesonet.agron.iastate.edu/ogc/).
39
39
40
+
<br/>
40
41
41
42
<iframeheight='500'scrolling='no'title='Tile Layer using X, Y, and Z'src='//codepen.io/azuremaps/embed/BGEQjG/?height=500&theme-id=0&default-tab=js,result&embed-version=2&editable=true'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/BGEQjG/'>Tile Layer using X, Y, and Z</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
42
43
</iframe>
@@ -49,6 +50,7 @@ In the second block of code, an [TileLayer](https://docs.microsoft.com/javascrip
49
50
50
51
The Tile layer only has a many styling options. Here is a tool to try them out.
51
52
53
+
<br/>
52
54
53
55
<iframeheight='700'scrolling='no'title='Tile Layer Options'src='//codepen.io/azuremaps/embed/xQeRWX/?height=700&theme-id=0&default-tab=result'frameborder='no'allowtransparency='true'allowfullscreen='true'style='width: 100%;'>See the Pen <a href='https://codepen.io/azuremaps/pen/xQeRWX/'>Tile Layer Options</a> by Azure Maps (<a href='https://codepen.io/azuremaps'>@azuremaps</a>) on <a href='https://codepen.io'>CodePen</a>.
0 commit comments