mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat(ImagePreview): add overlayStyle option (#10043)
This commit is contained in:
parent
1d4c4df4fa
commit
9a2acced0d
@ -27,6 +27,7 @@ export default createComponent({
|
||||
className: null,
|
||||
closeable: Boolean,
|
||||
asyncClose: Boolean,
|
||||
overlayStyle: Object,
|
||||
showIndicators: Boolean,
|
||||
images: {
|
||||
type: Array,
|
||||
|
@ -130,6 +130,7 @@ export default {
|
||||
| closeIcon `v2.5.0` | Close icon name | _string_ | `clear` |
|
||||
| closeIconPosition `v2.5.0` | Close icon position,can be set to `top-left` `bottom-left` `bottom-right` | _string_ | `top-right` |
|
||||
| transition `v2.12.8` | Transition, equivalent to `name` prop of [transition](https://vuejs.org/v2/api/#transition) | _string_ | `van-fade` |
|
||||
| overlayStyle `v2.12.37` | Custom overlay style | _object_ | - |
|
||||
| getContainer | Return the mount node for ImagePreview | _string \| () => Element_ | - |
|
||||
|
||||
### Props
|
||||
@ -151,6 +152,7 @@ export default {
|
||||
| close-icon `v2.5.0` | Close icon name | _string_ | `clear` |
|
||||
| close-icon-position `v2.5.0` | Close icon position,can be set to `top-left` `bottom-left` `bottom-right` | _string_ | `top-right` |
|
||||
| transition `v2.12.8` | Transition, equivalent to `name` prop of [transition](https://vuejs.org/v2/api/#transition) | _string_ | `van-fade` |
|
||||
| overlay-style `v2.12.37` | Custom overlay style | _object_ | - |
|
||||
| get-container | Return the mount node for ImagePreview | _string \| () => Element_ | - |
|
||||
|
||||
### Events
|
||||
|
@ -166,6 +166,7 @@ export default {
|
||||
| closeIcon `v2.5.0` | 关闭图标名称或图片链接 | _string_ | `clear` |
|
||||
| closeIconPosition `v2.5.0` | 关闭图标位置,可选值为`top-left`<br>`bottom-left` `bottom-right` | _string_ | `top-right` |
|
||||
| transition `v2.12.8` | 动画类名,等价于 [transition](https://cn.vuejs.org/v2/api/index.html#transition) 的 `name` 属性 | _string_ | `van-fade` |
|
||||
| overlayStyle `v2.12.37` | 自定义遮罩层样式 | _object_ | - |
|
||||
| getContainer | 指定挂载的节点,[用法示例](#/zh-CN/popup#zhi-ding-gua-zai-wei-zhi) | _string \| () => Element_ | - |
|
||||
|
||||
### Props
|
||||
@ -189,6 +190,7 @@ export default {
|
||||
| close-icon `v2.5.0` | 关闭图标名称或图片链接 | _string_ | `clear` |
|
||||
| close-icon-position `v2.5.0` | 关闭图标位置,可选值为`top-left`<br>`bottom-left` `bottom-right` | _string_ | `top-right` |
|
||||
| transition `v2.12.8` | 动画类名,等价于 [transition](https://cn.vuejs.org/v2/api/index.html#transition) 的 `name` 属性 | _string_ | `van-fade` |
|
||||
| overlay-style `v2.12.37` | 自定义遮罩层样式 | _object_ | - |
|
||||
| get-container | 指定挂载的节点,[用法示例](#/zh-CN/popup#zhi-ding-gua-zai-wei-zhi) | _string \| () => Element_ | - |
|
||||
|
||||
### Events
|
||||
|
@ -19,6 +19,7 @@ const defaultConfig = {
|
||||
asyncClose: false,
|
||||
transition: 'van-fade',
|
||||
getContainer: 'body',
|
||||
overlayStyle: null,
|
||||
startPosition: 0,
|
||||
swipeDuration: 300,
|
||||
showIndicators: false,
|
||||
|
1
types/image-preview.d.ts
vendored
1
types/image-preview.d.ts
vendored
@ -15,6 +15,7 @@ export type ImagePreviewOptions =
|
||||
closeIcon?: string;
|
||||
asyncClose?: boolean;
|
||||
transition?: string;
|
||||
overlayStyle?: object;
|
||||
swipeDuration?: number;
|
||||
startPosition?: number;
|
||||
showIndicators?: boolean;
|
||||
|
Loading…
x
Reference in New Issue
Block a user