Jump to content
Search Community

Recommended Posts

Posted

Hello, how can i achieve multiple list divs? and it the items will drag only inside there own divs

 

Thanks in advance!

 

edit; please excuse my english.

 

edit 2; what i want to achieve is have multiple 

<div id="list"></div>

See the Pen dPZLEp by GreenSock (@GreenSock) on CodePen.

Posted

Hey krx and welcome to the GreenSock forums!

 

You can have multiple draggable sortable grids by changing the IDs to classes and then looping through each element, setting it up as necessary for your particular use case.

 

Is there anything in particular that you're having trouble with?

Posted
4 minutes ago, ZachSaucier said:

Hey krx and welcome to the GreenSock forums!

 

You can have multiple draggable sortable grids by changing the IDs to classes and then looping through each element, setting it up as necessary for your particular use case.

 

Is there anything in particular that you're having trouble with?

 

Thanks for your response first of all, is there any chance you can update the codepen and send it here?

 

Thank you.

Posted
Just now, krx said:

is there any chance you can update the codepen and send it here?

Sorry, we don't have the capacity to help with every request like this. If you run into particular issues feel free to ask us and we'll help where we can.

Posted
3 hours ago, ZachSaucier said:

Sorry, we don't have the capacity to help with every request like this. If you run into particular issues feel free to ask us and we'll help where we can.

Sorry to disturb again after i loop every class what should i put inside? i update `$list` and start `init()` but couldn't make it work

Posted

I don't understand your question. Also please understand that we can't help with every logical error in your project.

Posted
5 minutes ago, ZachSaucier said:

I don't understand your question. Also please understand that we can't help with every logical error in your project.

 

I'm looping all the classes that has the class `list`, but it always uses the second class.

 

$('.list').each(function(i, obj) {
    window.$list = $(obj);
  window.tiles  = $list[0].getElementsByClassName("tile");
    init();
});

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...