2
0
mirror of https://github.com/tenrok/vue-form-wizard.git synced 2026-06-16 09:20:32 +03:00

Support tab icons

This commit is contained in:
cristijora
2017-04-16 13:22:04 +03:00
parent 7cc9c5aef4
commit 3410412fec
5 changed files with 42 additions and 19 deletions
+4
View File
@@ -12,6 +12,10 @@
type: String,
default: ''
},
icon: {
type: String,
default: ''
},
beforeChange: {
type: Function
}
+5 -2
View File
@@ -15,7 +15,7 @@
<li v-for="(tab, index) in tabs" :class="{active:tab.active}">
<a href="" @click.prevent="navigateToTab(index)">
<div class="icon-circle" :class="{checked:isChecked(index)}">
<i class="ti-user"></i>
<i v-if="tab.icon" :class="tab.icon"></i>
</div>
{{tab.title}}
</a>
@@ -32,7 +32,7 @@
@click="prevTab">
{{backButtonText}}
</button>
<button v-if="isLastStep" type="button" class="btn btn-info btn-fill btn-wd btn-next pull-right" @click="nextTab">
<button v-if="isLastStep" type="button" class="btn btn-info btn-fill btn-wd btn-next pull-right" @click="finish">
{{finishButtonText}}
</button>
<button v-else type="button" class="btn btn-info btn-fill btn-wd btn-next pull-right" @click="nextTab">
@@ -158,6 +158,9 @@
this.activeTabIndex--
this.isLastStep = false
}
},
finish () {
this.$emit('on-complete')
}
},
mounted () {