Adapt fallback for selection
Thanks @darthmaim for pointing this out
This commit is contained in:
parent
8290c4f726
commit
42cf8d3679
@ -10,7 +10,7 @@ var h = require('../../lib/helper')
|
||||
function bindSelectionHandler(element, i) {
|
||||
function getRangeNode() {
|
||||
var selection = window.getSelection ? window.getSelection() :
|
||||
document.getSelection ? document.getSelection() : {rangeCount: 0};
|
||||
document.getSelection ? document.getSelection() : '';
|
||||
if (selection.toString().length === 0) {
|
||||
return null;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user