feat: Enhance Cursor model selection and profile handling

- Updated AddFeatureDialog to support both Cursor and Claude profiles, allowing for dynamic model and thinking level selection based on the chosen profile.
- Modified ModelSelector to filter available Cursor models based on global settings and display a warning if the Cursor CLI is not available.
- Enhanced ProfileQuickSelect to handle both profile types and improve selection logic for Cursor profiles.
- Refactored CursorSettingsTab to manage global settings for enabled Cursor models and default model selection, streamlining the configuration process.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
This commit is contained in:
Kacper
2025-12-29 22:17:07 +01:00
parent fa23a7b8e2
commit 8e10f522c0
6 changed files with 184 additions and 154 deletions

View File

@@ -8,7 +8,7 @@
import type { AgentModel } from './model.js';
import type { CursorModelId } from './cursor-models.js';
import { CURSOR_MODEL_MAP } from './cursor-models.js';
import { CURSOR_MODEL_MAP, getAllCursorModelIds } from './cursor-models.js';
// Re-export AgentModel for convenience
export type { AgentModel };
@@ -304,6 +304,12 @@ export interface GlobalSettings {
/** Which model to use for GitHub issue validation */
validationModel: AgentModel;
// Cursor CLI Settings (global)
/** Which Cursor models are available in feature modal (empty = all) */
enabledCursorModels: CursorModelId[];
/** Default Cursor model selection when switching to Cursor CLI */
cursorDefaultModel: CursorModelId;
// Input Configuration
/** User's keyboard shortcut bindings */
keyboardShortcuts: KeyboardShortcuts;
@@ -488,6 +494,8 @@ export const DEFAULT_GLOBAL_SETTINGS: GlobalSettings = {
muteDoneSound: false,
enhancementModel: 'sonnet',
validationModel: 'opus',
enabledCursorModels: getAllCursorModelIds(),
cursorDefaultModel: 'auto',
keyboardShortcuts: DEFAULT_KEYBOARD_SHORTCUTS,
aiProfiles: [],
projects: [],