Root cause: loadManuallyCreatedProjects() was restoring projects with
stale session arrays from localStorage. When loadProjects() tried to
merge with fresh API data, the stale sessions would override.
Fix 1: In loadManuallyCreatedProjects(), reset the sessions array to
empty for each loaded project. This ensures sessions always come from
the API (authoritative source) rather than localStorage.
Fix 2: In createSessionInFolder(), remove the redundant initialize()
call after loadProjects(). initialize() would reload stale localStorage
data, undoing the fresh data fetched by loadProjects().
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Added logging to loadProjects() to trace session assignment
- Added logging to show manually created projects and their workingDirs
- Added logging to virtual session matching logic
- This will help identify where sessions are being incorrectly assigned
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Modified loadChatHistory() to check for active project before fetching all sessions
- When active project exists, use project.sessions instead of fetching from API
- Added detailed console logging to debug session filtering
- This prevents ALL sessions from appearing in every project's sidebar
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Implement localStorage persistence for closed session and project tabs.
When users close tabs, they now remain closed after page refresh.
Changes:
- session-tabs.js: Add closedSessions tracking with localStorage
- project-manager.js: Add closedProjects tracking with localStorage
- Filter out closed tabs on load
- Persist state whenever tabs are closed
Fixes issue where closed tabs would reappear on page refresh.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Fix missing 'x' close buttons on project tabs (Level 1). Session tabs
( Level 2) already had close buttons implemented.
Changes:
- project-manager.js: Added close button element to renderProjectTab()
- Added closeProject() method with confirmation dialog
- Added getSessionName() helper for session name display
- Auto-switches to next project when active project is closed
- project-tabs.css: Added .tab-close styling for project tabs
- Close button shows on hover, red highlight on hover
- Mobile responsive: always visible on small screens
The close button removes project tab from view but sessions remain
accessible via API/reload. Confirmation shows session count and list
for non-empty projects.
Resolves: https://rommark.dev/claude/ide/session/session-1769083280612-mdof554ot
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Phase 2 of enhancement plan:
- Created project-manager.js for project-level organization
- Created session-tabs.js for session-level organization
- Created project-tabs.css with responsive design
- Added tab structure to index.html
- Cache bust: v1769083200000
Features:
- Project tabs organize sessions by working directory
- Session tabs show all sessions within active project
- Context menu for rename/duplicate/delete/close
- Visual indicators for active/running sessions
- Responsive design for mobile
Co-Authored-By: Claude <noreply@anthropic.com>