dojo / widget-core

:rocket: Dojo 2 - widget authoring system.
http://dojo.io
Other
34 stars 39 forks source link

Node ordering incorrect when returning DNode[] #930

Closed nicknisi closed 6 years ago

nicknisi commented 6 years ago

Bug

Package Version: 2.0.0

Code

an example of this issue can be found at https://github.com/aldyn/dojo-tree.

Expected behavior:

The injected nodes would be placed in the order, next to their sibling

Actual behavior:

When a widget that returns a DNode[] is invalidated, any additional rows not part of the initial render are placed at the end of the parent node and not in the correct position next to the sibling.

szwoelf commented 6 years ago

Hi! Unfortunately this does not completely fix the issue. It works now in the example above but only for the first open. If you close and open the 2nd entry once again the subnodes will be displayed at the top of the tree. Kind Regards, Simon + Aldin

agubler commented 6 years ago

@szwoelf Thanks for the feedback - we'll take another look.

agubler commented 6 years ago

@szwoelf I have reopened the issue.

agubler commented 6 years ago

@szwoelf Thanks for reporting the issue, we have identified the cause and fix so should be able to raise the changes today:

rendering-nodes

agubler commented 6 years ago

@szwoelf We have added a change to widget-core/master that should fix this latest issue - Before we go ahead a publish a new release, it would be great if you could test this to make sure it covers the scenarios expected. Is this something that you are able to do?

szwoelf commented 6 years ago

Hi Anthony! We'll try this ... :-)

And thx for the video ...

szwoelf commented 6 years ago

Hi Anthony! We copied a built version of vdom.js into our node_modules. The Tree issue is fixed now.

But: when navigating with the buttons the buttons "jump" from the top of the page to the "bottom" which is not the correct order. Click on "Test1" and then on the "TreeView" ... then the buttons are at the bottom. Reload will move them to the top. Unfortunately this makes this version of widget-core unusable for us because sometimes this messes up the whole GUI.

P.S.: adding a key property to all of the buttons did not help.

Thanks again and kind regards, Aldin + Simon

agubler commented 6 years ago

Ah right thanks, more things to look into then

szwoelf commented 6 years ago

Excellent ;-) Thanks again