ol 10.7.1 → 10.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (268) hide show
  1. package/Collection.d.ts +1 -3
  2. package/Collection.d.ts.map +1 -1
  3. package/Feature.d.ts +6 -15
  4. package/Feature.d.ts.map +1 -1
  5. package/Feature.js +3 -6
  6. package/Geolocation.d.ts +1 -3
  7. package/Geolocation.d.ts.map +1 -1
  8. package/ImageTile.d.ts +2 -12
  9. package/ImageTile.d.ts.map +1 -1
  10. package/ImageTile.js +5 -32
  11. package/Map.d.ts +7 -27
  12. package/Map.d.ts.map +1 -1
  13. package/Map.js +3 -29
  14. package/Object.d.ts +18 -15
  15. package/Object.d.ts.map +1 -1
  16. package/Object.js +6 -9
  17. package/Overlay.d.ts +1 -3
  18. package/Overlay.d.ts.map +1 -1
  19. package/VectorRenderTile.d.ts +0 -4
  20. package/VectorRenderTile.d.ts.map +1 -1
  21. package/VectorRenderTile.js +0 -2
  22. package/View.d.ts +1 -40
  23. package/View.d.ts.map +1 -1
  24. package/View.js +0 -94
  25. package/colorlike.js +8 -4
  26. package/control/Control.d.ts +1 -3
  27. package/control/Control.d.ts.map +1 -1
  28. package/control/OverviewMap.d.ts +1 -5
  29. package/control/OverviewMap.d.ts.map +1 -1
  30. package/coordinate.d.ts +0 -8
  31. package/coordinate.d.ts.map +1 -1
  32. package/coordinate.js +1 -31
  33. package/dist/ol.d.ts +0 -24
  34. package/dist/ol.d.ts.map +1 -1
  35. package/dist/ol.js +1 -1
  36. package/dist/ol.js.map +1 -1
  37. package/dom.d.ts +0 -15
  38. package/dom.d.ts.map +1 -1
  39. package/dom.js +0 -6
  40. package/featureloader.d.ts +2 -6
  41. package/featureloader.d.ts.map +1 -1
  42. package/format/EsriJSON.d.ts +1 -3
  43. package/format/EsriJSON.d.ts.map +1 -1
  44. package/format/Feature.d.ts +1 -3
  45. package/format/Feature.d.ts.map +1 -1
  46. package/format/GeoJSON.d.ts +2 -6
  47. package/format/GeoJSON.d.ts.map +1 -1
  48. package/format/JSONFeature.d.ts +1 -3
  49. package/format/JSONFeature.d.ts.map +1 -1
  50. package/format/KML.d.ts +0 -9
  51. package/format/KML.d.ts.map +1 -1
  52. package/format/KML.js +0 -7
  53. package/format/TextFeature.d.ts +1 -3
  54. package/format/TextFeature.d.ts.map +1 -1
  55. package/format/TopoJSON.d.ts +1 -3
  56. package/format/TopoJSON.d.ts.map +1 -1
  57. package/format/WKB.d.ts +1 -3
  58. package/format/WKB.d.ts.map +1 -1
  59. package/format/XMLFeature.d.ts +1 -3
  60. package/format/XMLFeature.d.ts.map +1 -1
  61. package/geom/Geometry.d.ts +1 -3
  62. package/geom/Geometry.d.ts.map +1 -1
  63. package/interaction/DragAndDrop.d.ts +2 -6
  64. package/interaction/DragAndDrop.d.ts.map +1 -1
  65. package/interaction/Draw.d.ts +3 -9
  66. package/interaction/Draw.d.ts.map +1 -1
  67. package/interaction/Interaction.d.ts +1 -3
  68. package/interaction/Interaction.d.ts.map +1 -1
  69. package/interaction/Link.js +2 -2
  70. package/interaction/Modify.d.ts +28 -76
  71. package/interaction/Modify.d.ts.map +1 -1
  72. package/interaction/Modify.js +54 -248
  73. package/interaction/Select.d.ts +18 -10
  74. package/interaction/Select.d.ts.map +1 -1
  75. package/interaction/Select.js +89 -54
  76. package/interaction/Snap.d.ts +12 -18
  77. package/interaction/Snap.d.ts.map +1 -1
  78. package/interaction/Translate.d.ts +2 -6
  79. package/interaction/Translate.d.ts.map +1 -1
  80. package/layer/Base.d.ts +8 -19
  81. package/layer/Base.d.ts.map +1 -1
  82. package/layer/Base.js +3 -6
  83. package/layer/BaseImage.d.ts +1 -3
  84. package/layer/BaseImage.d.ts.map +1 -1
  85. package/layer/BaseTile.d.ts +1 -3
  86. package/layer/BaseTile.d.ts.map +1 -1
  87. package/layer/BaseVector.d.ts +1 -3
  88. package/layer/BaseVector.d.ts.map +1 -1
  89. package/layer/Flow.d.ts +2 -2
  90. package/layer/Graticule.d.ts +1 -5
  91. package/layer/Graticule.d.ts.map +1 -1
  92. package/layer/Group.d.ts +2 -8
  93. package/layer/Group.d.ts.map +1 -1
  94. package/layer/Heatmap.d.ts +2 -23
  95. package/layer/Heatmap.d.ts.map +1 -1
  96. package/layer/Heatmap.js +0 -29
  97. package/layer/Layer.d.ts +8 -17
  98. package/layer/Layer.d.ts.map +1 -1
  99. package/layer/Layer.js +2 -5
  100. package/layer/Tile.d.ts +1 -1
  101. package/layer/Vector.d.ts +2 -2
  102. package/layer/Vector.d.ts.map +1 -1
  103. package/layer/VectorImage.d.ts +2 -2
  104. package/layer/VectorImage.d.ts.map +1 -1
  105. package/layer/VectorTile.d.ts +2 -2
  106. package/layer/VectorTile.d.ts.map +1 -1
  107. package/layer/WebGLPoints.d.ts +1 -3
  108. package/layer/WebGLPoints.d.ts.map +1 -1
  109. package/layer/WebGLTile.d.ts +3 -3
  110. package/layer/WebGLTile.d.ts.map +1 -1
  111. package/layer/WebGLVector.d.ts +2 -4
  112. package/layer/WebGLVector.d.ts.map +1 -1
  113. package/layer/WebGLVectorTile.d.ts +2 -2
  114. package/layer/WebGLVectorTile.d.ts.map +1 -1
  115. package/package.json +3 -4
  116. package/proj/proj4.d.ts +6 -43
  117. package/proj/proj4.d.ts.map +1 -1
  118. package/proj/proj4.js +28 -89
  119. package/proj.js +2 -2
  120. package/render/canvas/Builder.d.ts.map +1 -1
  121. package/render/canvas/Builder.js +1 -8
  122. package/render/canvas/Executor.d.ts.map +1 -1
  123. package/render/canvas/Executor.js +3 -49
  124. package/render/canvas/ExecutorGroup.d.ts.map +1 -1
  125. package/render/canvas/ExecutorGroup.js +5 -41
  126. package/render/canvas/Immediate.d.ts +0 -2
  127. package/render/canvas/Immediate.d.ts.map +1 -1
  128. package/render/canvas/Immediate.js +4 -28
  129. package/render/canvas/LineStringBuilder.d.ts +0 -1
  130. package/render/canvas/LineStringBuilder.d.ts.map +1 -1
  131. package/render/canvas/LineStringBuilder.js +5 -15
  132. package/render/canvas/PolygonBuilder.d.ts +0 -2
  133. package/render/canvas/PolygonBuilder.d.ts.map +1 -1
  134. package/render/canvas/PolygonBuilder.js +6 -72
  135. package/render/canvas/style.d.ts.map +1 -1
  136. package/render/canvas/style.js +37 -118
  137. package/render/canvas.d.ts +2 -22
  138. package/render/canvas.d.ts.map +1 -1
  139. package/render/canvas.js +0 -9
  140. package/render/webgl/bufferUtil.d.ts.map +1 -1
  141. package/render/webgl/bufferUtil.js +31 -1
  142. package/renderer/Composite.js +4 -4
  143. package/renderer/canvas/ImageLayer.d.ts +1 -6
  144. package/renderer/canvas/ImageLayer.d.ts.map +1 -1
  145. package/renderer/canvas/ImageLayer.js +0 -14
  146. package/renderer/canvas/TileLayer.d.ts +1 -1
  147. package/renderer/canvas/VectorLayer.d.ts +1 -8
  148. package/renderer/canvas/VectorLayer.d.ts.map +1 -1
  149. package/renderer/canvas/VectorLayer.js +14 -55
  150. package/renderer/canvas/VectorTileLayer.d.ts +1 -1
  151. package/renderer/canvas/VectorTileLayer.d.ts.map +1 -1
  152. package/renderer/canvas/VectorTileLayer.js +0 -2
  153. package/renderer/webgl/TileLayerBase.js +1 -1
  154. package/reproj/Tile.d.ts +2 -7
  155. package/reproj/Tile.d.ts.map +1 -1
  156. package/reproj/Tile.js +6 -12
  157. package/source/Cluster.d.ts +2 -8
  158. package/source/Cluster.d.ts.map +1 -1
  159. package/source/DataTile.d.ts +0 -15
  160. package/source/DataTile.d.ts.map +1 -1
  161. package/source/DataTile.js +0 -9
  162. package/source/GeoTIFF.d.ts +2 -7
  163. package/source/GeoTIFF.d.ts.map +1 -1
  164. package/source/GeoTIFF.js +10 -15
  165. package/source/ImageArcGISRest.d.ts +0 -10
  166. package/source/ImageArcGISRest.d.ts.map +1 -1
  167. package/source/ImageArcGISRest.js +0 -8
  168. package/source/ImageMapGuide.d.ts +0 -10
  169. package/source/ImageMapGuide.d.ts.map +1 -1
  170. package/source/ImageMapGuide.js +0 -8
  171. package/source/ImageStatic.d.ts +0 -5
  172. package/source/ImageStatic.d.ts.map +1 -1
  173. package/source/ImageStatic.js +0 -2
  174. package/source/ImageTile.d.ts +1 -5
  175. package/source/ImageTile.d.ts.map +1 -1
  176. package/source/ImageTile.js +0 -5
  177. package/source/ImageWMS.d.ts +0 -10
  178. package/source/ImageWMS.d.ts.map +1 -1
  179. package/source/ImageWMS.js +0 -10
  180. package/source/OGCMapTile.d.ts +0 -5
  181. package/source/OGCMapTile.d.ts.map +1 -1
  182. package/source/OGCMapTile.js +0 -2
  183. package/source/OSM.d.ts +0 -5
  184. package/source/OSM.d.ts.map +1 -1
  185. package/source/OSM.js +19 -5
  186. package/source/SentinelHub.d.ts +0 -1
  187. package/source/SentinelHub.d.ts.map +1 -1
  188. package/source/SentinelHub.js +0 -5
  189. package/source/Source.d.ts +1 -3
  190. package/source/Source.d.ts.map +1 -1
  191. package/source/TileArcGISRest.d.ts +1 -6
  192. package/source/TileArcGISRest.d.ts.map +1 -1
  193. package/source/TileArcGISRest.js +0 -2
  194. package/source/TileDebug.d.ts +1 -1
  195. package/source/TileImage.d.ts +0 -10
  196. package/source/TileImage.d.ts.map +1 -1
  197. package/source/TileImage.js +3 -16
  198. package/source/TileWMS.d.ts +1 -1
  199. package/source/UrlTile.d.ts +1 -1
  200. package/source/Vector.d.ts +8 -18
  201. package/source/Vector.d.ts.map +1 -1
  202. package/source/Vector.js +3 -3
  203. package/source/WMTS.d.ts +0 -5
  204. package/source/WMTS.d.ts.map +1 -1
  205. package/source/WMTS.js +0 -2
  206. package/source/XYZ.d.ts +0 -5
  207. package/source/XYZ.d.ts.map +1 -1
  208. package/source/XYZ.js +0 -2
  209. package/source/Zoomify.d.ts +2 -7
  210. package/source/Zoomify.d.ts.map +1 -1
  211. package/source/Zoomify.js +3 -5
  212. package/source/arcgisRest.d.ts +0 -5
  213. package/source/arcgisRest.d.ts.map +1 -1
  214. package/source/arcgisRest.js +0 -5
  215. package/source/mapguide.d.ts +0 -4
  216. package/source/mapguide.d.ts.map +1 -1
  217. package/source/mapguide.js +0 -5
  218. package/source/mapserver.d.ts +1 -5
  219. package/source/mapserver.d.ts.map +1 -1
  220. package/source/mapserver.js +0 -4
  221. package/source/ogcTileUtil.d.ts +12 -20
  222. package/source/ogcTileUtil.d.ts.map +1 -1
  223. package/source/ogcTileUtil.js +15 -27
  224. package/source/static.d.ts +0 -5
  225. package/source/static.d.ts.map +1 -1
  226. package/source/static.js +0 -4
  227. package/source/wms.d.ts +0 -5
  228. package/source/wms.d.ts.map +1 -1
  229. package/source/wms.js +0 -5
  230. package/style/Circle.d.ts +14 -0
  231. package/style/Circle.d.ts.map +1 -1
  232. package/style/Circle.js +11 -0
  233. package/style/Fill.js +1 -1
  234. package/style/Icon.d.ts +0 -19
  235. package/style/Icon.d.ts.map +1 -1
  236. package/style/Icon.js +2 -55
  237. package/style/IconImage.d.ts +5 -14
  238. package/style/IconImage.d.ts.map +1 -1
  239. package/style/IconImage.js +18 -28
  240. package/style/IconImageCache.d.ts +8 -4
  241. package/style/IconImageCache.d.ts.map +1 -1
  242. package/style/IconImageCache.js +13 -11
  243. package/style/RegularShape.d.ts +0 -12
  244. package/style/RegularShape.d.ts.map +1 -1
  245. package/style/RegularShape.js +4 -36
  246. package/style/Stroke.d.ts +0 -25
  247. package/style/Stroke.d.ts.map +1 -1
  248. package/style/Stroke.js +0 -28
  249. package/style/Style.d.ts +1 -1
  250. package/style/flat.d.ts +2 -2
  251. package/style/flat.js +1 -1
  252. package/tilegrid/TileGrid.d.ts +0 -5
  253. package/tilegrid/TileGrid.d.ts.map +1 -1
  254. package/tilegrid/TileGrid.js +0 -8
  255. package/util.js +1 -1
  256. package/worker/webgl.js +1 -1
  257. package/geom/flat/lineoffset.d.ts +0 -45
  258. package/geom/flat/lineoffset.d.ts.map +0 -1
  259. package/geom/flat/lineoffset.js +0 -173
  260. package/source/GeoZarr.d.ts +0 -163
  261. package/source/GeoZarr.d.ts.map +0 -1
  262. package/source/GeoZarr.js +0 -472
  263. package/source/OGCMap.d.ts +0 -180
  264. package/source/OGCMap.d.ts.map +0 -1
  265. package/source/OGCMap.js +0 -227
  266. package/source/ogcMapUtil.d.ts +0 -88
  267. package/source/ogcMapUtil.d.ts.map +0 -1
  268. package/source/ogcMapUtil.js +0 -121
@@ -125,9 +125,7 @@ export type Options = {
125
125
  * selectable. If the option is absent, all visible layers will be considered
126
126
  * selectable.
127
127
  */
128
- layers?: import("../layer.js").Layer<import("../source.js").Source, import("../renderer/Layer.js").default<any>, {
129
- [x: string]: any;
130
- }>[] | ((arg0: import("../layer/Layer.js").default<import("../source/Source").default>) => boolean) | undefined;
128
+ layers?: import("../layer/Layer.js").default<import("../source/Source").default, import("../renderer/Layer.js").default<any>>[] | ((arg0: import("../layer/Layer.js").default<import("../source/Source").default>) => boolean) | undefined;
131
129
  /**
132
130
  * Style for the selected features. By default the default edit style is used
133
131
  * (see {@link module :ol/style/Style~Style}). Set to `null` if this interaction should not apply
@@ -166,9 +164,7 @@ export type Options = {
166
164
  * used by the interaction is returned by
167
165
  * {@link module :ol/interaction/Select~Select#getFeatures}.
168
166
  */
169
- features?: Collection<Feature<import("../geom.js").Geometry, {
170
- [x: string]: any;
171
- }>> | undefined;
167
+ features?: Collection<Feature<import("../geom.js").Geometry>> | undefined;
172
168
  /**
173
169
  * A function
174
170
  * that takes a {@link module :ol/Feature~Feature} and a
@@ -363,22 +359,36 @@ declare class Select extends Interaction {
363
359
  * @private
364
360
  */
365
361
  private removeFeatureLayerAssociation_;
362
+ /**
363
+ * @param {import("../Feature.js").FeatureLike} feature The feature to select
364
+ * @param {import("../layer/Layer.js").default} layer Optional layer containing this feature
365
+ * @param {Array<Feature>} [selected] optional array to which selected features will be added
366
+ * @return {Feature|undefined} The feature, if it got selected.
367
+ * @private
368
+ */
369
+ private selectFeatureInternal_;
366
370
  /**
367
371
  * Try to select a feature as if it was clicked and `addCondition` evaluated to True.
368
372
  * Unlike modifying `select.getFeatures()` directly, this respects the `filter` and `layers` options (except `multi`, which is ignored).
369
373
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
370
374
  * @param {Feature} feature The feature to select
371
375
  * @return {boolean} True if the feature was selected
372
- * @api
373
376
  */
374
377
  selectFeature(feature: Feature): boolean;
378
+ /**
379
+ * Deselects a feature if it was previously selected. Also removes layer association.
380
+ * @param {import("../Feature.js").FeatureLike} feature The feature to deselect
381
+ * @param {Array<Feature>} [deselected] optional array to which deselected features will be added
382
+ * @return {Feature|undefined} The feature, if it was previously selected.
383
+ * @private
384
+ */
385
+ private removeFeatureInternal_;
375
386
  /**
376
387
  * Try to deselect a feature as if it was clicked.
377
388
  * Compared to `select.getFeatures().remove(feature)` this causes a SelectEvent.
378
389
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
379
390
  * @param {Feature} feature The feature to deselect
380
391
  * @return {boolean} True if the feature was deselected
381
- * @api
382
392
  */
383
393
  deselectFeature(feature: Feature): boolean;
384
394
  /**
@@ -386,14 +396,12 @@ declare class Select extends Interaction {
386
396
  * Unlike modifying `select.getFeatures()` directly, this respects the `filter` and `layers` options (except `multi`, which is ignored).
387
397
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
388
398
  * @param {Feature} feature The feature to deselect
389
- * @api
390
399
  */
391
400
  toggleFeature(feature: Feature): void;
392
401
  /**
393
402
  * Deselect all features as if a user deselected them.
394
403
  * Compared to `select.getFeatures().clear()` this causes a SelectEvent.
395
404
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
396
- * @api
397
405
  */
398
406
  clearSelection(): void;
399
407
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["Select.js"],"names":[],"mappings":"AA2BA;;;;GAIG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsDG;AAEH;;;;GAIG;AACH;IACE;;;;;;OAMG;IACH,kBANW,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B;IAwCD;;;OAGG;IACH,oBAWC;IAED;;;OAGG;IACH,uBAIC;IAED;;;;OAIG;IACH,4BAeC;IAED;;OAEG;IACH,YAFY,OAAO,mBAAmB,EAAE,SAAS,GAAC,IAAI,CAIrD;IAED;;;OAGG;IACH,4BAMC;IAED;;;OAGG;IACH,8BAkBC;IAED;;;OAGG;IACH,uCAEC;IAED;;;;;;OAMG;IACH,+BAcC;IAED;;;;;;OAMG;IACH,uBAHW,OAAO,GACN,OAAO,CAclB;IAED;;;;;;OAMG;IACH,+BAYC;IAED;;;;;;OAMG;IACH,yBAHW,OAAO,GACN,OAAO,CAUlB;IAED;;;;;OAKG;IACH,uBAFW,OAAO,QAMjB;IACD;;;;OAIG;IACH,uBAUC;CAwGF;oBApqBmB,eAAe;uBAFZ,kBAAkB;wBAWjB,kBAAkB"}
@@ -9,6 +9,7 @@ import Event from '../events/Event.js';
9
9
  import {never, shiftKeyOnly, singleClick} from '../events/condition.js';
10
10
  import {TRUE} from '../functions.js';
11
11
  import VectorLayer from '../layer/Vector.js';
12
+ import {clear} from '../obj.js';
12
13
  import {createEditingStyle} from '../style/Style.js';
13
14
  import {getUid} from '../util.js';
14
15
  import Interaction from './Interaction.js';
@@ -391,7 +392,6 @@ class Select extends Interaction {
391
392
  if (this.style_) {
392
393
  this.restorePreviousStyle_(evt.element);
393
394
  }
394
- this.removeFeatureLayerAssociation_(evt.element);
395
395
  }
396
396
 
397
397
  /**
@@ -467,29 +467,69 @@ class Select extends Interaction {
467
467
  delete this.featureLayerAssociation_[getUid(feature)];
468
468
  }
469
469
 
470
+ /**
471
+ * @param {import("../Feature.js").FeatureLike} feature The feature to select
472
+ * @param {import("../layer/Layer.js").default} layer Optional layer containing this feature
473
+ * @param {Array<Feature>} [selected] optional array to which selected features will be added
474
+ * @return {Feature|undefined} The feature, if it got selected.
475
+ * @private
476
+ */
477
+ selectFeatureInternal_(feature, layer, selected) {
478
+ if (!(feature instanceof Feature)) {
479
+ return;
480
+ }
481
+ if (!this.filter_(feature, layer)) {
482
+ return;
483
+ }
484
+ const features = this.getFeatures();
485
+ if (!features.getArray().includes(feature)) {
486
+ this.addFeatureLayerAssociation_(feature, layer);
487
+ features.push(feature);
488
+ selected?.push(feature);
489
+ }
490
+ return feature;
491
+ }
492
+
470
493
  /**
471
494
  * Try to select a feature as if it was clicked and `addCondition` evaluated to True.
472
495
  * Unlike modifying `select.getFeatures()` directly, this respects the `filter` and `layers` options (except `multi`, which is ignored).
473
496
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
474
497
  * @param {Feature} feature The feature to select
475
498
  * @return {boolean} True if the feature was selected
476
- * @api
477
499
  */
478
500
  selectFeature(feature) {
479
501
  const layer = this.findLayerOfFeature_(feature);
480
- if (!this.layerFilter_(layer) || !this.filter_(feature, layer)) {
502
+ if (!this.layerFilter_(layer)) {
481
503
  return false;
482
504
  }
505
+ const selected = this.selectFeatureInternal_(feature, layer);
506
+ if (selected) {
507
+ this.dispatchEvent(
508
+ new SelectEvent(SelectEventType.SELECT, [selected], [], undefined),
509
+ );
510
+ }
511
+ return !!selected;
512
+ }
513
+
514
+ /**
515
+ * Deselects a feature if it was previously selected. Also removes layer association.
516
+ * @param {import("../Feature.js").FeatureLike} feature The feature to deselect
517
+ * @param {Array<Feature>} [deselected] optional array to which deselected features will be added
518
+ * @return {Feature|undefined} The feature, if it was previously selected.
519
+ * @private
520
+ */
521
+ removeFeatureInternal_(feature, deselected) {
483
522
  const features = this.getFeatures();
484
- if (features.getArray().includes(feature)) {
485
- return false;
523
+ if (
524
+ !(feature instanceof Feature) ||
525
+ !features.getArray().includes(feature)
526
+ ) {
527
+ return;
486
528
  }
487
- this.addFeatureLayerAssociation_(feature, layer);
488
- features.push(feature);
489
- this.dispatchEvent(
490
- new SelectEvent(SelectEventType.SELECT, [feature], [], undefined),
491
- );
492
- return true;
529
+ features.remove(feature);
530
+ this.removeFeatureLayerAssociation_(feature);
531
+ deselected?.push(feature);
532
+ return feature;
493
533
  }
494
534
 
495
535
  /**
@@ -498,19 +538,15 @@ class Select extends Interaction {
498
538
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
499
539
  * @param {Feature} feature The feature to deselect
500
540
  * @return {boolean} True if the feature was deselected
501
- * @api
502
541
  */
503
542
  deselectFeature(feature) {
504
- const features = this.getFeatures();
505
- const index = features.getArray().indexOf(feature);
506
- if (index === -1) {
507
- return false;
543
+ const deselected = this.removeFeatureInternal_(feature);
544
+ if (deselected) {
545
+ this.dispatchEvent(
546
+ new SelectEvent(SelectEventType.SELECT, [], [deselected], undefined),
547
+ );
508
548
  }
509
- features.removeAt(index);
510
- this.dispatchEvent(
511
- new SelectEvent(SelectEventType.SELECT, [], [feature], undefined),
512
- );
513
- return true;
549
+ return !!deselected;
514
550
  }
515
551
 
516
552
  /**
@@ -518,25 +554,23 @@ class Select extends Interaction {
518
554
  * Unlike modifying `select.getFeatures()` directly, this respects the `filter` and `layers` options (except `multi`, which is ignored).
519
555
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
520
556
  * @param {Feature} feature The feature to deselect
521
- * @api
522
557
  */
523
558
  toggleFeature(feature) {
524
559
  if (!this.deselectFeature(feature)) {
525
560
  this.selectFeature(feature);
526
561
  }
527
562
  }
528
-
529
563
  /**
530
564
  * Deselect all features as if a user deselected them.
531
565
  * Compared to `select.getFeatures().clear()` this causes a SelectEvent.
532
566
  * The {@link module:ol/interaction/Select~SelectEvent} fired by this won't have a mapBrowserEvent property
533
- * @api
534
567
  */
535
568
  clearSelection() {
569
+ clear(this.featureLayerAssociation_);
536
570
  const features = this.getFeatures();
537
- if (features.getLength() !== 0) {
538
- const deselected = features.getArray().slice(); // shallow copy
539
- features.clear();
571
+ const deselected = features.getArray().slice(); // shallow copy
572
+ features.clear();
573
+ if (deselected.length !== 0) {
540
574
  this.dispatchEvent(
541
575
  new SelectEvent(SelectEventType.SELECT, [], deselected, undefined),
542
576
  );
@@ -571,19 +605,23 @@ class Select extends Interaction {
571
605
  */
572
606
  const selected = [];
573
607
 
608
+ // TODO: technically the way i've restructured this logic means that
609
+ // instead of first emptying the features list of all extra features and then adding the selected ones back,
610
+ // the selected features get added and then the old ones get removed.
611
+ // a grow then shrink, instead of a shrink then grow. I can't imagine anyone relying on this, but alas, its worth a mention.
574
612
  if (set) {
575
613
  // Replace the currently selected feature(s) with the feature(s) at the
576
614
  // pixel, or clear the selected feature(s) if there is no feature at
577
615
  // the pixel.
616
+ let foundAtCursor = false;
578
617
  map.forEachFeatureAtPixel(
579
618
  mapBrowserEvent.pixel,
580
619
  (feature, layer) => {
581
- if (!(feature instanceof Feature) || !this.filter_(feature, layer)) {
582
- return;
620
+ foundAtCursor = true;
621
+ if (!this.selectFeatureInternal_(feature, layer, selected)) {
622
+ return; // keep going, this one wasn't selected
583
623
  }
584
- this.addFeatureLayerAssociation_(feature, layer);
585
- selected.push(feature);
586
- return !this.multi_;
624
+ return !this.multi_; // stop if not multi
587
625
  },
588
626
  {
589
627
  layerFilter: this.layerFilter_,
@@ -593,32 +631,33 @@ class Select extends Interaction {
593
631
 
594
632
  for (let i = features.getLength() - 1; i >= 0; --i) {
595
633
  const feature = features.item(i);
596
- const index = selected.indexOf(feature);
597
- if (index === -1) {
598
- features.removeAt(i);
599
- deselected.push(feature);
600
- } else {
601
- // feature is already selected
602
- selected.splice(index, 1);
634
+ if (
635
+ // remove all but selected, if there were any selected
636
+ (selected.length > 0 && !selected.includes(feature)) ||
637
+ // remove all, if click outside of layer
638
+ !foundAtCursor
639
+ ) {
640
+ this.removeFeatureInternal_(feature, deselected);
603
641
  }
604
642
  }
605
- if (selected.length !== 0) {
606
- features.extend(selected);
607
- }
608
643
  } else {
609
644
  // Modify the currently selected feature(s).
610
645
  map.forEachFeatureAtPixel(
611
646
  mapBrowserEvent.pixel,
612
647
  (feature, layer) => {
613
- if (!(feature instanceof Feature) || !this.filter_(feature, layer)) {
614
- return;
648
+ let modifiedFeature;
649
+ if (remove || toggle) {
650
+ modifiedFeature = this.removeFeatureInternal_(feature, deselected);
615
651
  }
616
- const hasFeature = features.getArray().includes(feature);
617
- if (hasFeature && (remove || toggle)) {
618
- deselected.push(feature);
619
- } else if (!hasFeature && (add || toggle)) {
620
- this.addFeatureLayerAssociation_(feature, layer);
621
- selected.push(feature);
652
+ if ((add || toggle) && !modifiedFeature) {
653
+ modifiedFeature = this.selectFeatureInternal_(
654
+ feature,
655
+ layer,
656
+ selected,
657
+ );
658
+ }
659
+ if (!modifiedFeature) {
660
+ return; // keep going, this one wasn't removed/selected
622
661
  }
623
662
  return !this.multi_; // stop if not multi
624
663
  },
@@ -627,10 +666,6 @@ class Select extends Interaction {
627
666
  hitTolerance: this.hitTolerance_,
628
667
  },
629
668
  );
630
- for (let j = deselected.length - 1; j >= 0; --j) {
631
- features.remove(deselected[j]);
632
- }
633
- features.extend(selected);
634
669
  }
635
670
  if (selected.length > 0 || deselected.length > 0) {
636
671
  this.dispatchEvent(
@@ -12,9 +12,7 @@ export type SegmentData = {
12
12
  /**
13
13
  * Feature which intersects.
14
14
  */
15
- intersectionFeature?: import("../Feature.js").default<import("../geom.js").Geometry, {
16
- [x: string]: any;
17
- }> | undefined;
15
+ intersectionFeature?: import("../Feature.js").default<import("../geom/Geometry.js").default> | undefined;
18
16
  /**
19
17
  * Segment.
20
18
  */
@@ -23,7 +21,7 @@ export type SegmentData = {
23
21
  /**
24
22
  * A function taking a {@link module :ol/geom/Geometry~Geometry} as argument and returning an array of {@link Segment}s.
25
23
  */
26
- export type Segmenter<GeometryType extends import("../geom/Geometry.js").default = import("../geom.js").Geometry> = (geometry: GeometryType, projection?: import("../proj/Projection.js").default) => Array<Segment>;
24
+ export type Segmenter<GeometryType extends import("../geom/Geometry.js").default = import("../geom/Geometry.js").default> = (geometry: GeometryType, projection?: import("../proj/Projection.js").default) => Array<Segment>;
27
25
  /**
28
26
  * Each segmenter specified here will override the default segmenter for the
29
27
  * corresponding geometry type. To exclude all geometries of a specific geometry type from being snapped to,
@@ -33,49 +31,45 @@ export type Segmenters = {
33
31
  /**
34
32
  * Point segmenter.
35
33
  */
36
- Point?: Segmenter<import("../geom.js").Point> | null | undefined;
34
+ Point?: Segmenter<import("../geom/Point.js").default> | null | undefined;
37
35
  /**
38
36
  * LineString segmenter.
39
37
  */
40
- LineString?: Segmenter<import("../geom.js").LineString> | null | undefined;
38
+ LineString?: Segmenter<import("../geom/LineString.js").default> | null | undefined;
41
39
  /**
42
40
  * Polygon segmenter.
43
41
  */
44
- Polygon?: Segmenter<import("../geom.js").Polygon> | null | undefined;
42
+ Polygon?: Segmenter<import("../geom/Polygon.js").default> | null | undefined;
45
43
  /**
46
44
  * Circle segmenter.
47
45
  */
48
- Circle?: Segmenter<import("../geom.js").Circle> | null | undefined;
46
+ Circle?: Segmenter<import("../geom/Circle.js").default> | null | undefined;
49
47
  /**
50
48
  * GeometryCollection segmenter.
51
49
  */
52
- GeometryCollection?: Segmenter<import("../geom.js").GeometryCollection> | null | undefined;
50
+ GeometryCollection?: Segmenter<import("../geom/GeometryCollection.js").default> | null | undefined;
53
51
  /**
54
52
  * MultiPoint segmenter.
55
53
  */
56
- MultiPoint?: Segmenter<import("../geom.js").MultiPoint> | null | undefined;
54
+ MultiPoint?: Segmenter<import("../geom/MultiPoint.js").default> | null | undefined;
57
55
  /**
58
56
  * MultiLineString segmenter.
59
57
  */
60
- MultiLineString?: Segmenter<import("../geom.js").MultiLineString> | null | undefined;
58
+ MultiLineString?: Segmenter<import("../geom/MultiLineString.js").default> | null | undefined;
61
59
  /**
62
60
  * MultiPolygon segmenter.
63
61
  */
64
- MultiPolygon?: Segmenter<import("../geom.js").MultiPolygon> | null | undefined;
62
+ MultiPolygon?: Segmenter<import("../geom/MultiPolygon.js").default> | null | undefined;
65
63
  };
66
64
  export type Options = {
67
65
  /**
68
66
  * Snap to these features. Either this option or source should be provided.
69
67
  */
70
- features?: import("../Collection.js").default<import("../Feature.js").default<import("../geom.js").Geometry, {
71
- [x: string]: any;
72
- }>> | undefined;
68
+ features?: import("../Collection.js").default<import("../Feature.js").default<import("../geom/Geometry.js").default>> | undefined;
73
69
  /**
74
70
  * Snap to features from this source. Either this option or features should be provided
75
71
  */
76
- source?: import("../source.js").Vector<import("../Feature.js").default<import("../geom.js").Geometry, {
77
- [x: string]: any;
78
- }>> | undefined;
72
+ source?: import("../source/Vector.js").default<import("../Feature.js").default<import("../geom/Geometry.js").default>> | undefined;
79
73
  /**
80
74
  * Snap to edges.
81
75
  */
@@ -1 +1 @@
1
- {"version":3,"file":"Snap.d.ts","sourceRoot":"","sources":["Snap.js"],"names":[],"mappings":";;;;;sBAkCa,KAAK,CAAC,OAAO,kBAAkB,EAAE,UAAU,CAAC;;;;;aAO3C,OAAO,eAAe,EAAE,OAAO;;;;;;;;;;aAE/B,OAAO;;;;;sBAIiC,YAAY,SAArD,OAAQ,qBAAqB,EAAE,OAAQ,oCACvC,CAAC,QAAQ,EAAE,YAAY,EAAE,UAAU,CAAC,EAAE,OAAO,uBAAuB,EAAE,OAAO,KAAK,KAAK,CAAC,OAAO,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA2C/F,OAAO,kBAAkB,EAAE,UAAU,GAAC,IAAI;;;;iBAC1C,OAAO,aAAa,EAAE,KAAK,GAAC,IAAI;;;;aAChC,OAAO,eAAe,EAAE,OAAO,GAAC,IAAI;;;;aACpC,OAAO,GAAC,IAAI;;;;;4BAgMb,MAAM,IACN,OAAO,eAAe,EAAE,WAAW,CAAC,OAAO,eAAe,EAAE,UAAU,EAAE,OAAO,oBAAoB,EAAE,OAAO,EAAE,MAAM,CAAC,GACjI,OAAW,eAAe,EAAE,WAAW,CAAC,OAAO,oBAAoB,EAAE,KAAK,GAC1E,eAAqB,EAAE,OAAO,WAAW,EAAE,WAAW,EAAE,MAAM,CAAC,GAC/D,OAAW,eAAe,EAAE,W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AAE,OAAO,GAC1B,WAAW,GAAC,IAAI,CAkH3B;IAED;;;OAGG;IACH,uBAGC;CACF;0BA71BsC,wBAAwB;+BAqBhC,cAAc"}
@@ -85,9 +85,7 @@ export type Options = {
85
85
  /**
86
86
  * Features contained in this collection will be able to be translated together.
87
87
  */
88
- features?: Collection<Feature<import("../geom.js").Geometry, {
89
- [x: string]: any;
90
- }>> | undefined;
88
+ features?: Collection<Feature<import("../geom.js").Geometry>> | undefined;
91
89
  /**
92
90
  * A list of layers from which features should be
93
91
  * translated. Alternatively, a filter function can be provided. The
@@ -96,9 +94,7 @@ export type Options = {
96
94
  * absent, all visible layers will be considered translatable.
97
95
  * Not used if `features` is provided.
98
96
  */
99
- layers?: import("../layer.js").Layer<import("../source.js").Source, import("../renderer/Layer.js").default<any>, {
100
- [x: string]: any;
101
- }>[] | ((arg0: import("../layer/Layer.js").default<import("../source/Source").default>) => boolean) | undefined;
97
+ layers?: import("../layer/Layer.js").default<import("../source/Source").default, import("../renderer/Layer.js").default<any>>[] | ((arg0: import("../layer/Layer.js").default<import("../source/Source").default>) => boolean) | undefined;
102
98
  /**
103
99
  * A function
104
100
  * that takes a {@link module :ol/Feature~Feature} and an
@@ -1 +1 @@
1
- {"version":3,"file":"Translate.d.ts","sourceRoot":"","sources":["Translate.js"],"names":[],"mappings":"AAoCA;;;;;;GAMG;AAEH;;;;;;;;;;;;;;;;;;;GAmBG;AAEH;;;;GAIG;AACH;IACE;;;;;;OAMG;IACH,kBANW,kBAAkB,YAClB,UAAU,CAAC,OAAO,CAAC,cACnB,OAAO,kBAAkB,EAAE,UAAU,mBACrC,OAAO,kBAAkB,EAAE,UAAU,mBACrC,OAAO,uBAAuB,EAAE,OAAO,EAkCjD;IA7BC;;;;OAIG;IACH,UAHU,UAAU,CAAC,OAAO,CAAC,CAGL;IAExB;;;;;OAKG;IACH,YAHU,OAAO,kBAAkB,EAAE,UAAU,CAGnB;IAE5B;;;;;OAKG;IACH,iBAHU,OAAO,kBAAkB,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ED;;;;OAIG;IACH,mBAHY,MAAM,CAKjB;IAED;;;;;OAKG;IACH,8BAHW,MAAM,QAKhB;IAED;;;;;;OAMG;IACH,qBAHW,OAAO,WAAW,EAAE,OAAO,QAOrC;IAED;;OAEG;IACH,6BAEC;IAED;;;OAGG;IACH,qBAUC;CACF;+BA3a8B,cAAc"}
package/layer/Base.d.ts CHANGED
@@ -8,11 +8,7 @@ export type BaseLayerObjectEventTypes = import("../ObjectEventType").Types | "ch
8
8
  * *
9
9
  */
10
10
  export type BaseLayerOnSignature<Return> = import("../Observable").OnSignature<import("../Observable").EventTypes, import("../events/Event.js").default, Return> & import("../Observable").OnSignature<BaseLayerObjectEventTypes, import("../Object").ObjectEvent, Return> & import("../Observable").CombinedOnSignature<import("../Observable").EventTypes | BaseLayerObjectEventTypes, Return>;
11
- export type Options<Properties extends {
12
- [x: string]: any;
13
- } = {
14
- [x: string]: any;
15
- }> = {
11
+ export type Options = {
16
12
  /**
17
13
  * A CSS class name to set to the layer element.
18
14
  */
@@ -65,7 +61,9 @@ export type Options<Properties extends {
65
61
  /**
66
62
  * Arbitrary observable properties. Can be accessed with `#get()` and `#set()`.
67
63
  */
68
- properties?: Properties | undefined;
64
+ properties?: {
65
+ [x: string]: any;
66
+ } | undefined;
69
67
  };
70
68
  /**
71
69
  * A css color, or a function called with a view resolution returning a css color.
@@ -84,7 +82,6 @@ export type Options<Properties extends {
84
82
  * import("../Observable").CombinedOnSignature<import("../Observable").EventTypes|BaseLayerObjectEventTypes, Return>} BaseLayerOnSignature
85
83
  */
86
84
  /**
87
- * @template {Object<string, *>} [Properties=Object<string, *>]
88
85
  * @typedef {Object} Options
89
86
  * @property {string} [className='ol-layer'] A CSS class name to set to the layer element.
90
87
  * @property {number} [opacity=1] Opacity (0, 1).
@@ -105,7 +102,7 @@ export type Options<Properties extends {
105
102
  * be visible.
106
103
  * @property {BackgroundColor} [background] Background color for the layer. If not specified, no background
107
104
  * will be rendered.
108
- * @property {Properties} [properties] Arbitrary observable properties. Can be accessed with `#get()` and `#set()`.
105
+ * @property {Object<string, *>} [properties] Arbitrary observable properties. Can be accessed with `#get()` and `#set()`.
109
106
  */
110
107
  /**
111
108
  * @classdesc
@@ -116,20 +113,12 @@ export type Options<Properties extends {
116
113
  * is observable, and has get/set accessors.
117
114
  *
118
115
  * @api
119
- * @template {Object<string, *>} [Properties=Object<string, *>]
120
- * @extends {BaseObject<NoInfer<Properties> & Object<string, *>>}
121
116
  */
122
- declare class BaseLayer<Properties extends {
123
- [x: string]: any;
124
- } = {
125
- [x: string]: any;
126
- }> extends BaseObject<NoInfer<Properties> & {
127
- [x: string]: any;
128
- }> {
117
+ declare class BaseLayer extends BaseObject {
129
118
  /**
130
- * @param {Options<NoInfer<Properties>>} options Layer options.
119
+ * @param {Options} options Layer options.
131
120
  */
132
- constructor(options: Options<NoInfer<Properties>>);
121
+ constructor(options: Options);
133
122
  /***
134
123
  * @type {BaseLayerOnSignature<import("../events").EventsKey>}
135
124
  */
@@ -1 +1 @@
1
- {"version":3,"file":"Base.d.ts","sourceRoot":"","sources":["Base.js"],"names":[],"mappings":";;;;8BAYa,MAAM,IAAC,CAAS,IAAM,EAAN,MAAM,KAAE,MAAM,CAAA;wCAK9B,OAAO,oBAAoB,EAAE,KAAK,GAAC,eAAe,GAAC,sBAAsB,GAAC,gBAAgB,GACtG,sBAA2B,GAAC,gBAAgB,GAAC,gBAAgB,GAAC,gBAAgB,GAAC,eAAe;;;;iCAIlF,MAAM,IACN,OAAO,eAAe,EAAE,WAAW,CAAC,OAAO,eAAe,EAAE,UAAU,EAAE,OAAO,oBAAoB,EAAE,OAAO,EAAE,MAAM,CAAC,GACjI,OAAW,eAAe,EAAE,WAAW,CAAC,yBAAyB,EAAE,OAAO,WAAW,EAAE,WAAW,EAAE,MAAM,CAAC,GAC3G,OAAW,eAAe,EAAE,mBAAmB,CAAC,OAAO,eAAe,EAAE,UAAU,GAAC,yBAAyB,EAAE,MAAM,CAAC;oBAIpF,UAAU,SAA/B;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IACH,cAJY,MAAM,CAMjB;IAED;;;;;OAKG;IACH,cAJY,MAAM,CAMjB;IAED;;;OAGG;IACH,kBAFY,OAAO,qBAAqB,EAAE,KAAK,CAI9C;IAED;;;;;;OAMG;IACH,cAJY,OAAO,CAMlB;IAED;;;;;;OAMG;IACH,aAJY,MAAM,GAAC,SAAS,CAM3B;IAED;;;OAGG;IACH,2BAFW,eAAe,QAKzB;IAED;;;;;;OAMG;IACH,kBAJW,OAAO,cAAc,EAAE,MAAM,GAAC,SAAS,QAMjD;IAED;;;;;OAKG;IACH,gCAJW,MAAM,QAMhB;IAED;;;;;OAKG;IACH,gCAJW,MAAM,QAMhB;IAED;;;;;;;OAOG;IACH,oBAJW,MAAM,QAMhB;IAED;;;;;;;OAOG;IACH,oBAJW,MAAM,QAMhB;IAED;;;;;OAKG;IACH,oBAJW,MAAM,QAOhB;IAED;;;;;OAKG;IACH,oBAJW,OAAO,QAMjB;IAED;;;;;;OAMG;IACH,kBAJW,MAAM,QAMhB;CAaF;uBAhZsB,cAAc"}
package/layer/Base.js CHANGED
@@ -27,7 +27,6 @@ import LayerProperty from './Property.js';
27
27
  */
28
28
 
29
29
  /**
30
- * @template {Object<string, *>} [Properties=Object<string, *>]
31
30
  * @typedef {Object} Options
32
31
  * @property {string} [className='ol-layer'] A CSS class name to set to the layer element.
33
32
  * @property {number} [opacity=1] Opacity (0, 1).
@@ -48,7 +47,7 @@ import LayerProperty from './Property.js';
48
47
  * be visible.
49
48
  * @property {BackgroundColor} [background] Background color for the layer. If not specified, no background
50
49
  * will be rendered.
51
- * @property {Properties} [properties] Arbitrary observable properties. Can be accessed with `#get()` and `#set()`.
50
+ * @property {Object<string, *>} [properties] Arbitrary observable properties. Can be accessed with `#get()` and `#set()`.
52
51
  */
53
52
 
54
53
  /**
@@ -60,12 +59,10 @@ import LayerProperty from './Property.js';
60
59
  * is observable, and has get/set accessors.
61
60
  *
62
61
  * @api
63
- * @template {Object<string, *>} [Properties=Object<string, *>]
64
- * @extends {BaseObject<NoInfer<Properties> & Object<string, *>>}
65
62
  */
66
63
  class BaseLayer extends BaseObject {
67
64
  /**
68
- * @param {Options<NoInfer<Properties>>} options Layer options.
65
+ * @param {Options} options Layer options.
69
66
  */
70
67
  constructor(options) {
71
68
  super();
@@ -92,7 +89,7 @@ class BaseLayer extends BaseObject {
92
89
  this.background_ = options.background;
93
90
 
94
91
  /**
95
- * @type {?}
92
+ * @type {Object<string, *>}
96
93
  */
97
94
  const properties = Object.assign({}, options);
98
95
  if (typeof options.properties === 'object') {
@@ -102,9 +102,7 @@ export type Options<ImageSourceType extends import("../source/Image.js").default
102
102
  * @extends {Layer<ImageSourceType, RendererType>}
103
103
  * @api
104
104
  */
105
- declare class BaseImageLayer<ImageSourceType extends import("../source/Image.js").default, RendererType extends import("../renderer/Layer.js").default<any>> extends Layer<ImageSourceType, RendererType, {
106
- [x: string]: any;
107
- }> {
105
+ declare class BaseImageLayer<ImageSourceType extends import("../source/Image.js").default, RendererType extends import("../renderer/Layer.js").default<any>> extends Layer<ImageSourceType, RendererType> {
108
106
  /**
109
107
  * @param {Options<ImageSourceType>} [options] Layer options.
110
108
  */
@@ -1 +1 @@
1
- {"version":3,"file":"BaseImage.d.ts","sourceRoot":"","sources":["BaseImage.js"],"names":[],"mappings":";oBAMoD,eAAe,SAAtD,OAAQ,oBAAoB,EAAE,OAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AADnD;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH;;;;;;;;;;;;GAYG;AACH,6BALoD,eAAe,SAAtD,OAAQ,oBAAoB,EAAE,OAAQ,EACG,YAAY,SAArD,2CAAwC;;;IAKnD;;OAEG;IACH,sBAFW,OAAO,CAAC,eAAe,CAAC,EAKlC;CACF;kBAnDiB,YAAY"}
1
+ {"version":3,"file":"BaseImage.d.ts","sourceRoot":"","sources":["BaseImage.js"],"names":[],"mappings":";oBAMoD,eAAe,SAAtD,OAAQ,oBAAoB,EAAE,OAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AADnD;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH;;;;;;;;;;;;GAYG;AACH,6BALoD,eAAe,SAAtD,OAAQ,oBAAoB,EAAE,OAAQ,EACG,YAAY,SAArD,2CAAwC;IAKnD;;OAEG;IACH,sBAFW,OAAO,CAAC,eAAe,CAAC,EAKlC;CACF;kBAnDiB,YAAY"}
@@ -141,9 +141,7 @@ export type Options<TileSourceType extends import("../source/Tile.js").default>
141
141
  * @extends {Layer<TileSourceType, RendererType>}
142
142
  * @api
143
143
  */
144
- declare class BaseTileLayer<TileSourceType extends import("../source/Tile.js").default, RendererType extends import("../renderer/Layer.js").default<any>> extends Layer<TileSourceType, RendererType, {
145
- [x: string]: any;
146
- }> {
144
+ declare class BaseTileLayer<TileSourceType extends import("../source/Tile.js").default, RendererType extends import("../renderer/Layer.js").default<any>> extends Layer<TileSourceType, RendererType> {
147
145
  /**
148
146
  * @param {Options<TileSourceType>} [options] Tile layer options.
149
147
  */
@@ -1 +1 @@
1
- {"version":3,"file":"BaseTile.d.ts","sourceRoot":"","sources":["BaseTile.js"],"names":[],"mappings":";;;;qCAOa,MAAM,IACN,OAAO,eAAe,EAAE,WAAW,CAAC,OAAO,eAAe,EAAE,UAAU,EAAE,OAAO,oBAAoB,EAAE,OAAO,EAAE,MAAM,CAAC,GACjI,OAAW,eAAe,EAAE,WAAW,CAAC,OAAO,QAAQ,EAAE,yBAAyB,GAClF,OAAa,YAAY,EAAE,cAAc,GAAC,gBAAgB,GAAC,+BAA+B,EAAE,OAAO,WAAW,EAAE,WAAW,EAAE,MAAM,CAAC,GACpI,OAAW,eAAe,EAAE,WAAW,CAAC,OAAO,qBAAqB,EAAE,qBAAqB,EAAE,OAAO,iBAAiB,EAAE,OAAO,EAAE,MAAM,CAAC,GACvI,OAAW,eAAe,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AKG;IACH,oBAJW,MAAM,QAMhB;IAED;;;;;OAKG;IACH,6BAJY,OAAO,CAQlB;IAED;;;;;OAKG;IACH,kDAJW,OAAO,QAMjB;CAsBF;kBAhLiB,YAAY"}
@@ -122,9 +122,7 @@ export type Options<FeatureType extends import("../Feature").FeatureLike, Vector
122
122
  * @template {import("../renderer/canvas/VectorLayer.js").default|import("../renderer/canvas/VectorTileLayer.js").default|import("../renderer/canvas/VectorImageLayer.js").default|import("../renderer/webgl/VectorLayer.js").default|import("../renderer/webgl/PointsLayer.js").default} RendererType
123
123
  * @api
124
124
  */
125
- declare class BaseVectorLayer<FeatureType extends import("../Feature").FeatureLike, VectorSourceType extends import("../source/Vector.js").default<FeatureType> | import("../source/VectorTile.js").default<FeatureType>, RendererType extends import("../renderer/canvas/VectorLayer.js").default | import("../renderer/canvas/VectorTileLayer.js").default | import("../renderer/canvas/VectorImageLayer.js").default | import("../renderer/webgl/VectorLayer.js").default | import("../renderer/webgl/PointsLayer.js").default> extends Layer<VectorSourceType, RendererType, {
126
- [x: string]: any;
127
- }> {
125
+ declare class BaseVectorLayer<FeatureType extends import("../Feature").FeatureLike, VectorSourceType extends import("../source/Vector.js").default<FeatureType> | import("../source/VectorTile.js").default<FeatureType>, RendererType extends import("../renderer/canvas/VectorLayer.js").default | import("../renderer/canvas/VectorTileLayer.js").default | import("../renderer/canvas/VectorImageLayer.js").default | import("../renderer/webgl/VectorLayer.js").default | import("../renderer/webgl/PointsLayer.js").default> extends Layer<VectorSourceType, RendererType> {
128
126
  /**
129
127
  * @param {Options<FeatureType, VectorSourceType>} [options] Options.
130
128
  */