[FIX] web_editor: allow to delete backward a contenteditable

Deleting a node content-editable false did not work.

X-original-commit: odoo/odoo@de42d0f965
Part-of: odoo/odoo#77377
This commit is contained in:
Nicolas Bayet
2021-09-28 23:42:54 +00:00
committed by Thibault Delavallée
parent 4813f42997
commit 810f832703
@@ -75,6 +75,10 @@ HTMLElement.prototype.oDeleteBackward = function (offset, alreadyMoved = false)
leftNode.remove();
return;
}
if (leftNode.getAttribute && leftNode.getAttribute('contenteditable') === 'false') {
leftNode.remove();
return;
}
if (!isBlock(leftNode) || isVisibleEmpty(leftNode)) {
/**
* Backspace just after an inline node, convert to backspace at the