@geode/opengeodeweb-front 9.13.1-rc.8 → 9.13.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.
|
@@ -50,6 +50,9 @@
|
|
|
50
50
|
() => treeviewStore.selection,
|
|
51
51
|
(current, previous) => {
|
|
52
52
|
if (!previous) previous = []
|
|
53
|
+
if (current.value === previous) {
|
|
54
|
+
return
|
|
55
|
+
}
|
|
53
56
|
const { added, removed } = compareSelections(current, previous)
|
|
54
57
|
|
|
55
58
|
added.forEach((item) => {
|
|
@@ -71,7 +74,6 @@
|
|
|
71
74
|
})
|
|
72
75
|
hybridViewerStore.remoteRender()
|
|
73
76
|
},
|
|
74
|
-
{ immediate: true },
|
|
75
77
|
)
|
|
76
78
|
|
|
77
79
|
function isModel(item) {
|
package/package.json
CHANGED
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"build": ""
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"@nuxt/test-utils": "3.
|
|
14
|
-
"@pinia/testing": "0.
|
|
13
|
+
"@nuxt/test-utils": "3.20.1",
|
|
14
|
+
"@pinia/testing": "1.0.3",
|
|
15
15
|
"@vitejs/plugin-vue": "5.2.3",
|
|
16
16
|
"@vue/test-utils": "2.4.6",
|
|
17
17
|
"electron": "36.4.0",
|
|
@@ -25,7 +25,6 @@
|
|
|
25
25
|
"happy-dom": "17.4.6",
|
|
26
26
|
"jsdom": "26.1.0",
|
|
27
27
|
"msw": "2.11.1",
|
|
28
|
-
"nuxt": "3.13.2",
|
|
29
28
|
"playwright-core": "1.52.0",
|
|
30
29
|
"prettier": "3.3.3",
|
|
31
30
|
"resize-observer-polyfill": "1.5.1",
|
|
@@ -40,14 +39,14 @@
|
|
|
40
39
|
},
|
|
41
40
|
"description": "OpenSource Vue/Nuxt/Pinia/Vuetify framework for web applications",
|
|
42
41
|
"type": "module",
|
|
43
|
-
"version": "9.13.1
|
|
42
|
+
"version": "9.13.1",
|
|
44
43
|
"main": "./nuxt.config.js",
|
|
45
44
|
"dependencies": {
|
|
46
|
-
"@geode/opengeodeweb-back": "
|
|
47
|
-
"@geode/opengeodeweb-viewer": "
|
|
45
|
+
"@geode/opengeodeweb-back": "latest",
|
|
46
|
+
"@geode/opengeodeweb-viewer": "latest",
|
|
48
47
|
"@kitware/vtk.js": "33.3.0",
|
|
49
48
|
"@mdi/font": "7.4.47",
|
|
50
|
-
"@pinia/nuxt": "0.
|
|
49
|
+
"@pinia/nuxt": "0.11.3",
|
|
51
50
|
"@types/node": "22.15.3",
|
|
52
51
|
"@vueuse/components": "13.1.0",
|
|
53
52
|
"@vueuse/nuxt": "13.1.0",
|
|
@@ -55,8 +54,8 @@
|
|
|
55
54
|
"get-port-please": "3.2.0",
|
|
56
55
|
"is-electron": "2.2.2",
|
|
57
56
|
"js-file-download": "0.4.12",
|
|
58
|
-
"nuxt": "3.
|
|
59
|
-
"pinia": "3.0.
|
|
57
|
+
"nuxt": "3.20.1",
|
|
58
|
+
"pinia": "3.0.4",
|
|
60
59
|
"sass": "1.87.0",
|
|
61
60
|
"semver": "7.7.1",
|
|
62
61
|
"uuid": "11.1.0",
|
package/stores/geode.js
CHANGED
|
@@ -55,17 +55,17 @@ export const useGeodeStore = defineStore("geode", {
|
|
|
55
55
|
method: back_schemas.opengeodeweb_back.ping.methods[0],
|
|
56
56
|
body: {},
|
|
57
57
|
onRequestError({ error }) {
|
|
58
|
-
feedback_store
|
|
58
|
+
feedback_store.$patch({ server_error: true })
|
|
59
59
|
geode_store.status = Status.NOT_CONNECTED
|
|
60
60
|
},
|
|
61
61
|
onResponse({ response }) {
|
|
62
62
|
if (response.ok) {
|
|
63
|
-
feedback_store
|
|
63
|
+
feedback_store.$patch({ server_error: false })
|
|
64
64
|
geode_store.status = Status.CONNECTED
|
|
65
65
|
}
|
|
66
66
|
},
|
|
67
67
|
onResponseError({ response }) {
|
|
68
|
-
feedback_store
|
|
68
|
+
feedback_store.$patch({ server_error: true })
|
|
69
69
|
geode_store.status = Status.NOT_CONNECTED
|
|
70
70
|
},
|
|
71
71
|
})
|
|
@@ -9,7 +9,7 @@ import * as directives from "vuetify/directives"
|
|
|
9
9
|
import { setActivePinia } from "pinia"
|
|
10
10
|
import { createTestingPinia } from "@pinia/testing"
|
|
11
11
|
|
|
12
|
-
import Launcher from "
|
|
12
|
+
import Launcher from "~/components/Launcher.vue"
|
|
13
13
|
|
|
14
14
|
const vuetify = createVuetify({
|
|
15
15
|
components,
|
|
@@ -38,15 +38,14 @@ describe("Launcher.vue", async () => {
|
|
|
38
38
|
})
|
|
39
39
|
setActivePinia(pinia)
|
|
40
40
|
const infra_store = useInfraStore()
|
|
41
|
-
const spy_create_backend = vi.spyOn(infra_store, "create_backend")
|
|
42
41
|
const wrapper = await mountSuspended(Launcher, {
|
|
43
42
|
global: {
|
|
44
|
-
plugins: [vuetify],
|
|
43
|
+
plugins: [pinia, vuetify],
|
|
45
44
|
},
|
|
46
45
|
})
|
|
47
46
|
expect(wrapper.exists()).toBe(true)
|
|
48
47
|
await infra_store.$patch({ is_captcha_validated: true })
|
|
49
|
-
flushPromises()
|
|
50
|
-
expect(
|
|
48
|
+
await flushPromises()
|
|
49
|
+
expect(infra_store.create_backend).toHaveBeenCalled()
|
|
51
50
|
})
|
|
52
51
|
})
|
|
@@ -125,16 +125,13 @@ describe("Geode store", () => {
|
|
|
125
125
|
|
|
126
126
|
test("response", async () => {
|
|
127
127
|
const geode_store = useGeodeStore()
|
|
128
|
-
const feedback_store = useFeedbackStore()
|
|
129
128
|
geode_store.base_url = ""
|
|
130
129
|
getFakeCall.mockImplementation(() => ({}))
|
|
131
130
|
await geode_store.do_ping()
|
|
132
131
|
expect(geode_store.status).toBe(Status.CONNECTED)
|
|
133
|
-
expect(feedback_store.server_error).toBe(false)
|
|
134
132
|
})
|
|
135
133
|
test("response_error", async () => {
|
|
136
134
|
const geode_store = useGeodeStore()
|
|
137
|
-
const feedback_store = useFeedbackStore()
|
|
138
135
|
geode_store.base_url = ""
|
|
139
136
|
getFakeCall.mockImplementation(() => {
|
|
140
137
|
throw createError({
|
|
@@ -144,7 +141,6 @@ describe("Geode store", () => {
|
|
|
144
141
|
|
|
145
142
|
await geode_store.do_ping()
|
|
146
143
|
expect(geode_store.status).toBe(Status.NOT_CONNECTED)
|
|
147
|
-
expect(feedback_store.server_error).toBe(true)
|
|
148
144
|
})
|
|
149
145
|
})
|
|
150
146
|
|
|
@@ -4,7 +4,7 @@ import { useHybridViewerStore } from "../stores/hybrid_viewer"
|
|
|
4
4
|
|
|
5
5
|
// Local imports
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
function importWorkflow(files) {
|
|
8
8
|
console.log("importWorkflow", { files })
|
|
9
9
|
const promise_array = []
|
|
10
10
|
for (const file of files) {
|
|
@@ -24,10 +24,12 @@ async function importFile(filename, geode_object) {
|
|
|
24
24
|
schema: back_schemas.opengeodeweb_back.save_viewable_file,
|
|
25
25
|
params: {
|
|
26
26
|
input_geode_object: geode_object,
|
|
27
|
-
filename
|
|
27
|
+
filename,
|
|
28
28
|
},
|
|
29
29
|
})
|
|
30
30
|
|
|
31
|
+
console.log("data.value", data.value)
|
|
32
|
+
|
|
31
33
|
const {
|
|
32
34
|
id,
|
|
33
35
|
native_file_name,
|
|
@@ -35,12 +37,9 @@ async function importFile(filename, geode_object) {
|
|
|
35
37
|
name,
|
|
36
38
|
object_type,
|
|
37
39
|
binary_light_viewable,
|
|
38
|
-
} = data.
|
|
39
|
-
|
|
40
|
-
console.log("data._value", data._value)
|
|
40
|
+
} = data.value
|
|
41
41
|
|
|
42
|
-
|
|
43
|
-
await dataBaseStore.registerObject(data._value.id)
|
|
42
|
+
await dataBaseStore.registerObject(id)
|
|
44
43
|
console.log("after dataBaseStore.registerObject")
|
|
45
44
|
await dataBaseStore.addItem(id, {
|
|
46
45
|
object_type: object_type,
|
|
@@ -60,13 +59,9 @@ async function importFile(filename, geode_object) {
|
|
|
60
59
|
await hybridViewerStore.addItem(id)
|
|
61
60
|
console.log("after dataBaseStore.addItem")
|
|
62
61
|
|
|
63
|
-
await dataStyleStore.addDataStyle(
|
|
64
|
-
data._value.id,
|
|
65
|
-
data._value.geode_object,
|
|
66
|
-
data._value.object_type,
|
|
67
|
-
)
|
|
62
|
+
await dataStyleStore.addDataStyle(id, geode_object, object_type)
|
|
68
63
|
console.log("after dataStyleStore.addDataStyle")
|
|
69
|
-
if (
|
|
64
|
+
if (object_type === "model") {
|
|
70
65
|
await Promise.all([
|
|
71
66
|
dataBaseStore.fetchMeshComponents(id),
|
|
72
67
|
dataBaseStore.fetchUuidToFlatIndexDict(id),
|
|
@@ -77,7 +72,7 @@ async function importFile(filename, geode_object) {
|
|
|
77
72
|
await dataStyleStore.applyDefaultStyle(id)
|
|
78
73
|
console.log("after dataStyleStore.applyDefaultStyle")
|
|
79
74
|
hybridViewerStore.remoteRender()
|
|
80
|
-
return
|
|
75
|
+
return id
|
|
81
76
|
}
|
|
82
77
|
|
|
83
78
|
export { importFile, importWorkflow }
|