View Full Version : Ext.button: remove all default css classes and add a single class

11 Mar 2012, 3:26 AM

I want to add a button which uses only one css class. The button mustn't use all the Ext.JS classes (x-btn....). How do I remove all default classes and add a single individual one? Thanks!!

Ext.define('myApp.view.basic.siteNavigationElement' ,{
extend: 'Ext.button.Button',
alias : 'widget.siteNavigationElement',
renderTo: Ext.get('upperBarLeftSideLinks'),
removeClass: 'x-btn', // does not work
addClass: 'myButtonClass' // does not work

11 Mar 2012, 6:55 AM
Change the baseCls config. Or if you want more control, change the renderTpl