tonytan4ever / Bootstrap-Form-Builder-V3V4

A bootstrap 3.0 form drag and drop builder, implemented in Jquery. Based on: https://github.com/minikomi/Bootstrap-Form-Builder
MIT License
74 stars 43 forks source link

wrong position() for dragged field, works with offset() #2

Closed pirasterize closed 9 years ago

pirasterize commented 9 years ago

Hi I tried to integrate your tool on my page but I found that the position of the dragged field was not recognized on the TARGET From, because of wrong coordinates. After investigation I changed every use of position() function with offset() and seems work. Every calls were in the file assets/js/views/my-form.js

Can you please check and, in case you agree, update the package ? Thanks Andrea

tonytan4ever commented 9 years ago

Hi: After I looked at and played with the code, I realize you are right, and using offset() rather than position() does provide a better user experience. A new change has been pushed:

https://github.com/tonytan4ever/Bootstrap-Form-Builder-JV3/commit/175d6435a88173ba1078c431b9ac79af7131719d

Thanks for your effort as well!

pirasterize commented 9 years ago

Thank you Andrea