Commit 1725a5e
committed
🤖 Fix Ctrl+J/K workspace navigation to use sorted order
Navigation now follows visual order displayed in sidebar.
**Problem:**
- PR #205 added recency-based sorting to workspace display
- Ctrl+J/K navigation still used unsorted config order
- Caused confusion: pressing next didn't select next visible workspace
**Solution:**
- Move sorting logic from ProjectSidebar to App.tsx
- Share sorted list between navigation and display
- Both now use same recency-sorted order
**Changes:**
- Added sortedWorkspacesByProject memo in App.tsx
- Updated handleNavigateWorkspace to use sorted list
- Pass sorted list through LeftSidebar to ProjectSidebar
- Remove duplicate sorting logic from ProjectSidebar1 parent 539d428 commit 1725a5e
3 files changed
+36
-31
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
287 | 287 | | |
288 | 288 | | |
289 | 289 | | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
290 | 312 | | |
291 | 313 | | |
292 | 314 | | |
293 | 315 | | |
294 | | - | |
295 | | - | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
296 | 319 | | |
297 | | - | |
298 | | - | |
| 320 | + | |
| 321 | + | |
299 | 322 | | |
300 | 323 | | |
301 | 324 | | |
302 | 325 | | |
303 | 326 | | |
304 | 327 | | |
305 | 328 | | |
306 | | - | |
| 329 | + | |
307 | 330 | | |
308 | | - | |
| 331 | + | |
309 | 332 | | |
310 | 333 | | |
311 | | - | |
| 334 | + | |
312 | 335 | | |
313 | 336 | | |
314 | 337 | | |
| |||
321 | 344 | | |
322 | 345 | | |
323 | 346 | | |
324 | | - | |
| 347 | + | |
325 | 348 | | |
326 | 349 | | |
327 | 350 | | |
| |||
555 | 578 | | |
556 | 579 | | |
557 | 580 | | |
| 581 | + | |
558 | 582 | | |
559 | 583 | | |
560 | 584 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| 47 | + | |
47 | 48 | | |
48 | 49 | | |
49 | 50 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
586 | 586 | | |
587 | 587 | | |
588 | 588 | | |
| 589 | + | |
589 | 590 | | |
590 | 591 | | |
591 | 592 | | |
| |||
606 | 607 | | |
607 | 608 | | |
608 | 609 | | |
| 610 | + | |
609 | 611 | | |
610 | 612 | | |
611 | 613 | | |
612 | 614 | | |
613 | | - | |
614 | | - | |
615 | | - | |
616 | | - | |
617 | | - | |
618 | | - | |
619 | | - | |
620 | | - | |
621 | | - | |
622 | | - | |
623 | | - | |
624 | | - | |
625 | | - | |
626 | | - | |
627 | | - | |
628 | | - | |
629 | | - | |
630 | | - | |
631 | | - | |
632 | | - | |
633 | | - | |
634 | | - | |
635 | 615 | | |
636 | 616 | | |
637 | 617 | | |
| |||
0 commit comments