Skip to content

Commit

Permalink
feat: add other tab example
Browse files Browse the repository at this point in the history
  • Loading branch information
glopezep committed Apr 15, 2019
1 parent 8eb9142 commit 8f69263
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions src/components/tabs/tabs.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,27 @@ stories
}), {
info: {}
})
.add('without full width', () => ({
data () {
return {
current: 1
}
},
methods: {
handleClick (e, tabIndex) {
this.current = tabIndex
}
},
components: { WTabs, WTab },
template: `
<div>
<w-tabs backgroundColor="white" color="primary">
<w-tab icon="clock" :active="current === 1" @click="handleClick($event, 1)">Recents</w-tab>
<w-tab icon="map-marker" :active="current === 2" @click="handleClick($event, 2)">Nearby</w-tab>
<w-tab icon="heart" :active="current === 3" @click="handleClick($event, 3)">Favorites</w-tab>
</w-tabs>
</div>
`
}), {
info: {}
})

0 comments on commit 8f69263

Please sign in to comment.