Drag a p to different areas, how to determine which area it is dragged to
Please select different option areas when dragging as shown. How to determine which area you have dragged to?
typecho2017-06-28 09:28:59
The drag API has little contact and only provides ideas: it can be judged based on the distance from the upper left corner of the target when it is dropped
巴扎黑2017-06-28 09:28:59
Use positioning to judge the distance relative to the parent element. It is best to use a plug-in for dragging
迷茫2017-06-28 09:28:59
Personal feeling can be judged by the top value of each p. For example, when the "Please select" block is moved, its top value is closest to the one below, and you can basically determine which area it has been dragged to.
大家讲道理2017-06-28 09:28:59
There are several events for dragging. Looking at the manual, there seem to be 7 events