X-Git-Url: http://git.roojs.org/?p=roojs1;a=blobdiff_plain;f=Roo%2Fbootstrap%2FButton.js;fp=Roo%2Fbootstrap%2FButton.js;h=8fb44dd1f36380f9a46e4015b42279cbc7e45c6d;hp=86b6244e42904a77184af2e5f12fa08e033151c6;hb=c5dcc1cee98b4c3b53d9334cf50c943d448af82f;hpb=ae72e7277d536ddcb0c55c1548f6ba830beeb17d diff --git a/Roo/bootstrap/Button.js b/Roo/bootstrap/Button.js index 86b6244e42..8fb44dd1f3 100644 --- a/Roo/bootstrap/Button.js +++ b/Roo/bootstrap/Button.js @@ -78,6 +78,7 @@ Roo.extend(Roo.bootstrap.Button, Roo.bootstrap.Component, { disabled: false, isClose: false, glyphicon: '', + fa: '', badge: '', theme: 'default', inverse: false, @@ -188,6 +189,10 @@ Roo.extend(Roo.bootstrap.Button, Roo.bootstrap.Component, { Roo.log('changing to ul' ); cfg.tag = 'ul'; this.glyphicon = 'caret'; + if (Roo.bootstrap.version == 4) { + this.fa = 'caret-down'; + } + } cfg.cls += this.size.length ? (' btn-' + this.size) : ''; @@ -226,6 +231,16 @@ Roo.extend(Roo.bootstrap.Button, Roo.bootstrap.Component, { } ]; } + if (this.fa) { + cfg.html = ' ' + cfg.html; + + cfg.cn = [ + { + tag: 'i', + cls: 'fa fa-' + this.fa + } + ]; + } if (this.badge) { cfg.html += ' ';