propertly support null entries in the values array
This commit is contained in:
parent
7d3feff3e5
commit
fa67ac4be1
|
@ -125,6 +125,7 @@ const AdvancedPageProperties: React.FunctionComponent<IAdvancedPagePropertiesPro
|
||||||
const RenderPagePropValue = (prop: PageProperty) => {
|
const RenderPagePropValue = (prop: PageProperty) => {
|
||||||
console.log(prop);
|
console.log(prop);
|
||||||
var retVal = _.map(prop.values, (val) => {
|
var retVal = _.map(prop.values, (val) => {
|
||||||
|
if (val !== null) {
|
||||||
switch (prop.info.TypeAsString) {
|
switch (prop.info.TypeAsString) {
|
||||||
case "URL":
|
case "URL":
|
||||||
return (
|
return (
|
||||||
|
@ -177,6 +178,9 @@ const AdvancedPageProperties: React.FunctionComponent<IAdvancedPagePropertiesPro
|
||||||
<span className={styles.standardCapsule} style={{backgroundColor: semanticColors.accentButtonBackground, color: semanticColors.accentButtonText}}>{val}</span>
|
<span className={styles.standardCapsule} style={{backgroundColor: semanticColors.accentButtonBackground, color: semanticColors.accentButtonText}}>{val}</span>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
return (<></>);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
return retVal;
|
return retVal;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue