@vtx/map 1.1.33 → 1.1.34
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/lib/VtxMap/AMap/AMap.js
CHANGED
|
@@ -1307,17 +1307,7 @@ var VortexAMap = /*#__PURE__*/function (_React$Component) {
|
|
|
1307
1307
|
|
|
1308
1308
|
}, {
|
|
1309
1309
|
key: "infoWindow",
|
|
1310
|
-
value: function (
|
|
1311
|
-
function infoWindow() {
|
|
1312
|
-
return _infoWindow.apply(this, arguments);
|
|
1313
|
-
}
|
|
1314
|
-
|
|
1315
|
-
infoWindow.toString = function () {
|
|
1316
|
-
return _infoWindow.toString();
|
|
1317
|
-
};
|
|
1318
|
-
|
|
1319
|
-
return infoWindow;
|
|
1320
|
-
}(function () {
|
|
1310
|
+
value: function infoWindow() {
|
|
1321
1311
|
var d = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
1322
1312
|
var t = this;
|
|
1323
1313
|
var cg = {
|
|
@@ -1336,14 +1326,20 @@ var VortexAMap = /*#__PURE__*/function (_React$Component) {
|
|
|
1336
1326
|
});
|
|
1337
1327
|
infowindow.setSize(new AMap.Size(cg.width, cg.height + 20));
|
|
1338
1328
|
|
|
1329
|
+
if (d.onClose instanceof Function) {
|
|
1330
|
+
infowindow.on("close", function (e) {
|
|
1331
|
+
d.onClose(e);
|
|
1332
|
+
});
|
|
1333
|
+
}
|
|
1334
|
+
|
|
1339
1335
|
if (d.lat && d.lng && d.content) {
|
|
1340
1336
|
(0, _reactDom.render)(d.content, sContent);
|
|
1341
1337
|
infowindow.open(t.state.gis, [d.lng, d.lat]);
|
|
1342
1338
|
} else {
|
|
1343
|
-
|
|
1339
|
+
infowindow.close();
|
|
1344
1340
|
}
|
|
1345
1341
|
} //添加海量点
|
|
1346
|
-
|
|
1342
|
+
|
|
1347
1343
|
}, {
|
|
1348
1344
|
key: "addPointCollection",
|
|
1349
1345
|
value: function addPointCollection() {
|