[new feature] Tabs: add animated props to change tabs with animation (#2126)

This commit is contained in:
张敏
2018-11-23 19:51:47 +08:00
committed by neverland
parent 8042e37829
commit d84b13a6cc
15 changed files with 2097 additions and 268 deletions
+20 -7
View File
@@ -5,11 +5,24 @@
<span>Vant</span>
</h1>
<div class="mobile-switch-lang">
<span :class="{ active: $vantLang === 'en-US' }" @click="switchLang('en-US')">EN</span>
<span :class="{ active: $vantLang === 'zh-CN' }" @click="switchLang('zh-CN')">中文</span>
<span
:class="{ active: $vantLang === 'en-US' }"
@click="switchLang('en-US')"
>
EN
</span>
<span
:class="{ active: $vantLang === 'zh-CN' }"
@click="switchLang('zh-CN')"
>
中文
</span>
</div>
<h2 class="zanui-desc">{{ description }}</h2>
<template v-for="item in navList" v-if="item.showInMobile">
<template
v-for="item in navList"
v-if="item.showInMobile"
>
<mobile-nav
v-for="(group, index) in item.groups"
:group="group"
@@ -26,16 +39,16 @@ import MobileNav from './MobileNav';
import { setLang } from '../utils/lang';
export default {
components: {
MobileNav
},
data() {
return {
docConfig
};
},
components: {
MobileNav
},
computed: {
navList() {
return this.docConfig[this.$vantLang].nav || [];