ElemeFE / element

A Vue.js 2.0 UI Toolkit for Web
https://element.eleme.io/
MIT License
54.1k stars 14.64k forks source link

[bug report] popconfirm [bubble confirmation box] when using the in DOM template, v-on cannot listen to the callback event #19707

Open ZhiLinLiang opened 4 years ago

ZhiLinLiang commented 4 years ago

Element UI version

2.13.2

OS/Browsers version

win7 / Chrome

Vue version

2.6.11

Reproduction Link

https://codepen.io/8023/pen/PoZpyae?editable=true%3Dhttps%3A%2F%2Felement.eleme.cn%2F

Steps to reproduce

使用in-DOM模板时不能使用v-on侦听camelCase事件

What is Expected?

应该使用“ on-confirm”而不是“ onConfirm”。 methods:{ confirm:function(){ this.visible=!1, this.$emit("on-confirm") }, cancel:function(){ this.visible=!1, this.$emit("on-cancel") } }

What is actually happening?

使用in-DOM模板时使用v-on无法侦听到onConfirm事件

element-bot commented 4 years ago

Translation of this issue:

Element UI version

0.1.0

OS/Browsers version

win7 / Chrome

Vue version

2.6.11

Reproduction Link

https://codepen.io/8023/pen/PoZpyae?editable=true%3Dhttps%3A%2F%2Felement.eleme.cn%2F

Steps to reproduce

You cannot use v-on to listen for camelCase events when using in DOM templates

What is Expected?

'on confirm' should be used instead of 'on confirm'.

What is actually happening?

V-on cannot listen to onconfirm event when using in DOM template

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.