gis-map-universal 0.1.8 → 0.1.9

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.
Files changed (2) hide show
  1. package/gismap.umd.js +25 -20
  2. package/package.json +1 -1
package/gismap.umd.js CHANGED
@@ -457890,28 +457890,33 @@ var Cluster_Cluster = /** @class */ (function (_super) {
457890
457890
  return foundLayer;
457891
457891
  },
457892
457892
  pileIsShow(layerName, isShow) {
457893
- if (this.isCluster) {
457894
- if (!isShow) {
457895
- const newclusterSource = new source_Cluster({
457896
- distance: 50,
457897
- minDistance: 200,
457898
- source: this.sourceWithoutText,
457899
- });
457900
- this.findLayerByName(layerName).setSource(newclusterSource);
457901
- } else {
457902
- const newclusterSource = new source_Cluster({
457903
- distance: 50,
457904
- minDistance: 200,
457905
- source: this.sourceWithText,
457906
- });
457907
- this.findLayerByName(layerName).setSource(newclusterSource);
457908
- }
457909
- } else {
457910
- if (!isShow) {
457911
- this.findLayerByName(layerName).setSource(this.sourceWithoutText);
457893
+ if(this.findLayerByName(layerName)){
457894
+ if (this.isCluster) {
457895
+ if (!isShow) {
457896
+ const newclusterSource = new source_Cluster({
457897
+ distance: 50,
457898
+ minDistance: 200,
457899
+ source: this.sourceWithoutText,
457900
+ });
457901
+ this.findLayerByName(layerName).setSource(newclusterSource);
457902
+ } else {
457903
+ const newclusterSource = new source_Cluster({
457904
+ distance: 50,
457905
+ minDistance: 200,
457906
+ source: this.sourceWithText,
457907
+ });
457908
+ this.findLayerByName(layerName).setSource(newclusterSource);
457909
+ }
457912
457910
  } else {
457913
- this.findLayerByName(layerName).setSource(this.sourceWithText);
457911
+ if (!isShow) {
457912
+ this.findLayerByName(layerName).setSource(this.sourceWithoutText);
457913
+ } else {
457914
+ this.findLayerByName(layerName).setSource(this.sourceWithText);
457915
+ }
457914
457916
  }
457917
+ }else{
457918
+ console.log('未找到该图层');
457919
+ return '未找到该图层'
457915
457920
  }
457916
457921
  },
457917
457922
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gis-map-universal",
3
- "version": "0.1.8",
3
+ "version": "0.1.9",
4
4
  "description": "GIS通用组件",
5
5
  "main": "gismap.umd.js",
6
6
  "private": false,