Gracefully prevent page text from being selected and dragged?

sometimes the text on the page is selected by mouse box , keyboard and other operations, resulting in a drag-and-drop mechanism that triggers the mouse, which is very bad for web experience, as shown in figure

.

clipboard.png
the text and pictures in the picture are easily selected by the mouse or hand-cheap, and then drag the mouse again, the scene is very embarrassing.
how to solve this problem gracefully?

I have tried to listen to the selection and drag events of body on the page, and the effect is very obvious, directly blocking all selections and drags except the input / text box, as shown below. However, there is a flaw: the text on the part of the dom (non-text / input box) wants to retain the function selected by the box , which is obviously too effective and not suitable.

document.body.onselectstart = document.body.ondrag = ()=>{ return false }

try to block it through CSS, the code is as follows. The effect is the same as that of the above scheme, and the defects are the same

body{
  -webkit-touch-callout: none;  
  -webkit-user-select: none;  
  -khtml-user-select: none;  
  -moz-user-select: none;  
  -ms-user-select: none;  
  user-select: none;
}

then narrows down the scope, but finds that as long as the text can be selected, the mouse can trigger the drag-and-drop mechanism, and it is not effective to disable body alone.

document.body.ondrag = ()=>{ return false }

how to achieve can only be selected, not dragged


er, we have just tried out a feasible solution, which only selects CSS restrictions on unselectable areas, and shields the drag events of the entire body

.
document.body.ondragstart= ()=>{ return false }
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e53f4f-45271.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e53f4f-45271.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?