瀏覽代碼

Fix wrong cursor for selection keyboard shortcut (#645)

Pressing 1 would change the cursor to a + instead of normal cursor
Christopher Chedeau 5 年之前
父節點
當前提交
29f1465b81
共有 1 個文件被更改,包括 1 次插入2 次删除
  1. 1 2
      src/index.tsx

+ 1 - 2
src/index.tsx

@@ -378,8 +378,7 @@ export class App extends React.Component<any, AppState> {
       this.state.draggingElement === null
     ) {
       if (!isHoldingSpace) {
-        document.documentElement.style.cursor =
-          shape === "text" ? CURSOR_TYPE.TEXT : CURSOR_TYPE.CROSSHAIR;
+        setCursorForShape(shape);
       }
       elements = clearSelection(elements);
       this.setState({ elementType: shape });