So the Danish weather has been AHHHH-mazing the past days, and what better way to enjoy the weather than to eat ice cream?! So here’s a fun little project using a library called jQuery UI (which apparently is a very popular library, however a bit old as I understand it).
- After downloading and linking to the jQuery UI library, I found the example code and it worked perfectly. So simple! The .draggable function is a function that makes DOM elements able to be dragged around the site. I made a containment to the containing div and set the scroll to false.
- I wanted to make sure that the cones where the top layer, so I sat the z-index to 100.
- Also the library has a stacked option that makes sure that whatever element is dragged is stacked on top of the other.