mirror of
https://github.com/donl/meteor-ionic.git
synced 2026-05-31 22:07:29 -06:00
Added title parameter to ionView
This commit is contained in:
parent
af62af5533
commit
bbc03d6056
2 changed files with 11 additions and 0 deletions
|
|
@ -1,4 +1,10 @@
|
|||
<template name="ionView">
|
||||
{{#if title}}
|
||||
{{#contentFor "headerTitle"}}
|
||||
<h1 class="title">{{title}}</h1>
|
||||
{{/contentFor}}
|
||||
{{/if}}
|
||||
|
||||
<div class="{{classes}}">
|
||||
{{> UI.contentBlock}}
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -19,5 +19,10 @@ Template.ionView.helpers({
|
|||
}
|
||||
|
||||
return classes.join(' ');
|
||||
},
|
||||
title: function () {
|
||||
if ( Template.instance().data && Template.instance().data.title ) {
|
||||
return this.title;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue