fix(item-group-title): no content required

This commit is contained in:
Max Lynch
2015-10-08 16:34:50 -05:00
parent 2eaec4ca96
commit fa499e00c8

View File

@ -38,7 +38,7 @@ export class ItemGroupTitle {
* TODO
* @param {ElementRef} elementRef TODO
*/
constructor(elementRef: ElementRef, config: IonicConfig, @Host() content: Content) {
constructor(elementRef: ElementRef, config: IonicConfig, @Optional() @Host() content: Content) {
this.isSticky = true;
this.content = content;
this.ele = elementRef.nativeElement;
@ -46,6 +46,7 @@ export class ItemGroupTitle {
}
onInit() {
if(!this.content) { return; }
this.scrollContent = this.content.elementRef.nativeElement.children[0];