|
@@ -30,6 +30,10 @@ export default {
|
|
|
default: 'click',
|
|
|
validator: value => ['click', 'focus', 'hover', 'manual'].indexOf(value) > -1
|
|
|
},
|
|
|
+ openDelay: {
|
|
|
+ type: Number,
|
|
|
+ default: 0
|
|
|
+ },
|
|
|
title: String,
|
|
|
disabled: Boolean,
|
|
|
content: String,
|
|
@@ -105,7 +109,13 @@ export default {
|
|
|
this.showPopper = false;
|
|
|
},
|
|
|
handleMouseEnter() {
|
|
|
- this.showPopper = true;
|
|
|
+ if (this.openDelay) {
|
|
|
+ setTimeout(() => {
|
|
|
+ this.showPopper = true;
|
|
|
+ }, this.openDelay);
|
|
|
+ } else {
|
|
|
+ this.showPopper = true;
|
|
|
+ }
|
|
|
clearTimeout(this._timer);
|
|
|
},
|
|
|
handleMouseLeave() {
|