Results 1 to 2 of 2

Thread: Ext.button: remove all default css classes and add a single class

  1. #1
    Sencha User
    Join Date
    Mar 2012
    Posts
    10
    Vote Rating
    0
      0  

    Question Ext.button: remove all default css classes and add a single class

    Hey,

    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
    });

  2. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,382
    Answers
    3997
    Vote Rating
    1536
      0  

    Default

    Change the baseCls config. Or if you want more control, change the renderTpl
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Frontend Engineer
    ________________
    Need any sort of Ext JS help? Modus Create is here to help!

    Check out my GitHub:
    https://github.com/mitchellsimoens

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •