feat: add image generation tool and WebUI mode

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Xubin Ren
2026-05-08 20:06:23 +08:00
committed by Xubin Ren
co-authored by Cursor
parent 3a2f47d720
commit e936ed48bd
45 changed files with 2979 additions and 89 deletions
+6
View File
@@ -7,6 +7,7 @@ import { ThreadComposer } from "@/components/thread/ThreadComposer";
import { resources } from "@/i18n";
const QUICK_ACTION_KEYS = ["plan", "analyze", "brainstorm", "code", "summarize", "more"];
const IMAGE_QUICK_ACTION_KEYS = ["icon", "sticker", "poster", "product", "portrait", "edit"];
describe("webui i18n", () => {
it("switches UI copy and document locale through the language switcher", async () => {
@@ -54,6 +55,11 @@ describe("webui i18n", () => {
expect(action.title).toBeTruthy();
expect(action.prompt).toBeTruthy();
}
for (const key of IMAGE_QUICK_ACTION_KEYS) {
const action = empty.imageQuickActions[key as keyof typeof empty.imageQuickActions];
expect(action.title).toBeTruthy();
expect(action.prompt).toBeTruthy();
}
}
});
});