xy-map 1.1.33 → 1.1.35
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/package.json +1 -1
- package/xy-map.common.js +4 -2
- package/xy-map.umd.js +4 -2
- package/xy-map.umd.min.js +1 -1
package/package.json
CHANGED
package/xy-map.common.js
CHANGED
|
@@ -44186,13 +44186,15 @@ class mapSdk {
|
|
|
44186
44186
|
* @param {*} position
|
|
44187
44187
|
* @param {*} html
|
|
44188
44188
|
* @param {*} option { offset: 25 }
|
|
44189
|
+
* @param {*} isClear // 是否情况上次的气泡
|
|
44189
44190
|
*/
|
|
44190
|
-
addPopup(position, html, option) {
|
|
44191
|
-
this.removePopup();
|
|
44191
|
+
addPopup(position, html, option, isClear = true) {
|
|
44192
|
+
if (isClear) this.removePopup();
|
|
44192
44193
|
popup = new (mapbox_gl_default()).Popup(option).setLngLat(position).setHTML(html).addTo(this.map);
|
|
44193
44194
|
popup.on('close', e => {
|
|
44194
44195
|
popup = null;
|
|
44195
44196
|
});
|
|
44197
|
+
return popup;
|
|
44196
44198
|
}
|
|
44197
44199
|
|
|
44198
44200
|
/**
|
package/xy-map.umd.js
CHANGED
|
@@ -44204,13 +44204,15 @@ class mapSdk {
|
|
|
44204
44204
|
* @param {*} position
|
|
44205
44205
|
* @param {*} html
|
|
44206
44206
|
* @param {*} option { offset: 25 }
|
|
44207
|
+
* @param {*} isClear // 是否情况上次的气泡
|
|
44207
44208
|
*/
|
|
44208
|
-
addPopup(position, html, option) {
|
|
44209
|
-
this.removePopup();
|
|
44209
|
+
addPopup(position, html, option, isClear = true) {
|
|
44210
|
+
if (isClear) this.removePopup();
|
|
44210
44211
|
popup = new (mapbox_gl_default()).Popup(option).setLngLat(position).setHTML(html).addTo(this.map);
|
|
44211
44212
|
popup.on('close', e => {
|
|
44212
44213
|
popup = null;
|
|
44213
44214
|
});
|
|
44215
|
+
return popup;
|
|
44214
44216
|
}
|
|
44215
44217
|
|
|
44216
44218
|
/**
|