MCPcopy Create free account
hub / github.com/bombshell-dev/clack / AutocompleteOptions

Interface AutocompleteOptions

packages/core/src/prompts/autocomplete.ts:49–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47}
48
49export interface AutocompleteOptions<T extends OptionLike>
50 extends PromptOptions<T['value'] | T['value'][], AutocompletePrompt<T>> {
51 options: T[] | ((this: AutocompletePrompt<T>) => T[]);
52 filter?: FilterFunction<T>;
53 multiple?: boolean;
54 /**
55 * When set (non-empty), pressing Tab with no input fills the field with this value
56 * and runs the normal filter/selection logic so the user can confirm with Enter.
57 * Tab only fills the input when the placeholder matches at least one option under
58 * the prompt's filter (so the value remains selectable).
59 */
60 placeholder?: string;
61}
62
63export default class AutocompletePrompt<T extends OptionLike> extends Prompt<
64 T['value'] | T['value'][]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected