From d5a6014076d8b08260340a38694bdff55f79bdd7 Mon Sep 17 00:00:00 2001 From: David Luzar Date: Fri, 7 Jan 2022 23:18:04 +0100 Subject: [PATCH] fix: prefer spreadsheet data over image (#4533) --- src/components/App.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/App.tsx b/src/components/App.tsx index c5ec90a8..cb89bac8 100644 --- a/src/components/App.tsx +++ b/src/components/App.tsx @@ -1306,7 +1306,8 @@ class App extends React.Component { } } - if (isSupportedImageFile(file)) { + // prefer spreadsheet data over image file (MS Office/Libre Office) + if (isSupportedImageFile(file) && !data.spreadsheet) { const { x: sceneX, y: sceneY } = viewportCoordsToSceneCoords( { clientX: cursorX, clientY: cursorY }, this.state,