/** Slash-command parsing and completion candidates shared by the composer and help panel. */ import type { CommandDescriptor } from '@deepseek-ai/dsh-commands'; import { type MessageKey } from './i18n.ts'; import type { SkillRow } from './skills.ts'; /** One TUI-owned slash command: label plus its i18n description key. */ export interface LocalCommand { readonly label: string; readonly descriptionKey: MessageKey; } /** One source of truth for TUI-owned slash commands in completion and `/help`. */ export declare const LOCAL_COMMANDS: readonly LocalCommand[]; export declare const LOCAL_COMMAND_NAMES: ReadonlySet; /** TUI-local commands that reject trailing input instead of forwarding it as a prompt. */ export declare const BARE_LOCAL_COMMANDS: ReadonlySet; /** Split a slash line into the command name and any trailing input. */ export declare function slashNameAndArgs(text: string): { readonly name: string; readonly args: string; } | undefined; /** One completion candidate row. */ export interface CompletionCandidate { readonly label: string; readonly description: string; readonly origin: 'command' | 'skill' | 'mention'; } /** Wrap one completion-menu cursor step; an empty menu keeps the index at zero. */ export declare function stepCompletionIndex(index: number, delta: number, count: number): number; /** Merge local commands, registry descriptors, and skills using dispatch shadowing order. */ export declare function completionCandidates(value: string, descriptors: readonly CommandDescriptor[], skills: readonly SkillRow[]): readonly CompletionCandidate[];