@geode/opengeodeweb-front 10.3.1 → 10.3.2-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/app/components/Viewer/EdgedCurve/SpecificEdgesOptions.vue +0 -2
- package/app/components/Viewer/Generic/Mesh/CellsOptions.vue +0 -4
- package/app/components/Viewer/Generic/Mesh/EdgesOptions.vue +59 -0
- package/app/components/Viewer/Generic/Mesh/PointsOptions.vue +31 -0
- package/app/components/Viewer/Generic/Mesh/PolygonsOptions.vue +68 -0
- package/app/components/Viewer/Generic/Mesh/PolyhedraOptions.vue +71 -0
- package/app/components/Viewer/Options/AttributeColorBar.vue +2 -0
- package/app/components/Viewer/Options/AttributeSelector.vue +112 -0
- package/app/components/Viewer/Options/ColoringTypeSelector.vue +31 -29
- package/app/components/Viewer/PointSet/SpecificPointsOptions.vue +0 -2
- package/app/components/Viewer/PolygonalSurface/SpecificPolygonsOptions.vue +0 -4
- package/app/components/Viewer/Solid/SpecificPolyhedraOptions.vue +0 -4
- package/internal/stores/data_style/mesh/cells/cell.js +20 -34
- package/internal/stores/data_style/mesh/cells/vertex.js +20 -34
- package/internal/stores/data_style/mesh/edges/edge.js +84 -86
- package/internal/stores/data_style/mesh/edges/vertex.js +20 -34
- package/internal/stores/data_style/mesh/points/vertex.js +20 -34
- package/internal/stores/data_style/mesh/polygons/polygon.js +23 -38
- package/internal/stores/data_style/mesh/polygons/vertex.js +20 -34
- package/internal/stores/data_style/mesh/polyhedra/polyhedron.js +19 -32
- package/internal/stores/data_style/mesh/polyhedra/vertex.js +20 -34
- package/package.json +3 -3
- package/tests/integration/microservices/viewer/requirements.txt +1 -1
- package/app/components/Viewer/Options/CellAttributeSelector.vue +0 -87
- package/app/components/Viewer/Options/EdgeAttributeSelector.vue +0 -84
- package/app/components/Viewer/Options/PolygonAttributeSelector.vue +0 -85
- package/app/components/Viewer/Options/PolyhedronAttributeSelector.vue +0 -91
- package/app/components/Viewer/Options/VertexAttributeSelector.vue +0 -84
|
@@ -18,26 +18,15 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
18
18
|
return meshPolygonsCommonStyle.meshPolygonsColoring(id).polygon
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
async function updateMeshPolygonsPolygonAttribute(id) {
|
|
22
|
-
const name = meshPolygonsPolygonAttributeName(id)
|
|
23
|
-
const storedConfig = meshPolygonsPolygonAttributeStoredConfig(id, name)
|
|
24
|
-
await meshPolygonsPolygonAttributeRange(
|
|
25
|
-
id,
|
|
26
|
-
storedConfig.minimum,
|
|
27
|
-
storedConfig.maximum,
|
|
28
|
-
)
|
|
29
|
-
await meshPolygonsPolygonAttributeColorMap(id, storedConfig.colorMap)
|
|
30
|
-
}
|
|
31
|
-
|
|
32
21
|
function meshPolygonsPolygonAttributeStoredConfig(id, name) {
|
|
33
22
|
const { storedConfigs } = meshPolygonsPolygonAttribute(id)
|
|
34
23
|
if (name in storedConfigs) {
|
|
35
24
|
return storedConfigs[name]
|
|
36
25
|
}
|
|
37
26
|
return setMeshPolygonsPolygonAttributeStoredConfig(id, name, {
|
|
38
|
-
minimum:
|
|
39
|
-
maximum:
|
|
40
|
-
colorMap:
|
|
27
|
+
minimum: undefined,
|
|
28
|
+
maximum: undefined,
|
|
29
|
+
colorMap: undefined,
|
|
41
30
|
})
|
|
42
31
|
}
|
|
43
32
|
|
|
@@ -46,7 +35,7 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
46
35
|
name,
|
|
47
36
|
{ minimum, maximum, colorMap },
|
|
48
37
|
) {
|
|
49
|
-
const
|
|
38
|
+
const storedConfigs = meshPolygonsPolygonAttribute(id).storedConfigs
|
|
50
39
|
storedConfigs[name] = { minimum, maximum, colorMap }
|
|
51
40
|
return storedConfigs[name]
|
|
52
41
|
}
|
|
@@ -59,8 +48,13 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
59
48
|
meshPolygonsPolygonAttributeSchemas.name,
|
|
60
49
|
{ id, name },
|
|
61
50
|
{
|
|
62
|
-
response_function: () => {
|
|
51
|
+
response_function: async () => {
|
|
63
52
|
meshPolygonsPolygonAttribute(id).name = name
|
|
53
|
+
const { minimum, maximum } = meshPolygonsPolygonAttributeStoredConfig(
|
|
54
|
+
id,
|
|
55
|
+
name,
|
|
56
|
+
)
|
|
57
|
+
await setMeshPolygonsPolygonAttributeRange(id, minimum, maximum)
|
|
64
58
|
console.log(
|
|
65
59
|
setMeshPolygonsPolygonAttributeName.name,
|
|
66
60
|
{ id },
|
|
@@ -81,29 +75,12 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
81
75
|
)
|
|
82
76
|
return [minimum, maximum]
|
|
83
77
|
}
|
|
84
|
-
|
|
85
|
-
console.log(setMeshPolygonsPolygonAttributeRange.name, {
|
|
86
|
-
id,
|
|
87
|
-
minimum,
|
|
88
|
-
maximum,
|
|
89
|
-
})
|
|
78
|
+
function setMeshPolygonsPolygonAttributeRange(id, minimum, maximum) {
|
|
90
79
|
const name = meshPolygonsPolygonAttributeName(id)
|
|
91
80
|
const storedConfig = meshPolygonsPolygonAttributeStoredConfig(id, name)
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
{
|
|
96
|
-
response_function: () => {
|
|
97
|
-
storedConfig.minimum = minimum
|
|
98
|
-
storedConfig.maximum = maximum
|
|
99
|
-
console.log(
|
|
100
|
-
setMeshPolygonsPolygonAttributeRange.name,
|
|
101
|
-
{ id },
|
|
102
|
-
meshPolygonsPolygonAttributeRange(id),
|
|
103
|
-
)
|
|
104
|
-
},
|
|
105
|
-
},
|
|
106
|
-
)
|
|
81
|
+
storedConfig.minimum = minimum
|
|
82
|
+
storedConfig.maximum = maximum
|
|
83
|
+
return setMeshPolygonsPolygonAttributeColorMap(id, storedConfig.colorMap)
|
|
107
84
|
}
|
|
108
85
|
|
|
109
86
|
function meshPolygonsPolygonAttributeColorMap(id) {
|
|
@@ -115,6 +92,14 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
115
92
|
function setMeshPolygonsPolygonAttributeColorMap(id, colorMap) {
|
|
116
93
|
const name = meshPolygonsPolygonAttributeName(id)
|
|
117
94
|
const storedConfig = meshPolygonsPolygonAttributeStoredConfig(id, name)
|
|
95
|
+
if (
|
|
96
|
+
storedConfig.minimum === undefined ||
|
|
97
|
+
storedConfig.maximum === undefined ||
|
|
98
|
+
colorMap === undefined
|
|
99
|
+
) {
|
|
100
|
+
storedConfig.colorMap = colorMap
|
|
101
|
+
return
|
|
102
|
+
}
|
|
118
103
|
const points = getRGBPointsFromPreset(colorMap)
|
|
119
104
|
const { minimum, maximum } = storedConfig
|
|
120
105
|
return viewerStore.request(
|
|
@@ -137,9 +122,9 @@ export function useMeshPolygonsPolygonAttributeStyle() {
|
|
|
137
122
|
meshPolygonsPolygonAttributeName,
|
|
138
123
|
meshPolygonsPolygonAttributeRange,
|
|
139
124
|
meshPolygonsPolygonAttributeColorMap,
|
|
125
|
+
meshPolygonsPolygonAttributeStoredConfig,
|
|
140
126
|
setMeshPolygonsPolygonAttributeName,
|
|
141
127
|
setMeshPolygonsPolygonAttributeRange,
|
|
142
128
|
setMeshPolygonsPolygonAttributeColorMap,
|
|
143
|
-
updateMeshPolygonsPolygonAttribute,
|
|
144
129
|
}
|
|
145
130
|
}
|
|
@@ -18,26 +18,15 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
18
18
|
return meshPolygonsCommonStyle.meshPolygonsColoring(id).vertex
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
async function updateMeshPolygonsVertexAttribute(id) {
|
|
22
|
-
const name = meshPolygonsVertexAttributeName(id)
|
|
23
|
-
const storedConfig = meshPolygonsVertexAttributeStoredConfig(id, name)
|
|
24
|
-
await meshPolygonsVertexAttributeRange(
|
|
25
|
-
id,
|
|
26
|
-
storedConfig.minimum,
|
|
27
|
-
storedConfig.maximum,
|
|
28
|
-
)
|
|
29
|
-
await meshPolygonsVertexAttributeColorMap(id, storedConfig.colorMap)
|
|
30
|
-
}
|
|
31
|
-
|
|
32
21
|
function meshPolygonsVertexAttributeStoredConfig(id, name) {
|
|
33
22
|
const { storedConfigs } = meshPolygonsVertexAttribute(id)
|
|
34
23
|
if (name in storedConfigs) {
|
|
35
24
|
return storedConfigs[name]
|
|
36
25
|
}
|
|
37
26
|
return setMeshPolygonsVertexAttributeStoredConfig(id, name, {
|
|
38
|
-
minimum:
|
|
39
|
-
maximum:
|
|
40
|
-
colorMap:
|
|
27
|
+
minimum: undefined,
|
|
28
|
+
maximum: undefined,
|
|
29
|
+
colorMap: undefined,
|
|
41
30
|
})
|
|
42
31
|
}
|
|
43
32
|
|
|
@@ -46,7 +35,7 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
46
35
|
name,
|
|
47
36
|
{ minimum, maximum, colorMap },
|
|
48
37
|
) {
|
|
49
|
-
const
|
|
38
|
+
const storedConfigs = meshPolygonsVertexAttribute(id).storedConfigs
|
|
50
39
|
storedConfigs[name] = { minimum, maximum, colorMap }
|
|
51
40
|
return storedConfigs[name]
|
|
52
41
|
}
|
|
@@ -67,10 +56,11 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
67
56
|
{
|
|
68
57
|
response_function: async () => {
|
|
69
58
|
meshPolygonsVertexAttribute(id).name = name
|
|
70
|
-
const { minimum, maximum
|
|
71
|
-
|
|
59
|
+
const { minimum, maximum } = meshPolygonsVertexAttributeStoredConfig(
|
|
60
|
+
id,
|
|
61
|
+
name,
|
|
62
|
+
)
|
|
72
63
|
await setMeshPolygonsVertexAttributeRange(id, minimum, maximum)
|
|
73
|
-
await setMeshPolygonsVertexAttributeColorMap(id, colorMap)
|
|
74
64
|
console.log(
|
|
75
65
|
setMeshPolygonsVertexAttributeName.name,
|
|
76
66
|
{ id },
|
|
@@ -90,21 +80,9 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
90
80
|
function setMeshPolygonsVertexAttributeRange(id, minimum, maximum) {
|
|
91
81
|
const name = meshPolygonsVertexAttributeName(id)
|
|
92
82
|
const storedConfig = meshPolygonsVertexAttributeStoredConfig(id, name)
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
{
|
|
97
|
-
response_function: () => {
|
|
98
|
-
storedConfig.minimum = minimum
|
|
99
|
-
storedConfig.maximum = maximum
|
|
100
|
-
console.log(
|
|
101
|
-
setMeshPolygonsVertexAttributeRange.name,
|
|
102
|
-
{ id },
|
|
103
|
-
meshPolygonsVertexAttributeRange(id),
|
|
104
|
-
)
|
|
105
|
-
},
|
|
106
|
-
},
|
|
107
|
-
)
|
|
83
|
+
storedConfig.minimum = minimum
|
|
84
|
+
storedConfig.maximum = maximum
|
|
85
|
+
return setMeshPolygonsVertexAttributeColorMap(id, storedConfig.colorMap)
|
|
108
86
|
}
|
|
109
87
|
|
|
110
88
|
function meshPolygonsVertexAttributeColorMap(id) {
|
|
@@ -116,6 +94,14 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
116
94
|
function setMeshPolygonsVertexAttributeColorMap(id, colorMap) {
|
|
117
95
|
const name = meshPolygonsVertexAttributeName(id)
|
|
118
96
|
const storedConfig = meshPolygonsVertexAttributeStoredConfig(id, name)
|
|
97
|
+
if (
|
|
98
|
+
storedConfig.minimum === undefined ||
|
|
99
|
+
storedConfig.maximum === undefined ||
|
|
100
|
+
colorMap === undefined
|
|
101
|
+
) {
|
|
102
|
+
storedConfig.colorMap = colorMap
|
|
103
|
+
return
|
|
104
|
+
}
|
|
119
105
|
const points = getRGBPointsFromPreset(colorMap)
|
|
120
106
|
const { minimum, maximum } = storedConfig
|
|
121
107
|
|
|
@@ -145,9 +131,9 @@ export function useMeshPolygonsVertexAttributeStyle() {
|
|
|
145
131
|
meshPolygonsVertexAttributeName,
|
|
146
132
|
meshPolygonsVertexAttributeRange,
|
|
147
133
|
meshPolygonsVertexAttributeColorMap,
|
|
134
|
+
meshPolygonsVertexAttributeStoredConfig,
|
|
148
135
|
setMeshPolygonsVertexAttributeName,
|
|
149
136
|
setMeshPolygonsVertexAttributeRange,
|
|
150
137
|
setMeshPolygonsVertexAttributeColorMap,
|
|
151
|
-
updateMeshPolygonsVertexAttribute,
|
|
152
138
|
}
|
|
153
139
|
}
|
|
@@ -18,26 +18,15 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
18
18
|
return meshPolyhedraCommonStyle.meshPolyhedraColoring(id).polyhedron
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
async function updateMeshPolyhedraPolyhedronAttribute(id) {
|
|
22
|
-
const name = meshPolyhedraPolyhedronAttributeName(id)
|
|
23
|
-
const storedConfig = meshPolyhedraPolyhedronAttributeStoredConfig(id, name)
|
|
24
|
-
await meshPolyhedraPolyhedronAttributeRange(
|
|
25
|
-
id,
|
|
26
|
-
storedConfig.minimum,
|
|
27
|
-
storedConfig.maximum,
|
|
28
|
-
)
|
|
29
|
-
await meshPolyhedraPolyhedronAttributeColorMap(id, storedConfig.colorMap)
|
|
30
|
-
}
|
|
31
|
-
|
|
32
21
|
function meshPolyhedraPolyhedronAttributeStoredConfig(id, name) {
|
|
33
22
|
const { storedConfigs } = meshPolyhedraPolyhedronAttribute(id)
|
|
34
23
|
if (name in storedConfigs) {
|
|
35
24
|
return storedConfigs[name]
|
|
36
25
|
}
|
|
37
26
|
return setMeshPolyhedraPolyhedronAttributeStoredConfig(id, name, {
|
|
38
|
-
minimum:
|
|
39
|
-
maximum:
|
|
40
|
-
colorMap:
|
|
27
|
+
minimum: undefined,
|
|
28
|
+
maximum: undefined,
|
|
29
|
+
colorMap: undefined,
|
|
41
30
|
})
|
|
42
31
|
}
|
|
43
32
|
|
|
@@ -46,7 +35,7 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
46
35
|
name,
|
|
47
36
|
{ minimum, maximum, colorMap },
|
|
48
37
|
) {
|
|
49
|
-
const
|
|
38
|
+
const storedConfigs = meshPolyhedraPolyhedronAttribute(id).storedConfigs
|
|
50
39
|
storedConfigs[name] = { minimum, maximum, colorMap }
|
|
51
40
|
return storedConfigs[name]
|
|
52
41
|
}
|
|
@@ -61,10 +50,9 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
61
50
|
{
|
|
62
51
|
response_function: async () => {
|
|
63
52
|
meshPolyhedraPolyhedronAttribute(id).name = name
|
|
64
|
-
const { minimum, maximum
|
|
53
|
+
const { minimum, maximum } =
|
|
65
54
|
meshPolyhedraPolyhedronAttributeStoredConfig(id, name)
|
|
66
55
|
await setMeshPolyhedraPolyhedronAttributeRange(id, minimum, maximum)
|
|
67
|
-
await setMeshPolyhedraPolyhedronAttributeColorMap(id, colorMap)
|
|
68
56
|
console.log(
|
|
69
57
|
setMeshPolyhedraPolyhedronAttributeName.name,
|
|
70
58
|
{ id },
|
|
@@ -83,20 +71,11 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
83
71
|
function setMeshPolyhedraPolyhedronAttributeRange(id, minimum, maximum) {
|
|
84
72
|
const name = meshPolyhedraPolyhedronAttributeName(id)
|
|
85
73
|
const storedConfig = meshPolyhedraPolyhedronAttributeStoredConfig(id, name)
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
storedConfig.minimum = minimum
|
|
92
|
-
storedConfig.maximum = maximum
|
|
93
|
-
console.log(
|
|
94
|
-
setMeshPolyhedraPolyhedronAttributeRange.name,
|
|
95
|
-
{ id },
|
|
96
|
-
meshPolyhedraPolyhedronAttributeRange(id),
|
|
97
|
-
)
|
|
98
|
-
},
|
|
99
|
-
},
|
|
74
|
+
storedConfig.minimum = minimum
|
|
75
|
+
storedConfig.maximum = maximum
|
|
76
|
+
return setMeshPolyhedraPolyhedronAttributeColorMap(
|
|
77
|
+
id,
|
|
78
|
+
storedConfig.colorMap,
|
|
100
79
|
)
|
|
101
80
|
}
|
|
102
81
|
|
|
@@ -109,6 +88,14 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
109
88
|
function setMeshPolyhedraPolyhedronAttributeColorMap(id, colorMap) {
|
|
110
89
|
const name = meshPolyhedraPolyhedronAttributeName(id)
|
|
111
90
|
const storedConfig = meshPolyhedraPolyhedronAttributeStoredConfig(id, name)
|
|
91
|
+
if (
|
|
92
|
+
storedConfig.minimum === undefined ||
|
|
93
|
+
storedConfig.maximum === undefined ||
|
|
94
|
+
colorMap === undefined
|
|
95
|
+
) {
|
|
96
|
+
storedConfig.colorMap = colorMap
|
|
97
|
+
return
|
|
98
|
+
}
|
|
112
99
|
const points = getRGBPointsFromPreset(colorMap)
|
|
113
100
|
const { minimum, maximum } = storedConfig
|
|
114
101
|
return viewerStore.request(
|
|
@@ -131,9 +118,9 @@ export function useMeshPolyhedraPolyhedronAttributeStyle() {
|
|
|
131
118
|
meshPolyhedraPolyhedronAttributeName,
|
|
132
119
|
meshPolyhedraPolyhedronAttributeRange,
|
|
133
120
|
meshPolyhedraPolyhedronAttributeColorMap,
|
|
121
|
+
meshPolyhedraPolyhedronAttributeStoredConfig,
|
|
134
122
|
setMeshPolyhedraPolyhedronAttributeName,
|
|
135
123
|
setMeshPolyhedraPolyhedronAttributeRange,
|
|
136
124
|
setMeshPolyhedraPolyhedronAttributeColorMap,
|
|
137
|
-
updateMeshPolyhedraPolyhedronAttribute,
|
|
138
125
|
}
|
|
139
126
|
}
|
|
@@ -18,26 +18,15 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
18
18
|
return meshPolyhedraCommonStyle.meshPolyhedraColoring(id).vertex
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
async function updateMeshPolyhedraVertexAttribute(id) {
|
|
22
|
-
const name = meshPolyhedraVertexAttributeName(id)
|
|
23
|
-
const storedConfig = meshPolyhedraVertexAttributeStoredConfig(id, name)
|
|
24
|
-
await meshPolyhedraVertexAttributeRange(
|
|
25
|
-
id,
|
|
26
|
-
storedConfig.minimum,
|
|
27
|
-
storedConfig.maximum,
|
|
28
|
-
)
|
|
29
|
-
await meshPolyhedraVertexAttributeColorMap(id, storedConfig.colorMap)
|
|
30
|
-
}
|
|
31
|
-
|
|
32
21
|
function meshPolyhedraVertexAttributeStoredConfig(id, name) {
|
|
33
22
|
const { storedConfigs } = meshPolyhedraVertexAttribute(id)
|
|
34
23
|
if (name in storedConfigs) {
|
|
35
24
|
return storedConfigs[name]
|
|
36
25
|
}
|
|
37
26
|
return setMeshPolyhedraVertexAttributeStoredConfig(id, name, {
|
|
38
|
-
minimum:
|
|
39
|
-
maximum:
|
|
40
|
-
colorMap:
|
|
27
|
+
minimum: undefined,
|
|
28
|
+
maximum: undefined,
|
|
29
|
+
colorMap: undefined,
|
|
41
30
|
})
|
|
42
31
|
}
|
|
43
32
|
|
|
@@ -46,7 +35,7 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
46
35
|
name,
|
|
47
36
|
{ minimum, maximum, colorMap },
|
|
48
37
|
) {
|
|
49
|
-
const
|
|
38
|
+
const storedConfigs = meshPolyhedraVertexAttribute(id).storedConfigs
|
|
50
39
|
storedConfigs[name] = { minimum, maximum, colorMap }
|
|
51
40
|
return storedConfigs[name]
|
|
52
41
|
}
|
|
@@ -67,10 +56,11 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
67
56
|
{
|
|
68
57
|
response_function: async () => {
|
|
69
58
|
meshPolyhedraVertexAttribute(id).name = name
|
|
70
|
-
const { minimum, maximum
|
|
71
|
-
|
|
59
|
+
const { minimum, maximum } = meshPolyhedraVertexAttributeStoredConfig(
|
|
60
|
+
id,
|
|
61
|
+
name,
|
|
62
|
+
)
|
|
72
63
|
await setMeshPolyhedraVertexAttributeRange(id, minimum, maximum)
|
|
73
|
-
await setMeshPolyhedraVertexAttributeColorMap(id, colorMap)
|
|
74
64
|
console.log(
|
|
75
65
|
setMeshPolyhedraVertexAttributeName.name,
|
|
76
66
|
{ id },
|
|
@@ -90,21 +80,9 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
90
80
|
function setMeshPolyhedraVertexAttributeRange(id, minimum, maximum) {
|
|
91
81
|
const name = meshPolyhedraVertexAttributeName(id)
|
|
92
82
|
const storedConfig = meshPolyhedraVertexAttributeStoredConfig(id, name)
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
{
|
|
97
|
-
response_function: () => {
|
|
98
|
-
storedConfig.minimum = minimum
|
|
99
|
-
storedConfig.maximum = maximum
|
|
100
|
-
console.log(
|
|
101
|
-
setMeshPolyhedraVertexAttributeRange.name,
|
|
102
|
-
{ id },
|
|
103
|
-
meshPolyhedraVertexAttributeRange(id),
|
|
104
|
-
)
|
|
105
|
-
},
|
|
106
|
-
},
|
|
107
|
-
)
|
|
83
|
+
storedConfig.minimum = minimum
|
|
84
|
+
storedConfig.maximum = maximum
|
|
85
|
+
return setMeshPolyhedraVertexAttributeColorMap(id, storedConfig.colorMap)
|
|
108
86
|
}
|
|
109
87
|
|
|
110
88
|
function meshPolyhedraVertexAttributeColorMap(id) {
|
|
@@ -116,6 +94,14 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
116
94
|
function setMeshPolyhedraVertexAttributeColorMap(id, colorMap) {
|
|
117
95
|
const name = meshPolyhedraVertexAttributeName(id)
|
|
118
96
|
const storedConfig = meshPolyhedraVertexAttributeStoredConfig(id, name)
|
|
97
|
+
if (
|
|
98
|
+
storedConfig.minimum === undefined ||
|
|
99
|
+
storedConfig.maximum === undefined ||
|
|
100
|
+
colorMap === undefined
|
|
101
|
+
) {
|
|
102
|
+
storedConfig.colorMap = colorMap
|
|
103
|
+
return
|
|
104
|
+
}
|
|
119
105
|
const points = getRGBPointsFromPreset(colorMap)
|
|
120
106
|
const { minimum, maximum } = storedConfig
|
|
121
107
|
|
|
@@ -145,9 +131,9 @@ export function useMeshPolyhedraVertexAttributeStyle() {
|
|
|
145
131
|
meshPolyhedraVertexAttributeName,
|
|
146
132
|
meshPolyhedraVertexAttributeRange,
|
|
147
133
|
meshPolyhedraVertexAttributeColorMap,
|
|
134
|
+
meshPolyhedraVertexAttributeStoredConfig,
|
|
148
135
|
setMeshPolyhedraVertexAttributeName,
|
|
149
136
|
setMeshPolyhedraVertexAttributeRange,
|
|
150
137
|
setMeshPolyhedraVertexAttributeColorMap,
|
|
151
|
-
updateMeshPolyhedraVertexAttribute,
|
|
152
138
|
}
|
|
153
139
|
}
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@geode/opengeodeweb-front",
|
|
3
3
|
"description": "OpenSource Vue/Nuxt/Pinia/Vuetify framework for web applications",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "10.3.1",
|
|
5
|
+
"version": "10.3.2-rc.1",
|
|
6
6
|
"main": "./nuxt.config.js",
|
|
7
7
|
"scripts": {
|
|
8
8
|
"lint": "eslint --fix --ext .js,.vue --ignore-path .gitignore .",
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
"build": ""
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@geode/opengeodeweb-back": "
|
|
18
|
-
"@geode/opengeodeweb-viewer": "
|
|
17
|
+
"@geode/opengeodeweb-back": "next",
|
|
18
|
+
"@geode/opengeodeweb-viewer": "next",
|
|
19
19
|
"@kitware/vtk.js": "33.3.0",
|
|
20
20
|
"@mdi/font": "7.4.47",
|
|
21
21
|
"@pinia/nuxt": "0.11.3",
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
import ViewerOptionsAttributeColorBar from "@ogw_front/components/Viewer/Options/AttributeColorBar"
|
|
3
|
-
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json"
|
|
4
|
-
import { useGeodeStore } from "@ogw_front/stores/geode"
|
|
5
|
-
|
|
6
|
-
const geodeStore = useGeodeStore()
|
|
7
|
-
|
|
8
|
-
const cell_attribute_name = defineModel("cell_attribute_name", {
|
|
9
|
-
type: String,
|
|
10
|
-
})
|
|
11
|
-
const cell_attribute_range = defineModel("cell_attribute_range", {
|
|
12
|
-
type: Array,
|
|
13
|
-
})
|
|
14
|
-
const cell_attribute_color_map = defineModel("cell_attribute_color_map", {
|
|
15
|
-
type: String,
|
|
16
|
-
})
|
|
17
|
-
const cell_attributes = ref([])
|
|
18
|
-
|
|
19
|
-
const { id } = defineProps({
|
|
20
|
-
id: { type: String, required: true },
|
|
21
|
-
})
|
|
22
|
-
|
|
23
|
-
const model = defineModel()
|
|
24
|
-
const cell_attribute_names = ref([])
|
|
25
|
-
const cell_attribute = reactive({ name: cell_attribute_name.value })
|
|
26
|
-
|
|
27
|
-
onMounted(() => {
|
|
28
|
-
if (model.value !== undefined) {
|
|
29
|
-
cell_attribute_name.value = model.value.name
|
|
30
|
-
}
|
|
31
|
-
})
|
|
32
|
-
|
|
33
|
-
watch(cell_attribute_name, (value) => {
|
|
34
|
-
cell_attribute.name = value
|
|
35
|
-
model.value = cell_attribute
|
|
36
|
-
})
|
|
37
|
-
|
|
38
|
-
onMounted(() => {
|
|
39
|
-
getCellAttributes()
|
|
40
|
-
})
|
|
41
|
-
|
|
42
|
-
function getCellAttributes() {
|
|
43
|
-
geodeStore.request(
|
|
44
|
-
back_schemas.opengeodeweb_back.cell_attribute_names,
|
|
45
|
-
{
|
|
46
|
-
id,
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
response_function: (response) =>
|
|
50
|
-
(cell_attributes.value = response.attributes),
|
|
51
|
-
},
|
|
52
|
-
)
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
const currentAttribute = computed(() =>
|
|
56
|
-
cell_attributes.value.find(
|
|
57
|
-
(attr) => attr.attribute_name === cell_attribute_name.value,
|
|
58
|
-
),
|
|
59
|
-
)
|
|
60
|
-
|
|
61
|
-
function resetRange() {
|
|
62
|
-
if (currentAttribute.value) {
|
|
63
|
-
cell_attribute_range.value = [
|
|
64
|
-
currentAttribute.value.min_value,
|
|
65
|
-
currentAttribute.value.max_value,
|
|
66
|
-
]
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
</script>
|
|
70
|
-
|
|
71
|
-
<template>
|
|
72
|
-
<v-select
|
|
73
|
-
v-model="cell_attribute_name"
|
|
74
|
-
:items="cell_attributes.map((attribute) => attribute.attribute_name)"
|
|
75
|
-
item-title="attribute_name"
|
|
76
|
-
item-value="attribute_name"
|
|
77
|
-
label="Select an attribute"
|
|
78
|
-
density="compact"
|
|
79
|
-
/>
|
|
80
|
-
<ViewerOptionsAttributeColorBar
|
|
81
|
-
v-if="cell_attribute_name"
|
|
82
|
-
v-model:minimum="rangeMin"
|
|
83
|
-
v-model:maximum="rangeMax"
|
|
84
|
-
v-model:colorMap="cell_attribute_color_map"
|
|
85
|
-
@reset="resetRange"
|
|
86
|
-
/>
|
|
87
|
-
</template>
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
import ViewerOptionsAttributeColorBar from "@ogw_front/components/Viewer/Options/AttributeColorBar"
|
|
3
|
-
import back_schemas from "@geode/opengeodeweb-back/opengeodeweb_back_schemas.json"
|
|
4
|
-
import { useGeodeStore } from "@ogw_front/stores/geode"
|
|
5
|
-
|
|
6
|
-
const geodeStore = useGeodeStore()
|
|
7
|
-
|
|
8
|
-
const edge_attribute_name = defineModel("edge_attribute_name", {
|
|
9
|
-
type: String,
|
|
10
|
-
})
|
|
11
|
-
const edge_attribute_range = defineModel("edge_attribute_range", {
|
|
12
|
-
type: Array,
|
|
13
|
-
})
|
|
14
|
-
const edge_attribute_color_map = defineModel("edge_attribute_color_map", {
|
|
15
|
-
type: String,
|
|
16
|
-
})
|
|
17
|
-
const edge_attributes = ref([])
|
|
18
|
-
|
|
19
|
-
const { id } = defineProps({
|
|
20
|
-
id: { type: String, required: true },
|
|
21
|
-
})
|
|
22
|
-
|
|
23
|
-
const rangeMin = computed({
|
|
24
|
-
get: () => edge_attribute_range.value[0],
|
|
25
|
-
set: (val) => {
|
|
26
|
-
edge_attribute_range.value = [val, edge_attribute_range.value[1]]
|
|
27
|
-
},
|
|
28
|
-
})
|
|
29
|
-
const rangeMax = computed({
|
|
30
|
-
get: () => edge_attribute_range.value[1],
|
|
31
|
-
set: (val) => {
|
|
32
|
-
edge_attribute_range.value = [edge_attribute_range.value[0], val]
|
|
33
|
-
},
|
|
34
|
-
})
|
|
35
|
-
|
|
36
|
-
onMounted(() => {
|
|
37
|
-
getEdgeAttributes()
|
|
38
|
-
})
|
|
39
|
-
|
|
40
|
-
function getEdgeAttributes() {
|
|
41
|
-
geodeStore.request(
|
|
42
|
-
back_schemas.opengeodeweb_back.edge_attribute_names,
|
|
43
|
-
{ id: id },
|
|
44
|
-
{
|
|
45
|
-
response_function: (response) => {
|
|
46
|
-
edge_attributes.value = response.attributes
|
|
47
|
-
},
|
|
48
|
-
},
|
|
49
|
-
)
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
const currentAttribute = computed(() =>
|
|
53
|
-
edge_attributes.value.find(
|
|
54
|
-
(attr) => attr.attribute_name === edge_attribute_name.value,
|
|
55
|
-
),
|
|
56
|
-
)
|
|
57
|
-
|
|
58
|
-
function resetRange() {
|
|
59
|
-
if (currentAttribute.value) {
|
|
60
|
-
edge_attribute_range.value = [
|
|
61
|
-
currentAttribute.value.min_value,
|
|
62
|
-
currentAttribute.value.max_value,
|
|
63
|
-
]
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
</script>
|
|
67
|
-
|
|
68
|
-
<template>
|
|
69
|
-
<v-select
|
|
70
|
-
v-model="edge_attribute_name"
|
|
71
|
-
:items="edge_attributes.map((attribute) => attribute.attribute_name)"
|
|
72
|
-
item-title="attribute_name"
|
|
73
|
-
item-value="attribute_name"
|
|
74
|
-
label="Select an attribute"
|
|
75
|
-
density="compact"
|
|
76
|
-
/>
|
|
77
|
-
<ViewerOptionsAttributeColorBar
|
|
78
|
-
v-if="edge_attribute_name"
|
|
79
|
-
v-model:minimum="rangeMin"
|
|
80
|
-
v-model:maximum="rangeMax"
|
|
81
|
-
v-model:colorMap="edge_attribute_color_map"
|
|
82
|
-
@reset="resetRange"
|
|
83
|
-
/>
|
|
84
|
-
</template>
|