@zgsm/costrict-cli 0.0.1 → 0.0.2
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/dist/index.js +1 -1
- package/dist/package.json +2 -2
- package/dist/src/commands/extensions/disable.js +1 -1
- package/dist/src/commands/extensions/disable.test.js +1 -1
- package/dist/src/commands/extensions/enable.js +1 -1
- package/dist/src/commands/extensions/enable.test.js +2 -2
- package/dist/src/commands/extensions/install.js +1 -1
- package/dist/src/commands/extensions/install.test.js +1 -1
- package/dist/src/commands/extensions/link.js +1 -1
- package/dist/src/commands/extensions/link.test.js +1 -1
- package/dist/src/commands/extensions/list.js +1 -1
- package/dist/src/commands/extensions/list.test.js +1 -1
- package/dist/src/commands/extensions/new.js +1 -1
- package/dist/src/commands/extensions/settings.js +1 -1
- package/dist/src/commands/extensions/uninstall.js +1 -1
- package/dist/src/commands/extensions/uninstall.test.js +1 -1
- package/dist/src/commands/extensions/update.js +1 -1
- package/dist/src/commands/extensions/update.test.js +1 -1
- package/dist/src/commands/extensions/utils.d.ts +1 -1
- package/dist/src/commands/extensions/utils.js +1 -1
- package/dist/src/commands/extensions/validate.js +1 -1
- package/dist/src/commands/extensions/validate.test.js +1 -1
- package/dist/src/commands/hooks/migrate.js +1 -1
- package/dist/src/commands/hooks/migrate.test.js +1 -1
- package/dist/src/commands/mcp/add.js +1 -1
- package/dist/src/commands/mcp/add.test.js +1 -1
- package/dist/src/commands/mcp/list.js +1 -1
- package/dist/src/commands/mcp/list.test.js +2 -2
- package/dist/src/commands/mcp/remove.js +1 -1
- package/dist/src/commands/mcp/remove.test.js +1 -1
- package/dist/src/config/auth.js +1 -1
- package/dist/src/config/auth.test.js +1 -1
- package/dist/src/config/config.d.ts +1 -1
- package/dist/src/config/config.integration.test.js +3 -3
- package/dist/src/config/config.js +1 -1
- package/dist/src/config/config.test.js +4 -4
- package/dist/src/config/extension-manager.d.ts +1 -1
- package/dist/src/config/extension-manager.js +1 -1
- package/dist/src/config/extension.d.ts +1 -1
- package/dist/src/config/extension.test.js +2 -2
- package/dist/src/config/extensions/consent.js +1 -1
- package/dist/src/config/extensions/consent.test.js +2 -2
- package/dist/src/config/extensions/extensionEnablement.d.ts +1 -1
- package/dist/src/config/extensions/extensionEnablement.js +1 -1
- package/dist/src/config/extensions/extensionEnablement.test.js +1 -1
- package/dist/src/config/extensions/extensionSettings.js +1 -1
- package/dist/src/config/extensions/extensionSettings.test.js +2 -2
- package/dist/src/config/extensions/github.d.ts +1 -1
- package/dist/src/config/extensions/github.js +1 -1
- package/dist/src/config/extensions/github.test.js +1 -1
- package/dist/src/config/extensions/storage.js +1 -1
- package/dist/src/config/extensions/storage.test.js +2 -2
- package/dist/src/config/extensions/update.d.ts +1 -1
- package/dist/src/config/extensions/update.js +1 -1
- package/dist/src/config/extensions/variables.js +1 -1
- package/dist/src/config/policy-engine.integration.test.js +1 -1
- package/dist/src/config/policy.d.ts +1 -1
- package/dist/src/config/policy.js +1 -1
- package/dist/src/config/sandboxConfig.d.ts +1 -1
- package/dist/src/config/sandboxConfig.js +1 -1
- package/dist/src/config/sandboxConfig.test.js +2 -2
- package/dist/src/config/settings.js +1 -1
- package/dist/src/config/settings.test.js +2 -2
- package/dist/src/config/settingsSchema.d.ts +3 -3
- package/dist/src/config/settingsSchema.js +1 -1
- package/dist/src/config/settings_repro.test.js +1 -1
- package/dist/src/config/trustedFolders.js +1 -1
- package/dist/src/config/trustedFolders.test.js +1 -1
- package/dist/src/core/auth.d.ts +1 -1
- package/dist/src/core/auth.js +1 -1
- package/dist/src/core/auth.test.js +2 -2
- package/dist/src/core/initializer.d.ts +1 -1
- package/dist/src/core/initializer.js +1 -1
- package/dist/src/core/initializer.test.js +2 -2
- package/dist/src/gemini.d.ts +1 -1
- package/dist/src/gemini.js +1 -1
- package/dist/src/gemini.test.js +7 -7
- package/dist/src/gemini_cleanup.test.js +3 -3
- package/dist/src/generated/git-commit.d.ts +2 -2
- package/dist/src/generated/git-commit.js +2 -2
- package/dist/src/generated/git-commit.js.map +1 -1
- package/dist/src/nonInteractiveCli.d.ts +1 -1
- package/dist/src/nonInteractiveCli.js +1 -1
- package/dist/src/nonInteractiveCli.test.js +3 -3
- package/dist/src/nonInteractiveCliCommands.d.ts +1 -1
- package/dist/src/nonInteractiveCliCommands.js +1 -1
- package/dist/src/services/BuiltinCommandLoader.d.ts +1 -1
- package/dist/src/services/BuiltinCommandLoader.js +1 -1
- package/dist/src/services/CommandService.js +1 -1
- package/dist/src/services/CommandService.test.js +1 -1
- package/dist/src/services/FileCommandLoader.d.ts +1 -1
- package/dist/src/services/FileCommandLoader.js +1 -1
- package/dist/src/services/FileCommandLoader.test.js +2 -2
- package/dist/src/services/McpPromptLoader.d.ts +1 -1
- package/dist/src/services/McpPromptLoader.js +1 -1
- package/dist/src/services/McpPromptLoader.test.js +1 -1
- package/dist/src/services/prompt-processors/argumentProcessor.js +1 -1
- package/dist/src/services/prompt-processors/atFileProcessor.js +1 -1
- package/dist/src/services/prompt-processors/atFileProcessor.test.js +1 -1
- package/dist/src/services/prompt-processors/shellProcessor.js +1 -1
- package/dist/src/services/prompt-processors/shellProcessor.test.js +2 -2
- package/dist/src/test-utils/createExtension.d.ts +1 -1
- package/dist/src/test-utils/createExtension.js +1 -1
- package/dist/src/test-utils/render.d.ts +1 -1
- package/dist/src/test-utils/render.js +1 -1
- package/dist/src/ui/App.test.js +1 -1
- package/dist/src/ui/AppContainer.d.ts +1 -1
- package/dist/src/ui/AppContainer.js +1 -1
- package/dist/src/ui/AppContainer.test.js +3 -3
- package/dist/src/ui/IdeIntegrationNudge.d.ts +1 -1
- package/dist/src/ui/auth/ApiAuthDialog.js +1 -1
- package/dist/src/ui/auth/ApiAuthDialog.test.js +2 -2
- package/dist/src/ui/auth/AuthDialog.d.ts +1 -1
- package/dist/src/ui/auth/AuthDialog.js +1 -1
- package/dist/src/ui/auth/AuthDialog.test.js +2 -2
- package/dist/src/ui/auth/useAuth.d.ts +1 -1
- package/dist/src/ui/auth/useAuth.js +2 -2
- package/dist/src/ui/auth/useAuth.test.js +2 -2
- package/dist/src/ui/commands/aboutCommand.js +1 -1
- package/dist/src/ui/commands/aboutCommand.test.js +2 -2
- package/dist/src/ui/commands/bugCommand.js +1 -1
- package/dist/src/ui/commands/bugCommand.test.js +2 -2
- package/dist/src/ui/commands/chatCommand.js +1 -1
- package/dist/src/ui/commands/chatCommand.test.js +1 -1
- package/dist/src/ui/commands/clearCommand.js +1 -1
- package/dist/src/ui/commands/clearCommand.test.js +3 -3
- package/dist/src/ui/commands/compressCommand.test.js +1 -1
- package/dist/src/ui/commands/copyCommand.js +1 -1
- package/dist/src/ui/commands/directoryCommand.js +1 -1
- package/dist/src/ui/commands/extensionsCommand.js +1 -1
- package/dist/src/ui/commands/hooksCommand.js +1 -1
- package/dist/src/ui/commands/hooksCommand.test.js +1 -1
- package/dist/src/ui/commands/ideCommand.js +2 -2
- package/dist/src/ui/commands/ideCommand.test.js +3 -3
- package/dist/src/ui/commands/initCommand.js +1 -1
- package/dist/src/ui/commands/mcpCommand.js +2 -2
- package/dist/src/ui/commands/mcpCommand.test.js +2 -2
- package/dist/src/ui/commands/memoryCommand.js +1 -1
- package/dist/src/ui/commands/memoryCommand.test.js +2 -2
- package/dist/src/ui/commands/policiesCommand.test.js +1 -1
- package/dist/src/ui/commands/restoreCommand.d.ts +1 -1
- package/dist/src/ui/commands/restoreCommand.js +1 -1
- package/dist/src/ui/commands/restoreCommand.test.js +1 -1
- package/dist/src/ui/commands/setupGithubCommand.js +1 -1
- package/dist/src/ui/commands/setupGithubCommand.test.js +1 -1
- package/dist/src/ui/commands/statsCommand.js +1 -1
- package/dist/src/ui/commands/terminalSetupCommand.js +1 -1
- package/dist/src/ui/commands/types.d.ts +1 -1
- package/dist/src/ui/components/AlternateBufferQuittingDisplay.test.js +1 -1
- package/dist/src/ui/components/AnsiOutput.d.ts +1 -1
- package/dist/src/ui/components/AppHeader.test.js +1 -1
- package/dist/src/ui/components/AutoAcceptIndicator.d.ts +1 -1
- package/dist/src/ui/components/AutoAcceptIndicator.js +1 -1
- package/dist/src/ui/components/AutoAcceptIndicator.test.js +1 -1
- package/dist/src/ui/components/Composer.js +1 -1
- package/dist/src/ui/components/Composer.test.js +1 -1
- package/dist/src/ui/components/ConfigInitDisplay.js +1 -1
- package/dist/src/ui/components/ConfigInitDisplay.test.js +1 -1
- package/dist/src/ui/components/ContextSummaryDisplay.d.ts +1 -1
- package/dist/src/ui/components/ContextSummaryDisplay.js +1 -1
- package/dist/src/ui/components/ContextUsageDisplay.js +1 -1
- package/dist/src/ui/components/ContextUsageDisplay.test.js +1 -1
- package/dist/src/ui/components/DebugProfiler.js +1 -1
- package/dist/src/ui/components/DialogManager.test.js +1 -1
- package/dist/src/ui/components/EditorSettingsDialog.d.ts +1 -1
- package/dist/src/ui/components/EditorSettingsDialog.js +1 -1
- package/dist/src/ui/components/EditorSettingsDialog.test.js +1 -1
- package/dist/src/ui/components/FolderTrustDialog.js +1 -1
- package/dist/src/ui/components/FolderTrustDialog.test.js +1 -1
- package/dist/src/ui/components/Footer.js +1 -1
- package/dist/src/ui/components/Footer.test.js +2 -2
- package/dist/src/ui/components/HistoryItemDisplay.js +1 -1
- package/dist/src/ui/components/InputPrompt.d.ts +2 -2
- package/dist/src/ui/components/InputPrompt.js +1 -1
- package/dist/src/ui/components/InputPrompt.test.js +1 -1
- package/dist/src/ui/components/LoadingIndicator.d.ts +1 -1
- package/dist/src/ui/components/ModelDialog.js +1 -1
- package/dist/src/ui/components/ModelDialog.test.js +1 -1
- package/dist/src/ui/components/ModelStatsDisplay.test.js +1 -1
- package/dist/src/ui/components/MultiFolderTrustDialog.d.ts +1 -1
- package/dist/src/ui/components/Notifications.js +1 -1
- package/dist/src/ui/components/Notifications.test.js +1 -1
- package/dist/src/ui/components/ProQuotaDialog.d.ts +1 -1
- package/dist/src/ui/components/ProQuotaDialog.js +1 -1
- package/dist/src/ui/components/ProQuotaDialog.test.js +1 -1
- package/dist/src/ui/components/SessionBrowser.d.ts +1 -1
- package/dist/src/ui/components/SessionSummaryDisplay.test.js +1 -1
- package/dist/src/ui/components/SettingsDialog.d.ts +1 -1
- package/dist/src/ui/components/SettingsDialog.js +1 -1
- package/dist/src/ui/components/ShellConfirmationDialog.d.ts +1 -1
- package/dist/src/ui/components/ShellConfirmationDialog.js +1 -1
- package/dist/src/ui/components/ShellInputPrompt.js +1 -1
- package/dist/src/ui/components/ShellInputPrompt.test.js +3 -3
- package/dist/src/ui/components/StatsDisplay.d.ts +1 -1
- package/dist/src/ui/components/StatsDisplay.js +1 -1
- package/dist/src/ui/components/StatsDisplay.test.js +1 -1
- package/dist/src/ui/components/Tips.d.ts +1 -1
- package/dist/src/ui/components/Tips.js +1 -1
- package/dist/src/ui/components/ToolStatsDisplay.test.js +1 -1
- package/dist/src/ui/components/messages/CompressionMessage.js +1 -1
- package/dist/src/ui/components/messages/CompressionMessage.test.js +1 -1
- package/dist/src/ui/components/messages/ShellToolMessage.d.ts +1 -1
- package/dist/src/ui/components/messages/ShellToolMessage.js +1 -1
- package/dist/src/ui/components/messages/ShellToolMessage.test.js +1 -1
- package/dist/src/ui/components/messages/Todo.js +1 -1
- package/dist/src/ui/components/messages/ToolConfirmationMessage.d.ts +1 -1
- package/dist/src/ui/components/messages/ToolConfirmationMessage.js +1 -1
- package/dist/src/ui/components/messages/ToolGroupMessage.js +1 -1
- package/dist/src/ui/components/messages/ToolMessage.d.ts +1 -1
- package/dist/src/ui/components/messages/ToolShared.js +1 -1
- package/dist/src/ui/components/shared/text-buffer.js +1 -1
- package/dist/src/ui/components/views/ExtensionsList.d.ts +1 -1
- package/dist/src/ui/components/views/ExtensionsList.js +1 -1
- package/dist/src/ui/components/views/McpStatus.d.ts +2 -2
- package/dist/src/ui/components/views/McpStatus.js +1 -1
- package/dist/src/ui/components/views/McpStatus.test.js +2 -2
- package/dist/src/ui/contexts/ConfigContext.d.ts +1 -1
- package/dist/src/ui/contexts/ConfigContext.js +1 -1
- package/dist/src/ui/contexts/KeypressContext.d.ts +1 -1
- package/dist/src/ui/contexts/KeypressContext.js +1 -1
- package/dist/src/ui/contexts/KeypressContext.test.js +1 -1
- package/dist/src/ui/contexts/MouseContext.js +1 -1
- package/dist/src/ui/contexts/SessionContext.d.ts +1 -1
- package/dist/src/ui/contexts/SessionContext.js +1 -1
- package/dist/src/ui/contexts/SessionContext.test.js +1 -1
- package/dist/src/ui/contexts/UIActionsContext.d.ts +1 -1
- package/dist/src/ui/contexts/UIActionsContext.js +1 -1
- package/dist/src/ui/contexts/UIStateContext.d.ts +1 -1
- package/dist/src/ui/editors/editorSettingsManager.d.ts +1 -1
- package/dist/src/ui/editors/editorSettingsManager.js +1 -1
- package/dist/src/ui/hooks/atCommandProcessor.d.ts +1 -1
- package/dist/src/ui/hooks/atCommandProcessor.js +1 -1
- package/dist/src/ui/hooks/atCommandProcessor.test.js +2 -2
- package/dist/src/ui/hooks/shellCommandProcessor.d.ts +1 -1
- package/dist/src/ui/hooks/shellCommandProcessor.js +1 -1
- package/dist/src/ui/hooks/shellCommandProcessor.test.js +2 -2
- package/dist/src/ui/hooks/slashCommandProcessor.d.ts +2 -2
- package/dist/src/ui/hooks/slashCommandProcessor.js +1 -1
- package/dist/src/ui/hooks/slashCommandProcessor.test.js +2 -2
- package/dist/src/ui/hooks/useAtCompletion.d.ts +1 -1
- package/dist/src/ui/hooks/useAtCompletion.js +1 -1
- package/dist/src/ui/hooks/useAtCompletion.test.js +1 -1
- package/dist/src/ui/hooks/useAutoAcceptIndicator.d.ts +1 -1
- package/dist/src/ui/hooks/useAutoAcceptIndicator.js +1 -1
- package/dist/src/ui/hooks/useAutoAcceptIndicator.test.js +3 -3
- package/dist/src/ui/hooks/useBanner.d.ts +1 -1
- package/dist/src/ui/hooks/useCommandCompletion.d.ts +1 -1
- package/dist/src/ui/hooks/useConsoleMessages.js +1 -1
- package/dist/src/ui/hooks/useConsoleMessages.test.js +2 -2
- package/dist/src/ui/hooks/useEditorSettings.d.ts +1 -1
- package/dist/src/ui/hooks/useEditorSettings.js +1 -1
- package/dist/src/ui/hooks/useEditorSettings.test.js +3 -3
- package/dist/src/ui/hooks/useExtensionUpdates.js +1 -1
- package/dist/src/ui/hooks/useExtensionUpdates.test.js +1 -1
- package/dist/src/ui/hooks/useFlickerDetector.js +1 -1
- package/dist/src/ui/hooks/useFlickerDetector.test.js +3 -3
- package/dist/src/ui/hooks/useFolderTrust.js +1 -1
- package/dist/src/ui/hooks/useFolderTrust.test.js +1 -1
- package/dist/src/ui/hooks/useGeminiStream.d.ts +2 -2
- package/dist/src/ui/hooks/useGeminiStream.js +1 -1
- package/dist/src/ui/hooks/useGeminiStream.test.js +2 -2
- package/dist/src/ui/hooks/useGitBranchName.js +1 -1
- package/dist/src/ui/hooks/useGitBranchName.test.js +4 -4
- package/dist/src/ui/hooks/useHistoryManager.d.ts +1 -1
- package/dist/src/ui/hooks/useIdeTrustListener.js +1 -1
- package/dist/src/ui/hooks/useIdeTrustListener.test.js +2 -2
- package/dist/src/ui/hooks/useIncludeDirsTrust.d.ts +1 -1
- package/dist/src/ui/hooks/useIncludeDirsTrust.js +1 -1
- package/dist/src/ui/hooks/useInputHistoryStore.js +1 -1
- package/dist/src/ui/hooks/useInputHistoryStore.test.js +1 -1
- package/dist/src/ui/hooks/useLogger.d.ts +2 -2
- package/dist/src/ui/hooks/useLogger.js +1 -1
- package/dist/src/ui/hooks/usePermissionsModifyTrust.js +1 -1
- package/dist/src/ui/hooks/usePermissionsModifyTrust.test.js +1 -1
- package/dist/src/ui/hooks/usePrivacySettings.d.ts +1 -1
- package/dist/src/ui/hooks/usePrivacySettings.js +1 -1
- package/dist/src/ui/hooks/usePrivacySettings.test.js +2 -2
- package/dist/src/ui/hooks/usePromptCompletion.d.ts +1 -1
- package/dist/src/ui/hooks/usePromptCompletion.js +1 -1
- package/dist/src/ui/hooks/useQuotaAndFallback.d.ts +1 -1
- package/dist/src/ui/hooks/useQuotaAndFallback.js +1 -1
- package/dist/src/ui/hooks/useQuotaAndFallback.test.js +1 -1
- package/dist/src/ui/hooks/useReactToolScheduler.d.ts +1 -1
- package/dist/src/ui/hooks/useReactToolScheduler.js +1 -1
- package/dist/src/ui/hooks/useReactToolScheduler.test.js +2 -2
- package/dist/src/ui/hooks/useSessionBrowser.d.ts +1 -1
- package/dist/src/ui/hooks/useSessionBrowser.js +1 -1
- package/dist/src/ui/hooks/useSessionResume.d.ts +1 -1
- package/dist/src/ui/hooks/useShellHistory.d.ts +1 -1
- package/dist/src/ui/hooks/useShellHistory.js +1 -1
- package/dist/src/ui/hooks/useShellHistory.test.js +2 -2
- package/dist/src/ui/hooks/useShowMemoryCommand.d.ts +1 -1
- package/dist/src/ui/hooks/useShowMemoryCommand.js +1 -1
- package/dist/src/ui/hooks/useSlashCompletion.js +1 -1
- package/dist/src/ui/hooks/useToolScheduler.test.js +4 -4
- package/dist/src/ui/hooks/vim.js +1 -1
- package/dist/src/ui/privacy/CloudFreePrivacyNotice.d.ts +1 -1
- package/dist/src/ui/privacy/PrivacyNotice.d.ts +1 -1
- package/dist/src/ui/privacy/PrivacyNotice.js +1 -1
- package/dist/src/ui/themes/color-utils.js +1 -1
- package/dist/src/ui/themes/theme-manager.js +1 -1
- package/dist/src/ui/themes/theme-manager.test.js +1 -1
- package/dist/src/ui/types.d.ts +1 -1
- package/dist/src/ui/utils/CodeColorizer.js +1 -1
- package/dist/src/ui/utils/bracketedPaste.js +1 -1
- package/dist/src/ui/utils/clipboardUtils.js +1 -1
- package/dist/src/ui/utils/commandUtils.js +1 -1
- package/dist/src/ui/utils/directoryUtils.test.js +1 -1
- package/dist/src/ui/utils/kittyProtocolDetector.js +1 -1
- package/dist/src/ui/utils/kittyProtocolDetector.test.js +1 -1
- package/dist/src/ui/utils/mouse.d.ts +1 -1
- package/dist/src/ui/utils/mouse.js +1 -1
- package/dist/src/ui/utils/terminalSetup.js +1 -1
- package/dist/src/ui/utils/updateCheck.js +1 -1
- package/dist/src/ui/utils/updateCheck.test.js +1 -1
- package/dist/src/utils/cleanup.d.ts +1 -1
- package/dist/src/utils/cleanup.js +1 -1
- package/dist/src/utils/cleanup.test.js +1 -1
- package/dist/src/utils/commentJson.js +1 -1
- package/dist/src/utils/commentJson.test.js +2 -2
- package/dist/src/utils/errors.d.ts +1 -1
- package/dist/src/utils/errors.js +1 -1
- package/dist/src/utils/errors.test.js +2 -2
- package/dist/src/utils/events.d.ts +1 -1
- package/dist/src/utils/gitUtils.js +1 -1
- package/dist/src/utils/installationInfo.js +1 -1
- package/dist/src/utils/installationInfo.test.js +2 -2
- package/dist/src/utils/persistentState.js +1 -1
- package/dist/src/utils/persistentState.test.js +2 -2
- package/dist/src/utils/readStdin.js +1 -1
- package/dist/src/utils/readStdin.test.js +2 -2
- package/dist/src/utils/sandbox.d.ts +1 -1
- package/dist/src/utils/sandbox.js +1 -1
- package/dist/src/utils/sandbox.test.js +2 -2
- package/dist/src/utils/sandboxUtils.js +1 -1
- package/dist/src/utils/sandboxUtils.test.js +1 -1
- package/dist/src/utils/sessionCleanup.d.ts +1 -1
- package/dist/src/utils/sessionCleanup.integration.test.js +1 -1
- package/dist/src/utils/sessionCleanup.js +1 -1
- package/dist/src/utils/sessionCleanup.test.js +1 -1
- package/dist/src/utils/sessionUtils.d.ts +1 -1
- package/dist/src/utils/sessionUtils.js +1 -1
- package/dist/src/utils/sessionUtils.test.js +1 -1
- package/dist/src/utils/sessions.d.ts +1 -1
- package/dist/src/utils/sessions.js +1 -1
- package/dist/src/utils/sessions.test.js +3 -3
- package/dist/src/utils/startupWarnings.js +1 -1
- package/dist/src/utils/startupWarnings.test.js +2 -2
- package/dist/src/validateNonInterActiveAuth.d.ts +2 -2
- package/dist/src/validateNonInterActiveAuth.js +1 -1
- package/dist/src/validateNonInterActiveAuth.test.js +1 -1
- package/dist/src/zed-integration/connection.js +1 -1
- package/dist/src/zed-integration/fileSystemService.d.ts +1 -1
- package/dist/src/zed-integration/schema.d.ts +940 -940
- package/dist/src/zed-integration/zedIntegration.d.ts +1 -1
- package/dist/src/zed-integration/zedIntegration.js +1 -1
- package/dist/src/zed-integration/zedIntegration.test.js +2 -2
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
|
@@ -17,7 +17,7 @@ vi.mock('../contexts/AppContext.js', () => ({
|
|
|
17
17
|
version: '0.10.0',
|
|
18
18
|
}),
|
|
19
19
|
}));
|
|
20
|
-
vi.mock('@
|
|
20
|
+
vi.mock('@zgsm/costrict-cli-core', async (importOriginal) => {
|
|
21
21
|
const actual = await importOriginal();
|
|
22
22
|
return {
|
|
23
23
|
...actual,
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import type { AnsiOutput } from '@
|
|
7
|
+
import type { AnsiOutput } from '@zgsm/costrict-cli-core';
|
|
8
8
|
interface AnsiOutputProps {
|
|
9
9
|
data: AnsiOutput;
|
|
10
10
|
availableTerminalHeight?: number;
|
|
@@ -7,7 +7,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { renderWithProviders } from '../../test-utils/render.js';
|
|
8
8
|
import { AppHeader } from './AppHeader.js';
|
|
9
9
|
import { describe, it, expect, vi, beforeEach } from 'vitest';
|
|
10
|
-
import { makeFakeConfig } from '@
|
|
10
|
+
import { makeFakeConfig } from '@zgsm/costrict-cli-core';
|
|
11
11
|
import crypto from 'node:crypto';
|
|
12
12
|
const persistentStateMock = vi.hoisted(() => ({
|
|
13
13
|
get: vi.fn(),
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import { ApprovalMode } from '@
|
|
7
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
8
8
|
interface AutoAcceptIndicatorProps {
|
|
9
9
|
approvalMode: ApprovalMode;
|
|
10
10
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
3
|
import { theme } from '../semantic-colors.js';
|
|
4
|
-
import { ApprovalMode } from '@
|
|
4
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
5
5
|
export const AutoAcceptIndicator = ({ approvalMode, }) => {
|
|
6
6
|
let textColor = '';
|
|
7
7
|
let textContent = '';
|
|
@@ -7,7 +7,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { render } from '../../test-utils/render.js';
|
|
8
8
|
import { AutoAcceptIndicator } from './AutoAcceptIndicator.js';
|
|
9
9
|
import { describe, it, expect } from 'vitest';
|
|
10
|
-
import { ApprovalMode } from '@
|
|
10
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
11
11
|
describe('AutoAcceptIndicator', () => {
|
|
12
12
|
it('renders correctly for AUTO_EDIT mode', () => {
|
|
13
13
|
const { lastFrame } = render(_jsx(AutoAcceptIndicator, { approvalMode: ApprovalMode.AUTO_EDIT }));
|
|
@@ -25,7 +25,7 @@ import { useVimMode } from '../contexts/VimModeContext.js';
|
|
|
25
25
|
import { useConfig } from '../contexts/ConfigContext.js';
|
|
26
26
|
import { useSettings } from '../contexts/SettingsContext.js';
|
|
27
27
|
import { useAlternateBuffer } from '../hooks/useAlternateBuffer.js';
|
|
28
|
-
import { ApprovalMode } from '@
|
|
28
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
29
29
|
import { StreamingState } from '../types.js';
|
|
30
30
|
import { ConfigInitDisplay } from '../components/ConfigInitDisplay.js';
|
|
31
31
|
import { TodoTray } from './messages/Todo.js';
|
|
@@ -19,7 +19,7 @@ vi.mock('../contexts/VimModeContext.js', () => ({
|
|
|
19
19
|
vimMode: 'NORMAL',
|
|
20
20
|
})),
|
|
21
21
|
}));
|
|
22
|
-
import { ApprovalMode } from '@
|
|
22
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
23
23
|
import { StreamingState } from '../types.js';
|
|
24
24
|
// Mock child components
|
|
25
25
|
vi.mock('./LoadingIndicator.js', () => ({
|
|
@@ -7,7 +7,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
7
7
|
import { useEffect, useState } from 'react';
|
|
8
8
|
import { AppEvent, appEvents } from './../../utils/events.js';
|
|
9
9
|
import { Box, Text } from 'ink';
|
|
10
|
-
import { MCPServerStatus } from '@
|
|
10
|
+
import { MCPServerStatus } from '@zgsm/costrict-cli-core';
|
|
11
11
|
import { GeminiSpinner } from './GeminiRespondingSpinner.js';
|
|
12
12
|
import { theme } from '../semantic-colors.js';
|
|
13
13
|
export const ConfigInitDisplay = () => {
|
|
@@ -10,7 +10,7 @@ import { waitFor } from '../../test-utils/async.js';
|
|
|
10
10
|
import { ConfigInitDisplay } from './ConfigInitDisplay.js';
|
|
11
11
|
import { describe, it, expect, vi, beforeEach, afterEach } from 'vitest';
|
|
12
12
|
import { AppEvent } from '../../utils/events.js';
|
|
13
|
-
import { MCPServerStatus } from '@
|
|
13
|
+
import { MCPServerStatus } from '@zgsm/costrict-cli-core';
|
|
14
14
|
import { Text } from 'ink';
|
|
15
15
|
// Mock GeminiSpinner
|
|
16
16
|
vi.mock('./GeminiRespondingSpinner.js', () => ({
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import { type IdeContext, type MCPServerConfig } from '@
|
|
7
|
+
import { type IdeContext, type MCPServerConfig } from '@zgsm/costrict-cli-core';
|
|
8
8
|
interface ContextSummaryDisplayProps {
|
|
9
9
|
geminiMdFileCount: number;
|
|
10
10
|
contextFileNames: string[];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
3
|
import { theme } from '../semantic-colors.js';
|
|
4
|
-
import {} from '@
|
|
4
|
+
import {} from '@zgsm/costrict-cli-core';
|
|
5
5
|
import { useTerminalSize } from '../hooks/useTerminalSize.js';
|
|
6
6
|
import { isNarrowWidth } from '../utils/isNarrowWidth.js';
|
|
7
7
|
export const ContextSummaryDisplay = ({ geminiMdFileCount, contextFileNames, mcpServers, blockedMcpServers, ideContext, }) => {
|
|
@@ -6,7 +6,7 @@ import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
6
6
|
*/
|
|
7
7
|
import { Text } from 'ink';
|
|
8
8
|
import { theme } from '../semantic-colors.js';
|
|
9
|
-
import { tokenLimit } from '@
|
|
9
|
+
import { tokenLimit } from '@zgsm/costrict-cli-core';
|
|
10
10
|
export const ContextUsageDisplay = ({ promptTokenCount, model, terminalWidth, }) => {
|
|
11
11
|
const percentage = promptTokenCount / tokenLimit(model);
|
|
12
12
|
const percentageLeft = ((1 - percentage) * 100).toFixed(0);
|
|
@@ -7,7 +7,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { render } from '../../test-utils/render.js';
|
|
8
8
|
import { ContextUsageDisplay } from './ContextUsageDisplay.js';
|
|
9
9
|
import { describe, it, expect, vi } from 'vitest';
|
|
10
|
-
vi.mock('@
|
|
10
|
+
vi.mock('@zgsm/costrict-cli-core', () => ({
|
|
11
11
|
tokenLimit: () => 10000,
|
|
12
12
|
}));
|
|
13
13
|
vi.mock('../../config/settings.js', () => ({
|
|
@@ -11,7 +11,7 @@ import { theme } from '../semantic-colors.js';
|
|
|
11
11
|
import { useUIState } from '../contexts/UIStateContext.js';
|
|
12
12
|
import { debugState } from '../debug.js';
|
|
13
13
|
import { appEvents, AppEvent } from '../../utils/events.js';
|
|
14
|
-
import { debugLogger } from '@
|
|
14
|
+
import { debugLogger } from '@zgsm/costrict-cli-core';
|
|
15
15
|
// Frames that render at least this far before or after an action are considered
|
|
16
16
|
// idle frames.
|
|
17
17
|
const MIN_TIME_FROM_ACTION_TO_BE_IDLE = 500;
|
|
@@ -10,7 +10,7 @@ import { describe, it, expect, vi } from 'vitest';
|
|
|
10
10
|
import { Text } from 'ink';
|
|
11
11
|
import {} from '../contexts/UIStateContext.js';
|
|
12
12
|
import {} from '../hooks/useIdeTrustListener.js';
|
|
13
|
-
import {} from '@
|
|
13
|
+
import {} from '@zgsm/costrict-cli-core';
|
|
14
14
|
import {} from '../types.js';
|
|
15
15
|
// Mock child components
|
|
16
16
|
vi.mock('../IdeIntegrationNudge.js', () => ({
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
7
|
import type { LoadableSettingScope, LoadedSettings } from '../../config/settings.js';
|
|
8
|
-
import { type EditorType } from '@
|
|
8
|
+
import { type EditorType } from '@zgsm/costrict-cli-core';
|
|
9
9
|
interface EditorDialogProps {
|
|
10
10
|
onSelect: (editorType: EditorType | undefined, scope: LoadableSettingScope) => void;
|
|
11
11
|
settings: LoadedSettings;
|
|
@@ -5,7 +5,7 @@ import { theme } from '../semantic-colors.js';
|
|
|
5
5
|
import { editorSettingsManager, } from '../editors/editorSettingsManager.js';
|
|
6
6
|
import { RadioButtonSelect } from './shared/RadioButtonSelect.js';
|
|
7
7
|
import { SettingScope } from '../../config/settings.js';
|
|
8
|
-
import { isEditorAvailable, EDITOR_DISPLAY_NAMES, } from '@
|
|
8
|
+
import { isEditorAvailable, EDITOR_DISPLAY_NAMES, } from '@zgsm/costrict-cli-core';
|
|
9
9
|
import { useKeypress } from '../hooks/useKeypress.js';
|
|
10
10
|
export function EditorSettingsDialog({ onSelect, settings, onExit, }) {
|
|
11
11
|
const [selectedScope, setSelectedScope] = useState(SettingScope.User);
|
|
@@ -11,7 +11,7 @@ import { SettingScope } from '../../config/settings.js';
|
|
|
11
11
|
import { KeypressProvider } from '../contexts/KeypressContext.js';
|
|
12
12
|
import { act } from 'react';
|
|
13
13
|
import { waitFor } from '../../test-utils/async.js';
|
|
14
|
-
vi.mock('@
|
|
14
|
+
vi.mock('@zgsm/costrict-cli-core', async (importOriginal) => {
|
|
15
15
|
const actual = await importOriginal();
|
|
16
16
|
return {
|
|
17
17
|
...actual,
|
|
@@ -13,7 +13,7 @@ import * as process from 'node:process';
|
|
|
13
13
|
import * as path from 'node:path';
|
|
14
14
|
import { relaunchApp } from '../../utils/processUtils.js';
|
|
15
15
|
import { runExitCleanup } from '../../utils/cleanup.js';
|
|
16
|
-
import { ExitCodes } from '@
|
|
16
|
+
import { ExitCodes } from '@zgsm/costrict-cli-core';
|
|
17
17
|
export var FolderTrustChoice;
|
|
18
18
|
(function (FolderTrustChoice) {
|
|
19
19
|
FolderTrustChoice["TRUST_FOLDER"] = "trust_folder";
|
|
@@ -9,7 +9,7 @@ import { waitFor } from '../../test-utils/async.js';
|
|
|
9
9
|
import { act } from 'react';
|
|
10
10
|
import { vi } from 'vitest';
|
|
11
11
|
import { FolderTrustDialog } from './FolderTrustDialog.js';
|
|
12
|
-
import { ExitCodes } from '@
|
|
12
|
+
import { ExitCodes } from '@zgsm/costrict-cli-core';
|
|
13
13
|
import * as processUtils from '../../utils/processUtils.js';
|
|
14
14
|
vi.mock('../../utils/processUtils.js', () => ({
|
|
15
15
|
relaunchApp: vi.fn(),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
3
|
import { theme } from '../semantic-colors.js';
|
|
4
|
-
import { shortenPath, tildeifyPath } from '@
|
|
4
|
+
import { shortenPath, tildeifyPath } from '@zgsm/costrict-cli-core';
|
|
5
5
|
import { ConsoleSummaryDisplay } from './ConsoleSummaryDisplay.js';
|
|
6
6
|
import process from 'node:process';
|
|
7
7
|
import { ThemedGradient } from './ThemedGradient.js';
|
|
@@ -7,8 +7,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { describe, it, expect, vi } from 'vitest';
|
|
8
8
|
import { renderWithProviders, createMockSettings, } from '../../test-utils/render.js';
|
|
9
9
|
import { Footer } from './Footer.js';
|
|
10
|
-
import { tildeifyPath, ToolCallDecision } from '@
|
|
11
|
-
vi.mock('@
|
|
10
|
+
import { tildeifyPath, ToolCallDecision } from '@zgsm/costrict-cli-core';
|
|
11
|
+
vi.mock('@zgsm/costrict-cli-core', async (importOriginal) => {
|
|
12
12
|
const original = await importOriginal();
|
|
13
13
|
return {
|
|
14
14
|
...original,
|
|
@@ -18,7 +18,7 @@ import { ToolStatsDisplay } from './ToolStatsDisplay.js';
|
|
|
18
18
|
import { SessionSummaryDisplay } from './SessionSummaryDisplay.js';
|
|
19
19
|
import { Help } from './Help.js';
|
|
20
20
|
import { ExtensionsList } from './views/ExtensionsList.js';
|
|
21
|
-
import { getMCPServerStatus } from '@
|
|
21
|
+
import { getMCPServerStatus } from '@zgsm/costrict-cli-core';
|
|
22
22
|
import { ToolsList } from './views/ToolsList.js';
|
|
23
23
|
import { McpStatus } from './views/McpStatus.js';
|
|
24
24
|
import { ChatList } from './views/ChatList.js';
|
|
@@ -7,8 +7,8 @@ import type React from 'react';
|
|
|
7
7
|
import type { TextBuffer } from './shared/text-buffer.js';
|
|
8
8
|
import type { Key } from '../hooks/useKeypress.js';
|
|
9
9
|
import type { CommandContext, SlashCommand } from '../commands/types.js';
|
|
10
|
-
import type { Config } from '@
|
|
11
|
-
import { ApprovalMode } from '@
|
|
10
|
+
import type { Config } from '@zgsm/costrict-cli-core';
|
|
11
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
12
12
|
import { StreamingState } from '../types.js';
|
|
13
13
|
/**
|
|
14
14
|
* Returns if the terminal can be trusted to handle paste events atomically
|
|
@@ -14,7 +14,7 @@ import { useReverseSearchCompletion } from '../hooks/useReverseSearchCompletion.
|
|
|
14
14
|
import { useCommandCompletion } from '../hooks/useCommandCompletion.js';
|
|
15
15
|
import { useKeypress } from '../hooks/useKeypress.js';
|
|
16
16
|
import { keyMatchers, Command } from '../keyMatchers.js';
|
|
17
|
-
import { ApprovalMode } from '@
|
|
17
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
18
18
|
import { parseInputForHighlighting, buildSegmentsForVisualSlice, } from '../utils/highlight.js';
|
|
19
19
|
import { useKittyKeyboardProtocol } from '../hooks/useKittyKeyboardProtocol.js';
|
|
20
20
|
import { clipboardHasImage, saveClipboardImage, cleanupOldClipboardImages, } from '../utils/clipboardUtils.js';
|
|
@@ -8,7 +8,7 @@ import { renderWithProviders } from '../../test-utils/render.js';
|
|
|
8
8
|
import { waitFor } from '../../test-utils/async.js';
|
|
9
9
|
import { act } from 'react';
|
|
10
10
|
import { InputPrompt } from './InputPrompt.js';
|
|
11
|
-
import { ApprovalMode } from '@
|
|
11
|
+
import { ApprovalMode } from '@zgsm/costrict-cli-core';
|
|
12
12
|
import * as path from 'node:path';
|
|
13
13
|
import { CommandKind } from '../commands/types.js';
|
|
14
14
|
import { describe, it, expect, beforeEach, vi, afterEach } from 'vitest';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Copyright 2025 Google LLC
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import type { ThoughtSummary } from '@
|
|
6
|
+
import type { ThoughtSummary } from '@zgsm/costrict-cli-core';
|
|
7
7
|
import type React from 'react';
|
|
8
8
|
interface LoadingIndicatorProps {
|
|
9
9
|
currentLoadingPhrase?: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useCallback, useContext, useMemo } from 'react';
|
|
3
3
|
import { Box, Text } from 'ink';
|
|
4
|
-
import { PREVIEW_GEMINI_MODEL, DEFAULT_GEMINI_MODEL, DEFAULT_GEMINI_FLASH_MODEL, DEFAULT_GEMINI_FLASH_LITE_MODEL, DEFAULT_GEMINI_MODEL_AUTO, GEMINI_MODEL_ALIAS_FLASH, GEMINI_MODEL_ALIAS_FLASH_LITE, GEMINI_MODEL_ALIAS_PRO, ModelSlashCommandEvent, logModelSlashCommand, AuthType, } from '@
|
|
4
|
+
import { PREVIEW_GEMINI_MODEL, DEFAULT_GEMINI_MODEL, DEFAULT_GEMINI_FLASH_MODEL, DEFAULT_GEMINI_FLASH_LITE_MODEL, DEFAULT_GEMINI_MODEL_AUTO, GEMINI_MODEL_ALIAS_FLASH, GEMINI_MODEL_ALIAS_FLASH_LITE, GEMINI_MODEL_ALIAS_PRO, ModelSlashCommandEvent, logModelSlashCommand, AuthType, } from '@zgsm/costrict-cli-core';
|
|
5
5
|
import { useKeypress } from '../hooks/useKeypress.js';
|
|
6
6
|
import { theme } from '../semantic-colors.js';
|
|
7
7
|
import { DescriptiveRadioButtonSelect } from './shared/DescriptiveRadioButtonSelect.js';
|
|
@@ -7,7 +7,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { render } from '../../test-utils/render.js';
|
|
8
8
|
import { cleanup } from 'ink-testing-library';
|
|
9
9
|
import { describe, it, expect, vi, beforeEach, afterEach } from 'vitest';
|
|
10
|
-
import { GEMINI_MODEL_ALIAS_FLASH_LITE, GEMINI_MODEL_ALIAS_FLASH, GEMINI_MODEL_ALIAS_PRO, DEFAULT_GEMINI_MODEL_AUTO, AuthType, } from '@
|
|
10
|
+
import { GEMINI_MODEL_ALIAS_FLASH_LITE, GEMINI_MODEL_ALIAS_FLASH, GEMINI_MODEL_ALIAS_PRO, DEFAULT_GEMINI_MODEL_AUTO, AuthType, } from '@zgsm/costrict-cli-core';
|
|
11
11
|
import { ModelDialog } from './ModelDialog.js';
|
|
12
12
|
import { useKeypress } from '../hooks/useKeypress.js';
|
|
13
13
|
import { DescriptiveRadioButtonSelect } from './shared/DescriptiveRadioButtonSelect.js';
|
|
@@ -8,7 +8,7 @@ import { render } from '../../test-utils/render.js';
|
|
|
8
8
|
import { describe, it, expect, vi, beforeAll, afterAll } from 'vitest';
|
|
9
9
|
import { ModelStatsDisplay } from './ModelStatsDisplay.js';
|
|
10
10
|
import * as SessionContext from '../contexts/SessionContext.js';
|
|
11
|
-
import { ToolCallDecision } from '@
|
|
11
|
+
import { ToolCallDecision } from '@zgsm/costrict-cli-core';
|
|
12
12
|
// Mock the context to provide controlled data for testing
|
|
13
13
|
vi.mock('../contexts/SessionContext.js', async (importOriginal) => {
|
|
14
14
|
const actual = await importOriginal();
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
7
|
import { type HistoryItem } from '../types.js';
|
|
8
|
-
import type { Config } from '@
|
|
8
|
+
import type { Config } from '@zgsm/costrict-cli-core';
|
|
9
9
|
export declare enum MultiFolderTrustChoice {
|
|
10
10
|
YES = 0,
|
|
11
11
|
YES_AND_REMEMBER = 1,
|
|
@@ -11,7 +11,7 @@ import { useUIState } from '../contexts/UIStateContext.js';
|
|
|
11
11
|
import { theme } from '../semantic-colors.js';
|
|
12
12
|
import { StreamingState } from '../types.js';
|
|
13
13
|
import { UpdateNotification } from './UpdateNotification.js';
|
|
14
|
-
import { GEMINI_DIR, Storage } from '@
|
|
14
|
+
import { GEMINI_DIR, Storage } from '@zgsm/costrict-cli-core';
|
|
15
15
|
import * as fs from 'node:fs/promises';
|
|
16
16
|
import os from 'node:os';
|
|
17
17
|
import path from 'node:path';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import { UserTierId } from '@
|
|
7
|
+
import { UserTierId } from '@zgsm/costrict-cli-core';
|
|
8
8
|
interface ProQuotaDialogProps {
|
|
9
9
|
failedModel: string;
|
|
10
10
|
fallbackModel: string;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
3
|
import { RadioButtonSelect } from './shared/RadioButtonSelect.js';
|
|
4
4
|
import { theme } from '../semantic-colors.js';
|
|
5
|
-
import { DEFAULT_GEMINI_FLASH_LITE_MODEL, DEFAULT_GEMINI_FLASH_MODEL, DEFAULT_GEMINI_MODEL, UserTierId, } from '@
|
|
5
|
+
import { DEFAULT_GEMINI_FLASH_LITE_MODEL, DEFAULT_GEMINI_FLASH_MODEL, DEFAULT_GEMINI_MODEL, UserTierId, } from '@zgsm/costrict-cli-core';
|
|
6
6
|
export function ProQuotaDialog({ failedModel, fallbackModel, message, isTerminalQuotaError, isModelNotFoundError, onChoice, userTier, }) {
|
|
7
7
|
// Use actual user tier if available; otherwise, default to FREE tier behavior (safe default)
|
|
8
8
|
const isPaidTier = userTier === UserTierId.LEGACY || userTier === UserTierId.STANDARD;
|
|
@@ -9,7 +9,7 @@ import { act } from 'react';
|
|
|
9
9
|
import { describe, it, expect, vi, beforeEach } from 'vitest';
|
|
10
10
|
import { ProQuotaDialog } from './ProQuotaDialog.js';
|
|
11
11
|
import { RadioButtonSelect } from './shared/RadioButtonSelect.js';
|
|
12
|
-
import { PREVIEW_GEMINI_MODEL, UserTierId, DEFAULT_GEMINI_FLASH_MODEL, } from '@
|
|
12
|
+
import { PREVIEW_GEMINI_MODEL, UserTierId, DEFAULT_GEMINI_FLASH_MODEL, } from '@zgsm/costrict-cli-core';
|
|
13
13
|
// Mock the child component to make it easier to test the parent
|
|
14
14
|
vi.mock('./shared/RadioButtonSelect.js', () => ({
|
|
15
15
|
RadioButtonSelect: vi.fn(),
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import type { Config } from '@
|
|
7
|
+
import type { Config } from '@zgsm/costrict-cli-core';
|
|
8
8
|
import type { SessionInfo } from '../../utils/sessionUtils.js';
|
|
9
9
|
/**
|
|
10
10
|
* Props for the main SessionBrowser component.
|
|
@@ -8,7 +8,7 @@ import { render } from '../../test-utils/render.js';
|
|
|
8
8
|
import { describe, it, expect, vi } from 'vitest';
|
|
9
9
|
import { SessionSummaryDisplay } from './SessionSummaryDisplay.js';
|
|
10
10
|
import * as SessionContext from '../contexts/SessionContext.js';
|
|
11
|
-
import { ToolCallDecision } from '@
|
|
11
|
+
import { ToolCallDecision } from '@zgsm/costrict-cli-core';
|
|
12
12
|
vi.mock('../contexts/SessionContext.js', async (importOriginal) => {
|
|
13
13
|
const actual = await importOriginal();
|
|
14
14
|
return {
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import type { LoadedSettings } from '../../config/settings.js';
|
|
8
8
|
import { SettingScope } from '../../config/settings.js';
|
|
9
|
-
import type { Config } from '@
|
|
9
|
+
import type { Config } from '@zgsm/costrict-cli-core';
|
|
10
10
|
interface SettingsDialogProps {
|
|
11
11
|
settings: LoadedSettings;
|
|
12
12
|
onSelect: (settingName: string | undefined, scope: SettingScope) => void;
|
|
@@ -17,7 +17,7 @@ import { useKeypress } from '../hooks/useKeypress.js';
|
|
|
17
17
|
import chalk from 'chalk';
|
|
18
18
|
import { cpSlice, cpLen, stripUnsafeCharacters } from '../utils/textUtils.js';
|
|
19
19
|
import { TOGGLE_TYPES, } from '../../config/settingsSchema.js';
|
|
20
|
-
import { debugLogger } from '@
|
|
20
|
+
import { debugLogger } from '@zgsm/costrict-cli-core';
|
|
21
21
|
import { keyMatchers, Command } from '../keyMatchers.js';
|
|
22
22
|
import { useUIState } from '../contexts/UIStateContext.js';
|
|
23
23
|
import { useTextBuffer } from './shared/text-buffer.js';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Copyright 2025 Google LLC
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import { ToolConfirmationOutcome } from '@
|
|
6
|
+
import { ToolConfirmationOutcome } from '@zgsm/costrict-cli-core';
|
|
7
7
|
import type React from 'react';
|
|
8
8
|
export interface ShellConfirmationRequest {
|
|
9
9
|
commands: string[];
|
|
@@ -4,7 +4,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
4
4
|
* Copyright 2025 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: Apache-2.0
|
|
6
6
|
*/
|
|
7
|
-
import { ToolConfirmationOutcome } from '@
|
|
7
|
+
import { ToolConfirmationOutcome } from '@zgsm/costrict-cli-core';
|
|
8
8
|
import { Box, Text } from 'ink';
|
|
9
9
|
import { theme } from '../semantic-colors.js';
|
|
10
10
|
import { RenderInline } from '../utils/InlineMarkdownRenderer.js';
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { useCallback } from 'react';
|
|
7
7
|
import { useKeypress } from '../hooks/useKeypress.js';
|
|
8
|
-
import { ShellExecutionService } from '@
|
|
8
|
+
import { ShellExecutionService } from '@zgsm/costrict-cli-core';
|
|
9
9
|
import { keyToAnsi } from '../hooks/keyToAnsi.js';
|
|
10
10
|
export const ShellInputPrompt = ({ activeShellPtyId, focus = true, }) => {
|
|
11
11
|
const handleShellInputSubmit = useCallback((input) => {
|
|
@@ -7,15 +7,15 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
7
7
|
import { render } from '../../test-utils/render.js';
|
|
8
8
|
import { ShellInputPrompt } from './ShellInputPrompt.js';
|
|
9
9
|
import { describe, it, expect, vi, beforeEach } from 'vitest';
|
|
10
|
-
import { ShellExecutionService } from '@
|
|
10
|
+
import { ShellExecutionService } from '@zgsm/costrict-cli-core';
|
|
11
11
|
// Mock useKeypress
|
|
12
12
|
const mockUseKeypress = vi.fn();
|
|
13
13
|
vi.mock('../hooks/useKeypress.js', () => ({
|
|
14
14
|
useKeypress: (handler, options) => mockUseKeypress(handler, options),
|
|
15
15
|
}));
|
|
16
16
|
// Mock ShellExecutionService
|
|
17
|
-
vi.mock('@
|
|
18
|
-
const actual = await vi.importActual('@
|
|
17
|
+
vi.mock('@zgsm/costrict-cli-core', async () => {
|
|
18
|
+
const actual = await vi.importActual('@zgsm/costrict-cli-core');
|
|
19
19
|
return {
|
|
20
20
|
...actual,
|
|
21
21
|
ShellExecutionService: {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import type React from 'react';
|
|
7
|
-
import { type RetrieveUserQuotaResponse } from '@
|
|
7
|
+
import { type RetrieveUserQuotaResponse } from '@zgsm/costrict-cli-core';
|
|
8
8
|
interface StatsDisplayProps {
|
|
9
9
|
duration: string;
|
|
10
10
|
title?: string;
|
|
@@ -6,7 +6,7 @@ import { formatDuration } from '../utils/formatters.js';
|
|
|
6
6
|
import { useSessionStats } from '../contexts/SessionContext.js';
|
|
7
7
|
import { getStatusColor, TOOL_SUCCESS_RATE_HIGH, TOOL_SUCCESS_RATE_MEDIUM, USER_AGREEMENT_RATE_HIGH, USER_AGREEMENT_RATE_MEDIUM, CACHE_EFFICIENCY_HIGH, CACHE_EFFICIENCY_MEDIUM, } from '../utils/displayUtils.js';
|
|
8
8
|
import { computeSessionStats } from '../utils/computeStats.js';
|
|
9
|
-
import { VALID_GEMINI_MODELS, } from '@
|
|
9
|
+
import { VALID_GEMINI_MODELS, } from '@zgsm/costrict-cli-core';
|
|
10
10
|
const StatRow = ({ title, children }) => (_jsxs(Box, { children: [_jsx(Box, { width: 28, children: _jsx(Text, { color: theme.text.link, children: title }) }), children] }));
|
|
11
11
|
const SubStatRow = ({ title, children }) => (_jsxs(Box, { paddingLeft: 2, children: [_jsx(Box, { width: 26, children: _jsxs(Text, { color: theme.text.secondary, children: ["\u00BB ", title] }) }), children] }));
|
|
12
12
|
const Section = ({ title, children }) => (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Text, { bold: true, color: theme.text.primary, children: title }), children] }));
|
|
@@ -8,7 +8,7 @@ import { render } from '../../test-utils/render.js';
|
|
|
8
8
|
import { describe, it, expect, vi } from 'vitest';
|
|
9
9
|
import { StatsDisplay } from './StatsDisplay.js';
|
|
10
10
|
import * as SessionContext from '../contexts/SessionContext.js';
|
|
11
|
-
import { ToolCallDecision, } from '@
|
|
11
|
+
import { ToolCallDecision, } from '@zgsm/costrict-cli-core';
|
|
12
12
|
// Mock the context to provide controlled data for testing
|
|
13
13
|
vi.mock('../contexts/SessionContext.js', async (importOriginal) => {
|
|
14
14
|
const actual = await importOriginal();
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
3
|
import { theme } from '../semantic-colors.js';
|
|
4
|
-
import {} from '@
|
|
4
|
+
import {} from '@zgsm/costrict-cli-core';
|
|
5
5
|
export const Tips = ({ config }) => {
|
|
6
6
|
const geminiMdFileCount = config.getGeminiMdFileCount();
|
|
7
7
|
return (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: theme.text.primary, children: "Tips for getting started:" }), _jsx(Text, { color: theme.text.primary, children: "1. Ask questions, edit files, or run commands." }), _jsx(Text, { color: theme.text.primary, children: "2. Be specific for the best results." }), geminiMdFileCount === 0 && (_jsxs(Text, { color: theme.text.primary, children: ["3. Create", ' ', _jsx(Text, { bold: true, color: theme.text.accent, children: "COSTRICT.md" }), ' ', "files to customize your interactions with CoStrict."] })), _jsxs(Text, { color: theme.text.primary, children: [geminiMdFileCount === 0 ? '4.' : '3.', ' ', _jsx(Text, { bold: true, color: theme.text.accent, children: "/help" }), ' ', "for more information."] })] }));
|
|
@@ -8,7 +8,7 @@ import { render } from '../../test-utils/render.js';
|
|
|
8
8
|
import { describe, it, expect, vi } from 'vitest';
|
|
9
9
|
import { ToolStatsDisplay } from './ToolStatsDisplay.js';
|
|
10
10
|
import * as SessionContext from '../contexts/SessionContext.js';
|
|
11
|
-
import { ToolCallDecision } from '@
|
|
11
|
+
import { ToolCallDecision } from '@zgsm/costrict-cli-core';
|
|
12
12
|
// Mock the context to provide controlled data for testing
|
|
13
13
|
vi.mock('../contexts/SessionContext.js', async (importOriginal) => {
|
|
14
14
|
const actual = await importOriginal();
|
|
@@ -8,7 +8,7 @@ import { Box, Text } from 'ink';
|
|
|
8
8
|
import { CliSpinner } from '../CliSpinner.js';
|
|
9
9
|
import { theme } from '../../semantic-colors.js';
|
|
10
10
|
import { SCREEN_READER_MODEL_PREFIX } from '../../textConstants.js';
|
|
11
|
-
import { CompressionStatus } from '@
|
|
11
|
+
import { CompressionStatus } from '@zgsm/costrict-cli-core';
|
|
12
12
|
/*
|
|
13
13
|
* Compression messages appear when the /compress command is run, and show a loading spinner
|
|
14
14
|
* while compression is in progress, followed up by some compression stats.
|
|
@@ -6,7 +6,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
6
6
|
*/
|
|
7
7
|
import { render } from '../../../test-utils/render.js';
|
|
8
8
|
import { CompressionMessage } from './CompressionMessage.js';
|
|
9
|
-
import { CompressionStatus } from '@
|
|
9
|
+
import { CompressionStatus } from '@zgsm/costrict-cli-core';
|
|
10
10
|
import { describe, it, expect } from 'vitest';
|
|
11
11
|
describe('<CompressionMessage />', () => {
|
|
12
12
|
const createCompressionProps = (overrides = {}) => ({
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import type { ToolMessageProps } from './ToolMessage.js';
|
|
8
|
-
import type { Config } from '@
|
|
8
|
+
import type { Config } from '@zgsm/costrict-cli-core';
|
|
9
9
|
export interface ShellToolMessageProps extends ToolMessageProps {
|
|
10
10
|
activeShellPtyId?: number | null;
|
|
11
11
|
embeddedShellFocused?: boolean;
|
|
@@ -11,7 +11,7 @@ import { ShellInputPrompt } from '../ShellInputPrompt.js';
|
|
|
11
11
|
import { StickyHeader } from '../StickyHeader.js';
|
|
12
12
|
import { SHELL_COMMAND_NAME, SHELL_NAME, SHELL_FOCUS_HINT_DELAY_MS, } from '../../constants.js';
|
|
13
13
|
import { theme } from '../../semantic-colors.js';
|
|
14
|
-
import { SHELL_TOOL_NAME } from '@
|
|
14
|
+
import { SHELL_TOOL_NAME } from '@zgsm/costrict-cli-core';
|
|
15
15
|
import { useUIActions } from '../../contexts/UIActionsContext.js';
|
|
16
16
|
import { useMouseClick } from '../../hooks/useMouseClick.js';
|
|
17
17
|
import { ToolResultDisplay } from './ToolResultDisplay.js';
|
|
@@ -11,7 +11,7 @@ import { Text } from 'ink';
|
|
|
11
11
|
import { renderWithProviders } from '../../../test-utils/render.js';
|
|
12
12
|
import { waitFor } from '../../../test-utils/async.js';
|
|
13
13
|
import { describe, it, expect, vi, beforeEach } from 'vitest';
|
|
14
|
-
import { SHELL_TOOL_NAME } from '@
|
|
14
|
+
import { SHELL_TOOL_NAME } from '@zgsm/costrict-cli-core';
|
|
15
15
|
import { SHELL_COMMAND_NAME } from '../../constants.js';
|
|
16
16
|
import { StreamingContext } from '../../contexts/StreamingContext.js';
|
|
17
17
|
vi.mock('../TerminalOutput.js', () => ({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
|
-
import {} from '@
|
|
3
|
+
import {} from '@zgsm/costrict-cli-core';
|
|
4
4
|
import { theme } from '../../semantic-colors.js';
|
|
5
5
|
import { useUIState } from '../../contexts/UIStateContext.js';
|
|
6
6
|
import { useMemo } from 'react';
|