[new feature] NoticeBar: add right-icon prop

This commit is contained in:
陈嘉涵
2019-04-30 14:59:51 +08:00
parent 152ee6a90d
commit dec1e4cee8
5 changed files with 36 additions and 26 deletions
@@ -1,10 +1,9 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`left-icon slot 1`] = `
exports[`icon slot 1`] = `
<div class="van-notice-bar">Custom Left Icon<div class="van-notice-bar__wrap">
<div class="van-notice-bar__content" style="padding-left: 0px; animation-delay: 1s; animation-duration: 0s;">
Content
</div>
</div>
</div>
</div>Custom Right Icon</div>
`;
+2 -1
View File
@@ -13,12 +13,13 @@ test('close event', () => {
expect(wrapper.emitted('close')).toBeTruthy();
});
test('left-icon slot', () => {
test('icon slot', () => {
const wrapper = mount({
template: `
<notice-bar>
Content
<template v-slot:left-icon>Custom Left Icon</template>
<template v-slot:right-icon>Custom Right Icon</template>
</notice-bar>
`,
components: {