@geode/opengeodeweb-front 10.34.0-rc.9 → 10.34.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 (282) hide show
  1. package/{server → .build/server}/utils/app_config.js +10 -9
  2. package/{server → .build/server}/utils/cleanup.js +31 -17
  3. package/{server → .build/server}/utils/cloud.js +1 -4
  4. package/{server → .build/server}/utils/microservices.js +21 -9
  5. package/{server → .build/server}/utils/path.js +4 -4
  6. package/{server → .build/server}/utils/scripts.js +9 -9
  7. package/.build/server/utils/server_config.js +51 -0
  8. package/.build/server/utils/stream.js +6 -0
  9. package/{server → .build/server}/utils/ws_client.js +18 -3
  10. package/{shared → .build/shared}/scripts.js +10 -10
  11. package/.build/shared/utils/call_raw.js +31 -0
  12. package/{shared → .build/shared}/utils/call_schema.js +2 -2
  13. package/.build/shared/utils/fetch_raw.js +52 -0
  14. package/{shared → .build/shared}/utils/fetch_schema.js +2 -2
  15. package/{shared → .build/shared}/utils/file.js +3 -1
  16. package/{shared → .build/shared}/utils/response_handlers/load.js +10 -7
  17. package/{shared → .build/shared}/utils/validate_schema.js +1 -1
  18. package/app/components/ActionButton.vue +6 -6
  19. package/app/components/CameraManager/List.vue +5 -5
  20. package/app/components/CameraManager/Saver.vue +3 -5
  21. package/app/components/CameraManager.vue +6 -4
  22. package/app/components/CameraOrientation.vue +12 -12
  23. package/app/components/ClippingPlaneCard.vue +4 -2
  24. package/app/components/ClippingPlanes.vue +8 -8
  25. package/app/components/CrsSelector.vue +9 -10
  26. package/app/components/DeleteDialog.vue +4 -2
  27. package/app/components/DragAndDrop.vue +10 -12
  28. package/app/components/DragAndDropInternal/DragAndDropInline.vue +4 -2
  29. package/app/components/ExtensionSelector.vue +4 -4
  30. package/app/components/FeedBack/ErrorBanner.vue +3 -1
  31. package/app/components/FeedBack/Snackers.vue +4 -3
  32. package/app/components/FileSelector.vue +10 -8
  33. package/app/components/FileUploader.vue +11 -11
  34. package/app/components/GlassCard.vue +1 -1
  35. package/app/components/HybridRenderingView.vue +7 -5
  36. package/app/components/HybridViewerTooltip.vue +7 -7
  37. package/app/components/Launcher.vue +1 -1
  38. package/app/components/Loading/EcoMessages.vue +9 -3
  39. package/app/components/Loading.vue +2 -2
  40. package/app/components/MissingFilesSelector.vue +12 -10
  41. package/app/components/ObjectSelector.vue +10 -9
  42. package/app/components/PackagesVersions.vue +6 -5
  43. package/app/components/Recaptcha.vue +3 -3
  44. package/app/components/RemoteRenderingView.vue +6 -7
  45. package/app/components/Ruler.vue +3 -3
  46. package/app/components/Screenshot.vue +6 -6
  47. package/app/components/SearchBar.vue +4 -2
  48. package/app/components/ShrinkFilter.vue +7 -7
  49. package/app/components/Step.vue +6 -5
  50. package/app/components/Stepper.vue +4 -3
  51. package/app/components/ToolPanel.vue +6 -3
  52. package/app/components/ViewToolbar.vue +25 -28
  53. package/app/components/Viewer/ContextMenu/CenterButton.vue +7 -5
  54. package/app/components/Viewer/ContextMenu/CircularItems.vue +3 -3
  55. package/app/components/Viewer/ContextMenu/ContextMenu.vue +22 -19
  56. package/app/components/Viewer/ContextMenu/ContextMenuItem.vue +10 -8
  57. package/app/components/Viewer/ContextMenu/InfoCard.vue +11 -12
  58. package/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +13 -17
  59. package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +11 -15
  60. package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +12 -16
  61. package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +8 -12
  62. package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +11 -15
  63. package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +11 -15
  64. package/app/components/Viewer/Generic/Model/BlocksOptions.vue +67 -38
  65. package/app/components/Viewer/Generic/Model/CornersOptions.vue +53 -23
  66. package/app/components/Viewer/Generic/Model/EdgesOptions.vue +1 -3
  67. package/app/components/Viewer/Generic/Model/LinesOptions.vue +67 -38
  68. package/app/components/Viewer/Generic/Model/ModelStyleCard.vue +31 -15
  69. package/app/components/Viewer/Generic/Model/ModelStyleOptions.vue +2 -3
  70. package/app/components/Viewer/Generic/Model/PointsOptions.vue +6 -6
  71. package/app/components/Viewer/Generic/Model/SurfacesOptions.vue +69 -38
  72. package/app/components/Viewer/ObjectTree/Base/CommonTreeView.vue +64 -46
  73. package/app/components/Viewer/ObjectTree/Base/Controls.vue +5 -5
  74. package/app/components/Viewer/ObjectTree/Base/ItemLabel.vue +13 -9
  75. package/app/components/Viewer/ObjectTree/Base/StickyHeader.vue +5 -5
  76. package/app/components/Viewer/ObjectTree/Base/TreeRow.vue +10 -10
  77. package/app/components/Viewer/ObjectTree/Box.vue +6 -4
  78. package/app/components/Viewer/ObjectTree/Layout.vue +23 -21
  79. package/app/components/Viewer/ObjectTree/Views/GlobalObjects.vue +14 -14
  80. package/app/components/Viewer/ObjectTree/Views/{ModelCollections.vue → ModelTree.vue} +59 -24
  81. package/app/components/Viewer/Options/AttributeColorBar.vue +4 -2
  82. package/app/components/Viewer/Options/AttributeRangeSelector.vue +4 -2
  83. package/app/components/Viewer/Options/AttributeSelector.vue +7 -9
  84. package/app/components/Viewer/Options/ColorMapList.vue +15 -13
  85. package/app/components/Viewer/Options/ColorMapPicker.vue +4 -4
  86. package/app/components/Viewer/Options/ColorPicker.vue +223 -41
  87. package/app/components/Viewer/Options/ColoringTypeSelector.vue +16 -16
  88. package/app/components/Viewer/Options/ColormapQuickPicker.vue +7 -5
  89. package/app/components/Viewer/Options/OptionsSection.vue +1 -1
  90. package/app/components/Viewer/Options/TextureItem.vue +8 -6
  91. package/app/components/Viewer/Options/TexturesSelector.vue +1 -1
  92. package/app/components/Viewer/OverlappingObjectsPicker.vue +8 -9
  93. package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +2 -6
  94. package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +12 -16
  95. package/app/components/Viewer/Surface/PolygonsOptions.vue +12 -16
  96. package/app/components/Viewer/Ui.vue +2 -2
  97. package/app/components/Wrapper.vue +1 -4
  98. package/app/components/ZScaling.vue +5 -3
  99. package/app/components/csv-preview/CsvPreviewer.vue +38 -37
  100. package/app/components/csv-preview/CsvSettings.vue +6 -4
  101. package/app/components/csv-preview/CsvTable.vue +1 -1
  102. package/app/composables/batch_style.ts +5 -6
  103. package/app/composables/clipping_planes_widget.ts +73 -181
  104. package/app/composables/clipping_planes_widget_entries.ts +189 -0
  105. package/app/composables/copy_to_clipboard.ts +7 -0
  106. package/app/composables/global_attribute_style.ts +163 -83
  107. package/app/composables/hover_highlight.ts +46 -14
  108. package/app/composables/model_collections.ts +26 -13
  109. package/app/composables/model_components.ts +26 -13
  110. package/app/composables/project_manager.ts +76 -19
  111. package/app/composables/responsive_middle_truncate.ts +13 -13
  112. package/app/composables/stepper_tree.ts +34 -11
  113. package/app/composables/tree_filter.ts +66 -44
  114. package/app/composables/tree_keyboard_nav.ts +25 -11
  115. package/app/composables/tree_scroll.ts +44 -14
  116. package/app/composables/use_adaptive_styles.ts +66 -23
  117. package/app/composables/use_overlapping_picker.ts +66 -16
  118. package/app/composables/use_quick_colormap.ts +16 -5
  119. package/app/composables/virtual_tree.ts +75 -43
  120. package/app/composables/vtk_implicit_plane_widget.d.ts +2 -0
  121. package/app/plugins/auto_store_register.ts +2 -7
  122. package/app/plugins/click_outside_ignore_snackbars.client.ts +39 -0
  123. package/app/stores/app.ts +57 -192
  124. package/app/stores/app_helpers/extension.ts +179 -0
  125. package/app/stores/back.ts +37 -21
  126. package/app/stores/camera_manager.ts +22 -20
  127. package/app/stores/cloud.ts +17 -13
  128. package/app/stores/data.ts +88 -47
  129. package/app/stores/data_helpers/collections.ts +36 -38
  130. package/app/stores/data_helpers/mesh.ts +45 -36
  131. package/app/stores/data_style.ts +50 -28
  132. package/app/stores/feedback.ts +6 -6
  133. package/app/stores/hybrid_viewer.ts +41 -52
  134. package/app/stores/infra.ts +39 -37
  135. package/app/stores/menu.ts +23 -14
  136. package/app/stores/treeview.ts +72 -42
  137. package/app/stores/viewer.ts +39 -27
  138. package/app/utils/attributes.ts +3 -3
  139. package/app/utils/clipping_planes.ts +111 -14
  140. package/app/utils/color_picker.ts +57 -0
  141. package/app/utils/colormap.ts +58 -35
  142. package/app/utils/default_styles/index.ts +2 -2
  143. package/app/utils/default_styles/meshes.ts +107 -13
  144. package/app/utils/default_styles/models.ts +83 -14
  145. package/app/utils/extension.ts +47 -20
  146. package/app/utils/import_workflow.ts +21 -13
  147. package/app/utils/name_cleaner.ts +1 -1
  148. package/app/utils/string.ts +1 -1
  149. package/app/utils/treeview.ts +2 -2
  150. package/internal/database/base_database.ts +7 -3
  151. package/internal/database/database.ts +36 -26
  152. package/internal/database/extended_database.ts +1 -1
  153. package/internal/stores/data_style/mesh/cells/cell.ts +70 -34
  154. package/internal/stores/data_style/mesh/cells/color.ts +12 -6
  155. package/internal/stores/data_style/mesh/cells/common.ts +18 -8
  156. package/internal/stores/data_style/mesh/cells/index.ts +122 -42
  157. package/internal/stores/data_style/mesh/cells/textures.ts +12 -6
  158. package/internal/stores/data_style/mesh/cells/vertex.ts +75 -34
  159. package/internal/stores/data_style/mesh/cells/visibility.ts +15 -4
  160. package/internal/stores/data_style/mesh/edges/color.ts +12 -6
  161. package/internal/stores/data_style/mesh/edges/common.ts +14 -6
  162. package/internal/stores/data_style/mesh/edges/edge.ts +71 -39
  163. package/internal/stores/data_style/mesh/edges/index.ts +117 -42
  164. package/internal/stores/data_style/mesh/edges/vertex.ts +76 -39
  165. package/internal/stores/data_style/mesh/edges/visibility.ts +15 -4
  166. package/internal/stores/data_style/mesh/edges/width.ts +12 -4
  167. package/internal/stores/data_style/mesh/index.ts +30 -11
  168. package/internal/stores/data_style/mesh/points/color.ts +12 -6
  169. package/internal/stores/data_style/mesh/points/common.ts +21 -8
  170. package/internal/stores/data_style/mesh/points/index.ts +101 -50
  171. package/internal/stores/data_style/mesh/points/size.ts +12 -4
  172. package/internal/stores/data_style/mesh/points/vertex.ts +75 -34
  173. package/internal/stores/data_style/mesh/points/visibility.ts +17 -7
  174. package/internal/stores/data_style/mesh/polygons/color.ts +12 -6
  175. package/internal/stores/data_style/mesh/polygons/common.ts +23 -6
  176. package/internal/stores/data_style/mesh/polygons/index.ts +130 -70
  177. package/internal/stores/data_style/mesh/polygons/polygon.ts +77 -43
  178. package/internal/stores/data_style/mesh/polygons/textures.ts +12 -6
  179. package/internal/stores/data_style/mesh/polygons/vertex.ts +79 -39
  180. package/internal/stores/data_style/mesh/polygons/visibility.ts +16 -6
  181. package/internal/stores/data_style/mesh/polyhedra/color.ts +12 -6
  182. package/internal/stores/data_style/mesh/polyhedra/common.ts +14 -6
  183. package/internal/stores/data_style/mesh/polyhedra/index.ts +115 -56
  184. package/internal/stores/data_style/mesh/polyhedra/polyhedron.ts +80 -39
  185. package/internal/stores/data_style/mesh/polyhedra/vertex.ts +79 -39
  186. package/internal/stores/data_style/mesh/polyhedra/visibility.ts +16 -6
  187. package/internal/stores/data_style/model/blocks/color.ts +43 -13
  188. package/internal/stores/data_style/model/blocks/common.ts +21 -6
  189. package/internal/stores/data_style/model/blocks/index.ts +89 -59
  190. package/internal/stores/data_style/model/blocks/polyhedron.ts +101 -44
  191. package/internal/stores/data_style/model/blocks/vertex.ts +107 -42
  192. package/internal/stores/data_style/model/blocks/visibility.ts +17 -4
  193. package/internal/stores/data_style/model/color.ts +171 -83
  194. package/internal/stores/data_style/model/common.ts +70 -21
  195. package/internal/stores/data_style/model/corners/color.ts +43 -11
  196. package/internal/stores/data_style/model/corners/common.ts +25 -6
  197. package/internal/stores/data_style/model/corners/index.ts +66 -41
  198. package/internal/stores/data_style/model/corners/vertex.ts +105 -74
  199. package/internal/stores/data_style/model/corners/visibility.ts +19 -4
  200. package/internal/stores/data_style/model/edges/common.ts +12 -4
  201. package/internal/stores/data_style/model/edges/index.ts +2 -1
  202. package/internal/stores/data_style/model/edges/visibility.ts +24 -7
  203. package/internal/stores/data_style/model/index.ts +24 -11
  204. package/internal/stores/data_style/model/lines/color.ts +41 -11
  205. package/internal/stores/data_style/model/lines/common.ts +17 -6
  206. package/internal/stores/data_style/model/lines/edge.ts +105 -42
  207. package/internal/stores/data_style/model/lines/index.ts +86 -59
  208. package/internal/stores/data_style/model/lines/vertex.ts +105 -42
  209. package/internal/stores/data_style/model/lines/visibility.ts +17 -4
  210. package/internal/stores/data_style/model/points/common.ts +8 -4
  211. package/internal/stores/data_style/model/points/index.ts +10 -3
  212. package/internal/stores/data_style/model/points/size.ts +12 -4
  213. package/internal/stores/data_style/model/points/visibility.ts +16 -6
  214. package/internal/stores/data_style/model/selection.ts +80 -58
  215. package/internal/stores/data_style/model/surfaces/color.ts +41 -11
  216. package/internal/stores/data_style/model/surfaces/common.ts +23 -6
  217. package/internal/stores/data_style/model/surfaces/index.ts +89 -59
  218. package/internal/stores/data_style/model/surfaces/polygon.ts +107 -67
  219. package/internal/stores/data_style/model/surfaces/vertex.ts +111 -67
  220. package/internal/stores/data_style/model/surfaces/visibility.ts +18 -5
  221. package/internal/stores/data_style/model/visibility.ts +82 -20
  222. package/internal/stores/data_style/state.ts +77 -65
  223. package/internal/stores/hybrid_viewer/brightness.ts +49 -31
  224. package/internal/stores/hybrid_viewer/camera.ts +191 -177
  225. package/internal/stores/hybrid_viewer/camera_animation.ts +11 -10
  226. package/internal/stores/hybrid_viewer/core.ts +64 -0
  227. package/internal/stores/hybrid_viewer/filters.ts +10 -16
  228. package/internal/stores/hybrid_viewer/highlight.ts +91 -130
  229. package/internal/stores/hybrid_viewer/ruler.ts +24 -15
  230. package/internal/stores/hybrid_viewer/scene.ts +96 -117
  231. package/internal/stores/hybrid_viewer/viewport.ts +74 -65
  232. package/internal/stores/hybrid_viewer/vtk_types.ts +13 -29
  233. package/internal/utils/api_fetch.ts +54 -23
  234. package/internal/utils/upload_file.ts +74 -53
  235. package/internal/utils/viewer_call.ts +22 -13
  236. package/internal/utils/ws_client.ts +24 -13
  237. package/nuxt.config.ts +58 -1
  238. package/package.json +20 -8
  239. package/server/api/cloud/extensions/run.post.ts +6 -10
  240. package/server/api/local/app/project_folder_path.post.ts +4 -4
  241. package/server/api/local/app/run_back.post.ts +5 -7
  242. package/server/api/local/app/run_viewer.post.ts +5 -7
  243. package/server/api/local/extensions/kill.post.ts +4 -3
  244. package/server/api/local/extensions/run.post.ts +7 -10
  245. package/server/api/local/extensions/upload.put.ts +44 -54
  246. package/server/api/microservice/app/get_is_app_ready.get.ts +4 -5
  247. package/server/api/microservice/app/set_app_base_url.post.ts +5 -6
  248. package/server/api/microservice/app/set_back_base_url.post.ts +5 -6
  249. package/server/api/microservice/app/set_is_app_ready.post.ts +5 -6
  250. package/server/api/microservice/app/set_viewer_base_url.post.ts +5 -6
  251. package/server/api/microservice/extensions/download.post.ts +5 -4
  252. package/server/api/serverless/run_cloud.post.ts +53 -11
  253. package/server/utils/app_config.ts +29 -22
  254. package/server/utils/cleanup.ts +60 -30
  255. package/server/utils/cloud.ts +9 -8
  256. package/server/utils/extension.ts +23 -9
  257. package/server/utils/microservices.ts +33 -24
  258. package/server/utils/path.ts +4 -4
  259. package/server/utils/scripts.ts +26 -23
  260. package/server/utils/server.ts +2 -2
  261. package/server/utils/server_config.ts +41 -27
  262. package/server/utils/stream.ts +6 -0
  263. package/server/utils/ws_client.ts +42 -8
  264. package/shared/scripts.ts +15 -10
  265. package/shared/utils/call_raw.ts +23 -16
  266. package/shared/utils/call_schema.ts +5 -8
  267. package/shared/utils/fetch_raw.ts +87 -47
  268. package/shared/utils/fetch_schema.ts +6 -9
  269. package/shared/utils/file.ts +8 -2
  270. package/shared/utils/response_handlers/load.ts +26 -11
  271. package/shared/utils/types.ts +9 -9
  272. package/shared/utils/validate_schema.ts +1 -1
  273. package/app/components/Viewer/ObjectTree/Views/ModelComponents.vue +0 -276
  274. package/server/types/vendor.d.ts +0 -64
  275. package/server/utils/server_config.js +0 -43
  276. package/shared/utils/call_raw.js +0 -30
  277. package/shared/utils/fetch_raw.js +0 -40
  278. /package/{opengeodeweb_front_schemas.js → .build/opengeodeweb_front_schemas.js} +0 -0
  279. /package/{server → .build/server}/utils/server.js +0 -0
  280. /package/{shared → .build/shared}/app_mode.js +0 -0
  281. /package/{shared → .build/shared}/utils/parse_boolean.js +0 -0
  282. /package/{shared → .build/shared}/utils/types.js +0 -0
@@ -11,9 +11,11 @@ import { useViewerStore } from "@ogw_front/stores/viewer";
11
11
 
12
12
  const DEFAULT_ELEMENT_HEIGHT = 100;
13
13
 
14
- const emit = defineEmits<{
14
+ interface Emits {
15
15
  click: [event: PointerEvent];
16
- }>();
16
+ }
17
+
18
+ const emit = defineEmits<Emits>();
17
19
 
18
20
  const container = useTemplateRef("viewer");
19
21
  const hybridViewerStore = useHybridViewerStore();
@@ -26,8 +28,8 @@ const { width: windowWidth, height: windowHeight } = useWindowSize();
26
28
 
27
29
  function debounce<Callback extends (...args: unknown[]) => void>(func: Callback, wait: number) {
28
30
  let timeout: ReturnType<typeof setTimeout> | undefined = undefined;
29
- return function executedFunction(...args: Parameters<Callback>) {
30
- function later() {
31
+ return function executedFunction(...args: Parameters<Callback>): void {
32
+ function later(): void {
31
33
  clearTimeout(timeout);
32
34
  func(...args);
33
35
  }
@@ -58,7 +60,7 @@ onMounted(async () => {
58
60
 
59
61
  const { pickColormap, quickColormap } = useQuickColormap();
60
62
 
61
- async function handleClick(event: PointerEvent) {
63
+ async function handleClick(event: PointerEvent): Promise<void> {
62
64
  const { offsetX, offsetY, clientX, clientY } = event;
63
65
  // Only ever fired from the pointerup handler bound to this same element.
64
66
  const containerEl = container.value;
@@ -16,7 +16,7 @@ const hybridViewerStore = useHybridViewerStore();
16
16
  const tooltipRef = useTemplateRef("tooltip");
17
17
  const { width: tooltipWidth, height: tooltipHeight } = useElementSize(tooltipRef);
18
18
 
19
- const tooltipStyle = computed(() => {
19
+ const tooltipStyle = computed<Record<string, string>>(() => {
20
20
  if (!hybridViewerStore.hoverData) {
21
21
  return {};
22
22
  }
@@ -48,7 +48,7 @@ const tooltipStyle = computed(() => {
48
48
  };
49
49
  });
50
50
 
51
- const originalIndex = computed(() => {
51
+ const originalIndex = computed<number | undefined>(() => {
52
52
  const attributes = hybridViewerStore.hoverData?.attributes || {};
53
53
  const originalId =
54
54
  attributes.vtkOriginalCellIds ??
@@ -65,14 +65,14 @@ const RESERVED_ATTRIBUTE_KEYS = new Set([
65
65
  "vtkOriginalPointIds",
66
66
  ]);
67
67
 
68
- const hasOtherAttributes = computed(() => {
68
+ const hasOtherAttributes = computed<boolean>(() => {
69
69
  const attributes = hybridViewerStore.hoverData?.attributes || {};
70
70
  return Object.keys(attributes).some(
71
71
  (key) => key !== "vtkOriginalCellIds" && key !== "vtkOriginalPointIds",
72
72
  );
73
73
  });
74
74
 
75
- const sortedAttributes = computed(() => {
75
+ const sortedAttributes = computed<[string, unknown][]>(() => {
76
76
  const attributes = hybridViewerStore.hoverData?.attributes || {};
77
77
  return (
78
78
  Object.entries(attributes)
@@ -82,7 +82,7 @@ const sortedAttributes = computed(() => {
82
82
  );
83
83
  });
84
84
 
85
- function capitalize(val: string) {
85
+ function capitalize(val: string): string {
86
86
  if (!val) {
87
87
  return "";
88
88
  }
@@ -90,7 +90,7 @@ function capitalize(val: string) {
90
90
  return spaced.charAt(0).toUpperCase() + spaced.slice(1);
91
91
  }
92
92
 
93
- const fieldTypeLabel = computed(() => {
93
+ const fieldTypeLabel = computed<string>(() => {
94
94
  const fieldType = hybridViewerStore.hoverData?.fieldType;
95
95
  return typeof fieldType === "string" ? capitalize(fieldType.toLowerCase()) : "";
96
96
  });
@@ -100,7 +100,7 @@ const coordinates = computed<number[] | undefined>(() => {
100
100
  return Array.isArray(value) ? (value as number[]) : undefined;
101
101
  });
102
102
 
103
- function formatAttributeValue(val: unknown) {
103
+ function formatAttributeValue(val: unknown): string {
104
104
  if (Array.isArray(val)) {
105
105
  const formattedValues = val.map((value) => {
106
106
  if (typeof value === "number") {
@@ -19,7 +19,7 @@ if (infraStore.app_mode !== appMode.CLOUD) {
19
19
  infraStore.create_backend();
20
20
  }
21
21
 
22
- function cloudCreateBackend() {
22
+ function cloudCreateBackend(): Promise<void> {
23
23
  return infraStore.create_backend(email);
24
24
  }
25
25
  </script>
@@ -5,7 +5,13 @@ interface Props {
5
5
 
6
6
  const { appName } = defineProps<Props>();
7
7
 
8
- const ecoMessages = computed(() => [
8
+ interface EcoMessage {
9
+ icon: string;
10
+ title: string;
11
+ message: string;
12
+ }
13
+
14
+ const ecoMessages = computed<EcoMessage[]>(() => [
9
15
  {
10
16
  icon: "mdi-leaf",
11
17
  title: "Why the wait?",
@@ -24,12 +30,12 @@ const ecoMessages = computed(() => [
24
30
  ]);
25
31
 
26
32
  const MESSAGE_INTERVAL_MS = 5000;
27
- const currentMessage = ref(0);
33
+ const currentMessage = ref<number>(0);
28
34
  let interval: ReturnType<typeof setInterval> | undefined = undefined;
29
35
 
30
36
  // Fallback only guards against noUncheckedIndexedAccess; currentMessage is always kept in range by the modulo below, so it is never actually used.
31
37
  const FALLBACK_ECO_MESSAGE = { icon: "", title: "", message: "" };
32
- const currentEcoMessage = computed(
38
+ const currentEcoMessage = computed<EcoMessage>(
33
39
  () => ecoMessages.value[currentMessage.value] ?? FALLBACK_ECO_MESSAGE,
34
40
  );
35
41
 
@@ -15,8 +15,8 @@ const extensionStores = computed(() =>
15
15
  infraStore.microservices.filter((store) => store.$id !== "back" && store.$id !== "viewer"),
16
16
  );
17
17
 
18
- const show = ref(false);
19
- const progress = ref(0);
18
+ const show = ref<boolean>(false);
19
+ const progress = ref<number>(0);
20
20
 
21
21
  let progressInterval: ReturnType<typeof setInterval> | undefined = undefined;
22
22
 
@@ -7,19 +7,21 @@ import { useBackStore } from "@ogw_front/stores/back";
7
7
 
8
8
  // Files carry extra app-specific bookkeeping fields once picked up here.
9
9
  type UploadFile = File & { isConfigured?: boolean };
10
- type FilePlan = {
10
+ interface FilePlan {
11
11
  has_missing_files: boolean;
12
12
  mandatory_files: string[];
13
13
  additional_files: string[];
14
- };
14
+ }
15
15
 
16
16
  const schema = schemas.opengeodeweb_back.missing_files;
17
17
 
18
- const emit = defineEmits<{
18
+ interface Emits {
19
19
  update_values: [value: { additional_files: UploadFile[] }];
20
20
  increment_step: [];
21
21
  decrement_step: [];
22
- }>();
22
+ }
23
+
24
+ const emit = defineEmits<Emits>();
23
25
 
24
26
  interface Props {
25
27
  multiple: boolean;
@@ -30,23 +32,23 @@ interface Props {
30
32
 
31
33
  const { multiple, geodeObjectType, filenames, files = [] } = defineProps<Props>();
32
34
 
33
- const accept = ref("");
34
- const loading = ref(false);
35
- const has_missing_files = ref(false);
35
+ const accept = ref<string>("");
36
+ const loading = ref<boolean>(false);
37
+ const has_missing_files = ref<boolean>(false);
36
38
  const mandatory_files = ref<string[]>([]);
37
39
  const additional_files = ref<string[]>([]);
38
40
  const toggle_loading = useToggle(loading);
39
41
 
40
- function files_uploaded_event(value: UploadFile[]) {
42
+ function files_uploaded_event(value: UploadFile[]): void {
41
43
  emit("update_values", { additional_files: value });
42
44
  emit("increment_step");
43
45
  }
44
46
 
45
- function isCsvFile(filename: string) {
47
+ function isCsvFile(filename: string): boolean {
46
48
  return filename.toLowerCase().endsWith(".csv") || filename.toLowerCase().endsWith(".csv.json");
47
49
  }
48
50
 
49
- async function missing_files() {
51
+ async function missing_files(): Promise<void> {
50
52
  toggle_loading();
51
53
  has_missing_files.value = false;
52
54
  mandatory_files.value = [];
@@ -1,6 +1,4 @@
1
1
  <script setup lang="ts">
2
- // Not auto-fixable (eslint's sort-imports core rule has no autofixer) and this file's import order doesn't match its syntax-kind-then-alphabetical requirement - left as-is rather than manually reordered across the codebase for a purely cosmetic rule.
3
- // oxlint-disable eslint/sort-imports
4
2
  import FetchingData from "@ogw_front/components/FetchingData.vue";
5
3
  import { geode_objects } from "@ogw_front/assets/geode_objects";
6
4
  import { resolveAllowedObjects } from "@ogw_shared/utils/response_handlers/load.js";
@@ -8,7 +6,10 @@ import schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json";
8
6
  import { useBackStore } from "@ogw_front/stores/back";
9
7
 
10
8
  // Mirrors the (unexported) shape produced by shared/utils/response_handlers/load.ts.
11
- type AllowedObject = { is_loadable: number; object_priority?: number };
9
+ interface AllowedObject {
10
+ is_loadable: number;
11
+ object_priority?: number;
12
+ }
12
13
  type AllowedObjectMap = Record<string, AllowedObject>;
13
14
 
14
15
  const schema = schemas.opengeodeweb_back.allowed_objects;
@@ -26,10 +27,10 @@ const { filenames } = defineProps<Props>();
26
27
 
27
28
  const backStore = useBackStore();
28
29
 
29
- const loading = ref(false);
30
+ const loading = ref<boolean>(false);
30
31
  const allowedGeodeObjects = ref<AllowedObjectMap>({});
31
32
  const toggleLoading = useToggle(loading);
32
- const multipleFilesNoCommon = ref(false);
33
+ const multipleFilesNoCommon = ref<boolean>(false);
33
34
 
34
35
  async function fetchAllowedObjectsList(): Promise<AllowedObjectMap[]> {
35
36
  const promiseArray = filenames.map((filename): Promise<{ allowed_objects: AllowedObjectMap }> => {
@@ -40,7 +41,7 @@ async function fetchAllowedObjectsList(): Promise<AllowedObjectMap[]> {
40
41
  return responses.map((response) => response.allowed_objects);
41
42
  }
42
43
 
43
- function setGeodeObject(geode_object_type: string | undefined) {
44
+ function setGeodeObject(geode_object_type: string | undefined): void {
44
45
  if (geode_object_type) {
45
46
  emit("update_values", { geode_object_type });
46
47
  emit("increment_step");
@@ -48,17 +49,17 @@ function setGeodeObject(geode_object_type: string | undefined) {
48
49
  }
49
50
 
50
51
  // The geode_objects lookup is fixed and keyed by known object type names; a missing entry only happens if the backend reports a type this table doesn't know about.
51
- function geodeObjectTooltip(key: string, isLoadable: boolean) {
52
+ function geodeObjectTooltip(key: string, isLoadable: boolean): string {
52
53
  return isLoadable
53
54
  ? (geode_objects[key]?.tooltip ?? key)
54
55
  : `Data not loadable with this class (${key})`;
55
56
  }
56
57
 
57
- function geodeObjectImage(key: string) {
58
+ function geodeObjectImage(key: string): string | undefined {
58
59
  return geode_objects[key]?.image;
59
60
  }
60
61
 
61
- async function getAllowedGeodeObjects() {
62
+ async function getAllowedGeodeObjects(): Promise<void> {
62
63
  toggleLoading();
63
64
  allowedGeodeObjects.value = {};
64
65
  multipleFilesNoCommon.value = false;
@@ -1,9 +1,7 @@
1
1
  <script setup lang="ts">
2
- // Not auto-fixable (eslint's sort-imports core rule has no autofixer) and this file's import order doesn't match its syntax-kind-then-alphabetical requirement - left as-is rather than manually reordered across the codebase for a purely cosmetic rule.
3
- // oxlint-disable eslint/sort-imports
2
+ import type { JsonRpcSchema } from "@ogw_shared/utils/types.js";
4
3
  import { Status } from "@ogw_front/utils/status";
5
4
  import { useBackStore } from "@ogw_front/stores/back";
6
- import type { JsonRpcSchema } from "@ogw_shared/utils/types.js";
7
5
 
8
6
  interface Props {
9
7
  schema: JsonRpcSchema;
@@ -11,12 +9,15 @@ interface Props {
11
9
 
12
10
  const { schema } = defineProps<Props>();
13
11
 
14
- type PackageVersion = { package: string; version: string };
12
+ interface PackageVersion {
13
+ package: string;
14
+ version: string;
15
+ }
15
16
 
16
17
  const backStore = useBackStore();
17
18
  const packages_versions = ref<PackageVersion[]>([]);
18
19
 
19
- async function get_packages_versions() {
20
+ async function get_packages_versions(): Promise<void> {
20
21
  await backStore.request(
21
22
  { schema },
22
23
  {
@@ -18,13 +18,13 @@ const email = ref("");
18
18
  const launch = ref(false);
19
19
  const valid = ref(false);
20
20
  const emailRules = [
21
- (value: string) => {
21
+ (value: string): boolean | string => {
22
22
  if (value) {
23
23
  return true;
24
24
  }
25
25
  return "E-mail is required.";
26
26
  },
27
- (value: string) => {
27
+ (value: string): boolean | string => {
28
28
  if (/.+@.+\..+/u.test(value)) {
29
29
  return true;
30
30
  }
@@ -32,7 +32,7 @@ const emailRules = [
32
32
  },
33
33
  ];
34
34
 
35
- function submit() {
35
+ function submit(): Promise<void> {
36
36
  const infraStore = useInfraStore();
37
37
  return infraStore.create_backend(email.value);
38
38
  }
@@ -10,7 +10,7 @@ import { useViewerStore } from "@ogw_front/stores/viewer";
10
10
  import ColormapQuickPicker from "@ogw_front/components/Viewer/Options/ColormapQuickPicker.vue";
11
11
  import ViewToolbar from "@ogw_front/components/ViewToolbar.vue";
12
12
  import viewer_schemas from "@geode/opengeodeweb-viewer/opengeodeweb_viewer_schemas.json";
13
- import vtkRemoteView from "@kitware/vtk.js/Rendering/Misc/RemoteView";
13
+ import { newInstance as vtkRemoteView } from "@kitware/vtk.js/Rendering/Misc/RemoteView";
14
14
 
15
15
  interface Props {
16
16
  viewId?: string;
@@ -28,7 +28,7 @@ const { width: windowWidth, height: windowHeight } = useWindowSize();
28
28
 
29
29
  const { pickColormap, quickColormap } = useQuickColormap();
30
30
 
31
- async function get_x_y(event: PointerEvent) {
31
+ async function get_x_y(event: PointerEvent): Promise<void> {
32
32
  const { offsetX, offsetY, clientX, clientY } = event;
33
33
  if (viewerStore.picking_mode === true) {
34
34
  viewerStore.set_picked_point(offsetX, offsetY);
@@ -40,9 +40,8 @@ async function get_x_y(event: PointerEvent) {
40
40
  }
41
41
  }
42
42
 
43
- const connected = ref(false);
44
- // oxlint-disable-next-line import/no-named-as-default-member
45
- const view = vtkRemoteView.newInstance({
43
+ const connected = ref<boolean>(false);
44
+ const view = vtkRemoteView({
46
45
  rpcWheelEvent: "viewport.mouse.zoom.wheel",
47
46
  });
48
47
 
@@ -50,7 +49,7 @@ if (location.hostname.split(".")[0] === "localhost") {
50
49
  view.setInteractiveRatio(1);
51
50
  }
52
51
 
53
- function resize() {
52
+ function resize(): void {
54
53
  if (view) {
55
54
  view.getCanvasView().setSize(0, 0);
56
55
  view.resize();
@@ -73,7 +72,7 @@ watch([width, height], () => {
73
72
  resize();
74
73
  });
75
74
 
76
- function connect() {
75
+ function connect(): void {
77
76
  if (viewerStore.status !== Status.CONNECTED) {
78
77
  return;
79
78
  }
@@ -11,8 +11,8 @@ const { escapeFunction = undefined } = defineProps<Props>();
11
11
  const show = defineModel<boolean>("show", { default: false });
12
12
  const hybridViewerStore = useHybridViewerStore();
13
13
 
14
- const localPoint1 = ref([0, 0, 0]);
15
- const localPoint2 = ref([0, 0, 0]);
14
+ const localPoint1 = ref<number[]>([0, 0, 0]);
15
+ const localPoint2 = ref<number[]>([0, 0, 0]);
16
16
 
17
17
  watch(
18
18
  () => hybridViewerStore.ruler_point1,
@@ -49,7 +49,7 @@ watch(
49
49
  },
50
50
  );
51
51
 
52
- async function applyManualCoords() {
52
+ async function applyManualCoords(): Promise<void> {
53
53
  hybridViewerStore.ruler_point1 = [...localPoint1.value];
54
54
  hybridViewerStore.ruler_point2 = [...localPoint2.value];
55
55
  await hybridViewerStore.applyRuler();
@@ -19,14 +19,14 @@ const { width = DEFAULT_PANEL_WIDTH, escapeFunction = undefined } = defineProps<
19
19
 
20
20
  const output_extensions =
21
21
  viewer_schemas.opengeodeweb_viewer.viewer.take_screenshot.properties.output_extension.enum;
22
- const filename = ref("");
23
- const output_extension = ref("png");
24
- const include_background = ref(true);
25
- const screenshot_type = ref("file");
22
+ const filename = ref<string>("");
23
+ const output_extension = ref<string>("png");
24
+ const include_background = ref<boolean>(true);
25
+ const screenshot_type = ref<string>("file");
26
26
 
27
27
  const { copy } = useClipboardItems();
28
28
 
29
- async function takeScreenshot() {
29
+ async function takeScreenshot(): Promise<void> {
30
30
  const viewerStore = useViewerStore();
31
31
  const feedbackStore = useFeedbackStore();
32
32
  const current_filename = screenshot_type.value === "file" ? filename.value : "screenshot";
@@ -80,7 +80,7 @@ watch(screenshot_type, (value) => {
80
80
  }
81
81
  });
82
82
 
83
- function handleClose() {
83
+ function handleClose(): void {
84
84
  if (escapeFunction) {
85
85
  escapeFunction();
86
86
  }
@@ -6,9 +6,11 @@ interface Props {
6
6
 
7
7
  const { modelValue = "", label = "" } = defineProps<Props>();
8
8
 
9
- const emit = defineEmits<{
9
+ interface Emits {
10
10
  "update:modelValue": [value: string];
11
- }>();
11
+ }
12
+
13
+ const emit = defineEmits<Emits>();
12
14
  </script>
13
15
 
14
16
  <template>
@@ -17,19 +17,19 @@ const { escapeFunction = undefined } = defineProps<Props>();
17
17
  const show = defineModel<boolean>("show", { default: false });
18
18
  const dataStore = useDataStore();
19
19
  const hybridViewerStore = useHybridViewerStore();
20
- const targetAllVisible = ref(true);
21
- const selectedDatasetIds = ref([]);
22
- const shrinkFactor = ref(DEFAULT_SHRINK_VALUE);
20
+ const targetAllVisible = ref<boolean>(true);
21
+ const selectedDatasetIds = ref<string[]>([]);
22
+ const shrinkFactor = ref<number>(DEFAULT_SHRINK_VALUE);
23
23
 
24
24
  const allItems = dataStore.refAllItems();
25
- const availableDatasets = computed(() =>
25
+ const availableDatasets = computed<{ title: string; value: string }[]>(() =>
26
26
  allItems.value.map((item) => ({
27
27
  title: item.name || item.id,
28
28
  value: item.id,
29
29
  })),
30
30
  );
31
31
 
32
- async function applyShrink() {
32
+ async function applyShrink(): Promise<void> {
33
33
  const allIds = allItems.value.map((item) => item.id);
34
34
  if (allIds.length === 0) {
35
35
  return;
@@ -47,12 +47,12 @@ async function applyShrink() {
47
47
 
48
48
  const debouncedApply = useDebounceFn(() => applyShrink(), DEBOUNCE_DELAY);
49
49
 
50
- async function resetShrink() {
50
+ async function resetShrink(): Promise<void> {
51
51
  shrinkFactor.value = DEFAULT_SHRINK_VALUE;
52
52
  await applyShrink();
53
53
  }
54
54
 
55
- async function removeShrink() {
55
+ async function removeShrink(): Promise<void> {
56
56
  shrinkFactor.value = MAX_SHRINK_VALUE;
57
57
  const allIds = allItems.value.map((item) => item.id);
58
58
  if (allIds.length > 0) {
@@ -1,5 +1,4 @@
1
1
  <script setup lang="ts">
2
- import type { Ref } from "vue";
3
2
  import type { useStepperTree } from "@ogw_front/composables/stepper_tree";
4
3
 
5
4
  interface StepConfig {
@@ -11,7 +10,7 @@ interface StepConfig {
11
10
  };
12
11
  }
13
12
 
14
- function truncate(text: string, maxLength: number) {
13
+ function truncate(text: string, maxLength: number): string {
15
14
  if (text.length > maxLength) {
16
15
  return `${text.slice(0, maxLength)}...`;
17
16
  }
@@ -25,9 +24,11 @@ interface Props {
25
24
 
26
25
  const { stepIndex, stepperTree } = defineProps<Props>();
27
26
 
28
- const emit = defineEmits<{
27
+ interface Emits {
29
28
  reset_values: [];
30
- }>();
29
+ }
30
+
31
+ const emit = defineEmits<Emits>();
31
32
 
32
33
  const { state, increment_step, decrement_step, update_values } = stepperTree;
33
34
  const { current_step_index, steps } = toRefs(state) as unknown as {
@@ -35,7 +36,7 @@ const { current_step_index, steps } = toRefs(state) as unknown as {
35
36
  steps: Ref<StepConfig[]>;
36
37
  };
37
38
 
38
- const sortedChips = computed(() => {
39
+ const sortedChips = computed<string[]>(() => {
39
40
  const chips = steps.value[stepIndex]?.chips || [];
40
41
  return chips.toSorted((chipA, chipB) =>
41
42
  chipA.localeCompare(chipB, undefined, {
@@ -1,12 +1,13 @@
1
1
  <script setup lang="ts">
2
- import type { Ref } from "vue";
3
2
  import Step from "@ogw_front/components/Step.vue";
4
3
  import type { useStepperTree } from "@ogw_front/composables/stepper_tree";
5
4
 
6
- const emit = defineEmits<{
5
+ interface Emits {
7
6
  reset_values: [];
8
7
  close: [];
9
- }>();
8
+ }
9
+
10
+ const emit = defineEmits<Emits>();
10
11
 
11
12
  interface Props {
12
13
  stepperTree: ReturnType<typeof useStepperTree>;
@@ -22,11 +22,14 @@ const {
22
22
  } = defineProps<Props>();
23
23
 
24
24
  const model = defineModel<boolean>({ default: false });
25
- const emit = defineEmits<{
25
+
26
+ interface Emits {
26
27
  action: [];
27
- }>();
28
+ }
29
+
30
+ const emit = defineEmits<Emits>();
28
31
 
29
- function close() {
32
+ function close(): void {
30
33
  if (escapeFunction) {
31
34
  escapeFunction();
32
35
  }