summaryrefslogtreecommitdiff
path: root/extension/react-app/src/tabs
diff options
context:
space:
mode:
authorNate Sesti <sestinj@gmail.com>2023-07-11 14:13:14 -0700
committerNate Sesti <sestinj@gmail.com>2023-07-11 14:13:14 -0700
commit3fc16804fe74c38d4f94c25281025a84fd51771b (patch)
treebb506427dc5143139722bf7784b51ccafb187aa2 /extension/react-app/src/tabs
parentea76462f971d6d235baacbb85d6e9ae6fe09d7e0 (diff)
downloadsncontinue-3fc16804fe74c38d4f94c25281025a84fd51771b.tar.gz
sncontinue-3fc16804fe74c38d4f94c25281025a84fd51771b.tar.bz2
sncontinue-3fc16804fe74c38d4f94c25281025a84fd51771b.zip
little ui stuff
Diffstat (limited to 'extension/react-app/src/tabs')
-rw-r--r--extension/react-app/src/tabs/gui.tsx11
1 files changed, 3 insertions, 8 deletions
diff --git a/extension/react-app/src/tabs/gui.tsx b/extension/react-app/src/tabs/gui.tsx
index 0e60e05c..619b91e1 100644
--- a/extension/react-app/src/tabs/gui.tsx
+++ b/extension/react-app/src/tabs/gui.tsx
@@ -170,6 +170,7 @@ function GUI(props: GUIProps) {
const waitingForSteps =
state.active &&
state.history.current_index < state.history.timeline.length &&
+ state.history.timeline[state.history.current_index] &&
state.history.timeline[
state.history.current_index
].step.description?.trim() === "";
@@ -236,14 +237,14 @@ function GUI(props: GUIProps) {
history.current_index < history.timeline.length
) {
if (
- history.timeline[history.current_index].step.name ===
+ history.timeline[history.current_index]?.step.name ===
"Waiting for user input"
) {
if (input.trim() === "") return;
onStepUserInput(input, history!.current_index);
return;
} else if (
- history.timeline[history.current_index].step.name ===
+ history.timeline[history.current_index]?.step.name ===
"Waiting for user confirmation"
) {
onStepUserInput("ok", history!.current_index);
@@ -350,12 +351,6 @@ function GUI(props: GUIProps) {
</div>
<ComboBox
- // disabled={
- // history?.timeline.length
- // ? history.timeline[history.current_index].step.name ===
- // "Waiting for user confirmation"
- // : false
- // }
ref={mainTextInputRef}
onEnter={(e) => {
onMainTextInput(e);