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