import type { ThinkingLevel } from "@caupulican/pi-agent-core"; import type { Transport } from "@caupulican/pi-ai"; import { Container, type SelectItem, SelectList, SettingsList } from "@caupulican/pi-tui"; import { type CostGuardSettings } from "../../../core/cost-guard.ts"; import type { AutoLearnSettings, AutonomySettings, ContextCurationSettings, ContextPromptEnforcementSettings, LearningPolicySettings, MemoryRetrievalSettings, ModelCapabilitySettings, ModelRouterSettings, ResearchLaneSettings, SelfModificationSettings, SettingsScope, WarningSettings, WorkerDelegationSettings } from "../../../core/settings-manager.ts"; export interface SettingsConfig { autoCompact: boolean; costGuard: CostGuardSettings; costGuardScope?: SettingsScope; showImages: boolean; imageWidthCells: number; autoResizeImages: boolean; blockImages: boolean; enableSkillCommands: boolean; steeringMode: "all" | "one-at-a-time"; followUpMode: "all" | "one-at-a-time"; transport: Transport; httpIdleTimeoutMs: number; thinkingLevel: ThinkingLevel; availableThinkingLevels: ThinkingLevel[]; currentTheme: string; availableThemes: string[]; hideThinkingBlock: boolean; projectContextFiles: "off" | "on-demand"; projectContextFilesScope?: SettingsScope; collapseChangelog: boolean; enableInstallTelemetry: boolean; doubleEscapeAction: "fork" | "tree" | "none"; treeFilterMode: "default" | "no-tools" | "user-only" | "labeled-only" | "all"; showHardwareCursor: boolean; editorPaddingX: number; autocompleteMaxVisible: number; quietStartup: boolean; clearOnShrink: boolean; showTerminalProgress: boolean; warnings: WarningSettings; selfModification: { enabled: boolean; sourcePath?: string; sourcePaths?: string[]; }; selfModificationScope?: SettingsScope; autonomy: AutonomySettings; autonomyScope?: SettingsScope; researchLane: ResearchLaneSettings; researchLaneScope?: SettingsScope; workerDelegation: WorkerDelegationSettings; contextCuration: ContextCurationSettings; contextCurationScope?: SettingsScope; learningPolicy: LearningPolicySettings; learningPolicyScope?: SettingsScope; modelCapability: ModelCapabilitySettings; modelCapabilityScope?: SettingsScope; workerDelegationScope?: SettingsScope; modelRouter: ModelRouterSettings; modelRouterScope?: SettingsScope; autoLearn: AutoLearnSettings; autoLearnScope?: SettingsScope; contextPolicyEnforcement: ContextPromptEnforcementSettings; contextPolicyEnforcementScope?: SettingsScope; contextMemoryRetrieval: MemoryRetrievalSettings; contextMemoryRetrievalScope?: SettingsScope; currentModelPattern?: string; autoLearnModelOptions?: SelectItem[]; /** Resolve the concrete thinking surface for a configured model pattern. */ resolveModelThinkingLevels?: (modelPattern: string | undefined) => ThinkingLevel[] | undefined; activeProfileName?: string; profileOptions?: SelectItem[]; externalResourceRoots?: string[]; trustedResourceRoots?: string[]; } export interface SettingsCallbacks { onAutoCompactChange: (enabled: boolean) => void; onCostGuardChange: (settings: CostGuardSettings, scope: SettingsScope) => void; onShowImagesChange: (enabled: boolean) => void; onImageWidthCellsChange: (width: number) => void; onAutoResizeImagesChange: (enabled: boolean) => void; onBlockImagesChange: (blocked: boolean) => void; onEnableSkillCommandsChange: (enabled: boolean) => void; onSteeringModeChange: (mode: "all" | "one-at-a-time") => void; onFollowUpModeChange: (mode: "all" | "one-at-a-time") => void; onTransportChange: (transport: Transport) => void; onHttpIdleTimeoutMsChange: (timeoutMs: number) => void; onThinkingLevelChange: (level: ThinkingLevel) => void; onThemeChange: (theme: string) => void; onThemePreview?: (theme: string) => void; onHideThinkingBlockChange: (hidden: boolean) => void; onProjectContextFilesChange: (mode: "off" | "on-demand", scope: SettingsScope) => void; onCollapseChangelogChange: (collapsed: boolean) => void; onEnableInstallTelemetryChange: (enabled: boolean) => void; onDoubleEscapeActionChange: (action: "fork" | "tree" | "none") => void; onTreeFilterModeChange: (mode: "default" | "no-tools" | "user-only" | "labeled-only" | "all") => void; onShowHardwareCursorChange: (enabled: boolean) => void; onEditorPaddingXChange: (padding: number) => void; onAutocompleteMaxVisibleChange: (maxVisible: number) => void; onQuietStartupChange: (enabled: boolean) => void; onClearOnShrinkChange: (enabled: boolean) => void; onShowTerminalProgressChange: (enabled: boolean) => void; onWarningsChange: (warnings: WarningSettings) => void; onSelfModificationChange: (settings: SelfModificationSettings, scope: SettingsScope) => void; onAutonomyChange: (settings: AutonomySettings, scope: SettingsScope) => void; onResearchLaneChange: (settings: ResearchLaneSettings, scope: SettingsScope) => void; onWorkerDelegationChange: (settings: WorkerDelegationSettings, scope: SettingsScope) => void; onContextCurationChange: (settings: ContextCurationSettings, scope: SettingsScope) => void; onLearningPolicyChange: (settings: LearningPolicySettings, scope: SettingsScope) => void; onModelCapabilityChange: (settings: ModelCapabilitySettings, scope: SettingsScope) => void; onModelRouterChange: (settings: ModelRouterSettings, scope: SettingsScope) => void; onAutoLearnChange: (settings: AutoLearnSettings, scope: SettingsScope) => void; onContextPolicyEnforcementChange: (settings: ContextPromptEnforcementSettings, scope: SettingsScope) => void; onContextMemoryRetrievalChange: (settings: MemoryRetrievalSettings, scope: SettingsScope) => void; onResourcesHubAction?: (action: string) => void; onCancel: () => void; } export declare class SelectSubmenu extends Container { private selectList; getSelectList(): SelectList; constructor(title: string, description: string, options: SelectItem[], currentValue: string, onSelect: (value: string) => void, onCancel: () => void, onSelectionChange?: (value: string) => void); handleInput(data: string): void; } /** * Main settings selector component. */ export declare class SettingsSelectorComponent extends Container { private settingsList; constructor(config: SettingsConfig, callbacks: SettingsCallbacks); getSettingsList(): SettingsList; } //# sourceMappingURL=settings-selector.d.ts.map