Skip to content

Commit

Permalink
fix(ConvertProxyProperty): Defer group visibility to child properties
Browse files Browse the repository at this point in the history
  • Loading branch information
scottwittenburg committed Oct 31, 2017
1 parent 5b60807 commit 1fd1c46
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/Common/Misc/ConvertProxyProperty/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,15 @@ export function proxyPropToProp(property, ui) {

if (isGroupWidget(ui.widget)) {
prop.children = property.children.map((p, idx) => proxyPropToProp(p, ui.children[idx]));
prop.show = (ctx) => {
let visible = false;
prop.children.forEach((propChild) => {
if (propChild.show(ctx)) {
visible = true;
}
});
return visible;
};
}

return prop;
Expand Down

0 comments on commit 1fd1c46

Please sign in to comment.