Repository navigation
Keep the commented text above the comment sheet on a phone - #189
Merged
Merged
Conversation
On a phone, the comment sheet and the keyboard covered the lower half of the screen, so a line or a block tapped in that part was hidden behind them, and a dark overlay dimmed the rest. The sheet now reports the top of the area that it and the keyboard cover, and the review pane scrolls so the end of the commented line or block sits just above it. The scroll follows the sheet animation, the keyboard and the pane resize until the reviewer scrolls. A bottom padding lets the last lines of a file scroll above the sheet. The review header hides while the sheet is open, to give the text more room, and the overlay of the comment sheet is lighter.
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.
Summary: On a phone, the line or block that the reviewer comments on stays visible directly above the comment sheet.
Changes:
ComposerSheetreports the top of the area that the sheet and the keyboard cover. It measures again after the slide-in animation and when the visible area changes.SheetContenttakes anoverlayClassName. The comment sheet usesbg-black/25, and the other sheets keep their overlay.Tests: e2e tests on the phone viewport for a line in the source view and a block in the rendered view near the end of a file. The test browser has no keyboard, so the behavior with a real keyboard is not tested.