@geode/opengeodeweb-front 10.6.2 → 10.6.3-rc.1
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.
- package/.eslintrc.cjs +1 -1
- package/.oxlintrc.json +3 -22
- package/app/assets/geode_objects.js +26 -26
- package/app/components/Carousel.vue +62 -66
- package/app/components/CrsSelector.vue +48 -52
- package/app/components/DeleteDialog.vue +21 -37
- package/app/components/DragAndDrop.vue +35 -41
- package/app/components/ExtensionSelector.vue +50 -63
- package/app/components/FeedBack/ErrorBanner.vue +7 -10
- package/app/components/FeedBack/Snackers.vue +12 -14
- package/app/components/FetchingData.vue +1 -6
- package/app/components/FileSelector.vue +41 -47
- package/app/components/FileUploader.vue +62 -79
- package/app/components/GlassCard.vue +19 -19
- package/app/components/HybridRenderingView.vue +37 -38
- package/app/components/InfraConnected.vue +3 -3
- package/app/components/Inspector/InspectionButton.vue +27 -31
- package/app/components/Inspector/ResultPanel.vue +13 -24
- package/app/components/Launcher.vue +13 -13
- package/app/components/Loading.vue +63 -69
- package/app/components/MissingFilesSelector.vue +53 -73
- package/app/components/ObjectSelector.vue +81 -99
- package/app/components/PackagesVersions.vue +27 -30
- package/app/components/Recaptcha.vue +60 -71
- package/app/components/RemoteRenderingView.vue +102 -108
- package/app/components/Screenshot.vue +36 -42
- package/app/components/SearchBar.vue +5 -5
- package/app/components/Step.vue +37 -44
- package/app/components/Stepper.vue +29 -35
- package/app/components/VeaseViewToolbar.vue +69 -78
- package/app/components/ViewToolbar.vue +41 -45
- package/app/components/Viewer/BreadCrumb.vue +18 -30
- package/app/components/Viewer/ContextMenu.vue +176 -179
- package/app/components/Viewer/ContextMenuItem.vue +105 -117
- package/app/components/Viewer/EdgedCurve/PointsOptions.vue +6 -9
- package/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +82 -93
- package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +84 -99
- package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +83 -98
- package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +62 -73
- package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +84 -108
- package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +82 -105
- package/app/components/Viewer/Generic/Model/EdgesOptions.vue +19 -23
- package/app/components/Viewer/Generic/Model/PointsOptions.vue +26 -30
- package/app/components/Viewer/Grid/2D/CellsOptions.vue +5 -5
- package/app/components/Viewer/Grid/2D/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Grid/2D/PointsOptions.vue +6 -9
- package/app/components/Viewer/Grid/3D/CellsOptions.vue +5 -5
- package/app/components/Viewer/Grid/3D/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Grid/3D/FacetsOptions.vue +5 -5
- package/app/components/Viewer/Grid/3D/PointsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/EdgesOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PointsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PolygonsOptions.vue +6 -9
- package/app/components/Viewer/HybridSolid/PolyhedraOptions.vue +6 -9
- package/app/components/Viewer/Options/AttributeColorBar.vue +8 -8
- package/app/components/Viewer/Options/AttributeSelector.vue +73 -78
- package/app/components/Viewer/Options/ColorMapList.vue +115 -140
- package/app/components/Viewer/Options/ColorMapPicker.vue +128 -142
- package/app/components/Viewer/Options/ColorPicker.vue +9 -9
- package/app/components/Viewer/Options/ColoringTypeSelector.vue +77 -91
- package/app/components/Viewer/Options/TextureItem.vue +54 -58
- package/app/components/Viewer/Options/TexturesSelector.vue +22 -26
- package/app/components/Viewer/Options/VisibilitySwitch.vue +1 -1
- package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +61 -68
- package/app/components/Viewer/PolygonalSurface/EdgesOptions.vue +6 -9
- package/app/components/Viewer/PolygonalSurface/PointsOptions.vue +6 -9
- package/app/components/Viewer/PolygonalSurface/SpecificPolygonsOptions.vue +83 -103
- package/app/components/Viewer/Solid/EdgesOptions.vue +6 -9
- package/app/components/Viewer/Solid/PointsOptions.vue +6 -9
- package/app/components/Viewer/Solid/PolygonsOptions.vue +6 -9
- package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +82 -105
- package/app/components/Viewer/TetrahedralSolid/TetrahedraOptions.vue +5 -5
- package/app/components/Viewer/TetrahedralSolid/TrianglesOptions.vue +5 -5
- package/app/components/Viewer/Tree/ObjectTree.vue +80 -89
- package/app/components/Viewer/TreeComponent.vue +43 -49
- package/app/components/Viewer/TreeObject.vue +48 -50
- package/app/components/Viewer/TriangulatedSurface/EdgesOptions.vue +6 -9
- package/app/components/Viewer/TriangulatedSurface/PointsOptions.vue +5 -5
- package/app/components/Viewer/TriangulatedSurface/TrianglesOptions.vue +5 -5
- package/app/components/Wrapper.vue +8 -8
- package/app/components/ZScaling.vue +18 -27
- package/app/composables/project_manager.js +57 -67
- package/app/composables/run_function_when_microservices_connected.js +8 -8
- package/app/plugins/auto_store_register.js +11 -13
- package/app/stores/app.js +118 -138
- package/app/stores/data.js +52 -68
- package/app/stores/data_style.js +36 -36
- package/app/stores/feedback.js +17 -20
- package/app/stores/geode.js +54 -55
- package/app/stores/hybrid_viewer.js +164 -177
- package/app/stores/infra.js +45 -55
- package/app/stores/lambda.js +26 -26
- package/app/stores/menu.js +78 -85
- package/app/stores/treeview.js +57 -65
- package/app/stores/viewer.js +92 -104
- package/app/utils/colormap.js +3 -3
- package/app/utils/config.js +16 -22
- package/app/utils/default_styles.js +50 -62
- package/app/utils/extension.js +44 -44
- package/app/utils/file_import_workflow.js +50 -64
- package/app/utils/local/app_mode.js +2 -2
- package/app/utils/local/cleanup.js +66 -72
- package/app/utils/local/microservices.js +61 -71
- package/app/utils/local/path.js +16 -19
- package/app/utils/local/scripts.js +22 -22
- package/app/utils/recaptcha.js +6 -6
- package/app/utils/server.js +21 -24
- package/app/utils/status.js +2 -2
- package/app/utils/treeview.js +4 -4
- package/app/utils/validate_schema.js +7 -7
- package/commitlint.config.js +2 -2
- package/eslint.config.js +4 -4
- package/internal/database/database.js +38 -46
- package/internal/database/extended_database.js +9 -10
- package/internal/database/tables/data.js +2 -3
- package/internal/database/tables/model_components.js +1 -1
- package/internal/database/tables/model_components_relation.js +1 -1
- package/internal/stores/data_style/mesh/cells/cell.js +47 -63
- package/internal/stores/data_style/mesh/cells/color.js +11 -16
- package/internal/stores/data_style/mesh/cells/common.js +6 -6
- package/internal/stores/data_style/mesh/cells/index.js +37 -47
- package/internal/stores/data_style/mesh/cells/textures.js +11 -12
- package/internal/stores/data_style/mesh/cells/vertex.js +47 -58
- package/internal/stores/data_style/mesh/cells/visibility.js +11 -16
- package/internal/stores/data_style/mesh/edges/color.js +11 -16
- package/internal/stores/data_style/mesh/edges/common.js +6 -6
- package/internal/stores/data_style/mesh/edges/edge.js +47 -63
- package/internal/stores/data_style/mesh/edges/index.js +38 -52
- package/internal/stores/data_style/mesh/edges/vertex.js +47 -58
- package/internal/stores/data_style/mesh/edges/visibility.js +11 -16
- package/internal/stores/data_style/mesh/edges/width.js +11 -16
- package/internal/stores/data_style/mesh/index.js +34 -34
- package/internal/stores/data_style/mesh/points/color.js +11 -16
- package/internal/stores/data_style/mesh/points/common.js +6 -6
- package/internal/stores/data_style/mesh/points/index.js +35 -49
- package/internal/stores/data_style/mesh/points/size.js +11 -16
- package/internal/stores/data_style/mesh/points/vertex.js +47 -58
- package/internal/stores/data_style/mesh/points/visibility.js +11 -16
- package/internal/stores/data_style/mesh/polygons/color.js +11 -16
- package/internal/stores/data_style/mesh/polygons/common.js +6 -6
- package/internal/stores/data_style/mesh/polygons/index.js +36 -45
- package/internal/stores/data_style/mesh/polygons/polygon.js +45 -56
- package/internal/stores/data_style/mesh/polygons/textures.js +11 -16
- package/internal/stores/data_style/mesh/polygons/vertex.js +47 -58
- package/internal/stores/data_style/mesh/polygons/visibility.js +11 -16
- package/internal/stores/data_style/mesh/polyhedra/color.js +11 -16
- package/internal/stores/data_style/mesh/polyhedra/common.js +6 -6
- package/internal/stores/data_style/mesh/polyhedra/index.js +29 -42
- package/internal/stores/data_style/mesh/polyhedra/polyhedron.js +43 -47
- package/internal/stores/data_style/mesh/polyhedra/vertex.js +47 -58
- package/internal/stores/data_style/mesh/polyhedra/visibility.js +11 -17
- package/internal/stores/data_style/model/blocks/color.js +21 -24
- package/internal/stores/data_style/model/blocks/common.js +6 -6
- package/internal/stores/data_style/model/blocks/index.js +13 -17
- package/internal/stores/data_style/model/blocks/visibility.js +21 -24
- package/internal/stores/data_style/model/corners/color.js +21 -24
- package/internal/stores/data_style/model/corners/common.js +6 -6
- package/internal/stores/data_style/model/corners/index.js +14 -18
- package/internal/stores/data_style/model/corners/visibility.js +21 -25
- package/internal/stores/data_style/model/edges/common.js +4 -4
- package/internal/stores/data_style/model/edges/index.js +7 -7
- package/internal/stores/data_style/model/edges/visibility.js +11 -15
- package/internal/stores/data_style/model/index.js +84 -100
- package/internal/stores/data_style/model/lines/color.js +21 -24
- package/internal/stores/data_style/model/lines/common.js +6 -6
- package/internal/stores/data_style/model/lines/index.js +13 -17
- package/internal/stores/data_style/model/lines/visibility.js +21 -24
- package/internal/stores/data_style/model/points/common.js +4 -4
- package/internal/stores/data_style/model/points/index.js +9 -9
- package/internal/stores/data_style/model/points/size.js +11 -11
- package/internal/stores/data_style/model/points/visibility.js +11 -15
- package/internal/stores/data_style/model/surfaces/color.js +21 -24
- package/internal/stores/data_style/model/surfaces/common.js +6 -6
- package/internal/stores/data_style/model/surfaces/index.js +14 -22
- package/internal/stores/data_style/model/surfaces/visibility.js +18 -22
- package/internal/stores/data_style/state.js +11 -11
- package/internal/utils/api_fetch.js +24 -34
- package/internal/utils/upload_file.js +19 -24
- package/internal/utils/viewer_call.js +23 -36
- package/nuxt.config.js +7 -11
- package/package.json +3 -3
- package/scripts/generate_geode_objects.js +14 -16
- package/server/api/app/kill.post.js +4 -4
- package/server/api/app/project_folder_path.post.js +11 -11
- package/server/api/app/run_back.post.js +12 -12
- package/server/api/app/run_viewer.post.js +12 -12
- package/server/api/extensions/run.post.js +34 -41
- package/server/api/extensions/upload.put.js +48 -62
- package/tests/integration/setup.js +43 -53
- package/tests/integration/stores/data_style/mesh/cells.nuxt.test.js +90 -116
- package/tests/integration/stores/data_style/mesh/edges.nuxt.test.js +81 -107
- package/tests/integration/stores/data_style/mesh/index.nuxt.test.js +38 -41
- package/tests/integration/stores/data_style/mesh/points.nuxt.test.js +85 -101
- package/tests/integration/stores/data_style/mesh/polygons.nuxt.test.js +89 -113
- package/tests/integration/stores/data_style/mesh/polyhedra.nuxt.test.js +81 -105
- package/tests/integration/stores/data_style/model/blocks.nuxt.test.js +56 -73
- package/tests/integration/stores/data_style/model/corners.nuxt.test.js +59 -76
- package/tests/integration/stores/data_style/model/edges.nuxt.test.js +39 -42
- package/tests/integration/stores/data_style/model/index.nuxt.test.js +31 -34
- package/tests/integration/stores/data_style/model/lines.nuxt.test.js +60 -73
- package/tests/integration/stores/data_style/model/points.nuxt.test.js +52 -55
- package/tests/integration/stores/data_style/model/surfaces.nuxt.test.js +59 -80
- package/tests/integration/stores/viewer.nuxt.test.js +35 -38
- package/tests/setup_indexeddb.js +2 -2
- package/tests/unit/components/CrsSelector.nuxt.test.js +28 -28
- package/tests/unit/components/ExtensionSelector.nuxt.test.js +33 -35
- package/tests/unit/components/FeedBack/ErrorsBanner.nuxt.test.js +23 -23
- package/tests/unit/components/FeedBack/Snackers.nuxt.test.js +18 -18
- package/tests/unit/components/FileSelector.nuxt.test.js +57 -59
- package/tests/unit/components/FileUploader.nuxt.test.js +35 -39
- package/tests/unit/components/Inspector/InspectionButton.nuxt.test.js +28 -28
- package/tests/unit/components/Inspector/ResultPanel.nuxt.test.js +22 -27
- package/tests/unit/components/Launcher.nuxt.test.js +20 -22
- package/tests/unit/components/MissingFilesSelector.nuxt.test.js +37 -37
- package/tests/unit/components/ObjectSelector.nuxt.test.js +62 -62
- package/tests/unit/components/PackagesVersions.nuxt.test.js +16 -16
- package/tests/unit/components/Step.nuxt.test.js +18 -19
- package/tests/unit/components/Stepper.nuxt.test.js +18 -18
- package/tests/unit/composables/api_fetch.nuxt.test.js +34 -36
- package/tests/unit/composables/project_manager.nuxt.test.js +93 -112
- package/tests/unit/composables/run_function_when_microservices_connected.nuxt.test.js +36 -36
- package/tests/unit/composables/upload_file.nuxt.test.js +27 -29
- package/tests/unit/plugins/project_load.nuxt.test.js +31 -33
- package/tests/unit/stores/app.nuxt.test.js +90 -92
- package/tests/unit/stores/feedback.nuxt.test.js +47 -57
- package/tests/unit/stores/geode.nuxt.test.js +111 -115
- package/tests/unit/stores/infra.nuxt.test.js +148 -148
- package/tests/unit/stores/lambda.nuxt.test.js +72 -74
- package/tests/unit/stores/treeview.nuxt.test.js +19 -21
- package/tests/unit/stores/viewer.nuxt.test.js +109 -122
- package/tests/unit/utils/recaptcha.nuxt.test.js +25 -29
- package/tests/unit/utils/validate_schema.nuxt.test.js +17 -17
- package/tests/utils.js +11 -11
- package/tests/vitest.config.js +9 -9
- package/vuetify_config.js +2 -2
package/app/stores/viewer.js
CHANGED
|
@@ -1,144 +1,137 @@
|
|
|
1
1
|
// Third party imports
|
|
2
|
-
import vtkWSLinkClient, {
|
|
3
|
-
|
|
4
|
-
} from "@kitware/vtk.js/IO/Core/WSLinkClient"
|
|
5
|
-
import _ from "lodash"
|
|
2
|
+
import vtkWSLinkClient, { newInstance } from "@kitware/vtk.js/IO/Core/WSLinkClient";
|
|
3
|
+
import _ from "lodash";
|
|
6
4
|
// oxlint-disable-next-line no-unassigned-import
|
|
7
|
-
import "@kitware/vtk.js/Rendering/OpenGL/Profiles/Geometry"
|
|
8
|
-
import SmartConnect from "wslink/src/SmartConnect"
|
|
9
|
-
import { connectImageStream } from "@kitware/vtk.js/Rendering/Misc/RemoteView"
|
|
10
|
-
import schemas from "@geode/opengeodeweb-viewer/opengeodeweb_viewer_schemas.json"
|
|
5
|
+
import "@kitware/vtk.js/Rendering/OpenGL/Profiles/Geometry";
|
|
6
|
+
import SmartConnect from "wslink/src/SmartConnect";
|
|
7
|
+
import { connectImageStream } from "@kitware/vtk.js/Rendering/Misc/RemoteView";
|
|
8
|
+
import schemas from "@geode/opengeodeweb-viewer/opengeodeweb_viewer_schemas.json";
|
|
11
9
|
|
|
12
10
|
// Local imports
|
|
13
|
-
import { Status } from "@ogw_front/utils/status"
|
|
14
|
-
import { appMode } from "@ogw_front/utils/local/app_mode"
|
|
15
|
-
import { useAppStore } from "@ogw_front/stores/app"
|
|
16
|
-
import { useInfraStore } from "@ogw_front/stores/infra"
|
|
17
|
-
import { viewer_call } from "@ogw_internal/utils/viewer_call"
|
|
11
|
+
import { Status } from "@ogw_front/utils/status";
|
|
12
|
+
import { appMode } from "@ogw_front/utils/local/app_mode";
|
|
13
|
+
import { useAppStore } from "@ogw_front/stores/app";
|
|
14
|
+
import { useInfraStore } from "@ogw_front/stores/infra";
|
|
15
|
+
import { viewer_call } from "@ogw_internal/utils/viewer_call";
|
|
18
16
|
|
|
19
|
-
const MS_PER_SECOND = 1000
|
|
20
|
-
const SECONDS_PER_REQUEST = 10
|
|
21
|
-
const request_timeout = MS_PER_SECOND * SECONDS_PER_REQUEST
|
|
17
|
+
const MS_PER_SECOND = 1000;
|
|
18
|
+
const SECONDS_PER_REQUEST = 10;
|
|
19
|
+
const request_timeout = MS_PER_SECOND * SECONDS_PER_REQUEST;
|
|
22
20
|
|
|
23
21
|
export const useViewerStore = defineStore(
|
|
24
22
|
"viewer",
|
|
25
23
|
// oxlint-disable-next-line max-lines-per-function max-statements
|
|
26
24
|
() => {
|
|
27
|
-
const infraStore = useInfraStore()
|
|
28
|
-
const default_local_port = ref("1234")
|
|
29
|
-
const client = ref({})
|
|
30
|
-
const config = ref(undefined)
|
|
31
|
-
const picking_mode = ref(false)
|
|
32
|
-
const picked_point = ref({ x: undefined, y: undefined })
|
|
33
|
-
const request_counter = ref(0)
|
|
34
|
-
const status = ref(Status.NOT_CONNECTED)
|
|
35
|
-
const buzy = ref(0)
|
|
25
|
+
const infraStore = useInfraStore();
|
|
26
|
+
const default_local_port = ref("1234");
|
|
27
|
+
const client = ref({});
|
|
28
|
+
const config = ref(undefined);
|
|
29
|
+
const picking_mode = ref(false);
|
|
30
|
+
const picked_point = ref({ x: undefined, y: undefined });
|
|
31
|
+
const request_counter = ref(0);
|
|
32
|
+
const status = ref(Status.NOT_CONNECTED);
|
|
33
|
+
const buzy = ref(0);
|
|
36
34
|
|
|
37
35
|
const protocol = computed(() => {
|
|
38
36
|
if (infraStore.app_mode === appMode.CLOUD) {
|
|
39
|
-
return "wss"
|
|
37
|
+
return "wss";
|
|
40
38
|
}
|
|
41
|
-
return "ws"
|
|
42
|
-
})
|
|
39
|
+
return "ws";
|
|
40
|
+
});
|
|
43
41
|
|
|
44
42
|
const port = computed(() => {
|
|
45
43
|
if (infraStore.app_mode === appMode.CLOUD) {
|
|
46
|
-
return "443"
|
|
44
|
+
return "443";
|
|
47
45
|
}
|
|
48
|
-
return default_local_port.value
|
|
49
|
-
})
|
|
46
|
+
return default_local_port.value;
|
|
47
|
+
});
|
|
50
48
|
|
|
51
49
|
const base_url = computed(() => {
|
|
52
|
-
let viewer_url = `${protocol.value}://${infraStore.domain_name}:${port.value}
|
|
50
|
+
let viewer_url = `${protocol.value}://${infraStore.domain_name}:${port.value}`;
|
|
53
51
|
if (infraStore.app_mode === appMode.CLOUD) {
|
|
54
52
|
if (infraStore.ID === "") {
|
|
55
|
-
throw new Error("ID must not be empty in cloud mode")
|
|
53
|
+
throw new Error("ID must not be empty in cloud mode");
|
|
56
54
|
}
|
|
57
|
-
viewer_url += `/${infraStore.ID}/viewer
|
|
55
|
+
viewer_url += `/${infraStore.ID}/viewer`;
|
|
58
56
|
}
|
|
59
|
-
viewer_url += "/ws"
|
|
60
|
-
return viewer_url
|
|
61
|
-
})
|
|
57
|
+
viewer_url += "/ws";
|
|
58
|
+
return viewer_url;
|
|
59
|
+
});
|
|
62
60
|
|
|
63
|
-
const is_busy = computed(() => request_counter.value > 0)
|
|
61
|
+
const is_busy = computed(() => request_counter.value > 0);
|
|
64
62
|
|
|
65
63
|
function toggle_picking_mode(value) {
|
|
66
|
-
picking_mode.value = value
|
|
64
|
+
picking_mode.value = value;
|
|
67
65
|
}
|
|
68
66
|
|
|
69
67
|
async function set_picked_point(x, y) {
|
|
70
|
-
const response = await request(
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
)
|
|
74
|
-
const { x: world_x, y: world_y } = response
|
|
75
|
-
picked_point.value.x = world_x
|
|
76
|
-
picked_point.value.y = world_y
|
|
77
|
-
picking_mode.value = false
|
|
68
|
+
const response = await request(schemas.opengeodeweb_viewer.generic.get_point_position, {
|
|
69
|
+
x,
|
|
70
|
+
y,
|
|
71
|
+
});
|
|
72
|
+
const { x: world_x, y: world_y } = response;
|
|
73
|
+
picked_point.value.x = world_x;
|
|
74
|
+
picked_point.value.y = world_y;
|
|
75
|
+
picking_mode.value = false;
|
|
78
76
|
}
|
|
79
77
|
|
|
80
78
|
function ws_connect() {
|
|
81
79
|
if (status.value === Status.CONNECTED) {
|
|
82
|
-
return
|
|
80
|
+
return;
|
|
83
81
|
}
|
|
84
82
|
return navigator.locks.request("viewer.ws_connect", async (lock) => {
|
|
85
83
|
if (status.value === Status.CONNECTED) {
|
|
86
|
-
return
|
|
84
|
+
return;
|
|
87
85
|
}
|
|
88
86
|
try {
|
|
89
|
-
console.log("VIEWER LOCK GRANTED !", lock)
|
|
90
|
-
status.value = Status.CONNECTING
|
|
91
|
-
vtkWSLinkClient.setSmartConnectClass(SmartConnect)
|
|
87
|
+
console.log("VIEWER LOCK GRANTED !", lock);
|
|
88
|
+
status.value = Status.CONNECTING;
|
|
89
|
+
vtkWSLinkClient.setSmartConnectClass(SmartConnect);
|
|
92
90
|
|
|
93
91
|
if (_.isEmpty(client.value)) {
|
|
94
|
-
client.value = newInstance()
|
|
92
|
+
client.value = newInstance();
|
|
95
93
|
}
|
|
96
94
|
|
|
97
95
|
client.value.onBusyChange((count) => {
|
|
98
|
-
buzy.value = count
|
|
99
|
-
})
|
|
96
|
+
buzy.value = count;
|
|
97
|
+
});
|
|
100
98
|
client.value.onConnectionError((httpReq) => {
|
|
101
|
-
const message = httpReq?.response?.error || `Connection error
|
|
102
|
-
console.error(message)
|
|
103
|
-
})
|
|
99
|
+
const message = httpReq?.response?.error || `Connection error`;
|
|
100
|
+
console.error(message);
|
|
101
|
+
});
|
|
104
102
|
client.value.onConnectionClose((httpReq) => {
|
|
105
|
-
const message = httpReq?.response?.error || `Connection close
|
|
106
|
-
console.error(message)
|
|
107
|
-
})
|
|
103
|
+
const message = httpReq?.response?.error || `Connection close`;
|
|
104
|
+
console.error(message);
|
|
105
|
+
});
|
|
108
106
|
|
|
109
|
-
client.value.beginBusy()
|
|
107
|
+
client.value.beginBusy();
|
|
110
108
|
await client.value.connect({
|
|
111
109
|
application: "Viewer",
|
|
112
110
|
sessionURL: base_url.value,
|
|
113
|
-
})
|
|
114
|
-
connectImageStream(client.value.getConnection().getSession())
|
|
115
|
-
client.value.endBusy()
|
|
116
|
-
await request(
|
|
117
|
-
|
|
118
|
-
{},
|
|
119
|
-
{},
|
|
120
|
-
undefined,
|
|
121
|
-
)
|
|
122
|
-
status.value = Status.CONNECTED
|
|
111
|
+
});
|
|
112
|
+
connectImageStream(client.value.getConnection().getSession());
|
|
113
|
+
client.value.endBusy();
|
|
114
|
+
await request(schemas.opengeodeweb_viewer.viewer.reset_visualization, {}, {}, undefined);
|
|
115
|
+
status.value = Status.CONNECTED;
|
|
123
116
|
} catch (error) {
|
|
124
|
-
console.error("ws_connect error", error)
|
|
125
|
-
status.value = Status.NOT_CONNECTED
|
|
126
|
-
throw error
|
|
117
|
+
console.error("ws_connect error", error);
|
|
118
|
+
status.value = Status.NOT_CONNECTED;
|
|
119
|
+
throw error;
|
|
127
120
|
}
|
|
128
|
-
})
|
|
121
|
+
});
|
|
129
122
|
}
|
|
130
123
|
|
|
131
124
|
function start_request() {
|
|
132
|
-
request_counter.value += 1
|
|
125
|
+
request_counter.value += 1;
|
|
133
126
|
}
|
|
134
127
|
|
|
135
128
|
function stop_request() {
|
|
136
|
-
request_counter.value -= 1
|
|
129
|
+
request_counter.value -= 1;
|
|
137
130
|
}
|
|
138
131
|
|
|
139
|
-
function launch(args = { projectFolderPath }) {
|
|
140
|
-
console.log("[VIEWER] Launching viewer microservice...", { args })
|
|
141
|
-
const appStore = useAppStore()
|
|
132
|
+
function launch(args = ({ projectFolderPath } = {})) {
|
|
133
|
+
console.log("[VIEWER] Launching viewer microservice...", { args });
|
|
134
|
+
const appStore = useAppStore();
|
|
142
135
|
const schema = {
|
|
143
136
|
$id: "/api/app/run_viewer",
|
|
144
137
|
methods: ["POST"],
|
|
@@ -146,36 +139,31 @@ export const useViewerStore = defineStore(
|
|
|
146
139
|
properties: {},
|
|
147
140
|
required: [],
|
|
148
141
|
additionalProperties: true,
|
|
149
|
-
}
|
|
142
|
+
};
|
|
150
143
|
|
|
151
|
-
const params = { args }
|
|
152
|
-
console.log("[VIEWER] params", params)
|
|
144
|
+
const params = { args };
|
|
145
|
+
console.log("[VIEWER] params", params);
|
|
153
146
|
|
|
154
147
|
return appStore.request(schema, params, {
|
|
155
148
|
response_function: (response) => {
|
|
156
|
-
console.log(`[VIEWER] Viewer launched on port ${response.port}`)
|
|
157
|
-
this.default_local_port = response.port
|
|
149
|
+
console.log(`[VIEWER] Viewer launched on port ${response.port}`);
|
|
150
|
+
this.default_local_port = response.port;
|
|
158
151
|
},
|
|
159
|
-
})
|
|
152
|
+
});
|
|
160
153
|
}
|
|
161
154
|
|
|
162
155
|
async function connect() {
|
|
163
|
-
console.log("[VIEWER] Connecting to viewer microservice...")
|
|
164
|
-
await ws_connect()
|
|
165
|
-
console.log("[VIEWER] Viewer connected successfully")
|
|
156
|
+
console.log("[VIEWER] Connecting to viewer microservice...");
|
|
157
|
+
await ws_connect();
|
|
158
|
+
console.log("[VIEWER] Viewer connected successfully");
|
|
166
159
|
}
|
|
167
160
|
|
|
168
|
-
function request(
|
|
169
|
-
schema
|
|
170
|
-
|
|
171
|
-
callbacks = {},
|
|
172
|
-
timeout = request_timeout,
|
|
173
|
-
) {
|
|
174
|
-
console.log("[VIEWER] Request:", schema.$id)
|
|
175
|
-
const start = Date.now()
|
|
161
|
+
function request(schema, params = {}, callbacks = {}, timeout = request_timeout) {
|
|
162
|
+
console.log("[VIEWER] Request:", schema.$id);
|
|
163
|
+
const start = Date.now();
|
|
176
164
|
|
|
177
165
|
// Get current store instance to pass to viewer_call
|
|
178
|
-
const store = useViewerStore()
|
|
166
|
+
const store = useViewerStore();
|
|
179
167
|
|
|
180
168
|
return viewer_call(
|
|
181
169
|
store,
|
|
@@ -189,14 +177,14 @@ export const useViewerStore = defineStore(
|
|
|
189
177
|
"in",
|
|
190
178
|
(Date.now() - start) / MS_PER_SECOND,
|
|
191
179
|
"s",
|
|
192
|
-
)
|
|
180
|
+
);
|
|
193
181
|
if (callbacks.response_function) {
|
|
194
|
-
await callbacks.response_function(response)
|
|
182
|
+
await callbacks.response_function(response);
|
|
195
183
|
}
|
|
196
184
|
},
|
|
197
185
|
},
|
|
198
186
|
timeout,
|
|
199
|
-
)
|
|
187
|
+
);
|
|
200
188
|
}
|
|
201
189
|
|
|
202
190
|
return {
|
|
@@ -219,11 +207,11 @@ export const useViewerStore = defineStore(
|
|
|
219
207
|
launch,
|
|
220
208
|
connect,
|
|
221
209
|
request,
|
|
222
|
-
}
|
|
210
|
+
};
|
|
223
211
|
},
|
|
224
212
|
{
|
|
225
213
|
share: {
|
|
226
214
|
omit: ["status", "client"],
|
|
227
215
|
},
|
|
228
216
|
},
|
|
229
|
-
)
|
|
217
|
+
);
|
package/app/utils/colormap.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import vtkColorMaps from "@kitware/vtk.js/Rendering/Core/ColorTransferFunction/ColorMaps"
|
|
1
|
+
import vtkColorMaps from "@kitware/vtk.js/Rendering/Core/ColorTransferFunction/ColorMaps";
|
|
2
2
|
|
|
3
3
|
function getRGBPointsFromPreset(presetName) {
|
|
4
|
-
return vtkColorMaps.getPresetByName(presetName).RGBPoints
|
|
4
|
+
return vtkColorMaps.getPresetByName(presetName).RGBPoints;
|
|
5
5
|
}
|
|
6
6
|
|
|
7
|
-
export { getRGBPointsFromPreset }
|
|
7
|
+
export { getRGBPointsFromPreset };
|
package/app/utils/config.js
CHANGED
|
@@ -1,45 +1,39 @@
|
|
|
1
1
|
// Node.js imports
|
|
2
|
-
import path from "node:path"
|
|
2
|
+
import path from "node:path";
|
|
3
3
|
|
|
4
4
|
// Third party imports
|
|
5
|
-
import Conf from "conf"
|
|
5
|
+
import Conf from "conf";
|
|
6
6
|
|
|
7
7
|
// Local imports
|
|
8
8
|
|
|
9
9
|
function projectConf(projectName) {
|
|
10
|
-
const projectConfig = new Conf({ projectName })
|
|
11
|
-
console.log(projectConf.name, { projectConfig })
|
|
12
|
-
return projectConfig
|
|
10
|
+
const projectConfig = new Conf({ projectName });
|
|
11
|
+
console.log(projectConf.name, { projectConfig });
|
|
12
|
+
return projectConfig;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
function confFolderPath(projectName) {
|
|
16
|
-
const projectConfig = projectConf(projectName)
|
|
17
|
-
return path.dirname(projectConfig.path)
|
|
16
|
+
const projectConfig = projectConf(projectName);
|
|
17
|
+
return path.dirname(projectConfig.path);
|
|
18
18
|
}
|
|
19
19
|
|
|
20
20
|
function extensionsConf(projectName) {
|
|
21
|
-
const projectConfig = projectConf(projectName)
|
|
21
|
+
const projectConfig = projectConf(projectName);
|
|
22
22
|
if (!projectConfig.has("extensions")) {
|
|
23
|
-
projectConfig.set("extensions", {})
|
|
23
|
+
projectConfig.set("extensions", {});
|
|
24
24
|
}
|
|
25
|
-
const extensionsConfig = projectConfig.get("extensions")
|
|
26
|
-
return extensionsConfig
|
|
25
|
+
const extensionsConfig = projectConfig.get("extensions");
|
|
26
|
+
return extensionsConfig;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
function addExtensionToConf(projectName, { extensionID, extensionPath }) {
|
|
30
|
-
const projectConfig = projectConf(projectName)
|
|
31
|
-
projectConfig.set(`extensions.${extensionID}.path`, extensionPath)
|
|
30
|
+
const projectConfig = projectConf(projectName);
|
|
31
|
+
projectConfig.set(`extensions.${extensionID}.path`, extensionPath);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
function extensionPathFromConf(projectName, extensionID) {
|
|
35
|
-
const projectConfig = projectConf(projectName)
|
|
36
|
-
return projectConfig.get(`extensions.${extensionID}.path`)
|
|
35
|
+
const projectConfig = projectConf(projectName);
|
|
36
|
+
return projectConfig.get(`extensions.${extensionID}.path`);
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
export {
|
|
40
|
-
confFolderPath,
|
|
41
|
-
projectConf,
|
|
42
|
-
extensionsConf,
|
|
43
|
-
addExtensionToConf,
|
|
44
|
-
extensionPathFromConf,
|
|
45
|
-
}
|
|
39
|
+
export { confFolderPath, projectConf, extensionsConf, addExtensionToConf, extensionPathFromConf };
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
// Global variables
|
|
2
|
-
const points_defaultVisibility = true
|
|
3
|
-
const edges_defaultVisibility = true
|
|
4
|
-
const cells_defaultVisibility = true
|
|
5
|
-
const polygons_defaultVisibility = true
|
|
6
|
-
const polyhedra_defaultVisibility = true
|
|
7
|
-
const points_defaultSize = 10
|
|
8
|
-
const points_defaultColor = { r: 20, g: 20, b: 20 }
|
|
9
|
-
const edges_defaultWidth = 2
|
|
10
|
-
const edges_defaultColor = { r: 20, g: 20, b: 20 }
|
|
11
|
-
const cells_defaultColor = { r: 255, g: 255, b: 255 }
|
|
12
|
-
const polygons_defaultColor = { r: 255, g: 255, b: 255 }
|
|
13
|
-
const polyhedra_defaultColor = { r: 255, g: 255, b: 255 }
|
|
2
|
+
const points_defaultVisibility = true;
|
|
3
|
+
const edges_defaultVisibility = true;
|
|
4
|
+
const cells_defaultVisibility = true;
|
|
5
|
+
const polygons_defaultVisibility = true;
|
|
6
|
+
const polyhedra_defaultVisibility = true;
|
|
7
|
+
const points_defaultSize = 10;
|
|
8
|
+
const points_defaultColor = { r: 20, g: 20, b: 20 };
|
|
9
|
+
const edges_defaultWidth = 2;
|
|
10
|
+
const edges_defaultColor = { r: 20, g: 20, b: 20 };
|
|
11
|
+
const cells_defaultColor = { r: 255, g: 255, b: 255 };
|
|
12
|
+
const polygons_defaultColor = { r: 255, g: 255, b: 255 };
|
|
13
|
+
const polyhedra_defaultColor = { r: 255, g: 255, b: 255 };
|
|
14
14
|
|
|
15
|
-
const corners_defaultVisibility = true
|
|
16
|
-
const corners_defaultColor = { r: 20, g: 20, b: 20 }
|
|
17
|
-
const lines_defaultVisibility = true
|
|
18
|
-
const lines_defaultColor = { r: 20, g: 20, b: 20 }
|
|
19
|
-
const surfaces_defaultVisibility = true
|
|
20
|
-
const surfaces_defaultColor = { r: 255, g: 255, b: 255 }
|
|
21
|
-
const blocks_defaultVisibility = true
|
|
22
|
-
const blocks_defaultColor = { r: 255, g: 255, b: 255 }
|
|
15
|
+
const corners_defaultVisibility = true;
|
|
16
|
+
const corners_defaultColor = { r: 20, g: 20, b: 20 };
|
|
17
|
+
const lines_defaultVisibility = true;
|
|
18
|
+
const lines_defaultColor = { r: 20, g: 20, b: 20 };
|
|
19
|
+
const surfaces_defaultVisibility = true;
|
|
20
|
+
const surfaces_defaultColor = { r: 255, g: 255, b: 255 };
|
|
21
|
+
const blocks_defaultVisibility = true;
|
|
22
|
+
const blocks_defaultColor = { r: 255, g: 255, b: 255 };
|
|
23
23
|
|
|
24
24
|
// Mesh functions
|
|
25
25
|
function meshPointsDefaultStyle(
|
|
@@ -38,7 +38,7 @@ function meshPointsDefaultStyle(
|
|
|
38
38
|
},
|
|
39
39
|
},
|
|
40
40
|
size,
|
|
41
|
-
}
|
|
41
|
+
};
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
function meshEdgesDefaultStyle(
|
|
@@ -61,13 +61,10 @@ function meshEdgesDefaultStyle(
|
|
|
61
61
|
},
|
|
62
62
|
},
|
|
63
63
|
width,
|
|
64
|
-
}
|
|
64
|
+
};
|
|
65
65
|
}
|
|
66
66
|
|
|
67
|
-
function meshCellsDefaultStyle(
|
|
68
|
-
visibility = cells_defaultVisibility,
|
|
69
|
-
color = cells_defaultColor,
|
|
70
|
-
) {
|
|
67
|
+
function meshCellsDefaultStyle(visibility = cells_defaultVisibility, color = cells_defaultColor) {
|
|
71
68
|
return {
|
|
72
69
|
visibility,
|
|
73
70
|
coloring: {
|
|
@@ -83,7 +80,7 @@ function meshCellsDefaultStyle(
|
|
|
83
80
|
storedConfigs: {},
|
|
84
81
|
},
|
|
85
82
|
},
|
|
86
|
-
}
|
|
83
|
+
};
|
|
87
84
|
}
|
|
88
85
|
|
|
89
86
|
function meshPolygonsDefaultStyle(
|
|
@@ -105,7 +102,7 @@ function meshPolygonsDefaultStyle(
|
|
|
105
102
|
storedConfigs: {},
|
|
106
103
|
},
|
|
107
104
|
},
|
|
108
|
-
}
|
|
105
|
+
};
|
|
109
106
|
}
|
|
110
107
|
|
|
111
108
|
function meshPolyhedraDefaultStyle(
|
|
@@ -126,14 +123,14 @@ function meshPolyhedraDefaultStyle(
|
|
|
126
123
|
storedConfigs: {},
|
|
127
124
|
},
|
|
128
125
|
},
|
|
129
|
-
}
|
|
126
|
+
};
|
|
130
127
|
}
|
|
131
128
|
|
|
132
129
|
function pointSet_defaultStyle() {
|
|
133
130
|
return {
|
|
134
131
|
visibility: true,
|
|
135
132
|
points: meshPointsDefaultStyle(),
|
|
136
|
-
}
|
|
133
|
+
};
|
|
137
134
|
}
|
|
138
135
|
|
|
139
136
|
function edgedCurve_defaultStyle() {
|
|
@@ -141,7 +138,7 @@ function edgedCurve_defaultStyle() {
|
|
|
141
138
|
visibility: true,
|
|
142
139
|
points: meshPointsDefaultStyle(),
|
|
143
140
|
edges: meshEdgesDefaultStyle(),
|
|
144
|
-
}
|
|
141
|
+
};
|
|
145
142
|
}
|
|
146
143
|
|
|
147
144
|
function grid2d_defaultStyle() {
|
|
@@ -150,7 +147,7 @@ function grid2d_defaultStyle() {
|
|
|
150
147
|
points: meshPointsDefaultStyle(false),
|
|
151
148
|
edges: meshEdgesDefaultStyle(false),
|
|
152
149
|
cells: meshCellsDefaultStyle(),
|
|
153
|
-
}
|
|
150
|
+
};
|
|
154
151
|
}
|
|
155
152
|
|
|
156
153
|
function grid3d_defaultStyle() {
|
|
@@ -160,7 +157,7 @@ function grid3d_defaultStyle() {
|
|
|
160
157
|
edges: meshEdgesDefaultStyle(false),
|
|
161
158
|
cells: meshCellsDefaultStyle(),
|
|
162
159
|
polyhedra: meshPolyhedraDefaultStyle(),
|
|
163
|
-
}
|
|
160
|
+
};
|
|
164
161
|
}
|
|
165
162
|
function surface_defaultStyle() {
|
|
166
163
|
return {
|
|
@@ -168,7 +165,7 @@ function surface_defaultStyle() {
|
|
|
168
165
|
points: meshPointsDefaultStyle(false),
|
|
169
166
|
edges: meshEdgesDefaultStyle(false),
|
|
170
167
|
polygons: meshPolygonsDefaultStyle(),
|
|
171
|
-
}
|
|
168
|
+
};
|
|
172
169
|
}
|
|
173
170
|
|
|
174
171
|
function solid_defaultStyle() {
|
|
@@ -178,7 +175,7 @@ function solid_defaultStyle() {
|
|
|
178
175
|
edges: meshEdgesDefaultStyle(false),
|
|
179
176
|
polygons: meshPolygonsDefaultStyle(),
|
|
180
177
|
polyhedra: meshPolyhedraDefaultStyle(),
|
|
181
|
-
}
|
|
178
|
+
};
|
|
182
179
|
}
|
|
183
180
|
|
|
184
181
|
// Model functions
|
|
@@ -186,42 +183,33 @@ function modelCornersDefaultStyle(
|
|
|
186
183
|
visibility = corners_defaultVisibility,
|
|
187
184
|
color = corners_defaultColor,
|
|
188
185
|
) {
|
|
189
|
-
return { visibility, color }
|
|
186
|
+
return { visibility, color };
|
|
190
187
|
}
|
|
191
188
|
|
|
192
|
-
function modelLinesDefaultStyle(
|
|
193
|
-
visibility
|
|
194
|
-
color = lines_defaultColor,
|
|
195
|
-
) {
|
|
196
|
-
return { visibility, color }
|
|
189
|
+
function modelLinesDefaultStyle(visibility = lines_defaultVisibility, color = lines_defaultColor) {
|
|
190
|
+
return { visibility, color };
|
|
197
191
|
}
|
|
198
192
|
|
|
199
193
|
function modelSurfacesDefaultStyle(
|
|
200
194
|
visibility = surfaces_defaultVisibility,
|
|
201
195
|
color = surfaces_defaultColor,
|
|
202
196
|
) {
|
|
203
|
-
return { visibility, color }
|
|
197
|
+
return { visibility, color };
|
|
204
198
|
}
|
|
205
199
|
|
|
206
200
|
function modelBlocksDefaultStyle(
|
|
207
201
|
visibility = blocks_defaultVisibility,
|
|
208
202
|
color = blocks_defaultColor,
|
|
209
203
|
) {
|
|
210
|
-
return { visibility, color }
|
|
204
|
+
return { visibility, color };
|
|
211
205
|
}
|
|
212
206
|
|
|
213
|
-
function modelPointsDefaultStyle(
|
|
214
|
-
visibility
|
|
215
|
-
size = points_defaultSize,
|
|
216
|
-
) {
|
|
217
|
-
return { visibility, size }
|
|
207
|
+
function modelPointsDefaultStyle(visibility = points_defaultVisibility, size = points_defaultSize) {
|
|
208
|
+
return { visibility, size };
|
|
218
209
|
}
|
|
219
210
|
|
|
220
|
-
function modelEdgesDefaultStyle(
|
|
221
|
-
visibility
|
|
222
|
-
width = edges_defaultWidth,
|
|
223
|
-
) {
|
|
224
|
-
return { visibility, width }
|
|
211
|
+
function modelEdgesDefaultStyle(visibility = edges_defaultVisibility, width = edges_defaultWidth) {
|
|
212
|
+
return { visibility, width };
|
|
225
213
|
}
|
|
226
214
|
|
|
227
215
|
function brep_defaultStyle() {
|
|
@@ -233,7 +221,7 @@ function brep_defaultStyle() {
|
|
|
233
221
|
blocks: modelBlocksDefaultStyle(),
|
|
234
222
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
235
223
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
236
|
-
}
|
|
224
|
+
};
|
|
237
225
|
}
|
|
238
226
|
|
|
239
227
|
function crossSection_defaultStyle() {
|
|
@@ -244,7 +232,7 @@ function crossSection_defaultStyle() {
|
|
|
244
232
|
surfaces: modelSurfacesDefaultStyle(),
|
|
245
233
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
246
234
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
247
|
-
}
|
|
235
|
+
};
|
|
248
236
|
}
|
|
249
237
|
|
|
250
238
|
function structuralModel_defaultStyle() {
|
|
@@ -256,7 +244,7 @@ function structuralModel_defaultStyle() {
|
|
|
256
244
|
blocks: modelBlocksDefaultStyle(),
|
|
257
245
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
258
246
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
259
|
-
}
|
|
247
|
+
};
|
|
260
248
|
}
|
|
261
249
|
|
|
262
250
|
function section_defaultStyle() {
|
|
@@ -267,7 +255,7 @@ function section_defaultStyle() {
|
|
|
267
255
|
surfaces: modelSurfacesDefaultStyle(),
|
|
268
256
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
269
257
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
270
|
-
}
|
|
258
|
+
};
|
|
271
259
|
}
|
|
272
260
|
|
|
273
261
|
function implicitCrossSection_defaultStyle() {
|
|
@@ -278,7 +266,7 @@ function implicitCrossSection_defaultStyle() {
|
|
|
278
266
|
surfaces: modelSurfacesDefaultStyle(),
|
|
279
267
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
280
268
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
281
|
-
}
|
|
269
|
+
};
|
|
282
270
|
}
|
|
283
271
|
|
|
284
272
|
function implicitStructuralModel_defaultStyle() {
|
|
@@ -290,7 +278,7 @@ function implicitStructuralModel_defaultStyle() {
|
|
|
290
278
|
blocks: modelBlocksDefaultStyle(),
|
|
291
279
|
points: modelPointsDefaultStyle(false, points_defaultSize),
|
|
292
280
|
edges: modelEdgesDefaultStyle(false, edges_defaultWidth),
|
|
293
|
-
}
|
|
281
|
+
};
|
|
294
282
|
}
|
|
295
283
|
|
|
296
284
|
function default_styles() {
|
|
@@ -320,11 +308,11 @@ function default_styles() {
|
|
|
320
308
|
TriangulatedSurface2D: surface_defaultStyle(),
|
|
321
309
|
TriangulatedSurface3D: surface_defaultStyle(),
|
|
322
310
|
VertexSet: {},
|
|
323
|
-
}
|
|
311
|
+
};
|
|
324
312
|
}
|
|
325
313
|
|
|
326
314
|
function getDefaultStyle(type) {
|
|
327
|
-
return default_styles()[type]
|
|
315
|
+
return default_styles()[type];
|
|
328
316
|
}
|
|
329
317
|
|
|
330
|
-
export { getDefaultStyle }
|
|
318
|
+
export { getDefaultStyle };
|