The jsTree plugin does not allow the user to select text using mouse

20 Views Asked by At

I'm using the jsTree latest plugin from https://www.jstree.com/. By default the text inside the jsTree are hyperlinks and due to that, the user cannot select the text using mouse drag. I want to know what changes I can make to make the text selectable using mouse drag without affecting the existing behavior of the jsTree results in my application. enter image description here

There is an alternative for this. i.e., pressing alt + mouse drag works in windows. But I want something to make the text selectable normally.

1

There are 1 best solutions below

1
Shwetha C N T On

The text selection using mouse drag is blocked in the jsTree by the event listener 'focus' in the jstree.min.js file. If the code related to the 'focus.jstree' event listener is removed, the user can select and copy text from jsTree.

enter image description here