diff --git a/src/renderer/src/pages/ChatPage.tsx b/src/renderer/src/pages/ChatPage.tsx index 6975c4db..c764e025 100644 --- a/src/renderer/src/pages/ChatPage.tsx +++ b/src/renderer/src/pages/ChatPage.tsx @@ -3,7 +3,7 @@ import { Field } from "../shared/ui"; import { Dialog } from "../shared/Dialog"; import { ChatSidebar } from "./chat/ChatSidebar"; import { ChatConversation } from "./chat/ChatConversation"; -import { ChatThreadPanel } from "./chat/ChatThreadPanel"; +import { ChatThreadView } from "./chat/ChatThreadView"; import { buildConversations, collectParticipants, @@ -266,33 +266,8 @@ export function ChatPage({ snapshot, actions }: PageProps) { onCreateSpace={() => setCreateOpen(true)} /> - decideApproval(approvalId, "approved")} - onDecline={(approvalId) => decideApproval(approvalId, "declined")} - onEditMessage={editChatMessage} - onDeleteMessage={deleteChatMessage} - onOpenFile={openFile} - onSubmit={sendInChannel} - composerRef={composerRef} - /> - - {selectedThread && ( - m.id === selectedThread.rootMessageId) ?? null} messages={threadMessages} @@ -311,6 +286,31 @@ export function ChatPage({ snapshot, actions }: PageProps) { onBoardSubmit={sendBoardIntervention} onOpenFile={openFile} /> + ) : ( + decideApproval(approvalId, "approved")} + onDecline={(approvalId) => decideApproval(approvalId, "declined")} + onEditMessage={editChatMessage} + onDeleteMessage={deleteChatMessage} + onOpenFile={openFile} + onSubmit={sendInChannel} + composerRef={composerRef} + /> )} file.id === attachmentFileId) ?? null; return ( - + ); } @@ -168,7 +161,7 @@ function BoardControl({ const [action, setAction] = useState("decision"); if (!canIntervene && interventions.length === 0) return null; return ( -
+
Board
{boardStateLabel(thread.boardState)} diff --git a/tests/contract/desktop-release-contract.test.ts b/tests/contract/desktop-release-contract.test.ts index 9783ec18..42c3db62 100644 --- a/tests/contract/desktop-release-contract.test.ts +++ b/tests/contract/desktop-release-contract.test.ts @@ -64,8 +64,12 @@ describe("desktop release contract", () => { expect(topLevelValue(config, "asar")).toBe("true"); expect(directories).toContain("output: release"); expect(directories).toContain("buildResources: resources"); - expect(topLevelList(config, "files")).toEqual(["out/**/*", "package.json"]); + // resources/icon.png ships inside the package so windows can load it at + // runtime on Windows and Linux. + expect(topLevelList(config, "files")).toEqual(["out/**/*", "package.json", "resources/icon.png"]); expect(existsSync(join(projectRoot, "resources", "icon.png"))).toBe(true); + expect(existsSync(join(projectRoot, "resources", "icon.ico"))).toBe(true); + expect(existsSync(join(projectRoot, "resources", "icon-mac.png"))).toBe(true); expect(existsSync(join(projectRoot, "resources", "entitlements.mac.plist"))).toBe(true); }); diff --git a/tests/e2e/desktop.spec.ts b/tests/e2e/desktop.spec.ts index 7a897ec1..26bcb72a 100644 --- a/tests/e2e/desktop.spec.ts +++ b/tests/e2e/desktop.spec.ts @@ -101,8 +101,13 @@ test("onboards, hires, and creates work in the Electron shell", async () => { await page.getByRole("button", { name: "Send" }).click(); await expect(page.getByText("@Board").first()).toBeVisible(); await expect(page.getByText("/escalate").first()).toBeVisible(); + // Threads open in place: the center pane becomes the thread and the + // channel composer is gone until you go back. await page.getByRole("button", { name: "Open thread" }).first().click(); await expect(page.getByRole("textbox", { name: "Thread reply" })).toBeVisible(); + await expect(page.getByRole("textbox", { name: "Message" })).not.toBeVisible(); + await page.getByRole("button", { name: "Close thread" }).click(); + await expect(page.getByRole("textbox", { name: "Message" })).toBeVisible(); await page.getByRole("button", { name: "Approvals" }).click(); await expect(page.getByText("Escalate release").first()).toBeVisible();