@artstesh/maps 1.1.35 → 1.1.37
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/dist/bundles/maps-components-src-map.umd.js +46 -3
- package/dist/bundles/maps-components-src-map.umd.js.map +1 -1
- package/dist/bundles/maps-components.umd.js +46 -3
- package/dist/bundles/maps-components.umd.js.map +1 -1
- package/dist/esm2015/map/map-plate/layers/osm-tile-layer/osm-tile-layer.component.js +12 -2
- package/dist/esm2015/map/map-plate/layers/raster-tile/raster-tile-layer.factory.js +2 -2
- package/dist/esm2015/map/map-plate/layers/raster-tile/raster-tile-layer.settings.js +17 -1
- package/dist/esm2015/map/map-plate/map-plate.component.js +2 -2
- package/dist/esm2015/map/models/map-settings.js +14 -1
- package/dist/esm2015/src/map/map-plate/layers/osm-tile-layer/osm-tile-layer.component.js +12 -2
- package/dist/esm2015/src/map/map-plate/layers/raster-tile/raster-tile-layer.factory.js +2 -2
- package/dist/esm2015/src/map/map-plate/layers/raster-tile/raster-tile-layer.settings.js +17 -1
- package/dist/esm2015/src/map/map-plate/map-plate.component.js +2 -2
- package/dist/esm2015/src/map/models/map-settings.js +14 -1
- package/dist/fesm2015/maps-components-src-map.js +42 -3
- package/dist/fesm2015/maps-components-src-map.js.map +1 -1
- package/dist/fesm2015/maps-components.js +42 -3
- package/dist/fesm2015/maps-components.js.map +1 -1
- package/dist/map/map-plate/layers/osm-tile-layer/osm-tile-layer.component.d.ts +4 -2
- package/dist/map/map-plate/layers/raster-tile/raster-tile-layer.settings.d.ts +11 -0
- package/dist/map/models/map-settings.d.ts +8 -0
- package/dist/src/map/map-plate/layers/osm-tile-layer/osm-tile-layer.component.d.ts +4 -2
- package/dist/src/map/map-plate/layers/raster-tile/raster-tile-layer.settings.d.ts +11 -0
- package/dist/src/map/models/map-settings.d.ts +8 -0
- package/package.json +1 -1
|
@@ -557,6 +557,7 @@
|
|
|
557
557
|
this.zoom = 4;
|
|
558
558
|
this.lyrs = exports.MapLyrs.Hybrid;
|
|
559
559
|
this.language = 'en';
|
|
560
|
+
this.osmOpacity = 1;
|
|
560
561
|
this.interactionSettings = {};
|
|
561
562
|
}
|
|
562
563
|
MapSettings.copy = function (model) {
|
|
@@ -568,6 +569,7 @@
|
|
|
568
569
|
result.lyrs = model.lyrs;
|
|
569
570
|
result.interactionSettings = model.interactionSettings;
|
|
570
571
|
result.language = model.language;
|
|
572
|
+
result.osmOpacity = model.osmOpacity;
|
|
571
573
|
return result;
|
|
572
574
|
};
|
|
573
575
|
/**
|
|
@@ -634,6 +636,15 @@
|
|
|
634
636
|
MapSettings.prototype.setLanguage = function (language) {
|
|
635
637
|
return MapSettings.copy(Object.assign(Object.assign({}, this), { language: language }));
|
|
636
638
|
};
|
|
639
|
+
/**
|
|
640
|
+
* Sets the opacity level for the OpenStreetMap layer.
|
|
641
|
+
*
|
|
642
|
+
* @param {number} osmOpacity - The opacity value for the OpenStreetMap layer, where 0 is fully transparent and 1 is fully opaque.
|
|
643
|
+
* @return {MapSettings} A new MapSettings instance with the updated OpenStreetMap opacity.
|
|
644
|
+
*/
|
|
645
|
+
MapSettings.prototype.setOsmOpacity = function (osmOpacity) {
|
|
646
|
+
return MapSettings.copy(Object.assign(Object.assign({}, this), { osmOpacity: osmOpacity }));
|
|
647
|
+
};
|
|
637
648
|
/**
|
|
638
649
|
* Compares the current MapSettings instance with another to determine if they are identical.
|
|
639
650
|
*
|
|
@@ -653,6 +664,8 @@
|
|
|
653
664
|
return false;
|
|
654
665
|
if (this.interactionSettings !== model.interactionSettings)
|
|
655
666
|
return false;
|
|
667
|
+
if (this.osmOpacity !== model.osmOpacity)
|
|
668
|
+
return false;
|
|
656
669
|
return this.center.length === model.center.length && !this.center.filter(function (c, i) { return c !== model.center[i]; }).length;
|
|
657
670
|
};
|
|
658
671
|
return MapSettings;
|
|
@@ -2416,6 +2429,7 @@
|
|
|
2416
2429
|
function OsmTileLayerComponent() {
|
|
2417
2430
|
var _this = _super.call(this) || this;
|
|
2418
2431
|
_this._url = '';
|
|
2432
|
+
_this._opacity = 1;
|
|
2419
2433
|
return _this;
|
|
2420
2434
|
}
|
|
2421
2435
|
Object.defineProperty(OsmTileLayerComponent.prototype, "url", {
|
|
@@ -2428,6 +2442,16 @@
|
|
|
2428
2442
|
enumerable: false,
|
|
2429
2443
|
configurable: true
|
|
2430
2444
|
});
|
|
2445
|
+
Object.defineProperty(OsmTileLayerComponent.prototype, "opacity", {
|
|
2446
|
+
set: function (value) {
|
|
2447
|
+
if (!value || this._opacity === value)
|
|
2448
|
+
return;
|
|
2449
|
+
this._opacity = value;
|
|
2450
|
+
this.initLayer();
|
|
2451
|
+
},
|
|
2452
|
+
enumerable: false,
|
|
2453
|
+
configurable: true
|
|
2454
|
+
});
|
|
2431
2455
|
Object.defineProperty(OsmTileLayerComponent.prototype, "map", {
|
|
2432
2456
|
set: function (value) {
|
|
2433
2457
|
if (!value || this._map === value)
|
|
@@ -2456,6 +2480,7 @@
|
|
|
2456
2480
|
source: new OSM__default["default"]({
|
|
2457
2481
|
url: this._url,
|
|
2458
2482
|
}),
|
|
2483
|
+
opacity: this._opacity,
|
|
2459
2484
|
});
|
|
2460
2485
|
this.layer.set('name', 'osm-tile-layer');
|
|
2461
2486
|
this._map.addLayer(this.layer);
|
|
@@ -2463,7 +2488,7 @@
|
|
|
2463
2488
|
return OsmTileLayerComponent;
|
|
2464
2489
|
}(DestructibleComponent));
|
|
2465
2490
|
OsmTileLayerComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: OsmTileLayerComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
|
|
2466
|
-
OsmTileLayerComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: OsmTileLayerComponent, selector: "art-osm-tile-layer", inputs: { url: "url", map: "map" }, usesInheritance: true, ngImport: i0__namespace, template: '', isInline: true, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
2491
|
+
OsmTileLayerComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: OsmTileLayerComponent, selector: "art-osm-tile-layer", inputs: { url: "url", opacity: "opacity", map: "map" }, usesInheritance: true, ngImport: i0__namespace, template: '', isInline: true, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
|
|
2467
2492
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: OsmTileLayerComponent, decorators: [{
|
|
2468
2493
|
type: i0.Component,
|
|
2469
2494
|
args: [{
|
|
@@ -2474,6 +2499,8 @@
|
|
|
2474
2499
|
}]
|
|
2475
2500
|
}], ctorParameters: function () { return []; }, propDecorators: { url: [{
|
|
2476
2501
|
type: i0.Input
|
|
2502
|
+
}], opacity: [{
|
|
2503
|
+
type: i0.Input
|
|
2477
2504
|
}], map: [{
|
|
2478
2505
|
type: i0.Input
|
|
2479
2506
|
}] } });
|
|
@@ -3235,6 +3262,10 @@
|
|
|
3235
3262
|
* @default An empty array
|
|
3236
3263
|
*/
|
|
3237
3264
|
this.requestHeaders = null;
|
|
3265
|
+
/**
|
|
3266
|
+
* The priority of showing - layers with higher zIndex cover others in case of collisions
|
|
3267
|
+
*/
|
|
3268
|
+
this.zIndex = 1;
|
|
3238
3269
|
this.operation = function (d) { var _a; return (_a = d[0]) !== null && _a !== void 0 ? _a : []; };
|
|
3239
3270
|
}
|
|
3240
3271
|
/**
|
|
@@ -3247,6 +3278,7 @@
|
|
|
3247
3278
|
var result = new RasterTileLayerSettings();
|
|
3248
3279
|
result.maxZoom = model.maxZoom;
|
|
3249
3280
|
result.minZoom = model.minZoom;
|
|
3281
|
+
result.zIndex = model.zIndex;
|
|
3250
3282
|
result.projection = model.projection;
|
|
3251
3283
|
result.opacity = model.opacity;
|
|
3252
3284
|
result.url = model.url;
|
|
@@ -3290,6 +3322,15 @@
|
|
|
3290
3322
|
RasterTileLayerSettings.prototype.setMaxZoom = function (maxZoom) {
|
|
3291
3323
|
return RasterTileLayerSettings.copy(Object.assign(Object.assign({}, this), { maxZoom: maxZoom }));
|
|
3292
3324
|
};
|
|
3325
|
+
/**
|
|
3326
|
+
* Sets the z-index for the RasterTileLayerSettings.
|
|
3327
|
+
*
|
|
3328
|
+
* @param {number} zIndex - The new z-index to be assigned.
|
|
3329
|
+
* @return {RasterTileLayerSettings} A new RasterTileLayerSettings instance with the updated z-index.
|
|
3330
|
+
*/
|
|
3331
|
+
RasterTileLayerSettings.prototype.setZIndex = function (zIndex) {
|
|
3332
|
+
return RasterTileLayerSettings.copy(Object.assign(Object.assign({}, this), { zIndex: zIndex }));
|
|
3333
|
+
};
|
|
3293
3334
|
/**
|
|
3294
3335
|
* Sets the minimum zoom level for the Tile Layer.
|
|
3295
3336
|
*
|
|
@@ -3328,6 +3369,8 @@
|
|
|
3328
3369
|
return false;
|
|
3329
3370
|
if (this.minZoom !== model.minZoom)
|
|
3330
3371
|
return false;
|
|
3372
|
+
if (this.zIndex !== model.zIndex)
|
|
3373
|
+
return false;
|
|
3331
3374
|
if (this.url !== model.url)
|
|
3332
3375
|
return false;
|
|
3333
3376
|
if (this.projection !== model.projection)
|
|
@@ -3364,7 +3407,7 @@
|
|
|
3364
3407
|
operationType: 'image',
|
|
3365
3408
|
operation: settings.operation,
|
|
3366
3409
|
});
|
|
3367
|
-
return new ImageLayer__default["default"]({ source: raster, opacity: settings.opacity });
|
|
3410
|
+
return new ImageLayer__default["default"]({ source: raster, opacity: settings.opacity, zIndex: settings.zIndex });
|
|
3368
3411
|
};
|
|
3369
3412
|
RasterTileLayerFactory.prototype.getTileFunc = function (settings) {
|
|
3370
3413
|
var _this = this;
|
|
@@ -3575,7 +3618,7 @@
|
|
|
3575
3618
|
FeatureService,
|
|
3576
3619
|
FeatureModificationService,
|
|
3577
3620
|
ControlsService,
|
|
3578
|
-
], usesInheritance: true, ngImport: i0__namespace, template: "<ng-content></ng-content>\r\n<art-osm-tile-layer *ngIf=\"osmUrl && map\" [map]=\"map\" [url]=\"osmUrl\"></art-osm-tile-layer>\r\n<art-feature-layer *ngIf=\"map\" [settings]=\"drawingLayerSettings\"></art-feature-layer>\r\n", styles: ["art-map-plate{display:block;width:100%;height:100%}\n"], components: [{ type: OsmTileLayerComponent, selector: "art-osm-tile-layer", inputs: ["url", "map"] }, { type: FeatureLayerComponent, selector: "art-feature-layer", inputs: ["settings"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush, encapsulation: i0__namespace.ViewEncapsulation.None });
|
|
3621
|
+
], usesInheritance: true, ngImport: i0__namespace, template: "<ng-content></ng-content>\r\n<art-osm-tile-layer *ngIf=\"osmUrl && map\" [map]=\"map\" [url]=\"osmUrl\" [opacity]=\"_settings.osmOpacity\"></art-osm-tile-layer>\r\n<art-feature-layer *ngIf=\"map\" [settings]=\"drawingLayerSettings\"></art-feature-layer>\r\n", styles: ["art-map-plate{display:block;width:100%;height:100%}\n"], components: [{ type: OsmTileLayerComponent, selector: "art-osm-tile-layer", inputs: ["url", "opacity", "map"] }, { type: FeatureLayerComponent, selector: "art-feature-layer", inputs: ["settings"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush, encapsulation: i0__namespace.ViewEncapsulation.None });
|
|
3579
3622
|
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapPlateComponent, decorators: [{
|
|
3580
3623
|
type: i0.Component,
|
|
3581
3624
|
args: [{
|