1
0
mirror of https://gitee.com/vant-contrib/vant.git synced 2025-04-06 03:57:59 +08:00

docs(ImagePreview): fix missing parameters ()

This commit is contained in:
Icey Wu 2024-06-22 19:20:04 +08:00 committed by GitHub
parent 8ca1d414c8
commit ad117d5ffd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions
packages/vant/src/image-preview

@ -194,7 +194,7 @@ When you customize the image through the `image` slot, you can bind the `style`
:close-on-click-image="false" :close-on-click-image="false"
> >
<template #image="{ src, style, onLoad }"> <template #image="{ src, style, onLoad }">
<img :style="[{ width: '100%' }, style]" @load="onLoad" /> <img :src="src" :style="[{ width: '100%' }, style]" @load="onLoad" />
</template> </template>
</van-image-preview> </van-image-preview>
``` ```

@ -195,7 +195,7 @@ export default {
:close-on-click-image="false" :close-on-click-image="false"
> >
<template #image="{ src, style, onLoad }"> <template #image="{ src, style, onLoad }">
<img :style="[{ width: '100%' }, style]" @load="onLoad" /> <img :src="src" :style="[{ width: '100%' }, style]" @load="onLoad" />
</template> </template>
</van-image-preview> </van-image-preview>
``` ```