Skip to content

Commit

Permalink
Merge pull request #1304 from FormidableLabs/bug/group-property
Browse files Browse the repository at this point in the history
rename private properties
  • Loading branch information
boygirl authored May 4, 2019
2 parents a98a759 + 9283a5e commit 38f98b0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/victory-core/src/victory-util/wrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -215,15 +215,15 @@ export default {
childData = Data.getData(childProps);
}
stack += 1;
return childData.map((datum, index) => assign({ stack, group: index }, datum));
return childData.map((datum, index) => assign({ _stack: stack, _group: index }, datum));
};
const children = childComponents
? childComponents.slice(0)
: React.Children.toArray(props.children);
const stacked = children.filter((c) => c.type && c.type.role === "stack").length;
const combine = (memo, val) => memo.concat(uniqBy(val, "group"));
const combine = (memo, val) => memo.concat(uniqBy(val, "_group"));
const datasets = Helpers.reduceChildren(children, iteratee, props, [], combine);
const group = stacked ? "group" : "stack";
const group = stacked ? "_group" : "_stack";
return values(groupBy(datasets, group));
},

Expand Down

0 comments on commit 38f98b0

Please sign in to comment.