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
@@ -59,7 +59,7 @@ export default {
tip3: '修改地址',
check: '全选',
clickButton: '点击按钮',
clickLink: '修改地址'
clickLink: '修改地址',
},
'en-US': {
submit: 'Submit',
@@ -68,13 +68,13 @@ export default {
tip3: 'Link',
check: 'Label',
clickButton: 'Click button',
clickLink: 'Click Link'
}
clickLink: 'Click Link',
},
},
data() {
return {
checked: true
checked: true,
};
},
@@ -84,8 +84,8 @@ export default {
},
onClickLink() {
this.$toast(this.$t('clickLink'));
}
}
},
},
};
</script>
+3 -3
View File
@@ -111,15 +111,15 @@ SubmitBar.props = {
safeAreaInsetBottom: Boolean,
decimalLength: {
type: Number,
default: 2
default: 2,
},
currency: {
type: String,
default: '¥'
default: '¥',
},
buttonType: {
type: String,
default: 'danger'
default: 'danger',
},
textAlign: String,
};
+20 -20
View File
@@ -6,10 +6,10 @@ test('submit event', () => {
const wrapper = mount(SubmitBar, {
context: {
props: {
price: 1
price: 1,
},
on: { submit }
}
on: { submit },
},
});
const button = wrapper.find('.van-button');
@@ -23,10 +23,10 @@ test('disable submit', () => {
context: {
props: {
price: 1,
disabled: true
disabled: true,
},
on: { submit }
}
on: { submit },
},
});
expect(wrapper).toMatchSnapshot();
@@ -41,9 +41,9 @@ test('without price', () => {
const wrapper = mount(SubmitBar, {
context: {
props: {
label: 'Label'
}
}
label: 'Label',
},
},
});
expect(wrapper).toMatchSnapshot();
@@ -52,8 +52,8 @@ test('without price', () => {
test('top slot', () => {
const wrapper = mount(SubmitBar, {
scopedSlots: {
top: () => 'top'
}
top: () => 'top',
},
});
expect(wrapper).toMatchSnapshot();
@@ -64,9 +64,9 @@ test('decimal-length prop', () => {
context: {
props: {
price: 111,
decimalLength: 1
}
}
decimalLength: 1,
},
},
});
expect(wrapper).toMatchSnapshot();
@@ -78,9 +78,9 @@ test('suffix-label prop', () => {
props: {
price: 111,
label: 'Label',
suffixLabel: 'Suffix Label'
}
}
suffixLabel: 'Suffix Label',
},
},
});
expect(wrapper).toMatchSnapshot();
@@ -91,9 +91,9 @@ test('text-align prop', () => {
context: {
props: {
price: 111,
textAlign: 'left'
}
}
textAlign: 'left',
},
},
});
expect(wrapper).toMatchSnapshot();
});