Skip to content

Commit

Permalink
0.8.8
Browse files Browse the repository at this point in the history
  • Loading branch information
fuzhenn committed Feb 27, 2024
1 parent c2ebb29 commit 3aa9441
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 28 deletions.
15 changes: 3 additions & 12 deletions dist/maptalks.markercluster.es.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* maptalks.markercluster v0.8.7
* maptalks.markercluster v0.8.8
* LICENSE : MIT
* (c) 2016-2024 maptalks.org
*/
Expand Down Expand Up @@ -328,16 +328,7 @@ ClusterLayer.registerRenderer('canvas', function (_maptalks$renderer$Ve) {
// if no clusters is hit, identify markers
if (this._markersToDraw && this._markersToDraw[0]) {
var _point = map.coordinateToContainerPoint(coordinate);
var minDistance = _point.distanceTo(map.coordinateToContainerPoint(this._markersToDraw[0]._coordinates));
var hitPoint = this._markersToDraw[0];
for (var _i = 1; _i < this._markersToDraw.length; _i++) {
var dis = _point.distanceTo(map.coordinateToContainerPoint(this._markersToDraw[_i]._coordinates));
if (minDistance > dis) {
minDistance = dis;
hitPoint = this._markersToDraw[_i];
}
}
return hitPoint;
return this.layer._hitGeos(this._markersToDraw, _point, options);
}
return null;
};
Expand Down Expand Up @@ -704,4 +695,4 @@ ClusterLayer.registerRenderer('canvas', function (_maptalks$renderer$Ve) {

export { ClusterLayer };

typeof console !== 'undefined' && console.log('maptalks.markercluster v0.8.7');
typeof console !== 'undefined' && console.log('maptalks.markercluster v0.8.8');
15 changes: 3 additions & 12 deletions dist/maptalks.markercluster.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* maptalks.markercluster v0.8.7
* maptalks.markercluster v0.8.8
* LICENSE : MIT
* (c) 2016-2024 maptalks.org
*/
Expand Down Expand Up @@ -332,16 +332,7 @@ ClusterLayer.registerRenderer('canvas', function (_maptalks$renderer$Ve) {
// if no clusters is hit, identify markers
if (this._markersToDraw && this._markersToDraw[0]) {
var _point = map.coordinateToContainerPoint(coordinate);
var minDistance = _point.distanceTo(map.coordinateToContainerPoint(this._markersToDraw[0]._coordinates));
var hitPoint = this._markersToDraw[0];
for (var _i = 1; _i < this._markersToDraw.length; _i++) {
var dis = _point.distanceTo(map.coordinateToContainerPoint(this._markersToDraw[_i]._coordinates));
if (minDistance > dis) {
minDistance = dis;
hitPoint = this._markersToDraw[_i];
}
}
return hitPoint;
return this.layer._hitGeos(this._markersToDraw, _point, options);
}
return null;
};
Expand Down Expand Up @@ -710,6 +701,6 @@ exports.ClusterLayer = ClusterLayer;

Object.defineProperty(exports, '__esModule', { value: true });

typeof console !== 'undefined' && console.log('maptalks.markercluster v0.8.7');
typeof console !== 'undefined' && console.log('maptalks.markercluster v0.8.8');

})));
4 changes: 2 additions & 2 deletions dist/maptalks.markercluster.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "maptalks.markercluster",
"version": "0.8.7",
"version": "0.8.8",
"description": "A layer of maptalks to cluster markers.",
"license": "MIT",
"repository": {
Expand Down

0 comments on commit 3aa9441

Please sign in to comment.