mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
chore: inherit click event
This commit is contained in:
parent
af94c92614
commit
48ff0f85fb
@ -83,7 +83,6 @@ export default createComponent({
|
||||
'blur',
|
||||
'focus',
|
||||
'clear',
|
||||
'click',
|
||||
'keypress',
|
||||
'click-input',
|
||||
'click-left-icon',
|
||||
@ -346,10 +345,6 @@ export default createComponent({
|
||||
resetScroll();
|
||||
},
|
||||
|
||||
onClick(event) {
|
||||
this.$emit('click', event);
|
||||
},
|
||||
|
||||
onClickInput(event) {
|
||||
this.$emit('click-input', event);
|
||||
},
|
||||
@ -585,7 +580,6 @@ export default createComponent({
|
||||
valueClass={bem('value')}
|
||||
titleClass={[bem('label', labelAlign), this.labelClass]}
|
||||
arrowDirection={this.arrowDirection}
|
||||
onClick={this.onClick}
|
||||
>
|
||||
<div class={bem('body')}>
|
||||
{this.genInput()}
|
||||
|
@ -26,7 +26,7 @@ export default createComponent({
|
||||
},
|
||||
},
|
||||
|
||||
emits: ['click', 'close', 'replay'],
|
||||
emits: ['close', 'replay'],
|
||||
|
||||
data() {
|
||||
return {
|
||||
@ -163,9 +163,6 @@ export default createComponent({
|
||||
vShow={this.show}
|
||||
class={bem({ wrapable: this.wrapable })}
|
||||
style={barStyle}
|
||||
onClick={(event) => {
|
||||
this.$emit('click', event);
|
||||
}}
|
||||
>
|
||||
{LeftIcon()}
|
||||
<div ref="wrap" class={bem('wrap')} role="marquee">
|
||||
|
@ -48,10 +48,6 @@ export default createComponent({
|
||||
},
|
||||
|
||||
methods: {
|
||||
onClick() {
|
||||
this.$emit('click');
|
||||
},
|
||||
|
||||
genText() {
|
||||
const Text = (
|
||||
<span class={bem('text', { ellipsis: !this.scrollable })}>
|
||||
@ -76,7 +72,6 @@ export default createComponent({
|
||||
return (
|
||||
<div
|
||||
role="tab"
|
||||
aria-selected={this.isActive}
|
||||
class={[
|
||||
bem({
|
||||
active: this.isActive,
|
||||
@ -84,7 +79,7 @@ export default createComponent({
|
||||
}),
|
||||
]}
|
||||
style={this.style}
|
||||
onClick={this.onClick}
|
||||
aria-selected={this.isActive}
|
||||
>
|
||||
{this.genText()}
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user