The custom table selection was not limited to the editable area bounds, which means we could end up styling a table as selected, which did not belong to the editor's scope. This sometimes happened when Firefox triggered a selectionchange event during the instantiation of the editor and the selection happened to be in a table outside the editor. opw-3150654 task-3166078 closes odoo/odoo#111779 X-original-commit: d51aab54775ed541d7955cee032aceed143d3a08 Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>