| Issue 472: | Need mechanism to "hide" a node | |
| 1 person starred this issue and may be notified of changes. | Back to list |
I would like to hide a node. I've tried adding a class to the node (if it is hidden) with css: 'visibility: hidden' and setting hideCheckbox=true but then I get the display as shown in the attached image 'current.png' where I try to hide nodes "layerC" and "layerD" I would like to get the display shown in the attached image 'desired.png' where the hidden nodes are collapsed completely.
Jan 21, 2014
> I've tried adding a class to the node (if it is hidden) with css: 'visibility: hidden' have you tried to use CSS 'display: none' instead?
Status:
Waiting
Labels: Milestone-Release1.2.6
Jan 22, 2014
WRT idea to add 'display: none' instead... great idea... I just tried that. It doesn't work because the display style is overridden by the dynatree-node style which sets display: inline-block The other problem is that the display:none should be on the <LI> not on the <span> see attached file "suggestionFailed.png"
Jan 25, 2014
That would be a new feature, so it's rather a topic for the successor 'Fancytree'. Have a look at the 'filter' extension there.
Status:
WontFix
|
My solution: I added a new node attribute 'hidden' $.ui.dynatree.nodedatadefaults = { .... hidden: false, // is node hidden then added a line #475 this.li.style.display = ( data.hidden ? "none" : "visible" ) this got me to the image shown in 'desired.png'