Skip to content
This repository was archived by the owner on Sep 20, 2019. It is now read-only.

Commit 2e991d7

Browse files
committed
feat(examples): Added a new and simplified paths example
1 parent 0663b30 commit 2e991d7

File tree

3 files changed

+8
-18
lines changed

3 files changed

+8
-18
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ See some basic examples:
2121
* [Single marker example](http://tombatossals.github.io/angular-leaflet-directive/examples/marker-example.html)
2222
* [Google Maps example](http://tombatossals.github.io/angular-leaflet-directive/examples/googlemaps-example.html)
2323
* [Paths Simple example](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-simple-example.html)
24+
* [Paths Types example](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-types-example.html)
2425
* [Paths example](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-example.html)
2526
* [Marker addition example](http://tombatossals.github.io/angular-leaflet-directive/examples/marker-add-example.html)
2627
* [Marker with label example](http://tombatossals.github.io/angular-leaflet-directive/examples/marker-label-example.html)

doc/paths-attribute.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ We can define these types of paths:
3434

3535
Examples
3636
--------
37-
These two demos show the use of this functionality:
37+
These three demos show the use of this functionality:
3838
* [http://tombatossals.github.io/angular-leaflet-directive/examples/paths-simple-example.html](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-simple-example.html)
39+
* [http://tombatossals.github.io/angular-leaflet-directive/examples/paths-types-example.html](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-types-example.html)
3940
* [http://tombatossals.github.io/angular-leaflet-directive/examples/paths-example.html](http://tombatossals.github.io/angular-leaflet-directive/examples/paths-example.html)

examples/paths-simple-example.html

Lines changed: 5 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
london: {
1313
lat: 51.505,
1414
lng: -0.09,
15-
zoom: 5
15+
zoom: 4
1616
},
17-
paths : {
17+
europeanPaths: {
1818
p1: {
19-
color: '#000',
19+
color: 'red',
2020
weight: 8,
2121
latlngs: [
2222
{ lat: 51.50, lng: -0.082 },
@@ -25,19 +25,7 @@
2525
],
2626
}
2727
}
28-
})
29-
30-
$scope.myPath = {
31-
p1: {
32-
color: '#0ff',
33-
weight: 8,
34-
latlngs: [
35-
{ lat: 48.83, lng: 2.37 },
36-
{ lat: 41.91, lng: 12.48 }
37-
],
38-
}
39-
}
40-
28+
});
4129
}]);
4230
</script>
4331
<style>
@@ -48,6 +36,6 @@
4836
</style>
4937
</head>
5038
<body ng-controller="DemoController">
51-
<leaflet center="london" paths="myPath"></leaflet>
39+
<leaflet center="london" paths="europeanPaths"></leaflet>
5240
</body>
5341
</html>

0 commit comments

Comments
 (0)