Skip to content

Commit 39197ae

Browse files
nabettuclaude
andcommitted
fix(mobile): iOS HTML file previews start below the header
File screens use a transparent header, and react-native-webview defaults contentInsetAdjustmentBehavior to "never", so the top of HTML previews sat under the status bar and header. Let UIKit apply the safe-area insets. Refs #21415 Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 1451e7c commit 39197ae

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎apps/mobile/src/features/files/WorkspaceFileWebPreview.tsx‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ function DocumentWebPreview(props: { readonly uri: string }) {
6868
) : null}
6969
<WebView
7070
source={{ uri: props.uri }}
71+
// File screens use a transparent glass header; react-native-webview defaults to "never",
72+
// so without this HTML starts under the status bar and header.
73+
contentInsetAdjustmentBehavior="automatic"
7174
originWhitelist={["*"]}
7275
allowsBackForwardNavigationGestures
7376
allowsFullscreenVideo

0 commit comments

Comments
 (0)