mirror of
https://github.com/fastmail/Squire.git
synced 2024-12-22 15:23:29 -05:00
Bugfix: decreaseBlockQuoteLevel removed all levels
This commit is contained in:
parent
19f73d162f
commit
724611477d
1 changed files with 1 additions and 2 deletions
|
@ -1317,10 +1317,9 @@ var increaseBlockQuoteLevel = function ( frag ) {
|
||||||
};
|
};
|
||||||
|
|
||||||
var decreaseBlockQuoteLevel = function ( frag ) {
|
var decreaseBlockQuoteLevel = function ( frag ) {
|
||||||
var root = this._root;
|
|
||||||
var blockquotes = frag.querySelectorAll( 'blockquote' );
|
var blockquotes = frag.querySelectorAll( 'blockquote' );
|
||||||
Array.prototype.filter.call( blockquotes, function ( el ) {
|
Array.prototype.filter.call( blockquotes, function ( el ) {
|
||||||
return !getNearest( el.parentNode, root, 'BLOCKQUOTE' );
|
return !getNearest( el.parentNode, frag, 'BLOCKQUOTE' );
|
||||||
}).forEach( function ( el ) {
|
}).forEach( function ( el ) {
|
||||||
replaceWith( el, empty( el ) );
|
replaceWith( el, empty( el ) );
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue