Skip to content

Commit 276b4d8

Browse files
committed
fix(release): remove preview run status overlay [skip ci]
1 parent 81ac1c6 commit 276b4d8

6 files changed

Lines changed: 35 additions & 66 deletions

File tree

apps/web/src/components/FileWorkspace.tsx

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,6 @@ import { useInView } from './plugins-home/useInView';
139139
import { LiveArtifactBadges } from './LiveArtifactBadges';
140140
import { MissingBrandFontsBanner } from './MissingBrandFontsBanner';
141141
import { LibraryPicker } from './LibraryPicker';
142-
import { PreviewRunStatusBar } from './PreviewRunStatusBar';
143142
import { QuickSwitcher } from './QuickSwitcher';
144143
import { SketchEditor } from './SketchEditor';
145144
import { SketchEnginePrewarm } from './SketchEnginePrewarm';
@@ -2847,12 +2846,6 @@ export function FileWorkspace({
28472846
return liveArtifactEntries.find((entry) => entry.tabId === activeTab) ?? null;
28482847
}, [activeTab, liveArtifactEntries]);
28492848

2850-
// The delivery hint belongs to the main design-preview surface only. Browser,
2851-
// terminal, questions, design-system, and side-chat tabs carry their own
2852-
// context and must not inherit status/analytics from the primary chat.
2853-
const showPreviewRunStatus =
2854-
activeTab === DESIGN_FILES_TAB || activeLiveArtifact !== null || activeFile !== null;
2855-
28562849
// Identity-stable props for the memoized FileViewer. Without these, every
28572850
// FileWorkspace state change (closing an adjacent tab, drag hover, launcher
28582851
// toggles) would hand FileViewer fresh object/function identities and drag
@@ -3903,15 +3896,6 @@ export function FileWorkspace({
39033896
.
39043897
</div>
39053898
)}
3906-
{showPreviewRunStatus ? (
3907-
<div className="ws-preview-run-status-slot">
3908-
<PreviewRunStatusBar
3909-
projectId={projectId}
3910-
conversationId={conversationId}
3911-
messages={messages}
3912-
/>
3913-
</div>
3914-
) : null}
39153899
</div>
39163900
<PageCreatorDialog
39173901
open={pageCreatorOpen}

apps/web/src/styles/workspace/drawer.css

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2544,26 +2544,6 @@
25442544
position: relative;
25452545
}
25462546

2547-
/* Canvas-local Design delivery feedback. It stays with the workspace while
2548-
the empty placeholder hands over to an actual file preview, rather than
2549-
becoming a bottom-of-screen notification. */
2550-
.ws-preview-run-status-slot {
2551-
position: absolute;
2552-
z-index: 2;
2553-
top: 50%;
2554-
left: 50%;
2555-
max-width: calc(100% - 48px);
2556-
pointer-events: none;
2557-
transform: translate(-50%, 116px);
2558-
}
2559-
2560-
@media (max-width: 640px) {
2561-
.ws-preview-run-status-slot {
2562-
max-width: calc(100% - 32px);
2563-
transform: translate(-50%, 104px);
2564-
}
2565-
}
2566-
25672547
.ws-browser-panel {
25682548
display: flex;
25692549
position: absolute;

apps/web/tests/components/FileWorkspace.test.tsx

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3076,11 +3076,12 @@ describe('FileWorkspace empty-project generation contract', () => {
30763076

30773077
expect(screen.queryByTestId('generating-tab')).toBeNull();
30783078
expect(screen.queryByTestId('generation-preview-stage')).toBeNull();
3079+
expect(screen.queryByTestId('preview-run-status')).toBeNull();
30793080
expect(screen.getByTestId('design-files-empty')).toBeTruthy();
30803081
},
30813082
);
30823083

3083-
it('keeps delivery recovery in Chat and leaves a passive failure hint over existing preview files', () => {
3084+
it('keeps delivery recovery in Chat without mounting status over existing preview files', () => {
30843085
render(
30853086
<FileWorkspace
30863087
projectId="project-1"
@@ -3104,13 +3105,9 @@ describe('FileWorkspace empty-project generation contract', () => {
31043105
/>,
31053106
);
31063107

3107-
const previewStatus = screen.getByTestId('preview-run-status');
3108-
expect(previewStatus).toHaveTextContent('Delivery needs attention · Retry in Chat');
3109-
expect(previewStatus.closest('.ws-preview-run-status-slot')).not.toBeNull();
3110-
expect(previewStatus.closest('[data-testid="design-files-empty"]')).toBeNull();
3108+
expect(screen.queryByTestId('preview-run-status')).toBeNull();
31113109
expect(screen.queryByTestId('preview-run-status-retry')).toBeNull();
31123110
expect(screen.queryByTestId('preview-run-status-view-details')).toBeNull();
3113-
expect(previewStatus).not.toHaveTextContent('Elapsed');
31143111
});
31153112

31163113
it('does not mount main-preview delivery feedback over a browser tab', () => {
@@ -3145,7 +3142,7 @@ describe('FileWorkspace empty-project generation contract', () => {
31453142
expect(screen.queryByTestId('preview-run-status')).toBeNull();
31463143
});
31473144

3148-
it('keeps a delivered confirmation on the preview canvas after files arrive', () => {
3145+
it('does not mount a delivered confirmation over the preview canvas', () => {
31493146
const now = 1_700_000_012_500;
31503147
vi.spyOn(Date, 'now').mockReturnValue(now);
31513148
render(
@@ -3172,13 +3169,6 @@ describe('FileWorkspace empty-project generation contract', () => {
31723169
/>,
31733170
);
31743171

3175-
const previewStatus = screen.getByTestId('preview-run-status');
3176-
expect(previewStatus).toHaveTextContent('Design ready');
3177-
expect(previewStatus.closest('.ws-preview-run-status-slot')).not.toBeNull();
3178-
expect(previewStatus.closest('[data-testid="design-files-empty"]')).toBeNull();
3179-
expect(previewStatus).not.toHaveAttribute('aria-live');
3180-
expect(within(previewStatus).getByRole('status')).toHaveTextContent('Design ready');
3181-
expect(previewStatus).not.toHaveTextContent('Elapsed');
3182-
expect(previewStatus.querySelector('[aria-hidden="true"]')).toBeNull();
3172+
expect(screen.queryByTestId('preview-run-status')).toBeNull();
31833173
});
31843174
});

docs/CHANGELOG/v0.16.1/en.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
title: Open Design 0.16.1
3+
description: A focused patch that keeps run status out of the design preview.
4+
---
5+
6+
# Open Design 0.16.1 — An Unobstructed Preview
7+
8+
0.16.1 is a focused patch release for the design preview.
9+
10+
## 🐛 Fixed
11+
12+
- **Run status no longer covers generated work.** Building, completion, and delivery-recovery status stays in Chat instead of appearing over the preview canvas. Chat remains the place to follow progress or retry a failed delivery. (#6005, #6027)

docs/CHANGELOG/v0.16.1/zh-CN.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
title: Open Design 0.16.1
3+
description: 一次聚焦修复,让运行状态不再遮挡设计预览。
4+
---
5+
6+
# Open Design 0.16.1 — 不被遮挡的预览
7+
8+
0.16.1 是一次聚焦于设计预览的补丁版本。
9+
10+
## 🐛 修复
11+
12+
- **运行状态不再遮挡生成结果。** 构建中、已完成和交付恢复状态会留在 Chat 中,不再显示在预览画布上。任务进度和交付失败重试仍统一在 Chat 中处理。 (#6005, #6027)

e2e/ui/preview-run-status.test.ts

Lines changed: 6 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ test.beforeAll(async () => {
1616
codexEnv = runtimes.codex.env;
1717
});
1818

19-
test('[P1] preview delivery status keeps persisted delivery-failure recovery in Chat', async ({ page }) => {
19+
test('[P1] preview canvas omits run status while Chat keeps delivery recovery', async ({ page }) => {
2020
test.setTimeout(T.xlong);
2121
const projectId = `preview-run-status-${Date.now()}`;
2222
const now = Date.now();
@@ -78,23 +78,17 @@ test('[P1] preview delivery status keeps persisted delivery-failure recovery in
7878
expect(failedResponse.ok(), await failedResponse.text()).toBeTruthy();
7979

8080
await gotoProject(page, projectId);
81-
const status = page.getByTestId('preview-run-status');
82-
await expect(status).toContainText('Delivery needs attention');
83-
await expect(status.locator('xpath=ancestor::*[contains(@class, "ws-preview-run-status-slot")]')).toHaveCount(1);
84-
await expect(status.locator('xpath=ancestor::*[@data-testid="design-files-empty"]')).toHaveCount(0);
85-
await expect(status).not.toContainText('Elapsed');
81+
await expect(page.getByTestId('preview-run-status')).toHaveCount(0);
8682
await expect(page.getByTestId('preview-run-status-retry')).toHaveCount(0);
87-
await expect(status).toContainText('Retry in Chat');
8883
await expect(page.getByTestId('preview-run-status-view-details')).toHaveCount(0);
8984
const chatRetry = page.locator('.chat-error-retry');
9085
await expect(chatRetry).toBeVisible();
9186

92-
// The persisted preview hint stays passive after navigation; the Chat
93-
// failure card remains the sole retry entry point.
87+
// The preview stays unobstructed after navigation; the Chat failure card
88+
// remains the sole retry entry point.
9489
await gotoEntryHome(page);
9590
await gotoProject(page, projectId);
96-
await expect(page.getByTestId('preview-run-status')).toContainText('Delivery needs attention');
97-
await expect(page.getByTestId('preview-run-status')).not.toContainText('Elapsed');
91+
await expect(page.getByTestId('preview-run-status')).toHaveCount(0);
9892
await expect(page.locator('.chat-error-retry')).toBeVisible();
9993

10094
await page.locator('.chat-error-retry').click();
@@ -118,8 +112,5 @@ test('[P1] preview delivery status keeps persisted delivery-failure recovery in
118112
}, { timeout: T.long })
119113
.toContain('fake-agent-runtime-codex.html');
120114

121-
await expect(page.getByTestId('preview-run-status')).toContainText('Design ready');
122-
await expect(
123-
page.getByTestId('preview-run-status').locator('xpath=ancestor::*[contains(@class, "ws-preview-run-status-slot")]'),
124-
).toHaveCount(1);
115+
await expect(page.getByTestId('preview-run-status')).toHaveCount(0);
125116
});

0 commit comments

Comments
 (0)