Refactor/stable bottom sheet peek height#6233
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors bottom sheet inset + peek-height calculation to make collapsed height more stable across different system inset configurations, and adjusts a few related UI flows (setup name submission state, swap error messaging, and help links).
Changes:
- Refactor bottom sheet inset handling and peek-height computation (including optional bottom-inset application and nav-bar-aware offsets).
- Restructure user/group bottom sheet layouts to separate “collapsed content” vs menu content and support stable collapsed measurement.
- Update Setup Name “Continue” UI to support a submitting/loading state, and add/adjust a couple of strings + preference cleanup.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| app/src/main/res/values/strings.xml | Adjust swap detailed error strings; add forget PIN help URL |
| app/src/main/res/values-zh-rCN/strings.xml | Same as above for zh-CN |
| app/src/main/res/layout/fragment_user_bottom_sheet.xml | Add top_content and menu_container to support stable collapsed measurement |
| app/src/main/res/layout/fragment_group_bottom_sheet.xml | Same layout restructuring as user bottom sheet |
| app/src/main/res/layout/fragment_setup_name.xml | Replace continue Button with ViewAnimator containing text + progress |
| app/src/main/res/layout-v26/fragment_setup_name.xml | Same as above for v26 |
| app/src/main/java/one/mixin/android/widget/MixinBottomSheetDialog.kt | Add flag to control whether bottom inset is applied to the sheet |
| app/src/main/java/one/mixin/android/widget/BottomSheetDialogInsets.kt | Switch bottom inset application to tappable-element insets + optional application |
| app/src/main/java/one/mixin/android/ui/landing/SetupNameFragment.kt | Add submitting/retry state handling for continue action |
| app/src/main/java/one/mixin/android/ui/home/web3/trade/SwapContent.kt | Refactor “input > max” check and error display derivation |
| app/src/main/java/one/mixin/android/ui/common/info/MixinScrollableBottomSheetDialogFragment.kt | Centralize peek-height scheduling + conditional inset routing to scroll content |
| app/src/main/java/one/mixin/android/ui/common/UserBottomSheetDialogFragment.kt | Use new collapsed-height measurement and updated menu container |
| app/src/main/java/one/mixin/android/ui/common/GroupBottomSheetDialogFragment.kt | Same as user: collapsed-height measurement + menu container |
| app/src/main/java/one/mixin/android/ui/common/BottomSheetPeekHeight.kt | Refine bottom-inset calculation logic with tappable-element awareness |
| app/src/main/java/one/mixin/android/ui/common/LoginVerifyBottomSheetDialogFragment.kt | Use new forget PIN help URL string |
| app/src/main/java/one/mixin/android/MixinApplication.kt | Clear PREF_APP_AUTH on logout/cleanup |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
app/src/main/java/one/mixin/android/ui/common/info/MixinScrollableBottomSheetDialogFragment.kt
Show resolved
Hide resolved
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.
No description provided.