add platform style attribute to tabs

This commit is contained in:
Nick Wientge 2014-12-28 11:15:08 -05:00
parent 39e03979b9
commit aa2be71240
2 changed files with 8 additions and 4 deletions

View file

@ -1,5 +1,7 @@
<template name="ionTabs">
<div class="{{classes}}">
{{> UI.contentBlock}}
<div class="tabs">
{{> UI.contentBlock}}
</div>
</div>
</template>

View file

@ -16,15 +16,17 @@ Template.ionTabs.destroyed = function () {
Template.ionTabs.helpers({
classes: function () {
var classes = ['tabs'];
var classes = [];
if (this.class) {
classes.push(this.class);
}
if (Platform.isAndroid()) {
if (this.style === 'android') {
classes.push('tabs-top tabs-striped tabs-icon-left');
} else {
}
if (this.style === 'ios') {
classes.push('tabs-icon-top');
}