-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
fix: border width disappearing when using border radius in bottom sheet #20891
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
fix: border width disappearing when using border radius in bottom sheet #20891
Conversation
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
...components/BottomSheets/BottomSheet/foundation/BottomSheetDialog/BottomSheetDialog.styles.ts
Outdated
Show resolved
Hide resolved
…ul-1078-bottom-sheet-border-disappearing-in-corners
…s' of github.com:MetaMask/metamask-mobile into fix-mul-1078-bottom-sheet-border-disappearing-in-corners
…ul-1078-bottom-sheet-border-disappearing-in-corners
…s' of github.com:MetaMask/metamask-mobile into fix-mul-1078-bottom-sheet-border-disappearing-in-corners
…ul-1078-bottom-sheet-border-disappearing-in-corners
|
brianacnguyen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DS changes look good
|
This PR has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions. |



Description
Problem
The
BottomSheetDialogcomponent had visual artifacts at corners where borders didn't properly follow the rounded corners, a known React Native rendering issue whenborderRadiusandborderWidthare applied to the same container.Solution
Implemented a two-layer rendering approach:
sizing, and shadows
Both layers use matching
24pxborder radius andoverflow: 'hidden'to ensure perfect alignment and proper clipping.Changes
BottomSheetDialog.styles.ts: Split sheet styles into two layersBottomSheetDialog.tsx: Wrapped content in newinnerSheetContainerViewWhy This Works
Separating border properties from layout properties allows React Native to render each layer independently, preventing the conflicts that cause corner artifacts. This is a standard pattern for resolving React Native border radius issues.
Changelog
CHANGELOG entry:null
Related issues
Fixes: https://consensyssoftware.atlassian.net/browse/MUL-1078
Manual testing steps
Screenshots/Recordings
~Before
Android remains unaffected by this bug
After
Android remains unaffected by these changes
Pre-merge author checklist
Pre-merge reviewer checklist
Note
Refactors
BottomSheetDialogto use an outer border layer and inner content container to resolve border radius artifacts, updating affected snapshots and minor docs/tests formatting.BottomSheetDialogto two-layer structure (outer sheet forborder/borderRadius; inner container for content, padding, sizing, shadows) to fix rounded border rendering.Written by Cursor Bugbot for commit 1e9f03c. This will update automatically on new commits. Configure here.