mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-24 22:35:41 +00:00
Merge "Strip trailing linebreaks on paste due to Chrome bug"
This commit is contained in:
commit
b5a3cfe30c
|
@ -1058,6 +1058,10 @@ ve.ce.Surface.prototype.afterPaste = function () {
|
|||
right--;
|
||||
context.splice( context.getLength() - 1, 1 );
|
||||
}
|
||||
// HACK: Strip trailing linebreaks probably introduced by Chrome bug
|
||||
while ( data.getType( right - 1 ) === 'break' ) {
|
||||
right--;
|
||||
}
|
||||
contextRange = new ve.Range( left, right );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue