The "close" action is under the "expand" button, the same as "collapse". However it might not be shown if there are no nodes that would be hidden by it.
Kārlis described the algorithm well. Clicking "close" on node X hides all direct neighbors of X that only have links to each other and X. If there are no such neighbors (that is, all neighbors have other links as well), then the "close" button won't be shown.
If you still can't get it to show even though you think that it should, please give a JSFiddle example so that I can investigate.
Also - what kind of behavior do you want?