chore: add trailingComma

This commit is contained in:
陈嘉涵
2020-01-19 11:57:09 +08:00
parent e841175fe8
commit 389d68884d
269 changed files with 2706 additions and 2702 deletions
+6 -6
View File
@@ -27,7 +27,7 @@
:loading="!show"
>
<div class="demo-preview">
<img src="https://img.yzcdn.cn/vant/logo.png">
<img src="https://img.yzcdn.cn/vant/logo.png" />
<div class="demo-content">
<h3>{{ $t('title') }}</h3>
<p>{{ $t('desc') }}</p>
@@ -45,21 +45,21 @@ export default {
showAvatar: '显示头像',
showChildren: '显示子组件',
title: '关于 Vant',
desc: 'Vant 是一套轻量、可靠的移动端 Vue 组件库,提供了丰富的基础组件和业务组件,帮助开发者快速搭建移动应用。'
desc: 'Vant 是一套轻量、可靠的移动端 Vue 组件库,提供了丰富的基础组件和业务组件,帮助开发者快速搭建移动应用。',
},
'en-US': {
showAvatar: 'Show Avatar',
showChildren: 'Show Children',
title: 'About Vant',
desc: 'Vant is a set of Mobile UI Components built on Vue.'
}
desc: 'Vant is a set of Mobile UI Components built on Vue.',
},
},
data() {
return {
show: false
show: false,
};
}
},
};
</script>
+8 -8
View File
@@ -88,32 +88,32 @@ Skeleton.props = {
avatar: Boolean,
row: {
type: Number,
default: 0
default: 0,
},
loading: {
type: Boolean,
default: true
default: true,
},
animate: {
type: Boolean,
default: true
default: true,
},
avatarSize: {
type: String,
default: '32px'
default: '32px',
},
avatarShape: {
type: String,
default: 'round'
default: 'round',
},
titleWidth: {
type: [Number, String],
default: '40%'
default: '40%',
},
rowWidth: {
type: [Number, String, Array],
default: DEFAULT_ROW_WIDTH
}
default: DEFAULT_ROW_WIDTH,
},
};
export default createComponent<SkeletonProps>(Skeleton);
+7 -7
View File
@@ -5,8 +5,8 @@ test('row-width array', () => {
const wrapper = mount(Skeleton, {
propsData: {
row: 4,
rowWidth: ['100%', 30, '5rem']
}
rowWidth: ['100%', 30, '5rem'],
},
});
expect(wrapper).toMatchSnapshot();
});
@@ -18,7 +18,7 @@ test('render chidren', () => {
<div>Content</div>
</skeleton>
`,
components: { Skeleton }
components: { Skeleton },
});
expect(wrapper).toMatchSnapshot();
});
@@ -28,8 +28,8 @@ test('avatar shape', () => {
propsData: {
avatar: true,
avatarSize: 20,
avatarShape: 'square'
}
avatarShape: 'square',
},
});
expect(wrapper).toMatchSnapshot();
});
@@ -38,8 +38,8 @@ test('disable animate', () => {
const wrapper = mount(Skeleton, {
propsData: {
row: 1,
aniamte: false
}
aniamte: false,
},
});
expect(wrapper).toMatchSnapshot();
});