UNPKG

1.56 kBTypeScriptView Raw
1import Command from '../base';
2import { Op, Workflow } from '../types';
3interface SearchInputs {
4 filter: string;
5 apiOps: Op[];
6 localWorkflows: Workflow[];
7 selectedOpOrWorkflow: Op | Workflow;
8}
9export default class Search extends Command {
10 static description: string;
11 static args: {
12 name: string;
13 description: string;
14 }[];
15 static flags: {
16 help: import("@oclif/parser/lib/flags").IBooleanFlag<void>;
17 };
18 opsAndWorkflows: (Op | Workflow)[];
19 showSearchMessage: (inputs: Pick<SearchInputs, "filter">) => Pick<SearchInputs, "filter">;
20 getApiOps: (inputs: SearchInputs) => Promise<SearchInputs>;
21 getLocalWorkflows: (inputs: SearchInputs) => Promise<SearchInputs>;
22 _removeIfNameOrDescriptionDontContainQuery: (filter: string) => (workflow: Workflow) => boolean;
23 filterLocalWorkflows: (inputs: SearchInputs) => SearchInputs;
24 _removeIfLocalExists: (workflows: Workflow[]) => (apiOp: Op) => boolean;
25 resolveLocalAndApi: (inputs: SearchInputs) => SearchInputs;
26 checkData: (inputs: SearchInputs) => Promise<SearchInputs>;
27 selectOpOrWorkflowPrompt: (inputs: SearchInputs) => Promise<SearchInputs>;
28 showRunMessage: (inputs: SearchInputs) => SearchInputs;
29 sendAnalytics: (filter: string) => (inputs: SearchInputs) => void;
30 _autocompleteSearch: (_: Record<string, any>, input?: string) => Promise<{
31 value: Op | Workflow;
32 name: string;
33 }[]>;
34 private fuzzyFilterParams;
35 private _formatOpOrWorkflowName;
36 run(): Promise<void>;
37}
38export {};