fss-link 1.0.27 → 1.0.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +25 -8
- package/bundle/fss-link.js +27930 -0
- package/package.json +100 -47
- package/dist/.last_build +0 -0
- package/dist/index.d.ts +0 -7
- package/dist/index.js +0 -20
- package/dist/index.js.map +0 -1
- package/dist/package.json +0 -90
- package/dist/src/commands/mcp/add.d.ts +0 -7
- package/dist/src/commands/mcp/add.js +0 -166
- package/dist/src/commands/mcp/add.js.map +0 -1
- package/dist/src/commands/mcp/list.d.ts +0 -8
- package/dist/src/commands/mcp/list.js +0 -110
- package/dist/src/commands/mcp/list.js.map +0 -1
- package/dist/src/commands/mcp/remove.d.ts +0 -7
- package/dist/src/commands/mcp/remove.js +0 -44
- package/dist/src/commands/mcp/remove.js.map +0 -1
- package/dist/src/commands/mcp.d.ts +0 -7
- package/dist/src/commands/mcp.js +0 -23
- package/dist/src/commands/mcp.js.map +0 -1
- package/dist/src/config/auth.d.ts +0 -13
- package/dist/src/config/auth.js +0 -78
- package/dist/src/config/auth.js.map +0 -1
- package/dist/src/config/auth.test.d.ts +0 -6
- package/dist/src/config/auth.test.js +0 -61
- package/dist/src/config/auth.test.js.map +0 -1
- package/dist/src/config/config.d.ts +0 -45
- package/dist/src/config/config.js +0 -490
- package/dist/src/config/config.js.map +0 -1
- package/dist/src/config/database.d.ts +0 -101
- package/dist/src/config/database.js +0 -345
- package/dist/src/config/database.js.map +0 -1
- package/dist/src/config/extension.d.ts +0 -23
- package/dist/src/config/extension.js +0 -126
- package/dist/src/config/extension.js.map +0 -1
- package/dist/src/config/keyBindings.d.ts +0 -66
- package/dist/src/config/keyBindings.js +0 -141
- package/dist/src/config/keyBindings.js.map +0 -1
- package/dist/src/config/keyBindings.test.d.ts +0 -6
- package/dist/src/config/keyBindings.test.js +0 -51
- package/dist/src/config/keyBindings.test.js.map +0 -1
- package/dist/src/config/modelManager.d.ts +0 -84
- package/dist/src/config/modelManager.js +0 -234
- package/dist/src/config/modelManager.js.map +0 -1
- package/dist/src/config/sandboxConfig.d.ts +0 -13
- package/dist/src/config/sandboxConfig.js +0 -75
- package/dist/src/config/sandboxConfig.js.map +0 -1
- package/dist/src/config/settings.d.ts +0 -56
- package/dist/src/config/settings.js +0 -407
- package/dist/src/config/settings.js.map +0 -1
- package/dist/src/config/settingsSchema.d.ts +0 -694
- package/dist/src/config/settingsSchema.js +0 -670
- package/dist/src/config/settingsSchema.js.map +0 -1
- package/dist/src/config/settingsSchema.test.d.ts +0 -6
- package/dist/src/config/settingsSchema.test.js +0 -195
- package/dist/src/config/settingsSchema.test.js.map +0 -1
- package/dist/src/config/trustedFolders.d.ts +0 -37
- package/dist/src/config/trustedFolders.js +0 -118
- package/dist/src/config/trustedFolders.js.map +0 -1
- package/dist/src/config/trustedFolders.test.d.ts +0 -6
- package/dist/src/config/trustedFolders.test.js +0 -160
- package/dist/src/config/trustedFolders.test.js.map +0 -1
- package/dist/src/gemini.d.ts +0 -9
- package/dist/src/gemini.js +0 -263
- package/dist/src/gemini.js.map +0 -1
- package/dist/src/gemini.test.d.ts +0 -6
- package/dist/src/gemini.test.js +0 -193
- package/dist/src/gemini.test.js.map +0 -1
- package/dist/src/generated/git-commit.d.ts +0 -7
- package/dist/src/generated/git-commit.js +0 -10
- package/dist/src/generated/git-commit.js.map +0 -1
- package/dist/src/nonInteractiveCli.d.ts +0 -7
- package/dist/src/nonInteractiveCli.js +0 -103
- package/dist/src/nonInteractiveCli.js.map +0 -1
- package/dist/src/patches/is-in-ci.d.ts +0 -7
- package/dist/src/patches/is-in-ci.js +0 -15
- package/dist/src/patches/is-in-ci.js.map +0 -1
- package/dist/src/services/BuiltinCommandLoader.d.ts +0 -24
- package/dist/src/services/BuiltinCommandLoader.js +0 -90
- package/dist/src/services/BuiltinCommandLoader.js.map +0 -1
- package/dist/src/services/BuiltinCommandLoader.test.d.ts +0 -6
- package/dist/src/services/BuiltinCommandLoader.test.js +0 -108
- package/dist/src/services/BuiltinCommandLoader.test.js.map +0 -1
- package/dist/src/services/CommandService.d.ts +0 -55
- package/dist/src/services/CommandService.js +0 -90
- package/dist/src/services/CommandService.js.map +0 -1
- package/dist/src/services/CommandService.test.d.ts +0 -6
- package/dist/src/services/CommandService.test.js +0 -232
- package/dist/src/services/CommandService.test.js.map +0 -1
- package/dist/src/services/FileCommandLoader.d.ts +0 -49
- package/dist/src/services/FileCommandLoader.js +0 -210
- package/dist/src/services/FileCommandLoader.js.map +0 -1
- package/dist/src/services/McpPromptLoader.d.ts +0 -25
- package/dist/src/services/McpPromptLoader.js +0 -192
- package/dist/src/services/McpPromptLoader.js.map +0 -1
- package/dist/src/services/SearchEngineConfigProvider.d.ts +0 -33
- package/dist/src/services/SearchEngineConfigProvider.js +0 -82
- package/dist/src/services/SearchEngineConfigProvider.js.map +0 -1
- package/dist/src/services/prompt-processors/argumentProcessor.d.ts +0 -16
- package/dist/src/services/prompt-processors/argumentProcessor.js +0 -20
- package/dist/src/services/prompt-processors/argumentProcessor.js.map +0 -1
- package/dist/src/services/prompt-processors/shellProcessor.d.ts +0 -35
- package/dist/src/services/prompt-processors/shellProcessor.js +0 -162
- package/dist/src/services/prompt-processors/shellProcessor.js.map +0 -1
- package/dist/src/services/prompt-processors/types.d.ts +0 -40
- package/dist/src/services/prompt-processors/types.js +0 -16
- package/dist/src/services/prompt-processors/types.js.map +0 -1
- package/dist/src/services/types.d.ts +0 -22
- package/dist/src/services/types.js +0 -7
- package/dist/src/services/types.js.map +0 -1
- package/dist/src/test-utils/customMatchers.d.ts +0 -14
- package/dist/src/test-utils/customMatchers.js +0 -46
- package/dist/src/test-utils/customMatchers.js.map +0 -1
- package/dist/src/test-utils/mockCommandContext.d.ts +0 -18
- package/dist/src/test-utils/mockCommandContext.js +0 -87
- package/dist/src/test-utils/mockCommandContext.js.map +0 -1
- package/dist/src/test-utils/mockCommandContext.test.d.ts +0 -6
- package/dist/src/test-utils/mockCommandContext.test.js +0 -51
- package/dist/src/test-utils/mockCommandContext.test.js.map +0 -1
- package/dist/src/test-utils/render.d.ts +0 -8
- package/dist/src/test-utils/render.js +0 -10
- package/dist/src/test-utils/render.js.map +0 -1
- package/dist/src/ui/App.d.ts +0 -15
- package/dist/src/ui/App.js +0 -703
- package/dist/src/ui/App.js.map +0 -1
- package/dist/src/ui/IdeIntegrationNudge.d.ts +0 -16
- package/dist/src/ui/IdeIntegrationNudge.js +0 -52
- package/dist/src/ui/IdeIntegrationNudge.js.map +0 -1
- package/dist/src/ui/colors.d.ts +0 -7
- package/dist/src/ui/colors.js +0 -54
- package/dist/src/ui/colors.js.map +0 -1
- package/dist/src/ui/commands/aboutCommand.d.ts +0 -7
- package/dist/src/ui/commands/aboutCommand.js +0 -43
- package/dist/src/ui/commands/aboutCommand.js.map +0 -1
- package/dist/src/ui/commands/authCommand.d.ts +0 -7
- package/dist/src/ui/commands/authCommand.js +0 -16
- package/dist/src/ui/commands/authCommand.js.map +0 -1
- package/dist/src/ui/commands/bugCommand.d.ts +0 -7
- package/dist/src/ui/commands/bugCommand.js +0 -71
- package/dist/src/ui/commands/bugCommand.js.map +0 -1
- package/dist/src/ui/commands/chatCommand.d.ts +0 -7
- package/dist/src/ui/commands/chatCommand.js +0 -234
- package/dist/src/ui/commands/chatCommand.js.map +0 -1
- package/dist/src/ui/commands/clearCommand.d.ts +0 -7
- package/dist/src/ui/commands/clearCommand.js +0 -27
- package/dist/src/ui/commands/clearCommand.js.map +0 -1
- package/dist/src/ui/commands/compressCommand.d.ts +0 -7
- package/dist/src/ui/commands/compressCommand.js +0 -64
- package/dist/src/ui/commands/compressCommand.js.map +0 -1
- package/dist/src/ui/commands/copyCommand.d.ts +0 -7
- package/dist/src/ui/commands/copyCommand.js +0 -59
- package/dist/src/ui/commands/copyCommand.js.map +0 -1
- package/dist/src/ui/commands/corgiCommand.d.ts +0 -7
- package/dist/src/ui/commands/corgiCommand.js +0 -15
- package/dist/src/ui/commands/corgiCommand.js.map +0 -1
- package/dist/src/ui/commands/directoryCommand.d.ts +0 -8
- package/dist/src/ui/commands/directoryCommand.js +0 -133
- package/dist/src/ui/commands/directoryCommand.js.map +0 -1
- package/dist/src/ui/commands/docsCommand.d.ts +0 -7
- package/dist/src/ui/commands/docsCommand.js +0 -31
- package/dist/src/ui/commands/docsCommand.js.map +0 -1
- package/dist/src/ui/commands/editorCommand.d.ts +0 -7
- package/dist/src/ui/commands/editorCommand.js +0 -16
- package/dist/src/ui/commands/editorCommand.js.map +0 -1
- package/dist/src/ui/commands/extensionsCommand.d.ts +0 -7
- package/dist/src/ui/commands/extensionsCommand.js +0 -31
- package/dist/src/ui/commands/extensionsCommand.js.map +0 -1
- package/dist/src/ui/commands/helpCommand.d.ts +0 -7
- package/dist/src/ui/commands/helpCommand.js +0 -21
- package/dist/src/ui/commands/helpCommand.js.map +0 -1
- package/dist/src/ui/commands/ideCommand.d.ts +0 -8
- package/dist/src/ui/commands/ideCommand.js +0 -218
- package/dist/src/ui/commands/ideCommand.js.map +0 -1
- package/dist/src/ui/commands/initCommand.d.ts +0 -7
- package/dist/src/ui/commands/initCommand.js +0 -105
- package/dist/src/ui/commands/initCommand.js.map +0 -1
- package/dist/src/ui/commands/mcpCommand.d.ts +0 -7
- package/dist/src/ui/commands/mcpCommand.js +0 -424
- package/dist/src/ui/commands/mcpCommand.js.map +0 -1
- package/dist/src/ui/commands/memoryCommand.d.ts +0 -7
- package/dist/src/ui/commands/memoryCommand.js +0 -224
- package/dist/src/ui/commands/memoryCommand.js.map +0 -1
- package/dist/src/ui/commands/privacyCommand.d.ts +0 -7
- package/dist/src/ui/commands/privacyCommand.js +0 -16
- package/dist/src/ui/commands/privacyCommand.js.map +0 -1
- package/dist/src/ui/commands/quitCommand.d.ts +0 -7
- package/dist/src/ui/commands/quitCommand.js +0 -34
- package/dist/src/ui/commands/quitCommand.js.map +0 -1
- package/dist/src/ui/commands/restoreCommand.d.ts +0 -8
- package/dist/src/ui/commands/restoreCommand.js +0 -128
- package/dist/src/ui/commands/restoreCommand.js.map +0 -1
- package/dist/src/ui/commands/searchEngineSetupCommand.d.ts +0 -7
- package/dist/src/ui/commands/searchEngineSetupCommand.js +0 -17
- package/dist/src/ui/commands/searchEngineSetupCommand.js.map +0 -1
- package/dist/src/ui/commands/settingsCommand.d.ts +0 -7
- package/dist/src/ui/commands/settingsCommand.js +0 -16
- package/dist/src/ui/commands/settingsCommand.js.map +0 -1
- package/dist/src/ui/commands/setupGithubCommand.d.ts +0 -9
- package/dist/src/ui/commands/setupGithubCommand.js +0 -154
- package/dist/src/ui/commands/setupGithubCommand.js.map +0 -1
- package/dist/src/ui/commands/setupGithubCommand.test.d.ts +0 -6
- package/dist/src/ui/commands/setupGithubCommand.test.js +0 -167
- package/dist/src/ui/commands/setupGithubCommand.test.js.map +0 -1
- package/dist/src/ui/commands/speakCommand.d.ts +0 -7
- package/dist/src/ui/commands/speakCommand.js +0 -136
- package/dist/src/ui/commands/speakCommand.js.map +0 -1
- package/dist/src/ui/commands/statsCommand.d.ts +0 -7
- package/dist/src/ui/commands/statsCommand.js +0 -54
- package/dist/src/ui/commands/statsCommand.js.map +0 -1
- package/dist/src/ui/commands/terminalSetupCommand.d.ts +0 -13
- package/dist/src/ui/commands/terminalSetupCommand.js +0 -41
- package/dist/src/ui/commands/terminalSetupCommand.js.map +0 -1
- package/dist/src/ui/commands/themeCommand.d.ts +0 -7
- package/dist/src/ui/commands/themeCommand.js +0 -16
- package/dist/src/ui/commands/themeCommand.js.map +0 -1
- package/dist/src/ui/commands/toolsCommand.d.ts +0 -7
- package/dist/src/ui/commands/toolsCommand.js +0 -56
- package/dist/src/ui/commands/toolsCommand.js.map +0 -1
- package/dist/src/ui/commands/ttsCommand.d.ts +0 -7
- package/dist/src/ui/commands/ttsCommand.js +0 -122
- package/dist/src/ui/commands/ttsCommand.js.map +0 -1
- package/dist/src/ui/commands/types.d.ts +0 -157
- package/dist/src/ui/commands/types.js +0 -12
- package/dist/src/ui/commands/types.js.map +0 -1
- package/dist/src/ui/commands/vimCommand.d.ts +0 -7
- package/dist/src/ui/commands/vimCommand.js +0 -23
- package/dist/src/ui/commands/vimCommand.js.map +0 -1
- package/dist/src/ui/commands/voiceCommand.d.ts +0 -7
- package/dist/src/ui/commands/voiceCommand.js +0 -95
- package/dist/src/ui/commands/voiceCommand.js.map +0 -1
- package/dist/src/ui/components/AboutBox.d.ts +0 -17
- package/dist/src/ui/components/AboutBox.js +0 -6
- package/dist/src/ui/components/AboutBox.js.map +0 -1
- package/dist/src/ui/components/AsciiArt.d.ts +0 -8
- package/dist/src/ui/components/AsciiArt.js +0 -53
- package/dist/src/ui/components/AsciiArt.js.map +0 -1
- package/dist/src/ui/components/AuthDialog.d.ts +0 -15
- package/dist/src/ui/components/AuthDialog.js +0 -151
- package/dist/src/ui/components/AuthDialog.js.map +0 -1
- package/dist/src/ui/components/AuthDialog.test.d.ts +0 -6
- package/dist/src/ui/components/AuthDialog.test.js +0 -220
- package/dist/src/ui/components/AuthDialog.test.js.map +0 -1
- package/dist/src/ui/components/AuthInProgress.d.ts +0 -11
- package/dist/src/ui/components/AuthInProgress.js +0 -28
- package/dist/src/ui/components/AuthInProgress.js.map +0 -1
- package/dist/src/ui/components/AutoAcceptIndicator.d.ts +0 -12
- package/dist/src/ui/components/AutoAcceptIndicator.js +0 -26
- package/dist/src/ui/components/AutoAcceptIndicator.js.map +0 -1
- package/dist/src/ui/components/ConsoleSummaryDisplay.d.ts +0 -11
- package/dist/src/ui/components/ConsoleSummaryDisplay.js +0 -11
- package/dist/src/ui/components/ConsoleSummaryDisplay.js.map +0 -1
- package/dist/src/ui/components/ContextSummaryDisplay.d.ts +0 -20
- package/dist/src/ui/components/ContextSummaryDisplay.js +0 -65
- package/dist/src/ui/components/ContextSummaryDisplay.js.map +0 -1
- package/dist/src/ui/components/ContextUsageDisplay.d.ts +0 -9
- package/dist/src/ui/components/ContextUsageDisplay.js +0 -14
- package/dist/src/ui/components/ContextUsageDisplay.js.map +0 -1
- package/dist/src/ui/components/DebugProfiler.d.ts +0 -6
- package/dist/src/ui/components/DebugProfiler.js +0 -27
- package/dist/src/ui/components/DebugProfiler.js.map +0 -1
- package/dist/src/ui/components/DetailedMessagesDisplay.d.ts +0 -14
- package/dist/src/ui/components/DetailedMessagesDisplay.js +0 -34
- package/dist/src/ui/components/DetailedMessagesDisplay.js.map +0 -1
- package/dist/src/ui/components/EditorSettingsDialog.d.ts +0 -15
- package/dist/src/ui/components/EditorSettingsDialog.js +0 -74
- package/dist/src/ui/components/EditorSettingsDialog.js.map +0 -1
- package/dist/src/ui/components/FolderTrustDialog.d.ts +0 -16
- package/dist/src/ui/components/FolderTrustDialog.js +0 -39
- package/dist/src/ui/components/FolderTrustDialog.js.map +0 -1
- package/dist/src/ui/components/FolderTrustDialog.test.d.ts +0 -6
- package/dist/src/ui/components/FolderTrustDialog.test.js +0 -26
- package/dist/src/ui/components/FolderTrustDialog.test.js.map +0 -1
- package/dist/src/ui/components/Footer.d.ts +0 -23
- package/dist/src/ui/components/Footer.js +0 -25
- package/dist/src/ui/components/Footer.js.map +0 -1
- package/dist/src/ui/components/GeminiRespondingSpinner.d.ts +0 -17
- package/dist/src/ui/components/GeminiRespondingSpinner.js +0 -16
- package/dist/src/ui/components/GeminiRespondingSpinner.js.map +0 -1
- package/dist/src/ui/components/Header.d.ts +0 -13
- package/dist/src/ui/components/Header.js +0 -28
- package/dist/src/ui/components/Header.js.map +0 -1
- package/dist/src/ui/components/Header.test.d.ts +0 -6
- package/dist/src/ui/components/Header.test.js +0 -37
- package/dist/src/ui/components/Header.test.js.map +0 -1
- package/dist/src/ui/components/Help.d.ts +0 -12
- package/dist/src/ui/components/Help.js +0 -10
- package/dist/src/ui/components/Help.js.map +0 -1
- package/dist/src/ui/components/HistoryItemDisplay.d.ts +0 -20
- package/dist/src/ui/components/HistoryItemDisplay.js +0 -18
- package/dist/src/ui/components/HistoryItemDisplay.js.map +0 -1
- package/dist/src/ui/components/HistoryItemDisplay.test.d.ts +0 -6
- package/dist/src/ui/components/HistoryItemDisplay.test.js +0 -91
- package/dist/src/ui/components/HistoryItemDisplay.test.js.map +0 -1
- package/dist/src/ui/components/InputPrompt.d.ts +0 -28
- package/dist/src/ui/components/InputPrompt.js +0 -440
- package/dist/src/ui/components/InputPrompt.js.map +0 -1
- package/dist/src/ui/components/LMStudioModelPrompt.d.ts +0 -12
- package/dist/src/ui/components/LMStudioModelPrompt.js +0 -100
- package/dist/src/ui/components/LMStudioModelPrompt.js.map +0 -1
- package/dist/src/ui/components/LoadingIndicator.d.ts +0 -15
- package/dist/src/ui/components/LoadingIndicator.js +0 -25
- package/dist/src/ui/components/LoadingIndicator.js.map +0 -1
- package/dist/src/ui/components/LoadingIndicator.test.d.ts +0 -6
- package/dist/src/ui/components/LoadingIndicator.test.js +0 -190
- package/dist/src/ui/components/LoadingIndicator.test.js.map +0 -1
- package/dist/src/ui/components/MemoryUsageDisplay.d.ts +0 -7
- package/dist/src/ui/components/MemoryUsageDisplay.js +0 -27
- package/dist/src/ui/components/MemoryUsageDisplay.js.map +0 -1
- package/dist/src/ui/components/ModelStatsDisplay.d.ts +0 -7
- package/dist/src/ui/components/ModelStatsDisplay.js +0 -33
- package/dist/src/ui/components/ModelStatsDisplay.js.map +0 -1
- package/dist/src/ui/components/OllamaModelPrompt.d.ts +0 -12
- package/dist/src/ui/components/OllamaModelPrompt.js +0 -94
- package/dist/src/ui/components/OllamaModelPrompt.js.map +0 -1
- package/dist/src/ui/components/OpenAIKeyPrompt.d.ts +0 -12
- package/dist/src/ui/components/OpenAIKeyPrompt.js +0 -118
- package/dist/src/ui/components/OpenAIKeyPrompt.js.map +0 -1
- package/dist/src/ui/components/OpenAIKeyPrompt.test.d.ts +0 -6
- package/dist/src/ui/components/OpenAIKeyPrompt.test.js +0 -44
- package/dist/src/ui/components/OpenAIKeyPrompt.test.js.map +0 -1
- package/dist/src/ui/components/PrepareLabel.d.ts +0 -15
- package/dist/src/ui/components/PrepareLabel.js +0 -16
- package/dist/src/ui/components/PrepareLabel.js.map +0 -1
- package/dist/src/ui/components/QwenOAuthProgress.d.ts +0 -16
- package/dist/src/ui/components/QwenOAuthProgress.js +0 -108
- package/dist/src/ui/components/QwenOAuthProgress.js.map +0 -1
- package/dist/src/ui/components/QwenOAuthProgress.test.d.ts +0 -6
- package/dist/src/ui/components/QwenOAuthProgress.test.js +0 -290
- package/dist/src/ui/components/QwenOAuthProgress.test.js.map +0 -1
- package/dist/src/ui/components/SearchEngineConfigDialog.d.ts +0 -18
- package/dist/src/ui/components/SearchEngineConfigDialog.js +0 -148
- package/dist/src/ui/components/SearchEngineConfigDialog.js.map +0 -1
- package/dist/src/ui/components/SessionSummaryDisplay.d.ts +0 -11
- package/dist/src/ui/components/SessionSummaryDisplay.js +0 -4
- package/dist/src/ui/components/SessionSummaryDisplay.js.map +0 -1
- package/dist/src/ui/components/SettingsDialog.d.ts +0 -14
- package/dist/src/ui/components/SettingsDialog.js +0 -519
- package/dist/src/ui/components/SettingsDialog.js.map +0 -1
- package/dist/src/ui/components/SettingsDialog.test.d.ts +0 -6
- package/dist/src/ui/components/SettingsDialog.test.js +0 -568
- package/dist/src/ui/components/SettingsDialog.test.js.map +0 -1
- package/dist/src/ui/components/ShellConfirmationDialog.d.ts +0 -15
- package/dist/src/ui/components/ShellConfirmationDialog.js +0 -46
- package/dist/src/ui/components/ShellConfirmationDialog.js.map +0 -1
- package/dist/src/ui/components/ShellConfirmationDialog.test.d.ts +0 -6
- package/dist/src/ui/components/ShellConfirmationDialog.test.js +0 -40
- package/dist/src/ui/components/ShellConfirmationDialog.test.js.map +0 -1
- package/dist/src/ui/components/ShellModeIndicator.d.ts +0 -7
- package/dist/src/ui/components/ShellModeIndicator.js +0 -5
- package/dist/src/ui/components/ShellModeIndicator.js.map +0 -1
- package/dist/src/ui/components/ShowMoreLines.d.ts +0 -10
- package/dist/src/ui/components/ShowMoreLines.js +0 -24
- package/dist/src/ui/components/ShowMoreLines.js.map +0 -1
- package/dist/src/ui/components/StatsDisplay.d.ts +0 -12
- package/dist/src/ui/components/StatsDisplay.js +0 -43
- package/dist/src/ui/components/StatsDisplay.js.map +0 -1
- package/dist/src/ui/components/SuggestionsDisplay.d.ts +0 -22
- package/dist/src/ui/components/SuggestionsDisplay.js +0 -32
- package/dist/src/ui/components/SuggestionsDisplay.js.map +0 -1
- package/dist/src/ui/components/ThemeDialog.d.ts +0 -19
- package/dist/src/ui/components/ThemeDialog.js +0 -143
- package/dist/src/ui/components/ThemeDialog.js.map +0 -1
- package/dist/src/ui/components/Tips.d.ts +0 -12
- package/dist/src/ui/components/Tips.js +0 -8
- package/dist/src/ui/components/Tips.js.map +0 -1
- package/dist/src/ui/components/TodoDisplay.d.ts +0 -16
- package/dist/src/ui/components/TodoDisplay.js +0 -27
- package/dist/src/ui/components/TodoDisplay.js.map +0 -1
- package/dist/src/ui/components/TodoDisplay.test.d.ts +0 -6
- package/dist/src/ui/components/TodoDisplay.test.js +0 -77
- package/dist/src/ui/components/TodoDisplay.test.js.map +0 -1
- package/dist/src/ui/components/ToolStatsDisplay.d.ts +0 -7
- package/dist/src/ui/components/ToolStatsDisplay.js +0 -41
- package/dist/src/ui/components/ToolStatsDisplay.js.map +0 -1
- package/dist/src/ui/components/UpdateNotification.d.ts +0 -10
- package/dist/src/ui/components/UpdateNotification.js +0 -10
- package/dist/src/ui/components/UpdateNotification.js.map +0 -1
- package/dist/src/ui/components/messages/CompressionMessage.d.ts +0 -11
- package/dist/src/ui/components/messages/CompressionMessage.js +0 -16
- package/dist/src/ui/components/messages/CompressionMessage.js.map +0 -1
- package/dist/src/ui/components/messages/DiffRenderer.d.ts +0 -16
- package/dist/src/ui/components/messages/DiffRenderer.js +0 -222
- package/dist/src/ui/components/messages/DiffRenderer.js.map +0 -1
- package/dist/src/ui/components/messages/DiffRenderer.test.d.ts +0 -6
- package/dist/src/ui/components/messages/DiffRenderer.test.js +0 -239
- package/dist/src/ui/components/messages/DiffRenderer.test.js.map +0 -1
- package/dist/src/ui/components/messages/ErrorMessage.d.ts +0 -11
- package/dist/src/ui/components/messages/ErrorMessage.js +0 -9
- package/dist/src/ui/components/messages/ErrorMessage.js.map +0 -1
- package/dist/src/ui/components/messages/GeminiMessage.d.ts +0 -14
- package/dist/src/ui/components/messages/GeminiMessage.js +0 -10
- package/dist/src/ui/components/messages/GeminiMessage.js.map +0 -1
- package/dist/src/ui/components/messages/GeminiMessageContent.d.ts +0 -14
- package/dist/src/ui/components/messages/GeminiMessageContent.js +0 -15
- package/dist/src/ui/components/messages/GeminiMessageContent.js.map +0 -1
- package/dist/src/ui/components/messages/InfoMessage.d.ts +0 -11
- package/dist/src/ui/components/messages/InfoMessage.js +0 -10
- package/dist/src/ui/components/messages/InfoMessage.js.map +0 -1
- package/dist/src/ui/components/messages/ToolConfirmationMessage.d.ts +0 -15
- package/dist/src/ui/components/messages/ToolConfirmationMessage.js +0 -145
- package/dist/src/ui/components/messages/ToolConfirmationMessage.js.map +0 -1
- package/dist/src/ui/components/messages/ToolConfirmationMessage.test.d.ts +0 -6
- package/dist/src/ui/components/messages/ToolConfirmationMessage.test.js +0 -37
- package/dist/src/ui/components/messages/ToolConfirmationMessage.test.js.map +0 -1
- package/dist/src/ui/components/messages/ToolGroupMessage.d.ts +0 -18
- package/dist/src/ui/components/messages/ToolGroupMessage.js +0 -55
- package/dist/src/ui/components/messages/ToolGroupMessage.js.map +0 -1
- package/dist/src/ui/components/messages/ToolMessage.d.ts +0 -15
- package/dist/src/ui/components/messages/ToolMessage.js +0 -111
- package/dist/src/ui/components/messages/ToolMessage.js.map +0 -1
- package/dist/src/ui/components/messages/ToolMessage.test.d.ts +0 -6
- package/dist/src/ui/components/messages/ToolMessage.test.js +0 -118
- package/dist/src/ui/components/messages/ToolMessage.test.js.map +0 -1
- package/dist/src/ui/components/messages/UserMessage.d.ts +0 -11
- package/dist/src/ui/components/messages/UserMessage.js +0 -12
- package/dist/src/ui/components/messages/UserMessage.js.map +0 -1
- package/dist/src/ui/components/messages/UserShellMessage.d.ts +0 -11
- package/dist/src/ui/components/messages/UserShellMessage.js +0 -9
- package/dist/src/ui/components/messages/UserShellMessage.js.map +0 -1
- package/dist/src/ui/components/shared/MaxSizedBox.d.ts +0 -61
- package/dist/src/ui/components/shared/MaxSizedBox.js +0 -451
- package/dist/src/ui/components/shared/MaxSizedBox.js.map +0 -1
- package/dist/src/ui/components/shared/MaxSizedBox.test.d.ts +0 -6
- package/dist/src/ui/components/shared/MaxSizedBox.test.js +0 -154
- package/dist/src/ui/components/shared/MaxSizedBox.test.js.map +0 -1
- package/dist/src/ui/components/shared/RadioButtonSelect.d.ts +0 -46
- package/dist/src/ui/components/shared/RadioButtonSelect.js +0 -121
- package/dist/src/ui/components/shared/RadioButtonSelect.js.map +0 -1
- package/dist/src/ui/components/shared/RadioButtonSelect.test.d.ts +0 -6
- package/dist/src/ui/components/shared/RadioButtonSelect.test.js +0 -111
- package/dist/src/ui/components/shared/RadioButtonSelect.test.js.map +0 -1
- package/dist/src/ui/components/shared/text-buffer.d.ts +0 -467
- package/dist/src/ui/components/shared/text-buffer.js +0 -1533
- package/dist/src/ui/components/shared/text-buffer.js.map +0 -1
- package/dist/src/ui/components/shared/vim-buffer-actions.d.ts +0 -72
- package/dist/src/ui/components/shared/vim-buffer-actions.js +0 -552
- package/dist/src/ui/components/shared/vim-buffer-actions.js.map +0 -1
- package/dist/src/ui/constants.d.ts +0 -9
- package/dist/src/ui/constants.js +0 -13
- package/dist/src/ui/constants.js.map +0 -1
- package/dist/src/ui/contexts/KeypressContext.d.ts +0 -30
- package/dist/src/ui/contexts/KeypressContext.js +0 -331
- package/dist/src/ui/contexts/KeypressContext.js.map +0 -1
- package/dist/src/ui/contexts/KeypressContext.test.d.ts +0 -6
- package/dist/src/ui/contexts/KeypressContext.test.js +0 -275
- package/dist/src/ui/contexts/KeypressContext.test.js.map +0 -1
- package/dist/src/ui/contexts/OverflowContext.d.ts +0 -19
- package/dist/src/ui/contexts/OverflowContext.js +0 -43
- package/dist/src/ui/contexts/OverflowContext.js.map +0 -1
- package/dist/src/ui/contexts/SessionContext.d.ts +0 -39
- package/dist/src/ui/contexts/SessionContext.js +0 -60
- package/dist/src/ui/contexts/SessionContext.js.map +0 -1
- package/dist/src/ui/contexts/SettingsContext.d.ts +0 -9
- package/dist/src/ui/contexts/SettingsContext.js +0 -15
- package/dist/src/ui/contexts/SettingsContext.js.map +0 -1
- package/dist/src/ui/contexts/StreamingContext.d.ts +0 -9
- package/dist/src/ui/contexts/StreamingContext.js +0 -15
- package/dist/src/ui/contexts/StreamingContext.js.map +0 -1
- package/dist/src/ui/contexts/VimModeContext.d.ts +0 -19
- package/dist/src/ui/contexts/VimModeContext.js +0 -48
- package/dist/src/ui/contexts/VimModeContext.js.map +0 -1
- package/dist/src/ui/editors/editorSettingsManager.d.ts +0 -19
- package/dist/src/ui/editors/editorSettingsManager.js +0 -47
- package/dist/src/ui/editors/editorSettingsManager.js.map +0 -1
- package/dist/src/ui/hooks/atCommandProcessor.d.ts +0 -31
- package/dist/src/ui/hooks/atCommandProcessor.js +0 -365
- package/dist/src/ui/hooks/atCommandProcessor.js.map +0 -1
- package/dist/src/ui/hooks/atCommandProcessor.test.d.ts +0 -6
- package/dist/src/ui/hooks/atCommandProcessor.test.js +0 -824
- package/dist/src/ui/hooks/atCommandProcessor.test.js.map +0 -1
- package/dist/src/ui/hooks/shellCommandProcessor.d.ts +0 -17
- package/dist/src/ui/hooks/shellCommandProcessor.js +0 -233
- package/dist/src/ui/hooks/shellCommandProcessor.js.map +0 -1
- package/dist/src/ui/hooks/shellCommandProcessor.test.d.ts +0 -6
- package/dist/src/ui/hooks/shellCommandProcessor.test.js +0 -328
- package/dist/src/ui/hooks/shellCommandProcessor.test.js.map +0 -1
- package/dist/src/ui/hooks/slashCommandProcessor.d.ts +0 -28
- package/dist/src/ui/hooks/slashCommandProcessor.js +0 -459
- package/dist/src/ui/hooks/slashCommandProcessor.js.map +0 -1
- package/dist/src/ui/hooks/useAtCompletion.d.ts +0 -23
- package/dist/src/ui/hooks/useAtCompletion.js +0 -179
- package/dist/src/ui/hooks/useAtCompletion.js.map +0 -1
- package/dist/src/ui/hooks/useAuthCommand.d.ts +0 -14
- package/dist/src/ui/hooks/useAuthCommand.js +0 -100
- package/dist/src/ui/hooks/useAuthCommand.js.map +0 -1
- package/dist/src/ui/hooks/useAutoAcceptIndicator.d.ts +0 -10
- package/dist/src/ui/hooks/useAutoAcceptIndicator.js +0 -37
- package/dist/src/ui/hooks/useAutoAcceptIndicator.js.map +0 -1
- package/dist/src/ui/hooks/useAutoAcceptIndicator.test.d.ts +0 -6
- package/dist/src/ui/hooks/useAutoAcceptIndicator.test.js +0 -190
- package/dist/src/ui/hooks/useAutoAcceptIndicator.test.js.map +0 -1
- package/dist/src/ui/hooks/useBracketedPaste.d.ts +0 -12
- package/dist/src/ui/hooks/useBracketedPaste.js +0 -32
- package/dist/src/ui/hooks/useBracketedPaste.js.map +0 -1
- package/dist/src/ui/hooks/useCommandCompletion.d.ts +0 -29
- package/dist/src/ui/hooks/useCommandCompletion.js +0 -165
- package/dist/src/ui/hooks/useCommandCompletion.js.map +0 -1
- package/dist/src/ui/hooks/useCompletion.d.ts +0 -24
- package/dist/src/ui/hooks/useCompletion.js +0 -88
- package/dist/src/ui/hooks/useCompletion.js.map +0 -1
- package/dist/src/ui/hooks/useConsoleMessages.d.ts +0 -12
- package/dist/src/ui/hooks/useConsoleMessages.js +0 -76
- package/dist/src/ui/hooks/useConsoleMessages.js.map +0 -1
- package/dist/src/ui/hooks/useEditorSettings.d.ts +0 -16
- package/dist/src/ui/hooks/useEditorSettings.js +0 -43
- package/dist/src/ui/hooks/useEditorSettings.js.map +0 -1
- package/dist/src/ui/hooks/useEditorSettings.test.d.ts +0 -6
- package/dist/src/ui/hooks/useEditorSettings.test.js +0 -164
- package/dist/src/ui/hooks/useEditorSettings.test.js.map +0 -1
- package/dist/src/ui/hooks/useFocus.d.ts +0 -10
- package/dist/src/ui/hooks/useFocus.js +0 -41
- package/dist/src/ui/hooks/useFocus.js.map +0 -1
- package/dist/src/ui/hooks/useFolderTrust.d.ts +0 -12
- package/dist/src/ui/hooks/useFolderTrust.js +0 -55
- package/dist/src/ui/hooks/useFolderTrust.js.map +0 -1
- package/dist/src/ui/hooks/useGeminiStream.d.ts +0 -24
- package/dist/src/ui/hooks/useGeminiStream.js +0 -653
- package/dist/src/ui/hooks/useGeminiStream.js.map +0 -1
- package/dist/src/ui/hooks/useGitBranchName.d.ts +0 -6
- package/dist/src/ui/hooks/useGitBranchName.js +0 -61
- package/dist/src/ui/hooks/useGitBranchName.js.map +0 -1
- package/dist/src/ui/hooks/useGitBranchName.test.d.ts +0 -6
- package/dist/src/ui/hooks/useGitBranchName.test.js +0 -215
- package/dist/src/ui/hooks/useGitBranchName.test.js.map +0 -1
- package/dist/src/ui/hooks/useHistoryManager.d.ts +0 -22
- package/dist/src/ui/hooks/useHistoryManager.js +0 -72
- package/dist/src/ui/hooks/useHistoryManager.js.map +0 -1
- package/dist/src/ui/hooks/useHistoryManager.test.d.ts +0 -6
- package/dist/src/ui/hooks/useHistoryManager.test.js +0 -171
- package/dist/src/ui/hooks/useHistoryManager.test.js.map +0 -1
- package/dist/src/ui/hooks/useInputHistory.d.ts +0 -19
- package/dist/src/ui/hooks/useInputHistory.js +0 -84
- package/dist/src/ui/hooks/useInputHistory.js.map +0 -1
- package/dist/src/ui/hooks/useInputHistory.test.d.ts +0 -6
- package/dist/src/ui/hooks/useInputHistory.test.js +0 -207
- package/dist/src/ui/hooks/useInputHistory.test.js.map +0 -1
- package/dist/src/ui/hooks/useKeypress.d.ts +0 -17
- package/dist/src/ui/hooks/useKeypress.js +0 -27
- package/dist/src/ui/hooks/useKeypress.js.map +0 -1
- package/dist/src/ui/hooks/useKittyKeyboardProtocol.d.ts +0 -15
- package/dist/src/ui/hooks/useKittyKeyboardProtocol.js +0 -20
- package/dist/src/ui/hooks/useKittyKeyboardProtocol.js.map +0 -1
- package/dist/src/ui/hooks/useLoadingIndicator.d.ts +0 -10
- package/dist/src/ui/hooks/useLoadingIndicator.js +0 -44
- package/dist/src/ui/hooks/useLoadingIndicator.js.map +0 -1
- package/dist/src/ui/hooks/useLoadingIndicator.test.d.ts +0 -6
- package/dist/src/ui/hooks/useLoadingIndicator.test.js +0 -91
- package/dist/src/ui/hooks/useLoadingIndicator.test.js.map +0 -1
- package/dist/src/ui/hooks/useLogger.d.ts +0 -10
- package/dist/src/ui/hooks/useLogger.js +0 -29
- package/dist/src/ui/hooks/useLogger.js.map +0 -1
- package/dist/src/ui/hooks/useMessageQueue.d.ts +0 -22
- package/dist/src/ui/hooks/useMessageQueue.js +0 -49
- package/dist/src/ui/hooks/useMessageQueue.js.map +0 -1
- package/dist/src/ui/hooks/useMessageQueue.test.d.ts +0 -6
- package/dist/src/ui/hooks/useMessageQueue.test.js +0 -158
- package/dist/src/ui/hooks/useMessageQueue.test.js.map +0 -1
- package/dist/src/ui/hooks/usePhraseCycler.d.ts +0 -14
- package/dist/src/ui/hooks/usePhraseCycler.js +0 -187
- package/dist/src/ui/hooks/usePhraseCycler.js.map +0 -1
- package/dist/src/ui/hooks/usePrivacySettings.d.ts +0 -16
- package/dist/src/ui/hooks/usePrivacySettings.js +0 -119
- package/dist/src/ui/hooks/usePrivacySettings.js.map +0 -1
- package/dist/src/ui/hooks/usePrivacySettings.test.d.ts +0 -6
- package/dist/src/ui/hooks/usePrivacySettings.test.js +0 -154
- package/dist/src/ui/hooks/usePrivacySettings.test.js.map +0 -1
- package/dist/src/ui/hooks/useQwenAuth.d.ts +0 -20
- package/dist/src/ui/hooks/useQwenAuth.js +0 -78
- package/dist/src/ui/hooks/useQwenAuth.js.map +0 -1
- package/dist/src/ui/hooks/useQwenAuth.test.d.ts +0 -6
- package/dist/src/ui/hooks/useQwenAuth.test.js +0 -288
- package/dist/src/ui/hooks/useQwenAuth.test.js.map +0 -1
- package/dist/src/ui/hooks/useReactToolScheduler.d.ts +0 -33
- package/dist/src/ui/hooks/useReactToolScheduler.js +0 -187
- package/dist/src/ui/hooks/useReactToolScheduler.js.map +0 -1
- package/dist/src/ui/hooks/useRefreshMemoryCommand.d.ts +0 -6
- package/dist/src/ui/hooks/useRefreshMemoryCommand.js +0 -7
- package/dist/src/ui/hooks/useRefreshMemoryCommand.js.map +0 -1
- package/dist/src/ui/hooks/useReverseSearchCompletion.d.ts +0 -19
- package/dist/src/ui/hooks/useReverseSearchCompletion.js +0 -56
- package/dist/src/ui/hooks/useReverseSearchCompletion.js.map +0 -1
- package/dist/src/ui/hooks/useReverseSearchCompletion.test.d.ts +0 -6
- package/dist/src/ui/hooks/useReverseSearchCompletion.test.js +0 -163
- package/dist/src/ui/hooks/useReverseSearchCompletion.test.js.map +0 -1
- package/dist/src/ui/hooks/useSettingsCommand.d.ts +0 -10
- package/dist/src/ui/hooks/useSettingsCommand.js +0 -21
- package/dist/src/ui/hooks/useSettingsCommand.js.map +0 -1
- package/dist/src/ui/hooks/useShellHistory.d.ts +0 -13
- package/dist/src/ui/hooks/useShellHistory.js +0 -112
- package/dist/src/ui/hooks/useShellHistory.js.map +0 -1
- package/dist/src/ui/hooks/useShellHistory.test.d.ts +0 -6
- package/dist/src/ui/hooks/useShellHistory.test.js +0 -162
- package/dist/src/ui/hooks/useShellHistory.test.js.map +0 -1
- package/dist/src/ui/hooks/useShowMemoryCommand.d.ts +0 -9
- package/dist/src/ui/hooks/useShowMemoryCommand.js +0 -58
- package/dist/src/ui/hooks/useShowMemoryCommand.js.map +0 -1
- package/dist/src/ui/hooks/useSlashCompletion.d.ts +0 -20
- package/dist/src/ui/hooks/useSlashCompletion.js +0 -135
- package/dist/src/ui/hooks/useSlashCompletion.js.map +0 -1
- package/dist/src/ui/hooks/useSlashCompletion.test.d.ts +0 -6
- package/dist/src/ui/hooks/useSlashCompletion.test.js +0 -272
- package/dist/src/ui/hooks/useSlashCompletion.test.js.map +0 -1
- package/dist/src/ui/hooks/useStateAndRef.d.ts +0 -7
- package/dist/src/ui/hooks/useStateAndRef.js +0 -26
- package/dist/src/ui/hooks/useStateAndRef.js.map +0 -1
- package/dist/src/ui/hooks/useTerminalSize.d.ts +0 -9
- package/dist/src/ui/hooks/useTerminalSize.js +0 -27
- package/dist/src/ui/hooks/useTerminalSize.js.map +0 -1
- package/dist/src/ui/hooks/useThemeCommand.d.ts +0 -15
- package/dist/src/ui/hooks/useThemeCommand.js +0 -79
- package/dist/src/ui/hooks/useThemeCommand.js.map +0 -1
- package/dist/src/ui/hooks/useTimer.d.ts +0 -12
- package/dist/src/ui/hooks/useTimer.js +0 -58
- package/dist/src/ui/hooks/useTimer.js.map +0 -1
- package/dist/src/ui/hooks/useTimer.test.d.ts +0 -6
- package/dist/src/ui/hooks/useTimer.test.js +0 -90
- package/dist/src/ui/hooks/useTimer.test.js.map +0 -1
- package/dist/src/ui/hooks/useToolScheduler.test.d.ts +0 -6
- package/dist/src/ui/hooks/useToolScheduler.test.js +0 -845
- package/dist/src/ui/hooks/useToolScheduler.test.js.map +0 -1
- package/dist/src/ui/hooks/vim.d.ts +0 -28
- package/dist/src/ui/hooks/vim.js +0 -639
- package/dist/src/ui/hooks/vim.js.map +0 -1
- package/dist/src/ui/keyMatchers.d.ts +0 -26
- package/dist/src/ui/keyMatchers.js +0 -68
- package/dist/src/ui/keyMatchers.js.map +0 -1
- package/dist/src/ui/keyMatchers.test.d.ts +0 -6
- package/dist/src/ui/keyMatchers.test.js +0 -276
- package/dist/src/ui/keyMatchers.test.js.map +0 -1
- package/dist/src/ui/privacy/CloudFreePrivacyNotice.d.ts +0 -12
- package/dist/src/ui/privacy/CloudFreePrivacyNotice.js +0 -41
- package/dist/src/ui/privacy/CloudFreePrivacyNotice.js.map +0 -1
- package/dist/src/ui/privacy/CloudPaidPrivacyNotice.d.ts +0 -10
- package/dist/src/ui/privacy/CloudPaidPrivacyNotice.js +0 -18
- package/dist/src/ui/privacy/CloudPaidPrivacyNotice.js.map +0 -1
- package/dist/src/ui/privacy/GeminiPrivacyNotice.d.ts +0 -10
- package/dist/src/ui/privacy/GeminiPrivacyNotice.js +0 -18
- package/dist/src/ui/privacy/GeminiPrivacyNotice.js.map +0 -1
- package/dist/src/ui/privacy/PrivacyNotice.d.ts +0 -12
- package/dist/src/ui/privacy/PrivacyNotice.js +0 -25
- package/dist/src/ui/privacy/PrivacyNotice.js.map +0 -1
- package/dist/src/ui/semantic-colors.d.ts +0 -7
- package/dist/src/ui/semantic-colors.js +0 -24
- package/dist/src/ui/semantic-colors.js.map +0 -1
- package/dist/src/ui/themes/ansi-light.d.ts +0 -7
- package/dist/src/ui/themes/ansi-light.js +0 -142
- package/dist/src/ui/themes/ansi-light.js.map +0 -1
- package/dist/src/ui/themes/ansi.d.ts +0 -7
- package/dist/src/ui/themes/ansi.js +0 -152
- package/dist/src/ui/themes/ansi.js.map +0 -1
- package/dist/src/ui/themes/atom-one-dark.d.ts +0 -7
- package/dist/src/ui/themes/atom-one-dark.js +0 -139
- package/dist/src/ui/themes/atom-one-dark.js.map +0 -1
- package/dist/src/ui/themes/ayu-light.d.ts +0 -7
- package/dist/src/ui/themes/ayu-light.js +0 -131
- package/dist/src/ui/themes/ayu-light.js.map +0 -1
- package/dist/src/ui/themes/ayu.d.ts +0 -7
- package/dist/src/ui/themes/ayu.js +0 -105
- package/dist/src/ui/themes/ayu.js.map +0 -1
- package/dist/src/ui/themes/color-utils.d.ts +0 -21
- package/dist/src/ui/themes/color-utils.js +0 -221
- package/dist/src/ui/themes/color-utils.js.map +0 -1
- package/dist/src/ui/themes/color-utils.test.d.ts +0 -6
- package/dist/src/ui/themes/color-utils.test.js +0 -197
- package/dist/src/ui/themes/color-utils.test.js.map +0 -1
- package/dist/src/ui/themes/default-light.d.ts +0 -7
- package/dist/src/ui/themes/default-light.js +0 -101
- package/dist/src/ui/themes/default-light.js.map +0 -1
- package/dist/src/ui/themes/default.d.ts +0 -7
- package/dist/src/ui/themes/default.js +0 -144
- package/dist/src/ui/themes/default.js.map +0 -1
- package/dist/src/ui/themes/dracula.d.ts +0 -7
- package/dist/src/ui/themes/dracula.js +0 -116
- package/dist/src/ui/themes/dracula.js.map +0 -1
- package/dist/src/ui/themes/fss-code-dark.d.ts +0 -7
- package/dist/src/ui/themes/fss-code-dark.js +0 -148
- package/dist/src/ui/themes/fss-code-dark.js.map +0 -1
- package/dist/src/ui/themes/fss-dark.d.ts +0 -7
- package/dist/src/ui/themes/fss-dark.js +0 -105
- package/dist/src/ui/themes/fss-dark.js.map +0 -1
- package/dist/src/ui/themes/fss-light.d.ts +0 -7
- package/dist/src/ui/themes/fss-light.js +0 -131
- package/dist/src/ui/themes/fss-light.js.map +0 -1
- package/dist/src/ui/themes/github-dark.d.ts +0 -7
- package/dist/src/ui/themes/github-dark.js +0 -139
- package/dist/src/ui/themes/github-dark.js.map +0 -1
- package/dist/src/ui/themes/github-light.d.ts +0 -7
- package/dist/src/ui/themes/github-light.js +0 -141
- package/dist/src/ui/themes/github-light.js.map +0 -1
- package/dist/src/ui/themes/googlecode.d.ts +0 -7
- package/dist/src/ui/themes/googlecode.js +0 -138
- package/dist/src/ui/themes/googlecode.js.map +0 -1
- package/dist/src/ui/themes/no-color.d.ts +0 -7
- package/dist/src/ui/themes/no-color.js +0 -115
- package/dist/src/ui/themes/no-color.js.map +0 -1
- package/dist/src/ui/themes/qwen-dark.d.ts +0 -7
- package/dist/src/ui/themes/qwen-dark.js +0 -105
- package/dist/src/ui/themes/qwen-dark.js.map +0 -1
- package/dist/src/ui/themes/qwen-light.d.ts +0 -7
- package/dist/src/ui/themes/qwen-light.js +0 -131
- package/dist/src/ui/themes/qwen-light.js.map +0 -1
- package/dist/src/ui/themes/semantic-tokens.d.ts +0 -37
- package/dist/src/ui/themes/semantic-tokens.js +0 -94
- package/dist/src/ui/themes/semantic-tokens.js.map +0 -1
- package/dist/src/ui/themes/shades-of-purple.d.ts +0 -11
- package/dist/src/ui/themes/shades-of-purple.js +0 -305
- package/dist/src/ui/themes/shades-of-purple.js.map +0 -1
- package/dist/src/ui/themes/theme-manager.d.ts +0 -64
- package/dist/src/ui/themes/theme-manager.js +0 -209
- package/dist/src/ui/themes/theme-manager.js.map +0 -1
- package/dist/src/ui/themes/theme-manager.test.d.ts +0 -6
- package/dist/src/ui/themes/theme-manager.test.js +0 -83
- package/dist/src/ui/themes/theme-manager.test.js.map +0 -1
- package/dist/src/ui/themes/theme.d.ts +0 -130
- package/dist/src/ui/themes/theme.js +0 -351
- package/dist/src/ui/themes/theme.js.map +0 -1
- package/dist/src/ui/themes/xcode.d.ts +0 -7
- package/dist/src/ui/themes/xcode.js +0 -146
- package/dist/src/ui/themes/xcode.js.map +0 -1
- package/dist/src/ui/types.d.ts +0 -191
- package/dist/src/ui/types.js +0 -44
- package/dist/src/ui/types.js.map +0 -1
- package/dist/src/ui/utils/CodeColorizer.d.ts +0 -17
- package/dist/src/ui/utils/CodeColorizer.js +0 -110
- package/dist/src/ui/utils/CodeColorizer.js.map +0 -1
- package/dist/src/ui/utils/ConsolePatcher.d.ts +0 -25
- package/dist/src/ui/utils/ConsolePatcher.js +0 -52
- package/dist/src/ui/utils/ConsolePatcher.js.map +0 -1
- package/dist/src/ui/utils/InlineMarkdownRenderer.d.ts +0 -16
- package/dist/src/ui/utils/InlineMarkdownRenderer.js +0 -111
- package/dist/src/ui/utils/InlineMarkdownRenderer.js.map +0 -1
- package/dist/src/ui/utils/MarkdownDisplay.d.ts +0 -14
- package/dist/src/ui/utils/MarkdownDisplay.js +0 -207
- package/dist/src/ui/utils/MarkdownDisplay.js.map +0 -1
- package/dist/src/ui/utils/MarkdownDisplay.test.d.ts +0 -6
- package/dist/src/ui/utils/MarkdownDisplay.test.js +0 -151
- package/dist/src/ui/utils/MarkdownDisplay.test.js.map +0 -1
- package/dist/src/ui/utils/TableRenderer.d.ts +0 -17
- package/dist/src/ui/utils/TableRenderer.js +0 -84
- package/dist/src/ui/utils/TableRenderer.js.map +0 -1
- package/dist/src/ui/utils/clipboardUtils.d.ts +0 -22
- package/dist/src/ui/utils/clipboardUtils.js +0 -127
- package/dist/src/ui/utils/clipboardUtils.js.map +0 -1
- package/dist/src/ui/utils/clipboardUtils.test.d.ts +0 -6
- package/dist/src/ui/utils/clipboardUtils.test.js +0 -65
- package/dist/src/ui/utils/clipboardUtils.test.js.map +0 -1
- package/dist/src/ui/utils/commandUtils.d.ts +0 -24
- package/dist/src/ui/utils/commandUtils.js +0 -93
- package/dist/src/ui/utils/commandUtils.js.map +0 -1
- package/dist/src/ui/utils/commandUtils.test.d.ts +0 -6
- package/dist/src/ui/utils/commandUtils.test.js +0 -294
- package/dist/src/ui/utils/commandUtils.test.js.map +0 -1
- package/dist/src/ui/utils/computeStats.d.ts +0 -10
- package/dist/src/ui/utils/computeStats.js +0 -57
- package/dist/src/ui/utils/computeStats.js.map +0 -1
- package/dist/src/ui/utils/displayUtils.d.ts +0 -17
- package/dist/src/ui/utils/displayUtils.js +0 -24
- package/dist/src/ui/utils/displayUtils.js.map +0 -1
- package/dist/src/ui/utils/displayUtils.test.d.ts +0 -6
- package/dist/src/ui/utils/displayUtils.test.js +0 -42
- package/dist/src/ui/utils/displayUtils.test.js.map +0 -1
- package/dist/src/ui/utils/formatters.d.ts +0 -13
- package/dist/src/ui/utils/formatters.js +0 -56
- package/dist/src/ui/utils/formatters.js.map +0 -1
- package/dist/src/ui/utils/formatters.test.d.ts +0 -6
- package/dist/src/ui/utils/formatters.test.js +0 -56
- package/dist/src/ui/utils/formatters.test.js.map +0 -1
- package/dist/src/ui/utils/isNarrowWidth.d.ts +0 -6
- package/dist/src/ui/utils/isNarrowWidth.js +0 -9
- package/dist/src/ui/utils/isNarrowWidth.js.map +0 -1
- package/dist/src/ui/utils/kittyProtocolDetector.d.ts +0 -13
- package/dist/src/ui/utils/kittyProtocolDetector.js +0 -88
- package/dist/src/ui/utils/kittyProtocolDetector.js.map +0 -1
- package/dist/src/ui/utils/markdownUtilities.d.ts +0 -6
- package/dist/src/ui/utils/markdownUtilities.js +0 -110
- package/dist/src/ui/utils/markdownUtilities.js.map +0 -1
- package/dist/src/ui/utils/markdownUtilities.test.d.ts +0 -6
- package/dist/src/ui/utils/markdownUtilities.test.js +0 -42
- package/dist/src/ui/utils/markdownUtilities.test.js.map +0 -1
- package/dist/src/ui/utils/platformConstants.d.ts +0 -45
- package/dist/src/ui/utils/platformConstants.js +0 -46
- package/dist/src/ui/utils/platformConstants.js.map +0 -1
- package/dist/src/ui/utils/terminalSetup.d.ts +0 -30
- package/dist/src/ui/utils/terminalSetup.js +0 -281
- package/dist/src/ui/utils/terminalSetup.js.map +0 -1
- package/dist/src/ui/utils/textUtils.d.ts +0 -14
- package/dist/src/ui/utils/textUtils.js +0 -36
- package/dist/src/ui/utils/textUtils.js.map +0 -1
- package/dist/src/ui/utils/updateCheck.d.ts +0 -12
- package/dist/src/ui/utils/updateCheck.js +0 -78
- package/dist/src/ui/utils/updateCheck.js.map +0 -1
- package/dist/src/ui/utils/updateCheck.test.d.ts +0 -6
- package/dist/src/ui/utils/updateCheck.test.js +0 -145
- package/dist/src/ui/utils/updateCheck.test.js.map +0 -1
- package/dist/src/utils/checks.d.ts +0 -19
- package/dist/src/utils/checks.js +0 -24
- package/dist/src/utils/checks.js.map +0 -1
- package/dist/src/utils/cleanup.d.ts +0 -8
- package/dist/src/utils/cleanup.js +0 -34
- package/dist/src/utils/cleanup.js.map +0 -1
- package/dist/src/utils/dialogScopeUtils.d.ts +0 -31
- package/dist/src/utils/dialogScopeUtils.js +0 -48
- package/dist/src/utils/dialogScopeUtils.js.map +0 -1
- package/dist/src/utils/events.d.ts +0 -11
- package/dist/src/utils/events.js +0 -13
- package/dist/src/utils/events.js.map +0 -1
- package/dist/src/utils/gitUtils.d.ts +0 -30
- package/dist/src/utils/gitUtils.js +0 -89
- package/dist/src/utils/gitUtils.js.map +0 -1
- package/dist/src/utils/gitUtils.test.d.ts +0 -6
- package/dist/src/utils/gitUtils.test.js +0 -113
- package/dist/src/utils/gitUtils.test.js.map +0 -1
- package/dist/src/utils/handleAutoUpdate.d.ts +0 -11
- package/dist/src/utils/handleAutoUpdate.js +0 -101
- package/dist/src/utils/handleAutoUpdate.js.map +0 -1
- package/dist/src/utils/installationInfo.d.ts +0 -23
- package/dist/src/utils/installationInfo.js +0 -153
- package/dist/src/utils/installationInfo.js.map +0 -1
- package/dist/src/utils/installationInfo.test.d.ts +0 -6
- package/dist/src/utils/installationInfo.test.js +0 -242
- package/dist/src/utils/installationInfo.test.js.map +0 -1
- package/dist/src/utils/package.d.ts +0 -12
- package/dist/src/utils/package.js +0 -24
- package/dist/src/utils/package.js.map +0 -1
- package/dist/src/utils/readStdin.d.ts +0 -6
- package/dist/src/utils/readStdin.js +0 -44
- package/dist/src/utils/readStdin.js.map +0 -1
- package/dist/src/utils/resolvePath.d.ts +0 -6
- package/dist/src/utils/resolvePath.js +0 -21
- package/dist/src/utils/resolvePath.js.map +0 -1
- package/dist/src/utils/sandbox.d.ts +0 -7
- package/dist/src/utils/sandbox.js +0 -745
- package/dist/src/utils/sandbox.js.map +0 -1
- package/dist/src/utils/settingsUtils.d.ts +0 -134
- package/dist/src/utils/settingsUtils.js +0 -336
- package/dist/src/utils/settingsUtils.js.map +0 -1
- package/dist/src/utils/settingsUtils.test.d.ts +0 -6
- package/dist/src/utils/settingsUtils.test.js +0 -514
- package/dist/src/utils/settingsUtils.test.js.map +0 -1
- package/dist/src/utils/spawnWrapper.d.ts +0 -7
- package/dist/src/utils/spawnWrapper.js +0 -8
- package/dist/src/utils/spawnWrapper.js.map +0 -1
- package/dist/src/utils/startupWarnings.d.ts +0 -6
- package/dist/src/utils/startupWarnings.js +0 -40
- package/dist/src/utils/startupWarnings.js.map +0 -1
- package/dist/src/utils/updateEventEmitter.d.ts +0 -11
- package/dist/src/utils/updateEventEmitter.js +0 -12
- package/dist/src/utils/updateEventEmitter.js.map +0 -1
- package/dist/src/utils/userStartupWarnings.d.ts +0 -6
- package/dist/src/utils/userStartupWarnings.js +0 -54
- package/dist/src/utils/userStartupWarnings.js.map +0 -1
- package/dist/src/utils/userStartupWarnings.test.d.ts +0 -6
- package/dist/src/utils/userStartupWarnings.test.js +0 -67
- package/dist/src/utils/userStartupWarnings.test.js.map +0 -1
- package/dist/src/utils/version.d.ts +0 -6
- package/dist/src/utils/version.js +0 -11
- package/dist/src/utils/version.js.map +0 -1
- package/dist/src/validateNonInterActiveAuth.d.ts +0 -7
- package/dist/src/validateNonInterActiveAuth.js +0 -40
- package/dist/src/validateNonInterActiveAuth.js.map +0 -1
- package/dist/src/zed-integration/acp.d.ts +0 -63
- package/dist/src/zed-integration/acp.js +0 -225
- package/dist/src/zed-integration/acp.js.map +0 -1
- package/dist/src/zed-integration/fileSystemService.d.ts +0 -19
- package/dist/src/zed-integration/fileSystemService.js +0 -43
- package/dist/src/zed-integration/fileSystemService.js.map +0 -1
- package/dist/src/zed-integration/schema.d.ts +0 -11782
- package/dist/src/zed-integration/schema.js +0 -311
- package/dist/src/zed-integration/schema.js.map +0 -1
- package/dist/src/zed-integration/zedIntegration.d.ts +0 -10
- package/dist/src/zed-integration/zedIntegration.js +0 -765
- package/dist/src/zed-integration/zedIntegration.js.map +0 -1
- package/dist/tsconfig.tsbuildinfo +0 -1
- /package/{dist/src/utils → bundle}/sandbox-macos-permissive-closed.sb +0 -0
- /package/{dist/src/utils → bundle}/sandbox-macos-permissive-open.sb +0 -0
- /package/{dist/src/utils → bundle}/sandbox-macos-permissive-proxied.sb +0 -0
- /package/{dist/src/utils → bundle}/sandbox-macos-restrictive-closed.sb +0 -0
- /package/{dist/src/utils → bundle}/sandbox-macos-restrictive-open.sb +0 -0
- /package/{dist/src/utils → bundle}/sandbox-macos-restrictive-proxied.sb +0 -0
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* Command enum for all available keyboard shortcuts
|
|
8
|
-
*/
|
|
9
|
-
export var Command;
|
|
10
|
-
(function (Command) {
|
|
11
|
-
// Basic bindings
|
|
12
|
-
Command["RETURN"] = "return";
|
|
13
|
-
Command["ESCAPE"] = "escape";
|
|
14
|
-
// Cursor movement
|
|
15
|
-
Command["HOME"] = "home";
|
|
16
|
-
Command["END"] = "end";
|
|
17
|
-
// Text deletion
|
|
18
|
-
Command["KILL_LINE_RIGHT"] = "killLineRight";
|
|
19
|
-
Command["KILL_LINE_LEFT"] = "killLineLeft";
|
|
20
|
-
Command["CLEAR_INPUT"] = "clearInput";
|
|
21
|
-
// Screen control
|
|
22
|
-
Command["CLEAR_SCREEN"] = "clearScreen";
|
|
23
|
-
// History navigation
|
|
24
|
-
Command["HISTORY_UP"] = "historyUp";
|
|
25
|
-
Command["HISTORY_DOWN"] = "historyDown";
|
|
26
|
-
Command["NAVIGATION_UP"] = "navigationUp";
|
|
27
|
-
Command["NAVIGATION_DOWN"] = "navigationDown";
|
|
28
|
-
// Auto-completion
|
|
29
|
-
Command["ACCEPT_SUGGESTION"] = "acceptSuggestion";
|
|
30
|
-
Command["COMPLETION_UP"] = "completionUp";
|
|
31
|
-
Command["COMPLETION_DOWN"] = "completionDown";
|
|
32
|
-
// Text input
|
|
33
|
-
Command["SUBMIT"] = "submit";
|
|
34
|
-
Command["NEWLINE"] = "newline";
|
|
35
|
-
// External tools
|
|
36
|
-
Command["OPEN_EXTERNAL_EDITOR"] = "openExternalEditor";
|
|
37
|
-
Command["PASTE_CLIPBOARD_IMAGE"] = "pasteClipboardImage";
|
|
38
|
-
// App level bindings
|
|
39
|
-
Command["SHOW_ERROR_DETAILS"] = "showErrorDetails";
|
|
40
|
-
Command["TOGGLE_TOOL_DESCRIPTIONS"] = "toggleToolDescriptions";
|
|
41
|
-
Command["TOGGLE_IDE_CONTEXT_DETAIL"] = "toggleIDEContextDetail";
|
|
42
|
-
Command["QUIT"] = "quit";
|
|
43
|
-
Command["EXIT"] = "exit";
|
|
44
|
-
Command["SHOW_MORE_LINES"] = "showMoreLines";
|
|
45
|
-
// Shell commands
|
|
46
|
-
Command["REVERSE_SEARCH"] = "reverseSearch";
|
|
47
|
-
Command["SUBMIT_REVERSE_SEARCH"] = "submitReverseSearch";
|
|
48
|
-
Command["ACCEPT_SUGGESTION_REVERSE_SEARCH"] = "acceptSuggestionReverseSearch";
|
|
49
|
-
})(Command || (Command = {}));
|
|
50
|
-
/**
|
|
51
|
-
* Default key binding configuration
|
|
52
|
-
* Matches the original hard-coded logic exactly
|
|
53
|
-
*/
|
|
54
|
-
export const defaultKeyBindings = {
|
|
55
|
-
// Basic bindings
|
|
56
|
-
[Command.RETURN]: [{ key: 'return' }],
|
|
57
|
-
// Original: key.name === 'escape'
|
|
58
|
-
[Command.ESCAPE]: [{ key: 'escape' }],
|
|
59
|
-
// Cursor movement
|
|
60
|
-
// Original: key.ctrl && key.name === 'a'
|
|
61
|
-
[Command.HOME]: [{ key: 'a', ctrl: true }],
|
|
62
|
-
// Original: key.ctrl && key.name === 'e'
|
|
63
|
-
[Command.END]: [{ key: 'e', ctrl: true }],
|
|
64
|
-
// Text deletion
|
|
65
|
-
// Original: key.ctrl && key.name === 'k'
|
|
66
|
-
[Command.KILL_LINE_RIGHT]: [{ key: 'k', ctrl: true }],
|
|
67
|
-
// Original: key.ctrl && key.name === 'u'
|
|
68
|
-
[Command.KILL_LINE_LEFT]: [{ key: 'u', ctrl: true }],
|
|
69
|
-
// Original: key.ctrl && key.name === 'c'
|
|
70
|
-
[Command.CLEAR_INPUT]: [{ key: 'c', ctrl: true }],
|
|
71
|
-
// Screen control
|
|
72
|
-
// Original: key.ctrl && key.name === 'l'
|
|
73
|
-
[Command.CLEAR_SCREEN]: [{ key: 'l', ctrl: true }],
|
|
74
|
-
// History navigation
|
|
75
|
-
// Original: key.ctrl && key.name === 'p'
|
|
76
|
-
[Command.HISTORY_UP]: [{ key: 'p', ctrl: true }],
|
|
77
|
-
// Original: key.ctrl && key.name === 'n'
|
|
78
|
-
[Command.HISTORY_DOWN]: [{ key: 'n', ctrl: true }],
|
|
79
|
-
// Original: key.name === 'up'
|
|
80
|
-
[Command.NAVIGATION_UP]: [{ key: 'up' }],
|
|
81
|
-
// Original: key.name === 'down'
|
|
82
|
-
[Command.NAVIGATION_DOWN]: [{ key: 'down' }],
|
|
83
|
-
// Auto-completion
|
|
84
|
-
// Original: key.name === 'tab' || (key.name === 'return' && !key.ctrl)
|
|
85
|
-
[Command.ACCEPT_SUGGESTION]: [{ key: 'tab' }, { key: 'return', ctrl: false }],
|
|
86
|
-
// Completion navigation (arrow or Ctrl+P/N)
|
|
87
|
-
[Command.COMPLETION_UP]: [{ key: 'up' }, { key: 'p', ctrl: true }],
|
|
88
|
-
[Command.COMPLETION_DOWN]: [{ key: 'down' }, { key: 'n', ctrl: true }],
|
|
89
|
-
// Text input
|
|
90
|
-
// Original: key.name === 'return' && !key.ctrl && !key.meta && !key.paste
|
|
91
|
-
// Must also exclude shift to allow shift+enter for newline
|
|
92
|
-
[Command.SUBMIT]: [
|
|
93
|
-
{
|
|
94
|
-
key: 'return',
|
|
95
|
-
ctrl: false,
|
|
96
|
-
command: false,
|
|
97
|
-
paste: false,
|
|
98
|
-
shift: false,
|
|
99
|
-
},
|
|
100
|
-
],
|
|
101
|
-
// Original: key.name === 'return' && (key.ctrl || key.meta || key.paste)
|
|
102
|
-
// Split into multiple data-driven bindings
|
|
103
|
-
// Now also includes shift+enter for multi-line input
|
|
104
|
-
[Command.NEWLINE]: [
|
|
105
|
-
{ key: 'return', ctrl: true },
|
|
106
|
-
{ key: 'return', command: true },
|
|
107
|
-
{ key: 'return', paste: true },
|
|
108
|
-
{ key: 'return', shift: true },
|
|
109
|
-
{ key: 'j', ctrl: true },
|
|
110
|
-
],
|
|
111
|
-
// External tools
|
|
112
|
-
// Original: key.ctrl && (key.name === 'x' || key.sequence === '\x18')
|
|
113
|
-
[Command.OPEN_EXTERNAL_EDITOR]: [
|
|
114
|
-
{ key: 'x', ctrl: true },
|
|
115
|
-
{ sequence: '\x18', ctrl: true },
|
|
116
|
-
],
|
|
117
|
-
// Original: key.ctrl && key.name === 'v'
|
|
118
|
-
[Command.PASTE_CLIPBOARD_IMAGE]: [{ key: 'v', ctrl: true }],
|
|
119
|
-
// App level bindings
|
|
120
|
-
// Original: key.ctrl && key.name === 'o'
|
|
121
|
-
[Command.SHOW_ERROR_DETAILS]: [{ key: 'o', ctrl: true }],
|
|
122
|
-
// Original: key.ctrl && key.name === 't'
|
|
123
|
-
[Command.TOGGLE_TOOL_DESCRIPTIONS]: [{ key: 't', ctrl: true }],
|
|
124
|
-
// Original: key.ctrl && key.name === 'g'
|
|
125
|
-
[Command.TOGGLE_IDE_CONTEXT_DETAIL]: [{ key: 'g', ctrl: true }],
|
|
126
|
-
// Original: key.ctrl && (key.name === 'c' || key.name === 'C')
|
|
127
|
-
[Command.QUIT]: [{ key: 'c', ctrl: true }],
|
|
128
|
-
// Original: key.ctrl && (key.name === 'd' || key.name === 'D')
|
|
129
|
-
[Command.EXIT]: [{ key: 'd', ctrl: true }],
|
|
130
|
-
// Original: key.ctrl && key.name === 's'
|
|
131
|
-
[Command.SHOW_MORE_LINES]: [{ key: 's', ctrl: true }],
|
|
132
|
-
// Shell commands
|
|
133
|
-
// Original: key.ctrl && key.name === 'r'
|
|
134
|
-
[Command.REVERSE_SEARCH]: [{ key: 'r', ctrl: true }],
|
|
135
|
-
// Original: key.name === 'return' && !key.ctrl
|
|
136
|
-
// Note: original logic ONLY checked ctrl=false, ignored meta/shift/paste
|
|
137
|
-
[Command.SUBMIT_REVERSE_SEARCH]: [{ key: 'return', ctrl: false }],
|
|
138
|
-
// Original: key.name === 'tab'
|
|
139
|
-
[Command.ACCEPT_SUGGESTION_REVERSE_SEARCH]: [{ key: 'tab' }],
|
|
140
|
-
};
|
|
141
|
-
//# sourceMappingURL=keyBindings.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"keyBindings.js","sourceRoot":"","sources":["../../../src/config/keyBindings.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;GAEG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|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import { describe, it, expect } from 'vitest';
|
|
7
|
-
import { Command, defaultKeyBindings, } from './keyBindings.js';
|
|
8
|
-
describe('keyBindings config', () => {
|
|
9
|
-
describe('defaultKeyBindings', () => {
|
|
10
|
-
it('should have bindings for all commands', () => {
|
|
11
|
-
const commands = Object.values(Command);
|
|
12
|
-
for (const command of commands) {
|
|
13
|
-
expect(defaultKeyBindings[command]).toBeDefined();
|
|
14
|
-
expect(Array.isArray(defaultKeyBindings[command])).toBe(true);
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
it('should have valid key binding structures', () => {
|
|
18
|
-
for (const [_, bindings] of Object.entries(defaultKeyBindings)) {
|
|
19
|
-
for (const binding of bindings) {
|
|
20
|
-
// Each binding should have either key or sequence, but not both
|
|
21
|
-
const hasKey = binding.key !== undefined;
|
|
22
|
-
const hasSequence = binding.sequence !== undefined;
|
|
23
|
-
expect(hasKey || hasSequence).toBe(true);
|
|
24
|
-
expect(hasKey && hasSequence).toBe(false);
|
|
25
|
-
// Modifier properties should be boolean or undefined
|
|
26
|
-
if (binding.ctrl !== undefined) {
|
|
27
|
-
expect(typeof binding.ctrl).toBe('boolean');
|
|
28
|
-
}
|
|
29
|
-
if (binding.shift !== undefined) {
|
|
30
|
-
expect(typeof binding.shift).toBe('boolean');
|
|
31
|
-
}
|
|
32
|
-
if (binding.command !== undefined) {
|
|
33
|
-
expect(typeof binding.command).toBe('boolean');
|
|
34
|
-
}
|
|
35
|
-
if (binding.paste !== undefined) {
|
|
36
|
-
expect(typeof binding.paste).toBe('boolean');
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
});
|
|
41
|
-
it('should export all required types', () => {
|
|
42
|
-
// Basic type checks
|
|
43
|
-
expect(typeof Command.HOME).toBe('string');
|
|
44
|
-
expect(typeof Command.END).toBe('string');
|
|
45
|
-
// Config should be readonly
|
|
46
|
-
const config = defaultKeyBindings;
|
|
47
|
-
expect(config[Command.HOME]).toBeDefined();
|
|
48
|
-
});
|
|
49
|
-
});
|
|
50
|
-
});
|
|
51
|
-
//# sourceMappingURL=keyBindings.test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"keyBindings.test.js","sourceRoot":"","sources":["../../../src/config/keyBindings.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EACL,OAAO,EAEP,kBAAkB,GACnB,MAAM,kBAAkB,CAAC;AAE1B,QAAQ,CAAC,oBAAoB,EAAE,GAAG,EAAE;IAClC,QAAQ,CAAC,oBAAoB,EAAE,GAAG,EAAE;QAClC,EAAE,CAAC,uCAAuC,EAAE,GAAG,EAAE;YAC/C,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YAExC,KAAK,MAAM,OAAO,IAAI,QAAQ,EAAE,CAAC;gBAC/B,MAAM,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;gBAClD,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YAChE,CAAC;QACH,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,0CAA0C,EAAE,GAAG,EAAE;YAClD,KAAK,MAAM,CAAC,CAAC,EAAE,QAAQ,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,kBAAkB,CAAC,EAAE,CAAC;gBAC/D,KAAK,MAAM,OAAO,IAAI,QAAQ,EAAE,CAAC;oBAC/B,gEAAgE;oBAChE,MAAM,MAAM,GAAG,OAAO,CAAC,GAAG,KAAK,SAAS,CAA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AC,IAAI,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;QAC7C,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import { AuthType, ModelConfig } from '@fsscoding/fss-link-core';
|
|
7
|
-
/**
|
|
8
|
-
* Model Manager - High-level interface for model switching and persistence
|
|
9
|
-
* Implements ModelStateProvider for integration with Config class
|
|
10
|
-
*/
|
|
11
|
-
export declare class ModelManager {
|
|
12
|
-
private getDb;
|
|
13
|
-
/**
|
|
14
|
-
* Set up a new model configuration and make it active
|
|
15
|
-
* Implements ModelStateProvider.setActiveModel
|
|
16
|
-
*/
|
|
17
|
-
setActiveModel(config: ModelConfig): Promise<number>;
|
|
18
|
-
/**
|
|
19
|
-
* Set up a new model configuration and make it active (legacy method)
|
|
20
|
-
*/
|
|
21
|
-
configureModel(authType: AuthType, modelName: string, endpointUrl?: string, apiKey?: string, displayName?: string): Promise<number>;
|
|
22
|
-
/**
|
|
23
|
-
* Switch to an existing model by ID
|
|
24
|
-
*/
|
|
25
|
-
switchToModel(modelId: number): Promise<boolean>;
|
|
26
|
-
/**
|
|
27
|
-
* Get the currently active model
|
|
28
|
-
*/
|
|
29
|
-
getActiveModel(): Promise<ModelConfig | null>;
|
|
30
|
-
/**
|
|
31
|
-
* Get all configured models
|
|
32
|
-
*/
|
|
33
|
-
getAllModels(): Promise<ModelConfig[]>;
|
|
34
|
-
/**
|
|
35
|
-
* Get favorite models
|
|
36
|
-
*/
|
|
37
|
-
getFavoriteModels(): Promise<ModelConfig[]>;
|
|
38
|
-
/**
|
|
39
|
-
* Get recently used models
|
|
40
|
-
*/
|
|
41
|
-
getRecentModels(limit?: number): Promise<ModelConfig[]>;
|
|
42
|
-
/**
|
|
43
|
-
* Toggle favorite status for a model
|
|
44
|
-
*/
|
|
45
|
-
toggleFavorite(modelId: number): Promise<void>;
|
|
46
|
-
/**
|
|
47
|
-
* Delete a model configuration
|
|
48
|
-
*/
|
|
49
|
-
deleteModel(modelId: number): Promise<void>;
|
|
50
|
-
/**
|
|
51
|
-
* Initialize environment variables from active model on startup
|
|
52
|
-
* Implements ModelStateProvider.initializeFromStore
|
|
53
|
-
*/
|
|
54
|
-
initializeFromStore(): Promise<boolean>;
|
|
55
|
-
/**
|
|
56
|
-
* Check if we have a valid active model configuration
|
|
57
|
-
*/
|
|
58
|
-
hasValidConfiguration(): Promise<boolean>;
|
|
59
|
-
/**
|
|
60
|
-
* Get current auth type from active model
|
|
61
|
-
* Implements ModelStateProvider.getCurrentAuthType
|
|
62
|
-
*/
|
|
63
|
-
getCurrentAuthType(): Promise<string | undefined>;
|
|
64
|
-
/**
|
|
65
|
-
* Get current auth type as FSS Link AuthType enum (legacy method)
|
|
66
|
-
*/
|
|
67
|
-
getCurrentFSSAuthType(): Promise<AuthType | undefined>;
|
|
68
|
-
/**
|
|
69
|
-
* Update process environment variables from model configuration
|
|
70
|
-
*/
|
|
71
|
-
private updateEnvironmentFromModel;
|
|
72
|
-
/**
|
|
73
|
-
* Map FSS Link AuthType to database auth type
|
|
74
|
-
*/
|
|
75
|
-
private mapAuthType;
|
|
76
|
-
/**
|
|
77
|
-
* Map database auth type to FSS Link AuthType
|
|
78
|
-
*/
|
|
79
|
-
private mapToFSSLinkAuthType;
|
|
80
|
-
}
|
|
81
|
-
/**
|
|
82
|
-
* Get the global model manager instance
|
|
83
|
-
*/
|
|
84
|
-
export declare function getModelManager(): ModelManager;
|
|
@@ -1,234 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import { AuthType } from '@fsscoding/fss-link-core';
|
|
7
|
-
import { getFSSLinkDatabase } from './database.js';
|
|
8
|
-
/**
|
|
9
|
-
* Model Manager - High-level interface for model switching and persistence
|
|
10
|
-
* Implements ModelStateProvider for integration with Config class
|
|
11
|
-
*/
|
|
12
|
-
export class ModelManager {
|
|
13
|
-
async getDb() {
|
|
14
|
-
return await getFSSLinkDatabase();
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* Set up a new model configuration and make it active
|
|
18
|
-
* Implements ModelStateProvider.setActiveModel
|
|
19
|
-
*/
|
|
20
|
-
async setActiveModel(config) {
|
|
21
|
-
const db = await this.getDb();
|
|
22
|
-
// Insert the model and get its ID
|
|
23
|
-
const modelId = await db.upsertModelConfig(config);
|
|
24
|
-
// Set as active model (deactivates others)
|
|
25
|
-
await db.setActiveModel(modelId);
|
|
26
|
-
// Update environment variables for immediate use
|
|
27
|
-
this.updateEnvironmentFromModel(config);
|
|
28
|
-
return modelId;
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* Set up a new model configuration and make it active (legacy method)
|
|
32
|
-
*/
|
|
33
|
-
async configureModel(authType, modelName, endpointUrl, apiKey, displayName) {
|
|
34
|
-
const db = await this.getDb();
|
|
35
|
-
const config = {
|
|
36
|
-
authType: this.mapAuthType(authType),
|
|
37
|
-
modelName,
|
|
38
|
-
endpointUrl,
|
|
39
|
-
apiKey,
|
|
40
|
-
displayName,
|
|
41
|
-
isFavorite: false,
|
|
42
|
-
isActive: true, // Make this the active model
|
|
43
|
-
};
|
|
44
|
-
// Insert the model and get its ID
|
|
45
|
-
const modelId = await db.upsertModelConfig(config);
|
|
46
|
-
// Set as active model (deactivates others)
|
|
47
|
-
await db.setActiveModel(modelId);
|
|
48
|
-
// Update environment variables for immediate use
|
|
49
|
-
this.updateEnvironmentFromModel(config);
|
|
50
|
-
return modelId;
|
|
51
|
-
}
|
|
52
|
-
/**
|
|
53
|
-
* Switch to an existing model by ID
|
|
54
|
-
*/
|
|
55
|
-
async switchToModel(modelId) {
|
|
56
|
-
try {
|
|
57
|
-
const db = await this.getDb();
|
|
58
|
-
await db.setActiveModel(modelId);
|
|
59
|
-
const activeModel = await db.getActiveModel();
|
|
60
|
-
if (activeModel) {
|
|
61
|
-
this.updateEnvironmentFromModel(activeModel);
|
|
62
|
-
return true;
|
|
63
|
-
}
|
|
64
|
-
return false;
|
|
65
|
-
}
|
|
66
|
-
catch (error) {
|
|
67
|
-
console.error('Failed to switch to model:', error);
|
|
68
|
-
return false;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
/**
|
|
72
|
-
* Get the currently active model
|
|
73
|
-
*/
|
|
74
|
-
async getActiveModel() {
|
|
75
|
-
const db = await this.getDb();
|
|
76
|
-
return await db.getActiveModel();
|
|
77
|
-
}
|
|
78
|
-
/**
|
|
79
|
-
* Get all configured models
|
|
80
|
-
*/
|
|
81
|
-
async getAllModels() {
|
|
82
|
-
const db = await this.getDb();
|
|
83
|
-
return await db.getAllModels();
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
|
-
* Get favorite models
|
|
87
|
-
*/
|
|
88
|
-
async getFavoriteModels() {
|
|
89
|
-
const db = await this.getDb();
|
|
90
|
-
return await db.getFavoriteModels();
|
|
91
|
-
}
|
|
92
|
-
/**
|
|
93
|
-
* Get recently used models
|
|
94
|
-
*/
|
|
95
|
-
async getRecentModels(limit = 5) {
|
|
96
|
-
const db = await this.getDb();
|
|
97
|
-
return await db.getRecentModels(limit);
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* Toggle favorite status for a model
|
|
101
|
-
*/
|
|
102
|
-
async toggleFavorite(modelId) {
|
|
103
|
-
const db = await this.getDb();
|
|
104
|
-
await db.toggleModelFavorite(modelId);
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Delete a model configuration
|
|
108
|
-
*/
|
|
109
|
-
async deleteModel(modelId) {
|
|
110
|
-
const db = await this.getDb();
|
|
111
|
-
await db.deleteModel(modelId);
|
|
112
|
-
}
|
|
113
|
-
/**
|
|
114
|
-
* Initialize environment variables from active model on startup
|
|
115
|
-
* Implements ModelStateProvider.initializeFromStore
|
|
116
|
-
*/
|
|
117
|
-
async initializeFromStore() {
|
|
118
|
-
const db = await this.getDb();
|
|
119
|
-
const activeModel = await db.getActiveModel();
|
|
120
|
-
if (activeModel) {
|
|
121
|
-
this.updateEnvironmentFromModel(activeModel);
|
|
122
|
-
return true;
|
|
123
|
-
}
|
|
124
|
-
return false;
|
|
125
|
-
}
|
|
126
|
-
/**
|
|
127
|
-
* Check if we have a valid active model configuration
|
|
128
|
-
*/
|
|
129
|
-
async hasValidConfiguration() {
|
|
130
|
-
const db = await this.getDb();
|
|
131
|
-
const activeModel = await db.getActiveModel();
|
|
132
|
-
return activeModel !== null;
|
|
133
|
-
}
|
|
134
|
-
/**
|
|
135
|
-
* Get current auth type from active model
|
|
136
|
-
* Implements ModelStateProvider.getCurrentAuthType
|
|
137
|
-
*/
|
|
138
|
-
async getCurrentAuthType() {
|
|
139
|
-
const db = await this.getDb();
|
|
140
|
-
const activeModel = await db.getActiveModel();
|
|
141
|
-
if (!activeModel || !activeModel.authType)
|
|
142
|
-
return undefined;
|
|
143
|
-
const authType = this.mapToFSSLinkAuthType(activeModel.authType);
|
|
144
|
-
return authType;
|
|
145
|
-
}
|
|
146
|
-
/**
|
|
147
|
-
* Get current auth type as FSS Link AuthType enum (legacy method)
|
|
148
|
-
*/
|
|
149
|
-
async getCurrentFSSAuthType() {
|
|
150
|
-
const db = await this.getDb();
|
|
151
|
-
const activeModel = await db.getActiveModel();
|
|
152
|
-
if (!activeModel || !activeModel.authType)
|
|
153
|
-
return undefined;
|
|
154
|
-
return this.mapToFSSLinkAuthType(activeModel.authType);
|
|
155
|
-
}
|
|
156
|
-
/**
|
|
157
|
-
* Update process environment variables from model configuration
|
|
158
|
-
*/
|
|
159
|
-
updateEnvironmentFromModel(model) {
|
|
160
|
-
switch (model.authType) {
|
|
161
|
-
case 'openai':
|
|
162
|
-
process.env['OPENAI_API_KEY'] = model.apiKey || '';
|
|
163
|
-
process.env['OPENAI_BASE_URL'] = model.endpointUrl || '';
|
|
164
|
-
process.env['OPENAI_MODEL'] = model.modelName || '';
|
|
165
|
-
break;
|
|
166
|
-
case 'ollama':
|
|
167
|
-
process.env['OLLAMA_API_KEY'] = model.apiKey || '1';
|
|
168
|
-
process.env['OLLAMA_BASE_URL'] = model.endpointUrl || 'http://localhost:11434/v1';
|
|
169
|
-
process.env['OLLAMA_MODEL'] = model.modelName || '';
|
|
170
|
-
break;
|
|
171
|
-
case 'lmstudio':
|
|
172
|
-
process.env['LM_STUDIO_API_KEY'] = model.apiKey || '1';
|
|
173
|
-
process.env['LM_STUDIO_BASE_URL'] = model.endpointUrl || 'http://localhost:1234/v1';
|
|
174
|
-
process.env['LM_STUDIO_MODEL'] = model.modelName || '';
|
|
175
|
-
break;
|
|
176
|
-
case 'qwen-oauth':
|
|
177
|
-
// Qwen OAuth doesn't use these environment variables
|
|
178
|
-
break;
|
|
179
|
-
default:
|
|
180
|
-
// Unknown auth type, no environment variables to set
|
|
181
|
-
console.warn(`Unknown auth type: ${model.authType}`);
|
|
182
|
-
break;
|
|
183
|
-
}
|
|
184
|
-
}
|
|
185
|
-
/**
|
|
186
|
-
* Map FSS Link AuthType to database auth type
|
|
187
|
-
*/
|
|
188
|
-
mapAuthType(authType) {
|
|
189
|
-
switch (authType) {
|
|
190
|
-
case AuthType.USE_OPENAI:
|
|
191
|
-
return 'openai';
|
|
192
|
-
case AuthType.OLLAMA:
|
|
193
|
-
return 'ollama';
|
|
194
|
-
case AuthType.LM_STUDIO:
|
|
195
|
-
return 'lmstudio';
|
|
196
|
-
case AuthType.QWEN_OAUTH:
|
|
197
|
-
return 'qwen-oauth';
|
|
198
|
-
default:
|
|
199
|
-
throw new Error(`Unsupported auth type: ${authType}`);
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
/**
|
|
203
|
-
* Map database auth type to FSS Link AuthType
|
|
204
|
-
*/
|
|
205
|
-
mapToFSSLinkAuthType(authType) {
|
|
206
|
-
if (!authType) {
|
|
207
|
-
throw new Error(`Auth type is null or undefined`);
|
|
208
|
-
}
|
|
209
|
-
switch (authType) {
|
|
210
|
-
case 'openai':
|
|
211
|
-
return AuthType.USE_OPENAI;
|
|
212
|
-
case 'ollama':
|
|
213
|
-
return AuthType.OLLAMA;
|
|
214
|
-
case 'lmstudio':
|
|
215
|
-
return AuthType.LM_STUDIO;
|
|
216
|
-
case 'qwen-oauth':
|
|
217
|
-
return AuthType.QWEN_OAUTH;
|
|
218
|
-
default:
|
|
219
|
-
throw new Error(`Unsupported database auth type: ${authType}`);
|
|
220
|
-
}
|
|
221
|
-
}
|
|
222
|
-
}
|
|
223
|
-
// Singleton instance
|
|
224
|
-
let modelManagerInstance = null;
|
|
225
|
-
/**
|
|
226
|
-
* Get the global model manager instance
|
|
227
|
-
*/
|
|
228
|
-
export function getModelManager() {
|
|
229
|
-
if (!modelManagerInstance) {
|
|
230
|
-
modelManagerInstance = new ModelManager();
|
|
231
|
-
}
|
|
232
|
-
return modelManagerInstance;
|
|
233
|
-
}
|
|
234
|
-
//# sourceMappingURL=modelManager.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"modelManager.js","sourceRoot":"","sources":["../../../src/config/modelManager.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAe,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD;;;GAGG;AACH,MAAM,OAAO,YAAY;IACf,KAAK,CAAC,KAAK;QACjB,OAAO,MAAM,kBAAkB,EAAE,CAAC;IACpC,CAAC;IAED;;;OAGG;IACH,KAAK,CAAC,cAAc,CAAC,MAAmB;QACtC,MAAM,EAAE,GAAG,MAAM,IAAI,CAAC,KAAK,EAAE,CAAC;QAE9B,kCAAkC;QAClC,MAAM,OAAO,GAAG,MAAM,EAAE,CAAC,iBAAiB,CA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;gBACrB,OAAO,UAAU,CAAC;YACpB,KAAK,QAAQ,CAAC,UAAU;gBACtB,OAAO,YAAY,CAAC;YACtB;gBACE,MAAM,IAAI,KAAK,CAAC,0BAA0B,QAAQ,EAAE,CAAC,CAAC;QAC1D,CAAC;IACH,CAAC;IAED;;OAEG;IACK,oBAAoB,CAAC,QAAgB;QAC3C,IAAI,CAAC,QAAQ,EAAE,CAAC;YACd,MAAM,IAAI,KAAK,CAAC,gCAAgC,CAAC,CAAC;QACpD,CAAC;QAED,QAAQ,QAAQ,EAAE,CAAC;YACjB,KAAK,QAAQ;gBACX,OAAO,QAAQ,CAAC,UAAU,CAAC;YAC7B,KAAK,QAAQ;gBACX,OAAO,QAAQ,CAAC,MAAM,CAAC;YACzB,KAAK,UAAU;gBACb,OAAO,QAAQ,CAAC,SAAS,CAAC;YAC5B,KAAK,YAAY;gBACf,OAAO,QAAQ,CAAC,UAAU,CAAC;YAC7B;gBACE,MAAM,IAAI,KAAK,CAAC,mCAAmC,QAAQ,EAAE,CAAC,CAAC;QACnE,CAAC;IACH,CAAC;CACF;AAED,qBAAqB;AACrB,IAAI,oBAAoB,GAAwB,IAAI,CAAC;AAErD;;GAEG;AACH,MAAM,UAAU,eAAe;IAC7B,IAAI,CAAC,oBAAoB,EAAE,CAAC;QAC1B,oBAAoB,GAAG,IAAI,YAAY,EAAE,CAAC;IAC5C,CAAC;IACD,OAAO,oBAAoB,CAAC;AAC9B,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import { SandboxConfig } from '@fsscoding/fss-link-core';
|
|
7
|
-
import { Settings } from './settings.js';
|
|
8
|
-
interface SandboxCliArgs {
|
|
9
|
-
sandbox?: boolean | string;
|
|
10
|
-
sandboxImage?: string;
|
|
11
|
-
}
|
|
12
|
-
export declare function loadSandboxConfig(settings: Settings, argv: SandboxCliArgs): Promise<SandboxConfig | undefined>;
|
|
13
|
-
export {};
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2025 Google LLC
|
|
4
|
-
* SPDX-License-Identifier: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import commandExists from 'command-exists';
|
|
7
|
-
import * as os from 'node:os';
|
|
8
|
-
import { getPackageJson } from '../utils/package.js';
|
|
9
|
-
const VALID_SANDBOX_COMMANDS = [
|
|
10
|
-
'docker',
|
|
11
|
-
'podman',
|
|
12
|
-
'sandbox-exec',
|
|
13
|
-
];
|
|
14
|
-
function isSandboxCommand(value) {
|
|
15
|
-
return VALID_SANDBOX_COMMANDS.includes(value);
|
|
16
|
-
}
|
|
17
|
-
function getSandboxCommand(sandbox) {
|
|
18
|
-
// If the SANDBOX env var is set, we're already inside the sandbox.
|
|
19
|
-
if (process.env['SANDBOX']) {
|
|
20
|
-
return '';
|
|
21
|
-
}
|
|
22
|
-
// note environment variable takes precedence over argument (from command line or settings)
|
|
23
|
-
const environmentConfiguredSandbox = process.env['GEMINI_SANDBOX']?.toLowerCase().trim() ?? '';
|
|
24
|
-
sandbox =
|
|
25
|
-
environmentConfiguredSandbox?.length > 0
|
|
26
|
-
? environmentConfiguredSandbox
|
|
27
|
-
: sandbox;
|
|
28
|
-
if (sandbox === '1' || sandbox === 'true')
|
|
29
|
-
sandbox = true;
|
|
30
|
-
else if (sandbox === '0' || sandbox === 'false' || !sandbox)
|
|
31
|
-
sandbox = false;
|
|
32
|
-
if (sandbox === false) {
|
|
33
|
-
return '';
|
|
34
|
-
}
|
|
35
|
-
if (typeof sandbox === 'string' && sandbox) {
|
|
36
|
-
if (!isSandboxCommand(sandbox)) {
|
|
37
|
-
console.error(`ERROR: invalid sandbox command '${sandbox}'. Must be one of ${VALID_SANDBOX_COMMANDS.join(', ')}`);
|
|
38
|
-
process.exit(1);
|
|
39
|
-
}
|
|
40
|
-
// confirm that specified command exists
|
|
41
|
-
if (commandExists.sync(sandbox)) {
|
|
42
|
-
return sandbox;
|
|
43
|
-
}
|
|
44
|
-
console.error(`ERROR: missing sandbox command '${sandbox}' (from GEMINI_SANDBOX)`);
|
|
45
|
-
process.exit(1);
|
|
46
|
-
}
|
|
47
|
-
// look for seatbelt, docker, or podman, in that order
|
|
48
|
-
// for container-based sandboxing, require sandbox to be enabled explicitly
|
|
49
|
-
if (os.platform() === 'darwin' && commandExists.sync('sandbox-exec')) {
|
|
50
|
-
return 'sandbox-exec';
|
|
51
|
-
}
|
|
52
|
-
else if (commandExists.sync('docker') && sandbox === true) {
|
|
53
|
-
return 'docker';
|
|
54
|
-
}
|
|
55
|
-
else if (commandExists.sync('podman') && sandbox === true) {
|
|
56
|
-
return 'podman';
|
|
57
|
-
}
|
|
58
|
-
// throw an error if user requested sandbox but no command was found
|
|
59
|
-
if (sandbox === true) {
|
|
60
|
-
console.error('ERROR: GEMINI_SANDBOX is true but failed to determine command for sandbox; ' +
|
|
61
|
-
'install docker or podman or specify command in GEMINI_SANDBOX');
|
|
62
|
-
process.exit(1);
|
|
63
|
-
}
|
|
64
|
-
return '';
|
|
65
|
-
}
|
|
66
|
-
export async function loadSandboxConfig(settings, argv) {
|
|
67
|
-
const sandboxOption = argv.sandbox ?? settings.sandbox;
|
|
68
|
-
const command = getSandboxCommand(sandboxOption);
|
|
69
|
-
const packageJson = await getPackageJson();
|
|
70
|
-
const image = argv.sandboxImage ??
|
|
71
|
-
process.env['GEMINI_SANDBOX_IMAGE'] ??
|
|
72
|
-
packageJson?.config?.sandboxImageUri;
|
|
73
|
-
return command && image ? { command, image } : undefined;
|
|
74
|
-
}
|
|
75
|
-
//# sourceMappingURL=sandboxConfig.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sandboxConfig.js","sourceRoot":"","sources":["../../../src/config/sandboxConfig.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,OAA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