I would like to Extend d3 tree layout to provide hyperlinks and text for each final node
http://mbostock.github.io/d3/talk/20111018/tree.html
For example if you go to
flare> analytics > ckuster > AgglomerativeClustr
I would like under the text AgglomerativeCluster I would like to have a textbox with the ability to have custom HTML.
How would I do this?
There are several ways to achieve what you want, but I believe the solution below is both simple and efficient.
I'll start with an example that is similar to yours, and also does not have any hyperlinks:
link to jsfiddle - starting point,
and will walk you through all necessary but simple modifications.
First, let's add field "url" for nodes that we want to have labels as hyperlinks:
Now, let's write code that selects all labels whose node data contain anything in field "url", and for each such label adds appropriate clock handler that will open correspondent url: (it also sets different cursor pointer for mouseovers so that user knows the label is actually a hyperlink)
That's it!
link to jsfiddle - finished example