mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Fix flickering selection
This commit is contained in:
parent
02aeb5ab63
commit
cf75f6bfe0
2 changed files with 2 additions and 2 deletions
|
@ -2088,7 +2088,7 @@ class App extends React.Component<AppProps, AppState> {
|
|||
swapPreviewOnAlt: true,
|
||||
colorPickerType:
|
||||
type === "stroke" ? "elementStroke" : "elementBackground",
|
||||
onSelect: (color, event) => {
|
||||
onSelect: (color: string, event: KeyboardEvent) => {
|
||||
const shouldUpdateStrokeColor =
|
||||
(type === "background" && event.altKey) ||
|
||||
(type === "stroke" && !event.altKey);
|
||||
|
|
|
@ -1089,7 +1089,7 @@ const _renderInteractiveScene = ({
|
|||
const dashedLinePadding =
|
||||
(DEFAULT_TRANSFORM_HANDLE_SPACING * 2) / appState.zoom.value;
|
||||
context.fillStyle = oc.white;
|
||||
const [x1, y1, x2, y2] = getCommonBounds(selectedElements);
|
||||
const [x1, y1, x2, y2] = getCommonBounds(selectedElements, elementsMap);
|
||||
const initialLineDash = context.getLineDash();
|
||||
context.setLineDash([2 / appState.zoom.value]);
|
||||
const lineWidth = context.lineWidth;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue