From 13e0647b472ab359f3d08a158c7543baec25fd84 Mon Sep 17 00:00:00 2001 From: Richard R Date: Wed, 27 May 2026 21:10:01 -0600 Subject: [PATCH] refactor(doclist): convert icon size controls to dropdown for icons view toggle Replace inline icon size buttons with a dropdown menu that appears when the icons view toggle is active. This change improves toolbar clarity by grouping related controls and enhances accessibility with better focus handling. The update also streamlines the button structure for view mode selection. --- .../doclist/window/FinderToolbar.tsx | 86 ++++++++++--------- 1 file changed, 47 insertions(+), 39 deletions(-) diff --git a/src/components/doclist/window/FinderToolbar.tsx b/src/components/doclist/window/FinderToolbar.tsx index e98284c..053402e 100644 --- a/src/components/doclist/window/FinderToolbar.tsx +++ b/src/components/doclist/window/FinderToolbar.tsx @@ -118,52 +118,60 @@ export function FinderToolbar({ {VIEW_BUTTONS.map(({ value, label, Icon }) => { const disabled = value === 'columns' && isNarrow; const active = viewMode === value; + const isIconsToggle = value === 'icons'; return ( - + + {isIconsToggle && viewMode === 'icons' && ( +
+
+ {ICON_SIZES.map(({ value: sizeValue, label: sizeLabel }) => { + const sizeActive = iconSize === sizeValue; + return ( + + ); + })} +
+
+ )} + ); })} - {viewMode === 'icons' && ( - - )} -