2018-04-16 13:54:37 +00:00
|
|
|
<cn>
|
|
|
|
#### 从浮层内关闭
|
|
|
|
使用 `visible` 属性控制浮层显示。
|
|
|
|
</cn>
|
|
|
|
|
|
|
|
<us>
|
|
|
|
#### Controlling the close of the dialog
|
|
|
|
Use `visible` prop to control the display of the card.
|
|
|
|
</us>
|
|
|
|
|
2019-10-09 10:32:23 +00:00
|
|
|
```tpl
|
2018-01-12 08:10:41 +00:00
|
|
|
<template>
|
2019-09-28 12:45:07 +00:00
|
|
|
<a-popover title="Title" trigger="click" v-model="visible">
|
2018-01-19 10:01:43 +00:00
|
|
|
<a @click="hide" slot="content">Close</a>
|
2018-01-23 10:55:39 +00:00
|
|
|
<a-button type="primary">Click me</a-button>
|
2018-04-16 13:54:37 +00:00
|
|
|
</a-popover>
|
2018-01-12 08:10:41 +00:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
2019-09-28 12:45:07 +00:00
|
|
|
export default {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
visible: false,
|
|
|
|
};
|
2018-01-12 08:10:41 +00:00
|
|
|
},
|
2019-09-28 12:45:07 +00:00
|
|
|
methods: {
|
|
|
|
hide() {
|
|
|
|
console.log(111);
|
|
|
|
this.visible = false;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
2018-01-12 08:10:41 +00:00
|
|
|
</script>
|
2018-04-16 13:54:37 +00:00
|
|
|
```
|