@nextgis/ngw-map 3.0.0-alpha.1 → 3.0.0-alpha.2
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/ngw-map.cjs.js +1 -1
- package/lib/ngw-map.esm-browser.js +61 -3
- package/lib/ngw-map.esm-browser.js.map +1 -1
- package/lib/ngw-map.esm-browser.prod.js +1 -1
- package/lib/ngw-map.esm-browser.prod.js.map +1 -1
- package/lib/ngw-map.esm-bundler.js +1 -1
- package/lib/ngw-map.global.js +61 -3
- package/lib/ngw-map.global.js.map +1 -1
- package/lib/ngw-map.global.prod.js +1 -1
- package/lib/ngw-map.global.prod.js.map +1 -1
- package/package.json +4 -4
package/lib/ngw-map.cjs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Bundle of @nextgis/ngw-map; version: 3.0.0-alpha.
|
|
1
|
+
/** Bundle of @nextgis/ngw-map; version: 3.0.0-alpha.2; author: NextGIS */
|
|
2
2
|
var domain;
|
|
3
3
|
|
|
4
4
|
// This constructor is used to store event handlers. Instantiating this is
|
|
@@ -938,6 +938,62 @@ const _Cache = class _Cache {
|
|
|
938
938
|
__publicField$v(_Cache, "instance", {});
|
|
939
939
|
let Cache = _Cache;
|
|
940
940
|
|
|
941
|
+
var pkg = {
|
|
942
|
+
name: "@nextgis/ngw-connector",
|
|
943
|
+
version: "3.0.0-alpha.2",
|
|
944
|
+
_priority: 12,
|
|
945
|
+
description: "A lightweight HTTP client optimized for use with NextGIS Web API",
|
|
946
|
+
main: "index.js",
|
|
947
|
+
module: "lib/ngw-connector.esm-bundler.js",
|
|
948
|
+
unpkg: "lib/ngw-connector.global.prod.js",
|
|
949
|
+
jsdelivr: "lib/ngw-connector.global.prod.js",
|
|
950
|
+
types: "lib/index.d.ts",
|
|
951
|
+
dependencies: {
|
|
952
|
+
"@nextgis/cache": "^3.0.0-alpha.1",
|
|
953
|
+
"@nextgis/cancelable-promise": "^3.0.0-alpha.1",
|
|
954
|
+
"@nextgis/utils": "^3.0.0-alpha.1",
|
|
955
|
+
"@types/events": "^3.0.0",
|
|
956
|
+
events: "*",
|
|
957
|
+
"form-data": "^4.0.0"
|
|
958
|
+
},
|
|
959
|
+
devDependencies: {
|
|
960
|
+
"@nextgis/build-tools": "^3.0.0-alpha.1"
|
|
961
|
+
},
|
|
962
|
+
scripts: {
|
|
963
|
+
clean: "rimraf ./lib",
|
|
964
|
+
dev: "node ../build-tools/lib/build.js",
|
|
965
|
+
prod: "npm run dev -- --release",
|
|
966
|
+
lint: "eslint ./src/**/*.ts --fix --c ../../.eslintrc",
|
|
967
|
+
watch: "npm run dev -- --watch",
|
|
968
|
+
"gen:types": "node ./scripts/generator"
|
|
969
|
+
},
|
|
970
|
+
buildOptions: {
|
|
971
|
+
name: "NgwConnector",
|
|
972
|
+
formats: [
|
|
973
|
+
"esm-bundler",
|
|
974
|
+
"esm-browser",
|
|
975
|
+
"cjs",
|
|
976
|
+
"global"
|
|
977
|
+
]
|
|
978
|
+
},
|
|
979
|
+
keywords: [
|
|
980
|
+
"NextGIS",
|
|
981
|
+
"MAP"
|
|
982
|
+
],
|
|
983
|
+
author: "NextGIS",
|
|
984
|
+
files: [
|
|
985
|
+
"index.js",
|
|
986
|
+
"lib"
|
|
987
|
+
],
|
|
988
|
+
license: "MIT",
|
|
989
|
+
homepage: "https://github.com/nextgis/nextgis_frontend/tree/master/packages/ngw-connector#readme",
|
|
990
|
+
repository: {
|
|
991
|
+
type: "git",
|
|
992
|
+
url: "git://github.com/nextgis/nextgis_frontend.git"
|
|
993
|
+
},
|
|
994
|
+
gitHead: "edc68033f914f6c95c4125b9738bba6d36e990b4"
|
|
995
|
+
};
|
|
996
|
+
|
|
941
997
|
var __defProp$J = Object.defineProperty;
|
|
942
998
|
var __defNormalProp$J = (obj, key, value) => key in obj ? __defProp$J(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
943
999
|
var __publicField$u = (obj, key, value) => __defNormalProp$J(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
@@ -1564,6 +1620,7 @@ class NgwConnector {
|
|
|
1564
1620
|
__publicField$p(this, "resources");
|
|
1565
1621
|
__publicField$p(this, "cache");
|
|
1566
1622
|
__publicField$p(this, "withCredentials");
|
|
1623
|
+
__publicField$p(this, "client", `NextGIS-NGW-Connector/${pkg.version}`);
|
|
1567
1624
|
__publicField$p(this, "routeStr", "/api/component/pyramid/route");
|
|
1568
1625
|
__publicField$p(this, "activeRequests", {});
|
|
1569
1626
|
__publicField$p(this, "requestTransform");
|
|
@@ -1634,8 +1691,9 @@ class NgwConnector {
|
|
|
1634
1691
|
yield this._login({ login, password });
|
|
1635
1692
|
}
|
|
1636
1693
|
}
|
|
1694
|
+
const routeUrl = `${this.routeStr}?client=${this.client}`;
|
|
1637
1695
|
return yield this.makeQuery(
|
|
1638
|
-
|
|
1696
|
+
routeUrl,
|
|
1639
1697
|
{},
|
|
1640
1698
|
{
|
|
1641
1699
|
cacheName: "route",
|
|
@@ -2206,7 +2264,7 @@ function updateItemRequestParam(params, options) {
|
|
|
2206
2264
|
if (extensionsStr !== "*") {
|
|
2207
2265
|
params.extensions = extensionsStr;
|
|
2208
2266
|
}
|
|
2209
|
-
if (fields !== void 0) {
|
|
2267
|
+
if (fields !== void 0 && fields !== null) {
|
|
2210
2268
|
params.fields = Array.isArray(fields) ? fields.join(",") : "";
|
|
2211
2269
|
}
|
|
2212
2270
|
if (geom !== void 0) {
|