Open develancer opened 4 years ago
The library currently does not have a settable generation limit. If you would like to add a limit option, here are the places in the code you would need to change:
AncestorChart::createHierarchy()
DescendantChart::createHierarchy()
ChartOptions
and SimpleChartOptions
:
maxAncestorGenerations?: number;
maxDescendantGenerations?: number;
createChartOptions()
The implementation of the limits would be in the createHierarchy()
methods.
Let me know if you have any questions.
Hi! Very cool library. I've been experimenting to use it with webpack: https://github.com/develancer/topola-webpack
Is it possible, though, to limit the number of generations displayed? I mean, so that for any currently selected
startIndi
, topola would only display parents and grandparents (but not their parents) and only children and grandchildren (but not their children)? It would be very helpful for large (10+ generations) family trees combined with smaller viewports.If it's not currently possible, please provide some directions on what part of the codebase should be responsible for such filtering. I'll be glad to try to work it out.