[FIX] web_editor: allow to simulate a preview of a colorpicker reset
This is important so that trigger-value works (see https://github.com/odoo/odoo/commit/e590609ebb429c6254766aa1fd8cab3ce3fd4c74) closes odoo/odoo#43182 Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
@@ -983,7 +983,10 @@ const ColorpickerUserValueWidget = SelectUserValueWidget.extend({
|
||||
* @override
|
||||
*/
|
||||
getValue: function (methodName) {
|
||||
return this._previewColor || this._super(...arguments);
|
||||
if (typeof this._previewColor === 'string') {
|
||||
return this._previewColor;
|
||||
}
|
||||
return this._super(...arguments);
|
||||
},
|
||||
/**
|
||||
* @override
|
||||
|
||||
Reference in New Issue
Block a user