Skip to content
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

Fix review box viewport overflow issue (#23800) #23898

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

GiteaBot
Copy link
Contributor

@GiteaBot GiteaBot commented Apr 3, 2023

Backport #23800 by @silverwind

Fix regression that came likely from #23271:

Long lines of text currently cause the review box's CodeMirror element to resize which apparently is not recognized by popper's resize detection and which causes the element to go partially out of viewport until a reflow happens:

wrap

Fix this by setting the element to a static width derived from viewport width and remove the previously clumsy media queries.

Fix regression that came likely from
go-gitea#23271:

Long lines of text currently cause the review box's CodeMirror element
to resize which apparently is not recognized by [popper's resize
detection](https://popper.js.org/docs/v2/modifiers/event-listeners/) and
which causes the element to go partially out of viewport until a reflow
happens:


![wrap](https://user-images.githubusercontent.com/115237/228673260-f8ffe89e-5724-4fb9-b93f-30b146c4c436.gif)

Fix this by setting the element to a static width derived from viewport
width and remove the previously clumsy media queries.
@GiteaBot GiteaBot added type/bug topic/ui Change the appearance of the Gitea UI labels Apr 3, 2023
@GiteaBot GiteaBot added this to the 1.19.2 milestone Apr 3, 2023
@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Apr 3, 2023
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Apr 3, 2023
@jolheiser jolheiser enabled auto-merge (squash) April 3, 2023 15:20
@jolheiser jolheiser merged commit 847f0bb into go-gitea:release/v1.19 Apr 3, 2023
@techknowlogick techknowlogick deleted the backport-23800-v1.19 branch April 3, 2023 16:33
@6543 6543 modified the milestones: 1.19.2, 1.19.1 Apr 3, 2023
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Aug 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. topic/ui Change the appearance of the Gitea UI type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants