mirror of
https://github.com/youzan/vant.git
synced 2025-10-22 03:44:48 +00:00
feat(Uplaoder): add image-fit prop (#4189)
This commit is contained in:
@@ -185,6 +185,19 @@ it('render preview image', async () => {
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('image-fit prop', () => {
|
||||
const wrapper = mount(Uploader, {
|
||||
propsData: {
|
||||
imageFit: 'contain',
|
||||
fileList: [
|
||||
{ url: 'https://img.yzcdn.cn/vant/cat.jpeg' }
|
||||
]
|
||||
}
|
||||
});
|
||||
|
||||
expect(wrapper).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('disable preview image', async () => {
|
||||
const wrapper = mount(Uploader, {
|
||||
propsData: {
|
||||
|
Reference in New Issue
Block a user