Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#4419 closed enhancement (fixed)

Tree: top tree node has unnecessary upward line in tundra

Reported by: guest Owned by:
Priority: high Milestone: 1.0
Component: Dijit Version: 0.9
Keywords: tree node tundra Cc:
Blocked By: Blocking:

Description

The top node of a tree with the tundra style looks like it comes from somewhere. In some cases, it does, but many trees end with a big root node with a + sign that is the end/beginning of the line. It would be great if there was an option not to include the extension. The bottom node, for instance, has nothing extending down from it. .dijitTreeIsRoot and .dijitTreeIsLast look like they might be used for these purposes. Perhaps .dijitTreeIsFirst is necessary.

Change History (4)

comment:1 Changed 12 years ago by bill

Milestone: 1.1
Summary: Top tree node has unnecessary upward line in tundraTree: top tree node has unnecessary upward line in tundra

Well, actually in the general case there are multiple top nodes (it's a forest not a tree). Every top level node already has the dijitTreeIsRoot class, so that could be used for styling if there is only one top level node. But I guess that's not sufficient in the case when there are multiple top level nodes...

comment:2 Changed 12 years ago by guest

It might be possible to use the E:first-child syntax in CSS to pick out the first tree in the forest and style it differently. I haven't verified that it works, though.

comment:3 Changed 12 years ago by bill

Resolution: fixed
Status: newclosed

(In [10580]) Refactor tree to have a special node (without a corresponding item) at the top of the tree, so that (for example) the continents/countries tree in test_Tree.html can have a top node marked "Continents" even though there is no such item in the data store.

This change requires handlers like onClick() to not fail when item==null, but rather to assume that's the root node.

Fixes #4527, #4419, #4457.

comment:4 Changed 12 years ago by bill

Milestone: 1.11.0
Note: See TracTickets for help on using tickets.