Skip to content
Source
Sign inSign up
pingdotgg/t3code

feat(web): collapse the question prompt from its header #6773

MergedJardo-51(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/6773/headmerged by juliusmarminge View on GitHub

Showing 2 changed files with 61 additions and 0 deletions (loading 1).

x
0 of 2 viewed, 2 left
61 additions and 0 deletionsapps/web/src/components/chat/ComposerPendingUserInputPanel.test.tsxAdded
View file
@@ -0,0 +1,61 @@
+import { ApprovalRequestId } from "@t3tools/contracts";
+import { renderToStaticMarkup } from "react-dom/server";
+import { describe, expect, it } from "vite-plus/test";
+​
+import { ComposerPendingUserInputPanel } from "./ComposerPendingUserInputPanel";
+import type { PendingUserInput } from "../../session-logic";
+​
+const prompt: PendingUserInput = {
+ requestId: ApprovalRequestId.make("request-1"),
+ createdAt: "2026-08-15T00:00:00.000Z",
+ questions: [
+ {
+ id: "question-1",
+ header: "Approach",
+ question: "Which approach should the migration take?",
+ options: [
+ { label: "Incremental", description: "Move one module at a time" },
+ { label: "Big bang", description: "Move everything in one release" },
+ ],
+ multiSelect: false,
+ },
+ ],
+};
+​
+function renderPanel() {
+ return renderToStaticMarkup(
+ <ComposerPendingUserInputPanel
+ pendingUserInputs={[prompt]}
+ respondingRequestIds={[]}
+ answers={{}}