[FIX] web_editor: display current text color in text color button
The editor toolbar button to trigger the colorpicker is supposed to show the color of the currently selected text. This was failing in iframes because the code was called on the wrong document. task-2623347 X-original-commit: 7ad6536dd98f9749d63bfc7292e490f6ac629b9c Part-of: odoo/odoo#83254
This commit is contained in:
@@ -1390,7 +1390,7 @@ export class OdooEditor extends EventTarget {
|
||||
if (hasGradient && hasTextGradientClass) {
|
||||
foreColor = backgroundImage;
|
||||
} else {
|
||||
foreColor = document.queryCommandValue('foreColor');
|
||||
foreColor = this.document.queryCommandValue('foreColor');
|
||||
}
|
||||
}
|
||||
if (!hiliteColor) {
|
||||
|
||||
Reference in New Issue
Block a user