@geode/opengeodeweb-front 12.2.0-rc.4 → 12.2.0-rc.5
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/app/components/ClippingPlanes.vue +1 -1
- package/app/components/FactorFilterPanel.vue +1 -1
- package/app/components/Launcher.vue +3 -2
- package/app/components/ThresholdFilter.vue +1 -2
- package/app/components/Viewer/Basemap/CropOptions.vue +7 -8
- package/app/components/Viewer/Basemap/OpacityOptions.vue +7 -8
- package/app/components/Viewer/ContextMenu/CircularItems.vue +6 -43
- package/app/components/Viewer/ContextMenu/ContextMenu.vue +1 -6
- package/app/components/Viewer/ContextMenu/ContextMenuItem.vue +14 -16
- package/app/components/Viewer/EdgedCurve/PointsOptions.vue +5 -4
- package/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +10 -13
- package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +8 -11
- package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +16 -13
- package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +28 -31
- package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +9 -11
- package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +8 -11
- package/app/components/Viewer/Generic/Model/BlocksOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/CornersOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/CornersTypeOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/EdgesOptions.vue +7 -8
- package/app/components/Viewer/Generic/Model/LinesOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/LinesTypeOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/ModelEdgesCard.vue +5 -7
- package/app/components/Viewer/Generic/Model/ModelPointsCard.vue +5 -7
- package/app/components/Viewer/Generic/Model/ModelStyleCard.vue +5 -7
- package/app/components/Viewer/Generic/Model/ModelStyleOptions.vue +7 -8
- package/app/components/Viewer/Generic/Model/PointsOptions.vue +7 -8
- package/app/components/Viewer/Generic/Model/SurfacesOptions.vue +1 -1
- package/app/components/Viewer/Grid/2D/CellsOptions.vue +6 -4
- package/app/components/Viewer/Grid/2D/EdgesOptions.vue +6 -4
- package/app/components/Viewer/Grid/2D/PointsOptions.vue +5 -4
- package/app/components/Viewer/Grid/3D/CellsOptions.vue +6 -4
- package/app/components/Viewer/Grid/3D/EdgesOptions.vue +6 -4
- package/app/components/Viewer/Grid/3D/FacetsOptions.vue +6 -4
- package/app/components/Viewer/Grid/3D/PointsOptions.vue +5 -4
- package/app/components/Viewer/Image/ImageOptions.vue +10 -13
- package/app/components/Viewer/ObjectTree/Base/CommonTreeView.vue +5 -0
- package/app/components/Viewer/ObjectTree/Base/ComponentRelations.vue +2 -2
- package/app/components/Viewer/ObjectTree/Base/StickyHeader.vue +4 -1
- package/app/components/Viewer/ObjectTree/Base/TreeRow.vue +6 -8
- package/app/components/Viewer/ObjectTree/Views/GlobalObjects.vue +10 -15
- package/app/components/Viewer/ObjectTree/Views/ModelTree.vue +3 -0
- package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +28 -31
- package/app/components/Viewer/Scene/BackgroundOptions.vue +4 -7
- package/app/components/Viewer/Scene/OrientationWidgetOptions.vue +4 -7
- package/app/components/Viewer/Scene/TextOptions.vue +4 -7
- package/app/components/Viewer/Solid/EdgesOptions.vue +6 -4
- package/app/components/Viewer/Solid/PointsOptions.vue +5 -4
- package/app/components/Viewer/Solid/PolygonsOptions.vue +6 -4
- package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +8 -11
- package/app/components/Viewer/Surface/EdgesOptions.vue +6 -4
- package/app/components/Viewer/Surface/PointsOptions.vue +6 -4
- package/app/components/Viewer/Surface/PolygonsOptions.vue +8 -11
- package/app/components/Viewer/Surface/Triangulated/TrianglesOptions.vue +5 -4
- package/app/components/Viewer/TetrahedralSolid/TetrahedraOptions.vue +6 -4
- package/app/components/Viewer/TetrahedralSolid/TrianglesOptions.vue +6 -4
- package/app/composables/circular_menu.ts +45 -0
- package/app/composables/hover_highlight.ts +1 -1
- package/app/composables/model_menu_context.ts +7 -11
- package/app/composables/model_tree.ts +3 -3
- package/app/composables/project_manager_helpers/types.ts +2 -3
- package/app/composables/use_overlapping_picker.ts +7 -19
- package/app/composables/viewer_context_menu.ts +2 -1
- package/app/stores/api.ts +6 -59
- package/app/stores/app.ts +21 -55
- package/app/stores/back.ts +86 -145
- package/app/stores/camera_manager.ts +12 -25
- package/app/stores/cloud.ts +21 -101
- package/app/stores/crs.ts +3 -2
- package/app/stores/data.ts +66 -409
- package/app/stores/data_style.ts +99 -93
- package/app/stores/feedback.ts +57 -53
- package/app/stores/infra.ts +61 -101
- package/app/stores/treeview.ts +12 -31
- package/app/stores/viewer.ts +9 -29
- package/app/stores/viewer_helpers/actions.ts +1 -23
- package/app/utils/backend_lifecycle.ts +155 -0
- package/app/utils/import_item.ts +5 -4
- package/app/utils/threshold_sources.ts +3 -2
- package/app/utils/treeview.ts +25 -1
- package/app/utils/viewer_object_type.ts +21 -0
- package/internal/database/base_database.ts +2 -1
- package/internal/database/database.ts +90 -7
- package/internal/database/queries.ts +45 -0
- package/internal/database/tables/camera_positions.ts +11 -1
- package/internal/database/tables/data.ts +20 -1
- package/internal/database/tables/data_style.ts +3 -1
- package/internal/database/tables/model_component_datastyle.ts +3 -1
- package/internal/database/tables/model_component_type_datastyle.ts +3 -1
- package/internal/database/tables/model_components.ts +12 -1
- package/internal/database/tables/model_components_relation.ts +11 -1
- package/internal/database/tables/scene_style.ts +3 -1
- package/internal/database/tables/treeview_config.ts +31 -0
- package/internal/stores/data/items.ts +110 -0
- package/internal/stores/data/model/collections.ts +107 -0
- package/internal/stores/data/model/components.ts +129 -0
- package/internal/stores/data/model/mesh_components.ts +134 -0
- package/internal/stores/data/model/relations.ts +76 -0
- package/internal/stores/data/model/types.ts +14 -0
- package/internal/stores/data/registration.ts +54 -0
- package/internal/stores/data/snapshot.ts +83 -0
- package/internal/stores/data/types.ts +26 -0
- package/internal/stores/data_style/model/common_mutations.ts +47 -77
- package/internal/stores/data_style/model/selection.ts +3 -10
- package/internal/stores/data_style/scene.ts +2 -2
- package/internal/stores/data_style/state.ts +10 -8
- package/internal/stores/data_style/state_shared.ts +10 -7
- package/internal/stores/hybrid_viewer/highlight.ts +9 -14
- package/internal/stores/hybrid_viewer/scene.ts +1 -1
- package/internal/stores/microservice.ts +192 -0
- package/package.json +1 -1
- package/tests/browser/helpers/data/helpers/attribute.ts +2 -1
- package/app/stores/data_helpers/collections.ts +0 -122
- package/app/stores/data_helpers/mesh.ts +0 -167
- package/app/stores/data_helpers/relations.ts +0 -94
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import
|
|
3
|
-
type ItemProps,
|
|
4
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
5
3
|
import type { MeshId } from "@ogw_front/types/identifiers";
|
|
4
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
6
5
|
import ViewerGenericMeshPolygonsColoring from "@ogw_front/components/Viewer/Generic/Mesh/PolygonsColoring.vue";
|
|
7
6
|
import ViewerOptionsVisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
8
7
|
import type { Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
@@ -20,25 +19,25 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
20
19
|
const { applyBatchStyle } = useBatchStyle();
|
|
21
20
|
|
|
22
21
|
interface Props {
|
|
23
|
-
|
|
22
|
+
dataId: DataId;
|
|
23
|
+
index: number;
|
|
24
24
|
btnImage: string;
|
|
25
25
|
tooltip?: string;
|
|
26
26
|
capabilities?: Record<string, CapabilityConfig>;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
const {
|
|
30
|
-
|
|
30
|
+
dataId,
|
|
31
|
+
index,
|
|
31
32
|
btnImage,
|
|
32
33
|
tooltip = "Polygons options",
|
|
33
34
|
capabilities = {},
|
|
34
35
|
} = defineProps<Props>();
|
|
35
36
|
|
|
36
|
-
const dataId = toRef(() => itemProps.id);
|
|
37
|
-
|
|
38
37
|
const visibility = computed<Visibility>({
|
|
39
|
-
get: () => dataStyleStore.meshPolygonsVisibility(dataId
|
|
38
|
+
get: () => dataStyleStore.meshPolygonsVisibility(dataId),
|
|
40
39
|
set: async (newValue) => {
|
|
41
|
-
await applyBatchStyle(dataId
|
|
40
|
+
await applyBatchStyle(dataId, (meshId: MeshId) =>
|
|
42
41
|
dataStyleStore.setMeshPolygonsVisibility(meshId, newValue),
|
|
43
42
|
);
|
|
44
43
|
hybridViewerStore.remoteRender();
|
|
@@ -49,8 +48,7 @@ const visibility = computed<Visibility>({
|
|
|
49
48
|
<template>
|
|
50
49
|
<ViewerContextMenuItem
|
|
51
50
|
data-testid="meshPolygonsMenu"
|
|
52
|
-
:index="
|
|
53
|
-
:itemProps="itemProps"
|
|
51
|
+
:index="index"
|
|
54
52
|
:tooltip="tooltip"
|
|
55
53
|
:btnImage="btnImage"
|
|
56
54
|
>
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import
|
|
3
|
-
type ItemProps,
|
|
4
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
5
3
|
import type { MeshId } from "@ogw_front/types/identifiers";
|
|
4
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
6
5
|
import ViewerGenericMeshPolyhedraColoring from "@ogw_front/components/Viewer/Generic/Mesh/PolyhedraColoring.vue";
|
|
7
6
|
import ViewerOptionsVisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
8
7
|
import type { Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
@@ -15,19 +14,18 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
15
14
|
const { applyBatchStyle } = useBatchStyle();
|
|
16
15
|
|
|
17
16
|
interface Props {
|
|
18
|
-
|
|
17
|
+
dataId: DataId;
|
|
18
|
+
index: number;
|
|
19
19
|
btnImage: string;
|
|
20
20
|
tooltip?: string;
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
-
const {
|
|
24
|
-
|
|
25
|
-
const dataId = toRef(() => itemProps.id);
|
|
23
|
+
const { dataId, index, btnImage, tooltip = "Polyhedra options" } = defineProps<Props>();
|
|
26
24
|
|
|
27
25
|
const visibility = computed<Visibility>({
|
|
28
|
-
get: () => dataStyleStore.meshPolyhedraVisibility(dataId
|
|
26
|
+
get: () => dataStyleStore.meshPolyhedraVisibility(dataId),
|
|
29
27
|
set: async (newValue) => {
|
|
30
|
-
await applyBatchStyle(dataId
|
|
28
|
+
await applyBatchStyle(dataId, (meshId: MeshId) =>
|
|
31
29
|
dataStyleStore.setMeshPolyhedraVisibility(meshId, newValue),
|
|
32
30
|
);
|
|
33
31
|
hybridViewerStore.remoteRender();
|
|
@@ -38,8 +36,7 @@ const visibility = computed<Visibility>({
|
|
|
38
36
|
<template>
|
|
39
37
|
<ViewerContextMenuItem
|
|
40
38
|
data-testid="meshPolyhedraMenu"
|
|
41
|
-
:index="
|
|
42
|
-
:itemProps="itemProps"
|
|
39
|
+
:index="index"
|
|
43
40
|
:tooltip="tooltip"
|
|
44
41
|
:btnImage="btnImage"
|
|
45
42
|
>
|
|
@@ -8,7 +8,7 @@ import type {
|
|
|
8
8
|
} from "@geode/opengeodeweb-viewer/schema_types";
|
|
9
9
|
import type { AttributeRange, AttributeTimeStep } from "@ogw_front/types/attribute";
|
|
10
10
|
import type { BlockId } from "@ogw_front/types/identifiers";
|
|
11
|
-
import type { CollectionComponent } from "@
|
|
11
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
12
12
|
import ViewerOptionsColoringTypeSelector from "@ogw_front/components/Viewer/Options/ColoringTypeSelector.vue";
|
|
13
13
|
import VisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
14
14
|
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_typed_schemas.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import type { CollectionComponent } from "@
|
|
2
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
3
3
|
import type { CornerId } from "@ogw_front/types/identifiers";
|
|
4
4
|
import ViewerGenericModelCornerComponentOptions from "@ogw_front/components/Viewer/Generic/Model/CornerComponentOptions.vue";
|
|
5
5
|
import ViewerGenericModelCornersTypeOptions from "@ogw_front/components/Viewer/Generic/Model/CornersTypeOptions.vue";
|
|
@@ -6,7 +6,7 @@ import type {
|
|
|
6
6
|
Visibility,
|
|
7
7
|
} from "@geode/opengeodeweb-viewer/schema_types";
|
|
8
8
|
import type { AttributeRange, AttributeTimeStep } from "@ogw_front/types/attribute";
|
|
9
|
-
import type { CollectionComponent } from "@
|
|
9
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
10
10
|
import { MODEL_VERTEX_COLORING } from "@ogw_front/utils/model_component_coloring";
|
|
11
11
|
import ViewerOptionsColoringTypeSelector from "@ogw_front/components/Viewer/Options/ColoringTypeSelector.vue";
|
|
12
12
|
import VisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import
|
|
3
|
-
type ItemProps,
|
|
4
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
5
3
|
import ModelEdgesCard from "./ModelEdgesCard.vue";
|
|
6
4
|
import SurfaceEdges from "@ogw_front/assets/viewer_svgs/surface_edges.svg";
|
|
5
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
7
6
|
|
|
8
7
|
interface Props {
|
|
9
|
-
|
|
8
|
+
dataId: DataId;
|
|
9
|
+
index: number;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
const {
|
|
12
|
+
const { dataId, index } = defineProps<Props>();
|
|
13
13
|
</script>
|
|
14
14
|
|
|
15
15
|
<template>
|
|
16
16
|
<ViewerContextMenuItem
|
|
17
17
|
data-testid="modelEdgesMenu"
|
|
18
|
-
:index="
|
|
19
|
-
:itemProps="itemProps"
|
|
18
|
+
:index="index"
|
|
20
19
|
tooltip="Edges options"
|
|
21
20
|
:btnImage="SurfaceEdges"
|
|
22
21
|
>
|
|
23
22
|
<template #options>
|
|
24
|
-
<ModelEdgesCard :
|
|
23
|
+
<ModelEdgesCard :data-id="dataId" />
|
|
25
24
|
</template>
|
|
26
25
|
</ViewerContextMenuItem>
|
|
27
26
|
</template>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import type { CollectionComponent } from "@
|
|
2
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
3
3
|
import type { LineId } from "@ogw_front/types/identifiers";
|
|
4
4
|
import ViewerGenericModelLineComponentOptions from "@ogw_front/components/Viewer/Generic/Model/LineComponentOptions.vue";
|
|
5
5
|
import ViewerGenericModelLinesTypeOptions from "@ogw_front/components/Viewer/Generic/Model/LinesTypeOptions.vue";
|
|
@@ -6,7 +6,7 @@ import type {
|
|
|
6
6
|
Visibility,
|
|
7
7
|
} from "@geode/opengeodeweb-viewer/schema_types";
|
|
8
8
|
import type { AttributeRange, AttributeTimeStep } from "@ogw_front/types/attribute";
|
|
9
|
-
import type { CollectionComponent } from "@
|
|
9
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
10
10
|
import { MODEL_LINE_COLORING } from "@ogw_front/utils/model_component_coloring";
|
|
11
11
|
import ViewerOptionsColoringTypeSelector from "@ogw_front/components/Viewer/Options/ColoringTypeSelector.vue";
|
|
12
12
|
import VisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import type { EdgeWidth, Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
3
|
-
import {
|
|
4
|
-
type ModelMenuItemProps,
|
|
5
|
-
useModelMenuContext,
|
|
6
|
-
} from "@ogw_front/composables/model_menu_context";
|
|
3
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
7
4
|
import ModelCardTabs from "./ModelCardTabs.vue";
|
|
8
5
|
import ViewerGenericModelComponentEdgesOptions from "@ogw_front/components/Viewer/Generic/Model/ComponentEdgesOptions.vue";
|
|
9
6
|
import ViewerOptionsWidthSlider from "@ogw_front/components/Viewer/Options/Sliders/Width.vue";
|
|
@@ -12,6 +9,7 @@ import { useBatchStyle } from "@ogw_front/composables/batch_style";
|
|
|
12
9
|
import { useDataStore } from "@ogw_front/stores/data";
|
|
13
10
|
import { useDataStyleStore } from "@ogw_front/stores/data_style";
|
|
14
11
|
import { useHybridViewerStore } from "@ogw_front/stores/hybrid_viewer";
|
|
12
|
+
import { useModelMenuContext } from "@ogw_front/composables/model_menu_context";
|
|
15
13
|
import { useModelTabs } from "@ogw_front/composables/model_tabs";
|
|
16
14
|
|
|
17
15
|
// Lines are edges themselves and corners have none: no edges options for them
|
|
@@ -27,10 +25,10 @@ function isEdgesComponentType(type: string | undefined): type is EdgesComponentT
|
|
|
27
25
|
}
|
|
28
26
|
|
|
29
27
|
interface Props {
|
|
30
|
-
|
|
28
|
+
dataId: DataId;
|
|
31
29
|
}
|
|
32
30
|
|
|
33
|
-
const {
|
|
31
|
+
const { dataId } = defineProps<Props>();
|
|
34
32
|
|
|
35
33
|
const dataStore = useDataStore();
|
|
36
34
|
const dataStyleStore = useDataStyleStore();
|
|
@@ -38,7 +36,7 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
38
36
|
const { applyBatchStyle } = useBatchStyle();
|
|
39
37
|
|
|
40
38
|
const { modelId, componentId, componentType, collections, targetComponentIds } =
|
|
41
|
-
useModelMenuContext(() =>
|
|
39
|
+
useModelMenuContext(() => dataId);
|
|
42
40
|
|
|
43
41
|
const modelEdgesVisibility = computed<Visibility | undefined>({
|
|
44
42
|
get: () => dataStyleStore.modelEdgesVisibility(modelId.value),
|
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import {
|
|
3
|
-
type ModelMenuItemProps,
|
|
4
|
-
useModelMenuContext,
|
|
5
|
-
} from "@ogw_front/composables/model_menu_context";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
6
3
|
import ModelCardTabs from "./ModelCardTabs.vue";
|
|
7
4
|
import ViewerGenericModelComponentPointsOptions from "@ogw_front/components/Viewer/Generic/Model/ComponentPointsOptions.vue";
|
|
8
5
|
import type { Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
@@ -11,6 +8,7 @@ import { useBatchStyle } from "@ogw_front/composables/batch_style";
|
|
|
11
8
|
import { useDataStore } from "@ogw_front/stores/data";
|
|
12
9
|
import { useDataStyleStore } from "@ogw_front/stores/data_style";
|
|
13
10
|
import { useHybridViewerStore } from "@ogw_front/stores/hybrid_viewer";
|
|
11
|
+
import { useModelMenuContext } from "@ogw_front/composables/model_menu_context";
|
|
14
12
|
import { useModelTabs } from "@ogw_front/composables/model_tabs";
|
|
15
13
|
|
|
16
14
|
// Corners have no points options: their points are the corners themselves
|
|
@@ -27,10 +25,10 @@ function isPointsComponentType(type: string | undefined): type is PointsComponen
|
|
|
27
25
|
}
|
|
28
26
|
|
|
29
27
|
interface Props {
|
|
30
|
-
|
|
28
|
+
dataId: DataId;
|
|
31
29
|
}
|
|
32
30
|
|
|
33
|
-
const {
|
|
31
|
+
const { dataId } = defineProps<Props>();
|
|
34
32
|
|
|
35
33
|
const dataStore = useDataStore();
|
|
36
34
|
const dataStyleStore = useDataStyleStore();
|
|
@@ -38,7 +36,7 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
38
36
|
const { applyBatchStyle } = useBatchStyle();
|
|
39
37
|
|
|
40
38
|
const { modelId, componentId, componentType, collections, targetComponentIds } =
|
|
41
|
-
useModelMenuContext(() =>
|
|
39
|
+
useModelMenuContext(() => dataId);
|
|
42
40
|
|
|
43
41
|
const modelPointsVisibility = computed<Visibility>({
|
|
44
42
|
get: () => dataStyleStore.modelPointsVisibility(modelId.value),
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import type { ColorRGBA, Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
3
|
-
import {
|
|
4
|
-
type ModelMenuItemProps,
|
|
5
|
-
useModelMenuContext,
|
|
6
|
-
} from "@ogw_front/composables/model_menu_context";
|
|
7
3
|
import BlocksOptions from "./BlocksOptions.vue";
|
|
8
4
|
import CornersOptions from "./CornersOptions.vue";
|
|
5
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
9
6
|
import LinesOptions from "./LinesOptions.vue";
|
|
10
7
|
import ModelCardTabs from "./ModelCardTabs.vue";
|
|
11
8
|
import SurfacesOptions from "./SurfacesOptions.vue";
|
|
@@ -14,6 +11,7 @@ import VisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwi
|
|
|
14
11
|
import { useBatchStyle } from "@ogw_front/composables/batch_style";
|
|
15
12
|
import { useDataStyleStore } from "@ogw_front/stores/data_style";
|
|
16
13
|
import { useHybridViewerStore } from "@ogw_front/stores/hybrid_viewer";
|
|
14
|
+
import { useModelMenuContext } from "@ogw_front/composables/model_menu_context";
|
|
17
15
|
import { useModelTabs } from "@ogw_front/composables/model_tabs";
|
|
18
16
|
|
|
19
17
|
const dataStyleStore = useDataStyleStore();
|
|
@@ -21,13 +19,13 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
21
19
|
const { applyBatchStyle } = useBatchStyle();
|
|
22
20
|
|
|
23
21
|
interface Props {
|
|
24
|
-
|
|
22
|
+
dataId: DataId;
|
|
25
23
|
}
|
|
26
24
|
|
|
27
|
-
const {
|
|
25
|
+
const { dataId } = defineProps<Props>();
|
|
28
26
|
|
|
29
27
|
const { modelId, componentId, componentType, collections, targetComponentIds } =
|
|
30
|
-
useModelMenuContext(() =>
|
|
28
|
+
useModelMenuContext(() => dataId);
|
|
31
29
|
|
|
32
30
|
const { tabs, activeTab } = useModelTabs({
|
|
33
31
|
componentType,
|
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import
|
|
3
|
-
type ItemProps,
|
|
4
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
5
3
|
import ModelColor from "@ogw_front/assets/viewer_svgs/model_component_color.svg";
|
|
6
4
|
import ModelStyleCard from "./ModelStyleCard.vue";
|
|
5
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
7
6
|
|
|
8
7
|
interface Props {
|
|
9
|
-
|
|
8
|
+
dataId: DataId;
|
|
9
|
+
index: number;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
const {
|
|
12
|
+
const { dataId, index } = defineProps<Props>();
|
|
13
13
|
</script>
|
|
14
14
|
|
|
15
15
|
<template>
|
|
16
16
|
<ViewerContextMenuItem
|
|
17
17
|
data-testid="modelStyleMenu"
|
|
18
|
-
:index="
|
|
19
|
-
:itemProps="itemProps"
|
|
18
|
+
:index="index"
|
|
20
19
|
tooltip="Style options"
|
|
21
20
|
:btnImage="ModelColor"
|
|
22
21
|
>
|
|
23
22
|
<template #options>
|
|
24
|
-
<ModelStyleCard :
|
|
23
|
+
<ModelStyleCard :data-id="dataId" />
|
|
25
24
|
</template>
|
|
26
25
|
</ViewerContextMenuItem>
|
|
27
26
|
</template>
|
|
@@ -1,27 +1,26 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import
|
|
3
|
-
type ItemProps,
|
|
4
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
5
3
|
import ModelPointsCard from "./ModelPointsCard.vue";
|
|
6
4
|
import SurfacePoints from "@ogw_front/assets/viewer_svgs/surface_points.svg";
|
|
5
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
7
6
|
|
|
8
7
|
interface Props {
|
|
9
|
-
|
|
8
|
+
dataId: DataId;
|
|
9
|
+
index: number;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
-
const {
|
|
12
|
+
const { dataId, index } = defineProps<Props>();
|
|
13
13
|
</script>
|
|
14
14
|
|
|
15
15
|
<template>
|
|
16
16
|
<ViewerContextMenuItem
|
|
17
17
|
data-testid="modelPointsMenu"
|
|
18
|
-
:index="
|
|
19
|
-
:itemProps="itemProps"
|
|
18
|
+
:index="index"
|
|
20
19
|
tooltip="Points options"
|
|
21
20
|
:btnImage="SurfacePoints"
|
|
22
21
|
>
|
|
23
22
|
<template #options>
|
|
24
|
-
<ModelPointsCard :
|
|
23
|
+
<ModelPointsCard :data-id="dataId" />
|
|
25
24
|
</template>
|
|
26
25
|
</ViewerContextMenuItem>
|
|
27
26
|
</template>
|
|
@@ -7,7 +7,7 @@ import type {
|
|
|
7
7
|
Visibility,
|
|
8
8
|
} from "@geode/opengeodeweb-viewer/schema_types";
|
|
9
9
|
import type { AttributeRange, AttributeTimeStep } from "@ogw_front/types/attribute";
|
|
10
|
-
import type { CollectionComponent } from "@
|
|
10
|
+
import type { CollectionComponent } from "@ogw_internal/stores/data/model/collections";
|
|
11
11
|
import type { SurfaceId } from "@ogw_front/types/identifiers";
|
|
12
12
|
import ViewerOptionsColoringTypeSelector from "@ogw_front/components/Viewer/Options/ColoringTypeSelector.vue";
|
|
13
13
|
import VisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid2D_Cells from "@ogw_front/assets/viewer_svgs/grid_2d_cells.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshCellsOptions from "@ogw_front/components/Viewer/Generic/Mesh/CellsOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
15
|
<ViewerGenericMeshCellsOptions
|
|
15
|
-
:
|
|
16
|
+
:data-id="dataId"
|
|
17
|
+
:index="index"
|
|
16
18
|
:btnImage="Grid2D_Cells"
|
|
17
19
|
tooltip="Cells options"
|
|
18
20
|
/>
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid2D_Edges from "@ogw_front/assets/viewer_svgs/grid_2d_edges.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshEdgesOptions from "@ogw_front/components/Viewer/Generic/Mesh/EdgesOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
15
|
<ViewerGenericMeshEdgesOptions
|
|
15
|
-
:
|
|
16
|
+
:data-id="dataId"
|
|
17
|
+
:index="index"
|
|
16
18
|
:btnImage="Grid2D_Edges"
|
|
17
19
|
:capabilities="{ edge: { available: false } }"
|
|
18
20
|
/>
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid2D_Points from "@ogw_front/assets/viewer_svgs/grid_2d_points.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshPointsOptions from "@ogw_front/components/Viewer/Generic/Mesh/PointsOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
|
-
<ViewerGenericMeshPointsOptions :
|
|
15
|
+
<ViewerGenericMeshPointsOptions :data-id="dataId" :index="index" :btnImage="Grid2D_Points" />
|
|
15
16
|
</template>
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid3DCells from "@ogw_front/assets/viewer_svgs/grid_3d_cells.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshCellsOptions from "@ogw_front/components/Viewer/Generic/Mesh/CellsOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
15
|
<ViewerGenericMeshCellsOptions
|
|
15
|
-
:
|
|
16
|
+
:data-id="dataId"
|
|
17
|
+
:index="index"
|
|
16
18
|
:btnImage="Grid3DCells"
|
|
17
19
|
tooltip="Cells options"
|
|
18
20
|
/>
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid3D_Edges from "@ogw_front/assets/viewer_svgs/grid_3d_edges.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshEdgesOptions from "@ogw_front/components/Viewer/Generic/Mesh/EdgesOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
15
|
<ViewerGenericMeshEdgesOptions
|
|
15
|
-
:
|
|
16
|
+
:data-id="dataId"
|
|
17
|
+
:index="index"
|
|
16
18
|
:btnImage="Grid3D_Edges"
|
|
17
19
|
:capabilities="{ edge: { available: false } }"
|
|
18
20
|
/>
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid3D_Facets from "@ogw_front/assets/viewer_svgs/grid_3d_facets.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshPolygonsOptions from "@ogw_front/components/Viewer/Generic/Mesh/PolygonsOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
15
|
<ViewerGenericMeshPolygonsOptions
|
|
15
|
-
:
|
|
16
|
+
:data-id="dataId"
|
|
17
|
+
:index="index"
|
|
16
18
|
:btnImage="Grid3D_Facets"
|
|
17
19
|
tooltip="Facets options"
|
|
18
20
|
/>
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
2
3
|
import Grid3D_Points from "@ogw_front/assets/viewer_svgs/grid_3d_points.svg";
|
|
3
|
-
import type { ItemProps } from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
4
4
|
import ViewerGenericMeshPointsOptions from "@ogw_front/components/Viewer/Generic/Mesh/PointsOptions.vue";
|
|
5
5
|
|
|
6
6
|
interface Props {
|
|
7
|
-
|
|
7
|
+
dataId: DataId;
|
|
8
|
+
index: number;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
|
-
const {
|
|
11
|
+
const { dataId, index } = defineProps<Props>();
|
|
11
12
|
</script>
|
|
12
13
|
|
|
13
14
|
<template>
|
|
14
|
-
<ViewerGenericMeshPointsOptions :
|
|
15
|
+
<ViewerGenericMeshPointsOptions :data-id="dataId" :index="index" :btnImage="Grid3D_Points" />
|
|
15
16
|
</template>
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import type { Opacity, Visibility } from "@geode/opengeodeweb-viewer/schema_types";
|
|
3
|
-
import
|
|
4
|
-
type ItemProps,
|
|
5
|
-
} from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
3
|
+
import type { DataId } from "@geode/opengeodeweb-microservice/schema_types";
|
|
6
4
|
import type { ImageId } from "@ogw_front/types/identifiers";
|
|
5
|
+
import ViewerContextMenuItem from "@ogw_front/components/Viewer/ContextMenu/ContextMenuItem.vue";
|
|
7
6
|
import ViewerOptionsOpacitySlider from "@ogw_front/components/Viewer/Options/Sliders/Opacity.vue";
|
|
8
7
|
import ViewerOptionsVisibilitySwitch from "@ogw_front/components/Viewer/Options/VisibilitySwitch.vue";
|
|
9
8
|
import { useBatchStyle } from "@ogw_front/composables/batch_style";
|
|
@@ -15,32 +14,31 @@ const hybridViewerStore = useHybridViewerStore();
|
|
|
15
14
|
const { applyBatchStyle } = useBatchStyle();
|
|
16
15
|
|
|
17
16
|
interface Props {
|
|
18
|
-
|
|
17
|
+
dataId: DataId;
|
|
18
|
+
index: number;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
const {
|
|
22
|
-
|
|
23
|
-
const dataId = toRef(() => itemProps.id);
|
|
21
|
+
const { dataId, index } = defineProps<Props>();
|
|
24
22
|
|
|
25
23
|
const visibility = computed<Visibility | undefined>({
|
|
26
|
-
get: () => dataStyleStore.imageVisibility(dataId
|
|
24
|
+
get: () => dataStyleStore.imageVisibility(dataId),
|
|
27
25
|
set: async (newValue) => {
|
|
28
26
|
if (newValue === undefined) {
|
|
29
27
|
return;
|
|
30
28
|
}
|
|
31
|
-
await applyBatchStyle(dataId
|
|
29
|
+
await applyBatchStyle(dataId, (imageId: ImageId) =>
|
|
32
30
|
dataStyleStore.setImageVisibility(imageId, newValue),
|
|
33
31
|
);
|
|
34
32
|
hybridViewerStore.remoteRender();
|
|
35
33
|
},
|
|
36
34
|
});
|
|
37
35
|
const opacity = computed<Opacity | undefined>({
|
|
38
|
-
get: () => dataStyleStore.imageOpacity(dataId
|
|
36
|
+
get: () => dataStyleStore.imageOpacity(dataId),
|
|
39
37
|
set: async (newValue) => {
|
|
40
38
|
if (newValue === undefined) {
|
|
41
39
|
return;
|
|
42
40
|
}
|
|
43
|
-
await applyBatchStyle(dataId
|
|
41
|
+
await applyBatchStyle(dataId, (imageId: ImageId) =>
|
|
44
42
|
dataStyleStore.setImageOpacity(imageId, newValue),
|
|
45
43
|
);
|
|
46
44
|
hybridViewerStore.remoteRender();
|
|
@@ -51,8 +49,7 @@ const opacity = computed<Opacity | undefined>({
|
|
|
51
49
|
<template>
|
|
52
50
|
<ViewerContextMenuItem
|
|
53
51
|
data-testid="imageMenu"
|
|
54
|
-
:index="
|
|
55
|
-
:itemProps="itemProps"
|
|
52
|
+
:index="index"
|
|
56
53
|
tooltip="Image options"
|
|
57
54
|
btnIcon="ph-image"
|
|
58
55
|
>
|