Răsfoiți Sursa

switch to default selection tool after pasting

Ryan Di 4 săptămâni în urmă
părinte
comite
4053ced148
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      packages/excalidraw/components/App.tsx

+ 2 - 2
packages/excalidraw/components/App.tsx

@@ -3203,7 +3203,7 @@ class App extends React.Component<AppProps, AppState> {
         }
         this.addTextFromPaste(data.text, isPlainPaste);
       }
-      this.setActiveTool({ type: "selection" });
+      this.setActiveTool({ type: this.defaultSelectionTool }, true);
       event?.preventDefault();
     },
   );
@@ -3347,7 +3347,7 @@ class App extends React.Component<AppProps, AppState> {
         }
       },
     );
-    this.setActiveTool({ type: "selection" });
+    this.setActiveTool({ type: this.defaultSelectionTool }, true);
 
     if (opts.fitToContent) {
       this.scrollToContent(duplicatedElements, {