fix(VoIP): NewMediaCall sheet hugs content on Android - #7258
Merged
diegolmello merged 2 commits intoApr 27, 2026
Conversation
The shared `fullContainer` action-sheet style forced `height: '100%'` on the inner wrapping View. For callers that pass `fullContainer: true` without snaps (NewMediaCall is the only such caller), this caused the contentHeight-driven detent calculation in `useActionSheetDetents` to lock the sheet at the max detent (0.75), leaving a large empty area below the Call button on Android. iOS skipped this path and rendered correctly. Removing `height: '100%'` lets the inner View size to its children, so onLayout reports the actual intrinsic content height and the detent computes correctly. The 4 other `fullContainer: true` callsites all pass snaps, which short-circuits the contentHeight branch in `useActionSheetDetents`; their detents come from the snaps and are not affected by this change. Empty-space symptom introduced by #7235.
diegolmello
had a problem deploying
to
approve_e2e_testing
April 27, 2026 18:49 — with
GitHub Actions
Error
Contributor
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
💤 Files with no reviewable changes (1)
📜 Recent review details⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
WalkthroughRemoved explicit flex/height layout properties from two component styles: Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Suggested labels
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
diegolmello
had a problem deploying
to
official_ios_build
April 27, 2026 18:54 — with
GitHub Actions
Error
diegolmello
had a problem deploying
to
experimental_ios_build
April 27, 2026 18:54 — with
GitHub Actions
Error
diegolmello
had a problem deploying
to
experimental_android_build
April 27, 2026 18:54 — with
GitHub Actions
Error
diegolmello
had a problem deploying
to
official_android_build
April 27, 2026 18:54 — with
GitHub Actions
Error
Without `height: '100%'` on the parent `fullContainer` wrapper, the inner `screen` View's `flex: 1` collapses to padding-only height (~84px) inside the unconstrained `flex: 0` parent. On Android only the bottom subset of children (search input, selected-peer pill, Call button) renders visibly; the "New call" title and the "Enter username or number" helper are clipped. Dropping `flex: 1` lets the screen size to its children's intrinsic heights, so the full UI renders and the sheet detent (computed from onLayout) reflects actual content height.
diegolmello
had a problem deploying
to
approve_e2e_testing
April 27, 2026 19:24 — with
GitHub Actions
Failure
diegolmello
had a problem deploying
to
official_android_build
April 27, 2026 19:27 — with
GitHub Actions
Failure
diegolmello
had a problem deploying
to
experimental_android_build
April 27, 2026 19:27 — with
GitHub Actions
Failure
diegolmello
had a problem deploying
to
experimental_ios_build
April 27, 2026 19:27 — with
GitHub Actions
Failure
diegolmello
had a problem deploying
to
official_ios_build
April 27, 2026 19:27 — with
GitHub Actions
Failure
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.
Proposed changes
Two layout fixes for the NewMediaCall action sheet on Android, which was rendering with ~250-300px of empty space below the green "Ligar" button.
Fix 1 —
app/containers/ActionSheet/styles.ts: dropheight: '100%'from the sharedfullContainerstyle.useActionSheetDetentshas two detent paths: snap-driven and contentHeight-driven. WhenfullContainer: truepropagatedheight: '100%'to the inner wrapping View, callers in the contentHeight path got a detent locked at the max fraction (0.75) becauseonLayoutreported the View's forced 100% of TrueSheet's max area instead of actual content height. NewMediaCall is the onlyfullContainer: truecaller that doesn't pass snaps, so it was the only one stuck. iOS bypasses the affected branch (fullContainer: false).Fix 2 —
app/containers/NewMediaCall/NewMediaCall.tsx: dropflex: 1from thescreenstyle.After fix 1, the parent wrapper became
flex: 0with no fixed height. The innerscreenView'sflex: 1then collapsed to padding-only (~84px on a 2400px-tall emulator), clipping the "New call" title and "Enter username or number" helper — only the search input, selected-peer pill, and Call button rendered. Droppingflex: 1lets the screen size to its children's intrinsic heights so the full UI renders and the detent reflects actual content height.The naive alternative — dropping
fullContainer: isAndroidfrom the NewMediaCall caller — was tried earlier and breaks Android rendering: title and helper disappear because the detent collapses too small. The flag wasn't wrong; the underlying styles were.Issue(s)
https://rocketchat.atlassian.net/browse/VMUX-103
How to test or reproduce
Android:
Audit of all 5
fullContainer: truecallsites:useNewMediaCall.tsxuseVideoConf/index.tsxRoomView/index.tsx(ReactionPicker)RoomView/index.tsx(ReactionsList)NewMessageView/Item.tsxiOS: unchanged (bypasses both paths via
fullContainer: falsefor NewMediaCall).Screenshots
Visual diff vs Figma reference: pass (
visual-verdictscore 93/100 on the post-fix state; remaining differences are theme/i18n/content variations).Types of changes
Checklist
yarn lintclean;TZ=UTC yarn test --testPathPattern='NewMediaCall|ActionSheet|useActionSheetDetents'— 8 suites / 65 tests / 10 snapshots green)Summary by CodeRabbit