Fix flickering selection

This commit is contained in:
Mark Tolmacs 2025-03-15 14:02:39 +01:00
parent 02aeb5ab63
commit cf75f6bfe0
2 changed files with 2 additions and 2 deletions

View file

@ -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);