feat: Enhance session management and tool settings for Claude and Cursor

- Updated ClaudeStatus component to accept a provider prop for better flexibility.
- Added CursorLogo component for displaying cursor sessions.
- Modified MainContent to conditionally display session names based on provider.
- Updated Shell component to show session names and summaries based on provider.
- Enhanced Sidebar to handle both Claude and Cursor sessions, including sorting and displaying session icons.
- Introduced new ToolsSettings functionality to manage tools for both Claude and Cursor, including allowed and disallowed commands.
- Implemented fetching and saving of Cursor-specific settings and commands.
- Added UI elements for managing Cursor tools, including permission settings and command lists.
This commit is contained in:
simos
2025-08-12 10:49:04 +03:00
parent ece52adac2
commit cf6f0e7321
15 changed files with 3146 additions and 94 deletions

View File

@@ -530,11 +530,16 @@ function Shell({ selectedProject, selectedSession, isActive }) {
<div className="flex items-center justify-between">
<div className="flex items-center space-x-2">
<div className={`w-2 h-2 rounded-full ${isConnected ? 'bg-green-500' : 'bg-red-500'}`} />
{selectedSession && (
<span className="text-xs text-blue-300">
({selectedSession.summary.slice(0, 30)}...)
</span>
)}
{selectedSession && (() => {
const displaySessionName = selectedSession.__provider === 'cursor'
? (selectedSession.name || 'Untitled Session')
: (selectedSession.summary || 'New Session');
return (
<span className="text-xs text-blue-300">
({displaySessionName.slice(0, 30)}...)
</span>
);
})()}
{!selectedSession && (
<span className="text-xs text-gray-400">(New Session)</span>
)}
@@ -601,7 +606,12 @@ function Shell({ selectedProject, selectedSession, isActive }) {
</button>
<p className="text-gray-400 text-sm mt-3 px-2">
{selectedSession ?
`Resume session: ${selectedSession.summary.slice(0, 50)}...` :
(() => {
const displaySessionName = selectedSession.__provider === 'cursor'
? (selectedSession.name || 'Untitled Session')
: (selectedSession.summary || 'New Session');
return `Resume session: ${displaySessionName.slice(0, 50)}...`;
})() :
'Start a new Claude session'
}
</p>