I used the Infoviz library for such a scenario (here demo ). You can use different node colors for different selection rules along with some textual description, although at first it would not be very intuitive.
The orientation of the tree is horizontal by default, which may seem odd, but it makes sense when you add text node names of variable length.
source share