From b73216ef8178b86f651f0937b7f156230245bab6 Mon Sep 17 00:00:00 2001 From: blessedcoolant <54517381+blessedcoolant@users.noreply.github.com> Date: Sat, 2 Sep 2023 10:23:14 +1200 Subject: [PATCH] feat: Decrement Brush Size by 1 for values under 5 for more precision --- .../IAICanvasToolbar/IAICanvasToolChooserOptions.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/invokeai/frontend/web/src/features/canvas/components/IAICanvasToolbar/IAICanvasToolChooserOptions.tsx b/invokeai/frontend/web/src/features/canvas/components/IAICanvasToolbar/IAICanvasToolChooserOptions.tsx index a3e8f6af8b..10e01ccac4 100644 --- a/invokeai/frontend/web/src/features/canvas/components/IAICanvasToolbar/IAICanvasToolChooserOptions.tsx +++ b/invokeai/frontend/web/src/features/canvas/components/IAICanvasToolbar/IAICanvasToolChooserOptions.tsx @@ -118,7 +118,11 @@ const IAICanvasToolChooserOptions = () => { useHotkeys( ['BracketLeft'], () => { - dispatch(setBrushSize(Math.max(brushSize - 5, 5))); + if (brushSize - 5 <= 5) { + dispatch(setBrushSize(Math.max(brushSize - 1, 1))); + } else { + dispatch(setBrushSize(Math.max(brushSize - 5, 1))); + } }, { enabled: () => !isStaging,