ant-design-vue/components/dropdown/demo/trigger.md

28 lines
683 B
Markdown
Raw Normal View History

2018-01-29 10:57:20 +00:00
<cn>
#### 触发方式
默认是移入触发菜单,可以点击触发。
</cn>
<us>
#### Trigger mode
The default trigger mode is `hover`, you can change it to `click`.
</us>
2019-10-09 10:32:23 +00:00
```tpl
2018-01-29 10:57:20 +00:00
<template>
<a-dropdown :trigger="['click']">
2019-09-28 12:45:07 +00:00
<a class="ant-dropdown-link" href="#"> Click me <a-icon type="down" /> </a>
2018-01-29 10:57:20 +00:00
<a-menu slot="overlay">
<a-menu-item key="0">
<a href="http://www.alipay.com/">1st menu item</a>
</a-menu-item>
<a-menu-item key="1">
<a href="http://www.taobao.com/">2nd menu item</a>
</a-menu-item>
<a-menu-divider />
<a-menu-item key="3">3rd menu item</a-menu-item>
</a-menu>
</a-dropdown>
</template>
```