feat: show question icon only for pending input (#782)

* fix: show question icon only for pending input

* fix: address pending input review feedback

* fix: reduce pending input sidebar complexity

* fix: address clarification review comments

* test: cover pending clarification hook
This commit is contained in:
José Almeida
2026-05-02 23:01:21 +01:00
committed by GitHub
parent eee547d891
commit 32f098a6fc
15 changed files with 327 additions and 22 deletions
@@ -19,6 +19,7 @@ import { useTasks } from "@/hooks/use-tasks";
import { useTaskActions, useArchiveAndSwitchTask } from "@/hooks/use-task-actions";
import { useTaskRemoval } from "@/hooks/use-task-removal";
import { getSessionInfoForTask } from "@/lib/utils/session-info";
import { hasPendingClarificationForSession } from "@/lib/utils/pending-clarification";
import type {
TaskState,
TaskSessionState,
@@ -85,6 +86,7 @@ function useSheetData(workspaceId: string | null, workflowId: string | null) {
const sessionsByTaskId = useAppStore((state) => state.taskSessionsByTask.itemsByTaskId);
const gitStatusByEnvId = useAppStore((state) => state.gitStatus.byEnvironmentId);
const envIdBySessionId = useAppStore((state) => state.environmentIdBySessionId);
const messagesBySession = useAppStore((state) => state.messages.bySession);
const { tasks } = useTasks(workflowId);
const steps = useAppStore((state) => state.kanban.steps);
const workspaces = useAppStore((state) => state.workspaces.items);
@@ -123,6 +125,10 @@ function useSheetData(workspaceId: string | null, workflowId: string | null) {
remoteExecutorType: task.primaryExecutorType ?? undefined,
remoteExecutorName: task.primaryExecutorName ?? undefined,
primarySessionId: task.primarySessionId ?? null,
hasPendingClarification: hasPendingClarificationForSession(
messagesBySession,
task.primarySessionId,
),
};
});
}, [
@@ -132,6 +138,7 @@ function useSheetData(workspaceId: string | null, workflowId: string | null) {
sessionsByTaskId,
gitStatusByEnvId,
envIdBySessionId,
messagesBySession,
]);
const dialogSteps = useMemo(