Leon4gr45 commited on
Commit
7fa19e5
·
verified ·
1 Parent(s): 1d590c7

Include updated package-lock.json (part 24)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +3 -0
  2. node_modules/leaflet.markercluster/.travis.yml +25 -0
  3. node_modules/leaflet.markercluster/CHANGELOG.md +268 -0
  4. node_modules/leaflet.markercluster/CONTRIBUTING.md +70 -0
  5. node_modules/leaflet.markercluster/ISSUE_TEMPLATE.md +23 -0
  6. node_modules/leaflet.markercluster/Jakefile.js +93 -0
  7. node_modules/leaflet.markercluster/MIT-LICENCE.txt +20 -0
  8. node_modules/leaflet.markercluster/README.md +319 -0
  9. node_modules/leaflet.markercluster/bower.json +27 -0
  10. node_modules/leaflet.markercluster/build/hintrc.js +37 -0
  11. node_modules/leaflet.markercluster/build/rollup-config.js +43 -0
  12. node_modules/leaflet.markercluster/example/geojson-sample.js +53 -0
  13. node_modules/leaflet.markercluster/example/geojson.html +54 -0
  14. node_modules/leaflet.markercluster/example/map.png +0 -0
  15. node_modules/leaflet.markercluster/example/marker-clustering-convexhull.html +81 -0
  16. node_modules/leaflet.markercluster/example/marker-clustering-custom.html +114 -0
  17. node_modules/leaflet.markercluster/example/marker-clustering-dragging.html +83 -0
  18. node_modules/leaflet.markercluster/example/marker-clustering-everything.html +80 -0
  19. node_modules/leaflet.markercluster/example/marker-clustering-geojson.html +70 -0
  20. node_modules/leaflet.markercluster/example/marker-clustering-pane.html +104 -0
  21. node_modules/leaflet.markercluster/example/marker-clustering-realworld-maxzoom.388.html +45 -0
  22. node_modules/leaflet.markercluster/example/marker-clustering-realworld-mobile.388.html +44 -0
  23. node_modules/leaflet.markercluster/example/marker-clustering-realworld.10000.html +46 -0
  24. node_modules/leaflet.markercluster/example/marker-clustering-realworld.388.html +45 -0
  25. node_modules/leaflet.markercluster/example/marker-clustering-realworld.50000.html +78 -0
  26. node_modules/leaflet.markercluster/example/marker-clustering-singlemarkermode.html +60 -0
  27. node_modules/leaflet.markercluster/example/marker-clustering-spiderfier.html +60 -0
  28. node_modules/leaflet.markercluster/example/marker-clustering-zoomtobounds.html +60 -0
  29. node_modules/leaflet.markercluster/example/marker-clustering-zoomtoshowlayer.html +59 -0
  30. node_modules/leaflet.markercluster/example/marker-clustering.html +88 -0
  31. node_modules/leaflet.markercluster/example/mobile.css +6 -0
  32. node_modules/leaflet.markercluster/example/old-bugs/add-1000-after.html +83 -0
  33. node_modules/leaflet.markercluster/example/old-bugs/add-markers-offscreen.html +52 -0
  34. node_modules/leaflet.markercluster/example/old-bugs/add-remove-before-addtomap.html +62 -0
  35. node_modules/leaflet.markercluster/example/old-bugs/animationless-zoom.html +47 -0
  36. node_modules/leaflet.markercluster/example/old-bugs/click-cluster-at-screen-edge.html +59 -0
  37. node_modules/leaflet.markercluster/example/old-bugs/disappearing-marker-from-spider.html +106 -0
  38. node_modules/leaflet.markercluster/example/old-bugs/doesnt-update-cluster-on-bottom-level.html +69 -0
  39. node_modules/leaflet.markercluster/example/old-bugs/drag-with-spiderfying.html +75 -0
  40. node_modules/leaflet.markercluster/example/old-bugs/remove-add-clustering.html +74 -0
  41. node_modules/leaflet.markercluster/example/old-bugs/remove-when-spiderfied.html +65 -0
  42. node_modules/leaflet.markercluster/example/old-bugs/removelayer-after-remove-from-map.html +69 -0
  43. node_modules/leaflet.markercluster/example/old-bugs/setView-doesnt-remove.html +69 -0
  44. node_modules/leaflet.markercluster/example/old-bugs/zoomtoshowlayer-doesnt-need-to-zoom.html +63 -0
  45. node_modules/leaflet.markercluster/example/old-bugs/zoomtoshowlayer-doesnt-zoom-if-centered-on.html +56 -0
  46. node_modules/leaflet.markercluster/example/realworld.10000.js +0 -0
  47. node_modules/leaflet.markercluster/example/realworld.388.js +393 -0
  48. node_modules/leaflet.markercluster/example/realworld.50000.1.js +0 -0
  49. node_modules/leaflet.markercluster/example/realworld.50000.2.js +0 -0
  50. node_modules/leaflet.markercluster/example/remove-geoJSON-when-spiderfied.html +83 -0
.gitattributes CHANGED
@@ -73,3 +73,6 @@ node_modules/gifwrap/test/fixtures/quantized/hairstreak32_Sorokin.png filter=lfs
73
  node_modules/gifwrap/test/fixtures/quantized/hairstreak32_Wu.png filter=lfs diff=lfs merge=lfs -text
74
  node_modules/gifwrap/test/fixtures/quantized/sculptmap256_Sorokin_FloydSteinberg.png filter=lfs diff=lfs merge=lfs -text
75
  node_modules/gifwrap/test/fixtures/rnaples-offsets-public.gif filter=lfs diff=lfs merge=lfs -text
 
 
 
 
73
  node_modules/gifwrap/test/fixtures/quantized/hairstreak32_Wu.png filter=lfs diff=lfs merge=lfs -text
74
  node_modules/gifwrap/test/fixtures/quantized/sculptmap256_Sorokin_FloydSteinberg.png filter=lfs diff=lfs merge=lfs -text
75
  node_modules/gifwrap/test/fixtures/rnaples-offsets-public.gif filter=lfs diff=lfs merge=lfs -text
76
+ node_modules/leaflet.markercluster/example/map.png filter=lfs diff=lfs merge=lfs -text
77
+ node_modules/lightningcss-linux-x64-gnu/lightningcss.linux-x64-gnu.node filter=lfs diff=lfs merge=lfs -text
78
+ node_modules/lightningcss-linux-x64-musl/lightningcss.linux-x64-musl.node filter=lfs diff=lfs merge=lfs -text
node_modules/leaflet.markercluster/.travis.yml ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ sudo: false
2
+ language: node_js
3
+ node_js:
4
+ - 8
5
+ cache:
6
+ directories:
7
+ - "travis_phantomjs"
8
+ - "$HOME/.npm"
9
+
10
+ before_install:
11
+ - "export PHANTOMJS_VERSION=2.1.1"
12
+ - "hash -r"
13
+ - "phantomjs --version"
14
+ - "export PATH=$PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64/bin:$PATH"
15
+ - "hash -r"
16
+ - "phantomjs --version"
17
+ - "if [ $(phantomjs --version) != \"$PHANTOMJS_VERSION\" ]; then rm -rf $PWD/travis_phantomjs; mkdir -p $PWD/travis_phantomjs; fi"
18
+ - "hash -r"
19
+ - "if [ $(phantomjs --version) != \"$PHANTOMJS_VERSION\" ]; then wget https://github.com/Medium/phantomjs/releases/download/v$PHANTOMJS_VERSION/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -O $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2; fi"
20
+ - "if [ $(phantomjs --version) != \"$PHANTOMJS_VERSION\" ]; then tar -xvf $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -C $PWD/travis_phantomjs; fi"
21
+ - "hash -r"
22
+ - "phantomjs --version"
23
+
24
+ install:
25
+ - npm ci
node_modules/leaflet.markercluster/CHANGELOG.md ADDED
@@ -0,0 +1,268 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Leaflet.markercluster
2
+
3
+ (part of repo mgmt responsibilities transferred to [@ykzeng](https://github.com/ykzeng))
4
+
5
+ ## 1.5.3 (2021-10-18)
6
+
7
+ ### Bugfixes
8
+
9
+ - Removing unnecessary files on npm package
10
+ - Inlucding correct versioning on Github repo
11
+
12
+ ## 1.5.2 (2021-10-18)
13
+
14
+ ### Improvements
15
+
16
+ - Merged PR [1022](https://github.com/Leaflet/Leaflet.markercluster/pull/1022) for Spiderfy on every room by [MasterEric](https://github.com/MasterEric)
17
+
18
+ ### Bugfixes
19
+
20
+ - Fixed issue [907](https://github.com/Leaflet/Leaflet.markercluster/issues/907) and [967](https://github.com/Leaflet/Leaflet.markercluster/issues/967) with PR [1027](https://github.com/Leaflet/Leaflet.markercluster/pull/1027) from [DerGuteWolf](https://github.com/DerGuteWolf)
21
+ - Removed unexpected dependencies in previous npm package
22
+
23
+ ## 1.5.1 (2021-08-28)
24
+
25
+ ### Improvements
26
+
27
+ - Spiderfy on keypress [1005](https://github.com/Leaflet/Leaflet.markercluster/pull/1005) by [@neorth](https://github.com/neorth), a fix for issue [940](https://github.com/Leaflet/Leaflet.markercluster/issues/940) and [947](https://github.com/Leaflet/Leaflet.markercluster/issues/947)
28
+
29
+ ## 1.5.0 (2021-03-12)
30
+
31
+ ### Bugfixes
32
+
33
+ - Updated peer dependency to match latest leaflet version (by [@sanjpareek](https://github.com/sanjpareek)) [#976](https://github.com/Leaflet/Leaflet.markercluster/pull/976)
34
+
35
+ (all changes below without author notice were made by [@danzel](https://github.com/danzel))
36
+
37
+ ## 1.4.1 (2018-09-14)
38
+
39
+ ### Bugfixes
40
+
41
+ - Better support stopping dragged markers from being clustered (by [@DerGuteWolf](https://github.com/DerGuteWolf)) [#909](https://github.com/Leaflet/Leaflet.markercluster/pull/909)
42
+
43
+ ## 1.4.0 (2018-08-22)
44
+
45
+ Required leaflet version bumped to 1.3.1
46
+
47
+ ### Improvements
48
+
49
+ - Tests run against leaflet 1.1.0+ [#863](https://github.com/Leaflet/Leaflet.markercluster/issues/863)
50
+
51
+ ### Bugfixes
52
+
53
+ - Fix clearLayers not removing removed markers [#860](https://github.com/Leaflet/Leaflet.markercluster/issues/860)
54
+ - Remember opacity 0 correctly (by [@r-yanyo](https://github.com/r-yanyo)) [#890](https://github.com/Leaflet/Leaflet.markercluster/pull/890)
55
+ - Fix chunkedLoading LatLngBounds.intersects() (by [@boldtrn](https://github.com/boldtrn)) [#743](https://github.com/Leaflet/Leaflet.markercluster/issues/743) [#891](https://github.com/Leaflet/Leaflet.markercluster/pull/891)
56
+
57
+ ## 1.3.0 (2018-01-19)
58
+
59
+ ### Improvements
60
+
61
+ - Use Rollup for builds (by [@IvanSanchez](https://github.com/IvanSanchez)) [#769](https://github.com/Leaflet/Leaflet.markercluster/pull/769)
62
+
63
+ ### Bugfixes
64
+
65
+ - Fix Spiderfier positioning for small markers (by [@ghybs](https://github.com/ghybs)) [#846](https://github.com/Leaflet/Leaflet.markercluster/pull/846)
66
+ - Fix anchor usage with latest leaflet version [#861](https://github.com/Leaflet/Leaflet.markercluster/issues/861)
67
+
68
+ ## 1.2.0 (2017-11-06)
69
+
70
+ ### Improvements
71
+
72
+ - Move `clusterPane` option in to `options` field (by [@ghybs](https://github.com/ghybs)) [#832](https://github.com/Leaflet/Leaflet.markercluster/pull/832)
73
+
74
+ ### Bugfixes
75
+
76
+ - Fix very small `maxClusterRadius` hanging the browser (by [@lucaswerkmeister](https://github.com/lucaswerkmeister)) [#838](https://github.com/Leaflet/Leaflet.markercluster/pull/838)
77
+
78
+ ## 1.1.0 (2017-08-27)
79
+
80
+ ### Improvements
81
+
82
+ - Add `clusterPane` option to allow putting clusters in a different pane (by [@ckrahe](https://github.com/ckrahe)) [#819](https://github.com/Leaflet/Leaflet.markercluster/issues/819)
83
+
84
+ ## 1.0.6 (2017-06-19)
85
+
86
+ ### Bugfixes
87
+
88
+ - Fix some issues when used with non-integer zoom [#789](https://github.com/Leaflet/Leaflet.markercluster/issues/789)
89
+ - Change examples to use https (by [@ghybs](https://github.com/ghybs)) [#794](https://github.com/Leaflet/Leaflet.markercluster/pull/794)
90
+
91
+ ## 1.0.5 (2017-04-26)
92
+
93
+ ### Improvements
94
+
95
+ - Allow passing fitBounds options to zoomToBounds (by [@timkelty](https://github.com/timkelty)) [#779](https://github.com/Leaflet/Leaflet.markercluster/pull/779)
96
+
97
+ ### Bugfixes
98
+
99
+ - Fixed bug where disableClusteringAtZoom being 0 is treated the same as null (by [@MrCheeze](https://github.com/MrCheeze)) [#773](https://github.com/Leaflet/Leaflet.markercluster/pull/773)
100
+
101
+ ## 1.0.4 (2017-03-14)
102
+
103
+ ### Bugfixes
104
+
105
+ - Fix errors removing a MarkerClusterGroup from the map during an animation [#758](https://github.com/Leaflet/Leaflet.markercluster/issues/758)
106
+
107
+ ## 1.0.3 (2017-02-02)
108
+
109
+ ### Bugfixes
110
+
111
+ - Fix moving markers while the MarkerClusterGroup is not on the map [#753](https://github.com/Leaflet/Leaflet.markercluster/issues/753)
112
+
113
+ ## 1.0.2 (2017-01-27)
114
+
115
+ ### Improvements
116
+
117
+ - Support `layeradd` and `layerremove` events [#647](https://github.com/Leaflet/Leaflet.markercluster/issues/647)
118
+
119
+ ### Bugfixes
120
+
121
+ - Add support for maps with negative minZoom [#704](https://github.com/Leaflet/Leaflet.markercluster/issues/704)
122
+ - Fixed zoomToShowLayer() markers disappearing bug (by [@z3ut](https://github.com/z3ut)) [#739](https://github.com/Leaflet/Leaflet.markercluster/issues/739)
123
+ - Fix an issue when opening a popup inside of zoomToShowLayer
124
+ - If a marker is moved with an open popup on it, re-open the popup after moving it. [#651](https://github.com/Leaflet/Leaflet.markercluster/issues/651)
125
+
126
+ ## 1.0.1 (2017-01-25)
127
+
128
+ ### Improvements
129
+
130
+ - Add install and build steps with jake (by [@kazes](https://github.com/kazes)) [#733](https://github.com/Leaflet/Leaflet.markercluster/pull/733)
131
+ - Readme improvements (by [@ghybs](https://github.com/ghybs), [@bertyhell](https://github.com/bertyhell)) [#734](https://github.com/Leaflet/Leaflet.markercluster/pull/738), [#734](https://github.com/Leaflet/Leaflet.markercluster/pull/738
132
+ - Bump all examples to leaflet 1.0.3
133
+
134
+ ### Bugfixes
135
+
136
+ - Fixed leaflet 1.0.2 bug where clearLayers would throw an exception (by [@marcianoviereck92](https://github.com/marcianoviereck92)) [#746](https://github.com/Leaflet/Leaflet.markercluster/pull/746)
137
+
138
+ ## 1.0.0 (2016-10-03)
139
+
140
+ ### Improvements
141
+
142
+ - Compatibility with Leaflet 1.0.0 (by [@danzel](https://githum.com/danzel), [@Eschon](https://github.com/Eschon), [@ghybs](https://github.com/ghybs), [@IvanSanchez](https://github.com/IvanSanchez))
143
+ - Support moving markers [#57](https://github.com/Leaflet/Leaflet.markercluster/issues/57)
144
+ - chunkedLoading option to keep browser more responsive during larging a load data set [#292](https://github.com/Leaflet/Leaflet.markercluster/issues/292)
145
+ - maxClusterRadius can be a function (by [@Schwanksta](https://github.com/Schwanksta)) [#298](https://github.com/Leaflet/Leaflet.markercluster/issues/298)
146
+ - Spiderfy without zooming when all markers at same location (by [@rdenniston](https://github.com/rdenniston), [@ghybs](https://github.com/ghybs)) [#415](https://github.com/Leaflet/Leaflet.markercluster/issues/415), [#606](https://github.com/Leaflet/Leaflet.markercluster/issues/606)
147
+ - On becoming visible, markers retain their original opacity. (by [@IvanSanchez](https://github.com/IvanSanchez)) [#444](https://github.com/Leaflet/Leaflet.markercluster/issues/444)
148
+ - Spiderleg Polyline options (by [@mikeatlas](https://github.com/mikeatlas)) [#466](https://github.com/Leaflet/Leaflet.markercluster/issues/466)
149
+ - Extra methods to allow refreshing cluster icons (by [@ghybs](https://github.com/ghybs)) [#564](https://github.com/Leaflet/Leaflet.markercluster/issues/564)
150
+ - Ability to disable animations (by [@ghybs](https://github.com/ghybs)) [#578](https://github.com/Leaflet/Leaflet.markercluster/issues/578)
151
+ - Optimized performance of bulk addLayers and removeLayers (by [@ghybs](https://github.com/ghybs)) [#584](https://github.com/Leaflet/Leaflet.markercluster/issues/584)
152
+ - Replaced spiderfy legs animation from SMIL to CSS transition (by [@ghybs](https://github.com/ghybs)) [#585](https://github.com/Leaflet/Leaflet.markercluster/issues/585)
153
+ - Provide more detailed context information on the spiderfied event (by [@evanvosberg](https://github.com/evanvosberg)) [#421](https://github.com/Leaflet/Leaflet.markercluster/issues/421)
154
+ - Add unspiderfied event
155
+ - Readme updates (by [@ghybs](https://github.com/ghybs), [@tomchadwin](https://github.com/tomchadwin) [@Cyrille37](https://github.com/Cyrille37) [@franckl](https://github.com/franckl) [@mikeatlas](https://github.com/mikeatlas)
156
+ [@rdenniston](https://github.com/rdenniston) [@maackle](https://github.com/maackle) [@fureigh](https://github.com/fureigh) [@Wildhoney](https://github.com/Wildhoney) [@Schwanksta](https://github.com/Schwanksta) [@frankrowe](https://github.com/frankrowe))
157
+ - Improve adding and removing nested LayerGroups (by [@ghybs](https://github.com/ghybs)) [#624](https://github.com/Leaflet/Leaflet.markercluster/pull/624)
158
+ - Add public unspiderfy method (by [@zverev](https://github.com/zverev)) [#617](https://github.com/Leaflet/Leaflet.markercluster/pull/617)
159
+ - Optimized performance of bulk add with complex icon create function (by [@mlazowik](https://github.com/mlazowik)) [#697](https://github.com/Leaflet/Leaflet.markercluster/pull/697)
160
+ - Remove leaflet from peerDependencies (by [@tyleralves](https://github.com/tyleralves)) [#703](https://github.com/Leaflet/Leaflet.markercluster/pull/703)
161
+ - Simplified \_recursively (by [@ghybs](https://github.com/ghybs)) [#656](https://github.com/Leaflet/Leaflet.markercluster/pull/656)
162
+
163
+ ### Bugfixes
164
+
165
+ - Fix getBounds when removeOutsideVisibleBounds: false is set. [#321](https://github.com/Leaflet/Leaflet.markercluster/issues/321)
166
+ - Fix zoomToShowLayer fails after initial spiderfy [#286](https://github.com/Leaflet/Leaflet.markercluster/issues/286)
167
+ - Fix cluster not disappearing on Android [#344](https://github.com/Leaflet/Leaflet.markercluster/issues/344)
168
+ - Fix RemoveLayers() when spiderified (by [@Grsmto](https://github.com/Grsmto)) [#358](https://github.com/Leaflet/Leaflet.markercluster/issues/358)
169
+ - Remove lines from map when removing cluster (by [@olive380](https://github.com/olive380)) [#532](https://github.com/Leaflet/Leaflet.markercluster/issues/532)
170
+ - Fix getConvexHull when all markers are located at same latitude (by [@olive380](https://github.com/olive380)) [#533](https://github.com/Leaflet/Leaflet.markercluster/issues/533)
171
+ - Fix removeLayers when cluster is not on the map (by [@eschon](https://github.com/eschon)) [#556](https://github.com/Leaflet/Leaflet.markercluster/issues/556)
172
+ - Improved zoomToShowLayer with callback check (by [@ghybs](https://github.com/ghybs)) [#572](https://github.com/Leaflet/Leaflet.markercluster/issues/572)
173
+ - Improved reliability of RefreshSpec test suite for PhantomJS (by [@ghybs](https://github.com/ghybs)) [#577](https://github.com/Leaflet/Leaflet.markercluster/issues/577)
174
+ - Corrected effect of removeOutsideVisibleBounds option (by [@ghybs](https://github.com/ghybs)) [#575](https://github.com/Leaflet/Leaflet.markercluster/issues/575)
175
+ - Fix getLayer when provided a string [#531](https://github.com/Leaflet/Leaflet.markercluster/issues/531)
176
+ - Documentation improvements (by [@ghybs](https://github.com/ghybs)) [#579](https://github.com/Leaflet/Leaflet.markercluster/issues/579)
177
+ - Correct \_getExpandedVisibleBounds for Max Latitude (by [@ghybs](https://github.com/ghybs)) [#587](https://github.com/Leaflet/Leaflet.markercluster/issues/587)
178
+ - Correct unspiderfy vector (by [@ghybs](https://github.com/ghybs)) [#604](https://github.com/Leaflet/Leaflet.markercluster/issues/604)
179
+ - Remove "leaflet-cluster-anim" class on map remove while spiderfied (by [@ghybs](https://github.com/ghybs)) [#607](https://github.com/Leaflet/Leaflet.markercluster/issues/607)
180
+ - Fix disableClusteringAtZoom maxZoom troubles (by [@OriginalSin](https://github.com/OriginalSin)) [#609](https://github.com/Leaflet/Leaflet.markercluster/issues/609)
181
+ - Fix clusters not disappearing when they were near the edge on mobile (by [@ghybs](https://github.com/ghybs)) [#529](https://github.com/Leaflet/Leaflet.markercluster/issues/529)
182
+ - Remove leaflet from dependencies (by [@ghybs](https://github.com/ghybs)) [#639](https://github.com/Leaflet/Leaflet.markercluster/issues/639)
183
+ - Fix interaction between zoomOrSpiderfy and disableClusteringAtZoom (by [@ghybs](https://github.com/ghybs)) [#633](https://github.com/Leaflet/Leaflet.markercluster/issues/633) [#648](https://github.com/Leaflet/Leaflet.markercluster/issues/648)
184
+
185
+ ## 0.4 (2013-12-19)
186
+
187
+ ### Improvements
188
+
189
+ - Fix Quick Zoom in/out causing everything to disappear in Firefox (Reported by [@paulovieira](https://github.com/paulovieira)) [#140](https://github.com/Leaflet/Leaflet.markercluster/issues/140)
190
+ - Slow the expand/contract animation down from 200ms to 300ms
191
+
192
+ ### Bugfixes
193
+
194
+ - Fix some cases zoomToShowLayer wouldn't work (Reported by [@absemetov](https://github.com/absemetov)) [#203](https://github.com/Leaflet/Leaflet.markercluster/issues/203) [#228](https://github.com/Leaflet/Leaflet.markercluster/issues/228) [#286](https://github.com/Leaflet/Leaflet.markercluster/issues/286)
195
+
196
+ ## 0.3 (2013-12-18)
197
+
198
+ ### Improvements
199
+
200
+ - Work better with custom projections (by [@andersarstrand](https://github.com/andersarstrand)) [#74](https://github.com/Leaflet/Leaflet.markercluster/issues/74)
201
+ - Add custom getBounds that works (Reported by [@2803media](https://github.com/2803media))
202
+ - Allow spacing spiderfied icons further apart (Reported by [@stevevance](https://github.com/stevevance)) [#100](https://github.com/Leaflet/Leaflet.markercluster/issues/100)
203
+ - Add custom eachLayer that works (Reported by [@cilogi](https://github.com/cilogi)) [#102](https://github.com/Leaflet/Leaflet.markercluster/issues/102)
204
+ - Add an option (removeOutsideVisibleBounds) to prevent removing clusters that are outside of the visible bounds (by [@wildhoney](https://github.com/wildhoney)) [#103](https://github.com/Leaflet/Leaflet.markercluster/issues/103)
205
+ - Add getBounds method to cluster (Reported by [@nderambure](https://github.com/nderambure)) [#88](https://github.com/Leaflet/Leaflet.markercluster/issues/88)
206
+ - Lots of unit tests
207
+ - Support having Circle / CircleMarker as child markers
208
+ - Add factory methods (Reported by [@mourner](https://github.com/mourner)) [#21](https://github.com/Leaflet/Leaflet.markercluster/issues/21)
209
+ - Add getVisibleParent method to allow getting the visible parent cluster or the marker if it is visible. (By [@littleiffel](https://github.com/littleiffel)) [#102](https://github.com/Leaflet/Leaflet.markercluster/issues/102)
210
+ - Allow adding non-clusterable things to a MarkerClusterGroup, we don't cluster them. (Reported by [@benbalter](https://github.com/benbalter)) [#195](https://github.com/Leaflet/Leaflet.markercluster/issues/195)
211
+ - removeLayer supports taking a FeatureGroup (Reported by [@pabloalcaraz](https://github.com/pabloalcaraz)) [#236](https://github.com/Leaflet/Leaflet.markercluster/issues/236)
212
+ - DistanceGrid tests, QuickHull tests and improvements (By [@tmcw](https://github.com/tmcw)) [#247](https://github.com/Leaflet/Leaflet.markercluster/issues/247) [#248](https://github.com/Leaflet/Leaflet.markercluster/issues/248) [#249](https://github.com/Leaflet/Leaflet.markercluster/issues/249)
213
+ - Implemented getLayers (Reported by [@metajungle](https://github.com/metajungle)) [#222](https://github.com/Leaflet/Leaflet.markercluster/issues/222)
214
+ - zoomToBounds now only zooms in as far as it needs to to get all of the markers on screen if this is less zoom than zooming to the actual bounds would be (Reported by [@adamyonk](https://github.com/adamyonk)) [#185](https://github.com/Leaflet/Leaflet.markercluster/issues/185)
215
+ - Keyboard accessibility improvements (By [@Zombienaute](https://github.com/Zombienaute)) [#273](https://github.com/Leaflet/Leaflet.markercluster/issues/273)
216
+ - IE Specific css in the default styles is no longer a separate file (By [@frankrowe](https://github.com/frankrowe)) [#280](https://github.com/Leaflet/Leaflet.markercluster/issues/280)
217
+ - Improve usability with small maps (Reported by [@JSCSJSCS](https://github.com/JSCSJSCS)) [#144](https://github.com/Leaflet/Leaflet.markercluster/issues/144)
218
+ - Implement FeatureGroup.getLayer (Reported by [@newmanw](https://github.com/newmanw)) [#244](https://github.com/Leaflet/Leaflet.markercluster/issues/244)
219
+
220
+ ### Bugfixes
221
+
222
+ - Fix singleMarkerMode when you aren't on the map (by [@duncanparkes](https://github.com/duncanparkes)) [#77](https://github.com/Leaflet/Leaflet.markercluster/issues/77)
223
+ - Fix clearLayers when you aren't on the map (by [@duncanparkes](https://github.com/duncanparkes)) [#79](https://github.com/Leaflet/Leaflet.markercluster/issues/79)
224
+ - IE10 Bug fix (Reported by [@theLundquist](https://github.com/theLundquist)) [#86](https://github.com/Leaflet/Leaflet.markercluster/issues/86)
225
+ - Fixes for hasLayer after removing a layer (Reported by [@cvisto](https://github.com/cvisto)) [#44](https://github.com/Leaflet/Leaflet.markercluster/issues/44)
226
+ - Fix clearLayers not unsetting \_\_parent of the markers, preventing them from being re-added. (Reported by [@apuntovanini](https://github.com/apuntovanini)) [#99](https://github.com/Leaflet/Leaflet.markercluster/issues/99)
227
+ - Fix map.removeLayer(markerClusterGroup) not working (Reported by [@Driklyn](https://github.com/Driklyn)) [#108](https://github.com/Leaflet/Leaflet.markercluster/issues/108)
228
+ - Fix map.addLayers not updating cluster icons (Reported by [@Driklyn](https://github.com/Driklyn)) [#114](https://github.com/Leaflet/Leaflet.markercluster/issues/114)
229
+ - Fix spiderfied clusters breaking if a marker is added to them (Reported by [@Driklyn](https://github.com/Driklyn)) [#114](https://github.com/Leaflet/Leaflet.markercluster/issues/114)
230
+ - Don't show coverage for spiderfied clusters as it will be wrong. (Reported by [@ajbeaven](https://github.com/ajbeaven)) [#95](https://github.com/Leaflet/Leaflet.markercluster/issues/95)
231
+ - Improve zoom in/out immediately making all everything disappear, still issues in Firefox [#140](https://github.com/Leaflet/Leaflet.markercluster/issues/140)
232
+ - Fix animation not stopping with only one marker. (Reported by [@Driklyn](https://github.com/Driklyn)) [#146](https://github.com/Leaflet/Leaflet.markercluster/issues/146)
233
+ - Various fixes for new leaflet (Reported by [@PeterAronZentai](https://github.com/PeterAronZentai)) [#159](https://github.com/Leaflet/Leaflet.markercluster/issues/159)
234
+ - Fix clearLayers when we are spiderfying (Reported by [@skullbooks](https://github.com/skullbooks)) [#162](https://github.com/Leaflet/Leaflet.markercluster/issues/162)
235
+ - Fix removing layers in certain situations (Reported by [@bpavot](https://github.com/bpavot)) [#160](https://github.com/Leaflet/Leaflet.markercluster/issues/160)
236
+ - Support calling hasLayer with null (by [@l0c0luke](https://github.com/l0c0luke)) [#170](https://github.com/Leaflet/Leaflet.markercluster/issues/170)
237
+ - Lots of fixes for removing a MarkerClusterGroup from the map (Reported by [@annetdeboer](https://github.com/annetdeboer)) [#200](https://github.com/Leaflet/Leaflet.markercluster/issues/200)
238
+ - Throw error when being added to a map with no maxZoom.
239
+ - Fixes for markers not appearing after a big zoom (Reported by [@arnoldbird](https://github.com/annetdeboer)) [#216](https://github.com/Leaflet/Leaflet.markercluster/issues/216) (Reported by [@mathilde-pellerin](https://github.com/mathilde-pellerin)) [#260](https://github.com/Leaflet/Leaflet.markercluster/issues/260)
240
+ - Fix coverage polygon not being removed when a MarkerClusterGroup is removed (Reported by [@ZeusTheTrueGod](https://github.com/ZeusTheTrueGod)) [#245](https://github.com/Leaflet/Leaflet.markercluster/issues/245)
241
+ - Fix getVisibleParent when no parent is visible (Reported by [@ajbeaven](https://github.com/ajbeaven)) [#265](https://github.com/Leaflet/Leaflet.markercluster/issues/265)
242
+ - Fix spiderfied markers not hiding on a big zoom (Reported by [@Vaesive](https://github.com/Vaesive)) [#268](https://github.com/Leaflet/Leaflet.markercluster/issues/268)
243
+ - Fix clusters not hiding on a big zoom (Reported by [@versusvoid](https://github.com/versusvoid)) [#281](https://github.com/Leaflet/Leaflet.markercluster/issues/281)
244
+ - Don't fire multiple clustermouseover/off events due to child divs in the cluster marker (Reported by [@heidemn](https://github.com/heidemn)) [#252](https://github.com/Leaflet/Leaflet.markercluster/issues/252)
245
+
246
+ ## 0.2 (2012-10-11)
247
+
248
+ ### Improvements
249
+
250
+ - Add addLayers/removeLayers bulk add and remove functions that perform better than the individual methods
251
+ - Allow customising the polygon generated for showing the area a cluster covers (by [@yohanboniface](https://github.com/yohanboniface)) [#68](https://github.com/Leaflet/Leaflet.markercluster/issues/68)
252
+ - Add zoomToShowLayer method to zoom down to a marker then call a callback once it is visible
253
+ - Add animateAddingMarkers to allow disabling animations caused when adding/removing markers
254
+ - Add hasLayer
255
+ - Pass the L.MarkerCluster to iconCreateFunction to give more flexibility deciding the icon
256
+ - Make addLayers support geojson layers
257
+ - Allow disabling clustering at a given zoom level
258
+ - Allow styling markers that are added like they were clusters of size 1
259
+
260
+ ### Bugfixes
261
+
262
+ - Support when leaflet is configured to use canvas rather than SVG
263
+ - Fix some potential crashes in zoom handlers
264
+ - Tidy up when we are removed from the map
265
+
266
+ ## 0.1 (2012-08-16)
267
+
268
+ Initial Release!
node_modules/leaflet.markercluster/CONTRIBUTING.md ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Contributing to Leaflet.MarkerCluster
2
+ =====================================
3
+
4
+ 1. [Reporting Bugs](#reporting-bugs)
5
+ 2. [Contributing Code](#contributing-code)
6
+ 3. [Building](#building)
7
+ 4. [Testing](#testing)
8
+
9
+ ## Reporting Bugs
10
+
11
+ Before reporting a bug on the project's [issues page](https://github.com/Leaflet/Leaflet.markercluster/issues),
12
+ first make sure that your issue is caused by Leaflet.MarkerCluster, not your application code
13
+ (e.g. passing incorrect arguments to methods, etc.).
14
+ Second, search the already reported issues for similar cases,
15
+ and if it's already reported, just add any additional details in the comments.
16
+
17
+ After you've made sure that you've found a new Leaflet.markercluster bug,
18
+ here are some tips for creating a helpful report that will make fixing it much easier and quicker:
19
+
20
+ * Write a **descriptive, specific title**. Bad: *Problem with polylines*. Good: *Doing X in IE9 causes Z*.
21
+ * Include **browser, OS and Leaflet version** info in the description.
22
+ * Create a **simple test case** that demonstrates the bug (e.g. using [JSFiddle](http://jsfiddle.net/) or [JS Bin](http://jsbin.com/)).
23
+ * Check whether the bug can be reproduced in **other browsers**.
24
+ * Check if the bug occurs in the stable version, master, or both.
25
+ * *Bonus tip:* if the bug only appears in the master version but the stable version is fine,
26
+ use `git bisect` to find the exact commit that introduced the bug.
27
+
28
+ If you just want some help with your project,
29
+ try asking [on the Leaflet forum](https://groups.google.com/forum/#!forum/leaflet-js) instead.
30
+
31
+ ## Contributing Code
32
+
33
+ ### Considerations for Accepting Patches
34
+
35
+ While we happily accept patches, we're also committed to keeping Leaflet simple, lightweight and blazingly fast.
36
+ So bugfixes, performance optimizations and small improvements that don't add a lot of code
37
+ are much more likely to get accepted quickly.
38
+
39
+ Before sending a pull request with a new feature, check if it's been discussed before already
40
+ (either on [GitHub issues](https://github.com/Leaflet/Leaflet/issues)
41
+ or [Leaflet UserVoice](http://leaflet.uservoice.com/)),
42
+ and ask yourself two questions:
43
+
44
+ 1. Are you sure that this new feature is important enough to justify its presence in the Leaflet core?
45
+ Or will it look better as a plugin in a separate repository?
46
+ 2. Is it written in a simple, concise way that doesn't add bulk to the codebase?
47
+
48
+ If your feature or API improvement did get merged into master,
49
+ please consider submitting another pull request with the corresponding [documentation update](#improving-documentation).
50
+
51
+ ## Building
52
+
53
+ Install the dependencies:
54
+ ```
55
+ npm install -g jake
56
+ npm install
57
+ ```
58
+
59
+ Then to build:
60
+ ```
61
+ jake
62
+ ```
63
+ Output will be in the ```dist/``` directory
64
+
65
+ ## Testing
66
+
67
+ To run unit tests:
68
+ ```
69
+ jake test
70
+ ```
node_modules/leaflet.markercluster/ISSUE_TEMPLATE.md ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ - [ ] I'm reporting a bug, not asking for help
2
+ - [ ] I'm sure this is a Leaflet.MarkerCluster code issue, not an issue with my own code nor with the framework I'm using (Cordova, Ionic, Angular, React…)
3
+ - [ ] I've searched through the issues to make sure it's not yet reported
4
+
5
+ ----
6
+
7
+ ## How to reproduce
8
+
9
+ - Leaflet version I'm using:
10
+ - Leaflet.MarkerCluster version I'm using:
11
+ - Browser (with version) I'm using:
12
+ - OS/Platform (with version) I'm using:
13
+ - step 1
14
+ - step 2
15
+
16
+ ## What behaviour I'm expecting and which behaviour I'm seeing
17
+
18
+ ## Minimal example reproducing the issue
19
+
20
+ - [ ] this example is as simple as possible
21
+ - [ ] this example does not rely on any third party code
22
+
23
+ Using http://leafletjs.com/edit.html or any other jsfiddle-like site.
node_modules/leaflet.markercluster/Jakefile.js ADDED
@@ -0,0 +1,93 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ Leaflet.markercluster building, testing and linting scripts.
3
+
4
+ To use, install Node, then run the following commands in the project root:
5
+
6
+ npm install -g jake
7
+ npm install
8
+
9
+ To check the code for errors and build Leaflet from source, run "jake".
10
+ To run the tests, run "jake test".
11
+
12
+ For a custom build, open build/build.html in the browser and follow the instructions.
13
+ */
14
+
15
+ var path = require('path');
16
+
17
+ desc('Check Leaflet.markercluster source for errors with JSHint');
18
+ task('lint', {
19
+ async: true
20
+ }, function(){
21
+ jake.exec('jshint', {
22
+ printStdout: true
23
+ }, function () {
24
+ console.log('\tCheck passed.\n');
25
+ complete();
26
+ });
27
+ });
28
+
29
+ desc('Combine Leaflet.markercluster source files');
30
+ task('build', ['lint'], {
31
+ async: true
32
+ }, function(){
33
+ jake.exec('npm run-script rollup', function() {
34
+ console.log('Rolled up.');
35
+ complete();
36
+ });
37
+ });
38
+
39
+ desc('Compress bundled files');
40
+ task('uglify', ['build'], function(){
41
+ jake.exec('npm run-script uglify', function() { console.log('Uglyfied.'); });
42
+ });
43
+
44
+ desc('Run PhantomJS tests');
45
+ task('test', ['lint'], function() {
46
+
47
+ var karma = require('karma'),
48
+ testConfig = {configFile : path.join(__dirname, './spec/karma.conf.js')};
49
+
50
+ testConfig.browsers = ['PhantomJS'];
51
+
52
+ function isArgv(optName) {
53
+ return process.argv.indexOf(optName) !== -1;
54
+ }
55
+
56
+ if (isArgv('--chrome')) {
57
+ testConfig.browsers.push('Chrome');
58
+ }
59
+ if (isArgv('--safari')) {
60
+ testConfig.browsers.push('Safari');
61
+ }
62
+ if (isArgv('--ff')) {
63
+ testConfig.browsers.push('Firefox');
64
+ }
65
+ if (isArgv('--ie')) {
66
+ testConfig.browsers.push('IE');
67
+ }
68
+
69
+ if (isArgv('--cov')) {
70
+ testConfig.preprocessors = {
71
+ 'src/**/*.js': 'coverage'
72
+ };
73
+ testConfig.coverageReporter = {
74
+ type : 'html',
75
+ dir : 'coverage/'
76
+ };
77
+ testConfig.reporters = ['coverage'];
78
+ }
79
+
80
+ console.log('Running tests...');
81
+
82
+ var server = new karma.Server(testConfig, function(exitCode) {
83
+ if (!exitCode) {
84
+ console.log('\tTests ran successfully.\n');
85
+ complete();
86
+ } else {
87
+ process.exit(exitCode);
88
+ }
89
+ });
90
+ server.start();
91
+ });
92
+
93
+ task('default', ['build', 'uglify']);
node_modules/leaflet.markercluster/MIT-LICENCE.txt ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Copyright 2012 David Leaver
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
node_modules/leaflet.markercluster/README.md ADDED
@@ -0,0 +1,319 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Leaflet.markercluster
2
+ =====================
3
+
4
+ Provides Beautiful Animated Marker Clustering functionality for [Leaflet](http://leafletjs.com), a JS library for interactive maps.
5
+
6
+ *Requires Leaflet 1.0.0*
7
+
8
+ ![cluster map example](example/map.png)
9
+
10
+ For a Leaflet 0.7 compatible version, [use the leaflet-0.7 branch](https://github.com/Leaflet/Leaflet.markercluster/tree/leaflet-0.7)<br>
11
+ For a Leaflet 0.5 compatible version, [Download b128e950](https://github.com/Leaflet/Leaflet.markercluster/archive/b128e950d8f5d7da5b60bd0aa9a88f6d3dd17c98.zip)<br>
12
+ For a Leaflet 0.4 compatible version, [Download the 0.2 release](https://github.com/Leaflet/Leaflet.markercluster/archive/0.2.zip)
13
+
14
+ <!---
15
+ TOC created with gh-md-toc
16
+ https://github.com/ekalinin/github-markdown-toc
17
+ removed link to h1 and indented back 2 spaces all links.
18
+ -->
19
+ ## Table of Contents
20
+ * [Using the plugin](#using-the-plugin)
21
+ * [Building, testing and linting scripts](#building-testing-and-linting-scripts)
22
+ * [Examples](#examples)
23
+ * [Usage](#usage)
24
+ * [Options](#options)
25
+ * [Defaults](#defaults)
26
+ * [Customising the Clustered Markers](#customising-the-clustered-markers)
27
+ * [Customising Spiderfy shape positions](#customising-spiderfy-shape-positions)
28
+ * [All Options](#all-options)
29
+ * [Enabled by default (boolean options)](#enabled-by-default-boolean-options)
30
+ * [Other options](#other-options)
31
+ * [Chunked addLayers options](#chunked-addlayers-options)
32
+ * [Events](#events)
33
+ * [Additional MarkerClusterGroup Events](#additional-markerclustergroup-events)
34
+ * [Methods](#methods)
35
+ * [Group methods](#group-methods)
36
+ * [Adding and removing Markers](#adding-and-removing-markers)
37
+ * [Bulk adding and removing Markers](#bulk-adding-and-removing-markers)
38
+ * [Getting the visible parent of a marker](#getting-the-visible-parent-of-a-marker)
39
+ * [Refreshing the clusters icon](#refreshing-the-clusters-icon)
40
+ * [Other Group Methods](#other-group-methods)
41
+ * [Clusters methods](#clusters-methods)
42
+ * [Getting the bounds of a cluster](#getting-the-bounds-of-a-cluster)
43
+ * [Zooming to the bounds of a cluster](#zooming-to-the-bounds-of-a-cluster)
44
+ * [Other clusters methods](#other-clusters-methods)
45
+ * [Handling LOTS of markers](#handling-lots-of-markers)
46
+ * [License](#license)
47
+ * [Sub-plugins](#sub-plugins)
48
+
49
+
50
+ ## Using the plugin
51
+ Include the plugin CSS and JS files on your page after Leaflet files, using your method of choice:
52
+ * [Download the `v1.4.1` release](https://github.com/Leaflet/Leaflet.markercluster/archive/v1.4.1.zip)
53
+ * Use unpkg CDN: `https://unpkg.com/leaflet.markercluster@1.4.1/dist/`
54
+ * Install with npm: `npm install leaflet.markercluster`
55
+
56
+ In each case, use files in the `dist` folder:
57
+ * `MarkerCluster.css`
58
+ * `MarkerCluster.Default.css` (not needed if you use your own `iconCreateFunction` instead of the default one)
59
+ * `leaflet.markercluster.js` (or `leaflet.markercluster-src.js` for the non-minified version)
60
+
61
+ ### Building, testing and linting scripts
62
+ Install jake `npm install -g jake` then run `npm install`
63
+ * To check the code for errors and build Leaflet from source, run `jake`.
64
+ * To run the tests, run `jake test`.
65
+
66
+ ### Examples
67
+ See the included examples for usage.
68
+
69
+ The [realworld example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-realworld.388.html) is a good place to start, it uses all of the defaults of the clusterer.
70
+ Or check out the [custom example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-custom.html) for how to customise the behaviour and appearance of the clusterer
71
+
72
+ ### Usage
73
+ Create a new MarkerClusterGroup, add your markers to it, then add it to the map
74
+
75
+ ```javascript
76
+ var markers = L.markerClusterGroup();
77
+ markers.addLayer(L.marker(getRandomLatLng(map)));
78
+ ... Add more layers ...
79
+ map.addLayer(markers);
80
+ ```
81
+
82
+ ## Options
83
+ ### Defaults
84
+ By default the Clusterer enables some nice defaults for you:
85
+ * **showCoverageOnHover**: When you mouse over a cluster it shows the bounds of its markers.
86
+ * **zoomToBoundsOnClick**: When you click a cluster we zoom to its bounds.
87
+ * **spiderfyOnMaxZoom**: When you click a cluster at the bottom zoom level we spiderfy it so you can see all of its markers. (*Note: the spiderfy occurs at the current zoom level if all items within the cluster are still clustered at the maximum zoom level or at zoom specified by `disableClusteringAtZoom` option*)
88
+ * **removeOutsideVisibleBounds**: Clusters and markers too far from the viewport are removed from the map for performance.
89
+ * **spiderLegPolylineOptions**: Allows you to specify [PolylineOptions](http://leafletjs.com/reference.html#polyline-options) to style spider legs. By default, they are `{ weight: 1.5, color: '#222', opacity: 0.5 }`.
90
+
91
+ You can disable any of these as you want in the options when you create the MarkerClusterGroup:
92
+ ```javascript
93
+ var markers = L.markerClusterGroup({
94
+ spiderfyOnMaxZoom: false,
95
+ showCoverageOnHover: false,
96
+ zoomToBoundsOnClick: false
97
+ });
98
+ ```
99
+
100
+ ### Customising the Clustered Markers
101
+ As an option to MarkerClusterGroup you can provide your own function for creating the Icon for the clustered markers.
102
+ The default implementation changes color at bounds of 10 and 100, but more advanced uses may require customising this.
103
+ You do not need to include the .Default css if you go this way.
104
+ You are passed a MarkerCluster object, you'll probably want to use `getChildCount()` or `getAllChildMarkers()` to work out the icon to show.
105
+
106
+ ```javascript
107
+ var markers = L.markerClusterGroup({
108
+ iconCreateFunction: function(cluster) {
109
+ return L.divIcon({ html: '<b>' + cluster.getChildCount() + '</b>' });
110
+ }
111
+ });
112
+ ```
113
+
114
+ Check out the [custom example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-custom.html) for an example of this.
115
+
116
+ If you need to update the clusters icon (e.g. they are based on markers real-time data), use the method [refreshClusters()](#refreshing-the-clusters-icon).
117
+
118
+ ### Customising Spiderfy shape positions
119
+ You can also provide a custom function as an option to MarkerClusterGroup to override the spiderfy shape positions. The example below implements linear spiderfy positions which overrides the default circular shape.
120
+
121
+ ```javascript
122
+ var markers = L.markerClusterGroup({
123
+ spiderfyShapePositions: function(count, centerPt) {
124
+ var distanceFromCenter = 35,
125
+ markerDistance = 45,
126
+ lineLength = markerDistance * (count - 1),
127
+ lineStart = centerPt.y - lineLength / 2,
128
+ res = [],
129
+ i;
130
+
131
+ res.length = count;
132
+
133
+ for (i = count - 1; i >= 0; i--) {
134
+ res[i] = new Point(centerPt.x + distanceFromCenter, lineStart + markerDistance * i);
135
+ }
136
+
137
+ return res;
138
+ }
139
+ });
140
+ ```
141
+
142
+ ### All Options
143
+ #### Enabled by default (boolean options)
144
+ * **showCoverageOnHover**: When you mouse over a cluster it shows the bounds of its markers.
145
+ * **zoomToBoundsOnClick**: When you click a cluster we zoom to its bounds.
146
+ * **spiderfyOnMaxZoom**: When you click a cluster at the bottom zoom level we spiderfy it so you can see all of its markers. (*Note: the spiderfy occurs at the current zoom level if all items within the cluster are still clustered at the maximum zoom level or at zoom specified by `disableClusteringAtZoom` option*).
147
+ * **removeOutsideVisibleBounds**: Clusters and markers too far from the viewport are removed from the map for performance.
148
+ * **animate**: Smoothly split / merge cluster children when zooming and spiderfying. If `L.DomUtil.TRANSITION` is false, this option has no effect (no animation is possible).
149
+
150
+ #### Other options
151
+ * **animateAddingMarkers**: If set to true (and `animate` option is also true) then adding individual markers to the MarkerClusterGroup after it has been added to the map will add the marker and animate it into the cluster. Defaults to false as this gives better performance when bulk adding markers. addLayers does not support this, only addLayer with individual Markers.
152
+ * **disableClusteringAtZoom**: If set, at this zoom level and below, markers will not be clustered. This defaults to disabled. [See Example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-realworld-maxzoom.388.html). Note: you may be interested in disabling `spiderfyOnMaxZoom` option when using `disableClusteringAtZoom`.
153
+ * **maxClusterRadius**: The maximum radius that a cluster will cover from the central marker (in pixels). Default 80. Decreasing will make more, smaller clusters. You can also use a function that accepts the current map zoom and returns the maximum cluster radius in pixels.
154
+ * **polygonOptions**: Options to pass when creating the L.Polygon(points, options) to show the bounds of a cluster. Defaults to empty, which lets Leaflet use the [default Path options](http://leafletjs.com/reference.html#path-options).
155
+ * **singleMarkerMode**: If set to true, overrides the icon for all added markers to make them appear as a 1 size cluster. Note: the markers are not replaced by cluster objects, only their icon is replaced. Hence they still react to normal events, and option `disableClusteringAtZoom` does not restore their previous icon (see [#391](https://github.com/Leaflet/Leaflet.markercluster/issues/391)).
156
+ * **spiderLegPolylineOptions**: Allows you to specify [PolylineOptions](http://leafletjs.com/reference.html#polyline-options) to style spider legs. By default, they are `{ weight: 1.5, color: '#222', opacity: 0.5 }`.
157
+ * **spiderfyDistanceMultiplier**: Increase from 1 to increase the distance away from the center that spiderfied markers are placed. Use if you are using big marker icons (Default: 1).
158
+ * **iconCreateFunction**: Function used to create the cluster icon. See [the default implementation](https://github.com/Leaflet/Leaflet.markercluster/blob/15ed12654acdc54a4521789c498e4603fe4bf781/src/MarkerClusterGroup.js#L542) or the [custom example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-custom.html).
159
+ * **spiderfyShapePositions**: Function used to override spiderfy default shape positions.
160
+ * **clusterPane**: Map pane where the cluster icons will be added. Defaults to L.Marker's default (currently 'markerPane'). [See the pane example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-pane.html).
161
+
162
+ #### Chunked addLayers options
163
+ Options for the [addLayers](#bulk-adding-and-removing-markers) method. See [#357](https://github.com/Leaflet/Leaflet.markercluster/issues/357) for explanation on how the chunking works.
164
+ * **chunkedLoading**: Boolean to split the addLayer**s** processing in to small intervals so that the page does not freeze.
165
+ * **chunkInterval**: Time interval (in ms) during which addLayers works before pausing to let the rest of the page process. In particular, this prevents the page from freezing while adding a lot of markers. Defaults to 200ms.
166
+ * **chunkDelay**: Time delay (in ms) between consecutive periods of processing for addLayers. Default to 50ms.
167
+ * **chunkProgress**: Callback function that is called at the end of each chunkInterval. Typically used to implement a progress indicator, e.g. [code in RealWorld 50k](https://github.com/Leaflet/Leaflet.markercluster/blob/master/example/marker-clustering-realworld.50000.html#L33-L49). Defaults to null. Arguments:
168
+ 1. Number of processed markers
169
+ 2. Total number of markers being added
170
+ 3. Elapsed time (in ms)
171
+
172
+ ## Events
173
+ Leaflet events like `click`, `mouseover`, etc. are just related to _Markers_ in the cluster.
174
+ To receive events for clusters, listen to `'cluster' + '<eventName>'`, ex: `clusterclick`, `clustermouseover`, `clustermouseout`.
175
+
176
+ Set your callback up as follows to handle both cases:
177
+
178
+ ```javascript
179
+ markers.on('click', function (a) {
180
+ console.log('marker ' + a.layer);
181
+ });
182
+
183
+ markers.on('clusterclick', function (a) {
184
+ // a.layer is actually a cluster
185
+ console.log('cluster ' + a.layer.getAllChildMarkers().length);
186
+ });
187
+ ```
188
+
189
+ ### Additional MarkerClusterGroup Events
190
+
191
+ - **animationend**: Fires when marker clustering/unclustering animation has completed
192
+ - **spiderfied**: Fires when overlapping markers get spiderified (Contains ```cluster``` and ```markers``` attributes)
193
+ - **unspiderfied**: Fires when overlapping markers get unspiderified (Contains ```cluster``` and ```markers``` attributes)
194
+
195
+ ## Methods
196
+
197
+ ### Group methods
198
+
199
+ #### Adding and removing Markers
200
+ `addLayer`, `removeLayer` and `clearLayers` are supported and they should work for most uses.
201
+
202
+ #### Bulk adding and removing Markers
203
+ `addLayers` and `removeLayers` are bulk methods for adding and removing markers and should be favoured over the single versions when doing bulk addition/removal of markers. Each takes an array of markers. You can use [dedicated options](#chunked-addlayers-options) to fine-tune the behaviour of `addLayers`.
204
+
205
+ These methods extract non-group layer children from Layer Group types, even deeply nested. _However_, be noted that:
206
+ - `chunkProgress` jumps backward when `addLayers` finds a group (since appending its children to the input array makes the total increase).
207
+ - Groups are not actually added into the MarkerClusterGroup, only their non-group child layers. Therfore, `hasLayer` method will return `true` for non-group child layers, but `false` on any (possibly parent) Layer Group types.
208
+
209
+ If you are removing a lot of markers it will almost definitely be better to call `clearLayers` then call `addLayers` to add the markers you don't want to remove back in. See [#59](https://github.com/Leaflet/Leaflet.markercluster/issues/59#issuecomment-9320628) for details.
210
+
211
+ #### Getting the visible parent of a marker
212
+ If you have a marker in your MarkerClusterGroup and you want to get the visible parent of it (Either itself or a cluster it is contained in that is currently visible on the map).
213
+ This will return null if the marker and its parent clusters are not visible currently (they are not near the visible viewpoint)
214
+ ```javascript
215
+ var visibleOne = markerClusterGroup.getVisibleParent(myMarker);
216
+ console.log(visibleOne.getLatLng());
217
+ ```
218
+
219
+ #### Refreshing the clusters icon
220
+ If you have [customized](#customising-the-clustered-markers) the clusters icon to use some data from the contained markers, and later that data changes, use this method to force a refresh of the cluster icons.
221
+ You can use the method:
222
+ - without arguments to force all cluster icons in the Marker Cluster Group to be re-drawn.
223
+ - with an array or a mapping of markers to force only their parent clusters to be re-drawn.
224
+ - with an L.LayerGroup. The method will look for all markers in it. Make sure it contains only markers which are also within this Marker Cluster Group.
225
+ - with a single marker.
226
+ ```javascript
227
+ markers.refreshClusters();
228
+ markers.refreshClusters([myMarker0, myMarker33]);
229
+ markers.refreshClusters({id_0: myMarker0, id_any: myMarker33});
230
+ markers.refreshClusters(myLayerGroup);
231
+ markers.refreshClusters(myMarker);
232
+ ```
233
+
234
+ The plugin also adds a method on L.Marker to easily update the underlying icon options and refresh the icon.
235
+ If passing a second argument that evaluates to `true`, the method will also trigger a `refreshCluster` on the parent MarkerClusterGroup for that single marker.
236
+ ```javascript
237
+ // Use as many times as required to update markers,
238
+ // then call refreshClusters once finished.
239
+ for (i in markersSubArray) {
240
+ markersSubArray[i].refreshIconOptions(newOptionsMappingArray[i]);
241
+ }
242
+ markers.refreshClusters(markersSubArray);
243
+
244
+ // If updating only one marker, pass true to
245
+ // refresh this marker's parent clusters right away.
246
+ myMarker.refreshIconOptions(optionsMap, true);
247
+ ```
248
+
249
+ #### Other Group Methods
250
+ * **hasLayer**(layer): Returns true if the given layer (marker) is in the MarkerClusterGroup.
251
+ * **zoomToShowLayer**(layer, callback): Zooms to show the given marker (spiderfying if required), calls the callback when the marker is visible on the map.
252
+
253
+ ### Clusters methods
254
+ The following methods can be used with clusters (not the group). They are typically used for event handling.
255
+
256
+ #### Getting the bounds of a cluster
257
+ When you receive an event from a cluster you can query it for the bounds.
258
+ ```javascript
259
+ markers.on('clusterclick', function (a) {
260
+ var latLngBounds = a.layer.getBounds();
261
+ });
262
+ ```
263
+
264
+ You can also query for the bounding convex polygon.
265
+ See [example/marker-clustering-convexhull.html](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-convexhull.html) for a working example.
266
+ ```javascript
267
+ markers.on('clusterclick', function (a) {
268
+ map.addLayer(L.polygon(a.layer.getConvexHull()));
269
+ });
270
+ ```
271
+
272
+ #### Zooming to the bounds of a cluster
273
+ When you receive an event from a cluster you can zoom to its bounds in one easy step.
274
+ If all of the markers will appear at a higher zoom level, that zoom level is zoomed to instead.
275
+ `zoomToBounds` takes an optional argument to pass [options to the resulting `fitBounds` call](http://leafletjs.com/reference.html#map-fitboundsoptions).
276
+
277
+ See [marker-clustering-zoomtobounds.html](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-zoomtobounds.html) for a working example.
278
+ ```javascript
279
+ markers.on('clusterclick', function (a) {
280
+ a.layer.zoomToBounds({padding: [20, 20]});
281
+ });
282
+ ```
283
+
284
+ #### Other clusters methods
285
+ * **getChildCount**: Returns the total number of markers contained within that cluster.
286
+ * **getAllChildMarkers(storage: array | undefined, ignoreDraggedMarker: boolean | undefined)**: Returns an array of all markers contained within this cluster (storage will be used if provided). If ignoreDraggedMarker is true and there is currently a marker dragged, the dragged marker will not be included in the array.
287
+ * **spiderfy**: Spiderfies the child markers of this cluster
288
+ * **unspiderfy**: Unspiderfies a cluster (opposite of spiderfy)
289
+
290
+ ## Handling LOTS of markers
291
+ The Clusterer can handle 10,000 or even 50,000 markers (in chrome). IE9 has some issues with 50,000.
292
+ - [realworld 10,000 example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-realworld.10000.html)
293
+ - [realworld 50,000 example](https://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-realworld.50000.html)
294
+
295
+ Note: these two examples use the `chunkedLoading` option set to true in order to avoid locking the browser for a long time.
296
+
297
+ ## License
298
+
299
+ Leaflet.markercluster is free software, and may be redistributed under the MIT-LICENSE.
300
+
301
+ [![Build Status](https://travis-ci.org/Leaflet/Leaflet.markercluster.png?branch=master)](https://travis-ci.org/Leaflet/Leaflet.markercluster)
302
+
303
+ ## Sub-plugins
304
+ Leaflet.markercluster plugin is very popular and as such it generates high and
305
+ diverse expectations for increased functionalities.
306
+
307
+ If you are in that case, be sure to have a look first at the repository
308
+ [issues](https://github.com/Leaflet/Leaflet.markercluster/issues) in case what
309
+ you are looking for would already be discussed, and some workarounds would be proposed.
310
+
311
+ Check also the below sub-plugins:
312
+
313
+ | Plugin | Description | Maintainer |
314
+ | :----- | :---------- | :--------- |
315
+ | [Leaflet.FeatureGroup.SubGroup](https://github.com/ghybs/Leaflet.FeatureGroup.SubGroup) | Creates a Feature Group that adds its child layers into a parent group when added to a map (e.g. through L.Control.Layers). Typical usage is to dynamically add/remove groups of markers from Marker Cluster. | [ghybs](https://github.com/ghybs) |
316
+ | [Leaflet.MarkerCluster.LayerSupport](https://github.com/ghybs/Leaflet.MarkerCluster.LayerSupport) | Brings compatibility with L.Control.Layers and other Leaflet plugins. I.e. everything that uses direct calls to map.addLayer and map.removeLayer. | [ghybs](https://github.com/ghybs) |
317
+ | [Leaflet.MarkerCluster.Freezable](https://github.com/ghybs/Leaflet.MarkerCluster.Freezable) | Adds the ability to freeze clusters at a specified zoom. E.g. freezing at maxZoom + 1 makes as if clustering was programmatically disabled. | [ghybs](https://github.com/ghybs) |
318
+ | [Leaflet.MarkerCluster.PlacementStrategies](https://github.com/adammertel/Leaflet.MarkerCluster.PlacementStrategies) | Implements new strategies to position clustered markers (eg: clock, concentric circles, ...). Recommended to use with circleMarkers. [Demo](https://adammertel.github.io/Leaflet.MarkerCluster.PlacementStrategies/demo/demo1.html) | [adammertel](https://github.com/adammertel) / [UNIVIE](http://carto.univie.ac.at/) |
319
+ | [Leaflet.MarkerCluster.List](https://github.com/adammertel/Leaflet.MarkerCluster.List) | Displays child elements in a list. Suitable for mobile devices. [Demo](https://adammertel.github.io/Leaflet.MarkerCluster.List/demo/demo1.html) | [adammertel](https://github.com/adammertel) / [UNIVIE](http://carto.univie.ac.at/) |
node_modules/leaflet.markercluster/bower.json ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "leaflet.markercluster",
3
+ "version": "1.4.1",
4
+ "homepage": "https://github.com/Leaflet/Leaflet.markercluster",
5
+ "authors": [
6
+ "Dave Leaver <danzel@localhost.geek.nz>"
7
+ ],
8
+ "description": "Marker Clustering plugin for Leaflet.",
9
+ "main": [
10
+ "dist/leaflet.markercluster-src.js",
11
+ "dist/MarkerCluster.css",
12
+ "dist/MarkerCluster.Default.css"
13
+ ],
14
+ "license": "MIT",
15
+ "ignore": [
16
+ "**/.*",
17
+ "node_modules",
18
+ "bower_components",
19
+ "example",
20
+ "spec",
21
+ "test",
22
+ "tests"
23
+ ],
24
+ "dependencies": {
25
+ "leaflet": ">= 1.3.1"
26
+ }
27
+ }
node_modules/leaflet.markercluster/build/hintrc.js ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ exports.config = {
2
+
3
+ // environment
4
+ "browser": true,
5
+ "node": true,
6
+ "predef": ['L', 'define'],
7
+ "strict": false,
8
+
9
+ // code style
10
+ "bitwise": true,
11
+ "camelcase": true,
12
+ "curly": true,
13
+ "eqeqeq": true,
14
+ "forin": false,
15
+ "immed": true,
16
+ "latedef": true,
17
+ "newcap": true,
18
+ "noarg": true,
19
+ "noempty": true,
20
+ "nonew": true,
21
+ "undef": true,
22
+ "unused": true,
23
+ //"quotmark": "single",
24
+
25
+ // whitespace
26
+ "indent": 4,
27
+ "trailing": true,
28
+ "white": true,
29
+ "smarttabs": true,
30
+ //"maxlen": 120
31
+
32
+ // code simplicity - not enforced but nice to check from time to time
33
+ // "maxstatements": 20,
34
+ // "maxcomplexity": 5
35
+ // "maxparams": 4,
36
+ // "maxdepth": 4
37
+ };
node_modules/leaflet.markercluster/build/rollup-config.js ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ // Config file for running Rollup in "normal" mode (non-watch)
3
+
4
+ import rollupGitVersion from 'rollup-plugin-git-version'
5
+ import json from 'rollup-plugin-json'
6
+
7
+ import gitRev from 'git-rev-sync'
8
+
9
+
10
+ let version = require('../package.json').version;
11
+ let release;
12
+
13
+ // Skip the git branch+rev in the banner when doing a release build
14
+ if (process.env.NODE_ENV === 'release') {
15
+ release = true;
16
+ } else {
17
+ release = false;
18
+ const branch = gitRev.branch();
19
+ const rev = gitRev.short();
20
+ version += '+' + branch + '.' + rev;
21
+ }
22
+
23
+ const banner = `/*
24
+ * Leaflet.markercluster ` + version + `,
25
+ * Provides Beautiful Animated Marker Clustering functionality for Leaflet, a JS library for interactive maps.
26
+ * https://github.com/Leaflet/Leaflet.markercluster
27
+ * (c) 2012-2017, Dave Leaver, smartrak
28
+ */`;
29
+
30
+ export default {
31
+ input: 'src/index.js',
32
+ output: {
33
+ banner,
34
+ file: 'dist/leaflet.markercluster-src.js',
35
+ format: 'umd',
36
+ legacy: true, // Needed to create files loadable by IE8
37
+ name: 'Leaflet.markercluster',
38
+ sourcemap: true,
39
+ },
40
+ plugins: [
41
+ release ? json() : rollupGitVersion(),
42
+ ],
43
+ };
node_modules/leaflet.markercluster/example/geojson-sample.js ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ var geojsonSample = {
2
+ "type": "FeatureCollection",
3
+ "features": [
4
+ {
5
+ "type": "Feature",
6
+ "geometry": {
7
+ "type": "Point",
8
+ "coordinates": [102.0, 0.5]
9
+ },
10
+ "properties": {
11
+ "prop0": "value0",
12
+ "color": "blue"
13
+ }
14
+ },
15
+
16
+ {
17
+ "type": "Feature",
18
+ "geometry": {
19
+ "type": "LineString",
20
+ "coordinates": [[102.0, 0.0], [103.0, 1.0], [104.0, 0.0], [105.0, 1.0]]
21
+ },
22
+ "properties": {
23
+ "color": "red",
24
+ "prop1": 0.0
25
+ }
26
+ },
27
+
28
+ {
29
+ "type": "Feature",
30
+ "geometry": {
31
+ "type": "Polygon",
32
+ "coordinates": [[[100.0, 0.0], [101.0, 0.0], [101.0, 1.0], [100.0, 1.0], [100.0, 0.0]]]
33
+ },
34
+ "properties": {
35
+ "color": "green",
36
+ "prop1": {
37
+ "this": "that"
38
+ }
39
+ }
40
+ },
41
+
42
+ {
43
+ "type": "Feature",
44
+ "geometry": {
45
+ "type": "MultiPolygon",
46
+ "coordinates": [[[[100.0, 1.5], [100.5, 1.5], [100.5, 2.0], [100.0, 2.0], [100.0, 1.5]]], [[[100.5, 2.0], [100.5, 2.5], [101.0, 2.5], [101.0, 2.0], [100.5, 2.0]]]]
47
+ },
48
+ "properties": {
49
+ "color": "purple"
50
+ }
51
+ }
52
+ ]
53
+ };
node_modules/leaflet.markercluster/example/geojson.html ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+
19
+ <script type="text/javascript">
20
+
21
+ var geoJsonData = {
22
+ "type": "FeatureCollection",
23
+ "features": [
24
+ { "type": "Feature", "id":"1", "properties": { "address": "2" }, "geometry": { "type": "Point", "coordinates": [175.2209316333,-37.8210922667 ] } },
25
+ { "type": "Feature", "id":"2", "properties": { "address": "151" }, "geometry": { "type": "Point", "coordinates": [175.2238417833,-37.80975435 ] } },
26
+ { "type": "Feature", "id":"3", "properties": { "address": "21" }, "geometry": { "type": "Point", "coordinates": [175.2169955667,-37.818193 ] } },
27
+ { "type": "Feature", "id":"4", "properties": { "address": "14" }, "geometry": { "type": "Point", "coordinates": [175.2240856667,-37.8216963 ] } },
28
+ { "type": "Feature", "id":"5", "properties": { "address": "38B" }, "geometry": { "type": "Point", "coordinates": [175.2196982333,-37.8188702167 ] } },
29
+ { "type": "Feature", "id":"6", "properties": { "address": "38" }, "geometry": { "type": "Point", "coordinates": [175.2209942 ,-37.8192782833 ] } }
30
+ ]
31
+ };
32
+
33
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
34
+ maxZoom: 18,
35
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
36
+ });
37
+
38
+ var map = L.map('map')
39
+ .addLayer(tiles);
40
+
41
+ var markers = L.markerClusterGroup();
42
+
43
+ var geoJsonLayer = L.geoJson(geoJsonData, {
44
+ onEachFeature: function (feature, layer) {
45
+ layer.bindPopup(feature.properties.address);
46
+ }
47
+ });
48
+ markers.addLayer(geoJsonLayer);
49
+
50
+ map.addLayer(markers);
51
+ map.fitBounds(markers.getBounds());
52
+ </script>
53
+ </body>
54
+ </html>
node_modules/leaflet.markercluster/example/map.png ADDED
node_modules/leaflet.markercluster/example/marker-clustering-convexhull.html ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="populate">Populate 1 marker</button>
19
+ <button id="remove">Remove 1 marker</button>
20
+
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = L.latLng(50.5, 30.51);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
30
+
31
+ var markers = L.markerClusterGroup({ spiderfyOnMaxZoom: false, showCoverageOnHover: false, zoomToBoundsOnClick: false });
32
+
33
+ function populate() {
34
+ for (var i = 0; i < 100; i++) {
35
+ var m = L.marker(getRandomLatLng(map));
36
+ markers.addLayer(m);
37
+ }
38
+ return false;
39
+ }
40
+ function getRandomLatLng(map) {
41
+ var bounds = map.getBounds(),
42
+ southWest = bounds.getSouthWest(),
43
+ northEast = bounds.getNorthEast(),
44
+ lngSpan = northEast.lng - southWest.lng,
45
+ latSpan = northEast.lat - southWest.lat;
46
+
47
+ return L.latLng(
48
+ southWest.lat + latSpan * Math.random(),
49
+ southWest.lng + lngSpan * Math.random());
50
+ }
51
+
52
+
53
+ var polygon;
54
+ markers.on('clustermouseover', function (a) {
55
+ if (polygon) {
56
+ map.removeLayer(polygon);
57
+ }
58
+ polygon = L.polygon(a.layer.getConvexHull());
59
+ map.addLayer(polygon);
60
+ });
61
+
62
+ markers.on('clustermouseout', function (a) {
63
+ if (polygon) {
64
+ map.removeLayer(polygon);
65
+ polygon = null;
66
+ }
67
+ });
68
+
69
+ map.on('zoomend', function () {
70
+ if (polygon) {
71
+ map.removeLayer(polygon);
72
+ polygon = null;
73
+ }
74
+ });
75
+
76
+
77
+ populate();
78
+ map.addLayer(markers);
79
+ </script>
80
+ </body>
81
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-custom.html ADDED
@@ -0,0 +1,114 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <script src="../dist/leaflet.markercluster-src.js"></script>
13
+
14
+ <style>
15
+ .mycluster {
16
+ width: 40px;
17
+ height: 40px;
18
+ background-color: greenyellow;
19
+ text-align: center;
20
+ font-size: 24px;
21
+ }
22
+
23
+ </style>
24
+ </head>
25
+ <body>
26
+
27
+ <div id="map"></div>
28
+
29
+ <script type="text/javascript">
30
+
31
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
32
+ maxZoom: 18,
33
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
34
+ }),
35
+ latlng = L.latLng(50.5, 30.51);
36
+
37
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
38
+
39
+
40
+ //Custom radius and icon create function
41
+ var markers = L.markerClusterGroup({
42
+ maxClusterRadius: 120,
43
+ iconCreateFunction: function (cluster) {
44
+ var markers = cluster.getAllChildMarkers();
45
+ var n = 0;
46
+ for (var i = 0; i < markers.length; i++) {
47
+ n += markers[i].number;
48
+ }
49
+ return L.divIcon({ html: n, className: 'mycluster', iconSize: L.point(40, 40) });
50
+ },
51
+ //Disable all of the defaults:
52
+ spiderfyOnMaxZoom: false, showCoverageOnHover: false, zoomToBoundsOnClick: false
53
+ });
54
+
55
+
56
+ function populate() {
57
+ for (var i = 0; i < 100; i++) {
58
+ var m = L.marker(getRandomLatLng(map), { title: i });
59
+ m.number = i;
60
+ markers.addLayer(m);
61
+ }
62
+ return false;
63
+ }
64
+ function populateRandomVector() {
65
+ for (var i = 0, latlngs = [], len = 20; i < len; i++) {
66
+ latlngs.push(getRandomLatLng(map));
67
+ }
68
+ var path = L.polyline(latlngs);
69
+ map.addLayer(path);
70
+ }
71
+ function getRandomLatLng(map) {
72
+ var bounds = map.getBounds(),
73
+ southWest = bounds.getSouthWest(),
74
+ northEast = bounds.getNorthEast(),
75
+ lngSpan = northEast.lng - southWest.lng,
76
+ latSpan = northEast.lat - southWest.lat;
77
+
78
+ return L.latLng(
79
+ southWest.lat + latSpan * Math.random(),
80
+ southWest.lng + lngSpan * Math.random());
81
+ }
82
+
83
+ populate();
84
+ map.addLayer(markers);
85
+
86
+
87
+
88
+ var shownLayer, polygon;
89
+
90
+ function removePolygon() {
91
+ if (shownLayer) {
92
+ shownLayer.setOpacity(1);
93
+ shownLayer = null;
94
+ }
95
+ if (polygon) {
96
+ map.removeLayer(polygon);
97
+ polygon = null;
98
+ }
99
+ };
100
+
101
+ markers.on('clustermouseover', function (a) {
102
+ removePolygon();
103
+
104
+ a.layer.setOpacity(0.2);
105
+ shownLayer = a.layer;
106
+ polygon = L.polygon(a.layer.getConvexHull());
107
+ map.addLayer(polygon);
108
+ });
109
+ markers.on('clustermouseout', removePolygon);
110
+ map.on('zoomend', removePolygon);
111
+
112
+ </script>
113
+ </body>
114
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-dragging.html ADDED
@@ -0,0 +1,83 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="moveone">Move a random marker</button>
19
+
20
+ <script type="text/javascript">
21
+
22
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
23
+ maxZoom: 18,
24
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
25
+ }),
26
+ latlng = new L.LatLng(50.5, 30.51);
27
+
28
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
29
+
30
+ var markers = new L.MarkerClusterGroup();
31
+ var markersList = [];
32
+
33
+ function populate() {
34
+ for (var i = 0; i < 100; i++) {
35
+ var m = new L.Marker(getRandomLatLng(map), { draggable: true });
36
+ markersList.push(m);
37
+ markers.addLayer(m);
38
+ }
39
+ return false;
40
+ }
41
+ function populateRandomVector() {
42
+ for (var i = 0, latlngs = [], len = 20; i < len; i++) {
43
+ latlngs.push(getRandomLatLng(map));
44
+ }
45
+ var path = new L.Polyline(latlngs);
46
+ map.addLayer(path);
47
+ }
48
+ function getRandomLatLng(map) {
49
+ var bounds = map.getBounds(),
50
+ southWest = bounds.getSouthWest(),
51
+ northEast = bounds.getNorthEast(),
52
+ lngSpan = northEast.lng - southWest.lng,
53
+ latSpan = northEast.lat - southWest.lat;
54
+
55
+ return new L.LatLng(
56
+ southWest.lat + latSpan * Math.random(),
57
+ southWest.lng + lngSpan * Math.random());
58
+ }
59
+
60
+ markers.on('clusterclick', function (a) {
61
+ alert('cluster ' + a.layer.getAllChildMarkers().length);
62
+ });
63
+ markers.on('click', function (a) {
64
+ alert('marker ' + a.layer);
65
+ });
66
+
67
+ populate();
68
+ map.addLayer(markers);
69
+
70
+ L.DomUtil.get('moveone').onclick = function () {
71
+ var m = markersList[Math.floor(Math.random() * markersList.length)];
72
+ var bounds = map.getBounds(),
73
+ southWest = bounds.getSouthWest(),
74
+ northEast = bounds.getNorthEast(),
75
+ lngSpan = northEast.lng - southWest.lng,
76
+ latSpan = northEast.lat - southWest.lat;
77
+ m.setLatLng(new L.LatLng(
78
+ southWest.lat + latSpan * 0.5,
79
+ southWest.lng + lngSpan * 0.5));
80
+ };
81
+ </script>
82
+ </body>
83
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-everything.html ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="populate">Populate 1 marker</button>
19
+ <button id="remove">Remove 1 marker</button>
20
+ <span>Mouse over a cluster to see the bounds of its children and click a cluster to zoom to those bounds</span>
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = L.latLng(50.5, 30.51);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
30
+
31
+ var markers = L.markerClusterGroup({ animateAddingMarkers : true });
32
+ var markersList = [];
33
+
34
+ function populate() {
35
+ for (var i = 0; i < 100; i++) {
36
+ var m = L.marker(getRandomLatLng(map));
37
+ markersList.push(m);
38
+ markers.addLayer(m);
39
+ }
40
+ return false;
41
+ }
42
+ function getRandomLatLng(map) {
43
+ var bounds = map.getBounds(),
44
+ southWest = bounds.getSouthWest(),
45
+ northEast = bounds.getNorthEast(),
46
+ lngSpan = northEast.lng - southWest.lng,
47
+ latSpan = northEast.lat - southWest.lat;
48
+
49
+ return L.latLng(
50
+ southWest.lat + latSpan * Math.random(),
51
+ southWest.lng + lngSpan * Math.random());
52
+ }
53
+
54
+ populate();
55
+ map.addLayer(markers);
56
+
57
+ for (var i = 0; i < 100; i++) {
58
+ markers.addLayer(markersList[i]);
59
+ }
60
+
61
+ //Ugly add/remove code
62
+ L.DomUtil.get('populate').onclick = function () {
63
+ var bounds = map.getBounds(),
64
+ southWest = bounds.getSouthWest(),
65
+ northEast = bounds.getNorthEast(),
66
+ lngSpan = northEast.lng - southWest.lng,
67
+ latSpan = northEast.lat - southWest.lat;
68
+ var m = L.marker([
69
+ southWest.lat + latSpan * 0.5,
70
+ southWest.lng + lngSpan * 0.5]);
71
+ markersList.push(m);
72
+ markers.addLayer(m);
73
+ };
74
+ L.DomUtil.get('remove').onclick = function () {
75
+ markers.removeLayer(markersList.pop());
76
+ };
77
+
78
+ </script>
79
+ </body>
80
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-geojson.html ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ <script type="text/javascript" src="geojson-sample.js"></script>
15
+
16
+ </head>
17
+ <body>
18
+
19
+ <div id="map"></div>
20
+ <span>Mouse over a cluster to see the bounds of its children and click a cluster to zoom to those bounds</span>
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = L.latLng(0.78, 102.37);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 7, layers: [tiles]});
30
+
31
+
32
+ var geojson = L.geoJson(geojsonSample, {
33
+
34
+ style: function (feature) {
35
+ return {color: feature.properties.color};
36
+ },
37
+
38
+ onEachFeature: function (feature, layer) {
39
+ var popupText = 'geometry type: ' + feature.geometry.type;
40
+
41
+ if (feature.properties.color) {
42
+ popupText += '<br/>color: ' + feature.properties.color;
43
+ }
44
+
45
+ layer.bindPopup(popupText);
46
+ }
47
+ });
48
+
49
+ geojson.addLayer(new L.Marker(new L.LatLng(2.745530718801952, 105.194091796875)));
50
+
51
+ var eye1 = new L.Marker(new L.LatLng(-0.7250783020332547, 101.8212890625));
52
+ var eye2 = new L.Marker(new L.LatLng(-0.7360637370492077, 103.2275390625));
53
+ var nose = new L.Marker(new L.LatLng(-1.3292264529974207, 102.5463867187));
54
+ var mouth = new L.Polyline([
55
+ new L.LatLng(-1.3841426927920029, 101.7333984375),
56
+ new L.LatLng(-1.6037944300589726, 101.964111328125),
57
+ new L.LatLng(-1.6806671337507222, 102.249755859375),
58
+ new L.LatLng(-1.7355743631421197, 102.67822265625),
59
+ new L.LatLng(-1.5928123762763, 103.0078125),
60
+ new L.LatLng(-1.3292264529974207, 103.3154296875)
61
+ ]);
62
+
63
+ var markers = L.markerClusterGroup();
64
+ markers.addLayer(geojson).addLayers([eye1,eye2,nose,mouth]);
65
+
66
+ map.addLayer(markers);
67
+
68
+ </script>
69
+ </body>
70
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-pane.html ADDED
@@ -0,0 +1,104 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <script src="../dist/leaflet.markercluster-src.js"></script>
13
+
14
+ <style>
15
+ .myclusterA {
16
+ width: 40px;
17
+ height: 40px;
18
+ background-color: greenyellow;
19
+ text-align: center;
20
+ font-size: 24px;
21
+ }
22
+ .myclusterB {
23
+ width: 40px;
24
+ height: 40px;
25
+ background-color: red;
26
+ text-align: center;
27
+ font-size: 24px;
28
+ }
29
+
30
+ </style>
31
+ </head>
32
+ <body>
33
+
34
+ <div id="map"></div>
35
+
36
+ <script type="text/javascript">
37
+
38
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
39
+ maxZoom: 18,
40
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
41
+ }),
42
+ latlng = L.latLng(50.5, 30.51);
43
+
44
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
45
+
46
+ //Define a pane above the default markerPane
47
+ map.createPane('paneB').style.zIndex = 610;
48
+
49
+ //Create two markerClusterGroups, one in the default markerPane, one in our custom pane
50
+ var markersA = createMarkerClusterGroup('myclusterA');
51
+ var markersB = createMarkerClusterGroup('myclusterB', 'paneB');
52
+
53
+ function createMarkerClusterGroup(className, pane) {
54
+ var options = {
55
+ maxClusterRadius: 120,
56
+ iconCreateFunction: function (cluster) {
57
+ var markers = cluster.getAllChildMarkers();
58
+ var n = 0;
59
+ for (var i = 0; i < markers.length; i++) {
60
+ n += markers[i].number;
61
+ }
62
+ return L.divIcon({ html: n, className: className, iconSize: L.point(40, 40) });
63
+ },
64
+ //Disable all of the defaults & specify the pane:
65
+ spiderfyOnMaxZoom: false,
66
+ showCoverageOnHover: false,
67
+ zoomToBoundsOnClick: false
68
+ };
69
+ if (pane) {
70
+ options.clusterPane = pane;
71
+ }
72
+ var mcg = L.markerClusterGroup(options);
73
+ return(mcg);
74
+ }
75
+
76
+ function populate(markers) {
77
+ for (var i = 0; i < 100; i++) {
78
+ var m = L.marker(getRandomLatLng(map), { title: i });
79
+ m.number = i;
80
+ markers.addLayer(m);
81
+ }
82
+ return false;
83
+ }
84
+
85
+ function getRandomLatLng(map) {
86
+ var bounds = map.getBounds(),
87
+ southWest = bounds.getSouthWest(),
88
+ northEast = bounds.getNorthEast(),
89
+ lngSpan = northEast.lng - southWest.lng,
90
+ latSpan = northEast.lat - southWest.lat;
91
+
92
+ return L.latLng(
93
+ southWest.lat + latSpan * Math.random(),
94
+ southWest.lng + lngSpan * Math.random());
95
+ }
96
+
97
+ populate(markersA);
98
+ populate(markersB);
99
+ map.addLayer(markersA);
100
+ map.addLayer(markersB);
101
+
102
+ </script>
103
+ </body>
104
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-realworld-maxzoom.388.html ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ <script src="realworld.388.js"></script>
15
+
16
+ </head>
17
+ <body>
18
+
19
+ <div id="map"></div>
20
+ <span>Markers will show on the bottom 2 zoom levels even though the markers would normally cluster.</span>
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
26
+ }),
27
+ latlng = L.latLng(-37.82, 175.24);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 13, layers: [tiles]});
30
+
31
+ var markers = L.markerClusterGroup({ disableClusteringAtZoom: 17 });
32
+
33
+ for (var i = 0; i < addressPoints.length; i++) {
34
+ var a = addressPoints[i];
35
+ var title = a[2];
36
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
37
+ marker.bindPopup(title);
38
+ markers.addLayer(marker);
39
+ }
40
+
41
+ map.addLayer(markers);
42
+
43
+ </script>
44
+ </body>
45
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-realworld-mobile.388.html ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
9
+ <link rel="stylesheet" href="mobile.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ <script src="realworld.388.js"></script>
15
+ </head>
16
+ <body>
17
+
18
+ <div id="map"></div>
19
+
20
+ <script type="text/javascript">
21
+
22
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
23
+ maxZoom: 18,
24
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
25
+ }),
26
+ latlng = L.latLng(-37.821, 175.22);
27
+
28
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
29
+
30
+ var markers = L.markerClusterGroup();
31
+
32
+ for (var i = 0; i < addressPoints.length; i++) {
33
+ var a = addressPoints[i];
34
+ var title = a[2];
35
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
36
+ marker.bindPopup(title);
37
+ markers.addLayer(marker);
38
+ }
39
+
40
+ map.addLayer(markers);
41
+
42
+ </script>
43
+ </body>
44
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-realworld.10000.html ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+
15
+ <script src="realworld.10000.js"></script>
16
+
17
+ </head>
18
+ <body>
19
+
20
+ <div id="map"></div>
21
+ <span>Mouse over a cluster to see the bounds of its children and click a cluster to zoom to those bounds</span>
22
+ <script type="text/javascript">
23
+
24
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
25
+ maxZoom: 18,
26
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
27
+ }),
28
+ latlng = L.latLng(-37.89, 175.46);
29
+
30
+ var map = L.map('map', {center: latlng, zoom: 13, layers: [tiles]});
31
+
32
+ var markers = L.markerClusterGroup({ chunkedLoading: true });
33
+
34
+ for (var i = 0; i < addressPoints.length; i++) {
35
+ var a = addressPoints[i];
36
+ var title = a[2];
37
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
38
+ marker.bindPopup(title);
39
+ markers.addLayer(marker);
40
+ }
41
+
42
+ map.addLayer(markers);
43
+
44
+ </script>
45
+ </body>
46
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-realworld.388.html ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ <script src="realworld.388.js"></script>
15
+
16
+ </head>
17
+ <body>
18
+
19
+ <div id="map"></div>
20
+ <span>Mouse over a cluster to see the bounds of its children and click a cluster to zoom to those bounds</span>
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
26
+ }),
27
+ latlng = L.latLng(-37.82, 175.24);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 13, layers: [tiles]});
30
+
31
+ var markers = L.markerClusterGroup();
32
+
33
+ for (var i = 0; i < addressPoints.length; i++) {
34
+ var a = addressPoints[i];
35
+ var title = a[2];
36
+ var marker = L.marker(new L.LatLng(a[0], a[1]), { title: title });
37
+ marker.bindPopup(title);
38
+ markers.addLayer(marker);
39
+ }
40
+
41
+ map.addLayer(markers);
42
+
43
+ </script>
44
+ </body>
45
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-realworld.50000.html ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+
15
+ <script src="realworld.50000.1.js"></script>
16
+ <script src="realworld.50000.2.js"></script>
17
+
18
+ </head>
19
+ <body>
20
+
21
+ <div id="progress"><div id="progress-bar"></div></div>
22
+ <div id="map"></div>
23
+ <span>Mouse over a cluster to see the bounds of its children and click a cluster to zoom to those bounds</span>
24
+ <script type="text/javascript">
25
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
26
+ maxZoom: 18,
27
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Points &copy 2012 LINZ'
28
+ }),
29
+ latlng = L.latLng(-37.79, 175.27);
30
+
31
+ var map = L.map('map', { center: latlng, zoom: 13, layers: [tiles] });
32
+
33
+ var progress = document.getElementById('progress');
34
+ var progressBar = document.getElementById('progress-bar');
35
+
36
+ function updateProgressBar(processed, total, elapsed, layersArray) {
37
+ if (elapsed > 1000) {
38
+ // if it takes more than a second to load, display the progress bar:
39
+ progress.style.display = 'block';
40
+ progressBar.style.width = Math.round(processed/total*100) + '%';
41
+ }
42
+
43
+ if (processed === total) {
44
+ // all markers processed - hide the progress bar:
45
+ progress.style.display = 'none';
46
+ }
47
+ }
48
+
49
+ var markers = L.markerClusterGroup({ chunkedLoading: true, chunkProgress: updateProgressBar });
50
+
51
+ var markerList = [];
52
+
53
+ //console.log('start creating markers: ' + window.performance.now());
54
+
55
+ for (var i = 0; i < addressPoints.length; i++) {
56
+ var a = addressPoints[i];
57
+ var title = a[2];
58
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
59
+ marker.bindPopup(title);
60
+ markerList.push(marker);
61
+ }
62
+ for (var i = 0; i < addressPoints2.length; i++) {
63
+ var a = addressPoints2[i];
64
+ var title = a[2];
65
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
66
+ marker.bindPopup(title);
67
+ markerList.push(marker);
68
+ }
69
+
70
+ //console.log('start clustering: ' + window.performance.now());
71
+
72
+ markers.addLayers(markerList);
73
+ map.addLayer(markers);
74
+
75
+ //console.log('end clustering: ' + window.performance.now());
76
+ </script>
77
+ </body>
78
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-singlemarkermode.html ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <span>Click a cluster to zoom to its bounds</span>
19
+
20
+ <script type="text/javascript">
21
+
22
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
23
+ maxZoom: 18,
24
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
25
+ }),
26
+ latlng = L.latLng(50.5, 30.51);
27
+
28
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
29
+
30
+ var markers = L.markerClusterGroup({ singleMarkerMode: true});
31
+
32
+ function populate() {
33
+ for (var i = 0; i < 100; i++) {
34
+ var m = L.marker(getRandomLatLng(map));
35
+ markers.addLayer(m);
36
+ }
37
+ return false;
38
+ }
39
+ function getRandomLatLng(map) {
40
+ var bounds = map.getBounds(),
41
+ southWest = bounds.getSouthWest(),
42
+ northEast = bounds.getNorthEast(),
43
+ lngSpan = northEast.lng - southWest.lng,
44
+ latSpan = northEast.lat - southWest.lat;
45
+
46
+ return L.latLng(
47
+ southWest.lat + latSpan * Math.random(),
48
+ southWest.lng + lngSpan * Math.random());
49
+ }
50
+
51
+ markers.on('clusterclick', function (a) {
52
+ a.layer.zoomToBounds();
53
+ });
54
+
55
+ populate();
56
+ map.addLayer(markers);
57
+
58
+ </script>
59
+ </body>
60
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-spiderfier.html ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="populate">Populate 1 marker</button>
19
+ <button id="remove">Remove 1 marker</button>
20
+
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = L.latLng(50.5, 30.51);
28
+
29
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
30
+
31
+ var markers = L.markerClusterGroup({ spiderfyOnMaxZoom: false, showCoverageOnHover: false, zoomToBoundsOnClick: false });
32
+
33
+ function populate() {
34
+ for (var i = 0; i < 100; i++) {
35
+ var m = L.marker(getRandomLatLng(map));
36
+ markers.addLayer(m);
37
+ }
38
+ return false;
39
+ }
40
+ function getRandomLatLng(map) {
41
+ var bounds = map.getBounds(),
42
+ southWest = bounds.getSouthWest(),
43
+ northEast = bounds.getNorthEast(),
44
+ lngSpan = northEast.lng - southWest.lng,
45
+ latSpan = northEast.lat - southWest.lat;
46
+
47
+ return L.latLng(
48
+ southWest.lat + latSpan * Math.random(),
49
+ southWest.lng + lngSpan * Math.random());
50
+ }
51
+
52
+ markers.on('clusterclick', function (a) {
53
+ a.layer.spiderfy();
54
+ });
55
+
56
+ populate();
57
+ map.addLayer(markers);
58
+ </script>
59
+ </body>
60
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-zoomtobounds.html ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <span>Click a cluster to zoom to its bounds</span>
19
+
20
+ <script type="text/javascript">
21
+
22
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
23
+ maxZoom: 18,
24
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
25
+ }),
26
+ latlng = L.latLng(50.5, 30.51);
27
+
28
+ var map = L.map('map', {center: latlng, zoom: 15, layers: [tiles]});
29
+
30
+ var markers = L.markerClusterGroup({spiderfyOnMaxZoom: false, showCoverageOnHover: false, zoomToBoundsOnClick: false});
31
+
32
+ function populate() {
33
+ for (var i = 0; i < 100; i++) {
34
+ var m = L.marker(getRandomLatLng(map));
35
+ markers.addLayer(m);
36
+ }
37
+ return false;
38
+ }
39
+ function getRandomLatLng(map) {
40
+ var bounds = map.getBounds(),
41
+ southWest = bounds.getSouthWest(),
42
+ northEast = bounds.getNorthEast(),
43
+ lngSpan = northEast.lng - southWest.lng,
44
+ latSpan = northEast.lat - southWest.lat;
45
+
46
+ return L.latLng(
47
+ southWest.lat + latSpan * Math.random(),
48
+ southWest.lng + lngSpan * Math.random());
49
+ }
50
+
51
+ markers.on('clusterclick', function (a) {
52
+ a.layer.zoomToBounds();
53
+ });
54
+
55
+ populate();
56
+ map.addLayer(markers);
57
+
58
+ </script>
59
+ </body>
60
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering-zoomtoshowlayer.html ADDED
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ <script src="realworld.388.js"></script>
15
+
16
+ </head>
17
+ <body>
18
+
19
+ <div id="map"></div>
20
+ <button id="doit">Zoom to marker</button>
21
+ <span>When clicked we will zoom down to a marker, spiderfying if required to show it and then open its popup</span>
22
+ <script type="text/javascript">
23
+
24
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
25
+ maxZoom: 18,
26
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
27
+ }),
28
+ latlng = L.latLng(-37.82, 175.24);
29
+
30
+ var map = L.map('map', {center: latlng, zoom: 13, layers: [tiles]});
31
+
32
+ var markers = L.markerClusterGroup();
33
+ var markerList = [];
34
+
35
+ function populate() {
36
+ for (var i = 0; i < addressPoints.length; i++) {
37
+ var a = addressPoints[i];
38
+ var title = a[2];
39
+ var marker = L.marker(L.latLng(a[0], a[1]), { title: title });
40
+ marker.bindPopup(title);
41
+ markers.addLayer(marker);
42
+ markerList.push(marker);
43
+ }
44
+ }
45
+
46
+ populate();
47
+
48
+ map.addLayer(markers);
49
+
50
+ document.getElementById('doit').onclick = function () {
51
+ var m = markerList[Math.floor(Math.random() * markerList.length)];
52
+ markers.zoomToShowLayer(m, function () {
53
+ m.openPopup();
54
+ });
55
+ };
56
+
57
+ </script>
58
+ </body>
59
+ </html>
node_modules/leaflet.markercluster/example/marker-clustering.html ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="populate">Populate 1 marker</button>
19
+ <button id="remove">Remove 1 marker</button>
20
+
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 18,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = new L.LatLng(50.5, 30.51);
28
+
29
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
30
+
31
+ var markers = new L.MarkerClusterGroup();
32
+ var markersList = [];
33
+
34
+ function populate() {
35
+ for (var i = 0; i < 100; i++) {
36
+ var m = new L.Marker(getRandomLatLng(map));
37
+ markersList.push(m);
38
+ markers.addLayer(m);
39
+ }
40
+ return false;
41
+ }
42
+ function populateRandomVector() {
43
+ for (var i = 0, latlngs = [], len = 20; i < len; i++) {
44
+ latlngs.push(getRandomLatLng(map));
45
+ }
46
+ var path = new L.Polyline(latlngs);
47
+ map.addLayer(path);
48
+ }
49
+ function getRandomLatLng(map) {
50
+ var bounds = map.getBounds(),
51
+ southWest = bounds.getSouthWest(),
52
+ northEast = bounds.getNorthEast(),
53
+ lngSpan = northEast.lng - southWest.lng,
54
+ latSpan = northEast.lat - southWest.lat;
55
+
56
+ return new L.LatLng(
57
+ southWest.lat + latSpan * Math.random(),
58
+ southWest.lng + lngSpan * Math.random());
59
+ }
60
+
61
+ markers.on('clusterclick', function (a) {
62
+ alert('cluster ' + a.layer.getAllChildMarkers().length);
63
+ });
64
+ markers.on('click', function (a) {
65
+ alert('marker ' + a.layer);
66
+ });
67
+
68
+ populate();
69
+ map.addLayer(markers);
70
+
71
+ L.DomUtil.get('populate').onclick = function () {
72
+ var bounds = map.getBounds(),
73
+ southWest = bounds.getSouthWest(),
74
+ northEast = bounds.getNorthEast(),
75
+ lngSpan = northEast.lng - southWest.lng,
76
+ latSpan = northEast.lat - southWest.lat;
77
+ var m = new L.Marker(new L.LatLng(
78
+ southWest.lat + latSpan * 0.5,
79
+ southWest.lng + lngSpan * 0.5));
80
+ markersList.push(m);
81
+ markers.addLayer(m);
82
+ };
83
+ L.DomUtil.get('remove').onclick = function () {
84
+ markers.removeLayer(markersList.pop());
85
+ };
86
+ </script>
87
+ </body>
88
+ </html>
node_modules/leaflet.markercluster/example/mobile.css ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ html, body, #map {
2
+ margin: 0;
3
+ padding: 0;
4
+ width: 100%;
5
+ height: 100%;
6
+ }
node_modules/leaflet.markercluster/example/old-bugs/add-1000-after.html ADDED
@@ -0,0 +1,83 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">Add 1000 Markers</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/51">#51</a>. Click the button. It will add 1000 markers to the map. this should be fast, but previously in (non-IE browsers) it was very slow.</span><br/>
24
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/43">#43</a>. Improving performance more.</span><br/>
25
+ <span id="time"></span>
26
+ <script type="text/javascript">
27
+
28
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
29
+ maxZoom: 18,
30
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
31
+ }),
32
+ latlng = new L.LatLng(50.5, 30.51);
33
+
34
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
35
+
36
+ var markers = new L.MarkerClusterGroup();
37
+ var markersList = [];
38
+
39
+ function getRandomLatLng(map) {
40
+ var bounds = map.getBounds(),
41
+ southWest = bounds.getSouthWest(),
42
+ northEast = bounds.getNorthEast(),
43
+ lngSpan = northEast.lng - southWest.lng,
44
+ latSpan = northEast.lat - southWest.lat;
45
+
46
+ return new L.LatLng(
47
+ southWest.lat + latSpan * Math.random(),
48
+ southWest.lng + lngSpan * Math.random());
49
+ }
50
+
51
+ function populate(length) {
52
+ var prestart = +new Date();
53
+ var list = [], i;
54
+ for (i = 0; i < length; i++) {
55
+ var m = new L.Marker(getRandomLatLng(map));
56
+ list.push(m);
57
+ }
58
+
59
+ var start = +new Date();
60
+
61
+ markers.addLayers(list);
62
+
63
+ var end = +new Date();
64
+
65
+ document.getElementById('time').innerHTML = 'Creating 1000 markers took: ' + (start - prestart) + 'ms . Appending 1000 markers took: ' + (end - start) + 'ms';
66
+
67
+ return false;
68
+ }
69
+
70
+ populate(1000);
71
+ var start = +new Date();
72
+ map.addLayer(markers);
73
+ var end = +new Date();
74
+ document.getElementById('time').innerHTML += ' . Adding to map took: ' + (end - start) + 'ms';
75
+
76
+ //Ugly add/remove code
77
+ L.DomUtil.get('doit').onclick = function () {
78
+ populate(1000);
79
+ };
80
+
81
+ </script>
82
+ </body>
83
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/add-markers-offscreen.html ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="populate">Populate 1 marker</button>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/69">#69</a>. Click the button 2+ times. Zoom out. Should just be a single cluster but instead one of the child markers is still visible.</span><br/>
24
+ <script type="text/javascript">
25
+
26
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
27
+ maxZoom: 18,
28
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
29
+ }),
30
+ latlng = new L.LatLng(50.5, 30.51);
31
+
32
+ var map = new L.Map('map', {center: new L.LatLng(50.41, 30.51), zoom: 17, layers: [tiles]});
33
+
34
+ var markers = new L.MarkerClusterGroup({ animateAddingMarkers : true });
35
+ var markersList = [];
36
+
37
+ function populate() {
38
+ var m = new L.Marker(latlng);
39
+ markersList.push(m);
40
+ markers.addLayer(m);
41
+ return false;
42
+ }
43
+
44
+ map.addLayer(markers);
45
+
46
+ //Ugly add/remove code
47
+ L.DomUtil.get('populate').onclick = function () {
48
+ populate();
49
+ };
50
+ </script>
51
+ </body>
52
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/add-remove-before-addtomap.html ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/64">#64</a>. Nothing should appear on the map.</span><br/>
23
+ <span id="time"></span>
24
+ <script type="text/javascript">
25
+
26
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
27
+ maxZoom: 18,
28
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
29
+ }),
30
+ latlng = new L.LatLng(50.5, 30.51);
31
+
32
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
33
+
34
+ var markers = new L.MarkerClusterGroup();
35
+
36
+ function getRandomLatLng(map) {
37
+ var bounds = map.getBounds(),
38
+ southWest = bounds.getSouthWest(),
39
+ northEast = bounds.getNorthEast(),
40
+ lngSpan = northEast.lng - southWest.lng,
41
+ latSpan = northEast.lat - southWest.lat;
42
+
43
+ return new L.LatLng(
44
+ southWest.lat + latSpan * Math.random(),
45
+ southWest.lng + lngSpan * Math.random());
46
+ }
47
+
48
+ function populate(length) {
49
+ var list = [], i;
50
+ for (i = 0; i < length; i++) {
51
+ var m = new L.Marker(getRandomLatLng(map));
52
+ markers.addLayer(m);
53
+ markers.removeLayer(m);
54
+ }
55
+ }
56
+
57
+ populate(1000);
58
+ map.addLayer(markers);
59
+
60
+ </script>
61
+ </body>
62
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/animationless-zoom.html ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">Zoom in</button><br/>
23
+ <span>Bug <a href="https://github.com/leaflet/Leaflet.markercluster/issues/216">#216</a>. Click the button. It will zoom in, leaflet will not do an animation for the zoom. A marker should be visible.</span><br/>
24
+ <span id="time"></span>
25
+ <script type="text/javascript">
26
+
27
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
28
+ maxZoom: 18,
29
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
30
+ }),
31
+ latlng = new L.LatLng(-37.36142550190516, 174.254150390625);
32
+
33
+ var map = new L.Map('map', {center: latlng, zoom: 7, layers: [tiles]});
34
+
35
+ var markers = new L.MarkerClusterGroup();
36
+ markers.addLayer(new L.Marker([-37.77852090603777, 175.3103667497635])); //The one we zoom in on
37
+ markers.addLayer(new L.Marker([-37.711800591811055, 174.50034790039062])); //Marker that we cluster with at the top zoom level, but not 1 level down
38
+ map.addLayer(markers);
39
+
40
+ //Ugly add/remove code
41
+ L.DomUtil.get('doit').onclick = function () {
42
+ map.setView([-37.77852090603777, 175.3103667497635], 15);
43
+ };
44
+
45
+ </script>
46
+ </body>
47
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/click-cluster-at-screen-edge.html ADDED
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <span>Bug <a href="https://github.com/leaflet/Leaflet.markercluster/issues/344">#344</a>. Click the cluster at the screen edge. Map will zoom to it and its markers will appear, but it will not disappear.</span><br/>
23
+ <span id="time"></span>
24
+ <script type="text/javascript">
25
+
26
+ var iconCreateFunction = function (cluster) {
27
+ var childCount = cluster.getChildCount();
28
+
29
+ var c = ' marker-cluster-';
30
+ if (childCount < 10) {
31
+ c += 'small';
32
+ } else if (childCount < 100) {
33
+ c += 'medium';
34
+ } else {
35
+ c += 'large';
36
+ }
37
+
38
+ return new L.DivIcon({ html: '<div><span>' + childCount + '</span></div>', className: 'marker-cluster' + c, iconSize: new L.Point(270, 270) });
39
+ };
40
+
41
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
42
+ maxZoom: 18,
43
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
44
+ }),
45
+ latlng = new L.LatLng(54.18815548107151, 6.1083984375);
46
+
47
+ var map = new L.Map('map', {center: latlng, zoom: 5, layers: [tiles]});
48
+
49
+ var markers = new L.MarkerClusterGroup({ iconCreateFunction: iconCreateFunction });
50
+ var markersList = [];
51
+
52
+ markers.addLayer(new L.Marker([41.969073, 5]));
53
+ markers.addLayer(new L.Marker([41.969073, 7]));
54
+
55
+ map.addLayer(markers);
56
+
57
+ </script>
58
+ </body>
59
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/disappearing-marker-from-spider.html ADDED
@@ -0,0 +1,106 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body style="font-family: verdana; font-size: 80%;">
16
+
17
+ <div id="map"></div>
18
+ Click on the cluster to <strong>spiderfy</strong> and then <button id="moveTrain">move train</button><br/>
19
+ <br/>
20
+ <div style="color: #888;"><strong>Note:</strong> The marker on the old cluster position comes back on next move or on map scrolling.</div>
21
+
22
+ <script type="text/javascript">
23
+
24
+ var stationJson = {
25
+ "type":"FeatureCollection",
26
+ "features":[
27
+ {"type":"Feature","id":1,"properties":{"type":"station","name":"Appenzell"},"geometry":{"type":"Point","coordinates":[9.40991,47.32849]}},
28
+ {"type":"Feature","id":2,"properties":{"type":"station","name":"Gais"},"geometry":{"type":"Point","coordinates":[9.45107,47.36073]}},
29
+ {"type":"Feature","id":3,"properties":{"type":"station","name":"St. Gallen"},"geometry":{"type":"Point","coordinates":[9.36901,47.42208]}},
30
+ {"type":"Feature","id":4,"properties":{"type":"station","name":"Teufen"},"geometry":{"type":"Point","coordinates":[9.390178,47.390157]}}
31
+ ]};
32
+
33
+ var trainJson = [{
34
+ "type":"FeatureCollection",
35
+ "features":[
36
+ {"type":"Feature","id":10,"properties":{"type":"train","name":"Testtrain"},"geometry":{"type":"Point","coordinates":[9.36901,47.42208]}}
37
+ ]},{
38
+ "type":"FeatureCollection",
39
+ "features":[
40
+ {"type":"Feature","id":10,"properties":{"type":"train","name":"Testtrain"},"geometry":{"type":"Point","coordinates":[9.390178,47.390157]}}
41
+ ]},{
42
+ "type":"FeatureCollection",
43
+ "features":[
44
+ {"type":"Feature","id":10,"properties":{"type":"train","name":"Testtrain"},"geometry":{"type":"Point","coordinates":[9.45107,47.36073]}}
45
+ ]},{
46
+ "type":"FeatureCollection",
47
+ "features":[
48
+ {"type":"Feature","id":10,"properties":{"type":"train","name":"Testtrain"},"geometry":{"type":"Point","coordinates":[9.40991,47.32849]}}
49
+ ]}];
50
+
51
+ var trainPosition = 0,
52
+ trainDirection = 'up';
53
+
54
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
55
+ maxZoom: 18,
56
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
57
+ }),
58
+ map = new L.Map('map', {zoom: 15, layers: [tiles]}),
59
+ markers = new L.MarkerClusterGroup({ spiderfyOnMaxZoom: false, showCoverageOnHover: false, zoomToBoundsOnClick: false });
60
+
61
+ var stationGeoJsonLayer = L.geoJson(stationJson, {
62
+ onEachFeature: function (feature, layer) {
63
+ layer.bindPopup(feature.properties.name);
64
+ }
65
+ }),
66
+ trainGeoJsonLayer = L.geoJson(trainJson[trainPosition], {
67
+ onEachFeature: function (feature, layer) {
68
+ layer.bindPopup(feature.properties.name);
69
+ }
70
+ });
71
+
72
+ // initial load
73
+ markers.addLayer(stationGeoJsonLayer);
74
+ markers.addLayer(trainGeoJsonLayer);
75
+ map.fitBounds(markers.getBounds());
76
+
77
+ markers.on('clusterclick', function (a) {
78
+ a.layer.spiderfy();
79
+ });
80
+
81
+ map.addLayer(markers);
82
+
83
+ /**
84
+ * Demonstration method that simulates that we got a new geoJson object with updated train positions.
85
+ */
86
+ function moveTrain() {
87
+ if (trainDirection == 'up') trainPosition++;
88
+ else if (trainDirection == 'down') trainPosition--;
89
+ if (trainPosition == trainJson.length-1) trainDirection = 'down';
90
+ else if (trainPosition == 0) trainDirection = 'up';
91
+
92
+ // build a new geoJson layer with the new train information
93
+ trainGeoJsonLayer = L.geoJson(trainJson[trainPosition], {});
94
+
95
+ // update the cluster markers with both layers (stations first so that the station marker is always the first on spider.
96
+ markers.clearLayers();
97
+ markers.addLayer(stationGeoJsonLayer);
98
+ markers.addLayer(trainGeoJsonLayer);
99
+ }
100
+
101
+ L.DomUtil.get('moveTrain').onclick = function () {
102
+ moveTrain();
103
+ };
104
+ </script>
105
+ </body>
106
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/doesnt-update-cluster-on-bottom-level.html ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">AddMarker</button><button id="doit2">Add by Timer</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/114">#114</a>. Markers are added to the map periodically using addLayers. Bug was that after becoming a cluster (size 2 or 3 usually) they would never change again even if more markers were added to them.</span><br/>
24
+
25
+ <script type="text/javascript">
26
+
27
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
28
+ maxZoom: 18,
29
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
30
+ }),
31
+ latlng = new L.LatLng(40.782982, -73.969452);
32
+
33
+ var map = new L.Map('map', {
34
+ center: latlng,
35
+ zoom: 12,
36
+ maxZoom: 12,
37
+ layers: [tiles]
38
+ });
39
+
40
+ var markerCluster = new L.MarkerClusterGroup();
41
+ map.addLayer(markerCluster);
42
+
43
+ function getRandomLatLng() {
44
+ return [
45
+ 40.782982 + (Math.random() > 0.5 ? 0.5 : -0.5) * Math.random(),
46
+ -73.969452 + (Math.random() > 0.5 ? 0.5 : -0.5) * Math.random()
47
+ ];
48
+ }
49
+
50
+ document.getElementById('doit').onclick = function () {
51
+ markerCluster.addLayers([new L.Marker(map.getCenter())]);
52
+ };
53
+ document.getElementById('doit2').onclick = function () {
54
+ setInterval(function () {
55
+ var n = 100;
56
+ var markers = new Array();
57
+
58
+ for (var i = 0; i < n; i++) {
59
+ markers.push(L.marker(getRandomLatLng()));
60
+ }
61
+
62
+ markerCluster.addLayers(markers);
63
+
64
+ }, 1000);
65
+ };
66
+
67
+ </script>
68
+ </body>
69
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/drag-with-spiderfying.html ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.3.4/dist/leaflet.css" integrity="sha384-BF7C732iE6WuqJMhUnTNJJLVvW1TIP87P2nMDY7aN2j2EJFWIaqK89j3WlirhFZU" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.3.4/dist/leaflet-src.js" integrity="sha384-oMM5jge511WERo7suehl8Npas4BrPvBEOY54KSP3MygO5gqNxTMKKIcMkS/E9JEX" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../dist/leaflet.markercluster.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <span>Bug <a href="https://github.com/Leaflet/Leaflet.markercluster/issues/907">#907</a>. Drag a marker from a spiderfied cluster over other clusters.</span><br/>
19
+ <span>Bug <a href="https://github.com/Leaflet/Leaflet.markercluster/issues/808">#808</a>. Drag a marker and while dragging zoom out with scroll-wheel.</span><br/>
20
+
21
+ <script type="text/javascript">
22
+
23
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
24
+ maxZoom: 12,
25
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
26
+ }),
27
+ latlng = new L.LatLng(48.85, 2.35);
28
+
29
+ var map = new L.Map('map', {center: latlng, zoom: 12, layers: [tiles]});
30
+
31
+ var mcg = new L.MarkerClusterGroup();
32
+ map.addLayer(mcg);
33
+
34
+ var dragMarker;
35
+ var lastCluster;
36
+ var oldZIndex;
37
+ for (var i = 0; i < 25; i += 1) {
38
+ L.marker(getRandomLatLng(), {
39
+ draggable: true
40
+ }).addTo(mcg).on("dragstart", function(event) {
41
+ oldZIndex = event.target._zIndex;
42
+ event.target.setZIndexOffset(-1000);
43
+ dragMarker = this;
44
+ }).on("dragend", function(event) {
45
+ event.target.setZIndexOffset(oldZIndex);
46
+ dragMarker = null;
47
+ if (lastCluster) {
48
+ lastCluster.unspiderfy();
49
+ }
50
+ lastCluster = null
51
+ });
52
+ }
53
+ mcg.on('clustermouseover', function (event) {
54
+ if (dragMarker && lastCluster !== event.layer) {
55
+ if (lastCluster) {
56
+ mcg.once("unspiderfied", function() { // wait for animation end
57
+ event.layer.spiderfy();
58
+ });
59
+ lastCluster.unspiderfy();
60
+ } else {
61
+ event.layer.spiderfy();
62
+ }
63
+ lastCluster = event.layer;
64
+ }
65
+ });
66
+
67
+ function getRandomLatLng() {
68
+ return [
69
+ 48.8 + 0.1 * Math.random(),
70
+ 2.25 + 0.2 * Math.random()
71
+ ];
72
+ }
73
+ </script>
74
+ </body>
75
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/remove-add-clustering.html ADDED
@@ -0,0 +1,74 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <p>Whenever a marker is clicked it is removed from the clusterer and added directly to the map instead.</p>
23
+ <p>Click Marker on Left, zoom out 1 layer, click marker on right.</p>
24
+ <p>Expected behaviour: Both markers are shown. Bugged behaviour: Both markers are on map with opacity 0.</p>
25
+ <pre id="log"></pre>
26
+
27
+ <script type="text/javascript">
28
+
29
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
30
+ maxZoom: 18,
31
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
32
+ }),
33
+ latlng = new L.LatLng(50.5, 30.51);
34
+
35
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
36
+
37
+ var markers = new L.MarkerClusterGroup({ animateAddingMarkers: true });
38
+ var markersList = [];
39
+ var m;
40
+
41
+ m = new L.Marker([50.5, 30.51]);
42
+ markersList.push(m);
43
+ markers.addLayer(m);
44
+ m = new L.Marker([50.5, 30.515]);
45
+ markersList.push(m);
46
+ markers.addLayer(m);
47
+
48
+ map.addLayer(markers);
49
+
50
+ var lastClicked = null;
51
+ markers.on('click', function (m) {
52
+ console.log('clicked ' + m);
53
+ if (lastClicked) {
54
+ map.removeLayer(lastClicked);
55
+ markers.addLayer(lastClicked);
56
+ }
57
+
58
+ lastClicked = m.layer;
59
+
60
+ markers.removeLayer(lastClicked);
61
+ map.addLayer(lastClicked);
62
+ });
63
+
64
+ map.on('click', function () {
65
+ console.log('map clicked');
66
+ if (lastClicked) {
67
+ map.removeLayer(lastClicked);
68
+ markers.addLayer(lastClicked);
69
+ }
70
+ lastClicked = null;
71
+ });
72
+ </script>
73
+ </body>
74
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/remove-when-spiderfied.html ADDED
@@ -0,0 +1,65 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">Remove and add direct to map</button><button id="doit2">clearLayers</button><button id="doit3">removeLayers</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/54">#54</a>. Spiderfy the cluster then click the button. Should result in 2 markers right beside each other on the map.</span><br/>
24
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/53">#53</a>. Spiderfy the cluster then click the button. Spider lines remain on the map.</span><br/>
25
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/49">#49</a>. Spiderfy the cluster then click the second button. Spider lines remain on the map. Click the map to get an error.</span>
26
+
27
+ <script type="text/javascript">
28
+
29
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
30
+ maxZoom: 18,
31
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
32
+ }),
33
+ latlng = new L.LatLng(50.5, 30.51);
34
+
35
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
36
+
37
+ var markers = new L.MarkerClusterGroup();
38
+ var markersList = [];
39
+ var m;
40
+
41
+ m = new L.Marker([50.5, 30.51]);
42
+ markersList.push(m);
43
+ markers.addLayer(m);
44
+ m = new L.Marker([50.5, 30.5101]);
45
+ markersList.push(m);
46
+ markers.addLayer(m);
47
+
48
+ map.addLayer(markers);
49
+
50
+ //Ugly add/remove code
51
+ L.DomUtil.get('doit').onclick = function () {
52
+ map.removeLayer(markers);
53
+ map.addLayer(markersList[0]);
54
+ map.addLayer(markersList[1]);
55
+ };
56
+ L.DomUtil.get('doit2').onclick = function () {
57
+ markers.clearLayers();
58
+ };
59
+ L.DomUtil.get('doit3').onclick = function () {
60
+ markers.removeLayers(markersList);
61
+ };
62
+
63
+ </script>
64
+ </body>
65
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/removelayer-after-remove-from-map.html ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <a href="#" onclick="swapLayers()">1 - Swap layers</a><br>
23
+ <a href="#" onclick="removeMarker()">2 - Remove all markers</a><br>
24
+ <a href="#" onclick="swapLayers()">3 - Swap layers again =&gt; Marker is still there<a/></br>
25
+
26
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/160">#160</a>. Click 1,2,3. There should be nothing on the map.</span><br/>
27
+ <script type="text/javascript">
28
+
29
+ var map = new L.Map('map');
30
+
31
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
32
+ maxZoom: 18,
33
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
34
+ });
35
+ map.addLayer(tiles);
36
+
37
+ var objectBounds = [[44.98131207805678, 6.0726203025917], [44.981459751363204, 6.073026722623153]];
38
+ map.fitBounds(new L.LatLngBounds(objectBounds));
39
+
40
+ var markers1 = new L.MarkerClusterGroup();
41
+ var markers2 = new L.MarkerClusterGroup();
42
+
43
+ map.addLayer(markers1);
44
+
45
+ var aMarker = new L.Marker(new L.LatLng(44.9813, 6.072620));
46
+ var anotherMarker = new L.Marker(new L.LatLng(44.9814, 6.072621));
47
+
48
+ markers1.addLayer(aMarker);
49
+ markers2.addLayer(anotherMarker);
50
+
51
+ swapLayers = function(){
52
+ if (map.hasLayer(markers1)){
53
+ map.removeLayer(markers1);
54
+ map.addLayer(markers2);
55
+ }else{
56
+ map.removeLayer(markers2);
57
+ map.addLayer(markers1);
58
+ }
59
+ };
60
+
61
+ removeMarker = function(){
62
+ markers1.removeLayer(aMarker);
63
+ markers2.removeLayer(anotherMarker);
64
+ };
65
+
66
+
67
+ </script>
68
+ </body>
69
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/setView-doesnt-remove.html ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">setView</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/63">#63</a>. Zoom down on the very left side untill markers are visible. Click the button. Scroll to the left in one go, those markers should be in clusters but the actual markers will still be visible.</span><br/>
24
+ <span id="time"></span>
25
+ <script type="text/javascript">
26
+
27
+ //Mobile does different bounds to desktop, makes the bug easier to reproduce
28
+ L.Browser.mobile = true;
29
+
30
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
31
+ maxZoom: 18,
32
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
33
+ }),
34
+ latlng = new L.LatLng(50.5, 30.51);
35
+
36
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
37
+
38
+ var markers = new L.MarkerClusterGroup();
39
+ var markersList = [];
40
+
41
+ function getRandomLatLng(map) {
42
+ var bounds = map.getBounds(),
43
+ southWest = bounds.getSouthWest(),
44
+ northEast = bounds.getNorthEast(),
45
+ lngSpan = northEast.lng - southWest.lng,
46
+ latSpan = northEast.lat - southWest.lat;
47
+
48
+ return new L.LatLng(
49
+ southWest.lat + latSpan * Math.random(),
50
+ southWest.lng + lngSpan * Math.random());
51
+ }
52
+
53
+ function populate(length) {
54
+ for (var i = 0; i < length; i++) {
55
+ var m = new L.Marker(getRandomLatLng(map));
56
+ markers.addLayer(m);
57
+ }
58
+ }
59
+
60
+ populate(1000);
61
+ map.addLayer(markers);
62
+
63
+ L.DomUtil.get('doit').onclick = function () {
64
+ map.setView(new L.LatLng(50.5, 30.525), 15);
65
+ };
66
+
67
+ </script>
68
+ </body>
69
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/zoomtoshowlayer-doesnt-need-to-zoom.html ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">open popup</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/65">#65</a>. Click 2 then click the button. You should be scrolled to the marker, old behaviour would zoom you out.</span><br/>
24
+ <span id="time"></span>
25
+ <script type="text/javascript">
26
+
27
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
28
+ maxZoom: 18,
29
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
30
+ }),
31
+ latlng = new L.LatLng(50.5, 30.51);
32
+
33
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
34
+
35
+ var markers = new L.MarkerClusterGroup();
36
+ var markersList = [];
37
+
38
+ var m = new L.Marker(new L.LatLng(50.507, 30.502));
39
+ m.bindPopup('asdasd');
40
+ markersList.push(m);
41
+ markers.addLayer(m);
42
+
43
+
44
+ m = new L.Marker(new L.LatLng(50.493, 30.518));
45
+ markersList.push(m);
46
+ markers.addLayer(m);
47
+
48
+ m = new L.Marker(new L.LatLng(50.493, 30.518));
49
+ markersList.push(m);
50
+ markers.addLayer(m);
51
+
52
+
53
+ map.addLayer(markers);
54
+
55
+ L.DomUtil.get('doit').onclick = function () {
56
+ markers.zoomToShowLayer(markersList[0], function () {
57
+ markersList[0].openPopup();
58
+ });
59
+ };
60
+
61
+ </script>
62
+ </body>
63
+ </html>
node_modules/leaflet.markercluster/example/old-bugs/zoomtoshowlayer-doesnt-zoom-if-centered-on.html ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="../screen.css" />
10
+
11
+ <link rel="stylesheet" href="../../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../../dist/MarkerCluster.Default.css" />
13
+ <script src="../../src/DistanceGrid.js"></script>
14
+ <script src="../../src/MarkerCluster.js"></script>
15
+ <script src="../../src/MarkerClusterGroup.js"></script>
16
+ <script src="../../src/MarkerCluster.QuickHull.js"></script>
17
+ <script src="../../src/MarkerCluster.Spiderfier.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div id="map"></div>
22
+ <button id="doit">open popup</button><br/>
23
+ <span>Bug <a href="https://github.com/danzel/Leaflet.markercluster/issues/286">#286 (from @Grsmto)</a>. Click the button. The cluster should spiderfy and show the popup, old behaviour did nothing.</span><br/>
24
+ <span id="time"></span>
25
+ <script type="text/javascript">
26
+
27
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
28
+ maxZoom: 18,
29
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
30
+ }),
31
+ latlng = new L.LatLng(50.5, 30.51);
32
+
33
+ var map = new L.Map('map', {center: latlng, zoom: 18, layers: [tiles]});
34
+
35
+ var markers = new L.MarkerClusterGroup();
36
+ var markersList = [];
37
+
38
+ for (var i = 0; i < 3; i++) {
39
+ var m = new L.Marker(latlng);
40
+ m.bindPopup('asdasd' + i);
41
+ markersList.push(m);
42
+ markers.addLayer(m);
43
+ }
44
+
45
+ map.addLayer(markers);
46
+
47
+ L.DomUtil.get('doit').onclick = function () {
48
+ //debugger;
49
+ markers.zoomToShowLayer(markersList[0], function () {
50
+ markersList[0].openPopup();
51
+ });
52
+ };
53
+
54
+ </script>
55
+ </body>
56
+ </html>
node_modules/leaflet.markercluster/example/realworld.10000.js ADDED
The diff for this file is too large to render. See raw diff
 
node_modules/leaflet.markercluster/example/realworld.388.js ADDED
@@ -0,0 +1,393 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ //An extract of address points from the LINZ bulk extract: http://www.linz.govt.nz/survey-titles/landonline-data/landonline-bde
3
+ //Should be this data set: http://data.linz.govt.nz/#/layer/779-nz-street-address-electoral/
4
+ var addressPoints = [
5
+ [-37.8210922667, 175.2209316333, "2"],
6
+ [-37.8210819833, 175.2213903167, "3"],
7
+ [-37.8210881833, 175.2215004833, "3A"],
8
+ [-37.8211946833, 175.2213655333, "1"],
9
+ [-37.8209458667, 175.2214051333, "5"],
10
+ [-37.8208292333, 175.2214374833, "7"],
11
+ [-37.8325816, 175.2238798667, "537"],
12
+ [-37.8315855167, 175.2279767, "454"],
13
+ [-37.8096336833, 175.2223743833, "176"],
14
+ [-37.80970685, 175.2221815833, "178"],
15
+ [-37.8102146667, 175.2211562833, "190"],
16
+ [-37.8088037167, 175.2242227, "156"],
17
+ [-37.8112330167, 175.2193425667, "210"],
18
+ [-37.8116368667, 175.2193005167, "212"],
19
+ [-37.80812645, 175.2255449333, "146"],
20
+ [-37.8080231333, 175.2286383167, "125"],
21
+ [-37.8089538667, 175.2222222333, "174"],
22
+ [-37.8080905833, 175.2275400667, "129"],
23
+ [-37.808811, 175.2227592833, "172"],
24
+ [-37.80832975, 175.2276898167, "131"],
25
+ [-37.8089395333, 175.2281710333, "133"],
26
+ [-37.8093421, 175.2274883167, "135"],
27
+ [-37.8084820833, 175.22601925, "137"],
28
+ [-37.80881015, 175.22622865, "139"],
29
+ [-37.8090947667, 175.2263585667, "141"],
30
+ [-37.8092962333, 175.2244872333, "147"],
31
+ [-37.8091016667, 175.2249140167, "145"],
32
+ [-37.8088785167, 175.2253611667, "143"],
33
+ [-37.80825965, 175.22530115, "148"],
34
+ [-37.80995685, 175.2238554333, "153"],
35
+ [-37.80975435, 175.2238417833, "151"],
36
+ [-37.80950755, 175.2237912, "149"],
37
+ [-37.8092772667, 175.2231980833, "170"],
38
+ [-37.8082753833, 175.20672975, "4"],
39
+ [-37.8078434833, 175.211822, "56"],
40
+ [-37.8083775667, 175.2090812333, "30B"],
41
+ [-37.8084588, 175.2058838167, "174"],
42
+ [-37.8088788333, 175.2062702833, "175"],
43
+ [-37.8091632833, 175.20514875, "182A"],
44
+ [-37.8094891167, 175.20384695, "202"],
45
+ [-37.8156715667, 175.2034881667, "277"],
46
+ [-37.8109189333, 175.2024631, "220"],
47
+ [-37.8108164333, 175.2039622, "219"],
48
+ [-37.8125773667, 175.2026079667, "238"],
49
+ [-37.8125799333, 175.2032824, "241A"],
50
+ [-37.8125869, 175.2037423833, "241C"],
51
+ [-37.8140266833, 175.2025706, "256"],
52
+ [-37.80932, 175.2051094333, "182B"],
53
+ [-37.8098799667, 175.2040444167, "197"],
54
+ [-37.8094298833, 175.20561245, "189"],
55
+ [-37.8172409333, 175.2035291167, "287"],
56
+ [-37.8232166667, 175.22452865, "2028"],
57
+ [-37.8225024333, 175.2249944667, "2022"],
58
+ [-37.82334135, 175.2244748667, "2030"],
59
+ [-37.8229725333, 175.2246809333, "2026"],
60
+ [-37.8224034667, 175.22507345, "2020"],
61
+ [-37.8227806, 175.2248285833, "2024"],
62
+ [-37.8178801, 175.2181871667, "6"],
63
+ [-37.81811315, 175.2180543667, "4"],
64
+ [-37.8181739833, 175.21851995, "1"],
65
+ [-37.81797515, 175.2186312, "3"],
66
+ [-37.8181787, 175.2176995, "2A"],
67
+ [-37.8183385333, 175.21812895, "2"],
68
+ [-37.8293053167, 175.2105357833, "31"],
69
+ [-37.8309444333, 175.21208735, "16"],
70
+ [-37.8306726667, 175.2115020833, "19"],
71
+ [-37.8300903, 175.2120791, "26"],
72
+ [-37.8289416167, 175.2113778333, "33"],
73
+ [-37.8274969167, 175.2113355167, "53"],
74
+ [-37.8199192667, 175.2173622833, "5A"],
75
+ [-37.8200392833, 175.2174100167, "3"],
76
+ [-37.8196328, 175.2167642, "18"],
77
+ [-37.81752585, 175.2155467667, "22C"],
78
+ [-37.81766615, 175.2153714167, "22B"],
79
+ [-37.8179022667, 175.2151616833, "22A"],
80
+ [-37.8191980333, 175.21664245, "20A"],
81
+ [-37.81799325, 175.21565925, "20C"],
82
+ [-37.8187486333, 175.2165228667, "20B"],
83
+ [-37.81964875, 175.2172874167, "7"],
84
+ [-37.81925545, 175.2171617, "11"],
85
+ [-37.8190491667, 175.2170928333, "13"],
86
+ [-37.8194515667, 175.2172147167, "9"],
87
+ [-37.81981045, 175.21733245, "5B"],
88
+ [-37.81876595, 175.2172445167, "15B"],
89
+ [-37.8185999167, 175.2172441, "17A"],
90
+ [-37.81816745, 175.21725905, "21B"],
91
+ [-37.8182157167, 175.2164626333, "24"],
92
+ [-37.8180109667, 175.2173984167, "23A"],
93
+ [-37.8179918, 175.217159, "23B"],
94
+ [-37.8188473167, 175.2170330333, "15"],
95
+ [-37.8186481333, 175.2169800667, "17"],
96
+ [-37.8184132, 175.2169327333, "19"],
97
+ [-37.8202288333, 175.2174746333, "1"],
98
+ [-37.818193, 175.2169955667, "21"],
99
+ [-37.8178000833, 175.21733275, "25"],
100
+ [-37.8176839, 175.2168488333, "26"],
101
+ [-37.8198172, 175.2204960667, "5"],
102
+ [-37.819986, 175.22049635, "3"],
103
+ [-37.8197666, 175.2200825, "4"],
104
+ [-37.8193835833, 175.2191669667, "10"],
105
+ [-37.8193426333, 175.2198626667, "11"],
106
+ [-37.8192171667, 175.2191711, "12"],
107
+ [-37.8192621333, 175.2196364167, "13"],
108
+ [-37.8195289667, 175.2193943167, "8"],
109
+ [-37.81946, 175.2201499167, "9"],
110
+ [-37.8196037833, 175.219674, "6"],
111
+ [-37.8194712, 175.2204032, "7A"],
112
+ [-37.8196381, 175.2203709333, "7"],
113
+ [-37.8200137667, 175.2201364333, "2"],
114
+ [-37.8191725167, 175.2193772833, "14"],
115
+ [-37.8214417333, 175.2256822167, "4"],
116
+ [-37.8210291, 175.2259429667, "8"],
117
+ [-37.8212328333, 175.2258132, "6"],
118
+ [-37.8216819833, 175.2253209, "3"],
119
+ [-37.8334697167, 175.2038651667, "326"],
120
+ [-37.8322603667, 175.2028621167, "317"],
121
+ [-37.8322013667, 175.2046802667, "1/341"],
122
+ [-37.8320576167, 175.2165535833, "435"],
123
+ [-37.8319540333, 175.20506915, "2/341"],
124
+ [-37.8316975667, 175.2053442333, "3/341"],
125
+ [-37.8328229833, 175.2062598, "346"],
126
+ [-37.83161565, 175.2074915, "355"],
127
+ [-37.83219305, 175.20629425, "347"],
128
+ [-37.8328549, 175.2080619667, "362"],
129
+ [-37.8321289667, 175.2084019333, "367"],
130
+ [-37.8322225167, 175.2120427667, "397"],
131
+ [-37.8321649, 175.21119325, "393"],
132
+ [-37.8321458833, 175.2131246333, "407"],
133
+ [-37.8327043833, 175.21377405, "416"],
134
+ [-37.8321267167, 175.2144058167, "417"],
135
+ [-37.83212555, 175.2096521333, "373"],
136
+ [-37.8331028667, 175.20928495, "366"],
137
+ [-37.82866875, 175.22177625, "563"],
138
+ [-37.8295602, 175.21924335, "582"],
139
+ [-37.8304707833, 175.2182986167, "590"],
140
+ [-37.83086, 175.2180687667, "592"],
141
+ [-37.8328604833, 175.2172892167, "618"],
142
+ [-37.8342575667, 175.2168357833, "638"],
143
+ [-37.8239713, 175.2245693667, "504"],
144
+ [-37.8365260167, 175.2170911, "673"],
145
+ [-37.8233928833, 175.2249669167, "492"],
146
+ [-37.8248650167, 175.2246300833, "509"],
147
+ [-37.8191798333, 175.2265331667, "435"],
148
+ [-37.8143243333, 175.2310940167, "368"],
149
+ [-37.81459255, 175.2320046, "363"],
150
+ [-37.81127515, 175.2356499167, "311"],
151
+ [-37.8126359667, 175.2340855167, "333"],
152
+ [-37.8096158333, 175.2375218167, "293"],
153
+ [-37.8315868667, 175.2177722833, "604"],
154
+ [-37.8160177667, 175.2299268333, "391"],
155
+ [-37.8204715667, 175.2265481833, "456"],
156
+ [-37.8206352, 175.2265670333, "458"],
157
+ [-37.8208412667, 175.2265323333, "460"],
158
+ [-37.8210184333, 175.22648325, "462"],
159
+ [-37.8212643833, 175.2270422167, "465"],
160
+ [-37.82119945, 175.2264274333, "464"],
161
+ [-37.82136485, 175.2263145667, "466"],
162
+ [-37.8215261, 175.22684075, "467"],
163
+ [-37.8215301833, 175.2262078, "468"],
164
+ [-37.8217701667, 175.2266360167, "1/471"],
165
+ [-37.8218376833, 175.22686725, "2/471"],
166
+ [-37.8217084667, 175.2260839667, "472"],
167
+ [-37.8219782333, 175.2265028333, "475"],
168
+ [-37.8218988833, 175.2259723, "476"],
169
+ [-37.8223939333, 175.2262447, "479"],
170
+ [-37.8223048667, 175.2256582833, "480"],
171
+ [-37.8226657, 175.2261230833, "481"],
172
+ [-37.8224199, 175.2255487833, "482"],
173
+ [-37.8229134167, 175.2259527833, "485"],
174
+ [-37.8226937833, 175.2253693167, "486"],
175
+ [-37.8231509667, 175.2258170333, "487"],
176
+ [-37.82295265, 175.2252571167, "488"],
177
+ [-37.8233779, 175.2256743833, "489"],
178
+ [-37.8232052667, 175.2251109333, "490"],
179
+ [-37.8236200333, 175.22553395, "493"],
180
+ [-37.82385775, 175.2253390833, "495"],
181
+ [-37.8203220167, 175.22650925, "454"],
182
+ [-37.8179795333, 175.2262826, "428"],
183
+ [-37.81038215, 175.2365298167, "303"],
184
+ [-37.8161746667, 175.2297239833, "393"],
185
+ [-37.8083635333, 175.233955, "294"],
186
+ [-37.82029495, 175.2214968167, "39"],
187
+ [-37.8204754333, 175.2247793333, "12B"],
188
+ [-37.8205440833, 175.22344905, "23"],
189
+ [-37.8195974333, 175.2254019333, "2"],
190
+ [-37.8210801, 175.2237748667, "20A"],
191
+ [-37.8209057333, 175.22389775, "18"],
192
+ [-37.8208016833, 175.2221582833, "32"],
193
+ [-37.8209372667, 175.2236919, "20"],
194
+ [-37.8210586833, 175.22351925, "22B"],
195
+ [-37.82092905, 175.2234855333, "22"],
196
+ [-37.8208587333, 175.2231887667, "24"],
197
+ [-37.8210241167, 175.2230882, "24B"],
198
+ [-37.8208547833, 175.2229410667, "26"],
199
+ [-37.8209917, 175.2228447667, "26B"],
200
+ [-37.82097645, 175.2227176167, "28B"],
201
+ [-37.8208099167, 175.2226765167, "28"],
202
+ [-37.8207666833, 175.2224338833, "30"],
203
+ [-37.8209508833, 175.2222094167, "32B"],
204
+ [-37.82076515, 175.2219195167, "34A"],
205
+ [-37.8207399667, 175.2218131667, "34B"],
206
+ [-37.8203075833, 175.2240482833, "19"],
207
+ [-37.8205368167, 175.2237746667, "21"],
208
+ [-37.8205025833, 175.2231658, "25A"],
209
+ [-37.820465, 175.2229733667, "27"],
210
+ [-37.82043535, 175.2227387, "29"],
211
+ [-37.8204582, 175.2225319667, "31"],
212
+ [-37.82024115, 175.2224347833, "31B"],
213
+ [-37.8203792333, 175.2222631667, "33"],
214
+ [-37.82034095, 175.2219843, "35"],
215
+ [-37.8201566167, 175.2219446, "35B"],
216
+ [-37.82030575, 175.2217594333, "37"],
217
+ [-37.8202966833, 175.2233158167, "25"],
218
+ [-37.8192714167, 175.2253842667, "1"],
219
+ [-37.81969695, 175.22516645, "4"],
220
+ [-37.8194904667, 175.22468815, "5"],
221
+ [-37.8198524333, 175.2249096667, "6"],
222
+ [-37.8200581833, 175.2247122, "8"],
223
+ [-37.8193447, 175.2244639667, "5C"],
224
+ [-37.8208238, 175.2241340167, "16"],
225
+ [-37.8193183667, 175.22515695, "1A"],
226
+ [-37.81940575, 175.2249383333, "3"],
227
+ [-37.8211855167, 175.2242545333, "18A"],
228
+ [-37.8207094833, 175.22430275, "14"],
229
+ [-37.82027725, 175.22488135, "10A"],
230
+ [-37.8202305833, 175.2245652667, "10"],
231
+ [-37.8205049667, 175.2244201333, "12"],
232
+ [-37.8196320333, 175.2255586, "22"],
233
+ [-37.8209711, 175.2250444667, "8"],
234
+ [-37.82120665, 175.2252942833, "5"],
235
+ [-37.8210184, 175.2254290333, "7"],
236
+ [-37.8213430333, 175.2252086167, "3"],
237
+ [-37.8207887833, 175.2251555667, "10"],
238
+ [-37.82060805, 175.2257042333, "13"],
239
+ [-37.8208330333, 175.22553905, "9"],
240
+ [-37.8216988833, 175.2249665667, "1"],
241
+ [-37.8215665833, 175.2246573333, "2"],
242
+ [-37.8213729, 175.2247789333, "4"],
243
+ [-37.8211700667, 175.2249324333, "6"],
244
+ [-37.8205967667, 175.2252867, "12"],
245
+ [-37.8204008833, 175.2254234667, "14"],
246
+ [-37.82043265, 175.22582195, "15"],
247
+ [-37.8202037333, 175.2255415833, "16"],
248
+ [-37.8200154333, 175.2256547667, "18"],
249
+ [-37.8197443167, 175.2256164833, "20"],
250
+ [-37.8202814333, 175.22590955, "17"],
251
+ [-37.8202967667, 175.21462555, "98"],
252
+ [-37.82204485, 175.21819735, "61B"],
253
+ [-37.8224241, 175.2179326667, "61C"],
254
+ [-37.8215043167, 175.2227943833, "24"],
255
+ [-37.8219082, 175.2255408167, "8"],
256
+ [-37.8216963, 175.2240856667, "14"],
257
+ [-37.8213418333, 175.2188135667, "55"],
258
+ [-37.8204966333, 175.2183406333, "54A"],
259
+ [-37.8221799833, 175.21122085, "139"],
260
+ [-37.8217387, 175.22431625, "12"],
261
+ [-37.8218650167, 175.2149734167, "107"],
262
+ [-37.8214083333, 175.2220152667, "30"],
263
+ [-37.8213738333, 175.2217301, "32"],
264
+ [-37.8221598167, 175.2247839333, "9"],
265
+ [-37.8216356, 175.2235610667, "18"],
266
+ [-37.8212188167, 175.2221387333, "30B"],
267
+ [-37.8200466667, 175.2166111, "84A"],
268
+ [-37.8216679333, 175.2238393333, "16"],
269
+ [-37.8211582833, 175.22031685, "34"],
270
+ [-37.8221918667, 175.2250378333, "7"],
271
+ [-37.8187410167, 175.2067290167, "170C"],
272
+ [-37.8206532, 175.2170745667, "81"],
273
+ [-37.8212348667, 175.2181024167, "67"],
274
+ [-37.8213057667, 175.2185351167, "57"],
275
+ [-37.8214571, 175.2145877333, "110"],
276
+ [-37.82207085, 175.2136727167, "121"],
277
+ [-37.82190125, 175.2123493, "130"],
278
+ [-37.8207519667, 175.2102467333, "150"],
279
+ [-37.8212159, 175.2096407, "159"],
280
+ [-37.8208313833, 175.2067756, "172"],
281
+ [-37.8214413333, 175.2222779833, "28"],
282
+ [-37.8206921333, 175.2182549, "54"],
283
+ [-37.82043975, 175.2181215, "56"],
284
+ [-37.8218791, 175.2252452167, "10"],
285
+ [-37.82029435, 175.2169818, "84"],
286
+ [-37.8215885167, 175.22308725, "22"],
287
+ [-37.8215897333, 175.2233113167, "20"],
288
+ [-37.82167455, 175.2183345, "61A"],
289
+ [-37.8217164667, 175.2179857333, "63"],
290
+ [-37.82147385, 175.22253565, "26"],
291
+ [-37.8206765333, 175.2160304333, "86"],
292
+ [-37.8188941, 175.2069437, "170A"],
293
+ [-37.8188068333, 175.2068104833, "170B"],
294
+ [-37.8193742667, 175.2085580333, "170"],
295
+ [-37.8214388167, 175.2200072, "45"],
296
+ [-37.8209547167, 175.2157149167, "92"],
297
+ [-37.82088565, 175.2164849333, "85"],
298
+ [-37.82136235, 175.2159546667, "97"],
299
+ [-37.8219607333, 175.2232987, "19"],
300
+ [-37.8210501, 175.2179753833, "69"],
301
+ [-37.8212466667, 175.2222175833, "28A"],
302
+ [-37.8213836167, 175.22300555, "22A"],
303
+ [-37.821339, 175.2227439167, "24A"],
304
+ [-37.8208144333, 175.2173117167, "77"],
305
+ [-37.8189363667, 175.2211582333, "25"],
306
+ [-37.8196676167, 175.2209947333, "26B"],
307
+ [-37.8194113, 175.2211991, "26"],
308
+ [-37.81883205, 175.2209747, "27"],
309
+ [-37.8186925833, 175.2207728833, "29"],
310
+ [-37.8199931833, 175.2240802167, "2"],
311
+ [-37.8191759333, 175.2208279333, "30"],
312
+ [-37.81835395, 175.2196571667, "39"],
313
+ [-37.8198807333, 175.2235938167, "6"],
314
+ [-37.8194567833, 175.22349015, "7"],
315
+ [-37.8200507833, 175.21933875, "58"],
316
+ [-37.8197902167, 175.2182408, "59A"],
317
+ [-37.81991635, 175.21797195, "59B"],
318
+ [-37.8198223833, 175.2179361833, "59C"],
319
+ [-37.8201049333, 175.2197347167, "60"],
320
+ [-37.8199380333, 175.21836645, "61A"],
321
+ [-37.82003775, 175.2182443833, "61B"],
322
+ [-37.8200944167, 175.21803015, "61C"],
323
+ [-37.8201259667, 175.2185610667, "63"],
324
+ [-37.82026275, 175.2188001167, "65"],
325
+ [-37.8188917833, 175.2203729333, "34"],
326
+ [-37.8184921333, 175.2203832, "33"],
327
+ [-37.8190387167, 175.2206181333, "32"],
328
+ [-37.81968705, 175.2224253667, "16"],
329
+ [-37.81981205, 175.223119, "10"],
330
+ [-37.8193882833, 175.2229798333, "11"],
331
+ [-37.8190901167, 175.2227829833, "13B"],
332
+ [-37.8193593, 175.2227247833, "13"],
333
+ [-37.81993935, 175.2226893333, "14B"],
334
+ [-37.81842725, 175.2201474167, "35"],
335
+ [-37.8187965833, 175.2200475333, "36"],
336
+ [-37.8183878167, 175.2198735667, "37"],
337
+ [-37.8188702167, 175.2196982333, "38B"],
338
+ [-37.82027885, 175.2209890667, "82"],
339
+ [-37.8199839667, 175.2190668, "56"],
340
+ [-37.8187008333, 175.21973745, "38A"],
341
+ [-37.8196820167, 175.22262455, "14"],
342
+ [-37.8186528333, 175.2191018, "42"],
343
+ [-37.8182912167, 175.21915535, "43"],
344
+ [-37.81870525, 175.21945675, "40"],
345
+ [-37.8195044333, 175.2214081833, "24"],
346
+ [-37.81857075, 175.2205925167, "31"],
347
+ [-37.8195656167, 175.2181396, "57"],
348
+ [-37.8198411667, 175.2213911167, "24A"],
349
+ [-37.8195851667, 175.2240869667, "3"],
350
+ [-37.8192829167, 175.2239720167, "3A"],
351
+ [-37.8193257, 175.2224725667, "15"],
352
+ [-37.8197290167, 175.2224129833, "16A"],
353
+ [-37.8196499333, 175.2221262667, "18"],
354
+ [-37.8196755333, 175.2243193333, "1"],
355
+ [-37.8192091667, 175.22166805, "21"],
356
+ [-37.81957585, 175.22166585, "22"],
357
+ [-37.8199106833, 175.2238436, "4"],
358
+ [-37.81953715, 175.22372785, "5A"],
359
+ [-37.8193377833, 175.22378105, "5"],
360
+ [-37.8189702833, 175.2184597333, "46"],
361
+ [-37.8185876167, 175.21821495, "47A"],
362
+ [-37.8185706333, 175.2178869167, "47B"],
363
+ [-37.8191945667, 175.21845965, "48"],
364
+ [-37.8188482167, 175.2176680833, "49"],
365
+ [-37.8194043667, 175.21852395, "50"],
366
+ [-37.8196233333, 175.2186248333, "52"],
367
+ [-37.81920055, 175.2179787167, "53"],
368
+ [-37.8198255, 175.2188011167, "54"],
369
+ [-37.8205994333, 175.2207248667, "81"],
370
+ [-37.8193045333, 175.2222075667, "17"],
371
+ [-37.8205621167, 175.2204520167, "79"],
372
+ [-37.8180799333, 175.2194407, "41A"],
373
+ [-37.8208301833, 175.2206735833, "81A"],
374
+ [-37.8202558, 175.2206809333, "80"],
375
+ [-37.81941275, 175.21804965, "55"],
376
+ [-37.8190239, 175.2179808833, "51"],
377
+ [-37.8187854, 175.2180712167, "47"],
378
+ [-37.8187476667, 175.2186516333, "44"],
379
+ [-37.8182977, 175.21889655, "45"],
380
+ [-37.81831675, 175.2194069833, "41"],
381
+ [-37.8192735167, 175.2219502167, "19"],
382
+ [-37.8196219167, 175.22189825, "20"],
383
+ [-37.81962665, 175.2216432667, "22A"],
384
+ [-37.8192782833, 175.2209942, "28"],
385
+ [-37.8208129833, 175.2209176833, "83A"],
386
+ [-37.8206351167, 175.2209705667, "83"],
387
+ [-37.8203109333, 175.2212402667, "84"],
388
+ [-37.81909575, 175.22139795, "23"],
389
+ [-37.8197787167, 175.2228814, "12"],
390
+ [-37.8195628333, 175.21791605, "57A"],
391
+ [-37.8198373833, 175.2233606833, "8"],
392
+ [-37.8194342167, 175.22322975, "9"]
393
+ ];
node_modules/leaflet.markercluster/example/realworld.50000.1.js ADDED
The diff for this file is too large to render. See raw diff
 
node_modules/leaflet.markercluster/example/realworld.50000.2.js ADDED
The diff for this file is too large to render. See raw diff
 
node_modules/leaflet.markercluster/example/remove-geoJSON-when-spiderfied.html ADDED
@@ -0,0 +1,83 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>Leaflet debug page</title>
5
+
6
+ <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.3/dist/leaflet.css" integrity="sha512-07I2e+7D8p6he1SIM+1twR5TIrhUQn9+I6yjqD53JQjFiMf8EtC93ty0/5vJTZGF8aAocvHYNEDJajGdNx1IsQ==" crossorigin="" />
7
+ <script src="https://unpkg.com/leaflet@1.0.3/dist/leaflet-src.js" integrity="sha512-WXoSHqw/t26DszhdMhOXOkI7qCiv5QWXhH9R7CgvgZMHz1ImlkVQ3uNsiQKu5wwbbxtPzFXd1hK4tzno2VqhpA==" crossorigin=""></script>
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link rel="stylesheet" href="screen.css" />
10
+
11
+ <link rel="stylesheet" href="../dist/MarkerCluster.css" />
12
+ <link rel="stylesheet" href="../dist/MarkerCluster.Default.css" />
13
+ <script src="../dist/leaflet.markercluster-src.js"></script>
14
+ </head>
15
+ <body>
16
+
17
+ <div id="map"></div>
18
+ <button id="doit">Remove marker #1</button><button id="doit2">Remove marker #2</button><br/>
19
+ <span>New Bug. Spiderfy the cluster then click the button #1. All markers disapear, but it should remain marker #2.</span><br/>
20
+ <span>New Bug. Spiderfy the cluster then click the button #2. All markers disapear, but it should remain marker #1.</span><br/>
21
+
22
+ <script type="text/javascript">
23
+
24
+ var tiles = L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
25
+ maxZoom: 18,
26
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
27
+ }),
28
+ latlng = new L.LatLng(50.5, 30.51);
29
+
30
+ var map = new L.Map('map', {center: latlng, zoom: 15, layers: [tiles]});
31
+
32
+ var markers = new L.MarkerClusterGroup({ disableClusteringAtZoom: 19});
33
+ var markersList = [];
34
+ var m;
35
+
36
+ geoJsonFeature = { "type": "FeatureCollection",
37
+ "features": [ { "type": "Feature",
38
+ "geometry": {
39
+ "type": "Point",
40
+ "coordinates": [30.51, 50.5]
41
+ }
42
+ }
43
+ ]
44
+ };
45
+ m = L.geoJson(geoJsonFeature, {
46
+ pointToLayer: function (feature, latlng) {
47
+ return L.marker(latlng);
48
+ }
49
+ });
50
+ markersList.push(m);
51
+ markers.addLayer(m);
52
+
53
+
54
+ geoJsonFeature = { "type": "FeatureCollection",
55
+ "features": [ { "type": "Feature",
56
+ "geometry": {
57
+ "type": "Point",
58
+ "coordinates": [30.5101, 50.5]
59
+ }
60
+ }
61
+ ]
62
+ };
63
+ m = L.geoJson(geoJsonFeature, {
64
+ pointToLayer: function (feature, latlng) {
65
+ return L.marker(latlng);
66
+ }
67
+ });
68
+ markersList.push(m);
69
+ markers.addLayer(m);
70
+
71
+ map.addLayer(markers);
72
+
73
+ L.DomUtil.get('doit').onclick = function () {
74
+ markers.removeLayer(markersList[0]);
75
+ };
76
+
77
+ L.DomUtil.get('doit2').onclick = function () {
78
+ markers.removeLayer(markersList[1]);
79
+ };
80
+
81
+ </script>
82
+ </body>
83
+ </html>