MCP apps are covered by the right pane at some widths on macOS
Summary
An MCP app in the Codex right pane becomes completely hidden at some pane
widths. The widget stays mounted and rendered. The right pane covers it.
I reproduced this with GitRight. With a 2560 × 1410 window at 2x scale, the
problem appears when the right pane is about 750–1220 CSS px wide. The exact
range changes with the window and sidebar widths.
Steps to reproduce
- Open an MCP app such as GitRight in the Codex right pane.
- Resize the right pane slowly.
- At some middle widths, the MCP app disappears. The pane shows the ChatGPT app's background color instead.
- Make the pane narrower or wider. The MCP app appears again.
Runtime observations
The widget is still healthy while it is hidden:
- Its webview remains mounted and has the expected size.
- Its DOM is rendered.
- Its opacity and visibility are normal.
- Its display mode remains
fullscreen. - The packaged widget renders correctly at every tested width in a standalone
host.
In the affected range, runtime DOM inspection shows:
- The fullscreen MCP app wrapper has
position: fixedandz-index: 43. - The right pane has
z-index: 41. - An ancestor of the MCP app has
transform: translateX(-158px). - The right pane appears above the MCP app at their overlapping coordinates.
This suggests a stacking-context problem. The transformed ancestor prevents the
fixed MCP app from appearing above the right pane, even though the app wrapper
has the larger z-index.
Causal checks
- At the same window and pane size, I disabled only the ancestor transform. The
MCP app changed from covered to visible.
- I restored the transform. The MCP app became covered again.
- I replaced the transform with the equivalent layout offset,
transform: none; position: relative; left: -158px. The thread stayed at the
same screen coordinates, and the MCP app stayed visible.
- I clicked "Expand side panel". The MCP app became visible immediately.
Restoring the previous pane width made it hidden again.
No in-widget workaround
The widget does not receive a notification that it is covered. It receives
container dimension updates, but those do not say whether the host is drawing
the pane above it. document.visibilityState also changes, but normal tab
changes produce the same signal.
An automatic requestDisplayMode({ mode: "inline" }) call does not work when
the host layout changes because the widget has no user activation at that time.
A call made with a user gesture can move the widget inline, but it does not fix
the right-pane layout.
The widget cannot change the host ancestor style or expand the host side panel.
Suggested fix
Please avoid using a transform on the thread ancestor when an MCP app is shown
in the right pane. A layout offset such as position: relative with left
keeps the same placement without creating this stacking context.
Another option is to mount the fullscreen MCP app portal outside the
transformed ancestor. Its fixed positioning and z-index would then share a
stacking context with the right pane.
Environment
- macOS, arm64
- Codex Framework 150.0.7871.128
- Window: 2560 × 1410 at 2x scale
- Plugin: GitRight 0.1.0-beta.2
Related
#33252 reports a similar disappearing widget on Windows with the built-in
DataAnalyticsWidget. That report suspects ResizeObserver. It may share the same
root cause, but this report covers an MCP app on macOS and includes a
stacking-context causal test.