@opengeoweb/store 12.10.0 → 12.12.0
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/index.esm.js +497 -497
- package/package.json +6 -6
- package/src/store/generic/selectors.d.ts +18 -18
- package/src/store/map/layer/selectors.d.ts +40 -0
- package/src/store/map/map/index.d.ts +1 -1
- package/src/store/map/map/reducer.d.ts +10 -2
- package/src/store/map/map/selectors.d.ts +31 -4
- package/src/store/map/map/types.d.ts +1 -0
package/index.esm.js
CHANGED
|
@@ -13,6 +13,9 @@ import { metronome } from '@opengeoweb/metronome';
|
|
|
13
13
|
import { View, Observable } from 'ol';
|
|
14
14
|
import { boundingExtent, getCenter } from 'ol/extent';
|
|
15
15
|
|
|
16
|
+
function _OverloadYield(e, d) {
|
|
17
|
+
this.v = e, this.k = d;
|
|
18
|
+
}
|
|
16
19
|
function _arrayLikeToArray(r, a) {
|
|
17
20
|
(null == a || a > r.length) && (a = r.length);
|
|
18
21
|
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
@@ -233,306 +236,180 @@ function _possibleConstructorReturn(t, e) {
|
|
|
233
236
|
if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined");
|
|
234
237
|
return _assertThisInitialized(t);
|
|
235
238
|
}
|
|
236
|
-
function
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
239
|
+
function _regenerator() {
|
|
240
|
+
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
|
|
241
|
+
var e,
|
|
242
|
+
t,
|
|
243
|
+
r = "function" == typeof Symbol ? Symbol : {},
|
|
244
|
+
n = r.iterator || "@@iterator",
|
|
245
|
+
o = r.toStringTag || "@@toStringTag";
|
|
246
|
+
function i(r, n, o, i) {
|
|
247
|
+
var c = n && n.prototype instanceof Generator ? n : Generator,
|
|
248
|
+
u = Object.create(c.prototype);
|
|
249
|
+
return _regeneratorDefine(u, "_invoke", function (r, n, o) {
|
|
250
|
+
var i,
|
|
251
|
+
c,
|
|
252
|
+
u,
|
|
253
|
+
f = 0,
|
|
254
|
+
p = o || [],
|
|
255
|
+
y = false,
|
|
256
|
+
G = {
|
|
257
|
+
p: 0,
|
|
258
|
+
n: 0,
|
|
259
|
+
v: e,
|
|
260
|
+
a: d,
|
|
261
|
+
f: d.bind(e, 4),
|
|
262
|
+
d: function (t, r) {
|
|
263
|
+
return i = t, c = 0, u = e, G.n = r, a;
|
|
264
|
+
}
|
|
265
|
+
};
|
|
266
|
+
function d(r, n) {
|
|
267
|
+
for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) {
|
|
268
|
+
var o,
|
|
269
|
+
i = p[t],
|
|
270
|
+
d = G.p,
|
|
271
|
+
l = i[2];
|
|
272
|
+
r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0));
|
|
273
|
+
}
|
|
274
|
+
if (o || r > 1) return a;
|
|
275
|
+
throw y = true, n;
|
|
276
|
+
}
|
|
277
|
+
return function (o, p, l) {
|
|
278
|
+
if (f > 1) throw TypeError("Generator is already running");
|
|
279
|
+
for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) {
|
|
280
|
+
i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u);
|
|
281
|
+
try {
|
|
282
|
+
if (f = 2, i) {
|
|
283
|
+
if (c || (o = "next"), t = i[o]) {
|
|
284
|
+
if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object");
|
|
285
|
+
if (!t.done) return t;
|
|
286
|
+
u = t.value, c < 2 && (c = 0);
|
|
287
|
+
} else 1 === c && (t = i.return) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1);
|
|
288
|
+
i = e;
|
|
289
|
+
} else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break;
|
|
290
|
+
} catch (t) {
|
|
291
|
+
i = e, c = 1, u = t;
|
|
292
|
+
} finally {
|
|
293
|
+
f = 1;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
return {
|
|
297
|
+
value: t,
|
|
298
|
+
done: y
|
|
299
|
+
};
|
|
284
300
|
};
|
|
285
|
-
}
|
|
301
|
+
}(r, o, i), true), u;
|
|
286
302
|
}
|
|
287
|
-
|
|
288
|
-
var h = "suspendedStart",
|
|
289
|
-
l = "suspendedYield",
|
|
290
|
-
f = "executing",
|
|
291
|
-
s = "completed",
|
|
292
|
-
y = {};
|
|
303
|
+
var a = {};
|
|
293
304
|
function Generator() {}
|
|
294
305
|
function GeneratorFunction() {}
|
|
295
306
|
function GeneratorFunctionPrototype() {}
|
|
296
|
-
|
|
297
|
-
|
|
307
|
+
t = Object.getPrototypeOf;
|
|
308
|
+
var c = [][n] ? t(t([][n]())) : (_regeneratorDefine(t = {}, n, function () {
|
|
309
|
+
return this;
|
|
310
|
+
}), t),
|
|
311
|
+
u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c);
|
|
312
|
+
function f(e) {
|
|
313
|
+
return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e;
|
|
314
|
+
}
|
|
315
|
+
return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine(u), _regeneratorDefine(u, o, "Generator"), _regeneratorDefine(u, n, function () {
|
|
298
316
|
return this;
|
|
317
|
+
}), _regeneratorDefine(u, "toString", function () {
|
|
318
|
+
return "[object Generator]";
|
|
319
|
+
}), (_regenerator = function () {
|
|
320
|
+
return {
|
|
321
|
+
w: i,
|
|
322
|
+
m: f
|
|
323
|
+
};
|
|
324
|
+
})();
|
|
325
|
+
}
|
|
326
|
+
function _regeneratorAsync(n, e, r, t, o) {
|
|
327
|
+
var a = _regeneratorAsyncGen(n, e, r, t, o);
|
|
328
|
+
return a.next().then(function (n) {
|
|
329
|
+
return n.done ? n.value : a.next();
|
|
299
330
|
});
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
331
|
+
}
|
|
332
|
+
function _regeneratorAsyncGen(r, e, t, o, n) {
|
|
333
|
+
return new _regeneratorAsyncIterator(_regenerator().w(r, e, t, o), n || Promise);
|
|
334
|
+
}
|
|
335
|
+
function _regeneratorAsyncIterator(t, e) {
|
|
336
|
+
function n(r, o, i, f) {
|
|
337
|
+
try {
|
|
338
|
+
var c = t[r](o),
|
|
339
|
+
u = c.value;
|
|
340
|
+
return u instanceof _OverloadYield ? e.resolve(u.v).then(function (t) {
|
|
341
|
+
n("next", t, i, f);
|
|
342
|
+
}, function (t) {
|
|
343
|
+
n("throw", t, i, f);
|
|
344
|
+
}) : e.resolve(u).then(function (t) {
|
|
345
|
+
c.value = t, i(c);
|
|
346
|
+
}, function (t) {
|
|
347
|
+
return n("throw", t, i, f);
|
|
308
348
|
});
|
|
309
|
-
})
|
|
349
|
+
} catch (t) {
|
|
350
|
+
f(t);
|
|
351
|
+
}
|
|
310
352
|
}
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
353
|
+
var r;
|
|
354
|
+
this.next || (_regeneratorDefine(_regeneratorAsyncIterator.prototype), _regeneratorDefine(_regeneratorAsyncIterator.prototype, "function" == typeof Symbol && Symbol.asyncIterator || "@asyncIterator", function () {
|
|
355
|
+
return this;
|
|
356
|
+
})), _regeneratorDefine(this, "_invoke", function (t, o, i) {
|
|
357
|
+
function f() {
|
|
358
|
+
return new e(function (e, r) {
|
|
359
|
+
n(t, i, e, r);
|
|
360
|
+
});
|
|
361
|
+
}
|
|
362
|
+
return r = r ? r.then(f, f) : f();
|
|
363
|
+
}, true);
|
|
364
|
+
}
|
|
365
|
+
function _regeneratorDefine(e, r, n, t) {
|
|
366
|
+
var i = Object.defineProperty;
|
|
367
|
+
try {
|
|
368
|
+
i({}, "", {});
|
|
369
|
+
} catch (e) {
|
|
370
|
+
i = 0;
|
|
371
|
+
}
|
|
372
|
+
_regeneratorDefine = function (e, r, n, t) {
|
|
373
|
+
if (r) i ? i(e, r, {
|
|
374
|
+
value: n,
|
|
375
|
+
enumerable: !t,
|
|
376
|
+
configurable: !t,
|
|
377
|
+
writable: !t
|
|
378
|
+
}) : e[r] = n;else {
|
|
379
|
+
function o(r, n) {
|
|
380
|
+
_regeneratorDefine(e, r, function (e) {
|
|
381
|
+
return this._invoke(r, n, e);
|
|
325
382
|
});
|
|
326
383
|
}
|
|
327
|
-
|
|
384
|
+
o("next", 0), o("throw", 1), o("return", 2);
|
|
328
385
|
}
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
var
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
386
|
+
}, _regeneratorDefine(e, r, n, t);
|
|
387
|
+
}
|
|
388
|
+
function _regeneratorKeys(e) {
|
|
389
|
+
var n = Object(e),
|
|
390
|
+
r = [];
|
|
391
|
+
for (var t in n) r.unshift(t);
|
|
392
|
+
return function e() {
|
|
393
|
+
for (; r.length;) if ((t = r.pop()) in n) return e.value = t, e.done = false, e;
|
|
394
|
+
return e.done = true, e;
|
|
395
|
+
};
|
|
396
|
+
}
|
|
397
|
+
function _regeneratorValues(e) {
|
|
398
|
+
if (null != e) {
|
|
399
|
+
var t = e["function" == typeof Symbol && Symbol.iterator || "@@iterator"],
|
|
400
|
+
r = 0;
|
|
401
|
+
if (t) return t.call(e);
|
|
402
|
+
if ("function" == typeof e.next) return e;
|
|
403
|
+
if (!isNaN(e.length)) return {
|
|
404
|
+
next: function () {
|
|
405
|
+
return e && r >= e.length && (e = void 0), {
|
|
406
|
+
value: e && e[r++],
|
|
407
|
+
done: !e
|
|
350
408
|
};
|
|
351
409
|
}
|
|
352
|
-
for (n.method = i, n.arg = a;;) {
|
|
353
|
-
var c = n.delegate;
|
|
354
|
-
if (c) {
|
|
355
|
-
var u = maybeInvokeDelegate(c, n);
|
|
356
|
-
if (u) {
|
|
357
|
-
if (u === y) continue;
|
|
358
|
-
return u;
|
|
359
|
-
}
|
|
360
|
-
}
|
|
361
|
-
if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
|
|
362
|
-
if (o === h) throw o = s, n.arg;
|
|
363
|
-
n.dispatchException(n.arg);
|
|
364
|
-
} else "return" === n.method && n.abrupt("return", n.arg);
|
|
365
|
-
o = f;
|
|
366
|
-
var p = tryCatch(e, r, n);
|
|
367
|
-
if ("normal" === p.type) {
|
|
368
|
-
if (o = n.done ? s : l, p.arg === y) continue;
|
|
369
|
-
return {
|
|
370
|
-
value: p.arg,
|
|
371
|
-
done: n.done
|
|
372
|
-
};
|
|
373
|
-
}
|
|
374
|
-
"throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
|
|
375
|
-
}
|
|
376
410
|
};
|
|
377
411
|
}
|
|
378
|
-
|
|
379
|
-
var n = r.method,
|
|
380
|
-
o = e.iterator[n];
|
|
381
|
-
if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
|
|
382
|
-
var i = tryCatch(o, e.iterator, r.arg);
|
|
383
|
-
if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
|
|
384
|
-
var a = i.arg;
|
|
385
|
-
return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
|
|
386
|
-
}
|
|
387
|
-
function pushTryEntry(t) {
|
|
388
|
-
var e = {
|
|
389
|
-
tryLoc: t[0]
|
|
390
|
-
};
|
|
391
|
-
1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
|
|
392
|
-
}
|
|
393
|
-
function resetTryEntry(t) {
|
|
394
|
-
var e = t.completion || {};
|
|
395
|
-
e.type = "normal", delete e.arg, t.completion = e;
|
|
396
|
-
}
|
|
397
|
-
function Context(t) {
|
|
398
|
-
this.tryEntries = [{
|
|
399
|
-
tryLoc: "root"
|
|
400
|
-
}], t.forEach(pushTryEntry, this), this.reset(true);
|
|
401
|
-
}
|
|
402
|
-
function values(e) {
|
|
403
|
-
if (e || "" === e) {
|
|
404
|
-
var r = e[a];
|
|
405
|
-
if (r) return r.call(e);
|
|
406
|
-
if ("function" == typeof e.next) return e;
|
|
407
|
-
if (!isNaN(e.length)) {
|
|
408
|
-
var o = -1,
|
|
409
|
-
i = function next() {
|
|
410
|
-
for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = false, next;
|
|
411
|
-
return next.value = t, next.done = true, next;
|
|
412
|
-
};
|
|
413
|
-
return i.next = i;
|
|
414
|
-
}
|
|
415
|
-
}
|
|
416
|
-
throw new TypeError(typeof e + " is not iterable");
|
|
417
|
-
}
|
|
418
|
-
return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
|
|
419
|
-
value: GeneratorFunctionPrototype,
|
|
420
|
-
configurable: true
|
|
421
|
-
}), o(GeneratorFunctionPrototype, "constructor", {
|
|
422
|
-
value: GeneratorFunction,
|
|
423
|
-
configurable: true
|
|
424
|
-
}), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
|
|
425
|
-
var e = "function" == typeof t && t.constructor;
|
|
426
|
-
return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
|
|
427
|
-
}, e.mark = function (t) {
|
|
428
|
-
return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
|
|
429
|
-
}, e.awrap = function (t) {
|
|
430
|
-
return {
|
|
431
|
-
__await: t
|
|
432
|
-
};
|
|
433
|
-
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
|
|
434
|
-
return this;
|
|
435
|
-
}), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
|
|
436
|
-
void 0 === i && (i = Promise);
|
|
437
|
-
var a = new AsyncIterator(wrap(t, r, n, o), i);
|
|
438
|
-
return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
|
|
439
|
-
return t.done ? t.value : a.next();
|
|
440
|
-
});
|
|
441
|
-
}, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
|
|
442
|
-
return this;
|
|
443
|
-
}), define(g, "toString", function () {
|
|
444
|
-
return "[object Generator]";
|
|
445
|
-
}), e.keys = function (t) {
|
|
446
|
-
var e = Object(t),
|
|
447
|
-
r = [];
|
|
448
|
-
for (var n in e) r.push(n);
|
|
449
|
-
return r.reverse(), function next() {
|
|
450
|
-
for (; r.length;) {
|
|
451
|
-
var t = r.pop();
|
|
452
|
-
if (t in e) return next.value = t, next.done = false, next;
|
|
453
|
-
}
|
|
454
|
-
return next.done = true, next;
|
|
455
|
-
};
|
|
456
|
-
}, e.values = values, Context.prototype = {
|
|
457
|
-
constructor: Context,
|
|
458
|
-
reset: function (e) {
|
|
459
|
-
if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = false, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
|
|
460
|
-
},
|
|
461
|
-
stop: function () {
|
|
462
|
-
this.done = true;
|
|
463
|
-
var t = this.tryEntries[0].completion;
|
|
464
|
-
if ("throw" === t.type) throw t.arg;
|
|
465
|
-
return this.rval;
|
|
466
|
-
},
|
|
467
|
-
dispatchException: function (e) {
|
|
468
|
-
if (this.done) throw e;
|
|
469
|
-
var r = this;
|
|
470
|
-
function handle(n, o) {
|
|
471
|
-
return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
|
|
472
|
-
}
|
|
473
|
-
for (var o = this.tryEntries.length - 1; o >= 0; --o) {
|
|
474
|
-
var i = this.tryEntries[o],
|
|
475
|
-
a = i.completion;
|
|
476
|
-
if ("root" === i.tryLoc) return handle("end");
|
|
477
|
-
if (i.tryLoc <= this.prev) {
|
|
478
|
-
var c = n.call(i, "catchLoc"),
|
|
479
|
-
u = n.call(i, "finallyLoc");
|
|
480
|
-
if (c && u) {
|
|
481
|
-
if (this.prev < i.catchLoc) return handle(i.catchLoc, true);
|
|
482
|
-
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
|
483
|
-
} else if (c) {
|
|
484
|
-
if (this.prev < i.catchLoc) return handle(i.catchLoc, true);
|
|
485
|
-
} else {
|
|
486
|
-
if (!u) throw Error("try statement without catch or finally");
|
|
487
|
-
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
|
488
|
-
}
|
|
489
|
-
}
|
|
490
|
-
}
|
|
491
|
-
},
|
|
492
|
-
abrupt: function (t, e) {
|
|
493
|
-
for (var r = this.tryEntries.length - 1; r >= 0; --r) {
|
|
494
|
-
var o = this.tryEntries[r];
|
|
495
|
-
if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
|
|
496
|
-
var i = o;
|
|
497
|
-
break;
|
|
498
|
-
}
|
|
499
|
-
}
|
|
500
|
-
i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
|
|
501
|
-
var a = i ? i.completion : {};
|
|
502
|
-
return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
|
|
503
|
-
},
|
|
504
|
-
complete: function (t, e) {
|
|
505
|
-
if ("throw" === t.type) throw t.arg;
|
|
506
|
-
return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
|
|
507
|
-
},
|
|
508
|
-
finish: function (t) {
|
|
509
|
-
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
|
510
|
-
var r = this.tryEntries[e];
|
|
511
|
-
if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
|
|
512
|
-
}
|
|
513
|
-
},
|
|
514
|
-
catch: function (t) {
|
|
515
|
-
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
|
516
|
-
var r = this.tryEntries[e];
|
|
517
|
-
if (r.tryLoc === t) {
|
|
518
|
-
var n = r.completion;
|
|
519
|
-
if ("throw" === n.type) {
|
|
520
|
-
var o = n.arg;
|
|
521
|
-
resetTryEntry(r);
|
|
522
|
-
}
|
|
523
|
-
return o;
|
|
524
|
-
}
|
|
525
|
-
}
|
|
526
|
-
throw Error("illegal catch attempt");
|
|
527
|
-
},
|
|
528
|
-
delegateYield: function (e, r, n) {
|
|
529
|
-
return this.delegate = {
|
|
530
|
-
iterator: values(e),
|
|
531
|
-
resultName: r,
|
|
532
|
-
nextLoc: n
|
|
533
|
-
}, "next" === this.method && (this.arg = t), y;
|
|
534
|
-
}
|
|
535
|
-
}, e;
|
|
412
|
+
throw new TypeError(typeof e + " is not iterable");
|
|
536
413
|
}
|
|
537
414
|
function _setPrototypeOf(t, e) {
|
|
538
415
|
return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
|
|
@@ -575,6 +452,74 @@ function _unsupportedIterableToArray(r, a) {
|
|
|
575
452
|
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
576
453
|
}
|
|
577
454
|
}
|
|
455
|
+
function _regeneratorRuntime() {
|
|
456
|
+
|
|
457
|
+
var r = _regenerator(),
|
|
458
|
+
e = r.m(_regeneratorRuntime),
|
|
459
|
+
t = (Object.getPrototypeOf ? Object.getPrototypeOf(e) : e.__proto__).constructor;
|
|
460
|
+
function n(r) {
|
|
461
|
+
var e = "function" == typeof r && r.constructor;
|
|
462
|
+
return !!e && (e === t || "GeneratorFunction" === (e.displayName || e.name));
|
|
463
|
+
}
|
|
464
|
+
var o = {
|
|
465
|
+
throw: 1,
|
|
466
|
+
return: 2,
|
|
467
|
+
break: 3,
|
|
468
|
+
continue: 3
|
|
469
|
+
};
|
|
470
|
+
function a(r) {
|
|
471
|
+
var e, t;
|
|
472
|
+
return function (n) {
|
|
473
|
+
e || (e = {
|
|
474
|
+
stop: function () {
|
|
475
|
+
return t(n.a, 2);
|
|
476
|
+
},
|
|
477
|
+
catch: function () {
|
|
478
|
+
return n.v;
|
|
479
|
+
},
|
|
480
|
+
abrupt: function (r, e) {
|
|
481
|
+
return t(n.a, o[r], e);
|
|
482
|
+
},
|
|
483
|
+
delegateYield: function (r, o, a) {
|
|
484
|
+
return e.resultName = o, t(n.d, _regeneratorValues(r), a);
|
|
485
|
+
},
|
|
486
|
+
finish: function (r) {
|
|
487
|
+
return t(n.f, r);
|
|
488
|
+
}
|
|
489
|
+
}, t = function (r, t, o) {
|
|
490
|
+
n.p = e.prev, n.n = e.next;
|
|
491
|
+
try {
|
|
492
|
+
return r(t, o);
|
|
493
|
+
} finally {
|
|
494
|
+
e.next = n.n;
|
|
495
|
+
}
|
|
496
|
+
}), e.resultName && (e[e.resultName] = n.v, e.resultName = void 0), e.sent = n.v, e.next = n.n;
|
|
497
|
+
try {
|
|
498
|
+
return r.call(this, e);
|
|
499
|
+
} finally {
|
|
500
|
+
n.p = e.prev, n.n = e.next;
|
|
501
|
+
}
|
|
502
|
+
};
|
|
503
|
+
}
|
|
504
|
+
return (_regeneratorRuntime = function () {
|
|
505
|
+
return {
|
|
506
|
+
wrap: function (e, t, n, o) {
|
|
507
|
+
return r.w(a(e), t, n, o && o.reverse());
|
|
508
|
+
},
|
|
509
|
+
isGeneratorFunction: n,
|
|
510
|
+
mark: r.m,
|
|
511
|
+
awrap: function (r, e) {
|
|
512
|
+
return new _OverloadYield(r, e);
|
|
513
|
+
},
|
|
514
|
+
AsyncIterator: _regeneratorAsyncIterator,
|
|
515
|
+
async: function (r, e, t, o, u) {
|
|
516
|
+
return (n(e) ? _regeneratorAsyncGen : _regeneratorAsync)(a(r), e, t, o, u);
|
|
517
|
+
},
|
|
518
|
+
keys: _regeneratorKeys,
|
|
519
|
+
values: _regeneratorValues
|
|
520
|
+
};
|
|
521
|
+
})();
|
|
522
|
+
}
|
|
578
523
|
|
|
579
524
|
var initialState$6 = {
|
|
580
525
|
byId: {},
|
|
@@ -1611,8 +1556,8 @@ var updateMinMaxValueWhenReferenceTimeChanges = function updateMinMaxValueWhenRe
|
|
|
1611
1556
|
if (wmLayer && wmLayer.dimensions.length >= 2) {
|
|
1612
1557
|
var referenceTimeDimension = wmLayer.getDimension('reference_time');
|
|
1613
1558
|
var timeDimension = wmLayer.getDimension('time');
|
|
1614
|
-
var reduxTimeDim = draftLayer.dimensions.find(function (
|
|
1615
|
-
return
|
|
1559
|
+
var reduxTimeDim = draftLayer.dimensions.find(function (dimension) {
|
|
1560
|
+
return dimension.name === 'time';
|
|
1616
1561
|
});
|
|
1617
1562
|
if (reduxTimeDim && timeDimension && referenceTimeDimension) {
|
|
1618
1563
|
// When the reference time changes, a new set of timevalues needs to be set in the layer.
|
|
@@ -1772,9 +1717,9 @@ var slice$6 = createSlice({
|
|
|
1772
1717
|
}
|
|
1773
1718
|
},
|
|
1774
1719
|
layerSetGeojsonFromLayer: function layerSetGeojsonFromLayer(draft, action) {
|
|
1775
|
-
var _action$
|
|
1776
|
-
layerId = _action$
|
|
1777
|
-
sourceLayerId = _action$
|
|
1720
|
+
var _action$payload0 = action.payload,
|
|
1721
|
+
layerId = _action$payload0.layerId,
|
|
1722
|
+
sourceLayerId = _action$payload0.sourceLayerId;
|
|
1778
1723
|
if (draft.byId[layerId]) {
|
|
1779
1724
|
var _draft$byId$sourceLay;
|
|
1780
1725
|
draft.byId[layerId].geojson = (_draft$byId$sourceLay = draft.byId[sourceLayerId]) === null || _draft$byId$sourceLay === void 0 ? void 0 : _draft$byId$sourceLay.geojson;
|
|
@@ -1808,9 +1753,9 @@ var slice$6 = createSlice({
|
|
|
1808
1753
|
}
|
|
1809
1754
|
},
|
|
1810
1755
|
setLayers: function setLayers(draft, action) {
|
|
1811
|
-
var _action$
|
|
1812
|
-
layers = _action$
|
|
1813
|
-
mapId = _action$
|
|
1756
|
+
var _action$payload1 = action.payload,
|
|
1757
|
+
layers = _action$payload1.layers,
|
|
1758
|
+
mapId = _action$payload1.mapId;
|
|
1814
1759
|
if (!checkValidLayersPayload(layers, mapId)) {
|
|
1815
1760
|
return;
|
|
1816
1761
|
}
|
|
@@ -1838,9 +1783,9 @@ var slice$6 = createSlice({
|
|
|
1838
1783
|
});
|
|
1839
1784
|
},
|
|
1840
1785
|
setBaseLayers: function setBaseLayers(draft, action) {
|
|
1841
|
-
var _action$
|
|
1842
|
-
layers = _action$
|
|
1843
|
-
mapId = _action$
|
|
1786
|
+
var _action$payload10 = action.payload,
|
|
1787
|
+
layers = _action$payload10.layers,
|
|
1788
|
+
mapId = _action$payload10.mapId;
|
|
1844
1789
|
var filtererdBaseLayers = layers.filter(function (layer) {
|
|
1845
1790
|
return layer.layerType === LayerType.baseLayer || layer.layerType === LayerType.overLayer;
|
|
1846
1791
|
});
|
|
@@ -1886,9 +1831,9 @@ var slice$6 = createSlice({
|
|
|
1886
1831
|
}
|
|
1887
1832
|
},
|
|
1888
1833
|
layerSetDimensions: function layerSetDimensions(draft, action) {
|
|
1889
|
-
var _action$
|
|
1890
|
-
dimensions = _action$
|
|
1891
|
-
layerId = _action$
|
|
1834
|
+
var _action$payload11 = action.payload,
|
|
1835
|
+
dimensions = _action$payload11.dimensions,
|
|
1836
|
+
layerId = _action$payload11.layerId;
|
|
1892
1837
|
if (draft.byId[layerId]) {
|
|
1893
1838
|
draft.byId[layerId].dimensions = dimensions;
|
|
1894
1839
|
}
|
|
@@ -1922,9 +1867,9 @@ var slice$6 = createSlice({
|
|
|
1922
1867
|
},
|
|
1923
1868
|
// Overwrites all baselayer for a certain map
|
|
1924
1869
|
setAvailableBaseLayers: function setAvailableBaseLayers(draft, action) {
|
|
1925
|
-
var _action$
|
|
1926
|
-
layers = _action$
|
|
1927
|
-
mapId = _action$
|
|
1870
|
+
var _action$payload12 = action.payload,
|
|
1871
|
+
layers = _action$payload12.layers,
|
|
1872
|
+
mapId = _action$payload12.mapId;
|
|
1928
1873
|
// remove current baselayers for passed map
|
|
1929
1874
|
draft.availableBaseLayers.allIds = draft.availableBaseLayers.allIds.filter(function (layerId) {
|
|
1930
1875
|
if (draft.availableBaseLayers.byId[layerId] && draft.availableBaseLayers.byId[layerId].mapId === mapId) {
|
|
@@ -1943,9 +1888,9 @@ var slice$6 = createSlice({
|
|
|
1943
1888
|
});
|
|
1944
1889
|
},
|
|
1945
1890
|
setUseLatestReferenceTime: function setUseLatestReferenceTime(draft, action) {
|
|
1946
|
-
var _action$
|
|
1947
|
-
id = _action$
|
|
1948
|
-
useLatestReferenceTime = _action$
|
|
1891
|
+
var _action$payload13 = action.payload,
|
|
1892
|
+
id = _action$payload13.id,
|
|
1893
|
+
useLatestReferenceTime = _action$payload13.useLatestReferenceTime;
|
|
1949
1894
|
var layer = draft.byId[id];
|
|
1950
1895
|
if (!layer) {
|
|
1951
1896
|
return;
|
|
@@ -1953,10 +1898,10 @@ var slice$6 = createSlice({
|
|
|
1953
1898
|
layer.useLatestReferenceTime = useLatestReferenceTime;
|
|
1954
1899
|
},
|
|
1955
1900
|
onUpdateLayerInformation: function onUpdateLayerInformation(draft, action) {
|
|
1956
|
-
var _action$
|
|
1957
|
-
layerStyle = _action$
|
|
1958
|
-
layerDimensions = _action$
|
|
1959
|
-
error = _action$
|
|
1901
|
+
var _action$payload14 = action.payload,
|
|
1902
|
+
layerStyle = _action$payload14.layerStyle,
|
|
1903
|
+
layerDimensions = _action$payload14.layerDimensions,
|
|
1904
|
+
error = _action$payload14.error;
|
|
1960
1905
|
if (error) {
|
|
1961
1906
|
draft.byId[error.layerId].status = LayerStatus.error;
|
|
1962
1907
|
return;
|
|
@@ -2045,25 +1990,25 @@ var slice$6 = createSlice({
|
|
|
2045
1990
|
},
|
|
2046
1991
|
// feature layer actions
|
|
2047
1992
|
setSelectedFeature: function setSelectedFeature(draft, action) {
|
|
2048
|
-
var _action$
|
|
2049
|
-
layerId = _action$
|
|
2050
|
-
selectedFeatureIndex = _action$
|
|
1993
|
+
var _action$payload15 = action.payload,
|
|
1994
|
+
layerId = _action$payload15.layerId,
|
|
1995
|
+
selectedFeatureIndex = _action$payload15.selectedFeatureIndex;
|
|
2051
1996
|
if (!draft.byId[layerId]) {
|
|
2052
1997
|
return;
|
|
2053
1998
|
}
|
|
2054
1999
|
draft.byId[layerId].selectedFeatureIndex = selectedFeatureIndex;
|
|
2055
2000
|
},
|
|
2056
2001
|
updateFeature: function updateFeature(draft, action) {
|
|
2057
|
-
var _action$
|
|
2058
|
-
layerId = _action$
|
|
2059
|
-
geojson = _action$
|
|
2060
|
-
_action$
|
|
2061
|
-
shouldAllowMultipleShapes = _action$
|
|
2062
|
-
_action$
|
|
2063
|
-
reason = _action$
|
|
2064
|
-
geoJSONIntersectionLayerId = _action$
|
|
2065
|
-
geoJSONIntersectionBoundsLayerId = _action$
|
|
2066
|
-
selectionType = _action$
|
|
2002
|
+
var _action$payload16 = action.payload,
|
|
2003
|
+
layerId = _action$payload16.layerId,
|
|
2004
|
+
geojson = _action$payload16.geojson,
|
|
2005
|
+
_action$payload16$sho = _action$payload16.shouldAllowMultipleShapes,
|
|
2006
|
+
shouldAllowMultipleShapes = _action$payload16$sho === void 0 ? false : _action$payload16$sho,
|
|
2007
|
+
_action$payload16$rea = _action$payload16.reason,
|
|
2008
|
+
reason = _action$payload16$rea === void 0 ? '' : _action$payload16$rea,
|
|
2009
|
+
geoJSONIntersectionLayerId = _action$payload16.geoJSONIntersectionLayerId,
|
|
2010
|
+
geoJSONIntersectionBoundsLayerId = _action$payload16.geoJSONIntersectionBoundsLayerId,
|
|
2011
|
+
selectionType = _action$payload16.selectionType;
|
|
2067
2012
|
var currentLayer = draft.byId[layerId];
|
|
2068
2013
|
if (!currentLayer) {
|
|
2069
2014
|
return;
|
|
@@ -2092,10 +2037,10 @@ var slice$6 = createSlice({
|
|
|
2092
2037
|
}
|
|
2093
2038
|
},
|
|
2094
2039
|
updateFeatureProperties: function updateFeatureProperties(draft, action) {
|
|
2095
|
-
var _action$
|
|
2096
|
-
layerId = _action$
|
|
2097
|
-
properties = _action$
|
|
2098
|
-
selectedFeatureIndex = _action$
|
|
2040
|
+
var _action$payload17 = action.payload,
|
|
2041
|
+
layerId = _action$payload17.layerId,
|
|
2042
|
+
properties = _action$payload17.properties,
|
|
2043
|
+
selectedFeatureIndex = _action$payload17.selectedFeatureIndex;
|
|
2099
2044
|
var currentLayer = draft.byId[layerId];
|
|
2100
2045
|
if (!currentLayer) {
|
|
2101
2046
|
return;
|
|
@@ -2111,10 +2056,10 @@ var slice$6 = createSlice({
|
|
|
2111
2056
|
}
|
|
2112
2057
|
},
|
|
2113
2058
|
toggleFeatureMode: function toggleFeatureMode(draft, action) {
|
|
2114
|
-
var _action$
|
|
2115
|
-
layerId = _action$
|
|
2116
|
-
isInEditMode = _action$
|
|
2117
|
-
drawMode = _action$
|
|
2059
|
+
var _action$payload18 = action.payload,
|
|
2060
|
+
layerId = _action$payload18.layerId,
|
|
2061
|
+
isInEditMode = _action$payload18.isInEditMode,
|
|
2062
|
+
drawMode = _action$payload18.drawMode;
|
|
2118
2063
|
if (!draft.byId[layerId]) {
|
|
2119
2064
|
return;
|
|
2120
2065
|
}
|
|
@@ -2126,10 +2071,10 @@ var slice$6 = createSlice({
|
|
|
2126
2071
|
}
|
|
2127
2072
|
},
|
|
2128
2073
|
exitFeatureDrawMode: function exitFeatureDrawMode(draft, action) {
|
|
2129
|
-
var _action$
|
|
2130
|
-
layerId = _action$
|
|
2131
|
-
shouldAllowMultipleShapes = _action$
|
|
2132
|
-
reason = _action$
|
|
2074
|
+
var _action$payload19 = action.payload,
|
|
2075
|
+
layerId = _action$payload19.layerId,
|
|
2076
|
+
shouldAllowMultipleShapes = _action$payload19.shouldAllowMultipleShapes,
|
|
2077
|
+
reason = _action$payload19.reason;
|
|
2133
2078
|
if (!draft.byId[layerId]) {
|
|
2134
2079
|
return;
|
|
2135
2080
|
}
|
|
@@ -2154,9 +2099,9 @@ var slice$6 = createSlice({
|
|
|
2154
2099
|
},
|
|
2155
2100
|
// layer info actions
|
|
2156
2101
|
showLayerInfo: function showLayerInfo(draft, action) {
|
|
2157
|
-
var _action$
|
|
2158
|
-
serviceUrl = _action$
|
|
2159
|
-
layerName = _action$
|
|
2102
|
+
var _action$payload20 = action.payload,
|
|
2103
|
+
serviceUrl = _action$payload20.serviceUrl,
|
|
2104
|
+
layerName = _action$payload20.layerName;
|
|
2160
2105
|
draft.activeLayerInfo = {
|
|
2161
2106
|
serviceUrl: serviceUrl,
|
|
2162
2107
|
layerName: layerName
|
|
@@ -2168,9 +2113,9 @@ var slice$6 = createSlice({
|
|
|
2168
2113
|
},
|
|
2169
2114
|
extraReducers: function extraReducers(builder) {
|
|
2170
2115
|
builder.addCase(setTimeSync, function (draft, action) {
|
|
2171
|
-
var _action$
|
|
2172
|
-
targetsFromAction = _action$
|
|
2173
|
-
source = _action$
|
|
2116
|
+
var _action$payload21 = action.payload,
|
|
2117
|
+
targetsFromAction = _action$payload21.targets,
|
|
2118
|
+
source = _action$payload21.source;
|
|
2174
2119
|
/* Because we want backwards compatibility with the previous code, we also need to listen to the original source action */
|
|
2175
2120
|
var targets = [];
|
|
2176
2121
|
if (source) {
|
|
@@ -2197,9 +2142,9 @@ var slice$6 = createSlice({
|
|
|
2197
2142
|
* These targets can be used as payloads in new Layer actions.
|
|
2198
2143
|
* These actions are here handled via the layer reducer, as it is the same logic
|
|
2199
2144
|
*/
|
|
2200
|
-
var _action$
|
|
2201
|
-
targets = _action$
|
|
2202
|
-
source = _action$
|
|
2145
|
+
var _action$payload22 = action.payload,
|
|
2146
|
+
targets = _action$payload22.targets,
|
|
2147
|
+
source = _action$payload22.source;
|
|
2203
2148
|
return targets.reduce(function (prevState, target) {
|
|
2204
2149
|
var actionType = (source === null || source === void 0 ? void 0 : source.type) || 'GENERIC_SYNC_SETLAYERACTIONS';
|
|
2205
2150
|
var action = {
|
|
@@ -2544,11 +2489,11 @@ var slice$4 = createSlice({
|
|
|
2544
2489
|
draft.byId[mapId].mapLayers = moveArrayElements(draft.byId[mapId].mapLayers, oldIndex, newIndex);
|
|
2545
2490
|
},
|
|
2546
2491
|
setAutoLayerId: function setAutoLayerId(draft, action) {
|
|
2547
|
-
var _action$
|
|
2548
|
-
mapId = _action$
|
|
2549
|
-
layerId = _action$
|
|
2550
|
-
autoTimeStepLayerId = _action$
|
|
2551
|
-
autoUpdateLayerId = _action$
|
|
2492
|
+
var _action$payload0 = action.payload,
|
|
2493
|
+
mapId = _action$payload0.mapId,
|
|
2494
|
+
layerId = _action$payload0.layerId,
|
|
2495
|
+
autoTimeStepLayerId = _action$payload0.autoTimeStepLayerId,
|
|
2496
|
+
autoUpdateLayerId = _action$payload0.autoUpdateLayerId;
|
|
2552
2497
|
var map = draft.byId[mapId];
|
|
2553
2498
|
if (!map) {
|
|
2554
2499
|
return;
|
|
@@ -2565,9 +2510,9 @@ var slice$4 = createSlice({
|
|
|
2565
2510
|
}
|
|
2566
2511
|
},
|
|
2567
2512
|
setAutoTimestepLayerId: function setAutoTimestepLayerId(draft, action) {
|
|
2568
|
-
var _action$
|
|
2569
|
-
mapId = _action$
|
|
2570
|
-
autoTimestepLayerId = _action$
|
|
2513
|
+
var _action$payload1 = action.payload,
|
|
2514
|
+
mapId = _action$payload1.mapId,
|
|
2515
|
+
autoTimestepLayerId = _action$payload1.autoTimestepLayerId;
|
|
2571
2516
|
var map = draft.byId[mapId];
|
|
2572
2517
|
if (!map) {
|
|
2573
2518
|
return;
|
|
@@ -2575,9 +2520,9 @@ var slice$4 = createSlice({
|
|
|
2575
2520
|
map.autoTimeStepLayerId = autoTimestepLayerId;
|
|
2576
2521
|
},
|
|
2577
2522
|
setAutoUpdateLayerId: function setAutoUpdateLayerId(draft, action) {
|
|
2578
|
-
var _action$
|
|
2579
|
-
mapId = _action$
|
|
2580
|
-
autoUpdateLayerId = _action$
|
|
2523
|
+
var _action$payload10 = action.payload,
|
|
2524
|
+
mapId = _action$payload10.mapId,
|
|
2525
|
+
autoUpdateLayerId = _action$payload10.autoUpdateLayerId;
|
|
2581
2526
|
var map = draft.byId[mapId];
|
|
2582
2527
|
if (!map) {
|
|
2583
2528
|
return;
|
|
@@ -2585,135 +2530,135 @@ var slice$4 = createSlice({
|
|
|
2585
2530
|
map.autoUpdateLayerId = autoUpdateLayerId;
|
|
2586
2531
|
},
|
|
2587
2532
|
setTimeSliderWidth: function setTimeSliderWidth(draft, action) {
|
|
2588
|
-
var _action$
|
|
2589
|
-
mapId = _action$
|
|
2590
|
-
timeSliderWidth = _action$
|
|
2533
|
+
var _action$payload11 = action.payload,
|
|
2534
|
+
mapId = _action$payload11.mapId,
|
|
2535
|
+
timeSliderWidth = _action$payload11.timeSliderWidth;
|
|
2591
2536
|
if (!draft.byId[mapId]) {
|
|
2592
2537
|
return;
|
|
2593
2538
|
}
|
|
2594
2539
|
draft.byId[mapId].timeSliderWidth = timeSliderWidth;
|
|
2595
2540
|
},
|
|
2596
2541
|
setTimeSliderCenterTime: function setTimeSliderCenterTime(draft, action) {
|
|
2597
|
-
var _action$
|
|
2598
|
-
mapId = _action$
|
|
2599
|
-
timeSliderCenterTime = _action$
|
|
2542
|
+
var _action$payload12 = action.payload,
|
|
2543
|
+
mapId = _action$payload12.mapId,
|
|
2544
|
+
timeSliderCenterTime = _action$payload12.timeSliderCenterTime;
|
|
2600
2545
|
if (!draft.byId[mapId]) {
|
|
2601
2546
|
return;
|
|
2602
2547
|
}
|
|
2603
2548
|
draft.byId[mapId].timeSliderCenterTime = timeSliderCenterTime;
|
|
2604
2549
|
},
|
|
2605
2550
|
setTimeSliderSecondsPerPx: function setTimeSliderSecondsPerPx(draft, action) {
|
|
2606
|
-
var _action$
|
|
2607
|
-
mapId = _action$
|
|
2608
|
-
timeSliderSecondsPerPx = _action$
|
|
2551
|
+
var _action$payload13 = action.payload,
|
|
2552
|
+
mapId = _action$payload13.mapId,
|
|
2553
|
+
timeSliderSecondsPerPx = _action$payload13.timeSliderSecondsPerPx;
|
|
2609
2554
|
if (!draft.byId[mapId]) {
|
|
2610
2555
|
return;
|
|
2611
2556
|
}
|
|
2612
2557
|
draft.byId[mapId].timeSliderSecondsPerPx = timeSliderSecondsPerPx;
|
|
2613
2558
|
},
|
|
2614
2559
|
toggleAutoUpdate: function toggleAutoUpdate(draft, action) {
|
|
2615
|
-
var _action$
|
|
2616
|
-
mapId = _action$
|
|
2617
|
-
shouldAutoUpdate = _action$
|
|
2560
|
+
var _action$payload14 = action.payload,
|
|
2561
|
+
mapId = _action$payload14.mapId,
|
|
2562
|
+
shouldAutoUpdate = _action$payload14.shouldAutoUpdate;
|
|
2618
2563
|
if (!draft.byId[mapId]) {
|
|
2619
2564
|
return;
|
|
2620
2565
|
}
|
|
2621
2566
|
draft.byId[mapId].isAutoUpdating = shouldAutoUpdate;
|
|
2622
2567
|
},
|
|
2623
2568
|
setEndTimeOverriding: function setEndTimeOverriding(draft, action) {
|
|
2624
|
-
var _action$
|
|
2625
|
-
mapId = _action$
|
|
2626
|
-
shouldEndtimeOverride = _action$
|
|
2569
|
+
var _action$payload15 = action.payload,
|
|
2570
|
+
mapId = _action$payload15.mapId,
|
|
2571
|
+
shouldEndtimeOverride = _action$payload15.shouldEndtimeOverride;
|
|
2627
2572
|
if (!draft.byId[mapId]) {
|
|
2628
2573
|
return;
|
|
2629
2574
|
}
|
|
2630
2575
|
draft.byId[mapId].shouldEndtimeOverride = shouldEndtimeOverride;
|
|
2631
2576
|
},
|
|
2632
2577
|
toggleTimestepAuto: function toggleTimestepAuto(draft, action) {
|
|
2633
|
-
var _action$
|
|
2634
|
-
mapId = _action$
|
|
2635
|
-
timestepAuto = _action$
|
|
2578
|
+
var _action$payload16 = action.payload,
|
|
2579
|
+
mapId = _action$payload16.mapId,
|
|
2580
|
+
timestepAuto = _action$payload16.timestepAuto;
|
|
2636
2581
|
if (!draft.byId[mapId]) {
|
|
2637
2582
|
return;
|
|
2638
2583
|
}
|
|
2639
2584
|
draft.byId[mapId].isTimestepAuto = timestepAuto;
|
|
2640
2585
|
},
|
|
2641
2586
|
toggleTimeSpanAuto: function toggleTimeSpanAuto(draft, action) {
|
|
2642
|
-
var _action$
|
|
2643
|
-
mapId = _action$
|
|
2644
|
-
timeSpanAuto = _action$
|
|
2587
|
+
var _action$payload17 = action.payload,
|
|
2588
|
+
mapId = _action$payload17.mapId,
|
|
2589
|
+
timeSpanAuto = _action$payload17.timeSpanAuto;
|
|
2645
2590
|
if (!draft.byId[mapId]) {
|
|
2646
2591
|
return;
|
|
2647
2592
|
}
|
|
2648
2593
|
draft.byId[mapId].isTimeSpanAuto = timeSpanAuto;
|
|
2649
2594
|
},
|
|
2650
2595
|
toggleAnimationLengthAuto: function toggleAnimationLengthAuto(draft, action) {
|
|
2651
|
-
var _action$
|
|
2652
|
-
mapId = _action$
|
|
2653
|
-
autoAnimationLength = _action$
|
|
2596
|
+
var _action$payload18 = action.payload,
|
|
2597
|
+
mapId = _action$payload18.mapId,
|
|
2598
|
+
autoAnimationLength = _action$payload18.autoAnimationLength;
|
|
2654
2599
|
if (!draft.byId[mapId]) {
|
|
2655
2600
|
return;
|
|
2656
2601
|
}
|
|
2657
2602
|
draft.byId[mapId].isAnimationLengthAuto = autoAnimationLength;
|
|
2658
2603
|
},
|
|
2659
2604
|
toggleTimeSliderHover: function toggleTimeSliderHover(draft, action) {
|
|
2660
|
-
var _action$
|
|
2661
|
-
mapId = _action$
|
|
2662
|
-
isTimeSliderHoverOn = _action$
|
|
2605
|
+
var _action$payload19 = action.payload,
|
|
2606
|
+
mapId = _action$payload19.mapId,
|
|
2607
|
+
isTimeSliderHoverOn = _action$payload19.isTimeSliderHoverOn;
|
|
2663
2608
|
if (!draft.byId[mapId]) {
|
|
2664
2609
|
return;
|
|
2665
2610
|
}
|
|
2666
2611
|
draft.byId[mapId].isTimeSliderHoverOn = isTimeSliderHoverOn;
|
|
2667
2612
|
},
|
|
2668
2613
|
toggleTimeSliderIsVisible: function toggleTimeSliderIsVisible(draft, action) {
|
|
2669
|
-
var _action$
|
|
2670
|
-
mapId = _action$
|
|
2671
|
-
isTimeSliderVisible = _action$
|
|
2614
|
+
var _action$payload20 = action.payload,
|
|
2615
|
+
mapId = _action$payload20.mapId,
|
|
2616
|
+
isTimeSliderVisible = _action$payload20.isTimeSliderVisible;
|
|
2672
2617
|
if (!draft.byId[mapId]) {
|
|
2673
2618
|
return;
|
|
2674
2619
|
}
|
|
2675
2620
|
draft.byId[mapId].isTimeSliderVisible = isTimeSliderVisible;
|
|
2676
2621
|
},
|
|
2677
2622
|
toggleZoomControls: function toggleZoomControls(draft, action) {
|
|
2678
|
-
var _action$
|
|
2679
|
-
mapId = _action$
|
|
2680
|
-
shouldShowZoomControls = _action$
|
|
2623
|
+
var _action$payload21 = action.payload,
|
|
2624
|
+
mapId = _action$payload21.mapId,
|
|
2625
|
+
shouldShowZoomControls = _action$payload21.shouldShowZoomControls;
|
|
2681
2626
|
if (!draft.byId[mapId]) {
|
|
2682
2627
|
return;
|
|
2683
2628
|
}
|
|
2684
2629
|
draft.byId[mapId].shouldShowZoomControls = shouldShowZoomControls;
|
|
2685
2630
|
},
|
|
2686
2631
|
setMapPinLocation: function setMapPinLocation(draft, action) {
|
|
2687
|
-
var _action$
|
|
2688
|
-
mapId = _action$
|
|
2689
|
-
mapPinLocation = _action$
|
|
2632
|
+
var _action$payload22 = action.payload,
|
|
2633
|
+
mapId = _action$payload22.mapId,
|
|
2634
|
+
mapPinLocation = _action$payload22.mapPinLocation;
|
|
2690
2635
|
if (!draft.byId[mapId]) {
|
|
2691
2636
|
return;
|
|
2692
2637
|
}
|
|
2693
2638
|
draft.byId[mapId].mapPinLocation = mapPinLocation;
|
|
2694
2639
|
},
|
|
2695
2640
|
setDisableMapPin: function setDisableMapPin(draft, action) {
|
|
2696
|
-
var _action$
|
|
2697
|
-
mapId = _action$
|
|
2698
|
-
disableMapPin = _action$
|
|
2641
|
+
var _action$payload23 = action.payload,
|
|
2642
|
+
mapId = _action$payload23.mapId,
|
|
2643
|
+
disableMapPin = _action$payload23.disableMapPin;
|
|
2699
2644
|
if (!draft.byId[mapId]) {
|
|
2700
2645
|
return;
|
|
2701
2646
|
}
|
|
2702
2647
|
draft.byId[mapId].disableMapPin = disableMapPin;
|
|
2703
2648
|
},
|
|
2704
2649
|
toggleMapPinIsVisible: function toggleMapPinIsVisible(draft, action) {
|
|
2705
|
-
var _action$
|
|
2706
|
-
mapId = _action$
|
|
2707
|
-
displayMapPin = _action$
|
|
2650
|
+
var _action$payload24 = action.payload,
|
|
2651
|
+
mapId = _action$payload24.mapId,
|
|
2652
|
+
displayMapPin = _action$payload24.displayMapPin;
|
|
2708
2653
|
if (!draft.byId[mapId]) {
|
|
2709
2654
|
return;
|
|
2710
2655
|
}
|
|
2711
2656
|
draft.byId[mapId].displayMapPin = displayMapPin;
|
|
2712
2657
|
},
|
|
2713
2658
|
setDockedLayerManagerSize: function setDockedLayerManagerSize(draft, action) {
|
|
2714
|
-
var _action$
|
|
2715
|
-
mapId = _action$
|
|
2716
|
-
dockedLayerManagerSize = _action$
|
|
2659
|
+
var _action$payload25 = action.payload,
|
|
2660
|
+
mapId = _action$payload25.mapId,
|
|
2661
|
+
dockedLayerManagerSize = _action$payload25.dockedLayerManagerSize;
|
|
2717
2662
|
if (!draft.byId[mapId]) {
|
|
2718
2663
|
return;
|
|
2719
2664
|
}
|
|
@@ -2726,14 +2671,23 @@ var slice$4 = createSlice({
|
|
|
2726
2671
|
action) {},
|
|
2727
2672
|
setDefaultMapSettings: function setDefaultMapSettings(draft, action) {
|
|
2728
2673
|
draft.defaultMapSettings = action.payload.preset;
|
|
2674
|
+
},
|
|
2675
|
+
changeOverlayer: function changeOverlayer(draft, action) {
|
|
2676
|
+
var _action$payload26 = action.payload,
|
|
2677
|
+
mapId = _action$payload26.mapId,
|
|
2678
|
+
selectedOverlayer = _action$payload26.selectedOverlayer;
|
|
2679
|
+
if (!draft.byId[mapId]) {
|
|
2680
|
+
return;
|
|
2681
|
+
}
|
|
2682
|
+
draft.byId[mapId].overLayers = [selectedOverlayer];
|
|
2729
2683
|
}
|
|
2730
2684
|
},
|
|
2731
2685
|
extraReducers: function extraReducers(builder) {
|
|
2732
2686
|
builder.addCase(layerActions.addLayer, function (draft, action) {
|
|
2733
|
-
var _action$
|
|
2734
|
-
layerId = _action$
|
|
2735
|
-
mapId = _action$
|
|
2736
|
-
layer = _action$
|
|
2687
|
+
var _action$payload27 = action.payload,
|
|
2688
|
+
layerId = _action$payload27.layerId,
|
|
2689
|
+
mapId = _action$payload27.mapId,
|
|
2690
|
+
layer = _action$payload27.layer;
|
|
2737
2691
|
if (!draft.byId[mapId]) {
|
|
2738
2692
|
return;
|
|
2739
2693
|
}
|
|
@@ -2752,9 +2706,9 @@ var slice$4 = createSlice({
|
|
|
2752
2706
|
draft.byId[mapId].mapLayers.unshift(layerId);
|
|
2753
2707
|
}
|
|
2754
2708
|
}).addCase(layerActions.duplicateMapLayer, function (draft, action) {
|
|
2755
|
-
var _action$
|
|
2756
|
-
newLayerId = _action$
|
|
2757
|
-
mapId = _action$
|
|
2709
|
+
var _action$payload28 = action.payload,
|
|
2710
|
+
newLayerId = _action$payload28.newLayerId,
|
|
2711
|
+
mapId = _action$payload28.mapId;
|
|
2758
2712
|
if (!draft.byId[mapId]) {
|
|
2759
2713
|
return;
|
|
2760
2714
|
}
|
|
@@ -2764,10 +2718,10 @@ var slice$4 = createSlice({
|
|
|
2764
2718
|
}
|
|
2765
2719
|
draft.byId[mapId].mapLayers.unshift(newLayerId);
|
|
2766
2720
|
}).addCase(layerActions.addBaseLayer, function (draft, action) {
|
|
2767
|
-
var _action$
|
|
2768
|
-
layer = _action$
|
|
2769
|
-
layerId = _action$
|
|
2770
|
-
mapId = _action$
|
|
2721
|
+
var _action$payload29 = action.payload,
|
|
2722
|
+
layer = _action$payload29.layer,
|
|
2723
|
+
layerId = _action$payload29.layerId,
|
|
2724
|
+
mapId = _action$payload29.mapId;
|
|
2771
2725
|
if (!draft.byId[mapId]) {
|
|
2772
2726
|
return;
|
|
2773
2727
|
}
|
|
@@ -2797,9 +2751,9 @@ var slice$4 = createSlice({
|
|
|
2797
2751
|
draft.byId[mapId].autoTimeStepLayerId = activeLayerId;
|
|
2798
2752
|
}
|
|
2799
2753
|
}).addCase(layerActions.setBaseLayers, function (draft, action) {
|
|
2800
|
-
var _action$
|
|
2801
|
-
layers = _action$
|
|
2802
|
-
mapId = _action$
|
|
2754
|
+
var _action$payload30 = action.payload,
|
|
2755
|
+
layers = _action$payload30.layers,
|
|
2756
|
+
mapId = _action$payload30.mapId;
|
|
2803
2757
|
// Split into base and overlayers
|
|
2804
2758
|
var baseLayers = [];
|
|
2805
2759
|
var overLayers = [];
|
|
@@ -2829,9 +2783,9 @@ var slice$4 = createSlice({
|
|
|
2829
2783
|
}
|
|
2830
2784
|
}
|
|
2831
2785
|
}).addCase(layerActions.layerDelete, function (draft, action) {
|
|
2832
|
-
var _action$
|
|
2833
|
-
mapId = _action$
|
|
2834
|
-
layerId = _action$
|
|
2786
|
+
var _action$payload31 = action.payload,
|
|
2787
|
+
mapId = _action$payload31.mapId,
|
|
2788
|
+
layerId = _action$payload31.layerId;
|
|
2835
2789
|
var map = draft.byId[mapId];
|
|
2836
2790
|
if (!map) {
|
|
2837
2791
|
return;
|
|
@@ -2857,9 +2811,9 @@ var slice$4 = createSlice({
|
|
|
2857
2811
|
return id !== layerId;
|
|
2858
2812
|
});
|
|
2859
2813
|
}).addCase(layerActions.baseLayerDelete, function (draft, action) {
|
|
2860
|
-
var _action$
|
|
2861
|
-
mapId = _action$
|
|
2862
|
-
layerId = _action$
|
|
2814
|
+
var _action$payload32 = action.payload,
|
|
2815
|
+
mapId = _action$payload32.mapId,
|
|
2816
|
+
layerId = _action$payload32.layerId;
|
|
2863
2817
|
if (!draft.byId[mapId]) {
|
|
2864
2818
|
return;
|
|
2865
2819
|
}
|
|
@@ -2870,14 +2824,14 @@ var slice$4 = createSlice({
|
|
|
2870
2824
|
return id !== layerId;
|
|
2871
2825
|
});
|
|
2872
2826
|
}).addCase(layerActions.layerChangeDimension, function (draft, action) {
|
|
2873
|
-
var _action$
|
|
2874
|
-
layerId = _action$
|
|
2875
|
-
dimension = _action$
|
|
2827
|
+
var _action$payload33 = action.payload,
|
|
2828
|
+
layerId = _action$payload33.layerId,
|
|
2829
|
+
dimension = _action$payload33.dimension;
|
|
2876
2830
|
produceDraftStateSetMapDimensionFromLayerChangeDimension(draft, layerId, dimension);
|
|
2877
2831
|
}).addCase(setTimeSync, function (draft, action) {
|
|
2878
|
-
var _action$
|
|
2879
|
-
targetsFromAction = _action$
|
|
2880
|
-
source = _action$
|
|
2832
|
+
var _action$payload34 = action.payload,
|
|
2833
|
+
targetsFromAction = _action$payload34.targets,
|
|
2834
|
+
source = _action$payload34.source;
|
|
2881
2835
|
/* Because we want backwards compatibility with the previous code, we also need to listen to the original source action */
|
|
2882
2836
|
var targets = [];
|
|
2883
2837
|
if (source) {
|
|
@@ -2901,9 +2855,9 @@ var slice$4 = createSlice({
|
|
|
2901
2855
|
}
|
|
2902
2856
|
});
|
|
2903
2857
|
}).addCase(setBboxSync, function (draft, action) {
|
|
2904
|
-
var _action$
|
|
2905
|
-
targetsFromAction = _action$
|
|
2906
|
-
source = _action$
|
|
2858
|
+
var _action$payload35 = action.payload,
|
|
2859
|
+
targetsFromAction = _action$payload35.targets,
|
|
2860
|
+
source = _action$payload35.source;
|
|
2907
2861
|
/* Because we want backwards compatibility with the previous code, we also need to listen to the original source action */
|
|
2908
2862
|
var targets = [];
|
|
2909
2863
|
if (source) {
|
|
@@ -2935,9 +2889,9 @@ var slice$4 = createSlice({
|
|
|
2935
2889
|
* These targets can be used as payloads in new Layer actions.
|
|
2936
2890
|
* These actions are here handled via the layer reducer, as it is the same logic
|
|
2937
2891
|
*/
|
|
2938
|
-
var _action$
|
|
2939
|
-
targets = _action$
|
|
2940
|
-
source = _action$
|
|
2892
|
+
var _action$payload36 = action.payload,
|
|
2893
|
+
targets = _action$payload36.targets,
|
|
2894
|
+
source = _action$payload36.source;
|
|
2941
2895
|
return targets.reduce(function (prevState, target) {
|
|
2942
2896
|
var actionType = (source === null || source === void 0 ? void 0 : source.type) || 'GENERIC_SYNC_SETLAYERACTIONS';
|
|
2943
2897
|
var action = {
|
|
@@ -2959,9 +2913,9 @@ var slice$4 = createSlice({
|
|
|
2959
2913
|
});
|
|
2960
2914
|
return draft;
|
|
2961
2915
|
}).addCase(mapChangeDimension, function (draft, action) {
|
|
2962
|
-
var _action$
|
|
2963
|
-
mapId = _action$
|
|
2964
|
-
dimensionFromAction = _action$
|
|
2916
|
+
var _action$payload37 = action.payload,
|
|
2917
|
+
mapId = _action$payload37.mapId,
|
|
2918
|
+
dimensionFromAction = _action$payload37.dimension;
|
|
2965
2919
|
produceDraftStateSetWebMapDimension(draft, mapId, dimensionFromAction, true);
|
|
2966
2920
|
}).addCase(setMapPreset, function (draft, action) {
|
|
2967
2921
|
var mapId = action.payload.mapId;
|
|
@@ -2981,9 +2935,9 @@ var slice$4 = createSlice({
|
|
|
2981
2935
|
draft.byId[mapId].animationDelay = defaultAnimationDelayAtStart;
|
|
2982
2936
|
draft.byId[mapId].dockedLayerManagerSize = '';
|
|
2983
2937
|
}).addCase(uiActions.registerDialog, function (draft, action) {
|
|
2984
|
-
var _action$
|
|
2985
|
-
mapId = _action$
|
|
2986
|
-
type = _action$
|
|
2938
|
+
var _action$payload38 = action.payload,
|
|
2939
|
+
mapId = _action$payload38.mapId,
|
|
2940
|
+
type = _action$payload38.type;
|
|
2987
2941
|
if (!draft.byId[mapId]) {
|
|
2988
2942
|
return;
|
|
2989
2943
|
}
|
|
@@ -3417,6 +3371,27 @@ var getTimeStepForLayerId = createSelector(getLayerTimeDimension, function (time
|
|
|
3417
3371
|
var getActiveLayerInfo = createSelector(layerStore, function (store) {
|
|
3418
3372
|
return store === null || store === void 0 ? void 0 : store.activeLayerInfo;
|
|
3419
3373
|
});
|
|
3374
|
+
/**
|
|
3375
|
+
* Gets all overlayers for a given mapId
|
|
3376
|
+
* Example: overlayers = getOverlayersForMapId(store, 'mapId123')
|
|
3377
|
+
* @param {CoreAppStore} store - The Redux store from which the layers state will be extracted.
|
|
3378
|
+
* @param {string} mapId - The ID of the map for which to retrieve the overlayers.
|
|
3379
|
+
* @returns {Array<{ id: string; name: string }>} - An array of overlayers containing layer information (id and name).
|
|
3380
|
+
*/
|
|
3381
|
+
var getOverlayersForMapId = createSelector([layerStore, function (_store, mapId) {
|
|
3382
|
+
return mapId;
|
|
3383
|
+
}], function (store, mapId) {
|
|
3384
|
+
var overLayers = [];
|
|
3385
|
+
(store === null || store === void 0 ? void 0 : store.byId) && Object.values(store.byId).forEach(function (layer) {
|
|
3386
|
+
if (layer.layerType === LayerType.overLayer && layer.mapId === mapId) {
|
|
3387
|
+
overLayers.push({
|
|
3388
|
+
id: layer.id || '',
|
|
3389
|
+
name: layer.name || ''
|
|
3390
|
+
});
|
|
3391
|
+
}
|
|
3392
|
+
});
|
|
3393
|
+
return overLayers;
|
|
3394
|
+
}, selectorMemoizationOptions);
|
|
3420
3395
|
|
|
3421
3396
|
var selectors$6 = /*#__PURE__*/Object.freeze({
|
|
3422
3397
|
__proto__: null,
|
|
@@ -3452,6 +3427,7 @@ var selectors$6 = /*#__PURE__*/Object.freeze({
|
|
|
3452
3427
|
getLayersByMapId: getLayersByMapId,
|
|
3453
3428
|
getLayersIds: getLayersIds,
|
|
3454
3429
|
getOverLayers: getOverLayers,
|
|
3430
|
+
getOverlayersForMapId: getOverlayersForMapId,
|
|
3455
3431
|
getSelectedFeatureIndex: getSelectedFeatureIndex,
|
|
3456
3432
|
getTimeStepForLayerId: getTimeStepForLayerId,
|
|
3457
3433
|
getUseLatestReferenceTime: getUseLatestReferenceTime
|
|
@@ -3827,18 +3803,18 @@ var constants$2 = /*#__PURE__*/Object.freeze({
|
|
|
3827
3803
|
* @param condition Function to check each element in the array
|
|
3828
3804
|
*/
|
|
3829
3805
|
var removeInPlace = function removeInPlace(inDraftArray, condition) {
|
|
3830
|
-
var
|
|
3806
|
+
var index = 0;
|
|
3831
3807
|
inDraftArray.forEach(function (e, i) {
|
|
3832
3808
|
if (!condition(e)) {
|
|
3833
|
-
if (i !==
|
|
3809
|
+
if (i !== index) {
|
|
3834
3810
|
// eslint-disable-next-line no-param-reassign
|
|
3835
|
-
inDraftArray[
|
|
3811
|
+
inDraftArray[index] = e;
|
|
3836
3812
|
}
|
|
3837
|
-
|
|
3813
|
+
index += 1;
|
|
3838
3814
|
}
|
|
3839
3815
|
});
|
|
3840
3816
|
// eslint-disable-next-line no-param-reassign
|
|
3841
|
-
inDraftArray.length =
|
|
3817
|
+
inDraftArray.length = index;
|
|
3842
3818
|
};
|
|
3843
3819
|
|
|
3844
3820
|
var initialState$2 = {
|
|
@@ -4384,7 +4360,7 @@ var syncGroupsListener = createListenerMiddleware();
|
|
|
4384
4360
|
syncGroupsListener.startListening({
|
|
4385
4361
|
matcher: isAnyOf(syncGroupsActions.syncGroupAddTarget, syncGroupsActions.syncGroupLinkTarget),
|
|
4386
4362
|
effect: function () {
|
|
4387
|
-
var _effect = _asyncToGenerator(
|
|
4363
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, listenerApi) {
|
|
4388
4364
|
var payload, groupId, linked, targetToUpdate, group;
|
|
4389
4365
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
4390
4366
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -4442,7 +4418,7 @@ syncGroupsListener.startListening({
|
|
|
4442
4418
|
syncGroupsListener.startListening({
|
|
4443
4419
|
matcher: isAnyOf(syncGroupsActions.syncGroupAddGroup, syncGroupsActions.syncGroupRemoveGroup, syncGroupsActions.syncGroupAddSource, syncGroupsActions.syncGroupRemoveSource, syncGroupsActions.syncGroupAddTarget, syncGroupsActions.syncGroupRemoveTarget, syncGroupsActions.syncGroupLinkTarget),
|
|
4444
4420
|
effect: function () {
|
|
4445
|
-
var _effect2 = _asyncToGenerator(
|
|
4421
|
+
var _effect2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_, listenerApi) {
|
|
4446
4422
|
var viewState;
|
|
4447
4423
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
4448
4424
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -5571,7 +5547,9 @@ var getLegendId = createSelector(getMapById, function (store) {
|
|
|
5571
5547
|
* @param {string} mapId mapId: string - Id of the map
|
|
5572
5548
|
* @returns {MapPreset} returnType: MapPreset
|
|
5573
5549
|
*/
|
|
5574
|
-
var getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLayers, getBbox, getSrs, getActiveLayerId, getAutoTimeStepLayerId, getAutoUpdateLayerId, isAnimating, isAutoUpdating, isTimeSliderVisible, getDisplayMapPin, isZoomControlsVisible, getMapTimeStep, getMapAnimationDelay, getAnimationStartTime, getAnimationEndTime, getMapTimeSliderSpan, isTimestepAuto, isTimeSpanAuto, getLegendId, getUiStore, function (
|
|
5550
|
+
var getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLayers, getBbox, getSrs, getActiveLayerId, getAutoTimeStepLayerId, getAutoUpdateLayerId, isAnimating, isAutoUpdating, isTimeSliderVisible, getDisplayMapPin, isZoomControlsVisible, getMapTimeStep, getMapAnimationDelay, getAnimationStartTime, getAnimationEndTime, getMapTimeSliderSpan, isTimestepAuto, isTimeSpanAuto, getLegendId, getUiStore, function (_store, mapId) {
|
|
5551
|
+
return mapId;
|
|
5552
|
+
}, function (mapLayers, baseLayers, overLayers, bbox, srs, activeLayerId, autoTimeStepLayerId, autoUpdateLayerId, isAnimating, isAutoUpdating, isTimeSliderVisible, displayMapPin, isZoomControlsVisible, mapTimeStep, mapAnimationDelay, animationStartTime, animationEndTime, timeSliderSpan, isTimestepAuto, isTimeSpanAuto, legendId, uiStore, mapId) {
|
|
5575
5553
|
var _uiStore$dialogs$lege;
|
|
5576
5554
|
var allLayers = [].concat(_toConsumableArray(baseLayers), _toConsumableArray(overLayers), _toConsumableArray(mapLayers)).map(function (_ref3) {
|
|
5577
5555
|
_ref3.mapId;
|
|
@@ -5593,6 +5571,8 @@ var getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLaye
|
|
|
5593
5571
|
duration: getAnimationDuration(animationEndTime, animationStartTime)
|
|
5594
5572
|
};
|
|
5595
5573
|
var shouldShowLegend = legendId ? uiStore === null || uiStore === void 0 || (_uiStore$dialogs$lege = uiStore.dialogs[legendId]) === null || _uiStore$dialogs$lege === void 0 ? void 0 : _uiStore$dialogs$lege.isOpen : false;
|
|
5574
|
+
var dataExplorerDialog = uiStore === null || uiStore === void 0 ? void 0 : uiStore.dialogs[DialogTypes.DataExplorer];
|
|
5575
|
+
var shouldShowDataExplorer = (dataExplorerDialog === null || dataExplorerDialog === void 0 ? void 0 : dataExplorerDialog.isOpen) && (dataExplorerDialog === null || dataExplorerDialog === void 0 ? void 0 : dataExplorerDialog.activeMapId) === mapId || false;
|
|
5596
5576
|
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
|
|
5597
5577
|
layers: allLayers
|
|
5598
5578
|
}, activeLayerId !== undefined && {
|
|
@@ -5615,7 +5595,8 @@ var getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLaye
|
|
|
5615
5595
|
toggleTimestepAuto: isTimestepAuto,
|
|
5616
5596
|
toggleTimeSpanAuto: isTimeSpanAuto,
|
|
5617
5597
|
shouldShowLegend: shouldShowLegend,
|
|
5618
|
-
timeSliderSpan: timeSliderSpan
|
|
5598
|
+
timeSliderSpan: timeSliderSpan,
|
|
5599
|
+
shouldShowDataExplorer: shouldShowDataExplorer
|
|
5619
5600
|
});
|
|
5620
5601
|
}, selectorMemoizationOptions);
|
|
5621
5602
|
/**
|
|
@@ -5738,6 +5719,15 @@ var getdefaultMapSettings = createSelector(getMapStore, function (state) {
|
|
|
5738
5719
|
var getdefaultMapSettingsLayers = createSelector(getdefaultMapSettings, function (state) {
|
|
5739
5720
|
return state && state.layers;
|
|
5740
5721
|
}, selectorMemoizationOptions);
|
|
5722
|
+
/**
|
|
5723
|
+
* Gets the selected overlayer from webmap state
|
|
5724
|
+
*
|
|
5725
|
+
* @param {CoreAppStore} store - The Redux store from which the layers state will be extracted.
|
|
5726
|
+
* @returns {string | null} returnType: string | null
|
|
5727
|
+
*/
|
|
5728
|
+
var getSelectedOverlayerByMapId = createSelector(getMapById, function (store) {
|
|
5729
|
+
return (store === null || store === void 0 ? void 0 : store.overLayers[0]) || null;
|
|
5730
|
+
}, selectorMemoizationOptions);
|
|
5741
5731
|
|
|
5742
5732
|
var selectors$1 = /*#__PURE__*/Object.freeze({
|
|
5743
5733
|
__proto__: null,
|
|
@@ -5788,6 +5778,7 @@ var selectors$1 = /*#__PURE__*/Object.freeze({
|
|
|
5788
5778
|
getMapTimeStep: getMapTimeStep,
|
|
5789
5779
|
getMapTimeStepWithoutDefault: getMapTimeStepWithoutDefault,
|
|
5790
5780
|
getPinLocation: getPinLocation,
|
|
5781
|
+
getSelectedOverlayerByMapId: getSelectedOverlayerByMapId,
|
|
5791
5782
|
getSelectedTime: getSelectedTime,
|
|
5792
5783
|
getSrs: getSrs,
|
|
5793
5784
|
getdefaultMapSettings: getdefaultMapSettings,
|
|
@@ -5867,7 +5858,7 @@ var filterLayers = function filterLayers() {
|
|
|
5867
5858
|
overLayers: overLayers
|
|
5868
5859
|
};
|
|
5869
5860
|
}
|
|
5870
|
-
if (layer.layerType === LayerType.mapLayer) {
|
|
5861
|
+
if (layer.layerType === LayerType.mapLayer || layer.layerType === LayerType.edrLayer) {
|
|
5871
5862
|
return {
|
|
5872
5863
|
mapLayers: mapLayers.concat(parsedLayer),
|
|
5873
5864
|
baseLayers: baseLayers,
|
|
@@ -6283,7 +6274,7 @@ var genericListener = createListenerMiddleware();
|
|
|
6283
6274
|
genericListener.startListening({
|
|
6284
6275
|
actionCreator: setTime,
|
|
6285
6276
|
effect: function () {
|
|
6286
|
-
var _effect = _asyncToGenerator(
|
|
6277
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, listenerApi) {
|
|
6287
6278
|
var payload, value, origin, targets, groups;
|
|
6288
6279
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
6289
6280
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -6314,7 +6305,7 @@ genericListener.startListening({
|
|
|
6314
6305
|
genericListener.startListening({
|
|
6315
6306
|
actionCreator: setBbox,
|
|
6316
6307
|
effect: function () {
|
|
6317
|
-
var _effect2 = _asyncToGenerator(
|
|
6308
|
+
var _effect2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_ref2, listenerApi) {
|
|
6318
6309
|
var payload, targets, groups;
|
|
6319
6310
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
6320
6311
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -6339,7 +6330,7 @@ genericListener.startListening({
|
|
|
6339
6330
|
genericListener.startListening({
|
|
6340
6331
|
matcher: isAnyOf(layerActions.layerChangeName, layerActions.layerChangeEnabled, layerActions.layerChangeOpacity, layerActions.layerChangeDimension, layerActions.layerChangeStyle),
|
|
6341
6332
|
effect: function () {
|
|
6342
|
-
var _effect3 = _asyncToGenerator(
|
|
6333
|
+
var _effect3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(_ref3, listenerApi) {
|
|
6343
6334
|
var payload, type, targets;
|
|
6344
6335
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
6345
6336
|
while (1) switch (_context3.prev = _context3.next) {
|
|
@@ -6372,7 +6363,7 @@ genericListener.startListening({
|
|
|
6372
6363
|
genericListener.startListening({
|
|
6373
6364
|
actionCreator: layerActions.addLayer,
|
|
6374
6365
|
effect: function () {
|
|
6375
|
-
var _effect4 = _asyncToGenerator(
|
|
6366
|
+
var _effect4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(_ref4, listenerApi) {
|
|
6376
6367
|
var payload, type, targets;
|
|
6377
6368
|
return _regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
6378
6369
|
while (1) switch (_context4.prev = _context4.next) {
|
|
@@ -6405,7 +6396,7 @@ genericListener.startListening({
|
|
|
6405
6396
|
genericListener.startListening({
|
|
6406
6397
|
actionCreator: layerActions.duplicateMapLayer,
|
|
6407
6398
|
effect: function () {
|
|
6408
|
-
var _effect5 = _asyncToGenerator(
|
|
6399
|
+
var _effect5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(_ref5, listenerApi) {
|
|
6409
6400
|
var payload, sourceLayer, newPayload, targets;
|
|
6410
6401
|
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
6411
6402
|
while (1) switch (_context5.prev = _context5.next) {
|
|
@@ -6428,7 +6419,7 @@ genericListener.startListening({
|
|
|
6428
6419
|
}
|
|
6429
6420
|
}, _callee5);
|
|
6430
6421
|
}));
|
|
6431
|
-
function effect(_x9,
|
|
6422
|
+
function effect(_x9, _x0) {
|
|
6432
6423
|
return _effect5.apply(this, arguments);
|
|
6433
6424
|
}
|
|
6434
6425
|
return effect;
|
|
@@ -6437,7 +6428,7 @@ genericListener.startListening({
|
|
|
6437
6428
|
genericListener.startListening({
|
|
6438
6429
|
actionCreator: mapActions.layerMoveLayer,
|
|
6439
6430
|
effect: function () {
|
|
6440
|
-
var _effect6 = _asyncToGenerator(
|
|
6431
|
+
var _effect6 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(_ref6, listenerApi) {
|
|
6441
6432
|
var payload, type, targets;
|
|
6442
6433
|
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
6443
6434
|
while (1) switch (_context6.prev = _context6.next) {
|
|
@@ -6461,7 +6452,7 @@ genericListener.startListening({
|
|
|
6461
6452
|
}
|
|
6462
6453
|
}, _callee6);
|
|
6463
6454
|
}));
|
|
6464
|
-
function effect(
|
|
6455
|
+
function effect(_x1, _x10) {
|
|
6465
6456
|
return _effect6.apply(this, arguments);
|
|
6466
6457
|
}
|
|
6467
6458
|
return effect;
|
|
@@ -6470,7 +6461,7 @@ genericListener.startListening({
|
|
|
6470
6461
|
genericListener.startListening({
|
|
6471
6462
|
matcher: isAnyOf(mapActions.setAutoLayerId, mapActions.setAutoUpdateLayerId, mapActions.setAutoTimestepLayerId),
|
|
6472
6463
|
effect: function () {
|
|
6473
|
-
var _effect7 = _asyncToGenerator(
|
|
6464
|
+
var _effect7 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(_ref7, listenerApi) {
|
|
6474
6465
|
var payload, type, targets;
|
|
6475
6466
|
return _regeneratorRuntime().wrap(function _callee7$(_context7) {
|
|
6476
6467
|
while (1) switch (_context7.prev = _context7.next) {
|
|
@@ -6487,7 +6478,7 @@ genericListener.startListening({
|
|
|
6487
6478
|
}
|
|
6488
6479
|
}, _callee7);
|
|
6489
6480
|
}));
|
|
6490
|
-
function effect(
|
|
6481
|
+
function effect(_x11, _x12) {
|
|
6491
6482
|
return _effect7.apply(this, arguments);
|
|
6492
6483
|
}
|
|
6493
6484
|
return effect;
|
|
@@ -6496,7 +6487,7 @@ genericListener.startListening({
|
|
|
6496
6487
|
genericListener.startListening({
|
|
6497
6488
|
actionCreator: layerActions.setBaseLayers,
|
|
6498
6489
|
effect: function () {
|
|
6499
|
-
var _effect8 = _asyncToGenerator(
|
|
6490
|
+
var _effect8 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee8(_ref8, listenerApi) {
|
|
6500
6491
|
var payload, type, targets;
|
|
6501
6492
|
return _regeneratorRuntime().wrap(function _callee8$(_context8) {
|
|
6502
6493
|
while (1) switch (_context8.prev = _context8.next) {
|
|
@@ -6520,7 +6511,7 @@ genericListener.startListening({
|
|
|
6520
6511
|
}
|
|
6521
6512
|
}, _callee8);
|
|
6522
6513
|
}));
|
|
6523
|
-
function effect(
|
|
6514
|
+
function effect(_x13, _x14) {
|
|
6524
6515
|
return _effect8.apply(this, arguments);
|
|
6525
6516
|
}
|
|
6526
6517
|
return effect;
|
|
@@ -6529,7 +6520,7 @@ genericListener.startListening({
|
|
|
6529
6520
|
genericListener.startListening({
|
|
6530
6521
|
actionCreator: layerActions.layerDelete,
|
|
6531
6522
|
effect: function () {
|
|
6532
|
-
var _effect9 = _asyncToGenerator(
|
|
6523
|
+
var _effect9 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee9(_ref9, listenerApi) {
|
|
6533
6524
|
var payload, type, targets;
|
|
6534
6525
|
return _regeneratorRuntime().wrap(function _callee9$(_context9) {
|
|
6535
6526
|
while (1) switch (_context9.prev = _context9.next) {
|
|
@@ -6553,7 +6544,7 @@ genericListener.startListening({
|
|
|
6553
6544
|
}
|
|
6554
6545
|
}, _callee9);
|
|
6555
6546
|
}));
|
|
6556
|
-
function effect(
|
|
6547
|
+
function effect(_x15, _x16) {
|
|
6557
6548
|
return _effect9.apply(this, arguments);
|
|
6558
6549
|
}
|
|
6559
6550
|
return effect;
|
|
@@ -6629,27 +6620,27 @@ var isNextStepAvailable = function isNextStepAvailable(reduxLayers, nextTimeStri
|
|
|
6629
6620
|
// Get all wmLayers for the found id's
|
|
6630
6621
|
var wmLayers = reduxLayers.map(function (reduxLayer) {
|
|
6631
6622
|
return reduxLayer.id && getWMLayerById(reduxLayer.id);
|
|
6632
|
-
}).filter(function (
|
|
6633
|
-
return !!
|
|
6623
|
+
}).filter(function (layer) {
|
|
6624
|
+
return !!layer;
|
|
6634
6625
|
});
|
|
6635
6626
|
// Returns a layer which could have an image for the requested time, but which isn't loaded yet.
|
|
6636
|
-
var isThereSomethingNotAvailable = wmLayers.map(function (
|
|
6637
|
-
var
|
|
6638
|
-
if (!
|
|
6627
|
+
var isThereSomethingNotAvailable = wmLayers.map(function (layer) {
|
|
6628
|
+
var _layer$getDimension;
|
|
6629
|
+
if (!layer || !layer.olSource) {
|
|
6639
6630
|
// No OpenLayers source, do nothing, so do not flag that something is not available
|
|
6640
6631
|
return {
|
|
6641
6632
|
status: true
|
|
6642
6633
|
};
|
|
6643
6634
|
}
|
|
6644
6635
|
// Check if there is a timevalue available
|
|
6645
|
-
var closestValue = (
|
|
6636
|
+
var closestValue = (_layer$getDimension = layer.getDimension('time')) === null || _layer$getDimension === void 0 ? void 0 : _layer$getDimension.getClosestValue(nextTimeString);
|
|
6646
6637
|
if (!closestValue || WMInvalidDateValues.has(closestValue)) {
|
|
6647
6638
|
// No value available, so do not flag that something is not available
|
|
6648
6639
|
return {
|
|
6649
6640
|
status: true
|
|
6650
6641
|
};
|
|
6651
6642
|
}
|
|
6652
|
-
var olSource =
|
|
6643
|
+
var olSource = layer.olSource;
|
|
6653
6644
|
var hasImageAvailableForRequestedTimeStep = olSource.hasImageForTimeValue(closestValue);
|
|
6654
6645
|
// If there is no image available for requested timestep, return true and flag that this thing is not ready yet.
|
|
6655
6646
|
if (hasImageAvailableForRequestedTimeStep) {
|
|
@@ -6662,8 +6653,8 @@ var isNextStepAvailable = function isNextStepAvailable(reduxLayers, nextTimeStri
|
|
|
6662
6653
|
status: false
|
|
6663
6654
|
};
|
|
6664
6655
|
});
|
|
6665
|
-
var nextStepIsAvailable = isThereSomethingNotAvailable.filter(function (
|
|
6666
|
-
return
|
|
6656
|
+
var nextStepIsAvailable = isThereSomethingNotAvailable.filter(function (step) {
|
|
6657
|
+
return step.status === true;
|
|
6667
6658
|
}).length === wmLayers.length;
|
|
6668
6659
|
return nextStepIsAvailable;
|
|
6669
6660
|
};
|
|
@@ -6700,8 +6691,8 @@ var olMetronomeHandler = function olMetronomeHandler(timerIds, listenerApi) {
|
|
|
6700
6691
|
// Collect all layers for this syncgroups target
|
|
6701
6692
|
var reduxLayers = [];
|
|
6702
6693
|
targets.forEach(function (target) {
|
|
6703
|
-
reduxLayers.push.apply(reduxLayers, _toConsumableArray(getLayersByMapId(listenerApi.getState(), target.targetId).filter(function (
|
|
6704
|
-
return
|
|
6694
|
+
reduxLayers.push.apply(reduxLayers, _toConsumableArray(getLayersByMapId(listenerApi.getState(), target.targetId).filter(function (layer) {
|
|
6695
|
+
return layer.layerType === LayerType.mapLayer;
|
|
6705
6696
|
})));
|
|
6706
6697
|
});
|
|
6707
6698
|
var nextStep = getNextStep(timerId, animationListValues.length, 1);
|
|
@@ -6856,7 +6847,7 @@ var updateAnimation = function updateAnimation(mapId, maxValue, listenerApi) {
|
|
|
6856
6847
|
mapListener.startListening({
|
|
6857
6848
|
actionCreator: mapActions.toggleAutoUpdate,
|
|
6858
6849
|
effect: function () {
|
|
6859
|
-
var _effect = _asyncToGenerator(
|
|
6850
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref3, listenerApi) {
|
|
6860
6851
|
var payload, shouldAutoUpdate, mapId, autoUpdateLayerId, timeDimension, syncedMapIds, payloads;
|
|
6861
6852
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
6862
6853
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -7002,8 +6993,8 @@ var handleBaseLayers = function handleBaseLayers(mapId, baseLayers, listenerApi)
|
|
|
7002
6993
|
mapListener.startListening({
|
|
7003
6994
|
actionCreator: mapActions.setMapPreset,
|
|
7004
6995
|
effect: function () {
|
|
7005
|
-
var _effect2 = _asyncToGenerator(
|
|
7006
|
-
var payload, mapId, initialProps, mapPreset, layers, activeLayerId, autoTimeStepLayerId, autoUpdateLayerId, proj, shouldAutoUpdate, shouldAnimate, animationPayload, toggleTimestepAuto, showTimeSlider, displayMapPin, shouldShowZoomControls, shouldShowLegend, dockedLayerManagerSize, timeSliderSpan, toggleTimeSpanAuto, _filterLayers, mapLayers, baseLayers, overLayers, _newLayerIds$layers$f, _newLayerIds$layers$f2, autoTimeStepLayerIdNew, autoUpdateLayerIdNew, onlyActiveLayerIdIsSet, newLayerIds, newAutoTimeStepLayerId, newAutoUpdateLayerId, customLayers, customBaseLayer, customOverLayer, baseLayersWithDefaultLayer, overLayersWithDefaultLayer, allBaseLayers, checkIsprojectionSupported, animationLength, animationEndTime, shouldEndtimeOverride, interval, endTime, startTime, centerTimeInSeconds, animationEnd, _startTime, duration, _animationEnd, animationStart, shouldOpenLegend, legendId, fiveMinuteDelayForAnimation, _animationEnd2, _animationStart;
|
|
6996
|
+
var _effect2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_ref6, listenerApi) {
|
|
6997
|
+
var payload, mapId, initialProps, mapPreset, layers, activeLayerId, autoTimeStepLayerId, autoUpdateLayerId, proj, shouldAutoUpdate, shouldAnimate, animationPayload, toggleTimestepAuto, showTimeSlider, displayMapPin, shouldShowZoomControls, shouldShowLegend, shouldShowDataExplorer, dockedLayerManagerSize, timeSliderSpan, toggleTimeSpanAuto, _filterLayers, mapLayers, baseLayers, overLayers, _newLayerIds$layers$f, _newLayerIds$layers$f2, autoTimeStepLayerIdNew, autoUpdateLayerIdNew, onlyActiveLayerIdIsSet, newLayerIds, newAutoTimeStepLayerId, newAutoUpdateLayerId, customLayers, customBaseLayer, customOverLayer, baseLayersWithDefaultLayer, overLayersWithDefaultLayer, allBaseLayers, checkIsprojectionSupported, animationLength, animationEndTime, shouldEndtimeOverride, interval, endTime, startTime, centerTimeInSeconds, animationEnd, _startTime, duration, _animationEnd, animationStart, shouldOpenLegend, legendId, fiveMinuteDelayForAnimation, _animationEnd2, _animationStart;
|
|
7007
6998
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
7008
6999
|
while (1) switch (_context2.prev = _context2.next) {
|
|
7009
7000
|
case 0:
|
|
@@ -7012,10 +7003,10 @@ mapListener.startListening({
|
|
|
7012
7003
|
mapId = payload.mapId, initialProps = payload.initialProps;
|
|
7013
7004
|
mapPreset = initialProps.mapPreset;
|
|
7014
7005
|
if (!mapPreset) {
|
|
7015
|
-
_context2.next =
|
|
7006
|
+
_context2.next = 51;
|
|
7016
7007
|
break;
|
|
7017
7008
|
}
|
|
7018
|
-
layers = mapPreset.layers, activeLayerId = mapPreset.activeLayerId, autoTimeStepLayerId = mapPreset.autoTimeStepLayerId, autoUpdateLayerId = mapPreset.autoUpdateLayerId, proj = mapPreset.proj, shouldAutoUpdate = mapPreset.shouldAutoUpdate, shouldAnimate = mapPreset.shouldAnimate, animationPayload = mapPreset.animationPayload, toggleTimestepAuto = mapPreset.toggleTimestepAuto, showTimeSlider = mapPreset.showTimeSlider, displayMapPin = mapPreset.displayMapPin, shouldShowZoomControls = mapPreset.shouldShowZoomControls, shouldShowLegend = mapPreset.shouldShowLegend, dockedLayerManagerSize = mapPreset.dockedLayerManagerSize, timeSliderSpan = mapPreset.timeSliderSpan, toggleTimeSpanAuto = mapPreset.toggleTimeSpanAuto;
|
|
7009
|
+
layers = mapPreset.layers, activeLayerId = mapPreset.activeLayerId, autoTimeStepLayerId = mapPreset.autoTimeStepLayerId, autoUpdateLayerId = mapPreset.autoUpdateLayerId, proj = mapPreset.proj, shouldAutoUpdate = mapPreset.shouldAutoUpdate, shouldAnimate = mapPreset.shouldAnimate, animationPayload = mapPreset.animationPayload, toggleTimestepAuto = mapPreset.toggleTimestepAuto, showTimeSlider = mapPreset.showTimeSlider, displayMapPin = mapPreset.displayMapPin, shouldShowZoomControls = mapPreset.shouldShowZoomControls, shouldShowLegend = mapPreset.shouldShowLegend, shouldShowDataExplorer = mapPreset.shouldShowDataExplorer, dockedLayerManagerSize = mapPreset.dockedLayerManagerSize, timeSliderSpan = mapPreset.timeSliderSpan, toggleTimeSpanAuto = mapPreset.toggleTimeSpanAuto;
|
|
7019
7010
|
_filterLayers = filterLayers(layers), mapLayers = _filterLayers.mapLayers, baseLayers = _filterLayers.baseLayers, overLayers = _filterLayers.overLayers;
|
|
7020
7011
|
if (layers) {
|
|
7021
7012
|
// make sure all layers have a unique id before going forward
|
|
@@ -7222,21 +7213,30 @@ mapListener.startListening({
|
|
|
7222
7213
|
setOpen: shouldOpenLegend
|
|
7223
7214
|
}));
|
|
7224
7215
|
}
|
|
7216
|
+
// show data explorer
|
|
7217
|
+
if (shouldShowDataExplorer) {
|
|
7218
|
+
listenerApi.dispatch(uiActions.setActiveMapIdForDialog({
|
|
7219
|
+
type: DialogTypes.DataExplorer,
|
|
7220
|
+
setOpen: true,
|
|
7221
|
+
source: 'app',
|
|
7222
|
+
mapId: mapId
|
|
7223
|
+
}));
|
|
7224
|
+
}
|
|
7225
7225
|
if (dockedLayerManagerSize) {
|
|
7226
7226
|
listenerApi.dispatch(mapActions.setDockedLayerManagerSize({
|
|
7227
7227
|
mapId: mapId,
|
|
7228
7228
|
dockedLayerManagerSize: dockedLayerManagerSize
|
|
7229
7229
|
}));
|
|
7230
7230
|
}
|
|
7231
|
-
case
|
|
7231
|
+
case 41:
|
|
7232
7232
|
if (!(animationEndTime && (shouldEndtimeOverride || !(shouldAutoUpdate || shouldAnimate)))) {
|
|
7233
|
-
_context2.next =
|
|
7233
|
+
_context2.next = 51;
|
|
7234
7234
|
break;
|
|
7235
7235
|
}
|
|
7236
7236
|
fiveMinuteDelayForAnimation = 1000 * 60 * 5; // eslint-disable-next-line no-await-in-loop
|
|
7237
|
-
_context2.next =
|
|
7237
|
+
_context2.next = 45;
|
|
7238
7238
|
return listenerApi.delay(fiveMinuteDelayForAnimation);
|
|
7239
|
-
case
|
|
7239
|
+
case 45:
|
|
7240
7240
|
_animationEnd2 = getAnimationEndTime(listenerApi.getState(), mapId);
|
|
7241
7241
|
listenerApi.dispatch(mapActions.setAnimationEndTime({
|
|
7242
7242
|
mapId: mapId,
|
|
@@ -7251,13 +7251,13 @@ mapListener.startListening({
|
|
|
7251
7251
|
minutes: 5
|
|
7252
7252
|
}).toISOString()
|
|
7253
7253
|
}));
|
|
7254
|
-
_context2.next =
|
|
7254
|
+
_context2.next = 41;
|
|
7255
7255
|
break;
|
|
7256
|
-
case
|
|
7257
|
-
_context2.next =
|
|
7256
|
+
case 51:
|
|
7257
|
+
_context2.next = 56;
|
|
7258
7258
|
break;
|
|
7259
|
-
case
|
|
7260
|
-
_context2.prev =
|
|
7259
|
+
case 53:
|
|
7260
|
+
_context2.prev = 53;
|
|
7261
7261
|
_context2.t0 = _context2["catch"](1);
|
|
7262
7262
|
if (_context2.t0 instanceof Error) {
|
|
7263
7263
|
listenerApi.dispatch(mapActions.setMapPresetError({
|
|
@@ -7265,11 +7265,11 @@ mapListener.startListening({
|
|
|
7265
7265
|
error: _context2.t0.message
|
|
7266
7266
|
}));
|
|
7267
7267
|
}
|
|
7268
|
-
case
|
|
7268
|
+
case 56:
|
|
7269
7269
|
case "end":
|
|
7270
7270
|
return _context2.stop();
|
|
7271
7271
|
}
|
|
7272
|
-
}, _callee2, null, [[1,
|
|
7272
|
+
}, _callee2, null, [[1, 53]]);
|
|
7273
7273
|
}));
|
|
7274
7274
|
function effect(_x3, _x4) {
|
|
7275
7275
|
return _effect2.apply(this, arguments);
|
|
@@ -7527,7 +7527,7 @@ openlayersListener.startListening({
|
|
|
7527
7527
|
var _excluded = ["url"];
|
|
7528
7528
|
var serviceListener = createListenerMiddleware();
|
|
7529
7529
|
var fetchService = /*#__PURE__*/function () {
|
|
7530
|
-
var _ref = _asyncToGenerator(
|
|
7530
|
+
var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(service, listenerApi) {
|
|
7531
7531
|
var layers;
|
|
7532
7532
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
7533
7533
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -7559,7 +7559,7 @@ var fetchService = /*#__PURE__*/function () {
|
|
|
7559
7559
|
};
|
|
7560
7560
|
}();
|
|
7561
7561
|
var fetchInitialServices = /*#__PURE__*/function () {
|
|
7562
|
-
var _ref2 = _asyncToGenerator(
|
|
7562
|
+
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(payload, listenerApi) {
|
|
7563
7563
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
7564
7564
|
while (1) switch (_context2.prev = _context2.next) {
|
|
7565
7565
|
case 0:
|
|
@@ -7599,7 +7599,7 @@ var fetchInitialServices = /*#__PURE__*/function () {
|
|
|
7599
7599
|
serviceListener.startListening({
|
|
7600
7600
|
actionCreator: serviceActions.fetchInitialServices,
|
|
7601
7601
|
effect: function () {
|
|
7602
|
-
var _effect = _asyncToGenerator(
|
|
7602
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(_ref4, listenerApi) {
|
|
7603
7603
|
var payload;
|
|
7604
7604
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
7605
7605
|
while (1) switch (_context3.prev = _context3.next) {
|
|
@@ -7684,7 +7684,7 @@ var routerListener = createListenerMiddleware();
|
|
|
7684
7684
|
routerListener.startListening({
|
|
7685
7685
|
actionCreator: routerActions.navigateToUrl,
|
|
7686
7686
|
effect: function () {
|
|
7687
|
-
var _effect = _asyncToGenerator(
|
|
7687
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, listenerApi) {
|
|
7688
7688
|
var payload;
|
|
7689
7689
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
7690
7690
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -7954,7 +7954,7 @@ var registerOrigin = 'drawings listener:registerDrawToolListener';
|
|
|
7954
7954
|
drawingToolListener.startListening({
|
|
7955
7955
|
actionCreator: drawingToolActions.registerDrawTool,
|
|
7956
7956
|
effect: function () {
|
|
7957
|
-
var _effect = _asyncToGenerator(
|
|
7957
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, listenerApi) {
|
|
7958
7958
|
var payload, mapId, geoJSONLayerId, geoJSONIntersectionLayerId, geoJSONIntersectionBoundsLayerId, _payload$defaultGeoJS, defaultGeoJSON, _payload$defaultGeoJS2, defaultGeoJSONIntersection, defaultGeoJSONIntersectionBounds, _payload$defaultGeoJS3, defaultGeoJSONIntersectionProperties, existingBoundsLayer;
|
|
7959
7959
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
7960
7960
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -8021,7 +8021,7 @@ drawingToolListener.startListening({
|
|
|
8021
8021
|
drawingToolListener.startListening({
|
|
8022
8022
|
actionCreator: drawingToolActions.changeDrawToolMode,
|
|
8023
8023
|
effect: function () {
|
|
8024
|
-
var _effect2 = _asyncToGenerator(
|
|
8024
|
+
var _effect2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_ref2, listenerApi) {
|
|
8025
8025
|
var payload, _currentGeoJSON$featu, _currentGeoJSON$featu2, drawModeId, drawToolId, _payload$shouldUpdate, shouldUpdateShape, drawingTool, _drawingTool$shouldAl, shouldAllowMultipleShapes, geoJSONIntersectionLayerId, geoJSONIntersectionBoundsLayerId, newDrawMode, geoJSONLayer, geoJSON, lastFeatureIndex, newGeoJSON, currentGeoJSONLayer, _ref3, currentGeoJSON, _ref3$selectedFeature, selectedFeatureIndex, currentSelectionType, newSelectionType, isNewToolSelected, shouldUpdateNewShape, shapeWithSelectionType, geoJSONFeatureCollection, _newGeoJSON;
|
|
8026
8026
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
8027
8027
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -8145,7 +8145,7 @@ drawingToolListener.startListening({
|
|
|
8145
8145
|
drawingToolListener.startListening({
|
|
8146
8146
|
actionCreator: drawingToolActions.changeIntersectionBounds,
|
|
8147
8147
|
effect: function () {
|
|
8148
|
-
var _effect3 = _asyncToGenerator(
|
|
8148
|
+
var _effect3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(_ref4, listenerApi) {
|
|
8149
8149
|
var payload, drawToolId, geoJSON, drawtool;
|
|
8150
8150
|
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
|
8151
8151
|
while (1) switch (_context3.prev = _context3.next) {
|
|
@@ -8189,7 +8189,7 @@ var layersListener = createListenerMiddleware();
|
|
|
8189
8189
|
layersListener.startListening({
|
|
8190
8190
|
actionCreator: layerActions.showLayerInfo,
|
|
8191
8191
|
effect: function () {
|
|
8192
|
-
var _effect = _asyncToGenerator(
|
|
8192
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, listenerApi) {
|
|
8193
8193
|
var payload, mapId, source, currentActiveMapId, isOpenInStore;
|
|
8194
8194
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
8195
8195
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -8221,7 +8221,7 @@ layersListener.startListening({
|
|
|
8221
8221
|
layersListener.startListening({
|
|
8222
8222
|
actionCreator: uiActions.setToggleOpenDialog,
|
|
8223
8223
|
effect: function () {
|
|
8224
|
-
var _effect2 = _asyncToGenerator(
|
|
8224
|
+
var _effect2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(_ref2, listenerApi) {
|
|
8225
8225
|
var payload, setOpen, type, isOpenInStore;
|
|
8226
8226
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
8227
8227
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -8251,7 +8251,7 @@ var metronomeListener = createListenerMiddleware();
|
|
|
8251
8251
|
metronomeListener.startListening({
|
|
8252
8252
|
actionCreator: mapActions.mapStartAnimation,
|
|
8253
8253
|
effect: function () {
|
|
8254
|
-
var _effect = _asyncToGenerator(
|
|
8254
|
+
var _effect = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_, listenerApi) {
|
|
8255
8255
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
8256
8256
|
while (1) switch (_context.prev = _context.next) {
|
|
8257
8257
|
case 0:
|