@evergis/react 4.0.22-alpha.3 → 4.0.22-alpha.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/dist/index.js +3 -5
- package/dist/index.js.map +1 -1
- package/dist/react.esm.js +3 -5
- package/dist/react.esm.js.map +1 -1
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -9386,7 +9386,7 @@ const getElementValue = ({ getDefaultContainer, ...props }) => {
|
|
|
9386
9386
|
|
|
9387
9387
|
const getLayerAttributes = (attributesConfiguration) => {
|
|
9388
9388
|
const { attributes, geometryAttribute } = attributesConfiguration;
|
|
9389
|
-
return
|
|
9389
|
+
return (attributes ?? []).filter(({ attributeName, isDisplayed }) => ![geometryAttribute].includes(attributeName) && isDisplayed);
|
|
9390
9390
|
};
|
|
9391
9391
|
const isSelectedFeature = (feature) => typeof feature === "object" && feature !== null && "layerDefinition" in feature;
|
|
9392
9392
|
function getFeatureAttributes(feature = {}, layer, dataSource) {
|
|
@@ -9402,11 +9402,9 @@ function getFeatureAttributes(feature = {}, layer, dataSource) {
|
|
|
9402
9402
|
const { idAttribute, attributes } = attributesConfiguration || {};
|
|
9403
9403
|
const layerAttributes = idAttribute
|
|
9404
9404
|
? getLayerAttributes(attributesConfiguration)
|
|
9405
|
-
: attributes
|
|
9406
|
-
? Object.entries(attributes)
|
|
9407
|
-
: [];
|
|
9405
|
+
: attributes || [];
|
|
9408
9406
|
// TODO: fix typings for "id" field, DO NOT REMOVE "id", it uses in src\hooks\attributes\useAttributes.ts
|
|
9409
|
-
return layerAttributes.map((
|
|
9407
|
+
return layerAttributes.map(({ attributeName, type, subType, attributeConfigurationType, isEditable, stringFormat, alias = null, description, }) => {
|
|
9410
9408
|
const isIdAttribute = attributeName === idAttribute;
|
|
9411
9409
|
const additionalProps = isIdAttribute
|
|
9412
9410
|
? {
|