@geode/opengeodeweb-front 10.25.0-rc.2 → 10.25.0-rc.4
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/Basic/Slider.vue +1 -1
- package/app/components/Basic/Switch.vue +1 -1
- package/app/components/CameraManager.vue +3 -3
- package/app/components/CrsSelector.vue +5 -5
- package/app/components/ExtensionSelector.vue +3 -3
- package/app/components/FileSelector.vue +8 -8
- package/app/components/FileUploader.vue +5 -5
- package/app/components/Inspector/InspectionButton.vue +3 -3
- package/app/components/Inspector/ResultPanel.vue +5 -5
- package/app/components/MissingFilesSelector.vue +4 -4
- package/app/components/Recaptcha.vue +4 -4
- package/app/components/Step.vue +14 -14
- package/app/components/Stepper.vue +5 -5
- package/app/components/Viewer/ContextMenu/ContextMenuItem.vue +3 -3
- package/app/components/Viewer/EdgedCurve/PointsOptions.vue +1 -1
- package/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +1 -1
- package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +3 -3
- package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +3 -3
- package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +3 -3
- package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +3 -3
- package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +3 -3
- package/app/components/Viewer/Generic/Model/EdgesOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/ModelStyleOptions.vue +1 -1
- package/app/components/Viewer/Generic/Model/PointsOptions.vue +1 -1
- package/app/components/Viewer/Grid/2D/CellsOptions.vue +1 -1
- package/app/components/Viewer/Grid/2D/EdgesOptions.vue +1 -1
- package/app/components/Viewer/Grid/2D/PointsOptions.vue +1 -1
- package/app/components/Viewer/Grid/3D/CellsOptions.vue +1 -1
- package/app/components/Viewer/Grid/3D/EdgesOptions.vue +1 -1
- package/app/components/Viewer/Grid/3D/FacetsOptions.vue +1 -1
- package/app/components/Viewer/Grid/3D/PointsOptions.vue +1 -1
- package/app/components/Viewer/Options/ColorMapPicker.vue +1 -1
- package/app/components/Viewer/Options/ColorPicker.vue +2 -1
- package/app/components/Viewer/Options/ColoringTypeSelector.vue +20 -18
- package/app/components/Viewer/Options/Sliders/Size.vue +1 -1
- package/app/components/Viewer/Options/Sliders/Slider.vue +1 -1
- package/app/components/Viewer/Options/Sliders/Width.vue +1 -1
- package/app/components/Viewer/Options/TextureItem.vue +15 -15
- package/app/components/Viewer/Options/TexturesSelector.vue +1 -1
- package/app/components/Viewer/Options/VisibilitySwitch.vue +1 -1
- package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +1 -1
- package/app/components/Viewer/Solid/EdgesOptions.vue +1 -1
- package/app/components/Viewer/Solid/PointsOptions.vue +1 -1
- package/app/components/Viewer/Solid/PolygonsOptions.vue +1 -1
- package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +1 -1
- package/app/components/Viewer/Surface/EdgesOptions.vue +1 -1
- package/app/components/Viewer/Surface/PointsOptions.vue +1 -1
- package/app/components/Viewer/Surface/PolygonsOptions.vue +1 -1
- package/app/components/Viewer/TetrahedralSolid/TetrahedraOptions.vue +1 -1
- package/app/components/Viewer/TetrahedralSolid/TrianglesOptions.vue +1 -1
- package/app/components/Wrapper.vue +3 -3
- package/package.json +1 -1
- package/server/utils/cloud.js +1 -1
- package/tests/unit/components/CrsSelector.nuxt.test.js +1 -1
- package/tests/unit/components/FileSelector.nuxt.test.js +6 -6
- package/tests/unit/components/FileUploader.nuxt.test.js +4 -4
- package/tests/unit/components/Inspector/ResultPanel.nuxt.test.js +5 -5
- package/tests/unit/components/Step.nuxt.test.js +1 -1
- package/tests/unit/components/Stepper.nuxt.test.js +1 -1
|
@@ -5,15 +5,15 @@ import Saver from "@ogw_front/components/CameraManager/Saver";
|
|
|
5
5
|
|
|
6
6
|
const emit = defineEmits(["close"]);
|
|
7
7
|
|
|
8
|
-
const {
|
|
9
|
-
|
|
8
|
+
const { showDialog, width } = defineProps({
|
|
9
|
+
showDialog: { type: Boolean, required: true },
|
|
10
10
|
width: { type: Number, required: false, default: 260 },
|
|
11
11
|
});
|
|
12
12
|
</script>
|
|
13
13
|
|
|
14
14
|
<template>
|
|
15
15
|
<GlassCard
|
|
16
|
-
v-if="
|
|
16
|
+
v-if="showDialog"
|
|
17
17
|
@click.stop
|
|
18
18
|
title="Camera Positions"
|
|
19
19
|
:width="width"
|
|
@@ -6,9 +6,9 @@ const schema = schemas.opengeodeweb_back.geographic_coordinate_systems;
|
|
|
6
6
|
|
|
7
7
|
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
|
|
8
8
|
|
|
9
|
-
const {
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
const { geodeObjectType, keyToUpdate } = defineProps({
|
|
10
|
+
geodeObjectType: { type: String, required: true },
|
|
11
|
+
keyToUpdate: { type: String, required: true },
|
|
12
12
|
});
|
|
13
13
|
|
|
14
14
|
const search = ref("");
|
|
@@ -21,7 +21,7 @@ const backStore = useBackStore();
|
|
|
21
21
|
watch(selected_crs, (new_value) => {
|
|
22
22
|
const crs = get_selected_crs(new_value[0]);
|
|
23
23
|
const keys_values_object = {
|
|
24
|
-
[
|
|
24
|
+
[keyToUpdate]: crs,
|
|
25
25
|
};
|
|
26
26
|
emit("update_values", keys_values_object);
|
|
27
27
|
emit("increment_step");
|
|
@@ -36,7 +36,7 @@ function get_selected_crs(crs_code) {
|
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
async function get_crs_table() {
|
|
39
|
-
const params = { geode_object_type };
|
|
39
|
+
const params = { geode_object_type: geodeObjectType };
|
|
40
40
|
toggle_loading();
|
|
41
41
|
await backStore.request(
|
|
42
42
|
{ schema, params },
|
|
@@ -7,8 +7,8 @@ import { useBackStore } from "@ogw_front/stores/back";
|
|
|
7
7
|
const schema = schemas.opengeodeweb_back.geode_objects_and_output_extensions;
|
|
8
8
|
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
|
|
9
9
|
|
|
10
|
-
const {
|
|
11
|
-
|
|
10
|
+
const { geodeObjectType, filenames } = defineProps({
|
|
11
|
+
geodeObjectType: { type: String, required: true },
|
|
12
12
|
filenames: { type: Array, required: true },
|
|
13
13
|
});
|
|
14
14
|
const geode_objects_and_output_extensions = ref({});
|
|
@@ -22,7 +22,7 @@ async function get_output_file_extensions() {
|
|
|
22
22
|
const backStore = useBackStore();
|
|
23
23
|
const values = await Promise.all(
|
|
24
24
|
filenames.map(async (filename) => {
|
|
25
|
-
const params = { geode_object_type, filename };
|
|
25
|
+
const params = { geode_object_type: geodeObjectType, filename };
|
|
26
26
|
const response = await backStore.request({ schema, params });
|
|
27
27
|
return response.geode_objects_and_output_extensions;
|
|
28
28
|
}),
|
|
@@ -9,15 +9,15 @@ const schema = schemas.opengeodeweb_back.allowed_files;
|
|
|
9
9
|
|
|
10
10
|
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
|
|
11
11
|
|
|
12
|
-
const { multiple, files,
|
|
12
|
+
const { multiple, files, autoUpload, showOverlay } = defineProps({
|
|
13
13
|
multiple: { type: Boolean, required: true },
|
|
14
14
|
files: { type: Array, default: () => [] },
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
autoUpload: { type: Boolean, default: true },
|
|
16
|
+
showOverlay: { type: Boolean, default: true },
|
|
17
17
|
});
|
|
18
18
|
|
|
19
19
|
const internal_files = ref(files);
|
|
20
|
-
const internal_auto_upload = ref(
|
|
20
|
+
const internal_auto_upload = ref(autoUpload);
|
|
21
21
|
const accept = ref("");
|
|
22
22
|
const loading = ref(false);
|
|
23
23
|
|
|
@@ -29,7 +29,7 @@ watch(
|
|
|
29
29
|
);
|
|
30
30
|
|
|
31
31
|
watch(
|
|
32
|
-
() =>
|
|
32
|
+
() => autoUpload,
|
|
33
33
|
(val) => {
|
|
34
34
|
internal_auto_upload.value = val;
|
|
35
35
|
},
|
|
@@ -39,7 +39,7 @@ const toggle_loading = useToggle(loading);
|
|
|
39
39
|
|
|
40
40
|
function files_uploaded_event(value) {
|
|
41
41
|
if (value.length > 0) {
|
|
42
|
-
emit("update_values", { files: value,
|
|
42
|
+
emit("update_values", { files: value, autoUpload: false });
|
|
43
43
|
emit("increment_step");
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -63,8 +63,8 @@ await get_allowed_files();
|
|
|
63
63
|
multiple,
|
|
64
64
|
accept,
|
|
65
65
|
files: internal_files,
|
|
66
|
-
|
|
67
|
-
showOverlay:
|
|
66
|
+
autoUpload: internal_auto_upload,
|
|
67
|
+
showOverlay: showOverlay,
|
|
68
68
|
}"
|
|
69
69
|
@files_uploaded="files_uploaded_event"
|
|
70
70
|
/>
|
|
@@ -6,11 +6,11 @@ import DragAndDrop from "@ogw_front/components/DragAndDrop";
|
|
|
6
6
|
|
|
7
7
|
const emit = defineEmits(["files_uploaded", "decrement_step", "reset_values"]);
|
|
8
8
|
|
|
9
|
-
const { multiple, accept, files,
|
|
9
|
+
const { multiple, accept, files, autoUpload, showOverlay, mini } = defineProps({
|
|
10
10
|
multiple: { type: Boolean, default: false },
|
|
11
11
|
accept: { type: String, default: "" },
|
|
12
12
|
files: { type: Array, default: () => [] },
|
|
13
|
-
|
|
13
|
+
autoUpload: { type: Boolean, default: true },
|
|
14
14
|
showOverlay: { type: Boolean, default: false },
|
|
15
15
|
mini: { type: Boolean, default: false },
|
|
16
16
|
});
|
|
@@ -94,7 +94,7 @@ watch(
|
|
|
94
94
|
|
|
95
95
|
const allConfigured = newFiles.every((file) => !isCsv(file) || file.isConfigured);
|
|
96
96
|
|
|
97
|
-
if (
|
|
97
|
+
if (autoUpload && allConfigured) {
|
|
98
98
|
await upload_files();
|
|
99
99
|
}
|
|
100
100
|
},
|
|
@@ -103,7 +103,7 @@ watch(
|
|
|
103
103
|
|
|
104
104
|
if (files.length > 0) {
|
|
105
105
|
internal_files.value = files;
|
|
106
|
-
if (
|
|
106
|
+
if (autoUpload) {
|
|
107
107
|
upload_files();
|
|
108
108
|
}
|
|
109
109
|
}
|
|
@@ -216,7 +216,7 @@ watch(
|
|
|
216
216
|
</v-sheet>
|
|
217
217
|
</v-card-text>
|
|
218
218
|
|
|
219
|
-
<v-card-actions v-if="!
|
|
219
|
+
<v-card-actions v-if="!autoUpload && internal_files.length" class="mt-8 pa-0">
|
|
220
220
|
<v-btn
|
|
221
221
|
color="primary"
|
|
222
222
|
variant="flat"
|
|
@@ -5,8 +5,8 @@ import { useBackStore } from "@ogw_front/stores/back";
|
|
|
5
5
|
const schema = schemas.opengeodeweb_back.inspect_file;
|
|
6
6
|
|
|
7
7
|
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
|
|
8
|
-
const {
|
|
9
|
-
|
|
8
|
+
const { geodeObjectType, filename } = defineProps({
|
|
9
|
+
geodeObjectType: { type: String, required: true },
|
|
10
10
|
filename: { type: String, required: true },
|
|
11
11
|
});
|
|
12
12
|
const loading = ref(false);
|
|
@@ -15,7 +15,7 @@ const toggle_loading = useToggle(loading);
|
|
|
15
15
|
async function get_inspection_results() {
|
|
16
16
|
toggle_loading();
|
|
17
17
|
const params = {
|
|
18
|
-
geode_object_type,
|
|
18
|
+
geode_object_type: geodeObjectType,
|
|
19
19
|
filename,
|
|
20
20
|
};
|
|
21
21
|
const backStore = useBackStore();
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import InspectorResultPanel from "@ogw_front/components/Inspector/ResultPanel";
|
|
3
3
|
|
|
4
|
-
const {
|
|
5
|
-
|
|
4
|
+
const { inspectionResult } = defineProps({
|
|
5
|
+
inspectionResult: { type: Array, required: true },
|
|
6
6
|
});
|
|
7
7
|
const opened_panels = ref([]);
|
|
8
8
|
|
|
9
9
|
onMounted(() => {
|
|
10
|
-
opened_panels.value =
|
|
10
|
+
opened_panels.value = inspectionResult
|
|
11
11
|
.map((result, i) => (result.nb_issues > 0 ? i : -1))
|
|
12
12
|
.filter((index) => index !== -1);
|
|
13
13
|
});
|
|
@@ -16,7 +16,7 @@ onMounted(() => {
|
|
|
16
16
|
<template>
|
|
17
17
|
<v-container class="pa-2">
|
|
18
18
|
<v-expansion-panels v-model="opened_panels" multiple elevation="5">
|
|
19
|
-
<v-expansion-panel v-for="(result, index) in
|
|
19
|
+
<v-expansion-panel v-for="(result, index) in inspectionResult" :key="index" class="card">
|
|
20
20
|
<v-expansion-panel-title>
|
|
21
21
|
<v-row align="center">
|
|
22
22
|
<v-col cols="auto">
|
|
@@ -31,7 +31,7 @@ onMounted(() => {
|
|
|
31
31
|
</v-row>
|
|
32
32
|
</v-expansion-panel-title>
|
|
33
33
|
<v-expansion-panel-text>
|
|
34
|
-
<InspectorResultPanel v-if="result.children" :
|
|
34
|
+
<InspectorResultPanel v-if="result.children" :inspectionResult="result.children" />
|
|
35
35
|
<v-container v-if="result.issues">
|
|
36
36
|
<v-col>
|
|
37
37
|
<v-row v-for="(issue, index) in result.issues" :key="index" class="pa-0">
|
|
@@ -9,9 +9,9 @@ const schema = schemas.opengeodeweb_back.missing_files;
|
|
|
9
9
|
|
|
10
10
|
const emit = defineEmits(["update_values", "increment_step", "decrement_step"]);
|
|
11
11
|
|
|
12
|
-
const { multiple,
|
|
12
|
+
const { multiple, geodeObjectType, filenames, files } = defineProps({
|
|
13
13
|
multiple: { type: Boolean, required: true },
|
|
14
|
-
|
|
14
|
+
geodeObjectType: { type: String, required: true },
|
|
15
15
|
filenames: { type: Array, required: true },
|
|
16
16
|
files: { type: Array, required: false, default: () => [] },
|
|
17
17
|
});
|
|
@@ -47,7 +47,7 @@ async function missing_files() {
|
|
|
47
47
|
additional_files: [],
|
|
48
48
|
});
|
|
49
49
|
}
|
|
50
|
-
const params = { geode_object_type, filename };
|
|
50
|
+
const params = { geode_object_type: geodeObjectType, filename };
|
|
51
51
|
return backStore.request({ schema, params });
|
|
52
52
|
});
|
|
53
53
|
const values = await Promise.all(promise_array);
|
|
@@ -99,7 +99,7 @@ await missing_files();
|
|
|
99
99
|
<v-row>
|
|
100
100
|
<v-col cols="12">
|
|
101
101
|
<FileUploader
|
|
102
|
-
v-bind="{ multiple, accept, files,
|
|
102
|
+
v-bind="{ multiple, accept, files, autoUpload: false }"
|
|
103
103
|
@files_uploaded="files_uploaded_event"
|
|
104
104
|
/>
|
|
105
105
|
</v-col>
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { useInfraStore } from "@ogw_front/stores/infra";
|
|
3
3
|
|
|
4
|
-
const {
|
|
5
|
-
|
|
4
|
+
const { buttonLabel, buttonColor, color } = defineProps({
|
|
5
|
+
buttonLabel: {
|
|
6
6
|
type: String,
|
|
7
7
|
required: false,
|
|
8
8
|
default: "Load the app",
|
|
9
9
|
},
|
|
10
|
-
|
|
10
|
+
buttonColor: {
|
|
11
11
|
type: String,
|
|
12
12
|
required: false,
|
|
13
13
|
default: "white",
|
|
@@ -69,7 +69,7 @@ function submit() {
|
|
|
69
69
|
</VRow>
|
|
70
70
|
<VRow align="center" justify="center">
|
|
71
71
|
<VCol cols="auto" class="d-flex justify-center align-center">
|
|
72
|
-
<VBtn class="load-btn" :text="
|
|
72
|
+
<VBtn class="load-btn" :text="buttonLabel" :color="color || buttonColor" @click="submit" />
|
|
73
73
|
</VCol>
|
|
74
74
|
</VRow>
|
|
75
75
|
</template>
|
package/app/components/Step.vue
CHANGED
|
@@ -6,18 +6,18 @@ function truncate(text, maxLength) {
|
|
|
6
6
|
return text;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
const {
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
const { stepIndex, stepperTree } = defineProps({
|
|
10
|
+
stepIndex: { type: Number, required: true },
|
|
11
|
+
stepperTree: { type: Object, required: true },
|
|
12
12
|
});
|
|
13
13
|
|
|
14
14
|
const emit = defineEmits(["reset_values"]);
|
|
15
15
|
|
|
16
|
-
const { state, increment_step, decrement_step, update_values } =
|
|
16
|
+
const { state, increment_step, decrement_step, update_values } = stepperTree;
|
|
17
17
|
const { current_step_index, steps } = toRefs(state);
|
|
18
18
|
|
|
19
19
|
const sortedChips = computed(() => {
|
|
20
|
-
const chips = steps.value[
|
|
20
|
+
const chips = steps.value[stepIndex]?.chips || [];
|
|
21
21
|
return chips.toSorted((chipA, chipB) =>
|
|
22
22
|
chipA.localeCompare(chipB, undefined, {
|
|
23
23
|
numeric: true,
|
|
@@ -29,8 +29,8 @@ const sortedChips = computed(() => {
|
|
|
29
29
|
|
|
30
30
|
<template>
|
|
31
31
|
<v-stepper-vertical-item
|
|
32
|
-
:value="
|
|
33
|
-
:editable="
|
|
32
|
+
:value="stepIndex + 1"
|
|
33
|
+
:editable="stepIndex < current_step_index"
|
|
34
34
|
color="primary"
|
|
35
35
|
hide-actions
|
|
36
36
|
>
|
|
@@ -39,13 +39,13 @@ const sortedChips = computed(() => {
|
|
|
39
39
|
<p
|
|
40
40
|
tag="h3"
|
|
41
41
|
class="text-subtitle-1 font-weight-bold mb-0 transition-swing"
|
|
42
|
-
:class="current_step_index ===
|
|
42
|
+
:class="current_step_index === stepIndex ? 'text-primary' : 'text-grey-darken-1'"
|
|
43
43
|
>
|
|
44
|
-
{{ steps[
|
|
44
|
+
{{ steps[stepIndex].step_title }}
|
|
45
45
|
</p>
|
|
46
46
|
|
|
47
47
|
<v-sheet
|
|
48
|
-
v-if="sortedChips.length && current_step_index >=
|
|
48
|
+
v-if="sortedChips.length && current_step_index >= stepIndex"
|
|
49
49
|
color="transparent"
|
|
50
50
|
class="d-flex flex-wrap mt-2"
|
|
51
51
|
>
|
|
@@ -67,10 +67,10 @@ const sortedChips = computed(() => {
|
|
|
67
67
|
<v-divider class="mb-6 opacity-10" />
|
|
68
68
|
|
|
69
69
|
<component
|
|
70
|
-
v-if="
|
|
71
|
-
:key="
|
|
72
|
-
:is="steps[
|
|
73
|
-
v-bind="steps[
|
|
70
|
+
v-if="stepIndex === current_step_index"
|
|
71
|
+
:key="stepIndex"
|
|
72
|
+
:is="steps[stepIndex].component.component_name"
|
|
73
|
+
v-bind="steps[stepIndex].component.component_options"
|
|
74
74
|
@increment_step="increment_step"
|
|
75
75
|
@decrement_step="decrement_step"
|
|
76
76
|
@update_values="update_values"
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import Step from "@ogw_front/components/Step";
|
|
3
3
|
|
|
4
4
|
const emit = defineEmits(["reset_values", "close"]);
|
|
5
|
-
const {
|
|
6
|
-
|
|
5
|
+
const { stepperTree } = defineProps({
|
|
6
|
+
stepperTree: { type: Object, required: true },
|
|
7
7
|
});
|
|
8
|
-
const { state } =
|
|
8
|
+
const { state } = stepperTree;
|
|
9
9
|
const { steps, current_step_index } = toRefs(state);
|
|
10
10
|
</script>
|
|
11
11
|
|
|
@@ -30,8 +30,8 @@ const { steps, current_step_index } = toRefs(state);
|
|
|
30
30
|
<Step
|
|
31
31
|
v-for="(step, index) in steps"
|
|
32
32
|
:key="index"
|
|
33
|
-
:
|
|
34
|
-
:
|
|
33
|
+
:stepIndex="index"
|
|
34
|
+
:stepperTree="stepperTree"
|
|
35
35
|
@reset_values="emit('reset_values')"
|
|
36
36
|
/>
|
|
37
37
|
</v-stepper-vertical>
|
|
@@ -15,11 +15,11 @@ const menuStore = useMenuStore();
|
|
|
15
15
|
const theme = useTheme();
|
|
16
16
|
const primaryColor = computed(() => theme.current.value.colors.primary);
|
|
17
17
|
|
|
18
|
-
const { index, itemProps, tooltip,
|
|
18
|
+
const { index, itemProps, tooltip, btnImage } = defineProps({
|
|
19
19
|
index: { type: Number, required: true },
|
|
20
20
|
itemProps: { type: Object, required: true },
|
|
21
21
|
tooltip: { type: String, required: true },
|
|
22
|
-
|
|
22
|
+
btnImage: { type: String, required: true },
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
const buttonCoords = computed(() => {
|
|
@@ -141,7 +141,7 @@ function toggleOptions() {
|
|
|
141
141
|
:style="computedItemStyles"
|
|
142
142
|
>
|
|
143
143
|
<v-img
|
|
144
|
-
:src="
|
|
144
|
+
:src="btnImage"
|
|
145
145
|
height="28"
|
|
146
146
|
width="28"
|
|
147
147
|
style="pointer-events: none; object-fit: contain"
|
|
@@ -114,7 +114,7 @@ const edge_attribute_color_map = computed({
|
|
|
114
114
|
<ViewerContextMenuItem
|
|
115
115
|
data-testid="meshEdgesMenu"
|
|
116
116
|
:itemProps="itemProps"
|
|
117
|
-
:
|
|
117
|
+
:btnImage="EdgedCurveEdges"
|
|
118
118
|
tooltip="Edges options"
|
|
119
119
|
>
|
|
120
120
|
<template #options>
|
|
@@ -11,9 +11,9 @@ const dataStyleStore = useDataStyleStore();
|
|
|
11
11
|
const hybridViewerStore = useHybridViewerStore();
|
|
12
12
|
const { applyBatchStyle } = useBatchStyle();
|
|
13
13
|
|
|
14
|
-
const { itemProps,
|
|
14
|
+
const { itemProps, btnImage, tooltip } = defineProps({
|
|
15
15
|
itemProps: { type: Object, required: true },
|
|
16
|
-
|
|
16
|
+
btnImage: { type: String, required: true },
|
|
17
17
|
tooltip: { type: String, required: false, default: "Cells options" },
|
|
18
18
|
});
|
|
19
19
|
|
|
@@ -116,7 +116,7 @@ const cell_attribute_color_map = computed({
|
|
|
116
116
|
data-testid="meshCellsMenu"
|
|
117
117
|
:itemProps="itemProps"
|
|
118
118
|
:tooltip="tooltip"
|
|
119
|
-
:
|
|
119
|
+
:btnImage="btnImage"
|
|
120
120
|
>
|
|
121
121
|
<template #options>
|
|
122
122
|
<ViewerOptionsVisibilitySwitch data-testid="meshCellsVisibilitySwitch" v-model="visibility" />
|
|
@@ -12,9 +12,9 @@ const dataStyleStore = useDataStyleStore();
|
|
|
12
12
|
const hybridViewerStore = useHybridViewerStore();
|
|
13
13
|
const { applyBatchStyle } = useBatchStyle();
|
|
14
14
|
|
|
15
|
-
const { itemProps,
|
|
15
|
+
const { itemProps, btnImage, tooltip } = defineProps({
|
|
16
16
|
itemProps: { type: Object, required: true },
|
|
17
|
-
|
|
17
|
+
btnImage: { type: String, required: true },
|
|
18
18
|
tooltip: { type: String, required: false, default: "Edges options" },
|
|
19
19
|
});
|
|
20
20
|
|
|
@@ -63,7 +63,7 @@ const color = computed({
|
|
|
63
63
|
data-testid="meshEdgesMenu"
|
|
64
64
|
:itemProps="itemProps"
|
|
65
65
|
:tooltip="tooltip"
|
|
66
|
-
:
|
|
66
|
+
:btnImage="btnImage"
|
|
67
67
|
>
|
|
68
68
|
<template #options>
|
|
69
69
|
<ViewerOptionsVisibilitySwitch data-testid="meshEdgesVisibilitySwitch" v-model="visibility" />
|
|
@@ -12,9 +12,9 @@ const dataStyleStore = useDataStyleStore();
|
|
|
12
12
|
const hybridViewerStore = useHybridViewerStore();
|
|
13
13
|
const { applyBatchStyle } = useBatchStyle();
|
|
14
14
|
|
|
15
|
-
const { itemProps,
|
|
15
|
+
const { itemProps, btnImage, tooltip } = defineProps({
|
|
16
16
|
itemProps: { type: Object, required: true },
|
|
17
|
-
|
|
17
|
+
btnImage: { type: String, required: true },
|
|
18
18
|
tooltip: { type: String, required: false, default: "Points options" },
|
|
19
19
|
});
|
|
20
20
|
|
|
@@ -90,7 +90,7 @@ const vertex_attribute_color_map = computed({
|
|
|
90
90
|
data-testid="meshPointsMenu"
|
|
91
91
|
:itemProps="itemProps"
|
|
92
92
|
:tooltip="tooltip"
|
|
93
|
-
:
|
|
93
|
+
:btnImage="btnImage"
|
|
94
94
|
>
|
|
95
95
|
<template #options>
|
|
96
96
|
<ViewerOptionsVisibilitySwitch
|
|
@@ -11,9 +11,9 @@ const dataStyleStore = useDataStyleStore();
|
|
|
11
11
|
const hybridViewerStore = useHybridViewerStore();
|
|
12
12
|
const { applyBatchStyle } = useBatchStyle();
|
|
13
13
|
|
|
14
|
-
const { itemProps,
|
|
14
|
+
const { itemProps, btnImage, tooltip } = defineProps({
|
|
15
15
|
itemProps: { type: Object, required: true },
|
|
16
|
-
|
|
16
|
+
btnImage: { type: String, required: true },
|
|
17
17
|
tooltip: { type: String, required: false, default: "Polygons options" },
|
|
18
18
|
});
|
|
19
19
|
|
|
@@ -62,7 +62,7 @@ const textures = computed({
|
|
|
62
62
|
data-testid="meshPolygonsMenu"
|
|
63
63
|
:itemProps="itemProps"
|
|
64
64
|
:tooltip="tooltip"
|
|
65
|
-
:
|
|
65
|
+
:btnImage="btnImage"
|
|
66
66
|
>
|
|
67
67
|
<template #options>
|
|
68
68
|
<ViewerOptionsVisibilitySwitch
|
|
@@ -11,9 +11,9 @@ const dataStyleStore = useDataStyleStore();
|
|
|
11
11
|
const hybridViewerStore = useHybridViewerStore();
|
|
12
12
|
const { applyBatchStyle } = useBatchStyle();
|
|
13
13
|
|
|
14
|
-
const { itemProps,
|
|
14
|
+
const { itemProps, btnImage, tooltip } = defineProps({
|
|
15
15
|
itemProps: { type: Object, required: true },
|
|
16
|
-
|
|
16
|
+
btnImage: { type: String, required: true },
|
|
17
17
|
tooltip: { type: String, required: false, default: "Polyhedra options" },
|
|
18
18
|
});
|
|
19
19
|
|
|
@@ -109,7 +109,7 @@ const polyhedron_attribute_color_map = computed({
|
|
|
109
109
|
data-testid="meshPolyhedraMenu"
|
|
110
110
|
:itemProps="itemProps"
|
|
111
111
|
:tooltip="tooltip"
|
|
112
|
-
:
|
|
112
|
+
:btnImage="btnImage"
|
|
113
113
|
>
|
|
114
114
|
<template #options>
|
|
115
115
|
<ViewerOptionsVisibilitySwitch
|
|
@@ -8,7 +8,7 @@ const { max, min } = defineProps({
|
|
|
8
8
|
max: { type: Number, required: true },
|
|
9
9
|
});
|
|
10
10
|
|
|
11
|
-
const selectedPresetName = defineModel("selectedPresetName", { default: "batlow" });
|
|
11
|
+
const selectedPresetName = defineModel("selectedPresetName", { type: String, default: "batlow" });
|
|
12
12
|
|
|
13
13
|
const menuOpen = ref(false);
|
|
14
14
|
const lutCanvas = ref();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
// oxlint-disable id-length
|
|
3
3
|
const colorPickerRef = useTemplateRef("colorPickerRef");
|
|
4
|
-
const model = defineModel();
|
|
4
|
+
const model = defineModel({ type: Object });
|
|
5
5
|
const { pressed } = useMousePressed({ target: colorPickerRef });
|
|
6
6
|
|
|
7
7
|
const vuetifyColor = ref({
|
|
@@ -39,6 +39,7 @@ watch(pressed, (value) => {
|
|
|
39
39
|
<template>
|
|
40
40
|
<v-color-picker
|
|
41
41
|
ref="colorPickerRef"
|
|
42
|
+
data-testid="colorPicker"
|
|
42
43
|
v-model="vuetifyColor"
|
|
43
44
|
flat
|
|
44
45
|
canvas-height="75"
|
|
@@ -4,30 +4,32 @@ import ViewerOptionsColorPicker from "@ogw_front/components/Viewer/Options/Color
|
|
|
4
4
|
import ViewerOptionsTexturesSelector from "@ogw_front/components/Viewer/Options/TexturesSelector.vue";
|
|
5
5
|
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json";
|
|
6
6
|
|
|
7
|
-
const coloring_style_key = defineModel("coloring_style_key");
|
|
7
|
+
const coloring_style_key = defineModel("coloring_style_key", { type: String });
|
|
8
8
|
|
|
9
|
-
const color = defineModel("color");
|
|
10
|
-
const textures = defineModel("textures");
|
|
9
|
+
const color = defineModel("color", { type: Object });
|
|
10
|
+
const textures = defineModel("textures", { type: Array });
|
|
11
11
|
|
|
12
|
-
const vertex_attribute_name = defineModel("vertex_attribute_name");
|
|
13
|
-
const vertex_attribute_range = defineModel("vertex_attribute_range");
|
|
14
|
-
const vertex_attribute_color_map = defineModel("vertex_attribute_color_map");
|
|
12
|
+
const vertex_attribute_name = defineModel("vertex_attribute_name", { type: String });
|
|
13
|
+
const vertex_attribute_range = defineModel("vertex_attribute_range", { type: Array });
|
|
14
|
+
const vertex_attribute_color_map = defineModel("vertex_attribute_color_map", { type: String });
|
|
15
15
|
|
|
16
|
-
const edge_attribute_name = defineModel("edge_attribute_name");
|
|
17
|
-
const edge_attribute_range = defineModel("edge_attribute_range");
|
|
18
|
-
const edge_attribute_color_map = defineModel("edge_attribute_color_map");
|
|
16
|
+
const edge_attribute_name = defineModel("edge_attribute_name", { type: String });
|
|
17
|
+
const edge_attribute_range = defineModel("edge_attribute_range", { type: Array });
|
|
18
|
+
const edge_attribute_color_map = defineModel("edge_attribute_color_map", { type: String });
|
|
19
19
|
|
|
20
|
-
const cell_attribute_name = defineModel("cell_attribute_name");
|
|
21
|
-
const cell_attribute_range = defineModel("cell_attribute_range");
|
|
22
|
-
const cell_attribute_color_map = defineModel("cell_attribute_color_map");
|
|
20
|
+
const cell_attribute_name = defineModel("cell_attribute_name", { type: String });
|
|
21
|
+
const cell_attribute_range = defineModel("cell_attribute_range", { type: Array });
|
|
22
|
+
const cell_attribute_color_map = defineModel("cell_attribute_color_map", { type: String });
|
|
23
23
|
|
|
24
|
-
const polygon_attribute_name = defineModel("polygon_attribute_name");
|
|
25
|
-
const polygon_attribute_range = defineModel("polygon_attribute_range");
|
|
26
|
-
const polygon_attribute_color_map = defineModel("polygon_attribute_color_map");
|
|
24
|
+
const polygon_attribute_name = defineModel("polygon_attribute_name", { type: String });
|
|
25
|
+
const polygon_attribute_range = defineModel("polygon_attribute_range", { type: Array });
|
|
26
|
+
const polygon_attribute_color_map = defineModel("polygon_attribute_color_map", { type: String });
|
|
27
27
|
|
|
28
|
-
const polyhedron_attribute_name = defineModel("polyhedron_attribute_name");
|
|
29
|
-
const polyhedron_attribute_range = defineModel("polyhedron_attribute_range");
|
|
30
|
-
const polyhedron_attribute_color_map = defineModel("polyhedron_attribute_color_map"
|
|
28
|
+
const polyhedron_attribute_name = defineModel("polyhedron_attribute_name", { type: String });
|
|
29
|
+
const polyhedron_attribute_range = defineModel("polyhedron_attribute_range", { type: Array });
|
|
30
|
+
const polyhedron_attribute_color_map = defineModel("polyhedron_attribute_color_map", {
|
|
31
|
+
type: String,
|
|
32
|
+
});
|
|
31
33
|
|
|
32
34
|
const {
|
|
33
35
|
id,
|
|
@@ -7,17 +7,17 @@ const emit = defineEmits(["update_value"]);
|
|
|
7
7
|
|
|
8
8
|
const { id } = defineProps({
|
|
9
9
|
id: { type: String, required: true },
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
textureId: { type: String, required: true },
|
|
11
|
+
textureName: { type: String, required: true },
|
|
12
12
|
});
|
|
13
13
|
|
|
14
|
-
const
|
|
15
|
-
|
|
14
|
+
const textureName = ref("");
|
|
15
|
+
textureName.value = textureName;
|
|
16
16
|
|
|
17
|
-
const
|
|
18
|
-
|
|
17
|
+
const textureId = ref("");
|
|
18
|
+
textureId.value = textureId;
|
|
19
19
|
|
|
20
|
-
const
|
|
20
|
+
const textureCoordinates = ref([]);
|
|
21
21
|
const backStore = useBackStore();
|
|
22
22
|
|
|
23
23
|
onMounted(() => {
|
|
@@ -31,7 +31,7 @@ function getTextureCoordinates() {
|
|
|
31
31
|
{ schema, params },
|
|
32
32
|
{
|
|
33
33
|
response_function: (response) => {
|
|
34
|
-
|
|
34
|
+
textureCoordinates.value = response.texture_coordinates;
|
|
35
35
|
},
|
|
36
36
|
},
|
|
37
37
|
);
|
|
@@ -48,18 +48,18 @@ async function files_uploaded_event(value) {
|
|
|
48
48
|
{ schema, params },
|
|
49
49
|
{
|
|
50
50
|
response_function: (response) => {
|
|
51
|
-
|
|
51
|
+
textureId.value = response.id;
|
|
52
52
|
},
|
|
53
53
|
},
|
|
54
54
|
);
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
watch(
|
|
58
|
+
watch(textureName, (value) => {
|
|
59
59
|
emit("update_value", { key: "texture_name", value });
|
|
60
60
|
});
|
|
61
61
|
|
|
62
|
-
watch(
|
|
62
|
+
watch(textureId, (value) => {
|
|
63
63
|
emit("update_value", { key: "id", value });
|
|
64
64
|
});
|
|
65
65
|
</script>
|
|
@@ -73,8 +73,8 @@ watch(texture_id, (value) => {
|
|
|
73
73
|
<template>
|
|
74
74
|
<v-col cols="8" class="pa-1">
|
|
75
75
|
<v-select
|
|
76
|
-
v-model="
|
|
77
|
-
:items="
|
|
76
|
+
v-model="textureName"
|
|
77
|
+
:items="textureCoordinates"
|
|
78
78
|
label="Select a texture"
|
|
79
79
|
density="compact"
|
|
80
80
|
hide-details
|
|
@@ -92,14 +92,14 @@ watch(texture_id, (value) => {
|
|
|
92
92
|
<FileUploader
|
|
93
93
|
@files_uploaded="files_uploaded_event($event, index)"
|
|
94
94
|
:accept="['image/png', 'image/jpeg', 'image/bmp']"
|
|
95
|
-
:
|
|
95
|
+
:autoUpload="true"
|
|
96
96
|
:multiple="true"
|
|
97
97
|
:mini="true"
|
|
98
98
|
class="mt-2"
|
|
99
99
|
/>
|
|
100
100
|
</v-col>
|
|
101
101
|
</v-badge>
|
|
102
|
-
<v-col v-if="
|
|
102
|
+
<v-col v-if="textureName == '' || texture_file_name == ''" cols="1">
|
|
103
103
|
<v-icon size="20" icon="mdi-close-circle" v-tooltip:bottom="'Invalid texture'" />
|
|
104
104
|
</v-col>
|
|
105
105
|
</template>
|
|
@@ -108,7 +108,7 @@ const polyhedron_attribute_color_map = computed({
|
|
|
108
108
|
data-testid="meshPolyhedraMenu"
|
|
109
109
|
:itemProps="itemProps"
|
|
110
110
|
:tooltip="tooltip"
|
|
111
|
-
:
|
|
111
|
+
:btnImage="SolidPolyhedra"
|
|
112
112
|
>
|
|
113
113
|
<template #options>
|
|
114
114
|
<ViewerOptionsVisibilitySwitch
|
|
@@ -116,7 +116,7 @@ const polygon_attribute_color_map = computed({
|
|
|
116
116
|
data-testid="meshPolygonsMenu"
|
|
117
117
|
:itemProps="itemProps"
|
|
118
118
|
:tooltip="tooltip"
|
|
119
|
-
:
|
|
119
|
+
:btnImage="PolygonalSurfacePolygons"
|
|
120
120
|
>
|
|
121
121
|
<template #options>
|
|
122
122
|
<ViewerOptionsVisibilitySwitch
|
|
@@ -7,8 +7,8 @@ import { useInfraStore } from "@ogw_front/stores/infra";
|
|
|
7
7
|
|
|
8
8
|
const infraStore = useInfraStore();
|
|
9
9
|
|
|
10
|
-
const {
|
|
11
|
-
|
|
10
|
+
const { versionsSchema, appName } = defineProps({
|
|
11
|
+
versionsSchema: { type: Object, required: true },
|
|
12
12
|
appName: { type: String, required: true },
|
|
13
13
|
});
|
|
14
14
|
</script>
|
|
@@ -26,7 +26,7 @@ const { versions_schema, appName } = defineProps({
|
|
|
26
26
|
<Stepper />
|
|
27
27
|
</v-col>
|
|
28
28
|
<v-col>
|
|
29
|
-
<PackagesVersions :schema="
|
|
29
|
+
<PackagesVersions :schema="versionsSchema" />
|
|
30
30
|
</v-col>
|
|
31
31
|
</template>
|
|
32
32
|
</v-row>
|
package/package.json
CHANGED
package/server/utils/cloud.js
CHANGED
|
@@ -40,7 +40,7 @@ describe("crs selector", () => {
|
|
|
40
40
|
global: {
|
|
41
41
|
plugins: [vuetify, pinia],
|
|
42
42
|
},
|
|
43
|
-
props: {
|
|
43
|
+
props: { geodeObjectType: "BRep", keyToUpdate: key_to_update },
|
|
44
44
|
});
|
|
45
45
|
const td_wrapper = await wrapper.find("td");
|
|
46
46
|
await wrapper.vm.$nextTick();
|
|
@@ -34,7 +34,7 @@ describe("file selector", () => {
|
|
|
34
34
|
global: {
|
|
35
35
|
plugins: [vuetify, pinia],
|
|
36
36
|
},
|
|
37
|
-
props: { multiple: false,
|
|
37
|
+
props: { multiple: false, autoUpload: false },
|
|
38
38
|
});
|
|
39
39
|
|
|
40
40
|
const file_uploader = wrapper.findComponent(FileUploader);
|
|
@@ -46,7 +46,7 @@ describe("file selector", () => {
|
|
|
46
46
|
|
|
47
47
|
const v_file_input = file_uploader.find('input[type="file"]');
|
|
48
48
|
const files = [new File(["fake_file"], "fake_file.txt")];
|
|
49
|
-
const
|
|
49
|
+
const autoUpload = false;
|
|
50
50
|
Object.defineProperty(v_file_input.element, "files", {
|
|
51
51
|
value: files,
|
|
52
52
|
writable: true,
|
|
@@ -61,7 +61,7 @@ describe("file selector", () => {
|
|
|
61
61
|
expect(wrapper.emitted().update_values).toHaveLength(EXPECTED_LENGTH);
|
|
62
62
|
expect(wrapper.emitted().update_values[FIRST_INDEX][FIRST_INDEX]).toStrictEqual({
|
|
63
63
|
files,
|
|
64
|
-
|
|
64
|
+
autoUpload,
|
|
65
65
|
});
|
|
66
66
|
});
|
|
67
67
|
|
|
@@ -87,7 +87,7 @@ describe("file selector", () => {
|
|
|
87
87
|
props: {
|
|
88
88
|
multiple: false,
|
|
89
89
|
files,
|
|
90
|
-
|
|
90
|
+
autoUpload: true,
|
|
91
91
|
},
|
|
92
92
|
});
|
|
93
93
|
|
|
@@ -97,7 +97,7 @@ describe("file selector", () => {
|
|
|
97
97
|
expect(wrapper.emitted().update_values).toHaveLength(EXPECTED_LENGTH);
|
|
98
98
|
expect(wrapper.emitted().update_values[FIRST_INDEX][FIRST_INDEX]).toStrictEqual({
|
|
99
99
|
files,
|
|
100
|
-
|
|
100
|
+
autoUpload: false,
|
|
101
101
|
});
|
|
102
102
|
});
|
|
103
103
|
|
|
@@ -109,7 +109,7 @@ describe("file selector", () => {
|
|
|
109
109
|
props: {
|
|
110
110
|
multiple: false,
|
|
111
111
|
files,
|
|
112
|
-
|
|
112
|
+
autoUpload: false,
|
|
113
113
|
},
|
|
114
114
|
});
|
|
115
115
|
|
|
@@ -32,12 +32,12 @@ describe("file uploader", () => {
|
|
|
32
32
|
const files = [new File(["fake_file"], "fake_file.txt")];
|
|
33
33
|
|
|
34
34
|
describe("upload file", () => {
|
|
35
|
-
test("prop
|
|
35
|
+
test("prop autoUpload false", async () => {
|
|
36
36
|
const wrapper = await mountSuspended(FileUploader, {
|
|
37
37
|
global: {
|
|
38
38
|
plugins: [vuetify, pinia],
|
|
39
39
|
},
|
|
40
|
-
props: { multiple: false, accept: "*.txt",
|
|
40
|
+
props: { multiple: false, accept: "*.txt", autoUpload: false },
|
|
41
41
|
});
|
|
42
42
|
|
|
43
43
|
const v_file_input = wrapper.find('input[type="file"]');
|
|
@@ -55,12 +55,12 @@ describe("file uploader", () => {
|
|
|
55
55
|
expect(wrapper.emitted().files_uploaded[FIRST_INDEX][FIRST_INDEX]).toStrictEqual(files);
|
|
56
56
|
});
|
|
57
57
|
|
|
58
|
-
test(`prop
|
|
58
|
+
test(`prop autoUpload true`, async () => {
|
|
59
59
|
const wrapper = await mountSuspended(FileUploader, {
|
|
60
60
|
global: {
|
|
61
61
|
plugins: [vuetify, pinia],
|
|
62
62
|
},
|
|
63
|
-
props: { multiple: false, accept: "*.txt", files,
|
|
63
|
+
props: { multiple: false, accept: "*.txt", files, autoUpload: true },
|
|
64
64
|
});
|
|
65
65
|
await flushPromises();
|
|
66
66
|
expect(wrapper.emitted().files_uploaded[FIRST_INDEX][FIRST_INDEX]).toStrictEqual(files);
|
|
@@ -20,15 +20,15 @@ describe("inspector result panel", () => {
|
|
|
20
20
|
global: {
|
|
21
21
|
plugins: [vuetify],
|
|
22
22
|
},
|
|
23
|
-
props: { inspection_result },
|
|
23
|
+
props: { inspectionResult: inspection_result },
|
|
24
24
|
});
|
|
25
25
|
|
|
26
26
|
expect(wrapper.exists()).toBe(true);
|
|
27
|
-
expect(wrapper.componentVM.
|
|
27
|
+
expect(wrapper.componentVM.inspectionResult).toStrictEqual(inspection_result);
|
|
28
28
|
|
|
29
29
|
const child_result_panel_wrapper = await wrapper.findComponent(InspectorResultPanel);
|
|
30
30
|
expect(child_result_panel_wrapper.exists()).toBe(true);
|
|
31
|
-
expect(child_result_panel_wrapper.componentVM.
|
|
31
|
+
expect(child_result_panel_wrapper.componentVM.inspectionResult).toStrictEqual(
|
|
32
32
|
inspection_result[0].children,
|
|
33
33
|
);
|
|
34
34
|
});
|
|
@@ -44,13 +44,13 @@ describe("inspector result panel", () => {
|
|
|
44
44
|
global: {
|
|
45
45
|
plugins: [vuetify],
|
|
46
46
|
},
|
|
47
|
-
props: { inspection_result },
|
|
47
|
+
props: { inspectionResult: inspection_result },
|
|
48
48
|
});
|
|
49
49
|
|
|
50
50
|
expect(wrapper.exists()).toBe(true);
|
|
51
51
|
|
|
52
52
|
console.log({ wrapper });
|
|
53
53
|
|
|
54
|
-
expect(wrapper.componentVM.
|
|
54
|
+
expect(wrapper.componentVM.inspectionResult).toStrictEqual(inspection_result);
|
|
55
55
|
});
|
|
56
56
|
});
|