feat(webui): add a compact composer workspace toolbar (#6256)

* feat(webui): add a compact composer workspace toolbar

* refactor(webui): simplify composer workspace access control

* feat(webui): add a draggable workspace access capsule

* refactor(webui): simplify composer permission controls

* fix(webui): align mobile workspace permissions and stabilize CI test
This commit is contained in:
chengyongru authored and GitHub committed 2026-10-23 21:09:21 +08:00
1 parent 0254bf1217
commit cf0a0276a7
34 files changed
+528 -267

No files matched your search

+4 -4
View File
@@ -1110,12 +1110,12 @@ describe("App layout", () => {
window.history.replaceState(null, "", "/#/chat/websocket%3Aexisting-chat");
render(<App />);
await waitFor(() => expect(connectSpy).toHaveBeenCalled());
// Wait for the existing chat's lazy composer before opening its sidebar menu.
await screen.findByRole("button", { name: "Workspace access mode: Full Access" });
const projectSection = screen.getByRole("region", { name: "selected-project" });
fireEvent.contextMenu(within(projectSection).getByRole("button", { name: "selected-project" }));
fireEvent.click(await screen.findByRole("menuitem", { name: "New topic" }));
expect(window.location.hash).toBe("#/new");
// Let queued browser navigation events settle before sending the first message.
await act(async () => { await new Promise((resolve) => setTimeout(resolve, 50)); });
await userEvent.setup().click(await screen.findByRole("menuitem", { name: "New topic" }));
await waitFor(() => expect(window.location.hash).toBe("#/new"));
expect(await screen.findByRole("button", { name: "Switch directory" })).toHaveTextContent("selected-project");
fireEvent.change(screen.getByLabelText("Message input"), {
target: { value: "project topic" },