mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-25 10:21:17 +02:00
fix: incorrectly selecting linear elements on creation while tool-locked (#5785)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { queries, buildQueries } from "@testing-library/react";
|
||||
|
||||
const toolMap = {
|
||||
lock: "lock",
|
||||
selection: "selection",
|
||||
rectangle: "rectangle",
|
||||
diamond: "diamond",
|
||||
@@ -15,7 +16,7 @@ export type ToolName = keyof typeof toolMap;
|
||||
|
||||
const _getAllByToolName = (container: HTMLElement, tool: string) => {
|
||||
const toolTitle = toolMap[tool as ToolName];
|
||||
return queries.getAllByTestId(container, toolTitle);
|
||||
return queries.getAllByTestId(container, `toolbar-${toolTitle}`);
|
||||
};
|
||||
|
||||
const getMultipleError = (_container: any, tool: any) =>
|
||||
|
Reference in New Issue
Block a user