I'm working on a fixed div with an image as the background, set up like this:
<div style='
width:230px;
height:230px;
background-repeat: no-repeat;
background-image:url(img/myimage.jpeg)
background-size: cover;'></div>
The issue I'm facing is that the image overlaps the div-box. What I want to do is allow the user to drag the image and then be able to access the new background-position: coordinates via jQuery when they release the mouse. Essentially, I want to create a simple image effect similar to what you see on Facebook:
https://i.sstatic.net/faQ84.gif
Is there a way to achieve this? And would it still work if the background overflowed due to using background-size:cover?