mirror of
https://github.com/ElemeFE/element.git
synced 2025-12-13 11:34:02 +08:00
ScrollBar: prevent right button click on thumb (#14196)
This commit is contained in:
@@ -40,6 +40,10 @@ export default {
|
||||
|
||||
methods: {
|
||||
clickThumbHandler(e) {
|
||||
// prevent click event of right button
|
||||
if (e.ctrlKey || e.button === 2) {
|
||||
return;
|
||||
}
|
||||
this.startDrag(e);
|
||||
this[this.bar.axis] = (e.currentTarget[this.bar.offset] - (e[this.bar.client] - e.currentTarget.getBoundingClientRect()[this.bar.direction]));
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user