Merge branch '2.x' into dev
This commit is contained in:
+5
-12
@@ -17,9 +17,7 @@ app.use(Popover);
|
||||
```html
|
||||
<van-popover v-model:show="showPopover" :actions="actions" @select="onSelect">
|
||||
<template #reference>
|
||||
<van-button type="primary" @click="showPopover = true">
|
||||
Light Theme
|
||||
</van-button>
|
||||
<van-button type="primary"> Light Theme </van-button>
|
||||
</template>
|
||||
</van-popover>
|
||||
```
|
||||
@@ -53,9 +51,7 @@ Using the `theme` prop to change the style of Popover.
|
||||
```html
|
||||
<van-popover v-model:show="showPopover" theme="dark" :actions="actions">
|
||||
<template #reference>
|
||||
<van-button type="primary" @click="showPopover = true">
|
||||
Dark Theme
|
||||
</van-button>
|
||||
<van-button type="primary"> Dark Theme </van-button>
|
||||
</template>
|
||||
</van-popover>
|
||||
```
|
||||
@@ -103,9 +99,7 @@ bottom-end # Bottom right
|
||||
```html
|
||||
<van-popover v-model:show="showPopover" :actions="actions">
|
||||
<template #reference>
|
||||
<van-button type="primary" @click="showPopover = true">
|
||||
Show Icon
|
||||
</van-button>
|
||||
<van-button type="primary"> Show Icon </van-button>
|
||||
</template>
|
||||
</van-popover>
|
||||
```
|
||||
@@ -132,9 +126,7 @@ Using the `disabled` option to disable an action.
|
||||
```html
|
||||
<van-popover v-model:show="showPopover" :actions="actions">
|
||||
<template #reference>
|
||||
<van-button type="primary" @click="showPopover = true">
|
||||
Disable Action
|
||||
</van-button>
|
||||
<van-button type="primary"> Disable Action </van-button>
|
||||
</template>
|
||||
</van-popover>
|
||||
```
|
||||
@@ -164,6 +156,7 @@ export default {
|
||||
| actions | Actions | _Action[]_ | `[]` |
|
||||
| placement | Placement | _string_ | `bottom` |
|
||||
| theme | Theme,can be set to `dark` | _string_ | `light` |
|
||||
| trigger `v2.11.1` | Trigger mode,can be set to `click` | - |
|
||||
| offset | Distance to reference | _[number, number]_ | `[0, 8]` |
|
||||
| overlay | Whether to show overlay | _boolean_ | `false` |
|
||||
| close-on-click-action | Whether to close when clicking action | _boolean_ | `true` |
|
||||
|
||||
Reference in New Issue
Block a user