fix(figma): run live preview edge-to-edge in full-screen mode#71
Merged
Conversation
When the live-preview WebView hides the bottom tab bar (full-screen toggle), the SafeAreaView still applied the top inset, so the prototype stayed clipped under the notch/status bar — the bottom bar was gone but the top wasn't, which looked broken. Switch the SafeAreaView to a no-inset edge set while the tab bar is hidden so the preview fills the whole screen, then restore the normal safe-area edges when the bar comes back. Verified on iOS sim: toggling full-screen expands the WebView from (0, 0.071, 1, 0.834) to (0, 0, 1, 1) and back. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
In the Figma live-preview screen, the full-screen toggle hides the bottom tab bar, but the WebView is still wrapped in a
SafeAreaViewwith atop: 'additive'inset. So in "full-screen" the bottom bar disappears while the prototype stays clipped under the notch/status bar — half-immersive and visually broken.Fix
PulsarApp/app/(tabs)/figma.tsx: when the tab bar is hidden, swap theSafeAreaViewto a no-inset edge set (top/left/right/bottom: 'off') so the preview runs truly edge-to-edge; restore the normaldefaultEdgeswhen the bar returns. ThetabBarHiddenstate already drives the bar visibility, so the edge set is derived from it.Verification (iOS simulator)
Toggling full-screen expands the WebView bounds and removes the top clip, and toggling back restores them:
(0, 0.071, 1, 0.834)(0, 0, 1, 1)Notes
set-tab-bar-hiddenhandling this builds on already exists onmain).🤖 Generated with Claude Code