Gallery folders have no drag-reorder affordance — folders appear in fixed insertion order, user with 8 folders in a non-ideal order has to delete and recreate them to reorder #235
Labels
No labels
blocked:commit-ready-failed
blocked:gate-fetch
blocked:gate-lint
blocked:gate-plan
blocked:gate-research
blocked:needs-attention
blocked:needs-decision
blocked:needs-human
blocked:no-changes
blocked:verify-failed
bug
deferred
feature-request
in-progress
needs-decompose
needs-triage
quickfix
security/medium
triage-approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Mark/Kimi_Agent_Brother_10_Digitizing_App#235
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Finding
src/components/gallery/FolderNav.tsxrenders folders as buttons in aflex items-center gap-2 overflow-x-autorow. The order isfolders.map((folder, i) => ...)— the array order. There's no drag handle, no reorder UI.grep -n 'onFolderDragOver' src/components/gallery/FolderNav.tsx— the prop exists (line 14), and the folder button hasonDragOverandonDropfor receiving designs (not for reordering the folders themselves). The "drag over" is for designs being moved INTO the folder, not for folders being dragged.A user with 8 folders in creation order:
grep -n 'sortFolders\|reorderFolder' src/returns 0 hits.Where
src/components/gallery/FolderNav.tsx(no folder drag handle)onFolderDragOver,onFolderDragLeave,onFolderDrop(all one.dataTransferof incoming designs, not folder reorder)grep -n 'reorderFolder' src/returns 0Suggested fix shape
Add a drag handle (GripVertical icon, matching the per-row drag handle in the workspace's ObjectList per #182) to each folder button:
The drag handle has the
draggableHTML attribute and adragstarthandler:A drop zone (the folder button itself, or a "between" gap) accepts the drag and reorders the folders array:
onReorderFoldersdispatches aREORDER_FOLDERSaction that updates the folders array and persists to localStorage.Severity
Low. The user can work around with delete + recreate. Power users with many folders notice.
Discovered by
Gap analysis (2026-10-02) of gallery folder management.
Related
Shipped in commit
25b08cconmain.What changed:
src/components/gallery/FolderNav.tsx: each custom (user-owned) folder button now renders aGripVerticaldrag handle on the left. Dropping the handle onto another folder button or onto the leading drop slot reorders the folder in the custom-folder slice. Default folders (All Designs/Unsorted/Favorites) stay pinned at positions 0–2 and do not expose a handle.src/pages/Gallery.tsx: newhandleReorderFolders(draggedId, targetIndex)splits the folders array into defaults + customs, splices the dragged id out of the custom slice, and re-inserts it at the target index. Persistence is automatic via the existinguseEffect([folders]) -> saveFolderschain.Pipeline isolation: folder-reorder uses a custom MIME payload (
application/x-folder-id) distinct from the existingtext/plaindesign-into-folder payload — dropping a design onto a folder still moves the design, and dropping a folder onto another folder reorders the folders.Tests: 7 new in
src/components/gallery/issue-235-folder-reorder.test.tsx. Full suite 1199/1199 (1 pre-existing skip). TypeScript clean, ESLint clean.