@antv/l7-component 2.10.5 → 2.10.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/popup/popup.js +15 -3
- package/lib/popup/popup.js +15 -3
- package/package.json +5 -5
package/es/popup/popup.js
CHANGED
|
@@ -496,29 +496,41 @@ var Popup = /*#__PURE__*/function (_EventEmitter) {
|
|
|
496
496
|
}, {
|
|
497
497
|
key: "updateCloseOnClick",
|
|
498
498
|
value: function updateCloseOnClick(onlyClear) {
|
|
499
|
+
var _this3 = this;
|
|
500
|
+
|
|
499
501
|
this.mapsService.off('click', this.onCloseButtonClick);
|
|
500
502
|
|
|
501
503
|
if (this.popupOption.closeOnClick && !onlyClear) {
|
|
502
|
-
|
|
504
|
+
requestAnimationFrame(function () {
|
|
505
|
+
_this3.mapsService.on('click', _this3.onCloseButtonClick);
|
|
506
|
+
});
|
|
503
507
|
}
|
|
504
508
|
}
|
|
505
509
|
}, {
|
|
506
510
|
key: "updateCloseOnEsc",
|
|
507
511
|
value: function updateCloseOnEsc(onlyClear) {
|
|
512
|
+
var _this4 = this;
|
|
513
|
+
|
|
508
514
|
window.removeEventListener('keydown', this.onKeyDown);
|
|
509
515
|
|
|
510
516
|
if (this.popupOption.closeOnEsc && !onlyClear) {
|
|
511
|
-
|
|
517
|
+
requestAnimationFrame(function () {
|
|
518
|
+
window.addEventListener('keydown', _this4.onKeyDown);
|
|
519
|
+
});
|
|
512
520
|
}
|
|
513
521
|
}
|
|
514
522
|
}, {
|
|
515
523
|
key: "updateFollowCursor",
|
|
516
524
|
value: function updateFollowCursor(onlyClear) {
|
|
525
|
+
var _this5 = this;
|
|
526
|
+
|
|
517
527
|
var container = this.mapsService.getContainer();
|
|
518
528
|
container.removeEventListener('mousemove', this.onMouseMove);
|
|
519
529
|
|
|
520
530
|
if (this.popupOption.followCursor && !onlyClear) {
|
|
521
|
-
|
|
531
|
+
requestAnimationFrame(function () {
|
|
532
|
+
container.addEventListener('mousemove', _this5.onMouseMove);
|
|
533
|
+
});
|
|
522
534
|
}
|
|
523
535
|
}
|
|
524
536
|
}, {
|
package/lib/popup/popup.js
CHANGED
|
@@ -510,29 +510,41 @@ var Popup = /*#__PURE__*/function (_EventEmitter) {
|
|
|
510
510
|
}, {
|
|
511
511
|
key: "updateCloseOnClick",
|
|
512
512
|
value: function updateCloseOnClick(onlyClear) {
|
|
513
|
+
var _this3 = this;
|
|
514
|
+
|
|
513
515
|
this.mapsService.off('click', this.onCloseButtonClick);
|
|
514
516
|
|
|
515
517
|
if (this.popupOption.closeOnClick && !onlyClear) {
|
|
516
|
-
|
|
518
|
+
requestAnimationFrame(function () {
|
|
519
|
+
_this3.mapsService.on('click', _this3.onCloseButtonClick);
|
|
520
|
+
});
|
|
517
521
|
}
|
|
518
522
|
}
|
|
519
523
|
}, {
|
|
520
524
|
key: "updateCloseOnEsc",
|
|
521
525
|
value: function updateCloseOnEsc(onlyClear) {
|
|
526
|
+
var _this4 = this;
|
|
527
|
+
|
|
522
528
|
window.removeEventListener('keydown', this.onKeyDown);
|
|
523
529
|
|
|
524
530
|
if (this.popupOption.closeOnEsc && !onlyClear) {
|
|
525
|
-
|
|
531
|
+
requestAnimationFrame(function () {
|
|
532
|
+
window.addEventListener('keydown', _this4.onKeyDown);
|
|
533
|
+
});
|
|
526
534
|
}
|
|
527
535
|
}
|
|
528
536
|
}, {
|
|
529
537
|
key: "updateFollowCursor",
|
|
530
538
|
value: function updateFollowCursor(onlyClear) {
|
|
539
|
+
var _this5 = this;
|
|
540
|
+
|
|
531
541
|
var container = this.mapsService.getContainer();
|
|
532
542
|
container.removeEventListener('mousemove', this.onMouseMove);
|
|
533
543
|
|
|
534
544
|
if (this.popupOption.followCursor && !onlyClear) {
|
|
535
|
-
|
|
545
|
+
requestAnimationFrame(function () {
|
|
546
|
+
container.addEventListener('mousemove', _this5.onMouseMove);
|
|
547
|
+
});
|
|
536
548
|
}
|
|
537
549
|
}
|
|
538
550
|
}, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antv/l7-component",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.6",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"author": "lzxue",
|
|
27
27
|
"license": "ISC",
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@antv/l7-core": "2.10.
|
|
30
|
-
"@antv/l7-utils": "2.10.
|
|
29
|
+
"@antv/l7-core": "2.10.6",
|
|
30
|
+
"@antv/l7-utils": "2.10.6",
|
|
31
31
|
"@babel/runtime": "^7.7.7",
|
|
32
32
|
"eventemitter3": "^4.0.0",
|
|
33
33
|
"inversify": "^5.0.1",
|
|
@@ -36,11 +36,11 @@
|
|
|
36
36
|
"supercluster": "^7.0.0"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@antv/l7-test-utils": "2.10.
|
|
39
|
+
"@antv/l7-test-utils": "2.10.6",
|
|
40
40
|
"gcoord": "^0.3.2",
|
|
41
41
|
"less": "^4.1.3"
|
|
42
42
|
},
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "7fc81ea48b86d6aeb0f5351a8c5eb3017f473ccc",
|
|
44
44
|
"publishConfig": {
|
|
45
45
|
"access": "public"
|
|
46
46
|
}
|