import { CommandInfo } from "./sessionModel.mjs"; //#region src/web/lib/composerCompletion.d.ts /** * The composer's `/command`, `$skill` and `@file` completion, shared by the * cockpit and the phone so both offer the same items for the same draft. */ /** Bound the result set so searches and their scrollable list stay quick even in large workspaces. */ export declare const MAX_COMPLETION_ITEMS = 20; export type CompletionKind = 'command' | 'skill' | 'file'; export declare const TRIGGER_CHARS: Record; export interface CompletionItem { /** What replaces the trigger token when accepted. */ insert: string; label: string; detail?: string; } export interface CompletionTrigger { kind: CompletionKind; /** Index of the trigger character in the draft. */ start: number; query: string; } /** The /command, $skill or @file token the caret sits in, or null when there is none. */ export declare function triggerTokenAt(draft: string, caret: number): CompletionTrigger | null; /** The session's commands or skills whose shown name starts with the query, sorted. */ export declare function commandCompletions(commands: readonly CommandInfo[], kind: 'command' | 'skill', query: string): CompletionItem[]; /** * The hub's file search answer as completion items, after any references * plugins offer for files outside the workspace, such as `artifact:plan.md`. */ export declare function fileCompletions(files: readonly string[], owned?: readonly { path: string; detail?: string; }[]): CompletionItem[]; //#endregion //# sourceMappingURL=composerCompletion.d.mts.map