mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Resize handler detection should not be active when moving multip… (#767)
* Fix bug. * Implement `getSelectedElements`. * Explicit condition. * Respect variable naming. * Keep state consistent. * Use `isSomeElementSelected` abstraction. * Missing ones.
This commit is contained in:
parent
ad72946131
commit
6ebd41734f
9 changed files with 53 additions and 37 deletions
|
@ -1,6 +1,7 @@
|
|||
import React from "react";
|
||||
import { t } from "../i18n";
|
||||
import { ExcalidrawElement } from "../element/types";
|
||||
import { getSelectedElements } from "../scene";
|
||||
|
||||
import "./HintViewer.css";
|
||||
|
||||
|
@ -20,7 +21,7 @@ const getHints = ({ elementType, multiMode, isResizing, elements }: Hint) => {
|
|||
}
|
||||
|
||||
if (isResizing) {
|
||||
const selectedElements = elements.filter(el => el.isSelected);
|
||||
const selectedElements = getSelectedElements(elements);
|
||||
if (
|
||||
selectedElements.length === 1 &&
|
||||
(selectedElements[0].type === "arrow" ||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue