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',
|
'blur',
|
||||||
'focus',
|
'focus',
|
||||||
'clear',
|
'clear',
|
||||||
'click',
|
|
||||||
'keypress',
|
'keypress',
|
||||||
'click-input',
|
'click-input',
|
||||||
'click-left-icon',
|
'click-left-icon',
|
||||||
@ -346,10 +345,6 @@ export default createComponent({
|
|||||||
resetScroll();
|
resetScroll();
|
||||||
},
|
},
|
||||||
|
|
||||||
onClick(event) {
|
|
||||||
this.$emit('click', event);
|
|
||||||
},
|
|
||||||
|
|
||||||
onClickInput(event) {
|
onClickInput(event) {
|
||||||
this.$emit('click-input', event);
|
this.$emit('click-input', event);
|
||||||
},
|
},
|
||||||
@ -585,7 +580,6 @@ export default createComponent({
|
|||||||
valueClass={bem('value')}
|
valueClass={bem('value')}
|
||||||
titleClass={[bem('label', labelAlign), this.labelClass]}
|
titleClass={[bem('label', labelAlign), this.labelClass]}
|
||||||
arrowDirection={this.arrowDirection}
|
arrowDirection={this.arrowDirection}
|
||||||
onClick={this.onClick}
|
|
||||||
>
|
>
|
||||||
<div class={bem('body')}>
|
<div class={bem('body')}>
|
||||||
{this.genInput()}
|
{this.genInput()}
|
||||||
|
@ -26,7 +26,7 @@ export default createComponent({
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
emits: ['click', 'close', 'replay'],
|
emits: ['close', 'replay'],
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -163,9 +163,6 @@ export default createComponent({
|
|||||||
vShow={this.show}
|
vShow={this.show}
|
||||||
class={bem({ wrapable: this.wrapable })}
|
class={bem({ wrapable: this.wrapable })}
|
||||||
style={barStyle}
|
style={barStyle}
|
||||||
onClick={(event) => {
|
|
||||||
this.$emit('click', event);
|
|
||||||
}}
|
|
||||||
>
|
>
|
||||||
{LeftIcon()}
|
{LeftIcon()}
|
||||||
<div ref="wrap" class={bem('wrap')} role="marquee">
|
<div ref="wrap" class={bem('wrap')} role="marquee">
|
||||||
|
@ -48,10 +48,6 @@ export default createComponent({
|
|||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
onClick() {
|
|
||||||
this.$emit('click');
|
|
||||||
},
|
|
||||||
|
|
||||||
genText() {
|
genText() {
|
||||||
const Text = (
|
const Text = (
|
||||||
<span class={bem('text', { ellipsis: !this.scrollable })}>
|
<span class={bem('text', { ellipsis: !this.scrollable })}>
|
||||||
@ -76,7 +72,6 @@ export default createComponent({
|
|||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
role="tab"
|
role="tab"
|
||||||
aria-selected={this.isActive}
|
|
||||||
class={[
|
class={[
|
||||||
bem({
|
bem({
|
||||||
active: this.isActive,
|
active: this.isActive,
|
||||||
@ -84,7 +79,7 @@ export default createComponent({
|
|||||||
}),
|
}),
|
||||||
]}
|
]}
|
||||||
style={this.style}
|
style={this.style}
|
||||||
onClick={this.onClick}
|
aria-selected={this.isActive}
|
||||||
>
|
>
|
||||||
{this.genText()}
|
{this.genText()}
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user