afloesch / sortable-list

Polymer 1.X and 2.X element for drag-and-drop reordering of template items
MIT License
4 stars 3 forks source link

Polymer 2.0 problems #1

Open FynjyAC opened 7 years ago

FynjyAC commented 7 years ago

The demo (https://www.webcomponents.org/element/afloesch/sortable-list/demo/demo/index.html) does not work. Demo inside Git page does not work too, without error. Error in my project:

async.html:36 Uncaught TypeError: Cannot read property 'addEventListener' of null at HTMLElement. (sortable-list.html:97) at MutationObserver.microtaskFlush (async.html:34)

afloesch commented 7 years ago

Thanks for reporting this! Not sure when this changed exactly, but it looks like the Polymer helper method getEffectiveChildren is giving a different result now. Previously this would return the dom-repeat template child nodes, but now it's giving the template.

Looking at a fix now and will update this issue once resolved.

Nagasai-Aytha commented 7 years ago

demo js fiddle is not working -https://jsfiddle.net/api/post/library/pure/ https://www.webcomponents.org/element/afloesch/sortable-list/demo/demo/index.html any workaround or anyother component ?

Please suggest

feuerste commented 6 years ago

This can be resolved by changing the two occurrences of this.querySelector("template[is='dom-repeat']") to this.querySelector('dom-repeat')

WilliamTsao commented 5 years ago

Fixed in our v1.1.0 release. Additional feature and updates on sorting logic have been made in v1.2.0