@vcmap/ui 5.3.7 → 5.3.8
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/dist/assets/cesium.js +1 -1
- package/dist/assets/{core.7122ed.js → core.6f0114.js} +2 -2
- package/dist/assets/core.js +1 -1
- package/dist/assets/index-17490f9e.js +1 -0
- package/dist/assets/ol.js +1 -1
- package/dist/assets/{ui.07c23d.js → ui.d7e3c5.js} +679 -660
- package/dist/assets/ui.js +1 -1
- package/dist/assets/vue.js +2 -2
- package/dist/assets/{vuetify.8284ec.js → vuetify.5cde8b.js} +1 -1
- package/dist/assets/vuetify.js +2 -2
- package/dist/index.html +1 -1
- package/package.json +1 -1
- package/src/featureInfo/abstractFeatureInfoView.d.ts +6 -0
- package/src/featureInfo/abstractFeatureInfoView.js +35 -2
- package/dist/assets/index-12958251.js +0 -1
- /package/dist/assets/{cesium.0cabe2.js → cesium.14e362.js} +0 -0
- /package/dist/assets/{ol.086f00.js → ol.9f32ab.js} +0 -0
- /package/dist/assets/{ui.07c23d.css → ui.d7e3c5.css} +0 -0
- /package/dist/assets/{vue.67ce32.js → vue.399094.js} +0 -0
- /package/dist/assets/{vuetify.8284ec.css → vuetify.5cde8b.css} +0 -0
package/dist/assets/ui.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export * from "./ui.
|
1
|
+
export * from "./ui.d7e3c5.js";
|
package/dist/assets/vue.js
CHANGED
@@ -13,7 +13,7 @@ function loadCss(href) {
|
|
13
13
|
elem.onerror = reject;
|
14
14
|
document.head.appendChild(elem);
|
15
15
|
});
|
16
|
-
} await loadCss('./assets/vuetify.
|
16
|
+
} await loadCss('./assets/vuetify.5cde8b.css');import v from "./vue.399094.js";
|
17
17
|
const Ne = v.extend().extend({
|
18
18
|
name: "themeable",
|
19
19
|
provide() {
|
package/dist/assets/vuetify.js
CHANGED
package/dist/index.html
CHANGED
package/package.json
CHANGED
@@ -164,6 +164,12 @@ declare class AbstractFeatureInfoView extends VcsObject {
|
|
164
164
|
* @type {import("vue").Component|undefined}
|
165
165
|
*/
|
166
166
|
get component(): import("vue").Component<import("vue/types/options.js").DefaultData<never>, import("vue/types/options.js").DefaultMethods<never>, import("vue/types/options.js").DefaultComputed, import("vue/types/options.js").DefaultProps, {}> | undefined;
|
167
|
+
/**
|
168
|
+
* @param {undefined|import("ol").Feature|import("@vcmap-cesium/engine").Cesium3DTileFeature|import("@vcmap-cesium/engine").Cesium3DTilePointFeature} feature
|
169
|
+
* @returns {Object}
|
170
|
+
* @protected
|
171
|
+
*/
|
172
|
+
protected _getAttributesFromFeature(feature: undefined | import("ol").Feature | import("@vcmap-cesium/engine").Cesium3DTileFeature | import("@vcmap-cesium/engine").Cesium3DTilePointFeature): Object;
|
167
173
|
/**
|
168
174
|
* This method returns all relevant attributes for this view.
|
169
175
|
* Called by `getProperties()` to pass attributes as props object to the VueComponent of this view.
|
@@ -266,6 +266,21 @@ function getWindowState(app, state, attributes) {
|
|
266
266
|
};
|
267
267
|
}
|
268
268
|
|
269
|
+
/**
|
270
|
+
* Filters all __ attributes (from vc-converter tilesets) not provided as keys
|
271
|
+
* @param {Object<string, unknown>} attributes
|
272
|
+
* @param {Array<string>} keys
|
273
|
+
* @returns {Object}
|
274
|
+
*/
|
275
|
+
function applyDoubleUnderscoreFilter(attributes, keys = []) {
|
276
|
+
return Object.keys(attributes)
|
277
|
+
.filter((key) => keys.includes(key) || !/^__/.test(key))
|
278
|
+
.reduce((obj, key) => {
|
279
|
+
obj[key] = attributes[key];
|
280
|
+
return obj;
|
281
|
+
}, {});
|
282
|
+
}
|
283
|
+
|
269
284
|
/**
|
270
285
|
* Abstract class to be extended by FeatureInfoView classes
|
271
286
|
* Subclasses must always provide a component and may overwrite class methods.
|
@@ -343,6 +358,23 @@ class AbstractFeatureInfoView extends VcsObject {
|
|
343
358
|
return this._component;
|
344
359
|
}
|
345
360
|
|
361
|
+
/**
|
362
|
+
* @param {undefined|import("ol").Feature|import("@vcmap-cesium/engine").Cesium3DTileFeature|import("@vcmap-cesium/engine").Cesium3DTilePointFeature} feature
|
363
|
+
* @returns {Object}
|
364
|
+
* @protected
|
365
|
+
*/
|
366
|
+
// eslint-disable-next-line class-methods-use-this
|
367
|
+
_getAttributesFromFeature(feature) {
|
368
|
+
if (feature?.tileset?.asset?.version === '1.1') {
|
369
|
+
const attributes = {};
|
370
|
+
feature.getPropertyIds().forEach((id) => {
|
371
|
+
attributes[id] = feature.getProperty(id);
|
372
|
+
});
|
373
|
+
return attributes;
|
374
|
+
}
|
375
|
+
return feature.getProperty('attributes') || {};
|
376
|
+
}
|
377
|
+
|
346
378
|
/**
|
347
379
|
* This method returns all relevant attributes for this view.
|
348
380
|
* Called by `getProperties()` to pass attributes as props object to the VueComponent of this view.
|
@@ -352,7 +384,7 @@ class AbstractFeatureInfoView extends VcsObject {
|
|
352
384
|
* @returns {Object}
|
353
385
|
*/
|
354
386
|
getAttributes(feature) {
|
355
|
-
let attributes =
|
387
|
+
let attributes = this._getAttributesFromFeature(feature);
|
356
388
|
if (this.attributeKeys.length > 0) {
|
357
389
|
attributes = applyAttributeFilter(attributes, this.attributeKeys);
|
358
390
|
}
|
@@ -363,6 +395,7 @@ class AbstractFeatureInfoView extends VcsObject {
|
|
363
395
|
applyKeyMapping(attributes, this.keyMapping);
|
364
396
|
}
|
365
397
|
attributes = applyOlcsAttributeFilter(attributes, this.attributeKeys);
|
398
|
+
attributes = applyDoubleUnderscoreFilter(attributes, this.attributeKeys);
|
366
399
|
return applyEmptyAttributesFilter(attributes);
|
367
400
|
}
|
368
401
|
|
@@ -375,7 +408,7 @@ class AbstractFeatureInfoView extends VcsObject {
|
|
375
408
|
*/
|
376
409
|
getTags(feature) {
|
377
410
|
if (this.tags) {
|
378
|
-
const attributes =
|
411
|
+
const attributes = this._getAttributesFromFeature(feature);
|
379
412
|
const tags = Object.keys(this.tags)
|
380
413
|
.filter(
|
381
414
|
(key) =>
|
@@ -1 +0,0 @@
|
|
1
|
-
import{initAppFromAppConfig as p}from"./ui.07c23d.js";p("#app","app.config.json");
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|