feat(agents): 新增云端智能体入口与草稿编辑

This commit is contained in:
2026-09-10 16:00:37 +08:00
parent 927a85fa22
commit 46fbae9dec
21 changed files with 921 additions and 17 deletions

View File

@@ -81,7 +81,7 @@ test.describe('Makelore module navigation without setup flow', () => {
}
});
test('keeps the three module entries in a proportional vertical stack while resizing the window', async ({ launchElectronApp }) => {
test('keeps the four module entries in a proportional vertical stack while resizing the window', async ({ launchElectronApp }) => {
const app = await launchElectronApp({ skipSetup: true });
try {
@@ -103,7 +103,7 @@ test.describe('Makelore module navigation without setup flow', () => {
}));
const initialMetrics = await readCardMetrics();
expect(initialMetrics).toHaveLength(3);
expect(initialMetrics).toHaveLength(4);
await expect(moduleCards.first().locator('.module-option-card-arrow')).toHaveCount(0);
await expect(moduleCards.first().locator('.module-option-artwork')).toHaveCount(0);
await expect.poll(async () => await moduleCards.first().evaluate((element) => {
@@ -155,7 +155,7 @@ test.describe('Makelore module navigation without setup flow', () => {
await expect.poll(async () => (await readCardMetrics())[0]?.width ?? 0).toBeLessThan(initialWidth - 1);
const resizedMetrics = await readCardMetrics();
expect(resizedMetrics).toHaveLength(3);
expect(resizedMetrics).toHaveLength(4);
expect(Math.max(...resizedMetrics.map((card) => card.left)) - Math.min(...resizedMetrics.map((card) => card.left))).toBeLessThan(1);
expect(resizedMetrics.map((card) => card.top)).toEqual(
[...resizedMetrics].sort((top, bottom) => top.top - bottom.top).map((card) => card.top),
@@ -195,7 +195,7 @@ test.describe('Makelore module navigation without setup flow', () => {
const page = await getStableWindow(app);
await expect(page.getByTestId('ai-module-selection-page')).toBeVisible();
await expect(page.locator('[data-testid^="ai-module-option-"]')).toHaveCount(3);
await expect(page.locator('[data-testid^="ai-module-option-"]')).toHaveCount(4);
await expect(page.getByTestId('ai-module-option-learning')).toHaveCount(0);
await page.evaluate(() => {
window.location.hash = '#/learning';