[FIX] web_editor: allow adding options on predefined bg classes
The editor allows using background image options on snippets which use a background-image. For this to work, the oe_img_bg css class has to be on this snippet. The problem is that the class is absent when using some themes as the select_class method removes it to place its own value. Now, the oe_img_bg class is (re)added when a select_class method is used within the background image option.
This commit is contained in:
@@ -383,7 +383,7 @@ odoo.define('web_editor.snippets.options', function (require) {
|
||||
},
|
||||
select_class : function (type, value, $li) {
|
||||
this.background(type, '', $li);
|
||||
this._super(type, value, $li);
|
||||
this._super(type, value ? (value + " oe_img_bg") : value, $li);
|
||||
},
|
||||
choose_image: function (type, value, $li) {
|
||||
if(type !== "click") return;
|
||||
|
||||
Reference in New Issue
Block a user