roojs-bootstrap.js
[roojs1] / roojs-bootstrap-debug.js
index 961210f..7646245 100644 (file)
@@ -1508,7 +1508,7 @@ Roo.extend(Roo.bootstrap.Container, Roo.bootstrap.Component,  {
  *
  * possible... may not be implemented..
  * @cfg {String} header_image  src url of image.
- * @cfg {String} header
+ * @cfg {String|Object} header
  * @cfg {Number} header_size (0|1|2|3|4|5) H1 or H2 etc.. 0 indicates default
  * 
  * @cfg {String} title
@@ -1677,7 +1677,12 @@ Roo.extend(Roo.bootstrap.Card, Roo.bootstrap.Component,  {
                 cls : 'card-header',
                 html : this.header // escape?
             });
-        }
+        } else {
+           cfg.cn.push({
+                tag : 'div',
+                cls : 'card-header d-none'
+            });
+       }
         if (this.header_image.length) {
             cfg.cn.push({
                 tag : 'img',
@@ -1734,6 +1739,16 @@ Roo.extend(Roo.bootstrap.Card, Roo.bootstrap.Component,  {
     },
     
     
+    getCardHeader : function()
+    {
+        var  ret = this.el.select('.card-header',true).first();
+       if (ret.hasClass('d-none')) {
+           ret.removeClass('d-none');
+       }
+        
+        return ret;
+    },
+    
     getChildContainer : function()
     {