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 strange UI behavior of cancelling dismiss review modal (#25133) #25147

Closed

Conversation

GiteaBot
Copy link
Collaborator

@GiteaBot GiteaBot commented Jun 8, 2023

Backport #25133 by @yp05327

Fixes #25130

The old code uses $(this).next() to get dismiss-review-modal.
At first, it will get $(#dismiss-review-modal), but the next time it will get $(#dismiss-review-modal).next();
and then $(#dismiss-review-modal).next().next();.
Because div dismiss-review-modal will be removed when dismiss-review-btn clicked.

Maybe the right usage is adding show-modal class and data-modal attribute.

…25133)

Fixes go-gitea#25130

The old code uses `$(this).next()` to get `dismiss-review-modal`.
At first, it will get `$(#dismiss-review-modal)`, but the next time it
will get `$(#dismiss-review-modal).next();`
and then `$(#dismiss-review-modal).next().next();`.
Because div `dismiss-review-modal` will be removed when
`dismiss-review-btn` clicked.

Maybe the right usage is adding `show-modal` class and `data-modal`
attribute.
@GiteaBot GiteaBot added type/bug topic/ui Change the appearance of the Gitea UI labels Jun 8, 2023
@GiteaBot GiteaBot added this to the 1.20.0 milestone Jun 8, 2023
@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jun 8, 2023
@pull-request-size pull-request-size bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Jun 8, 2023
@GiteaBot GiteaBot requested review from silverwind and wolfogre June 8, 2023 08:52
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Jun 8, 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 Jun 8, 2023
@silverwind silverwind enabled auto-merge (squash) June 8, 2023 08:53
@lunny lunny added the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Jun 8, 2023
@lunny lunny removed the reviewed/wait-merge This pull request is part of the merge queue. It will be merged soon. label Jun 8, 2023
@wxiaoguang wxiaoguang added the status/blocked This PR cannot be merged yet, i.e. because it depends on another unmerged PR label Jun 8, 2023
Copy link
Member

@techknowlogick techknowlogick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

adding blocked review so this doesn't get accidentally merged. feel free to dismiss this review as needed

@GiteaBot GiteaBot added lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged and removed lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. labels Jun 8, 2023
@silverwind
Copy link
Member

Blocked because of #25133 (comment). Once the fix is available, we can still merge this and then backport the fix.

@silverwind
Copy link
Member

Merge this before the backport of #25162

@silverwind
Copy link
Member

silverwind commented Jun 9, 2023

#25172 contains this backport.

@silverwind silverwind closed this Jun 9, 2023
auto-merge was automatically disabled June 9, 2023 10:45

Pull request was closed

@GiteaBot GiteaBot removed this from the 1.20.0 milestone Jun 9, 2023
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Sep 7, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/blocked A maintainer has reservations with the PR and thus it cannot be merged size/S Denotes a PR that changes 10-29 lines, ignoring generated files. status/blocked This PR cannot be merged yet, i.e. because it depends on another unmerged PR topic/ui Change the appearance of the Gitea UI type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants