Explorar o código

fix: prevent multiple context menus

Konstantinos Kaloutas %!s(int64=2) %!d(string=hai) anos
pai
achega
c33fc8a60e
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      tldraw/packages/core/src/lib/TLApp/TLApp.ts

+ 1 - 0
tldraw/packages/core/src/lib/TLApp/TLApp.ts

@@ -1035,6 +1035,7 @@ export class TLApp<
 
 
     // Switch to select on right click to enable contextMenu state
     // Switch to select on right click to enable contextMenu state
     if (e.button === 2 && !this.editingShape) {
     if (e.button === 2 && !this.editingShape) {
+      e.preventDefault()
       this.transition('select')
       this.transition('select')
       return
       return
     }
     }