mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
docs(Popup): add transition component link (#4635)
This commit is contained in:
parent
c4713ad0c2
commit
8493fda8b0
@ -93,22 +93,13 @@ Use `get-container` prop to specify mount location
|
||||
|
||||
```html
|
||||
<!-- mount to body -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
get-container="body"
|
||||
/>
|
||||
<van-popup v-model="show" get-container="body" />
|
||||
|
||||
<!-- mount to #app -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
get-container="#app"
|
||||
/>
|
||||
<van-popup v-model="show" get-container="#app" />
|
||||
|
||||
<!-- Specify the mount location by function -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
:get-container="getContainer"
|
||||
/>
|
||||
<van-popup v-model="show" :get-container="getContainer" />
|
||||
```
|
||||
|
||||
```js
|
||||
@ -140,7 +131,7 @@ export default {
|
||||
| closeable | Whether to show close icon | *boolean* | `false` | 2.2.0 |
|
||||
| close-icon | Close icon name | *string* | `cross` | 2.2.0 |
|
||||
| close-icon-position | Close Icon Position,can be set to `top-left` `bottom-left` `bottom-right` | *string* | `top-right` | 2.2.2 |
|
||||
| transition | Transition | *string* | `popup-slide` | - |
|
||||
| transition | Transition, equivalent to `name` prop of [transtion](https://vuejs.org/v2/api/#transition) | *string* | - | - |
|
||||
| get-container | Return the mount node for Popup | *string \| () => Element* | - | - |
|
||||
| safe-area-inset-bottom | Whether to enable bottom safe area adaptation | *boolean* | `false` | 2.2.1 |
|
||||
|
||||
|
@ -103,22 +103,13 @@ export default {
|
||||
|
||||
```html
|
||||
<!-- 挂载到 body 节点下 -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
get-container="body"
|
||||
/>
|
||||
<van-popup v-model="show" get-container="body" />
|
||||
|
||||
<!-- 挂载到 #app 节点下 -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
get-container="#app"
|
||||
/>
|
||||
<van-popup v-model="show" get-container="#app" />
|
||||
|
||||
<!-- 通过函数指定挂载位置 -->
|
||||
<van-popup
|
||||
v-model="show"
|
||||
:get-container="getContainer"
|
||||
/>
|
||||
<van-popup v-model="show" :get-container="getContainer" />
|
||||
```
|
||||
|
||||
```js
|
||||
@ -151,7 +142,7 @@ export default {
|
||||
| closeable | 是否显示关闭图标 | *boolean* | `false` | 2.2.0 |
|
||||
| close-icon | 关闭图标名称或图片链接 | *string* | `cross` | 2.2.0 |
|
||||
| close-icon-position | 关闭图标位置,可选值为`top-left` `bottom-left` `bottom-right` | *string* | `top-right` | 2.2.2 |
|
||||
| transition | 动画类名,用法与 Vue 原生`transtion`组件的`name`属性一致 | *string* | - | - |
|
||||
| transition | 动画类名,等价于 [transtion](https://cn.vuejs.org/v2/api/index.html#transition) 的`name`属性 | *string* | - | - |
|
||||
| get-container | 指定挂载的节点,可以传入选择器,<br>或一个返回节点的函数 | *string \| () => Element* | - | - |
|
||||
| safe-area-inset-bottom | 是否开启底部安全区适配,[详细说明](#/zh-CN/quickstart#di-bu-an-quan-qu-gua-pei) | *boolean* | `false` | 2.2.1 |
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user