Preview panel renders blank on open — fixes only after window minimize/restore
Description
When opening the preview panel in Claude Code, the left portion of the panel stays black/empty, and the content (in this case, FastAPI Swagger UI at /docs) only appears in the right portion of the split view.
The issue resolves itself after minimizing and restoring the Claude Code window.
Steps to Reproduce
- Start a local FastAPI server (e.g. on port 8010)
- Configure
.claude/launch.jsonwith"url": "http://localhost:8010/docs" - Call
preview_startto open the preview panel - Observe the preview panel — left side is black, content is clipped to the right
Expected Behavior
Preview panel renders the full content correctly on first open.
Actual Behavior
Left side of the preview panel is black. Content is partially visible on the right. After minimizing and restoring the Claude Code window, the panel renders correctly.
Root Cause (suspected)
The preview iframe likely does not receive a resize event when the panel is first opened. Minimizing/restoring the window triggers a resize event, which causes the iframe content to reflow and render correctly.
Environment
- OS: macOS (Darwin 25.3.0)
- App: Claude Code desktop
- Server: FastAPI with Swagger UI (
/docs)
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗