@panoramax/web-viewer 4.4.0-develop-d74d6c58 → 4.4.0-develop-9ead4553
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/CHANGELOG.md +1 -1
- package/build/index.js +1 -1
- package/build/index.js.map +1 -1
- package/build/photoviewer.js +1 -1
- package/package.json +1 -1
- package/src/utils/SemanticsMapProtocol.js +12 -1
- package/src/utils/indoor.js +3 -1
package/package.json
CHANGED
|
@@ -112,7 +112,18 @@ export default class SemanticsMapProtocol {
|
|
|
112
112
|
|
|
113
113
|
// Remove useless stuff
|
|
114
114
|
geojson.features = geojson.features
|
|
115
|
-
.filter(f =>
|
|
115
|
+
.filter(f => {
|
|
116
|
+
let keep = f.properties?.semantics?.length > 0 || f.properties?.annotations?.length > 0;
|
|
117
|
+
|
|
118
|
+
// Look if sequence has indoor level
|
|
119
|
+
if(!keep) {
|
|
120
|
+
if(f.properties?.collection?.semantics?.find(s => s.key === "osm|level")) {
|
|
121
|
+
keep = true;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
}
|
|
125
|
+
return keep;
|
|
126
|
+
})
|
|
116
127
|
.map(f => ({
|
|
117
128
|
type: f.type,
|
|
118
129
|
geometry: f.geometry,
|
package/src/utils/indoor.js
CHANGED
|
@@ -43,7 +43,9 @@ export function initIndoorEqualOnMap(map, forceSwitchOn = false) {
|
|
|
43
43
|
const SEM_SRC_ID = "sem-"+LEVEL_SEM_LAYER;
|
|
44
44
|
map.indoorEqual._updateLevels = function() {
|
|
45
45
|
if(
|
|
46
|
-
this.map.
|
|
46
|
+
this.map.getSource(this.source.sourceId)
|
|
47
|
+
&& this.map.isSourceLoaded(this.source.sourceId)
|
|
48
|
+
&& this.map.getSource(SEM_SRC_ID)
|
|
47
49
|
&& this.map.isSourceLoaded(SEM_SRC_ID)
|
|
48
50
|
) {
|
|
49
51
|
let levels = new Set();
|