This article analyzes the solution to the problem that the Textarea scroll bar cannot be dragged in JavaScript. Share it with everyone for your reference, the details are as follows:
In IE, have you ever encountered that the scroll bar of Textarea cannot be dragged, but the content can be scrolled by clicking the up and down buttons?
The reason for this problem is probably that the onfocus event is bound to the Textarea, but based on certain conditions, its focus is removed (ie blur()), which results in the scroll bar being unable to be dragged.
A typical example is:
me.$input.on("focus",function(){ if ($isIE && me.enabled == false) me.$input.blur(); });
When the input control $input (DOM element I·textarea) binds the focus event and then sets it to unavailable (!enabled), it loses focus, causing the scroll bar to not be dragged.
I hope this article will be helpful to everyone in JavaScript programming.