@kalisio/kdk 2.5.3 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (545) hide show
  1. package/.github/workflows/main.yaml +35 -6
  2. package/client.globe.js +8 -0
  3. package/client.js +8 -0
  4. package/client.map.js +8 -0
  5. package/core/api/hooks/hooks.push.js +3 -2
  6. package/core/api/hooks/hooks.tags.js +56 -0
  7. package/core/api/models/tags.model.mongodb.js +8 -0
  8. package/core/api/services/index.js +33 -2
  9. package/core/api/services/tags/tags.hooks.js +47 -0
  10. package/core/client/api.js +5 -5
  11. package/core/client/components/KActivity.vue +3 -2
  12. package/core/client/components/KChip.vue +2 -2
  13. package/core/client/components/KEditor.vue +3 -1
  14. package/core/client/components/KFollower.vue +4 -4
  15. package/core/client/components/KStore.vue +1 -1
  16. package/core/client/components/KTab.vue +20 -7
  17. package/core/client/components/account/KProfile.vue +9 -25
  18. package/core/client/components/action/KAction.vue +10 -10
  19. package/core/client/components/action/KToggleFullscreenAction.vue +2 -11
  20. package/core/client/components/app/KHome.vue +3 -2
  21. package/core/client/components/collection/KFilter.vue +5 -4
  22. package/core/client/components/collection/KGrid.vue +5 -1
  23. package/core/client/components/collection/KItemsFilter.vue +47 -0
  24. package/core/client/components/collection/KItemsSorter.vue +42 -0
  25. package/core/client/components/collection/KScrollDown.vue +2 -2
  26. package/core/client/components/collection/KSearchFilterControl.vue +3 -2
  27. package/core/client/components/collection/KSorter.vue +33 -37
  28. package/core/client/components/collection/KTagsFilterControl.vue +14 -40
  29. package/core/client/components/collection/KTagsFilterView.vue +10 -45
  30. package/core/client/components/collection/KTimeFilterControl.vue +6 -7
  31. package/core/client/components/collection/KTimeFilterView.vue +13 -22
  32. package/core/client/components/collection/KTimeLine.vue +18 -9
  33. package/core/client/components/form/KColorField.vue +13 -6
  34. package/core/client/components/form/KColorScaleField.vue +7 -12
  35. package/core/client/components/form/KFileField.vue +118 -89
  36. package/core/client/components/form/KForm.vue +30 -18
  37. package/core/client/components/form/KIconField.vue +4 -1
  38. package/core/client/components/form/KNumberField.vue +9 -2
  39. package/core/client/components/form/KSelectField.vue +1 -4
  40. package/core/client/components/form/KTagField.vue +229 -0
  41. package/core/client/components/form/KTextField.vue +4 -0
  42. package/core/client/components/form/KTextareaField.vue +3 -1
  43. package/core/client/components/input/KShapePicker.vue +3 -3
  44. package/core/client/components/layout/KFab.vue +32 -20
  45. package/core/client/components/layout/KPage.vue +11 -6
  46. package/core/client/components/layout/KWindow.vue +5 -0
  47. package/core/client/components/media/index.js +2 -6
  48. package/core/client/components/menu/KMenu.vue +12 -10
  49. package/core/client/components/menu/KSubMenu.vue +12 -12
  50. package/core/client/components/messages/KMessageCard.vue +13 -12
  51. package/core/client/components/messages/KMessageComposer.vue +13 -9
  52. package/core/client/components/messages/KMessagesTimeLine.vue +16 -8
  53. package/core/client/components/tags/KTagFilter.vue +99 -0
  54. package/core/client/components/tags/KTagItem.vue +65 -0
  55. package/core/client/components/tags/KTagManager.vue +198 -0
  56. package/core/client/components/tags/KTagSelection.vue +82 -0
  57. package/core/client/components/time/KDate.vue +3 -17
  58. package/core/client/components/time/KDateTime.vue +1 -1
  59. package/core/client/components/time/KTime.vue +0 -4
  60. package/core/client/composables/collection-filter.js +41 -2
  61. package/core/client/composables/collection.js +3 -3
  62. package/core/client/composables/index.js +1 -0
  63. package/core/client/composables/pwa.js +13 -0
  64. package/core/client/composables/session.js +7 -8
  65. package/core/client/composables/user.js +36 -0
  66. package/core/client/directives/index.js +1 -0
  67. package/core/client/directives/v-drop-file.js +174 -0
  68. package/core/client/document.js +2 -1
  69. package/core/client/exporter.js +17 -3
  70. package/core/client/i18n/core_en.json +34 -7
  71. package/core/client/i18n/core_fr.json +36 -9
  72. package/core/client/i18n.js +26 -11
  73. package/core/client/layout.js +5 -5
  74. package/core/client/mixins/mixin.base-activity.js +8 -5
  75. package/core/client/mixins/mixin.base-editor.js +2 -1
  76. package/core/client/mixins/mixin.base-field.js +3 -2
  77. package/core/client/mixins/mixin.base-item.js +12 -10
  78. package/core/client/mixins/mixin.service.js +3 -1
  79. package/core/client/platform.js +0 -3
  80. package/core/client/readers/reader.json.js +2 -2
  81. package/core/client/utils/index.js +2 -0
  82. package/core/client/utils/utils.collection.js +6 -6
  83. package/core/client/utils/utils.colors.js +46 -19
  84. package/core/client/utils/utils.files.js +19 -0
  85. package/core/client/utils/utils.locale.js +13 -17
  86. package/core/client/utils/utils.services.js +27 -0
  87. package/core/client/utils/utils.shapes.js +2 -2
  88. package/core/client/utils/utils.tags.js +17 -0
  89. package/core/client/utils/utils.tours.js +31 -0
  90. package/core/common/permissions.js +3 -0
  91. package/core/common/schemas/tags.update.json +35 -0
  92. package/core/common/schemas/users.update-profile.json +1 -1
  93. package/core/common/utils.js +5 -5
  94. package/extras/configs/panes.top.js +11 -0
  95. package/extras/configs/stickies.js +1 -1
  96. package/extras/configs/widgets.left.js +13 -1
  97. package/extras/libs/jsts.min.js +8 -0
  98. package/{test/client/core/account.js → extras/tests/core/account.mjs} +4 -4
  99. package/extras/tests/core/api.mjs +114 -0
  100. package/{test/client/core/collection.js → extras/tests/core/collection.mjs} +8 -8
  101. package/{test/client/core/dialogs.js → extras/tests/core/dialogs.mjs} +1 -1
  102. package/extras/tests/core/index.mjs +9 -0
  103. package/{test/client/core/layout.js → extras/tests/core/layout.mjs} +7 -3
  104. package/{test/client/core/runner.js → extras/tests/core/runner.mjs} +3 -3
  105. package/{test/client/core/screens.js → extras/tests/core/screens.mjs} +1 -1
  106. package/{test/client/core/utils.js → extras/tests/core/utils.mjs} +79 -26
  107. package/extras/tests/index.mjs +4 -0
  108. package/{test/client/map/api.js → extras/tests/map/api.mjs} +1 -1
  109. package/{test/client/map/catalog.js → extras/tests/map/catalog.mjs} +18 -18
  110. package/{test/client/map/controls.js → extras/tests/map/controls.mjs} +3 -3
  111. package/extras/tests/map/index.mjs +5 -0
  112. package/{test/client/map/time.js → extras/tests/map/time.mjs} +3 -3
  113. package/{test/client/map/utils.js → extras/tests/map/utils.mjs} +6 -5
  114. package/extras/tours/fab.js +36 -0
  115. package/extras/tours/layout.js +49 -0
  116. package/extras/tours/pane.left.js +78 -0
  117. package/extras/tours/pane.right.js +145 -0
  118. package/extras/tours/pane.top.js +239 -0
  119. package/map/api/config/layers.cjs +28 -13
  120. package/map/api/hooks/hooks.query.js +12 -7
  121. package/map/api/models/catalog.model.mongodb.js +17 -6
  122. package/map/api/services/catalog/catalog.hooks.js +1 -1
  123. package/map/api/services/index.js +18 -1
  124. package/map/client/cesium/utils/utils.cesium.js +25 -65
  125. package/map/client/cesium/utils/utils.features.js +1 -0
  126. package/map/client/cesium/utils/utils.geojson.js +1 -0
  127. package/map/client/cesium/utils/utils.style.js +7 -6
  128. package/map/client/components/KFeatureEditor.vue +3 -3
  129. package/map/client/components/KFeaturesChart.vue +4 -4
  130. package/map/client/components/KFeaturesFilterEditor.vue +19 -13
  131. package/map/client/components/KFeaturesFilterManager.vue +7 -4
  132. package/map/client/components/KFeaturesTable.vue +2 -2
  133. package/map/client/components/KLayerEditor.vue +6 -6
  134. package/map/client/components/KMeasureTool.vue +2 -1
  135. package/map/client/components/catalog/KBaseLayersSelector.vue +1 -1
  136. package/map/client/components/catalog/KCategoryItem.vue +15 -1
  137. package/map/client/components/catalog/KConnectLayer.vue +2 -2
  138. package/map/client/components/catalog/KCreateView.vue +3 -2
  139. package/map/client/components/catalog/KFilteredLayerItem.vue +26 -6
  140. package/map/client/components/catalog/KImportLayer.vue +6 -3
  141. package/map/client/components/catalog/KLayerCategories.vue +6 -6
  142. package/map/client/components/catalog/KLayerItem.vue +12 -2
  143. package/map/client/components/catalog/KLayersList.vue +180 -0
  144. package/map/client/components/catalog/KLayersPanel.vue +146 -36
  145. package/map/client/components/catalog/KLayersSelector.vue +96 -48
  146. package/map/client/components/catalog/KProjectEditor.vue +0 -9
  147. package/map/client/components/catalog/KProjectSelector.vue +3 -2
  148. package/map/client/components/catalog/KProjectsPanel.vue +23 -8
  149. package/map/client/components/catalog/KViewsPanel.vue +18 -8
  150. package/map/client/components/catalog/KWeatherLayersSelector.vue +3 -3
  151. package/map/client/components/form/KDirectionField.vue +3 -6
  152. package/map/client/components/form/KLayerCategoryField.vue +2 -2
  153. package/map/client/components/form/KOwsServiceField.vue +25 -24
  154. package/map/client/components/form/KSelectLayersField.vue +4 -4
  155. package/map/client/components/form/KSelectViewsField.vue +4 -4
  156. package/map/client/components/legend/KLayerLegend.vue +11 -2
  157. package/map/client/components/legend/KLegend.vue +44 -51
  158. package/map/client/components/location/KLocationCardSection.vue +6 -7
  159. package/map/client/components/location/KLocationMap.vue +23 -13
  160. package/map/client/components/stickies/KPosition.vue +5 -0
  161. package/map/client/components/styles/KLayerStyleAction.vue +59 -12
  162. package/map/client/components/styles/KStyleEditor.vue +71 -8
  163. package/map/client/components/styles/KStyleEditorSection.vue +82 -33
  164. package/map/client/components/styles/KStyleManager.vue +119 -59
  165. package/map/client/components/styles/KStylePreview.vue +9 -25
  166. package/map/client/components/styles/KStylePreviewItem.vue +22 -1
  167. package/map/client/components/tools/KSearchTool.vue +1 -1
  168. package/map/client/components/widget/KElevationProfile.vue +20 -17
  169. package/map/client/components/widget/KInformationBox.vue +5 -5
  170. package/map/client/components/widget/KMapillaryViewer.vue +2 -1
  171. package/map/client/components/widget/KTimeSeries.vue +11 -9
  172. package/map/client/globe.js +2 -0
  173. package/map/client/i18n/map_en.json +29 -7
  174. package/map/client/i18n/map_fr.json +29 -7
  175. package/map/client/leaflet/GradientPath.js +61 -24
  176. package/map/client/leaflet/ShapeMarker.js +12 -5
  177. package/map/client/leaflet/TiledMeshLayer.js +3 -3
  178. package/map/client/leaflet/utils/utils.geojson.js +66 -8
  179. package/map/client/leaflet/utils/utils.style.js +14 -15
  180. package/map/client/mixins/globe/mixin.base-globe.js +181 -34
  181. package/map/client/mixins/globe/mixin.file-layers.js +3 -0
  182. package/map/client/mixins/globe/mixin.geojson-layers.js +179 -31
  183. package/map/client/mixins/globe/mixin.opendap-layers.js +2 -1
  184. package/map/client/mixins/globe/mixin.style.js +23 -1
  185. package/map/client/mixins/globe/mixin.tooltip.js +14 -2
  186. package/map/client/mixins/map/mixin.base-map.js +146 -58
  187. package/map/client/mixins/map/mixin.edit-layers.js +18 -15
  188. package/map/client/mixins/map/mixin.geojson-layers.js +181 -106
  189. package/map/client/mixins/map/mixin.heatmap-layers.js +3 -2
  190. package/map/client/mixins/map/mixin.map-activity.js +6 -1
  191. package/map/client/mixins/map/mixin.mapillary-layers.js +2 -1
  192. package/map/client/mixins/map/mixin.pmtiles-layers.js +3 -3
  193. package/map/client/mixins/map/mixin.tiled-mesh-layers.js +3 -2
  194. package/map/client/mixins/map/mixin.tiled-wind-layers.js +3 -2
  195. package/map/client/mixins/mixin.activity.js +197 -51
  196. package/map/client/mixins/mixin.context.js +11 -11
  197. package/map/client/mixins/mixin.feature-service.js +11 -9
  198. package/map/client/mixins/mixin.weacast.js +5 -3
  199. package/map/client/readers/reader.geojson.js +3 -1
  200. package/map/client/utils/utils.capture.js +3 -3
  201. package/map/client/utils/utils.catalog.js +9 -5
  202. package/map/client/utils/utils.features.js +120 -54
  203. package/map/client/utils/utils.js +25 -10
  204. package/map/client/utils/utils.layers.js +148 -24
  205. package/map/client/utils/utils.location.js +26 -9
  206. package/map/client/utils/utils.schema.js +2 -1
  207. package/map/client/utils/utils.style.js +53 -9
  208. package/map/common/geotiff-grid-source.js +1 -3
  209. package/map/common/opendap-utils.js +0 -1
  210. package/map/common/tms-utils.js +0 -1
  211. package/map/common/wcs-utils.js +0 -1
  212. package/map/common/wfs-utils.js +0 -1
  213. package/map/common/wms-utils.js +7 -1
  214. package/map/common/wmts-utils.js +0 -1
  215. package/package.json +12 -12
  216. package/scripts/init_runner.sh +3 -3
  217. package/scripts/kash/CHANGELOG.md +27 -0
  218. package/scripts/kash/kash.sh +556 -237
  219. package/scripts/kash/scripts/run_tests.sh +44 -5
  220. package/scripts/setup_workspace.sh +23 -13
  221. package/test/api/core/config/default.cjs +2 -1
  222. package/test/api/core/tags.test.js +62 -0
  223. package/test/api/map/config/default.cjs +2 -1
  224. package/test/api/map/config/layers.json +9 -0
  225. package/test/api/map/data/openradiation.json +13811 -0
  226. package/test/api/map/grid-sources.test.js +1 -3
  227. package/test/api/map/index.test.js +60 -1
  228. package/test/api/map/style.test.js +30 -1
  229. package/test.api.js +1 -1
  230. package/vite/App.vue +18 -0
  231. package/vite/AppWithGlobe.vue +84 -0
  232. package/vite/GlobeActivity.vue +58 -0
  233. package/vite/MapActivity.vue +63 -0
  234. package/vite/MapActivityWithGlobe.vue +63 -0
  235. package/vite/README.md +169 -0
  236. package/vite/config.js +221 -0
  237. package/vite/index_with_globe.html +50 -0
  238. package/vite/index_with_map.html +50 -0
  239. package/vite/package.json +173 -0
  240. package/vite/quasar.variables.scss +17 -0
  241. package/vite/vite.config.js +166 -0
  242. package/vite/yarn.lock +11641 -0
  243. package/core/client/components/media/KImageViewer.vue +0 -68
  244. package/core/client/components/media/KMarkdownViewer.vue +0 -55
  245. package/core/client/components/media/KMediaBrowser.vue +0 -301
  246. package/coverage/base.css +0 -224
  247. package/coverage/block-navigation.js +0 -87
  248. package/coverage/core/api/application.js.html +0 -1870
  249. package/coverage/core/api/authentication.js.html +0 -874
  250. package/coverage/core/api/db.js.html +0 -793
  251. package/coverage/core/api/hooks/hooks.authentication.js.html +0 -139
  252. package/coverage/core/api/hooks/hooks.authorisations.js.html +0 -958
  253. package/coverage/core/api/hooks/hooks.groups.js.html +0 -229
  254. package/coverage/core/api/hooks/hooks.logger.js.html +0 -163
  255. package/coverage/core/api/hooks/hooks.model.js.html +0 -967
  256. package/coverage/core/api/hooks/hooks.organisations.js.html +0 -541
  257. package/coverage/core/api/hooks/hooks.push.js.html +0 -265
  258. package/coverage/core/api/hooks/hooks.query.js.html +0 -862
  259. package/coverage/core/api/hooks/hooks.schemas.js.html +0 -298
  260. package/coverage/core/api/hooks/hooks.service.js.html +0 -319
  261. package/coverage/core/api/hooks/hooks.storage.js.html +0 -193
  262. package/coverage/core/api/hooks/hooks.users.js.html +0 -595
  263. package/coverage/core/api/hooks/index.html +0 -266
  264. package/coverage/core/api/hooks/index.js.html +0 -115
  265. package/coverage/core/api/index.html +0 -176
  266. package/coverage/core/api/index.js.html +0 -148
  267. package/coverage/core/api/marshall.js.html +0 -448
  268. package/coverage/core/api/models/groups.model.mongodb.js.html +0 -109
  269. package/coverage/core/api/models/index.html +0 -131
  270. package/coverage/core/api/models/messages.model.mongodb.js.html +0 -121
  271. package/coverage/core/api/models/organisations.model.mongodb.js.html +0 -94
  272. package/coverage/core/api/models/tags.model.mongodb.js.html +0 -115
  273. package/coverage/core/api/models/users.model.mongodb.js.html +0 -115
  274. package/coverage/core/api/services/account/account.hooks.js.html +0 -208
  275. package/coverage/core/api/services/account/account.service.js.html +0 -436
  276. package/coverage/core/api/services/account/index.html +0 -131
  277. package/coverage/core/api/services/authorisations/authorisations.hooks.js.html +0 -184
  278. package/coverage/core/api/services/authorisations/authorisations.service.js.html +0 -520
  279. package/coverage/core/api/services/authorisations/index.html +0 -131
  280. package/coverage/core/api/services/databases/databases.hooks.js.html +0 -193
  281. package/coverage/core/api/services/databases/databases.service.js.html +0 -100
  282. package/coverage/core/api/services/databases/index.html +0 -131
  283. package/coverage/core/api/services/groups/groups.hooks.js.html +0 -178
  284. package/coverage/core/api/services/groups/index.html +0 -116
  285. package/coverage/core/api/services/import-export/import-export.hooks.js.html +0 -184
  286. package/coverage/core/api/services/import-export/import-export.service.js.html +0 -118
  287. package/coverage/core/api/services/import-export/index.html +0 -131
  288. package/coverage/core/api/services/index.html +0 -116
  289. package/coverage/core/api/services/index.js.html +0 -532
  290. package/coverage/core/api/services/mailer/index.html +0 -131
  291. package/coverage/core/api/services/mailer/mailer.hooks.js.html +0 -190
  292. package/coverage/core/api/services/mailer/mailer.service.js.html +0 -118
  293. package/coverage/core/api/services/messages/index.html +0 -116
  294. package/coverage/core/api/services/messages/messages.hooks.js.html +0 -202
  295. package/coverage/core/api/services/organisations/index.html +0 -131
  296. package/coverage/core/api/services/organisations/organisations.hooks.js.html +0 -178
  297. package/coverage/core/api/services/organisations/organisations.service.js.html +0 -343
  298. package/coverage/core/api/services/push/index.html +0 -131
  299. package/coverage/core/api/services/push/push.hooks.js.html +0 -190
  300. package/coverage/core/api/services/push/push.service.js.html +0 -121
  301. package/coverage/core/api/services/storage/index.html +0 -131
  302. package/coverage/core/api/services/storage/storage.hooks.js.html +0 -190
  303. package/coverage/core/api/services/storage/storage.service.js.html +0 -172
  304. package/coverage/core/api/services/tags/index.html +0 -116
  305. package/coverage/core/api/services/tags/tags.hooks.js.html +0 -178
  306. package/coverage/core/api/services/users/index.html +0 -131
  307. package/coverage/core/api/services/users/users.hooks.js.html +0 -310
  308. package/coverage/core/api/services/users/users.service.js.html +0 -100
  309. package/coverage/core/api/utils.js.html +0 -118
  310. package/coverage/core/common/errors.js.html +0 -88
  311. package/coverage/core/common/index.html +0 -191
  312. package/coverage/core/common/index.js.html +0 -115
  313. package/coverage/core/common/permissions.js.html +0 -733
  314. package/coverage/core/common/schema.js.html +0 -190
  315. package/coverage/core/common/utils.js.html +0 -226
  316. package/coverage/core/common/utils.offline.js.html +0 -199
  317. package/coverage/favicon.png +0 -0
  318. package/coverage/index.html +0 -476
  319. package/coverage/lcov-report/base.css +0 -224
  320. package/coverage/lcov-report/block-navigation.js +0 -87
  321. package/coverage/lcov-report/core/api/application.js.html +0 -1870
  322. package/coverage/lcov-report/core/api/authentication.js.html +0 -874
  323. package/coverage/lcov-report/core/api/db.js.html +0 -793
  324. package/coverage/lcov-report/core/api/hooks/hooks.authentication.js.html +0 -139
  325. package/coverage/lcov-report/core/api/hooks/hooks.authorisations.js.html +0 -958
  326. package/coverage/lcov-report/core/api/hooks/hooks.groups.js.html +0 -229
  327. package/coverage/lcov-report/core/api/hooks/hooks.logger.js.html +0 -163
  328. package/coverage/lcov-report/core/api/hooks/hooks.model.js.html +0 -967
  329. package/coverage/lcov-report/core/api/hooks/hooks.organisations.js.html +0 -541
  330. package/coverage/lcov-report/core/api/hooks/hooks.push.js.html +0 -265
  331. package/coverage/lcov-report/core/api/hooks/hooks.query.js.html +0 -862
  332. package/coverage/lcov-report/core/api/hooks/hooks.schemas.js.html +0 -298
  333. package/coverage/lcov-report/core/api/hooks/hooks.service.js.html +0 -319
  334. package/coverage/lcov-report/core/api/hooks/hooks.storage.js.html +0 -193
  335. package/coverage/lcov-report/core/api/hooks/hooks.users.js.html +0 -595
  336. package/coverage/lcov-report/core/api/hooks/index.html +0 -266
  337. package/coverage/lcov-report/core/api/hooks/index.js.html +0 -115
  338. package/coverage/lcov-report/core/api/index.html +0 -176
  339. package/coverage/lcov-report/core/api/index.js.html +0 -148
  340. package/coverage/lcov-report/core/api/marshall.js.html +0 -448
  341. package/coverage/lcov-report/core/api/models/groups.model.mongodb.js.html +0 -109
  342. package/coverage/lcov-report/core/api/models/index.html +0 -131
  343. package/coverage/lcov-report/core/api/models/messages.model.mongodb.js.html +0 -121
  344. package/coverage/lcov-report/core/api/models/organisations.model.mongodb.js.html +0 -94
  345. package/coverage/lcov-report/core/api/models/tags.model.mongodb.js.html +0 -115
  346. package/coverage/lcov-report/core/api/models/users.model.mongodb.js.html +0 -115
  347. package/coverage/lcov-report/core/api/services/account/account.hooks.js.html +0 -208
  348. package/coverage/lcov-report/core/api/services/account/account.service.js.html +0 -436
  349. package/coverage/lcov-report/core/api/services/account/index.html +0 -131
  350. package/coverage/lcov-report/core/api/services/authorisations/authorisations.hooks.js.html +0 -184
  351. package/coverage/lcov-report/core/api/services/authorisations/authorisations.service.js.html +0 -520
  352. package/coverage/lcov-report/core/api/services/authorisations/index.html +0 -131
  353. package/coverage/lcov-report/core/api/services/databases/databases.hooks.js.html +0 -193
  354. package/coverage/lcov-report/core/api/services/databases/databases.service.js.html +0 -100
  355. package/coverage/lcov-report/core/api/services/databases/index.html +0 -131
  356. package/coverage/lcov-report/core/api/services/groups/groups.hooks.js.html +0 -178
  357. package/coverage/lcov-report/core/api/services/groups/index.html +0 -116
  358. package/coverage/lcov-report/core/api/services/import-export/import-export.hooks.js.html +0 -184
  359. package/coverage/lcov-report/core/api/services/import-export/import-export.service.js.html +0 -118
  360. package/coverage/lcov-report/core/api/services/import-export/index.html +0 -131
  361. package/coverage/lcov-report/core/api/services/index.html +0 -116
  362. package/coverage/lcov-report/core/api/services/index.js.html +0 -532
  363. package/coverage/lcov-report/core/api/services/mailer/index.html +0 -131
  364. package/coverage/lcov-report/core/api/services/mailer/mailer.hooks.js.html +0 -190
  365. package/coverage/lcov-report/core/api/services/mailer/mailer.service.js.html +0 -118
  366. package/coverage/lcov-report/core/api/services/messages/index.html +0 -116
  367. package/coverage/lcov-report/core/api/services/messages/messages.hooks.js.html +0 -202
  368. package/coverage/lcov-report/core/api/services/organisations/index.html +0 -131
  369. package/coverage/lcov-report/core/api/services/organisations/organisations.hooks.js.html +0 -178
  370. package/coverage/lcov-report/core/api/services/organisations/organisations.service.js.html +0 -343
  371. package/coverage/lcov-report/core/api/services/push/index.html +0 -131
  372. package/coverage/lcov-report/core/api/services/push/push.hooks.js.html +0 -190
  373. package/coverage/lcov-report/core/api/services/push/push.service.js.html +0 -121
  374. package/coverage/lcov-report/core/api/services/storage/index.html +0 -131
  375. package/coverage/lcov-report/core/api/services/storage/storage.hooks.js.html +0 -190
  376. package/coverage/lcov-report/core/api/services/storage/storage.service.js.html +0 -172
  377. package/coverage/lcov-report/core/api/services/tags/index.html +0 -116
  378. package/coverage/lcov-report/core/api/services/tags/tags.hooks.js.html +0 -178
  379. package/coverage/lcov-report/core/api/services/users/index.html +0 -131
  380. package/coverage/lcov-report/core/api/services/users/users.hooks.js.html +0 -310
  381. package/coverage/lcov-report/core/api/services/users/users.service.js.html +0 -100
  382. package/coverage/lcov-report/core/api/utils.js.html +0 -118
  383. package/coverage/lcov-report/core/common/errors.js.html +0 -88
  384. package/coverage/lcov-report/core/common/index.html +0 -191
  385. package/coverage/lcov-report/core/common/index.js.html +0 -115
  386. package/coverage/lcov-report/core/common/permissions.js.html +0 -733
  387. package/coverage/lcov-report/core/common/schema.js.html +0 -190
  388. package/coverage/lcov-report/core/common/utils.js.html +0 -226
  389. package/coverage/lcov-report/core/common/utils.offline.js.html +0 -199
  390. package/coverage/lcov-report/favicon.png +0 -0
  391. package/coverage/lcov-report/index.html +0 -476
  392. package/coverage/lcov-report/map/api/hooks/hooks.catalog.js.html +0 -553
  393. package/coverage/lcov-report/map/api/hooks/hooks.features.js.html +0 -397
  394. package/coverage/lcov-report/map/api/hooks/hooks.query.js.html +0 -1294
  395. package/coverage/lcov-report/map/api/hooks/index.html +0 -161
  396. package/coverage/lcov-report/map/api/hooks/index.js.html +0 -94
  397. package/coverage/lcov-report/map/api/index.html +0 -131
  398. package/coverage/lcov-report/map/api/index.js.html +0 -139
  399. package/coverage/lcov-report/map/api/marshall.js.html +0 -178
  400. package/coverage/lcov-report/map/api/models/alerts.model.mongodb.js.html +0 -106
  401. package/coverage/lcov-report/map/api/models/catalog.model.mongodb.js.html +0 -169
  402. package/coverage/lcov-report/map/api/models/features.model.mongodb.js.html +0 -196
  403. package/coverage/lcov-report/map/api/models/index.html +0 -176
  404. package/coverage/lcov-report/map/api/models/projects.model.mongodb.js.html +0 -109
  405. package/coverage/lcov-report/map/api/models/styles.model.mongodb.js.html +0 -112
  406. package/coverage/lcov-report/map/api/services/alerts/alerts.hooks.js.html +0 -274
  407. package/coverage/lcov-report/map/api/services/alerts/alerts.service.js.html +0 -610
  408. package/coverage/lcov-report/map/api/services/alerts/index.html +0 -131
  409. package/coverage/lcov-report/map/api/services/catalog/catalog.hooks.js.html +0 -328
  410. package/coverage/lcov-report/map/api/services/catalog/index.html +0 -116
  411. package/coverage/lcov-report/map/api/services/daptiles/daptiles.service.js.html +0 -1510
  412. package/coverage/lcov-report/map/api/services/daptiles/index.html +0 -116
  413. package/coverage/lcov-report/map/api/services/features/features.hooks.js.html +0 -310
  414. package/coverage/lcov-report/map/api/services/features/features.service.js.html +0 -544
  415. package/coverage/lcov-report/map/api/services/features/index.html +0 -131
  416. package/coverage/lcov-report/map/api/services/index.html +0 -116
  417. package/coverage/lcov-report/map/api/services/index.js.html +0 -1054
  418. package/coverage/lcov-report/map/api/services/projects/index.html +0 -116
  419. package/coverage/lcov-report/map/api/services/projects/projects.hooks.js.html +0 -439
  420. package/coverage/lcov-report/map/api/services/styles/index.html +0 -116
  421. package/coverage/lcov-report/map/api/services/styles/styles.hooks.js.html +0 -196
  422. package/coverage/lcov-report/map/common/dynamic-grid-source.js.html +0 -466
  423. package/coverage/lcov-report/map/common/errors.js.html +0 -94
  424. package/coverage/lcov-report/map/common/geotiff-grid-source.js.html +0 -544
  425. package/coverage/lcov-report/map/common/grid.js.html +0 -1612
  426. package/coverage/lcov-report/map/common/index.html +0 -371
  427. package/coverage/lcov-report/map/common/index.js.html +0 -172
  428. package/coverage/lcov-report/map/common/meteo-model-grid-source.js.html +0 -556
  429. package/coverage/lcov-report/map/common/moment-utils.js.html +0 -157
  430. package/coverage/lcov-report/map/common/opendap-grid-source.js.html +0 -868
  431. package/coverage/lcov-report/map/common/opendap-utils.js.html +0 -826
  432. package/coverage/lcov-report/map/common/permissions.js.html +0 -130
  433. package/coverage/lcov-report/map/common/time-based-grid-source.js.html +0 -418
  434. package/coverage/lcov-report/map/common/tms-utils.js.html +0 -274
  435. package/coverage/lcov-report/map/common/wcs-grid-source.js.html +0 -364
  436. package/coverage/lcov-report/map/common/wcs-utils.js.html +0 -586
  437. package/coverage/lcov-report/map/common/weacast-grid-source.js.html +0 -1033
  438. package/coverage/lcov-report/map/common/wfs-utils.js.html +0 -574
  439. package/coverage/lcov-report/map/common/wms-utils.js.html +0 -451
  440. package/coverage/lcov-report/map/common/wmts-utils.js.html +0 -547
  441. package/coverage/lcov-report/prettify.css +0 -1
  442. package/coverage/lcov-report/prettify.js +0 -2
  443. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  444. package/coverage/lcov-report/sorter.js +0 -196
  445. package/coverage/lcov.info +0 -11520
  446. package/coverage/map/api/hooks/hooks.catalog.js.html +0 -553
  447. package/coverage/map/api/hooks/hooks.features.js.html +0 -397
  448. package/coverage/map/api/hooks/hooks.query.js.html +0 -1294
  449. package/coverage/map/api/hooks/index.html +0 -161
  450. package/coverage/map/api/hooks/index.js.html +0 -94
  451. package/coverage/map/api/index.html +0 -131
  452. package/coverage/map/api/index.js.html +0 -139
  453. package/coverage/map/api/marshall.js.html +0 -178
  454. package/coverage/map/api/models/alerts.model.mongodb.js.html +0 -106
  455. package/coverage/map/api/models/catalog.model.mongodb.js.html +0 -169
  456. package/coverage/map/api/models/features.model.mongodb.js.html +0 -196
  457. package/coverage/map/api/models/index.html +0 -176
  458. package/coverage/map/api/models/projects.model.mongodb.js.html +0 -109
  459. package/coverage/map/api/models/styles.model.mongodb.js.html +0 -112
  460. package/coverage/map/api/services/alerts/alerts.hooks.js.html +0 -274
  461. package/coverage/map/api/services/alerts/alerts.service.js.html +0 -610
  462. package/coverage/map/api/services/alerts/index.html +0 -131
  463. package/coverage/map/api/services/catalog/catalog.hooks.js.html +0 -328
  464. package/coverage/map/api/services/catalog/index.html +0 -116
  465. package/coverage/map/api/services/daptiles/daptiles.service.js.html +0 -1510
  466. package/coverage/map/api/services/daptiles/index.html +0 -116
  467. package/coverage/map/api/services/features/features.hooks.js.html +0 -310
  468. package/coverage/map/api/services/features/features.service.js.html +0 -544
  469. package/coverage/map/api/services/features/index.html +0 -131
  470. package/coverage/map/api/services/index.html +0 -116
  471. package/coverage/map/api/services/index.js.html +0 -1054
  472. package/coverage/map/api/services/projects/index.html +0 -116
  473. package/coverage/map/api/services/projects/projects.hooks.js.html +0 -439
  474. package/coverage/map/api/services/styles/index.html +0 -116
  475. package/coverage/map/api/services/styles/styles.hooks.js.html +0 -196
  476. package/coverage/map/common/dynamic-grid-source.js.html +0 -466
  477. package/coverage/map/common/errors.js.html +0 -94
  478. package/coverage/map/common/geotiff-grid-source.js.html +0 -544
  479. package/coverage/map/common/grid.js.html +0 -1612
  480. package/coverage/map/common/index.html +0 -371
  481. package/coverage/map/common/index.js.html +0 -172
  482. package/coverage/map/common/meteo-model-grid-source.js.html +0 -556
  483. package/coverage/map/common/moment-utils.js.html +0 -157
  484. package/coverage/map/common/opendap-grid-source.js.html +0 -868
  485. package/coverage/map/common/opendap-utils.js.html +0 -826
  486. package/coverage/map/common/permissions.js.html +0 -130
  487. package/coverage/map/common/time-based-grid-source.js.html +0 -418
  488. package/coverage/map/common/tms-utils.js.html +0 -274
  489. package/coverage/map/common/wcs-grid-source.js.html +0 -364
  490. package/coverage/map/common/wcs-utils.js.html +0 -586
  491. package/coverage/map/common/weacast-grid-source.js.html +0 -1033
  492. package/coverage/map/common/wfs-utils.js.html +0 -574
  493. package/coverage/map/common/wms-utils.js.html +0 -451
  494. package/coverage/map/common/wmts-utils.js.html +0 -547
  495. package/coverage/prettify.css +0 -1
  496. package/coverage/prettify.js +0 -2
  497. package/coverage/sort-arrow-sprite.png +0 -0
  498. package/coverage/sorter.js +0 -196
  499. package/coverage/tmp/coverage-151198-1753351220086-0.json +0 -1
  500. package/coverage/tmp/coverage-151210-1753351220070-0.json +0 -1
  501. package/coverage/tmp/coverage-151221-1753351129816-0.json +0 -1
  502. package/coverage/tmp/coverage-151233-1753351129803-0.json +0 -1
  503. package/coverage/tmp/coverage-151240-1753351129770-0.json +0 -1
  504. package/coverage/tmp/coverage-151307-1753351220058-0.json +0 -1
  505. package/coverage/tmp/coverage-151319-1753351220044-0.json +0 -1
  506. package/coverage/tmp/coverage-151326-1753351220010-0.json +0 -1
  507. package/extras/tours/core/account-profile.js +0 -32
  508. package/extras/tours/core/account.js +0 -143
  509. package/extras/tours/core/add-member.js +0 -75
  510. package/extras/tours/core/add-tag.js +0 -13
  511. package/extras/tours/core/create-group.js +0 -19
  512. package/extras/tours/core/create-organisation.js +0 -19
  513. package/extras/tours/core/create-tag.js +0 -26
  514. package/extras/tours/core/edit-member-role.js +0 -13
  515. package/extras/tours/core/groups.js +0 -65
  516. package/extras/tours/core/join-group.js +0 -13
  517. package/extras/tours/core/login.js +0 -41
  518. package/extras/tours/core/members.js +0 -108
  519. package/extras/tours/core/register.js +0 -61
  520. package/extras/tours/core/send-reset-password.js +0 -14
  521. package/extras/tours/core/tags.js +0 -65
  522. package/extras/tours/map/catalog-panel.js +0 -112
  523. package/extras/tours/map/fab.js +0 -26
  524. package/extras/tours/map/navigation-bar.js +0 -187
  525. package/extras/tours/map/side-nav.js +0 -36
  526. package/test/api/core/test-log-2025-02-05.log +0 -23
  527. package/test/api/core/test-log-2025-05-21.log +0 -15
  528. package/test/api/core/test-log-2025-06-25.log +0 -9
  529. package/test/api/core/test-log-2025-07-24.log +0 -44
  530. package/test/api/map/test-log-2025-05-27.log +0 -13
  531. package/test/api/map/test-log-2025-06-23.log +0 -7
  532. package/test/api/map/test-log-2025-07-24.log +0 -11
  533. package/test/client/core/api.js +0 -361
  534. package/test/client/core/index.js +0 -9
  535. package/test/client/index.js +0 -4
  536. package/test/client/map/index.js +0 -5
  537. package/test.client.js +0 -1
  538. /package/{test/client/core/time.js → extras/tests/core/time.mjs} +0 -0
  539. /package/extras/tours/{map/add-layer.js → add-layer.js} +0 -0
  540. /package/extras/tours/{map/catalog-categories.js → catalog-categories.js} +0 -0
  541. /package/extras/tours/{map/connect-layer.js → connect-layer.js} +0 -0
  542. /package/extras/tours/{map/create-layer.js → create-layer.js} +0 -0
  543. /package/extras/tours/{map/create-view.js → create-view.js} +0 -0
  544. /package/extras/tours/{map/import-layer.js → import-layer.js} +0 -0
  545. /package/extras/tours/{map/timeline.js → pane.bottom.js} +0 -0
@@ -2,13 +2,13 @@ import L from 'leaflet'
2
2
  import _ from 'lodash'
3
3
  import sift from 'sift'
4
4
  import logger from 'loglevel'
5
- import { point, rhumbDistance, rhumbBearing, rhumbDestination } from '@turf/turf'
6
- import { Time, Units, utils as kdkCoreUtils } from '../../../../core.client.js'
5
+ import { point, rhumbDistance, rhumbBearing, rhumbDestination, getType } from '@turf/turf'
6
+ import { Time, Units, Events, utils as kdkCoreUtils } from '../../../../core.client.js'
7
7
  import { getUpdateFeatureFunction, hasUnitInLeafletLayerTemplate, GeoJsonLeafletLayerFilters } from '../../leaflet/utils/utils.geojson.js'
8
8
  import { MaskLayer } from '../../leaflet/MaskLayer.js'
9
9
  import { TiledFeatureLayer } from '../../leaflet/TiledFeatureLayer.js'
10
10
  import {
11
- fetchGeoJson, LeafletEvents, bindLeafletEvents, unbindLeafletEvents, getFeatureId, isInMemoryLayer, getFeatureStyleType,
11
+ fetchGeoJson, getGeoJsonFeatures, LeafletEvents, bindLeafletEvents, unbindLeafletEvents, getFeatureId, isInMemoryLayer, getFeatureStyleType,
12
12
  convertSimpleStyleToPointStyle, convertSimpleStyleToLineStyle, convertSimpleStyleToPolygonStyle, createMarkerFromPointStyle
13
13
  } from '../../utils.map.js'
14
14
  import * as maths from '../../../../core/client/utils/utils.math.js'
@@ -61,7 +61,7 @@ export const geojsonLayers = {
61
61
  // Use probes as reference
62
62
  const geoJson = await this.getProbeFeatures(options)
63
63
  // When probes are fetched, we flag them with a 'measureRequestIssued' property that we may use in dynamic styling
64
- const features = (geoJson.type === 'FeatureCollection' ? geoJson.features : [geoJson])
64
+ const features = getGeoJsonFeatures(geoJson)
65
65
  features.forEach(feature => { feature.measureRequestIssued = true })
66
66
  successCallback(geoJson)
67
67
  initialized = true
@@ -143,33 +143,92 @@ export const geojsonLayers = {
143
143
  leafletOptions.container = this.createLeafletLayer(clusterOptions)
144
144
  bindLeafletEvents(leafletOptions.container, LeafletEvents.Cluster, this, options)
145
145
  },
146
+ processGeoJsonPaneOptions (options) {
147
+ const leafletOptions = options.leaflet || options
148
+ // Min/Max zoom are automatically managed on tiled layers by inheriting GridLayer
149
+ // but on non-tiled layers we need to use a pane to manage it.
150
+ // However, as we'd like to be able to easily control layer display order we create a pane for each layer by default anyway.
151
+ const panes = _.get(leafletOptions, 'panes', [])
152
+ const defaultPane = _.find(panes, { name: _.get(leafletOptions, 'pane') })
153
+ const hasMinZoom = !!_.get(leafletOptions, 'minZoom')
154
+ const hasMaxZoom = !!_.get(leafletOptions, 'maxZoom')
155
+ const hasZIndex = !!_.get(leafletOptions, 'zIndex')
156
+ const hasPaneZIndex = _.get(defaultPane, 'zIndex')
157
+ const name = options.name
158
+ // Default pane will be automatically used for Leaflet vector layers (ie polygons/lines)
159
+ const layerPane = defaultPane || { name }
160
+ if (hasMinZoom) layerPane.minZoom = _.get(leafletOptions, 'minZoom')
161
+ if (hasMaxZoom) layerPane.maxZoom = _.get(leafletOptions, 'maxZoom')
162
+ if (hasZIndex && !hasPaneZIndex) layerPane.zIndex = _.get(leafletOptions, 'zIndex')
163
+ if (!_.find(panes, { name: layerPane.name })) panes.push(layerPane)
164
+ // Set layer to use its default pane as target
165
+ // Avoid erasing any existing pane, if so the pane should have been created taken into account the layer zIndex up-front
166
+ if (!_.has(leafletOptions, 'pane')) leafletOptions.pane = layerPane.name
167
+ if (!_.has(leafletOptions, 'shadowPane')) leafletOptions.shadowPane = layerPane.name
168
+ // Make default pane available to styles as well as eg shape markers are created from here
169
+ for (const type of ['point', 'line', 'polygon']) {
170
+ _.set(leafletOptions, `style.${type}.pane`, layerPane.name)
171
+ _.set(leafletOptions, `style.${type}.shadowPane`, layerPane.name)
172
+ }
173
+ // If we only use this default pane all elements of a layer will be affected to this pane.
174
+ // We prefer the markers and their shadows to be affected to different panes than others elements like Leaflet does by default.
175
+ // This is notably required if we'd like to be able to control the rendering order of the elements with bringToFront/bringToBack functions.
176
+ // Except if a z-index is specified as in this case the user wants to control the order by himself
177
+ if (!hasZIndex && !hasPaneZIndex) {
178
+ // No z-index means that the pane will use the default for overlays in Leaflet which is 400
179
+ // so that we use the default for markers and shadows in Leaflet as well.
180
+ if (!_.find(panes, { name: `${name}-markers` })) panes.push(Object.assign({ name: `${name}-markers`, zIndex: 600 }, _.omit(layerPane, ['name'])))
181
+ if (!_.find(panes, { name: `${name}-shadows` })) panes.push(Object.assign({ name: `${name}-shadows`, zIndex: 500 }, _.omit(layerPane, ['name'])))
182
+ // Avoid erasing any existing pane, if so the pane should have been created taken into account the layer zIndex up-front
183
+ if (!_.has(leafletOptions, 'shadowPane')) leafletOptions.shadowPane = `${name}-shadows`
184
+ // Make panes available to styles as eg shape markers are created from here
185
+ _.set(leafletOptions, 'style.point.pane', `${name}-markers`)
186
+ _.set(leafletOptions, 'style.point.shadowPane', `${name}-shadows`)
187
+ }
188
+ leafletOptions.panes = panes
189
+ },
190
+ processGeoJsonStyleOptions (options) {
191
+ const leafletOptions = options.leaflet || options
192
+ // Optimize templating by creating compilers up-front
193
+ const layerStyleTemplate = _.get(leafletOptions, 'template')
194
+ if (layerStyleTemplate) {
195
+ // We allow to template style properties according to feature, because it can be slow you have to specify a subset of properties
196
+ leafletOptions.template = layerStyleTemplate.map(property => ({
197
+ property, compiler: _.template(_.get(leafletOptions, property))
198
+ }))
199
+ }
200
+ const popupTemplate = _.get(leafletOptions, 'popup.template')
201
+ if (popupTemplate) {
202
+ leafletOptions.popup.compiler = _.template(popupTemplate)
203
+ }
204
+ const tooltipTemplate = _.get(leafletOptions, 'tooltip.template')
205
+ if (tooltipTemplate) {
206
+ leafletOptions.tooltip.compiler = _.template(tooltipTemplate)
207
+ }
208
+ // Optimize styling by creating color scales up-front
209
+ const variables = _.get(options, 'variables', [])
210
+ variables.forEach(variable => {
211
+ if (_.has(variable, 'chromajs')) {
212
+ variable.colorScale = kdkCoreUtils.buildColorScale(_.get(variable, 'chromajs'))
213
+ }
214
+ })
215
+ // Convert and store the style
216
+ if (leafletOptions.style) {
217
+ leafletOptions.layerPointStyle = _.get(leafletOptions.style, 'point')
218
+ leafletOptions.layerLineStyle = _.get(leafletOptions.style, 'line')
219
+ leafletOptions.layerPolygonStyle = _.get(leafletOptions.style, 'polygon')
220
+ } else {
221
+ leafletOptions.layerPointStyle = convertSimpleStyleToPointStyle(leafletOptions)
222
+ leafletOptions.layerLineStyle = convertSimpleStyleToLineStyle(leafletOptions)
223
+ leafletOptions.layerPolygonStyle = convertSimpleStyleToPolygonStyle(leafletOptions)
224
+ }
225
+ },
146
226
  async createLeafletGeoJsonLayer (options) {
147
227
  const leafletOptions = options.leaflet || options
148
228
  // Check for valid type
149
229
  if (leafletOptions.type !== 'geoJson') return
150
230
 
151
231
  try {
152
- // min/max zoom are automatically managed on tiled layers by inheriting GridLayer
153
- // on non-tiled layers we need to use a pane to manage it
154
- const hasMinZoom = !!_.get(leafletOptions, 'minZoom')
155
- const hasMaxZoom = !!_.get(leafletOptions, 'maxZoom')
156
- const hasZIndex = !!_.get(leafletOptions, 'zIndex')
157
- if (!leafletOptions.tiled && (hasMinZoom || hasMaxZoom)) {
158
- const pane = { name: options.name }
159
- if (hasMinZoom) pane.minZoom = _.get(leafletOptions, 'minZoom')
160
- if (hasMaxZoom) pane.maxZoom = _.get(leafletOptions, 'maxZoom')
161
- if (hasZIndex) pane.zIndex = _.get(leafletOptions, 'zIndex')
162
- leafletOptions.panes = [pane]
163
- leafletOptions.pane = options.name
164
- leafletOptions.shadowPane = options.name
165
- // Make pane available to styles as well as eg shape markers are created from here
166
- for (const type of ['point', 'line', 'polygon']) {
167
- if (_.has(leafletOptions, `style.${type}`)) {
168
- _.set(leafletOptions, `style.${type}.pane`, options.name)
169
- _.set(leafletOptions, `style.${type}.shadowPane`, options.name)
170
- }
171
- }
172
- }
173
232
  // If not explicitely disable use defaults for clustering
174
233
  if (!_.has(leafletOptions, 'cluster') && _.get(this, 'activityOptions.engine.cluster')) {
175
234
  // Merge existing config or create a new one on layer
@@ -186,39 +245,9 @@ export const geojsonLayers = {
186
245
  } else {
187
246
  await this.processGeoJsonLayerOptions(options)
188
247
  }
189
- // Optimize templating by creating compilers up-front
190
- const layerStyleTemplate = _.get(leafletOptions, 'template')
191
- if (layerStyleTemplate) {
192
- // We allow to template style properties according to feature, because it can be slow you have to specify a subset of properties
193
- leafletOptions.template = layerStyleTemplate.map(property => ({
194
- property, compiler: _.template(_.get(leafletOptions, property))
195
- }))
196
- }
197
- const popupTemplate = _.get(leafletOptions, 'popup.template')
198
- if (popupTemplate) {
199
- leafletOptions.popup.compiler = _.template(popupTemplate)
200
- }
201
- const tooltipTemplate = _.get(leafletOptions, 'tooltip.template')
202
- if (tooltipTemplate) {
203
- leafletOptions.tooltip.compiler = _.template(tooltipTemplate)
204
- }
205
- // Optimize styling by creating color scales up-front
206
- const variables = _.get(options, 'variables', [])
207
- variables.forEach(variable => {
208
- if (_.has(variable, 'chromajs')) {
209
- variable.colorScale = kdkCoreUtils.buildColorScale(_.get(variable, 'chromajs'))
210
- }
211
- })
212
- // Convert and store the style
213
- if (leafletOptions.style) {
214
- leafletOptions.layerPointStyle = _.get(leafletOptions.style, 'point')
215
- leafletOptions.layerLineStyle = _.get(leafletOptions.style, 'line')
216
- leafletOptions.layerPolygonStyle = _.get(leafletOptions.style, 'polygon')
217
- } else {
218
- leafletOptions.layerPointStyle = convertSimpleStyleToPointStyle(leafletOptions)
219
- leafletOptions.layerLineStyle = convertSimpleStyleToLineStyle(leafletOptions)
220
- leafletOptions.layerPolygonStyle = convertSimpleStyleToPolygonStyle(leafletOptions)
221
- }
248
+ this.processGeoJsonStyleOptions(options)
249
+ // Do this after style because it may alter it
250
+ this.processGeoJsonPaneOptions(options)
222
251
  // Merge generic GeoJson options and layer options
223
252
  const geoJsonOptions = this.getGeoJsonOptions(options)
224
253
  Object.keys(geoJsonOptions).forEach(key => {
@@ -247,13 +276,6 @@ export const geojsonLayers = {
247
276
  }
248
277
  // Bind event
249
278
  layer.on('update', (data) => this.onLayerUpdated(options, layer, data))
250
- if (leafletOptions.container) layer.once('add', () => leafletOptions.container.addTo(this.map))
251
- // Add FeatureGroup interface so that layer edition works as well
252
- layer.toGeoJSON = () => ({ type: 'FeatureCollection', features: _.values(layer._features) })
253
- layer.clearLayers = () => layer._onNewData(true, { type: 'FeatureCollection', features: [] })
254
- layer.getLayers = () => _.values(layer._featureLayers)
255
- layer.addLayer = (geoJsonLayer) => layer._onNewData(false, geoJsonLayer.toGeoJSON())
256
- layer.removeLayer = (geoJsonLayer) => layer.remove(geoJsonLayer.toGeoJSON())
257
279
  // We launch a first update to initialize data
258
280
  layer.update()
259
281
  } else {
@@ -309,10 +331,10 @@ export const geojsonLayers = {
309
331
  logger.warn(`[KDK] cannot get a style type from the feature of geometry type ${feature.geometry.type}`)
310
332
  return
311
333
  }
312
- return this.generateStyle(styleType, feature, options, _.get(this, 'activityOptions.engine'))
334
+ return this.generateStyle(styleType, feature, options, _.get(this, `activityOptions.engine.style.${styleType}`), this.map.getZoom())
313
335
  },
314
336
  pointToLayer: (feature, latlng) => {
315
- const style = this.generateStyle('point', feature, options, _.get(this, 'activityOptions.engine'))
337
+ const style = this.generateStyle('point', feature, options, _.get(this, 'activityOptions.engine.style.point'), this.map.getZoom())
316
338
  if (!style) {
317
339
  logger.warn('[KDK] cannot generate point style from a feature')
318
340
  return
@@ -325,16 +347,24 @@ export const geojsonLayers = {
325
347
  getUpdateAnimation(name, layer, options, geoJson) {
326
348
  const { duration, removeMissing, animate } = options
327
349
  const animatedProperties = _.keys(animate)
328
- const features = (Array.isArray(geoJson) ? geoJson : (geoJson.type === 'FeatureCollection' ? geoJson.features : [geoJson]))
350
+ animatedProperties.forEach(property => {
351
+ _.defaultsDeep(animate, {
352
+ [property]: { easing: { function: 'linear' }, bearing: false }
353
+ })
354
+ })
355
+ const features = getGeoJsonFeatures(geoJson)
329
356
  features.forEach(feature => {
330
357
  const previousLayer = layer.getLayer(layer.options.getFeatureId(feature))
331
358
  const previousFeature = (previousLayer ? previousLayer.feature : null)
332
359
  if (previousFeature) {
333
- Object.assign(feature, { previousFeature })
334
- const startLongitude = _.get(feature.previousFeature, 'geometry.coordinates[0]')
335
- const startLatitude = _.get(feature.previousFeature, 'geometry.coordinates[1]')
336
- const endLongitude = _.get(feature, 'geometry.coordinates[0]')
337
- const endLatitude = _.get(feature, 'geometry.coordinates[1]')
360
+ // Remove reference to previous feature otherwise it will create a reference tree that will grow as timle passes by
361
+ // and that will never be clear by garbage collector unless the layer is destroyed
362
+ delete previousFeature['previousFeature']
363
+ feature.previousFeature = previousFeature
364
+ const startLongitude = feature.previousFeature.geometry.coordinates[0]
365
+ const startLatitude = feature.previousFeature.geometry.coordinates[1]
366
+ const endLongitude = feature.geometry.coordinates[0]
367
+ const endLatitude = feature.geometry.coordinates[1]
338
368
  const rhumbStart = point([startLongitude, startLatitude])
339
369
  const rhumbEnd = point([endLongitude, endLatitude])
340
370
  Object.assign(feature, {
@@ -345,12 +375,29 @@ export const geojsonLayers = {
345
375
  })
346
376
  }
347
377
  })
378
+ // Note: as this callback is called frequently by the animation system
379
+ // we don't use lodash utility functions like _.get/_.set to improve performances
348
380
  return (timestamp) => {
349
381
  // Initialize animation time origin
350
382
  if (!options.startTime) options.startTime = timestamp
351
- const { id, startTime } = options
352
- const elapsed = timestamp - startTime
353
- const percent = Math.abs(elapsed / (1000 * duration))
383
+ const { id, startTime, fps } = options
384
+ const elapsedSinceStart = timestamp - startTime
385
+ // If we target a specific frame rate check if we need to update or not
386
+ if (fps && options.lastTime) {
387
+ const elapsedSinceLastFrame = timestamp - options.lastTime
388
+ const fpsInterval = 1000 / fps
389
+ if (elapsedSinceLastFrame < fpsInterval) {
390
+ options.id = requestAnimationFrame(options.step)
391
+ // For debug purpose only, avoid flooding the browser
392
+ //logger.debug('[KDK] Skipping update layer animation frame')
393
+ return
394
+ } else {
395
+ // For debug purpose only, avoid floodign the browser
396
+ //logger.debug('[KDK] Drawing update layer animation frame')
397
+ }
398
+ }
399
+ // Else animate if animation not yet finished
400
+ const percent = Math.abs(elapsedSinceStart / (1000 * duration))
354
401
  if (percent <= 1) {
355
402
  const animatedFeatures = []
356
403
  features.forEach(feature => {
@@ -358,54 +405,61 @@ export const geojsonLayers = {
358
405
  animatedFeatures.push(feature)
359
406
  return
360
407
  }
361
- const endLongitude = _.get(feature, 'geometry.coordinates[0]')
362
- const endLatitude = _.get(feature, 'geometry.coordinates[1]')
408
+ const endLongitude = feature.geometry.coordinates[0]
409
+ const endLatitude = feature.geometry.coordinates[1]
363
410
  let dLongitude = endLongitude, dLatitude = endLatitude
364
411
  if (animate.geometry) {
365
- const easingGeometryFunction = _.get(animate.geometry, 'easing.function')
366
- const easingGeometryParameters = _.get(animate.geometry, 'easing.parameters', [])
412
+ const easingGeometryFunction = animate.geometry.easing.function
413
+ const easingGeometryParameters = animate.geometry.easing.parameters || []
367
414
  const percentGeometry = maths[easingGeometryFunction](percent, ...easingGeometryParameters)
368
415
  if (animate.geometry.rhumb) {
369
416
  const destination = rhumbDestination(feature.rhumbStart, percentGeometry * feature.rhumbDistance, feature.rhumbBearing)
370
- dLongitude = _.get(destination, 'geometry.coordinates[0]')
371
- dLatitude = _.get(destination, 'geometry.coordinates[1]')
417
+ dLongitude = destination.geometry.coordinates[0]
418
+ dLatitude = destination.geometry.coordinates[1]
372
419
  } else {
373
- const startLongitude = _.get(feature.previousFeature, 'geometry.coordinates[0]')
374
- const startLatitude = _.get(feature.previousFeature, 'geometry.coordinates[1]')
375
- const dLongitude = startLongitude + percentGeometry * (endLongitude - startLongitude)
376
- const dLatitude = startLatitude + percentGeometry * (endLatitude - startLatitude)
420
+ const startLongitude = feature.previousFeature.geometry.coordinates[0]
421
+ const startLatitude = feature.previousFeature.geometry.coordinates[1]
422
+ dLongitude = startLongitude + percentGeometry * (endLongitude - startLongitude)
423
+ dLatitude = startLatitude + percentGeometry * (endLatitude - startLatitude)
377
424
  }
378
425
  }
379
426
  const properties = {}
427
+ const previousFeatureProperties = feature.previousFeature.properties || {}
428
+ const featureProperties = feature.properties || {}
380
429
  animatedProperties.forEach(property => {
381
430
  // Skip geometry as specifically managed above
382
431
  if (property === 'geometry') return
383
- const easingPropertyFunction = _.get(animate, `${property}.easing.function`, 'cubicBezier')
384
- const easingPropertyParameters = _.get(animate, `${property}.easing.parameters`, [])
432
+ const animateProperty = animate[property]
433
+ const easingPropertyFunction = animateProperty.easing.function
434
+ const easingPropertyParameters = animateProperty.easing.parameters || []
385
435
  const percentProperty = maths[easingPropertyFunction](percent, ...easingPropertyParameters)
386
- const startValue = _.get(feature.previousFeature, `properties.${property}`)
387
- const endValue = _.get(feature, `properties.${property}`)
436
+ const startValue = previousFeatureProperties[property]
437
+ const endValue = featureProperties[property]
388
438
  let dValue = startValue + percentProperty * (endValue - startValue)
389
- if (_.get(animate, `${property}.bearing`, false)) {
439
+ if (animateProperty.bearing) {
390
440
  // Take care to animate using the shortest "path", eg from 355° to 5° avoid running counterclockwise
391
441
  // First computes the smallest angle difference, either clockwise or counterclockwise.
392
442
  const bearingDifference = (endValue - startValue + 540) % 360 - 180
393
443
  // Then normalize the final result to be between 0 and 360
394
444
  dValue = (startValue + percentProperty * bearingDifference + 360) % 360
395
445
  }
396
- _.set(properties, property, dValue)
446
+ properties[property] = dValue
397
447
  })
398
- animatedFeatures.push(_.defaultsDeep({
448
+ animatedFeatures.push({
449
+ type: feature.type,
399
450
  geometry: {
451
+ type: feature.geometry.type,
400
452
  coordinates: [dLongitude, dLatitude]
401
453
  },
402
- properties
403
- }, feature))
454
+ properties: Object.assign({}, featureProperties, properties),
455
+ style: feature.style
456
+ })
404
457
  })
405
458
  layer._onNewData(_.isNil(removeMissing) ? layer.options.removeMissing : removeMissing, animatedFeatures)
459
+ options.lastTime = timestamp
406
460
  options.id = requestAnimationFrame(options.step)
407
461
  } else {
408
- options.id = null
462
+ delete options.id
409
463
  }
410
464
  }
411
465
  },
@@ -417,12 +471,12 @@ export const geojsonLayers = {
417
471
  logger.warn(`Impossible to update non-realtime layer ${name}`)
418
472
  return // Cannot update non-realtime layer
419
473
  }
420
-
421
474
  const replace = _.get(options, 'replace', false)
422
475
  if (replace) {
423
476
  // Replace given features, we first remove them to add them back afterwards
424
477
  this.updateLayer(name, geoJson, { remove: true })
425
- this.updateLayer(name, geoJson)
478
+ // Avoid infinite regression by removing the replace option
479
+ this.updateLayer(name, geoJson, _.omit(options, ['replace']))
426
480
  } else {
427
481
  // Backward compatibility when third parameter was the remove flag
428
482
  const remove = (typeof options === 'boolean' ? options : options.remove)
@@ -439,26 +493,39 @@ export const geojsonLayers = {
439
493
  */
440
494
  if (remove) {
441
495
  if (typeof layer.remove !== 'function') return
442
- let features = (geoJson.type === 'FeatureCollection' ? geoJson.features : [geoJson])
496
+ let features = getGeoJsonFeatures(geoJson)
443
497
  // Filter features to ensure some have not been already removed
444
498
  // FIXME: indeed it seems to causes a bug with clustering, see https://github.com/kalisio/kdk/issues/140
445
499
  features = features.filter(feature => layer.getLayer(layer.options.getFeatureId(feature)))
446
500
  layer.remove(features)
447
501
  } else if (geoJson) {
448
502
  if (typeof layer._onNewData === 'function') {
449
- const duration = _.get(options, 'duration', 0)
503
+ let duration = _.get(options, 'duration', 0)
504
+ const features = (Array.isArray(geoJson) ? geoJson : (geoJson.type === 'FeatureCollection' ? geoJson.features : [geoJson]))
505
+ // Nothing to animate in this case
506
+ if (duration && (features.length === 0)) {
507
+ duration = 0
508
+ }
509
+ if (duration && _.some(features, feature => (getType(feature) !== 'Point'))) {
510
+ logger.warn(`Impossible to animate layer ${name} as it does not contain only point geometries`)
511
+ duration = 0
512
+ }
450
513
  if (duration) {
514
+ // For debug purpose only, avoid flooding the browser
515
+ //logger.debug(`Calling updateLayer(${name}) with`, options)
451
516
  _.defaultsDeep(options, {
452
517
  animate: {
453
- geometry: { easing: { function: 'cubicBezier' }, rhumb: true }
518
+ geometry: { easing: { function: 'linear' }, rhumb: false }
454
519
  }
455
520
  })
456
521
  // Stop any scheduled animation on the same layer
457
- if (_.has(this.updateAnimations, `${name}.id`)) cancelAnimationFrame(_.get(this.updateAnimations, `${name}.id`))
522
+ const frameId = _.get(this.updateAnimations, `${name}.id`)
523
+ if (!_.isNil(frameId)) cancelAnimationFrame(frameId)
458
524
  options.step = this.getUpdateAnimation(name, layer, options, geoJson)
459
525
  options.id = requestAnimationFrame(options.step)
460
526
  _.set(this.updateAnimations, name, options)
461
527
  } else {
528
+ _.unset(this.updateAnimations, name)
462
529
  layer._onNewData(removeMissing, geoJson)
463
530
  }
464
531
  }
@@ -577,6 +644,12 @@ export const geojsonLayers = {
577
644
  }
578
645
  }
579
646
  },
647
+ onEditStopGeoJsonLayers ({ status, layer }) {
648
+ // Check if we have to cache/update geojson data for this layer
649
+ if (isInMemoryLayer(layer)) {
650
+ this.geojsonCache[layer.name] = this.toGeoJson(layer.name)
651
+ }
652
+ },
580
653
  onLayerRemovedGeoJsonLayers (layer) {
581
654
  // Remove cached geojson data if any
582
655
  if (_.has(this.geojsonCache, layer.name)) {
@@ -586,11 +659,12 @@ export const geojsonLayers = {
586
659
  },
587
660
  created () {
588
661
  this.registerLeafletConstructor(this.createLeafletGeoJsonLayer)
589
- this.$events.on('time-current-time-changed', this.onCurrentTimeChangedGeoJsonLayers)
662
+ Events.on('time-current-time-changed', this.onCurrentTimeChangedGeoJsonLayers)
590
663
  this.$engineEvents.on('selected-level-changed', this.onCurrentLevelChangedGeoJsonLayers)
591
- this.$events.on('units-changed', this.onDefaultUnitChangedGeoJsonLayers)
664
+ Events.on('units-changed', this.onDefaultUnitChangedGeoJsonLayers)
592
665
  this.$engineEvents.on('zoomend', this.onMapZoomChangedGeoJsonLayers)
593
666
  this.$engineEvents.on('layer-shown', this.onLayerShownGeoJsonLayers)
667
+ this.$engineEvents.on('edit-stop', this.onEditStopGeoJsonLayers)
594
668
  this.$engineEvents.on('layer-removed', this.onLayerRemovedGeoJsonLayers)
595
669
 
596
670
  // Used to store animation options when animating a layer
@@ -599,11 +673,12 @@ export const geojsonLayers = {
599
673
  this.geojsonCache = {}
600
674
  },
601
675
  beforeUnmount () {
602
- this.$events.off('time-current-time-changed', this.onCurrentTimeChangedGeoJsonLayers)
676
+ Events.off('time-current-time-changed', this.onCurrentTimeChangedGeoJsonLayers)
603
677
  this.$engineEvents.off('selected-level-changed', this.onCurrentLevelChangedGeoJsonLayers)
604
- this.$events.off('units-changed', this.onDefaultUnitChangedGeoJsonLayers)
678
+ Events.off('units-changed', this.onDefaultUnitChangedGeoJsonLayers)
605
679
  this.$engineEvents.off('zoomend', this.onMapZoomChangedGeoJsonLayers)
606
680
  this.$engineEvents.off('layer-shown', this.onLayerShownGeoJsonLayers)
681
+ this.$engineEvents.off('edit-stop', this.onEditStopGeoJsonLayers)
607
682
  this.$engineEvents.off('layer-removed', this.onLayerRemovedGeoJsonLayers)
608
683
 
609
684
  this.geojsonCache = {}
@@ -4,6 +4,7 @@ import sift from 'sift'
4
4
  import centroid from '@turf/centroid'
5
5
  import HeatmapOverlay from 'leaflet-heatmap'
6
6
  import { Time } from '../../../../core/client/time.js'
7
+ import { Events } from '../../../../core/client/events.js'
7
8
  import { fetchGeoJson } from '../../utils/utils.features.js'
8
9
 
9
10
  export const heatmapLayers = {
@@ -103,10 +104,10 @@ export const heatmapLayers = {
103
104
  },
104
105
  created () {
105
106
  this.registerLeafletConstructor(this.createLeafletHeatmapLayer)
106
- this.$events.on('time-current-time-changed', this.onCurrentTimeChangedHeatmapLayers)
107
+ Events.on('time-current-time-changed', this.onCurrentTimeChangedHeatmapLayers)
107
108
  },
108
109
  beforeUnmount () {
109
- this.$events.off('time-current-time-changed', this.onCurrentTimeChangedHeatmapLayers)
110
+ Events.off('time-current-time-changed', this.onCurrentTimeChangedHeatmapLayers)
110
111
  }
111
112
  }
112
113
 
@@ -1,3 +1,5 @@
1
+ import _ from 'lodash'
2
+
1
3
  export const activity = {
2
4
  methods: {
3
5
  async initializeMap (container) {
@@ -11,7 +13,10 @@ export const activity = {
11
13
  },
12
14
  storeView () {
13
15
  // Check if the activity is using context restoration
14
- if (typeof this.storeContext === 'function') this.storeContext('view')
16
+ if (typeof this.storeContext === 'function') {
17
+ // Do not store context on each animation frame to avoid too much CPU consumption
18
+ if (!_.get(this.centerAnimation, 'id')) this.storeContext('view')
19
+ }
15
20
  },
16
21
  onMapResized (size) {
17
22
  // Avoid to refresh the layout when leaving the component
@@ -1,5 +1,6 @@
1
1
  import _ from 'lodash'
2
2
  import logger from 'loglevel'
3
+ import { Store } from '../../../../core/client/index.js'
3
4
  import { LeafletEvents, bindLeafletEvents } from '../../utils.map.js'
4
5
 
5
6
  export const mapillaryLayers = {
@@ -34,7 +35,7 @@ export const mapillaryLayers = {
34
35
  },
35
36
  created () {
36
37
  // Check whether the token is initialized
37
- this.mapillaryToken = this.$store.get('capabilities.api.mapillary.token')
38
+ this.mapillaryToken = Store.get('capabilities.api.mapillary.token')
38
39
  if (!this.mapillaryToken) {
39
40
  logger.warn('You must provide a client token to use Mapillary')
40
41
  return
@@ -5,7 +5,7 @@ import sift from 'sift'
5
5
  import L from 'leaflet'
6
6
  import * as protomaps from 'protomaps-leaflet'
7
7
  import { mapbox_style } from '@kalisio/leaflet-pmtiles'
8
- import { api, Time, Units, TemplateContext } from '../../../../core/client/index.js'
8
+ import { api, Time, Units, Events, TemplateContext } from '../../../../core/client/index.js'
9
9
 
10
10
  export const pmtilesLayers = {
11
11
  methods: {
@@ -104,11 +104,11 @@ export const pmtilesLayers = {
104
104
  },
105
105
  created () {
106
106
  this.registerLeafletConstructor(this.createLeafletPMTilesLayer)
107
- this.$events.on('time-current-time-changed', this.onCurrentTimeChangedPMTilesLayers)
107
+ Events.on('time-current-time-changed', this.onCurrentTimeChangedPMTilesLayers)
108
108
  this.$engineEvents.on('selected-level-changed', this.onCurrentLevelChangedPMTilesLayers)
109
109
  },
110
110
  beforeUnmount () {
111
- this.$events.off('time-current-time-changed', this.onCurrentTimeChangedPMTilesLayers)
111
+ Events.off('time-current-time-changed', this.onCurrentTimeChangedPMTilesLayers)
112
112
  this.$engineEvents.off('selected-level-changed', this.onCurrentLevelChangedPMTilesLayers)
113
113
  }
114
114
  }
@@ -1,5 +1,6 @@
1
1
  import _ from 'lodash'
2
2
  import { Time } from '../../../../core/client/time.js'
3
+ import { Events } from '../../../../core/client/events.js'
3
4
  import { makeGridSource, extractGridSourceConfig } from '../../../common/grid.js'
4
5
  import { TiledMeshLayer } from '../../leaflet/TiledMeshLayer.js'
5
6
 
@@ -106,7 +107,7 @@ export const tiledMeshLayers = {
106
107
  this.$engineEvents.on('layer-hidden', this.onHideTiledMeshLayer)
107
108
  this.$engineEvents.on('selected-level-changed', this.onSelectedLevelChangedTiledMeshLayer)
108
109
  this.$engineEvents.on('forecast-model-changed', this.onForecastModelChangedTiledMeshLayer)
109
- this.$events.on('time-current-time-changed', this.onCurrentTimeChangedTiledMeshLayer)
110
+ Events.on('time-current-time-changed', this.onCurrentTimeChangedTiledMeshLayer)
110
111
  },
111
112
 
112
113
  beforeUnmount () {
@@ -115,6 +116,6 @@ export const tiledMeshLayers = {
115
116
  this.$engineEvents.off('layer-hidden', this.onHideTiledMeshLayer)
116
117
  this.$engineEvents.off('selected-level-changed', this.onSelectedLevelChangedTiledMeshLayer)
117
118
  this.$engineEvents.off('forecast-model-changed', this.onForecastModelChangedTiledMeshLayer)
118
- this.$events.off('time-current-time-changed', this.onCurrentTimeChangedTiledMeshLayer)
119
+ Events.off('time-current-time-changed', this.onCurrentTimeChangedTiledMeshLayer)
119
120
  }
120
121
  }
@@ -1,6 +1,7 @@
1
1
  import _ from 'lodash'
2
2
  import 'leaflet-velocity'
3
3
  import { Time } from '../../../../core/client/time.js'
4
+ import { Events } from '../../../../core/client/events.js'
4
5
  import { makeGridSource, extractGridSourceConfig } from '../../../common/grid.js'
5
6
  import { TiledWindLayer } from '../../leaflet/TiledWindLayer.js'
6
7
 
@@ -115,7 +116,7 @@ export const tiledWindLayers = {
115
116
  this.$engineEvents.on('layer-hidden', this.onHideTiledWindLayer)
116
117
  this.$engineEvents.on('selected-level-changed', this.onSelectedLevelChangedTiledWindLayer)
117
118
  this.$engineEvents.on('forecast-model-changed', this.onForecastModelChangedTiledWindLayer)
118
- this.$events.on('time-current-time-changed', this.onCurrentTimeChangedTiledWindLayer)
119
+ Events.on('time-current-time-changed', this.onCurrentTimeChangedTiledWindLayer)
119
120
  },
120
121
 
121
122
  beforeUnmount () {
@@ -124,6 +125,6 @@ export const tiledWindLayers = {
124
125
  this.$engineEvents.off('layer-hidden', this.onHideTiledWindLayer)
125
126
  this.$engineEvents.off('selected-level-changed', this.onSelectedLevelChangedTiledWindLayer)
126
127
  this.$engineEvents.off('forecast-model-changed', this.onForecastModelChangedTiledWindLayer)
127
- this.$events.off('time-current-time-changed', this.onCurrentTimeChangedTiledWindLayer)
128
+ Events.off('time-current-time-changed', this.onCurrentTimeChangedTiledWindLayer)
128
129
  }
129
130
  }