Remove redundant checks for deleted paths and streamline binary file handling. This fixes the browser using excessive memory and freezing.
Improve DiffView to use a singleton instance of Shiki
* Add persistent file locking feature with enhanced UI
* Fix file locking to be scoped by chat ID
* Add folder locking functionality
* Update CHANGES.md to include folder locking functionality
* Add early detection of locked files/folders in user prompts
* Improve locked files detection with smarter pattern matching and prevent AI from attempting to modify locked files
* Add detection for unlocked files to allow AI to continue with modifications in the same chat session
* Implement dialog-based Lock Manager with improved styling for dark/light modes
* Add remaining files for file locking implementation
* refactor(lock-manager): simplify lock management UI and remove scoped lock options
Consolidate lock management UI by removing scoped lock options and integrating LockManager directly into the EditorPanel. Simplify the lock management interface by removing the dialog and replacing it with a tab-based view. This improves maintainability and user experience by reducing complexity and streamlining the lock management process.
Change Lock & Unlock action to use toast instead of alert.
Remove LockManagerDialog as it is now tab based.
* Optimize file locking mechanism for better performance
- Add in-memory caching to reduce localStorage reads
- Implement debounced localStorage writes
- Use Map data structures for faster lookups
- Add batch operations for locking/unlocking multiple items
- Reduce polling frequency and add event-based updates
- Add performance monitoring and cross-tab synchronization
* refactor(file-locking): simplify file locking mechanism and remove scoped locks
This commit removes the scoped locking feature and simplifies the file locking mechanism. The `LockMode` type and related logic have been removed, and all locks are now treated as full locks. The `isLocked` property has been standardized across the codebase, replacing the previous `locked` and `lockMode` properties. Additionally, the `useLockedFilesChecker` hook and `LockAlert` component have been removed as they are no longer needed with the simplified locking system.
This gives the LLM a clear understanding of locked files and strict instructions not to make any changes to these files
* refactor: remove debug console.log statements
---------
Co-authored-by: KevIsDev <zennerd404@gmail.com>
Refactor the file deletion logic in FilesStore to precompute prefixes and iterate through files only once. This reduces the complexity of nested loops and improves performance by applying all deletions in a single update to the store. Additionally, remove a redundant console.log statement in Chat.client.tsx and update the prompts documentation for clarity.
* Fix FilesStore: Handle empty content correctly in saveFile(). Happens when user creates files in the web terminal
* updated logic
---------
Co-authored-by: Anirban Kar <thecodacus@gmail.com>