Jump to content
Search Community

llan

Members
  • Posts

    1
  • Joined

  • Last visited

Posts posted by llan

  1. Hello!

     

    See my pen here: 

     

    I'm building a configurator, where certain elements can be drag-and-dropped into different slots. I have implemented the cloning mechanism mentioned here: https://greensock.com/forums/topic/10466-draggable-cloning-option/

    This part of working fine.

     

    In addition, I want the new elements to snap to their respective slots. For this, I have used the code from:

    See the Pen IaAfl by antpearson (@antpearson) on CodePen

     

    Snapping works for the first element I drop onto a slot. For each additional element, though, snapping doesn't work. I suppose it has something to do with the JS code in line 45.

     

    I've been trying to figure this out, yet without success.

    I would really appreciate your help. Thanks!

     

    Laurent

    See the Pen NdwYJb by llan (@llan) on CodePen

×
×
  • Create New...