@vaadin/bundles 23.0.9 → 23.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/node_modules_ol_ImageCanvas_js.js +121 -0
  2. package/node_modules_ol_ImageCanvas_js.js.map +1 -0
  3. package/node_modules_ol_ImageTile_js.js +177 -0
  4. package/node_modules_ol_ImageTile_js.js.map +1 -0
  5. package/node_modules_ol_TileRange_js.js +154 -0
  6. package/node_modules_ol_TileRange_js.js.map +1 -0
  7. package/node_modules_ol_VectorRenderTile_js.js +182 -0
  8. package/node_modules_ol_VectorRenderTile_js.js.map +1 -0
  9. package/node_modules_ol_VectorTile_js.js +158 -0
  10. package/node_modules_ol_VectorTile_js.js.map +1 -0
  11. package/node_modules_ol_geom_flat_geodesic_js.js +171 -0
  12. package/node_modules_ol_geom_flat_geodesic_js.js.map +1 -0
  13. package/node_modules_ol_render_js.js +131 -0
  14. package/node_modules_ol_render_js.js.map +1 -0
  15. package/node_modules_ol_structs_LRUCache_js.js +275 -0
  16. package/node_modules_ol_structs_LRUCache_js.js.map +1 -0
  17. package/node_modules_ol_style_js.js +47 -0
  18. package/node_modules_ol_style_js.js.map +1 -0
  19. package/node_modules_ol_tilecoord_js.js +115 -0
  20. package/node_modules_ol_tilecoord_js.js.map +1 -0
  21. package/package.json +146 -119
  22. package/vaadin-bundle.json +2571 -949
  23. package/vaadin.js +83552 -36675
  24. package/vaadin.js.map +1 -1
  25. package/vendors-node_modules_ol_Geolocation_js.js +379 -0
  26. package/vendors-node_modules_ol_Geolocation_js.js.map +1 -0
  27. package/vendors-node_modules_ol_TileCache_js.js +461 -0
  28. package/vendors-node_modules_ol_TileCache_js.js.map +1 -0
  29. package/vendors-node_modules_ol_Tile_js.js +330 -0
  30. package/vendors-node_modules_ol_Tile_js.js.map +1 -0
  31. package/vendors-node_modules_ol_index_js.js +874 -0
  32. package/vendors-node_modules_ol_index_js.js.map +1 -0
  33. package/vendors-node_modules_ol_layer_Graticule_js.js +1359 -0
  34. package/vendors-node_modules_ol_layer_Graticule_js.js.map +1 -0
  35. package/vendors-node_modules_ol_style_Text_js.js +509 -0
  36. package/vendors-node_modules_ol_style_Text_js.js.map +1 -0
  37. package/vendors-node_modules_rbush_index_js.js +531 -0
  38. package/vendors-node_modules_rbush_index_js.js.map +1 -0
@@ -0,0 +1,461 @@
1
+ (self["webpackChunk_vaadin_bundles"] = self["webpackChunk_vaadin_bundles"] || []).push([["vendors-node_modules_ol_TileCache_js"],{
2
+
3
+ /***/ "./node_modules/ol/TileCache.js":
4
+ /*!**************************************!*\
5
+ !*** ./node_modules/ol/TileCache.js ***!
6
+ \**************************************/
7
+ /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
8
+
9
+ __webpack_require__.r(__webpack_exports__);
10
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
11
+ /* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
12
+ /* harmony export */ });
13
+ /* harmony import */ var _structs_LRUCache_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./structs/LRUCache.js */ "./node_modules/ol/structs/LRUCache.js");
14
+ /* harmony import */ var _tilecoord_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./tilecoord.js */ "./node_modules/ol/tilecoord.js");
15
+ var __extends = (undefined && undefined.__extends) || (function () {
16
+ var extendStatics = function (d, b) {
17
+ extendStatics = Object.setPrototypeOf ||
18
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
19
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
20
+ return extendStatics(d, b);
21
+ };
22
+ return function (d, b) {
23
+ if (typeof b !== "function" && b !== null)
24
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
25
+ extendStatics(d, b);
26
+ function __() { this.constructor = d; }
27
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
28
+ };
29
+ })();
30
+ /**
31
+ * @module ol/TileCache
32
+ */
33
+
34
+
35
+ var TileCache = /** @class */ (function (_super) {
36
+ __extends(TileCache, _super);
37
+ function TileCache() {
38
+ return _super !== null && _super.apply(this, arguments) || this;
39
+ }
40
+ /**
41
+ * @param {!Object<string, boolean>} usedTiles Used tiles.
42
+ */
43
+ TileCache.prototype.expireCache = function (usedTiles) {
44
+ while (this.canExpireCache()) {
45
+ var tile = this.peekLast();
46
+ if (tile.getKey() in usedTiles) {
47
+ break;
48
+ }
49
+ else {
50
+ this.pop().release();
51
+ }
52
+ }
53
+ };
54
+ /**
55
+ * Prune all tiles from the cache that don't have the same z as the newest tile.
56
+ */
57
+ TileCache.prototype.pruneExceptNewestZ = function () {
58
+ if (this.getCount() === 0) {
59
+ return;
60
+ }
61
+ var key = this.peekFirstKey();
62
+ var tileCoord = (0,_tilecoord_js__WEBPACK_IMPORTED_MODULE_0__.fromKey)(key);
63
+ var z = tileCoord[0];
64
+ this.forEach(function (tile) {
65
+ if (tile.tileCoord[0] !== z) {
66
+ this.remove((0,_tilecoord_js__WEBPACK_IMPORTED_MODULE_0__.getKey)(tile.tileCoord));
67
+ tile.release();
68
+ }
69
+ }.bind(this));
70
+ };
71
+ return TileCache;
72
+ }(_structs_LRUCache_js__WEBPACK_IMPORTED_MODULE_1__["default"]));
73
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (TileCache);
74
+ //# sourceMappingURL=TileCache.js.map
75
+
76
+ /***/ }),
77
+
78
+ /***/ "./node_modules/ol/structs/LRUCache.js":
79
+ /*!*********************************************!*\
80
+ !*** ./node_modules/ol/structs/LRUCache.js ***!
81
+ \*********************************************/
82
+ /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
83
+
84
+ __webpack_require__.r(__webpack_exports__);
85
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
86
+ /* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
87
+ /* harmony export */ });
88
+ /* harmony import */ var _asserts_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../asserts.js */ "./node_modules/ol/asserts.js");
89
+ /**
90
+ * @module ol/structs/LRUCache
91
+ */
92
+
93
+ /**
94
+ * @typedef {Object} Entry
95
+ * @property {string} key_ Key.
96
+ * @property {Object} newer Newer.
97
+ * @property {Object} older Older.
98
+ * @property {*} value_ Value.
99
+ */
100
+ /**
101
+ * @classdesc
102
+ * Implements a Least-Recently-Used cache where the keys do not conflict with
103
+ * Object's properties (e.g. 'hasOwnProperty' is not allowed as a key). Expiring
104
+ * items from the cache is the responsibility of the user.
105
+ *
106
+ * @fires import("../events/Event.js").default
107
+ * @template T
108
+ */
109
+ var LRUCache = /** @class */ (function () {
110
+ /**
111
+ * @param {number} [opt_highWaterMark] High water mark.
112
+ */
113
+ function LRUCache(opt_highWaterMark) {
114
+ /**
115
+ * Desired max cache size after expireCache(). If set to 0, no cache entries
116
+ * will be pruned at all.
117
+ * @type {number}
118
+ */
119
+ this.highWaterMark =
120
+ opt_highWaterMark !== undefined ? opt_highWaterMark : 2048;
121
+ /**
122
+ * @private
123
+ * @type {number}
124
+ */
125
+ this.count_ = 0;
126
+ /**
127
+ * @private
128
+ * @type {!Object<string, Entry>}
129
+ */
130
+ this.entries_ = {};
131
+ /**
132
+ * @private
133
+ * @type {?Entry}
134
+ */
135
+ this.oldest_ = null;
136
+ /**
137
+ * @private
138
+ * @type {?Entry}
139
+ */
140
+ this.newest_ = null;
141
+ }
142
+ /**
143
+ * @return {boolean} Can expire cache.
144
+ */
145
+ LRUCache.prototype.canExpireCache = function () {
146
+ return this.highWaterMark > 0 && this.getCount() > this.highWaterMark;
147
+ };
148
+ /**
149
+ * Expire the cache.
150
+ * @param {!Object<string, boolean>} [keep] Keys to keep. To be implemented by subclasses.
151
+ */
152
+ LRUCache.prototype.expireCache = function (keep) {
153
+ while (this.canExpireCache()) {
154
+ this.pop();
155
+ }
156
+ };
157
+ /**
158
+ * FIXME empty description for jsdoc
159
+ */
160
+ LRUCache.prototype.clear = function () {
161
+ this.count_ = 0;
162
+ this.entries_ = {};
163
+ this.oldest_ = null;
164
+ this.newest_ = null;
165
+ };
166
+ /**
167
+ * @param {string} key Key.
168
+ * @return {boolean} Contains key.
169
+ */
170
+ LRUCache.prototype.containsKey = function (key) {
171
+ return this.entries_.hasOwnProperty(key);
172
+ };
173
+ /**
174
+ * @param {function(T, string, LRUCache<T>): ?} f The function
175
+ * to call for every entry from the oldest to the newer. This function takes
176
+ * 3 arguments (the entry value, the entry key and the LRUCache object).
177
+ * The return value is ignored.
178
+ */
179
+ LRUCache.prototype.forEach = function (f) {
180
+ var entry = this.oldest_;
181
+ while (entry) {
182
+ f(entry.value_, entry.key_, this);
183
+ entry = entry.newer;
184
+ }
185
+ };
186
+ /**
187
+ * @param {string} key Key.
188
+ * @param {*} [opt_options] Options (reserved for subclasses).
189
+ * @return {T} Value.
190
+ */
191
+ LRUCache.prototype.get = function (key, opt_options) {
192
+ var entry = this.entries_[key];
193
+ (0,_asserts_js__WEBPACK_IMPORTED_MODULE_0__.assert)(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache
194
+ if (entry === this.newest_) {
195
+ return entry.value_;
196
+ }
197
+ else if (entry === this.oldest_) {
198
+ this.oldest_ = /** @type {Entry} */ (this.oldest_.newer);
199
+ this.oldest_.older = null;
200
+ }
201
+ else {
202
+ entry.newer.older = entry.older;
203
+ entry.older.newer = entry.newer;
204
+ }
205
+ entry.newer = null;
206
+ entry.older = this.newest_;
207
+ this.newest_.newer = entry;
208
+ this.newest_ = entry;
209
+ return entry.value_;
210
+ };
211
+ /**
212
+ * Remove an entry from the cache.
213
+ * @param {string} key The entry key.
214
+ * @return {T} The removed entry.
215
+ */
216
+ LRUCache.prototype.remove = function (key) {
217
+ var entry = this.entries_[key];
218
+ (0,_asserts_js__WEBPACK_IMPORTED_MODULE_0__.assert)(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache
219
+ if (entry === this.newest_) {
220
+ this.newest_ = /** @type {Entry} */ (entry.older);
221
+ if (this.newest_) {
222
+ this.newest_.newer = null;
223
+ }
224
+ }
225
+ else if (entry === this.oldest_) {
226
+ this.oldest_ = /** @type {Entry} */ (entry.newer);
227
+ if (this.oldest_) {
228
+ this.oldest_.older = null;
229
+ }
230
+ }
231
+ else {
232
+ entry.newer.older = entry.older;
233
+ entry.older.newer = entry.newer;
234
+ }
235
+ delete this.entries_[key];
236
+ --this.count_;
237
+ return entry.value_;
238
+ };
239
+ /**
240
+ * @return {number} Count.
241
+ */
242
+ LRUCache.prototype.getCount = function () {
243
+ return this.count_;
244
+ };
245
+ /**
246
+ * @return {Array<string>} Keys.
247
+ */
248
+ LRUCache.prototype.getKeys = function () {
249
+ var keys = new Array(this.count_);
250
+ var i = 0;
251
+ var entry;
252
+ for (entry = this.newest_; entry; entry = entry.older) {
253
+ keys[i++] = entry.key_;
254
+ }
255
+ return keys;
256
+ };
257
+ /**
258
+ * @return {Array<T>} Values.
259
+ */
260
+ LRUCache.prototype.getValues = function () {
261
+ var values = new Array(this.count_);
262
+ var i = 0;
263
+ var entry;
264
+ for (entry = this.newest_; entry; entry = entry.older) {
265
+ values[i++] = entry.value_;
266
+ }
267
+ return values;
268
+ };
269
+ /**
270
+ * @return {T} Last value.
271
+ */
272
+ LRUCache.prototype.peekLast = function () {
273
+ return this.oldest_.value_;
274
+ };
275
+ /**
276
+ * @return {string} Last key.
277
+ */
278
+ LRUCache.prototype.peekLastKey = function () {
279
+ return this.oldest_.key_;
280
+ };
281
+ /**
282
+ * Get the key of the newest item in the cache. Throws if the cache is empty.
283
+ * @return {string} The newest key.
284
+ */
285
+ LRUCache.prototype.peekFirstKey = function () {
286
+ return this.newest_.key_;
287
+ };
288
+ /**
289
+ * @return {T} value Value.
290
+ */
291
+ LRUCache.prototype.pop = function () {
292
+ var entry = this.oldest_;
293
+ delete this.entries_[entry.key_];
294
+ if (entry.newer) {
295
+ entry.newer.older = null;
296
+ }
297
+ this.oldest_ = /** @type {Entry} */ (entry.newer);
298
+ if (!this.oldest_) {
299
+ this.newest_ = null;
300
+ }
301
+ --this.count_;
302
+ return entry.value_;
303
+ };
304
+ /**
305
+ * @param {string} key Key.
306
+ * @param {T} value Value.
307
+ */
308
+ LRUCache.prototype.replace = function (key, value) {
309
+ this.get(key); // update `newest_`
310
+ this.entries_[key].value_ = value;
311
+ };
312
+ /**
313
+ * @param {string} key Key.
314
+ * @param {T} value Value.
315
+ */
316
+ LRUCache.prototype.set = function (key, value) {
317
+ (0,_asserts_js__WEBPACK_IMPORTED_MODULE_0__.assert)(!(key in this.entries_), 16); // Tried to set a value for a key that is used already
318
+ var entry = {
319
+ key_: key,
320
+ newer: null,
321
+ older: this.newest_,
322
+ value_: value,
323
+ };
324
+ if (!this.newest_) {
325
+ this.oldest_ = entry;
326
+ }
327
+ else {
328
+ this.newest_.newer = entry;
329
+ }
330
+ this.newest_ = entry;
331
+ this.entries_[key] = entry;
332
+ ++this.count_;
333
+ };
334
+ /**
335
+ * Set a maximum number of entries for the cache.
336
+ * @param {number} size Cache size.
337
+ * @api
338
+ */
339
+ LRUCache.prototype.setSize = function (size) {
340
+ this.highWaterMark = size;
341
+ };
342
+ return LRUCache;
343
+ }());
344
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (LRUCache);
345
+ //# sourceMappingURL=LRUCache.js.map
346
+
347
+ /***/ }),
348
+
349
+ /***/ "./node_modules/ol/tilecoord.js":
350
+ /*!**************************************!*\
351
+ !*** ./node_modules/ol/tilecoord.js ***!
352
+ \**************************************/
353
+ /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
354
+
355
+ __webpack_require__.r(__webpack_exports__);
356
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
357
+ /* harmony export */ "createOrUpdate": () => (/* binding */ createOrUpdate),
358
+ /* harmony export */ "fromKey": () => (/* binding */ fromKey),
359
+ /* harmony export */ "getCacheKeyForTileKey": () => (/* binding */ getCacheKeyForTileKey),
360
+ /* harmony export */ "getKey": () => (/* binding */ getKey),
361
+ /* harmony export */ "getKeyZXY": () => (/* binding */ getKeyZXY),
362
+ /* harmony export */ "hash": () => (/* binding */ hash),
363
+ /* harmony export */ "withinExtentAndZ": () => (/* binding */ withinExtentAndZ)
364
+ /* harmony export */ });
365
+ /**
366
+ * @module ol/tilecoord
367
+ */
368
+ /**
369
+ * An array of three numbers representing the location of a tile in a tile
370
+ * grid. The order is `z` (zoom level), `x` (column), and `y` (row).
371
+ * @typedef {Array<number>} TileCoord
372
+ * @api
373
+ */
374
+ /**
375
+ * @param {number} z Z.
376
+ * @param {number} x X.
377
+ * @param {number} y Y.
378
+ * @param {TileCoord} [opt_tileCoord] Tile coordinate.
379
+ * @return {TileCoord} Tile coordinate.
380
+ */
381
+ function createOrUpdate(z, x, y, opt_tileCoord) {
382
+ if (opt_tileCoord !== undefined) {
383
+ opt_tileCoord[0] = z;
384
+ opt_tileCoord[1] = x;
385
+ opt_tileCoord[2] = y;
386
+ return opt_tileCoord;
387
+ }
388
+ else {
389
+ return [z, x, y];
390
+ }
391
+ }
392
+ /**
393
+ * @param {number} z Z.
394
+ * @param {number} x X.
395
+ * @param {number} y Y.
396
+ * @return {string} Key.
397
+ */
398
+ function getKeyZXY(z, x, y) {
399
+ return z + '/' + x + '/' + y;
400
+ }
401
+ /**
402
+ * Get the key for a tile coord.
403
+ * @param {TileCoord} tileCoord The tile coord.
404
+ * @return {string} Key.
405
+ */
406
+ function getKey(tileCoord) {
407
+ return getKeyZXY(tileCoord[0], tileCoord[1], tileCoord[2]);
408
+ }
409
+ /**
410
+ * Get the tile cache key for a tile key obtained through `tile.getKey()`.
411
+ * @param {string} tileKey The tile key.
412
+ * @return {string} The cache key.
413
+ */
414
+ function getCacheKeyForTileKey(tileKey) {
415
+ var _a = tileKey
416
+ .substring(tileKey.lastIndexOf('/') + 1, tileKey.length)
417
+ .split(',')
418
+ .map(Number), z = _a[0], x = _a[1], y = _a[2];
419
+ return getKeyZXY(z, x, y);
420
+ }
421
+ /**
422
+ * Get a tile coord given a key.
423
+ * @param {string} key The tile coord key.
424
+ * @return {TileCoord} The tile coord.
425
+ */
426
+ function fromKey(key) {
427
+ return key.split('/').map(Number);
428
+ }
429
+ /**
430
+ * @param {TileCoord} tileCoord Tile coord.
431
+ * @return {number} Hash.
432
+ */
433
+ function hash(tileCoord) {
434
+ return (tileCoord[1] << tileCoord[0]) + tileCoord[2];
435
+ }
436
+ /**
437
+ * @param {TileCoord} tileCoord Tile coordinate.
438
+ * @param {!import("./tilegrid/TileGrid.js").default} tileGrid Tile grid.
439
+ * @return {boolean} Tile coordinate is within extent and zoom level range.
440
+ */
441
+ function withinExtentAndZ(tileCoord, tileGrid) {
442
+ var z = tileCoord[0];
443
+ var x = tileCoord[1];
444
+ var y = tileCoord[2];
445
+ if (tileGrid.getMinZoom() > z || z > tileGrid.getMaxZoom()) {
446
+ return false;
447
+ }
448
+ var tileRange = tileGrid.getFullTileRange(z);
449
+ if (!tileRange) {
450
+ return true;
451
+ }
452
+ else {
453
+ return tileRange.containsXY(x, y);
454
+ }
455
+ }
456
+ //# sourceMappingURL=tilecoord.js.map
457
+
458
+ /***/ })
459
+
460
+ }])
461
+ //# sourceMappingURL=vendors-node_modules_ol_TileCache_js.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vendors-node_modules_ol_TileCache_js.js","mappings":";;;;;;;;;;;;;;AAAA,iBAAiB,SAAI,IAAI,SAAI;AAC7B;AACA;AACA,eAAe,gBAAgB,sCAAsC,kBAAkB;AACvF,8BAA8B;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwB;AACxB;AACA;AACA,CAAC;AACD;AACA;AACA;AAC6C;AACI;AACjD;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,0BAA0B;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,wBAAwB,sDAAO;AAC/B;AACA;AACA;AACA,4BAA4B,qDAAM;AAClC;AACA;AACA,SAAS;AACT;AACA;AACA,CAAC,CAAC,4DAAQ;AACV,iEAAe,SAAS,EAAC;AACzB;;;;;;;;;;;;;;;AC3DA;AACA;AACA;AACuC;AACvC;AACA,aAAa,QAAQ;AACrB,cAAc,QAAQ;AACtB,cAAc,QAAQ;AACtB,cAAc,QAAQ;AACtB,cAAc,GAAG;AACjB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB;AACA;AACA;AACA;AACA;AACA,kBAAkB;AAClB;AACA;AACA;AACA;AACA;AACA,kBAAkB;AAClB;AACA;AACA;AACA;AACA,kBAAkB;AAClB;AACA;AACA;AACA;AACA,kBAAkB;AAClB;AACA;AACA;AACA;AACA,kBAAkB;AAClB;AACA;AACA;AACA;AACA,gBAAgB,SAAS;AACzB;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,0BAA0B;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB,gBAAgB,SAAS;AACzB;AACA;AACA;AACA;AACA;AACA,eAAe,qCAAqC;AACpD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB,eAAe,GAAG;AAClB,gBAAgB,GAAG;AACnB;AACA;AACA;AACA,QAAQ,mDAAM,2BAA2B;AACzC;AACA;AACA;AACA;AACA,sCAAsC,OAAO;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB,gBAAgB,GAAG;AACnB;AACA;AACA;AACA,QAAQ,mDAAM,2BAA2B;AACzC;AACA,sCAAsC,OAAO;AAC7C;AACA;AACA;AACA;AACA;AACA,sCAAsC,OAAO;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB,QAAQ;AACxB;AACA;AACA;AACA;AACA;AACA,gBAAgB,eAAe;AAC/B;AACA;AACA;AACA;AACA;AACA,mCAAmC,OAAO;AAC1C;AACA;AACA;AACA;AACA;AACA,gBAAgB,UAAU;AAC1B;AACA;AACA;AACA;AACA;AACA,mCAAmC,OAAO;AAC1C;AACA;AACA;AACA;AACA;AACA,gBAAgB,GAAG;AACnB;AACA;AACA;AACA;AACA;AACA,gBAAgB,QAAQ;AACxB;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB,QAAQ;AACxB;AACA;AACA;AACA;AACA;AACA,gBAAgB,GAAG;AACnB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kCAAkC,OAAO;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB,eAAe,GAAG;AAClB;AACA;AACA,uBAAuB;AACvB;AACA;AACA;AACA,eAAe,QAAQ;AACvB,eAAe,GAAG;AAClB;AACA;AACA,QAAQ,mDAAM,+BAA+B;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,QAAQ;AACvB;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,iEAAe,QAAQ,EAAC;AACxB;;;;;;;;;;;;;;;;;;;;AChQA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa,eAAe;AAC5B;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,WAAW;AACtB,YAAY,WAAW;AACvB;AACO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,YAAY,QAAQ;AACpB;AACO;AACP;AACA;AACA;AACA;AACA,WAAW,WAAW;AACtB,YAAY,QAAQ;AACpB;AACO;AACP;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,YAAY,QAAQ;AACpB;AACO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,YAAY,WAAW;AACvB;AACO;AACP;AACA;AACA;AACA,WAAW,WAAW;AACtB,YAAY,QAAQ;AACpB;AACO;AACP;AACA;AACA;AACA,WAAW,WAAW;AACtB,WAAW,2CAA2C;AACtD,YAAY,SAAS;AACrB;AACO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sources":["webpack://@vaadin/bundles/./node_modules/ol/TileCache.js","webpack://@vaadin/bundles/./node_modules/ol/structs/LRUCache.js","webpack://@vaadin/bundles/./node_modules/ol/tilecoord.js"],"sourcesContent":["var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\n/**\n * @module ol/TileCache\n */\nimport LRUCache from './structs/LRUCache.js';\nimport { fromKey, getKey } from './tilecoord.js';\nvar TileCache = /** @class */ (function (_super) {\n __extends(TileCache, _super);\n function TileCache() {\n return _super !== null && _super.apply(this, arguments) || this;\n }\n /**\n * @param {!Object<string, boolean>} usedTiles Used tiles.\n */\n TileCache.prototype.expireCache = function (usedTiles) {\n while (this.canExpireCache()) {\n var tile = this.peekLast();\n if (tile.getKey() in usedTiles) {\n break;\n }\n else {\n this.pop().release();\n }\n }\n };\n /**\n * Prune all tiles from the cache that don't have the same z as the newest tile.\n */\n TileCache.prototype.pruneExceptNewestZ = function () {\n if (this.getCount() === 0) {\n return;\n }\n var key = this.peekFirstKey();\n var tileCoord = fromKey(key);\n var z = tileCoord[0];\n this.forEach(function (tile) {\n if (tile.tileCoord[0] !== z) {\n this.remove(getKey(tile.tileCoord));\n tile.release();\n }\n }.bind(this));\n };\n return TileCache;\n}(LRUCache));\nexport default TileCache;\n//# sourceMappingURL=TileCache.js.map","/**\n * @module ol/structs/LRUCache\n */\nimport { assert } from '../asserts.js';\n/**\n * @typedef {Object} Entry\n * @property {string} key_ Key.\n * @property {Object} newer Newer.\n * @property {Object} older Older.\n * @property {*} value_ Value.\n */\n/**\n * @classdesc\n * Implements a Least-Recently-Used cache where the keys do not conflict with\n * Object's properties (e.g. 'hasOwnProperty' is not allowed as a key). Expiring\n * items from the cache is the responsibility of the user.\n *\n * @fires import(\"../events/Event.js\").default\n * @template T\n */\nvar LRUCache = /** @class */ (function () {\n /**\n * @param {number} [opt_highWaterMark] High water mark.\n */\n function LRUCache(opt_highWaterMark) {\n /**\n * Desired max cache size after expireCache(). If set to 0, no cache entries\n * will be pruned at all.\n * @type {number}\n */\n this.highWaterMark =\n opt_highWaterMark !== undefined ? opt_highWaterMark : 2048;\n /**\n * @private\n * @type {number}\n */\n this.count_ = 0;\n /**\n * @private\n * @type {!Object<string, Entry>}\n */\n this.entries_ = {};\n /**\n * @private\n * @type {?Entry}\n */\n this.oldest_ = null;\n /**\n * @private\n * @type {?Entry}\n */\n this.newest_ = null;\n }\n /**\n * @return {boolean} Can expire cache.\n */\n LRUCache.prototype.canExpireCache = function () {\n return this.highWaterMark > 0 && this.getCount() > this.highWaterMark;\n };\n /**\n * Expire the cache.\n * @param {!Object<string, boolean>} [keep] Keys to keep. To be implemented by subclasses.\n */\n LRUCache.prototype.expireCache = function (keep) {\n while (this.canExpireCache()) {\n this.pop();\n }\n };\n /**\n * FIXME empty description for jsdoc\n */\n LRUCache.prototype.clear = function () {\n this.count_ = 0;\n this.entries_ = {};\n this.oldest_ = null;\n this.newest_ = null;\n };\n /**\n * @param {string} key Key.\n * @return {boolean} Contains key.\n */\n LRUCache.prototype.containsKey = function (key) {\n return this.entries_.hasOwnProperty(key);\n };\n /**\n * @param {function(T, string, LRUCache<T>): ?} f The function\n * to call for every entry from the oldest to the newer. This function takes\n * 3 arguments (the entry value, the entry key and the LRUCache object).\n * The return value is ignored.\n */\n LRUCache.prototype.forEach = function (f) {\n var entry = this.oldest_;\n while (entry) {\n f(entry.value_, entry.key_, this);\n entry = entry.newer;\n }\n };\n /**\n * @param {string} key Key.\n * @param {*} [opt_options] Options (reserved for subclasses).\n * @return {T} Value.\n */\n LRUCache.prototype.get = function (key, opt_options) {\n var entry = this.entries_[key];\n assert(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache\n if (entry === this.newest_) {\n return entry.value_;\n }\n else if (entry === this.oldest_) {\n this.oldest_ = /** @type {Entry} */ (this.oldest_.newer);\n this.oldest_.older = null;\n }\n else {\n entry.newer.older = entry.older;\n entry.older.newer = entry.newer;\n }\n entry.newer = null;\n entry.older = this.newest_;\n this.newest_.newer = entry;\n this.newest_ = entry;\n return entry.value_;\n };\n /**\n * Remove an entry from the cache.\n * @param {string} key The entry key.\n * @return {T} The removed entry.\n */\n LRUCache.prototype.remove = function (key) {\n var entry = this.entries_[key];\n assert(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache\n if (entry === this.newest_) {\n this.newest_ = /** @type {Entry} */ (entry.older);\n if (this.newest_) {\n this.newest_.newer = null;\n }\n }\n else if (entry === this.oldest_) {\n this.oldest_ = /** @type {Entry} */ (entry.newer);\n if (this.oldest_) {\n this.oldest_.older = null;\n }\n }\n else {\n entry.newer.older = entry.older;\n entry.older.newer = entry.newer;\n }\n delete this.entries_[key];\n --this.count_;\n return entry.value_;\n };\n /**\n * @return {number} Count.\n */\n LRUCache.prototype.getCount = function () {\n return this.count_;\n };\n /**\n * @return {Array<string>} Keys.\n */\n LRUCache.prototype.getKeys = function () {\n var keys = new Array(this.count_);\n var i = 0;\n var entry;\n for (entry = this.newest_; entry; entry = entry.older) {\n keys[i++] = entry.key_;\n }\n return keys;\n };\n /**\n * @return {Array<T>} Values.\n */\n LRUCache.prototype.getValues = function () {\n var values = new Array(this.count_);\n var i = 0;\n var entry;\n for (entry = this.newest_; entry; entry = entry.older) {\n values[i++] = entry.value_;\n }\n return values;\n };\n /**\n * @return {T} Last value.\n */\n LRUCache.prototype.peekLast = function () {\n return this.oldest_.value_;\n };\n /**\n * @return {string} Last key.\n */\n LRUCache.prototype.peekLastKey = function () {\n return this.oldest_.key_;\n };\n /**\n * Get the key of the newest item in the cache. Throws if the cache is empty.\n * @return {string} The newest key.\n */\n LRUCache.prototype.peekFirstKey = function () {\n return this.newest_.key_;\n };\n /**\n * @return {T} value Value.\n */\n LRUCache.prototype.pop = function () {\n var entry = this.oldest_;\n delete this.entries_[entry.key_];\n if (entry.newer) {\n entry.newer.older = null;\n }\n this.oldest_ = /** @type {Entry} */ (entry.newer);\n if (!this.oldest_) {\n this.newest_ = null;\n }\n --this.count_;\n return entry.value_;\n };\n /**\n * @param {string} key Key.\n * @param {T} value Value.\n */\n LRUCache.prototype.replace = function (key, value) {\n this.get(key); // update `newest_`\n this.entries_[key].value_ = value;\n };\n /**\n * @param {string} key Key.\n * @param {T} value Value.\n */\n LRUCache.prototype.set = function (key, value) {\n assert(!(key in this.entries_), 16); // Tried to set a value for a key that is used already\n var entry = {\n key_: key,\n newer: null,\n older: this.newest_,\n value_: value,\n };\n if (!this.newest_) {\n this.oldest_ = entry;\n }\n else {\n this.newest_.newer = entry;\n }\n this.newest_ = entry;\n this.entries_[key] = entry;\n ++this.count_;\n };\n /**\n * Set a maximum number of entries for the cache.\n * @param {number} size Cache size.\n * @api\n */\n LRUCache.prototype.setSize = function (size) {\n this.highWaterMark = size;\n };\n return LRUCache;\n}());\nexport default LRUCache;\n//# sourceMappingURL=LRUCache.js.map","/**\n * @module ol/tilecoord\n */\n/**\n * An array of three numbers representing the location of a tile in a tile\n * grid. The order is `z` (zoom level), `x` (column), and `y` (row).\n * @typedef {Array<number>} TileCoord\n * @api\n */\n/**\n * @param {number} z Z.\n * @param {number} x X.\n * @param {number} y Y.\n * @param {TileCoord} [opt_tileCoord] Tile coordinate.\n * @return {TileCoord} Tile coordinate.\n */\nexport function createOrUpdate(z, x, y, opt_tileCoord) {\n if (opt_tileCoord !== undefined) {\n opt_tileCoord[0] = z;\n opt_tileCoord[1] = x;\n opt_tileCoord[2] = y;\n return opt_tileCoord;\n }\n else {\n return [z, x, y];\n }\n}\n/**\n * @param {number} z Z.\n * @param {number} x X.\n * @param {number} y Y.\n * @return {string} Key.\n */\nexport function getKeyZXY(z, x, y) {\n return z + '/' + x + '/' + y;\n}\n/**\n * Get the key for a tile coord.\n * @param {TileCoord} tileCoord The tile coord.\n * @return {string} Key.\n */\nexport function getKey(tileCoord) {\n return getKeyZXY(tileCoord[0], tileCoord[1], tileCoord[2]);\n}\n/**\n * Get the tile cache key for a tile key obtained through `tile.getKey()`.\n * @param {string} tileKey The tile key.\n * @return {string} The cache key.\n */\nexport function getCacheKeyForTileKey(tileKey) {\n var _a = tileKey\n .substring(tileKey.lastIndexOf('/') + 1, tileKey.length)\n .split(',')\n .map(Number), z = _a[0], x = _a[1], y = _a[2];\n return getKeyZXY(z, x, y);\n}\n/**\n * Get a tile coord given a key.\n * @param {string} key The tile coord key.\n * @return {TileCoord} The tile coord.\n */\nexport function fromKey(key) {\n return key.split('/').map(Number);\n}\n/**\n * @param {TileCoord} tileCoord Tile coord.\n * @return {number} Hash.\n */\nexport function hash(tileCoord) {\n return (tileCoord[1] << tileCoord[0]) + tileCoord[2];\n}\n/**\n * @param {TileCoord} tileCoord Tile coordinate.\n * @param {!import(\"./tilegrid/TileGrid.js\").default} tileGrid Tile grid.\n * @return {boolean} Tile coordinate is within extent and zoom level range.\n */\nexport function withinExtentAndZ(tileCoord, tileGrid) {\n var z = tileCoord[0];\n var x = tileCoord[1];\n var y = tileCoord[2];\n if (tileGrid.getMinZoom() > z || z > tileGrid.getMaxZoom()) {\n return false;\n }\n var tileRange = tileGrid.getFullTileRange(z);\n if (!tileRange) {\n return true;\n }\n else {\n return tileRange.containsXY(x, y);\n }\n}\n//# sourceMappingURL=tilecoord.js.map"],"names":[],"sourceRoot":""}