Label Styling, Focus and Expand/Collapse All

77 views
Skip to first unread message

Uday Shankar

unread,
Feb 16, 2017, 3:40:47 PM2/16/17
to JavaScript InfoVis Toolkit
Hi All,

Newbie here. I have been trying to customize my space tree implementation. I managed to get the basic version working. 
But, I am stuck at getting a few things to work:

Here's a JSBin of  the basic version http://jsbin.com/qobipujiyu/edit?js,output

1. Custom Label Styling based on the value.
I understand from the documentation (https://philogb.github.io/jit/static/v20/Docs/files/Loader/Loader-js.html) that we can use the data object to attach node specific styling. But, I am not able to get them working in my version here.

2. Center and focus on a specific node the tree. 
I have a dropdown in my UI, that the user can use to find the node they are looking for in the tree. When they select a item on that list, I want to tree to collapse/pan and center itself to the selected item. Is this possible? 

3. A Collapse All/Expand All
I understand the levelsToShow helps in defining the number of levels to show. But, I guess this is when the tree is rendered. Is there a way to expand or collapsing the tree without redrawing the entire tree?

Any help/pointers is really appreciated.

Thanks,
Uday

Uday Shankar

unread,
Feb 18, 2017, 12:44:27 AM2/18/17
to JavaScript InfoVis Toolkit
Just realized that JSBIN links are not working... I'll update it by Monday.
Reply all
Reply to author
Forward
0 new messages