@nextgis/ngw-map 3.0.0-alpha.14 → 3.0.0-alpha.15

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.
@@ -5873,15 +5873,19 @@ function createRasterAdapter(_0) {
5873
5873
  }
5874
5874
  showLayer() {
5875
5875
  this._layerVisibility = true;
5876
- if (this.layer) {
5877
- if (!this._blocked) {
5876
+ if (!this._blocked) {
5877
+ if (super.showLayer) {
5878
+ super.showLayer(this.layer);
5879
+ } else if (this.layer) {
5878
5880
  webMap.mapAdapter.showLayer(this.layer);
5879
5881
  }
5880
5882
  }
5881
5883
  }
5882
5884
  hideLayer() {
5883
5885
  this._layerVisibility = false;
5884
- if (this.layer) {
5886
+ if (super.hideLayer) {
5887
+ super.hideLayer(this.layer);
5888
+ } else if (this.layer) {
5885
5889
  webMap.mapAdapter.hideLayer(this.layer);
5886
5890
  }
5887
5891
  }
@@ -6428,24 +6432,26 @@ function getCompanyLogo(connector, options) {
6428
6432
  img.style.maxHeight = "100px";
6429
6433
  img.style.maxWidth = "100px";
6430
6434
  img.src = "";
6431
- try {
6432
- const resp = yield connector.route("pyramid.csettings").get();
6433
- const logo = (_b = resp.pyramid) == null ? void 0 : _b.header_logo;
6434
- if (logo) {
6435
- const [mimeType, base64Data] = logo;
6436
- const byteCharacters = atob(base64Data);
6437
- const byteNumbers = new Array(byteCharacters.length);
6438
- for (let i = 0; i < byteCharacters.length; i++) {
6439
- byteNumbers[i] = byteCharacters.charCodeAt(i);
6440
- }
6441
- const byteArray = new Uint8Array(byteNumbers);
6442
- const blob = new Blob([byteArray], { type: mimeType });
6443
- const urlCreator = window.URL || window.webkitURL;
6444
- const imageUrl = urlCreator.createObjectURL(blob);
6445
- img.src = imageUrl;
6435
+ const resp = yield connector.route("pyramid.csettings").get({
6436
+ query: {
6437
+ pyramid: ["header_logo"]
6446
6438
  }
6447
- } catch (er) {
6448
- console.warn(er);
6439
+ });
6440
+ const logo = (_b = resp.pyramid) == null ? void 0 : _b.header_logo;
6441
+ if (logo) {
6442
+ const [mimeType, base64Data] = logo;
6443
+ const byteCharacters = atob(base64Data);
6444
+ const byteNumbers = new Array(byteCharacters.length);
6445
+ for (let i = 0; i < byteCharacters.length; i++) {
6446
+ byteNumbers[i] = byteCharacters.charCodeAt(i);
6447
+ }
6448
+ const byteArray = new Uint8Array(byteNumbers);
6449
+ const blob = new Blob([byteArray], { type: mimeType });
6450
+ const urlCreator = window.URL || window.webkitURL;
6451
+ const imageUrl = urlCreator.createObjectURL(blob);
6452
+ img.src = imageUrl;
6453
+ } else {
6454
+ return;
6449
6455
  }
6450
6456
  if (settings.company_logo.link !== null && settings.company_logo.link.trim() !== "") {
6451
6457
  anchor.href = settings.company_logo.link;