In my continued effort to change a Webix Button’s background color, I got it working using webix.html.addCss/removeCss. In order for the button to actually change color, I had to remove the class webixtype_base.
When I try to use removeCss on webixtype_base, it will not remove. The “bug” here is the RegExp in removeCss, which is:
node.className.replace(RegExp(" “+name,“g”),”");
Since webixtype_base does not have a leading space, this regular expression will never work, and my button will never change color.
I do realize that I can force the styles by using “!important”. So my guess is that the RexExp being used is to preserve all Webix classes in the HTML.