Skip to content

Commit

Permalink
getBoundingClientRect actually works on BR nodes
Browse files Browse the repository at this point in the history
Fix #765
  • Loading branch information
jhchen committed Jul 20, 2016
1 parent a2ee3da commit c66e888
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions core/selection.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,7 @@ class Selection {
}
var rect = range.getBoundingClientRect();
} else {
if (leaf instanceof BreakBlot) {
var rect = leaf.parent.domNode.getBoundingClientRect();
} else {
var rect = leaf.domNode.getBoundingClientRect();
}
var rect = leaf.domNode.getBoundingClientRect();
if (offset > 0) side = 'right';
}
bounds = {
Expand Down

0 comments on commit c66e888

Please sign in to comment.