style(workspace): remove the embedded work preview title bar
This commit is contained in:
@@ -264,7 +264,13 @@ describe('AgentBrowserPanel', () => {
|
||||
const onOpenChange = vi.fn();
|
||||
const view = render(<AgentBrowserPanel projectId="project-a" open embedded onOpenChange={onOpenChange} />);
|
||||
await waitFor(() => expect(latestPresentation()).toMatchObject({ project_id: 'project-a', visible: true }));
|
||||
expect(screen.getByRole('complementary', { name: '作品预览' })).toBeVisible();
|
||||
expect(screen.queryByRole('heading', { name: '作品预览' })).not.toBeInTheDocument();
|
||||
expect(screen.queryByRole('button', { name: '收起作品' })).not.toBeInTheDocument();
|
||||
expect(screen.getByRole('textbox', { name: '网页地址' })).toHaveValue('http://127.0.0.1:4173/');
|
||||
expect(screen.getByRole('textbox', { name: '网页地址' })).toBeEnabled();
|
||||
expect(screen.getByTestId('agent-browser-viewport')).toBeVisible();
|
||||
expect(screen.getByTestId('agent-browser-viewport')).toHaveAccessibleName('作品画面');
|
||||
|
||||
view.rerender(<AgentBrowserPanel projectId="project-a" open={false} embedded onOpenChange={onOpenChange} />);
|
||||
await waitFor(() => expect(latestPresentation()).toMatchObject({ visible: false }));
|
||||
|
||||
Reference in New Issue
Block a user