@vaadin/bundles 25.0.0-alpha3 → 25.0.0-alpha5

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 (192) hide show
  1. package/node_modules_ol_ImageCanvas_js.js +76 -83
  2. package/node_modules_ol_ImageCanvas_js.js.map +1 -1
  3. package/node_modules_ol_TileRange_js.js +128 -110
  4. package/node_modules_ol_TileRange_js.js.map +1 -1
  5. package/node_modules_ol_Tile_js.js +279 -0
  6. package/node_modules_ol_Tile_js.js.map +1 -0
  7. package/node_modules_ol_VectorRenderTile_js.js +428 -143
  8. package/node_modules_ol_VectorRenderTile_js.js.map +1 -1
  9. package/node_modules_ol_VectorTile_js.js +405 -119
  10. package/node_modules_ol_VectorTile_js.js.map +1 -1
  11. package/node_modules_ol_control_MousePosition_js.js +327 -0
  12. package/node_modules_ol_control_MousePosition_js.js.map +1 -0
  13. package/node_modules_ol_control_ZoomToExtent_js.js +118 -0
  14. package/node_modules_ol_control_ZoomToExtent_js.js.map +1 -0
  15. package/node_modules_ol_events_SnapEvent_js.js +79 -0
  16. package/node_modules_ol_events_SnapEvent_js.js.map +1 -0
  17. package/node_modules_ol_featureloader_js.js +205 -0
  18. package/node_modules_ol_featureloader_js.js.map +1 -0
  19. package/node_modules_ol_geom_Circle_js.js +300 -0
  20. package/node_modules_ol_geom_Circle_js.js.map +1 -0
  21. package/node_modules_ol_geom_GeometryCollection_js.js +369 -0
  22. package/node_modules_ol_geom_GeometryCollection_js.js.map +1 -0
  23. package/node_modules_ol_geom_MultiPoint_js.js +228 -0
  24. package/node_modules_ol_geom_MultiPoint_js.js.map +1 -0
  25. package/node_modules_ol_geom_flat_center_js.js +47 -0
  26. package/node_modules_ol_geom_flat_center_js.js.map +1 -0
  27. package/node_modules_ol_geom_flat_geodesic_js.js +123 -88
  28. package/node_modules_ol_geom_flat_geodesic_js.js.map +1 -1
  29. package/node_modules_ol_geom_flat_interpolate_js.js +230 -0
  30. package/node_modules_ol_geom_flat_interpolate_js.js.map +1 -0
  31. package/node_modules_ol_geom_flat_length_js-_375a0.js +58 -0
  32. package/node_modules_ol_geom_flat_length_js-_375a0.js.map +1 -0
  33. package/node_modules_ol_geom_flat_length_js-_375a1.js +58 -0
  34. package/node_modules_ol_geom_flat_length_js-_375a1.js.map +1 -0
  35. package/node_modules_ol_geom_flat_length_js-_375a2.js +58 -0
  36. package/node_modules_ol_geom_flat_length_js-_375a2.js.map +1 -0
  37. package/node_modules_ol_geom_flat_length_js-_375a3.js +58 -0
  38. package/node_modules_ol_geom_flat_length_js-_375a3.js.map +1 -0
  39. package/node_modules_ol_geom_flat_length_js-_375a4.js +58 -0
  40. package/node_modules_ol_geom_flat_length_js-_375a4.js.map +1 -0
  41. package/node_modules_ol_geom_flat_linechunk_js.js +76 -0
  42. package/node_modules_ol_geom_flat_linechunk_js.js.map +1 -0
  43. package/node_modules_ol_geom_flat_straightchunk_js.js +68 -0
  44. package/node_modules_ol_geom_flat_straightchunk_js.js.map +1 -0
  45. package/node_modules_ol_geom_flat_textpath_js.js +178 -0
  46. package/node_modules_ol_geom_flat_textpath_js.js.map +1 -0
  47. package/node_modules_ol_interaction_DblClickDragZoom_js.js +285 -0
  48. package/node_modules_ol_interaction_DblClickDragZoom_js.js.map +1 -0
  49. package/node_modules_ol_interaction_DragAndDrop_js.js +351 -0
  50. package/node_modules_ol_interaction_DragAndDrop_js.js.map +1 -0
  51. package/node_modules_ol_interaction_DragRotateAndZoom_js.js +159 -0
  52. package/node_modules_ol_interaction_DragRotateAndZoom_js.js.map +1 -0
  53. package/node_modules_ol_layer_Vector_js-_49290.js +110 -0
  54. package/node_modules_ol_layer_Vector_js-_49290.js.map +1 -0
  55. package/node_modules_ol_layer_Vector_js-_49291.js +110 -0
  56. package/node_modules_ol_layer_Vector_js-_49291.js.map +1 -0
  57. package/node_modules_ol_layer_Vector_js-_49292.js +110 -0
  58. package/node_modules_ol_layer_Vector_js-_49292.js.map +1 -0
  59. package/node_modules_ol_layer_Vector_js-_49293.js +110 -0
  60. package/node_modules_ol_layer_Vector_js-_49293.js.map +1 -0
  61. package/node_modules_ol_loadingstrategy_js.js +95 -0
  62. package/node_modules_ol_loadingstrategy_js.js.map +1 -0
  63. package/node_modules_ol_render_VectorContext_js-_3ad60.js +144 -0
  64. package/node_modules_ol_render_VectorContext_js-_3ad60.js.map +1 -0
  65. package/node_modules_ol_render_VectorContext_js-_3ad61.js +144 -0
  66. package/node_modules_ol_render_VectorContext_js-_3ad61.js.map +1 -0
  67. package/node_modules_ol_render_VectorContext_js-node_modules_ol_render_canvas_hitdetect_js.js +372 -0
  68. package/node_modules_ol_render_VectorContext_js-node_modules_ol_render_canvas_hitdetect_js.js.map +1 -0
  69. package/node_modules_ol_render_canvas_ImageBuilder_js.js +318 -0
  70. package/node_modules_ol_render_canvas_ImageBuilder_js.js.map +1 -0
  71. package/node_modules_ol_render_canvas_Instruction_js.js +66 -0
  72. package/node_modules_ol_render_canvas_Instruction_js.js.map +1 -0
  73. package/node_modules_ol_render_canvas_LineStringBuilder_js.js +187 -0
  74. package/node_modules_ol_render_canvas_LineStringBuilder_js.js.map +1 -0
  75. package/node_modules_ol_render_canvas_PolygonBuilder_js.js +276 -0
  76. package/node_modules_ol_render_canvas_PolygonBuilder_js.js.map +1 -0
  77. package/node_modules_ol_render_canvas_ZIndexContext_js-_fab20.js +156 -0
  78. package/node_modules_ol_render_canvas_ZIndexContext_js-_fab20.js.map +1 -0
  79. package/node_modules_ol_render_canvas_ZIndexContext_js-_fab21.js +156 -0
  80. package/node_modules_ol_render_canvas_ZIndexContext_js-_fab21.js.map +1 -0
  81. package/node_modules_ol_render_js-node_modules_ol_render_VectorContext_js.js +301 -0
  82. package/node_modules_ol_render_js-node_modules_ol_render_VectorContext_js.js.map +1 -0
  83. package/node_modules_ol_renderer_Layer_js.js +219 -0
  84. package/node_modules_ol_renderer_Layer_js.js.map +1 -0
  85. package/node_modules_ol_source_Source_js.js +256 -0
  86. package/node_modules_ol_source_Source_js.js.map +1 -0
  87. package/node_modules_ol_source_VectorEventType_js-node_modules_ol_structs_RBush_js.js +318 -0
  88. package/node_modules_ol_source_VectorEventType_js-node_modules_ol_structs_RBush_js.js.map +1 -0
  89. package/node_modules_ol_source_VectorEventType_js.js +80 -0
  90. package/node_modules_ol_source_VectorEventType_js.js.map +1 -0
  91. package/node_modules_ol_structs_RBush_js.js +242 -0
  92. package/node_modules_ol_structs_RBush_js.js.map +1 -0
  93. package/node_modules_ol_style_js.js +2 -1
  94. package/node_modules_ol_style_js.js.map +1 -1
  95. package/node_modules_rbush_rbush_min_js.js +16 -0
  96. package/node_modules_rbush_rbush_min_js.js.map +1 -0
  97. package/package.json +142 -146
  98. package/vaadin-bundle.json +2447 -2352
  99. package/vaadin.js +52246 -63791
  100. package/vaadin.js.map +1 -1
  101. package/vendors-node_modules_dompurify_dist_purify_es_mjs.js +1364 -0
  102. package/vendors-node_modules_dompurify_dist_purify_es_mjs.js.map +1 -0
  103. package/vendors-node_modules_dompurify_dist_purify_js.js +26 -21
  104. package/vendors-node_modules_dompurify_dist_purify_js.js.map +1 -1
  105. package/vendors-node_modules_marked_lib_marked_esm_js.js +2205 -0
  106. package/vendors-node_modules_marked_lib_marked_esm_js.js.map +1 -0
  107. package/vendors-node_modules_marked_lib_marked_umd_js.js +2164 -2556
  108. package/vendors-node_modules_marked_lib_marked_umd_js.js.map +1 -1
  109. package/vendors-node_modules_ol_Feature_js.js +360 -0
  110. package/vendors-node_modules_ol_Feature_js.js.map +1 -0
  111. package/vendors-node_modules_ol_Geolocation_js.js +352 -293
  112. package/vendors-node_modules_ol_Geolocation_js.js.map +1 -1
  113. package/vendors-node_modules_ol_ImageTile_js.js +494 -0
  114. package/vendors-node_modules_ol_ImageTile_js.js.map +1 -0
  115. package/vendors-node_modules_ol_Overlay_js.js +606 -0
  116. package/vendors-node_modules_ol_Overlay_js.js.map +1 -0
  117. package/vendors-node_modules_ol_control_FullScreen_js.js +417 -0
  118. package/vendors-node_modules_ol_control_FullScreen_js.js.map +1 -0
  119. package/vendors-node_modules_ol_control_OverviewMap_js.js +711 -0
  120. package/vendors-node_modules_ol_control_OverviewMap_js.js.map +1 -0
  121. package/vendors-node_modules_ol_control_ScaleLine_js.js +509 -0
  122. package/vendors-node_modules_ol_control_ScaleLine_js.js.map +1 -0
  123. package/vendors-node_modules_ol_control_ZoomSlider_js.js +418 -0
  124. package/vendors-node_modules_ol_control_ZoomSlider_js.js.map +1 -0
  125. package/vendors-node_modules_ol_control_js.js +490 -0
  126. package/vendors-node_modules_ol_control_js.js.map +1 -0
  127. package/vendors-node_modules_ol_geom_LineString_js.js +574 -0
  128. package/vendors-node_modules_ol_geom_LineString_js.js.map +1 -0
  129. package/vendors-node_modules_ol_geom_MultiLineString_js.js +405 -0
  130. package/vendors-node_modules_ol_geom_MultiLineString_js.js.map +1 -0
  131. package/vendors-node_modules_ol_geom_MultiPolygon_js.js +773 -0
  132. package/vendors-node_modules_ol_geom_MultiPolygon_js.js.map +1 -0
  133. package/vendors-node_modules_ol_geom_js-node_modules_ol_geom_flat_length_js.js +769 -0
  134. package/vendors-node_modules_ol_geom_js-node_modules_ol_geom_flat_length_js.js.map +1 -0
  135. package/vendors-node_modules_ol_index_js.js +526 -675
  136. package/vendors-node_modules_ol_index_js.js.map +1 -1
  137. package/vendors-node_modules_ol_interaction_Draw_js.js +2777 -0
  138. package/vendors-node_modules_ol_interaction_Draw_js.js.map +1 -0
  139. package/vendors-node_modules_ol_interaction_Extent_js.js +586 -0
  140. package/vendors-node_modules_ol_interaction_Extent_js.js.map +1 -0
  141. package/vendors-node_modules_ol_interaction_Link_js.js +489 -0
  142. package/vendors-node_modules_ol_interaction_Link_js.js.map +1 -0
  143. package/vendors-node_modules_ol_interaction_Modify_js.js +1841 -0
  144. package/vendors-node_modules_ol_interaction_Modify_js.js.map +1 -0
  145. package/vendors-node_modules_ol_interaction_Select_js.js +623 -0
  146. package/vendors-node_modules_ol_interaction_Select_js.js.map +1 -0
  147. package/vendors-node_modules_ol_interaction_Snap_js.js +982 -0
  148. package/vendors-node_modules_ol_interaction_Snap_js.js.map +1 -0
  149. package/vendors-node_modules_ol_interaction_Translate_js.js +466 -0
  150. package/vendors-node_modules_ol_interaction_Translate_js.js.map +1 -0
  151. package/vendors-node_modules_ol_interaction_js.js +872 -0
  152. package/vendors-node_modules_ol_interaction_js.js.map +1 -0
  153. package/vendors-node_modules_ol_layer_Graticule_js.js +1374 -989
  154. package/vendors-node_modules_ol_layer_Graticule_js.js.map +1 -1
  155. package/vendors-node_modules_ol_render_Feature_js.js +546 -0
  156. package/vendors-node_modules_ol_render_Feature_js.js.map +1 -0
  157. package/vendors-node_modules_ol_render_canvas_BuilderGroup_js.js +897 -0
  158. package/vendors-node_modules_ol_render_canvas_BuilderGroup_js.js.map +1 -0
  159. package/vendors-node_modules_ol_render_canvas_Builder_js.js +907 -0
  160. package/vendors-node_modules_ol_render_canvas_Builder_js.js.map +1 -0
  161. package/vendors-node_modules_ol_render_canvas_ExecutorGroup_js.js +539 -0
  162. package/vendors-node_modules_ol_render_canvas_ExecutorGroup_js.js.map +1 -0
  163. package/vendors-node_modules_ol_render_canvas_Executor_js.js +1715 -0
  164. package/vendors-node_modules_ol_render_canvas_Executor_js.js.map +1 -0
  165. package/vendors-node_modules_ol_render_canvas_Immediate_js.js +1208 -0
  166. package/vendors-node_modules_ol_render_canvas_Immediate_js.js.map +1 -0
  167. package/vendors-node_modules_ol_render_canvas_TextBuilder_js.js +825 -0
  168. package/vendors-node_modules_ol_render_canvas_TextBuilder_js.js.map +1 -0
  169. package/vendors-node_modules_ol_renderer_canvas_Layer_js.js +654 -0
  170. package/vendors-node_modules_ol_renderer_canvas_Layer_js.js.map +1 -0
  171. package/vendors-node_modules_ol_renderer_canvas_VectorLayer_js.js +1044 -0
  172. package/vendors-node_modules_ol_renderer_canvas_VectorLayer_js.js.map +1 -0
  173. package/vendors-node_modules_ol_renderer_vector_js.js +460 -0
  174. package/vendors-node_modules_ol_renderer_vector_js.js.map +1 -0
  175. package/vendors-node_modules_ol_source_Vector_js.js +2091 -0
  176. package/vendors-node_modules_ol_source_Vector_js.js.map +1 -0
  177. package/node_modules_ol_ImageTile_js.js +0 -177
  178. package/node_modules_ol_ImageTile_js.js.map +0 -1
  179. package/node_modules_ol_render_js.js +0 -131
  180. package/node_modules_ol_render_js.js.map +0 -1
  181. package/node_modules_ol_structs_LRUCache_js.js +0 -275
  182. package/node_modules_ol_structs_LRUCache_js.js.map +0 -1
  183. package/node_modules_ol_tilecoord_js.js +0 -115
  184. package/node_modules_ol_tilecoord_js.js.map +0 -1
  185. package/vendors-node_modules_ol_TileCache_js.js +0 -461
  186. package/vendors-node_modules_ol_TileCache_js.js.map +0 -1
  187. package/vendors-node_modules_ol_Tile_js.js +0 -330
  188. package/vendors-node_modules_ol_Tile_js.js.map +0 -1
  189. package/vendors-node_modules_ol_style_Text_js.js +0 -509
  190. package/vendors-node_modules_ol_style_Text_js.js.map +0 -1
  191. package/vendors-node_modules_rbush_index_js.js +0 -531
  192. package/vendors-node_modules_rbush_index_js.js.map +0 -1
@@ -0,0 +1,318 @@
1
+ (self["webpackChunk_vaadin_bundles"] = self["webpackChunk_vaadin_bundles"] || []).push([["node_modules_ol_render_canvas_ImageBuilder_js"],{
2
+
3
+ /***/ "./node_modules/ol/render/canvas/ImageBuilder.js":
4
+ /*!*******************************************************!*\
5
+ !*** ./node_modules/ol/render/canvas/ImageBuilder.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 _extent_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../extent.js */ "./node_modules/ol/extent.js");
14
+ /* harmony import */ var _Builder_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Builder.js */ "./node_modules/ol/render/canvas/Builder.js");
15
+ /* harmony import */ var _Instruction_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Instruction.js */ "./node_modules/ol/render/canvas/Instruction.js");
16
+ /**
17
+ * @module ol/render/canvas/ImageBuilder
18
+ */
19
+
20
+
21
+
22
+
23
+ class CanvasImageBuilder extends _Builder_js__WEBPACK_IMPORTED_MODULE_0__["default"] {
24
+ /**
25
+ * @param {number} tolerance Tolerance.
26
+ * @param {import("../../extent.js").Extent} maxExtent Maximum extent.
27
+ * @param {number} resolution Resolution.
28
+ * @param {number} pixelRatio Pixel ratio.
29
+ */
30
+ constructor(tolerance, maxExtent, resolution, pixelRatio) {
31
+ super(tolerance, maxExtent, resolution, pixelRatio);
32
+
33
+ /**
34
+ * @private
35
+ * @type {import('../../DataTile.js').ImageLike}
36
+ */
37
+ this.hitDetectionImage_ = null;
38
+
39
+ /**
40
+ * @private
41
+ * @type {import('../../DataTile.js').ImageLike}
42
+ */
43
+ this.image_ = null;
44
+
45
+ /**
46
+ * @private
47
+ * @type {number|undefined}
48
+ */
49
+ this.imagePixelRatio_ = undefined;
50
+
51
+ /**
52
+ * @private
53
+ * @type {number|undefined}
54
+ */
55
+ this.anchorX_ = undefined;
56
+
57
+ /**
58
+ * @private
59
+ * @type {number|undefined}
60
+ */
61
+ this.anchorY_ = undefined;
62
+
63
+ /**
64
+ * @private
65
+ * @type {number|undefined}
66
+ */
67
+ this.height_ = undefined;
68
+
69
+ /**
70
+ * @private
71
+ * @type {number|undefined}
72
+ */
73
+ this.opacity_ = undefined;
74
+
75
+ /**
76
+ * @private
77
+ * @type {number|undefined}
78
+ */
79
+ this.originX_ = undefined;
80
+
81
+ /**
82
+ * @private
83
+ * @type {number|undefined}
84
+ */
85
+ this.originY_ = undefined;
86
+
87
+ /**
88
+ * @private
89
+ * @type {boolean|undefined}
90
+ */
91
+ this.rotateWithView_ = undefined;
92
+
93
+ /**
94
+ * @private
95
+ * @type {number|undefined}
96
+ */
97
+ this.rotation_ = undefined;
98
+
99
+ /**
100
+ * @private
101
+ * @type {import("../../size.js").Size|undefined}
102
+ */
103
+ this.scale_ = undefined;
104
+
105
+ /**
106
+ * @private
107
+ * @type {number|undefined}
108
+ */
109
+ this.width_ = undefined;
110
+
111
+ /**
112
+ * @private
113
+ * @type {import('../../style/Style.js').DeclutterMode}
114
+ */
115
+ this.declutterMode_ = undefined;
116
+
117
+ /**
118
+ * Data shared with a text builder for combined decluttering.
119
+ * @private
120
+ * @type {import("../canvas.js").DeclutterImageWithText}
121
+ */
122
+ this.declutterImageWithText_ = undefined;
123
+ }
124
+
125
+ /**
126
+ * @param {import("../../geom/Point.js").default|import("../Feature.js").default} pointGeometry Point geometry.
127
+ * @param {import("../../Feature.js").FeatureLike} feature Feature.
128
+ * @param {number} [index] Render order index.
129
+ * @override
130
+ */
131
+ drawPoint(pointGeometry, feature, index) {
132
+ if (
133
+ !this.image_ ||
134
+ (this.maxExtent &&
135
+ !(0,_extent_js__WEBPACK_IMPORTED_MODULE_1__.containsCoordinate)(this.maxExtent, pointGeometry.getFlatCoordinates()))
136
+ ) {
137
+ return;
138
+ }
139
+ this.beginGeometry(pointGeometry, feature, index);
140
+ const flatCoordinates = pointGeometry.getFlatCoordinates();
141
+ const stride = pointGeometry.getStride();
142
+ const myBegin = this.coordinates.length;
143
+ const myEnd = this.appendFlatPointCoordinates(flatCoordinates, stride);
144
+ this.instructions.push([
145
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_2__["default"].DRAW_IMAGE,
146
+ myBegin,
147
+ myEnd,
148
+ this.image_,
149
+ // Remaining arguments to DRAW_IMAGE are in alphabetical order
150
+ this.anchorX_ * this.imagePixelRatio_,
151
+ this.anchorY_ * this.imagePixelRatio_,
152
+ Math.ceil(this.height_ * this.imagePixelRatio_),
153
+ this.opacity_,
154
+ this.originX_ * this.imagePixelRatio_,
155
+ this.originY_ * this.imagePixelRatio_,
156
+ this.rotateWithView_,
157
+ this.rotation_,
158
+ [
159
+ (this.scale_[0] * this.pixelRatio) / this.imagePixelRatio_,
160
+ (this.scale_[1] * this.pixelRatio) / this.imagePixelRatio_,
161
+ ],
162
+ Math.ceil(this.width_ * this.imagePixelRatio_),
163
+ this.declutterMode_,
164
+ this.declutterImageWithText_,
165
+ ]);
166
+ this.hitDetectionInstructions.push([
167
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_2__["default"].DRAW_IMAGE,
168
+ myBegin,
169
+ myEnd,
170
+ this.hitDetectionImage_,
171
+ // Remaining arguments to DRAW_IMAGE are in alphabetical order
172
+ this.anchorX_,
173
+ this.anchorY_,
174
+ this.height_,
175
+ 1,
176
+ this.originX_,
177
+ this.originY_,
178
+ this.rotateWithView_,
179
+ this.rotation_,
180
+ this.scale_,
181
+ this.width_,
182
+ this.declutterMode_,
183
+ this.declutterImageWithText_,
184
+ ]);
185
+ this.endGeometry(feature);
186
+ }
187
+
188
+ /**
189
+ * @param {import("../../geom/MultiPoint.js").default|import("../Feature.js").default} multiPointGeometry MultiPoint geometry.
190
+ * @param {import("../../Feature.js").FeatureLike} feature Feature.
191
+ * @param {number} [index] Render order index.
192
+ * @override
193
+ */
194
+ drawMultiPoint(multiPointGeometry, feature, index) {
195
+ if (!this.image_) {
196
+ return;
197
+ }
198
+ this.beginGeometry(multiPointGeometry, feature, index);
199
+ const flatCoordinates = multiPointGeometry.getFlatCoordinates();
200
+ const filteredFlatCoordinates = [];
201
+ for (
202
+ let i = 0, ii = flatCoordinates.length;
203
+ i < ii;
204
+ i += multiPointGeometry.getStride()
205
+ ) {
206
+ if (
207
+ !this.maxExtent ||
208
+ (0,_extent_js__WEBPACK_IMPORTED_MODULE_1__.containsCoordinate)(this.maxExtent, flatCoordinates.slice(i, i + 2))
209
+ ) {
210
+ filteredFlatCoordinates.push(
211
+ flatCoordinates[i],
212
+ flatCoordinates[i + 1],
213
+ );
214
+ }
215
+ }
216
+ const myBegin = this.coordinates.length;
217
+ const myEnd = this.appendFlatPointCoordinates(filteredFlatCoordinates, 2);
218
+ this.instructions.push([
219
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_2__["default"].DRAW_IMAGE,
220
+ myBegin,
221
+ myEnd,
222
+ this.image_,
223
+ // Remaining arguments to DRAW_IMAGE are in alphabetical order
224
+ this.anchorX_ * this.imagePixelRatio_,
225
+ this.anchorY_ * this.imagePixelRatio_,
226
+ Math.ceil(this.height_ * this.imagePixelRatio_),
227
+ this.opacity_,
228
+ this.originX_ * this.imagePixelRatio_,
229
+ this.originY_ * this.imagePixelRatio_,
230
+ this.rotateWithView_,
231
+ this.rotation_,
232
+ [
233
+ (this.scale_[0] * this.pixelRatio) / this.imagePixelRatio_,
234
+ (this.scale_[1] * this.pixelRatio) / this.imagePixelRatio_,
235
+ ],
236
+ Math.ceil(this.width_ * this.imagePixelRatio_),
237
+ this.declutterMode_,
238
+ this.declutterImageWithText_,
239
+ ]);
240
+ this.hitDetectionInstructions.push([
241
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_2__["default"].DRAW_IMAGE,
242
+ myBegin,
243
+ myEnd,
244
+ this.hitDetectionImage_,
245
+ // Remaining arguments to DRAW_IMAGE are in alphabetical order
246
+ this.anchorX_,
247
+ this.anchorY_,
248
+ this.height_,
249
+ 1,
250
+ this.originX_,
251
+ this.originY_,
252
+ this.rotateWithView_,
253
+ this.rotation_,
254
+ this.scale_,
255
+ this.width_,
256
+ this.declutterMode_,
257
+ this.declutterImageWithText_,
258
+ ]);
259
+ this.endGeometry(feature);
260
+ }
261
+
262
+ /**
263
+ * @return {import("../canvas.js").SerializableInstructions} the serializable instructions.
264
+ * @override
265
+ */
266
+ finish() {
267
+ this.reverseHitDetectionInstructions();
268
+ // FIXME this doesn't really protect us against further calls to draw*Geometry
269
+ this.anchorX_ = undefined;
270
+ this.anchorY_ = undefined;
271
+ this.hitDetectionImage_ = null;
272
+ this.image_ = null;
273
+ this.imagePixelRatio_ = undefined;
274
+ this.height_ = undefined;
275
+ this.scale_ = undefined;
276
+ this.opacity_ = undefined;
277
+ this.originX_ = undefined;
278
+ this.originY_ = undefined;
279
+ this.rotateWithView_ = undefined;
280
+ this.rotation_ = undefined;
281
+ this.width_ = undefined;
282
+ return super.finish();
283
+ }
284
+
285
+ /**
286
+ * @param {import("../../style/Image.js").default} imageStyle Image style.
287
+ * @param {Object} [sharedData] Shared data.
288
+ * @override
289
+ */
290
+ setImageStyle(imageStyle, sharedData) {
291
+ const anchor = imageStyle.getAnchor();
292
+ const size = imageStyle.getSize();
293
+ const origin = imageStyle.getOrigin();
294
+ this.imagePixelRatio_ = imageStyle.getPixelRatio(this.pixelRatio);
295
+ this.anchorX_ = anchor[0];
296
+ this.anchorY_ = anchor[1];
297
+ this.hitDetectionImage_ = imageStyle.getHitDetectionImage();
298
+ this.image_ = imageStyle.getImage(this.pixelRatio);
299
+ this.height_ = size[1];
300
+ this.opacity_ = imageStyle.getOpacity();
301
+ this.originX_ = origin[0];
302
+ this.originY_ = origin[1];
303
+ this.rotateWithView_ = imageStyle.getRotateWithView();
304
+ this.rotation_ = imageStyle.getRotation();
305
+ this.scale_ = imageStyle.getScaleArray();
306
+ this.width_ = size[0];
307
+ this.declutterMode_ = imageStyle.getDeclutterMode();
308
+ this.declutterImageWithText_ = sharedData;
309
+ }
310
+ }
311
+
312
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (CanvasImageBuilder);
313
+
314
+
315
+ /***/ })
316
+
317
+ }])
318
+ //# sourceMappingURL=node_modules_ol_render_canvas_ImageBuilder_js.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"node_modules_ol_render_canvas_ImageBuilder_js.js","mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACmD;AACV;AACQ;;AAEjD,iCAAiC,mDAAa;AAC9C;AACA,aAAa,QAAQ;AACrB,aAAa,kCAAkC;AAC/C,aAAa,QAAQ;AACrB,aAAa,QAAQ;AACrB;AACA;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA,cAAc;AACd;AACA;;AAEA;AACA;AACA;AACA,cAAc;AACd;AACA;AACA;;AAEA;AACA,aAAa,uEAAuE;AACpF,aAAa,wCAAwC;AACrD,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,8DAAkB;AAC3B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,kEAA4B;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,kEAA4B;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,aAAa,4EAA4E;AACzF,aAAa,wCAAwC;AACrD,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ,8DAAkB;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,kEAA4B;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,kEAA4B;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,cAAc,iDAAiD;AAC/D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,aAAa,wCAAwC;AACrD,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,iEAAe,kBAAkB,EAAC","sources":["webpack://@vaadin/bundles/./node_modules/ol/render/canvas/ImageBuilder.js"],"sourcesContent":["/**\n * @module ol/render/canvas/ImageBuilder\n */\nimport {containsCoordinate} from '../../extent.js';\nimport CanvasBuilder from './Builder.js';\nimport CanvasInstruction from './Instruction.js';\n\nclass CanvasImageBuilder extends CanvasBuilder {\n /**\n * @param {number} tolerance Tolerance.\n * @param {import(\"../../extent.js\").Extent} maxExtent Maximum extent.\n * @param {number} resolution Resolution.\n * @param {number} pixelRatio Pixel ratio.\n */\n constructor(tolerance, maxExtent, resolution, pixelRatio) {\n super(tolerance, maxExtent, resolution, pixelRatio);\n\n /**\n * @private\n * @type {import('../../DataTile.js').ImageLike}\n */\n this.hitDetectionImage_ = null;\n\n /**\n * @private\n * @type {import('../../DataTile.js').ImageLike}\n */\n this.image_ = null;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.imagePixelRatio_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.anchorX_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.anchorY_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.height_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.opacity_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.originX_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.originY_ = undefined;\n\n /**\n * @private\n * @type {boolean|undefined}\n */\n this.rotateWithView_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.rotation_ = undefined;\n\n /**\n * @private\n * @type {import(\"../../size.js\").Size|undefined}\n */\n this.scale_ = undefined;\n\n /**\n * @private\n * @type {number|undefined}\n */\n this.width_ = undefined;\n\n /**\n * @private\n * @type {import('../../style/Style.js').DeclutterMode}\n */\n this.declutterMode_ = undefined;\n\n /**\n * Data shared with a text builder for combined decluttering.\n * @private\n * @type {import(\"../canvas.js\").DeclutterImageWithText}\n */\n this.declutterImageWithText_ = undefined;\n }\n\n /**\n * @param {import(\"../../geom/Point.js\").default|import(\"../Feature.js\").default} pointGeometry Point geometry.\n * @param {import(\"../../Feature.js\").FeatureLike} feature Feature.\n * @param {number} [index] Render order index.\n * @override\n */\n drawPoint(pointGeometry, feature, index) {\n if (\n !this.image_ ||\n (this.maxExtent &&\n !containsCoordinate(this.maxExtent, pointGeometry.getFlatCoordinates()))\n ) {\n return;\n }\n this.beginGeometry(pointGeometry, feature, index);\n const flatCoordinates = pointGeometry.getFlatCoordinates();\n const stride = pointGeometry.getStride();\n const myBegin = this.coordinates.length;\n const myEnd = this.appendFlatPointCoordinates(flatCoordinates, stride);\n this.instructions.push([\n CanvasInstruction.DRAW_IMAGE,\n myBegin,\n myEnd,\n this.image_,\n // Remaining arguments to DRAW_IMAGE are in alphabetical order\n this.anchorX_ * this.imagePixelRatio_,\n this.anchorY_ * this.imagePixelRatio_,\n Math.ceil(this.height_ * this.imagePixelRatio_),\n this.opacity_,\n this.originX_ * this.imagePixelRatio_,\n this.originY_ * this.imagePixelRatio_,\n this.rotateWithView_,\n this.rotation_,\n [\n (this.scale_[0] * this.pixelRatio) / this.imagePixelRatio_,\n (this.scale_[1] * this.pixelRatio) / this.imagePixelRatio_,\n ],\n Math.ceil(this.width_ * this.imagePixelRatio_),\n this.declutterMode_,\n this.declutterImageWithText_,\n ]);\n this.hitDetectionInstructions.push([\n CanvasInstruction.DRAW_IMAGE,\n myBegin,\n myEnd,\n this.hitDetectionImage_,\n // Remaining arguments to DRAW_IMAGE are in alphabetical order\n this.anchorX_,\n this.anchorY_,\n this.height_,\n 1,\n this.originX_,\n this.originY_,\n this.rotateWithView_,\n this.rotation_,\n this.scale_,\n this.width_,\n this.declutterMode_,\n this.declutterImageWithText_,\n ]);\n this.endGeometry(feature);\n }\n\n /**\n * @param {import(\"../../geom/MultiPoint.js\").default|import(\"../Feature.js\").default} multiPointGeometry MultiPoint geometry.\n * @param {import(\"../../Feature.js\").FeatureLike} feature Feature.\n * @param {number} [index] Render order index.\n * @override\n */\n drawMultiPoint(multiPointGeometry, feature, index) {\n if (!this.image_) {\n return;\n }\n this.beginGeometry(multiPointGeometry, feature, index);\n const flatCoordinates = multiPointGeometry.getFlatCoordinates();\n const filteredFlatCoordinates = [];\n for (\n let i = 0, ii = flatCoordinates.length;\n i < ii;\n i += multiPointGeometry.getStride()\n ) {\n if (\n !this.maxExtent ||\n containsCoordinate(this.maxExtent, flatCoordinates.slice(i, i + 2))\n ) {\n filteredFlatCoordinates.push(\n flatCoordinates[i],\n flatCoordinates[i + 1],\n );\n }\n }\n const myBegin = this.coordinates.length;\n const myEnd = this.appendFlatPointCoordinates(filteredFlatCoordinates, 2);\n this.instructions.push([\n CanvasInstruction.DRAW_IMAGE,\n myBegin,\n myEnd,\n this.image_,\n // Remaining arguments to DRAW_IMAGE are in alphabetical order\n this.anchorX_ * this.imagePixelRatio_,\n this.anchorY_ * this.imagePixelRatio_,\n Math.ceil(this.height_ * this.imagePixelRatio_),\n this.opacity_,\n this.originX_ * this.imagePixelRatio_,\n this.originY_ * this.imagePixelRatio_,\n this.rotateWithView_,\n this.rotation_,\n [\n (this.scale_[0] * this.pixelRatio) / this.imagePixelRatio_,\n (this.scale_[1] * this.pixelRatio) / this.imagePixelRatio_,\n ],\n Math.ceil(this.width_ * this.imagePixelRatio_),\n this.declutterMode_,\n this.declutterImageWithText_,\n ]);\n this.hitDetectionInstructions.push([\n CanvasInstruction.DRAW_IMAGE,\n myBegin,\n myEnd,\n this.hitDetectionImage_,\n // Remaining arguments to DRAW_IMAGE are in alphabetical order\n this.anchorX_,\n this.anchorY_,\n this.height_,\n 1,\n this.originX_,\n this.originY_,\n this.rotateWithView_,\n this.rotation_,\n this.scale_,\n this.width_,\n this.declutterMode_,\n this.declutterImageWithText_,\n ]);\n this.endGeometry(feature);\n }\n\n /**\n * @return {import(\"../canvas.js\").SerializableInstructions} the serializable instructions.\n * @override\n */\n finish() {\n this.reverseHitDetectionInstructions();\n // FIXME this doesn't really protect us against further calls to draw*Geometry\n this.anchorX_ = undefined;\n this.anchorY_ = undefined;\n this.hitDetectionImage_ = null;\n this.image_ = null;\n this.imagePixelRatio_ = undefined;\n this.height_ = undefined;\n this.scale_ = undefined;\n this.opacity_ = undefined;\n this.originX_ = undefined;\n this.originY_ = undefined;\n this.rotateWithView_ = undefined;\n this.rotation_ = undefined;\n this.width_ = undefined;\n return super.finish();\n }\n\n /**\n * @param {import(\"../../style/Image.js\").default} imageStyle Image style.\n * @param {Object} [sharedData] Shared data.\n * @override\n */\n setImageStyle(imageStyle, sharedData) {\n const anchor = imageStyle.getAnchor();\n const size = imageStyle.getSize();\n const origin = imageStyle.getOrigin();\n this.imagePixelRatio_ = imageStyle.getPixelRatio(this.pixelRatio);\n this.anchorX_ = anchor[0];\n this.anchorY_ = anchor[1];\n this.hitDetectionImage_ = imageStyle.getHitDetectionImage();\n this.image_ = imageStyle.getImage(this.pixelRatio);\n this.height_ = size[1];\n this.opacity_ = imageStyle.getOpacity();\n this.originX_ = origin[0];\n this.originY_ = origin[1];\n this.rotateWithView_ = imageStyle.getRotateWithView();\n this.rotation_ = imageStyle.getRotation();\n this.scale_ = imageStyle.getScaleArray();\n this.width_ = size[0];\n this.declutterMode_ = imageStyle.getDeclutterMode();\n this.declutterImageWithText_ = sharedData;\n }\n}\n\nexport default CanvasImageBuilder;\n"],"names":[],"sourceRoot":""}
@@ -0,0 +1,66 @@
1
+ (self["webpackChunk_vaadin_bundles"] = self["webpackChunk_vaadin_bundles"] || []).push([["node_modules_ol_render_canvas_Instruction_js"],{
2
+
3
+ /***/ "./node_modules/ol/render/canvas/Instruction.js":
4
+ /*!******************************************************!*\
5
+ !*** ./node_modules/ol/render/canvas/Instruction.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 */ "beginPathInstruction": () => (/* binding */ beginPathInstruction),
12
+ /* harmony export */ "closePathInstruction": () => (/* binding */ closePathInstruction),
13
+ /* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__),
14
+ /* harmony export */ "fillInstruction": () => (/* binding */ fillInstruction),
15
+ /* harmony export */ "strokeInstruction": () => (/* binding */ strokeInstruction)
16
+ /* harmony export */ });
17
+ /**
18
+ * @module ol/render/canvas/Instruction
19
+ */
20
+
21
+ /**
22
+ * @enum {number}
23
+ */
24
+ const Instruction = {
25
+ BEGIN_GEOMETRY: 0,
26
+ BEGIN_PATH: 1,
27
+ CIRCLE: 2,
28
+ CLOSE_PATH: 3,
29
+ CUSTOM: 4,
30
+ DRAW_CHARS: 5,
31
+ DRAW_IMAGE: 6,
32
+ END_GEOMETRY: 7,
33
+ FILL: 8,
34
+ MOVE_TO_LINE_TO: 9,
35
+ SET_FILL_STYLE: 10,
36
+ SET_STROKE_STYLE: 11,
37
+ STROKE: 12,
38
+ };
39
+
40
+ /**
41
+ * @type {Array<Instruction>}
42
+ */
43
+ const fillInstruction = [Instruction.FILL];
44
+
45
+ /**
46
+ * @type {Array<Instruction>}
47
+ */
48
+ const strokeInstruction = [Instruction.STROKE];
49
+
50
+ /**
51
+ * @type {Array<Instruction>}
52
+ */
53
+ const beginPathInstruction = [Instruction.BEGIN_PATH];
54
+
55
+ /**
56
+ * @type {Array<Instruction>}
57
+ */
58
+ const closePathInstruction = [Instruction.CLOSE_PATH];
59
+
60
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Instruction);
61
+
62
+
63
+ /***/ })
64
+
65
+ }])
66
+ //# sourceMappingURL=node_modules_ol_render_canvas_Instruction_js.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"node_modules_ol_render_canvas_Instruction_js.js","mappings":";;;;;;;;;;;;;;;;AAAA;AACA;AACA;;AAEA;AACA,UAAU;AACV;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,UAAU;AACV;AACO;;AAEP;AACA,UAAU;AACV;AACO;;AAEP;AACA,UAAU;AACV;AACO;;AAEP;AACA,UAAU;AACV;AACO;;AAEP,iEAAe,WAAW,EAAC","sources":["webpack://@vaadin/bundles/./node_modules/ol/render/canvas/Instruction.js"],"sourcesContent":["/**\n * @module ol/render/canvas/Instruction\n */\n\n/**\n * @enum {number}\n */\nconst Instruction = {\n BEGIN_GEOMETRY: 0,\n BEGIN_PATH: 1,\n CIRCLE: 2,\n CLOSE_PATH: 3,\n CUSTOM: 4,\n DRAW_CHARS: 5,\n DRAW_IMAGE: 6,\n END_GEOMETRY: 7,\n FILL: 8,\n MOVE_TO_LINE_TO: 9,\n SET_FILL_STYLE: 10,\n SET_STROKE_STYLE: 11,\n STROKE: 12,\n};\n\n/**\n * @type {Array<Instruction>}\n */\nexport const fillInstruction = [Instruction.FILL];\n\n/**\n * @type {Array<Instruction>}\n */\nexport const strokeInstruction = [Instruction.STROKE];\n\n/**\n * @type {Array<Instruction>}\n */\nexport const beginPathInstruction = [Instruction.BEGIN_PATH];\n\n/**\n * @type {Array<Instruction>}\n */\nexport const closePathInstruction = [Instruction.CLOSE_PATH];\n\nexport default Instruction;\n"],"names":[],"sourceRoot":""}
@@ -0,0 +1,187 @@
1
+ (self["webpackChunk_vaadin_bundles"] = self["webpackChunk_vaadin_bundles"] || []).push([["node_modules_ol_render_canvas_LineStringBuilder_js"],{
2
+
3
+ /***/ "./node_modules/ol/render/canvas/LineStringBuilder.js":
4
+ /*!************************************************************!*\
5
+ !*** ./node_modules/ol/render/canvas/LineStringBuilder.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 _canvas_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../canvas.js */ "./node_modules/ol/render/canvas.js");
14
+ /* harmony import */ var _Builder_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Builder.js */ "./node_modules/ol/render/canvas/Builder.js");
15
+ /* harmony import */ var _Instruction_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Instruction.js */ "./node_modules/ol/render/canvas/Instruction.js");
16
+ /**
17
+ * @module ol/render/canvas/LineStringBuilder
18
+ */
19
+
20
+
21
+
22
+
23
+ class CanvasLineStringBuilder extends _Builder_js__WEBPACK_IMPORTED_MODULE_0__["default"] {
24
+ /**
25
+ * @param {number} tolerance Tolerance.
26
+ * @param {import("../../extent.js").Extent} maxExtent Maximum extent.
27
+ * @param {number} resolution Resolution.
28
+ * @param {number} pixelRatio Pixel ratio.
29
+ */
30
+ constructor(tolerance, maxExtent, resolution, pixelRatio) {
31
+ super(tolerance, maxExtent, resolution, pixelRatio);
32
+ }
33
+
34
+ /**
35
+ * @param {Array<number>} flatCoordinates Flat coordinates.
36
+ * @param {number} offset Offset.
37
+ * @param {number} end End.
38
+ * @param {number} stride Stride.
39
+ * @private
40
+ * @return {number} end.
41
+ */
42
+ drawFlatCoordinates_(flatCoordinates, offset, end, stride) {
43
+ const myBegin = this.coordinates.length;
44
+ const myEnd = this.appendFlatLineCoordinates(
45
+ flatCoordinates,
46
+ offset,
47
+ end,
48
+ stride,
49
+ false,
50
+ false,
51
+ );
52
+ const moveToLineToInstruction = [
53
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_1__["default"].MOVE_TO_LINE_TO,
54
+ myBegin,
55
+ myEnd,
56
+ ];
57
+ this.instructions.push(moveToLineToInstruction);
58
+ this.hitDetectionInstructions.push(moveToLineToInstruction);
59
+ return end;
60
+ }
61
+
62
+ /**
63
+ * @param {import("../../geom/LineString.js").default|import("../Feature.js").default} lineStringGeometry Line string geometry.
64
+ * @param {import("../../Feature.js").FeatureLike} feature Feature.
65
+ * @param {number} [index] Render order index.
66
+ * @override
67
+ */
68
+ drawLineString(lineStringGeometry, feature, index) {
69
+ const state = this.state;
70
+ const strokeStyle = state.strokeStyle;
71
+ const lineWidth = state.lineWidth;
72
+ if (strokeStyle === undefined || lineWidth === undefined) {
73
+ return;
74
+ }
75
+ this.updateStrokeStyle(state, this.applyStroke);
76
+ this.beginGeometry(lineStringGeometry, feature, index);
77
+ this.hitDetectionInstructions.push(
78
+ [
79
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_1__["default"].SET_STROKE_STYLE,
80
+ state.strokeStyle,
81
+ state.lineWidth,
82
+ state.lineCap,
83
+ state.lineJoin,
84
+ state.miterLimit,
85
+ _canvas_js__WEBPACK_IMPORTED_MODULE_2__.defaultLineDash,
86
+ _canvas_js__WEBPACK_IMPORTED_MODULE_2__.defaultLineDashOffset,
87
+ ],
88
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_1__.beginPathInstruction,
89
+ );
90
+ const flatCoordinates = lineStringGeometry.getFlatCoordinates();
91
+ const stride = lineStringGeometry.getStride();
92
+ this.drawFlatCoordinates_(
93
+ flatCoordinates,
94
+ 0,
95
+ flatCoordinates.length,
96
+ stride,
97
+ );
98
+ this.hitDetectionInstructions.push(_Instruction_js__WEBPACK_IMPORTED_MODULE_1__.strokeInstruction);
99
+ this.endGeometry(feature);
100
+ }
101
+
102
+ /**
103
+ * @param {import("../../geom/MultiLineString.js").default|import("../Feature.js").default} multiLineStringGeometry MultiLineString geometry.
104
+ * @param {import("../../Feature.js").FeatureLike} feature Feature.
105
+ * @param {number} [index] Render order index.
106
+ * @override
107
+ */
108
+ drawMultiLineString(multiLineStringGeometry, feature, index) {
109
+ const state = this.state;
110
+ const strokeStyle = state.strokeStyle;
111
+ const lineWidth = state.lineWidth;
112
+ if (strokeStyle === undefined || lineWidth === undefined) {
113
+ return;
114
+ }
115
+ this.updateStrokeStyle(state, this.applyStroke);
116
+ this.beginGeometry(multiLineStringGeometry, feature, index);
117
+ this.hitDetectionInstructions.push(
118
+ [
119
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_1__["default"].SET_STROKE_STYLE,
120
+ state.strokeStyle,
121
+ state.lineWidth,
122
+ state.lineCap,
123
+ state.lineJoin,
124
+ state.miterLimit,
125
+ _canvas_js__WEBPACK_IMPORTED_MODULE_2__.defaultLineDash,
126
+ _canvas_js__WEBPACK_IMPORTED_MODULE_2__.defaultLineDashOffset,
127
+ ],
128
+ _Instruction_js__WEBPACK_IMPORTED_MODULE_1__.beginPathInstruction,
129
+ );
130
+ const ends = multiLineStringGeometry.getEnds();
131
+ const flatCoordinates = multiLineStringGeometry.getFlatCoordinates();
132
+ const stride = multiLineStringGeometry.getStride();
133
+ let offset = 0;
134
+ for (let i = 0, ii = ends.length; i < ii; ++i) {
135
+ offset = this.drawFlatCoordinates_(
136
+ flatCoordinates,
137
+ offset,
138
+ /** @type {number} */ (ends[i]),
139
+ stride,
140
+ );
141
+ }
142
+ this.hitDetectionInstructions.push(_Instruction_js__WEBPACK_IMPORTED_MODULE_1__.strokeInstruction);
143
+ this.endGeometry(feature);
144
+ }
145
+
146
+ /**
147
+ * @return {import("../canvas.js").SerializableInstructions} the serializable instructions.
148
+ * @override
149
+ */
150
+ finish() {
151
+ const state = this.state;
152
+ if (
153
+ state.lastStroke != undefined &&
154
+ state.lastStroke != this.coordinates.length
155
+ ) {
156
+ this.instructions.push(_Instruction_js__WEBPACK_IMPORTED_MODULE_1__.strokeInstruction);
157
+ }
158
+ this.reverseHitDetectionInstructions();
159
+ this.state = null;
160
+ return super.finish();
161
+ }
162
+
163
+ /**
164
+ * @param {import("../canvas.js").FillStrokeState} state State.
165
+ * @override
166
+ */
167
+ applyStroke(state) {
168
+ if (
169
+ state.lastStroke != undefined &&
170
+ state.lastStroke != this.coordinates.length
171
+ ) {
172
+ this.instructions.push(_Instruction_js__WEBPACK_IMPORTED_MODULE_1__.strokeInstruction);
173
+ state.lastStroke = this.coordinates.length;
174
+ }
175
+ state.lastStroke = 0;
176
+ super.applyStroke(state);
177
+ this.instructions.push(_Instruction_js__WEBPACK_IMPORTED_MODULE_1__.beginPathInstruction);
178
+ }
179
+ }
180
+
181
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (CanvasLineStringBuilder);
182
+
183
+
184
+ /***/ })
185
+
186
+ }])
187
+ //# sourceMappingURL=node_modules_ol_render_canvas_LineStringBuilder_js.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"node_modules_ol_render_canvas_LineStringBuilder_js.js","mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACoE;AAC3B;AAIf;;AAE1B,sCAAsC,mDAAa;AACnD;AACA,aAAa,QAAQ;AACrB,aAAa,kCAAkC;AAC/C,aAAa,QAAQ;AACrB,aAAa,QAAQ;AACrB;AACA;AACA;AACA;;AAEA;AACA,aAAa,eAAe;AAC5B,aAAa,QAAQ;AACrB,aAAa,QAAQ;AACrB,aAAa,QAAQ;AACrB;AACA,cAAc,QAAQ;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,uEAAiC;AACvC;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,aAAa,4EAA4E;AACzF,aAAa,wCAAwC;AACrD,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ,wEAAkC;AAC1C;AACA;AACA;AACA;AACA;AACA,QAAQ,uDAAe;AACvB,QAAQ,6DAAqB;AAC7B;AACA,MAAM,iEAAoB;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uCAAuC,8DAAiB;AACxD;AACA;;AAEA;AACA,aAAa,iFAAiF;AAC9F,aAAa,wCAAwC;AACrD,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ,wEAAkC;AAC1C;AACA;AACA;AACA;AACA;AACA,QAAQ,uDAAe;AACvB,QAAQ,6DAAqB;AAC7B;AACA,MAAM,iEAAoB;AAC1B;AACA;AACA;AACA;AACA;AACA,sCAAsC,QAAQ;AAC9C;AACA;AACA;AACA,mBAAmB,QAAQ;AAC3B;AACA;AACA;AACA,uCAAuC,8DAAiB;AACxD;AACA;;AAEA;AACA,cAAc,iDAAiD;AAC/D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B,8DAAiB;AAC9C;AACA;AACA;AACA;AACA;;AAEA;AACA,aAAa,wCAAwC;AACrD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B,8DAAiB;AAC9C;AACA;AACA;AACA;AACA,2BAA2B,iEAAoB;AAC/C;AACA;;AAEA,iEAAe,uBAAuB,EAAC","sources":["webpack://@vaadin/bundles/./node_modules/ol/render/canvas/LineStringBuilder.js"],"sourcesContent":["/**\n * @module ol/render/canvas/LineStringBuilder\n */\nimport {defaultLineDash, defaultLineDashOffset} from '../canvas.js';\nimport CanvasBuilder from './Builder.js';\nimport CanvasInstruction, {\n beginPathInstruction,\n strokeInstruction,\n} from './Instruction.js';\n\nclass CanvasLineStringBuilder extends CanvasBuilder {\n /**\n * @param {number} tolerance Tolerance.\n * @param {import(\"../../extent.js\").Extent} maxExtent Maximum extent.\n * @param {number} resolution Resolution.\n * @param {number} pixelRatio Pixel ratio.\n */\n constructor(tolerance, maxExtent, resolution, pixelRatio) {\n super(tolerance, maxExtent, resolution, pixelRatio);\n }\n\n /**\n * @param {Array<number>} flatCoordinates Flat coordinates.\n * @param {number} offset Offset.\n * @param {number} end End.\n * @param {number} stride Stride.\n * @private\n * @return {number} end.\n */\n drawFlatCoordinates_(flatCoordinates, offset, end, stride) {\n const myBegin = this.coordinates.length;\n const myEnd = this.appendFlatLineCoordinates(\n flatCoordinates,\n offset,\n end,\n stride,\n false,\n false,\n );\n const moveToLineToInstruction = [\n CanvasInstruction.MOVE_TO_LINE_TO,\n myBegin,\n myEnd,\n ];\n this.instructions.push(moveToLineToInstruction);\n this.hitDetectionInstructions.push(moveToLineToInstruction);\n return end;\n }\n\n /**\n * @param {import(\"../../geom/LineString.js\").default|import(\"../Feature.js\").default} lineStringGeometry Line string geometry.\n * @param {import(\"../../Feature.js\").FeatureLike} feature Feature.\n * @param {number} [index] Render order index.\n * @override\n */\n drawLineString(lineStringGeometry, feature, index) {\n const state = this.state;\n const strokeStyle = state.strokeStyle;\n const lineWidth = state.lineWidth;\n if (strokeStyle === undefined || lineWidth === undefined) {\n return;\n }\n this.updateStrokeStyle(state, this.applyStroke);\n this.beginGeometry(lineStringGeometry, feature, index);\n this.hitDetectionInstructions.push(\n [\n CanvasInstruction.SET_STROKE_STYLE,\n state.strokeStyle,\n state.lineWidth,\n state.lineCap,\n state.lineJoin,\n state.miterLimit,\n defaultLineDash,\n defaultLineDashOffset,\n ],\n beginPathInstruction,\n );\n const flatCoordinates = lineStringGeometry.getFlatCoordinates();\n const stride = lineStringGeometry.getStride();\n this.drawFlatCoordinates_(\n flatCoordinates,\n 0,\n flatCoordinates.length,\n stride,\n );\n this.hitDetectionInstructions.push(strokeInstruction);\n this.endGeometry(feature);\n }\n\n /**\n * @param {import(\"../../geom/MultiLineString.js\").default|import(\"../Feature.js\").default} multiLineStringGeometry MultiLineString geometry.\n * @param {import(\"../../Feature.js\").FeatureLike} feature Feature.\n * @param {number} [index] Render order index.\n * @override\n */\n drawMultiLineString(multiLineStringGeometry, feature, index) {\n const state = this.state;\n const strokeStyle = state.strokeStyle;\n const lineWidth = state.lineWidth;\n if (strokeStyle === undefined || lineWidth === undefined) {\n return;\n }\n this.updateStrokeStyle(state, this.applyStroke);\n this.beginGeometry(multiLineStringGeometry, feature, index);\n this.hitDetectionInstructions.push(\n [\n CanvasInstruction.SET_STROKE_STYLE,\n state.strokeStyle,\n state.lineWidth,\n state.lineCap,\n state.lineJoin,\n state.miterLimit,\n defaultLineDash,\n defaultLineDashOffset,\n ],\n beginPathInstruction,\n );\n const ends = multiLineStringGeometry.getEnds();\n const flatCoordinates = multiLineStringGeometry.getFlatCoordinates();\n const stride = multiLineStringGeometry.getStride();\n let offset = 0;\n for (let i = 0, ii = ends.length; i < ii; ++i) {\n offset = this.drawFlatCoordinates_(\n flatCoordinates,\n offset,\n /** @type {number} */ (ends[i]),\n stride,\n );\n }\n this.hitDetectionInstructions.push(strokeInstruction);\n this.endGeometry(feature);\n }\n\n /**\n * @return {import(\"../canvas.js\").SerializableInstructions} the serializable instructions.\n * @override\n */\n finish() {\n const state = this.state;\n if (\n state.lastStroke != undefined &&\n state.lastStroke != this.coordinates.length\n ) {\n this.instructions.push(strokeInstruction);\n }\n this.reverseHitDetectionInstructions();\n this.state = null;\n return super.finish();\n }\n\n /**\n * @param {import(\"../canvas.js\").FillStrokeState} state State.\n * @override\n */\n applyStroke(state) {\n if (\n state.lastStroke != undefined &&\n state.lastStroke != this.coordinates.length\n ) {\n this.instructions.push(strokeInstruction);\n state.lastStroke = this.coordinates.length;\n }\n state.lastStroke = 0;\n super.applyStroke(state);\n this.instructions.push(beginPathInstruction);\n }\n}\n\nexport default CanvasLineStringBuilder;\n"],"names":[],"sourceRoot":""}