9 * @class Roo.bootstrap.NavGroup
10 * @extends Roo.bootstrap.Component
11 * Bootstrap NavGroup class
12 * @cfg {String} align left | right
13 * @cfg {Boolean} inverse false | true
14 * @cfg {String} type (nav|pills|tab) default nav
15 * @cfg {String} navId - reference Id for navbar.
19 * Create a new nav group
20 * @param {Object} config The config object
23 Roo.bootstrap.NavGroup = function(config){
24 Roo.bootstrap.NavGroup.superclass.constructor.call(this, config);
27 Roo.extend(Roo.bootstrap.NavGroup, Roo.bootstrap.Component, {
35 getAutoCreate : function(){
36 var cfg = Roo.apply({}, Roo.bootstrap.NavGroup.superclass.getAutoCreate.call(this));
43 if (['tabs','pills'].indexOf(this.type)!==-1) {
44 cfg.cls += ' nav-' + this.type
46 if (this.type!=='nav') {
47 Roo.log('nav type must be nav/tabs/pills')
49 cfg.cls += ' navbar-nav'
52 if (this.parent().sidebar === true) {
61 if (this.form === true) {
67 if (this.align === 'right') {
68 cfg.cls += ' navbar-right';
70 cfg.cls += ' navbar-left';
74 if (this.align === 'right') {
75 cfg.cls += ' navbar-right';
79 cfg.cls += ' navbar-inverse';