From 95363a5b52f3bf73531ac76b00178fa79ca97661 Mon Sep 17 00:00:00 2001 From: Nate Sesti <33237525+sestinj@users.noreply.github.com> Date: Thu, 28 Sep 2023 01:02:52 -0700 Subject: Past input (#513) * feat: :construction: use ComboBox in place of UserInputContainer * feat: :construction: adding context to previous inputs steps * feat: :sparkles: preview context items on click * feat: :construction: more work on context items ui * style: :construction: working out the details of ctx item buttons * feat: :sparkles: getting the final details * fix: :bug: fix height of ctx items bar * fix: :bug: last couple of details * fix: :bug: pass model param through to hf inference api * fix: :loud_sound: better logging for timeout * feat: :sparkles: option to set the meilisearch url * fix: :bug: fix height of past inputs --- .../react-app/src/hooks/ContinueGUIClientProtocol.ts | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'extension/react-app/src/hooks/ContinueGUIClientProtocol.ts') diff --git a/extension/react-app/src/hooks/ContinueGUIClientProtocol.ts b/extension/react-app/src/hooks/ContinueGUIClientProtocol.ts index 8205a629..863b1031 100644 --- a/extension/react-app/src/hooks/ContinueGUIClientProtocol.ts +++ b/extension/react-app/src/hooks/ContinueGUIClientProtocol.ts @@ -101,9 +101,10 @@ class ContinueGUIClientProtocol extends AbstractContinueGUIClientProtocol { this.messenger?.send("delete_at_index", { index }); } - deleteContextWithIds(ids: ContextItemId[]) { + deleteContextWithIds(ids: ContextItemId[], index?: number) { this.messenger?.send("delete_context_with_ids", { ids: ids.map((id) => `${id.provider_title}-${id.item_id}`), + index, }); } @@ -119,14 +120,22 @@ class ContinueGUIClientProtocol extends AbstractContinueGUIClientProtocol { this.messenger?.send("show_logs_at_index", { index }); } - showContextVirtualFile(): void { - this.messenger?.send("show_context_virtual_file", {}); + showContextVirtualFile(index?: number): void { + this.messenger?.send("show_context_virtual_file", { index }); } selectContextItem(id: string, query: string): void { this.messenger?.send("select_context_item", { id, query }); } + selectContextItemAtIndex(id: string, query: string, index: number): void { + this.messenger?.send("select_context_item_at_index", { + id, + query, + index, + }); + } + editStepAtIndex(userInput: string, index: number): void { this.messenger?.send("edit_step_at_index", { user_input: userInput, -- cgit v1.2.3-70-g09d2